Merge branch 'master' of github.com:diaspora/diaspora

This commit is contained in:
ilya 2010-09-29 12:16:07 -07:00
commit cbe65aeb49
7 changed files with 82 additions and 32 deletions

View file

@ -31,10 +31,16 @@ class UsersController < ApplicationController
def public
user = User.find_by_username(params[:username])
director = Diaspora::Director.new
ostatus_builder = Diaspora::OstatusBuilder.new(user)
render :xml => director.build(ostatus_builder)
if user
director = Diaspora::Director.new
ostatus_builder = Diaspora::OstatusBuilder.new(user)
render :xml => director.build(ostatus_builder)
else
flash[:error] = "User #{params[:username]} does not exist!"
redirect_to root_url
end
end
private

View file

@ -22,3 +22,13 @@
\--
= link_to "#{t('.show_comments')} (#{post.comments.count})", '#', :class => "show_post_comments"
= render "comments/comments", :post => post
- if post.public?
.public_aspect_tag
public
- else
.aspect_tag
%ul
- for aspect in current_user.aspects_with_post( post.id )
%li= aspect.name

View file

@ -4,11 +4,11 @@
#aspect_nav
%ul
%li{:class => ("selected" if @aspect == :all)}
= link_to t('.all_aspects'), root_url
- for aspect in @aspects
%li{:class => ("selected" if current_aspect?(aspect))}
= link_for_aspect aspect
%li{:class => ("selected" if @aspect == :all)}
= link_to t('.all_aspects'), root_url
%ul{ :style => "position:absolute;right:0;bottom:0.01em;"}
%li{:class => ("selected" if @aspect == :public)}

View file

@ -7,6 +7,7 @@
= @status_message.message
%h4= "#{t('.comments')} (#{@status_message.comments.count})"
= render "comments/comments", :post => @status_message
%p

View file

@ -21,10 +21,10 @@ $(".show_post_comments").live('click', function(event) {
if( $this.hasClass( "visible")) {
$this.html($(this).html().replace("hide", "show"));
$this.closest("li").children(".content").children(".comments").fadeOut(100);
$this.closest("li").children(".content").children(".comments").slideUp(150);
} else {
$this.html($(this).html().replace("show", "hide"));
$this.closest("li").children(".content").children(".comments").fadeIn(100);
$this.closest("li").children(".content").children(".comments").slideDown(150);
}
$(this).toggleClass( "visible" );
});

View file

@ -118,6 +118,9 @@ header {
header #session_action ul li:last-child {
margin-right: 0; }
header #aspect_header {
-webkit-box-shadow: 0px -4px 6px -2px #777777;
background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#f7f7f7), to(#eeeeee));
background: -moz-linear-gradient(19% 75% 90deg, #eeeeee, #f7f7f7);
background-color: #eeeeee;
border-top: 1px solid white;
padding: 20px 0; }
@ -143,7 +146,9 @@ ul#stream {
padding: 12px 0;
border-bottom: 1px solid #eeeeee; }
ul#stream > li:hover {
background-color: #fafafa; }
background: -webkit-gradient(linear, 0% 0%, 0% 50%, from(#fafafa), to(#fcfcfc));
background-color: #fafafa;
border-bottom: 1px solid #dddddd; }
ul#stream > li:hover .destroy_link {
display: inline; }
ul#stream .right {
@ -160,7 +165,8 @@ li.message {
li.message .delete:hover {
background: #eeeeee; }
li.message .content {
padding-left: 65px; }
padding-left: 65px;
width: 600px; }
li.message .content span.from {
color: black;
font-weight: normal;
@ -262,7 +268,7 @@ ul.comment_set {
margin-bottom: 0.5em;
background-color: rgba(10, 81, 109, 0.05);
padding: 0.6em;
border-bottom: 1px solid #cccccc; }
border-bottom: 1px solid #dddddd; }
ul.comment_set li.comment .from {
font-size: 1em; }
ul.comment_set li.comment div.time {
@ -387,13 +393,15 @@ label {
height: 42px;
margin-top: 0;
margin-bottom: 0;
box-shadow: 0 1px white;
-moz-box-shadow: 0 1px white;
-webkit-box-shadow: 0 1px white; }
box-shadow: 0 1px 2px white;
-moz-box-shadow: 0 1px 2px white;
-webkit-box-shadow: 0 1px 2px white; }
#publisher .button {
margin-left: 100px; }
#publisher img {
-webkit-box-shadow: 0 1px 0 white;
box-shadow: 0 1px 2px white;
-moz-box-shadow: 0 1px 2px white;
-webkit-box-shadow: 0 1px 2px white;
border: 1px solid #bbbbbb;
border-top: 1px solid #666666; }
@ -528,10 +536,10 @@ h1.big_text {
line-height: 18px;
font-weight: bold;
background-color: #eeeeee;
background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(white), to(#eeeeee));
background: -moz-linear-gradient(19% 75% 90deg, #eeeeee, white);
background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(white), to(#f7f7f7));
background: -moz-linear-gradient(19% 75% 90deg, #f7f7f7, white);
border: 1px solid white;
border-bottom: 1px solid #eeeeee;
border-bottom: 1px solid #f7f7f7;
color: black; }
#aspect_nav ul > li.selected a:hover {
background-color: #efefef; }
@ -692,19 +700,25 @@ ul#settings_nav {
cursor: default; }
.public_aspect_tag {
background-color: #fffc7f; }
background: -moz-linear-gradient(19% 75% 90deg, #fffa75, #fff8ba);
background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#fff8ba), to(#fffa75));
background-color: #fffc7f;
border-top: 1px solid #ebe66c; }
.aspect_tag {
background-color: #eeeeee;
background: -moz-linear-gradient(19% 75% 90deg, #e0e0e0, #f0f0f0);
background: -webkit-gradient(linear, 0% 0%, 0% 100%, from(#f0f0f0), to(#e0e0e0));
background-color: #eeeeee;
color: #999999;
text-shadow: 0 1px white; }
text-shadow: 0 1px white;
border-top: 1px solid #dddddd; }
.aspect_tag ul {
display: inline;
margin: 0;
padding: 0;
list-style: none; }
.aspect_tag ul li {
display: inline;
display: inline-block;
margin-right: 2px;
padding-right: 4px;
border-right: 1px solid #cccccc; }

View file

@ -146,6 +146,11 @@ header
:right 0
#aspect_header
:-webkit-box-shadow 0px -4px 6px -2px #777
:background -webkit-gradient(linear, 0% 0%, 0% 100%, from(#F7F7F7), to(#EEEEEE))
:background -moz-linear-gradient(19% 75% 90deg, #eee, #f7f7f7)
:background
:color #eee
:border
@ -182,9 +187,14 @@ ul#stream
:bottom 1px solid #eee
&:hover
:background -webkit-gradient(linear, 0% 0%, 0% 50%, from(#FAFAFA), to(#FCFCFC))
:background
:color #fafafa
:border
:bottom 1px solid #ddd
.destroy_link
:display inline
@ -209,6 +219,7 @@ li.message
.content
:padding
:left 65px
:width 600px
span.from
:color #000
@ -355,7 +366,7 @@ ul.comment_set
:color rgba(10,81,109,0.05)
:padding 0.6em
:border
:bottom 1px solid #ccc
:bottom 1px solid #ddd
.from
:font
@ -515,15 +526,17 @@ label
:top 0
:bottom 0
:box-shadow 0 1px #fff
:-moz-box-shadow 0 1px #fff
:-webkit-box-shadow 0 1px #fff
:box-shadow 0 1px 2px #fff
:-moz-box-shadow 0 1px 2px #fff
:-webkit-box-shadow 0 1px 2px #fff
.button
:margin-left 100px
img
:-webkit-box-shadow 0 1px 0 #fff
:box-shadow 0 1px 2px #fff
:-moz-box-shadow 0 1px 2px #fff
:-webkit-box-shadow 0 1px 2px #fff
:border 1px solid #bbb
:top 1px solid #666
@ -712,11 +725,11 @@ h1.big_text
:background
:color #eee
:background -webkit-gradient(linear, 0% 0%, 0% 100%, from(#fff), to(#eee))
:background -moz-linear-gradient(19% 75% 90deg, #eee, #fff)
:background -webkit-gradient(linear, 0% 0%, 0% 100%, from(#fff), to(#F7F7F7))
:background -moz-linear-gradient(19% 75% 90deg, #f7f7f7, #fff)
:border 1px solid #fff
:bottom 1px solid #eee
:bottom 1px solid #F7F7F7
:color #000
&:hover
:background
@ -890,15 +903,21 @@ ul#settings_nav
:cursor default
.public_aspect_tag
:background
:background -moz-linear-gradient(19% 75% 90deg,#FFFA75, #FFF8BA)
:background -webkit-gradient(linear, 0% 0%, 0% 100%, from(#FFF8BA), to(#FFFA75))
:color #FFFC7F
:border
:top 1px solid #EBE66C
.aspect_tag
:background
:background -moz-linear-gradient(19% 75% 90deg,#E0E0E0, #F0F0F0)
:background -webkit-gradient(linear, 0% 0%, 0% 100%, from(#F0F0F0), to(#E0E0E0))
:color #eee
:color #999
:text
:shadow 0 1px #fff
:border
:top 1px solid #ddd
ul
:display inline
@ -908,7 +927,7 @@ ul#settings_nav
:style none
li
:display inline
:display inline-block
:margin
:right 2px
:padding