<%= select_tag 'per_page',
options_for_select(per_page_options, index_params[:per_page]),
class: 'appearance-none inline-flex bg-white-100 disabled:bg-white-400 disabled:cursor-not-allowed focus:bg-white text-slate-700 disabled:text-slate-600 rounded-md py-1 px-2 leading-tight border border-slate-300 outline-none focus:border-slate-400 outline w-16 mr-1 text-sm',
data: {
'turbo-frame': turbo_frame,
'per-page-target': 'selector',
action: 'change->per-page#reload'
}
%> <%= t('avo.per_page').downcase %>
<% per_page_options.each do |option| %>
<% if parent_resource.present? %>
<%= link_to "Change to #{option} items per page", helpers.related_resources_path(parent_resource.model_class, resource.model_class, per_page: option, keep_query_params: true), class: 'hidden', 'data-per-page-option': option, 'data-turbo-frame': turbo_frame %>
<% else %>
<%= link_to "Change to #{option} items per page", helpers.resources_path(resource: resource, per_page: option, keep_query_params: true), class: 'hidden', 'data-per-page-option': option, 'data-turbo-frame': turbo_frame %>
<% end %>
<% end %>