view app/views/pastes/new.html.erb @ 401:6bb805283daf

Allow vertical resize.
author nanaya <me@myconan.net>
date Sun, 06 Sep 2015 04:01:22 +0900
parents 851432f21603
children a18e19139f57
line wrap: on
line source

<% provide :title, t(".title") %>
<%= form_for @paste do |f| %>
  <%= render "shared/filter_spam" %>

  <div class="form-group <%= error_class f.object, :paste %>">
    <%= f.text_area :paste, :autofocus => true, :class => "form-control paste-paste js-paste-paste", :rows => 20 %>
  </div>

  <div class="form-horizontal">
    <div class="form-group <%= error_class f.object, :key %>">
      <%= f.label :key, t(".deletion_key"), :class => "col-sm-2 control-label" %>
      <div class="col-sm-3">
        <%= f.text_field :key, :class => "form-control" %>
      </div>
    </div>

    <div class="form-group">
      <label class="control-label col-sm-2"><%= t(".privacy.label") %></label>

      <div class="col-sm-10">
        <% paste_privacy_options.each do |label, value| %>
          <div class="radio">
            <label>
              <%= f.radio_button :is_private, value %>
              <%= t(".privacy.#{label}") %>
            </label>
          </div>
        <% end %>
      </div>
    </div>

    <div class="form-group"><div class="col-sm-offset-2 col-sm-10">
      <%= f.button :class => "btn btn-primary" %>

      <%= link_to t(".clear"), "#", :class => "btn btn-danger js-paste-clear" %>
    </div></div>
  </div>
<% end %>