Mercurial > zeropaste
comparison app/views/pastes/_form.html.erb @ 380:2ddd61aca2c8
I18n. And refactor paste privacy settings form.
| author | nanaya <me@myconan.net> |
|---|---|
| date | Sun, 07 Jun 2015 02:45:49 +0900 |
| parents | 2ad092e60975 |
| children | 26f8c634052c |
comparison
equal
deleted
inserted
replaced
| 379:2ad092e60975 | 380:2ddd61aca2c8 |
|---|---|
| 6 | 6 |
| 7 <div id="paste-control"> | 7 <div id="paste-control"> |
| 8 <div class="inputs left"> | 8 <div class="inputs left"> |
| 9 | 9 |
| 10 <div class="vertical-flex"> | 10 <div class="vertical-flex"> |
| 11 <%= f.label :key, "Deletion key", :class => "form-label" %> | 11 <%= f.label :key, t(".deletion_key"), :class => "form-label" %> |
| 12 <%= f.text_field :key %> | 12 <%= f.text_field :key %> |
| 13 </div> | 13 </div> |
| 14 | 14 |
| 15 <div class="vertical-flex"> | 15 <div class="vertical-flex"> |
| 16 <div class="form-label">Privacy</div> | 16 <div class="form-label"><%= t(".privacy.label") %></div> |
| 17 <label class="radio"> | |
| 18 <%= f.radio_button :is_private, "0" %> | |
| 19 <span>Public</span> | |
| 20 </label> | |
| 21 | 17 |
| 22 <label class="radio"> | 18 <% paste_privacy_options.each do |label, value| %> |
| 23 <%= f.radio_button :is_private, "1" %> | 19 <label class="radio"> |
| 24 <span>Private</span> | 20 <%= f.radio_button :is_private, value %> |
| 25 </label> | 21 <span><%= t(".privacy.#{label}") %></span> |
| 22 </label> | |
| 23 <% end %> | |
| 26 </div> | 24 </div> |
| 27 </div> | 25 </div> |
| 28 | 26 |
| 29 <div class="inputs right"> | 27 <div class="inputs right"> |
| 30 <%= f.button %> | 28 <%= f.button %> |
| 31 | 29 |
| 32 <%= button_tag "Clear", :type => "button", :id => "reset_paste" %> | 30 <%= button_tag t(".clear"), :type => "button", :id => "reset_paste" %> |
| 33 </div> | 31 </div> |
| 34 </div> | 32 </div> |
| 35 <% end %> | 33 <% end %> |
