From 5f163eef1c7d2e8748d93d815a5547d9aa53c789 Mon Sep 17 00:00:00 2001 From: Will Marshall Date: Fri, 30 May 2014 16:10:28 +1000 Subject: [PATCH] Tweaking the contact thingy --- app/assets/stylesheets/darkswarm/footer.sass | 3 - .../stylesheets/darkswarm/typography.css.sass | 5 ++ app/views/shopping_shared/_contact.html.haml | 69 +++++++++++-------- 3 files changed, 46 insertions(+), 31 deletions(-) diff --git a/app/assets/stylesheets/darkswarm/footer.sass b/app/assets/stylesheets/darkswarm/footer.sass index 80216af995..30f8caf8b4 100644 --- a/app/assets/stylesheets/darkswarm/footer.sass +++ b/app/assets/stylesheets/darkswarm/footer.sass @@ -15,6 +15,3 @@ footer &:hover, &:active, &:focus color: $clr-brick-bright @include textsoftpress - span.email - direction: rtl - unicode-bidi: bidi-override diff --git a/app/assets/stylesheets/darkswarm/typography.css.sass b/app/assets/stylesheets/darkswarm/typography.css.sass index 63d4efe13f..69d16aef9e 100644 --- a/app/assets/stylesheets/darkswarm/typography.css.sass +++ b/app/assets/stylesheets/darkswarm/typography.css.sass @@ -69,3 +69,8 @@ table tr th, table tr td color: #333333 table thead tr th, table thead tr td, table tfoot tr th, table tfoot tr td color: #333333 + + +span.email + direction: rtl + unicode-bidi: bidi-override diff --git a/app/views/shopping_shared/_contact.html.haml b/app/views/shopping_shared/_contact.html.haml index 6a949f9f9c..d4894357ad 100644 --- a/app/views/shopping_shared/_contact.html.haml +++ b/app/views/shopping_shared/_contact.html.haml @@ -7,36 +7,49 @@ %h4=current_distributor.name %p = current_distributor.address.address1 - %br + - if current_distributor.address.address2 + %br = current_distributor.address.address2 %br - = current_distributor.address.city - = current_distributor.address.state - = current_distributor.address.zipcode + = current_distributor.address.city + = current_distributor.address.state + = current_distributor.address.zipcode .small-12.large-8.columns %ul.small-block-grid-1.large-block-grid-2{bindonce: true} - %li - %a{href: "mailto:#{current_distributor.website}", target: "_blank" } - %i.fi-web - = current_distributor.website - %li - %a{href: "mailto:#{current_distributor.email}", target: "_blank" } - %i.fi-mail - = current_distributor.email - %li - %a{href: "mailto:#{current_distributor.twitter}", target: "_blank" } - %i.fi-social-twitter - = current_distributor.twitter - %li - %a{href: "mailto:#{current_distributor.facebook}", target: "_blank" } - %i.fi-social-facebook - = current_distributor.facebook - %li - %a{href: "mailto:#{current_distributor.linkedin}", target: "_blank" } - %i.fi-social-linkedin - = current_distributor.linkedin - %li - %a{href: "mailto:#{current_distributor.instagram}", target: "_blank" } - %i.fi-social-instagram - = current_distributor.instagram + - unless current_distributor.website.blank? + %li + %a{href: current_distributor.website, target: "_blank" } + %i.fi-web + = current_distributor.website + + - unless current_distributor.email.blank? + %li + %a{href: current_distributor.email.reverse, mailto: true } + %i.fi-mail + %span.email + = current_distributor.email.reverse + + - unless current_distributor.twitter.blank? + %li + %a{href: current_distributor.twitter, target: "_blank" } + %i.fi-social-twitter + = current_distributor.twitter + + - unless current_distributor.facebook.blank? + %li + %a{href: current_distributor.facebook, target: "_blank" } + %i.fi-social-facebook + = current_distributor.facebook + + - unless current_distributor.linkedin.blank? + %li + %a{href: current_distributor.linkedin, target: "_blank" } + %i.fi-social-linkedin + = current_distributor.linkedin + + - unless current_distributor.instagram.blank? + %li + %a{href: current_distributor.instagram, target: "_blank" } + %i.fi-social-instagram + = current_distributor.instagram