mirror of
https://gitcode.com/GitHub_Trending/ji/jitsi-meet.git
synced 2026-05-14 13:27:49 +00:00
Improve usability of toggled button labels (#12426)
* feat(a11y) buttons can now have toggled-aware a11y labels
This commit is contained in:
committed by
GitHub
parent
27765b47d7
commit
45b7f53294
@@ -26,25 +26,11 @@ type Props = AbstractButtonProps & {
|
||||
*/
|
||||
class OverflowToggleButton extends AbstractButton<Props, *> {
|
||||
accessibilityLabel = 'toolbar.accessibilityLabel.moreActions';
|
||||
toggledAccessibilityLabel = 'toolbar.accessibilityLabel.closeMoreActions';
|
||||
icon = IconDotsHorizontal;
|
||||
label = 'toolbar.moreActions';
|
||||
toggledLabel = 'toolbar.moreActions';
|
||||
|
||||
/**
|
||||
* Retrieves tooltip dynamically.
|
||||
*/
|
||||
get tooltip() {
|
||||
return 'toolbar.moreActions';
|
||||
}
|
||||
|
||||
/**
|
||||
* Required by linter due to AbstractButton overwritten prop being writable.
|
||||
*
|
||||
* @param {string} _value - The value.
|
||||
*/
|
||||
set tooltip(_value) {
|
||||
// Unused.
|
||||
}
|
||||
tooltip = 'toolbar.moreActions';
|
||||
|
||||
/**
|
||||
* Indicates whether this button is in toggled state or not.
|
||||
|
||||
Reference in New Issue
Block a user