add focus delegation; fixes #1622 (#1651)

This commit is contained in:
Cory LaViska
2025-10-24 09:28:25 -04:00
committed by GitHub
parent 1bfebe36a3
commit f906b07d98
2 changed files with 4 additions and 2 deletions

View File

@@ -24,6 +24,8 @@ Components with the <wa-badge variant="warning">Experimental</wa-badge> badge sh
- Added the Kazakh translation [pr:1496]
- Added docs for code completion for VS Code and JetBrains [pr:1550]
- Added back the missing `form-control-label` part to `<wa-textarea>` for consistency with other form controls [pr:1533]
- Added focus delegation to `<wa-button>` to ensure tabbing works properly when using `tabindex` [issue:1622]
- Added [text utilities](/docs/utilities/text/) for longform text, form control text, font sizes, font weights, text color, and truncation [pr:1602]
- Fixed a bug in `<wa-button>` where slotted badges weren't properly positioned in buttons with an `href` [issue:1377]
- Fixed focus outline styles in `<wa-details>` and native `<details>` [issue:1456]
- Fixed focus outline styles in `<wa-scroller>`, `<wa-dialog>`, and `<wa-drawer>` [issue:1484]
@@ -37,9 +39,8 @@ Components with the <wa-badge variant="warning">Experimental</wa-badge> badge sh
- Fixed a bug that caused the required `*` in form labels to have incorrect spacing in `<wa-checkbox>` and `<wa-switch>` [issue:1472]
- Fixed a bug in `<wa-dialog>` and `<wa-drawer>` that caused the component to prematurely hide when certain child elements are used [pr:1636]
- Improved autofill styles in `<wa-input>` so they span the entire width of the visual input [issue:1439]
- Modified `<wa-slider>` to only show the tooltip on the handle being dragged when in range mode [issue:1320]
- Improved [text utilities](/docs/utilities/text/) so that each size modifier always exactly matches the applied font size [pr:1602]
- Added [text utilities](/docs/utilities/text/) for longform text, form control text, font sizes, font weights, text color, and truncation [pr:1602]
- Modified `<wa-slider>` to only show the tooltip on the handle being dragged when in range mode [issue:1320]
- Upgraded `<wa-page>` from _experimental_ to _stable_
## 3.0.0-beta.6

View File

@@ -41,6 +41,7 @@ import styles from './button.css';
*/
@customElement('wa-button')
export default class WaButton extends WebAwesomeFormAssociatedElement {
static shadowRootOptions = { ...WebAwesomeFormAssociatedElement.shadowRootOptions, delegatesFocus: true };
static css = [styles, variantStyles, sizeStyles];
static get validators() {