Adding ignore user icon

Adding ignore user icon

Added jquery

Changed profile.js
This commit is contained in:
sjain1107 2013-08-23 18:50:47 +05:30 committed by Jonne Haß
parent 5eb5057864
commit 5223a2d906
5 changed files with 24 additions and 13 deletions

View file

@ -9,4 +9,14 @@
$(document).ready(function() { $(document).ready(function() {
$('#profile_buttons .profile_button div').tooltip({placement: 'bottom'}); $('#profile_buttons .profile_button div').tooltip({placement: 'bottom'});
$('#profile_buttons .sharing_message_container').tooltip({placement: 'bottom'}); $('#profile_buttons .sharing_message_container').tooltip({placement: 'bottom'});
$("#block_user_button").click(function(evt) {
if(!confirm(Diaspora.I18n.t('ignore_user'))) { return }
var personId = $(this).data('person-id');
var block = new app.models.Block();
block.save({block : {person_id : personId}});
$('#profile_buttons').attr('class', 'blocked');
$('#sharing_message').attr('class', 'icons-circle');
$('.profile_button, .white_bar').remove();
return false;
});
}); });

View file

@ -3,3 +3,4 @@
* the COPYRIGHT file. * the COPYRIGHT file.
*/ */
//= require jquery.autoSuggest.custom //= require jquery.autoSuggest.custom

View file

@ -41,8 +41,7 @@
.mutual { .mutual {
background-color: rgb(142, 222, 61); background-color: rgb(142, 222, 61);
.profile_button { .profile_button {
//width: 50px; width: 50px;
width: 75px;
} }
} }
.only_sharing { .only_sharing {
@ -54,8 +53,7 @@
.receiving { .receiving {
background-color: rgb(211, 211, 211); background-color: rgb(211, 211, 211);
.profile_button { .profile_button {
//width: 75px; width: 75px;
width: 150px;
} }
} }
.not_sharing { .not_sharing {

View file

@ -14,17 +14,18 @@
- if @contact.receiving? - if @contact.receiving?
.profile_button .profile_button
= link_to content_tag(:div, nil, :class => 'icons-mention', :title => t('people.show.mention'), :id => 'mention_button'), new_status_message_path(:person_id => @person.id), :rel => 'facebox' = link_to content_tag(:div, nil, :class => 'icons-mention', :title => t('people.show.mention'), :id => 'mention_button'), new_status_message_path(:person_id => @person.id), :rel => 'facebox'
//.white_bar .white_bar
- if @contact.mutual? - if @contact.mutual?
// remove the following line when adding the ignore button
.white_bar
.profile_button .profile_button
= link_to content_tag(:div, nil, :class => 'icons-message', :title => t('people.show.message'), :id => 'message_button'), new_conversation_path(:contact_id => @contact.id, :name => @contact.person.name), :rel => 'facebox' = link_to content_tag(:div, nil, :class => 'icons-message', :title => t('people.show.message'), :id => 'message_button'), new_conversation_path(:contact_id => @contact.id, :name => @contact.person.name), :rel => 'facebox'
//.white_bar .white_bar
.profile_button
= link_to content_tag(:div, nil, :class => 'icons-ignoreuser block_user', :title => t('ignore'), :id => 'block_user_button', :data => { :person_id => @person.id }), '#', :rel => "nofollow" if @block.blank?
//.profile_button
// = link_to content_tag(:div, nil, :class => 'icons-ignoreuser', :title => t('people.show.message'), :id => 'block_user_button'), '/block', :rel => 'facebox'
%br %br

View file

@ -20,6 +20,7 @@ en:
cancel: "Cancel" cancel: "Cancel"
delete: "Delete" delete: "Delete"
hide: "Hide" hide: "Hide"
ignore: "Ignore"
undo: "Undo?" undo: "Undo?"
or: "or" or: "or"
ago: "%{time} ago" ago: "%{time} ago"