<%# locals: (form:) %> <%= render DS::Tabs.new( variant: :unstyled, active_tab: get_default_transaction_search_filter[:key], active_btn_classes: "bg-surface text-primary", inactive_btn_classes: "text-secondary hover:bg-container-inset" ) do |tabs| %>
<%= tabs.with_nav(classes: "shrink-0 flex w-full md:w-44 flex-row md:flex-col items-start p-3 text-sm font-medium text-secondary border-b md:border-b-0 md:border-r border-secondary overflow-x-auto md:overflow-x-visible") do |nav| %> <% transaction_search_filters.each do |filter| %> <%= nav.with_btn(id: filter[:key], label: filter[:label], classes: "w-full px-3 py-2 flex gap-2 items-center rounded-md") do %> <%= icon(filter[:icon]) %> <%= tag.span(filter[:label], class: "text-sm font-medium") %> <% end %> <% end %> <% end %>
<% transaction_search_filters.each do |filter| %> <%= tabs.with_panel(tab_id: filter[:key]) do %> <%= render partial: get_transaction_search_filter_partial_path(filter), locals: { form: form } %> <% end %> <% end %>
<% if @q.present? %> <%= render DS::Link.new( text: t(".clear_filters"), variant: "ghost", href: transactions_path(clear_filters: true), ) %> <% end %>
<%= render DS::Button.new(text: t(".cancel"), type: "button", variant: "ghost", data: { action: "DS--menu#close" }) %> <%= render DS::Button.new(text: t(".apply")) %>
<% end %>