%# locals: (value: 'last_30_days', button_class: '') -%>
<% options = [["7D", "last_7_days"], ["1M", "last_30_days"], ["1Y", "last_365_days"], ["All", "all"]] %>
<%=
tag.button(
type: "button",
data: { "select-target": "button" },
class: button_class.presence || "flex items-center gap-1 w-full border border-alpha-black-100 shadow-xs rounded-lg text-sm p-2 cursor-pointer text-gray-900 text-sm"
) do
%>
<%= options.find { |option| option[1] == value }[0] %>
<%= lucide_icon("chevron-down", class: "w-5 h-5 text-gray-500") %>
<% end %>
<% options.each do |label, value| %>
-
<%= label %>
<% end %>