Sha256: a768e70de504c4c14ba926553fe04fc9b4ae7fbd20e1d31b2c0fd403b99e501f
Contents?: true
Size: 1.16 KB
Versions: 2
Compression:
Stored size: 1.16 KB
Contents
<% locations = { tokyo: "Tokyo", new_york: "New York", london: "London" } %> <%= sl_turbo_form_for(@user, url: hotwire_forms_path) do |form| %> <div> <%= form.text_field :name do %> <span slot="help-text" style="color: rgb(var(--sl-color-danger-600));"> <%= @user.errors.full_messages_for(:name).first %> </span> <% end %> </div> <div> <%= form.color_field :color %> </div> <div> <%= form.range_field :score, min: 0, max: 100, step: 1 %> </div> <div> <%= form.collection_radio_buttons :current_city, locations, :first, :last %> </div> <div> <%= form.collection_select :previous_city, locations, :first, :last, {}, { placeholder: "Select one" } %> </div> <div> <%= form.collection_select :past_cities, locations, :first, :last, {}, { placeholder: "Select two or more", multiple: true, clearable: true } %> </div> <div> <%= form.check_box :remember_me %> </div> <div> <%= form.switch_field :subscribe_to_emails, value: "1" %> </div> <div> <%= form.text_area :description %> </div> <%= form.submit %> <%= form.submit "Submit without Turbo", data: { turbo: false } %> <% end %>
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
shoelace-rails-0.2.0 | test/dummy_app/app/views/hotwire_forms/form.html.erb |
shoelace-rails-0.1.0 | test/dummy_app/app/views/hotwire_forms/form.html.erb |