From: Andy Allan Date: Wed, 28 Feb 2018 07:27:01 +0000 (+0800) Subject: Rework the new report form text and layout X-Git-Tag: live~2937^2~47 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/8587c2a02bfafd7bf07e6f7130a9211f41da1757 Rework the new report form text and layout --- diff --git a/app/assets/stylesheets/common.scss b/app/assets/stylesheets/common.scss index cb55f1ae0..f1fdc136b 100644 --- a/app/assets/stylesheets/common.scss +++ b/app/assets/stylesheets/common.scss @@ -2842,9 +2842,19 @@ input.richtext_title[type="text"] { float:right; } -.disclaimer { - width: 600px; +.report-disclaimer { background: #fff1f0; color: #d85030; border-color: rgba(216, 80, 48, 0.3); + padding: 5px; + margin-bottom: $lineheight; + + ul { + padding-left: $lineheight; + margin-bottom: 0; + + li { + list-style: disc; + } + } } diff --git a/app/views/reports/new.html.erb b/app/views/reports/new.html.erb index f3bda8880..9812c6806 100644 --- a/app/views/reports/new.html.erb +++ b/app/views/reports/new.html.erb @@ -2,13 +2,13 @@

<%= t ".title_html", :link => link_to(reportable_title(@report.issue.reportable), reportable_url(@report.issue.reportable)) %>

<% end %> -
+
+ <%= t('issues.new.disclaimer.intro') %>
    - <%= t('issues.new.disclaimer.intro') %>: -
  • <%= t('issues.new.disclaimer.not_just_mistake') %>
  • -
  • <%= t('issues.new.disclaimer.unable_to_fix') %>
  • -
  • <%= t('issues.new.disclaimer.resolve_with_user') %>
  • -
+
  • <%= t('issues.new.disclaimer.not_just_mistake') %>
  • +
  • <%= t('issues.new.disclaimer.unable_to_fix') %>
  • +
  • <%= t('issues.new.disclaimer.resolve_with_user') %>
  • +
    <%= form_for(@report) do |f| %> @@ -19,20 +19,20 @@ <%= issue_form.hidden_field :reportable_type %> <% end %> -
    -

    <%= t('issues.new.select') %>:

    - -
    - <% Report.categories_for(@report.issue.reportable).each do |c| %> -
    - <%= radio_button :report, :category, c %> - <%= label_tag "report_category_#{c}", t("reports.categories.#{@report.issue.reportable.class.name}.#{c}") %>
    -
    - <% end %> -
    +
    +

    <%= t('issues.new.select') %>

    +
      + <% Report.categories_for(@report.issue.reportable).each do |c| %> +
    • + <%= radio_button :report, :category, c %> + <%= label_tag "report_category_#{c}", t("reports.categories.#{@report.issue.reportable.class.name}.#{c}") %>
      +
    • + <% end %> +
    +
    -
    - <%= text_area :report, :details, :cols => 20, :rows => 3, placeholder: t('issues.new.details'), required: true %> +
    + <%= text_area :report, :details, :cols => 20, :rows => 5, placeholder: t('issues.new.details'), required: true %>
    diff --git a/config/locales/en.yml b/config/locales/en.yml index bb1292d9c..40237b63b 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -941,13 +941,13 @@ en: successful_update: Your report has been updated successfully provide_details: Please provide the required details new: - details: Please provide some more details into the problem. (This field cannot be left blank!) - select: Select a reason for your report + details: Please provide some more details about the problem (required). + select: "Select a reason for your report:" disclaimer: - intro: Before sending in a report for official action, be sure that - not_just_mistake: You are sure that the problem is not just a mistake - unable_to_fix: You are unable to fix the problem yourself - resolve_with_user: You have tried to resolve the problem with the user + intro: "Before sending your report to the site moderators, please ensure that:" + not_just_mistake: You are certain that the problem is not just a mistake + unable_to_fix: You are unable to fix the problem yourself or with the help of your fellow community members + resolve_with_user: You have already tried to resolve the problem with the user concerned show: title: "%{status} Issue #%{issue_id}" reports: