]> git.openstreetmap.org Git - rails.git/blob - app/views/preferences/edit.html.erb
Merge branch 'pull/4985'
[rails.git] / app / views / preferences / edit.html.erb
1 <% content_for :heading do %>
2   <h1><%= t ".title" %></h1>
3 <% end %>
4
5 <%= bootstrap_form_for current_user, :url => { :action => :update } do |f| %>
6   <%= f.select :preferred_editor, [[t("editor.default", :name => t("editor.#{Settings.default_editor}.name")), "default"]] + Editors::AVAILABLE_EDITORS.collect { |e| [t("editor.#{e}.description"), e] } %>
7
8   <%= f.text_field :languages %>
9
10   <div class="mb-3">
11     <%= label_tag "site_color_scheme", t("preferences.show.preferred_site_color_scheme"), :class => "form-label" %>
12     <%= select_tag "site_color_scheme",
13                    options_for_select(%w[auto light dark].map { |scheme| [t("preferences.show.site_color_schemes.#{scheme}"), scheme] },
14                                       preferred_color_scheme(:site)),
15                    :class => "form-select" %>
16   </div>
17
18   <div class="mb-3">
19     <%= label_tag "map_color_scheme", t("preferences.show.preferred_map_color_scheme"), :class => "form-label" %>
20     <%= select_tag "map_color_scheme",
21                    options_for_select(%w[auto light dark].map { |scheme| [t("preferences.show.map_color_schemes.#{scheme}"), scheme] },
22                                       preferred_color_scheme(:map)),
23                    :class => "form-select" %>
24   </div>
25
26   <%= f.primary t(".save") %>
27   <%= link_to t(".cancel"), preferences_path, :class => "btn btn-link" %>
28 <% end %>