app/views/spina/admin/attachments/edit.html.erb
<%= turbo_frame_tag dom_id(@attachment) + "_filename" do %>
<%= form_with model: @attachment, url: spina.admin_attachment_path(@attachment), html: {class: 'w-full max-w-sm pr-3'} do |f| %>
<div class="flex items-center w-full">
<div class="relative w-full mr-2">
<%= text_field_tag :filename, @attachment.file.filename.base, class: 'form-input w-full h-9 pr-10 text-sm', placeholder: t('spina.media_library.filename'), data: {controller: "autofocus"} %>
<div class="absolute top-0 right-2 h-full flex items-center text-gray-400">
<%= ".#{@attachment.file.filename.extension}" %>
</div>
</div>
<button type="submit" class="btn btn-default px-2">
<%= heroicon("check-circle", style: :mini, class: "w-6 h-6") %>
</button>
</div>
<% end %>
<% end %>