@fluentui/web-components 3.0.0-rc.26 → 3.0.0-rc.28

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (128) hide show
  1. package/CHANGELOG.md +21 -2
  2. package/README.md +26 -0
  3. package/custom-elements.json +41 -56
  4. package/dist/esm/accordion/accordion.styles.css +11 -7
  5. package/dist/esm/accordion/accordion.template.html +4 -3
  6. package/dist/esm/accordion-item/accordion-item.styles.css +174 -170
  7. package/dist/esm/accordion-item/accordion-item.template.html +38 -31
  8. package/dist/esm/anchor-button/anchor-button.styles.css +224 -223
  9. package/dist/esm/anchor-button/anchor-button.template.html +8 -11
  10. package/dist/esm/avatar/avatar.styles.css +475 -470
  11. package/dist/esm/avatar/avatar.template.html +10 -14
  12. package/dist/esm/badge/badge.styles.css +264 -266
  13. package/dist/esm/badge/badge.template.html +5 -2
  14. package/dist/esm/button/button.base.js +2 -0
  15. package/dist/esm/button/button.base.js.map +1 -1
  16. package/dist/esm/button/button.styles.css +260 -259
  17. package/dist/esm/button/button.template.html +8 -10
  18. package/dist/esm/checkbox/checkbox.base.js +2 -0
  19. package/dist/esm/checkbox/checkbox.base.js.map +1 -1
  20. package/dist/esm/checkbox/checkbox.styles.css +146 -142
  21. package/dist/esm/checkbox/checkbox.template.html +21 -16
  22. package/dist/esm/compound-button/compound-button.styles.css +363 -365
  23. package/dist/esm/compound-button/compound-button.template.html +9 -11
  24. package/dist/esm/counter-badge/counter-badge.styles.css +177 -177
  25. package/dist/esm/counter-badge/counter-badge.template.html +5 -2
  26. package/dist/esm/dialog/dialog.styles.css +65 -66
  27. package/dist/esm/dialog/dialog.template.html +18 -15
  28. package/dist/esm/dialog-body/dialog-body.styles.css +81 -76
  29. package/dist/esm/dialog-body/dialog-body.styles.js +1 -0
  30. package/dist/esm/dialog-body/dialog-body.styles.js.map +1 -1
  31. package/dist/esm/dialog-body/dialog-body.template.html +2 -1
  32. package/dist/esm/divider/divider.styles.css +105 -101
  33. package/dist/esm/divider/divider.template.html +6 -1
  34. package/dist/esm/drawer/drawer.styles.css +124 -119
  35. package/dist/esm/drawer/drawer.template.html +5 -2
  36. package/dist/esm/drawer-body/drawer-body.styles.css +29 -26
  37. package/dist/esm/drawer-body/drawer-body.template.html +5 -2
  38. package/dist/esm/dropdown/dropdown.base.d.ts +1 -1
  39. package/dist/esm/dropdown/dropdown.base.js +3 -1
  40. package/dist/esm/dropdown/dropdown.base.js.map +1 -1
  41. package/dist/esm/dropdown/dropdown.styles.css +192 -190
  42. package/dist/esm/dropdown/dropdown.styles.js +1 -0
  43. package/dist/esm/dropdown/dropdown.styles.js.map +1 -1
  44. package/dist/esm/dropdown/dropdown.template.html +26 -19
  45. package/dist/esm/field/field.styles.css +125 -121
  46. package/dist/esm/field/field.template.html +3 -2
  47. package/dist/esm/image/image.styles.css +49 -50
  48. package/dist/esm/image/image.template.html +6 -1
  49. package/dist/esm/label/label.styles.css +34 -30
  50. package/dist/esm/label/label.template.html +5 -2
  51. package/dist/esm/link/link.styles.css +58 -54
  52. package/dist/esm/link/link.template.html +4 -7
  53. package/dist/esm/listbox/listbox.styles.css +40 -36
  54. package/dist/esm/listbox/listbox.styles.js +2 -2
  55. package/dist/esm/listbox/listbox.template.html +4 -6
  56. package/dist/esm/menu/menu.d.ts +8 -8
  57. package/dist/esm/menu/menu.js.map +1 -1
  58. package/dist/esm/menu/menu.styles.css +56 -52
  59. package/dist/esm/menu/menu.styles.js +5 -5
  60. package/dist/esm/menu/menu.template.html +6 -5
  61. package/dist/esm/menu-button/menu-button.styles.css +260 -259
  62. package/dist/esm/menu-button/menu-button.template.html +23 -14
  63. package/dist/esm/menu-item/menu-item.js +2 -0
  64. package/dist/esm/menu-item/menu-item.js.map +1 -1
  65. package/dist/esm/menu-item/menu-item.styles.css +141 -137
  66. package/dist/esm/menu-item/menu-item.styles.js +8 -3
  67. package/dist/esm/menu-item/menu-item.styles.js.map +1 -1
  68. package/dist/esm/menu-item/menu-item.template.html +48 -17
  69. package/dist/esm/menu-list/menu-list.styles.css +19 -15
  70. package/dist/esm/menu-list/menu-list.template.html +4 -3
  71. package/dist/esm/message-bar/message-bar.styles.css +83 -84
  72. package/dist/esm/message-bar/message-bar.template.html +7 -2
  73. package/dist/esm/option/option.styles.css +117 -114
  74. package/dist/esm/option/option.template.html +17 -14
  75. package/dist/esm/progress-bar/progress-bar.styles.css +83 -79
  76. package/dist/esm/progress-bar/progress-bar.template.html +4 -1
  77. package/dist/esm/radio/radio.styles.css +100 -96
  78. package/dist/esm/radio/radio.template.html +6 -9
  79. package/dist/esm/radio-group/radio-group.styles.css +45 -41
  80. package/dist/esm/radio-group/radio-group.template.html +11 -10
  81. package/dist/esm/rating-display/rating-display.styles.css +136 -134
  82. package/dist/esm/rating-display/rating-display.template.html +5 -2
  83. package/dist/esm/slider/slider.js +2 -0
  84. package/dist/esm/slider/slider.js.map +1 -1
  85. package/dist/esm/slider/slider.styles.css +186 -182
  86. package/dist/esm/slider/slider.template.html +13 -15
  87. package/dist/esm/spinner/spinner.styles.css +155 -151
  88. package/dist/esm/spinner/spinner.template.html +16 -11
  89. package/dist/esm/switch/switch.styles.css +112 -108
  90. package/dist/esm/switch/switch.template.html +9 -8
  91. package/dist/esm/tab/tab.js +2 -0
  92. package/dist/esm/tab/tab.js.map +1 -1
  93. package/dist/esm/tab/tab.styles.css +112 -108
  94. package/dist/esm/tab/tab.template.html +6 -5
  95. package/dist/esm/tablist/tablist.styles.css +194 -190
  96. package/dist/esm/tablist/tablist.template.html +2 -5
  97. package/dist/esm/text/text.styles.css +105 -101
  98. package/dist/esm/text/text.template.html +6 -1
  99. package/dist/esm/text-input/text-input.base.d.ts +0 -7
  100. package/dist/esm/text-input/text-input.base.js +3 -14
  101. package/dist/esm/text-input/text-input.base.js.map +1 -1
  102. package/dist/esm/text-input/text-input.styles.css +199 -195
  103. package/dist/esm/text-input/text-input.template.html +34 -35
  104. package/dist/esm/text-input/text-input.template.js +1 -4
  105. package/dist/esm/text-input/text-input.template.js.map +1 -1
  106. package/dist/esm/textarea/textarea.base.js +2 -0
  107. package/dist/esm/textarea/textarea.base.js.map +1 -1
  108. package/dist/esm/textarea/textarea.styles.css +254 -250
  109. package/dist/esm/textarea/textarea.template.html +28 -27
  110. package/dist/esm/toggle-button/toggle-button.styles.css +360 -357
  111. package/dist/esm/toggle-button/toggle-button.template.html +8 -10
  112. package/dist/esm/tooltip/tooltip.styles.css +81 -77
  113. package/dist/esm/tooltip/tooltip.template.html +6 -1
  114. package/dist/esm/tree/tree.styles.css +9 -5
  115. package/dist/esm/tree/tree.template.html +3 -2
  116. package/dist/esm/tree-item/tree-item.base.js +2 -0
  117. package/dist/esm/tree-item/tree-item.base.js.map +1 -1
  118. package/dist/esm/tree-item/tree-item.styles.css +157 -153
  119. package/dist/esm/tree-item/tree-item.template.html +8 -7
  120. package/dist/esm/utils/autofocus.d.ts +12 -0
  121. package/dist/esm/utils/autofocus.js +25 -0
  122. package/dist/esm/utils/autofocus.js.map +1 -0
  123. package/dist/web-components-all.js +26 -20
  124. package/dist/web-components-all.min.js +15 -15
  125. package/dist/web-components.d.ts +9 -16
  126. package/dist/web-components.js +26 -20
  127. package/dist/web-components.min.js +15 -15
  128. package/package.json +4 -5
@@ -2159,7 +2159,7 @@ export declare class BaseDropdown extends FASTElement {
2159
2159
  */
2160
2160
  private searchTimeout?;
2161
2161
  /**
2162
- * Handles printable character input by moving {@link activeIndex} to the next option whose label matches the
2162
+ * Handles printable character input by moving {@link Dropdown#activeIndex} to the next option whose label matches the
2163
2163
  * accumulated search string. When the string is a single character (or the same character repeated), matching
2164
2164
  * options are cycled through; otherwise the string is treated as a prefix match.
2165
2165
  *
@@ -3623,13 +3623,6 @@ export declare class BaseTextInput extends FASTElement {
3623
3623
  */
3624
3624
  clickHandler(e: MouseEvent): boolean | void;
3625
3625
  connectedCallback(): void;
3626
- /**
3627
- * Focuses the inner control when the component is focused.
3628
- *
3629
- * @param e - the event object
3630
- * @public
3631
- */
3632
- focusinHandler(e: FocusEvent): boolean | void;
3633
3626
  /**
3634
3627
  * Resets the value to its initial value when the form is reset.
3635
3628
  *
@@ -8615,25 +8608,25 @@ export declare class Menu extends FASTElement {
8615
8608
  * Defines whether the menu is open or not.
8616
8609
  * @internal
8617
8610
  */
8618
- private _open;
8611
+ protected _open: boolean;
8619
8612
  /**
8620
8613
  * The trigger element of the menu.
8621
8614
  * @internal
8622
8615
  */
8623
- private _trigger?;
8616
+ protected _trigger?: HTMLElement;
8624
8617
  /**
8625
8618
  * The menu list element of the menu which has the popover behavior.
8626
8619
  * @internal
8627
8620
  */
8628
- private _menuList?;
8621
+ protected _menuList?: HTMLElement;
8629
8622
  /**
8630
8623
  * @internal
8631
8624
  */
8632
- private _triggerAbortController?;
8625
+ protected _triggerAbortController?: AbortController;
8633
8626
  /**
8634
8627
  * @internal
8635
8628
  */
8636
- private _menuListAbortController?;
8629
+ protected _menuListAbortController?: AbortController;
8637
8630
  /**
8638
8631
  * Called when the element is connected to the DOM.
8639
8632
  * Sets up the component.
@@ -8722,12 +8715,12 @@ export declare class Menu extends FASTElement {
8722
8715
  * Adds trigger-related event listeners.
8723
8716
  * @internal
8724
8717
  */
8725
- private addTriggerListeners;
8718
+ protected addTriggerListeners(): void;
8726
8719
  /**
8727
8720
  * Adds menu-list event listeners.
8728
8721
  * @internal
8729
8722
  */
8730
- private addMenuListListeners;
8723
+ protected addMenuListListeners(): void;
8731
8724
  /**
8732
8725
  * Handles keyboard interaction for the menu. Closes the menu and focuses on the trigger when the Escape key is
8733
8726
  * pressed. Closes the menu when the Tab key is pressed.
@@ -8749,7 +8742,7 @@ export declare class Menu extends FASTElement {
8749
8742
  * @internal
8750
8743
  * @param e - The event triggered on document click.
8751
8744
  */
8752
- private documentClickHandler;
8745
+ protected documentClickHandler: (e: any) => void;
8753
8746
  }
8754
8747
 
8755
8748
  /**
@@ -5980,6 +5980,16 @@ const definition$B = Badge.compose({
5980
5980
 
5981
5981
  definition$B.define(FluentDesignSystem.registry);
5982
5982
 
5983
+ function maybeSetAutoFocus(element) {
5984
+ const doc = element.ownerDocument;
5985
+ if (element?.isConnected && element?.hasAttribute("autofocus") && // Note: opacity=0 is considered visible based on the native `autofocus` implementation
5986
+ element?.checkVisibility?.({ contentVisibilityAuto: true, visibilityProperty: true }) && [null, element, doc.body, doc.documentElement].includes(doc.activeElement)) {
5987
+ Updates.enqueue(() => {
5988
+ element.focus();
5989
+ });
5990
+ }
5991
+ }
5992
+
5983
5993
  var __defProp$H = Object.defineProperty;
5984
5994
  var __getOwnPropDesc$H = Object.getOwnPropertyDescriptor;
5985
5995
  var __decorateClass$H = (decorators, target, key, kind) => {
@@ -6072,6 +6082,7 @@ class BaseButton extends FASTElement {
6072
6082
  super.connectedCallback();
6073
6083
  this.elementInternals.ariaDisabled = `${!!this.disabledFocusable}`;
6074
6084
  this.setTabIndex();
6085
+ maybeSetAutoFocus(this);
6075
6086
  }
6076
6087
  /**
6077
6088
  * This fallback creates a new slot, then creates a submit button to mirror the custom element's
@@ -6527,6 +6538,7 @@ class BaseCheckbox extends FASTElement {
6527
6538
  this.disabled = !!this.disabledAttribute;
6528
6539
  this.setAriaChecked();
6529
6540
  this.setValidity();
6541
+ maybeSetAutoFocus(this);
6530
6542
  }
6531
6543
  /**
6532
6544
  * Updates the form value when a user changes the `checked` state.
@@ -7091,7 +7103,7 @@ class DialogBody extends FASTElement {
7091
7103
 
7092
7104
  const template$v = html`<template><div class=title part=title><slot name=title></slot><slot name=title-action></slot><slot name=close @click=${(x, c) => x.clickHandler(c.event)}></slot></div><div class=content part=content><slot></slot></div><div class=actions part=actions><slot name=action></slot></div></template>`;
7093
7105
 
7094
- const styles$v = css`${display("grid")} :host{background:${colorNeutralBackground1};box-sizing:border-box;gap:${spacingVerticalS};padding:${spacingVerticalXXL} ${spacingHorizontalXXL};container:dialog-body/inline-size}.title{box-sizing:border-box;align-items:flex-start;background:${colorNeutralBackground1};color:${colorNeutralForeground1};column-gap:8px;display:flex;font-family:${fontFamilyBase};font-size:${fontSizeBase500};font-weight:${fontWeightSemibold};inset-block-start:0;justify-content:space-between;line-height:${lineHeightBase500};margin-block-end:calc(${spacingVerticalS} * -1);margin-block-start:calc(${spacingVerticalXXL} * -1);padding-block-end:${spacingVerticalS};padding-block-start:${spacingVerticalXXL}}.content{box-sizing:border-box;color:${colorNeutralForeground1};font-family:${fontFamilyBase};font-size:${fontSizeBase300};font-weight:${fontWeightRegular};line-height:${lineHeightBase300};min-height:32px}.actions{box-sizing:border-box;background:${colorNeutralBackground1};display:flex;flex-direction:column;gap:${spacingVerticalS};inset-block-end:0;margin-block-end:calc(${spacingVerticalXXL} * -1);padding-block-end:${spacingVerticalXXL};padding-block-start:${spacingVerticalL}}::slotted([slot='title-action']){margin-inline-start:auto}::slotted([slot='title']){font:inherit;padding:0;margin:0}:not(:has(:is([slot='title'],[slot='title-action']))) .title{justify-content:end}@container (min-width:480px){.actions{align-items:center;flex-direction:row;justify-content:flex-end;margin-block-start:calc(${spacingVerticalS} * -1);padding-block-start:${spacingVerticalS}}}@media (min-height:480px){.title{position:sticky;z-index:1}.actions{position:sticky;z-index:2}`;
7106
+ const styles$v = css`${display("grid")} :host{background:${colorNeutralBackground1};box-sizing:border-box;gap:${spacingVerticalS};padding:${spacingVerticalXXL} ${spacingHorizontalXXL};container:dialog-body/inline-size}.title{box-sizing:border-box;align-items:flex-start;background:${colorNeutralBackground1};color:${colorNeutralForeground1};column-gap:8px;display:flex;font-family:${fontFamilyBase};font-size:${fontSizeBase500};font-weight:${fontWeightSemibold};inset-block-start:0;justify-content:space-between;line-height:${lineHeightBase500};margin-block-end:calc(${spacingVerticalS} * -1);margin-block-start:calc(${spacingVerticalXXL} * -1);padding-block-end:${spacingVerticalS};padding-block-start:${spacingVerticalXXL}}.content{box-sizing:border-box;color:${colorNeutralForeground1};font-family:${fontFamilyBase};font-size:${fontSizeBase300};font-weight:${fontWeightRegular};line-height:${lineHeightBase300};min-height:32px}.actions{box-sizing:border-box;background:${colorNeutralBackground1};display:flex;flex-direction:column;gap:${spacingVerticalS};inset-block-end:0;margin-block-end:calc(${spacingVerticalXXL} * -1);padding-block-end:${spacingVerticalXXL};padding-block-start:${spacingVerticalL}}::slotted([slot='title-action']){margin-inline-start:auto}::slotted([slot='title']){font:inherit;padding:0;margin:0}:not(:has(:is([slot='title'],[slot='title-action']))) .title{justify-content:end}@container (min-width:480px){.actions{align-items:center;flex-direction:row;justify-content:flex-end;margin-block-start:calc(${spacingVerticalS} * -1);padding-block-start:${spacingVerticalS}}}@media (min-height:480px){.title{position:sticky;z-index:1}.actions{position:sticky;z-index:2}}`;
7095
7107
 
7096
7108
  const definition$v = DialogBody.compose({
7097
7109
  name: tagName$v,
@@ -8033,7 +8045,7 @@ const _BaseDropdown = class _BaseDropdown extends FASTElement {
8033
8045
  this._insertingControl = false;
8034
8046
  }
8035
8047
  /**
8036
- * Handles printable character input by moving {@link activeIndex} to the next option whose label matches the
8048
+ * Handles printable character input by moving {@link Dropdown#activeIndex} to the next option whose label matches the
8037
8049
  * accumulated search string. When the string is a single character (or the same character repeated), matching
8038
8050
  * options are cycled through; otherwise the string is treated as a prefix match.
8039
8051
  *
@@ -8236,6 +8248,7 @@ const _BaseDropdown = class _BaseDropdown extends FASTElement {
8236
8248
  Updates.enqueue(() => {
8237
8249
  this.insertControl();
8238
8250
  });
8251
+ maybeSetAutoFocus(this);
8239
8252
  }
8240
8253
  disconnectedCallback() {
8241
8254
  _BaseDropdown.AnchorPositionFallbackObserver?.disconnect();
@@ -8381,7 +8394,7 @@ __decorateClass$w([
8381
8394
  attr
8382
8395
  ], Dropdown.prototype, "size", 2);
8383
8396
 
8384
- const styles$r = css`${display("inline-flex")} :host{box-sizing:border-box;color:${colorNeutralForeground1};cursor:pointer}:host(${placeholderShownState}){color:${colorNeutralForeground4}}.control{appearance:none;background-color:${colorNeutralBackground1};border-radius:${borderRadiusMedium};border:${strokeWidthThin} solid ${colorTransparentStroke};box-shadow:inset 0 0 0 ${strokeWidthThin} var(--control-border-color);box-sizing:border-box;color:inherit;column-gap:${spacingHorizontalXXS};display:inline-flex;justify-content:space-between;min-width:160px;overflow:hidden;padding:${spacingVerticalSNudge} ${spacingHorizontalMNudge};white-space:normal;position:relative;text-align:start;width:100%;z-index:1;${typographyBody1Styles}}:host([size='small']) .control{column-gap:${spacingHorizontalXXS};padding:${spacingVerticalXS} ${spacingHorizontalSNudge};${typographyCaption1Styles}}:host([size='large']) .control{column-gap:${spacingHorizontalS};padding:${spacingVerticalS} ${spacingHorizontalM};${typographyBody2Styles}}::slotted(:is(input,button)){all:unset;flex:1 1 auto}::slotted(button){cursor:pointer}::slotted(input){cursor:text}:where(slot[name='indicator']>*,::slotted([slot='indicator'])){all:unset;align-items:center;appearance:none;aspect-ratio:1;color:${colorNeutralForeground3};display:inline-flex;justify-content:center;width:20px}:host([size='small']) :where(slot[name='indicator']>*,::slotted([slot='indicator'])){width:16px}:host([size='large']) :where(slot[name='indicator']>*,::slotted([slot='indicator'])){width:24px}.control::after,.control::before{content:''/'';inset:auto 0 0;pointer-events:none;position:absolute}.control::before{height:${strokeWidthThin}}.control::after{background-color:${colorCompoundBrandStroke};height:${strokeWidthThick};scale:0 1;transition:scale ${durationUltraFast} ${curveDecelerateMid}}:host(:where(:focus-within)) .control{border-radius:${borderRadiusMedium};box-shadow:inset 0 0 0 1px ${colorStrokeFocus1};outline:${strokeWidthThick} solid ${colorStrokeFocus2}}:host(:where(${openState},:focus-within)) .control::after{scale:1 1;transition-duration:${durationNormal};transition-timing-function:${curveAccelerateMid}}:host(:where([appearance='outline'],[appearance='transparent'])) .control::before{background-color:${colorNeutralStrokeAccessible}}:host([appearance='transparent']) .control{--control-border-color:${colorTransparentStrokeInteractive};background-color:${colorTransparentBackground};border-radius:${borderRadiusNone}}:host([appearance='outline']) .control{--control-border-color:${colorNeutralStroke1}}:host([appearance='outline']) .control:hover{--control-border-color:${colorNeutralStroke1Hover}}:host(:where([appearance='outline'],[appearance='transparent'])) .control:hover::before{background-color:${colorNeutralStrokeAccessibleHover}}:host([appearance='outline']) .control:hover::after{background-color:${colorCompoundBrandBackgroundHover}}:host([appearance='outline']) .control:active{--control-border-color:${colorNeutralStroke1Pressed}}:host(:where([appearance='outline'],[appearance='transparent'])) .control:active::before{background-color:${colorNeutralStrokeAccessiblePressed}}:host(:where([appearance='outline'],[appearance='transparent'])) .control:active::after{background-color:${colorCompoundBrandBackgroundPressed}}:host([appearance='filled-darker']) .control{background-color:${colorNeutralBackground3}}:host(:where([appearance='filled-lighter'],[appearance='filled-darker'])) .control{--control-border-color:${colorTransparentStroke}}:host(:disabled),:host(:disabled) ::slotted(:where(button,input)){cursor:not-allowed}:host(:disabled) .control::before,:host(:disabled) .control::after{content:none}:host(:disabled) .control:is(*,:active,:hover),:host(:disabled) :where(slot[name='indicator']>*,::slotted([slot='indicator'])){--control-border-color:${colorNeutralStrokeDisabled};background-color:${colorNeutralBackgroundDisabled};color:${colorNeutralForegroundDisabled}}::slotted(:not([slot]):not([popover])),::slotted([popover]:not(:popover-open)){display:none}@supports not (anchor-name:--anchor){:host{--listbox-max-height:50vh;--margin-offset:calc(${lineHeightBase300} + (${spacingVerticalSNudge} * 2) + ${strokeWidthThin})}:host([size='small']){--margin-offset:calc(${lineHeightBase200} + (${spacingVerticalXS} * 2) + ${strokeWidthThin})}:host([size='large']){--margin-offset:calc(${lineHeightBase400} + (${spacingVerticalS} * 2) + ${strokeWidthThin})}}@media (forced-colors:active){:host(:disabled) .control{border-color:GrayText}:host(:disabled) :where(slot[name='indicator']>*,::slotted([slot='indicator'])){color:GrayText}`;
8397
+ const styles$r = css`${display("inline-flex")} :host{box-sizing:border-box;color:${colorNeutralForeground1};cursor:pointer}:host(${placeholderShownState}){color:${colorNeutralForeground4}}.control{appearance:none;background-color:${colorNeutralBackground1};border-radius:${borderRadiusMedium};border:${strokeWidthThin} solid ${colorTransparentStroke};box-shadow:inset 0 0 0 ${strokeWidthThin} var(--control-border-color);box-sizing:border-box;color:inherit;column-gap:${spacingHorizontalXXS};display:inline-flex;justify-content:space-between;min-width:160px;overflow:hidden;padding:${spacingVerticalSNudge} ${spacingHorizontalMNudge};white-space:normal;position:relative;text-align:start;width:100%;z-index:1;${typographyBody1Styles}}:host([size='small']) .control{column-gap:${spacingHorizontalXXS};padding:${spacingVerticalXS} ${spacingHorizontalSNudge};${typographyCaption1Styles}}:host([size='large']) .control{column-gap:${spacingHorizontalS};padding:${spacingVerticalS} ${spacingHorizontalM};${typographyBody2Styles}}::slotted(:is(input,button)){all:unset;flex:1 1 auto}::slotted(button){cursor:pointer}::slotted(input){cursor:text}:where(slot[name='indicator']>*,::slotted([slot='indicator'])){all:unset;align-items:center;appearance:none;aspect-ratio:1;color:${colorNeutralForeground3};display:inline-flex;justify-content:center;width:20px}:host([size='small']) :where(slot[name='indicator']>*,::slotted([slot='indicator'])){width:16px}:host([size='large']) :where(slot[name='indicator']>*,::slotted([slot='indicator'])){width:24px}.control::after,.control::before{content:''/'';inset:auto 0 0;pointer-events:none;position:absolute}.control::before{height:${strokeWidthThin}}.control::after{background-color:${colorCompoundBrandStroke};height:${strokeWidthThick};scale:0 1;transition:scale ${durationUltraFast} ${curveDecelerateMid}}:host(:where(:focus-within)) .control{border-radius:${borderRadiusMedium};box-shadow:inset 0 0 0 1px ${colorStrokeFocus1};outline:${strokeWidthThick} solid ${colorStrokeFocus2}}:host(:where(${openState},:focus-within)) .control::after{scale:1 1;transition-duration:${durationNormal};transition-timing-function:${curveAccelerateMid}}:host(:where([appearance='outline'],[appearance='transparent'])) .control::before{background-color:${colorNeutralStrokeAccessible}}:host([appearance='transparent']) .control{--control-border-color:${colorTransparentStrokeInteractive};background-color:${colorTransparentBackground};border-radius:${borderRadiusNone}}:host([appearance='outline']) .control{--control-border-color:${colorNeutralStroke1}}:host([appearance='outline']) .control:hover{--control-border-color:${colorNeutralStroke1Hover}}:host(:where([appearance='outline'],[appearance='transparent'])) .control:hover::before{background-color:${colorNeutralStrokeAccessibleHover}}:host([appearance='outline']) .control:hover::after{background-color:${colorCompoundBrandBackgroundHover}}:host([appearance='outline']) .control:active{--control-border-color:${colorNeutralStroke1Pressed}}:host(:where([appearance='outline'],[appearance='transparent'])) .control:active::before{background-color:${colorNeutralStrokeAccessiblePressed}}:host(:where([appearance='outline'],[appearance='transparent'])) .control:active::after{background-color:${colorCompoundBrandBackgroundPressed}}:host([appearance='filled-darker']) .control{background-color:${colorNeutralBackground3}}:host(:where([appearance='filled-lighter'],[appearance='filled-darker'])) .control{--control-border-color:${colorTransparentStroke}}:host(:disabled),:host(:disabled) ::slotted(:where(button,input)){cursor:not-allowed}:host(:disabled) .control::before,:host(:disabled) .control::after{content:none}:host(:disabled) .control:is(*,:active,:hover),:host(:disabled) :where(slot[name='indicator']>*,::slotted([slot='indicator'])){--control-border-color:${colorNeutralStrokeDisabled};background-color:${colorNeutralBackgroundDisabled};color:${colorNeutralForegroundDisabled}}::slotted(:not([slot]):not([popover])),::slotted([popover]:not(:popover-open)){display:none}@supports not (anchor-name:--anchor){:host{--listbox-max-height:50vh;--margin-offset:calc(${lineHeightBase300} + (${spacingVerticalSNudge} * 2) + ${strokeWidthThin})}:host([size='small']){--margin-offset:calc(${lineHeightBase200} + (${spacingVerticalXS} * 2) + ${strokeWidthThin})}:host([size='large']){--margin-offset:calc(${lineHeightBase400} + (${spacingVerticalS} * 2) + ${strokeWidthThin})}}@media (forced-colors:active){:host(:disabled) .control{border-color:GrayText}:host(:disabled) :where(slot[name='indicator']>*,::slotted([slot='indicator'])){color:GrayText}}`;
8385
8398
 
8386
8399
  const definition$r = Dropdown.compose({
8387
8400
  name: tagName$r,
@@ -8960,7 +8973,7 @@ __decorateClass$q([
8960
8973
  observable
8961
8974
  ], Listbox.prototype, "dropdown", 2);
8962
8975
 
8963
- const styles$m = css`${display("inline-flex")} :host{background-color:${colorNeutralBackground1};border-radius:${borderRadiusMedium};border:${strokeWidthThin} solid ${colorTransparentStroke};box-shadow:${shadow16};box-sizing:border-box;flex-direction:column;margin:0;min-inline-size:160px;padding:${spacingHorizontalXS};row-gap:${spacingHorizontalXXS};width:auto}:host([popover]){inset:unset;overflow:auto}@supports (anchor-name:--anchor){:host([popover]){position:fixed;max-block-size:var(--listbox-max-height,calc(50vh - anchor-size(self-block)));min-inline-size:anchor-size(inline);inset-block-start:anchor(end);inset-inline-start:anchor(start);position-try-fallbacks:flip-block,flip-inline,flip-inline flip-block}}@supports not (anchor-name:--anchor){:host([popover]){margin-block-start:var(--margin-offset,0);max-block-size:var(--listbox-max-height,50vh);position:absolute}:host([popover]${flipBlockState}){margin-block-start:revert;translate:0 -100%}}`;
8976
+ const styles$m = css`${display("inline-flex")} :host{background-color:${colorNeutralBackground1};border-radius:${borderRadiusMedium};border:${strokeWidthThin} solid ${colorTransparentStroke};box-shadow:${shadow16};box-sizing:border-box;flex-direction:column;margin:0;min-inline-size:160px;padding:${spacingHorizontalXS};row-gap:${spacingHorizontalXXS};width:auto}:host([popover]){inset:unset;overflow:auto}@supports (anchor-name:--anchor){:host([popover]){position:fixed;max-block-size:var(--listbox-max-height,calc(50vh - anchor-size(self-block)));min-inline-size:anchor-size(inline);inset-block-start:anchor(outside);inset-inline-start:anchor(inside);position-try-fallbacks:flip-block,flip-inline,flip-inline flip-block}}@supports not (anchor-name:--anchor){:host([popover]){margin-block-start:var(--margin-offset,0);max-block-size:var(--listbox-max-height,50vh);position:absolute}:host([popover]${flipBlockState}){margin-block-start:revert;translate:0 -100%}}`;
8964
8977
 
8965
8978
  function listboxTemplate() {
8966
8979
  return html`<template @beforetoggle=${(x, c) => x.beforetoggleHandler(c.event)} @click=${(x, c) => x.clickHandler(c.event)}><slot ${ref("defaultSlot")} @slotchange=${(x, c) => x.slotchangeHandler(c.event)}></slot></template>`;
@@ -9228,6 +9241,7 @@ class MenuItem extends FASTElement {
9228
9241
  super.connectedCallback();
9229
9242
  this.elementInternals.role = this.role ?? MenuItemRole.menuitem;
9230
9243
  this.elementInternals.ariaChecked = this.role !== MenuItemRole.menuitem ? `${!!this.checked}` : null;
9244
+ maybeSetAutoFocus(this);
9231
9245
  }
9232
9246
  }
9233
9247
  __decorateClass$p([
@@ -9250,7 +9264,7 @@ __decorateClass$p([
9250
9264
  ], MenuItem.prototype, "submenu", 2);
9251
9265
  applyMixins(MenuItem, StartEnd);
9252
9266
 
9253
- const styles$k = css`${display("grid")} :host{--indent:0;align-items:center;background:${colorNeutralBackground1};border-radius:${borderRadiusMedium};color:${colorNeutralForeground2};contain:layout;cursor:pointer;flex-shrink:0;font:${fontWeightRegular} ${fontSizeBase300}/${lineHeightBase300} ${fontFamilyBase};grid-gap:4px;grid-template-columns:20px 20px auto 20px;height:32px;overflow:visible;padding:0 10px}:host(:hover){background:${colorNeutralBackground1Hover};color:${colorNeutralForeground2Hover}}:host(:active){background-color:${colorNeutralBackground1Selected};color:${colorNeutralForeground2Pressed}}:host(:active) ::slotted([slot='start']){color:${colorCompoundBrandForeground1Pressed}}:host(${disabledState}){background-color:${colorNeutralBackgroundDisabled};color:${colorNeutralForegroundDisabled}}:host(${disabledState}) ::slotted([slot='start']),:host(${disabledState}) ::slotted([slot='end']){color:${colorNeutralForegroundDisabled}}:host(:focus-visible){border-radius:${borderRadiusMedium};outline:2px solid ${colorStrokeFocus2}}.content{white-space:nowrap;flex-grow:1;grid-column:auto/span 2;padding:0 2px}:host(:not(${checkedState})) .indicator,:host(:not(${checkedState})) ::slotted([slot='indicator']),:host(:not(${submenuState})) .submenu-glyph,:host(:not(${submenuState})) ::slotted([slot='submenu-glyph']){display:none}::slotted([slot='end']){color:${colorNeutralForeground3};font:${fontWeightRegular} ${fontSizeBase200}/${lineHeightBase200} ${fontFamilyBase};white-space:nowrap}:host([data-indent='1']){--indent:1}:host([data-indent='2']){--indent:2;grid-template-columns:20px 20px auto auto}:host(${submenuState}){grid-template-columns:20px auto auto 20px}:host([data-indent='2']${submenuState}){grid-template-columns:20px 20px auto auto 20px}.indicator,::slotted([slot='indicator']){grid-column:1/span 1;width:20px}::slotted([slot='start']){display:inline-flex;grid-column:calc(var(--indent))/span 1}.content{grid-column:calc(var(--indent) + 1)/span 1}::slotted([slot='end']){grid-column:calc(var(--indent) + 2)/span 1;justify-self:end}.submenu-glyph,::slotted([slot='submenu-glyph']){grid-column:-2/span 1;justify-self:end}@layer popover{:host{anchor-name:--menu-trigger;position:relative}::slotted([popover]){margin:0;max-height:var(--menu-max-height,auto);position:fixed;position-anchor:--menu-trigger;inset:unset;inset-block-start:anchor(start);inset-inline-start:anchor(end);position-try-fallbacks:flip-inline,block-start,block-end;z-index:1}::slotted([popover]:not(:popover-open)){display:none}@supports not (anchor-name:--menu-trigger){::slotted([popover]){align-self:start}}}@media (forced-colors:active){:host(${disabledState}),:host(${disabledState}) ::slotted([slot='start']),:host(${disabledState}) ::slotted([slot='end']){color:GrayText}}`;
9267
+ const styles$k = css`${display("grid")} :host{--indent:0;align-items:center;background:${colorNeutralBackground1};border-radius:${borderRadiusMedium};color:${colorNeutralForeground2};contain:layout;cursor:pointer;flex-shrink:0;font:${fontWeightRegular} ${fontSizeBase300}/${lineHeightBase300} ${fontFamilyBase};grid-gap:4px;grid-template-columns:20px 20px auto 20px;height:32px;overflow:visible;padding:0 10px}:host(:hover){background:${colorNeutralBackground1Hover};color:${colorNeutralForeground2Hover}}:host(:active){background-color:${colorNeutralBackground1Selected};color:${colorNeutralForeground2Pressed}}:host(:active) ::slotted([slot='start']){color:${colorCompoundBrandForeground1Pressed}}:host(${disabledState}){background-color:${colorNeutralBackgroundDisabled};color:${colorNeutralForegroundDisabled}}:host(${disabledState}) ::slotted([slot='start']),:host(${disabledState}) ::slotted([slot='end']){color:${colorNeutralForegroundDisabled}}:host(:focus-visible){border-radius:${borderRadiusMedium};outline:2px solid ${colorStrokeFocus2}}.content{white-space:nowrap;flex-grow:1;grid-column:auto/span 2;padding:0 2px}:host(:not(${checkedState})) .indicator,:host(:not(${checkedState})) ::slotted([slot='indicator']),:host(:not(${submenuState})) .submenu-glyph,:host(:not(${submenuState})) ::slotted([slot='submenu-glyph']){display:none}::slotted([slot='end']){color:${colorNeutralForeground3};font:${fontWeightRegular} ${fontSizeBase200}/${lineHeightBase200} ${fontFamilyBase};white-space:nowrap}:host([data-indent='1']){--indent:1}:host([data-indent='2']){--indent:2;grid-template-columns:20px 20px auto auto}:host(${submenuState}){grid-template-columns:20px auto auto 20px}:host([data-indent='2']${submenuState}){grid-template-columns:20px 20px auto auto 20px}.indicator,::slotted([slot='indicator']){grid-column:1/span 1;width:20px}::slotted([slot='start']){display:inline-flex;grid-column:calc(var(--indent))/span 1}.content{grid-column:calc(var(--indent) + 1)/span 1}::slotted([slot='end']){grid-column:calc(var(--indent) + 2)/span 1;justify-self:end}.submenu-glyph,::slotted([slot='submenu-glyph']){grid-column:-2/span 1;justify-self:end}@layer popover{:host{anchor-name:--menu-trigger;position:relative}@position-try --inline-inside{inset-inline-start:unset;inset-inline-end:anchor(inside)}::slotted([popover]){margin:0;max-height:var(--menu-max-height,auto);position:fixed;position-anchor:--menu-trigger;inset:unset;inset-block-start:anchor(inside);inset-inline-start:anchor(outside);position-try-fallbacks:--inline-inside,flip-block,flip-block --inline-inside;z-index:1}::slotted([popover]:not(:popover-open)){display:none}@supports not (anchor-name:--menu-trigger){::slotted([popover]){align-self:start}}}@media (forced-colors:active){:host(${disabledState}),:host(${disabledState}) ::slotted([slot='start']),:host(${disabledState}) ::slotted([slot='end']){color:GrayText}}`;
9254
9268
 
9255
9269
  const Checkmark16Filled = html.partial(
9256
9270
  `<svg class=indicator fill=currentColor aria-hidden=true width=16 height=16 viewBox="0 0 16 16" xmlns=http://www.w3.org/2000/svg><path d="M14.05 3.49c.28.3.27.77-.04 1.06l-7.93 7.47A.85.85 0 014.9 12L2.22 9.28a.75.75 0 111.06-1.06l2.24 2.27 7.47-7.04a.75.75 0 011.06.04z" fill=currentColor></path></svg>`
@@ -10250,7 +10264,7 @@ __decorateClass$n([
10250
10264
  observable
10251
10265
  ], Menu.prototype, "primaryAction", 2);
10252
10266
 
10253
- const styles$i = css`${display("inline-block")} ::slotted([slot='trigger']){anchor-name:--menu-trigger}::slotted([popover]){margin:0;max-height:var(--menu-max-height,auto);position-anchor:--menu-trigger;inset:unset;inset-block-start:anchor(end);inset-inline-start:anchor(start);position-try-fallbacks:flip-block;position:fixed;z-index:1}:host([split]) ::slotted([popover]){inset-inline-start:auto;inset-inline-end:anchor(end)}::slotted([popover]:not(:popover-open)){display:none}:host([split]){display:inline-flex}:host([split]) ::slotted([slot='primary-action']){border-inline-end:${strokeWidthThin} solid ${colorNeutralStroke1};border-start-end-radius:0;border-end-end-radius:0}:host([split]) ::slotted([slot='primary-action']:focus-visible){z-index:1}:host([split]) ::slotted([slot='primary-action'][appearance='primary']){border-inline-end:${strokeWidthThin} solid white}:host([split]) ::slotted([slot='trigger']){border-inline-start:0;border-start-start-radius:0;border-end-start-radius:0}`;
10267
+ const styles$i = css`${display("inline-block")} ::slotted([slot='trigger']){anchor-name:--menu-trigger}::slotted([popover]){margin:0;max-height:var(--menu-max-height,auto);position-anchor:--menu-trigger;inset:unset;inset-block-start:anchor(outside);inset-inline-start:anchor(self-start);position-try-fallbacks:flip-block,flip-inline,flip-block flip-inline;position:fixed;z-index:1}:host([split]) ::slotted([popover]){inset-inline-start:unset;inset-inline-end:anchor(self-end)}::slotted([popover]:not(:popover-open)){display:none}:host([split]){display:inline-flex}:host([split]) ::slotted([slot='primary-action']){border-inline-end:${strokeWidthThin} solid ${colorNeutralStroke1};border-start-end-radius:0;border-end-end-radius:0}:host([split]) ::slotted([slot='primary-action']:focus-visible){z-index:1}:host([split]) ::slotted([slot='primary-action'][appearance='primary']){border-inline-end:${strokeWidthThin} solid white}:host([split]) ::slotted([slot='trigger']){border-inline-start:0;border-start-start-radius:0;border-end-start-radius:0}`;
10254
10268
 
10255
10269
  function menuTemplate() {
10256
10270
  return html`<template @keydown=${(x, c) => x.menuKeydownHandler(c.event)}><slot name=primary-action ${ref("primaryAction")}></slot><slot name=trigger ${slotted({ property: "slottedTriggers", filter: elements() })}></slot><slot ${slotted({ property: "slottedMenuList", filter: elements() })}></slot></template>`;
@@ -11926,6 +11940,7 @@ class Slider extends FASTElement {
11926
11940
  notifier.subscribe(this, "min");
11927
11941
  notifier.subscribe(this, "step");
11928
11942
  });
11943
+ maybeSetAutoFocus(this);
11929
11944
  }
11930
11945
  /**
11931
11946
  * @internal
@@ -12251,6 +12266,7 @@ class Tab extends FASTElement {
12251
12266
  }
12252
12267
  this.styles = css`:host{--textContent:'${this.textContent}'}`;
12253
12268
  this.$fastController.addStyles(this.styles);
12269
+ maybeSetAutoFocus(this);
12254
12270
  }
12255
12271
  setDisabledSideEffect(disabled) {
12256
12272
  if (disabled) {
@@ -12734,6 +12750,7 @@ class BaseTextArea extends FASTElement {
12734
12750
  this.setValidity();
12735
12751
  this.preConnectControlEl = null;
12736
12752
  this.maybeCreateAutoSizerEl();
12753
+ maybeSetAutoFocus(this);
12737
12754
  });
12738
12755
  }
12739
12756
  /**
@@ -13267,21 +13284,9 @@ class BaseTextInput extends FASTElement {
13267
13284
  }
13268
13285
  connectedCallback() {
13269
13286
  super.connectedCallback();
13270
- this.tabIndex = Number(this.getAttribute("tabindex") ?? 0) < 0 ? -1 : 0;
13271
13287
  this.setFormValue(this.value);
13272
13288
  this.setValidity();
13273
- }
13274
- /**
13275
- * Focuses the inner control when the component is focused.
13276
- *
13277
- * @param e - the event object
13278
- * @public
13279
- */
13280
- focusinHandler(e) {
13281
- if (e.target === this) {
13282
- this.control?.focus();
13283
- }
13284
- return true;
13289
+ maybeSetAutoFocus(this);
13285
13290
  }
13286
13291
  /**
13287
13292
  * Resets the value to its initial value when the form is reset.
@@ -13504,7 +13509,7 @@ applyMixins(TextInput, StartEnd);
13504
13509
  const styles$5 = css`${display("block")} :host{font-family:${fontFamilyBase};font-size:${fontSizeBase300};font-weight:${fontWeightRegular};line-height:${lineHeightBase300};max-width:400px}.label{display:flex;color:${colorNeutralForeground1};padding-bottom:${spacingVerticalXS};flex-shrink:0;padding-inline-end:${spacingHorizontalXS}}.label[hidden],:host(:empty) .label{display:none}.root{align-items:center;background-color:${colorNeutralBackground1};border:${strokeWidthThin} solid ${colorNeutralStroke1};border-bottom-color:${colorNeutralStrokeAccessible};border-radius:${borderRadiusMedium};box-sizing:border-box;height:32px;display:inline-flex;flex-direction:row;gap:${spacingHorizontalXXS};padding:0 ${spacingHorizontalMNudge};position:relative;width:100%}:has(.control:user-invalid){border-color:${colorPaletteRedBorder2}}.root::after{box-sizing:border-box;content:'';position:absolute;left:-1px;bottom:0px;right:-1px;height:max(2px,${borderRadiusMedium});border-radius:0 0 ${borderRadiusMedium} ${borderRadiusMedium};border-bottom:2px solid ${colorCompoundBrandStroke};clip-path:inset(calc(100% - 2px) 1px 0px);transform:scaleX(0);transition-property:transform;transition-duration:${durationUltraFast};transition-delay:${curveAccelerateMid}}.control{width:100%;height:100%;box-sizing:border-box;color:${colorNeutralForeground1};border-radius:${borderRadiusMedium};background:${colorTransparentBackground};font-family:${fontFamilyBase};font-weight:${fontWeightRegular};font-size:${fontSizeBase300};border:none;vertical-align:center}.control:focus-visible{outline:0;border:0}.control::placeholder{color:${colorNeutralForeground4}}:host ::slotted([slot='start']),:host ::slotted([slot='end']){display:flex;align-items:center;justify-content:center;color:${colorNeutralForeground3};font-size:${fontSizeBase500}}:host ::slotted([slot='start']){padding-right:${spacingHorizontalXXS}}:host ::slotted([slot='end']){padding-left:${spacingHorizontalXXS};gap:${spacingHorizontalXS}}:host(:hover) .root{border-color:${colorNeutralStroke1Hover};border-bottom-color:${colorNeutralStrokeAccessibleHover}}:host(:active) .root{border-color:${colorNeutralStroke1Pressed}}:host(:focus-within) .root{outline:transparent solid 2px;border-bottom:0}:host(:focus-within) .root::after{transform:scaleX(1);transition-property:transform;transition-duration:${durationNormal};transition-delay:${curveDecelerateMid}}:host(:focus-within:active) .root:after{border-bottom-color:${colorCompoundBrandStrokePressed}}:host([appearance='outline']:focus-within) .root{border:${strokeWidthThin} solid ${colorNeutralStroke1}}:host(:focus-within) .control{color:${colorNeutralForeground1}}:host([disabled]) .root{background:${colorTransparentBackground};border:${strokeWidthThin} solid ${colorNeutralStrokeDisabled}}:host([disabled]) .control::placeholder,:host([disabled]) ::slotted([slot='start']),:host([disabled]) ::slotted([slot='end']){color:${colorNeutralForegroundDisabled}}::selection{color:${colorNeutralForegroundInverted};background-color:${colorNeutralBackgroundInverted}}:host([control-size='small']) .control{font-size:${fontSizeBase200};font-weight:${fontWeightRegular};line-height:${lineHeightBase200}}:host([control-size='small']) .root{height:24px;gap:${spacingHorizontalXXS};padding:0 ${spacingHorizontalSNudge}}:host([control-size='small']) ::slotted([slot='start']),:host([control-size='small']) ::slotted([slot='end']){font-size:${fontSizeBase400}}:host([control-size='large']) .control{font-size:${fontSizeBase400};font-weight:${fontWeightRegular};line-height:${lineHeightBase400}}:host([control-size='large']) .root{height:40px;gap:${spacingHorizontalS};padding:0 ${spacingHorizontalM}}:host([control-size='large']) ::slotted([slot='start']),:host([control-size='large']) ::slotted([slot='end']){font-size:${fontSizeBase600}}:host([appearance='underline']) .root{background:${colorTransparentBackground};border:0;border-radius:0;border-bottom:${strokeWidthThin} solid ${colorNeutralStrokeAccessible}}:host([appearance='underline']:hover) .root{border-bottom-color:${colorNeutralStrokeAccessibleHover}}:host([appearance='underline']:active) .root{border-bottom-color:${colorNeutralStrokeAccessiblePressed}}:host([appearance='underline']:focus-within) .root{border:0;border-bottom-color:${colorNeutralStrokeAccessiblePressed}}:host([appearance='underline'][disabled]) .root{border-bottom-color:${colorNeutralStrokeDisabled}}:host([appearance='filled-lighter']) .root,:host([appearance='filled-darker']) .root{border:${strokeWidthThin} solid ${colorTransparentStroke};box-shadow:${shadow2}}:host([appearance='filled-lighter']) .root{background:${colorNeutralBackground1}}:host([appearance='filled-darker']) .root{background:${colorNeutralBackground3}}:host([appearance='filled-lighter']:hover) .root,:host([appearance='filled-darker']:hover) .root{border-color:${colorTransparentStrokeInteractive}}:host([appearance='filled-lighter']:active) .root,:host([appearance='filled-darker']:active) .root{border-color:${colorTransparentStrokeInteractive};background:${colorNeutralBackground3}}`;
13505
13510
 
13506
13511
  function textInputTemplate(options = {}) {
13507
- return html`<template @focusin=${(x, c) => x.focusinHandler(c.event)} @keydown=${(x, c) => x.keydownHandler(c.event)}><label part=label for=control class=label ${ref("controlLabel")}><slot ${slotted("defaultSlottedNodes")}></slot></label><div class=root part=root>${startSlotTemplate(options)} <input class=control part=control id=control @change=${(x, c) => x.changeHandler(c.event)} @input=${(x, c) => x.inputHandler(c.event)} autocomplete=${(x) => x.autocomplete} ?disabled=${(x) => x.disabled} list=${(x) => x.list} maxlength=${(x) => x.maxlength} minlength=${(x) => x.minlength} ?multiple=${(x) => x.multiple} name=${(x) => x.name} pattern=${(x) => x.pattern} placeholder=${(x) => x.placeholder} ?readonly=${(x) => x.readOnly} ?required=${(x) => x.required} size=${(x) => x.size} spellcheck=${(x) => x.spellcheck} type=${(x) => x.type} value=${(x) => x.value} ${ref("control")}> ${endSlotTemplate(options)}</div></template>`;
13512
+ return html`<template @keydown=${(x, c) => x.keydownHandler(c.event)}><label part=label for=control class=label ${ref("controlLabel")}><slot ${slotted("defaultSlottedNodes")}></slot></label><div class=root part=root>${startSlotTemplate(options)} <input class=control part=control id=control @change=${(x, c) => x.changeHandler(c.event)} @input=${(x, c) => x.inputHandler(c.event)} autocomplete=${(x) => x.autocomplete} ?disabled=${(x) => x.disabled} list=${(x) => x.list} maxlength=${(x) => x.maxlength} minlength=${(x) => x.minlength} ?multiple=${(x) => x.multiple} name=${(x) => x.name} pattern=${(x) => x.pattern} placeholder=${(x) => x.placeholder} ?readonly=${(x) => x.readOnly} ?required=${(x) => x.required} size=${(x) => x.size} spellcheck=${(x) => x.spellcheck} type=${(x) => x.type} value=${(x) => x.value} ${ref("control")}> ${endSlotTemplate(options)}</div></template>`;
13508
13513
  }
13509
13514
  const template$5 = textInputTemplate();
13510
13515
 
@@ -14206,6 +14211,7 @@ class BaseTreeItem extends FASTElement {
14206
14211
  if (isTreeItem(this.parentElement)) {
14207
14212
  this.slot || (this.slot = "item");
14208
14213
  }
14214
+ maybeSetAutoFocus(this);
14209
14215
  }
14210
14216
  /**
14211
14217
  * Handles changes to the expanded attribute