Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Incorrect buttons labels in High Contrast mode #4436

Merged
merged 8 commits into from
Dec 21, 2020
Merged
3 changes: 2 additions & 1 deletion plugins/button/plugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@

template += '>&nbsp;</span>' +
'<span id="{id}_label" class="cke_button_label cke_button__{name}_label" aria-hidden="false">{label}</span>' +
'<span id="{id}_description" class="cke_button_label" aria-hidden="false">{ariaShortcut}</span>' +
'<span id="{id}_description" class="cke_button_label" aria-hidden="false">{ariaShortcutSpace}{ariaShortcut}</span>' +
'{arrowHtml}' +
'</a>';

Expand Down Expand Up @@ -300,6 +300,7 @@
state: stateName,
ariaDisabled: stateName == 'disabled' ? 'true' : 'false',
title: this.title + ( shortcut ? ' (' + shortcut.display + ')' : '' ),
ariaShortcutSpace: shortcut ? '&nbsp;' : '',
ariaShortcut: shortcut ? editor.lang.common.keyboardShortcut + ' ' + shortcut.aria : '',
titleJs: env.gecko && !env.hc ? '' : ( this.title || '' ).replace( "'", '' ),
hasArrow: typeof this.hasArrow === 'string' && this.hasArrow || ( this.hasArrow ? 'true' : 'false' ),
Expand Down