vpat 8: make window buttons not focusable (#4070)

Minimize, maximize, close, etc. window buttons are generally
not accessible for focus. They can get focused on mac with
voiceover enabled which can be confusing.

Added aria-hidden attribute to prevent voiceover from
placing the cursor on them.
This commit is contained in:
abaevbog 2024-10-03 21:02:16 -07:00 • committed by GitHub
parent 6282eef3cc
commit d462330347
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 8 additions and 0 deletions

View file

@ -354,21 +354,25 @@
titlebar-btn="min"
oncommand="window.minimize();"
data-l10n-id="browser-window-minimize-button"
aria-hidden="true"
/>
<toolbarbutton class="titlebar-button titlebar-max"
titlebar-btn="max"
oncommand="window.maximize();"
data-l10n-id="browser-window-maximize-button"
aria-hidden="true"
/>
<toolbarbutton class="titlebar-button titlebar-restore"
titlebar-btn="max"
oncommand="window.fullScreen ? BrowserFullScreen() : window.restore();"
data-l10n-id="browser-window-restore-down-button"
aria-hidden="true"
/>
<toolbarbutton class="titlebar-button titlebar-close"
titlebar-btn="close"
oncommand="window.close();"
data-l10n-id="browser-window-close-button"
aria-hidden="true"
/>
</hbox>
</vbox>

View file

@ -818,18 +818,22 @@
<toolbarbutton class="titlebar-button titlebar-min"
oncommand="window.minimize();"
data-l10n-id="browser-window-minimize-button"
aria-hidden="true"
/>
<toolbarbutton class="titlebar-button titlebar-max"
oncommand="window.maximize();"
data-l10n-id="browser-window-maximize-button"
aria-hidden="true"
/>
<toolbarbutton class="titlebar-button titlebar-restore"
oncommand="window.fullScreen ? BrowserFullScreen() : window.restore();"
data-l10n-id="browser-window-restore-down-button"
aria-hidden="true"
/>
<toolbarbutton class="titlebar-button titlebar-close"
oncommand="window.close();"
data-l10n-id="browser-window-close-button"
aria-hidden="true"
/>
</hbox>
</vbox>