From d94f806a50aa505aaff18ed44f3341dad26518d4 Mon Sep 17 00:00:00 2001 From: Dan Hansen Date: Tue, 26 Jul 2011 20:43:35 -0700 Subject: [PATCH 1/4] close the lightbox when a user clicks on the backdrop --- public/javascripts/widgets/lightbox.js | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/public/javascripts/widgets/lightbox.js b/public/javascripts/widgets/lightbox.js index 8b1e7fd6a..409ade1f1 100644 --- a/public/javascripts/widgets/lightbox.js +++ b/public/javascripts/widgets/lightbox.js @@ -43,6 +43,8 @@ jQuery.fn.center = (function() { evt.preventDefault(); self.resetLightbox(); }); + self.backdrop.click(self.resetLightbox); + self.lightbox.click(self.resetLightbox); self.body.keydown(function(evt) { @@ -82,7 +84,7 @@ jQuery.fn.center = (function() { this.lightboxImageClicked = function(evt) { evt.preventDefault(); - + var selectedImage = $(this).find("img.stream-photo"), imageUrl = selectedImage.attr("data-full-photo"), images = selectedImage.parents('.stream_element').find('img.stream-photo'), @@ -110,7 +112,7 @@ jQuery.fn.center = (function() { this.imagesetImageClicked = function(evt) { evt.preventDefault(); - + evt.stopPropagation(); self.selectImage($(this)); }; From e8bde11a92a17eb9578762589be30511f7f07c70 Mon Sep 17 00:00:00 2001 From: Dan Hansen Date: Tue, 26 Jul 2011 21:55:52 -0700 Subject: [PATCH 2/4] fix failing features --- features/change_email.feature | 4 ++-- features/change_password.feature | 4 ++-- features/repost.feature | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/features/change_email.feature b/features/change_email.feature index d81f4d0e8..14b6d5bbe 100644 --- a/features/change_email.feature +++ b/features/change_email.feature @@ -7,8 +7,8 @@ Feature: Change email And I follow "settings" Then I should be on my account settings page When I fill in "user_email" with "new_email@newplac.es" - And I press "Change E-Mail" - Then I should see "E-Mail Changed" + And I press "Change email" + Then I should see "Email changed" And I follow the "confirm_email" link from the last sent email Then I should see "activated" And my "email" should be "new_email@newplac.es" diff --git a/features/change_password.feature b/features/change_password.feature index 4a44797b5..aef13d451 100644 --- a/features/change_password.feature +++ b/features/change_password.feature @@ -9,8 +9,8 @@ Feature: Change password When I put in my password in "user_current_password" And I fill in "user_password" with "newsecret" And I fill in "user_password_confirmation" with "newsecret" - And I press "Change Password" - Then I should see "Password Changed" + And I press "Change password" + Then I should see "Password changed" Then I should be on the new user session page When I sign in with password "newsecret" Then I should be on the aspects page diff --git a/features/repost.feature b/features/repost.feature index 39567dc9f..0c9251d01 100644 --- a/features/repost.feature +++ b/features/repost.feature @@ -93,6 +93,6 @@ Feature: public repost And I should see "Bob" And I go to the home page - And I should see "1 Reshare" + And I should see "1 reshare" Scenario: Can have text From 73f96273385e1f0cb325ce27c506de021af3547e Mon Sep 17 00:00:00 2001 From: Ilyaaaaaaaaaaaaa Zhitomirskiy Date: Tue, 26 Jul 2011 23:31:21 -0700 Subject: [PATCH 3/4] moved invite people to the top --- app/views/aspects/index.html.haml | 40 +++++++++++++++---------------- 1 file changed, 19 insertions(+), 21 deletions(-) diff --git a/app/views/aspects/index.html.haml b/app/views/aspects/index.html.haml index 5014a8ba3..067c26a77 100644 --- a/app/views/aspects/index.html.haml +++ b/app/views/aspects/index.html.haml @@ -53,13 +53,18 @@ %br = t(".diaspora_id.content_2") - .section - .title - = image_tag('/images/icons/bookmark.png') - %h5 - = t('bookmarklet.heading') - .content - != t('bookmarklet.explanation', :link => link_to(t('bookmarklet.explanation_link_text'), bookmarklet)) + - unless AppConfig[:invites_off] + .section + .title + + = image_tag('/images/icons/plus.png') + %h5 + - unless AppConfig[:open_invitations] + .right + = t('shared.invitations.invitations_left', :count => @invites) + = t('shared.invitations.invite_your_friends') + .content + = render "shared/invitations", :invites => @invites .section .title @@ -81,17 +86,10 @@ - unless current_user.services.any?{|x| x.provider == service} %br= link_to service.titleize, "/auth/#{service}" - - - unless AppConfig[:invites_off] - .section - .title - - = image_tag('/images/icons/plus.png') - %h5 - - unless AppConfig[:open_invitations] - .right - = t('shared.invitations.invitations_left', :count => @invites) - = t('shared.invitations.invite_your_friends') - .content - = render "shared/invitations", :invites => @invites - + .section + .title + = image_tag('/images/icons/bookmark.png') + %h5 + = t('bookmarklet.heading') + .content + != t('bookmarklet.explanation', :link => link_to(t('bookmarklet.explanation_link_text'), bookmarklet)) From 7b572bf40b27995df146ab251f79faf714fe3d14 Mon Sep 17 00:00:00 2001 From: Ilyaaaaaaaaaaaaa Zhitomirskiy Date: Wed, 27 Jul 2011 00:11:24 -0700 Subject: [PATCH 4/4] don't display connect to services unless services are configured on that pod --- app/views/aspects/index.html.haml | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/app/views/aspects/index.html.haml b/app/views/aspects/index.html.haml index 067c26a77..3d5ee3b2c 100644 --- a/app/views/aspects/index.html.haml +++ b/app/views/aspects/index.html.haml @@ -75,16 +75,17 @@ = t('.cubbies.explanation') = link_to t('.cubbies.learn_more'), token_path - .section - .title - = image_tag('/images/icons/monotone_wrench_settings.png') - %h5 - = t('.services.heading') - .content - = t('.services.content') - - AppConfig.configured_services.each do |service| - - unless current_user.services.any?{|x| x.provider == service} - %br= link_to service.titleize, "/auth/#{service}" + - unless AppConfig.configured_services.blank? + .section + .title + = image_tag('/images/icons/monotone_wrench_settings.png') + %h5 + = t('.services.heading') + .content + = t('.services.content') + - AppConfig.configured_services.each do |service| + - unless current_user.services.any?{|x| x.provider == service} + %br= link_to service.titleize, "/auth/#{service}" .section .title