@fluentui/web-components 3.1.2 → 3.1.4
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.
- package/CHANGELOG.md +29 -2
- package/custom-elements.json +45 -55
- package/dist/esm/divider/divider.styles.css +21 -13
- package/dist/esm/divider/divider.styles.js +21 -13
- package/dist/esm/divider/divider.styles.js.map +1 -1
- package/dist/esm/dropdown/dropdown.base.d.ts +7 -9
- package/dist/esm/dropdown/dropdown.base.js +8 -13
- package/dist/esm/dropdown/dropdown.base.js.map +1 -1
- package/dist/esm/dropdown/dropdown.styles.css +37 -6
- package/dist/esm/dropdown/dropdown.styles.d.ts +4 -0
- package/dist/esm/dropdown/dropdown.styles.js +41 -6
- package/dist/esm/dropdown/dropdown.styles.js.map +1 -1
- package/dist/esm/dropdown/dropdown.template.d.ts +2 -0
- package/dist/esm/dropdown/dropdown.template.js +4 -2
- package/dist/esm/dropdown/dropdown.template.js.map +1 -1
- package/dist/esm/field/field.base.d.ts +1 -0
- package/dist/esm/field/field.base.js +32 -9
- package/dist/esm/field/field.base.js.map +1 -1
- package/dist/esm/field/field.options.d.ts +4 -0
- package/dist/esm/field/field.options.js.map +1 -1
- package/dist/esm/menu-list/menu-list.base.js +19 -1
- package/dist/esm/menu-list/menu-list.base.js.map +1 -1
- package/dist/esm/menu-list/menu-list.styles.css +10 -10
- package/dist/esm/menu-list/menu-list.styles.js +10 -10
- package/dist/esm/message-bar/message-bar.styles.css +0 -1
- package/dist/esm/switch/switch.styles.css +2 -2
- package/dist/esm/switch/switch.styles.js +2 -2
- package/dist/esm/text-input/text-input.base.d.ts +18 -0
- package/dist/esm/text-input/text-input.base.js +59 -5
- package/dist/esm/text-input/text-input.base.js.map +1 -1
- package/dist/esm/textarea/textarea.styles.css +1 -0
- package/dist/esm/textarea/textarea.styles.js +1 -0
- package/dist/esm/textarea/textarea.styles.js.map +1 -1
- package/dist/esm/tooltip/tooltip.options.d.ts +13 -13
- package/dist/esm/tooltip/tooltip.options.js +13 -13
- package/dist/esm/tooltip/tooltip.options.js.map +1 -1
- package/dist/esm/tooltip/tooltip.styles.js +12 -13
- package/dist/esm/tooltip/tooltip.styles.js.map +1 -1
- package/dist/esm/utils/get-initials.js +1 -2
- package/dist/esm/utils/get-initials.js.map +1 -1
- package/dist/web-components-all.js +109 -40
- package/dist/web-components-all.min.js +13 -13
- package/dist/web-components.d.ts +49 -22
- package/dist/web-components.js +97 -42
- package/dist/web-components.min.js +13 -13
- package/package.json +1 -1
|
@@ -5854,7 +5854,7 @@ const definition$C = {
|
|
|
5854
5854
|
|
|
5855
5855
|
const UNWANTED_ENCLOSURES_REGEX = /[\(\[\{][^\)\]\}]*[\)\]\}]/g;
|
|
5856
5856
|
const UNWANTED_CHARS_REGEX = /[\0-\u001F\!-/:-@\[-`\{-\u00BF\u0250-\u036F\uD800-\uFFFF]/g;
|
|
5857
|
-
const PHONENUMBER_REGEX =
|
|
5857
|
+
const PHONENUMBER_REGEX = /^(?:\d[\d\s]*\d|\d[\d\s]*(?:ext|x)\s*\d+)$/i;
|
|
5858
5858
|
const MULTIPLE_WHITESPACES_REGEX = /\s+/g;
|
|
5859
5859
|
const UNSUPPORTED_TEXT_REGEX = /[\u0600-\u06FF\u0750-\u077F\u08A0-\u08FF\u1100-\u11FF\u3130-\u318F\uA960-\uA97F\uAC00-\uD7AF\uD7B0-\uD7FF\u3040-\u309F\u30A0-\u30FF\u3400-\u4DBF\u4E00-\u9FFF\uF900-\uFAFF]|[\uD840-\uD869][\uDC00-\uDED6]/;
|
|
5860
5860
|
function getInitialsLatin(displayName, isRtl, firstInitialOnly) {
|
|
@@ -7409,7 +7409,7 @@ const DividerAppearance = {
|
|
|
7409
7409
|
};
|
|
7410
7410
|
const tagName$u = `${FluentDesignSystem.prefix}-divider`;
|
|
7411
7411
|
|
|
7412
|
-
const styles$u = css`${display("flex")} :host{contain:content}:host::after,:host::before{align-self:center;background:${colorNeutralStroke2};box-sizing:border-box;content:'';display:flex;flex-grow:1;height:${strokeWidthThin}}:host([inset]){padding:0 12px}:host ::slotted(*){color:${colorNeutralForeground2};font-family:${fontFamilyBase};font-size:${fontSizeBase200};font-weight:${fontWeightRegular};margin:0;padding:0 12px}:host([align-content='start'])::before,:host([align-content='end'])::after{flex-basis:12px;flex-grow:0;flex-shrink:0}:host([orientation='vertical']){align-items:center;flex-direction:column;height:100
|
|
7412
|
+
const styles$u = css`${display("flex")} :host{--_vertical-min-height:10px;contain:content}:host::after,:host::before{align-self:center;background:${colorNeutralStroke2};box-sizing:border-box;content:'';display:flex;flex-grow:1;height:${strokeWidthThin}}:host([inset]){padding:0 12px}:host ::slotted(*){color:${colorNeutralForeground2};font-family:${fontFamilyBase};font-size:${fontSizeBase200};font-weight:${fontWeightRegular};margin:0;padding:0 12px}:host([align-content='start'])::before,:host([align-content='end'])::after{flex-basis:12px;flex-grow:0;flex-shrink:0}:host([orientation='vertical']){align-items:center;flex-direction:column;height:100%}:host([orientation='vertical'][inset])::before{margin-top:12px}:host([orientation='vertical'][inset])::after{margin-bottom:12px}:host([orientation='vertical'])::before,:host([orientation='vertical'])::after{width:${strokeWidthThin};min-height:var(--_vertical-min-height);height:100%}@supports not selector(:host(:has(*))){@scope{:scope:has(*){--_vertical-min-height:20px}}}:host(:has(*)){--_vertical-min-height:20px}:host([orientation='vertical']) ::slotted(*){display:flex;flex-direction:column;padding:12px 0;line-height:20px}:host([orientation='vertical'][align-content='start'])::before{min-height:8px}:host([orientation='vertical'][align-content='end'])::after{min-height:8px}:host([appearance='strong'])::before,:host([appearance='strong'])::after{background:${colorNeutralStroke1}}:host([appearance='strong']) ::slotted(*){color:${colorNeutralForeground1}}:host([appearance='brand'])::before,:host([appearance='brand'])::after{background:${colorBrandStroke1}}:host([appearance='brand']) ::slotted(*){color:${colorBrandForeground1}}:host([appearance='subtle'])::before,:host([appearance='subtle'])::after{background:${colorNeutralStroke3}}:host([appearance='subtle']) ::slotted(*){color:${colorNeutralForeground3}}@media (forced-colors:active){:host([appearance='strong'])::before,:host([appearance='strong'])::after,:host([appearance='brand'])::before,:host([appearance='brand'])::after,:host([appearance='subtle'])::before,:host([appearance='subtle'])::after,:host::after,:host::before{background:WindowText;color:WindowText}}`;
|
|
7413
7413
|
|
|
7414
7414
|
function dividerTemplate() {
|
|
7415
7415
|
return html`<slot></slot>`;
|
|
@@ -7776,10 +7776,10 @@ const DropdownType = {
|
|
|
7776
7776
|
};
|
|
7777
7777
|
const tagName$r = `${FluentDesignSystem.prefix}-dropdown`;
|
|
7778
7778
|
|
|
7779
|
-
const styles$r = css`${display("inline-flex")} :host{box-sizing:border-box;color:${colorNeutralForeground1};cursor:pointer}:host(${placeholderShownState}){color
|
|
7779
|
+
const styles$r = css`${display("inline-flex")} :host{--_indicator-size:20px;--_placeholder-color:${colorNeutralForeground4};--_initial-display:attr(initial-display raw-string,attr(placeholder raw-string,none));box-sizing:border-box;color:${colorNeutralForeground1};cursor:pointer}:host(${placeholderShownState}){color:var(--_placeholder-color)}.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-grid;grid-template-columns:1fr var(--_indicator-size);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}}:host(:not(:has([slot='control']))) slot[name='control']::before{content:var(--_initial-display)}@scope{:scope:not(:has([slot='control'])) slot[name='control']::before{content:var(--_initial-display)}}:host(:is(:not([value]),[value=''])) slot[name='control']::before{color:var(--_placeholder-color)}::slotted(:is(input,button)){all:unset}slot[name='control']::before,::slotted(:is(input,button)){grid-area:1/1}::slotted(button){cursor:pointer}::slotted(input){cursor:text;min-width:0;width:100%}::slotted(input)::placeholder{color:var(--_placeholder-color)}:where(slot[name='indicator']>*,::slotted([slot='indicator'])){all:unset;align-items:center;appearance:none;aspect-ratio:1;color:${colorNeutralForeground3};display:inline-flex;grid-area:1/2;justify-content:center;width:var(--_indicator-size)}:host([size='small']) :where(slot[name='indicator']>*,::slotted([slot='indicator'])){--_indicator-size:16px}:host([size='large']) :where(slot[name='indicator']>*,::slotted([slot='indicator'])){--_indicator-size: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(${nativeDisabledState}),:host(${nativeDisabledState}) ::slotted(:where(button,input)){cursor:not-allowed}:host(${nativeDisabledState}) .control::before,:host(${nativeDisabledState}) .control::after{content:none}:host(${nativeDisabledState}) .control:is(*,:active,:hover),:host(${nativeDisabledState}) :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(${nativeDisabledState}) .control{border-color:GrayText}:host(${nativeDisabledState}) :where(slot[name='indicator']>*,::slotted([slot='indicator'])){color:GrayText}}`;
|
|
7780
7780
|
|
|
7781
7781
|
const dropdownIndicatorTemplate = html`<svg class=chevron-down-20-regular aria-hidden=true slot=indicator viewBox="0 0 20 20" ${ref("indicator")}><path d="M15.85 7.65a.5.5 0 0 1 0 .7l-5.46 5.49a.55.55 0 0 1-.78 0L4.15 8.35a.5.5 0 1 1 .7-.7L10 12.8l5.15-5.16a.5.5 0 0 1 .7 0" fill=currentColor /></svg>`;
|
|
7782
|
-
const dropdownInputTemplate = html`<input @input=${(x, c) => x.inputHandler(c.event)} @change=${(x, c) => x.changeHandler(c.event)} aria-activedescendant=${(x) => x.activeDescendant} aria-controls=${(x) => x.listbox?.id ?? null} aria-labelledby=${(x) => x.ariaLabelledBy} aria-expanded=${(x) => x.open} aria-haspopup=listbox placeholder=${(x) => x.placeholder} role=combobox ?disabled=${(x) => x.disabled}
|
|
7782
|
+
const dropdownInputTemplate = html`<input @input=${(x, c) => x.inputHandler(c.event)} @change=${(x, c) => x.changeHandler(c.event)} aria-activedescendant=${(x) => x.activeDescendant} aria-controls=${(x) => x.listbox?.id ?? null} aria-labelledby=${(x) => x.ariaLabelledBy} aria-expanded=${(x) => x.open} aria-haspopup=listbox size=1 placeholder=${(x) => x.placeholder} role=combobox ?disabled=${(x) => x.disabled} value=${(x) => x.initialValue} slot=control ${ref("control")}>`;
|
|
7783
7783
|
const dropdownButtonTemplate = html`<button aria-activedescendant=${(x) => x.activeDescendant} aria-controls=${(x) => x.listbox?.id ?? null} aria-expanded=${(x) => x.open} aria-haspopup=listbox role=combobox ?disabled=${(x) => x.disabled} type=button slot=control ${ref("control")}>${(x) => x.displayValue}</button>`;
|
|
7784
7784
|
function dropdownTemplate(options = {}) {
|
|
7785
7785
|
return html`<template @click=${(x, c) => x.clickHandler(c.event)} @focusout=${(x, c) => x.focusoutHandler(c.event)} @keydown=${(x, c) => x.keydownHandler(c.event)} @mousedown=${(x, c) => x.mousedownHandler(c.event)}><div class=control><slot name=control ${ref("controlSlot")}></slot><slot name=indicator ${ref("indicatorSlot")}>${staticallyCompose(options.indicator)}</slot></div><slot @slotchange=${(x, c) => x.slotchangeHandler(c.event)}></slot></template>`;
|
|
@@ -7846,7 +7846,6 @@ const _BaseDropdown = class _BaseDropdown extends FASTElement {
|
|
|
7846
7846
|
this.id = uniqueId("dropdown-");
|
|
7847
7847
|
this.required = false;
|
|
7848
7848
|
this.type = DropdownType.dropdown;
|
|
7849
|
-
this.valueAttribute = "";
|
|
7850
7849
|
/**
|
|
7851
7850
|
* Repositions the listbox to align with the control element. Used when the browser does not support CSS anchor
|
|
7852
7851
|
* positioning.
|
|
@@ -7996,7 +7995,7 @@ const _BaseDropdown = class _BaseDropdown extends FASTElement {
|
|
|
7996
7995
|
this.setValidity();
|
|
7997
7996
|
});
|
|
7998
7997
|
if (AnchorPositioningCSSSupported) {
|
|
7999
|
-
const anchorName = uniqueId("--dropdown-anchor-");
|
|
7998
|
+
const anchorName = this.style.getPropertyValue("anchor-name") || uniqueId("--dropdown-anchor-");
|
|
8000
7999
|
this.style.setProperty("anchor-name", anchorName);
|
|
8001
8000
|
this.listbox.style.setProperty("position-anchor", anchorName);
|
|
8002
8001
|
}
|
|
@@ -8610,6 +8609,13 @@ const _BaseDropdown = class _BaseDropdown extends FASTElement {
|
|
|
8610
8609
|
}
|
|
8611
8610
|
}
|
|
8612
8611
|
};
|
|
8612
|
+
/**
|
|
8613
|
+
* The element identity. This static property should NOT be overridden by subclasses. It’s designed to provide an
|
|
8614
|
+
* unambiguous name for the custom element and its subclass custom elements, regardless of their tag names.
|
|
8615
|
+
* @readonly
|
|
8616
|
+
* @internal
|
|
8617
|
+
*/
|
|
8618
|
+
_BaseDropdown.elementIdentity = "dropdown";
|
|
8613
8619
|
/**
|
|
8614
8620
|
* The form-associated flag.
|
|
8615
8621
|
* @see {@link https://html.spec.whatwg.org/multipage/custom-elements.html#custom-elements-face-example | Form-associated custom elements}
|
|
@@ -8668,9 +8674,6 @@ __decorateClass$x([
|
|
|
8668
8674
|
__decorateClass$x([
|
|
8669
8675
|
attr
|
|
8670
8676
|
], _BaseDropdown.prototype, "type", 2);
|
|
8671
|
-
__decorateClass$x([
|
|
8672
|
-
attr({ attribute: "value" })
|
|
8673
|
-
], _BaseDropdown.prototype, "valueAttribute", 2);
|
|
8674
8677
|
let BaseDropdown = _BaseDropdown;
|
|
8675
8678
|
|
|
8676
8679
|
var __defProp$w = Object.defineProperty;
|
|
@@ -8888,17 +8891,40 @@ class BaseField extends FASTElement {
|
|
|
8888
8891
|
*
|
|
8889
8892
|
* @internal
|
|
8890
8893
|
*/
|
|
8891
|
-
setLabelProperties() {
|
|
8892
|
-
|
|
8893
|
-
|
|
8894
|
-
|
|
8895
|
-
|
|
8896
|
-
|
|
8897
|
-
|
|
8898
|
-
|
|
8894
|
+
async setLabelProperties() {
|
|
8895
|
+
const input = await this.getLabelableInput();
|
|
8896
|
+
if (!input) {
|
|
8897
|
+
return;
|
|
8898
|
+
}
|
|
8899
|
+
input.id || (input.id = uniqueId("input"));
|
|
8900
|
+
this.labelSlot?.forEach((label) => {
|
|
8901
|
+
if (label instanceof HTMLLabelElement) {
|
|
8902
|
+
label.htmlFor || (label.htmlFor = input.id);
|
|
8903
|
+
label.id || (label.id = `${input.id}--label`);
|
|
8904
|
+
input.setAttribute("aria-labelledby", label.id);
|
|
8905
|
+
}
|
|
8906
|
+
});
|
|
8907
|
+
}
|
|
8908
|
+
getLabelableInput() {
|
|
8909
|
+
return new Promise((resolve) => {
|
|
8910
|
+
if (!this.input) {
|
|
8911
|
+
return resolve(null);
|
|
8912
|
+
}
|
|
8913
|
+
if (this.input.constructor.elementIdentity !== "dropdown") {
|
|
8914
|
+
return resolve(this.input);
|
|
8915
|
+
}
|
|
8916
|
+
if (this.input.control) {
|
|
8917
|
+
return resolve(this.input.control);
|
|
8918
|
+
}
|
|
8919
|
+
new MutationObserver((_, observer) => {
|
|
8920
|
+
if (this.input.control) {
|
|
8921
|
+
resolve(this.input.control);
|
|
8922
|
+
observer.disconnect();
|
|
8899
8923
|
}
|
|
8924
|
+
}).observe(this.input, {
|
|
8925
|
+
childList: true
|
|
8900
8926
|
});
|
|
8901
|
-
}
|
|
8927
|
+
});
|
|
8902
8928
|
}
|
|
8903
8929
|
/**
|
|
8904
8930
|
* Toggles the field's states based on the slotted input.
|
|
@@ -9626,7 +9652,7 @@ MenuItem.define(definition$k);
|
|
|
9626
9652
|
|
|
9627
9653
|
const tagName$i = `${FluentDesignSystem.prefix}-menu-list`;
|
|
9628
9654
|
|
|
9629
|
-
const styles$j = css`${display("grid")} :host{--_col-indicator-width:0px;--_col-start-width:0px;--_col-content-width:1fr;--_col-end-width:0px;--_col-submenu-width:0px;contain:
|
|
9655
|
+
const styles$j = css`${display("grid")} :host{--_col-indicator-width:0px;--_col-start-width:0px;--_col-content-width:1fr;--_col-end-width:0px;--_col-submenu-width:0px;contain:layout style;block-size:auto;max-inline-size:300px;min-inline-size:160px;inline-size:auto;background-color:${colorNeutralBackground1};border:1px solid ${colorTransparentStroke};border-radius:${borderRadiusMedium};box-shadow:${shadow16};grid-template-columns:10px var(--_col-indicator-width) var(--_col-start-width) var(--_col-content-width) var(--_col-end-width) var(--_col-submenu-width) 10px;gap:2px 0;padding:4px}::slotted(*){grid-column:1/-1}:host(:has(>[role='menuitemradio'],>[role='menuitemcheckbox'])){--_col-indicator-width:24px}:host(:has(>*>[slot='start'])){--_col-start-width:24px}:host(:has(>*>[slot='end'])){--_col-end-width:24px}:host(:has(>*>[slot='submenu'])){--_col-submenu-width:24px}@scope{:scope:has(>[role='menuitemradio'],>[role='menuitemcheckbox']){--_col-indicator-width:24px}:scope:has(>*>[slot='start']){--_col-start-width:24px}:scope:has(>*>[slot='end']){--_col-end-width:24px}:scope:has(>*>[slot='submenu']){--_col-submenu-width:24px}}`;
|
|
9630
9656
|
|
|
9631
9657
|
function menuTemplate$1() {
|
|
9632
9658
|
return html`<template focusgroup=menu><slot ${slotted("items")}></slot></template>`;
|
|
@@ -10203,7 +10229,9 @@ const _BaseMenuList = class _BaseMenuList extends FASTElement {
|
|
|
10203
10229
|
* @public
|
|
10204
10230
|
*/
|
|
10205
10231
|
focus() {
|
|
10206
|
-
|
|
10232
|
+
Updates.enqueue(() => {
|
|
10233
|
+
this.menuItems?.find((item) => !item.disabled)?.focus();
|
|
10234
|
+
});
|
|
10207
10235
|
}
|
|
10208
10236
|
setItems() {
|
|
10209
10237
|
const children = Array.from(this.children);
|
|
@@ -12585,7 +12613,7 @@ const SwitchLabelPosition = {
|
|
|
12585
12613
|
};
|
|
12586
12614
|
const tagName$9 = `${FluentDesignSystem.prefix}-switch`;
|
|
12587
12615
|
|
|
12588
|
-
const styles$9 = css`${display("inline-flex")} :host{box-sizing:border-box;align-items:center;flex-direction:row;outline:none;user-select:none;contain:content;padding:0 ${spacingHorizontalXXS};width:40px;height:20px;background-color:${colorTransparentBackground};border:1px solid ${colorNeutralStrokeAccessible};border-radius:${borderRadiusCircular}}:host(:enabled){cursor:pointer}:host(:hover){background:none;border-color:${colorNeutralStrokeAccessibleHover}}:host(:active){border-color:${colorNeutralStrokeAccessiblePressed}}:host(${nativeDisabledState}),:host([readonly]){border:1px solid ${colorNeutralStrokeDisabled};background-color:none;pointer:default}:host(${checkedState}){background:${colorCompoundBrandBackground};border-color:${colorCompoundBrandBackground}}:host(${checkedState}:hover){background:${colorCompoundBrandBackgroundHover};border-color:${colorCompoundBrandBackgroundHover}}:host(${checkedState}:active){background:${colorCompoundBrandBackgroundPressed};border-color:${colorCompoundBrandBackgroundPressed}}:host(${checkedState}${nativeDisabledState}){background:${colorNeutralBackgroundDisabled};border-color:${colorNeutralStrokeDisabled}}.checked-indicator{height:14px;width:14px;border-radius:50%;margin-inline-start:0;background-color:${colorNeutralForeground3};transition-duration:${durationNormal};transition-timing-function:${curveEasyEase};transition-property:margin-inline-start}:host(${checkedState}) .checked-indicator{background-color:${colorNeutralForegroundInverted};margin-inline-start:calc(100% - 14px)}:host(${checkedState}:hover) .checked-indicator{background:${colorNeutralForegroundInvertedHover}}:host(${checkedState}:active) .checked-indicator{background:${colorNeutralForegroundInvertedPressed}}:host(:hover) .checked-indicator{background-color:${colorNeutralForeground3Hover}}:host(:active) .checked-indicator{background-color:${colorNeutralForeground3Pressed}}:host(${nativeDisabledState}) .checked-indicator,:host([readonly]) .checked-indicator{background:${colorNeutralForegroundDisabled}}:host(${checkedState}${nativeDisabledState}) .checked-indicator{background:${colorNeutralForegroundDisabled}}:host(:focus-visible){outline:none}:host(:not([slot='input']):focus-visible){border-color:${colorTransparentStroke};outline:${strokeWidthThick} solid ${colorTransparentStroke};outline-offset:1px;box-shadow:${shadow4},0 0 0 2px ${colorStrokeFocus2}}@media (forced-colors:active){:host{border-color:InactiveBorder}:host(${checkedState}),:host(${checkedState}:active),:host(${checkedState}:hover){background:Highlight;border-color:Highlight}.checked-indicator,:host(:hover) .checked-indicator,:host(:active) .checked-indicator{background-color:
|
|
12616
|
+
const styles$9 = css`${display("inline-flex")} :host{box-sizing:border-box;align-items:center;flex-direction:row;outline:none;user-select:none;contain:content;padding:0 ${spacingHorizontalXXS};width:40px;height:20px;background-color:${colorTransparentBackground};border:1px solid ${colorNeutralStrokeAccessible};border-radius:${borderRadiusCircular}}:host(:enabled){cursor:pointer}:host(:hover){background:none;border-color:${colorNeutralStrokeAccessibleHover}}:host(:active){border-color:${colorNeutralStrokeAccessiblePressed}}:host(${nativeDisabledState}),:host([readonly]){border:1px solid ${colorNeutralStrokeDisabled};background-color:none;pointer:default}:host(${checkedState}){background:${colorCompoundBrandBackground};border-color:${colorCompoundBrandBackground}}:host(${checkedState}:hover){background:${colorCompoundBrandBackgroundHover};border-color:${colorCompoundBrandBackgroundHover}}:host(${checkedState}:active){background:${colorCompoundBrandBackgroundPressed};border-color:${colorCompoundBrandBackgroundPressed}}:host(${checkedState}${nativeDisabledState}){background:${colorNeutralBackgroundDisabled};border-color:${colorNeutralStrokeDisabled}}.checked-indicator{height:14px;width:14px;border-radius:50%;margin-inline-start:0;background-color:${colorNeutralForeground3};transition-duration:${durationNormal};transition-timing-function:${curveEasyEase};transition-property:margin-inline-start}:host(${checkedState}) .checked-indicator{background-color:${colorNeutralForegroundInverted};margin-inline-start:calc(100% - 14px)}:host(${checkedState}:hover) .checked-indicator{background:${colorNeutralForegroundInvertedHover}}:host(${checkedState}:active) .checked-indicator{background:${colorNeutralForegroundInvertedPressed}}:host(:hover) .checked-indicator{background-color:${colorNeutralForeground3Hover}}:host(:active) .checked-indicator{background-color:${colorNeutralForeground3Pressed}}:host(${nativeDisabledState}) .checked-indicator,:host([readonly]) .checked-indicator{background:${colorNeutralForegroundDisabled}}:host(${checkedState}${nativeDisabledState}) .checked-indicator{background:${colorNeutralForegroundDisabled}}:host(:focus-visible){outline:none}:host(:not([slot='input']):focus-visible){border-color:${colorTransparentStroke};outline:${strokeWidthThick} solid ${colorTransparentStroke};outline-offset:1px;box-shadow:${shadow4},0 0 0 2px ${colorStrokeFocus2}}@media (forced-colors:active){:host{border-color:InactiveBorder}:host(${checkedState}),:host(${checkedState}:active),:host(${checkedState}:hover){background:Highlight;border-color:Highlight}.checked-indicator,:host(:hover) .checked-indicator,:host(:active) .checked-indicator{background-color:CanvasText}:host(${checkedState}) .checked-indicator,:host(${checkedState}:hover) .checked-indicator,:host(${checkedState}:active) .checked-indicator{background-color:HighlightText}:host(${nativeDisabledState}) .checked-indicator,:host(${checkedState}${nativeDisabledState}) .checked-indicator{background-color:GrayText}}`;
|
|
12589
12617
|
|
|
12590
12618
|
function switchTemplate(options = {}) {
|
|
12591
12619
|
return html`<template @click=${(x, c) => x.clickHandler(c.event)} @input=${(x, c) => x.inputHandler(c.event)} @keydown=${(x, c) => x.keydownHandler(c.event)} @keyup=${(x, c) => x.keyupHandler(c.event)}><slot name=switch>${staticallyCompose(options.switch)}</slot></template>`;
|
|
@@ -12945,7 +12973,7 @@ const TextAreaResize = {
|
|
|
12945
12973
|
};
|
|
12946
12974
|
const tagName$6 = `${FluentDesignSystem.prefix}-textarea`;
|
|
12947
12975
|
|
|
12948
|
-
const styles$6 = css`${display("inline-block")} :host{--font-size:${fontSizeBase300};--line-height:${lineHeightBase300};--padding-inline:${spacingHorizontalMNudge};--padding-block:${spacingVerticalSNudge};--min-block-size:52px;--block-size:var(--min-block-size);--inline-size:18rem;--border-width:${strokeWidthThin};--control-padding-inline:${spacingHorizontalXXS};--color:${colorNeutralForeground1};--background-color:${colorNeutralBackground1};--border-color:${colorNeutralStroke1};--border-block-end-color:${colorNeutralStrokeAccessible};--placeholder-color:${colorNeutralForeground4};--focus-indicator-color:${colorCompoundBrandStroke};--box-shadow:none;--contain-size:size;--resize:none;color:var(--color);font-family:${fontFamilyBase};font-size:var(--font-size);font-weight:${fontWeightRegular};line-height:var(--line-height);position:relative}:host(:hover){--border-color:${colorNeutralStroke1Hover};--border-block-end-color:${colorNeutralStrokeAccessibleHover}}:host(:active){--border-color:${colorNeutralStroke1Pressed};--border-block-end-color:${colorNeutralStrokeAccessiblePressed}}:host(:focus-within){outline:none}:host([block]:not([hidden])){display:block}:host([size='small']){--font-size:${fontSizeBase200};--line-height:${lineHeightBase200};--min-block-size:40px;--padding-block:${spacingVerticalXS};--padding-inline:${spacingHorizontalSNudge};--control-padding-inline:${spacingHorizontalXXS}}:host([size='large']){--font-size:${fontSizeBase400};--line-height:${lineHeightBase400};--min-block-size:64px;--padding-block:${spacingVerticalS};--padding-inline:${spacingHorizontalM};--control-padding-inline:${spacingHorizontalSNudge}}:host([resize='both']:not(${nativeDisabledState})){--resize:both}:host([resize='horizontal']:not(${nativeDisabledState})){--resize:horizontal}:host([resize='vertical']:not(${nativeDisabledState})){--resize:vertical}:host([auto-resize]){--block-size:auto;--contain-size:inline-size}:host([appearance='filled-darker']){--background-color:${colorNeutralBackground3};--border-color:var(--background-color);--border-block-end-color:var(--border-color)}:host([appearance='filled-lighter']){--border-color:var(--background-color);--border-block-end-color:var(--border-color)}:host([appearance='filled-darker'][display-shadow]),:host([appearance='filled-lighter'][display-shadow]){--box-shadow:${shadow2}}:host(${userInvalidState}){--border-color:${colorPaletteRedBorder2};--border-block-end-color:${colorPaletteRedBorder2}}:host(${nativeDisabledState}){--color:${colorNeutralForegroundDisabled};--background-color:${colorTransparentBackground};--border-color:${colorNeutralStrokeDisabled};--border-block-end-color:var(--border-color);--box-shadow:none;--placeholder-color:${colorNeutralForegroundDisabled};cursor:no-drop;user-select:none}.root{background-color:var(--background-color);border:var(--border-width) solid var(--border-color);border-block-end-color:var(--border-block-end-color);border-radius:${borderRadiusMedium};box-sizing:border-box;box-shadow:var(--box-shadow);contain:paint layout style var(--contain-size);display:grid;grid-template:1fr/1fr;inline-size:var(--inline-size);min-block-size:var(--min-block-size);block-size:var(--block-size);overflow:hidden;padding:var(--padding-block) var(--padding-inline);position:relative;resize:var(--resize)}:host([block]) .root{inline-size:auto}.root::after{border-bottom:2px solid var(--focus-indicator-color);border-radius:0 0 ${borderRadiusMedium} ${borderRadiusMedium};box-sizing:border-box;clip-path:inset(calc(100% - 2px) 1px 0px);content:'';height:max(2px,${borderRadiusMedium});inset:auto -1px 0;position:absolute;transform:scaleX(0);transition-delay:${curveAccelerateMid};transition-duration:${durationUltraFast};transition-property:transform}:host(:focus-within) .root::after{transform:scaleX(1);transition-property:transform;transition-duration:${durationNormal};transition-delay:${curveDecelerateMid}}:host([readonly]) .root::after,:host(${nativeDisabledState}) .root::after{content:none}label{color:var(--color);display:flex;inline-size:fit-content;padding-block-end:${spacingVerticalXS};padding-inline-end:${spacingHorizontalXS}}:host(:empty) label,label[hidden]{display:none}.auto-sizer,.control{box-sizing:border-box;font:inherit;grid-column:1/-1;grid-row:1/-1;letter-space:inherit;padding:0 var(--control-padding-inline)}.auto-sizer{display:none;padding-block-end:2px;pointer-events:none;visibility:hidden;white-space:pre-wrap}:host([auto-resize]) .auto-sizer{display:block}.control{appearance:none;background-color:transparent;border:0;color:inherit;field-sizing:content;max-block-size:100%;outline:0;resize:none;text-align:inherit}.control:disabled{cursor:inherit}.control::placeholder{color:var(--placeholder-color)}::selection{color:${colorNeutralForegroundInverted};background-color:${colorNeutralBackgroundInverted}}@media (forced-colors:active){:host{--border-color:FieldText;--border-block-end-color:FieldText;--focus-indicator-color:Highlight;--placeholder-color:FieldText}:host(:hover),:host(:active),:host(:focus-within){--border-color:Highlight;--border-block-end-color:Highlight}:host(${nativeDisabledState}){--color:GrayText;--border-color:GrayText;--border-block-end-color:GrayText;--placeholder-color:GrayText}}`;
|
|
12976
|
+
const styles$6 = css`${display("inline-block")} :host{--font-size:${fontSizeBase300};--line-height:${lineHeightBase300};--padding-inline:${spacingHorizontalMNudge};--padding-block:${spacingVerticalSNudge};--min-block-size:52px;--block-size:var(--min-block-size);--inline-size:18rem;--border-width:${strokeWidthThin};--control-padding-inline:${spacingHorizontalXXS};--color:${colorNeutralForeground1};--background-color:${colorNeutralBackground1};--border-color:${colorNeutralStroke1};--border-block-end-color:${colorNeutralStrokeAccessible};--placeholder-color:${colorNeutralForeground4};--focus-indicator-color:${colorCompoundBrandStroke};--box-shadow:none;--contain-size:size;--resize:none;color:var(--color);font-family:${fontFamilyBase};font-size:var(--font-size);font-weight:${fontWeightRegular};line-height:var(--line-height);position:relative}:host(:hover){--border-color:${colorNeutralStroke1Hover};--border-block-end-color:${colorNeutralStrokeAccessibleHover}}:host(:active){--border-color:${colorNeutralStroke1Pressed};--border-block-end-color:${colorNeutralStrokeAccessiblePressed}}:host(:focus-within){outline:none}:host([block]:not([hidden])){display:block}:host([size='small']){--font-size:${fontSizeBase200};--line-height:${lineHeightBase200};--min-block-size:40px;--padding-block:${spacingVerticalXS};--padding-inline:${spacingHorizontalSNudge};--control-padding-inline:${spacingHorizontalXXS}}:host([size='large']){--font-size:${fontSizeBase400};--line-height:${lineHeightBase400};--min-block-size:64px;--padding-block:${spacingVerticalS};--padding-inline:${spacingHorizontalM};--control-padding-inline:${spacingHorizontalSNudge}}:host([resize='both']:not(${nativeDisabledState})){--resize:both}:host([resize='horizontal']:not(${nativeDisabledState})){--resize:horizontal}:host([resize='vertical']:not(${nativeDisabledState})){--resize:vertical}:host([auto-resize]){--block-size:auto;--contain-size:inline-size}:host([appearance='filled-darker']){--background-color:${colorNeutralBackground3};--border-color:var(--background-color);--border-block-end-color:var(--border-color)}:host([appearance='filled-lighter']){--border-color:var(--background-color);--border-block-end-color:var(--border-color)}:host([appearance='filled-darker'][display-shadow]),:host([appearance='filled-lighter'][display-shadow]){--box-shadow:${shadow2}}:host(${userInvalidState}){--border-color:${colorPaletteRedBorder2};--border-block-end-color:${colorPaletteRedBorder2}}:host(${nativeDisabledState}){--color:${colorNeutralForegroundDisabled};--background-color:${colorTransparentBackground};--border-color:${colorNeutralStrokeDisabled};--border-block-end-color:var(--border-color);--box-shadow:none;--placeholder-color:${colorNeutralForegroundDisabled};cursor:no-drop;user-select:none}.root{background-color:var(--background-color);border:var(--border-width) solid var(--border-color);border-block-end-color:var(--border-block-end-color);border-radius:${borderRadiusMedium};box-sizing:border-box;box-shadow:var(--box-shadow);contain:paint layout style var(--contain-size);display:grid;grid-template:1fr/1fr;inline-size:var(--inline-size);min-block-size:var(--min-block-size);block-size:var(--block-size);overflow:hidden;padding:var(--padding-block) var(--padding-inline);position:relative;resize:var(--resize)}:host([block]) .root{inline-size:auto}.root::after{border-bottom:2px solid var(--focus-indicator-color);border-radius:0 0 ${borderRadiusMedium} ${borderRadiusMedium};box-sizing:border-box;clip-path:inset(calc(100% - 2px) 1px 0px);content:'';height:max(2px,${borderRadiusMedium});inset:auto -1px 0;position:absolute;transform:scaleX(0);transition-delay:${curveAccelerateMid};transition-duration:${durationUltraFast};transition-property:transform}:host(:focus-within) .root::after{transform:scaleX(1);transition-property:transform;transition-duration:${durationNormal};transition-delay:${curveDecelerateMid}}:host([readonly]) .root::after,:host(${nativeDisabledState}) .root::after{content:none}label{color:var(--color);display:flex;inline-size:fit-content;padding-block-end:${spacingVerticalXS};padding-inline-end:${spacingHorizontalXS}}:host(:empty) label,label[hidden]{display:none}.auto-sizer,.control{box-sizing:border-box;font:inherit;grid-column:1/-1;grid-row:1/-1;letter-space:inherit;padding:0 var(--control-padding-inline)}.auto-sizer{display:none;padding-block-end:2px;pointer-events:none;visibility:hidden;white-space:pre-wrap}:host([auto-resize]) .auto-sizer{display:block}.control{appearance:none;background-color:transparent;border:0;color:inherit;field-sizing:content;max-block-size:100%;outline:0;overflow:auto;resize:none;text-align:inherit}.control:disabled{cursor:inherit}.control::placeholder{color:var(--placeholder-color)}::selection{color:${colorNeutralForegroundInverted};background-color:${colorNeutralBackgroundInverted}}@media (forced-colors:active){:host{--border-color:FieldText;--border-block-end-color:FieldText;--focus-indicator-color:Highlight;--placeholder-color:FieldText}:host(:hover),:host(:active),:host(:focus-within){--border-color:Highlight;--border-block-end-color:Highlight}:host(${nativeDisabledState}){--color:GrayText;--border-color:GrayText;--border-block-end-color:GrayText;--placeholder-color:GrayText}}`;
|
|
12949
12977
|
|
|
12950
12978
|
function textAreaTemplate() {
|
|
12951
12979
|
return html`<template><label ${ref("labelEl")} for=control part=label><slot name=label ${slotted("labelSlottedNodes")}></slot></label><div class=root part=root ${ref("rootEl")}><textarea ${ref("controlEl")} id=control class=control part=control ?required=${(x) => x.required} ?disabled=${(x) => x.disabled} ?readonly=${(x) => x.readOnly} ?spellcheck=${(x) => x.spellcheck} autocomplete=${(x) => x.autocomplete} maxlength=${(x) => x.maxLength} minlength=${(x) => x.minLength} placeholder=${(x) => x.placeholder} @change=${(x) => x.handleControlChange()} @select=${(x) => x.handleControlSelect()} @input=${(x) => x.handleControlInput()}></textarea></div><div hidden><slot ${slotted("defaultSlottedNodes")}></slot></div></template>`;
|
|
@@ -13543,6 +13571,18 @@ class BaseTextInput extends FASTElement {
|
|
|
13543
13571
|
* @internal
|
|
13544
13572
|
*/
|
|
13545
13573
|
this.dirtyValue = false;
|
|
13574
|
+
/**
|
|
13575
|
+
* The value as of the last `change` event or programmatic update.
|
|
13576
|
+
*
|
|
13577
|
+
* @internal
|
|
13578
|
+
*/
|
|
13579
|
+
this.committedValue = "";
|
|
13580
|
+
/**
|
|
13581
|
+
* Indicates that `value` is being updated from the internal control's `input` event.
|
|
13582
|
+
*
|
|
13583
|
+
* @internal
|
|
13584
|
+
*/
|
|
13585
|
+
this.isUserInput = false;
|
|
13546
13586
|
/**
|
|
13547
13587
|
* The internal {@link https://developer.mozilla.org/docs/Web/API/ElementInternals | `ElementInternals`} instance for the component.
|
|
13548
13588
|
*
|
|
@@ -13653,6 +13693,9 @@ class BaseTextInput extends FASTElement {
|
|
|
13653
13693
|
}
|
|
13654
13694
|
set value(value) {
|
|
13655
13695
|
this.currentValue = value;
|
|
13696
|
+
if (!this.isUserInput) {
|
|
13697
|
+
this.committedValue = value ?? "";
|
|
13698
|
+
}
|
|
13656
13699
|
if (this.elementInternals && this.control) {
|
|
13657
13700
|
this.control.value = value ?? "";
|
|
13658
13701
|
this.setFormValue(value);
|
|
@@ -13689,12 +13732,23 @@ class BaseTextInput extends FASTElement {
|
|
|
13689
13732
|
* proxies the change event, emitting a `change` event whenever the internal control emits a `change` event.
|
|
13690
13733
|
*/
|
|
13691
13734
|
changeHandler(e) {
|
|
13735
|
+
if (this.control.value !== this.committedValue) {
|
|
13736
|
+
this.emitChange(e);
|
|
13737
|
+
}
|
|
13738
|
+
return true;
|
|
13739
|
+
}
|
|
13740
|
+
/**
|
|
13741
|
+
* Validates, records the committed value, and emits `change` on the host.
|
|
13742
|
+
*
|
|
13743
|
+
* @internal
|
|
13744
|
+
*/
|
|
13745
|
+
emitChange(detail) {
|
|
13746
|
+
this.committedValue = this.control.value;
|
|
13692
13747
|
this.setValidity();
|
|
13693
|
-
this.$emit("change",
|
|
13748
|
+
this.$emit("change", detail, {
|
|
13694
13749
|
bubbles: true,
|
|
13695
13750
|
composed: true
|
|
13696
13751
|
});
|
|
13697
|
-
return true;
|
|
13698
13752
|
}
|
|
13699
13753
|
/**
|
|
13700
13754
|
* Checks the validity of the element and returns the result.
|
|
@@ -13766,7 +13820,12 @@ class BaseTextInput extends FASTElement {
|
|
|
13766
13820
|
*/
|
|
13767
13821
|
inputHandler(e) {
|
|
13768
13822
|
this.dirtyValue = true;
|
|
13769
|
-
this.
|
|
13823
|
+
this.isUserInput = true;
|
|
13824
|
+
try {
|
|
13825
|
+
this.value = this.control.value;
|
|
13826
|
+
} finally {
|
|
13827
|
+
this.isUserInput = false;
|
|
13828
|
+
}
|
|
13770
13829
|
return true;
|
|
13771
13830
|
}
|
|
13772
13831
|
/**
|
|
@@ -13776,9 +13835,19 @@ class BaseTextInput extends FASTElement {
|
|
|
13776
13835
|
* @internal
|
|
13777
13836
|
*/
|
|
13778
13837
|
keydownHandler(e) {
|
|
13779
|
-
if (e.key
|
|
13780
|
-
|
|
13838
|
+
if (e.key !== "Enter") {
|
|
13839
|
+
return true;
|
|
13840
|
+
}
|
|
13841
|
+
if (e.isComposing || e.keyCode === 229) {
|
|
13842
|
+
return true;
|
|
13781
13843
|
}
|
|
13844
|
+
if (e.composedPath()[0] !== this.control) {
|
|
13845
|
+
return true;
|
|
13846
|
+
}
|
|
13847
|
+
if (this.control.value !== this.committedValue) {
|
|
13848
|
+
this.emitChange();
|
|
13849
|
+
}
|
|
13850
|
+
this.implicitSubmit();
|
|
13782
13851
|
return true;
|
|
13783
13852
|
}
|
|
13784
13853
|
/**
|
|
@@ -14124,22 +14193,22 @@ __decorateClass$5([
|
|
|
14124
14193
|
ToggleButton.define(definition$3);
|
|
14125
14194
|
|
|
14126
14195
|
const TooltipPositioningOption = {
|
|
14127
|
-
"above-start": "
|
|
14128
|
-
above: "
|
|
14129
|
-
"above-end": "
|
|
14130
|
-
"below-start": "
|
|
14131
|
-
below: "
|
|
14132
|
-
"below-end": "
|
|
14133
|
-
"before-top": "
|
|
14134
|
-
before: "
|
|
14135
|
-
"before-bottom": "
|
|
14136
|
-
"after-top": "
|
|
14137
|
-
after: "
|
|
14138
|
-
"after-bottom": "
|
|
14196
|
+
"above-start": "above-start",
|
|
14197
|
+
above: "above",
|
|
14198
|
+
"above-end": "above-end",
|
|
14199
|
+
"below-start": "below-start",
|
|
14200
|
+
below: "below",
|
|
14201
|
+
"below-end": "below-end",
|
|
14202
|
+
"before-top": "before-top",
|
|
14203
|
+
before: "before",
|
|
14204
|
+
"before-bottom": "before-bottom",
|
|
14205
|
+
"after-top": "after-top",
|
|
14206
|
+
after: "after",
|
|
14207
|
+
"after-bottom": "after-bottom"
|
|
14139
14208
|
};
|
|
14140
14209
|
const tagName$2 = `${FluentDesignSystem.prefix}-tooltip`;
|
|
14141
14210
|
|
|
14142
|
-
const styles$2 = css`${display("inline-flex")} :host(:not(:popover-open)){display:none}:host{--position-area:block-start;--position-try-options:flip-block;--block-offset:${spacingVerticalXS};--inline-offset:${spacingHorizontalXS};background:${colorNeutralBackground1};border-radius:${borderRadiusMedium};border:1px solid ${colorTransparentStroke};box-sizing:border-box;color:${colorNeutralForeground1};display:inline-flex;filter:drop-shadow(0 0 2px ${colorNeutralShadowAmbient}) drop-shadow(0 4px 8px ${colorNeutralShadowKey});font-family:${fontFamilyBase};font-size:${fontSizeBase200};inset:unset;line-height:${lineHeightBase200};margin:unset;max-width:240px;overflow:visible;padding:4px ${spacingHorizontalMNudge} 6px;position:absolute;position-area:var(--position-area);position-try-fallbacks:var(--position-try-options);width:auto;z-index:1}@supports (inset-area:block-start){:host{inset-area:var(--position-area);position-try-fallbacks:var(--position-try-options)}}:host(:is([positioning^='above'],[positioning^='below'],:not([positioning]))){margin-block:var(--block-offset)}:host(:is([positioning^='before'],[positioning^='after'])){margin-inline:var(--inline-offset);--position-try-options:flip-inline}:host([positioning='above-start']){--position-area
|
|
14211
|
+
const styles$2 = css`${display("inline-flex")} :host(:not(:popover-open)){display:none}:host{--position-area:block-start;--position-try-options:flip-block;--block-offset:${spacingVerticalXS};--inline-offset:${spacingHorizontalXS};background:${colorNeutralBackground1};border-radius:${borderRadiusMedium};border:1px solid ${colorTransparentStroke};box-sizing:border-box;color:${colorNeutralForeground1};display:inline-flex;filter:drop-shadow(0 0 2px ${colorNeutralShadowAmbient}) drop-shadow(0 4px 8px ${colorNeutralShadowKey});font-family:${fontFamilyBase};font-size:${fontSizeBase200};inset:unset;line-height:${lineHeightBase200};margin:unset;max-width:240px;overflow:visible;padding:4px ${spacingHorizontalMNudge} 6px;position:absolute;position-area:var(--position-area);position-try-fallbacks:var(--position-try-options);width:auto;z-index:1}@supports (inset-area:block-start){:host{inset-area:var(--position-area);position-try-fallbacks:var(--position-try-options)}}:host(:is([positioning^='above'],[positioning^='below'],:not([positioning]))){margin-block:var(--block-offset)}:host(:is([positioning^='before'],[positioning^='after'])){margin-inline:var(--inline-offset);--position-try-options:flip-inline}:host([positioning='above-start']){--position-area:block-start span-inline-end}:host([positioning='above']){--position-area:block-start}:host([positioning='above-end']){--position-area:block-start span-inline-start}:host([positioning='below-start']){--position-area:block-end span-inline-end}:host([positioning='below']){--position-area:block-end}:host([positioning='below-end']){--position-area:block-end span-inline-start}:host([positioning='before-top']){--position-area:inline-start span-block-end}:host([positioning='before']){--position-area:inline-start}:host([positioning='before-bottom']){--position-area:inline-start span-block-start}:host([positioning='after-top']){--position-area:inline-end span-block-end}:host([positioning='after']){--position-area:inline-end}:host([positioning='after-bottom']){--position-area:inline-end span-block-start}`;
|
|
14143
14212
|
|
|
14144
14213
|
const template$2 = html`<template popover aria-hidden=true><slot></slot></template>`;
|
|
14145
14214
|
|