Skip to content

Comments

Fix download disabled buttons#9125

Merged
garethrees merged 3 commits intodevelopfrom
fix-download-disabled-buttons
Feb 17, 2026
Merged

Fix download disabled buttons#9125
garethrees merged 3 commits intodevelopfrom
fix-download-disabled-buttons

Conversation

@garethrees
Copy link
Member

Relevant issue(s)

Broke in b869305 as part of #8803.

What does this do

Fix disabled buttons still submitting. Disabled on a link is only presentational, so we need to use button_to in order to truly disable these.

Also adds some CSS fixes to make the button_to versions look as intended.

Screenshots

btn-group fix works with button in each position:

Screenshot 2026-02-16 at 10 00 36 Screenshot 2026-02-16 at 10 00 46

[skip changelog]

90% of the time you use a button_to like a link_to so want it to be
displayed as one. Without this the form is `display:block`.
When we use the `button_to` helper a form is generated with a button
inside the form element. Bootstrap doesn't expect this so the btn-group
styling breaks.

This CSS enables mixed link-based/form-based buttons to be correctly
grouped.
Disabled on a link is only presentational, so we need to use button_to
in order to truly disable these.
@garethrees garethrees marked this pull request as ready for review February 16, 2026 11:58
@garethrees garethrees merged commit 291b454 into develop Feb 17, 2026
5 checks passed
@garethrees garethrees deleted the fix-download-disabled-buttons branch February 17, 2026 10:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant