app/views/decidim/meetings/polls/questions/_published_question.html.erb in decidim-meetings-0.28.4 vs app/views/decidim/meetings/polls/questions/_published_question.html.erb in decidim-meetings-0.29.0.rc1
- old
+ new
@@ -1,27 +1,30 @@
-<summary><%= t(".question") %></summary>
+<summary>
+ <span><%= t(".question") %></span>
+</summary>
<div>
- <p><%= translated_attribute(question.body) %></p>
<% @form = form || Decidim::Meetings::AnswerForm.new(question_id: question.id, current_user:) %>
- <%= decidim_form_for(@form, url: meeting_polls_answers_path(meeting), method: :post, remote: true, html: { class: "form-defaults mt-4" }, data: { "safe-path" => meeting_live_event_path(meeting) }) do |form| %>
- <div class="answer question" data-max-choices="<%= question.max_choices %>">
+
+ <p class="h3"><%= @form.label %></p>
+
+ <%= decidim_form_for(@form, url: meeting_polls_answers_path(meeting), method: :post, remote: true, html: { class: "form-defaults" }, data: { "safe-path" => meeting_live_event_path(meeting) }) do |form| %>
+ <div class="meeting-polls__answer" data-max-choices="<%= question.max_choices %>">
<p class="form-error max-choices-alert mt-0 mb-4"><%= t(".max_choices_alert") %></p>
<%= render partial: "decidim/meetings/polls/answers/#{question.question_type}", locals: { answer: @form.answer, question:, answer_form: form, disabled: question.answered_by?(current_user), field_id: question.id } %>
<%= form.hidden_field :question_id %>
<% @form.errors.full_messages.each do |msg| %>
<small class="form-error is-visible mt-1"><%= msg %></small>
<% end %>
+
+ <% if question.answered_by?(current_user) %>
+ <%= cell("decidim/announcement", t(".question_replied"), callout_class: "success" ) %>
+ <% else %>
+ <button class="ml-auto mt-8 button button__lg button__secondary"><%= t(".reply_question") %></button>
+ <% end %>
</div>
- <% if question.answered_by?(current_user) %>
- <%= cell("decidim/announcement", t(".question_replied"), callout_class: "success" ) %>
- <% else %>
- <div class="text-right">
- <button class="ml-auto button button button__sm button__secondary"><%= t(".reply_question") %></button>
- </div>
- <% end %>
<% end %>
</div>