@fluentui/web-components 3.0.0-beta.84 → 3.0.0-beta.86
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 +21 -2
- package/dist/dts/anchor-button/index.d.ts +1 -0
- package/dist/dts/index-rollup.d.ts +2 -0
- package/dist/dts/index.d.ts +7 -8
- package/dist/dts/tree/define.d.ts +1 -0
- package/dist/dts/tree/index.d.ts +5 -0
- package/dist/dts/tree/tree.base.d.ts +68 -0
- package/dist/dts/tree/tree.bench.d.ts +3 -0
- package/dist/dts/tree/tree.d.ts +28 -0
- package/dist/dts/tree/tree.definition.d.ts +8 -0
- package/dist/dts/tree/tree.styles.d.ts +1 -0
- package/dist/dts/tree/tree.template.d.ts +2 -0
- package/dist/dts/tree-item/define.d.ts +1 -0
- package/dist/dts/tree-item/index.d.ts +6 -0
- package/dist/dts/tree-item/tree-item.base.d.ts +99 -0
- package/dist/dts/tree-item/tree-item.bench.d.ts +3 -0
- package/dist/dts/tree-item/tree-item.d.ts +38 -0
- package/dist/dts/tree-item/tree-item.definition.d.ts +8 -0
- package/dist/dts/tree-item/tree-item.options.d.ts +22 -0
- package/dist/dts/tree-item/tree-item.styles.d.ts +1 -0
- package/dist/dts/tree-item/tree-item.template.d.ts +2 -0
- package/dist/esm/anchor-button/index.js +1 -0
- package/dist/esm/anchor-button/index.js.map +1 -1
- package/dist/esm/index-rollup.js +2 -0
- package/dist/esm/index-rollup.js.map +1 -1
- package/dist/esm/index.js +6 -5
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/tree/define.js +4 -0
- package/dist/esm/tree/define.js.map +1 -0
- package/dist/esm/tree/index.js +6 -0
- package/dist/esm/tree/index.js.map +1 -0
- package/dist/esm/tree/tree.base.js +232 -0
- package/dist/esm/tree/tree.base.js.map +1 -0
- package/dist/esm/tree/tree.bench.js +10 -0
- package/dist/esm/tree/tree.bench.js.map +1 -0
- package/dist/esm/tree/tree.definition.js +16 -0
- package/dist/esm/tree/tree.definition.js.map +1 -0
- package/dist/esm/tree/tree.js +55 -0
- package/dist/esm/tree/tree.js.map +1 -0
- package/dist/esm/tree/tree.styles.js +9 -0
- package/dist/esm/tree/tree.styles.js.map +1 -0
- package/dist/esm/tree/tree.template.js +19 -0
- package/dist/esm/tree/tree.template.js.map +1 -0
- package/dist/esm/tree-item/define.js +4 -0
- package/dist/esm/tree-item/define.js.map +1 -0
- package/dist/esm/tree-item/index.js +6 -0
- package/dist/esm/tree-item/index.js.map +1 -0
- package/dist/esm/tree-item/tree-item.base.js +165 -0
- package/dist/esm/tree-item/tree-item.base.js.map +1 -0
- package/dist/esm/tree-item/tree-item.bench.js +10 -0
- package/dist/esm/tree-item/tree-item.bench.js.map +1 -0
- package/dist/esm/tree-item/tree-item.definition.js +16 -0
- package/dist/esm/tree-item/tree-item.definition.js.map +1 -0
- package/dist/esm/tree-item/tree-item.js +65 -0
- package/dist/esm/tree-item/tree-item.js.map +1 -0
- package/dist/esm/tree-item/tree-item.options.js +24 -0
- package/dist/esm/tree-item/tree-item.options.js.map +1 -0
- package/dist/esm/tree-item/tree-item.styles.js +157 -0
- package/dist/esm/tree-item/tree-item.styles.js.map +1 -0
- package/dist/esm/tree-item/tree-item.template.js +39 -0
- package/dist/esm/tree-item/tree-item.template.js.map +1 -0
- package/dist/web-components.d.ts +173 -0
- package/dist/web-components.js +1327 -800
- package/dist/web-components.min.js +291 -284
- package/package.json +1 -1
package/dist/web-components.js
CHANGED
|
@@ -4011,70 +4011,70 @@ const FASTElement = Object.assign(createFASTElement(HTMLElement), {
|
|
|
4011
4011
|
compose
|
|
4012
4012
|
});
|
|
4013
4013
|
|
|
4014
|
-
var __defProp$
|
|
4015
|
-
var __getOwnPropDesc$
|
|
4016
|
-
var __decorateClass$
|
|
4017
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
4014
|
+
var __defProp$S = Object.defineProperty;
|
|
4015
|
+
var __getOwnPropDesc$S = Object.getOwnPropertyDescriptor;
|
|
4016
|
+
var __decorateClass$S = (decorators, target, key, kind) => {
|
|
4017
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$S(target, key) : target;
|
|
4018
4018
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
4019
|
-
if (kind && result) __defProp$
|
|
4019
|
+
if (kind && result) __defProp$S(target, key, result);
|
|
4020
4020
|
return result;
|
|
4021
4021
|
};
|
|
4022
4022
|
class ARIAGlobalStatesAndProperties {}
|
|
4023
|
-
__decorateClass$
|
|
4023
|
+
__decorateClass$S([attr({
|
|
4024
4024
|
attribute: "aria-atomic"
|
|
4025
4025
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaAtomic", 2);
|
|
4026
|
-
__decorateClass$
|
|
4026
|
+
__decorateClass$S([attr({
|
|
4027
4027
|
attribute: "aria-busy"
|
|
4028
4028
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaBusy", 2);
|
|
4029
|
-
__decorateClass$
|
|
4029
|
+
__decorateClass$S([attr({
|
|
4030
4030
|
attribute: "aria-controls"
|
|
4031
4031
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaControls", 2);
|
|
4032
|
-
__decorateClass$
|
|
4032
|
+
__decorateClass$S([attr({
|
|
4033
4033
|
attribute: "aria-current"
|
|
4034
4034
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaCurrent", 2);
|
|
4035
|
-
__decorateClass$
|
|
4035
|
+
__decorateClass$S([attr({
|
|
4036
4036
|
attribute: "aria-describedby"
|
|
4037
4037
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaDescribedby", 2);
|
|
4038
|
-
__decorateClass$
|
|
4038
|
+
__decorateClass$S([attr({
|
|
4039
4039
|
attribute: "aria-details"
|
|
4040
4040
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaDetails", 2);
|
|
4041
|
-
__decorateClass$
|
|
4041
|
+
__decorateClass$S([attr({
|
|
4042
4042
|
attribute: "aria-disabled"
|
|
4043
4043
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaDisabled", 2);
|
|
4044
|
-
__decorateClass$
|
|
4044
|
+
__decorateClass$S([attr({
|
|
4045
4045
|
attribute: "aria-errormessage"
|
|
4046
4046
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaErrormessage", 2);
|
|
4047
|
-
__decorateClass$
|
|
4047
|
+
__decorateClass$S([attr({
|
|
4048
4048
|
attribute: "aria-flowto"
|
|
4049
4049
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaFlowto", 2);
|
|
4050
|
-
__decorateClass$
|
|
4050
|
+
__decorateClass$S([attr({
|
|
4051
4051
|
attribute: "aria-haspopup"
|
|
4052
4052
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaHaspopup", 2);
|
|
4053
|
-
__decorateClass$
|
|
4053
|
+
__decorateClass$S([attr({
|
|
4054
4054
|
attribute: "aria-hidden"
|
|
4055
4055
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaHidden", 2);
|
|
4056
|
-
__decorateClass$
|
|
4056
|
+
__decorateClass$S([attr({
|
|
4057
4057
|
attribute: "aria-invalid"
|
|
4058
4058
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaInvalid", 2);
|
|
4059
|
-
__decorateClass$
|
|
4059
|
+
__decorateClass$S([attr({
|
|
4060
4060
|
attribute: "aria-keyshortcuts"
|
|
4061
4061
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaKeyshortcuts", 2);
|
|
4062
|
-
__decorateClass$
|
|
4062
|
+
__decorateClass$S([attr({
|
|
4063
4063
|
attribute: "aria-label"
|
|
4064
4064
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaLabel", 2);
|
|
4065
|
-
__decorateClass$
|
|
4065
|
+
__decorateClass$S([attr({
|
|
4066
4066
|
attribute: "aria-labelledby"
|
|
4067
4067
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaLabelledby", 2);
|
|
4068
|
-
__decorateClass$
|
|
4068
|
+
__decorateClass$S([attr({
|
|
4069
4069
|
attribute: "aria-live"
|
|
4070
4070
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaLive", 2);
|
|
4071
|
-
__decorateClass$
|
|
4071
|
+
__decorateClass$S([attr({
|
|
4072
4072
|
attribute: "aria-owns"
|
|
4073
4073
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaOwns", 2);
|
|
4074
|
-
__decorateClass$
|
|
4074
|
+
__decorateClass$S([attr({
|
|
4075
4075
|
attribute: "aria-relevant"
|
|
4076
4076
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaRelevant", 2);
|
|
4077
|
-
__decorateClass$
|
|
4077
|
+
__decorateClass$S([attr({
|
|
4078
4078
|
attribute: "aria-roledescription"
|
|
4079
4079
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaRoledescription", 2);
|
|
4080
4080
|
|
|
@@ -4378,12 +4378,12 @@ function swapStates(elementInternals, prev = "", next = "", States, prefix = "")
|
|
|
4378
4378
|
}
|
|
4379
4379
|
}
|
|
4380
4380
|
|
|
4381
|
-
var __defProp$
|
|
4382
|
-
var __getOwnPropDesc$
|
|
4383
|
-
var __decorateClass$
|
|
4384
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
4381
|
+
var __defProp$R = Object.defineProperty;
|
|
4382
|
+
var __getOwnPropDesc$R = Object.getOwnPropertyDescriptor;
|
|
4383
|
+
var __decorateClass$R = (decorators, target, key, kind) => {
|
|
4384
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$R(target, key) : target;
|
|
4385
4385
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
4386
|
-
if (kind && result) __defProp$
|
|
4386
|
+
if (kind && result) __defProp$R(target, key, result);
|
|
4387
4387
|
return result;
|
|
4388
4388
|
};
|
|
4389
4389
|
class BaseAccordionItem extends FASTElement {
|
|
@@ -4417,18 +4417,18 @@ class BaseAccordionItem extends FASTElement {
|
|
|
4417
4417
|
toggleState(this.elementInternals, "disabled", next);
|
|
4418
4418
|
}
|
|
4419
4419
|
}
|
|
4420
|
-
__decorateClass$
|
|
4420
|
+
__decorateClass$R([attr({
|
|
4421
4421
|
attribute: "heading-level",
|
|
4422
4422
|
mode: "fromView",
|
|
4423
4423
|
converter: nullableNumberConverter
|
|
4424
4424
|
})], BaseAccordionItem.prototype, "headinglevel", 2);
|
|
4425
|
-
__decorateClass$
|
|
4425
|
+
__decorateClass$R([attr({
|
|
4426
4426
|
mode: "boolean"
|
|
4427
4427
|
})], BaseAccordionItem.prototype, "expanded", 2);
|
|
4428
|
-
__decorateClass$
|
|
4428
|
+
__decorateClass$R([attr({
|
|
4429
4429
|
mode: "boolean"
|
|
4430
4430
|
})], BaseAccordionItem.prototype, "disabled", 2);
|
|
4431
|
-
__decorateClass$
|
|
4431
|
+
__decorateClass$R([attr], BaseAccordionItem.prototype, "id", 2);
|
|
4432
4432
|
|
|
4433
4433
|
const AccordionItemSize = {
|
|
4434
4434
|
small: "small",
|
|
@@ -4441,12 +4441,12 @@ const AccordionItemMarkerPosition = {
|
|
|
4441
4441
|
end: "end"
|
|
4442
4442
|
};
|
|
4443
4443
|
|
|
4444
|
-
var __defProp$
|
|
4445
|
-
var __getOwnPropDesc$
|
|
4446
|
-
var __decorateClass$
|
|
4447
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
4444
|
+
var __defProp$Q = Object.defineProperty;
|
|
4445
|
+
var __getOwnPropDesc$Q = Object.getOwnPropertyDescriptor;
|
|
4446
|
+
var __decorateClass$Q = (decorators, target, key, kind) => {
|
|
4447
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$Q(target, key) : target;
|
|
4448
4448
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
4449
|
-
if (kind && result) __defProp$
|
|
4449
|
+
if (kind && result) __defProp$Q(target, key, result);
|
|
4450
4450
|
return result;
|
|
4451
4451
|
};
|
|
4452
4452
|
class AccordionItem extends BaseAccordionItem {
|
|
@@ -4479,11 +4479,11 @@ class AccordionItem extends BaseAccordionItem {
|
|
|
4479
4479
|
toggleState(this.elementInternals, "block", next);
|
|
4480
4480
|
}
|
|
4481
4481
|
}
|
|
4482
|
-
__decorateClass$
|
|
4483
|
-
__decorateClass$
|
|
4482
|
+
__decorateClass$Q([attr], AccordionItem.prototype, "size", 2);
|
|
4483
|
+
__decorateClass$Q([attr({
|
|
4484
4484
|
attribute: "marker-position"
|
|
4485
4485
|
})], AccordionItem.prototype, "markerPosition", 2);
|
|
4486
|
-
__decorateClass$
|
|
4486
|
+
__decorateClass$Q([attr({
|
|
4487
4487
|
mode: "boolean"
|
|
4488
4488
|
})], AccordionItem.prototype, "block", 2);
|
|
4489
4489
|
applyMixins(AccordionItem, StartEnd);
|
|
@@ -4629,6 +4629,7 @@ const colorNeutralForeground2BrandSelected = "var(--colorNeutralForeground2Brand
|
|
|
4629
4629
|
const colorNeutralForeground3 = "var(--colorNeutralForeground3)";
|
|
4630
4630
|
const colorNeutralForeground3Hover = "var(--colorNeutralForeground3Hover)";
|
|
4631
4631
|
const colorNeutralForeground3Pressed = "var(--colorNeutralForeground3Pressed)";
|
|
4632
|
+
const colorNeutralForeground3Selected = "var(--colorNeutralForeground3Selected)";
|
|
4632
4633
|
const colorNeutralForeground4 = "var(--colorNeutralForeground4)";
|
|
4633
4634
|
const colorNeutralForegroundDisabled = "var(--colorNeutralForegroundDisabled)";
|
|
4634
4635
|
const colorBrandForegroundLink = "var(--colorBrandForegroundLink)";
|
|
@@ -4660,6 +4661,9 @@ const colorSubtleBackground = "var(--colorSubtleBackground)";
|
|
|
4660
4661
|
const colorSubtleBackgroundHover = "var(--colorSubtleBackgroundHover)";
|
|
4661
4662
|
const colorSubtleBackgroundPressed = "var(--colorSubtleBackgroundPressed)";
|
|
4662
4663
|
const colorSubtleBackgroundSelected = "var(--colorSubtleBackgroundSelected)";
|
|
4664
|
+
const colorSubtleBackgroundLightAlphaHover = "var(--colorSubtleBackgroundLightAlphaHover)";
|
|
4665
|
+
const colorSubtleBackgroundLightAlphaPressed = "var(--colorSubtleBackgroundLightAlphaPressed)";
|
|
4666
|
+
const colorSubtleBackgroundLightAlphaSelected = "var(--colorSubtleBackgroundLightAlphaSelected)";
|
|
4663
4667
|
const colorTransparentBackground = "var(--colorTransparentBackground)";
|
|
4664
4668
|
const colorTransparentBackgroundHover = "var(--colorTransparentBackgroundHover)";
|
|
4665
4669
|
const colorTransparentBackgroundPressed = "var(--colorTransparentBackgroundPressed)";
|
|
@@ -4831,6 +4835,7 @@ const spacingHorizontalM = "var(--spacingHorizontalM)";
|
|
|
4831
4835
|
const spacingHorizontalL = "var(--spacingHorizontalL)";
|
|
4832
4836
|
const spacingHorizontalXL = "var(--spacingHorizontalXL)";
|
|
4833
4837
|
const spacingHorizontalXXL = "var(--spacingHorizontalXXL)";
|
|
4838
|
+
const spacingVerticalNone = "var(--spacingVerticalNone)";
|
|
4834
4839
|
const spacingVerticalXXS = "var(--spacingVerticalXXS)";
|
|
4835
4840
|
const spacingVerticalXS = "var(--spacingVerticalXS)";
|
|
4836
4841
|
const spacingVerticalSNudge = "var(--spacingVerticalSNudge)";
|
|
@@ -4839,6 +4844,7 @@ const spacingVerticalMNudge = "var(--spacingVerticalMNudge)";
|
|
|
4839
4844
|
const spacingVerticalM = "var(--spacingVerticalM)";
|
|
4840
4845
|
const spacingVerticalL = "var(--spacingVerticalL)";
|
|
4841
4846
|
const spacingVerticalXXL = "var(--spacingVerticalXXL)";
|
|
4847
|
+
const spacingVerticalXXXL = "var(--spacingVerticalXXXL)";
|
|
4842
4848
|
const durationUltraFast = "var(--durationUltraFast)";
|
|
4843
4849
|
const durationFaster = "var(--durationFaster)";
|
|
4844
4850
|
const durationNormal = "var(--durationNormal)";
|
|
@@ -4856,7 +4862,7 @@ const curveEasyEaseMax = "var(--curveEasyEaseMax)";
|
|
|
4856
4862
|
const curveEasyEase = "var(--curveEasyEase)";
|
|
4857
4863
|
const curveLinear = "var(--curveLinear)";
|
|
4858
4864
|
|
|
4859
|
-
const styles$
|
|
4865
|
+
const styles$G = css`
|
|
4860
4866
|
${display("block")}
|
|
4861
4867
|
|
|
4862
4868
|
:host{max-width:fit-content;contain:content}.heading{height:44px;display:grid;position:relative;padding-inline:${spacingHorizontalM} ${spacingHorizontalMNudge};border-radius:${borderRadiusMedium};font-family:${fontFamilyBase};font-size:${fontSizeBase300};font-weight:${fontWeightRegular};line-height:${lineHeightBase300};grid-template-columns:auto auto 1fr auto}.button{appearance:none;background:${colorTransparentBackground};border:none;box-sizing:border-box;color:${colorNeutralForeground1};cursor:pointer;font:inherit;grid-column:auto / span 2;grid-row:1;height:44px;outline:none;padding:0;text-align:start}.button::before{content:'';position:absolute;inset:0px;cursor:pointer;border-radius:${borderRadiusSmall}}:where(.default-marker-collapsed,.default-marker-expanded),::slotted(:is([slot='marker-collapsed'],[slot='marker-expanded'])){display:flex;align-items:center;justify-content:center;pointer-events:none;position:relative;height:100%;padding-inline-end:${spacingHorizontalS};grid-column:1 / span 1;grid-row:1}.content{margin:0 ${spacingHorizontalM}}::slotted([slot='start']){display:flex;justify-content:center;align-items:center;padding-right:${spacingHorizontalS};grid-column:2 / span 1;grid-row:1}button:focus-visible::after{content:'';position:absolute;inset:0px;cursor:pointer;border-radius:${borderRadiusSmall};outline:none;border:2px solid ${colorStrokeFocus1};box-shadow:inset 0 0 0 1px ${colorStrokeFocus2}}:host(${disabledState}) .button{color:${colorNeutralForegroundDisabled}}:host(${disabledState}) svg{filter:invert(89%) sepia(0%) saturate(569%) hue-rotate(155deg) brightness(88%) contrast(87%)}:host(${expandedState}) .content{display:block}:host(${expandedState}) .default-marker-collapsed,:host(${expandedState}) ::slotted([slot='marker-collapsed']),:host(:not(${expandedState})) :is(.default-marker-expanded,.content),:host(:not(${expandedState})) ::slotted([slot='marker-expanded']){display:none}:host(${expandedState}) ::slotted([slot='marker-expanded']),:host(:not(${expandedState})) ::slotted([slot='marker-collapsed']){display:flex}.heading{font-size:${fontSizeBase300};line-height:${lineHeightBase300}}:host(${smallState}) .heading{font-size:${fontSizeBase200};line-height:${lineHeightBase200}}:host(${largeState}) .heading{font-size:${fontSizeBase400};line-height:${lineHeightBase400}}:host(${extraLargeState}) .heading{font-size:${fontSizeBase500};line-height:${lineHeightBase500}}:host(${alignEndState}) :slotted([slot='start']){grid-column:1 / span 1}:host(${alignEndState}) :is(.default-marker-collapsed,.default-marker-expanded){grid-column:4 / span 1;padding-inline-start:${spacingHorizontalS};padding-inline-end:0}:host(${alignEndState}) .button{grid-column:2 / span 3}:host([block]){max-width:100%}:host(${alignEndState}) .heading{grid-template-columns:auto auto 28px;padding-inline:${spacingHorizontalM}}:host(${alignEndState}:has([slot='start'])) .heading{padding-inline:${spacingHorizontalMNudge} ${spacingHorizontalM}}:host(${blockState}${alignEndState}) .heading{grid-template-columns:auto 1fr}:host(${alignEndState}) :is(.default-marker-collapsed,.default-marker-expanded){grid-column:5 / span 1}`;
|
|
@@ -4892,30 +4898,30 @@ const chevronDown20Filled = html.partial(`<svg
|
|
|
4892
4898
|
function accordionItemTemplate(options = {}) {
|
|
4893
4899
|
return html`<div class="heading" part="heading" role="heading" aria-level="${x => x.headinglevel}"><button class="button" part="button" ${ref("expandbutton")} ?disabled="${x => x.disabled ? "true" : void 0}" aria-expanded="${x => x.expanded}" aria-controls="${x => x.id}-panel" id="${x => x.id}"><slot name="heading"></slot></button>${startSlotTemplate(options)}<slot name="marker-expanded">${staticallyCompose(options.expandedIcon)}</slot><slot name="marker-collapsed">${staticallyCompose(options.collapsedIcon)}</slot></div><div class="content" part="content" id="${x => x.id}-panel" role="region" aria-labelledby="${x => x.id}"><slot></slot></div>`;
|
|
4894
4900
|
}
|
|
4895
|
-
const template$
|
|
4901
|
+
const template$H = accordionItemTemplate({
|
|
4896
4902
|
collapsedIcon: chevronRight20Filled,
|
|
4897
4903
|
expandedIcon: chevronDown20Filled
|
|
4898
4904
|
});
|
|
4899
4905
|
|
|
4900
|
-
const definition$
|
|
4906
|
+
const definition$H = AccordionItem.compose({
|
|
4901
4907
|
name: `${FluentDesignSystem.prefix}-accordion-item`,
|
|
4902
|
-
template: template$
|
|
4903
|
-
styles: styles$
|
|
4908
|
+
template: template$H,
|
|
4909
|
+
styles: styles$G
|
|
4904
4910
|
});
|
|
4905
4911
|
|
|
4906
|
-
definition$
|
|
4912
|
+
definition$H.define(FluentDesignSystem.registry);
|
|
4907
4913
|
|
|
4908
4914
|
const AccordionExpandMode = {
|
|
4909
4915
|
single: "single",
|
|
4910
4916
|
multi: "multi"
|
|
4911
4917
|
};
|
|
4912
4918
|
|
|
4913
|
-
var __defProp$
|
|
4914
|
-
var __getOwnPropDesc$
|
|
4915
|
-
var __decorateClass$
|
|
4916
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
4919
|
+
var __defProp$P = Object.defineProperty;
|
|
4920
|
+
var __getOwnPropDesc$P = Object.getOwnPropertyDescriptor;
|
|
4921
|
+
var __decorateClass$P = (decorators, target, key, kind) => {
|
|
4922
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$P(target, key) : target;
|
|
4917
4923
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
4918
|
-
if (kind && result) __defProp$
|
|
4924
|
+
if (kind && result) __defProp$P(target, key, result);
|
|
4919
4925
|
return result;
|
|
4920
4926
|
};
|
|
4921
4927
|
class Accordion extends FASTElement {
|
|
@@ -5054,12 +5060,12 @@ class Accordion extends FASTElement {
|
|
|
5054
5060
|
});
|
|
5055
5061
|
}
|
|
5056
5062
|
}
|
|
5057
|
-
__decorateClass$
|
|
5063
|
+
__decorateClass$P([attr({
|
|
5058
5064
|
attribute: "expand-mode"
|
|
5059
5065
|
})], Accordion.prototype, "expandmode", 2);
|
|
5060
|
-
__decorateClass$
|
|
5066
|
+
__decorateClass$P([observable], Accordion.prototype, "slottedAccordionItems", 2);
|
|
5061
5067
|
|
|
5062
|
-
const styles$
|
|
5068
|
+
const styles$F = css`
|
|
5063
5069
|
${display("flex")}
|
|
5064
5070
|
|
|
5065
5071
|
:host{flex-direction:column;width:100%;contain:content}`;
|
|
@@ -5070,15 +5076,15 @@ function accordionTemplate() {
|
|
|
5070
5076
|
filter: elements()
|
|
5071
5077
|
})}></slot></template>`;
|
|
5072
5078
|
}
|
|
5073
|
-
const template$
|
|
5079
|
+
const template$G = accordionTemplate();
|
|
5074
5080
|
|
|
5075
|
-
const definition$
|
|
5081
|
+
const definition$G = Accordion.compose({
|
|
5076
5082
|
name: `${FluentDesignSystem.prefix}-accordion`,
|
|
5077
|
-
template: template$
|
|
5078
|
-
styles: styles$
|
|
5083
|
+
template: template$G,
|
|
5084
|
+
styles: styles$F
|
|
5079
5085
|
});
|
|
5080
5086
|
|
|
5081
|
-
definition$
|
|
5087
|
+
definition$G.define(FluentDesignSystem.registry);
|
|
5082
5088
|
|
|
5083
5089
|
const ButtonAppearance = {
|
|
5084
5090
|
primary: "primary",
|
|
@@ -5116,12 +5122,12 @@ const AnchorAttributes = {
|
|
|
5116
5122
|
type: "type"
|
|
5117
5123
|
};
|
|
5118
5124
|
|
|
5119
|
-
var __defProp$
|
|
5120
|
-
var __getOwnPropDesc$
|
|
5121
|
-
var __decorateClass$
|
|
5122
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
5125
|
+
var __defProp$O = Object.defineProperty;
|
|
5126
|
+
var __getOwnPropDesc$O = Object.getOwnPropertyDescriptor;
|
|
5127
|
+
var __decorateClass$O = (decorators, target, key, kind) => {
|
|
5128
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$O(target, key) : target;
|
|
5123
5129
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
5124
|
-
if (kind && result) __defProp$
|
|
5130
|
+
if (kind && result) __defProp$O(target, key, result);
|
|
5125
5131
|
return result;
|
|
5126
5132
|
};
|
|
5127
5133
|
class BaseAnchor extends FASTElement {
|
|
@@ -5229,21 +5235,21 @@ class BaseAnchor extends FASTElement {
|
|
|
5229
5235
|
return proxy;
|
|
5230
5236
|
}
|
|
5231
5237
|
}
|
|
5232
|
-
__decorateClass$
|
|
5233
|
-
__decorateClass$
|
|
5234
|
-
__decorateClass$
|
|
5235
|
-
__decorateClass$
|
|
5236
|
-
__decorateClass$
|
|
5237
|
-
__decorateClass$
|
|
5238
|
-
__decorateClass$
|
|
5239
|
-
__decorateClass$
|
|
5238
|
+
__decorateClass$O([attr], BaseAnchor.prototype, "download", 2);
|
|
5239
|
+
__decorateClass$O([attr], BaseAnchor.prototype, "href", 2);
|
|
5240
|
+
__decorateClass$O([attr], BaseAnchor.prototype, "hreflang", 2);
|
|
5241
|
+
__decorateClass$O([attr], BaseAnchor.prototype, "ping", 2);
|
|
5242
|
+
__decorateClass$O([attr], BaseAnchor.prototype, "referrerpolicy", 2);
|
|
5243
|
+
__decorateClass$O([attr], BaseAnchor.prototype, "rel", 2);
|
|
5244
|
+
__decorateClass$O([attr], BaseAnchor.prototype, "target", 2);
|
|
5245
|
+
__decorateClass$O([attr], BaseAnchor.prototype, "type", 2);
|
|
5240
5246
|
|
|
5241
|
-
var __defProp$
|
|
5242
|
-
var __getOwnPropDesc$
|
|
5243
|
-
var __decorateClass$
|
|
5244
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
5247
|
+
var __defProp$N = Object.defineProperty;
|
|
5248
|
+
var __getOwnPropDesc$N = Object.getOwnPropertyDescriptor;
|
|
5249
|
+
var __decorateClass$N = (decorators, target, key, kind) => {
|
|
5250
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$N(target, key) : target;
|
|
5245
5251
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
5246
|
-
if (kind && result) __defProp$
|
|
5252
|
+
if (kind && result) __defProp$N(target, key, result);
|
|
5247
5253
|
return result;
|
|
5248
5254
|
};
|
|
5249
5255
|
class AnchorButton extends BaseAnchor {
|
|
@@ -5284,10 +5290,10 @@ class AnchorButton extends BaseAnchor {
|
|
|
5284
5290
|
toggleState(this.elementInternals, "icon", !!next);
|
|
5285
5291
|
}
|
|
5286
5292
|
}
|
|
5287
|
-
__decorateClass$
|
|
5288
|
-
__decorateClass$
|
|
5289
|
-
__decorateClass$
|
|
5290
|
-
__decorateClass$
|
|
5293
|
+
__decorateClass$N([attr], AnchorButton.prototype, "appearance", 2);
|
|
5294
|
+
__decorateClass$N([attr], AnchorButton.prototype, "shape", 2);
|
|
5295
|
+
__decorateClass$N([attr], AnchorButton.prototype, "size", 2);
|
|
5296
|
+
__decorateClass$N([attr({
|
|
5291
5297
|
attribute: "icon-only",
|
|
5292
5298
|
mode: "boolean"
|
|
5293
5299
|
})], AnchorButton.prototype, "iconOnly", 2);
|
|
@@ -5297,13 +5303,13 @@ const baseButtonStyles = css`
|
|
|
5297
5303
|
${display("inline-flex")}
|
|
5298
5304
|
|
|
5299
5305
|
:host{--icon-spacing:${spacingHorizontalSNudge};position:relative;contain:layout style;vertical-align:middle;align-items:center;box-sizing:border-box;justify-content:center;text-align:center;text-decoration-line:none;margin:0;min-height:32px;outline-style:none;background-color:${colorNeutralBackground1};color:${colorNeutralForeground1};border:${strokeWidthThin} solid ${colorNeutralStroke1};padding:0 ${spacingHorizontalM};min-width:96px;border-radius:${borderRadiusMedium};font-size:${fontSizeBase300};font-family:${fontFamilyBase};font-weight:${fontWeightSemibold};line-height:${lineHeightBase300};transition-duration:${durationFaster};transition-property:background,border,color;transition-timing-function:${curveEasyEase};cursor:pointer;user-select:none}.content{display:inherit}:host(:hover){background-color:${colorNeutralBackground1Hover};color:${colorNeutralForeground1Hover};border-color:${colorNeutralStroke1Hover}}:host(:hover:active){background-color:${colorNeutralBackground1Pressed};border-color:${colorNeutralStroke1Pressed};color:${colorNeutralForeground1Pressed};outline-style:none}:host(:focus-visible){border-color:${colorTransparentStroke};outline:${strokeWidthThick} solid ${colorTransparentStroke};box-shadow:${shadow4},0 0 0 2px ${colorStrokeFocus2}}@media screen and (prefers-reduced-motion:reduce){:host{transition-duration:0.01ms}}::slotted(svg){font-size:20px;height:20px;width:20px;fill:currentColor}::slotted([slot='start']){margin-inline-end:var(--icon-spacing)}::slotted([slot='end']),[slot='end']{flex-shrink:0;margin-inline-start:var(--icon-spacing)}:host(${iconOnlyState}){min-width:32px;max-width:32px}:host(${smallState}){--icon-spacing:${spacingHorizontalXS};min-height:24px;min-width:64px;padding:0 ${spacingHorizontalS};border-radius:${borderRadiusSmall};font-size:${fontSizeBase200};line-height:${lineHeightBase200};font-weight:${fontWeightRegular}}:host(${smallState}${iconOnlyState}){min-width:24px;max-width:24px}:host(${largeState}){min-height:40px;border-radius:${borderRadiusLarge};padding:0 ${spacingHorizontalL};font-size:${fontSizeBase400};line-height:${lineHeightBase400}}:host(${largeState}${iconOnlyState}){min-width:40px;max-width:40px}:host(${largeState}) ::slotted(svg){font-size:24px;height:24px;width:24px}:host(:is(${circularState},${circularState}:focus-visible)){border-radius:${borderRadiusCircular}}:host(:is(${squareState},${squareState}:focus-visible)){border-radius:${borderRadiusNone}}:host(${primaryState}){background-color:${colorBrandBackground};color:${colorNeutralForegroundOnBrand};border-color:transparent}:host(${primaryState}:hover){background-color:${colorBrandBackgroundHover}}:host(${primaryState}:is(:hover,:hover:active)){border-color:transparent;color:${colorNeutralForegroundOnBrand}}:host(${primaryState}:hover:active){background-color:${colorBrandBackgroundPressed}}:host(${primaryState}:focus-visible){border-color:${colorNeutralForegroundOnBrand};box-shadow:${shadow2},0 0 0 2px ${colorStrokeFocus2}}:host(${outlineState}){background-color:${colorTransparentBackground}}:host(${outlineState}:hover){background-color:${colorTransparentBackgroundHover}}:host(${outlineState}:hover:active){background-color:${colorTransparentBackgroundPressed}}:host(${subtleState}){background-color:${colorSubtleBackground};color:${colorNeutralForeground2};border-color:transparent}:host(${subtleState}:hover){background-color:${colorSubtleBackgroundHover};color:${colorNeutralForeground2Hover};border-color:transparent}:host(${subtleState}:hover:active){background-color:${colorSubtleBackgroundPressed};color:${colorNeutralForeground2Pressed};border-color:transparent}:host(${subtleState}:hover) ::slotted(svg){fill:${colorNeutralForeground2BrandHover}}:host(${subtleState}:hover:active) ::slotted(svg){fill:${colorNeutralForeground2BrandPressed}}:host(${transparentState}){background-color:${colorTransparentBackground};color:${colorNeutralForeground2}}:host(${transparentState}:hover){background-color:${colorTransparentBackgroundHover};color:${colorNeutralForeground2BrandHover}}:host(${transparentState}:hover:active){background-color:${colorTransparentBackgroundPressed};color:${colorNeutralForeground2BrandPressed}}:host(:is(${transparentState},${transparentState}:is(:hover,:active))){border-color:transparent}`;
|
|
5300
|
-
const styles$
|
|
5306
|
+
const styles$E = css`
|
|
5301
5307
|
${baseButtonStyles}
|
|
5302
5308
|
|
|
5303
5309
|
:host(:is(:disabled,[disabled-focusable],[appearance]:disabled,[appearance][disabled-focusable])),:host(:is(:disabled,[disabled-focusable],[appearance]:disabled,[appearance][disabled-focusable]):hover),:host(:is(:disabled,[disabled-focusable],[appearance]:disabled,[appearance][disabled-focusable]):hover:active){background-color:${colorNeutralBackgroundDisabled};border-color:${colorNeutralStrokeDisabled};color:${colorNeutralForegroundDisabled};cursor:not-allowed}:host(${primaryState}:is(:disabled,[disabled-focusable])),:host(${primaryState}:is(:disabled,[disabled-focusable]):is(:hover,:hover:active)){border-color:transparent}:host(${outlineState}:is(:disabled,[disabled-focusable])),:host(${outlineState}:is(:disabled,[disabled-focusable]):is(:hover,:hover:active)){background-color:${colorTransparentBackground}}:host(${subtleState}:is(:disabled,[disabled-focusable])),:host(${subtleState}:is(:disabled,[disabled-focusable]):is(:hover,:hover:active)){background-color:${colorTransparentBackground};border-color:transparent}:host(${transparentState}:is(:disabled,[disabled-focusable])),:host(${transparentState}:is(:disabled,[disabled-focusable]):is(:hover,:hover:active)){border-color:transparent;background-color:${colorTransparentBackground}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
5304
5310
|
:host{background-color:ButtonFace;color:ButtonText}:host(:is(:hover,:focus-visible)){border-color:Highlight !important}:host(${primaryState}:not(:is(:hover,:focus-visible))){background-color:Highlight;color:HighlightText;forced-color-adjust:none}:host(:is(:disabled,[disabled-focusable],[appearance]:disabled,[appearance][disabled-focusable])){background-color:ButtonFace;color:GrayText;border-color:ButtonText}`));
|
|
5305
5311
|
|
|
5306
|
-
const styles$
|
|
5312
|
+
const styles$D = css`
|
|
5307
5313
|
${baseButtonStyles}
|
|
5308
5314
|
|
|
5309
5315
|
::slotted(a){position:absolute;inset:0}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
@@ -5312,15 +5318,15 @@ const styles$B = css`
|
|
|
5312
5318
|
function anchorTemplate$1(options = {}) {
|
|
5313
5319
|
return html`<template tabindex="0" @click="${(x, c) => x.clickHandler(c.event)}" @keydown="${(x, c) => x.keydownHandler(c.event)}">${startSlotTemplate(options)}<span class="content" part="content"><slot></slot></span>${endSlotTemplate(options)}</template>`;
|
|
5314
5320
|
}
|
|
5315
|
-
const template$
|
|
5321
|
+
const template$F = anchorTemplate$1();
|
|
5316
5322
|
|
|
5317
|
-
const definition$
|
|
5323
|
+
const definition$F = AnchorButton.compose({
|
|
5318
5324
|
name: `${FluentDesignSystem.prefix}-anchor-button`,
|
|
5319
|
-
template: template$
|
|
5320
|
-
styles: styles$
|
|
5325
|
+
template: template$F,
|
|
5326
|
+
styles: styles$D
|
|
5321
5327
|
});
|
|
5322
5328
|
|
|
5323
|
-
definition$
|
|
5329
|
+
definition$F.define(FluentDesignSystem.registry);
|
|
5324
5330
|
|
|
5325
5331
|
const UNWANTED_ENCLOSURES_REGEX = /[\(\[\{][^\)\]\}]*[\)\]\}]/g;
|
|
5326
5332
|
const UNWANTED_CHARS_REGEX = /[\0-\u001F\!-/:-@\[-`\{-\u00BF\u0250-\u036F\uD800-\uFFFF]/g;
|
|
@@ -5363,12 +5369,12 @@ function getInitials(displayName, isRtl, options) {
|
|
|
5363
5369
|
return getInitialsLatin(displayName, isRtl, options?.firstInitialOnly);
|
|
5364
5370
|
}
|
|
5365
5371
|
|
|
5366
|
-
var __defProp$
|
|
5367
|
-
var __getOwnPropDesc$
|
|
5368
|
-
var __decorateClass$
|
|
5369
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
5372
|
+
var __defProp$M = Object.defineProperty;
|
|
5373
|
+
var __getOwnPropDesc$M = Object.getOwnPropertyDescriptor;
|
|
5374
|
+
var __decorateClass$M = (decorators, target, key, kind) => {
|
|
5375
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$M(target, key) : target;
|
|
5370
5376
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
5371
|
-
if (kind && result) __defProp$
|
|
5377
|
+
if (kind && result) __defProp$M(target, key, result);
|
|
5372
5378
|
return result;
|
|
5373
5379
|
};
|
|
5374
5380
|
class BaseAvatar extends FASTElement {
|
|
@@ -5383,9 +5389,9 @@ class BaseAvatar extends FASTElement {
|
|
|
5383
5389
|
this.elementInternals.role = "img";
|
|
5384
5390
|
}
|
|
5385
5391
|
}
|
|
5386
|
-
__decorateClass$
|
|
5387
|
-
__decorateClass$
|
|
5388
|
-
__decorateClass$
|
|
5392
|
+
__decorateClass$M([attr], BaseAvatar.prototype, "name", 2);
|
|
5393
|
+
__decorateClass$M([attr], BaseAvatar.prototype, "initials", 2);
|
|
5394
|
+
__decorateClass$M([attr], BaseAvatar.prototype, "active", 2);
|
|
5389
5395
|
|
|
5390
5396
|
const AvatarNamedColor = {
|
|
5391
5397
|
darkRed: "dark-red",
|
|
@@ -5426,12 +5432,12 @@ const AvatarColor = {
|
|
|
5426
5432
|
...AvatarNamedColor
|
|
5427
5433
|
};
|
|
5428
5434
|
|
|
5429
|
-
var __defProp$
|
|
5430
|
-
var __getOwnPropDesc$
|
|
5431
|
-
var __decorateClass$
|
|
5432
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
5435
|
+
var __defProp$L = Object.defineProperty;
|
|
5436
|
+
var __getOwnPropDesc$L = Object.getOwnPropertyDescriptor;
|
|
5437
|
+
var __decorateClass$L = (decorators, target, key, kind) => {
|
|
5438
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$L(target, key) : target;
|
|
5433
5439
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
5434
|
-
if (kind && result) __defProp$
|
|
5440
|
+
if (kind && result) __defProp$L(target, key, result);
|
|
5435
5441
|
return result;
|
|
5436
5442
|
};
|
|
5437
5443
|
const _Avatar = class _Avatar extends BaseAvatar {
|
|
@@ -5486,13 +5492,13 @@ const _Avatar = class _Avatar extends BaseAvatar {
|
|
|
5486
5492
|
* An array of the available Avatar named colors
|
|
5487
5493
|
*/
|
|
5488
5494
|
_Avatar.colors = Object.values(AvatarNamedColor);
|
|
5489
|
-
__decorateClass$
|
|
5490
|
-
__decorateClass$
|
|
5491
|
-
__decorateClass$
|
|
5495
|
+
__decorateClass$L([attr], _Avatar.prototype, "shape", 2);
|
|
5496
|
+
__decorateClass$L([attr], _Avatar.prototype, "appearance", 2);
|
|
5497
|
+
__decorateClass$L([attr({
|
|
5492
5498
|
converter: nullableNumberConverter
|
|
5493
5499
|
})], _Avatar.prototype, "size", 2);
|
|
5494
|
-
__decorateClass$
|
|
5495
|
-
__decorateClass$
|
|
5500
|
+
__decorateClass$L([attr], _Avatar.prototype, "color", 2);
|
|
5501
|
+
__decorateClass$L([attr({
|
|
5496
5502
|
attribute: "color-id"
|
|
5497
5503
|
})], _Avatar.prototype, "colorId", 2);
|
|
5498
5504
|
let Avatar = _Avatar;
|
|
@@ -5517,22 +5523,22 @@ const animations = {
|
|
|
5517
5523
|
normalEase: curveEasyEase,
|
|
5518
5524
|
nullEasing: curveLinear
|
|
5519
5525
|
};
|
|
5520
|
-
const styles$
|
|
5526
|
+
const styles$C = css`
|
|
5521
5527
|
${display("inline-flex")} :host{position:relative;align-items:center;justify-content:center;flex-shrink:0;width:32px;height:32px;font-family:${fontFamilyBase};font-weight:${fontWeightSemibold};font-size:${fontSizeBase300};border-radius:${borderRadiusCircular};color:${colorNeutralForeground3};background-color:${colorNeutralBackground6};contain:layout style}.default-icon,::slotted(svg){width:20px;height:20px;font-size:20px}::slotted(img){box-sizing:border-box;width:100%;height:100%;border-radius:${borderRadiusCircular}}::slotted([slot='badge']){position:absolute;bottom:0;right:0;box-shadow:0 0 0 ${strokeWidthThin}) ${colorNeutralBackground1}}:host([size='64']) ::slotted([slot='badge']),:host([size='72']) ::slotted([slot='badge']),:host([size='96']) ::slotted([slot='badge']),:host([size='120']) ::slotted([slot='badge']),:host([size='128']) ::slotted([slot='badge']){box-shadow:0 0 0 ${strokeWidthThick}) ${colorNeutralBackground1}}:host([size='16']),:host([size='20']),:host([size='24']){font-size:${fontSizeBase100};font-weight:${fontWeightRegular}}:host([size='16']){width:16px;height:16px}:host([size='20']){width:20px;height:20px}:host([size='24']){width:24px;height:24px}:host([size='16']) .default-icon,:host([size='16']) ::slotted(svg){width:12px;height:12px;font-size:12px}:host([size='20']) .default-icon,:host([size='24']) .default-icon,:host([size='20']) ::slotted(svg),:host([size='24']) ::slotted(svg){width:16px;height:16px;font-size:16px}:host([size='28']){width:28px;height:28px;font-size:${fontSizeBase200}}:host([size='36']){width:36px;height:36px}:host([size='40']){width:40px;height:40px}:host([size='48']),:host([size='56']){font-size:${fontSizeBase400}}:host([size='48']){width:48px;height:48px}:host([size='48']) .default-icon,:host([size='48']) ::slotted(svg){width:24px;height:24px;font-size:24px}:host([size='56']){width:56px;height:56px}:host([size='56']) .default-icon,:host([size='56']) ::slotted(svg){width:28px;height:28px;font-size:28px}:host([size='64']),:host([size='72']),:host([size='96']){font-size:${fontSizeBase500}}:host([size='64']) .default-icon,:host([size='72']) .default-icon,:host([size='64']) ::slotted(svg),:host([size='72']) ::slotted(svg){width:32px;height:32px;font-size:32px}:host([size='64']){width:64px;height:64px}:host([size='72']){width:72px;height:72px}:host([size='96']){width:96px;height:96px}:host([size='96']) .default-icon,:host([size='120']) .default-icon,:host([size='128']) .default-icon,:host([size='96']) ::slotted(svg),:host([size='120']) ::slotted(svg),:host([size='128']) ::slotted(svg){width:48px;height:48px;font-size:48px}:host([size='120']),:host([size='128']){font-size:${fontSizeBase600}}:host([size='120']){width:120px;height:120px}:host([size='128']){width:128px;height:128px}:host([shape='square']){border-radius:${borderRadiusMedium}}:host([shape='square'][size='20']),:host([shape='square'][size='24']){border-radius:${borderRadiusSmall}}:host([shape='square'][size='56']),:host([shape='square'][size='64']),:host([shape='square'][size='72']){border-radius:${borderRadiusLarge}}:host([shape='square'][size='96']),:host([shape='square'][size='120']),:host([shape='square'][size='128']){border-radius:${borderRadiusXLarge}}:host(${brandState}){color:${colorNeutralForegroundStaticInverted};background-color:${colorBrandBackgroundStatic}}:host(${darkRedState}){color:${colorPaletteDarkRedForeground2};background-color:${colorPaletteDarkRedBackground2}}:host(${cranberryState}){color:${colorPaletteCranberryForeground2};background-color:${colorPaletteCranberryBackground2}}:host(${redState}){color:${colorPaletteRedForeground2};background-color:${colorPaletteRedBackground2}}:host(${pumpkinState}){color:${colorPalettePumpkinForeground2};background-color:${colorPalettePumpkinBackground2}}:host(${peachState}){color:${colorPalettePeachForeground2};background-color:${colorPalettePeachBackground2}}:host(${marigoldState}){color:${colorPaletteMarigoldForeground2};background-color:${colorPaletteMarigoldBackground2}}:host(${goldState}){color:${colorPaletteGoldForeground2};background-color:${colorPaletteGoldBackground2}}:host(${brassState}){color:${colorPaletteBrassForeground2};background-color:${colorPaletteBrassBackground2}}:host(${brownState}){color:${colorPaletteBrownForeground2};background-color:${colorPaletteBrownBackground2}}:host(${forestState}){color:${colorPaletteForestForeground2};background-color:${colorPaletteForestBackground2}}:host(${seafoamState}){color:${colorPaletteSeafoamForeground2};background-color:${colorPaletteSeafoamBackground2}}:host(${darkGreenState}){color:${colorPaletteDarkGreenForeground2};background-color:${colorPaletteDarkGreenBackground2}}:host(${lightTealState}){color:${colorPaletteLightTealForeground2};background-color:${colorPaletteLightTealBackground2}}:host(${tealState}){color:${colorPaletteTealForeground2};background-color:${colorPaletteTealBackground2}}:host(${steelState}){color:${colorPaletteSteelForeground2};background-color:${colorPaletteSteelBackground2}}:host(${blueState}){color:${colorPaletteBlueForeground2};background-color:${colorPaletteBlueBackground2}}:host(${royalBlueState}){color:${colorPaletteRoyalBlueForeground2};background-color:${colorPaletteRoyalBlueBackground2}}:host(${cornflowerState}){color:${colorPaletteCornflowerForeground2};background-color:${colorPaletteCornflowerBackground2}}:host(${navyState}){color:${colorPaletteNavyForeground2};background-color:${colorPaletteNavyBackground2}}:host(${lavenderState}){color:${colorPaletteLavenderForeground2};background-color:${colorPaletteLavenderBackground2}}:host(${purpleState}){color:${colorPalettePurpleForeground2};background-color:${colorPalettePurpleBackground2}}:host(${grapeState}){color:${colorPaletteGrapeForeground2};background-color:${colorPaletteGrapeBackground2}}:host(${lilacState}){color:${colorPaletteLilacForeground2};background-color:${colorPaletteLilacBackground2}}:host(${pinkState}){color:${colorPalettePinkForeground2};background-color:${colorPalettePinkBackground2}}:host(${magentaState}){color:${colorPaletteMagentaForeground2};background-color:${colorPaletteMagentaBackground2}}:host(${plumState}){color:${colorPalettePlumForeground2};background-color:${colorPalettePlumBackground2}}:host(${beigeState}){color:${colorPaletteBeigeForeground2};background-color:${colorPaletteBeigeBackground2}}:host(${minkState}){color:${colorPaletteMinkForeground2};background-color:${colorPaletteMinkBackground2}}:host(${platinumState}){color:${colorPalettePlatinumForeground2};background-color:${colorPalettePlatinumBackground2}}:host(${anchorState}){color:${colorPaletteAnchorForeground2};background-color:${colorPaletteAnchorBackground2}}:host([active]){transform:perspective(1px);transition-property:transform,opacity;transition-duration:${durationUltraSlow},${durationFaster};transition-delay:${animations.fastEase},${animations.nullEasing}}:host([active])::before{content:'';position:absolute;top:0;left:0;bottom:0;right:0;border-radius:inherit;transition-property:margin,opacity;transition-duration:${durationUltraSlow}),${durationSlower};transition-delay:${animations.fastEase}),${animations.nullEasing})}:host([active])::before{box-shadow:${shadow8};border-style:solid;border-color:${colorBrandBackgroundStatic}}:host([active][appearance='shadow'])::before{border-style:none;border-color:none}:host([active]:not([appearance='shadow']))::before{margin:calc(-2 * ${strokeWidthThick});border-width:${strokeWidthThick}}:host([size='56'][active]:not([appearance='shadow']))::before,:host([size='64'][active]:not([appearance='shadow']))::before{margin:calc(-2 * ${strokeWidthThicker});border-width:${strokeWidthThicker}}:host([size='72'][active]:not([appearance='shadow']))::before,:host([size='96'][active]:not([appearance='shadow']))::before,:host([size='120'][active]:not([appearance='shadow']))::before,:host([size='128'][active]:not([appearance='shadow']))::before{margin:calc(-2 * ${strokeWidthThickest});border-width:${strokeWidthThickest}}:host([size='20'][active][appearance])::before,:host([size='24'][active][appearance])::before,:host([size='28'][active][appearance])::before{box-shadow:${shadow4}}:host([size='56'][active][appearance])::before,:host([size='64'][active][appearance])::before{box-shadow:${shadow16}}:host([size='72'][active][appearance])::before,:host([size='96'][active][appearance])::before,:host([size='120'][active][appearance])::before,:host([size='128'][active][appearance])::before{box-shadow:${shadow28}}:host([active][appearance='ring'])::before{box-shadow:none}:host([active='inactive']){opacity:0.8;transform:scale(0.875);transition-property:transform,opacity;transition-duration:${durationUltraSlow},${durationFaster};transition-delay:${animations.fastOutSlowInMin},${animations.nullEasing}}:host([active='inactive'])::before{margin:0;opacity:0;transition-property:margin,opacity;transition-duration:${durationUltraSlow},${durationSlower};transition-delay:${animations.fastOutSlowInMin},${animations.nullEasing}}@media screen and (prefers-reduced-motion:reduce){:host([active]){transition-duration:0.01ms}:host([active])::before{transition-duration:0.01ms;transition-delay:0.01ms}}`;
|
|
5522
5528
|
|
|
5523
5529
|
const defaultIconTemplate = html`<svg width="1em" height="1em" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg" class="default-icon" fill="currentcolor" aria-hidden="true"><path d="M10 2a4 4 0 100 8 4 4 0 000-8zM7 6a3 3 0 116 0 3 3 0 01-6 0zm-2 5a2 2 0 00-2 2c0 1.7.83 2.97 2.13 3.8A9.14 9.14 0 0010 18c1.85 0 3.58-.39 4.87-1.2A4.35 4.35 0 0017 13a2 2 0 00-2-2H5zm-1 2a1 1 0 011-1h10a1 1 0 011 1c0 1.3-.62 2.28-1.67 2.95A8.16 8.16 0 0110 17a8.16 8.16 0 01-4.33-1.05A3.36 3.36 0 014 13z"></path></svg>`;
|
|
5524
5530
|
function avatarTemplate() {
|
|
5525
5531
|
return html`<slot>${x => x.name || x.initials ? x.generateInitials() : defaultIconTemplate}</slot><slot name="badge"></slot>`;
|
|
5526
5532
|
}
|
|
5527
|
-
const template$
|
|
5533
|
+
const template$E = avatarTemplate();
|
|
5528
5534
|
|
|
5529
|
-
const definition$
|
|
5535
|
+
const definition$E = Avatar.compose({
|
|
5530
5536
|
name: `${FluentDesignSystem.prefix}-avatar`,
|
|
5531
|
-
template: template$
|
|
5532
|
-
styles: styles$
|
|
5537
|
+
template: template$E,
|
|
5538
|
+
styles: styles$C
|
|
5533
5539
|
});
|
|
5534
5540
|
|
|
5535
|
-
definition$
|
|
5541
|
+
definition$E.define(FluentDesignSystem.registry);
|
|
5536
5542
|
|
|
5537
5543
|
const BadgeAppearance = {
|
|
5538
5544
|
filled: "filled",
|
|
@@ -5564,12 +5570,12 @@ const BadgeSize = {
|
|
|
5564
5570
|
extraLarge: "extra-large"
|
|
5565
5571
|
};
|
|
5566
5572
|
|
|
5567
|
-
var __defProp$
|
|
5568
|
-
var __getOwnPropDesc$
|
|
5569
|
-
var __decorateClass$
|
|
5570
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
5573
|
+
var __defProp$K = Object.defineProperty;
|
|
5574
|
+
var __getOwnPropDesc$K = Object.getOwnPropertyDescriptor;
|
|
5575
|
+
var __decorateClass$K = (decorators, target, key, kind) => {
|
|
5576
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$K(target, key) : target;
|
|
5571
5577
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
5572
|
-
if (kind && result) __defProp$
|
|
5578
|
+
if (kind && result) __defProp$K(target, key, result);
|
|
5573
5579
|
return result;
|
|
5574
5580
|
};
|
|
5575
5581
|
class Badge extends FASTElement {
|
|
@@ -5617,10 +5623,10 @@ class Badge extends FASTElement {
|
|
|
5617
5623
|
swapStates(this.elementInternals, prev, next, BadgeSize);
|
|
5618
5624
|
}
|
|
5619
5625
|
}
|
|
5620
|
-
__decorateClass$
|
|
5621
|
-
__decorateClass$
|
|
5622
|
-
__decorateClass$
|
|
5623
|
-
__decorateClass$
|
|
5626
|
+
__decorateClass$K([attr], Badge.prototype, "appearance", 2);
|
|
5627
|
+
__decorateClass$K([attr], Badge.prototype, "color", 2);
|
|
5628
|
+
__decorateClass$K([attr], Badge.prototype, "shape", 2);
|
|
5629
|
+
__decorateClass$K([attr], Badge.prototype, "size", 2);
|
|
5624
5630
|
applyMixins(Badge, StartEnd);
|
|
5625
5631
|
|
|
5626
5632
|
const badgeBaseStyles = css.partial`
|
|
@@ -5974,7 +5980,7 @@ css.partial`
|
|
|
5974
5980
|
font-weight: ${fontWeightSemibold};
|
|
5975
5981
|
`;
|
|
5976
5982
|
|
|
5977
|
-
const styles$
|
|
5983
|
+
const styles$B = css`
|
|
5978
5984
|
:host(${squareState}){border-radius:${borderRadiusNone}}:host(${roundedState}){border-radius:${borderRadiusMedium}}:host(${roundedState}${tinyState}),:host(${roundedState}${extraSmallState}),:host(${roundedState}${smallState}){border-radius:${borderRadiusSmall}}${badgeSizeStyles}
|
|
5979
5985
|
${badgeFilledStyles}
|
|
5980
5986
|
${badgeGhostStyles}
|
|
@@ -5987,22 +5993,22 @@ const styles$z = css`
|
|
|
5987
5993
|
function badgeTemplate(options = {}) {
|
|
5988
5994
|
return html` ${startSlotTemplate(options)}<slot>${staticallyCompose(options.defaultContent)}</slot>${endSlotTemplate(options)} `;
|
|
5989
5995
|
}
|
|
5990
|
-
const template$
|
|
5996
|
+
const template$D = badgeTemplate();
|
|
5991
5997
|
|
|
5992
|
-
const definition$
|
|
5998
|
+
const definition$D = Badge.compose({
|
|
5993
5999
|
name: `${FluentDesignSystem.prefix}-badge`,
|
|
5994
|
-
template: template$
|
|
5995
|
-
styles: styles$
|
|
6000
|
+
template: template$D,
|
|
6001
|
+
styles: styles$B
|
|
5996
6002
|
});
|
|
5997
6003
|
|
|
5998
|
-
definition$
|
|
6004
|
+
definition$D.define(FluentDesignSystem.registry);
|
|
5999
6005
|
|
|
6000
|
-
var __defProp$
|
|
6001
|
-
var __getOwnPropDesc$
|
|
6002
|
-
var __decorateClass$
|
|
6003
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6006
|
+
var __defProp$J = Object.defineProperty;
|
|
6007
|
+
var __getOwnPropDesc$J = Object.getOwnPropertyDescriptor;
|
|
6008
|
+
var __decorateClass$J = (decorators, target, key, kind) => {
|
|
6009
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$J(target, key) : target;
|
|
6004
6010
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6005
|
-
if (kind && result) __defProp$
|
|
6011
|
+
if (kind && result) __defProp$J(target, key, result);
|
|
6006
6012
|
return result;
|
|
6007
6013
|
};
|
|
6008
6014
|
class BaseButton extends FASTElement {
|
|
@@ -6206,51 +6212,51 @@ class BaseButton extends FASTElement {
|
|
|
6206
6212
|
* @public
|
|
6207
6213
|
*/
|
|
6208
6214
|
BaseButton.formAssociated = true;
|
|
6209
|
-
__decorateClass$
|
|
6215
|
+
__decorateClass$J([attr({
|
|
6210
6216
|
mode: "boolean"
|
|
6211
6217
|
})], BaseButton.prototype, "autofocus", 2);
|
|
6212
|
-
__decorateClass$
|
|
6213
|
-
__decorateClass$
|
|
6218
|
+
__decorateClass$J([observable], BaseButton.prototype, "defaultSlottedContent", 2);
|
|
6219
|
+
__decorateClass$J([attr({
|
|
6214
6220
|
mode: "boolean"
|
|
6215
6221
|
})], BaseButton.prototype, "disabled", 2);
|
|
6216
|
-
__decorateClass$
|
|
6222
|
+
__decorateClass$J([attr({
|
|
6217
6223
|
attribute: "disabled-focusable",
|
|
6218
6224
|
mode: "boolean"
|
|
6219
6225
|
})], BaseButton.prototype, "disabledFocusable", 2);
|
|
6220
|
-
__decorateClass$
|
|
6226
|
+
__decorateClass$J([attr({
|
|
6221
6227
|
attribute: "tabindex",
|
|
6222
6228
|
mode: "fromView",
|
|
6223
6229
|
converter: nullableNumberConverter
|
|
6224
6230
|
})], BaseButton.prototype, "tabIndex", 2);
|
|
6225
|
-
__decorateClass$
|
|
6231
|
+
__decorateClass$J([attr({
|
|
6226
6232
|
attribute: "formaction"
|
|
6227
6233
|
})], BaseButton.prototype, "formAction", 2);
|
|
6228
|
-
__decorateClass$
|
|
6234
|
+
__decorateClass$J([attr({
|
|
6229
6235
|
attribute: "form"
|
|
6230
6236
|
})], BaseButton.prototype, "formAttribute", 2);
|
|
6231
|
-
__decorateClass$
|
|
6237
|
+
__decorateClass$J([attr({
|
|
6232
6238
|
attribute: "formenctype"
|
|
6233
6239
|
})], BaseButton.prototype, "formEnctype", 2);
|
|
6234
|
-
__decorateClass$
|
|
6240
|
+
__decorateClass$J([attr({
|
|
6235
6241
|
attribute: "formmethod"
|
|
6236
6242
|
})], BaseButton.prototype, "formMethod", 2);
|
|
6237
|
-
__decorateClass$
|
|
6243
|
+
__decorateClass$J([attr({
|
|
6238
6244
|
attribute: "formnovalidate",
|
|
6239
6245
|
mode: "boolean"
|
|
6240
6246
|
})], BaseButton.prototype, "formNoValidate", 2);
|
|
6241
|
-
__decorateClass$
|
|
6247
|
+
__decorateClass$J([attr({
|
|
6242
6248
|
attribute: "formtarget"
|
|
6243
6249
|
})], BaseButton.prototype, "formTarget", 2);
|
|
6244
|
-
__decorateClass$
|
|
6245
|
-
__decorateClass$
|
|
6246
|
-
__decorateClass$
|
|
6250
|
+
__decorateClass$J([attr], BaseButton.prototype, "name", 2);
|
|
6251
|
+
__decorateClass$J([attr], BaseButton.prototype, "type", 2);
|
|
6252
|
+
__decorateClass$J([attr], BaseButton.prototype, "value", 2);
|
|
6247
6253
|
|
|
6248
|
-
var __defProp$
|
|
6249
|
-
var __getOwnPropDesc$
|
|
6250
|
-
var __decorateClass$
|
|
6251
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6254
|
+
var __defProp$I = Object.defineProperty;
|
|
6255
|
+
var __getOwnPropDesc$I = Object.getOwnPropertyDescriptor;
|
|
6256
|
+
var __decorateClass$I = (decorators, target, key, kind) => {
|
|
6257
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$I(target, key) : target;
|
|
6252
6258
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6253
|
-
if (kind && result) __defProp$
|
|
6259
|
+
if (kind && result) __defProp$I(target, key, result);
|
|
6254
6260
|
return result;
|
|
6255
6261
|
};
|
|
6256
6262
|
class Button extends BaseButton {
|
|
@@ -6291,10 +6297,10 @@ class Button extends BaseButton {
|
|
|
6291
6297
|
toggleState(this.elementInternals, "icon", next);
|
|
6292
6298
|
}
|
|
6293
6299
|
}
|
|
6294
|
-
__decorateClass$
|
|
6295
|
-
__decorateClass$
|
|
6296
|
-
__decorateClass$
|
|
6297
|
-
__decorateClass$
|
|
6300
|
+
__decorateClass$I([attr], Button.prototype, "appearance", 2);
|
|
6301
|
+
__decorateClass$I([attr], Button.prototype, "shape", 2);
|
|
6302
|
+
__decorateClass$I([attr], Button.prototype, "size", 2);
|
|
6303
|
+
__decorateClass$I([attr({
|
|
6298
6304
|
attribute: "icon-only",
|
|
6299
6305
|
mode: "boolean"
|
|
6300
6306
|
})], Button.prototype, "iconOnly", 2);
|
|
@@ -6303,22 +6309,22 @@ applyMixins(Button, StartEnd);
|
|
|
6303
6309
|
function buttonTemplate$1(options = {}) {
|
|
6304
6310
|
return html`<template tabindex="${x => x.disabled ? null : x.tabIndex ?? 0}" @click="${(x, c) => x.clickHandler(c.event)}" @keypress="${(x, c) => x.keypressHandler(c.event)}">${startSlotTemplate(options)}<span class="content" part="content"><slot ${slotted("defaultSlottedContent")}></slot></span>${endSlotTemplate(options)}</template>`;
|
|
6305
6311
|
}
|
|
6306
|
-
const template$
|
|
6312
|
+
const template$C = buttonTemplate$1();
|
|
6307
6313
|
|
|
6308
|
-
const definition$
|
|
6314
|
+
const definition$C = Button.compose({
|
|
6309
6315
|
name: `${FluentDesignSystem.prefix}-button`,
|
|
6310
|
-
template: template$
|
|
6311
|
-
styles: styles$
|
|
6316
|
+
template: template$C,
|
|
6317
|
+
styles: styles$E
|
|
6312
6318
|
});
|
|
6313
6319
|
|
|
6314
|
-
definition$
|
|
6320
|
+
definition$C.define(FluentDesignSystem.registry);
|
|
6315
6321
|
|
|
6316
|
-
var __defProp$
|
|
6317
|
-
var __getOwnPropDesc$
|
|
6318
|
-
var __decorateClass$
|
|
6319
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6322
|
+
var __defProp$H = Object.defineProperty;
|
|
6323
|
+
var __getOwnPropDesc$H = Object.getOwnPropertyDescriptor;
|
|
6324
|
+
var __decorateClass$H = (decorators, target, key, kind) => {
|
|
6325
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$H(target, key) : target;
|
|
6320
6326
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6321
|
-
if (kind && result) __defProp$
|
|
6327
|
+
if (kind && result) __defProp$H(target, key, result);
|
|
6322
6328
|
return result;
|
|
6323
6329
|
};
|
|
6324
6330
|
class BaseCheckbox extends FASTElement {
|
|
@@ -6652,27 +6658,27 @@ class BaseCheckbox extends FASTElement {
|
|
|
6652
6658
|
* @public
|
|
6653
6659
|
*/
|
|
6654
6660
|
BaseCheckbox.formAssociated = true;
|
|
6655
|
-
__decorateClass$
|
|
6661
|
+
__decorateClass$H([attr({
|
|
6656
6662
|
mode: "boolean"
|
|
6657
6663
|
})], BaseCheckbox.prototype, "autofocus", 2);
|
|
6658
|
-
__decorateClass$
|
|
6659
|
-
__decorateClass$
|
|
6664
|
+
__decorateClass$H([observable], BaseCheckbox.prototype, "disabled", 2);
|
|
6665
|
+
__decorateClass$H([attr({
|
|
6660
6666
|
attribute: "disabled",
|
|
6661
6667
|
mode: "boolean"
|
|
6662
6668
|
})], BaseCheckbox.prototype, "disabledAttribute", 2);
|
|
6663
|
-
__decorateClass$
|
|
6669
|
+
__decorateClass$H([attr({
|
|
6664
6670
|
attribute: "form"
|
|
6665
6671
|
})], BaseCheckbox.prototype, "formAttribute", 2);
|
|
6666
|
-
__decorateClass$
|
|
6672
|
+
__decorateClass$H([attr({
|
|
6667
6673
|
attribute: "checked",
|
|
6668
6674
|
mode: "boolean"
|
|
6669
6675
|
})], BaseCheckbox.prototype, "initialChecked", 2);
|
|
6670
|
-
__decorateClass$
|
|
6676
|
+
__decorateClass$H([attr({
|
|
6671
6677
|
attribute: "value",
|
|
6672
6678
|
mode: "fromView"
|
|
6673
6679
|
})], BaseCheckbox.prototype, "initialValue", 2);
|
|
6674
|
-
__decorateClass$
|
|
6675
|
-
__decorateClass$
|
|
6680
|
+
__decorateClass$H([attr], BaseCheckbox.prototype, "name", 2);
|
|
6681
|
+
__decorateClass$H([attr({
|
|
6676
6682
|
mode: "boolean"
|
|
6677
6683
|
})], BaseCheckbox.prototype, "required", 2);
|
|
6678
6684
|
|
|
@@ -6685,12 +6691,12 @@ const CheckboxSize = {
|
|
|
6685
6691
|
large: "large"
|
|
6686
6692
|
};
|
|
6687
6693
|
|
|
6688
|
-
var __defProp$
|
|
6689
|
-
var __getOwnPropDesc$
|
|
6690
|
-
var __decorateClass$
|
|
6691
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6694
|
+
var __defProp$G = Object.defineProperty;
|
|
6695
|
+
var __getOwnPropDesc$G = Object.getOwnPropertyDescriptor;
|
|
6696
|
+
var __decorateClass$G = (decorators, target, key, kind) => {
|
|
6697
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$G(target, key) : target;
|
|
6692
6698
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6693
|
-
if (kind && result) __defProp$
|
|
6699
|
+
if (kind && result) __defProp$G(target, key, result);
|
|
6694
6700
|
return result;
|
|
6695
6701
|
};
|
|
6696
6702
|
class Checkbox extends BaseCheckbox {
|
|
@@ -6753,11 +6759,11 @@ class Checkbox extends BaseCheckbox {
|
|
|
6753
6759
|
super.toggleChecked(force);
|
|
6754
6760
|
}
|
|
6755
6761
|
}
|
|
6756
|
-
__decorateClass$
|
|
6757
|
-
__decorateClass$
|
|
6758
|
-
__decorateClass$
|
|
6762
|
+
__decorateClass$G([observable], Checkbox.prototype, "indeterminate", 2);
|
|
6763
|
+
__decorateClass$G([attr], Checkbox.prototype, "shape", 2);
|
|
6764
|
+
__decorateClass$G([attr], Checkbox.prototype, "size", 2);
|
|
6759
6765
|
|
|
6760
|
-
const styles$
|
|
6766
|
+
const styles$A = css`
|
|
6761
6767
|
${display("inline-flex")}
|
|
6762
6768
|
|
|
6763
6769
|
:host{--size:16px;background-color:${colorNeutralBackground1};border-radius:${borderRadiusSmall};border:${strokeWidthThin} solid ${colorNeutralStrokeAccessible};box-sizing:border-box;cursor:pointer;position:relative;width:var(--size)}:host,.indeterminate-indicator,.checked-indicator{aspect-ratio:1}:host(:hover){border-color:${colorNeutralStrokeAccessibleHover}}:host(:active){border-color:${colorNeutralStrokeAccessiblePressed}}:host(${checkedState}:hover){background-color:${colorCompoundBrandBackgroundHover};border-color:${colorCompoundBrandStrokeHover}}:host(${checkedState}:active){background-color:${colorCompoundBrandBackgroundPressed};border-color:${colorCompoundBrandStrokePressed}}:host(:focus-visible){outline:none}:host(:not([slot='input']))::after{content:'';position:absolute;inset:-8px;box-sizing:border-box;outline:none;border:${strokeWidthThick} solid ${colorTransparentStroke};border-radius:${borderRadiusMedium}}:host(:not([slot='input']):focus-visible)::after{border-color:${colorStrokeFocus2}}.indeterminate-indicator,.checked-indicator{color:${colorNeutralForegroundInverted};inset:0;margin:auto;position:absolute}::slotted([slot='checked-indicator']),.checked-indicator{fill:currentColor;display:inline-flex;flex:1 0 auto;width:12px}:host(:not(${checkedState})) *:is(::slotted([slot='checked-indicator']),.checked-indicator){display:none}:host(${checkedState}),:host(${indeterminateState}){border-color:${colorCompoundBrandStroke}}:host(${checkedState}),:host(${indeterminateState}) .indeterminate-indicator{background-color:${colorCompoundBrandBackground}}:host(${indeterminateState}) .indeterminate-indicator{border-radius:${borderRadiusSmall};position:absolute;width:calc(var(--size) / 2);inset:0}:host(${largeState}){--size:20px}:host(${largeState}) ::slotted([slot='checked-indicator']),:host(${largeState}) .checked-indicator{width:16px}:host(${circularState}),:host(${circularState}) .indeterminate-indicator{border-radius:${borderRadiusCircular}}:host([disabled]),:host([disabled]${checkedState}){background-color:${colorNeutralBackgroundDisabled};border-color:${colorNeutralStrokeDisabled}}:host([disabled]){cursor:unset}:host([disabled]${indeterminateState}) .indeterminate-indicator{background-color:${colorNeutralStrokeDisabled}}:host([disabled]${checkedState}) .checked-indicator{color:${colorNeutralStrokeDisabled}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
@@ -6783,23 +6789,23 @@ const indeterminateIndicator = html.partial( /* html */
|
|
|
6783
6789
|
function checkboxTemplate(options = {}) {
|
|
6784
6790
|
return html`<template tabindex="${x => !x.disabled ? 0 : void 0}" @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="checked-indicator">${staticallyCompose(options.checkedIndicator)}</slot><slot name="indeterminate-indicator">${staticallyCompose(options.indeterminateIndicator)}</slot></template>`;
|
|
6785
6791
|
}
|
|
6786
|
-
const template$
|
|
6792
|
+
const template$B = checkboxTemplate({
|
|
6787
6793
|
checkedIndicator: checkedIndicator$2,
|
|
6788
6794
|
indeterminateIndicator
|
|
6789
6795
|
});
|
|
6790
6796
|
|
|
6791
|
-
const definition$
|
|
6797
|
+
const definition$B = Checkbox.compose({
|
|
6792
6798
|
name: `${FluentDesignSystem.prefix}-checkbox`,
|
|
6793
|
-
template: template$
|
|
6794
|
-
styles: styles$
|
|
6799
|
+
template: template$B,
|
|
6800
|
+
styles: styles$A
|
|
6795
6801
|
});
|
|
6796
6802
|
|
|
6797
|
-
definition$
|
|
6803
|
+
definition$B.define(FluentDesignSystem.registry);
|
|
6798
6804
|
|
|
6799
6805
|
class CompoundButton extends Button {}
|
|
6800
6806
|
|
|
6801
|
-
const styles$
|
|
6802
|
-
${styles$
|
|
6807
|
+
const styles$z = css`
|
|
6808
|
+
${styles$E}
|
|
6803
6809
|
|
|
6804
6810
|
:host,:host(:is([size])){gap:12px;height:auto;padding-top:14px;padding-inline:12px;padding-bottom:16px;font-size:${fontSizeBase300};line-height:${lineHeightBase300}}.content{display:flex;flex-direction:column;text-align:start}::slotted([slot='description']){color:${colorNeutralForeground2};line-height:100%;font-size:${fontSizeBase200};font-weight:${fontWeightRegular}}::slotted(svg),:host(${largeState}) ::slotted(svg){font-size:40px;height:40px;width:40px}:host(:hover) ::slotted([slot='description']){color:${colorNeutralForeground2Hover}}:host(:active) ::slotted([slot='description']){color:${colorNeutralForeground2Pressed}}:host(:is(${primaryState},${primaryState}:hover,${primaryState}:active)) ::slotted([slot='description']){color:${colorNeutralForegroundOnBrand}}:host(:is(${subtleState},${subtleState}:hover,${subtleState}:active)) ::slotted([slot='description']),:host(${transparentState}) ::slotted([slot='description']){color:${colorNeutralForeground2}}:host(${transparentState}:hover) ::slotted([slot='description']){color:${colorNeutralForeground2BrandHover}}:host(${transparentState}:active) ::slotted([slot='description']){color:${colorNeutralForeground2BrandPressed}}:host(:is(:disabled,:disabled[appearance],[disabled-focusable],[disabled-focusable][appearance]))
|
|
6805
6811
|
::slotted([slot='description']){color:${colorNeutralForegroundDisabled}}:host(${smallState}){padding:8px;padding-bottom:10px}:host(${iconOnlyState}){min-width:52px;max-width:52px;padding:${spacingHorizontalSNudge}}:host(${iconOnlyState}${smallState}){min-width:48px;max-width:48px;padding:${spacingHorizontalXS}}:host(${iconOnlyState}${largeState}){min-width:56px;max-width:56px;padding:${spacingHorizontalS}}:host(${largeState}){padding-top:18px;padding-inline:16px;padding-bottom:20px;font-size:${fontSizeBase400};line-height:${lineHeightBase400}}:host(${largeState}) ::slotted([slot='description']){font-size:${fontSizeBase300}}`;
|
|
@@ -6807,15 +6813,15 @@ const styles$x = css`
|
|
|
6807
6813
|
function buttonTemplate(options = {}) {
|
|
6808
6814
|
return html`<template ?disabled="${x => x.disabled}" tabindex="${x => x.disabled ? null : x.tabIndex ?? 0}">${startSlotTemplate(options)}<span class="content" part="content"><slot ${slotted("defaultSlottedContent")}></slot><slot name="description"></slot></span>${endSlotTemplate(options)}</template>`;
|
|
6809
6815
|
}
|
|
6810
|
-
const template$
|
|
6816
|
+
const template$A = buttonTemplate();
|
|
6811
6817
|
|
|
6812
|
-
const definition$
|
|
6818
|
+
const definition$A = CompoundButton.compose({
|
|
6813
6819
|
name: `${FluentDesignSystem.prefix}-compound-button`,
|
|
6814
|
-
template: template$
|
|
6815
|
-
styles: styles$
|
|
6820
|
+
template: template$A,
|
|
6821
|
+
styles: styles$z
|
|
6816
6822
|
});
|
|
6817
6823
|
|
|
6818
|
-
definition$
|
|
6824
|
+
definition$A.define(FluentDesignSystem.registry);
|
|
6819
6825
|
|
|
6820
6826
|
const CounterBadgeAppearance = {
|
|
6821
6827
|
filled: "filled",
|
|
@@ -6844,12 +6850,12 @@ const CounterBadgeSize = {
|
|
|
6844
6850
|
extraLarge: "extra-large"
|
|
6845
6851
|
};
|
|
6846
6852
|
|
|
6847
|
-
var __defProp$
|
|
6848
|
-
var __getOwnPropDesc$
|
|
6849
|
-
var __decorateClass$
|
|
6850
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6853
|
+
var __defProp$F = Object.defineProperty;
|
|
6854
|
+
var __getOwnPropDesc$F = Object.getOwnPropertyDescriptor;
|
|
6855
|
+
var __decorateClass$F = (decorators, target, key, kind) => {
|
|
6856
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$F(target, key) : target;
|
|
6851
6857
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6852
|
-
if (kind && result) __defProp$
|
|
6858
|
+
if (kind && result) __defProp$F(target, key, result);
|
|
6853
6859
|
return result;
|
|
6854
6860
|
};
|
|
6855
6861
|
class CounterBadge extends FASTElement {
|
|
@@ -6926,27 +6932,27 @@ class CounterBadge extends FASTElement {
|
|
|
6926
6932
|
return;
|
|
6927
6933
|
}
|
|
6928
6934
|
}
|
|
6929
|
-
__decorateClass$
|
|
6930
|
-
__decorateClass$
|
|
6931
|
-
__decorateClass$
|
|
6932
|
-
__decorateClass$
|
|
6933
|
-
__decorateClass$
|
|
6935
|
+
__decorateClass$F([attr], CounterBadge.prototype, "appearance", 2);
|
|
6936
|
+
__decorateClass$F([attr], CounterBadge.prototype, "color", 2);
|
|
6937
|
+
__decorateClass$F([attr], CounterBadge.prototype, "shape", 2);
|
|
6938
|
+
__decorateClass$F([attr], CounterBadge.prototype, "size", 2);
|
|
6939
|
+
__decorateClass$F([attr({
|
|
6934
6940
|
converter: nullableNumberConverter
|
|
6935
6941
|
})], CounterBadge.prototype, "count", 2);
|
|
6936
|
-
__decorateClass$
|
|
6942
|
+
__decorateClass$F([attr({
|
|
6937
6943
|
attribute: "overflow-count",
|
|
6938
6944
|
converter: nullableNumberConverter
|
|
6939
6945
|
})], CounterBadge.prototype, "overflowCount", 2);
|
|
6940
|
-
__decorateClass$
|
|
6946
|
+
__decorateClass$F([attr({
|
|
6941
6947
|
attribute: "show-zero",
|
|
6942
6948
|
mode: "boolean"
|
|
6943
6949
|
})], CounterBadge.prototype, "showZero", 2);
|
|
6944
|
-
__decorateClass$
|
|
6950
|
+
__decorateClass$F([attr({
|
|
6945
6951
|
mode: "boolean"
|
|
6946
6952
|
})], CounterBadge.prototype, "dot", 2);
|
|
6947
6953
|
applyMixins(CounterBadge, StartEnd);
|
|
6948
6954
|
|
|
6949
|
-
const styles$
|
|
6955
|
+
const styles$y = css`
|
|
6950
6956
|
:host(${roundedState}){border-radius:${borderRadiusMedium}}:host(${roundedState}${tinyState}),:host(${roundedState}${extraSmallState}),:host(${roundedState}${smallState}){border-radius:${borderRadiusSmall}}${badgeSizeStyles}
|
|
6951
6957
|
${badgeFilledStyles}
|
|
6952
6958
|
${badgeGhostStyles}
|
|
@@ -6959,15 +6965,15 @@ function composeTemplate(options = {}) {
|
|
|
6959
6965
|
defaultContent: html`${x => x.setCount()}`
|
|
6960
6966
|
});
|
|
6961
6967
|
}
|
|
6962
|
-
const template$
|
|
6968
|
+
const template$z = composeTemplate();
|
|
6963
6969
|
|
|
6964
|
-
const definition$
|
|
6970
|
+
const definition$z = CounterBadge.compose({
|
|
6965
6971
|
name: `${FluentDesignSystem.prefix}-counter-badge`,
|
|
6966
|
-
template: template$
|
|
6967
|
-
styles: styles$
|
|
6972
|
+
template: template$z,
|
|
6973
|
+
styles: styles$y
|
|
6968
6974
|
});
|
|
6969
6975
|
|
|
6970
|
-
definition$
|
|
6976
|
+
definition$z.define(FluentDesignSystem.registry);
|
|
6971
6977
|
|
|
6972
6978
|
const DialogType = {
|
|
6973
6979
|
modal: "modal",
|
|
@@ -6975,12 +6981,12 @@ const DialogType = {
|
|
|
6975
6981
|
alert: "alert"
|
|
6976
6982
|
};
|
|
6977
6983
|
|
|
6978
|
-
var __defProp$
|
|
6979
|
-
var __getOwnPropDesc$
|
|
6980
|
-
var __decorateClass$
|
|
6981
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6984
|
+
var __defProp$E = Object.defineProperty;
|
|
6985
|
+
var __getOwnPropDesc$E = Object.getOwnPropertyDescriptor;
|
|
6986
|
+
var __decorateClass$E = (decorators, target, key, kind) => {
|
|
6987
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$E(target, key) : target;
|
|
6982
6988
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6983
|
-
if (kind && result) __defProp$
|
|
6989
|
+
if (kind && result) __defProp$E(target, key, result);
|
|
6984
6990
|
return result;
|
|
6985
6991
|
};
|
|
6986
6992
|
class Dialog extends FASTElement {
|
|
@@ -7048,35 +7054,35 @@ class Dialog extends FASTElement {
|
|
|
7048
7054
|
return true;
|
|
7049
7055
|
}
|
|
7050
7056
|
}
|
|
7051
|
-
__decorateClass$
|
|
7052
|
-
__decorateClass$
|
|
7057
|
+
__decorateClass$E([observable], Dialog.prototype, "dialog", 2);
|
|
7058
|
+
__decorateClass$E([attr({
|
|
7053
7059
|
attribute: "aria-describedby"
|
|
7054
7060
|
})], Dialog.prototype, "ariaDescribedby", 2);
|
|
7055
|
-
__decorateClass$
|
|
7061
|
+
__decorateClass$E([attr({
|
|
7056
7062
|
attribute: "aria-labelledby"
|
|
7057
7063
|
})], Dialog.prototype, "ariaLabelledby", 2);
|
|
7058
|
-
__decorateClass$
|
|
7064
|
+
__decorateClass$E([attr], Dialog.prototype, "type", 2);
|
|
7059
7065
|
|
|
7060
|
-
const template$
|
|
7066
|
+
const template$y = html`<dialog role="${x => x.type === DialogType.alert ? "alertdialog" : "dialog"}" type="${x => x.type}" class="dialog" part="dialog" aria-modal="${x => x.type === DialogType.modal || x.type === DialogType.alert ? "true" : void 0}" aria-describedby="${x => x.ariaDescribedby}" aria-labelledby="${x => x.ariaLabelledby}" aria-label="${x => x.ariaLabel}" @click="${(x, c) => x.clickHandler(c.event)}" @cancel="${(x, c) => x.type === DialogType.alert ? c.event.preventDefault() : x.hide()}" ${ref("dialog")}><slot></slot></dialog>`;
|
|
7061
7067
|
|
|
7062
|
-
const styles$
|
|
7068
|
+
const styles$x = css`
|
|
7063
7069
|
@layer base{:host{--dialog-backdrop:${colorBackgroundOverlay};--dialog-starting-scale:0.85}::backdrop{background:var(--dialog-backdrop,rgba(0,0,0,0.4))}dialog{background:${colorNeutralBackground1};border-radius:${borderRadiusXLarge};border:none;box-shadow:${shadow64};color:${colorNeutralForeground1};max-height:calc(-48px + 100vh);padding:0;width:100%;max-width:600px}:host([type='non-modal']) dialog{inset:0;position:fixed;z-index:2;overflow:auto}}@layer animations{@media (prefers-reduced-motion:no-preference){dialog,::backdrop{transition:display allow-discrete,opacity,overlay allow-discrete,scale;transition-duration:${durationGentle};transition-timing-function:${curveDecelerateMid};opacity:0}::backdrop{transition-timing-function:${curveLinear}}[open],[open]::backdrop{opacity:1}dialog:not([open]){scale:var(--dialog-starting-scale);transition-timing-function:${curveAccelerateMid}}}@starting-style{[open],[open]::backdrop{opacity:0}dialog{scale:var(--dialog-starting-scale)}}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
7064
7070
|
@layer base{dialog{border:${strokeWidthThin} solid ${colorTransparentStroke}}}`));
|
|
7065
7071
|
|
|
7066
|
-
const definition$
|
|
7072
|
+
const definition$y = Dialog.compose({
|
|
7067
7073
|
name: `${FluentDesignSystem.prefix}-dialog`,
|
|
7068
|
-
template: template$
|
|
7069
|
-
styles: styles$
|
|
7074
|
+
template: template$y,
|
|
7075
|
+
styles: styles$x
|
|
7070
7076
|
});
|
|
7071
7077
|
|
|
7072
|
-
definition$
|
|
7078
|
+
definition$y.define(FluentDesignSystem.registry);
|
|
7073
7079
|
|
|
7074
|
-
var __defProp$
|
|
7075
|
-
var __getOwnPropDesc$
|
|
7076
|
-
var __decorateClass$
|
|
7077
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7080
|
+
var __defProp$D = Object.defineProperty;
|
|
7081
|
+
var __getOwnPropDesc$D = Object.getOwnPropertyDescriptor;
|
|
7082
|
+
var __decorateClass$D = (decorators, target, key, kind) => {
|
|
7083
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$D(target, key) : target;
|
|
7078
7084
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7079
|
-
if (kind && result) __defProp$
|
|
7085
|
+
if (kind && result) __defProp$D(target, key, result);
|
|
7080
7086
|
return result;
|
|
7081
7087
|
};
|
|
7082
7088
|
class DialogBody extends FASTElement {
|
|
@@ -7085,7 +7091,7 @@ class DialogBody extends FASTElement {
|
|
|
7085
7091
|
this.noTitleAction = false;
|
|
7086
7092
|
}
|
|
7087
7093
|
}
|
|
7088
|
-
__decorateClass$
|
|
7094
|
+
__decorateClass$D([attr({
|
|
7089
7095
|
mode: "boolean",
|
|
7090
7096
|
attribute: "no-title-action"
|
|
7091
7097
|
})], DialogBody.prototype, "noTitleAction", 2);
|
|
@@ -7104,20 +7110,20 @@ const dismissed16Regular = html.partial(`
|
|
|
7104
7110
|
fill="currentColor"
|
|
7105
7111
|
></path>
|
|
7106
7112
|
</svg>`);
|
|
7107
|
-
const template$
|
|
7113
|
+
const template$x = html`<div class="title" part="title"><slot name="title"></slot><slot name="title-action"><fluent-button ?hidden=${x => x.noTitleAction || x.parentNode?.type === DialogType.alert} tabindex="0" part="title-action" class="title-action" appearance="transparent" icon-only @click=${x => x.parentNode?.hide()} ${ref("defaultTitleAction")}>${dismissed16Regular}</fluent-button></slot></div><div class="content" part="content"><slot></slot></div><div class="actions" part="actions"><slot name="action"></slot></div>`;
|
|
7108
7114
|
|
|
7109
|
-
const styles$
|
|
7115
|
+
const styles$w = css`
|
|
7110
7116
|
${display("grid")}
|
|
7111
7117
|
|
|
7112
7118
|
: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};position:sticky;z-index:1}.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};position:sticky;z-index:2}:not(:has(:is([slot='title'],[slot='title-action']))) .title:not(:has(.title-action)),:not(:has([slot='action'])) .actions{display:none}@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}}}`;
|
|
7113
7119
|
|
|
7114
|
-
const definition$
|
|
7120
|
+
const definition$x = DialogBody.compose({
|
|
7115
7121
|
name: `${FluentDesignSystem.prefix}-dialog-body`,
|
|
7116
|
-
template: template$
|
|
7117
|
-
styles: styles$
|
|
7122
|
+
template: template$x,
|
|
7123
|
+
styles: styles$w
|
|
7118
7124
|
});
|
|
7119
7125
|
|
|
7120
|
-
definition$
|
|
7126
|
+
definition$x.define(FluentDesignSystem.registry);
|
|
7121
7127
|
|
|
7122
7128
|
const DividerRole = {
|
|
7123
7129
|
/**
|
|
@@ -7141,12 +7147,12 @@ const DividerAppearance = {
|
|
|
7141
7147
|
subtle: "subtle"
|
|
7142
7148
|
};
|
|
7143
7149
|
|
|
7144
|
-
var __defProp$
|
|
7145
|
-
var __getOwnPropDesc$
|
|
7146
|
-
var __decorateClass$
|
|
7147
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7150
|
+
var __defProp$C = Object.defineProperty;
|
|
7151
|
+
var __getOwnPropDesc$C = Object.getOwnPropertyDescriptor;
|
|
7152
|
+
var __decorateClass$C = (decorators, target, key, kind) => {
|
|
7153
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$C(target, key) : target;
|
|
7148
7154
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7149
|
-
if (kind && result) __defProp$
|
|
7155
|
+
if (kind && result) __defProp$C(target, key, result);
|
|
7150
7156
|
return result;
|
|
7151
7157
|
};
|
|
7152
7158
|
class BaseDivider extends FASTElement {
|
|
@@ -7193,15 +7199,15 @@ class BaseDivider extends FASTElement {
|
|
|
7193
7199
|
swapStates(this.elementInternals, previous, next, DividerOrientation);
|
|
7194
7200
|
}
|
|
7195
7201
|
}
|
|
7196
|
-
__decorateClass$
|
|
7197
|
-
__decorateClass$
|
|
7202
|
+
__decorateClass$C([attr], BaseDivider.prototype, "role", 2);
|
|
7203
|
+
__decorateClass$C([attr], BaseDivider.prototype, "orientation", 2);
|
|
7198
7204
|
|
|
7199
|
-
var __defProp$
|
|
7200
|
-
var __getOwnPropDesc$
|
|
7201
|
-
var __decorateClass$
|
|
7202
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7205
|
+
var __defProp$B = Object.defineProperty;
|
|
7206
|
+
var __getOwnPropDesc$B = Object.getOwnPropertyDescriptor;
|
|
7207
|
+
var __decorateClass$B = (decorators, target, key, kind) => {
|
|
7208
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$B(target, key) : target;
|
|
7203
7209
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7204
|
-
if (kind && result) __defProp$
|
|
7210
|
+
if (kind && result) __defProp$B(target, key, result);
|
|
7205
7211
|
return result;
|
|
7206
7212
|
};
|
|
7207
7213
|
class Divider extends BaseDivider {
|
|
@@ -7230,32 +7236,32 @@ class Divider extends BaseDivider {
|
|
|
7230
7236
|
toggleState(this.elementInternals, "inset", next);
|
|
7231
7237
|
}
|
|
7232
7238
|
}
|
|
7233
|
-
__decorateClass$
|
|
7239
|
+
__decorateClass$B([attr({
|
|
7234
7240
|
attribute: "align-content"
|
|
7235
7241
|
})], Divider.prototype, "alignContent", 2);
|
|
7236
|
-
__decorateClass$
|
|
7237
|
-
__decorateClass$
|
|
7242
|
+
__decorateClass$B([attr], Divider.prototype, "appearance", 2);
|
|
7243
|
+
__decorateClass$B([attr({
|
|
7238
7244
|
mode: "boolean"
|
|
7239
7245
|
})], Divider.prototype, "inset", 2);
|
|
7240
7246
|
|
|
7241
7247
|
function dividerTemplate() {
|
|
7242
7248
|
return html`<slot></slot>`;
|
|
7243
7249
|
}
|
|
7244
|
-
const template$
|
|
7250
|
+
const template$w = dividerTemplate();
|
|
7245
7251
|
|
|
7246
|
-
const styles$
|
|
7252
|
+
const styles$v = css`
|
|
7247
7253
|
${display("flex")}
|
|
7248
7254
|
|
|
7249
7255
|
: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(${insetState}){padding:0 12px}:host ::slotted(*){color:${colorNeutralForeground2};font-family:${fontFamilyBase};font-size:${fontSizeBase200};font-weight:${fontWeightRegular};margin:0;padding:0 12px}:host(${alignStartState})::before,:host(${alignEndState})::after{flex-basis:12px;flex-grow:0;flex-shrink:0}:host(${verticalState}){height:100%;min-height:84px}:host(${verticalState}):empty{min-height:20px}:host(${verticalState}){flex-direction:column;align-items:center}:host(${verticalState}${insetState})::before{margin-top:12px}:host(${verticalState}${insetState})::after{margin-bottom:12px}:host(${verticalState}):empty::before,:host(${verticalState}):empty::after{height:10px;min-height:10px;flex-grow:0}:host(${verticalState})::before,:host(${verticalState})::after{width:${strokeWidthThin};min-height:20px;height:100%}:host(${verticalState}) ::slotted(*){display:flex;flex-direction:column;padding:12px 0;line-height:20px}:host(${verticalState}${alignStartState})::before{min-height:8px}:host(${verticalState}${alignEndState})::after{min-height:8px}:host(${strongState})::before,:host(${strongState})::after{background:${colorNeutralStroke1}}:host(${strongState}) ::slotted(*){color:${colorNeutralForeground1}}:host(${brandState})::before,:host(${brandState})::after{background:${colorBrandStroke1}}:host(${brandState}) ::slotted(*){color:${colorBrandForeground1}}:host(${subtleState})::before,:host(${subtleState})::after{background:${colorNeutralStroke3}}:host(${subtleState}) ::slotted(*){color:${colorNeutralForeground3}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
7250
7256
|
:host(${strongState})::before,:host(${strongState})::after,:host(${brandState})::before,:host(${brandState})::after,:host(${subtleState})::before,:host(${subtleState})::after,:host::after,:host::before{background:WindowText;color:WindowText}`));
|
|
7251
7257
|
|
|
7252
|
-
const definition$
|
|
7258
|
+
const definition$w = Divider.compose({
|
|
7253
7259
|
name: `${FluentDesignSystem.prefix}-divider`,
|
|
7254
|
-
template: template$
|
|
7255
|
-
styles: styles$
|
|
7260
|
+
template: template$w,
|
|
7261
|
+
styles: styles$v
|
|
7256
7262
|
});
|
|
7257
7263
|
|
|
7258
|
-
definition$
|
|
7264
|
+
definition$w.define(FluentDesignSystem.registry);
|
|
7259
7265
|
|
|
7260
7266
|
const DrawerPosition = {
|
|
7261
7267
|
start: "start",
|
|
@@ -7273,12 +7279,12 @@ const DrawerType = {
|
|
|
7273
7279
|
inline: "inline"
|
|
7274
7280
|
};
|
|
7275
7281
|
|
|
7276
|
-
var __defProp$
|
|
7277
|
-
var __getOwnPropDesc$
|
|
7278
|
-
var __decorateClass$
|
|
7279
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7282
|
+
var __defProp$A = Object.defineProperty;
|
|
7283
|
+
var __getOwnPropDesc$A = Object.getOwnPropertyDescriptor;
|
|
7284
|
+
var __decorateClass$A = (decorators, target, key, kind) => {
|
|
7285
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$A(target, key) : target;
|
|
7280
7286
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7281
|
-
if (kind && result) __defProp$
|
|
7287
|
+
if (kind && result) __defProp$A(target, key, result);
|
|
7282
7288
|
return result;
|
|
7283
7289
|
};
|
|
7284
7290
|
class Drawer extends FASTElement {
|
|
@@ -7348,20 +7354,20 @@ class Drawer extends FASTElement {
|
|
|
7348
7354
|
return true;
|
|
7349
7355
|
}
|
|
7350
7356
|
}
|
|
7351
|
-
__decorateClass$
|
|
7352
|
-
__decorateClass$
|
|
7357
|
+
__decorateClass$A([attr], Drawer.prototype, "type", 2);
|
|
7358
|
+
__decorateClass$A([attr({
|
|
7353
7359
|
attribute: "aria-labelledby"
|
|
7354
7360
|
})], Drawer.prototype, "ariaLabelledby", 2);
|
|
7355
|
-
__decorateClass$
|
|
7361
|
+
__decorateClass$A([attr({
|
|
7356
7362
|
attribute: "aria-describedby"
|
|
7357
7363
|
})], Drawer.prototype, "ariaDescribedby", 2);
|
|
7358
|
-
__decorateClass$
|
|
7359
|
-
__decorateClass$
|
|
7364
|
+
__decorateClass$A([attr], Drawer.prototype, "position", 2);
|
|
7365
|
+
__decorateClass$A([attr({
|
|
7360
7366
|
attribute: "size"
|
|
7361
7367
|
})], Drawer.prototype, "size", 2);
|
|
7362
|
-
__decorateClass$
|
|
7368
|
+
__decorateClass$A([observable], Drawer.prototype, "dialog", 2);
|
|
7363
7369
|
|
|
7364
|
-
const styles$
|
|
7370
|
+
const styles$u = css`
|
|
7365
7371
|
${display("block")}
|
|
7366
7372
|
|
|
7367
7373
|
:host{--dialog-backdrop:${colorBackgroundOverlay}}:host([type='non-modal']) dialog[open]::backdrop{display:none}:host([type='non-modal']) dialog{position:fixed;top:0;bottom:0}:host([type='inline']){height:100%;width:fit-content}:host([type='inline']) dialog[open]{box-shadow:none;position:relative}:host([size='small']) dialog{width:320px;max-width:320px}:host([size='large']) dialog{width:940px;max-width:940px}:host([size='full']) dialog{width:100%;max-width:100%}:host([position='end']) dialog{margin-inline-start:auto;margin-inline-end:0}dialog{box-sizing:border-box;z-index:var(--drawer-elevation,1000);font-size:${fontSizeBase300};line-height:${lineHeightBase300};font-family:${fontFamilyBase};font-weight:${fontWeightRegular};color:${colorNeutralForeground1};max-width:var(--drawer-width,592px);max-height:100vh;height:100%;margin-inline-start:0;margin-inline-end:auto;border-inline-end-color:${colorTransparentStroke};border-inline-start-color:var(--drawer-separator,${colorTransparentStroke});outline:none;top:0;bottom:0;width:var(--drawer-width,592px);border-radius:0;padding:0;max-width:var(--drawer-width,592px);box-shadow:${shadow64};border:${strokeWidthThin} solid ${colorTransparentStroke};background:${colorNeutralBackground1}}dialog::backdrop{background:var(--dialog-backdrop)}@layer animations{@media (prefers-reduced-motion:no-preference){dialog{transition:display allow-discrete,opacity,overlay allow-discrete,transform;transition-duration:${durationGentle};transition-timing-function:${curveDecelerateMid}}:host dialog:not([open]){transform:translateX(-100%);transition-timing-function:${curveAccelerateMid}}:host([position='end']) dialog:not([open]){transform:translateX(100%);transition-timing-function:${curveAccelerateMid}}dialog[open]{transform:translateX(0)}dialog::backdrop{transition:display allow-discrete,opacity,overlay allow-discrete,scale;transition-duration:${durationGentle};transition-timing-function:${curveDecelerateMid};background:var(--dialog-backdrop,${colorBackgroundOverlay});opacity:0}dialog[open]::backdrop{opacity:1}dialog::backdrop{transition-timing-function:${curveLinear}}}@starting-style{dialog[open]{transform:translateX(-100%)}:host([position='end']) dialog[open]{transform:translateX(100%)}dialog[open]::backdrop{opacity:0}}}`;
|
|
@@ -7369,34 +7375,34 @@ const styles$s = css`
|
|
|
7369
7375
|
function drawerTemplate() {
|
|
7370
7376
|
return html`<dialog class="dialog" part="dialog" role="${x => x.type === "modal" ? "dialog" : x.role}" aria-modal="${x => x.type === "modal" ? "true" : void 0}" aria-describedby="${x => x.ariaDescribedby}" aria-labelledby="${x => x.ariaLabelledby}" aria-label="${x => x.ariaLabel}" size="${x => x.size}" position="${x => x.position}" type="${x => x.type}" @click="${(x, c) => x.clickHandler(c.event)}" @cancel="${(x, c) => x.hide()}" ${ref("dialog")}><slot></slot></dialog>`;
|
|
7371
7377
|
}
|
|
7372
|
-
const template$
|
|
7378
|
+
const template$v = drawerTemplate();
|
|
7373
7379
|
|
|
7374
|
-
const definition$
|
|
7380
|
+
const definition$v = Drawer.compose({
|
|
7375
7381
|
name: `${FluentDesignSystem.prefix}-drawer`,
|
|
7376
|
-
template: template$
|
|
7377
|
-
styles: styles$
|
|
7382
|
+
template: template$v,
|
|
7383
|
+
styles: styles$u
|
|
7378
7384
|
});
|
|
7379
7385
|
|
|
7380
|
-
definition$
|
|
7386
|
+
definition$v.define(FluentDesignSystem.registry);
|
|
7381
7387
|
|
|
7382
7388
|
class DrawerBody extends FASTElement {}
|
|
7383
7389
|
|
|
7384
|
-
const styles$
|
|
7390
|
+
const styles$t = css`
|
|
7385
7391
|
${display("grid")}
|
|
7386
7392
|
:host{box-sizing:border-box;grid-template-rows:min-content auto min-content;position:relative;height:100%;padding:${spacingHorizontalXL};max-height:100svh}.header{display:flex;justify-content:space-between;align-items:center;${typographySubtitle1Styles}}.footer{display:flex;justify-content:flex-start;gap:${spacingHorizontalM}}`;
|
|
7387
7393
|
|
|
7388
7394
|
function drawerBodyTemplate() {
|
|
7389
7395
|
return html`<div class="header" part="header"><slot name="title"></slot><slot name="close"></slot></div><div class="content" part="content"><slot></slot></div><div class="footer" part="footer"><slot name="footer"></slot></div>`;
|
|
7390
7396
|
}
|
|
7391
|
-
const template$
|
|
7397
|
+
const template$u = drawerBodyTemplate();
|
|
7392
7398
|
|
|
7393
|
-
const definition$
|
|
7399
|
+
const definition$u = DrawerBody.compose({
|
|
7394
7400
|
name: `${FluentDesignSystem.prefix}-drawer-body`,
|
|
7395
|
-
template: template$
|
|
7396
|
-
styles: styles$
|
|
7401
|
+
template: template$u,
|
|
7402
|
+
styles: styles$t
|
|
7397
7403
|
});
|
|
7398
7404
|
|
|
7399
|
-
definition$
|
|
7405
|
+
definition$u.define(FluentDesignSystem.registry);
|
|
7400
7406
|
|
|
7401
7407
|
function isListbox(element, tagName = "-listbox") {
|
|
7402
7408
|
if (element?.nodeType !== Node.ELEMENT_NODE) {
|
|
@@ -7445,16 +7451,16 @@ const dropdownButtonTemplate = html`<button aria-activedescendant="${x => x.acti
|
|
|
7445
7451
|
function dropdownTemplate(options = {}) {
|
|
7446
7452
|
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 ${ref("listboxSlot")}></slot></template>`;
|
|
7447
7453
|
}
|
|
7448
|
-
const template$
|
|
7454
|
+
const template$t = dropdownTemplate({
|
|
7449
7455
|
indicator: dropdownIndicatorTemplate
|
|
7450
7456
|
});
|
|
7451
7457
|
|
|
7452
|
-
var __defProp$
|
|
7453
|
-
var __getOwnPropDesc$
|
|
7454
|
-
var __decorateClass$
|
|
7455
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7458
|
+
var __defProp$z = Object.defineProperty;
|
|
7459
|
+
var __getOwnPropDesc$z = Object.getOwnPropertyDescriptor;
|
|
7460
|
+
var __decorateClass$z = (decorators, target, key, kind) => {
|
|
7461
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$z(target, key) : target;
|
|
7456
7462
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7457
|
-
if (kind && result) __defProp$
|
|
7463
|
+
if (kind && result) __defProp$z(target, key, result);
|
|
7458
7464
|
return result;
|
|
7459
7465
|
};
|
|
7460
7466
|
class BaseDropdown extends FASTElement {
|
|
@@ -8013,48 +8019,48 @@ class BaseDropdown extends FASTElement {
|
|
|
8013
8019
|
* @public
|
|
8014
8020
|
*/
|
|
8015
8021
|
BaseDropdown.formAssociated = true;
|
|
8016
|
-
__decorateClass$
|
|
8017
|
-
__decorateClass$
|
|
8018
|
-
__decorateClass$
|
|
8022
|
+
__decorateClass$z([volatile], BaseDropdown.prototype, "activeDescendant", 1);
|
|
8023
|
+
__decorateClass$z([observable], BaseDropdown.prototype, "activeIndex", 2);
|
|
8024
|
+
__decorateClass$z([attr({
|
|
8019
8025
|
attribute: "aria-labelledby",
|
|
8020
8026
|
mode: "fromView"
|
|
8021
8027
|
})], BaseDropdown.prototype, "ariaLabelledBy", 2);
|
|
8022
|
-
__decorateClass$
|
|
8023
|
-
__decorateClass$
|
|
8028
|
+
__decorateClass$z([observable], BaseDropdown.prototype, "control", 2);
|
|
8029
|
+
__decorateClass$z([attr({
|
|
8024
8030
|
mode: "boolean"
|
|
8025
8031
|
})], BaseDropdown.prototype, "disabled", 2);
|
|
8026
|
-
__decorateClass$
|
|
8027
|
-
__decorateClass$
|
|
8032
|
+
__decorateClass$z([volatile], BaseDropdown.prototype, "displayValue", 1);
|
|
8033
|
+
__decorateClass$z([attr({
|
|
8028
8034
|
attribute: "id"
|
|
8029
8035
|
})], BaseDropdown.prototype, "id", 2);
|
|
8030
|
-
__decorateClass$
|
|
8031
|
-
__decorateClass$
|
|
8032
|
-
__decorateClass$
|
|
8036
|
+
__decorateClass$z([observable], BaseDropdown.prototype, "indicator", 2);
|
|
8037
|
+
__decorateClass$z([observable], BaseDropdown.prototype, "indicatorSlot", 2);
|
|
8038
|
+
__decorateClass$z([attr({
|
|
8033
8039
|
attribute: "value",
|
|
8034
8040
|
mode: "fromView"
|
|
8035
8041
|
})], BaseDropdown.prototype, "initialValue", 2);
|
|
8036
|
-
__decorateClass$
|
|
8037
|
-
__decorateClass$
|
|
8038
|
-
__decorateClass$
|
|
8042
|
+
__decorateClass$z([observable], BaseDropdown.prototype, "listbox", 2);
|
|
8043
|
+
__decorateClass$z([observable], BaseDropdown.prototype, "listboxSlot", 2);
|
|
8044
|
+
__decorateClass$z([attr({
|
|
8039
8045
|
mode: "boolean"
|
|
8040
8046
|
})], BaseDropdown.prototype, "multiple", 2);
|
|
8041
|
-
__decorateClass$
|
|
8042
|
-
__decorateClass$
|
|
8043
|
-
__decorateClass$
|
|
8044
|
-
__decorateClass$
|
|
8047
|
+
__decorateClass$z([attr], BaseDropdown.prototype, "name", 2);
|
|
8048
|
+
__decorateClass$z([observable], BaseDropdown.prototype, "open", 2);
|
|
8049
|
+
__decorateClass$z([attr], BaseDropdown.prototype, "placeholder", 2);
|
|
8050
|
+
__decorateClass$z([attr({
|
|
8045
8051
|
mode: "boolean"
|
|
8046
8052
|
})], BaseDropdown.prototype, "required", 2);
|
|
8047
|
-
__decorateClass$
|
|
8048
|
-
__decorateClass$
|
|
8053
|
+
__decorateClass$z([attr], BaseDropdown.prototype, "type", 2);
|
|
8054
|
+
__decorateClass$z([attr({
|
|
8049
8055
|
attribute: "value"
|
|
8050
8056
|
})], BaseDropdown.prototype, "valueAttribute", 2);
|
|
8051
8057
|
|
|
8052
|
-
var __defProp$
|
|
8053
|
-
var __getOwnPropDesc$
|
|
8054
|
-
var __decorateClass$
|
|
8055
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8058
|
+
var __defProp$y = Object.defineProperty;
|
|
8059
|
+
var __getOwnPropDesc$y = Object.getOwnPropertyDescriptor;
|
|
8060
|
+
var __decorateClass$y = (decorators, target, key, kind) => {
|
|
8061
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$y(target, key) : target;
|
|
8056
8062
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8057
|
-
if (kind && result) __defProp$
|
|
8063
|
+
if (kind && result) __defProp$y(target, key, result);
|
|
8058
8064
|
return result;
|
|
8059
8065
|
};
|
|
8060
8066
|
const _Dropdown = class _Dropdown extends BaseDropdown {
|
|
@@ -8146,25 +8152,25 @@ const _Dropdown = class _Dropdown extends BaseDropdown {
|
|
|
8146
8152
|
});
|
|
8147
8153
|
}
|
|
8148
8154
|
};
|
|
8149
|
-
__decorateClass$
|
|
8150
|
-
__decorateClass$
|
|
8155
|
+
__decorateClass$y([attr], _Dropdown.prototype, "appearance", 2);
|
|
8156
|
+
__decorateClass$y([attr], _Dropdown.prototype, "size", 2);
|
|
8151
8157
|
let Dropdown = _Dropdown;
|
|
8152
8158
|
|
|
8153
|
-
const styles$
|
|
8159
|
+
const styles$s = css`
|
|
8154
8160
|
${display("inline-flex")}
|
|
8155
8161
|
|
|
8156
8162
|
:host{anchor-name:--dropdown-trigger;box-sizing:border-box;color:${colorNeutralForeground1};cursor:pointer}:host(${placeholderShownState}){color:${colorNeutralForeground4}}.control{appearance:none;background-color:${colorNeutralBackground1};border-radius:${borderRadiusMedium};border:none;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};position:relative;text-align:start;width:100%;z-index:1;${typographyBody1Styles}}:host(${smallState}) .control{column-gap:${spacingHorizontalXXS};padding:${spacingVerticalXS} ${spacingHorizontalSNudge};${typographyCaption1Styles}}:host(${largeState}) .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(${smallState}) :where(slot[name='indicator'] > *,::slotted([slot='indicator'])){width:16px}:host(${largeState}) :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(${openState},:focus-within)) .control::after{scale:1 1;transition-duration:${durationNormal};transition-timing-function:${curveAccelerateMid}}:host(:where(${outlineState},${transparentState})) .control::before{background-color:${colorNeutralStrokeAccessible}}:host(${transparentState}) .control{--control-border-color:${colorTransparentStrokeInteractive};background-color:${colorTransparentBackground};border-radius:${borderRadiusNone}}:host(${outlineState}) .control{--control-border-color:${colorNeutralStroke1}}:host(${outlineState}) .control:hover{--control-border-color:${colorNeutralStroke1Hover}}:host(:where(${outlineState},${transparentState})) .control:hover::before{background-color:${colorNeutralStrokeAccessibleHover}}:host(${outlineState}) .control:hover::after{background-color:${colorCompoundBrandBackgroundHover}}:host(${outlineState}) .control:active{--control-border-color:${colorNeutralStroke1Pressed}}:host(:where(${outlineState},${transparentState})) .control:active::before{background-color:${colorNeutralStrokeAccessiblePressed}}:host(:where(${outlineState},${transparentState})) .control:active::after{background-color:${colorCompoundBrandBackgroundPressed}}:host(${filledDarkerState}) .control{background-color:${colorNeutralBackground3}}:host(:where(${filledLighterState},${filledDarkerState})) .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([popover]){inset:unset;position:absolute;position-anchor:--dropdown-trigger;position-area:block-end span-inline-end;position-try-fallbacks:flip-inline,flip-block,block-start;max-height:var(--listbox-max-height,calc(50vh - anchor-size(self-block)));min-width:anchor-size(width);overflow:auto}::slotted([popover]:not(:popover-open)){display:none}@supports not (anchor-name:--anchor){::slotted([popover]){margin-block-start:calc(${lineHeightBase300} + (${spacingVerticalSNudge} * 2) + ${strokeWidthThin});max-height:50vh}:host(${smallState}) ::slotted([popover]){margin-block-start:calc(${lineHeightBase200} + (${spacingVerticalXS} * 2) + ${strokeWidthThin})}:host(${largeState}) ::slotted([popover]){margin-block-start:calc(${lineHeightBase400} + (${spacingVerticalS} * 2) + ${strokeWidthThin})}:host(${flipBlockState}) ::slotted([popover]){margin-block-start:revert;transform:translate(0,-100%)}}`;
|
|
8157
8163
|
|
|
8158
|
-
const definition$
|
|
8164
|
+
const definition$t = Dropdown.compose({
|
|
8159
8165
|
name: `${FluentDesignSystem.prefix}-dropdown`,
|
|
8160
|
-
template: template$
|
|
8161
|
-
styles: styles$
|
|
8166
|
+
template: template$t,
|
|
8167
|
+
styles: styles$s,
|
|
8162
8168
|
shadowOptions: {
|
|
8163
8169
|
slotAssignment: "manual"
|
|
8164
8170
|
}
|
|
8165
8171
|
});
|
|
8166
8172
|
|
|
8167
|
-
definition$
|
|
8173
|
+
definition$t.define(FluentDesignSystem.registry);
|
|
8168
8174
|
|
|
8169
8175
|
const LabelPosition = {
|
|
8170
8176
|
above: "above",
|
|
@@ -8185,12 +8191,12 @@ const ValidationFlags = {
|
|
|
8185
8191
|
valid: "valid"
|
|
8186
8192
|
};
|
|
8187
8193
|
|
|
8188
|
-
var __defProp$
|
|
8189
|
-
var __getOwnPropDesc$
|
|
8190
|
-
var __decorateClass$
|
|
8191
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8194
|
+
var __defProp$x = Object.defineProperty;
|
|
8195
|
+
var __getOwnPropDesc$x = Object.getOwnPropertyDescriptor;
|
|
8196
|
+
var __decorateClass$x = (decorators, target, key, kind) => {
|
|
8197
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$x(target, key) : target;
|
|
8192
8198
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8193
|
-
if (kind && result) __defProp$
|
|
8199
|
+
if (kind && result) __defProp$x(target, key, result);
|
|
8194
8200
|
return result;
|
|
8195
8201
|
};
|
|
8196
8202
|
class BaseField extends FASTElement {
|
|
@@ -8358,17 +8364,17 @@ class BaseField extends FASTElement {
|
|
|
8358
8364
|
}
|
|
8359
8365
|
}
|
|
8360
8366
|
}
|
|
8361
|
-
__decorateClass$
|
|
8362
|
-
__decorateClass$
|
|
8363
|
-
__decorateClass$
|
|
8364
|
-
__decorateClass$
|
|
8367
|
+
__decorateClass$x([observable], BaseField.prototype, "labelSlot", 2);
|
|
8368
|
+
__decorateClass$x([observable], BaseField.prototype, "messageSlot", 2);
|
|
8369
|
+
__decorateClass$x([observable], BaseField.prototype, "slottedInputs", 2);
|
|
8370
|
+
__decorateClass$x([observable], BaseField.prototype, "input", 2);
|
|
8365
8371
|
|
|
8366
|
-
var __defProp$
|
|
8367
|
-
var __getOwnPropDesc$
|
|
8368
|
-
var __decorateClass$
|
|
8369
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8372
|
+
var __defProp$w = Object.defineProperty;
|
|
8373
|
+
var __getOwnPropDesc$w = Object.getOwnPropertyDescriptor;
|
|
8374
|
+
var __decorateClass$w = (decorators, target, key, kind) => {
|
|
8375
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$w(target, key) : target;
|
|
8370
8376
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8371
|
-
if (kind && result) __defProp$
|
|
8377
|
+
if (kind && result) __defProp$w(target, key, result);
|
|
8372
8378
|
return result;
|
|
8373
8379
|
};
|
|
8374
8380
|
class Field extends BaseField {
|
|
@@ -8377,16 +8383,16 @@ class Field extends BaseField {
|
|
|
8377
8383
|
this.labelPosition = LabelPosition.above;
|
|
8378
8384
|
}
|
|
8379
8385
|
}
|
|
8380
|
-
__decorateClass$
|
|
8386
|
+
__decorateClass$w([attr({
|
|
8381
8387
|
attribute: "label-position"
|
|
8382
8388
|
})], Field.prototype, "labelPosition", 2);
|
|
8383
8389
|
|
|
8384
|
-
const styles$
|
|
8390
|
+
const styles$r = css`
|
|
8385
8391
|
${display("inline-grid")}
|
|
8386
8392
|
|
|
8387
8393
|
:host{color:${colorNeutralForeground1};align-items:center;gap:0 ${spacingHorizontalM};justify-items:start;position:relative}:has([slot='message']){color:${colorNeutralForeground1};row-gap:${spacingVerticalS}}:not(::slotted([slot='label'])){gap:0}:host([label-position='before']){grid-template-areas:'label input' 'label message'}:host([label-position='after']){gap:0;grid-template-areas:'input label' 'message message';grid-template-columns:auto 1fr}:host([label-position='after']) ::slotted([slot='input']){margin-inline-end:${spacingHorizontalM}}:host([label-position='above']){grid-template-areas:'label' 'input' 'message';row-gap:${spacingVerticalXXS}}:host([label-position='below']){grid-template-areas:'input' 'label' 'message';justify-items:center}:host([label-position='below']) ::slotted([slot='label']){margin-block-start:${spacingVerticalM}}:host([label-position='below']:not(${hasMessageState})){grid-template-areas:'input' 'label'}::slotted([slot='label'])::after{content:'';display:block;position:absolute;inset:0}::slotted([slot='input']){grid-area:input;position:relative;z-index:1}::slotted([slot='message']){margin-block-start:${spacingVerticalXXS};grid-area:message}:host(${focusVisibleState}:focus-within){border-radius:${borderRadiusMedium};outline:${strokeWidthThick} solid ${colorStrokeFocus2}}::slotted(label),::slotted([slot='label']){cursor:inherit;display:inline-flex;font-family:${fontFamilyBase};font-size:${fontSizeBase300};font-weight:${fontWeightRegular};grid-area:label;line-height:${lineHeightBase300};user-select:none}:host([size='small']) ::slotted(label){font-size:${fontSizeBase200};line-height:${lineHeightBase200}}:host([size='large']) ::slotted(label){font-size:${fontSizeBase400};line-height:${lineHeightBase400}}:host([size='large']) ::slotted(label),:host([weight='semibold']) ::slotted(label){font-weight:${fontWeightSemibold}}:host(${disabledState}){cursor:default}::slotted([flag]){display:none}:host(${badInputState}) ::slotted([flag='${ValidationFlags.badInput}']),:host(${customErrorState}) ::slotted([flag='${ValidationFlags.customError}']),:host(${patternMismatchState}) ::slotted([flag='${ValidationFlags.patternMismatch}']),:host(${rangeOverflowState}) ::slotted([flag='${ValidationFlags.rangeOverflow}']),:host(${rangeUnderflowState}) ::slotted([flag='${ValidationFlags.rangeUnderflow}']),:host(${stepMismatchState}) ::slotted([flag='${ValidationFlags.stepMismatch}']),:host(${tooLongState}) ::slotted([flag='${ValidationFlags.tooLong}']),:host(${tooShortState}) ::slotted([flag='${ValidationFlags.tooShort}']),:host(${typeMismatchState}) ::slotted([flag='${ValidationFlags.typeMismatch}']),:host(${valueMissingState}) ::slotted([flag='${ValidationFlags.valueMissing}']),:host(${validState}) ::slotted([flag='${ValidationFlags.valid}']){display:block}`;
|
|
8388
8394
|
|
|
8389
|
-
const template$
|
|
8395
|
+
const template$s = html`<template @click="${(x, c) => x.clickHandler(c.event)}" @change="${(x, c) => x.changeHandler(c.event)}" @focusin="${(x, c) => x.focusinHandler(c.event)}" @focusout="${(x, c) => x.focusoutHandler(c.event)}" ${children({
|
|
8390
8396
|
property: "slottedInputs",
|
|
8391
8397
|
attributes: true,
|
|
8392
8398
|
attributeFilter: ["disabled", "required", "readonly"],
|
|
@@ -8398,16 +8404,16 @@ const template$q = html`<template @click="${(x, c) => x.clickHandler(c.event)}"
|
|
|
8398
8404
|
filter: elements("[flag]")
|
|
8399
8405
|
})}></slot></template>`;
|
|
8400
8406
|
|
|
8401
|
-
const definition$
|
|
8407
|
+
const definition$s = Field.compose({
|
|
8402
8408
|
name: `${FluentDesignSystem.prefix}-field`,
|
|
8403
|
-
template: template$
|
|
8404
|
-
styles: styles$
|
|
8409
|
+
template: template$s,
|
|
8410
|
+
styles: styles$r,
|
|
8405
8411
|
shadowOptions: {
|
|
8406
8412
|
delegatesFocus: true
|
|
8407
8413
|
}
|
|
8408
8414
|
});
|
|
8409
8415
|
|
|
8410
|
-
definition$
|
|
8416
|
+
definition$s.define(FluentDesignSystem.registry);
|
|
8411
8417
|
|
|
8412
8418
|
const ImageFit = {
|
|
8413
8419
|
none: "none",
|
|
@@ -8421,12 +8427,12 @@ const ImageShape = {
|
|
|
8421
8427
|
square: "square"
|
|
8422
8428
|
};
|
|
8423
8429
|
|
|
8424
|
-
var __defProp$
|
|
8425
|
-
var __getOwnPropDesc$
|
|
8426
|
-
var __decorateClass$
|
|
8427
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8430
|
+
var __defProp$v = Object.defineProperty;
|
|
8431
|
+
var __getOwnPropDesc$v = Object.getOwnPropertyDescriptor;
|
|
8432
|
+
var __decorateClass$v = (decorators, target, key, kind) => {
|
|
8433
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$v(target, key) : target;
|
|
8428
8434
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8429
|
-
if (kind && result) __defProp$
|
|
8435
|
+
if (kind && result) __defProp$v(target, key, result);
|
|
8430
8436
|
return result;
|
|
8431
8437
|
};
|
|
8432
8438
|
class Image extends FASTElement {
|
|
@@ -8480,30 +8486,30 @@ class Image extends FASTElement {
|
|
|
8480
8486
|
swapStates(this.elementInternals, prev, next, ImageShape);
|
|
8481
8487
|
}
|
|
8482
8488
|
}
|
|
8483
|
-
__decorateClass$
|
|
8489
|
+
__decorateClass$v([attr({
|
|
8484
8490
|
mode: "boolean"
|
|
8485
8491
|
})], Image.prototype, "block", 2);
|
|
8486
|
-
__decorateClass$
|
|
8492
|
+
__decorateClass$v([attr({
|
|
8487
8493
|
mode: "boolean"
|
|
8488
8494
|
})], Image.prototype, "bordered", 2);
|
|
8489
|
-
__decorateClass$
|
|
8495
|
+
__decorateClass$v([attr({
|
|
8490
8496
|
mode: "boolean"
|
|
8491
8497
|
})], Image.prototype, "shadow", 2);
|
|
8492
|
-
__decorateClass$
|
|
8493
|
-
__decorateClass$
|
|
8498
|
+
__decorateClass$v([attr], Image.prototype, "fit", 2);
|
|
8499
|
+
__decorateClass$v([attr], Image.prototype, "shape", 2);
|
|
8494
8500
|
|
|
8495
|
-
const template$
|
|
8501
|
+
const template$r = html`<slot></slot>`;
|
|
8496
8502
|
|
|
8497
|
-
const styles$
|
|
8503
|
+
const styles$q = css`
|
|
8498
8504
|
:host{contain:content}:host ::slotted(img){box-sizing:border-box;min-height:8px;min-width:8px;display:inline-block}:host(${blockState}) ::slotted(img){width:100%;height:auto}:host(${borderedState}) ::slotted(img){border:${strokeWidthThin} solid ${colorNeutralStroke2}}:host(${fitNoneState}) ::slotted(img){object-fit:none;object-position:top left;height:100%;width:100%}:host(${fitCenterState}) ::slotted(img){object-fit:none;object-position:center;height:100%;width:100%}:host(${fitContainState}) ::slotted(img){object-fit:contain;object-position:center;height:100%;width:100%}:host(${fitCoverState}) ::slotted(img){object-fit:cover;object-position:center;height:100%;width:100%}:host(${shadowState}) ::slotted(img){box-shadow:${shadow4}}:host(${circularState}) ::slotted(img){border-radius:${borderRadiusCircular}}:host(${roundedState}) ::slotted(img){border-radius:${borderRadiusMedium}}`;
|
|
8499
8505
|
|
|
8500
|
-
const definition$
|
|
8506
|
+
const definition$r = Image.compose({
|
|
8501
8507
|
name: `${FluentDesignSystem.prefix}-image`,
|
|
8502
|
-
template: template$
|
|
8503
|
-
styles: styles$
|
|
8508
|
+
template: template$r,
|
|
8509
|
+
styles: styles$q
|
|
8504
8510
|
});
|
|
8505
8511
|
|
|
8506
|
-
definition$
|
|
8512
|
+
definition$r.define(FluentDesignSystem.registry);
|
|
8507
8513
|
|
|
8508
8514
|
const LabelSize = {
|
|
8509
8515
|
small: "small",
|
|
@@ -8515,12 +8521,12 @@ const LabelWeight = {
|
|
|
8515
8521
|
semibold: "semibold"
|
|
8516
8522
|
};
|
|
8517
8523
|
|
|
8518
|
-
var __defProp$
|
|
8519
|
-
var __getOwnPropDesc$
|
|
8520
|
-
var __decorateClass$
|
|
8521
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8524
|
+
var __defProp$u = Object.defineProperty;
|
|
8525
|
+
var __getOwnPropDesc$u = Object.getOwnPropertyDescriptor;
|
|
8526
|
+
var __decorateClass$u = (decorators, target, key, kind) => {
|
|
8527
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$u(target, key) : target;
|
|
8522
8528
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8523
|
-
if (kind && result) __defProp$
|
|
8529
|
+
if (kind && result) __defProp$u(target, key, result);
|
|
8524
8530
|
return result;
|
|
8525
8531
|
};
|
|
8526
8532
|
class Label extends FASTElement {
|
|
@@ -8560,16 +8566,16 @@ class Label extends FASTElement {
|
|
|
8560
8566
|
toggleState(this.elementInternals, "disabled", next);
|
|
8561
8567
|
}
|
|
8562
8568
|
}
|
|
8563
|
-
__decorateClass$
|
|
8564
|
-
__decorateClass$
|
|
8565
|
-
__decorateClass$
|
|
8569
|
+
__decorateClass$u([attr], Label.prototype, "size", 2);
|
|
8570
|
+
__decorateClass$u([attr], Label.prototype, "weight", 2);
|
|
8571
|
+
__decorateClass$u([attr({
|
|
8566
8572
|
mode: "boolean"
|
|
8567
8573
|
})], Label.prototype, "disabled", 2);
|
|
8568
|
-
__decorateClass$
|
|
8574
|
+
__decorateClass$u([attr({
|
|
8569
8575
|
mode: "boolean"
|
|
8570
8576
|
})], Label.prototype, "required", 2);
|
|
8571
8577
|
|
|
8572
|
-
const styles$
|
|
8578
|
+
const styles$p = css`
|
|
8573
8579
|
${display("inline-flex")}
|
|
8574
8580
|
|
|
8575
8581
|
:host{color:${colorNeutralForeground1};cursor:pointer;font-family:${fontFamilyBase};font-size:${fontSizeBase300};font-weight:${fontWeightRegular};line-height:${lineHeightBase300};user-select:none}.asterisk{color:${colorPaletteRedForeground1};margin-inline-start:${spacingHorizontalXS}}:host(${smallState}){font-size:${fontSizeBase200};line-height:${lineHeightBase200}}:host(${largeState}){font-size:${fontSizeBase400};line-height:${lineHeightBase400}}:host(:is(${largeState},${semiboldState})){font-weight:${fontWeightSemibold}}:host(${disabledState}),:host(${disabledState}) .asterisk{color:${colorNeutralForegroundDisabled}}`;
|
|
@@ -8577,26 +8583,26 @@ const styles$n = css`
|
|
|
8577
8583
|
function labelTemplate() {
|
|
8578
8584
|
return html`<slot></slot><span part="asterisk" class="asterisk" ?hidden="${x => !x.required}">*</span>`;
|
|
8579
8585
|
}
|
|
8580
|
-
const template$
|
|
8586
|
+
const template$q = labelTemplate();
|
|
8581
8587
|
|
|
8582
|
-
const definition$
|
|
8588
|
+
const definition$q = Label.compose({
|
|
8583
8589
|
name: `${FluentDesignSystem.prefix}-label`,
|
|
8584
|
-
template: template$
|
|
8585
|
-
styles: styles$
|
|
8590
|
+
template: template$q,
|
|
8591
|
+
styles: styles$p
|
|
8586
8592
|
});
|
|
8587
8593
|
|
|
8588
|
-
definition$
|
|
8594
|
+
definition$q.define(FluentDesignSystem.registry);
|
|
8589
8595
|
|
|
8590
8596
|
const LinkAppearance = {
|
|
8591
8597
|
subtle: "subtle"
|
|
8592
8598
|
};
|
|
8593
8599
|
|
|
8594
|
-
var __defProp$
|
|
8595
|
-
var __getOwnPropDesc$
|
|
8596
|
-
var __decorateClass$
|
|
8597
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8600
|
+
var __defProp$t = Object.defineProperty;
|
|
8601
|
+
var __getOwnPropDesc$t = Object.getOwnPropertyDescriptor;
|
|
8602
|
+
var __decorateClass$t = (decorators, target, key, kind) => {
|
|
8603
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$t(target, key) : target;
|
|
8598
8604
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8599
|
-
if (kind && result) __defProp$
|
|
8605
|
+
if (kind && result) __defProp$t(target, key, result);
|
|
8600
8606
|
return result;
|
|
8601
8607
|
};
|
|
8602
8608
|
class Link extends BaseAnchor {
|
|
@@ -8621,12 +8627,12 @@ class Link extends BaseAnchor {
|
|
|
8621
8627
|
toggleState(this.elementInternals, "inline", next);
|
|
8622
8628
|
}
|
|
8623
8629
|
}
|
|
8624
|
-
__decorateClass$
|
|
8625
|
-
__decorateClass$
|
|
8630
|
+
__decorateClass$t([attr], Link.prototype, "appearance", 2);
|
|
8631
|
+
__decorateClass$t([attr({
|
|
8626
8632
|
mode: "boolean"
|
|
8627
8633
|
})], Link.prototype, "inline", 2);
|
|
8628
8634
|
|
|
8629
|
-
const styles$
|
|
8635
|
+
const styles$o = css`
|
|
8630
8636
|
${display("inline")}
|
|
8631
8637
|
|
|
8632
8638
|
:host{position:relative;box-sizing:border-box;background-color:transparent;color:${colorBrandForegroundLink};cursor:pointer;font-family:${fontFamilyBase};font-size:${fontSizeBase300};font-weight:${fontWeightRegular};overflow:inherit;text-align:start;text-decoration:none;text-decoration-thickness:${strokeWidthThin};text-overflow:inherit;user-select:text}:host(:is(:hover,:focus-visible)){outline:none;text-decoration-line:underline}@media (hover:hover){:host(:hover){color:${colorBrandForegroundLinkHover}}:host(:active){color:${colorBrandForegroundLinkPressed}}:host(${subtleState}:hover){color:${colorNeutralForeground2LinkHover}}:host(${subtleState}:active){color:${colorNeutralForeground2LinkPressed}}}:host(${subtleState}){color:${colorNeutralForeground2Link}}:host-context(:is(h1,h2,h3,h4,h5,h6,p,fluent-text)),:host(${inlineState}){font:inherit;text-decoration:underline}:host(:not([href])){color:inherit;text-decoration:none}::slotted(a){position:absolute;inset:0}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
@@ -8635,22 +8641,22 @@ const styles$m = css`
|
|
|
8635
8641
|
function anchorTemplate() {
|
|
8636
8642
|
return html`<template tabindex="0" @click="${(x, c) => x.clickHandler(c.event)}" @keydown="${(x, c) => x.keydownHandler(c.event)}"><slot></slot></template>`;
|
|
8637
8643
|
}
|
|
8638
|
-
const template$
|
|
8644
|
+
const template$p = anchorTemplate();
|
|
8639
8645
|
|
|
8640
|
-
const definition$
|
|
8646
|
+
const definition$p = Link.compose({
|
|
8641
8647
|
name: `${FluentDesignSystem.prefix}-link`,
|
|
8642
|
-
template: template$
|
|
8643
|
-
styles: styles$
|
|
8648
|
+
template: template$p,
|
|
8649
|
+
styles: styles$o
|
|
8644
8650
|
});
|
|
8645
8651
|
|
|
8646
|
-
definition$
|
|
8652
|
+
definition$p.define(FluentDesignSystem.registry);
|
|
8647
8653
|
|
|
8648
|
-
var __defProp$
|
|
8649
|
-
var __getOwnPropDesc$
|
|
8650
|
-
var __decorateClass$
|
|
8651
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8654
|
+
var __defProp$s = Object.defineProperty;
|
|
8655
|
+
var __getOwnPropDesc$s = Object.getOwnPropertyDescriptor;
|
|
8656
|
+
var __decorateClass$s = (decorators, target, key, kind) => {
|
|
8657
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$s(target, key) : target;
|
|
8652
8658
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8653
|
-
if (kind && result) __defProp$
|
|
8659
|
+
if (kind && result) __defProp$s(target, key, result);
|
|
8654
8660
|
return result;
|
|
8655
8661
|
};
|
|
8656
8662
|
class Listbox extends FASTElement {
|
|
@@ -8788,16 +8794,16 @@ class Listbox extends FASTElement {
|
|
|
8788
8794
|
this.selectedIndex = selectedIndex;
|
|
8789
8795
|
}
|
|
8790
8796
|
}
|
|
8791
|
-
__decorateClass$
|
|
8797
|
+
__decorateClass$s([attr({
|
|
8792
8798
|
attribute: "id",
|
|
8793
8799
|
mode: "fromView"
|
|
8794
8800
|
})], Listbox.prototype, "id", 2);
|
|
8795
|
-
__decorateClass$
|
|
8796
|
-
__decorateClass$
|
|
8797
|
-
__decorateClass$
|
|
8798
|
-
__decorateClass$
|
|
8801
|
+
__decorateClass$s([observable], Listbox.prototype, "multiple", 2);
|
|
8802
|
+
__decorateClass$s([observable], Listbox.prototype, "options", 2);
|
|
8803
|
+
__decorateClass$s([observable], Listbox.prototype, "selectedIndex", 2);
|
|
8804
|
+
__decorateClass$s([observable], Listbox.prototype, "dropdown", 2);
|
|
8799
8805
|
|
|
8800
|
-
const styles$
|
|
8806
|
+
const styles$n = css`
|
|
8801
8807
|
${display("inline-flex")}
|
|
8802
8808
|
|
|
8803
8809
|
:host{background-color:${colorNeutralBackground1};border-radius:${borderRadiusMedium};border:none;box-shadow:${shadow16};box-sizing:border-box;flex-direction:column;margin:0;min-width:160px;padding:${spacingHorizontalXS};row-gap:${spacingHorizontalXXS};width:auto}`;
|
|
@@ -8808,19 +8814,19 @@ function listboxTemplate() {
|
|
|
8808
8814
|
filter: node => isDropdownOption(node)
|
|
8809
8815
|
})}></slot></template>`;
|
|
8810
8816
|
}
|
|
8811
|
-
const template$
|
|
8817
|
+
const template$o = listboxTemplate();
|
|
8812
8818
|
|
|
8813
|
-
const definition$
|
|
8819
|
+
const definition$o = Listbox.compose({
|
|
8814
8820
|
name: `${FluentDesignSystem.prefix}-listbox`,
|
|
8815
|
-
template: template$
|
|
8816
|
-
styles: styles$
|
|
8821
|
+
template: template$o,
|
|
8822
|
+
styles: styles$n
|
|
8817
8823
|
});
|
|
8818
8824
|
|
|
8819
|
-
definition$
|
|
8825
|
+
definition$o.define(FluentDesignSystem.registry);
|
|
8820
8826
|
|
|
8821
8827
|
class MenuButton extends Button {}
|
|
8822
8828
|
|
|
8823
|
-
const template$
|
|
8829
|
+
const template$n = buttonTemplate$1({
|
|
8824
8830
|
end: html.partial( /* html */
|
|
8825
8831
|
`
|
|
8826
8832
|
<svg slot="end" fill="currentColor" aria-hidden="true" width="1em" height="1em" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg">
|
|
@@ -8829,13 +8835,13 @@ const template$l = buttonTemplate$1({
|
|
|
8829
8835
|
`)
|
|
8830
8836
|
});
|
|
8831
8837
|
|
|
8832
|
-
const definition$
|
|
8838
|
+
const definition$n = MenuButton.compose({
|
|
8833
8839
|
name: `${FluentDesignSystem.prefix}-menu-button`,
|
|
8834
|
-
template: template$
|
|
8835
|
-
styles: styles$
|
|
8840
|
+
template: template$n,
|
|
8841
|
+
styles: styles$E
|
|
8836
8842
|
});
|
|
8837
8843
|
|
|
8838
|
-
definition$
|
|
8844
|
+
definition$n.define(FluentDesignSystem.registry);
|
|
8839
8845
|
|
|
8840
8846
|
const MenuItemRole = {
|
|
8841
8847
|
/**
|
|
@@ -8857,12 +8863,12 @@ const MenuItemRole = {
|
|
|
8857
8863
|
[MenuItemRole.menuitemradio]: "menuitemradio"
|
|
8858
8864
|
});
|
|
8859
8865
|
|
|
8860
|
-
var __defProp$
|
|
8861
|
-
var __getOwnPropDesc$
|
|
8862
|
-
var __decorateClass$
|
|
8863
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8866
|
+
var __defProp$r = Object.defineProperty;
|
|
8867
|
+
var __getOwnPropDesc$r = Object.getOwnPropertyDescriptor;
|
|
8868
|
+
var __decorateClass$r = (decorators, target, key, kind) => {
|
|
8869
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$r(target, key) : target;
|
|
8864
8870
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8865
|
-
if (kind && result) __defProp$
|
|
8871
|
+
if (kind && result) __defProp$r(target, key, result);
|
|
8866
8872
|
return result;
|
|
8867
8873
|
};
|
|
8868
8874
|
class MenuItem extends FASTElement {
|
|
@@ -9051,21 +9057,21 @@ class MenuItem extends FASTElement {
|
|
|
9051
9057
|
this.elementInternals.ariaChecked = this.role !== MenuItemRole.menuitem ? `${!!this.checked}` : null;
|
|
9052
9058
|
}
|
|
9053
9059
|
}
|
|
9054
|
-
__decorateClass$
|
|
9060
|
+
__decorateClass$r([attr({
|
|
9055
9061
|
mode: "boolean"
|
|
9056
9062
|
})], MenuItem.prototype, "disabled", 2);
|
|
9057
|
-
__decorateClass$
|
|
9058
|
-
__decorateClass$
|
|
9063
|
+
__decorateClass$r([attr], MenuItem.prototype, "role", 2);
|
|
9064
|
+
__decorateClass$r([attr({
|
|
9059
9065
|
mode: "boolean"
|
|
9060
9066
|
})], MenuItem.prototype, "checked", 2);
|
|
9061
|
-
__decorateClass$
|
|
9067
|
+
__decorateClass$r([attr({
|
|
9062
9068
|
mode: "boolean"
|
|
9063
9069
|
})], MenuItem.prototype, "hidden", 2);
|
|
9064
|
-
__decorateClass$
|
|
9065
|
-
__decorateClass$
|
|
9070
|
+
__decorateClass$r([observable], MenuItem.prototype, "slottedSubmenu", 2);
|
|
9071
|
+
__decorateClass$r([observable], MenuItem.prototype, "submenu", 2);
|
|
9066
9072
|
applyMixins(MenuItem, StartEnd);
|
|
9067
9073
|
|
|
9068
|
-
const styles$
|
|
9074
|
+
const styles$m = css`
|
|
9069
9075
|
${display("grid")}
|
|
9070
9076
|
|
|
9071
9077
|
: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:absolute;position-anchor:--menu-trigger;position-area:inline-end span-block-end;position-try-fallbacks:flip-inline;z-index:1}::slotted([popover]:not(:popover-open)){display:none}::slotted([popover]:popover-open){inset:unset}@supports not (anchor-name:--menu-trigger){::slotted([popover]){align-self:start}}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
@@ -9078,25 +9084,25 @@ function menuItemTemplate(options = {}) {
|
|
|
9078
9084
|
property: "slottedSubmenu"
|
|
9079
9085
|
})}></slot></template>`;
|
|
9080
9086
|
}
|
|
9081
|
-
const template$
|
|
9087
|
+
const template$m = menuItemTemplate({
|
|
9082
9088
|
indicator: Checkmark16Filled,
|
|
9083
9089
|
submenuGlyph: chevronRight16Filled
|
|
9084
9090
|
});
|
|
9085
9091
|
|
|
9086
|
-
const definition$
|
|
9092
|
+
const definition$m = MenuItem.compose({
|
|
9087
9093
|
name: `${FluentDesignSystem.prefix}-menu-item`,
|
|
9088
|
-
template: template$
|
|
9089
|
-
styles: styles$
|
|
9094
|
+
template: template$m,
|
|
9095
|
+
styles: styles$m
|
|
9090
9096
|
});
|
|
9091
9097
|
|
|
9092
|
-
definition$
|
|
9098
|
+
definition$m.define(FluentDesignSystem.registry);
|
|
9093
9099
|
|
|
9094
|
-
var __defProp$
|
|
9095
|
-
var __getOwnPropDesc$
|
|
9096
|
-
var __decorateClass$
|
|
9097
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
9100
|
+
var __defProp$q = Object.defineProperty;
|
|
9101
|
+
var __getOwnPropDesc$q = Object.getOwnPropertyDescriptor;
|
|
9102
|
+
var __decorateClass$q = (decorators, target, key, kind) => {
|
|
9103
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$q(target, key) : target;
|
|
9098
9104
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
9099
|
-
if (kind && result) __defProp$
|
|
9105
|
+
if (kind && result) __defProp$q(target, key, result);
|
|
9100
9106
|
return result;
|
|
9101
9107
|
};
|
|
9102
9108
|
const _MenuList = class _MenuList extends FASTElement {
|
|
@@ -9312,10 +9318,10 @@ const _MenuList = class _MenuList extends FASTElement {
|
|
|
9312
9318
|
}
|
|
9313
9319
|
};
|
|
9314
9320
|
_MenuList.focusableElementRoles = MenuItemRole;
|
|
9315
|
-
__decorateClass$
|
|
9321
|
+
__decorateClass$q([observable], _MenuList.prototype, "items", 2);
|
|
9316
9322
|
let MenuList = _MenuList;
|
|
9317
9323
|
|
|
9318
|
-
const styles$
|
|
9324
|
+
const styles$l = css`
|
|
9319
9325
|
${display("flex")}
|
|
9320
9326
|
|
|
9321
9327
|
:host{flex-direction:column;height:fit-content;max-width:300px;min-width:160px;width:auto;background-color:${colorNeutralBackground1};border:1px solid ${colorTransparentStroke};border-radius:${borderRadiusMedium};box-shadow:${shadow16};padding:4px;row-gap:2px}`;
|
|
@@ -9323,22 +9329,22 @@ const styles$j = css`
|
|
|
9323
9329
|
function menuTemplate$1() {
|
|
9324
9330
|
return html`<template slot="${x => x.slot ? x.slot : x.isNestedMenu() ? "submenu" : void 0}" @keydown="${(x, c) => x.handleMenuKeyDown(c.event)}" @focusout="${(x, c) => x.handleFocusOut(c.event)}"><slot ${slotted("items")}></slot></template>`;
|
|
9325
9331
|
}
|
|
9326
|
-
const template$
|
|
9332
|
+
const template$l = menuTemplate$1();
|
|
9327
9333
|
|
|
9328
|
-
const definition$
|
|
9334
|
+
const definition$l = MenuList.compose({
|
|
9329
9335
|
name: `${FluentDesignSystem.prefix}-menu-list`,
|
|
9330
|
-
template: template$
|
|
9331
|
-
styles: styles$
|
|
9336
|
+
template: template$l,
|
|
9337
|
+
styles: styles$l
|
|
9332
9338
|
});
|
|
9333
9339
|
|
|
9334
|
-
definition$
|
|
9340
|
+
definition$l.define(FluentDesignSystem.registry);
|
|
9335
9341
|
|
|
9336
|
-
var __defProp$
|
|
9337
|
-
var __getOwnPropDesc$
|
|
9338
|
-
var __decorateClass$
|
|
9339
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
9342
|
+
var __defProp$p = Object.defineProperty;
|
|
9343
|
+
var __getOwnPropDesc$p = Object.getOwnPropertyDescriptor;
|
|
9344
|
+
var __decorateClass$p = (decorators, target, key, kind) => {
|
|
9345
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$p(target, key) : target;
|
|
9340
9346
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
9341
|
-
if (kind && result) __defProp$
|
|
9347
|
+
if (kind && result) __defProp$p(target, key, result);
|
|
9342
9348
|
return result;
|
|
9343
9349
|
};
|
|
9344
9350
|
class Menu extends FASTElement {
|
|
@@ -9618,30 +9624,30 @@ class Menu extends FASTElement {
|
|
|
9618
9624
|
}
|
|
9619
9625
|
}
|
|
9620
9626
|
}
|
|
9621
|
-
__decorateClass$
|
|
9627
|
+
__decorateClass$p([attr({
|
|
9622
9628
|
attribute: "open-on-hover",
|
|
9623
9629
|
mode: "boolean"
|
|
9624
9630
|
})], Menu.prototype, "openOnHover", 2);
|
|
9625
|
-
__decorateClass$
|
|
9631
|
+
__decorateClass$p([attr({
|
|
9626
9632
|
attribute: "open-on-context",
|
|
9627
9633
|
mode: "boolean"
|
|
9628
9634
|
})], Menu.prototype, "openOnContext", 2);
|
|
9629
|
-
__decorateClass$
|
|
9635
|
+
__decorateClass$p([attr({
|
|
9630
9636
|
attribute: "close-on-scroll",
|
|
9631
9637
|
mode: "boolean"
|
|
9632
9638
|
})], Menu.prototype, "closeOnScroll", 2);
|
|
9633
|
-
__decorateClass$
|
|
9639
|
+
__decorateClass$p([attr({
|
|
9634
9640
|
attribute: "persist-on-item-click",
|
|
9635
9641
|
mode: "boolean"
|
|
9636
9642
|
})], Menu.prototype, "persistOnItemClick", 2);
|
|
9637
|
-
__decorateClass$
|
|
9643
|
+
__decorateClass$p([attr({
|
|
9638
9644
|
mode: "boolean"
|
|
9639
9645
|
})], Menu.prototype, "split", 2);
|
|
9640
|
-
__decorateClass$
|
|
9641
|
-
__decorateClass$
|
|
9642
|
-
__decorateClass$
|
|
9646
|
+
__decorateClass$p([observable], Menu.prototype, "slottedMenuList", 2);
|
|
9647
|
+
__decorateClass$p([observable], Menu.prototype, "slottedTriggers", 2);
|
|
9648
|
+
__decorateClass$p([observable], Menu.prototype, "primaryAction", 2);
|
|
9643
9649
|
|
|
9644
|
-
const styles$
|
|
9650
|
+
const styles$k = css`
|
|
9645
9651
|
${display("inline-block")}
|
|
9646
9652
|
|
|
9647
9653
|
::slotted([slot='trigger']){anchor-name:--menu-trigger}::slotted([popover]){margin:0;max-height:var(--menu-max-height,auto);position-anchor:--menu-trigger;position-area:block-end span-inline-end;position-try-fallbacks:flip-block;position:absolute;z-index:1}:host([split]) ::slotted([popover]){position-area:block-end span-inline-start}::slotted([popover]:popover-open){inset:unset}::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}`;
|
|
@@ -9655,15 +9661,15 @@ function menuTemplate() {
|
|
|
9655
9661
|
filter: elements()
|
|
9656
9662
|
})}></slot></template>`;
|
|
9657
9663
|
}
|
|
9658
|
-
const template$
|
|
9664
|
+
const template$k = menuTemplate();
|
|
9659
9665
|
|
|
9660
|
-
const definition$
|
|
9666
|
+
const definition$k = Menu.compose({
|
|
9661
9667
|
name: `${FluentDesignSystem.prefix}-menu`,
|
|
9662
|
-
template: template$
|
|
9663
|
-
styles: styles$
|
|
9668
|
+
template: template$k,
|
|
9669
|
+
styles: styles$k
|
|
9664
9670
|
});
|
|
9665
9671
|
|
|
9666
|
-
definition$
|
|
9672
|
+
definition$k.define(FluentDesignSystem.registry);
|
|
9667
9673
|
|
|
9668
9674
|
const MessageBarLayout = {
|
|
9669
9675
|
multiline: "multiline",
|
|
@@ -9680,12 +9686,12 @@ const MessageBarIntent = {
|
|
|
9680
9686
|
info: "info"
|
|
9681
9687
|
};
|
|
9682
9688
|
|
|
9683
|
-
var __defProp$
|
|
9684
|
-
var __getOwnPropDesc$
|
|
9685
|
-
var __decorateClass$
|
|
9686
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
9689
|
+
var __defProp$o = Object.defineProperty;
|
|
9690
|
+
var __getOwnPropDesc$o = Object.getOwnPropertyDescriptor;
|
|
9691
|
+
var __decorateClass$o = (decorators, target, key, kind) => {
|
|
9692
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$o(target, key) : target;
|
|
9687
9693
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
9688
|
-
if (kind && result) __defProp$
|
|
9694
|
+
if (kind && result) __defProp$o(target, key, result);
|
|
9689
9695
|
return result;
|
|
9690
9696
|
};
|
|
9691
9697
|
class MessageBar extends FASTElement {
|
|
@@ -9731,36 +9737,36 @@ class MessageBar extends FASTElement {
|
|
|
9731
9737
|
swapStates(this.elementInternals, prev, next, MessageBarIntent);
|
|
9732
9738
|
}
|
|
9733
9739
|
}
|
|
9734
|
-
__decorateClass$
|
|
9735
|
-
__decorateClass$
|
|
9736
|
-
__decorateClass$
|
|
9740
|
+
__decorateClass$o([attr], MessageBar.prototype, "shape", 2);
|
|
9741
|
+
__decorateClass$o([attr], MessageBar.prototype, "layout", 2);
|
|
9742
|
+
__decorateClass$o([attr], MessageBar.prototype, "intent", 2);
|
|
9737
9743
|
|
|
9738
|
-
const styles$
|
|
9744
|
+
const styles$j = css`
|
|
9739
9745
|
:host{display:grid;box-sizing:border-box;font-family:${fontFamilyBase};font-size:${fontSizeBase200};line-height:${lineHeightBase200};width:100%;background:${colorNeutralBackground3};border:1px solid ${colorNeutralStroke1};padding-inline:${spacingHorizontalM};border-radius:${borderRadiusMedium};min-height:36px;align-items:center;grid-template:'icon body actions dismiss' / auto 1fr auto auto;contain:layout style paint}:host(${squareState}){border-radius:0}:host(${successState}){background-color:${colorPaletteGreenBackground1};border-color:${colorPaletteGreenBorder1}}:host(${warningState}){background-color:${colorPaletteDarkOrangeBackground1};border-color:${colorPaletteDarkOrangeBorder1}}:host(${errorState}){background-color:${colorPaletteRedBackground1};border-color:${colorPaletteRedBorder1}}:host(${multiLineState}){grid-template-areas:'icon body dismiss'
|
|
9740
9746
|
'actions actions actions';grid-template-columns:auto 1fr auto;grid-template-rows:auto auto 1fr;padding-block:${spacingVerticalMNudge};padding-inline:${spacingHorizontalM}}.content{grid-area:body;max-width:520px;padding-block:${spacingVerticalMNudge};padding-inline:0}:host(${multiLineState}) .content{padding:0}::slotted([slot='icon']){display:flex;grid-area:icon;flex-direction:column;align-items:center;color:${colorNeutralForeground3};margin-inline-end:${spacingHorizontalS}}:host(${multiLineState}) ::slotted([slot='icon']){align-items:start;height:100%}::slotted([slot='dismiss']){grid-area:dismiss}.actions{grid-area:actions;display:flex;justify-self:end;margin-inline-end:${spacingHorizontalS};gap:${spacingHorizontalS}}:host(${multiLineState}) .actions{margin-block-start:${spacingVerticalMNudge};margin-inline-end:0}:host(${multiLineState}) ::slotted([slot='dismiss']){align-items:start;height:100%;padding-block-start:${spacingVerticalS}}::slotted(*){font-size:inherit}`;
|
|
9741
9747
|
|
|
9742
9748
|
function messageBarTemplate() {
|
|
9743
9749
|
return html`<slot name="icon"></slot><div class="content"><slot></slot></div><div class="actions"><slot name="actions"></slot></div><slot name="dismiss"></slot>`;
|
|
9744
9750
|
}
|
|
9745
|
-
const template$
|
|
9751
|
+
const template$j = messageBarTemplate();
|
|
9746
9752
|
|
|
9747
|
-
const definition$
|
|
9753
|
+
const definition$j = MessageBar.compose({
|
|
9748
9754
|
name: `${FluentDesignSystem.prefix}-message-bar`,
|
|
9749
|
-
template: template$
|
|
9750
|
-
styles: styles$
|
|
9755
|
+
template: template$j,
|
|
9756
|
+
styles: styles$j,
|
|
9751
9757
|
shadowOptions: {
|
|
9752
9758
|
mode: FluentDesignSystem.shadowRootMode
|
|
9753
9759
|
}
|
|
9754
9760
|
});
|
|
9755
9761
|
|
|
9756
|
-
definition$
|
|
9762
|
+
definition$j.define(FluentDesignSystem.registry);
|
|
9757
9763
|
|
|
9758
|
-
var __defProp$
|
|
9759
|
-
var __getOwnPropDesc$
|
|
9760
|
-
var __decorateClass$
|
|
9761
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
9764
|
+
var __defProp$n = Object.defineProperty;
|
|
9765
|
+
var __getOwnPropDesc$n = Object.getOwnPropertyDescriptor;
|
|
9766
|
+
var __decorateClass$n = (decorators, target, key, kind) => {
|
|
9767
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$n(target, key) : target;
|
|
9762
9768
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
9763
|
-
if (kind && result) __defProp$
|
|
9769
|
+
if (kind && result) __defProp$n(target, key, result);
|
|
9764
9770
|
return result;
|
|
9765
9771
|
};
|
|
9766
9772
|
class DropdownOption extends FASTElement {
|
|
@@ -9970,43 +9976,43 @@ class DropdownOption extends FASTElement {
|
|
|
9970
9976
|
* @public
|
|
9971
9977
|
*/
|
|
9972
9978
|
DropdownOption.formAssociated = true;
|
|
9973
|
-
__decorateClass$
|
|
9974
|
-
__decorateClass$
|
|
9979
|
+
__decorateClass$n([observable], DropdownOption.prototype, "active", 2);
|
|
9980
|
+
__decorateClass$n([attr({
|
|
9975
9981
|
attribute: "current-selected",
|
|
9976
9982
|
mode: "boolean"
|
|
9977
9983
|
})], DropdownOption.prototype, "currentSelected", 2);
|
|
9978
|
-
__decorateClass$
|
|
9984
|
+
__decorateClass$n([attr({
|
|
9979
9985
|
attribute: "selected",
|
|
9980
9986
|
mode: "boolean"
|
|
9981
9987
|
})], DropdownOption.prototype, "defaultSelected", 2);
|
|
9982
|
-
__decorateClass$
|
|
9983
|
-
__decorateClass$
|
|
9984
|
-
__decorateClass$
|
|
9988
|
+
__decorateClass$n([observable], DropdownOption.prototype, "descriptionSlot", 2);
|
|
9989
|
+
__decorateClass$n([observable], DropdownOption.prototype, "disabled", 2);
|
|
9990
|
+
__decorateClass$n([attr({
|
|
9985
9991
|
attribute: "disabled",
|
|
9986
9992
|
mode: "boolean"
|
|
9987
9993
|
})], DropdownOption.prototype, "disabledAttribute", 2);
|
|
9988
|
-
__decorateClass$
|
|
9994
|
+
__decorateClass$n([attr({
|
|
9989
9995
|
attribute: "form"
|
|
9990
9996
|
})], DropdownOption.prototype, "formAttribute", 2);
|
|
9991
|
-
__decorateClass$
|
|
9997
|
+
__decorateClass$n([attr({
|
|
9992
9998
|
mode: "boolean"
|
|
9993
9999
|
})], DropdownOption.prototype, "freeform", 2);
|
|
9994
|
-
__decorateClass$
|
|
10000
|
+
__decorateClass$n([attr({
|
|
9995
10001
|
attribute: "id"
|
|
9996
10002
|
})], DropdownOption.prototype, "id", 2);
|
|
9997
|
-
__decorateClass$
|
|
10003
|
+
__decorateClass$n([attr({
|
|
9998
10004
|
attribute: "value",
|
|
9999
10005
|
mode: "fromView"
|
|
10000
10006
|
})], DropdownOption.prototype, "initialValue", 2);
|
|
10001
|
-
__decorateClass$
|
|
10002
|
-
__decorateClass$
|
|
10003
|
-
__decorateClass$
|
|
10004
|
-
__decorateClass$
|
|
10007
|
+
__decorateClass$n([observable], DropdownOption.prototype, "multiple", 2);
|
|
10008
|
+
__decorateClass$n([attr], DropdownOption.prototype, "name", 2);
|
|
10009
|
+
__decorateClass$n([observable], DropdownOption.prototype, "start", 2);
|
|
10010
|
+
__decorateClass$n([attr({
|
|
10005
10011
|
attribute: "text",
|
|
10006
10012
|
mode: "fromView"
|
|
10007
10013
|
})], DropdownOption.prototype, "textAttribute", 2);
|
|
10008
10014
|
|
|
10009
|
-
const styles$
|
|
10015
|
+
const styles$i = css`
|
|
10010
10016
|
${display("inline-grid")}
|
|
10011
10017
|
|
|
10012
10018
|
:host{-webkit-tap-highlight-color:transparent;${typographyBody1Styles}
|
|
@@ -10032,17 +10038,17 @@ function dropdownOptionTemplate(options = {}) {
|
|
|
10032
10038
|
filter: elements("output")
|
|
10033
10039
|
})}></slot></div><div class="description" part="description"><slot name="description" ${slotted("descriptionSlot")}></slot></div>`;
|
|
10034
10040
|
}
|
|
10035
|
-
const template$
|
|
10041
|
+
const template$i = dropdownOptionTemplate({
|
|
10036
10042
|
checkedIndicator: checkedIndicator$1
|
|
10037
10043
|
});
|
|
10038
10044
|
|
|
10039
|
-
const definition$
|
|
10045
|
+
const definition$i = DropdownOption.compose({
|
|
10040
10046
|
name: `${FluentDesignSystem.prefix}-option`,
|
|
10041
|
-
template: template$
|
|
10042
|
-
styles: styles$
|
|
10047
|
+
template: template$i,
|
|
10048
|
+
styles: styles$i
|
|
10043
10049
|
});
|
|
10044
10050
|
|
|
10045
|
-
definition$
|
|
10051
|
+
definition$i.define(FluentDesignSystem.registry);
|
|
10046
10052
|
|
|
10047
10053
|
const ProgressBarThickness = {
|
|
10048
10054
|
medium: "medium",
|
|
@@ -10058,12 +10064,12 @@ const ProgressBarValidationState = {
|
|
|
10058
10064
|
error: "error"
|
|
10059
10065
|
};
|
|
10060
10066
|
|
|
10061
|
-
var __defProp$
|
|
10062
|
-
var __getOwnPropDesc$
|
|
10063
|
-
var __decorateClass$
|
|
10064
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
10067
|
+
var __defProp$m = Object.defineProperty;
|
|
10068
|
+
var __getOwnPropDesc$m = Object.getOwnPropertyDescriptor;
|
|
10069
|
+
var __decorateClass$m = (decorators, target, key, kind) => {
|
|
10070
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$m(target, key) : target;
|
|
10065
10071
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
10066
|
-
if (kind && result) __defProp$
|
|
10072
|
+
if (kind && result) __defProp$m(target, key, result);
|
|
10067
10073
|
return result;
|
|
10068
10074
|
};
|
|
10069
10075
|
class BaseProgressBar extends FASTElement {
|
|
@@ -10121,26 +10127,26 @@ class BaseProgressBar extends FASTElement {
|
|
|
10121
10127
|
return range === 0 ? 0 : Math.fround((value - min) / range * 100);
|
|
10122
10128
|
}
|
|
10123
10129
|
}
|
|
10124
|
-
__decorateClass$
|
|
10130
|
+
__decorateClass$m([attr({
|
|
10125
10131
|
attribute: "validation-state"
|
|
10126
10132
|
})], BaseProgressBar.prototype, "validationState", 2);
|
|
10127
|
-
__decorateClass$
|
|
10133
|
+
__decorateClass$m([attr({
|
|
10128
10134
|
converter: nullableNumberConverter
|
|
10129
10135
|
})], BaseProgressBar.prototype, "value", 2);
|
|
10130
|
-
__decorateClass$
|
|
10136
|
+
__decorateClass$m([attr({
|
|
10131
10137
|
converter: nullableNumberConverter
|
|
10132
10138
|
})], BaseProgressBar.prototype, "min", 2);
|
|
10133
|
-
__decorateClass$
|
|
10139
|
+
__decorateClass$m([attr({
|
|
10134
10140
|
converter: nullableNumberConverter
|
|
10135
10141
|
})], BaseProgressBar.prototype, "max", 2);
|
|
10136
|
-
__decorateClass$
|
|
10142
|
+
__decorateClass$m([volatile], BaseProgressBar.prototype, "percentComplete", 1);
|
|
10137
10143
|
|
|
10138
|
-
var __defProp$
|
|
10139
|
-
var __getOwnPropDesc$
|
|
10140
|
-
var __decorateClass$
|
|
10141
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
10144
|
+
var __defProp$l = Object.defineProperty;
|
|
10145
|
+
var __getOwnPropDesc$l = Object.getOwnPropertyDescriptor;
|
|
10146
|
+
var __decorateClass$l = (decorators, target, key, kind) => {
|
|
10147
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$l(target, key) : target;
|
|
10142
10148
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
10143
|
-
if (kind && result) __defProp$
|
|
10149
|
+
if (kind && result) __defProp$l(target, key, result);
|
|
10144
10150
|
return result;
|
|
10145
10151
|
};
|
|
10146
10152
|
class ProgressBar extends BaseProgressBar {
|
|
@@ -10161,10 +10167,10 @@ class ProgressBar extends BaseProgressBar {
|
|
|
10161
10167
|
swapStates(this.elementInternals, prev, next, ProgressBarShape);
|
|
10162
10168
|
}
|
|
10163
10169
|
}
|
|
10164
|
-
__decorateClass$
|
|
10165
|
-
__decorateClass$
|
|
10170
|
+
__decorateClass$l([attr], ProgressBar.prototype, "thickness", 2);
|
|
10171
|
+
__decorateClass$l([attr], ProgressBar.prototype, "shape", 2);
|
|
10166
10172
|
|
|
10167
|
-
const styles$
|
|
10173
|
+
const styles$h = css`
|
|
10168
10174
|
${display("block")}
|
|
10169
10175
|
|
|
10170
10176
|
:host{width:100%;height:2px;overflow-x:hidden;background-color:${colorNeutralBackground6};border-radius:${borderRadiusMedium};contain:content}:host(${largeState}){height:4px}:host(${squareState}){border-radius:${borderRadiusNone}}.indicator{background-color:${colorCompoundBrandBackground};border-radius:inherit;height:100%}:host([value]) .indicator{transition:all 0.2s ease-in-out}:host(:not([value])) .indicator{position:relative;width:33%;background-image:linear-gradient(
|
|
@@ -10175,15 +10181,15 @@ const styles$f = css`
|
|
|
10175
10181
|
function progressTemplate() {
|
|
10176
10182
|
return html`<div class="indicator" part="indicator" style="${x => typeof x.value === "number" ? `width: ${x.percentComplete}%` : void 0}"></div>`;
|
|
10177
10183
|
}
|
|
10178
|
-
const template$
|
|
10184
|
+
const template$h = progressTemplate();
|
|
10179
10185
|
|
|
10180
|
-
const definition$
|
|
10186
|
+
const definition$h = ProgressBar.compose({
|
|
10181
10187
|
name: `${FluentDesignSystem.prefix}-progress-bar`,
|
|
10182
|
-
template: template$
|
|
10183
|
-
styles: styles$
|
|
10188
|
+
template: template$h,
|
|
10189
|
+
styles: styles$h
|
|
10184
10190
|
});
|
|
10185
10191
|
|
|
10186
|
-
definition$
|
|
10192
|
+
definition$h.define(FluentDesignSystem.registry);
|
|
10187
10193
|
|
|
10188
10194
|
class Radio extends BaseCheckbox {
|
|
10189
10195
|
connectedCallback() {
|
|
@@ -10268,12 +10274,12 @@ function getRootActiveElement(element) {
|
|
|
10268
10274
|
|
|
10269
10275
|
const RadioGroupOrientation = Orientation;
|
|
10270
10276
|
|
|
10271
|
-
var __defProp$
|
|
10272
|
-
var __getOwnPropDesc$
|
|
10273
|
-
var __decorateClass$
|
|
10274
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
10277
|
+
var __defProp$k = Object.defineProperty;
|
|
10278
|
+
var __getOwnPropDesc$k = Object.getOwnPropertyDescriptor;
|
|
10279
|
+
var __decorateClass$k = (decorators, target, key, kind) => {
|
|
10280
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$k(target, key) : target;
|
|
10275
10281
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
10276
|
-
if (kind && result) __defProp$
|
|
10282
|
+
if (kind && result) __defProp$k(target, key, result);
|
|
10277
10283
|
return result;
|
|
10278
10284
|
};
|
|
10279
10285
|
class RadioGroup extends FASTElement {
|
|
@@ -10702,23 +10708,23 @@ class RadioGroup extends FASTElement {
|
|
|
10702
10708
|
* @public
|
|
10703
10709
|
*/
|
|
10704
10710
|
RadioGroup.formAssociated = true;
|
|
10705
|
-
__decorateClass$
|
|
10706
|
-
__decorateClass$
|
|
10711
|
+
__decorateClass$k([observable], RadioGroup.prototype, "checkedIndex", 2);
|
|
10712
|
+
__decorateClass$k([attr({
|
|
10707
10713
|
attribute: "disabled",
|
|
10708
10714
|
mode: "boolean"
|
|
10709
10715
|
})], RadioGroup.prototype, "disabled", 2);
|
|
10710
|
-
__decorateClass$
|
|
10716
|
+
__decorateClass$k([attr({
|
|
10711
10717
|
attribute: "value",
|
|
10712
10718
|
mode: "fromView"
|
|
10713
10719
|
})], RadioGroup.prototype, "initialValue", 2);
|
|
10714
|
-
__decorateClass$
|
|
10715
|
-
__decorateClass$
|
|
10716
|
-
__decorateClass$
|
|
10717
|
-
__decorateClass$
|
|
10720
|
+
__decorateClass$k([attr], RadioGroup.prototype, "name", 2);
|
|
10721
|
+
__decorateClass$k([attr], RadioGroup.prototype, "orientation", 2);
|
|
10722
|
+
__decorateClass$k([observable], RadioGroup.prototype, "radios", 2);
|
|
10723
|
+
__decorateClass$k([attr({
|
|
10718
10724
|
mode: "boolean"
|
|
10719
10725
|
})], RadioGroup.prototype, "required", 2);
|
|
10720
10726
|
|
|
10721
|
-
const styles$
|
|
10727
|
+
const styles$g = css`
|
|
10722
10728
|
${display("flex")}
|
|
10723
10729
|
|
|
10724
10730
|
:host{-webkit-tap-highlight-color:transparent;cursor:pointer;gap:${spacingVerticalL}}:host(${disabledState}),:host([orientation='vertical']){flex-direction:column;justify-content:flex-start}:host([orientation='horizontal']){flex-direction:row}::slotted(*){color:${colorNeutralForeground3}}::slotted(:hover){color:${colorNeutralForeground2}}::slotted(:active){color:${colorNeutralForeground1}}::slotted(${disabledState}){color:${colorNeutralForegroundDisabled}}::slotted(${checkedState}){color:${colorNeutralForeground1}}`;
|
|
@@ -10726,17 +10732,17 @@ const styles$e = css`
|
|
|
10726
10732
|
function radioGroupTemplate() {
|
|
10727
10733
|
return html`<template @disabled="${(x, c) => x.disabledRadioHandler(c.event)}" @change="${(x, c) => x.changeHandler(c.event)}" @click="${(x, c) => x.clickHandler(c.event)}" @focusin="${(x, c) => x.focusinHandler(c.event)}" @focusout="${(x, c) => x.focusoutHandler(c.event)}" @keydown="${(x, c) => x.keydownHandler(c.event)}"><slot @slotchange="${(x, c) => x.slotchangeHandler(c.event)}"></slot></template>`;
|
|
10728
10734
|
}
|
|
10729
|
-
const template$
|
|
10735
|
+
const template$g = radioGroupTemplate();
|
|
10730
10736
|
|
|
10731
|
-
const definition$
|
|
10737
|
+
const definition$g = RadioGroup.compose({
|
|
10732
10738
|
name: `${FluentDesignSystem.prefix}-radio-group`,
|
|
10733
|
-
template: template$
|
|
10734
|
-
styles: styles$
|
|
10739
|
+
template: template$g,
|
|
10740
|
+
styles: styles$g
|
|
10735
10741
|
});
|
|
10736
10742
|
|
|
10737
|
-
definition$
|
|
10743
|
+
definition$g.define(FluentDesignSystem.registry);
|
|
10738
10744
|
|
|
10739
|
-
const styles$
|
|
10745
|
+
const styles$f = css`
|
|
10740
10746
|
${display("inline-flex")}
|
|
10741
10747
|
|
|
10742
10748
|
:host{--size:16px;aspect-ratio:1;background-color:${colorNeutralBackground1};border:${strokeWidthThin} solid ${colorNeutralStrokeAccessible};border-radius:${borderRadiusCircular};box-sizing:border-box;position:relative;width:var(--size)}:host([size='large']){--size:20px}.checked-indicator{aspect-ratio:1;border-radius:${borderRadiusCircular};color:${colorNeutralForegroundInverted};inset:0;margin:auto;position:absolute;width:calc(var(--size) * 0.625)}:host(:not([slot='input']))::after{content:'' / '';position:absolute;display:block;inset:-8px;box-sizing:border-box;outline:none;border:${strokeWidthThick} solid ${colorTransparentStroke};border-radius:${borderRadiusMedium}}:host(:not([slot='input']):focus-visible)::after{border-color:${colorStrokeFocus2}}:host(:hover){border-color:${colorNeutralStrokeAccessibleHover}}:host(${checkedState}){border-color:${colorCompoundBrandStroke}}:host(${checkedState}) .checked-indicator{background-color:${colorCompoundBrandBackground}}:host(${checkedState}:hover) .checked-indicator{background-color:${colorCompoundBrandBackgroundHover}}:host(:active){border-color:${colorNeutralStrokeAccessiblePressed}}:host(${checkedState}:active) .checked-indicator{background-color:${colorCompoundBrandBackgroundPressed}}:host(:focus-visible){outline:none}:host(${disabledState}){background-color:${colorNeutralBackgroundDisabled};border-color:${colorNeutralStrokeDisabled}}:host(${checkedState}${disabledState}) .checked-indicator{background-color:${colorNeutralStrokeDisabled}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
@@ -10749,24 +10755,24 @@ const checkedIndicator = html.partial( /* html */
|
|
|
10749
10755
|
function radioTemplate(options = {}) {
|
|
10750
10756
|
return html`<template @click="${(x, c) => x.clickHandler(c.event)}" @keydown="${(x, c) => x.keydownHandler(c.event)}" @keyup="${(x, c) => x.keyupHandler(c.event)}"><slot name="checked-indicator">${staticallyCompose(options.checkedIndicator)}</slot></template>`;
|
|
10751
10757
|
}
|
|
10752
|
-
const template$
|
|
10758
|
+
const template$f = radioTemplate({
|
|
10753
10759
|
checkedIndicator
|
|
10754
10760
|
});
|
|
10755
10761
|
|
|
10756
|
-
const definition$
|
|
10762
|
+
const definition$f = Radio.compose({
|
|
10757
10763
|
name: `${FluentDesignSystem.prefix}-radio`,
|
|
10758
|
-
template: template$
|
|
10759
|
-
styles: styles$
|
|
10764
|
+
template: template$f,
|
|
10765
|
+
styles: styles$f
|
|
10760
10766
|
});
|
|
10761
10767
|
|
|
10762
|
-
definition$
|
|
10768
|
+
definition$f.define(FluentDesignSystem.registry);
|
|
10763
10769
|
|
|
10764
|
-
var __defProp$
|
|
10765
|
-
var __getOwnPropDesc$
|
|
10766
|
-
var __decorateClass$
|
|
10767
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
10770
|
+
var __defProp$j = Object.defineProperty;
|
|
10771
|
+
var __getOwnPropDesc$j = Object.getOwnPropertyDescriptor;
|
|
10772
|
+
var __decorateClass$j = (decorators, target, key, kind) => {
|
|
10773
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$j(target, key) : target;
|
|
10768
10774
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
10769
|
-
if (kind && result) __defProp$
|
|
10775
|
+
if (kind && result) __defProp$j(target, key, result);
|
|
10770
10776
|
return result;
|
|
10771
10777
|
};
|
|
10772
10778
|
class BaseRatingDisplay extends FASTElement {
|
|
@@ -10832,20 +10838,20 @@ class BaseRatingDisplay extends FASTElement {
|
|
|
10832
10838
|
return htmlString;
|
|
10833
10839
|
}
|
|
10834
10840
|
}
|
|
10835
|
-
__decorateClass$
|
|
10841
|
+
__decorateClass$j([attr({
|
|
10836
10842
|
converter: nullableNumberConverter
|
|
10837
10843
|
})], BaseRatingDisplay.prototype, "count", 2);
|
|
10838
|
-
__decorateClass$
|
|
10844
|
+
__decorateClass$j([attr({
|
|
10839
10845
|
attribute: "icon-view-box"
|
|
10840
10846
|
})], BaseRatingDisplay.prototype, "iconViewBox", 2);
|
|
10841
|
-
__decorateClass$
|
|
10847
|
+
__decorateClass$j([attr({
|
|
10842
10848
|
converter: nullableNumberConverter
|
|
10843
10849
|
})], BaseRatingDisplay.prototype, "max", 2);
|
|
10844
|
-
__decorateClass$
|
|
10850
|
+
__decorateClass$j([attr({
|
|
10845
10851
|
converter: nullableNumberConverter
|
|
10846
10852
|
})], BaseRatingDisplay.prototype, "value", 2);
|
|
10847
|
-
__decorateClass$
|
|
10848
|
-
__decorateClass$
|
|
10853
|
+
__decorateClass$j([observable], BaseRatingDisplay.prototype, "slottedIcon", 2);
|
|
10854
|
+
__decorateClass$j([observable], BaseRatingDisplay.prototype, "customIcon", 2);
|
|
10849
10855
|
|
|
10850
10856
|
const RatingDisplayColor = {
|
|
10851
10857
|
neutral: "neutral",
|
|
@@ -10858,12 +10864,12 @@ const RatingDisplaySize = {
|
|
|
10858
10864
|
large: "large"
|
|
10859
10865
|
};
|
|
10860
10866
|
|
|
10861
|
-
var __defProp$
|
|
10862
|
-
var __getOwnPropDesc$
|
|
10863
|
-
var __decorateClass$
|
|
10864
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
10867
|
+
var __defProp$i = Object.defineProperty;
|
|
10868
|
+
var __getOwnPropDesc$i = Object.getOwnPropertyDescriptor;
|
|
10869
|
+
var __decorateClass$i = (decorators, target, key, kind) => {
|
|
10870
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$i(target, key) : target;
|
|
10865
10871
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
10866
|
-
if (kind && result) __defProp$
|
|
10872
|
+
if (kind && result) __defProp$i(target, key, result);
|
|
10867
10873
|
return result;
|
|
10868
10874
|
};
|
|
10869
10875
|
class RatingDisplay extends BaseRatingDisplay {
|
|
@@ -10906,13 +10912,13 @@ class RatingDisplay extends BaseRatingDisplay {
|
|
|
10906
10912
|
return (this.compact ? 1 : this.max ?? 5) * 2;
|
|
10907
10913
|
}
|
|
10908
10914
|
}
|
|
10909
|
-
__decorateClass$
|
|
10910
|
-
__decorateClass$
|
|
10911
|
-
__decorateClass$
|
|
10915
|
+
__decorateClass$i([attr], RatingDisplay.prototype, "color", 2);
|
|
10916
|
+
__decorateClass$i([attr], RatingDisplay.prototype, "size", 2);
|
|
10917
|
+
__decorateClass$i([attr({
|
|
10912
10918
|
mode: "boolean"
|
|
10913
10919
|
})], RatingDisplay.prototype, "compact", 2);
|
|
10914
10920
|
|
|
10915
|
-
const styles$
|
|
10921
|
+
const styles$e = css`
|
|
10916
10922
|
${display("inline-flex")}
|
|
10917
10923
|
|
|
10918
10924
|
:host{--icon-size:16px;--icon-color-filled:${colorPaletteMarigoldBackground3};--icon-color-empty:${colorPaletteMarigoldBackground2};align-items:center;color:${colorNeutralForeground1};font-family:${fontFamilyBase};font-size:${fontSizeBase200};line-height:${lineHeightBase200};contain:layout style;user-select:none}:host(${smallState}){--icon-size:12px}:host(${largeState}){--icon-size:20px;font-size:${fontSizeBase300};line-height:${lineHeightBase300}}::slotted([slot='icon']){display:none}svg{width:var(--icon-size);height:var(--icon-size);fill:var(--icon-color-filled);margin-inline-end:${spacingHorizontalXXS}}svg:nth-child(odd){clip-path:inset(0 50% 0 0);margin-inline-end:calc(0px - var(--icon-size))}:host(${neutralState}) svg{--icon-color-filled:${colorNeutralForeground1}}:host(${brandState}) svg{--icon-color-filled:${colorBrandBackground}}:host(:is([value^='-'],[value='0'])) svg,:host(:not([value])) svg,svg[selected] ~ svg{fill:var(--icon-color-empty)}:host(${neutralState}:is([value^='-'],[value='0'])) svg,:host(${neutralState}:not([value])) svg,:host(${neutralState}) svg[selected] ~ svg{--icon-color-empty:${colorNeutralBackground1Pressed}}:host(${brandState}:is([value^='-'],[value='0'])) svg,:host(${brandState}:not([value])) svg,:host(${brandState}) svg[selected] ~ svg{--icon-color-empty:${colorBrandStroke2}}.value-label,::slotted([slot='value']){display:block;margin-inline-start:${spacingHorizontalXS};font-weight:${fontWeightSemibold}}:host(${smallState}) .value-label,:host(${smallState}) ::slotted([slot='value']){margin-inline-start:${spacingHorizontalXXS}}:host(${largeState}) .value-label,:host(${largeState}) ::slotted([slot='value']){margin-inline-start:${spacingHorizontalSNudge}}:host(:not([count])) .count-label{display:none}.count-label::before,::slotted([slot='count'])::before{content:'·';margin-inline:${spacingHorizontalXS}}:host(${smallState}) .count-label::before,:host(${smallState}) ::slotted([slot='count'])::before{margin-inline:${spacingHorizontalXXS}}:host(${largeState}) .count-label::before,:host(${largeState}) ::slotted([slot='count'])::before{margin-inline:${spacingHorizontalSNudge}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
@@ -10925,15 +10931,15 @@ function ratingDisplayTemplate() {
|
|
|
10925
10931
|
filter: elements("svg")
|
|
10926
10932
|
})}>${star}</slot><slot name="value"><span class="value-label" aria-hidden="true">${x => x.value}</span></slot><slot name="count"><span class="count-label" aria-hidden="true">${x => x.formattedCount}</span></slot>`;
|
|
10927
10933
|
}
|
|
10928
|
-
const template$
|
|
10934
|
+
const template$e = ratingDisplayTemplate();
|
|
10929
10935
|
|
|
10930
|
-
const definition$
|
|
10936
|
+
const definition$e = RatingDisplay.compose({
|
|
10931
10937
|
name: `${FluentDesignSystem.prefix}-rating-display`,
|
|
10932
|
-
template: template$
|
|
10933
|
-
styles: styles$
|
|
10938
|
+
template: template$e,
|
|
10939
|
+
styles: styles$e
|
|
10934
10940
|
});
|
|
10935
10941
|
|
|
10936
|
-
definition$
|
|
10942
|
+
definition$e.define(FluentDesignSystem.registry);
|
|
10937
10943
|
|
|
10938
10944
|
const SliderSize = {
|
|
10939
10945
|
small: "small",
|
|
@@ -10952,12 +10958,12 @@ function convertPixelToPercent(pixelPos, minPosition, maxPosition, direction) {
|
|
|
10952
10958
|
return pct;
|
|
10953
10959
|
}
|
|
10954
10960
|
|
|
10955
|
-
var __defProp$
|
|
10956
|
-
var __getOwnPropDesc$
|
|
10957
|
-
var __decorateClass$
|
|
10958
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
10961
|
+
var __defProp$h = Object.defineProperty;
|
|
10962
|
+
var __getOwnPropDesc$h = Object.getOwnPropertyDescriptor;
|
|
10963
|
+
var __decorateClass$h = (decorators, target, key, kind) => {
|
|
10964
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$h(target, key) : target;
|
|
10959
10965
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
10960
|
-
if (kind && result) __defProp$
|
|
10966
|
+
if (kind && result) __defProp$h(target, key, result);
|
|
10961
10967
|
return result;
|
|
10962
10968
|
};
|
|
10963
10969
|
class Slider extends FASTElement {
|
|
@@ -11482,36 +11488,36 @@ class Slider extends FASTElement {
|
|
|
11482
11488
|
* @public
|
|
11483
11489
|
*/
|
|
11484
11490
|
Slider.formAssociated = true;
|
|
11485
|
-
__decorateClass$
|
|
11486
|
-
__decorateClass$
|
|
11491
|
+
__decorateClass$h([attr], Slider.prototype, "size", 2);
|
|
11492
|
+
__decorateClass$h([attr({
|
|
11487
11493
|
attribute: "value",
|
|
11488
11494
|
mode: "fromView"
|
|
11489
11495
|
})], Slider.prototype, "initialValue", 2);
|
|
11490
|
-
__decorateClass$
|
|
11491
|
-
__decorateClass$
|
|
11492
|
-
__decorateClass$
|
|
11493
|
-
__decorateClass$
|
|
11494
|
-
__decorateClass$
|
|
11495
|
-
__decorateClass$
|
|
11496
|
-
__decorateClass$
|
|
11497
|
-
__decorateClass$
|
|
11498
|
-
__decorateClass$
|
|
11499
|
-
__decorateClass$
|
|
11496
|
+
__decorateClass$h([observable], Slider.prototype, "direction", 2);
|
|
11497
|
+
__decorateClass$h([observable], Slider.prototype, "isDragging", 2);
|
|
11498
|
+
__decorateClass$h([observable], Slider.prototype, "position", 2);
|
|
11499
|
+
__decorateClass$h([observable], Slider.prototype, "trackWidth", 2);
|
|
11500
|
+
__decorateClass$h([observable], Slider.prototype, "trackMinWidth", 2);
|
|
11501
|
+
__decorateClass$h([observable], Slider.prototype, "trackHeight", 2);
|
|
11502
|
+
__decorateClass$h([observable], Slider.prototype, "trackLeft", 2);
|
|
11503
|
+
__decorateClass$h([observable], Slider.prototype, "trackMinHeight", 2);
|
|
11504
|
+
__decorateClass$h([observable], Slider.prototype, "valueTextFormatter", 2);
|
|
11505
|
+
__decorateClass$h([attr({
|
|
11500
11506
|
mode: "boolean"
|
|
11501
11507
|
})], Slider.prototype, "disabled", 2);
|
|
11502
|
-
__decorateClass$
|
|
11508
|
+
__decorateClass$h([attr({
|
|
11503
11509
|
converter: numberLikeStringConverter
|
|
11504
11510
|
})], Slider.prototype, "min", 2);
|
|
11505
|
-
__decorateClass$
|
|
11511
|
+
__decorateClass$h([attr({
|
|
11506
11512
|
converter: numberLikeStringConverter
|
|
11507
11513
|
})], Slider.prototype, "max", 2);
|
|
11508
|
-
__decorateClass$
|
|
11514
|
+
__decorateClass$h([attr({
|
|
11509
11515
|
converter: numberLikeStringConverter
|
|
11510
11516
|
})], Slider.prototype, "step", 2);
|
|
11511
|
-
__decorateClass$
|
|
11512
|
-
__decorateClass$
|
|
11517
|
+
__decorateClass$h([attr], Slider.prototype, "orientation", 2);
|
|
11518
|
+
__decorateClass$h([attr], Slider.prototype, "mode", 2);
|
|
11513
11519
|
|
|
11514
|
-
const styles$
|
|
11520
|
+
const styles$d = css`
|
|
11515
11521
|
${display("inline-grid")}
|
|
11516
11522
|
|
|
11517
11523
|
:host{--thumb-size:20px;--track-margin-inline:calc(var(--thumb-size) / 2);--track-size:4px;--track-overhang:calc(var(--track-size) / -2);--rail-color:${colorCompoundBrandBackground};--track-color:${colorNeutralStrokeAccessible};--slider-direction:90deg;--border-radius:${borderRadiusMedium};--step-marker-inset:var(--track-overhang) -1px;position:relative;align-items:center;justify-content:center;box-sizing:border-box;outline:none;user-select:none;touch-action:none;min-width:120px;min-height:32px;grid-template-rows:1fr var(--thumb-size) 1fr;grid-template-columns:var(--track-margin-inline) 1fr var(--track-margin-inline)}:host(:hover){--rail-color:${colorCompoundBrandBackgroundHover}}:host(:active){--rail-color:${colorCompoundBrandBackgroundPressed}}:host(:disabled){--rail-color:${colorNeutralForegroundDisabled};--track-color:${colorNeutralBackgroundDisabled}}:host(:not(:disabled)){cursor:pointer}:host(:dir(rtl)){--slider-direction:-90deg}:host(${smallState}){--thumb-size:16px;--track-overhang:-1px;--track-size:2px;--border-radius:${borderRadiusSmall}}:host(${verticalState}){--slider-direction:0deg;--step-marker-inset:-1px var(--track-overhang);min-height:120px;grid-template-rows:var(--track-margin-inline) 1fr var(--track-margin-inline);grid-template-columns:1fr var(--thumb-size) 1fr;width:unset;min-width:32px;justify-items:center}:host(:not([slot='input']):focus-visible){box-shadow:0 0 0 2pt ${colorStrokeFocus2};outline:1px solid ${colorStrokeFocus1}}:host:after,.track{height:var(--track-size);width:100%}:host:after{background-image:linear-gradient(
|
|
@@ -11524,17 +11530,17 @@ const styles$b = css`
|
|
|
11524
11530
|
function sliderTemplate(options = {}) {
|
|
11525
11531
|
return html`<template tabindex="${x => x.disabled ? null : 0}" @pointerdown="${(x, c) => x.handlePointerDown(c.event)}" @keydown="${(x, c) => x.handleKeydown(c.event)}"><div ${ref("track")} part="track-container" class="track" style="${x => x.position}"></div><div ${ref("thumb")} part="thumb-container" class="thumb-container" style="${x => x.position}" @pointerdown="${(x, c) => x.handleThumbPointerDown(c.event)}"><slot name="thumb">${staticallyCompose(options.thumb)}</slot></div></template>`;
|
|
11526
11532
|
}
|
|
11527
|
-
const template$
|
|
11533
|
+
const template$d = sliderTemplate({
|
|
11528
11534
|
thumb: `<div class="thumb"></div>`
|
|
11529
11535
|
});
|
|
11530
11536
|
|
|
11531
|
-
const definition$
|
|
11537
|
+
const definition$d = Slider.compose({
|
|
11532
11538
|
name: `${FluentDesignSystem.prefix}-slider`,
|
|
11533
|
-
template: template$
|
|
11534
|
-
styles: styles$
|
|
11539
|
+
template: template$d,
|
|
11540
|
+
styles: styles$d
|
|
11535
11541
|
});
|
|
11536
11542
|
|
|
11537
|
-
definition$
|
|
11543
|
+
definition$d.define(FluentDesignSystem.registry);
|
|
11538
11544
|
|
|
11539
11545
|
class BaseSpinner extends FASTElement {
|
|
11540
11546
|
constructor() {
|
|
@@ -11563,12 +11569,12 @@ const SpinnerSize = {
|
|
|
11563
11569
|
huge: "huge"
|
|
11564
11570
|
};
|
|
11565
11571
|
|
|
11566
|
-
var __defProp$
|
|
11567
|
-
var __getOwnPropDesc$
|
|
11568
|
-
var __decorateClass$
|
|
11569
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
11572
|
+
var __defProp$g = Object.defineProperty;
|
|
11573
|
+
var __getOwnPropDesc$g = Object.getOwnPropertyDescriptor;
|
|
11574
|
+
var __decorateClass$g = (decorators, target, key, kind) => {
|
|
11575
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$g(target, key) : target;
|
|
11570
11576
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
11571
|
-
if (kind && result) __defProp$
|
|
11577
|
+
if (kind && result) __defProp$g(target, key, result);
|
|
11572
11578
|
return result;
|
|
11573
11579
|
};
|
|
11574
11580
|
class Spinner extends BaseSpinner {
|
|
@@ -11589,24 +11595,24 @@ class Spinner extends BaseSpinner {
|
|
|
11589
11595
|
swapStates(this.elementInternals, prev, next, SpinnerAppearance);
|
|
11590
11596
|
}
|
|
11591
11597
|
}
|
|
11592
|
-
__decorateClass$
|
|
11593
|
-
__decorateClass$
|
|
11598
|
+
__decorateClass$g([attr], Spinner.prototype, "size", 2);
|
|
11599
|
+
__decorateClass$g([attr], Spinner.prototype, "appearance", 2);
|
|
11594
11600
|
|
|
11595
|
-
const styles$
|
|
11601
|
+
const styles$c = css`
|
|
11596
11602
|
${display("inline-flex")}
|
|
11597
11603
|
|
|
11598
11604
|
:host{--duration:1.5s;--indicatorSize:${strokeWidthThicker};--size:32px;height:var(--size);width:var(--size);contain:strict;content-visibility:auto}:host(${tinyState}){--indicatorSize:${strokeWidthThick};--size:20px}:host(${extraSmallState}){--indicatorSize:${strokeWidthThick};--size:24px}:host(${smallState}){--indicatorSize:${strokeWidthThick};--size:28px}:host(${largeState}){--indicatorSize:${strokeWidthThicker};--size:36px}:host(${extraLargeState}){--indicatorSize:${strokeWidthThicker};--size:40px}:host(${hugeState}){--indicatorSize:${strokeWidthThickest};--size:44px}.progress,.background,.spinner,.start,.end,.indicator{position:absolute;inset:0}.progress,.spinner,.indicator{animation:none var(--duration) infinite ${curveEasyEase}}.progress{animation-timing-function:linear;animation-name:spin-linear}.background{border:var(--indicatorSize) solid ${colorBrandStroke2};border-radius:50%}:host(${invertedState}) .background{border-color:rgba(255,255,255,0.2)}.spinner{animation-name:spin-swing}.start{overflow:hidden;right:50%}.end{overflow:hidden;left:50%}.indicator{color:${colorBrandStroke1};box-sizing:border-box;border-radius:50%;border:var(--indicatorSize) solid transparent;border-block-start-color:currentcolor;border-right-color:currentcolor}:host(${invertedState}) .indicator{color:${colorNeutralStrokeOnBrand2}}.start .indicator{rotate:135deg;inset:0 -100% 0 0;animation-name:spin-start}.end .indicator{rotate:135deg;inset:0 0 0 -100%;animation-name:spin-end}@keyframes spin-linear{100%{transform:rotate(360deg)}}@keyframes spin-swing{0%{transform:rotate(-135deg)}50%{transform:rotate(0deg)}100%{transform:rotate(225deg)}}@keyframes spin-start{0%,100%{transform:rotate(0deg)}50%{transform:rotate(-80deg)}}@keyframes spin-end{0%,100%{transform:rotate(0deg)}50%{transform:rotate(70deg)}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
11599
11605
|
.background{display:none}.indicator{border-color:Canvas;border-block-start-color:Highlight;border-right-color:Highlight}`));
|
|
11600
11606
|
|
|
11601
|
-
const template$
|
|
11607
|
+
const template$c = html`<slot name="indicator"><div class="background"></div><div class="progress"><div class="spinner"><div class="start"><div class="indicator"></div></div><div class="end"><div class="indicator"></div></div></div></div></slot>`;
|
|
11602
11608
|
|
|
11603
|
-
const definition$
|
|
11609
|
+
const definition$c = Spinner.compose({
|
|
11604
11610
|
name: `${FluentDesignSystem.prefix}-spinner`,
|
|
11605
|
-
template: template$
|
|
11606
|
-
styles: styles$
|
|
11611
|
+
template: template$c,
|
|
11612
|
+
styles: styles$c
|
|
11607
11613
|
});
|
|
11608
11614
|
|
|
11609
|
-
definition$
|
|
11615
|
+
definition$c.define(FluentDesignSystem.registry);
|
|
11610
11616
|
|
|
11611
11617
|
class Switch extends BaseCheckbox {
|
|
11612
11618
|
constructor() {
|
|
@@ -11618,50 +11624,50 @@ class Switch extends BaseCheckbox {
|
|
|
11618
11624
|
function switchTemplate(options = {}) {
|
|
11619
11625
|
return html`<template tabindex="${x => !x.disabled ? 0 : void 0}" @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>`;
|
|
11620
11626
|
}
|
|
11621
|
-
const template$
|
|
11627
|
+
const template$b = switchTemplate({
|
|
11622
11628
|
switch: `<span class="checked-indicator" part="checked-indicator"></span>`
|
|
11623
11629
|
});
|
|
11624
11630
|
|
|
11625
|
-
const styles$
|
|
11631
|
+
const styles$b = css`
|
|
11626
11632
|
${display("inline-flex")}
|
|
11627
11633
|
|
|
11628
11634
|
: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};cursor:pointer}:host(:hover){background:none;border-color:${colorNeutralStrokeAccessibleHover}}:host(:active){border-color:${colorNeutralStrokeAccessiblePressed}}:host(:disabled),: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}:disabled){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(:disabled) .checked-indicator,:host([readonly]) .checked-indicator{background:${colorNeutralForegroundDisabled}}:host(${checkedState}:disabled) .checked-indicator{background:${colorNeutralForegroundDisabled}}:host(:focus-visible){outline:none}:host(:not([slot='input']):focus-visible){border-color:${colorTransparentStroke};outline:${strokeWidthThick} solid ${colorTransparentStroke};box-shadow:${shadow4},0 0 0 2px ${colorStrokeFocus2}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
11629
11635
|
: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:ActiveCaption}:host(${checkedState}) .checked-indicator,:host(${checkedState}:hover) .checked-indicator,:host(${checkedState}:active) .checked-indicator{background-color:ButtonFace}:host(:disabled) .checked-indicator,:host(${checkedState}:disabled) .checked-indicator{background-color:GrayText}`));
|
|
11630
11636
|
|
|
11631
|
-
const definition$
|
|
11637
|
+
const definition$b = Switch.compose({
|
|
11632
11638
|
name: `${FluentDesignSystem.prefix}-switch`,
|
|
11633
|
-
template: template$
|
|
11634
|
-
styles: styles$
|
|
11639
|
+
template: template$b,
|
|
11640
|
+
styles: styles$b
|
|
11635
11641
|
});
|
|
11636
11642
|
|
|
11637
|
-
definition$
|
|
11643
|
+
definition$b.define(FluentDesignSystem.registry);
|
|
11638
11644
|
|
|
11639
11645
|
class TabPanel extends FASTElement {}
|
|
11640
11646
|
|
|
11641
11647
|
function tabPanelTemplate() {
|
|
11642
11648
|
return html`<template slot="tabpanel" role="tabpanel"><slot></slot></template>`;
|
|
11643
11649
|
}
|
|
11644
|
-
const template$
|
|
11650
|
+
const template$a = tabPanelTemplate();
|
|
11645
11651
|
|
|
11646
|
-
const styles$
|
|
11652
|
+
const styles$a = css`
|
|
11647
11653
|
${display("block")}
|
|
11648
11654
|
|
|
11649
11655
|
:host{box-sizing:border-box;padding:${spacingHorizontalM} ${spacingHorizontalMNudge}}`;
|
|
11650
11656
|
|
|
11651
|
-
const definition$
|
|
11657
|
+
const definition$a = TabPanel.compose({
|
|
11652
11658
|
name: `${FluentDesignSystem.prefix}-tab-panel`,
|
|
11653
|
-
template: template$
|
|
11654
|
-
styles: styles$
|
|
11659
|
+
template: template$a,
|
|
11660
|
+
styles: styles$a
|
|
11655
11661
|
});
|
|
11656
11662
|
|
|
11657
|
-
definition$
|
|
11663
|
+
definition$a.define(FluentDesignSystem.registry);
|
|
11658
11664
|
|
|
11659
|
-
var __defProp$
|
|
11660
|
-
var __getOwnPropDesc$
|
|
11661
|
-
var __decorateClass$
|
|
11662
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
11665
|
+
var __defProp$f = Object.defineProperty;
|
|
11666
|
+
var __getOwnPropDesc$f = Object.getOwnPropertyDescriptor;
|
|
11667
|
+
var __decorateClass$f = (decorators, target, key, kind) => {
|
|
11668
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$f(target, key) : target;
|
|
11663
11669
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
11664
|
-
if (kind && result) __defProp$
|
|
11670
|
+
if (kind && result) __defProp$f(target, key, result);
|
|
11665
11671
|
return result;
|
|
11666
11672
|
};
|
|
11667
11673
|
class Tab extends FASTElement {
|
|
@@ -11675,7 +11681,7 @@ class Tab extends FASTElement {
|
|
|
11675
11681
|
this.$fastController.addStyles(this.styles);
|
|
11676
11682
|
}
|
|
11677
11683
|
}
|
|
11678
|
-
__decorateClass$
|
|
11684
|
+
__decorateClass$f([attr({
|
|
11679
11685
|
mode: "boolean"
|
|
11680
11686
|
})], Tab.prototype, "disabled", 2);
|
|
11681
11687
|
applyMixins(Tab, StartEnd);
|
|
@@ -11683,21 +11689,21 @@ applyMixins(Tab, StartEnd);
|
|
|
11683
11689
|
function tabTemplate(options = {}) {
|
|
11684
11690
|
return html`<template slot="tab" role="tab" aria-disabled="${x => x.disabled}">${startSlotTemplate(options)}<span class="tab-content"><slot></slot></span>${endSlotTemplate(options)}</template>`;
|
|
11685
11691
|
}
|
|
11686
|
-
const template$
|
|
11692
|
+
const template$9 = tabTemplate({});
|
|
11687
11693
|
|
|
11688
|
-
const styles$
|
|
11694
|
+
const styles$9 = css`
|
|
11689
11695
|
${display("inline-flex")}
|
|
11690
11696
|
|
|
11691
11697
|
:host{position:relative;flex-direction:column;cursor:pointer;box-sizing:border-box;justify-content:center;line-height:${lineHeightBase300};font-family:${fontFamilyBase};font-size:${fontSizeBase300};color:${colorNeutralForeground2};fill:currentcolor;grid-row:1;padding:${spacingHorizontalM} ${spacingHorizontalMNudge};border-radius:${borderRadiusMedium}}:host .tab-content{display:inline-flex;flex-direction:column;padding:0 2px}:host([aria-selected='true']){color:${colorNeutralForeground1};font-weight:${fontWeightSemibold}}:host .tab-content::after{content:var(--textContent);visibility:hidden;height:0;line-height:${lineHeightBase300};font-weight:${fontWeightSemibold}}:host([aria-selected='true'])::after{background-color:${colorCompoundBrandStroke};border-radius:${borderRadiusCircular};content:'';inset:0;position:absolute;z-index:2}:host([aria-selected='false']:hover)::after{background-color:${colorNeutralStroke1Hover};border-radius:${borderRadiusCircular};content:'';inset:0;position:absolute;z-index:1}:host([aria-selected='true'][disabled])::after{background-color:${colorNeutralForegroundDisabled}}::slotted([slot='start']),::slotted([slot='end']){display:flex}::slotted([slot='start']){margin-inline-end:11px}::slotted([slot='end']){margin-inline-start:11px}:host([disabled]){cursor:not-allowed;fill:${colorNeutralForegroundDisabled};color:${colorNeutralForegroundDisabled}}:host([disabled]:hover)::after{background-color:unset}:host(:focus){outline:none}:host(:focus-visible){border-radius:${borderRadiusSmall};box-shadow:0 0 0 3px ${colorStrokeFocus2};outline:1px solid ${colorStrokeFocus1}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
11692
11698
|
:host([aria-selected='true'])::after{background-color:Highlight}`));
|
|
11693
11699
|
|
|
11694
|
-
const definition$
|
|
11700
|
+
const definition$9 = Tab.compose({
|
|
11695
11701
|
name: `${FluentDesignSystem.prefix}-tab`,
|
|
11696
|
-
template: template$
|
|
11697
|
-
styles: styles$
|
|
11702
|
+
template: template$9,
|
|
11703
|
+
styles: styles$9
|
|
11698
11704
|
});
|
|
11699
11705
|
|
|
11700
|
-
definition$
|
|
11706
|
+
definition$9.define(FluentDesignSystem.registry);
|
|
11701
11707
|
|
|
11702
11708
|
const TabsAppearance = {
|
|
11703
11709
|
subtle: "subtle",
|
|
@@ -11705,12 +11711,12 @@ const TabsAppearance = {
|
|
|
11705
11711
|
};
|
|
11706
11712
|
const TabsOrientation = Orientation;
|
|
11707
11713
|
|
|
11708
|
-
var __defProp$
|
|
11709
|
-
var __getOwnPropDesc$
|
|
11710
|
-
var __decorateClass$
|
|
11711
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
11714
|
+
var __defProp$e = Object.defineProperty;
|
|
11715
|
+
var __getOwnPropDesc$e = Object.getOwnPropertyDescriptor;
|
|
11716
|
+
var __decorateClass$e = (decorators, target, key, kind) => {
|
|
11717
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$e(target, key) : target;
|
|
11712
11718
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
11713
|
-
if (kind && result) __defProp$
|
|
11719
|
+
if (kind && result) __defProp$e(target, key, result);
|
|
11714
11720
|
return result;
|
|
11715
11721
|
};
|
|
11716
11722
|
class BaseTabs extends FASTElement {
|
|
@@ -11954,17 +11960,17 @@ class BaseTabs extends FASTElement {
|
|
|
11954
11960
|
this.activeTabIndex = this.getActiveIndex();
|
|
11955
11961
|
}
|
|
11956
11962
|
}
|
|
11957
|
-
__decorateClass$
|
|
11958
|
-
__decorateClass$
|
|
11959
|
-
__decorateClass$
|
|
11960
|
-
__decorateClass$
|
|
11963
|
+
__decorateClass$e([attr], BaseTabs.prototype, "orientation", 2);
|
|
11964
|
+
__decorateClass$e([attr], BaseTabs.prototype, "activeid", 2);
|
|
11965
|
+
__decorateClass$e([observable], BaseTabs.prototype, "tabs", 2);
|
|
11966
|
+
__decorateClass$e([observable], BaseTabs.prototype, "tabpanels", 2);
|
|
11961
11967
|
|
|
11962
|
-
var __defProp$
|
|
11963
|
-
var __getOwnPropDesc$
|
|
11964
|
-
var __decorateClass$
|
|
11965
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
11968
|
+
var __defProp$d = Object.defineProperty;
|
|
11969
|
+
var __getOwnPropDesc$d = Object.getOwnPropertyDescriptor;
|
|
11970
|
+
var __decorateClass$d = (decorators, target, key, kind) => {
|
|
11971
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$d(target, key) : target;
|
|
11966
11972
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
11967
|
-
if (kind && result) __defProp$
|
|
11973
|
+
if (kind && result) __defProp$d(target, key, result);
|
|
11968
11974
|
return result;
|
|
11969
11975
|
};
|
|
11970
11976
|
class Tabs extends BaseTabs {
|
|
@@ -12098,30 +12104,30 @@ class Tabs extends BaseTabs {
|
|
|
12098
12104
|
this.setTabData();
|
|
12099
12105
|
}
|
|
12100
12106
|
}
|
|
12101
|
-
__decorateClass$
|
|
12102
|
-
__decorateClass$
|
|
12107
|
+
__decorateClass$d([attr], Tabs.prototype, "appearance", 2);
|
|
12108
|
+
__decorateClass$d([attr({
|
|
12103
12109
|
mode: "boolean"
|
|
12104
12110
|
})], Tabs.prototype, "disabled", 2);
|
|
12105
|
-
__decorateClass$
|
|
12111
|
+
__decorateClass$d([attr], Tabs.prototype, "size", 2);
|
|
12106
12112
|
applyMixins(Tabs, StartEnd);
|
|
12107
12113
|
|
|
12108
12114
|
function tabsTemplate(options = {}) {
|
|
12109
12115
|
return html` ${startSlotTemplate(options)}<div class="tablist" part="tablist" role="tablist"><slot name="tab" ${slotted("tabs")}></slot></div>${endSlotTemplate(options)}<div class="tabpanel" part="tabpanel"><slot name="tabpanel" ${slotted("tabpanels")}></slot></div>`;
|
|
12110
12116
|
}
|
|
12111
|
-
const template$
|
|
12117
|
+
const template$8 = tabsTemplate({});
|
|
12112
12118
|
|
|
12113
|
-
const styles$
|
|
12119
|
+
const styles$8 = css`
|
|
12114
12120
|
${display("grid")}
|
|
12115
12121
|
|
|
12116
12122
|
:host{box-sizing:border-box;font-family:${fontFamilyBase};font-size:${fontSizeBase300};line-height:${lineHeightBase300};color:${colorNeutralForeground2};grid-template-columns:auto 1fr auto;grid-template-rows:auto 1fr}:host([disabled]){cursor:not-allowed;color:${colorNeutralForegroundDisabled}}:host([disabled]) ::slotted(fluent-tab){pointer-events:none;cursor:not-allowed;color:${colorNeutralForegroundDisabled}}:host([disabled]) ::slotted(fluent-tab:after){background-color:${colorNeutralForegroundDisabled}}:host([disabled]) ::slotted(fluent-tab[aria-selected='true'])::after{background-color:${colorNeutralForegroundDisabled}}:host([disabled]) ::slotted(fluent-tab:hover):before{content:unset}:host ::slotted(fluent-tab){border-radius:${borderRadiusMedium}}:host ::slotted(fluent-tab[aria-selected='true'])::before{background-color:${colorNeutralForegroundDisabled}}.tablist{display:grid;grid-template-rows:auto auto;grid-template-columns:auto;position:relative;width:max-content;align-self:end;box-sizing:border-box}::slotted([slot='start']),::slotted([slot='end']){display:flex;align-self:center}::slotted([slot='start']){margin-inline-end:11px}::slotted([slot='end']){margin-inline-start:11px}.tabpanel{grid-row:2;grid-column-start:1;grid-column-end:4;position:relative}:host([orientation='vertical']){grid-template-rows:auto 1fr auto;grid-template-columns:auto 1fr}:host([orientation='vertical']) .tablist{grid-row-start:2;grid-row-end:2;display:grid;grid-template-rows:auto;grid-template-columns:auto 1fr;position:relative;width:max-content;justify-self:end;align-self:flex-start;width:100%}:host([orientation='vertical']) .tabpanel{grid-column:2;grid-row-start:1;grid-row-end:4}:host([orientation='vertical']) ::slotted([slot='end']){grid-row:3}:host([appearance='subtle']) ::slotted(fluent-tab:hover){background-color:${colorSubtleBackgroundHover};color:${colorNeutralForeground1Hover};fill:${colorCompoundBrandForeground1Hover}}:host([appearance='subtle']) ::slotted(fluent-tab:active){background-color:${colorSubtleBackgroundPressed};fill:${colorSubtleBackgroundPressed};color:${colorNeutralForeground1}}:host([size='small']) ::slotted(fluent-tab){font-size:${fontSizeBase300};line-height:${lineHeightBase300};padding:${spacingVerticalSNudge} ${spacingHorizontalSNudge}}:host([size='large']) ::slotted(fluent-tab){font-size:${fontSizeBase400};line-height:${lineHeightBase400};padding:${spacingVerticalL} ${spacingHorizontalMNudge}}:host ::slotted(fluent-tab[data-animate='true'])::after{transition-property:transform;transition-duration:${durationSlow};transition-timing-function:${curveDecelerateMax}}:host ::slotted(fluent-tab)::after{height:${strokeWidthThicker};margin-top:auto;transform-origin:left;transform:translateX(var(--tabIndicatorOffset)) scaleX(var(--tabIndicatorScale))}:host([orientation='vertical']) ::slotted(fluent-tab)::after{width:${strokeWidthThicker};height:unset;margin-top:unset;transform-origin:top;transform:translateY(var(--tabIndicatorOffset)) scaleY(var(--tabIndicatorScale))}:host ::slotted(fluent-tab)::before{height:${strokeWidthThicker};border-radius:${borderRadiusCircular};content:'';inset:0;position:absolute;margin-top:auto}:host([orientation='vertical']) ::slotted(fluent-tab)::before{height:unset;width:${strokeWidthThicker};margin-inline-end:auto;transform-origin:top}:host ::slotted(fluent-tab[aria-selected='false']:hover)::after{height:${strokeWidthThicker};margin-top:auto;transform-origin:left}:host([orientation='vertical']) ::slotted(fluent-tab[aria-selected='false']:hover)::after{height:unset;margin-inline-end:auto;transform-origin:top;width:${strokeWidthThicker}}:host([orientation='vertical']) ::slotted(fluent-tab){align-items:flex-start;grid-column:2;padding-top:${spacingVerticalSNudge};padding-bottom:${spacingVerticalSNudge}}:host([orientation='vertical'][size='small']) ::slotted(fluent-tab){padding-top:${spacingVerticalXXS};padding-bottom:${spacingVerticalXXS}}:host([orientation='vertical'][size='large']) ::slotted(fluent-tab){padding-top:${spacingVerticalS};padding-bottom:${spacingVerticalS}}:host([size='small']) ::slotted(fluent-tab)::after,:host([size='small']) ::slotted(fluent-tab)::before,:host([size='small']) ::slotted(fluent-tab:hover)::after{right:${spacingHorizontalSNudge};left:${spacingHorizontalSNudge}}:host ::slotted(fluent-tab)::after,:host ::slotted(fluent-tab)::before,:host ::slotted(fluent-tab:hover)::after{right:${spacingHorizontalMNudge};left:${spacingHorizontalMNudge}}:host([size='large']) ::slotted(fluent-tab)::after,:host([size='large']) ::slotted(fluent-tab)::before,:host([size='large']) ::slotted(fluent-tab:hover)::after{right:${spacingHorizontalMNudge};left:${spacingHorizontalMNudge}}:host([orientation='vertical'][size='small']) ::slotted(fluent-tab)::after,:host([orientation='vertical'][size='small']) ::slotted(fluent-tab)::before,:host([orientation='vertical'][size='small']) ::slotted(fluent-tab:hover)::after{right:0;left:0;top:${spacingVerticalSNudge};bottom:${spacingVerticalSNudge}}:host([orientation='vertical']) ::slotted(fluent-tab)::after,:host([orientation='vertical']) ::slotted(fluent-tab)::before,:host([orientation='vertical']) ::slotted(fluent-tab:hover)::after{right:0;left:0;top:${spacingVerticalS};bottom:${spacingVerticalS}}:host([orientation='vertical'][size='large']) ::slotted(fluent-tab)::after,:host([orientation='vertical'][size='large']) ::slotted(fluent-tab)::before,:host([orientation='vertical'][size='large']) ::slotted(fluent-tab:hover)::after{right:0;left:0;top:${spacingVerticalMNudge};bottom:${spacingVerticalMNudge}}`;
|
|
12117
12123
|
|
|
12118
|
-
const definition$
|
|
12124
|
+
const definition$8 = Tabs.compose({
|
|
12119
12125
|
name: `${FluentDesignSystem.prefix}-tabs`,
|
|
12120
|
-
template: template$
|
|
12121
|
-
styles: styles$
|
|
12126
|
+
template: template$8,
|
|
12127
|
+
styles: styles$8
|
|
12122
12128
|
});
|
|
12123
12129
|
|
|
12124
|
-
definition$
|
|
12130
|
+
definition$8.define(FluentDesignSystem.registry);
|
|
12125
12131
|
|
|
12126
12132
|
const isARIADisabledElement = el => {
|
|
12127
12133
|
return el.getAttribute("aria-disabled") === "true";
|
|
@@ -12144,12 +12150,12 @@ const TablistSize = {
|
|
|
12144
12150
|
};
|
|
12145
12151
|
const TablistOrientation = Orientation;
|
|
12146
12152
|
|
|
12147
|
-
var __defProp$
|
|
12148
|
-
var __getOwnPropDesc$
|
|
12149
|
-
var __decorateClass$
|
|
12150
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
12153
|
+
var __defProp$c = Object.defineProperty;
|
|
12154
|
+
var __getOwnPropDesc$c = Object.getOwnPropertyDescriptor;
|
|
12155
|
+
var __decorateClass$c = (decorators, target, key, kind) => {
|
|
12156
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$c(target, key) : target;
|
|
12151
12157
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
12152
|
-
if (kind && result) __defProp$
|
|
12158
|
+
if (kind && result) __defProp$c(target, key, result);
|
|
12153
12159
|
return result;
|
|
12154
12160
|
};
|
|
12155
12161
|
class BaseTablist extends FASTElement {
|
|
@@ -12362,19 +12368,19 @@ class BaseTablist extends FASTElement {
|
|
|
12362
12368
|
this.activeTabIndex = this.getActiveIndex();
|
|
12363
12369
|
}
|
|
12364
12370
|
}
|
|
12365
|
-
__decorateClass$
|
|
12371
|
+
__decorateClass$c([attr({
|
|
12366
12372
|
mode: "boolean"
|
|
12367
12373
|
})], BaseTablist.prototype, "disabled", 2);
|
|
12368
|
-
__decorateClass$
|
|
12369
|
-
__decorateClass$
|
|
12370
|
-
__decorateClass$
|
|
12374
|
+
__decorateClass$c([attr], BaseTablist.prototype, "orientation", 2);
|
|
12375
|
+
__decorateClass$c([attr], BaseTablist.prototype, "activeid", 2);
|
|
12376
|
+
__decorateClass$c([observable], BaseTablist.prototype, "tabs", 2);
|
|
12371
12377
|
|
|
12372
|
-
var __defProp$
|
|
12373
|
-
var __getOwnPropDesc$
|
|
12374
|
-
var __decorateClass$
|
|
12375
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
12378
|
+
var __defProp$b = Object.defineProperty;
|
|
12379
|
+
var __getOwnPropDesc$b = Object.getOwnPropertyDescriptor;
|
|
12380
|
+
var __decorateClass$b = (decorators, target, key, kind) => {
|
|
12381
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$b(target, key) : target;
|
|
12376
12382
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
12377
|
-
if (kind && result) __defProp$
|
|
12383
|
+
if (kind && result) __defProp$b(target, key, result);
|
|
12378
12384
|
return result;
|
|
12379
12385
|
};
|
|
12380
12386
|
class Tablist extends BaseTablist {
|
|
@@ -12528,23 +12534,23 @@ class Tablist extends BaseTablist {
|
|
|
12528
12534
|
}
|
|
12529
12535
|
}
|
|
12530
12536
|
}
|
|
12531
|
-
__decorateClass$
|
|
12532
|
-
__decorateClass$
|
|
12537
|
+
__decorateClass$b([attr], Tablist.prototype, "appearance", 2);
|
|
12538
|
+
__decorateClass$b([attr], Tablist.prototype, "size", 2);
|
|
12533
12539
|
|
|
12534
|
-
const template$
|
|
12540
|
+
const template$7 = html`<template role="tablist"><slot name="tab" ${slotted("tabs")}></slot></template>`;
|
|
12535
12541
|
|
|
12536
|
-
const styles$
|
|
12542
|
+
const styles$7 = css`
|
|
12537
12543
|
${display("flex")}
|
|
12538
12544
|
|
|
12539
12545
|
:host{--tabPaddingInline:inherit;--tabPaddingBlock:inherit;--tabIndicatorInsetInline:0;--tabIndicatorInsetBlock:0;box-sizing:border-box;color:${colorNeutralForeground2};flex-direction:row}:host(${verticalState}){flex-direction:column}:host ::slotted([role='tab']){align-items:flex-start}:host ::slotted([slot='tab'][data-animate='true'])::after{transition-property:transform;transition-duration:${durationSlow};transition-timing-function:${curveDecelerateMax}}:host ::slotted([slot='tab'])::after{height:${strokeWidthThicker};margin-block-start:auto;transform-origin:left;transform:translateX(var(--tabIndicatorOffset)) scaleX(var(--tabIndicatorScale))}:host(${verticalState}) ::slotted([slot='tab'])::after{width:${strokeWidthThicker};height:unset;margin-block-start:unset;transform-origin:top;transform:translateY(var(--tabIndicatorOffset)) scaleY(var(--tabIndicatorScale))}:host ::slotted([slot='tab'])::before{height:${strokeWidthThicker};border-radius:${borderRadiusCircular};content:'';inset-inline:var(--tabIndicatorInsetInline);inset-block:var(--tabIndicatorInsetBlock);position:absolute;margin-top:auto}:host ::slotted([slot='tab'])::before{inset-inline:var(--tabIndicatorInsetInline);inset-block:var(--tabIndicatorInsetBlock)}:host ::slotted([slot='tab'][aria-selected='true'])::before{background-color:${colorNeutralForegroundDisabled}}:host ::slotted([slot='tab'][aria-selected='false']:hover)::after{height:${strokeWidthThicker};margin-block-start:auto;transform-origin:left}:host(${verticalState}) ::slotted([slot='tab'])::before,:host(${verticalState}) ::slotted([slot='tab'][aria-selected='false']:hover)::after{height:unset;width:${strokeWidthThicker};margin-inline-end:auto;transform-origin:top}:host(:where(${smallState},${largeState})) ::slotted([slot='tab']){padding-inline:var(--tabPaddingInline);padding-block:var(--tabPaddingBlock)}:host(${smallState}) ::slotted([slot='tab']){--tabPaddingBlock:${spacingVerticalSNudge};--tabPaddingInline:${spacingHorizontalSNudge};font-size:${fontSizeBase300};line-height:${lineHeightBase300}}:host(${largeState}) ::slotted([slot='tab']){--tabPaddingBlock:${spacingVerticalL};--tabPaddingInline:${spacingHorizontalMNudge};font-size:${fontSizeBase400};line-height:${lineHeightBase400}}:host ::slotted([slot='tab'])::after,:host ::slotted([slot='tab'])::before,:host ::slotted([slot='tab']:hover)::after{inset-inline:var(--tabIndicatorInsetInline)}:host ::slotted([slot='tab']){--tabIndicatorInsetInline:${spacingHorizontalMNudge}}:host(${smallState}) ::slotted([slot='tab']){--tabIndicatorInsetInline:${spacingHorizontalSNudge}}:host(${largeState}) ::slotted([slot='tab']){--tabIndicatorInsetInline:${spacingHorizontalMNudge}}:host(${verticalState}) ::slotted([slot='tab']){padding-block:var(--tabPaddingBlock)}:host(${verticalState}) ::slotted([slot='tab']){--tabPaddingBlock:${spacingVerticalS}}:host(${verticalState}${smallState}) ::slotted([slot='tab']){--tabPaddingBlock:${spacingVerticalXXS}}:host(${verticalState}${largeState}) ::slotted([slot='tab']){--tabPaddingBlock:${spacingVerticalS}}:host(${verticalState}) ::slotted([slot='tab'])::after,:host(${verticalState}) ::slotted([slot='tab'])::before,:host(${verticalState}) ::slotted([slot='tab']:hover)::after{inset-inline:0;inset-block:var(--tabIndicatorInsetBlock)}:host(${verticalState}){--tabIndicatorInsetBlock:${spacingVerticalS}}:host(${verticalState}${smallState}){--tabIndicatorInsetBlock:${spacingVerticalSNudge}}:host(${verticalState}${largeState}){--tabIndicatorInsetBlock:${spacingVerticalMNudge}}:host(${disabledState}){cursor:not-allowed;color:${colorNeutralForegroundDisabled}}:host(${disabledState}) ::slotted([slot='tab']){pointer-events:none;cursor:not-allowed;color:${colorNeutralForegroundDisabled}}:host(${disabledState}) ::slotted([slot='tab']:after){background-color:${colorNeutralForegroundDisabled}}:host(${disabledState}) ::slotted([slot='tab'][aria-selected='true'])::after{background-color:${colorNeutralForegroundDisabled}}:host(${disabledState}) ::slotted([slot='tab']:hover):before{content:unset}:host(${subtleState}) ::slotted([slot='tab']:hover){background-color:${colorSubtleBackgroundHover};color:${colorNeutralForeground1Hover};fill:${colorCompoundBrandForeground1Hover}}:host(${subtleState}) ::slotted([slot='tab']:active){background-color:${colorSubtleBackgroundPressed};fill:${colorSubtleBackgroundPressed};color:${colorNeutralForeground1}}`;
|
|
12540
12546
|
|
|
12541
|
-
const definition$
|
|
12547
|
+
const definition$7 = Tablist.compose({
|
|
12542
12548
|
name: `${FluentDesignSystem.prefix}-tablist`,
|
|
12543
|
-
template: template$
|
|
12544
|
-
styles: styles$
|
|
12549
|
+
template: template$7,
|
|
12550
|
+
styles: styles$7
|
|
12545
12551
|
});
|
|
12546
12552
|
|
|
12547
|
-
definition$
|
|
12553
|
+
definition$7.define(FluentDesignSystem.registry);
|
|
12548
12554
|
|
|
12549
12555
|
const TextAreaSize = {
|
|
12550
12556
|
small: "small",
|
|
@@ -12564,12 +12570,12 @@ const TextAreaResize = {
|
|
|
12564
12570
|
vertical: "vertical"
|
|
12565
12571
|
};
|
|
12566
12572
|
|
|
12567
|
-
var __defProp$
|
|
12568
|
-
var __getOwnPropDesc$
|
|
12569
|
-
var __decorateClass$
|
|
12570
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
12573
|
+
var __defProp$a = Object.defineProperty;
|
|
12574
|
+
var __getOwnPropDesc$a = Object.getOwnPropertyDescriptor;
|
|
12575
|
+
var __decorateClass$a = (decorators, target, key, kind) => {
|
|
12576
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$a(target, key) : target;
|
|
12571
12577
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
12572
|
-
if (kind && result) __defProp$
|
|
12578
|
+
if (kind && result) __defProp$a(target, key, result);
|
|
12573
12579
|
return result;
|
|
12574
12580
|
};
|
|
12575
12581
|
class BaseTextArea extends FASTElement {
|
|
@@ -12938,56 +12944,56 @@ class BaseTextArea extends FASTElement {
|
|
|
12938
12944
|
* @public
|
|
12939
12945
|
*/
|
|
12940
12946
|
BaseTextArea.formAssociated = true;
|
|
12941
|
-
__decorateClass$
|
|
12942
|
-
__decorateClass$
|
|
12943
|
-
__decorateClass$
|
|
12944
|
-
__decorateClass$
|
|
12947
|
+
__decorateClass$a([observable], BaseTextArea.prototype, "defaultSlottedNodes", 2);
|
|
12948
|
+
__decorateClass$a([observable], BaseTextArea.prototype, "labelSlottedNodes", 2);
|
|
12949
|
+
__decorateClass$a([attr], BaseTextArea.prototype, "autocomplete", 2);
|
|
12950
|
+
__decorateClass$a([attr({
|
|
12945
12951
|
attribute: "auto-resize",
|
|
12946
12952
|
mode: "boolean"
|
|
12947
12953
|
})], BaseTextArea.prototype, "autoResize", 2);
|
|
12948
|
-
__decorateClass$
|
|
12954
|
+
__decorateClass$a([attr({
|
|
12949
12955
|
attribute: "dirname"
|
|
12950
12956
|
})], BaseTextArea.prototype, "dirName", 2);
|
|
12951
|
-
__decorateClass$
|
|
12957
|
+
__decorateClass$a([attr({
|
|
12952
12958
|
mode: "boolean"
|
|
12953
12959
|
})], BaseTextArea.prototype, "disabled", 2);
|
|
12954
|
-
__decorateClass$
|
|
12960
|
+
__decorateClass$a([attr({
|
|
12955
12961
|
attribute: "display-shadow",
|
|
12956
12962
|
mode: "boolean"
|
|
12957
12963
|
})], BaseTextArea.prototype, "displayShadow", 2);
|
|
12958
|
-
__decorateClass$
|
|
12964
|
+
__decorateClass$a([attr({
|
|
12959
12965
|
attribute: "form"
|
|
12960
12966
|
})], BaseTextArea.prototype, "initialForm", 2);
|
|
12961
|
-
__decorateClass$
|
|
12967
|
+
__decorateClass$a([attr({
|
|
12962
12968
|
attribute: "maxlength",
|
|
12963
12969
|
converter: nullableNumberConverter
|
|
12964
12970
|
})], BaseTextArea.prototype, "maxLength", 2);
|
|
12965
|
-
__decorateClass$
|
|
12971
|
+
__decorateClass$a([attr({
|
|
12966
12972
|
attribute: "minlength",
|
|
12967
12973
|
converter: nullableNumberConverter
|
|
12968
12974
|
})], BaseTextArea.prototype, "minLength", 2);
|
|
12969
|
-
__decorateClass$
|
|
12970
|
-
__decorateClass$
|
|
12971
|
-
__decorateClass$
|
|
12975
|
+
__decorateClass$a([attr], BaseTextArea.prototype, "name", 2);
|
|
12976
|
+
__decorateClass$a([attr], BaseTextArea.prototype, "placeholder", 2);
|
|
12977
|
+
__decorateClass$a([attr({
|
|
12972
12978
|
attribute: "readonly",
|
|
12973
12979
|
mode: "boolean"
|
|
12974
12980
|
})], BaseTextArea.prototype, "readOnly", 2);
|
|
12975
|
-
__decorateClass$
|
|
12981
|
+
__decorateClass$a([attr({
|
|
12976
12982
|
mode: "boolean"
|
|
12977
12983
|
})], BaseTextArea.prototype, "required", 2);
|
|
12978
|
-
__decorateClass$
|
|
12984
|
+
__decorateClass$a([attr({
|
|
12979
12985
|
mode: "fromView"
|
|
12980
12986
|
})], BaseTextArea.prototype, "resize", 2);
|
|
12981
|
-
__decorateClass$
|
|
12987
|
+
__decorateClass$a([attr({
|
|
12982
12988
|
mode: "boolean"
|
|
12983
12989
|
})], BaseTextArea.prototype, "spellcheck", 2);
|
|
12984
12990
|
|
|
12985
|
-
var __defProp$
|
|
12986
|
-
var __getOwnPropDesc$
|
|
12987
|
-
var __decorateClass$
|
|
12988
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
12991
|
+
var __defProp$9 = Object.defineProperty;
|
|
12992
|
+
var __getOwnPropDesc$9 = Object.getOwnPropertyDescriptor;
|
|
12993
|
+
var __decorateClass$9 = (decorators, target, key, kind) => {
|
|
12994
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$9(target, key) : target;
|
|
12989
12995
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
12990
|
-
if (kind && result) __defProp$
|
|
12996
|
+
if (kind && result) __defProp$9(target, key, result);
|
|
12991
12997
|
return result;
|
|
12992
12998
|
};
|
|
12993
12999
|
class TextArea extends BaseTextArea {
|
|
@@ -13055,15 +13061,15 @@ class TextArea extends BaseTextArea {
|
|
|
13055
13061
|
toggleState(this.elementInternals, "display-shadow", this.displayShadow && TextAreaAppearancesForDisplayShadow.includes(this.appearance));
|
|
13056
13062
|
}
|
|
13057
13063
|
}
|
|
13058
|
-
__decorateClass$
|
|
13064
|
+
__decorateClass$9([attr({
|
|
13059
13065
|
mode: "fromView"
|
|
13060
13066
|
})], TextArea.prototype, "appearance", 2);
|
|
13061
|
-
__decorateClass$
|
|
13067
|
+
__decorateClass$9([attr({
|
|
13062
13068
|
mode: "boolean"
|
|
13063
13069
|
})], TextArea.prototype, "block", 2);
|
|
13064
|
-
__decorateClass$
|
|
13070
|
+
__decorateClass$9([attr], TextArea.prototype, "size", 2);
|
|
13065
13071
|
|
|
13066
|
-
const styles$
|
|
13072
|
+
const styles$6 = css`
|
|
13067
13073
|
${display("inline-block")}
|
|
13068
13074
|
|
|
13069
13075
|
: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(${blockState}:not([hidden])){display:block}:host(${smallState}){--font-size:${fontSizeBase200};--line-height:${lineHeightBase200};--min-block-size:40px;--padding-block:${spacingVerticalXS};--padding-inline:${spacingHorizontalSNudge};--control-padding-inline:${spacingHorizontalXXS}}:host(${largeState}){--font-size:${fontSizeBase400};--line-height:${lineHeightBase400};--min-block-size:64px;--padding-block:${spacingVerticalS};--padding-inline:${spacingHorizontalM};--control-padding-inline:${spacingHorizontalSNudge}}:host(${resizeBothState}:not(:disabled)){--resize:both}:host(${resizeHorizontalState}:not(:disabled)){--resize:horizontal}:host(${resizeVerticalState}:not(:disabled)){--resize:vertical}:host(${autoResizeState}){--block-size:auto;--contain-size:inline-size}:host(${filledDarkerState}){--background-color:${colorNeutralBackground3};--border-color:var(--background-color);--border-block-end-color:var(--border-color)}:host(${filledLighterState}){--border-color:var(--background-color);--border-block-end-color:var(--border-color)}:host(${filledDarkerState}${displayShadowState}),:host(${filledLighterState}${displayShadowState}){--box-shadow:${shadow2}}:host(${userInvalidState}){--border-color:${colorPaletteRedBorder2};--border-block-end-color:${colorPaletteRedBorder2}}:host(:disabled){--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(${blockState}) .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(:disabled) .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(${autoResizeState}) .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}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
@@ -13078,18 +13084,18 @@ function textAreaTemplate() {
|
|
|
13078
13084
|
filter: whitespaceFilter
|
|
13079
13085
|
})}></slot></div></template>`;
|
|
13080
13086
|
}
|
|
13081
|
-
const template$
|
|
13087
|
+
const template$6 = textAreaTemplate();
|
|
13082
13088
|
|
|
13083
|
-
const definition$
|
|
13089
|
+
const definition$6 = TextArea.compose({
|
|
13084
13090
|
name: `${FluentDesignSystem.prefix}-textarea`,
|
|
13085
|
-
template: template$
|
|
13086
|
-
styles: styles$
|
|
13091
|
+
template: template$6,
|
|
13092
|
+
styles: styles$6,
|
|
13087
13093
|
shadowOptions: {
|
|
13088
13094
|
delegatesFocus: true
|
|
13089
13095
|
}
|
|
13090
13096
|
});
|
|
13091
13097
|
|
|
13092
|
-
definition$
|
|
13098
|
+
definition$6.define(FluentDesignSystem.registry);
|
|
13093
13099
|
|
|
13094
13100
|
const TextInputControlSize = {
|
|
13095
13101
|
small: "small",
|
|
@@ -13111,12 +13117,12 @@ const TextInputType = {
|
|
|
13111
13117
|
};
|
|
13112
13118
|
const ImplicitSubmissionBlockingTypes = ["date", "datetime-local", "email", "month", "number", "password", "search", "tel", "text", "time", "url", "week"];
|
|
13113
13119
|
|
|
13114
|
-
var __defProp$
|
|
13115
|
-
var __getOwnPropDesc$
|
|
13116
|
-
var __decorateClass$
|
|
13117
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
13120
|
+
var __defProp$8 = Object.defineProperty;
|
|
13121
|
+
var __getOwnPropDesc$8 = Object.getOwnPropertyDescriptor;
|
|
13122
|
+
var __decorateClass$8 = (decorators, target, key, kind) => {
|
|
13123
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$8(target, key) : target;
|
|
13118
13124
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
13119
|
-
if (kind && result) __defProp$
|
|
13125
|
+
if (kind && result) __defProp$8(target, key, result);
|
|
13120
13126
|
return result;
|
|
13121
13127
|
};
|
|
13122
13128
|
class BaseTextInput extends FASTElement {
|
|
@@ -13437,63 +13443,63 @@ class BaseTextInput extends FASTElement {
|
|
|
13437
13443
|
* @public
|
|
13438
13444
|
*/
|
|
13439
13445
|
BaseTextInput.formAssociated = true;
|
|
13440
|
-
__decorateClass$
|
|
13441
|
-
__decorateClass$
|
|
13446
|
+
__decorateClass$8([attr], BaseTextInput.prototype, "autocomplete", 2);
|
|
13447
|
+
__decorateClass$8([attr({
|
|
13442
13448
|
mode: "boolean"
|
|
13443
13449
|
})], BaseTextInput.prototype, "autofocus", 2);
|
|
13444
|
-
__decorateClass$
|
|
13450
|
+
__decorateClass$8([attr({
|
|
13445
13451
|
attribute: "current-value"
|
|
13446
13452
|
})], BaseTextInput.prototype, "currentValue", 2);
|
|
13447
|
-
__decorateClass$
|
|
13448
|
-
__decorateClass$
|
|
13449
|
-
__decorateClass$
|
|
13453
|
+
__decorateClass$8([observable], BaseTextInput.prototype, "defaultSlottedNodes", 2);
|
|
13454
|
+
__decorateClass$8([attr], BaseTextInput.prototype, "dirname", 2);
|
|
13455
|
+
__decorateClass$8([attr({
|
|
13450
13456
|
mode: "boolean"
|
|
13451
13457
|
})], BaseTextInput.prototype, "disabled", 2);
|
|
13452
|
-
__decorateClass$
|
|
13458
|
+
__decorateClass$8([attr({
|
|
13453
13459
|
attribute: "form"
|
|
13454
13460
|
})], BaseTextInput.prototype, "formAttribute", 2);
|
|
13455
|
-
__decorateClass$
|
|
13461
|
+
__decorateClass$8([attr({
|
|
13456
13462
|
attribute: "value",
|
|
13457
13463
|
mode: "fromView"
|
|
13458
13464
|
})], BaseTextInput.prototype, "initialValue", 2);
|
|
13459
|
-
__decorateClass$
|
|
13460
|
-
__decorateClass$
|
|
13465
|
+
__decorateClass$8([attr], BaseTextInput.prototype, "list", 2);
|
|
13466
|
+
__decorateClass$8([attr({
|
|
13461
13467
|
converter: nullableNumberConverter
|
|
13462
13468
|
})], BaseTextInput.prototype, "maxlength", 2);
|
|
13463
|
-
__decorateClass$
|
|
13469
|
+
__decorateClass$8([attr({
|
|
13464
13470
|
converter: nullableNumberConverter
|
|
13465
13471
|
})], BaseTextInput.prototype, "minlength", 2);
|
|
13466
|
-
__decorateClass$
|
|
13472
|
+
__decorateClass$8([attr({
|
|
13467
13473
|
mode: "boolean"
|
|
13468
13474
|
})], BaseTextInput.prototype, "multiple", 2);
|
|
13469
|
-
__decorateClass$
|
|
13470
|
-
__decorateClass$
|
|
13471
|
-
__decorateClass$
|
|
13472
|
-
__decorateClass$
|
|
13475
|
+
__decorateClass$8([attr], BaseTextInput.prototype, "name", 2);
|
|
13476
|
+
__decorateClass$8([attr], BaseTextInput.prototype, "pattern", 2);
|
|
13477
|
+
__decorateClass$8([attr], BaseTextInput.prototype, "placeholder", 2);
|
|
13478
|
+
__decorateClass$8([attr({
|
|
13473
13479
|
attribute: "readonly",
|
|
13474
13480
|
mode: "boolean"
|
|
13475
13481
|
})], BaseTextInput.prototype, "readOnly", 2);
|
|
13476
|
-
__decorateClass$
|
|
13482
|
+
__decorateClass$8([attr({
|
|
13477
13483
|
mode: "boolean"
|
|
13478
13484
|
})], BaseTextInput.prototype, "required", 2);
|
|
13479
|
-
__decorateClass$
|
|
13485
|
+
__decorateClass$8([attr({
|
|
13480
13486
|
converter: nullableNumberConverter
|
|
13481
13487
|
})], BaseTextInput.prototype, "size", 2);
|
|
13482
|
-
__decorateClass$
|
|
13488
|
+
__decorateClass$8([attr({
|
|
13483
13489
|
converter: {
|
|
13484
13490
|
fromView: value => typeof value === "string" ? ["true", ""].includes(value.trim().toLowerCase()) : null,
|
|
13485
13491
|
toView: value => value.toString()
|
|
13486
13492
|
}
|
|
13487
13493
|
})], BaseTextInput.prototype, "spellcheck", 2);
|
|
13488
|
-
__decorateClass$
|
|
13489
|
-
__decorateClass$
|
|
13494
|
+
__decorateClass$8([attr], BaseTextInput.prototype, "type", 2);
|
|
13495
|
+
__decorateClass$8([observable], BaseTextInput.prototype, "controlLabel", 2);
|
|
13490
13496
|
|
|
13491
|
-
var __defProp$
|
|
13492
|
-
var __getOwnPropDesc$
|
|
13493
|
-
var __decorateClass$
|
|
13494
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
13497
|
+
var __defProp$7 = Object.defineProperty;
|
|
13498
|
+
var __getOwnPropDesc$7 = Object.getOwnPropertyDescriptor;
|
|
13499
|
+
var __decorateClass$7 = (decorators, target, key, kind) => {
|
|
13500
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$7(target, key) : target;
|
|
13495
13501
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
13496
|
-
if (kind && result) __defProp$
|
|
13502
|
+
if (kind && result) __defProp$7(target, key, result);
|
|
13497
13503
|
return result;
|
|
13498
13504
|
};
|
|
13499
13505
|
class TextInput extends BaseTextInput {
|
|
@@ -13514,13 +13520,13 @@ class TextInput extends BaseTextInput {
|
|
|
13514
13520
|
swapStates(this.elementInternals, prev, next, TextInputControlSize);
|
|
13515
13521
|
}
|
|
13516
13522
|
}
|
|
13517
|
-
__decorateClass$
|
|
13518
|
-
__decorateClass$
|
|
13523
|
+
__decorateClass$7([attr], TextInput.prototype, "appearance", 2);
|
|
13524
|
+
__decorateClass$7([attr({
|
|
13519
13525
|
attribute: "control-size"
|
|
13520
13526
|
})], TextInput.prototype, "controlSize", 2);
|
|
13521
13527
|
applyMixins(TextInput, StartEnd);
|
|
13522
13528
|
|
|
13523
|
-
const styles$
|
|
13529
|
+
const styles$5 = css`
|
|
13524
13530
|
${display("block")}
|
|
13525
13531
|
|
|
13526
13532
|
: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(${outlineState}: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(${smallState}) .control{font-size:${fontSizeBase200};font-weight:${fontWeightRegular};line-height:${lineHeightBase200}}:host(${smallState}) .root{height:24px;gap:${spacingHorizontalXXS};padding:0 ${spacingHorizontalSNudge}}:host(${smallState}) ::slotted([slot='start']),:host(${smallState}) ::slotted([slot='end']){font-size:${fontSizeBase400}}:host(${largeState}) .control{font-size:${fontSizeBase400};font-weight:${fontWeightRegular};line-height:${lineHeightBase400}}:host(${largeState}) .root{height:40px;gap:${spacingHorizontalS};padding:0 ${spacingHorizontalM}}:host(${largeState}) ::slotted([slot='start']),:host(${largeState}) ::slotted([slot='end']){font-size:${fontSizeBase600}}:host(${underlineState}) .root{background:${colorTransparentBackground};border:0;border-radius:0;border-bottom:${strokeWidthThin} solid ${colorNeutralStrokeAccessible}}:host(${underlineState}:hover) .root{border-bottom-color:${colorNeutralStrokeAccessibleHover}}:host(${underlineState}:active) .root{border-bottom-color:${colorNeutralStrokeAccessiblePressed}}:host(${underlineState}:focus-within) .root{border:0;border-bottom-color:${colorNeutralStrokeAccessiblePressed}}:host(${underlineState}[disabled]) .root{border-bottom-color:${colorNeutralStrokeDisabled}}:host(${filledLighterState}) .root,:host(${filledDarkerState}) .root{border:${strokeWidthThin} solid ${colorTransparentStroke};box-shadow:${shadow2}}:host(${filledLighterState}) .root{background:${colorNeutralBackground1}}:host(${filledDarkerState}) .root{background:${colorNeutralBackground3}}:host(${filledLighterState}:hover) .root,:host(${filledDarkerState}:hover) .root{border-color:${colorTransparentStrokeInteractive}}:host(${filledLighterState}:active) .root,:host(${filledDarkerState}:active) .root{border-color:${colorTransparentStrokeInteractive};background:${colorNeutralBackground3}}`;
|
|
@@ -13531,18 +13537,18 @@ function textInputTemplate(options = {}) {
|
|
|
13531
13537
|
filter: whitespaceFilter
|
|
13532
13538
|
})}></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)}" ?autofocus="${x => x.autofocus}" 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.initialValue}" ${ref("control")} />${endSlotTemplate(options)}</div></template>`;
|
|
13533
13539
|
}
|
|
13534
|
-
const template$
|
|
13540
|
+
const template$5 = textInputTemplate();
|
|
13535
13541
|
|
|
13536
|
-
const definition$
|
|
13542
|
+
const definition$5 = TextInput.compose({
|
|
13537
13543
|
name: `${FluentDesignSystem.prefix}-text-input`,
|
|
13538
|
-
template: template$
|
|
13539
|
-
styles: styles$
|
|
13544
|
+
template: template$5,
|
|
13545
|
+
styles: styles$5,
|
|
13540
13546
|
shadowOptions: {
|
|
13541
13547
|
delegatesFocus: true
|
|
13542
13548
|
}
|
|
13543
13549
|
});
|
|
13544
13550
|
|
|
13545
|
-
definition$
|
|
13551
|
+
definition$5.define(FluentDesignSystem.registry);
|
|
13546
13552
|
|
|
13547
13553
|
const TextSize = {
|
|
13548
13554
|
_100: "100",
|
|
@@ -13574,12 +13580,12 @@ const TextAlign = {
|
|
|
13574
13580
|
justify: "justify"
|
|
13575
13581
|
};
|
|
13576
13582
|
|
|
13577
|
-
var __defProp$
|
|
13578
|
-
var __getOwnPropDesc$
|
|
13579
|
-
var __decorateClass$
|
|
13580
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
13583
|
+
var __defProp$6 = Object.defineProperty;
|
|
13584
|
+
var __getOwnPropDesc$6 = Object.getOwnPropertyDescriptor;
|
|
13585
|
+
var __decorateClass$6 = (decorators, target, key, kind) => {
|
|
13586
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$6(target, key) : target;
|
|
13581
13587
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
13582
|
-
if (kind && result) __defProp$
|
|
13588
|
+
if (kind && result) __defProp$6(target, key, result);
|
|
13583
13589
|
return result;
|
|
13584
13590
|
};
|
|
13585
13591
|
class Text extends FASTElement {
|
|
@@ -13660,50 +13666,50 @@ class Text extends FASTElement {
|
|
|
13660
13666
|
}
|
|
13661
13667
|
}
|
|
13662
13668
|
}
|
|
13663
|
-
__decorateClass$
|
|
13669
|
+
__decorateClass$6([attr({
|
|
13664
13670
|
mode: "boolean"
|
|
13665
13671
|
})], Text.prototype, "nowrap", 2);
|
|
13666
|
-
__decorateClass$
|
|
13672
|
+
__decorateClass$6([attr({
|
|
13667
13673
|
mode: "boolean"
|
|
13668
13674
|
})], Text.prototype, "truncate", 2);
|
|
13669
|
-
__decorateClass$
|
|
13675
|
+
__decorateClass$6([attr({
|
|
13670
13676
|
mode: "boolean"
|
|
13671
13677
|
})], Text.prototype, "italic", 2);
|
|
13672
|
-
__decorateClass$
|
|
13678
|
+
__decorateClass$6([attr({
|
|
13673
13679
|
mode: "boolean"
|
|
13674
13680
|
})], Text.prototype, "underline", 2);
|
|
13675
|
-
__decorateClass$
|
|
13681
|
+
__decorateClass$6([attr({
|
|
13676
13682
|
mode: "boolean"
|
|
13677
13683
|
})], Text.prototype, "strikethrough", 2);
|
|
13678
|
-
__decorateClass$
|
|
13684
|
+
__decorateClass$6([attr({
|
|
13679
13685
|
mode: "boolean"
|
|
13680
13686
|
})], Text.prototype, "block", 2);
|
|
13681
|
-
__decorateClass$
|
|
13682
|
-
__decorateClass$
|
|
13683
|
-
__decorateClass$
|
|
13684
|
-
__decorateClass$
|
|
13687
|
+
__decorateClass$6([attr], Text.prototype, "size", 2);
|
|
13688
|
+
__decorateClass$6([attr], Text.prototype, "font", 2);
|
|
13689
|
+
__decorateClass$6([attr], Text.prototype, "weight", 2);
|
|
13690
|
+
__decorateClass$6([attr], Text.prototype, "align", 2);
|
|
13685
13691
|
|
|
13686
|
-
const styles$
|
|
13692
|
+
const styles$4 = css`
|
|
13687
13693
|
${display("inline")}
|
|
13688
13694
|
|
|
13689
13695
|
:host{contain:content;font-family:${fontFamilyBase};font-size:${fontSizeBase300};line-height:${lineHeightBase300};font-weight:${fontWeightRegular};text-align:start}:host(${nowrapState}),:host(${nowrapState}) ::slotted(*){white-space:nowrap;overflow:hidden}:host(${truncateState}),:host(${truncateState}) ::slotted(*){text-overflow:ellipsis}:host(${blockState}){display:block}:host(${italicState}){font-style:italic}:host(${underlineState}){text-decoration-line:underline}:host(${strikethroughState}){text-decoration-line:line-through}:host(${underlineState}${strikethroughState}){text-decoration-line:line-through underline}:host(${size100State}){font-size:${fontSizeBase100};line-height:${lineHeightBase100}}:host(${size200State}){font-size:${fontSizeBase200};line-height:${lineHeightBase200}}:host(${size400State}){font-size:${fontSizeBase400};line-height:${lineHeightBase400}}:host(${size500State}){font-size:${fontSizeBase500};line-height:${lineHeightBase500}}:host(${size600State}){font-size:${fontSizeBase600};line-height:${lineHeightBase600}}:host(${size700State}){font-size:${fontSizeHero700};line-height:${lineHeightHero700}}:host(${size800State}){font-size:${fontSizeHero800};line-height:${lineHeightHero800}}:host(${size900State}){font-size:${fontSizeHero900};line-height:${lineHeightHero900}}:host(${size1000State}){font-size:${fontSizeHero1000};line-height:${lineHeightHero1000}}:host(${monospaceState}){font-family:${fontFamilyMonospace}}:host(${numericState}){font-family:${fontFamilyNumeric}}:host(${mediumState}){font-weight:${fontWeightMedium}}:host(${semiboldState}){font-weight:${fontWeightSemibold}}:host(${boldState}){font-weight:${fontWeightBold}}:host(${centerState}){text-align:center}:host(${endState}){text-align:end}:host(${justifyState}){text-align:justify}::slotted(*){font:inherit;line-height:inherit;text-decoration-line:inherit;text-align:inherit;text-decoration-line:inherit;margin:0}`;
|
|
13690
13696
|
|
|
13691
|
-
const template$
|
|
13697
|
+
const template$4 = html`<slot></slot>`;
|
|
13692
13698
|
|
|
13693
|
-
const definition$
|
|
13699
|
+
const definition$4 = Text.compose({
|
|
13694
13700
|
name: `${FluentDesignSystem.prefix}-text`,
|
|
13695
|
-
template: template$
|
|
13696
|
-
styles: styles$
|
|
13701
|
+
template: template$4,
|
|
13702
|
+
styles: styles$4
|
|
13697
13703
|
});
|
|
13698
13704
|
|
|
13699
|
-
definition$
|
|
13705
|
+
definition$4.define(FluentDesignSystem.registry);
|
|
13700
13706
|
|
|
13701
|
-
var __defProp$
|
|
13702
|
-
var __getOwnPropDesc$
|
|
13703
|
-
var __decorateClass$
|
|
13704
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
13707
|
+
var __defProp$5 = Object.defineProperty;
|
|
13708
|
+
var __getOwnPropDesc$5 = Object.getOwnPropertyDescriptor;
|
|
13709
|
+
var __decorateClass$5 = (decorators, target, key, kind) => {
|
|
13710
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$5(target, key) : target;
|
|
13705
13711
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
13706
|
-
if (kind && result) __defProp$
|
|
13712
|
+
if (kind && result) __defProp$5(target, key, result);
|
|
13707
13713
|
return result;
|
|
13708
13714
|
};
|
|
13709
13715
|
class ToggleButton extends Button {
|
|
@@ -13750,35 +13756,35 @@ class ToggleButton extends Button {
|
|
|
13750
13756
|
}
|
|
13751
13757
|
}
|
|
13752
13758
|
}
|
|
13753
|
-
__decorateClass$
|
|
13759
|
+
__decorateClass$5([attr({
|
|
13754
13760
|
mode: "boolean"
|
|
13755
13761
|
})], ToggleButton.prototype, "pressed", 2);
|
|
13756
|
-
__decorateClass$
|
|
13762
|
+
__decorateClass$5([attr({
|
|
13757
13763
|
mode: "boolean"
|
|
13758
13764
|
})], ToggleButton.prototype, "mixed", 2);
|
|
13759
13765
|
|
|
13760
|
-
const styles$
|
|
13761
|
-
${styles$
|
|
13766
|
+
const styles$3 = css`
|
|
13767
|
+
${styles$E}
|
|
13762
13768
|
|
|
13763
13769
|
:host(${pressedState}){border-color:${colorNeutralStroke1};background-color:${colorNeutralBackground1Selected};color:${colorNeutralForeground1};border-width:${strokeWidthThin}}:host(${pressedState}:hover){border-color:${colorNeutralStroke1Hover};background-color:${colorNeutralBackground1Hover}}:host(${pressedState}:active){border-color:${colorNeutralStroke1Pressed};background-color:${colorNeutralBackground1Pressed}}:host(${pressedState}${primaryState}){border-color:transparent;background-color:${colorBrandBackgroundSelected};color:${colorNeutralForegroundOnBrand}}:host(${pressedState}${primaryState}:hover){background-color:${colorBrandBackgroundHover}}:host(${pressedState}${primaryState}:active){background-color:${colorBrandBackgroundPressed}}:host(${pressedState}${subtleState}){border-color:transparent;background-color:${colorSubtleBackgroundSelected};color:${colorNeutralForeground2Selected}}:host(${pressedState}${subtleState}:hover){background-color:${colorSubtleBackgroundHover};color:${colorNeutralForeground2Hover}}:host(${pressedState}${subtleState}:active){background-color:${colorSubtleBackgroundPressed};color:${colorNeutralForeground2Pressed}}:host(${pressedState}${outlineState}),:host(${pressedState}${transparentState}){background-color:${colorTransparentBackgroundSelected}}:host(${pressedState}${outlineState}:hover),:host(${pressedState}${transparentState}:hover){background-color:${colorTransparentBackgroundHover}}:host(${pressedState}${outlineState}:active),:host(${pressedState}${transparentState}:active){background-color:${colorTransparentBackgroundPressed}}:host(${pressedState}${transparentState}){border-color:transparent;color:${colorNeutralForeground2BrandSelected}}:host(${pressedState}${transparentState}:hover){color:${colorNeutralForeground2BrandHover}}:host(${pressedState}${transparentState}:active){color:${colorNeutralForeground2BrandPressed}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
13764
13770
|
:host(${pressedState}),:host(${pressedState}${primaryState}),:host(${pressedState}${subtleState}),:host(${pressedState}${outlineState}),:host(${pressedState}${transparentState}){background:SelectedItem;color:SelectedItemText}`));
|
|
13765
13771
|
|
|
13766
|
-
const template$
|
|
13772
|
+
const template$3 = buttonTemplate$1();
|
|
13767
13773
|
|
|
13768
|
-
const definition$
|
|
13774
|
+
const definition$3 = ToggleButton.compose({
|
|
13769
13775
|
name: `${FluentDesignSystem.prefix}-toggle-button`,
|
|
13770
|
-
template: template$
|
|
13771
|
-
styles: styles$
|
|
13776
|
+
template: template$3,
|
|
13777
|
+
styles: styles$3
|
|
13772
13778
|
});
|
|
13773
13779
|
|
|
13774
|
-
definition$
|
|
13780
|
+
definition$3.define(FluentDesignSystem.registry);
|
|
13775
13781
|
|
|
13776
|
-
var __defProp = Object.defineProperty;
|
|
13777
|
-
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
13778
|
-
var __decorateClass = (decorators, target, key, kind) => {
|
|
13779
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc(target, key) : target;
|
|
13782
|
+
var __defProp$4 = Object.defineProperty;
|
|
13783
|
+
var __getOwnPropDesc$4 = Object.getOwnPropertyDescriptor;
|
|
13784
|
+
var __decorateClass$4 = (decorators, target, key, kind) => {
|
|
13785
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$4(target, key) : target;
|
|
13780
13786
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
13781
|
-
if (kind && result) __defProp(target, key, result);
|
|
13787
|
+
if (kind && result) __defProp$4(target, key, result);
|
|
13782
13788
|
return result;
|
|
13783
13789
|
};
|
|
13784
13790
|
class Tooltip extends FASTElement {
|
|
@@ -13944,12 +13950,12 @@ class Tooltip extends FASTElement {
|
|
|
13944
13950
|
}
|
|
13945
13951
|
}
|
|
13946
13952
|
}
|
|
13947
|
-
__decorateClass([attr], Tooltip.prototype, "id", 2);
|
|
13948
|
-
__decorateClass([attr({
|
|
13953
|
+
__decorateClass$4([attr], Tooltip.prototype, "id", 2);
|
|
13954
|
+
__decorateClass$4([attr({
|
|
13949
13955
|
converter: nullableNumberConverter
|
|
13950
13956
|
})], Tooltip.prototype, "delay", 2);
|
|
13951
|
-
__decorateClass([attr], Tooltip.prototype, "positioning", 2);
|
|
13952
|
-
__decorateClass([attr], Tooltip.prototype, "anchor", 2);
|
|
13957
|
+
__decorateClass$4([attr], Tooltip.prototype, "positioning", 2);
|
|
13958
|
+
__decorateClass$4([attr], Tooltip.prototype, "anchor", 2);
|
|
13953
13959
|
|
|
13954
13960
|
const TooltipPositioningOption = {
|
|
13955
13961
|
"above-start": "block-start span-inline-end",
|
|
@@ -13966,17 +13972,538 @@ const TooltipPositioningOption = {
|
|
|
13966
13972
|
"after-bottom": "inline-end span-block-start"
|
|
13967
13973
|
};
|
|
13968
13974
|
|
|
13969
|
-
const styles = css`
|
|
13975
|
+
const styles$2 = css`
|
|
13970
13976
|
${display("inline-flex")}
|
|
13971
13977
|
|
|
13972
13978
|
: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-options: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:${TooltipPositioningOption["above-start"]}}:host([positioning='above']){--position-area:${TooltipPositioningOption.above}}:host([positioning='above-end']){--position-area:${TooltipPositioningOption["above-end"]}}:host([positioning='below-start']){--position-area:${TooltipPositioningOption["below-start"]}}:host([positioning='below']){--position-area:${TooltipPositioningOption.below}}:host([positioning='below-end']){--position-area:${TooltipPositioningOption["below-end"]}}:host([positioning='before-top']){--position-area:${TooltipPositioningOption["before-top"]}}:host([positioning='before']){--position-area:${TooltipPositioningOption.before}}:host([positioning='before-bottom']){--position-area:${TooltipPositioningOption["before-bottom"]}}:host([positioning='after-top']){--position-area:${TooltipPositioningOption["after-top"]}}:host([positioning='after']){--position-area:${TooltipPositioningOption.after}}:host([positioning='after-bottom']){--position-area:${TooltipPositioningOption["after-bottom"]}}`;
|
|
13973
13979
|
|
|
13974
|
-
const template = html`<template popover aria-hidden="true"><slot></slot></template>`;
|
|
13980
|
+
const template$2 = html`<template popover aria-hidden="true"><slot></slot></template>`;
|
|
13975
13981
|
|
|
13976
|
-
const definition = Tooltip.compose({
|
|
13982
|
+
const definition$2 = Tooltip.compose({
|
|
13977
13983
|
name: `${FluentDesignSystem.prefix}-tooltip`,
|
|
13978
|
-
template,
|
|
13979
|
-
styles
|
|
13984
|
+
template: template$2,
|
|
13985
|
+
styles: styles$2
|
|
13986
|
+
});
|
|
13987
|
+
|
|
13988
|
+
definition$2.define(FluentDesignSystem.registry);
|
|
13989
|
+
|
|
13990
|
+
const TreeItemAppearance = {
|
|
13991
|
+
subtle: "subtle",
|
|
13992
|
+
subtleAlpha: "subtle-alpha",
|
|
13993
|
+
transparent: "transparent"
|
|
13994
|
+
};
|
|
13995
|
+
const TreeItemSize = {
|
|
13996
|
+
small: "small",
|
|
13997
|
+
medium: "medium"
|
|
13998
|
+
};
|
|
13999
|
+
function isTreeItem(element, tagName = "-tree-item") {
|
|
14000
|
+
if (element?.nodeType !== Node.ELEMENT_NODE) {
|
|
14001
|
+
return false;
|
|
14002
|
+
}
|
|
14003
|
+
return element.tagName.toLowerCase().endsWith(tagName);
|
|
14004
|
+
}
|
|
14005
|
+
|
|
14006
|
+
var __defProp$3 = Object.defineProperty;
|
|
14007
|
+
var __getOwnPropDesc$3 = Object.getOwnPropertyDescriptor;
|
|
14008
|
+
var __decorateClass$3 = (decorators, target, key, kind) => {
|
|
14009
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$3(target, key) : target;
|
|
14010
|
+
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
14011
|
+
if (kind && result) __defProp$3(target, key, result);
|
|
14012
|
+
return result;
|
|
14013
|
+
};
|
|
14014
|
+
class BaseTree extends FASTElement {
|
|
14015
|
+
constructor() {
|
|
14016
|
+
super();
|
|
14017
|
+
this.currentSelected = null;
|
|
14018
|
+
/**
|
|
14019
|
+
* The tree item that is designated to be in the tab queue.
|
|
14020
|
+
*
|
|
14021
|
+
* @internal
|
|
14022
|
+
*/
|
|
14023
|
+
this.currentFocused = null;
|
|
14024
|
+
/**
|
|
14025
|
+
* The internal {@link https://developer.mozilla.org/docs/Web/API/ElementInternals | `ElementInternals`} instance for the component.
|
|
14026
|
+
*
|
|
14027
|
+
* @internal
|
|
14028
|
+
*/
|
|
14029
|
+
this.elementInternals = this.attachInternals();
|
|
14030
|
+
this.childTreeItems = [];
|
|
14031
|
+
this.elementInternals.role = "tree";
|
|
14032
|
+
}
|
|
14033
|
+
childTreeItemsChanged() {
|
|
14034
|
+
this.updateCurrentSelected();
|
|
14035
|
+
}
|
|
14036
|
+
/**
|
|
14037
|
+
* Updates current selected when slottedTreeItems changes
|
|
14038
|
+
*/
|
|
14039
|
+
updateCurrentSelected() {
|
|
14040
|
+
const selectedItem = this.querySelector(`[aria-selected='true']`);
|
|
14041
|
+
this.currentSelected = selectedItem;
|
|
14042
|
+
if (this.currentFocused === null || !this.contains(this.currentFocused)) {
|
|
14043
|
+
this.currentFocused = this.getValidFocusableItem();
|
|
14044
|
+
}
|
|
14045
|
+
}
|
|
14046
|
+
/**
|
|
14047
|
+
* KeyDown handler
|
|
14048
|
+
*
|
|
14049
|
+
* @internal
|
|
14050
|
+
*/
|
|
14051
|
+
keydownHandler(e) {
|
|
14052
|
+
if (e.defaultPrevented) {
|
|
14053
|
+
return;
|
|
14054
|
+
}
|
|
14055
|
+
const item = e.target;
|
|
14056
|
+
if (!isTreeItem(item) || this.childTreeItems.length < 1) {
|
|
14057
|
+
return true;
|
|
14058
|
+
}
|
|
14059
|
+
const elements = this.getVisibleNodes();
|
|
14060
|
+
switch (e.key) {
|
|
14061
|
+
case keyHome:
|
|
14062
|
+
{
|
|
14063
|
+
if (elements.length) {
|
|
14064
|
+
elements[0].focus();
|
|
14065
|
+
}
|
|
14066
|
+
return;
|
|
14067
|
+
}
|
|
14068
|
+
case keyEnd:
|
|
14069
|
+
{
|
|
14070
|
+
if (elements.length) {
|
|
14071
|
+
elements[elements.length - 1].focus();
|
|
14072
|
+
}
|
|
14073
|
+
return;
|
|
14074
|
+
}
|
|
14075
|
+
case keyArrowLeft:
|
|
14076
|
+
{
|
|
14077
|
+
if (item?.childTreeItems?.length && item.expanded) {
|
|
14078
|
+
item.expanded = false;
|
|
14079
|
+
} else if (isTreeItem(item.parentElement)) {
|
|
14080
|
+
item.parentElement.focus();
|
|
14081
|
+
}
|
|
14082
|
+
return;
|
|
14083
|
+
}
|
|
14084
|
+
case keyArrowRight:
|
|
14085
|
+
{
|
|
14086
|
+
if (item?.childTreeItems?.length) {
|
|
14087
|
+
if (!item.expanded) {
|
|
14088
|
+
item.expanded = true;
|
|
14089
|
+
} else {
|
|
14090
|
+
this.focusNextNode(1, item);
|
|
14091
|
+
}
|
|
14092
|
+
}
|
|
14093
|
+
return;
|
|
14094
|
+
}
|
|
14095
|
+
case keyArrowDown:
|
|
14096
|
+
{
|
|
14097
|
+
this.focusNextNode(1, item);
|
|
14098
|
+
return;
|
|
14099
|
+
}
|
|
14100
|
+
case keyArrowUp:
|
|
14101
|
+
{
|
|
14102
|
+
this.focusNextNode(-1, item);
|
|
14103
|
+
return;
|
|
14104
|
+
}
|
|
14105
|
+
case keyEnter:
|
|
14106
|
+
{
|
|
14107
|
+
this.clickHandler(e);
|
|
14108
|
+
return;
|
|
14109
|
+
}
|
|
14110
|
+
case keySpace:
|
|
14111
|
+
{
|
|
14112
|
+
item.toggleSelection();
|
|
14113
|
+
return;
|
|
14114
|
+
}
|
|
14115
|
+
}
|
|
14116
|
+
return true;
|
|
14117
|
+
}
|
|
14118
|
+
/**
|
|
14119
|
+
* Handle focus events
|
|
14120
|
+
*
|
|
14121
|
+
* @internal
|
|
14122
|
+
*/
|
|
14123
|
+
focusHandler(e) {
|
|
14124
|
+
if (this.childTreeItems.length < 1) {
|
|
14125
|
+
return;
|
|
14126
|
+
}
|
|
14127
|
+
if (e.target === this) {
|
|
14128
|
+
if (this.currentFocused === null) {
|
|
14129
|
+
this.currentFocused = this.getValidFocusableItem();
|
|
14130
|
+
}
|
|
14131
|
+
if (this.currentFocused !== null) {
|
|
14132
|
+
this.currentFocused.focus();
|
|
14133
|
+
}
|
|
14134
|
+
return;
|
|
14135
|
+
}
|
|
14136
|
+
if (this.contains(e.target)) {
|
|
14137
|
+
this.setAttribute("tabindex", "-1");
|
|
14138
|
+
this.currentFocused = e.target;
|
|
14139
|
+
}
|
|
14140
|
+
}
|
|
14141
|
+
/**
|
|
14142
|
+
* Handle blur events
|
|
14143
|
+
*
|
|
14144
|
+
* @internal
|
|
14145
|
+
*/
|
|
14146
|
+
blurHandler(e) {
|
|
14147
|
+
if (e.target instanceof HTMLElement && (e.relatedTarget === null || !this.contains(e.relatedTarget))) {
|
|
14148
|
+
this.setAttribute("tabindex", "0");
|
|
14149
|
+
}
|
|
14150
|
+
}
|
|
14151
|
+
/**
|
|
14152
|
+
* Handles click events bubbling up
|
|
14153
|
+
*
|
|
14154
|
+
* @internal
|
|
14155
|
+
*/
|
|
14156
|
+
clickHandler(e) {
|
|
14157
|
+
if (e.defaultPrevented) {
|
|
14158
|
+
return;
|
|
14159
|
+
}
|
|
14160
|
+
if (!isTreeItem(e.target)) {
|
|
14161
|
+
return true;
|
|
14162
|
+
}
|
|
14163
|
+
const item = e.target;
|
|
14164
|
+
item.toggleExpansion();
|
|
14165
|
+
item.toggleSelection();
|
|
14166
|
+
}
|
|
14167
|
+
/**
|
|
14168
|
+
* Handles the selected-changed events bubbling up
|
|
14169
|
+
* from child tree items
|
|
14170
|
+
*
|
|
14171
|
+
* @internal
|
|
14172
|
+
*/
|
|
14173
|
+
changeHandler(e) {
|
|
14174
|
+
if (e.defaultPrevented) {
|
|
14175
|
+
return;
|
|
14176
|
+
}
|
|
14177
|
+
if (!isTreeItem(e.target)) {
|
|
14178
|
+
return true;
|
|
14179
|
+
}
|
|
14180
|
+
const item = e.target;
|
|
14181
|
+
if (item.selected) {
|
|
14182
|
+
if (this.currentSelected && this.currentSelected !== item && isTreeItem(this.currentSelected)) {
|
|
14183
|
+
this.currentSelected.selected = false;
|
|
14184
|
+
}
|
|
14185
|
+
this.currentSelected = item;
|
|
14186
|
+
} else if (!item.selected && this.currentSelected === item) {
|
|
14187
|
+
this.currentSelected = null;
|
|
14188
|
+
}
|
|
14189
|
+
}
|
|
14190
|
+
/**
|
|
14191
|
+
* checks if there are any nested tree items
|
|
14192
|
+
*/
|
|
14193
|
+
getValidFocusableItem() {
|
|
14194
|
+
const elements = this.getVisibleNodes();
|
|
14195
|
+
let focusIndex = elements.findIndex(el => el.selected);
|
|
14196
|
+
if (focusIndex === -1) {
|
|
14197
|
+
focusIndex = elements.findIndex(el => isTreeItem(el));
|
|
14198
|
+
}
|
|
14199
|
+
if (focusIndex !== -1) {
|
|
14200
|
+
return elements[focusIndex];
|
|
14201
|
+
}
|
|
14202
|
+
return null;
|
|
14203
|
+
}
|
|
14204
|
+
getVisibleNodes() {
|
|
14205
|
+
return Array.from(this.querySelectorAll("*")).filter(node => isTreeItem(node) && node.offsetParent !== null);
|
|
14206
|
+
}
|
|
14207
|
+
/**
|
|
14208
|
+
* Move focus to a tree item based on its offset from the provided item
|
|
14209
|
+
*/
|
|
14210
|
+
focusNextNode(delta, item) {
|
|
14211
|
+
const visibleNodes = this.getVisibleNodes();
|
|
14212
|
+
if (!visibleNodes.length) {
|
|
14213
|
+
return;
|
|
14214
|
+
}
|
|
14215
|
+
const focusItem = visibleNodes[visibleNodes.indexOf(item) + delta];
|
|
14216
|
+
if (isHTMLElement(focusItem)) {
|
|
14217
|
+
focusItem.focus();
|
|
14218
|
+
}
|
|
14219
|
+
}
|
|
14220
|
+
}
|
|
14221
|
+
__decorateClass$3([observable], BaseTree.prototype, "currentSelected", 2);
|
|
14222
|
+
__decorateClass$3([observable], BaseTree.prototype, "childTreeItems", 2);
|
|
14223
|
+
|
|
14224
|
+
var __defProp$2 = Object.defineProperty;
|
|
14225
|
+
var __getOwnPropDesc$2 = Object.getOwnPropertyDescriptor;
|
|
14226
|
+
var __decorateClass$2 = (decorators, target, key, kind) => {
|
|
14227
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$2(target, key) : target;
|
|
14228
|
+
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
14229
|
+
if (kind && result) __defProp$2(target, key, result);
|
|
14230
|
+
return result;
|
|
14231
|
+
};
|
|
14232
|
+
class Tree extends BaseTree {
|
|
14233
|
+
constructor() {
|
|
14234
|
+
super(...arguments);
|
|
14235
|
+
this.size = TreeItemSize.small;
|
|
14236
|
+
this.appearance = TreeItemAppearance.subtle;
|
|
14237
|
+
}
|
|
14238
|
+
sizeChanged() {
|
|
14239
|
+
this.updateSizeAndAppearance();
|
|
14240
|
+
}
|
|
14241
|
+
appearanceChanged() {
|
|
14242
|
+
this.updateSizeAndAppearance();
|
|
14243
|
+
}
|
|
14244
|
+
/**
|
|
14245
|
+
* child tree items supered change event
|
|
14246
|
+
* @internal
|
|
14247
|
+
*/
|
|
14248
|
+
childTreeItemsChanged() {
|
|
14249
|
+
super.childTreeItemsChanged();
|
|
14250
|
+
this.updateSizeAndAppearance();
|
|
14251
|
+
}
|
|
14252
|
+
/**
|
|
14253
|
+
* 1. Update the child items' size based on the tree's size
|
|
14254
|
+
* 2. Update the child items' appearance based on the tree's appearance
|
|
14255
|
+
*/
|
|
14256
|
+
updateSizeAndAppearance() {
|
|
14257
|
+
if (!this.childTreeItems?.length) {
|
|
14258
|
+
return;
|
|
14259
|
+
}
|
|
14260
|
+
this.childTreeItems.forEach(item => {
|
|
14261
|
+
item.size = this.size;
|
|
14262
|
+
item.appearance = this.appearance;
|
|
14263
|
+
});
|
|
14264
|
+
}
|
|
14265
|
+
}
|
|
14266
|
+
__decorateClass$2([attr], Tree.prototype, "size", 2);
|
|
14267
|
+
__decorateClass$2([attr], Tree.prototype, "appearance", 2);
|
|
14268
|
+
|
|
14269
|
+
const styles$1 = css`
|
|
14270
|
+
${display("block")}
|
|
14271
|
+
:host{outline:none}`;
|
|
14272
|
+
|
|
14273
|
+
const template$1 = html`<template tabindex="0" @click="${(x, c) => x.clickHandler(c.event)}" @focusin="${(x, c) => x.focusHandler(c.event)}" @focusout="${(x, c) => x.blurHandler(c.event)}" @keydown="${(x, c) => x.keydownHandler(c.event)}" @change="${(x, c) => x.changeHandler(c.event)}" ${children({
|
|
14274
|
+
property: "childTreeItems",
|
|
14275
|
+
filter: node => isTreeItem(node)
|
|
14276
|
+
})}><slot></slot></template>`;
|
|
14277
|
+
|
|
14278
|
+
const definition$1 = Tree.compose({
|
|
14279
|
+
name: `${FluentDesignSystem.prefix}-tree`,
|
|
14280
|
+
template: template$1,
|
|
14281
|
+
styles: styles$1
|
|
14282
|
+
});
|
|
14283
|
+
|
|
14284
|
+
definition$1.define(FluentDesignSystem.registry);
|
|
14285
|
+
|
|
14286
|
+
var __defProp$1 = Object.defineProperty;
|
|
14287
|
+
var __getOwnPropDesc$1 = Object.getOwnPropertyDescriptor;
|
|
14288
|
+
var __decorateClass$1 = (decorators, target, key, kind) => {
|
|
14289
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$1(target, key) : target;
|
|
14290
|
+
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
14291
|
+
if (kind && result) __defProp$1(target, key, result);
|
|
14292
|
+
return result;
|
|
14293
|
+
};
|
|
14294
|
+
class BaseTreeItem extends FASTElement {
|
|
14295
|
+
constructor() {
|
|
14296
|
+
super();
|
|
14297
|
+
/**
|
|
14298
|
+
* The internal {@link https://developer.mozilla.org/docs/Web/API/ElementInternals | `ElementInternals`} instance for the component.
|
|
14299
|
+
*
|
|
14300
|
+
* @internal
|
|
14301
|
+
*/
|
|
14302
|
+
this.elementInternals = this.attachInternals();
|
|
14303
|
+
this.expanded = false;
|
|
14304
|
+
this.selected = false;
|
|
14305
|
+
this.empty = false;
|
|
14306
|
+
this.childTreeItems = [];
|
|
14307
|
+
this.elementInternals.role = "treeitem";
|
|
14308
|
+
}
|
|
14309
|
+
/**
|
|
14310
|
+
* Handles changes to the expanded attribute
|
|
14311
|
+
* @param prev - the previous state
|
|
14312
|
+
* @param next - the next state
|
|
14313
|
+
*
|
|
14314
|
+
* @public
|
|
14315
|
+
*/
|
|
14316
|
+
expandedChanged(prev, next) {
|
|
14317
|
+
toggleState(this.elementInternals, "expanded", next);
|
|
14318
|
+
if (this.childTreeItems && this.childTreeItems.length > 0) {
|
|
14319
|
+
this.elementInternals.ariaExpanded = next ? "true" : "false";
|
|
14320
|
+
}
|
|
14321
|
+
}
|
|
14322
|
+
/**
|
|
14323
|
+
* Handles changes to the selected attribute
|
|
14324
|
+
* @param prev - the previous state
|
|
14325
|
+
* @param next - the next state
|
|
14326
|
+
*
|
|
14327
|
+
* @internal
|
|
14328
|
+
*/
|
|
14329
|
+
selectedChanged(prev, next) {
|
|
14330
|
+
this.$emit("change");
|
|
14331
|
+
toggleState(this.elementInternals, "selected", next);
|
|
14332
|
+
this.elementInternals.ariaSelected = next ? "true" : "false";
|
|
14333
|
+
}
|
|
14334
|
+
dataIndentChanged(prev, next) {
|
|
14335
|
+
if (this.styles !== void 0) {
|
|
14336
|
+
this.$fastController.removeStyles(this.styles);
|
|
14337
|
+
}
|
|
14338
|
+
this.styles = css`
|
|
14339
|
+
:host{--indent:${next}}`;
|
|
14340
|
+
this.$fastController.addStyles(this.styles);
|
|
14341
|
+
}
|
|
14342
|
+
/**
|
|
14343
|
+
* Handles changes to the child tree items
|
|
14344
|
+
*
|
|
14345
|
+
* @public
|
|
14346
|
+
*/
|
|
14347
|
+
childTreeItemsChanged() {
|
|
14348
|
+
this.empty = this.childTreeItems?.length === 0;
|
|
14349
|
+
this.updateChildTreeItems();
|
|
14350
|
+
}
|
|
14351
|
+
/**
|
|
14352
|
+
* Updates the childrens indent
|
|
14353
|
+
*
|
|
14354
|
+
* @public
|
|
14355
|
+
*/
|
|
14356
|
+
updateChildTreeItems() {
|
|
14357
|
+
if (!this.childTreeItems?.length) {
|
|
14358
|
+
return;
|
|
14359
|
+
}
|
|
14360
|
+
this.childTreeItems.forEach(item => {
|
|
14361
|
+
this.setIndent(item);
|
|
14362
|
+
});
|
|
14363
|
+
}
|
|
14364
|
+
/**
|
|
14365
|
+
* Sets the indent for each item
|
|
14366
|
+
*/
|
|
14367
|
+
setIndent(item) {
|
|
14368
|
+
const indent = this.dataIndent ?? 0;
|
|
14369
|
+
item.dataIndent = indent + 1;
|
|
14370
|
+
}
|
|
14371
|
+
/**
|
|
14372
|
+
* Handle focus events
|
|
14373
|
+
*
|
|
14374
|
+
* @public
|
|
14375
|
+
*/
|
|
14376
|
+
focusHandler(e) {
|
|
14377
|
+
if (e.target === this ||
|
|
14378
|
+
// In case where the tree-item contains a focusable element, we should not set the tabindex to 0 when the focus is on its child focusable element,
|
|
14379
|
+
// so users can shift+tab to navigate to the tree-item from its child focusable element.
|
|
14380
|
+
this.contains(e.target)) {
|
|
14381
|
+
this.setAttribute("tabindex", "0");
|
|
14382
|
+
}
|
|
14383
|
+
}
|
|
14384
|
+
/**
|
|
14385
|
+
* Handle blur events
|
|
14386
|
+
*
|
|
14387
|
+
* @public
|
|
14388
|
+
*/
|
|
14389
|
+
blurHandler(e) {
|
|
14390
|
+
if (e.target === this) {
|
|
14391
|
+
this.setAttribute("tabindex", "-1");
|
|
14392
|
+
}
|
|
14393
|
+
}
|
|
14394
|
+
/**
|
|
14395
|
+
* Toggle the expansion state of the tree item
|
|
14396
|
+
*
|
|
14397
|
+
* @public
|
|
14398
|
+
*/
|
|
14399
|
+
toggleExpansion() {
|
|
14400
|
+
if (this.childTreeItems?.length) {
|
|
14401
|
+
this.expanded = !this.expanded;
|
|
14402
|
+
}
|
|
14403
|
+
}
|
|
14404
|
+
/**
|
|
14405
|
+
* Toggle the single selection state of the tree item
|
|
14406
|
+
*
|
|
14407
|
+
* @public
|
|
14408
|
+
*/
|
|
14409
|
+
toggleSelection() {
|
|
14410
|
+
this.selected = !this.selected;
|
|
14411
|
+
}
|
|
14412
|
+
/**
|
|
14413
|
+
* Whether the tree is nested
|
|
14414
|
+
* @internal
|
|
14415
|
+
*/
|
|
14416
|
+
get isNestedItem() {
|
|
14417
|
+
return isTreeItem(this.parentElement);
|
|
14418
|
+
}
|
|
14419
|
+
}
|
|
14420
|
+
__decorateClass$1([attr({
|
|
14421
|
+
mode: "boolean"
|
|
14422
|
+
})], BaseTreeItem.prototype, "expanded", 2);
|
|
14423
|
+
__decorateClass$1([attr({
|
|
14424
|
+
mode: "boolean"
|
|
14425
|
+
})], BaseTreeItem.prototype, "selected", 2);
|
|
14426
|
+
__decorateClass$1([attr({
|
|
14427
|
+
mode: "boolean"
|
|
14428
|
+
})], BaseTreeItem.prototype, "empty", 2);
|
|
14429
|
+
__decorateClass$1([attr({
|
|
14430
|
+
attribute: "data-indent"
|
|
14431
|
+
})], BaseTreeItem.prototype, "dataIndent", 2);
|
|
14432
|
+
__decorateClass$1([observable], BaseTreeItem.prototype, "childTreeItems", 2);
|
|
14433
|
+
|
|
14434
|
+
var __defProp = Object.defineProperty;
|
|
14435
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
14436
|
+
var __decorateClass = (decorators, target, key, kind) => {
|
|
14437
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc(target, key) : target;
|
|
14438
|
+
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
14439
|
+
if (kind && result) __defProp(target, key, result);
|
|
14440
|
+
return result;
|
|
14441
|
+
};
|
|
14442
|
+
class TreeItem extends BaseTreeItem {
|
|
14443
|
+
constructor() {
|
|
14444
|
+
super(...arguments);
|
|
14445
|
+
this.size = TreeItemSize.small;
|
|
14446
|
+
this.appearance = TreeItemAppearance.subtle;
|
|
14447
|
+
}
|
|
14448
|
+
/**
|
|
14449
|
+
* Handles changes to the size attribute
|
|
14450
|
+
* we update the child tree items' size based on the size
|
|
14451
|
+
* @internal
|
|
14452
|
+
*/
|
|
14453
|
+
sizeChanged() {
|
|
14454
|
+
this.updateSizeAndAppearance();
|
|
14455
|
+
}
|
|
14456
|
+
/**
|
|
14457
|
+
* Handles changes to the appearance attribute
|
|
14458
|
+
*
|
|
14459
|
+
* @internal
|
|
14460
|
+
*/
|
|
14461
|
+
appearanceChanged() {
|
|
14462
|
+
this.updateSizeAndAppearance();
|
|
14463
|
+
}
|
|
14464
|
+
/**
|
|
14465
|
+
* child tree items supered change event
|
|
14466
|
+
* @internal
|
|
14467
|
+
*/
|
|
14468
|
+
childTreeItemsChanged() {
|
|
14469
|
+
super.childTreeItemsChanged();
|
|
14470
|
+
this.updateSizeAndAppearance();
|
|
14471
|
+
}
|
|
14472
|
+
/**
|
|
14473
|
+
* 1. Update the child items' size based on the tree's size
|
|
14474
|
+
* 2. Update the child items' appearance based on the tree's appearance
|
|
14475
|
+
*
|
|
14476
|
+
* @public
|
|
14477
|
+
*/
|
|
14478
|
+
updateSizeAndAppearance() {
|
|
14479
|
+
if (!this.childTreeItems?.length) {
|
|
14480
|
+
return;
|
|
14481
|
+
}
|
|
14482
|
+
this.childTreeItems.forEach(item => {
|
|
14483
|
+
item.size = this.size;
|
|
14484
|
+
item.appearance = this.appearance;
|
|
14485
|
+
});
|
|
14486
|
+
}
|
|
14487
|
+
}
|
|
14488
|
+
__decorateClass([attr], TreeItem.prototype, "size", 2);
|
|
14489
|
+
__decorateClass([attr], TreeItem.prototype, "appearance", 2);
|
|
14490
|
+
|
|
14491
|
+
const styles = css`
|
|
14492
|
+
${display("block")}
|
|
14493
|
+
|
|
14494
|
+
:host{outline:none;font-size:${fontSizeBase300};line-height:${lineHeightBase300}}:host(:focus-visible) .positioning-region{box-shadow:${spacingVerticalNone} ${spacingVerticalNone} ${spacingVerticalNone} ${spacingVerticalXXS}
|
|
14495
|
+
${colorStrokeFocus2} inset}.positioning-region{display:flex;align-items:center;justify-content:space-between;cursor:pointer;height:${spacingVerticalXXXL};padding-inline-start:calc(var(--indent) * ${spacingHorizontalXXL});padding-inline-end:${spacingVerticalS};border-radius:${borderRadiusMedium};background-color:${colorSubtleBackground};color:${colorNeutralForeground2};gap:${spacingHorizontalXS}}@media (prefers-contrast:more){:host(:focus-visible) .positioning-region{outline:1px solid ${colorStrokeFocus2}}}.content{display:flex;align-items:center;gap:${spacingHorizontalXS}}.chevron{display:flex;align-items:center;flex-shrink:0;justify-content:center;width:${spacingHorizontalXXL};height:${spacingVerticalXXL};transition:transform ${durationFaster} ${curveEasyEaseMax};transform:rotate(0deg)}.chevron:dir(rtl){transform:rotate(180deg)}.aside{display:flex;align-items:center}.positioning-region:hover{background-color:${colorSubtleBackgroundHover};color:${colorNeutralForeground2Hover}}.positioning-region:active{background-color:${colorSubtleBackgroundPressed};color:${colorNeutralForeground2Pressed}}::slotted([slot='start']),::slotted([slot='end']),::slotted(:not([slot])){display:flex;align-items:center;min-width:0}::slotted([slot='start']){flex-shrink:0}::slotted(:not([slot])){padding-inline:${spacingHorizontalXXS}}.items{display:none}:host([expanded]) .items{display:block}:host([empty]) .chevron,:host([empty]) .items{visibility:hidden}:host([selected]) .positioning-region{background-color:${colorSubtleBackgroundSelected};color:${colorNeutralForeground2Selected}}:host([selected]) .content,:host([selected]) .chevron{color:${colorNeutralForeground3Selected}}:host([size='small']) .positioning-region{height:${spacingVerticalXXL};padding-inline-start:calc(var(--indent) * ${spacingHorizontalM})}:host([appearance='subtle-alpha']) .positioning-region:hover{background-color:${colorSubtleBackgroundLightAlphaHover}}:host([appearance='subtle-alpha']) .positioning-region:active{background-color:${colorSubtleBackgroundLightAlphaPressed}}:host([appearance='subtle-alpha'][selected]) .positioning-region{background-color:${colorSubtleBackgroundLightAlphaSelected};color:${colorNeutralForeground2Selected}}:host([appearance='transparent']) .positioning-region{background-color:${colorTransparentBackground}}:host([appearance='transparent']) .positioning-region:hover{background-color:${colorTransparentBackgroundHover}}:host([appearance='transparent']) .positioning-region:active{background-color:${colorTransparentBackgroundPressed}}:host([appearance='transparent'][selected]) .positioning-region{background-color:${colorTransparentBackgroundSelected};color:${colorNeutralForeground2Selected}}:host([expanded]) .chevron{transform:rotate(90deg)}`;
|
|
14496
|
+
|
|
14497
|
+
const chevronIcon = html`<svg width="12" height="12" xmlns="http://www.w3.org/2000/svg" fill="currentColor"><path d="M4.65 2.15a.5.5 0 000 .7L7.79 6 4.65 9.15a.5.5 0 10.7.7l3.5-3.5a.5.5 0 000-.7l-3.5-3.5a.5.5 0 00-.7 0z"></path></svg>`;
|
|
14498
|
+
const template = html`<template tabindex="-1" slot="${x => x.isNestedItem ? "item" : void 0}" @focusin="${(x, c) => x.focusHandler(c.event)}" @focusout="${(x, c) => x.blurHandler(c.event)}" ${children({
|
|
14499
|
+
property: "childTreeItems",
|
|
14500
|
+
filter: node => isTreeItem(node)
|
|
14501
|
+
})}><div class="positioning-region" part="positioning-region"><div class="content" part="content"><span class="chevron" part="chevron"><slot name="chevron">${chevronIcon}</slot></span><slot name="start"></slot><slot></slot><slot name="end"></slot></div><div class="aside" part="aside"><slot name="aside"></slot></div></div><div role="group" class="items" part="items"><slot name="item"></slot></div></template>`;
|
|
14502
|
+
|
|
14503
|
+
const definition = TreeItem.compose({
|
|
14504
|
+
name: `${FluentDesignSystem.prefix}-tree-item`,
|
|
14505
|
+
template: template,
|
|
14506
|
+
styles: styles
|
|
13980
14507
|
});
|
|
13981
14508
|
|
|
13982
14509
|
definition.define(FluentDesignSystem.registry);
|