Skip to content

Commit

Permalink
Fix issue with closing dialog in the userbar
Browse files Browse the repository at this point in the history
- Remove `data-a11y-dialog-hide` and use Stimulus data action approach
- This ensures that our code is more agnostic to the third party library and can leverage our own DialogController behaviour
- Works around ally-dialog issue KittyGiraudel/a11y-dialog#582
- Fixes #10924
  • Loading branch information
lb- authored and laymonage committed Oct 18, 2023
1 parent 7131a85 commit 8683981
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@
{% if theme %}data-w-dialog-theme-value="{{ theme }}"{% endif %}
{% if data_url %}data-url="{{ data_url }}"{% endif %}
>
<div data-a11y-dialog-hide class="w-dialog__overlay"></div>
<div class="w-dialog__overlay" data-action="click->w-dialog#hide"></div>
<div class="w-dialog__box">
<button type="button" data-a11y-dialog-hide aria-label="{% trans 'Close dialog' %}" class="w-dialog__close-button">
<button type="button" class="w-dialog__close-button" aria-label="{% trans 'Close dialog' %}" data-action="w-dialog#hide">
{% icon name='cross' classname="w-dialog__close-icon" %}
</button>

Expand Down

0 comments on commit 8683981

Please sign in to comment.