Merge branch 'master' into polls-gallery-polish
This commit is contained in:
@@ -12,13 +12,19 @@
|
|||||||
label: t("admin.questions.new.poll_label") %>
|
label: t("admin.questions.new.poll_label") %>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<%= f.text_field :title, maxlength: Poll::Question.title_max_length %>
|
<%= f.text_field :title %>
|
||||||
|
|
||||||
<div class="small-12">
|
<div class="small-12">
|
||||||
<%= f.label :video_url, t("proposals.form.proposal_video_url") %>
|
<%= f.label :video_url, t("proposals.form.proposal_video_url") %>
|
||||||
<p class="help-text" id="video-url-help-text"><%= t("proposals.form.proposal_video_url_note") %></p>
|
|
||||||
<%= f.text_field :video_url, placeholder: t("proposals.form.proposal_video_url"), label: false,
|
<p class="help-text" id="video-url-help-text">
|
||||||
aria: {describedby: "video-url-help-text"} %>
|
<%= t("proposals.form.proposal_video_url_note") %>
|
||||||
|
</p>
|
||||||
|
|
||||||
|
<%= f.text_field :video_url,
|
||||||
|
placeholder: t("proposals.form.proposal_video_url"),
|
||||||
|
label: false,
|
||||||
|
aria: {describedby: "video-url-help-text"} %>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="small-12 medium-6 large-4 margin-top">
|
<div class="small-12 medium-6 large-4 margin-top">
|
||||||
|
|||||||
@@ -66,42 +66,57 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="expanded poll-more-info-answers">
|
<% @poll.questions.map(&:question_answers).flatten.each do |answer| %>
|
||||||
<div class="row padding">
|
<% if answer.description.present? || answer.images.any? || answer.documents.present? %>
|
||||||
|
<div class="expanded poll-more-info-answers">
|
||||||
|
<div class="row padding">
|
||||||
|
|
||||||
<% @poll.questions.map(&:question_answers).flatten.each do |answer| %>
|
<% @poll.questions.map(&:question_answers).flatten.each do |answer| %>
|
||||||
<div class="small-12 medium-6 column end" id="answer_<%= answer.id %>"
|
<div class="small-12 medium-6 column end" id="answer_<%= answer.id %>"
|
||||||
data-toggler="medium-6 answer-divider">
|
data-toggler="medium-6 answer-divider">
|
||||||
|
|
||||||
<% if answer.description.present? %>
|
|
||||||
<h3><%= answer.title %></h3>
|
<h3><%= answer.title %></h3>
|
||||||
<% end %>
|
|
||||||
|
|
||||||
<% if answer.images.any? %>
|
<% if answer.description.present? %>
|
||||||
<%= render "gallery", answer: answer %>
|
<div class="margin-top">
|
||||||
<% end %>
|
|
||||||
|
|
||||||
<% if answer.description.present? %>
|
|
||||||
<div class="margin-top">
|
|
||||||
<div id="answer_description_<%= answer.id %>" class="answer-description short" data-toggler="short">
|
|
||||||
<%= safe_html_with_links simple_format(answer.description) %>
|
<%= safe_html_with_links simple_format(answer.description) %>
|
||||||
</div>
|
</div>
|
||||||
<a id="read_more_<%= answer.id %>"
|
<% end %>
|
||||||
data-toggle="answer_description_<%= answer.id %> read_more_<%= answer.id %> read_less_<%= answer.id %>"
|
|
||||||
data-toggler="hide">
|
<% if answer.images.any? %>
|
||||||
<%= t("polls.show.read_more", answer: answer.title) %>
|
<%= render "gallery", answer: answer %>
|
||||||
</a>
|
<% end %>
|
||||||
<a id="read_less_<%= answer.id %>"
|
|
||||||
data-toggle="answer_description_<%= answer.id %> read_more_<%= answer.id %> read_less_<%= answer.id %>"
|
<% if answer.description.present? %>
|
||||||
data-toggler="hide"
|
<div class="margin-top">
|
||||||
class="hide">
|
<div id="answer_description_<%= answer.id %>" class="answer-description short" data-toggler="short">
|
||||||
<%= t("polls.show.read_less", answer: answer.title) %>
|
<%= safe_html_with_links simple_format(answer.description) %>
|
||||||
</a>
|
</div>
|
||||||
</div>
|
<a id="read_more_<%= answer.id %>"
|
||||||
<% end %>
|
data-toggle="answer_description_<%= answer.id %> read_more_<%= answer.id %> read_less_<%= answer.id %>"
|
||||||
|
data-toggler="hide">
|
||||||
|
<%= t("polls.show.read_more", answer: answer.title) %>
|
||||||
|
</a>
|
||||||
|
<a id="read_less_<%= answer.id %>"
|
||||||
|
data-toggle="answer_description_<%= answer.id %> read_more_<%= answer.id %> read_less_<%= answer.id %>"
|
||||||
|
data-toggler="hide"
|
||||||
|
class="hide">
|
||||||
|
<%= t("polls.show.read_less", answer: answer.title) %>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
<% end %>
|
||||||
|
|
||||||
|
<% if answer.documents.present? %>
|
||||||
|
<% answer.documents.each do |document| %>
|
||||||
|
<%= link_to document.title,
|
||||||
|
document.attachment.url,
|
||||||
|
target: "_blank",
|
||||||
|
rel: "nofollow" %>
|
||||||
|
<% end %>
|
||||||
|
<% end %>
|
||||||
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
</div>
|
||||||
</div>
|
<% end %>
|
||||||
</div>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user