Currently Drupal.behaviors.dialog.prepareDialogButtons only works on input elements or links styled as buttons. It does not account for the fact there may be button elements.

| Comment | File | Size | Author |
|---|---|---|---|
| #30 | 2822014-30.patch | 704 bytes | casey |
| #29 | 2822014-29.patch | 616 bytes | casey |
| #3 | Home___ForkdIn_and_Home___ForkdIn.png | 218.67 KB | mglaman |
Issue fork drupal-2822014
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #2
mglamanThis can easily reproduced by using a theme which adds
input--submit.html.twigand replaces the input with button tag.Comment #3
mglamanAttaching screenshot
Comment #8
luuph commentedIs there a reason why everything in .form-actions shouldn't be in that area? At first glance it seems like a logical place for all form actions.
Comment #17
needs-review-queue-bot commentedThe Needs Review Queue Bot tested this issue. It either no longer applies to Drupal core, or fails the Drupal core commit checks. Therefore, this issue status is now "Needs work".
Apart from a re-roll or rebase, this issue may need more work to address feedback in the issue or MR comments. To progress an issue, incorporate this feedback as part of the process of updating the issue. This helps other contributors to know what is outstanding.
Consult the Drupal Contributor Guide to find step-by-step guides for working with issues.
Comment #19
seanbReroll for 10.1
Comment #20
smustgrave commentedAs a bug could we get a test case showing the issue?
Comment #21
kksandr commentedThe Claro theme converts the delete button from a.button to a.action-link (_claro_convert_link_to_action_link), I think they should also be moved to the action area.
Comment #22
jonmcl commentedI know it should probably be another issue, but if this issue ever manages to make it into core, it would be great if one small addition could be added:
allowing the dialog buttons to inherit the disabled attribute from the original button.
Comment #23
kksandr commentedThe issue with action links has been resolved here: https://www.drupal.org/project/drupal/issues/3359240
Comment #25
kksandr commentedI moved the fix from patches to the merge request
Comment #26
sourabhjainLet me work on suggestion #22.
Comment #27
bramdriesen@sourabhjain That suggestion needs a separate issue. All issues should focus on only fixing one specific thing, you should know that by now. Please revert, and if you're feeling like it, create a child issue for that.
Comment #28
sourabhjainSure @bramdriesen. Let me revert it.
Comment #29
casey commentedReroll for 10.2
Comment #30
casey commentedSnapshot of latest state of MR (after rebase) for safe usage with composer patches
Comment #31
oily commentedThe broken functional test looked unrelated. Re-ran the pipeline once or twice and now it is green.
Test coverage still required.