Fix Upload button missing from Tab order

The label element used as the upload trigger had no tabindex, making it
unreachable by keyboard. Add tabindex="0" and role="button" so it is
included in Tab order and correctly announced by screen readers.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
pull/599/head
Marcelo Paiva 3 weeks ago
parent a4872d64d3
commit 25a2519dd8

@ -1,5 +1,5 @@
<%= form_for '', url: templates_upload_path, id: form_id = SecureRandom.uuid, method: :post, class: 'inline', html: { enctype: 'multipart/form-data' } do %>
<label for="upload_template" id="templates_upload_button" class="btn btn-ghost text-base">
<label for="upload_template" id="templates_upload_button" class="btn btn-ghost text-base" tabindex="0" role="button">
<button type="submit" class="hidden peer"></button>
<span class="peer-disabled:hidden">
<span class="flex items-center justify-center space-x-2">

Loading…
Cancel
Save