Skip to content

Commit

Permalink
Merge pull request #16 from AjuntamentdeBarcelona/feature/restyle-pro…
Browse files Browse the repository at this point in the history
…ject-vote-button

Restyle project vote button
  • Loading branch information
Vera Rojman authored Jun 4, 2021
2 parents f881440 + 3b93ce1 commit c1fba1a
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 16 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,20 +4,19 @@
justify-content: space-between;
align-items: center;

&:hover,
&:focus {
&.added {
.budget-list__action {
background: var(--primary);
border-color: white;
color: white;
}
}
&:not(.added) {
.budget-list__action {
border-color: white;
color: white;
}
span {
font-size: 1rem;
}

&.added {
background-color: tint($success, 80%);
color: $body-font-color;
}

&:not(.added) {
.budget-list__action {
border-color: white;
color: white;
}
}
}
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<% if current_user.blank? %>
<div id="project-<%= project.id %>-budget-button">
<button class="button expanded button--sc" data-toggle="loginModal">
<button class="button expanded primary button--sc" data-toggle="loginModal">
<%= t(".add") %>
</button>
</div>
<% else %>
<div id="project-<%= project.id %>-budget-button" class="<%= "added" if voted_for?(project) %> button expanded button--sc budget-vote-button budget-list__data">
<div id="project-<%= project.id %>-budget-button" class="<%= "added" if voted_for?(project) %> button expanded primary button--sc budget-vote-button budget-list__data">
<span>
<%= t(voted_for?(project) ? ".added" : ".add") %>
</span>
Expand Down

0 comments on commit c1fba1a

Please sign in to comment.