Skip to content

Commit

Permalink
Add aria-expanded to settings accordion button
Browse files Browse the repository at this point in the history
Mark settings button that triggers the expand/collaps of the
side nav settings with aria-expanded attribute to improve accesibility.

Resolves : nextcloud/server#37136

Signed-off-by: fenn-cs <fenn25.fn@gmail.com>
  • Loading branch information
Fenn-CS committed May 17, 2023
1 parent 2d6245a commit b31fc57
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 0 deletions.
3 changes: 3 additions & 0 deletions l10n/messages.pot
Expand Up @@ -143,6 +143,9 @@ msgstr ""
msgid "Open navigation"
msgstr ""

msgid "Open settings menu"
msgstr ""

msgid "Password is secure"
msgstr ""

Expand Down
Expand Up @@ -27,6 +27,9 @@
<div id="app-settings__header">
<button class="settings-button"
type="button"
:aria-expanded="open"
aria-controls="app-settings__content"
:aria-label="ariaLabel"
@click="toggleMenu">
<Cog class="settings-button__icon" :size="20" />
<span class="settings-button__label">{{ title }}</span>
Expand Down Expand Up @@ -77,6 +80,9 @@ export default {
this.clickOutsideOptions,
]
},
ariaLabel() {
return t('Open settings menu')
},
},
methods: {
toggleMenu() {
Expand Down

0 comments on commit b31fc57

Please sign in to comment.