% %i[actions_on_multiple].each do |key| if (content = content_for(key).presence) flush_content_for key partial.section key, content end end %> <% form ||= current_fields_form if defined?(options) && options.is_a?(Array) option_field_options = options options = defined?(html_options) ? html_options : {} ActiveSupport::Deprecation.new.warn( "`options` will be replaced with `option_field_options` in a later version. " \ "Please pass all of the options you want as strings to ``." ) end options ||= {} option_field_options ||= options_for(form, method) other_options ||= {} if defined?(html_options) ActiveSupport::Deprecation.new.warn( "The `html_options` attribute for checkboxes and radio buttons will be removed in a later version " \ "Pass all of your html options like `class` to `options` instead." ) end options[:multiple] ||= false if defined?(multiple) options[:multiple] = multiple ActiveSupport::Deprecation.new.warn( "The `multiple` attribute will be removed in a later version. " \ "Please pass `options: {multiple: true}` to `render` instead." ) end options[:id] ||= form.field_id(method) show_select_all_top ||= false show_select_all_bottom ||= false use_columns ||= false labels = labels_for(form, method) options[:data] ||= {} options[:data][:controller] ||= "" options[:data][:controller] += " fields--field" if options[:multiple] options[:data] = options[:data].merge({ "select-all-target": 'checkbox' }) options[:data][:action] ||= "" options[:data][:action] += " select-all#updateToggle" end %> <%# # TODO: We should either remove this, or move the Action Models `bulk_action_select` # partial here to bullet_train-core because this cannot work with the setup we currently have. %> <% if options[:multiple] && (show_select_all_top || show_select_all_bottom) %> <% select_all = capture do %>