Improves styles for retire proposals
This commit is contained in:
committed by
Juanjo Bazán
parent
5b4a7b8cf8
commit
f079bdac8a
@@ -545,7 +545,7 @@ footer {
|
|||||||
// 04. Tags
|
// 04. Tags
|
||||||
// - - - - - - - - - - - - - - - - - - - - - - - - -
|
// - - - - - - - - - - - - - - - - - - - - - - - - -
|
||||||
|
|
||||||
.tags a , .tag-cloud a, .categories a, .geozone a {
|
.tags a , .tag-cloud a, .categories a, .geozone a, .sidebar-links a {
|
||||||
background: #ececec;
|
background: #ececec;
|
||||||
border-radius: rem-calc(6);
|
border-radius: rem-calc(6);
|
||||||
color: $text;
|
color: $text;
|
||||||
@@ -1730,9 +1730,12 @@ table {
|
|||||||
border: 0;
|
border: 0;
|
||||||
|
|
||||||
td {
|
td {
|
||||||
padding-left: $line-height*1.5;
|
|
||||||
position: relative;
|
position: relative;
|
||||||
word-break: break-all;
|
|
||||||
|
&:first-child {
|
||||||
|
padding-left: $line-height*1.5;
|
||||||
|
width: 80%;
|
||||||
|
}
|
||||||
|
|
||||||
&:before {
|
&:before {
|
||||||
color: $brand;
|
color: $brand;
|
||||||
@@ -1753,11 +1756,18 @@ table {
|
|||||||
top: 14px;
|
top: 14px;
|
||||||
}
|
}
|
||||||
|
|
||||||
&.activity-proposals td:first-child:before {
|
&.activity-proposals {
|
||||||
|
|
||||||
|
td:first-child:before {
|
||||||
content: "h";
|
content: "h";
|
||||||
top: 18px;
|
top: 18px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.retired {
|
||||||
|
text-decoration: line-through;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
&.activity-investment-projects td:first-child:before {
|
&.activity-investment-projects td:first-child:before {
|
||||||
content: "\53";
|
content: "\53";
|
||||||
top: 10px;
|
top: 10px;
|
||||||
|
|||||||
@@ -343,6 +343,10 @@
|
|||||||
word-wrap: break-word;
|
word-wrap: break-word;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.callout.proposal-retired {
|
||||||
|
font-size: $base-font-size;
|
||||||
|
}
|
||||||
|
|
||||||
.social-share-full .social-share-button {
|
.social-share-full .social-share-button {
|
||||||
display:inline;
|
display:inline;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,13 +1,13 @@
|
|||||||
<div class="sidebar-divider"></div>
|
<div class="sidebar-divider"></div>
|
||||||
<h3 class="sidebar-title"><%= t("proposals.index.retired_proposals") %></h3>
|
<h3 class="sidebar-title"><%= t("proposals.index.retired_proposals") %></h3>
|
||||||
|
|
||||||
<p>
|
|
||||||
<% if params[:retired].blank? %>
|
<% if params[:retired].blank? %>
|
||||||
<%= link_to t("proposals.index.retired_proposals_link"), proposals_path(retired: 'all'), class: "small" %><br>
|
<p><%= link_to t("proposals.index.retired_proposals_link"), proposals_path(retired: 'all'), class: "small" %></p>
|
||||||
<% else %>
|
<% else %>
|
||||||
<%= link_to t("proposals.index.retired_links.all"), proposals_path(retired: 'all'), ({class: "small"} unless params[:retired] == 'all') %><br>
|
<div class="sidebar-links">
|
||||||
|
<%= link_to t("proposals.index.retired_links.all"), proposals_path(retired: 'all'), ({class: "small"} unless params[:retired] == 'all') %>
|
||||||
<% Proposal::RETIRE_OPTIONS.each do |option| %>
|
<% Proposal::RETIRE_OPTIONS.each do |option| %>
|
||||||
<%= link_to t("proposals.index.retired_links.#{option}"), proposals_path(retired: option), ({class: "small"} unless params[:retired] == option) %><br>
|
<%= link_to t("proposals.index.retired_links.#{option}"), proposals_path(retired: option), ({class: "small"} unless params[:retired] == option) %>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
</p>
|
|
||||||
|
|||||||
@@ -2,33 +2,34 @@
|
|||||||
|
|
||||||
<div class="small-12 column">
|
<div class="small-12 column">
|
||||||
|
|
||||||
<div class="float-right">
|
<h1 class="inline-block"><%= t("proposals.retire_form.title") %></h1>
|
||||||
<%= link_to @proposal.title, @proposal %>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<h1><%= t("proposals.retire_form.title") %></h1>
|
<h3><%= link_to @proposal.title, @proposal %></h3>
|
||||||
|
|
||||||
<div data-alert class="callout primary">
|
<div data-alert class="callout warning">
|
||||||
<%= t("proposals.retire_form.warning") %>
|
<%= t("proposals.retire_form.warning") %>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<%= form_for(@proposal, url: retire_proposal_path(@proposal)) do |f| %>
|
<%= form_for(@proposal, url: retire_proposal_path(@proposal)) do |f| %>
|
||||||
<%= render 'shared/errors', resource: @proposal %>
|
<%= render 'shared/errors', resource: @proposal %>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
|
<div class="small-12 medium-6 large-4 column">
|
||||||
<div class="small-12 medium-6 column">
|
|
||||||
<%= f.label :retired_reason, t("proposals.retire_form.retired_reason_label") %>
|
<%= f.label :retired_reason, t("proposals.retire_form.retired_reason_label") %>
|
||||||
<%= f.select :retired_reason, retire_proposals_options, {include_blank: t("proposals.retire_form.retired_reason_blank"), label: false} %>
|
<%= f.select :retired_reason, retire_proposals_options, {include_blank: t("proposals.retire_form.retired_reason_blank"), label: false} %>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="small-12 column">
|
<div class="row">
|
||||||
|
<div class="small-12 medium-9 column">
|
||||||
<%= f.label :retired_explanation, t("proposals.retire_form.retired_explanation_label") %>
|
<%= f.label :retired_explanation, t("proposals.retire_form.retired_explanation_label") %>
|
||||||
<%= f.text_area :retired_explanation, rows: 4, maxlength: 500, label: false,
|
<%= f.text_area :retired_explanation, rows: 4, maxlength: 500, label: false,
|
||||||
placeholder: t('proposals.retire_form.retired_explanation_placeholder') %>
|
placeholder: t('proposals.retire_form.retired_explanation_placeholder') %>
|
||||||
</div>
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="actions small-12 column">
|
<div class="row">
|
||||||
<%= f.submit(class: "button", value: t("proposals.retire_form.submit_button")) %>
|
<div class="actions small-12 medium-3 column">
|
||||||
|
<%= f.submit(class: "button expanded", value: t("proposals.retire_form.submit_button")) %>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|||||||
@@ -23,8 +23,11 @@
|
|||||||
|
|
||||||
<h1><%= @proposal.title %></h1>
|
<h1><%= @proposal.title %></h1>
|
||||||
<% if @proposal.retired? %>
|
<% if @proposal.retired? %>
|
||||||
<div data-alert class="callout alert margin-top">
|
<div data-alert class="callout alert margin-top proposal-retired">
|
||||||
<strong><%= t("proposals.show.retired_warning") %> <%= link_to t("proposals.show.retired_warning_link_to_explanation"), "#retired_explanation" %></strong>
|
<strong>
|
||||||
|
<%= t("proposals.show.retired_warning") %><br>
|
||||||
|
<%= link_to t("proposals.show.retired_warning_link_to_explanation"), "#retired_explanation" %>
|
||||||
|
</strong>
|
||||||
</div>
|
</div>
|
||||||
<% elsif @proposal.conflictive? %>
|
<% elsif @proposal.conflictive? %>
|
||||||
<div data-alert class="callout alert margin-top">
|
<div data-alert class="callout alert margin-top">
|
||||||
@@ -79,9 +82,10 @@
|
|||||||
<h4><%= @proposal.question %></h4>
|
<h4><%= @proposal.question %></h4>
|
||||||
|
|
||||||
<% if @proposal.retired? %>
|
<% if @proposal.retired? %>
|
||||||
<a id="retired_explanation"></a>
|
<div id="retired_explanation" class="callout">
|
||||||
<h2><%= t('proposals.show.retired') %>: <%= t("proposals.retire_options.#{@proposal.retired_reason}") unless @proposal.retired_reason == 'other' %></h2>
|
<h2><%= t('proposals.show.retired') %>: <%= t("proposals.retire_options.#{@proposal.retired_reason}") unless @proposal.retired_reason == 'other' %></h2>
|
||||||
<%= simple_format text_with_links(@proposal.retired_explanation), {}, sanitize: false %>
|
<%= simple_format text_with_links(@proposal.retired_explanation), {}, sanitize: false %>
|
||||||
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
|
|
||||||
<%= render 'shared/tags', taggable: @proposal %>
|
<%= render 'shared/tags', taggable: @proposal %>
|
||||||
|
|||||||
@@ -2,13 +2,13 @@
|
|||||||
<% @proposals.each do |proposal| %>
|
<% @proposals.each do |proposal| %>
|
||||||
<tr id="proposal_<%= proposal.id %>">
|
<tr id="proposal_<%= proposal.id %>">
|
||||||
<td>
|
<td>
|
||||||
<%= link_to proposal.title, proposal, proposal.retired? ? {class: 'delete'} : {} %>
|
<%= link_to proposal.title, proposal, proposal.retired? ? {class: 'retired'} : {} %>
|
||||||
<br>
|
<br>
|
||||||
<%= proposal.summary %>
|
<%= proposal.summary %>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td class="text-center">
|
||||||
<% if proposal.retired? %>
|
<% if proposal.retired? %>
|
||||||
<%= t('users.show.retired') %>
|
<span class="label alert"><%= t('users.show.retired') %></span>
|
||||||
<% else %>
|
<% else %>
|
||||||
<%= link_to t('users.show.retire'),
|
<%= link_to t('users.show.retire'),
|
||||||
retire_form_proposal_path(proposal),
|
retire_form_proposal_path(proposal),
|
||||||
|
|||||||
Reference in New Issue
Block a user