From 839d76c15e672cbb3bbb847378167670cebf9b88 Mon Sep 17 00:00:00 2001 From: Steffen van Bergerem Date: Tue, 21 Jul 2015 18:12:01 +0200 Subject: [PATCH] Moar entypo on mobile website --- app/assets/images/mobile/arrow-left.png | Bin 2414 -> 0 bytes app/assets/images/mobile/arrow-right.png | Bin 2439 -> 0 bytes app/assets/images/mobile/camera.png | Bin 1217 -> 0 bytes app/assets/stylesheets/mobile/mobile.scss | 44 ++++++++------------ app/views/photos/show.mobile.haml | 19 +++++---- app/views/publisher/_publisher.mobile.haml | 2 +- app/views/users/getting_started.mobile.haml | 4 -- features/mobile/multiphoto.feature | 12 +++--- 8 files changed, 35 insertions(+), 46 deletions(-) delete mode 100644 app/assets/images/mobile/arrow-left.png delete mode 100644 app/assets/images/mobile/arrow-right.png delete mode 100644 app/assets/images/mobile/camera.png diff --git a/app/assets/images/mobile/arrow-left.png b/app/assets/images/mobile/arrow-left.png deleted file mode 100644 index 8ae1a3d0e36242e8abc4b1f2c43aafd8f1609cf0..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 2414 zcmV-!36b`RP)3E0+;No%f^bGErkM4emBrLrlq71i*+#;m`pN%cn}KlG2bmT|`@ zYe5rAP(VviQTcJ<_I>1eeoaa18_xXI9Q`9Lg zrwJS&PH}()P6@Ty=hgX3XeflQI=@aG>JT)@S3^Dri2p%^@aGMOA_RpAPYP=MepVmU z3k^VChU9aAOumR9rb02SSSSjL6xzYd5N<%%pzExg3~7L&IY1@>gDhYQ1DFNHvFLsV zLkZ)b?`Ig@&_B>6=rZ3Epj!-OFld43x-RASVty6ERzVFu6PgRnhmz{+>z9?3lssNr zTbt0{-X1BwZ}H;AJ?ZJ`mkJ6Ben?A8`xXE7C)5gcKwS*XC(Tl5VrZo#d>)-(KvSSO z&{Aj}w6(3R?UM}~Hnehs-dFkg`R7_&TTAiY*C98w2$}&!a6SHSk6;4AjT8z+L2*zD z^enXf!i5W;;@f|Hyf6&WdjRq%LwN#9f?~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+++ b/app/assets/stylesheets/mobile/mobile.scss @@ -292,29 +292,22 @@ h3 { margin-top: 0; } } #photo_controls { - margin-bottom: 5px; -} - -.arrow { - color: white !important; - font-size: 26pt; - text: { - shadow: 0 1px 2px #333; - decoration: none; }; - padding: 0; - position: fixed; - bottom: 10%; - z-index: 1; - height: 50px; - width: 50px; -} - -#left.arrow { - left: 5%; -} - -#right.arrow{ - right: 5%; + .arrow { + font-size: 10em; + text-decoration: none; + text-shadow: 0 0 3px $white; + position: fixed; + bottom: -0.2em; + z-index: 1; + &.left { + left: -0.2em; + } + &.right { + right: -0.2em; + text-align: right; + } + .entypo-chevron-left, .entypo-chevron-right { margin-right: 0; } + } } .header-full-width { @@ -931,10 +924,7 @@ select#aspect_ids_ { float: left; padding: 3px 12px; cursor: pointer; - - &:hover img { - opacity: 0.4; - } + .entypo-camera { margin-right: 0; } } #publisher_textarea_wrapper { diff --git a/app/views/photos/show.mobile.haml b/app/views/photos/show.mobile.haml index 4b5c3a3ea..6082e8edc 100644 --- a/app/views/photos/show.mobile.haml +++ b/app/views/photos/show.mobile.haml @@ -20,12 +20,13 @@ -if additional_photos && additional_photos.length > 1 #photo_controls - %table - %tr - %td - - if previous_photo != additional_photos.last - = link_to(image_tag("mobile/arrow-left.png", id: "arrow-left"), person_photo_path(previous_photo.author, previous_photo), rel: "prefetch", class: "arrow", id: "left") - %td{:width => '100%'} - %td - - if next_photo == additional_photos[additional_photos.index(photo)+1] - = link_to(image_tag("mobile/arrow-right.png", id: "arrow-right"), person_photo_path(next_photo.author, next_photo), rel: "prefetch", class: "arrow", id: "right") + - if previous_photo != additional_photos.last + = link_to(content_tag(:i, nil, id: "arrow-left", class: "entypo-chevron-left"), + person_photo_path(previous_photo.author, previous_photo), + rel: "prefetch", + class: "arrow left") + - if next_photo == additional_photos[additional_photos.index(photo)+1] + = link_to(content_tag(:i, nil, id: "arrow-right", class: "entypo-chevron-right"), + person_photo_path(next_photo.author, next_photo), + rel: "prefetch", + class: "arrow right") diff --git a/app/views/publisher/_publisher.mobile.haml b/app/views/publisher/_publisher.mobile.haml index 9aced532e..c29d73c2e 100644 --- a/app/views/publisher/_publisher.mobile.haml +++ b/app/views/publisher/_publisher.mobile.haml @@ -30,7 +30,7 @@ #fileInfo-publisher #file-upload-publisher{title: t('shared.publisher.upload_photos'), class: 'btn btn-default'} - = image_tag "mobile/camera.png", alt: t("shared.publisher.upload_photos").titleize + %i.entypo-camera.middle #publisher_mobile = submit_tag t('shared.publisher.share'), class: 'btn btn-primary', id: "submit_new_message" .clearfix diff --git a/app/views/users/getting_started.mobile.haml b/app/views/users/getting_started.mobile.haml index 951e82a49..66f5d2687 100644 --- a/app/views/users/getting_started.mobile.haml +++ b/app/views/users/getting_started.mobile.haml @@ -59,10 +59,6 @@ %fieldset = label_tag 'profile[first_name]', t('profiles.edit.your_name'), class: "bootstrapped" = text_field_tag 'profile[first_name]', current_user.first_name - = image_tag 'ajax-loader2.gif', id: "gs-name-form-spinner", class: "hidden" - %span.saved{class: "hidden"} - = image_tag "mobile/check_yes_ok.png" - = t(".saved") .clearfix.visible-xs-block = label_tag :your_photo, t('profiles.edit.your_photo'), class: "bootstrapped" = render 'photos/new_profile_photo', aspect: :getting_started, person: current_user.person diff --git a/features/mobile/multiphoto.feature b/features/mobile/multiphoto.feature index 956db048b..f36966b3e 100644 --- a/features/mobile/multiphoto.feature +++ b/features/mobile/multiphoto.feature @@ -15,7 +15,8 @@ Feature: viewing photos on the mobile main page When I press "Share" And I click on selector "img.stream-photo" Then I should see a "img" within "#show_content" - And I should not see a "#right" within "#main" + And I should not see a "#arrow-right" within "#main" + And I should not see a "#arrow-left" within "#main" Scenario: view multiphoto post Given I attach the file "spec/fixtures/button.png" to hidden "file" within "#file-upload-publisher" @@ -25,8 +26,9 @@ Feature: viewing photos on the mobile main page Then I should see "+ 1" within ".additional_photo_count" When I click on selector "img.stream-photo" - Then I should see a "#right" within "tbody" + Then I should see a "#arrow-right" within "#main" + And I should not see a "#arrow-left" within "#main" - When I click on selector "img#arrow-right" - And I should see a "#left" within "tbody" - And I should not see a "#right" within "tbody" + When I click on selector "#arrow-right" + Then I should see a "#arrow-left" within "#main" + And I should not see a "#arrow-right" within "#main"