Closed Bug 1946776 Opened 1 year ago Closed 1 year ago

Add support for accesskey to moz-box-button

Categories

(Toolkit :: UI Widgets, enhancement)

enhancement

Tracking

()

RESOLVED FIXED
138 Branch
Tracking Status
firefox138 --- fixed

People

(Reporter: hjones, Assigned: hjones)

References

(Blocks 1 open bug)

Details

(Whiteboard: [recomp])

Attachments

(1 external file)

We generally tend to support accesskeys on interactive elements, especially those that are used in settings. We should extend this support to our moz-box-button element so that it can more easily be activated by the keyboard. We will want it to be mapped and delegated to the inner button element in the component, similar to how we handle accesskeys in moz-button.

Acceptance Criteria:

  1. Add the accesskey: { type: String, fluent: true, mapped: true } property to moz-box-button
  2. Update the labelTemplate() function in MozBoxBase to use moz-label and set the accesskey if it is defined (searchfox)
    • <label is="moz-label accesskey=${ifDefined(this.accessKey)>${this.label}</label>
Assignee: nobody → hjones
Status: NEW → ASSIGNED
Pushed by hjones@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/a279aec9ee6f add accesskey support to moz-box-button r=reusable-components-reviewers,akulyk
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → 138 Branch
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: