added translations to all conversation/message views. tweaked css
This commit is contained in:
parent
84198e4750
commit
d38e3a6b29
11 changed files with 79 additions and 31 deletions
9
app/helpers/conversations_helper.rb
Normal file
9
app/helpers/conversations_helper.rb
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
module ConversationsHelper
|
||||
def new_message_text(count)
|
||||
if count > 0
|
||||
t('new_messages', :count => count)
|
||||
else
|
||||
t('no_new_messages')
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
@ -5,11 +5,10 @@
|
|||
%li.comment{:data=>{:guid => comment.id}, :class => ("hidden" if(defined? hidden))}
|
||||
= person_image_link(comment.author)
|
||||
.content
|
||||
%strong
|
||||
.from
|
||||
= person_link(comment.author)
|
||||
|
||||
= markdownify(comment.text, :youtube_maps => comment.youtube_titles)
|
||||
|
||||
.info
|
||||
%span.time
|
||||
%time.timeago{:datetime => comment.created_at}
|
||||
= comment.created_at ? timeago(comment.created_at) : timeago(Time.now)
|
||||
|
||||
%p
|
||||
= markdownify(comment.text, :youtube_maps => comment.youtube_titles)
|
||||
|
|
|
|||
|
|
@ -13,7 +13,7 @@
|
|||
|
||||
.last_author
|
||||
.timestamp
|
||||
= time_ago_in_words conversation.updated_at
|
||||
= time_ago_in_words(conversation.updated_at)
|
||||
= authors[conversation.id].name
|
||||
|
||||
- if conversation.participants.size > 2
|
||||
|
|
|
|||
|
|
@ -10,7 +10,7 @@
|
|||
= conversation.subject
|
||||
|
||||
.conversation_controls
|
||||
= link_to (image_tag('reply.png', :height => 14, :width => 14) + ' ' + 'reply'), '#', :id => 'reply_to_conversation'
|
||||
= link_to (image_tag('reply.png', :height => 14, :width => 14) + ' ' + t('.reply')), '#', :id => 'reply_to_conversation'
|
||||
= link_to (image_tag('deletelabel.png') + ' ' + t('delete').downcase), conversation_conversation_visibility_path(conversation), :method => 'delete', :confirm => t('are_you_sure')
|
||||
|
||||
.span-6.avatars.last
|
||||
|
|
@ -33,5 +33,5 @@
|
|||
= form_for [conversation, Message.new] do |message|
|
||||
= message.text_area :text, :rows => 5
|
||||
.right
|
||||
= message.submit 'Reply', :class => 'button'
|
||||
= link_to 'Cancel', '#'
|
||||
= message.submit t('.reply').capitalize, :class => 'button'
|
||||
= link_to t('cancel'), '#'
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@
|
|||
= include_javascripts :inbox
|
||||
|
||||
- content_for :page_title do
|
||||
Message Inbox
|
||||
= t('.message_inbox')
|
||||
|
||||
:css
|
||||
footer{ display:none;}
|
||||
|
|
@ -16,7 +16,7 @@
|
|||
#left_pane_header
|
||||
%h3
|
||||
.right
|
||||
= link_to 'New Message', new_conversation_path, :class => 'button', :rel => 'facebox'
|
||||
= link_to t('.new_message'), new_conversation_path, :class => 'button', :rel => 'facebox'
|
||||
Inbox
|
||||
|
||||
#conversation_inbox
|
||||
|
|
@ -26,13 +26,13 @@
|
|||
= will_paginate @conversations
|
||||
- else
|
||||
%i
|
||||
You have no messages
|
||||
= t('.you_have_no_new_messages')
|
||||
|
||||
#conversation_show.span-16.prepend-8.last
|
||||
- if @conversation
|
||||
= render 'conversations/show', :conversation => @conversation
|
||||
- else
|
||||
#no_conversation_text
|
||||
no conversation selected
|
||||
= t('.no_conversation_selected')
|
||||
#no_conversation_controls
|
||||
= link_to 'create a new message', new_conversation_path, :rel => 'facebox'
|
||||
= link_to t('.create_a_new_message'), new_conversation_path, :rel => 'facebox'
|
||||
|
|
|
|||
|
|
@ -26,20 +26,20 @@
|
|||
.span-12.last
|
||||
#facebox_header
|
||||
%h4
|
||||
New Message
|
||||
= t('conversations.index.new_message')
|
||||
|
||||
= form_for Conversation.new do |conversation|
|
||||
%br
|
||||
|
||||
.span-2
|
||||
%h4
|
||||
to
|
||||
= t('.to')
|
||||
.span-10.last
|
||||
= text_field_tag "contact_autocomplete"
|
||||
|
||||
.span-2
|
||||
%h4
|
||||
subject
|
||||
= t('.subject')
|
||||
.span-10.last
|
||||
= conversation.text_field :subject
|
||||
|
||||
|
|
@ -47,5 +47,5 @@
|
|||
= text_area_tag "conversation[text]", '', :rows => 5
|
||||
|
||||
.text-right
|
||||
= conversation.submit :send, :class => 'button'
|
||||
= link_to 'cancel', conversations_path
|
||||
= conversation.submit t('.send'), :class => 'button'
|
||||
= link_to t('cancel'), conversations_path
|
||||
|
|
|
|||
|
|
@ -24,12 +24,12 @@
|
|||
- if @notification_count
|
||||
#notification_badge
|
||||
= link_to "", notifications_path, :title => new_notification_text(@notification_count)
|
||||
= image_tag 'icons/mail_grey.png'
|
||||
= image_tag 'icons/monotone_flag.png', :height => 20, :width => 20
|
||||
.badge_count{:class => ("hidden" if @notification_count == 0)}
|
||||
= @notification_count
|
||||
#message_inbox_badge
|
||||
= link_to "", conversations_path #, :title => new_notification_text(@notification_count)
|
||||
= image_tag 'icons/mail_grey.png'
|
||||
= link_to "", conversations_path , :title => new_message_text(@unread_message_count)
|
||||
= image_tag 'icons/mail_grey.png', :height => 16, :width => 16
|
||||
.badge_count{:class => ("hidden" if @unread_message_count == 0)}
|
||||
= @unread_message_count
|
||||
|
||||
|
|
|
|||
|
|
@ -16,7 +16,6 @@
|
|||
.from
|
||||
= person_link(post.author, :class => 'author')
|
||||
%time.timeago{:datetime => post.created_at}
|
||||
= link_to(how_long_ago(post), status_message_path(post))
|
||||
%p
|
||||
= render 'status_messages/status_message', :post => post, :photos => post.photos
|
||||
|
||||
|
|
@ -29,6 +28,9 @@
|
|||
%span.aspect_badges
|
||||
= aspect_badges(aspects_with_post(all_aspects, post))
|
||||
|
||||
%span.timeago
|
||||
= link_to(how_long_ago(post), status_message_path(post))
|
||||
|
||||
= link_to t('comments.new_comment.comment').downcase, '#', :class => 'focus_comment_textarea'
|
||||
|
||||
= render "comments/comments", :post_id => post.id, :comments => post.comments, :current_user => current_user, :condensed => true, :commenting_disabled => defined?(@commenting_disabled)
|
||||
|
|
|
|||
|
|
@ -27,6 +27,8 @@ en:
|
|||
search: "Search"
|
||||
new_notifications: "%{count} new notifications"
|
||||
no_new_notifications: "no new notifications"
|
||||
new_messages: "%{count} new messages"
|
||||
no_new_messages: "no new messages"
|
||||
_home: "Home"
|
||||
_more: "More"
|
||||
_comments: "Comments"
|
||||
|
|
@ -523,3 +525,16 @@ en:
|
|||
fullmonth_day: "%B %d"
|
||||
birthday: "%B %d"
|
||||
birthday_with_year: "%B %d %Y"
|
||||
|
||||
conversations:
|
||||
index:
|
||||
message_inbox: "Message Inbox"
|
||||
new_message: "New Message"
|
||||
no_conversation_selected: "no conversation selected"
|
||||
create_a_new_message: "create a new message"
|
||||
show:
|
||||
reply: 'reply'
|
||||
new:
|
||||
to: 'to'
|
||||
subject: 'subject'
|
||||
send: 'Send'
|
||||
|
|
|
|||
BIN
public/images/icons/monotone_flag.png
Normal file
BIN
public/images/icons/monotone_flag.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 783 B |
|
|
@ -254,6 +254,7 @@ header
|
|||
.stream
|
||||
.stream_element
|
||||
:padding 20px 20px
|
||||
:right 70px
|
||||
:min-height 50px
|
||||
:border
|
||||
:bottom 1px solid #ddd
|
||||
|
|
@ -262,6 +263,9 @@ header
|
|||
&:hover
|
||||
.right
|
||||
:display inline
|
||||
.from
|
||||
a
|
||||
:color $blue
|
||||
|
||||
.youtube-player, .vimeo-player
|
||||
:border none
|
||||
|
|
@ -393,7 +397,7 @@ header
|
|||
:margin
|
||||
:top 2px
|
||||
:color #999
|
||||
:font-size smaller
|
||||
:font-size 11px
|
||||
|
||||
.comments
|
||||
.info
|
||||
|
|
@ -410,7 +414,7 @@ header
|
|||
|
||||
.time,
|
||||
.timeago
|
||||
:color #ccc
|
||||
:color #999
|
||||
a
|
||||
:color #ccc
|
||||
:margin
|
||||
|
|
@ -559,6 +563,8 @@ ul.show_comments
|
|||
:line
|
||||
:height 18px
|
||||
|
||||
:position relative
|
||||
|
||||
textarea
|
||||
:width 100%
|
||||
:height 1.4em
|
||||
|
|
@ -593,9 +599,6 @@ ul.show_comments
|
|||
a
|
||||
:color #444
|
||||
|
||||
div.time
|
||||
:color #bbb
|
||||
|
||||
form
|
||||
:margin
|
||||
:top -5px
|
||||
|
|
@ -634,6 +637,12 @@ ul.show_comments
|
|||
textarea
|
||||
:min-height 2.4em
|
||||
|
||||
.comments
|
||||
time
|
||||
:margin
|
||||
:right -15px
|
||||
.timeago
|
||||
:color #999
|
||||
|
||||
.stream.show
|
||||
ul.comments
|
||||
|
|
@ -693,11 +702,14 @@ a.paginate, #infscr-loading
|
|||
:right 12px
|
||||
|
||||
&.controls
|
||||
:z-index 6
|
||||
:background
|
||||
:color $background
|
||||
:font
|
||||
:size 12px
|
||||
:color #999
|
||||
:padding
|
||||
:left 100px
|
||||
a
|
||||
:color #999
|
||||
:font
|
||||
|
|
@ -1672,11 +1684,11 @@ h3 span.current_gs_step
|
|||
:top 5px
|
||||
:display inline
|
||||
:margin 0 10px
|
||||
:right 0
|
||||
:right -5px
|
||||
:font
|
||||
:weight bold
|
||||
:size smaller
|
||||
:width 30px
|
||||
:width 28px
|
||||
|
||||
a
|
||||
:z-index 5
|
||||
|
|
@ -1685,6 +1697,16 @@ h3 span.current_gs_step
|
|||
:width 20px
|
||||
:height 20px
|
||||
|
||||
&:hover
|
||||
.badge_count
|
||||
:background
|
||||
:color lighten(#A40802, 5%)
|
||||
|
||||
#notification_badge
|
||||
img
|
||||
:position relative
|
||||
:top 2px
|
||||
|
||||
.badge_count
|
||||
:z-index 3
|
||||
:position absolute
|
||||
|
|
@ -2275,6 +2297,7 @@ ul.show_comments
|
|||
:margin
|
||||
:left 0.5em
|
||||
:right 0.5em
|
||||
|
||||
.mark_all_read
|
||||
:position relative
|
||||
:top 10px
|
||||
|
|
|
|||
Loading…
Reference in a new issue