Sha256: 54f3ad19589d1415670808ff52798078c13058626be50ed01a28bfc479d49c3c
Contents?: true
Size: 1.38 KB
Versions: 25
Compression:
Stored size: 1.38 KB
Contents
<%= field_wrapper **field_wrapper_args, data: { controller: "tags-field", tags_field_mode_value: @field.mode, tags_field_whitelist_items_value: @field.suggestions.to_json, tags_field_disallowed_items_value: @field.disallowed.to_json, tags_field_enforce_suggestions_value: @field.enforce_suggestions, tags_field_suggestions_max_items_value: @field.suggestions_max_items, tags_field_close_on_select_value: @field.close_on_select, tags_field_delimiters_value: @field.delimiters, tags_field_fetch_values_from_value: @field.fetch_values_from, } do %> <%# We use a dummy field so the back action from Turbo does not brake the field %> <%# dummy field %> <%= text_field_tag "#{@field.id}-dummy", '', class: classes("w-full"), data: { tags_field_target: :fakeInput, }, disabled: disabled?, placeholder: @field.placeholder, style: @field.get_html(:style, view: view, element: :input), value: '' %> <%# real field %> <%= @form.text_field @field.id, class: classes("hidden w-full border-primary-500 focus-within:border-primary-500"), data: { tags_field_target: :input, }, disabled: disabled?, placeholder: @field.placeholder, style: @field.get_html(:style, view: view, element: :input), value: @field.field_value.to_json %> <% end %>
Version data entries
25 entries across 25 versions & 1 rubygems