diff --git a/app/assets/stylesheets/debates.scss b/app/assets/stylesheets/debates.scss index c050ff09b..7078c6718 100644 --- a/app/assets/stylesheets/debates.scss +++ b/app/assets/stylesheets/debates.scss @@ -352,7 +352,7 @@ @media (min-width: $small-breakpoint) { border-top-left-radius: 3px; border-bottom-left-radius: 3px; - margin: 0 rem-calc(-24) 0 rem-calc(12); + margin: 0 rem-calc(-25) 0 rem-calc(12); } &:after { diff --git a/app/assets/stylesheets/proposals.scss b/app/assets/stylesheets/proposals.scss index c672f46ac..4dfb0f6e4 100644 --- a/app/assets/stylesheets/proposals.scss +++ b/app/assets/stylesheets/proposals.scss @@ -22,10 +22,14 @@ } @mixin supports { - margin-top: rem-calc(24); + background: $proposals; + border-top: 1px solid $proposals-border; + margin: 0 rem-calc(-12); + padding: rem-calc(14) rem-calc(12); + position: relative; .progress { - background-color: rgba(0, 0, 0, 0.1); + background-color: white; height: rem-calc(18); margin-bottom: rem-calc(6); @@ -35,8 +39,8 @@ } .button-support { - background: $proposals; - color: white; + background: white; + color: $proposals; display: inline-block; font-size: rem-calc(14); margin-top: rem-calc(12); @@ -53,13 +57,12 @@ } .total-supports { - color: $proposals; + color: white; float: right; font-size: rem-calc(14); span { - color: $text-medium; - font-size: rem-calc(12); + font-size: rem-calc(11); } } @@ -110,6 +113,10 @@ text-decoration: underline; } } + + .supported { + color: white; + } } // 02. Index @@ -294,31 +301,31 @@ } .supports { - // border: 1px solid $proposals-border; - // margin: 0 rem-calc(-12); + border: 1px solid $proposals-border; + margin: 0 rem-calc(-12); - // @media (min-width: $small-breakpoint) { - // border-top-left-radius: 3px; - // border-bottom-left-radius: 3px; - // margin: 0 rem-calc(-24) 0 rem-calc(12); - // } + @media (min-width: $small-breakpoint) { + border-top-left-radius: 3px; + border-bottom-left-radius: 3px; + margin: 0 rem-calc(-25) 0 rem-calc(12); + } - // &:after { - // content: none; - // position: absolute; - // display: block; - // border-style: solid; - // border-color: #664212 transparent transparent transparent; - // bottom: rem-calc(-14); - // border-left-width: 0; - // border-right-color: transparent; - // right: rem-calc(-1); - // border-width: 1em 1em 0 0; + &:after { + content: none; + position: absolute; + display: block; + border-style: solid; + border-color: #664212 transparent transparent transparent; + bottom: rem-calc(-14); + border-left-width: 0; + border-right-color: transparent; + right: rem-calc(-1); + border-width: 1em 1em 0 0; - // @media (min-width: $small-breakpoint) { - // content: ""; - // } - // } + @media (min-width: $small-breakpoint) { + content: ""; + } + } .total-supports { display: inline-block; diff --git a/app/views/proposals/_votes.html.erb b/app/views/proposals/_votes.html.erb index f192942c2..02952eef9 100644 --- a/app/views/proposals/_votes.html.erb +++ b/app/views/proposals/_votes.html.erb @@ -13,7 +13,12 @@ <%= link_to vote_proposal_path(proposal, value: 'yes'), class: "button button-support tiny radius expand #{voted_classes[:in_favor]}", title: t('proposals.proposal.support_title'), method: "post", remote: true do %> <%= t("proposals.proposal.support") %> - <% end %> + <% end %> + +
+ <%= t("proposals.proposal.already_supported") %> +
+ <% if user_signed_in? && current_user.organization? %> diff --git a/config/locales/en.yml b/config/locales/en.yml index 527a2f495..63a619503 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -170,6 +170,7 @@ en: one: 1 support other: "%{count} supports" supports_necessary: "/ 53.726" + already_supported: "¡You already supported this proposal!" form: proposal_title: Proposal title proposal_question: Proposal question diff --git a/config/locales/es.yml b/config/locales/es.yml index 8823f8321..177468300 100644 --- a/config/locales/es.yml +++ b/config/locales/es.yml @@ -170,6 +170,7 @@ es: one: 1 apoyo other: "%{count} apoyos" supports_necessary: "/ 53.726" + already_supported: "¡Ya has apoyado esta propuesta!" form: proposal_title: Título de la propuesta proposal_question: Pregunta de la propuesta