<%= t(".subtitle.#{@type}") %>
<% if @addresses.present? %>
<%= render component('ui/dropdown').new(
text: t(".select_address"),
"data-#{stimulus_id}-target": "addresses",
class: "max-h-[26rem] overflow-y-auto"
) do %>
<% @addresses.each do |address| %>
<%= tag.a(
format_address(address),
href: solidus_admin.send("order_#{@type}_address_path", @order, address_id: address.id),
'data-turbo-frame': address_frame_id,
'data-action': "#{component('ui/dropdown').stimulus_id}#close",
) %>
<% end %>
<% end %>
<% end %>
<%= turbo_frame_tag address_frame_id do %>
<%= render component('ui/forms/address').new(address: @address, name: "order[#{@type}_address_attributes]") %>
<% end %>
<% end %>
<% modal.with_actions do %>