@fluentui/web-components 3.0.0-beta.55 → 3.0.0-beta.56
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 +12 -2
- package/dist/dts/anchor-button/index.d.ts +1 -1
- package/dist/dts/helpers.tests.d.ts +22 -0
- package/dist/dts/index-rollup.d.ts +1 -0
- package/dist/dts/index.d.ts +2 -1
- package/dist/dts/slider/slider.d.ts +1 -1
- package/dist/dts/styles/states/index.d.ts +36 -0
- package/dist/dts/textarea/define.d.ts +1 -0
- package/dist/dts/textarea/index.d.ts +5 -0
- package/dist/dts/textarea/textarea.bench.d.ts +3 -0
- package/dist/dts/textarea/textarea.d.ts +390 -0
- package/dist/dts/textarea/textarea.definition.d.ts +9 -0
- package/dist/dts/textarea/textarea.options.d.ts +47 -0
- package/dist/dts/textarea/textarea.styles.d.ts +7 -0
- package/dist/dts/textarea/textarea.template.d.ts +12 -0
- package/dist/esm/anchor-button/index.js +1 -1
- package/dist/esm/anchor-button/index.js.map +1 -1
- package/dist/esm/helpers.tests.js +44 -0
- package/dist/esm/helpers.tests.js.map +1 -1
- package/dist/esm/index-rollup.js +1 -0
- package/dist/esm/index-rollup.js.map +1 -1
- package/dist/esm/index.js +2 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/slider/slider.js +1 -1
- package/dist/esm/styles/states/index.js +40 -0
- package/dist/esm/styles/states/index.js.map +1 -1
- package/dist/esm/textarea/define.js +4 -0
- package/dist/esm/textarea/define.js.map +1 -0
- package/dist/esm/textarea/index.js +6 -0
- package/dist/esm/textarea/index.js.map +1 -0
- package/dist/esm/textarea/textarea.bench.js +10 -0
- package/dist/esm/textarea/textarea.bench.js.map +1 -0
- package/dist/esm/textarea/textarea.definition.js +20 -0
- package/dist/esm/textarea/textarea.definition.js.map +1 -0
- package/dist/esm/textarea/textarea.js +605 -0
- package/dist/esm/textarea/textarea.js.map +1 -0
- package/dist/esm/textarea/textarea.options.js +56 -0
- package/dist/esm/textarea/textarea.options.js.map +1 -0
- package/dist/esm/textarea/textarea.styles.js +268 -0
- package/dist/esm/textarea/textarea.styles.js.map +1 -0
- package/dist/esm/textarea/textarea.template.js +54 -0
- package/dist/esm/textarea/textarea.template.js.map +1 -0
- package/dist/web-components.d.ts +462 -2
- package/dist/web-components.js +1090 -538
- package/dist/web-components.min.js +284 -280
- package/package.json +6 -1
package/dist/web-components.js
CHANGED
|
@@ -3391,70 +3391,70 @@ function uniqueId(prefix = "") {
|
|
|
3391
3391
|
return `${prefix}${uniqueIdCounter++}`;
|
|
3392
3392
|
}
|
|
3393
3393
|
|
|
3394
|
-
var __defProp$
|
|
3395
|
-
var __getOwnPropDesc$
|
|
3396
|
-
var __decorateClass$
|
|
3397
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
3394
|
+
var __defProp$w = Object.defineProperty;
|
|
3395
|
+
var __getOwnPropDesc$w = Object.getOwnPropertyDescriptor;
|
|
3396
|
+
var __decorateClass$w = (decorators, target, key, kind) => {
|
|
3397
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$w(target, key) : target;
|
|
3398
3398
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
3399
|
-
if (kind && result) __defProp$
|
|
3399
|
+
if (kind && result) __defProp$w(target, key, result);
|
|
3400
3400
|
return result;
|
|
3401
3401
|
};
|
|
3402
3402
|
class ARIAGlobalStatesAndProperties {}
|
|
3403
|
-
__decorateClass$
|
|
3403
|
+
__decorateClass$w([attr({
|
|
3404
3404
|
attribute: "aria-atomic"
|
|
3405
3405
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaAtomic", 2);
|
|
3406
|
-
__decorateClass$
|
|
3406
|
+
__decorateClass$w([attr({
|
|
3407
3407
|
attribute: "aria-busy"
|
|
3408
3408
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaBusy", 2);
|
|
3409
|
-
__decorateClass$
|
|
3409
|
+
__decorateClass$w([attr({
|
|
3410
3410
|
attribute: "aria-controls"
|
|
3411
3411
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaControls", 2);
|
|
3412
|
-
__decorateClass$
|
|
3412
|
+
__decorateClass$w([attr({
|
|
3413
3413
|
attribute: "aria-current"
|
|
3414
3414
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaCurrent", 2);
|
|
3415
|
-
__decorateClass$
|
|
3415
|
+
__decorateClass$w([attr({
|
|
3416
3416
|
attribute: "aria-describedby"
|
|
3417
3417
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaDescribedby", 2);
|
|
3418
|
-
__decorateClass$
|
|
3418
|
+
__decorateClass$w([attr({
|
|
3419
3419
|
attribute: "aria-details"
|
|
3420
3420
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaDetails", 2);
|
|
3421
|
-
__decorateClass$
|
|
3421
|
+
__decorateClass$w([attr({
|
|
3422
3422
|
attribute: "aria-disabled"
|
|
3423
3423
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaDisabled", 2);
|
|
3424
|
-
__decorateClass$
|
|
3424
|
+
__decorateClass$w([attr({
|
|
3425
3425
|
attribute: "aria-errormessage"
|
|
3426
3426
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaErrormessage", 2);
|
|
3427
|
-
__decorateClass$
|
|
3427
|
+
__decorateClass$w([attr({
|
|
3428
3428
|
attribute: "aria-flowto"
|
|
3429
3429
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaFlowto", 2);
|
|
3430
|
-
__decorateClass$
|
|
3430
|
+
__decorateClass$w([attr({
|
|
3431
3431
|
attribute: "aria-haspopup"
|
|
3432
3432
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaHaspopup", 2);
|
|
3433
|
-
__decorateClass$
|
|
3433
|
+
__decorateClass$w([attr({
|
|
3434
3434
|
attribute: "aria-hidden"
|
|
3435
3435
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaHidden", 2);
|
|
3436
|
-
__decorateClass$
|
|
3436
|
+
__decorateClass$w([attr({
|
|
3437
3437
|
attribute: "aria-invalid"
|
|
3438
3438
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaInvalid", 2);
|
|
3439
|
-
__decorateClass$
|
|
3439
|
+
__decorateClass$w([attr({
|
|
3440
3440
|
attribute: "aria-keyshortcuts"
|
|
3441
3441
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaKeyshortcuts", 2);
|
|
3442
|
-
__decorateClass$
|
|
3442
|
+
__decorateClass$w([attr({
|
|
3443
3443
|
attribute: "aria-label"
|
|
3444
3444
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaLabel", 2);
|
|
3445
|
-
__decorateClass$
|
|
3445
|
+
__decorateClass$w([attr({
|
|
3446
3446
|
attribute: "aria-labelledby"
|
|
3447
3447
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaLabelledby", 2);
|
|
3448
|
-
__decorateClass$
|
|
3448
|
+
__decorateClass$w([attr({
|
|
3449
3449
|
attribute: "aria-live"
|
|
3450
3450
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaLive", 2);
|
|
3451
|
-
__decorateClass$
|
|
3451
|
+
__decorateClass$w([attr({
|
|
3452
3452
|
attribute: "aria-owns"
|
|
3453
3453
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaOwns", 2);
|
|
3454
|
-
__decorateClass$
|
|
3454
|
+
__decorateClass$w([attr({
|
|
3455
3455
|
attribute: "aria-relevant"
|
|
3456
3456
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaRelevant", 2);
|
|
3457
|
-
__decorateClass$
|
|
3457
|
+
__decorateClass$w([attr({
|
|
3458
3458
|
attribute: "aria-roledescription"
|
|
3459
3459
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaRoledescription", 2);
|
|
3460
3460
|
|
|
@@ -3648,12 +3648,12 @@ function toggleState(elementInternals, state, force) {
|
|
|
3648
3648
|
elementInternals.states.delete(state);
|
|
3649
3649
|
}
|
|
3650
3650
|
|
|
3651
|
-
var __defProp$
|
|
3652
|
-
var __getOwnPropDesc$
|
|
3653
|
-
var __decorateClass$
|
|
3654
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
3651
|
+
var __defProp$v = Object.defineProperty;
|
|
3652
|
+
var __getOwnPropDesc$v = Object.getOwnPropertyDescriptor;
|
|
3653
|
+
var __decorateClass$v = (decorators, target, key, kind) => {
|
|
3654
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$v(target, key) : target;
|
|
3655
3655
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
3656
|
-
if (kind && result) __defProp$
|
|
3656
|
+
if (kind && result) __defProp$v(target, key, result);
|
|
3657
3657
|
return result;
|
|
3658
3658
|
};
|
|
3659
3659
|
class BaseAccordionItem extends FASTElement {
|
|
@@ -3687,18 +3687,18 @@ class BaseAccordionItem extends FASTElement {
|
|
|
3687
3687
|
toggleState(this.elementInternals, "disabled", next);
|
|
3688
3688
|
}
|
|
3689
3689
|
}
|
|
3690
|
-
__decorateClass$
|
|
3690
|
+
__decorateClass$v([attr({
|
|
3691
3691
|
attribute: "heading-level",
|
|
3692
3692
|
mode: "fromView",
|
|
3693
3693
|
converter: nullableNumberConverter
|
|
3694
3694
|
})], BaseAccordionItem.prototype, "headinglevel", 2);
|
|
3695
|
-
__decorateClass$
|
|
3695
|
+
__decorateClass$v([attr({
|
|
3696
3696
|
mode: "boolean"
|
|
3697
3697
|
})], BaseAccordionItem.prototype, "expanded", 2);
|
|
3698
|
-
__decorateClass$
|
|
3698
|
+
__decorateClass$v([attr({
|
|
3699
3699
|
mode: "boolean"
|
|
3700
3700
|
})], BaseAccordionItem.prototype, "disabled", 2);
|
|
3701
|
-
__decorateClass$
|
|
3701
|
+
__decorateClass$v([attr], BaseAccordionItem.prototype, "id", 2);
|
|
3702
3702
|
class AccordionItem extends BaseAccordionItem {
|
|
3703
3703
|
constructor() {
|
|
3704
3704
|
super(...arguments);
|
|
@@ -3739,11 +3739,11 @@ class AccordionItem extends BaseAccordionItem {
|
|
|
3739
3739
|
toggleState(this.elementInternals, "block", next);
|
|
3740
3740
|
}
|
|
3741
3741
|
}
|
|
3742
|
-
__decorateClass$
|
|
3743
|
-
__decorateClass$
|
|
3742
|
+
__decorateClass$v([attr], AccordionItem.prototype, "size", 2);
|
|
3743
|
+
__decorateClass$v([attr({
|
|
3744
3744
|
attribute: "marker-position"
|
|
3745
3745
|
})], AccordionItem.prototype, "markerPosition", 2);
|
|
3746
|
-
__decorateClass$
|
|
3746
|
+
__decorateClass$v([attr({
|
|
3747
3747
|
mode: "boolean"
|
|
3748
3748
|
})], AccordionItem.prototype, "block", 2);
|
|
3749
3749
|
applyMixins(AccordionItem, StartEnd);
|
|
@@ -3792,6 +3792,14 @@ css.partial`:is([state--singleline], :state(singleline))`;
|
|
|
3792
3792
|
const multiLineState = css.partial`:is([state--multiline], :state(multiline))`;
|
|
3793
3793
|
const expandedState = css.partial`:is([state--expanded], :state(expanded))`;
|
|
3794
3794
|
const blockState = css.partial`:is([state--block], :state(block))`;
|
|
3795
|
+
css.partial`:is([state--resize], :state(resize))`;
|
|
3796
|
+
const resizeHorizontalState = css.partial`:is([state--resize-horizontal], :state(resize-horizontal))`;
|
|
3797
|
+
const resizeVerticalState = css.partial`:is([state--resize-vertical], :state(resize-vertical))`;
|
|
3798
|
+
const resizeBothState = css.partial`:is([state--resize-both], :state(resize-both))`;
|
|
3799
|
+
const autoResizeState = css.partial`:is([state--auto-resize], :state(auto-resize))`;
|
|
3800
|
+
const displayShadowState = css.partial`:is([state--display-shadow], :state(display-shadow))`;
|
|
3801
|
+
const userInvalidState = css.partial`:is([state--user-invalid], :state(user-invalid))`;
|
|
3802
|
+
css.partial`:is([state--user-valid], :state(user-valid))`;
|
|
3795
3803
|
|
|
3796
3804
|
const colorNeutralForeground1 = "var(--colorNeutralForeground1)";
|
|
3797
3805
|
const colorNeutralForeground1Hover = "var(--colorNeutralForeground1Hover)";
|
|
@@ -4031,7 +4039,7 @@ const curveEasyEaseMax = "var(--curveEasyEaseMax)";
|
|
|
4031
4039
|
const curveEasyEase = "var(--curveEasyEase)";
|
|
4032
4040
|
const curveLinear = "var(--curveLinear)";
|
|
4033
4041
|
|
|
4034
|
-
const styles$
|
|
4042
|
+
const styles$A = css`
|
|
4035
4043
|
${display("block")}
|
|
4036
4044
|
|
|
4037
4045
|
: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}`;
|
|
@@ -4067,30 +4075,30 @@ const chevronDown20Filled = html.partial(`<svg
|
|
|
4067
4075
|
function accordionItemTemplate(options = {}) {
|
|
4068
4076
|
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>`;
|
|
4069
4077
|
}
|
|
4070
|
-
const template$
|
|
4078
|
+
const template$B = accordionItemTemplate({
|
|
4071
4079
|
collapsedIcon: chevronRight20Filled,
|
|
4072
4080
|
expandedIcon: chevronDown20Filled
|
|
4073
4081
|
});
|
|
4074
4082
|
|
|
4075
|
-
const definition$
|
|
4083
|
+
const definition$B = AccordionItem.compose({
|
|
4076
4084
|
name: `${FluentDesignSystem.prefix}-accordion-item`,
|
|
4077
|
-
template: template$
|
|
4078
|
-
styles: styles$
|
|
4085
|
+
template: template$B,
|
|
4086
|
+
styles: styles$A
|
|
4079
4087
|
});
|
|
4080
4088
|
|
|
4081
|
-
definition$
|
|
4089
|
+
definition$B.define(FluentDesignSystem.registry);
|
|
4082
4090
|
|
|
4083
4091
|
const AccordionExpandMode = {
|
|
4084
4092
|
single: "single",
|
|
4085
4093
|
multi: "multi"
|
|
4086
4094
|
};
|
|
4087
4095
|
|
|
4088
|
-
var __defProp$
|
|
4089
|
-
var __getOwnPropDesc$
|
|
4090
|
-
var __decorateClass$
|
|
4091
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
4096
|
+
var __defProp$u = Object.defineProperty;
|
|
4097
|
+
var __getOwnPropDesc$u = Object.getOwnPropertyDescriptor;
|
|
4098
|
+
var __decorateClass$u = (decorators, target, key, kind) => {
|
|
4099
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$u(target, key) : target;
|
|
4092
4100
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
4093
|
-
if (kind && result) __defProp$
|
|
4101
|
+
if (kind && result) __defProp$u(target, key, result);
|
|
4094
4102
|
return result;
|
|
4095
4103
|
};
|
|
4096
4104
|
class Accordion extends FASTElement {
|
|
@@ -4229,12 +4237,12 @@ class Accordion extends FASTElement {
|
|
|
4229
4237
|
});
|
|
4230
4238
|
}
|
|
4231
4239
|
}
|
|
4232
|
-
__decorateClass$
|
|
4240
|
+
__decorateClass$u([attr({
|
|
4233
4241
|
attribute: "expand-mode"
|
|
4234
4242
|
})], Accordion.prototype, "expandmode", 2);
|
|
4235
|
-
__decorateClass$
|
|
4243
|
+
__decorateClass$u([observable], Accordion.prototype, "slottedAccordionItems", 2);
|
|
4236
4244
|
|
|
4237
|
-
const styles$
|
|
4245
|
+
const styles$z = css`
|
|
4238
4246
|
${display("flex")}
|
|
4239
4247
|
|
|
4240
4248
|
:host{flex-direction:column;width:100%;contain:content}`;
|
|
@@ -4245,15 +4253,15 @@ function accordionTemplate() {
|
|
|
4245
4253
|
filter: elements()
|
|
4246
4254
|
})}></slot></template>`;
|
|
4247
4255
|
}
|
|
4248
|
-
const template$
|
|
4256
|
+
const template$A = accordionTemplate();
|
|
4249
4257
|
|
|
4250
|
-
const definition$
|
|
4258
|
+
const definition$A = Accordion.compose({
|
|
4251
4259
|
name: `${FluentDesignSystem.prefix}-accordion`,
|
|
4252
|
-
template: template$
|
|
4253
|
-
styles: styles$
|
|
4260
|
+
template: template$A,
|
|
4261
|
+
styles: styles$z
|
|
4254
4262
|
});
|
|
4255
4263
|
|
|
4256
|
-
definition$
|
|
4264
|
+
definition$A.define(FluentDesignSystem.registry);
|
|
4257
4265
|
|
|
4258
4266
|
const ButtonType = {
|
|
4259
4267
|
submit: "submit",
|
|
@@ -4272,12 +4280,12 @@ const AnchorAttributes = {
|
|
|
4272
4280
|
type: "type"
|
|
4273
4281
|
};
|
|
4274
4282
|
|
|
4275
|
-
var __defProp$
|
|
4276
|
-
var __getOwnPropDesc$
|
|
4277
|
-
var __decorateClass$
|
|
4278
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
4283
|
+
var __defProp$t = Object.defineProperty;
|
|
4284
|
+
var __getOwnPropDesc$t = Object.getOwnPropertyDescriptor;
|
|
4285
|
+
var __decorateClass$t = (decorators, target, key, kind) => {
|
|
4286
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$t(target, key) : target;
|
|
4279
4287
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
4280
|
-
if (kind && result) __defProp$
|
|
4288
|
+
if (kind && result) __defProp$t(target, key, result);
|
|
4281
4289
|
return result;
|
|
4282
4290
|
};
|
|
4283
4291
|
class BaseAnchor extends FASTElement {
|
|
@@ -4385,14 +4393,14 @@ class BaseAnchor extends FASTElement {
|
|
|
4385
4393
|
return proxy;
|
|
4386
4394
|
}
|
|
4387
4395
|
}
|
|
4388
|
-
__decorateClass$
|
|
4389
|
-
__decorateClass$
|
|
4390
|
-
__decorateClass$
|
|
4391
|
-
__decorateClass$
|
|
4392
|
-
__decorateClass$
|
|
4393
|
-
__decorateClass$
|
|
4394
|
-
__decorateClass$
|
|
4395
|
-
__decorateClass$
|
|
4396
|
+
__decorateClass$t([attr], BaseAnchor.prototype, "download", 2);
|
|
4397
|
+
__decorateClass$t([attr], BaseAnchor.prototype, "href", 2);
|
|
4398
|
+
__decorateClass$t([attr], BaseAnchor.prototype, "hreflang", 2);
|
|
4399
|
+
__decorateClass$t([attr], BaseAnchor.prototype, "ping", 2);
|
|
4400
|
+
__decorateClass$t([attr], BaseAnchor.prototype, "referrerpolicy", 2);
|
|
4401
|
+
__decorateClass$t([attr], BaseAnchor.prototype, "rel", 2);
|
|
4402
|
+
__decorateClass$t([attr], BaseAnchor.prototype, "target", 2);
|
|
4403
|
+
__decorateClass$t([attr], BaseAnchor.prototype, "type", 2);
|
|
4396
4404
|
class AnchorButton extends BaseAnchor {
|
|
4397
4405
|
constructor() {
|
|
4398
4406
|
super(...arguments);
|
|
@@ -4446,10 +4454,10 @@ class AnchorButton extends BaseAnchor {
|
|
|
4446
4454
|
toggleState(this.elementInternals, "icon", !!next);
|
|
4447
4455
|
}
|
|
4448
4456
|
}
|
|
4449
|
-
__decorateClass$
|
|
4450
|
-
__decorateClass$
|
|
4451
|
-
__decorateClass$
|
|
4452
|
-
__decorateClass$
|
|
4457
|
+
__decorateClass$t([attr], AnchorButton.prototype, "appearance", 2);
|
|
4458
|
+
__decorateClass$t([attr], AnchorButton.prototype, "shape", 2);
|
|
4459
|
+
__decorateClass$t([attr], AnchorButton.prototype, "size", 2);
|
|
4460
|
+
__decorateClass$t([attr({
|
|
4453
4461
|
attribute: "icon-only",
|
|
4454
4462
|
mode: "boolean"
|
|
4455
4463
|
})], AnchorButton.prototype, "iconOnly", 2);
|
|
@@ -4459,13 +4467,13 @@ const baseButtonStyles = css`
|
|
|
4459
4467
|
${display("inline-flex")}
|
|
4460
4468
|
|
|
4461
4469
|
: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){transition-duration:0.01ms}::slotted(svg){font-size:20px;height:20px;width:20px;fill:currentColor}:is([slot='start'],::slotted([slot='start'])){margin-inline-end:var(--icon-spacing)}:is([slot='end'],::slotted([slot='end'])){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}`;
|
|
4462
|
-
const styles$
|
|
4470
|
+
const styles$y = css`
|
|
4463
4471
|
${baseButtonStyles}
|
|
4464
4472
|
|
|
4465
4473
|
: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`
|
|
4466
4474
|
:host{background:ButtonFace;color:ButtonText}:host(:is(:hover,:focus-visible)){border-color:Highlight}`));
|
|
4467
4475
|
|
|
4468
|
-
const styles$
|
|
4476
|
+
const styles$x = css`
|
|
4469
4477
|
${baseButtonStyles}
|
|
4470
4478
|
|
|
4471
4479
|
::slotted(a){position:absolute;inset:0}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
@@ -4474,15 +4482,15 @@ const styles$w = css`
|
|
|
4474
4482
|
function anchorTemplate$1(options = {}) {
|
|
4475
4483
|
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>`;
|
|
4476
4484
|
}
|
|
4477
|
-
const template$
|
|
4485
|
+
const template$z = anchorTemplate$1();
|
|
4478
4486
|
|
|
4479
|
-
const definition$
|
|
4487
|
+
const definition$z = AnchorButton.compose({
|
|
4480
4488
|
name: `${FluentDesignSystem.prefix}-anchor-button`,
|
|
4481
|
-
template: template$
|
|
4482
|
-
styles: styles$
|
|
4489
|
+
template: template$z,
|
|
4490
|
+
styles: styles$x
|
|
4483
4491
|
});
|
|
4484
4492
|
|
|
4485
|
-
definition$
|
|
4493
|
+
definition$z.define(FluentDesignSystem.registry);
|
|
4486
4494
|
|
|
4487
4495
|
const UNWANTED_ENCLOSURES_REGEX = /[\(\[\{][^\)\]\}]*[\)\]\}]/g;
|
|
4488
4496
|
const UNWANTED_CHARS_REGEX = /[\0-\u001F\!-/:-@\[-`\{-\u00BF\u0250-\u036F\uD800-\uFFFF]/g;
|
|
@@ -4564,12 +4572,12 @@ const AvatarColor = {
|
|
|
4564
4572
|
...AvatarNamedColor
|
|
4565
4573
|
};
|
|
4566
4574
|
|
|
4567
|
-
var __defProp$
|
|
4568
|
-
var __getOwnPropDesc$
|
|
4569
|
-
var __decorateClass$
|
|
4570
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
4575
|
+
var __defProp$s = Object.defineProperty;
|
|
4576
|
+
var __getOwnPropDesc$s = Object.getOwnPropertyDescriptor;
|
|
4577
|
+
var __decorateClass$s = (decorators, target, key, kind) => {
|
|
4578
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$s(target, key) : target;
|
|
4571
4579
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
4572
|
-
if (kind && result) __defProp$
|
|
4580
|
+
if (kind && result) __defProp$s(target, key, result);
|
|
4573
4581
|
return result;
|
|
4574
4582
|
};
|
|
4575
4583
|
class BaseAvatar extends FASTElement {
|
|
@@ -4584,9 +4592,9 @@ class BaseAvatar extends FASTElement {
|
|
|
4584
4592
|
this.elementInternals.role = "img";
|
|
4585
4593
|
}
|
|
4586
4594
|
}
|
|
4587
|
-
__decorateClass$
|
|
4588
|
-
__decorateClass$
|
|
4589
|
-
__decorateClass$
|
|
4595
|
+
__decorateClass$s([attr], BaseAvatar.prototype, "name", 2);
|
|
4596
|
+
__decorateClass$s([attr], BaseAvatar.prototype, "initials", 2);
|
|
4597
|
+
__decorateClass$s([attr], BaseAvatar.prototype, "active", 2);
|
|
4590
4598
|
const _Avatar = class _Avatar extends BaseAvatar {
|
|
4591
4599
|
/**
|
|
4592
4600
|
* Handles changes to observable properties
|
|
@@ -4640,13 +4648,13 @@ const _Avatar = class _Avatar extends BaseAvatar {
|
|
|
4640
4648
|
* An array of the available Avatar named colors
|
|
4641
4649
|
*/
|
|
4642
4650
|
_Avatar.colors = Object.values(AvatarNamedColor);
|
|
4643
|
-
__decorateClass$
|
|
4644
|
-
__decorateClass$
|
|
4645
|
-
__decorateClass$
|
|
4651
|
+
__decorateClass$s([attr], _Avatar.prototype, "shape", 2);
|
|
4652
|
+
__decorateClass$s([attr], _Avatar.prototype, "appearance", 2);
|
|
4653
|
+
__decorateClass$s([attr({
|
|
4646
4654
|
converter: nullableNumberConverter
|
|
4647
4655
|
})], _Avatar.prototype, "size", 2);
|
|
4648
|
-
__decorateClass$
|
|
4649
|
-
__decorateClass$
|
|
4656
|
+
__decorateClass$s([attr], _Avatar.prototype, "color", 2);
|
|
4657
|
+
__decorateClass$s([attr({
|
|
4650
4658
|
attribute: "color-id"
|
|
4651
4659
|
})], _Avatar.prototype, "colorId", 2);
|
|
4652
4660
|
let Avatar = _Avatar;
|
|
@@ -4671,22 +4679,22 @@ const animations = {
|
|
|
4671
4679
|
normalEase: curveEasyEase,
|
|
4672
4680
|
nullEasing: curveLinear
|
|
4673
4681
|
};
|
|
4674
|
-
const styles$
|
|
4682
|
+
const styles$w = css`
|
|
4675
4683
|
${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(:is([state--brand],:state(brand))){color:${colorNeutralForegroundStaticInverted};background-color:${colorBrandBackgroundStatic}}:host(:is([state--dark-red],:state(dark-red))){color:${colorPaletteDarkRedForeground2};background-color:${colorPaletteDarkRedBackground2}}:host(:is([state--cranberry],:state(cranberry))){color:${colorPaletteCranberryForeground2};background-color:${colorPaletteCranberryBackground2}}:host(:is([state--red],:state(red))){color:${colorPaletteRedForeground2};background-color:${colorPaletteRedBackground2}}:host(:is([state--pumpkin],:state(pumpkin))){color:${colorPalettePumpkinForeground2};background-color:${colorPalettePumpkinBackground2}}:host(:is([state--peach],:state(peach))){color:${colorPalettePeachForeground2};background-color:${colorPalettePeachBackground2}}:host(:is([state--marigold],:state(marigold))){color:${colorPaletteMarigoldForeground2};background-color:${colorPaletteMarigoldBackground2}}:host(:is([state--gold],:state(gold))){color:${colorPaletteGoldForeground2};background-color:${colorPaletteGoldBackground2}}:host(:is([state--brass],:state(brass))){color:${colorPaletteBrassForeground2};background-color:${colorPaletteBrassBackground2}}:host(:is([state--brown],:state(brown))){color:${colorPaletteBrownForeground2};background-color:${colorPaletteBrownBackground2}}:host(:is([state--forest],:state(forest))){color:${colorPaletteForestForeground2};background-color:${colorPaletteForestBackground2}}:host(:is([state--seafoam],:state(seafoam))){color:${colorPaletteSeafoamForeground2};background-color:${colorPaletteSeafoamBackground2}}:host(:is([state--dark-green],:state(dark-green))){color:${colorPaletteDarkGreenForeground2};background-color:${colorPaletteDarkGreenBackground2}}:host(:is([state--light-teal],:state(light-teal))){color:${colorPaletteLightTealForeground2};background-color:${colorPaletteLightTealBackground2}}:host(:is([state--teal],:state(teal))){color:${colorPaletteTealForeground2};background-color:${colorPaletteTealBackground2}}:host(:is([state--steel],:state(steel))){color:${colorPaletteSteelForeground2};background-color:${colorPaletteSteelBackground2}}:host(:is([state--blue],:state(blue))){color:${colorPaletteBlueForeground2};background-color:${colorPaletteBlueBackground2}}:host(:is([state--royal-blue],:state(royal-blue))){color:${colorPaletteRoyalBlueForeground2};background-color:${colorPaletteRoyalBlueBackground2}}:host(:is([state--cornflower],:state(cornflower))){color:${colorPaletteCornflowerForeground2};background-color:${colorPaletteCornflowerBackground2}}:host(:is([state--navy],:state(navy))){color:${colorPaletteNavyForeground2};background-color:${colorPaletteNavyBackground2}}:host(:is([state--lavender],:state(lavender))){color:${colorPaletteLavenderForeground2};background-color:${colorPaletteLavenderBackground2}}:host(:is([state--purple],:state(purple))){color:${colorPalettePurpleForeground2};background-color:${colorPalettePurpleBackground2}}:host(:is([state--grape],:state(grape))){color:${colorPaletteGrapeForeground2};background-color:${colorPaletteGrapeBackground2}}:host(:is([state--lilac],:state(lilac))){color:${colorPaletteLilacForeground2};background-color:${colorPaletteLilacBackground2}}:host(:is([state--pink],:state(pink))){color:${colorPalettePinkForeground2};background-color:${colorPalettePinkBackground2}}:host(:is([state--magenta],:state(magenta))){color:${colorPaletteMagentaForeground2};background-color:${colorPaletteMagentaBackground2}}:host(:is([state--plum],:state(plum))){color:${colorPalettePlumForeground2};background-color:${colorPalettePlumBackground2}}:host(:is([state--beige],:state(beige))){color:${colorPaletteBeigeForeground2};background-color:${colorPaletteBeigeBackground2}}:host(:is([state--mink],:state(mink))){color:${colorPaletteMinkForeground2};background-color:${colorPaletteMinkBackground2}}:host(:is([state--platinum],:state(platinum))){color:${colorPalettePlatinumForeground2};background-color:${colorPalettePlatinumBackground2}}:host(:is([state--anchor],:state(anchor))){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}}`;
|
|
4676
4684
|
|
|
4677
4685
|
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>`;
|
|
4678
4686
|
function avatarTemplate() {
|
|
4679
4687
|
return html`<slot>${x => x.name || x.initials ? x.generateInitials() : defaultIconTemplate}</slot><slot name="badge"></slot>`;
|
|
4680
4688
|
}
|
|
4681
|
-
const template$
|
|
4689
|
+
const template$y = avatarTemplate();
|
|
4682
4690
|
|
|
4683
|
-
const definition$
|
|
4691
|
+
const definition$y = Avatar.compose({
|
|
4684
4692
|
name: `${FluentDesignSystem.prefix}-avatar`,
|
|
4685
|
-
template: template$
|
|
4686
|
-
styles: styles$
|
|
4693
|
+
template: template$y,
|
|
4694
|
+
styles: styles$w
|
|
4687
4695
|
});
|
|
4688
4696
|
|
|
4689
|
-
definition$
|
|
4697
|
+
definition$y.define(FluentDesignSystem.registry);
|
|
4690
4698
|
|
|
4691
4699
|
const BadgeAppearance = {
|
|
4692
4700
|
filled: "filled",
|
|
@@ -4705,12 +4713,12 @@ const BadgeColor = {
|
|
|
4705
4713
|
warning: "warning"
|
|
4706
4714
|
};
|
|
4707
4715
|
|
|
4708
|
-
var __defProp$
|
|
4709
|
-
var __getOwnPropDesc$
|
|
4710
|
-
var __decorateClass$
|
|
4711
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
4716
|
+
var __defProp$r = Object.defineProperty;
|
|
4717
|
+
var __getOwnPropDesc$r = Object.getOwnPropertyDescriptor;
|
|
4718
|
+
var __decorateClass$r = (decorators, target, key, kind) => {
|
|
4719
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$r(target, key) : target;
|
|
4712
4720
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
4713
|
-
if (kind && result) __defProp$
|
|
4721
|
+
if (kind && result) __defProp$r(target, key, result);
|
|
4714
4722
|
return result;
|
|
4715
4723
|
};
|
|
4716
4724
|
class Badge extends FASTElement {
|
|
@@ -4778,10 +4786,10 @@ class Badge extends FASTElement {
|
|
|
4778
4786
|
}
|
|
4779
4787
|
}
|
|
4780
4788
|
}
|
|
4781
|
-
__decorateClass$
|
|
4782
|
-
__decorateClass$
|
|
4783
|
-
__decorateClass$
|
|
4784
|
-
__decorateClass$
|
|
4789
|
+
__decorateClass$r([attr], Badge.prototype, "appearance", 2);
|
|
4790
|
+
__decorateClass$r([attr], Badge.prototype, "color", 2);
|
|
4791
|
+
__decorateClass$r([attr], Badge.prototype, "shape", 2);
|
|
4792
|
+
__decorateClass$r([attr], Badge.prototype, "size", 2);
|
|
4785
4793
|
applyMixins(Badge, StartEnd);
|
|
4786
4794
|
|
|
4787
4795
|
const badgeBaseStyles = css.partial`
|
|
@@ -5135,7 +5143,7 @@ css.partial`
|
|
|
5135
5143
|
font-weight: ${fontWeightSemibold};
|
|
5136
5144
|
`;
|
|
5137
5145
|
|
|
5138
|
-
const styles$
|
|
5146
|
+
const styles$v = css`
|
|
5139
5147
|
:host(${squareState}){border-radius:${borderRadiusNone}}:host(${roundedState}){border-radius:${borderRadiusMedium}}:host(${roundedState}${tinyState}),:host(${roundedState}${extraSmallState}),:host(${roundedState}${smallState}){border-radius:${borderRadiusSmall}}${badgeSizeStyles}
|
|
5140
5148
|
${badgeFilledStyles}
|
|
5141
5149
|
${badgeGhostStyles}
|
|
@@ -5148,22 +5156,22 @@ const styles$u = css`
|
|
|
5148
5156
|
function badgeTemplate(options = {}) {
|
|
5149
5157
|
return html` ${startSlotTemplate(options)}<slot>${staticallyCompose(options.defaultContent)}</slot>${endSlotTemplate(options)} `;
|
|
5150
5158
|
}
|
|
5151
|
-
const template$
|
|
5159
|
+
const template$x = badgeTemplate();
|
|
5152
5160
|
|
|
5153
|
-
const definition$
|
|
5161
|
+
const definition$x = Badge.compose({
|
|
5154
5162
|
name: `${FluentDesignSystem.prefix}-badge`,
|
|
5155
|
-
template: template$
|
|
5156
|
-
styles: styles$
|
|
5163
|
+
template: template$x,
|
|
5164
|
+
styles: styles$v
|
|
5157
5165
|
});
|
|
5158
5166
|
|
|
5159
|
-
definition$
|
|
5167
|
+
definition$x.define(FluentDesignSystem.registry);
|
|
5160
5168
|
|
|
5161
|
-
var __defProp$
|
|
5162
|
-
var __getOwnPropDesc$
|
|
5163
|
-
var __decorateClass$
|
|
5164
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
5169
|
+
var __defProp$q = Object.defineProperty;
|
|
5170
|
+
var __getOwnPropDesc$q = Object.getOwnPropertyDescriptor;
|
|
5171
|
+
var __decorateClass$q = (decorators, target, key, kind) => {
|
|
5172
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$q(target, key) : target;
|
|
5165
5173
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
5166
|
-
if (kind && result) __defProp$
|
|
5174
|
+
if (kind && result) __defProp$q(target, key, result);
|
|
5167
5175
|
return result;
|
|
5168
5176
|
};
|
|
5169
5177
|
class BaseButton extends FASTElement {
|
|
@@ -5367,44 +5375,44 @@ class BaseButton extends FASTElement {
|
|
|
5367
5375
|
* @public
|
|
5368
5376
|
*/
|
|
5369
5377
|
BaseButton.formAssociated = true;
|
|
5370
|
-
__decorateClass$
|
|
5378
|
+
__decorateClass$q([attr({
|
|
5371
5379
|
mode: "boolean"
|
|
5372
5380
|
})], BaseButton.prototype, "autofocus", 2);
|
|
5373
|
-
__decorateClass$
|
|
5374
|
-
__decorateClass$
|
|
5381
|
+
__decorateClass$q([observable], BaseButton.prototype, "defaultSlottedContent", 2);
|
|
5382
|
+
__decorateClass$q([attr({
|
|
5375
5383
|
mode: "boolean"
|
|
5376
5384
|
})], BaseButton.prototype, "disabled", 2);
|
|
5377
|
-
__decorateClass$
|
|
5385
|
+
__decorateClass$q([attr({
|
|
5378
5386
|
attribute: "disabled-focusable",
|
|
5379
5387
|
mode: "boolean"
|
|
5380
5388
|
})], BaseButton.prototype, "disabledFocusable", 2);
|
|
5381
|
-
__decorateClass$
|
|
5389
|
+
__decorateClass$q([attr({
|
|
5382
5390
|
attribute: "tabindex",
|
|
5383
5391
|
mode: "fromView",
|
|
5384
5392
|
converter: nullableNumberConverter
|
|
5385
5393
|
})], BaseButton.prototype, "tabIndex", 2);
|
|
5386
|
-
__decorateClass$
|
|
5394
|
+
__decorateClass$q([attr({
|
|
5387
5395
|
attribute: "formaction"
|
|
5388
5396
|
})], BaseButton.prototype, "formAction", 2);
|
|
5389
|
-
__decorateClass$
|
|
5397
|
+
__decorateClass$q([attr({
|
|
5390
5398
|
attribute: "form"
|
|
5391
5399
|
})], BaseButton.prototype, "formAttribute", 2);
|
|
5392
|
-
__decorateClass$
|
|
5400
|
+
__decorateClass$q([attr({
|
|
5393
5401
|
attribute: "formenctype"
|
|
5394
5402
|
})], BaseButton.prototype, "formEnctype", 2);
|
|
5395
|
-
__decorateClass$
|
|
5403
|
+
__decorateClass$q([attr({
|
|
5396
5404
|
attribute: "formmethod"
|
|
5397
5405
|
})], BaseButton.prototype, "formMethod", 2);
|
|
5398
|
-
__decorateClass$
|
|
5406
|
+
__decorateClass$q([attr({
|
|
5399
5407
|
attribute: "formnovalidate",
|
|
5400
5408
|
mode: "boolean"
|
|
5401
5409
|
})], BaseButton.prototype, "formNoValidate", 2);
|
|
5402
|
-
__decorateClass$
|
|
5410
|
+
__decorateClass$q([attr({
|
|
5403
5411
|
attribute: "formtarget"
|
|
5404
5412
|
})], BaseButton.prototype, "formTarget", 2);
|
|
5405
|
-
__decorateClass$
|
|
5406
|
-
__decorateClass$
|
|
5407
|
-
__decorateClass$
|
|
5413
|
+
__decorateClass$q([attr], BaseButton.prototype, "name", 2);
|
|
5414
|
+
__decorateClass$q([attr], BaseButton.prototype, "type", 2);
|
|
5415
|
+
__decorateClass$q([attr], BaseButton.prototype, "value", 2);
|
|
5408
5416
|
class Button extends BaseButton {
|
|
5409
5417
|
constructor() {
|
|
5410
5418
|
super(...arguments);
|
|
@@ -5458,10 +5466,10 @@ class Button extends BaseButton {
|
|
|
5458
5466
|
toggleState(this.elementInternals, "icon", next);
|
|
5459
5467
|
}
|
|
5460
5468
|
}
|
|
5461
|
-
__decorateClass$
|
|
5462
|
-
__decorateClass$
|
|
5463
|
-
__decorateClass$
|
|
5464
|
-
__decorateClass$
|
|
5469
|
+
__decorateClass$q([attr], Button.prototype, "appearance", 2);
|
|
5470
|
+
__decorateClass$q([attr], Button.prototype, "shape", 2);
|
|
5471
|
+
__decorateClass$q([attr], Button.prototype, "size", 2);
|
|
5472
|
+
__decorateClass$q([attr({
|
|
5465
5473
|
attribute: "icon-only",
|
|
5466
5474
|
mode: "boolean"
|
|
5467
5475
|
})], Button.prototype, "iconOnly", 2);
|
|
@@ -5470,22 +5478,22 @@ applyMixins(Button, StartEnd);
|
|
|
5470
5478
|
function buttonTemplate$1(options = {}) {
|
|
5471
5479
|
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>`;
|
|
5472
5480
|
}
|
|
5473
|
-
const template$
|
|
5481
|
+
const template$w = buttonTemplate$1();
|
|
5474
5482
|
|
|
5475
|
-
const definition$
|
|
5483
|
+
const definition$w = Button.compose({
|
|
5476
5484
|
name: `${FluentDesignSystem.prefix}-button`,
|
|
5477
|
-
template: template$
|
|
5478
|
-
styles: styles$
|
|
5485
|
+
template: template$w,
|
|
5486
|
+
styles: styles$y
|
|
5479
5487
|
});
|
|
5480
5488
|
|
|
5481
|
-
definition$
|
|
5489
|
+
definition$w.define(FluentDesignSystem.registry);
|
|
5482
5490
|
|
|
5483
|
-
var __defProp$
|
|
5484
|
-
var __getOwnPropDesc$
|
|
5485
|
-
var __decorateClass$
|
|
5486
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
5491
|
+
var __defProp$p = Object.defineProperty;
|
|
5492
|
+
var __getOwnPropDesc$p = Object.getOwnPropertyDescriptor;
|
|
5493
|
+
var __decorateClass$p = (decorators, target, key, kind) => {
|
|
5494
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$p(target, key) : target;
|
|
5487
5495
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
5488
|
-
if (kind && result) __defProp$
|
|
5496
|
+
if (kind && result) __defProp$p(target, key, result);
|
|
5489
5497
|
return result;
|
|
5490
5498
|
};
|
|
5491
5499
|
class BaseCheckbox extends FASTElement {
|
|
@@ -5819,27 +5827,27 @@ class BaseCheckbox extends FASTElement {
|
|
|
5819
5827
|
* @public
|
|
5820
5828
|
*/
|
|
5821
5829
|
BaseCheckbox.formAssociated = true;
|
|
5822
|
-
__decorateClass$
|
|
5830
|
+
__decorateClass$p([attr({
|
|
5823
5831
|
mode: "boolean"
|
|
5824
5832
|
})], BaseCheckbox.prototype, "autofocus", 2);
|
|
5825
|
-
__decorateClass$
|
|
5826
|
-
__decorateClass$
|
|
5833
|
+
__decorateClass$p([observable], BaseCheckbox.prototype, "disabled", 2);
|
|
5834
|
+
__decorateClass$p([attr({
|
|
5827
5835
|
attribute: "disabled",
|
|
5828
5836
|
mode: "boolean"
|
|
5829
5837
|
})], BaseCheckbox.prototype, "disabledAttribute", 2);
|
|
5830
|
-
__decorateClass$
|
|
5838
|
+
__decorateClass$p([attr({
|
|
5831
5839
|
attribute: "form"
|
|
5832
5840
|
})], BaseCheckbox.prototype, "formAttribute", 2);
|
|
5833
|
-
__decorateClass$
|
|
5841
|
+
__decorateClass$p([attr({
|
|
5834
5842
|
attribute: "checked",
|
|
5835
5843
|
mode: "boolean"
|
|
5836
5844
|
})], BaseCheckbox.prototype, "initialChecked", 2);
|
|
5837
|
-
__decorateClass$
|
|
5845
|
+
__decorateClass$p([attr({
|
|
5838
5846
|
attribute: "value",
|
|
5839
5847
|
mode: "fromView"
|
|
5840
5848
|
})], BaseCheckbox.prototype, "initialValue", 2);
|
|
5841
|
-
__decorateClass$
|
|
5842
|
-
__decorateClass$
|
|
5849
|
+
__decorateClass$p([attr], BaseCheckbox.prototype, "name", 2);
|
|
5850
|
+
__decorateClass$p([attr({
|
|
5843
5851
|
mode: "boolean"
|
|
5844
5852
|
})], BaseCheckbox.prototype, "required", 2);
|
|
5845
5853
|
class Checkbox extends BaseCheckbox {
|
|
@@ -5912,12 +5920,12 @@ class Checkbox extends BaseCheckbox {
|
|
|
5912
5920
|
super.toggleChecked(force);
|
|
5913
5921
|
}
|
|
5914
5922
|
}
|
|
5915
|
-
__decorateClass$
|
|
5916
|
-
__decorateClass$
|
|
5917
|
-
__decorateClass$
|
|
5923
|
+
__decorateClass$p([observable], Checkbox.prototype, "indeterminate", 2);
|
|
5924
|
+
__decorateClass$p([attr], Checkbox.prototype, "shape", 2);
|
|
5925
|
+
__decorateClass$p([attr], Checkbox.prototype, "size", 2);
|
|
5918
5926
|
|
|
5919
5927
|
const indeterminateState = css.partial`:is([state--indeterminate], :state(indeterminate))`;
|
|
5920
|
-
const styles$
|
|
5928
|
+
const styles$u = css`
|
|
5921
5929
|
${display("inline-flex")}
|
|
5922
5930
|
|
|
5923
5931
|
: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`
|
|
@@ -5943,23 +5951,23 @@ const indeterminateIndicator = html.partial( /* html */
|
|
|
5943
5951
|
function checkboxTemplate(options = {}) {
|
|
5944
5952
|
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>`;
|
|
5945
5953
|
}
|
|
5946
|
-
const template$
|
|
5954
|
+
const template$v = checkboxTemplate({
|
|
5947
5955
|
checkedIndicator: checkedIndicator$1,
|
|
5948
5956
|
indeterminateIndicator
|
|
5949
5957
|
});
|
|
5950
5958
|
|
|
5951
|
-
const definition$
|
|
5959
|
+
const definition$v = Checkbox.compose({
|
|
5952
5960
|
name: `${FluentDesignSystem.prefix}-checkbox`,
|
|
5953
|
-
template: template$
|
|
5954
|
-
styles: styles$
|
|
5961
|
+
template: template$v,
|
|
5962
|
+
styles: styles$u
|
|
5955
5963
|
});
|
|
5956
5964
|
|
|
5957
|
-
definition$
|
|
5965
|
+
definition$v.define(FluentDesignSystem.registry);
|
|
5958
5966
|
|
|
5959
5967
|
class CompoundButton extends Button {}
|
|
5960
5968
|
|
|
5961
|
-
const styles$
|
|
5962
|
-
${styles$
|
|
5969
|
+
const styles$t = css`
|
|
5970
|
+
${styles$y}
|
|
5963
5971
|
|
|
5964
5972
|
: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]))
|
|
5965
5973
|
::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}}`;
|
|
@@ -5967,22 +5975,22 @@ const styles$s = css`
|
|
|
5967
5975
|
function buttonTemplate(options = {}) {
|
|
5968
5976
|
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>`;
|
|
5969
5977
|
}
|
|
5970
|
-
const template$
|
|
5978
|
+
const template$u = buttonTemplate();
|
|
5971
5979
|
|
|
5972
|
-
const definition$
|
|
5980
|
+
const definition$u = CompoundButton.compose({
|
|
5973
5981
|
name: `${FluentDesignSystem.prefix}-compound-button`,
|
|
5974
|
-
template: template$
|
|
5975
|
-
styles: styles$
|
|
5982
|
+
template: template$u,
|
|
5983
|
+
styles: styles$t
|
|
5976
5984
|
});
|
|
5977
5985
|
|
|
5978
|
-
definition$
|
|
5986
|
+
definition$u.define(FluentDesignSystem.registry);
|
|
5979
5987
|
|
|
5980
|
-
var __defProp$
|
|
5981
|
-
var __getOwnPropDesc$
|
|
5982
|
-
var __decorateClass$
|
|
5983
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
5988
|
+
var __defProp$o = Object.defineProperty;
|
|
5989
|
+
var __getOwnPropDesc$o = Object.getOwnPropertyDescriptor;
|
|
5990
|
+
var __decorateClass$o = (decorators, target, key, kind) => {
|
|
5991
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$o(target, key) : target;
|
|
5984
5992
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
5985
|
-
if (kind && result) __defProp$
|
|
5993
|
+
if (kind && result) __defProp$o(target, key, result);
|
|
5986
5994
|
return result;
|
|
5987
5995
|
};
|
|
5988
5996
|
class CounterBadge extends FASTElement {
|
|
@@ -6079,28 +6087,28 @@ class CounterBadge extends FASTElement {
|
|
|
6079
6087
|
return;
|
|
6080
6088
|
}
|
|
6081
6089
|
}
|
|
6082
|
-
__decorateClass$
|
|
6083
|
-
__decorateClass$
|
|
6084
|
-
__decorateClass$
|
|
6085
|
-
__decorateClass$
|
|
6086
|
-
__decorateClass$
|
|
6090
|
+
__decorateClass$o([attr], CounterBadge.prototype, "appearance", 2);
|
|
6091
|
+
__decorateClass$o([attr], CounterBadge.prototype, "color", 2);
|
|
6092
|
+
__decorateClass$o([attr], CounterBadge.prototype, "shape", 2);
|
|
6093
|
+
__decorateClass$o([attr], CounterBadge.prototype, "size", 2);
|
|
6094
|
+
__decorateClass$o([attr({
|
|
6087
6095
|
converter: nullableNumberConverter
|
|
6088
6096
|
})], CounterBadge.prototype, "count", 2);
|
|
6089
|
-
__decorateClass$
|
|
6097
|
+
__decorateClass$o([attr({
|
|
6090
6098
|
attribute: "overflow-count",
|
|
6091
6099
|
converter: nullableNumberConverter
|
|
6092
6100
|
})], CounterBadge.prototype, "overflowCount", 2);
|
|
6093
|
-
__decorateClass$
|
|
6101
|
+
__decorateClass$o([attr({
|
|
6094
6102
|
attribute: "show-zero",
|
|
6095
6103
|
mode: "boolean"
|
|
6096
6104
|
})], CounterBadge.prototype, "showZero", 2);
|
|
6097
|
-
__decorateClass$
|
|
6105
|
+
__decorateClass$o([attr({
|
|
6098
6106
|
mode: "boolean"
|
|
6099
6107
|
})], CounterBadge.prototype, "dot", 2);
|
|
6100
6108
|
applyMixins(CounterBadge, StartEnd);
|
|
6101
6109
|
|
|
6102
6110
|
const dotState = css.partial`:is([state--dot], :state(dot))`;
|
|
6103
|
-
const styles$
|
|
6111
|
+
const styles$s = css`
|
|
6104
6112
|
:host(${roundedState}){border-radius:${borderRadiusMedium}}:host(${roundedState}${tinyState}),:host(${roundedState}${extraSmallState}),:host(${roundedState}${smallState}){border-radius:${borderRadiusSmall}}${badgeSizeStyles}
|
|
6105
6113
|
${badgeFilledStyles}
|
|
6106
6114
|
${badgeGhostStyles}
|
|
@@ -6113,15 +6121,15 @@ function composeTemplate(options = {}) {
|
|
|
6113
6121
|
defaultContent: html`${x => x.setCount()}`
|
|
6114
6122
|
});
|
|
6115
6123
|
}
|
|
6116
|
-
const template$
|
|
6124
|
+
const template$t = composeTemplate();
|
|
6117
6125
|
|
|
6118
|
-
const definition$
|
|
6126
|
+
const definition$t = CounterBadge.compose({
|
|
6119
6127
|
name: `${FluentDesignSystem.prefix}-counter-badge`,
|
|
6120
|
-
template: template$
|
|
6121
|
-
styles: styles$
|
|
6128
|
+
template: template$t,
|
|
6129
|
+
styles: styles$s
|
|
6122
6130
|
});
|
|
6123
6131
|
|
|
6124
|
-
definition$
|
|
6132
|
+
definition$t.define(FluentDesignSystem.registry);
|
|
6125
6133
|
|
|
6126
6134
|
const DialogType = {
|
|
6127
6135
|
modal: "modal",
|
|
@@ -6129,12 +6137,12 @@ const DialogType = {
|
|
|
6129
6137
|
alert: "alert"
|
|
6130
6138
|
};
|
|
6131
6139
|
|
|
6132
|
-
var __defProp$
|
|
6133
|
-
var __getOwnPropDesc$
|
|
6134
|
-
var __decorateClass$
|
|
6135
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6140
|
+
var __defProp$n = Object.defineProperty;
|
|
6141
|
+
var __getOwnPropDesc$n = Object.getOwnPropertyDescriptor;
|
|
6142
|
+
var __decorateClass$n = (decorators, target, key, kind) => {
|
|
6143
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$n(target, key) : target;
|
|
6136
6144
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6137
|
-
if (kind && result) __defProp$
|
|
6145
|
+
if (kind && result) __defProp$n(target, key, result);
|
|
6138
6146
|
return result;
|
|
6139
6147
|
};
|
|
6140
6148
|
class Dialog extends FASTElement {
|
|
@@ -6202,35 +6210,35 @@ class Dialog extends FASTElement {
|
|
|
6202
6210
|
return true;
|
|
6203
6211
|
}
|
|
6204
6212
|
}
|
|
6205
|
-
__decorateClass$
|
|
6206
|
-
__decorateClass$
|
|
6213
|
+
__decorateClass$n([observable], Dialog.prototype, "dialog", 2);
|
|
6214
|
+
__decorateClass$n([attr({
|
|
6207
6215
|
attribute: "aria-describedby"
|
|
6208
6216
|
})], Dialog.prototype, "ariaDescribedby", 2);
|
|
6209
|
-
__decorateClass$
|
|
6217
|
+
__decorateClass$n([attr({
|
|
6210
6218
|
attribute: "aria-labelledby"
|
|
6211
6219
|
})], Dialog.prototype, "ariaLabelledby", 2);
|
|
6212
|
-
__decorateClass$
|
|
6220
|
+
__decorateClass$n([attr], Dialog.prototype, "type", 2);
|
|
6213
6221
|
|
|
6214
|
-
const template$
|
|
6222
|
+
const template$s = 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>`;
|
|
6215
6223
|
|
|
6216
|
-
const styles$
|
|
6224
|
+
const styles$r = css`
|
|
6217
6225
|
@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`
|
|
6218
6226
|
@layer base{dialog{border:${strokeWidthThin} solid ${colorTransparentStroke}}}`));
|
|
6219
6227
|
|
|
6220
|
-
const definition$
|
|
6228
|
+
const definition$s = Dialog.compose({
|
|
6221
6229
|
name: `${FluentDesignSystem.prefix}-dialog`,
|
|
6222
|
-
template: template$
|
|
6223
|
-
styles: styles$
|
|
6230
|
+
template: template$s,
|
|
6231
|
+
styles: styles$r
|
|
6224
6232
|
});
|
|
6225
6233
|
|
|
6226
|
-
definition$
|
|
6234
|
+
definition$s.define(FluentDesignSystem.registry);
|
|
6227
6235
|
|
|
6228
|
-
var __defProp$
|
|
6229
|
-
var __getOwnPropDesc$
|
|
6230
|
-
var __decorateClass$
|
|
6231
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6236
|
+
var __defProp$m = Object.defineProperty;
|
|
6237
|
+
var __getOwnPropDesc$m = Object.getOwnPropertyDescriptor;
|
|
6238
|
+
var __decorateClass$m = (decorators, target, key, kind) => {
|
|
6239
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$m(target, key) : target;
|
|
6232
6240
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6233
|
-
if (kind && result) __defProp$
|
|
6241
|
+
if (kind && result) __defProp$m(target, key, result);
|
|
6234
6242
|
return result;
|
|
6235
6243
|
};
|
|
6236
6244
|
class DialogBody extends FASTElement {
|
|
@@ -6239,7 +6247,7 @@ class DialogBody extends FASTElement {
|
|
|
6239
6247
|
this.noTitleAction = false;
|
|
6240
6248
|
}
|
|
6241
6249
|
}
|
|
6242
|
-
__decorateClass$
|
|
6250
|
+
__decorateClass$m([attr({
|
|
6243
6251
|
mode: "boolean",
|
|
6244
6252
|
attribute: "no-title-action"
|
|
6245
6253
|
})], DialogBody.prototype, "noTitleAction", 2);
|
|
@@ -6258,20 +6266,20 @@ const dismissed16Regular = html.partial(`
|
|
|
6258
6266
|
fill="currentColor"
|
|
6259
6267
|
></path>
|
|
6260
6268
|
</svg>`);
|
|
6261
|
-
const template$
|
|
6269
|
+
const template$r = 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>`;
|
|
6262
6270
|
|
|
6263
|
-
const styles$
|
|
6271
|
+
const styles$q = css`
|
|
6264
6272
|
${display("grid")}
|
|
6265
6273
|
|
|
6266
6274
|
: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}}}`;
|
|
6267
6275
|
|
|
6268
|
-
const definition$
|
|
6276
|
+
const definition$r = DialogBody.compose({
|
|
6269
6277
|
name: `${FluentDesignSystem.prefix}-dialog-body`,
|
|
6270
|
-
template: template$
|
|
6271
|
-
styles: styles$
|
|
6278
|
+
template: template$r,
|
|
6279
|
+
styles: styles$q
|
|
6272
6280
|
});
|
|
6273
6281
|
|
|
6274
|
-
definition$
|
|
6282
|
+
definition$r.define(FluentDesignSystem.registry);
|
|
6275
6283
|
|
|
6276
6284
|
const DividerRole = {
|
|
6277
6285
|
/**
|
|
@@ -6285,12 +6293,12 @@ const DividerRole = {
|
|
|
6285
6293
|
};
|
|
6286
6294
|
const DividerOrientation = Orientation;
|
|
6287
6295
|
|
|
6288
|
-
var __defProp$
|
|
6289
|
-
var __getOwnPropDesc$
|
|
6290
|
-
var __decorateClass$
|
|
6291
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6296
|
+
var __defProp$l = Object.defineProperty;
|
|
6297
|
+
var __getOwnPropDesc$l = Object.getOwnPropertyDescriptor;
|
|
6298
|
+
var __decorateClass$l = (decorators, target, key, kind) => {
|
|
6299
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$l(target, key) : target;
|
|
6292
6300
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6293
|
-
if (kind && result) __defProp$
|
|
6301
|
+
if (kind && result) __defProp$l(target, key, result);
|
|
6294
6302
|
return result;
|
|
6295
6303
|
};
|
|
6296
6304
|
class BaseDivider extends FASTElement {
|
|
@@ -6342,8 +6350,8 @@ class BaseDivider extends FASTElement {
|
|
|
6342
6350
|
}
|
|
6343
6351
|
}
|
|
6344
6352
|
}
|
|
6345
|
-
__decorateClass$
|
|
6346
|
-
__decorateClass$
|
|
6353
|
+
__decorateClass$l([attr], BaseDivider.prototype, "role", 2);
|
|
6354
|
+
__decorateClass$l([attr], BaseDivider.prototype, "orientation", 2);
|
|
6347
6355
|
class Divider extends BaseDivider {
|
|
6348
6356
|
constructor() {
|
|
6349
6357
|
super(...arguments);
|
|
@@ -6384,32 +6392,32 @@ class Divider extends BaseDivider {
|
|
|
6384
6392
|
toggleState(this.elementInternals, "inset", next);
|
|
6385
6393
|
}
|
|
6386
6394
|
}
|
|
6387
|
-
__decorateClass$
|
|
6395
|
+
__decorateClass$l([attr({
|
|
6388
6396
|
attribute: "align-content"
|
|
6389
6397
|
})], Divider.prototype, "alignContent", 2);
|
|
6390
|
-
__decorateClass$
|
|
6391
|
-
__decorateClass$
|
|
6398
|
+
__decorateClass$l([attr], Divider.prototype, "appearance", 2);
|
|
6399
|
+
__decorateClass$l([attr({
|
|
6392
6400
|
mode: "boolean"
|
|
6393
6401
|
})], Divider.prototype, "inset", 2);
|
|
6394
6402
|
|
|
6395
6403
|
function dividerTemplate() {
|
|
6396
6404
|
return html`<slot></slot>`;
|
|
6397
6405
|
}
|
|
6398
|
-
const template$
|
|
6406
|
+
const template$q = dividerTemplate();
|
|
6399
6407
|
|
|
6400
|
-
const styles$
|
|
6408
|
+
const styles$p = css`
|
|
6401
6409
|
${display("flex")}
|
|
6402
6410
|
|
|
6403
6411
|
: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`
|
|
6404
6412
|
: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}`));
|
|
6405
6413
|
|
|
6406
|
-
const definition$
|
|
6414
|
+
const definition$q = Divider.compose({
|
|
6407
6415
|
name: `${FluentDesignSystem.prefix}-divider`,
|
|
6408
|
-
template: template$
|
|
6409
|
-
styles: styles$
|
|
6416
|
+
template: template$q,
|
|
6417
|
+
styles: styles$p
|
|
6410
6418
|
});
|
|
6411
6419
|
|
|
6412
|
-
definition$
|
|
6420
|
+
definition$q.define(FluentDesignSystem.registry);
|
|
6413
6421
|
|
|
6414
6422
|
const DrawerPosition = {
|
|
6415
6423
|
start: "start",
|
|
@@ -6427,12 +6435,12 @@ const DrawerType = {
|
|
|
6427
6435
|
inline: "inline"
|
|
6428
6436
|
};
|
|
6429
6437
|
|
|
6430
|
-
var __defProp$
|
|
6431
|
-
var __getOwnPropDesc$
|
|
6432
|
-
var __decorateClass$
|
|
6433
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6438
|
+
var __defProp$k = Object.defineProperty;
|
|
6439
|
+
var __getOwnPropDesc$k = Object.getOwnPropertyDescriptor;
|
|
6440
|
+
var __decorateClass$k = (decorators, target, key, kind) => {
|
|
6441
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$k(target, key) : target;
|
|
6434
6442
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6435
|
-
if (kind && result) __defProp$
|
|
6443
|
+
if (kind && result) __defProp$k(target, key, result);
|
|
6436
6444
|
return result;
|
|
6437
6445
|
};
|
|
6438
6446
|
class Drawer extends FASTElement {
|
|
@@ -6502,20 +6510,20 @@ class Drawer extends FASTElement {
|
|
|
6502
6510
|
return true;
|
|
6503
6511
|
}
|
|
6504
6512
|
}
|
|
6505
|
-
__decorateClass$
|
|
6506
|
-
__decorateClass$
|
|
6513
|
+
__decorateClass$k([attr], Drawer.prototype, "type", 2);
|
|
6514
|
+
__decorateClass$k([attr({
|
|
6507
6515
|
attribute: "aria-labelledby"
|
|
6508
6516
|
})], Drawer.prototype, "ariaLabelledby", 2);
|
|
6509
|
-
__decorateClass$
|
|
6517
|
+
__decorateClass$k([attr({
|
|
6510
6518
|
attribute: "aria-describedby"
|
|
6511
6519
|
})], Drawer.prototype, "ariaDescribedby", 2);
|
|
6512
|
-
__decorateClass$
|
|
6513
|
-
__decorateClass$
|
|
6520
|
+
__decorateClass$k([attr], Drawer.prototype, "position", 2);
|
|
6521
|
+
__decorateClass$k([attr({
|
|
6514
6522
|
attribute: "size"
|
|
6515
6523
|
})], Drawer.prototype, "size", 2);
|
|
6516
|
-
__decorateClass$
|
|
6524
|
+
__decorateClass$k([observable], Drawer.prototype, "dialog", 2);
|
|
6517
6525
|
|
|
6518
|
-
const styles$
|
|
6526
|
+
const styles$o = css`
|
|
6519
6527
|
${display("block")}
|
|
6520
6528
|
|
|
6521
6529
|
: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}}}`;
|
|
@@ -6523,34 +6531,34 @@ const styles$n = css`
|
|
|
6523
6531
|
function drawerTemplate() {
|
|
6524
6532
|
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>`;
|
|
6525
6533
|
}
|
|
6526
|
-
const template$
|
|
6534
|
+
const template$p = drawerTemplate();
|
|
6527
6535
|
|
|
6528
|
-
const definition$
|
|
6536
|
+
const definition$p = Drawer.compose({
|
|
6529
6537
|
name: `${FluentDesignSystem.prefix}-drawer`,
|
|
6530
|
-
template: template$
|
|
6531
|
-
styles: styles$
|
|
6538
|
+
template: template$p,
|
|
6539
|
+
styles: styles$o
|
|
6532
6540
|
});
|
|
6533
6541
|
|
|
6534
|
-
definition$
|
|
6542
|
+
definition$p.define(FluentDesignSystem.registry);
|
|
6535
6543
|
|
|
6536
6544
|
class DrawerBody extends FASTElement {}
|
|
6537
6545
|
|
|
6538
|
-
const styles$
|
|
6546
|
+
const styles$n = css`
|
|
6539
6547
|
${display("grid")}
|
|
6540
6548
|
: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}}`;
|
|
6541
6549
|
|
|
6542
6550
|
function drawerBodyTemplate() {
|
|
6543
6551
|
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>`;
|
|
6544
6552
|
}
|
|
6545
|
-
const template$
|
|
6553
|
+
const template$o = drawerBodyTemplate();
|
|
6546
6554
|
|
|
6547
|
-
const definition$
|
|
6555
|
+
const definition$o = DrawerBody.compose({
|
|
6548
6556
|
name: `${FluentDesignSystem.prefix}-drawer-body`,
|
|
6549
|
-
template: template$
|
|
6550
|
-
styles: styles$
|
|
6557
|
+
template: template$o,
|
|
6558
|
+
styles: styles$n
|
|
6551
6559
|
});
|
|
6552
6560
|
|
|
6553
|
-
definition$
|
|
6561
|
+
definition$o.define(FluentDesignSystem.registry);
|
|
6554
6562
|
|
|
6555
6563
|
const LabelPosition = {
|
|
6556
6564
|
above: "above",
|
|
@@ -6571,12 +6579,12 @@ const ValidationFlags = {
|
|
|
6571
6579
|
valid: "valid"
|
|
6572
6580
|
};
|
|
6573
6581
|
|
|
6574
|
-
var __defProp$
|
|
6575
|
-
var __getOwnPropDesc$
|
|
6576
|
-
var __decorateClass$
|
|
6577
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6582
|
+
var __defProp$j = Object.defineProperty;
|
|
6583
|
+
var __getOwnPropDesc$j = Object.getOwnPropertyDescriptor;
|
|
6584
|
+
var __decorateClass$j = (decorators, target, key, kind) => {
|
|
6585
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$j(target, key) : target;
|
|
6578
6586
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6579
|
-
if (kind && result) __defProp$
|
|
6587
|
+
if (kind && result) __defProp$j(target, key, result);
|
|
6580
6588
|
return result;
|
|
6581
6589
|
};
|
|
6582
6590
|
class BaseField extends FASTElement {
|
|
@@ -6744,17 +6752,17 @@ class BaseField extends FASTElement {
|
|
|
6744
6752
|
}
|
|
6745
6753
|
}
|
|
6746
6754
|
}
|
|
6747
|
-
__decorateClass$
|
|
6748
|
-
__decorateClass$
|
|
6749
|
-
__decorateClass$
|
|
6750
|
-
__decorateClass$
|
|
6755
|
+
__decorateClass$j([observable], BaseField.prototype, "labelSlot", 2);
|
|
6756
|
+
__decorateClass$j([observable], BaseField.prototype, "messageSlot", 2);
|
|
6757
|
+
__decorateClass$j([observable], BaseField.prototype, "slottedInputs", 2);
|
|
6758
|
+
__decorateClass$j([observable], BaseField.prototype, "input", 2);
|
|
6751
6759
|
class Field extends BaseField {
|
|
6752
6760
|
constructor() {
|
|
6753
6761
|
super(...arguments);
|
|
6754
6762
|
this.labelPosition = LabelPosition.above;
|
|
6755
6763
|
}
|
|
6756
6764
|
}
|
|
6757
|
-
__decorateClass$
|
|
6765
|
+
__decorateClass$j([attr({
|
|
6758
6766
|
attribute: "label-position"
|
|
6759
6767
|
})], Field.prototype, "labelPosition", 2);
|
|
6760
6768
|
|
|
@@ -6771,12 +6779,12 @@ const typeMismatchState = css.partial`:is([state--${ValidationFlags.typeMismatch
|
|
|
6771
6779
|
const validState = css.partial`:is([state-${ValidationFlags.valid}], :state(${ValidationFlags.valid}))`;
|
|
6772
6780
|
const valueMissingState = css.partial`:is([state--${ValidationFlags.valueMissing}], :state(${ValidationFlags.valueMissing}))`;
|
|
6773
6781
|
const hasMessageState = css.partial`:is([state--has-message], :state(has-message))`;
|
|
6774
|
-
const styles$
|
|
6782
|
+
const styles$m = css`
|
|
6775
6783
|
${display("inline-grid")}
|
|
6776
6784
|
|
|
6777
6785
|
: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}`;
|
|
6778
6786
|
|
|
6779
|
-
const template$
|
|
6787
|
+
const template$n = 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({
|
|
6780
6788
|
property: "slottedInputs",
|
|
6781
6789
|
attributes: true,
|
|
6782
6790
|
attributeFilter: ["disabled", "required", "readonly"],
|
|
@@ -6788,23 +6796,23 @@ const template$m = html`<template @click="${(x, c) => x.clickHandler(c.event)}"
|
|
|
6788
6796
|
filter: elements("[flag]")
|
|
6789
6797
|
})}></slot></template>`;
|
|
6790
6798
|
|
|
6791
|
-
const definition$
|
|
6799
|
+
const definition$n = Field.compose({
|
|
6792
6800
|
name: `${FluentDesignSystem.prefix}-field`,
|
|
6793
|
-
template: template$
|
|
6794
|
-
styles: styles$
|
|
6801
|
+
template: template$n,
|
|
6802
|
+
styles: styles$m,
|
|
6795
6803
|
shadowOptions: {
|
|
6796
6804
|
delegatesFocus: true
|
|
6797
6805
|
}
|
|
6798
6806
|
});
|
|
6799
6807
|
|
|
6800
|
-
definition$
|
|
6808
|
+
definition$n.define(FluentDesignSystem.registry);
|
|
6801
6809
|
|
|
6802
|
-
var __defProp$
|
|
6803
|
-
var __getOwnPropDesc$
|
|
6804
|
-
var __decorateClass$
|
|
6805
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6810
|
+
var __defProp$i = Object.defineProperty;
|
|
6811
|
+
var __getOwnPropDesc$i = Object.getOwnPropertyDescriptor;
|
|
6812
|
+
var __decorateClass$i = (decorators, target, key, kind) => {
|
|
6813
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$i(target, key) : target;
|
|
6806
6814
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6807
|
-
if (kind && result) __defProp$
|
|
6815
|
+
if (kind && result) __defProp$i(target, key, result);
|
|
6808
6816
|
return result;
|
|
6809
6817
|
};
|
|
6810
6818
|
class Image extends FASTElement {
|
|
@@ -6869,37 +6877,37 @@ class Image extends FASTElement {
|
|
|
6869
6877
|
}
|
|
6870
6878
|
}
|
|
6871
6879
|
}
|
|
6872
|
-
__decorateClass$
|
|
6880
|
+
__decorateClass$i([attr({
|
|
6873
6881
|
mode: "boolean"
|
|
6874
6882
|
})], Image.prototype, "block", 2);
|
|
6875
|
-
__decorateClass$
|
|
6883
|
+
__decorateClass$i([attr({
|
|
6876
6884
|
mode: "boolean"
|
|
6877
6885
|
})], Image.prototype, "bordered", 2);
|
|
6878
|
-
__decorateClass$
|
|
6886
|
+
__decorateClass$i([attr({
|
|
6879
6887
|
mode: "boolean"
|
|
6880
6888
|
})], Image.prototype, "shadow", 2);
|
|
6881
|
-
__decorateClass$
|
|
6882
|
-
__decorateClass$
|
|
6889
|
+
__decorateClass$i([attr], Image.prototype, "fit", 2);
|
|
6890
|
+
__decorateClass$i([attr], Image.prototype, "shape", 2);
|
|
6883
6891
|
|
|
6884
|
-
const template$
|
|
6892
|
+
const template$m = html`<slot></slot>`;
|
|
6885
6893
|
|
|
6886
|
-
const styles$
|
|
6894
|
+
const styles$l = css`
|
|
6887
6895
|
:host{contain:content}:host ::slotted(img){box-sizing:border-box;min-height:8px;min-width:8px;display:inline-block}:host(:is([state--block],:state(block))) ::slotted(img){width:100%;height:auto}:host(:is([state--bordered],:state(bordered))) ::slotted(img){border:${strokeWidthThin} solid ${colorNeutralStroke2}}:host(:is([state--fit-none],:state(fit-none))) ::slotted(img){object-fit:none;object-position:top left;height:100%;width:100%}:host(:is([state--fit-center],:state(fit-center))) ::slotted(img){object-fit:none;object-position:center;height:100%;width:100%}:host(:is([state--fit-contain],:state(fit-contain))) ::slotted(img){object-fit:contain;object-position:center;height:100%;width:100%}:host(:is([state--fit-cover],:state(fit-cover))) ::slotted(img){object-fit:cover;object-position:center;height:100%;width:100%}:host(:is([state--shadowed],:state(shadowed))) ::slotted(img){box-shadow:${shadow4}}:host(${circularState}) ::slotted(img){border-radius:${borderRadiusCircular}}:host(${roundedState}) ::slotted(img){border-radius:${borderRadiusMedium}}`;
|
|
6888
6896
|
|
|
6889
|
-
const definition$
|
|
6897
|
+
const definition$m = Image.compose({
|
|
6890
6898
|
name: `${FluentDesignSystem.prefix}-image`,
|
|
6891
|
-
template: template$
|
|
6892
|
-
styles: styles$
|
|
6899
|
+
template: template$m,
|
|
6900
|
+
styles: styles$l
|
|
6893
6901
|
});
|
|
6894
6902
|
|
|
6895
|
-
definition$
|
|
6903
|
+
definition$m.define(FluentDesignSystem.registry);
|
|
6896
6904
|
|
|
6897
|
-
var __defProp$
|
|
6898
|
-
var __getOwnPropDesc$
|
|
6899
|
-
var __decorateClass$
|
|
6900
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6905
|
+
var __defProp$h = Object.defineProperty;
|
|
6906
|
+
var __getOwnPropDesc$h = Object.getOwnPropertyDescriptor;
|
|
6907
|
+
var __decorateClass$h = (decorators, target, key, kind) => {
|
|
6908
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$h(target, key) : target;
|
|
6901
6909
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6902
|
-
if (kind && result) __defProp$
|
|
6910
|
+
if (kind && result) __defProp$h(target, key, result);
|
|
6903
6911
|
return result;
|
|
6904
6912
|
};
|
|
6905
6913
|
class Label extends FASTElement {
|
|
@@ -6949,16 +6957,16 @@ class Label extends FASTElement {
|
|
|
6949
6957
|
toggleState(this.elementInternals, "disabled", next);
|
|
6950
6958
|
}
|
|
6951
6959
|
}
|
|
6952
|
-
__decorateClass$
|
|
6953
|
-
__decorateClass$
|
|
6954
|
-
__decorateClass$
|
|
6960
|
+
__decorateClass$h([attr], Label.prototype, "size", 2);
|
|
6961
|
+
__decorateClass$h([attr], Label.prototype, "weight", 2);
|
|
6962
|
+
__decorateClass$h([attr({
|
|
6955
6963
|
mode: "boolean"
|
|
6956
6964
|
})], Label.prototype, "disabled", 2);
|
|
6957
|
-
__decorateClass$
|
|
6965
|
+
__decorateClass$h([attr({
|
|
6958
6966
|
mode: "boolean"
|
|
6959
6967
|
})], Label.prototype, "required", 2);
|
|
6960
6968
|
|
|
6961
|
-
const styles$
|
|
6969
|
+
const styles$k = css`
|
|
6962
6970
|
${display("inline-flex")}
|
|
6963
6971
|
|
|
6964
6972
|
: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(${largeState}),:host(:is([state--semibold],:state(semibold))){font-weight:${fontWeightSemibold}}:host(:is([state--disabled],:state(disabled))),:host(:is([state--disabled],:state(disabled))) .asterisk{color:${colorNeutralForegroundDisabled}}`;
|
|
@@ -6966,22 +6974,22 @@ const styles$j = css`
|
|
|
6966
6974
|
function labelTemplate() {
|
|
6967
6975
|
return html`<slot></slot><span part="asterisk" class="asterisk" ?hidden="${x => !x.required}">*</span>`;
|
|
6968
6976
|
}
|
|
6969
|
-
const template$
|
|
6977
|
+
const template$l = labelTemplate();
|
|
6970
6978
|
|
|
6971
|
-
const definition$
|
|
6979
|
+
const definition$l = Label.compose({
|
|
6972
6980
|
name: `${FluentDesignSystem.prefix}-label`,
|
|
6973
|
-
template: template$
|
|
6974
|
-
styles: styles$
|
|
6981
|
+
template: template$l,
|
|
6982
|
+
styles: styles$k
|
|
6975
6983
|
});
|
|
6976
6984
|
|
|
6977
|
-
definition$
|
|
6985
|
+
definition$l.define(FluentDesignSystem.registry);
|
|
6978
6986
|
|
|
6979
|
-
var __defProp$
|
|
6980
|
-
var __getOwnPropDesc$
|
|
6981
|
-
var __decorateClass$
|
|
6982
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6987
|
+
var __defProp$g = Object.defineProperty;
|
|
6988
|
+
var __getOwnPropDesc$g = Object.getOwnPropertyDescriptor;
|
|
6989
|
+
var __decorateClass$g = (decorators, target, key, kind) => {
|
|
6990
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$g(target, key) : target;
|
|
6983
6991
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6984
|
-
if (kind && result) __defProp$
|
|
6992
|
+
if (kind && result) __defProp$g(target, key, result);
|
|
6985
6993
|
return result;
|
|
6986
6994
|
};
|
|
6987
6995
|
class Link extends BaseAnchor {
|
|
@@ -7011,12 +7019,12 @@ class Link extends BaseAnchor {
|
|
|
7011
7019
|
toggleState(this.elementInternals, "inline", next);
|
|
7012
7020
|
}
|
|
7013
7021
|
}
|
|
7014
|
-
__decorateClass$
|
|
7015
|
-
__decorateClass$
|
|
7022
|
+
__decorateClass$g([attr], Link.prototype, "appearance", 2);
|
|
7023
|
+
__decorateClass$g([attr({
|
|
7016
7024
|
mode: "boolean"
|
|
7017
7025
|
})], Link.prototype, "inline", 2);
|
|
7018
7026
|
|
|
7019
|
-
const styles$
|
|
7027
|
+
const styles$j = css`
|
|
7020
7028
|
${display("inline")}
|
|
7021
7029
|
|
|
7022
7030
|
:host{position:relative;box-sizing:border-box;background-color:transparent;color:${colorBrandForegroundLink};cursor:pointer;font-family:${fontFamilyBase};font-size:${fontSizeBase300};font-weight:${fontWeightRegular};margin:0;padding:0;overflow:inherit;text-align:left;text-decoration:none;text-decoration-thinkness:${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(:is([state--inline],:state(inline))){font:inherit;text-decoration:underline}:host(:not([href])){color:inherit;text-decoration:none}::slotted(a){position:absolute;inset:0}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
@@ -7025,19 +7033,19 @@ const styles$i = css`
|
|
|
7025
7033
|
function anchorTemplate() {
|
|
7026
7034
|
return html`<template tabindex="0" @click="${(x, c) => x.clickHandler(c.event)}" @keydown="${(x, c) => x.keydownHandler(c.event)}"><slot></slot></template>`;
|
|
7027
7035
|
}
|
|
7028
|
-
const template$
|
|
7036
|
+
const template$k = anchorTemplate();
|
|
7029
7037
|
|
|
7030
|
-
const definition$
|
|
7038
|
+
const definition$k = Link.compose({
|
|
7031
7039
|
name: `${FluentDesignSystem.prefix}-link`,
|
|
7032
|
-
template: template$
|
|
7033
|
-
styles: styles$
|
|
7040
|
+
template: template$k,
|
|
7041
|
+
styles: styles$j
|
|
7034
7042
|
});
|
|
7035
7043
|
|
|
7036
|
-
definition$
|
|
7044
|
+
definition$k.define(FluentDesignSystem.registry);
|
|
7037
7045
|
|
|
7038
7046
|
class MenuButton extends Button {}
|
|
7039
7047
|
|
|
7040
|
-
const template$
|
|
7048
|
+
const template$j = buttonTemplate$1({
|
|
7041
7049
|
end: html.partial( /* html */
|
|
7042
7050
|
`
|
|
7043
7051
|
<svg slot="end" fill="currentColor" aria-hidden="true" width="1em" height="1em" viewBox="0 0 20 20" xmlns="http://www.w3.org/2000/svg">
|
|
@@ -7046,13 +7054,13 @@ const template$i = buttonTemplate$1({
|
|
|
7046
7054
|
`)
|
|
7047
7055
|
});
|
|
7048
7056
|
|
|
7049
|
-
const definition$
|
|
7057
|
+
const definition$j = MenuButton.compose({
|
|
7050
7058
|
name: `${FluentDesignSystem.prefix}-menu-button`,
|
|
7051
|
-
template: template$
|
|
7052
|
-
styles: styles$
|
|
7059
|
+
template: template$j,
|
|
7060
|
+
styles: styles$y
|
|
7053
7061
|
});
|
|
7054
7062
|
|
|
7055
|
-
definition$
|
|
7063
|
+
definition$j.define(FluentDesignSystem.registry);
|
|
7056
7064
|
|
|
7057
7065
|
const MenuItemRole = {
|
|
7058
7066
|
/**
|
|
@@ -7074,12 +7082,12 @@ const MenuItemRole = {
|
|
|
7074
7082
|
[MenuItemRole.menuitemradio]: "menuitemradio"
|
|
7075
7083
|
});
|
|
7076
7084
|
|
|
7077
|
-
var __defProp$
|
|
7078
|
-
var __getOwnPropDesc$
|
|
7079
|
-
var __decorateClass$
|
|
7080
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7085
|
+
var __defProp$f = Object.defineProperty;
|
|
7086
|
+
var __getOwnPropDesc$f = Object.getOwnPropertyDescriptor;
|
|
7087
|
+
var __decorateClass$f = (decorators, target, key, kind) => {
|
|
7088
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$f(target, key) : target;
|
|
7081
7089
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7082
|
-
if (kind && result) __defProp$
|
|
7090
|
+
if (kind && result) __defProp$f(target, key, result);
|
|
7083
7091
|
return result;
|
|
7084
7092
|
};
|
|
7085
7093
|
const menuFilter = () => value => value.nodeType === 1 && value.elementInternals.role === "menu";
|
|
@@ -7267,22 +7275,22 @@ class MenuItem extends FASTElement {
|
|
|
7267
7275
|
this.elementInternals.ariaChecked = this.role !== MenuItemRole.menuitem ? `${!!this.checked}` : null;
|
|
7268
7276
|
}
|
|
7269
7277
|
}
|
|
7270
|
-
__decorateClass$
|
|
7278
|
+
__decorateClass$f([attr({
|
|
7271
7279
|
mode: "boolean"
|
|
7272
7280
|
})], MenuItem.prototype, "disabled", 2);
|
|
7273
|
-
__decorateClass$
|
|
7274
|
-
__decorateClass$
|
|
7281
|
+
__decorateClass$f([attr], MenuItem.prototype, "role", 2);
|
|
7282
|
+
__decorateClass$f([attr({
|
|
7275
7283
|
mode: "boolean"
|
|
7276
7284
|
})], MenuItem.prototype, "checked", 2);
|
|
7277
|
-
__decorateClass$
|
|
7285
|
+
__decorateClass$f([attr({
|
|
7278
7286
|
mode: "boolean"
|
|
7279
7287
|
})], MenuItem.prototype, "hidden", 2);
|
|
7280
|
-
__decorateClass$
|
|
7281
|
-
__decorateClass$
|
|
7288
|
+
__decorateClass$f([observable], MenuItem.prototype, "slottedSubmenu", 2);
|
|
7289
|
+
__decorateClass$f([observable], MenuItem.prototype, "submenu", 2);
|
|
7282
7290
|
applyMixins(MenuItem, StartEnd);
|
|
7283
7291
|
|
|
7284
7292
|
const submenuState = css.partial`:is([state--submenu], :state(submenu))`;
|
|
7285
|
-
const styles$
|
|
7293
|
+
const styles$i = css`
|
|
7286
7294
|
${display("grid")}
|
|
7287
7295
|
|
|
7288
7296
|
: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]){inset-area:inline-end span-block-end;margin:0;max-height:var(--menu-max-height,auto);position:absolute;position-anchor:--menu-trigger;position-try-options:flip-inline,inset-area(block-start);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`
|
|
@@ -7296,25 +7304,25 @@ function menuItemTemplate(options = {}) {
|
|
|
7296
7304
|
filter: menuFilter()
|
|
7297
7305
|
})}></slot></template>`;
|
|
7298
7306
|
}
|
|
7299
|
-
const template$
|
|
7307
|
+
const template$i = menuItemTemplate({
|
|
7300
7308
|
indicator: Checkmark16Filled,
|
|
7301
7309
|
submenuGlyph: chevronRight16Filled
|
|
7302
7310
|
});
|
|
7303
7311
|
|
|
7304
|
-
const definition$
|
|
7312
|
+
const definition$i = MenuItem.compose({
|
|
7305
7313
|
name: `${FluentDesignSystem.prefix}-menu-item`,
|
|
7306
|
-
template: template$
|
|
7307
|
-
styles: styles$
|
|
7314
|
+
template: template$i,
|
|
7315
|
+
styles: styles$i
|
|
7308
7316
|
});
|
|
7309
7317
|
|
|
7310
|
-
definition$
|
|
7318
|
+
definition$i.define(FluentDesignSystem.registry);
|
|
7311
7319
|
|
|
7312
|
-
var __defProp$
|
|
7313
|
-
var __getOwnPropDesc$
|
|
7314
|
-
var __decorateClass$
|
|
7315
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7320
|
+
var __defProp$e = Object.defineProperty;
|
|
7321
|
+
var __getOwnPropDesc$e = Object.getOwnPropertyDescriptor;
|
|
7322
|
+
var __decorateClass$e = (decorators, target, key, kind) => {
|
|
7323
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$e(target, key) : target;
|
|
7316
7324
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7317
|
-
if (kind && result) __defProp$
|
|
7325
|
+
if (kind && result) __defProp$e(target, key, result);
|
|
7318
7326
|
return result;
|
|
7319
7327
|
};
|
|
7320
7328
|
const _MenuList = class _MenuList extends FASTElement {
|
|
@@ -7530,10 +7538,10 @@ const _MenuList = class _MenuList extends FASTElement {
|
|
|
7530
7538
|
}
|
|
7531
7539
|
};
|
|
7532
7540
|
_MenuList.focusableElementRoles = MenuItemRole;
|
|
7533
|
-
__decorateClass$
|
|
7541
|
+
__decorateClass$e([observable], _MenuList.prototype, "items", 2);
|
|
7534
7542
|
let MenuList = _MenuList;
|
|
7535
7543
|
|
|
7536
|
-
const styles$
|
|
7544
|
+
const styles$h = css`
|
|
7537
7545
|
${display("flex")}
|
|
7538
7546
|
|
|
7539
7547
|
: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}`;
|
|
@@ -7541,22 +7549,22 @@ const styles$g = css`
|
|
|
7541
7549
|
function menuTemplate$1() {
|
|
7542
7550
|
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>`;
|
|
7543
7551
|
}
|
|
7544
|
-
const template$
|
|
7552
|
+
const template$h = menuTemplate$1();
|
|
7545
7553
|
|
|
7546
|
-
const definition$
|
|
7554
|
+
const definition$h = MenuList.compose({
|
|
7547
7555
|
name: `${FluentDesignSystem.prefix}-menu-list`,
|
|
7548
|
-
template: template$
|
|
7549
|
-
styles: styles$
|
|
7556
|
+
template: template$h,
|
|
7557
|
+
styles: styles$h
|
|
7550
7558
|
});
|
|
7551
7559
|
|
|
7552
|
-
definition$
|
|
7560
|
+
definition$h.define(FluentDesignSystem.registry);
|
|
7553
7561
|
|
|
7554
|
-
var __defProp$
|
|
7555
|
-
var __getOwnPropDesc$
|
|
7556
|
-
var __decorateClass$
|
|
7557
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7562
|
+
var __defProp$d = Object.defineProperty;
|
|
7563
|
+
var __getOwnPropDesc$d = Object.getOwnPropertyDescriptor;
|
|
7564
|
+
var __decorateClass$d = (decorators, target, key, kind) => {
|
|
7565
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$d(target, key) : target;
|
|
7558
7566
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7559
|
-
if (kind && result) __defProp$
|
|
7567
|
+
if (kind && result) __defProp$d(target, key, result);
|
|
7560
7568
|
return result;
|
|
7561
7569
|
};
|
|
7562
7570
|
class Menu extends FASTElement {
|
|
@@ -7840,26 +7848,26 @@ class Menu extends FASTElement {
|
|
|
7840
7848
|
}
|
|
7841
7849
|
}
|
|
7842
7850
|
}
|
|
7843
|
-
__decorateClass$
|
|
7851
|
+
__decorateClass$d([attr({
|
|
7844
7852
|
attribute: "open-on-hover",
|
|
7845
7853
|
mode: "boolean"
|
|
7846
7854
|
})], Menu.prototype, "openOnHover", 2);
|
|
7847
|
-
__decorateClass$
|
|
7855
|
+
__decorateClass$d([attr({
|
|
7848
7856
|
attribute: "open-on-context",
|
|
7849
7857
|
mode: "boolean"
|
|
7850
7858
|
})], Menu.prototype, "openOnContext", 2);
|
|
7851
|
-
__decorateClass$
|
|
7859
|
+
__decorateClass$d([attr({
|
|
7852
7860
|
attribute: "close-on-scroll",
|
|
7853
7861
|
mode: "boolean"
|
|
7854
7862
|
})], Menu.prototype, "closeOnScroll", 2);
|
|
7855
|
-
__decorateClass$
|
|
7863
|
+
__decorateClass$d([attr({
|
|
7856
7864
|
attribute: "persist-on-item-click",
|
|
7857
7865
|
mode: "boolean"
|
|
7858
7866
|
})], Menu.prototype, "persistOnItemClick", 2);
|
|
7859
|
-
__decorateClass$
|
|
7860
|
-
__decorateClass$
|
|
7867
|
+
__decorateClass$d([observable], Menu.prototype, "slottedMenuList", 2);
|
|
7868
|
+
__decorateClass$d([observable], Menu.prototype, "slottedTriggers", 2);
|
|
7861
7869
|
|
|
7862
|
-
const styles$
|
|
7870
|
+
const styles$g = css`
|
|
7863
7871
|
${display("inline-block")}
|
|
7864
7872
|
|
|
7865
7873
|
::slotted([slot='trigger']){anchor-name:--menu-trigger}::slotted([popover]){inset-area:block-end span-inline-end;margin:0;max-height:var(--menu-max-height,auto);position-anchor:--menu-trigger;position-try-options:flip-block;position:absolute;z-index:1}::slotted([popover]:popover-open){inset:unset}::slotted([popover]:not(:popover-open)){display:none}`;
|
|
@@ -7873,22 +7881,22 @@ function menuTemplate() {
|
|
|
7873
7881
|
filter: elements()
|
|
7874
7882
|
})}></slot></template>`;
|
|
7875
7883
|
}
|
|
7876
|
-
const template$
|
|
7884
|
+
const template$g = menuTemplate();
|
|
7877
7885
|
|
|
7878
|
-
const definition$
|
|
7886
|
+
const definition$g = Menu.compose({
|
|
7879
7887
|
name: `${FluentDesignSystem.prefix}-menu`,
|
|
7880
|
-
template: template$
|
|
7881
|
-
styles: styles$
|
|
7888
|
+
template: template$g,
|
|
7889
|
+
styles: styles$g
|
|
7882
7890
|
});
|
|
7883
7891
|
|
|
7884
|
-
definition$
|
|
7892
|
+
definition$g.define(FluentDesignSystem.registry);
|
|
7885
7893
|
|
|
7886
|
-
var __defProp$
|
|
7887
|
-
var __getOwnPropDesc$
|
|
7888
|
-
var __decorateClass$
|
|
7889
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7894
|
+
var __defProp$c = Object.defineProperty;
|
|
7895
|
+
var __getOwnPropDesc$c = Object.getOwnPropertyDescriptor;
|
|
7896
|
+
var __decorateClass$c = (decorators, target, key, kind) => {
|
|
7897
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$c(target, key) : target;
|
|
7890
7898
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7891
|
-
if (kind && result) __defProp$
|
|
7899
|
+
if (kind && result) __defProp$c(target, key, result);
|
|
7892
7900
|
return result;
|
|
7893
7901
|
};
|
|
7894
7902
|
class MessageBar extends FASTElement {
|
|
@@ -7949,36 +7957,36 @@ class MessageBar extends FASTElement {
|
|
|
7949
7957
|
}
|
|
7950
7958
|
}
|
|
7951
7959
|
}
|
|
7952
|
-
__decorateClass$
|
|
7953
|
-
__decorateClass$
|
|
7954
|
-
__decorateClass$
|
|
7960
|
+
__decorateClass$c([attr], MessageBar.prototype, "shape", 2);
|
|
7961
|
+
__decorateClass$c([attr], MessageBar.prototype, "layout", 2);
|
|
7962
|
+
__decorateClass$c([attr], MessageBar.prototype, "intent", 2);
|
|
7955
7963
|
|
|
7956
|
-
const styles$
|
|
7964
|
+
const styles$f = css`
|
|
7957
7965
|
: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'
|
|
7958
7966
|
'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}`;
|
|
7959
7967
|
|
|
7960
7968
|
function messageBarTemplate() {
|
|
7961
7969
|
return html`<slot name="icon"></slot><div class="content"><slot></slot></div><div class="actions"><slot name="actions"></slot></div><slot name="dismiss"></slot>`;
|
|
7962
7970
|
}
|
|
7963
|
-
const template$
|
|
7971
|
+
const template$f = messageBarTemplate();
|
|
7964
7972
|
|
|
7965
|
-
const definition$
|
|
7973
|
+
const definition$f = MessageBar.compose({
|
|
7966
7974
|
name: `${FluentDesignSystem.prefix}-message-bar`,
|
|
7967
|
-
template: template$
|
|
7968
|
-
styles: styles$
|
|
7975
|
+
template: template$f,
|
|
7976
|
+
styles: styles$f,
|
|
7969
7977
|
shadowOptions: {
|
|
7970
7978
|
mode: FluentDesignSystem.shadowRootMode
|
|
7971
7979
|
}
|
|
7972
7980
|
});
|
|
7973
7981
|
|
|
7974
|
-
definition$
|
|
7982
|
+
definition$f.define(FluentDesignSystem.registry);
|
|
7975
7983
|
|
|
7976
|
-
var __defProp$
|
|
7977
|
-
var __getOwnPropDesc$
|
|
7978
|
-
var __decorateClass$
|
|
7979
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7984
|
+
var __defProp$b = Object.defineProperty;
|
|
7985
|
+
var __getOwnPropDesc$b = Object.getOwnPropertyDescriptor;
|
|
7986
|
+
var __decorateClass$b = (decorators, target, key, kind) => {
|
|
7987
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$b(target, key) : target;
|
|
7980
7988
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7981
|
-
if (kind && result) __defProp$
|
|
7989
|
+
if (kind && result) __defProp$b(target, key, result);
|
|
7982
7990
|
return result;
|
|
7983
7991
|
};
|
|
7984
7992
|
class BaseProgressBar extends FASTElement {
|
|
@@ -8041,19 +8049,19 @@ class BaseProgressBar extends FASTElement {
|
|
|
8041
8049
|
return range === 0 ? 0 : Math.fround((value - min) / range * 100);
|
|
8042
8050
|
}
|
|
8043
8051
|
}
|
|
8044
|
-
__decorateClass$
|
|
8052
|
+
__decorateClass$b([attr({
|
|
8045
8053
|
attribute: "validation-state"
|
|
8046
8054
|
})], BaseProgressBar.prototype, "validationState", 2);
|
|
8047
|
-
__decorateClass$
|
|
8055
|
+
__decorateClass$b([attr({
|
|
8048
8056
|
converter: nullableNumberConverter
|
|
8049
8057
|
})], BaseProgressBar.prototype, "value", 2);
|
|
8050
|
-
__decorateClass$
|
|
8058
|
+
__decorateClass$b([attr({
|
|
8051
8059
|
converter: nullableNumberConverter
|
|
8052
8060
|
})], BaseProgressBar.prototype, "min", 2);
|
|
8053
|
-
__decorateClass$
|
|
8061
|
+
__decorateClass$b([attr({
|
|
8054
8062
|
converter: nullableNumberConverter
|
|
8055
8063
|
})], BaseProgressBar.prototype, "max", 2);
|
|
8056
|
-
__decorateClass$
|
|
8064
|
+
__decorateClass$b([volatile], BaseProgressBar.prototype, "percentComplete", 1);
|
|
8057
8065
|
class ProgressBar extends BaseProgressBar {
|
|
8058
8066
|
/**
|
|
8059
8067
|
* Handles changes to thickness attribute custom states
|
|
@@ -8082,10 +8090,10 @@ class ProgressBar extends BaseProgressBar {
|
|
|
8082
8090
|
}
|
|
8083
8091
|
}
|
|
8084
8092
|
}
|
|
8085
|
-
__decorateClass$
|
|
8086
|
-
__decorateClass$
|
|
8093
|
+
__decorateClass$b([attr], ProgressBar.prototype, "thickness", 2);
|
|
8094
|
+
__decorateClass$b([attr], ProgressBar.prototype, "shape", 2);
|
|
8087
8095
|
|
|
8088
|
-
const styles$
|
|
8096
|
+
const styles$e = css`
|
|
8089
8097
|
${display("block")}
|
|
8090
8098
|
|
|
8091
8099
|
: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(
|
|
@@ -8096,15 +8104,15 @@ const styles$d = css`
|
|
|
8096
8104
|
function progressTemplate() {
|
|
8097
8105
|
return html`<div class="indicator" part="indicator" style="${x => typeof x.value === "number" ? `width: ${x.percentComplete}%` : void 0}"></div>`;
|
|
8098
8106
|
}
|
|
8099
|
-
const template$
|
|
8107
|
+
const template$e = progressTemplate();
|
|
8100
8108
|
|
|
8101
|
-
const definition$
|
|
8109
|
+
const definition$e = ProgressBar.compose({
|
|
8102
8110
|
name: `${FluentDesignSystem.prefix}-progress-bar`,
|
|
8103
|
-
template: template$
|
|
8104
|
-
styles: styles$
|
|
8111
|
+
template: template$e,
|
|
8112
|
+
styles: styles$e
|
|
8105
8113
|
});
|
|
8106
8114
|
|
|
8107
|
-
definition$
|
|
8115
|
+
definition$e.define(FluentDesignSystem.registry);
|
|
8108
8116
|
|
|
8109
8117
|
class Radio extends BaseCheckbox {
|
|
8110
8118
|
connectedCallback() {
|
|
@@ -8190,12 +8198,12 @@ function getRootActiveElement(element) {
|
|
|
8190
8198
|
|
|
8191
8199
|
const RadioGroupOrientation = Orientation;
|
|
8192
8200
|
|
|
8193
|
-
var __defProp$
|
|
8194
|
-
var __getOwnPropDesc$
|
|
8195
|
-
var __decorateClass$
|
|
8196
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8201
|
+
var __defProp$a = Object.defineProperty;
|
|
8202
|
+
var __getOwnPropDesc$a = Object.getOwnPropertyDescriptor;
|
|
8203
|
+
var __decorateClass$a = (decorators, target, key, kind) => {
|
|
8204
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$a(target, key) : target;
|
|
8197
8205
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8198
|
-
if (kind && result) __defProp$
|
|
8206
|
+
if (kind && result) __defProp$a(target, key, result);
|
|
8199
8207
|
return result;
|
|
8200
8208
|
};
|
|
8201
8209
|
class RadioGroup extends FASTElement {
|
|
@@ -8618,23 +8626,23 @@ class RadioGroup extends FASTElement {
|
|
|
8618
8626
|
* @public
|
|
8619
8627
|
*/
|
|
8620
8628
|
RadioGroup.formAssociated = true;
|
|
8621
|
-
__decorateClass$
|
|
8622
|
-
__decorateClass$
|
|
8629
|
+
__decorateClass$a([observable], RadioGroup.prototype, "checkedIndex", 2);
|
|
8630
|
+
__decorateClass$a([attr({
|
|
8623
8631
|
attribute: "disabled",
|
|
8624
8632
|
mode: "boolean"
|
|
8625
8633
|
})], RadioGroup.prototype, "disabled", 2);
|
|
8626
|
-
__decorateClass$
|
|
8634
|
+
__decorateClass$a([attr({
|
|
8627
8635
|
attribute: "value",
|
|
8628
8636
|
mode: "fromView"
|
|
8629
8637
|
})], RadioGroup.prototype, "initialValue", 2);
|
|
8630
|
-
__decorateClass$
|
|
8631
|
-
__decorateClass$
|
|
8632
|
-
__decorateClass$
|
|
8633
|
-
__decorateClass$
|
|
8638
|
+
__decorateClass$a([attr], RadioGroup.prototype, "name", 2);
|
|
8639
|
+
__decorateClass$a([attr], RadioGroup.prototype, "orientation", 2);
|
|
8640
|
+
__decorateClass$a([observable], RadioGroup.prototype, "radios", 2);
|
|
8641
|
+
__decorateClass$a([attr({
|
|
8634
8642
|
mode: "boolean"
|
|
8635
8643
|
})], RadioGroup.prototype, "required", 2);
|
|
8636
8644
|
|
|
8637
|
-
const styles$
|
|
8645
|
+
const styles$d = css`
|
|
8638
8646
|
${display("flex")}
|
|
8639
8647
|
|
|
8640
8648
|
: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}}`;
|
|
@@ -8642,17 +8650,17 @@ const styles$c = css`
|
|
|
8642
8650
|
function radioGroupTemplate() {
|
|
8643
8651
|
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>`;
|
|
8644
8652
|
}
|
|
8645
|
-
const template$
|
|
8653
|
+
const template$d = radioGroupTemplate();
|
|
8646
8654
|
|
|
8647
|
-
const definition$
|
|
8655
|
+
const definition$d = RadioGroup.compose({
|
|
8648
8656
|
name: `${FluentDesignSystem.prefix}-radio-group`,
|
|
8649
|
-
template: template$
|
|
8650
|
-
styles: styles$
|
|
8657
|
+
template: template$d,
|
|
8658
|
+
styles: styles$d
|
|
8651
8659
|
});
|
|
8652
8660
|
|
|
8653
|
-
definition$
|
|
8661
|
+
definition$d.define(FluentDesignSystem.registry);
|
|
8654
8662
|
|
|
8655
|
-
const styles$
|
|
8663
|
+
const styles$c = css`
|
|
8656
8664
|
${display("inline-flex")}
|
|
8657
8665
|
|
|
8658
8666
|
: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`
|
|
@@ -8665,24 +8673,24 @@ const checkedIndicator = html.partial( /* html */
|
|
|
8665
8673
|
function radioTemplate(options = {}) {
|
|
8666
8674
|
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>`;
|
|
8667
8675
|
}
|
|
8668
|
-
const template$
|
|
8676
|
+
const template$c = radioTemplate({
|
|
8669
8677
|
checkedIndicator
|
|
8670
8678
|
});
|
|
8671
8679
|
|
|
8672
|
-
const definition$
|
|
8680
|
+
const definition$c = Radio.compose({
|
|
8673
8681
|
name: `${FluentDesignSystem.prefix}-radio`,
|
|
8674
|
-
template: template$
|
|
8675
|
-
styles: styles$
|
|
8682
|
+
template: template$c,
|
|
8683
|
+
styles: styles$c
|
|
8676
8684
|
});
|
|
8677
8685
|
|
|
8678
|
-
definition$
|
|
8686
|
+
definition$c.define(FluentDesignSystem.registry);
|
|
8679
8687
|
|
|
8680
|
-
var __defProp$
|
|
8681
|
-
var __getOwnPropDesc$
|
|
8682
|
-
var __decorateClass$
|
|
8683
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8688
|
+
var __defProp$9 = Object.defineProperty;
|
|
8689
|
+
var __getOwnPropDesc$9 = Object.getOwnPropertyDescriptor;
|
|
8690
|
+
var __decorateClass$9 = (decorators, target, key, kind) => {
|
|
8691
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$9(target, key) : target;
|
|
8684
8692
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8685
|
-
if (kind && result) __defProp$
|
|
8693
|
+
if (kind && result) __defProp$9(target, key, result);
|
|
8686
8694
|
return result;
|
|
8687
8695
|
};
|
|
8688
8696
|
class BaseRatingDisplay extends FASTElement {
|
|
@@ -8736,13 +8744,13 @@ class BaseRatingDisplay extends FASTElement {
|
|
|
8736
8744
|
return htmlString;
|
|
8737
8745
|
}
|
|
8738
8746
|
}
|
|
8739
|
-
__decorateClass$
|
|
8747
|
+
__decorateClass$9([attr({
|
|
8740
8748
|
converter: nullableNumberConverter
|
|
8741
8749
|
})], BaseRatingDisplay.prototype, "count", 2);
|
|
8742
|
-
__decorateClass$
|
|
8750
|
+
__decorateClass$9([attr({
|
|
8743
8751
|
converter: nullableNumberConverter
|
|
8744
8752
|
})], BaseRatingDisplay.prototype, "max", 2);
|
|
8745
|
-
__decorateClass$
|
|
8753
|
+
__decorateClass$9([attr({
|
|
8746
8754
|
converter: nullableNumberConverter
|
|
8747
8755
|
})], BaseRatingDisplay.prototype, "value", 2);
|
|
8748
8756
|
class RatingDisplay extends BaseRatingDisplay {
|
|
@@ -8787,13 +8795,13 @@ class RatingDisplay extends BaseRatingDisplay {
|
|
|
8787
8795
|
return (this.compact ? 1 : this.max ?? 5) * 2;
|
|
8788
8796
|
}
|
|
8789
8797
|
}
|
|
8790
|
-
__decorateClass$
|
|
8791
|
-
__decorateClass$
|
|
8792
|
-
__decorateClass$
|
|
8798
|
+
__decorateClass$9([attr], RatingDisplay.prototype, "color", 2);
|
|
8799
|
+
__decorateClass$9([attr], RatingDisplay.prototype, "size", 2);
|
|
8800
|
+
__decorateClass$9([attr({
|
|
8793
8801
|
mode: "boolean"
|
|
8794
8802
|
})], RatingDisplay.prototype, "compact", 2);
|
|
8795
8803
|
|
|
8796
|
-
const styles$
|
|
8804
|
+
const styles$b = css`
|
|
8797
8805
|
${display("inline-flex")}
|
|
8798
8806
|
|
|
8799
8807
|
:host{--icon-size:16px;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}}svg{width:var(--icon-size);height:var(--icon-size);fill:${colorPaletteMarigoldBackground3};margin-inline-end:${spacingHorizontalXXS}}svg:nth-child(even){clip-path:inset(0 50% 0 0);margin-inline-end:calc(0px - var(--icon-size))}:host(${neutralState}) svg{fill:${colorNeutralForeground1}}:host(${brandState}) svg{fill:${colorBrandBackground}}:host(:is([value^='-'],[value='0'])) svg,:host(:not([value])) svg,svg[selected] ~ svg{fill:${colorPaletteMarigoldBackground2}}:host(${neutralState}:is([value^='-'],[value='0'])) svg,:host(${neutralState}:not([value])) svg,:host(${neutralState}) svg[selected] ~ svg{fill:${colorNeutralBackground1Pressed}}:host(${brandState}:is([value^='-'],[value='0'])) svg,:host(${brandState}:not([value])) svg,:host(${brandState}) svg[selected] ~ svg{fill:${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`
|
|
@@ -8803,15 +8811,15 @@ const star = html`<svg xmlns="http://www.w3.org/2000/svg" style="display: none">
|
|
|
8803
8811
|
function ratingDisplayTemplate() {
|
|
8804
8812
|
return html` ${star} ${x => html`${html.partial(x.generateIcons())}`}<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>`;
|
|
8805
8813
|
}
|
|
8806
|
-
const template$
|
|
8814
|
+
const template$b = ratingDisplayTemplate();
|
|
8807
8815
|
|
|
8808
|
-
const definition$
|
|
8816
|
+
const definition$b = RatingDisplay.compose({
|
|
8809
8817
|
name: `${FluentDesignSystem.prefix}-rating-display`,
|
|
8810
|
-
template: template$
|
|
8811
|
-
styles: styles$
|
|
8818
|
+
template: template$b,
|
|
8819
|
+
styles: styles$b
|
|
8812
8820
|
});
|
|
8813
8821
|
|
|
8814
|
-
definition$
|
|
8822
|
+
definition$b.define(FluentDesignSystem.registry);
|
|
8815
8823
|
|
|
8816
8824
|
const SliderOrientation = Orientation;
|
|
8817
8825
|
const SliderMode = {
|
|
@@ -8826,12 +8834,12 @@ function convertPixelToPercent(pixelPos, minPosition, maxPosition, direction) {
|
|
|
8826
8834
|
return pct;
|
|
8827
8835
|
}
|
|
8828
8836
|
|
|
8829
|
-
var __defProp$
|
|
8830
|
-
var __getOwnPropDesc$
|
|
8831
|
-
var __decorateClass$
|
|
8832
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8837
|
+
var __defProp$8 = Object.defineProperty;
|
|
8838
|
+
var __getOwnPropDesc$8 = Object.getOwnPropertyDescriptor;
|
|
8839
|
+
var __decorateClass$8 = (decorators, target, key, kind) => {
|
|
8840
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$8(target, key) : target;
|
|
8833
8841
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8834
|
-
if (kind && result) __defProp$
|
|
8842
|
+
if (kind && result) __defProp$8(target, key, result);
|
|
8835
8843
|
return result;
|
|
8836
8844
|
};
|
|
8837
8845
|
class Slider extends FASTElement {
|
|
@@ -9370,36 +9378,36 @@ class Slider extends FASTElement {
|
|
|
9370
9378
|
* @public
|
|
9371
9379
|
*/
|
|
9372
9380
|
Slider.formAssociated = true;
|
|
9373
|
-
__decorateClass$
|
|
9374
|
-
__decorateClass$
|
|
9381
|
+
__decorateClass$8([attr], Slider.prototype, "size", 2);
|
|
9382
|
+
__decorateClass$8([attr({
|
|
9375
9383
|
attribute: "value",
|
|
9376
9384
|
mode: "fromView"
|
|
9377
9385
|
})], Slider.prototype, "initialValue", 2);
|
|
9378
|
-
__decorateClass$
|
|
9379
|
-
__decorateClass$
|
|
9380
|
-
__decorateClass$
|
|
9381
|
-
__decorateClass$
|
|
9382
|
-
__decorateClass$
|
|
9383
|
-
__decorateClass$
|
|
9384
|
-
__decorateClass$
|
|
9385
|
-
__decorateClass$
|
|
9386
|
-
__decorateClass$
|
|
9387
|
-
__decorateClass$
|
|
9386
|
+
__decorateClass$8([observable], Slider.prototype, "direction", 2);
|
|
9387
|
+
__decorateClass$8([observable], Slider.prototype, "isDragging", 2);
|
|
9388
|
+
__decorateClass$8([observable], Slider.prototype, "position", 2);
|
|
9389
|
+
__decorateClass$8([observable], Slider.prototype, "trackWidth", 2);
|
|
9390
|
+
__decorateClass$8([observable], Slider.prototype, "trackMinWidth", 2);
|
|
9391
|
+
__decorateClass$8([observable], Slider.prototype, "trackHeight", 2);
|
|
9392
|
+
__decorateClass$8([observable], Slider.prototype, "trackLeft", 2);
|
|
9393
|
+
__decorateClass$8([observable], Slider.prototype, "trackMinHeight", 2);
|
|
9394
|
+
__decorateClass$8([observable], Slider.prototype, "valueTextFormatter", 2);
|
|
9395
|
+
__decorateClass$8([attr({
|
|
9388
9396
|
mode: "boolean"
|
|
9389
9397
|
})], Slider.prototype, "disabled", 2);
|
|
9390
|
-
__decorateClass$
|
|
9398
|
+
__decorateClass$8([attr({
|
|
9391
9399
|
converter: numberLikeStringConverter
|
|
9392
9400
|
})], Slider.prototype, "min", 2);
|
|
9393
|
-
__decorateClass$
|
|
9401
|
+
__decorateClass$8([attr({
|
|
9394
9402
|
converter: numberLikeStringConverter
|
|
9395
9403
|
})], Slider.prototype, "max", 2);
|
|
9396
|
-
__decorateClass$
|
|
9404
|
+
__decorateClass$8([attr({
|
|
9397
9405
|
converter: numberLikeStringConverter
|
|
9398
9406
|
})], Slider.prototype, "step", 2);
|
|
9399
|
-
__decorateClass$
|
|
9400
|
-
__decorateClass$
|
|
9407
|
+
__decorateClass$8([attr], Slider.prototype, "orientation", 2);
|
|
9408
|
+
__decorateClass$8([attr], Slider.prototype, "mode", 2);
|
|
9401
9409
|
|
|
9402
|
-
const styles$
|
|
9410
|
+
const styles$a = css`
|
|
9403
9411
|
${display("inline-grid")}
|
|
9404
9412
|
|
|
9405
9413
|
:host{--thumb-size:20px;--track-margin-inline:calc(var(--thumb-size) / 2);--track-size:4px;--track-overhang:calc(var(--track-size) / -2);--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(: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}}.track{position:relative;background-color:${colorNeutralStrokeAccessible};border-radius:var(--border-radius);grid-row:2 / 2;grid-column:2 / 2;width:100%;height:var(--track-size);forced-color-adjust:none}:host(${verticalState}) .track{top:var(--track-overhang);bottom:var(--track-overhang);width:var(--track-size);height:100%}.track::before{content:'';position:absolute;height:100%;border-radius:inherit;inset-inline-start:0;width:var(--slider-progress)}:host(${verticalState}) .track::before{width:100%;bottom:0;height:var(--slider-progress)}:host([step]) .track::after{content:'';position:absolute;border-radius:inherit;inset:var(--step-marker-inset);background-image:repeating-linear-gradient(
|
|
@@ -9410,24 +9418,24 @@ const styles$9 = css`
|
|
|
9410
9418
|
function sliderTemplate(options = {}) {
|
|
9411
9419
|
return html`<template tabindex="${x => x.disabled ? null : 0}" @pointerdown="${(x, c) => x.handlePointerDown(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>`;
|
|
9412
9420
|
}
|
|
9413
|
-
const template$
|
|
9421
|
+
const template$a = sliderTemplate({
|
|
9414
9422
|
thumb: `<div class="thumb"></div>`
|
|
9415
9423
|
});
|
|
9416
9424
|
|
|
9417
|
-
const definition$
|
|
9425
|
+
const definition$a = Slider.compose({
|
|
9418
9426
|
name: `${FluentDesignSystem.prefix}-slider`,
|
|
9419
|
-
template: template$
|
|
9420
|
-
styles: styles$
|
|
9427
|
+
template: template$a,
|
|
9428
|
+
styles: styles$a
|
|
9421
9429
|
});
|
|
9422
9430
|
|
|
9423
|
-
definition$
|
|
9431
|
+
definition$a.define(FluentDesignSystem.registry);
|
|
9424
9432
|
|
|
9425
|
-
var __defProp$
|
|
9426
|
-
var __getOwnPropDesc$
|
|
9427
|
-
var __decorateClass$
|
|
9428
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
9433
|
+
var __defProp$7 = Object.defineProperty;
|
|
9434
|
+
var __getOwnPropDesc$7 = Object.getOwnPropertyDescriptor;
|
|
9435
|
+
var __decorateClass$7 = (decorators, target, key, kind) => {
|
|
9436
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$7(target, key) : target;
|
|
9429
9437
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
9430
|
-
if (kind && result) __defProp$
|
|
9438
|
+
if (kind && result) __defProp$7(target, key, result);
|
|
9431
9439
|
return result;
|
|
9432
9440
|
};
|
|
9433
9441
|
class BaseSpinner extends FASTElement {
|
|
@@ -9470,24 +9478,24 @@ class Spinner extends BaseSpinner {
|
|
|
9470
9478
|
}
|
|
9471
9479
|
}
|
|
9472
9480
|
}
|
|
9473
|
-
__decorateClass$
|
|
9474
|
-
__decorateClass$
|
|
9481
|
+
__decorateClass$7([attr], Spinner.prototype, "size", 2);
|
|
9482
|
+
__decorateClass$7([attr], Spinner.prototype, "appearance", 2);
|
|
9475
9483
|
|
|
9476
|
-
const styles$
|
|
9484
|
+
const styles$9 = css`
|
|
9477
9485
|
${display("inline-flex")}
|
|
9478
9486
|
|
|
9479
9487
|
: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;inset-inline-end:50%}.end{overflow:hidden;inset-inline-start:50%}.indicator{color:${colorBrandStroke1};box-sizing:border-box;border-radius:50%;border:var(--indicatorSize) solid transparent;border-block-start-color:currentcolor;border-inline-end-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`
|
|
9480
9488
|
.background{display:none}.indicator{border-color:Canvas;border-block-start-color:Highlight;border-inline-end-color:Highlight}`));
|
|
9481
9489
|
|
|
9482
|
-
const template$
|
|
9490
|
+
const template$9 = 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>`;
|
|
9483
9491
|
|
|
9484
|
-
const definition$
|
|
9492
|
+
const definition$9 = Spinner.compose({
|
|
9485
9493
|
name: `${FluentDesignSystem.prefix}-spinner`,
|
|
9486
|
-
template: template$
|
|
9487
|
-
styles: styles$
|
|
9494
|
+
template: template$9,
|
|
9495
|
+
styles: styles$9
|
|
9488
9496
|
});
|
|
9489
9497
|
|
|
9490
|
-
definition$
|
|
9498
|
+
definition$9.define(FluentDesignSystem.registry);
|
|
9491
9499
|
|
|
9492
9500
|
class Switch extends BaseCheckbox {
|
|
9493
9501
|
constructor() {
|
|
@@ -9499,50 +9507,50 @@ class Switch extends BaseCheckbox {
|
|
|
9499
9507
|
function switchTemplate(options = {}) {
|
|
9500
9508
|
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>`;
|
|
9501
9509
|
}
|
|
9502
|
-
const template$
|
|
9510
|
+
const template$8 = switchTemplate({
|
|
9503
9511
|
switch: `<span class="checked-indicator" part="checked-indicator"></span>`
|
|
9504
9512
|
});
|
|
9505
9513
|
|
|
9506
|
-
const styles$
|
|
9514
|
+
const styles$8 = css`
|
|
9507
9515
|
${display("inline-flex")}
|
|
9508
9516
|
|
|
9509
9517
|
: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`
|
|
9510
9518
|
: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}`));
|
|
9511
9519
|
|
|
9512
|
-
const definition$
|
|
9520
|
+
const definition$8 = Switch.compose({
|
|
9513
9521
|
name: `${FluentDesignSystem.prefix}-switch`,
|
|
9514
|
-
template: template$
|
|
9515
|
-
styles: styles$
|
|
9522
|
+
template: template$8,
|
|
9523
|
+
styles: styles$8
|
|
9516
9524
|
});
|
|
9517
9525
|
|
|
9518
|
-
definition$
|
|
9526
|
+
definition$8.define(FluentDesignSystem.registry);
|
|
9519
9527
|
|
|
9520
9528
|
class TabPanel extends FASTElement {}
|
|
9521
9529
|
|
|
9522
9530
|
function tabPanelTemplate() {
|
|
9523
9531
|
return html`<template slot="tabpanel" role="tabpanel"><slot></slot></template>`;
|
|
9524
9532
|
}
|
|
9525
|
-
const template$
|
|
9533
|
+
const template$7 = tabPanelTemplate();
|
|
9526
9534
|
|
|
9527
|
-
const styles$
|
|
9535
|
+
const styles$7 = css`
|
|
9528
9536
|
${display("block")}
|
|
9529
9537
|
|
|
9530
9538
|
:host{box-sizing:border-box;padding:${spacingHorizontalM} ${spacingHorizontalMNudge}}`;
|
|
9531
9539
|
|
|
9532
|
-
const definition$
|
|
9540
|
+
const definition$7 = TabPanel.compose({
|
|
9533
9541
|
name: `${FluentDesignSystem.prefix}-tab-panel`,
|
|
9534
|
-
template: template$
|
|
9535
|
-
styles: styles$
|
|
9542
|
+
template: template$7,
|
|
9543
|
+
styles: styles$7
|
|
9536
9544
|
});
|
|
9537
9545
|
|
|
9538
|
-
definition$
|
|
9546
|
+
definition$7.define(FluentDesignSystem.registry);
|
|
9539
9547
|
|
|
9540
|
-
var __defProp$
|
|
9541
|
-
var __getOwnPropDesc$
|
|
9542
|
-
var __decorateClass$
|
|
9543
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
9548
|
+
var __defProp$6 = Object.defineProperty;
|
|
9549
|
+
var __getOwnPropDesc$6 = Object.getOwnPropertyDescriptor;
|
|
9550
|
+
var __decorateClass$6 = (decorators, target, key, kind) => {
|
|
9551
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$6(target, key) : target;
|
|
9544
9552
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
9545
|
-
if (kind && result) __defProp$
|
|
9553
|
+
if (kind && result) __defProp$6(target, key, result);
|
|
9546
9554
|
return result;
|
|
9547
9555
|
};
|
|
9548
9556
|
class Tab extends FASTElement {
|
|
@@ -9556,7 +9564,7 @@ class Tab extends FASTElement {
|
|
|
9556
9564
|
this.$fastController.addStyles(this.styles);
|
|
9557
9565
|
}
|
|
9558
9566
|
}
|
|
9559
|
-
__decorateClass$
|
|
9567
|
+
__decorateClass$6([attr({
|
|
9560
9568
|
mode: "boolean"
|
|
9561
9569
|
})], Tab.prototype, "disabled", 2);
|
|
9562
9570
|
applyMixins(Tab, StartEnd);
|
|
@@ -9564,21 +9572,21 @@ applyMixins(Tab, StartEnd);
|
|
|
9564
9572
|
function tabTemplate(options = {}) {
|
|
9565
9573
|
return html`<template slot="tab" role="tab" aria-disabled="${x => x.disabled}">${startSlotTemplate(options)}<span class="tab-content"><slot></slot></span>${endSlotTemplate(options)}</template>`;
|
|
9566
9574
|
}
|
|
9567
|
-
const template$
|
|
9575
|
+
const template$6 = tabTemplate({});
|
|
9568
9576
|
|
|
9569
|
-
const styles$
|
|
9577
|
+
const styles$6 = css`
|
|
9570
9578
|
${display("inline-flex")}
|
|
9571
9579
|
|
|
9572
9580
|
: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`
|
|
9573
9581
|
:host([aria-selected='true'])::after{background-color:Highlight}`));
|
|
9574
9582
|
|
|
9575
|
-
const definition$
|
|
9583
|
+
const definition$6 = Tab.compose({
|
|
9576
9584
|
name: `${FluentDesignSystem.prefix}-tab`,
|
|
9577
|
-
template: template$
|
|
9578
|
-
styles: styles$
|
|
9585
|
+
template: template$6,
|
|
9586
|
+
styles: styles$6
|
|
9579
9587
|
});
|
|
9580
9588
|
|
|
9581
|
-
definition$
|
|
9589
|
+
definition$6.define(FluentDesignSystem.registry);
|
|
9582
9590
|
|
|
9583
9591
|
const TabsAppearance = {
|
|
9584
9592
|
subtle: "subtle",
|
|
@@ -9586,12 +9594,12 @@ const TabsAppearance = {
|
|
|
9586
9594
|
};
|
|
9587
9595
|
const TabsOrientation = Orientation;
|
|
9588
9596
|
|
|
9589
|
-
var __defProp$
|
|
9590
|
-
var __getOwnPropDesc$
|
|
9591
|
-
var __decorateClass$
|
|
9592
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
9597
|
+
var __defProp$5 = Object.defineProperty;
|
|
9598
|
+
var __getOwnPropDesc$5 = Object.getOwnPropertyDescriptor;
|
|
9599
|
+
var __decorateClass$5 = (decorators, target, key, kind) => {
|
|
9600
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$5(target, key) : target;
|
|
9593
9601
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
9594
|
-
if (kind && result) __defProp$
|
|
9602
|
+
if (kind && result) __defProp$5(target, key, result);
|
|
9595
9603
|
return result;
|
|
9596
9604
|
};
|
|
9597
9605
|
class BaseTabs extends FASTElement {
|
|
@@ -9835,10 +9843,10 @@ class BaseTabs extends FASTElement {
|
|
|
9835
9843
|
this.activeTabIndex = this.getActiveIndex();
|
|
9836
9844
|
}
|
|
9837
9845
|
}
|
|
9838
|
-
__decorateClass$
|
|
9839
|
-
__decorateClass$
|
|
9840
|
-
__decorateClass$
|
|
9841
|
-
__decorateClass$
|
|
9846
|
+
__decorateClass$5([attr], BaseTabs.prototype, "orientation", 2);
|
|
9847
|
+
__decorateClass$5([attr], BaseTabs.prototype, "activeid", 2);
|
|
9848
|
+
__decorateClass$5([observable], BaseTabs.prototype, "tabs", 2);
|
|
9849
|
+
__decorateClass$5([observable], BaseTabs.prototype, "tabpanels", 2);
|
|
9842
9850
|
class Tabs extends BaseTabs {
|
|
9843
9851
|
constructor() {
|
|
9844
9852
|
super(...arguments);
|
|
@@ -9970,30 +9978,30 @@ class Tabs extends BaseTabs {
|
|
|
9970
9978
|
this.setTabData();
|
|
9971
9979
|
}
|
|
9972
9980
|
}
|
|
9973
|
-
__decorateClass$
|
|
9974
|
-
__decorateClass$
|
|
9981
|
+
__decorateClass$5([attr], Tabs.prototype, "appearance", 2);
|
|
9982
|
+
__decorateClass$5([attr({
|
|
9975
9983
|
mode: "boolean"
|
|
9976
9984
|
})], Tabs.prototype, "disabled", 2);
|
|
9977
|
-
__decorateClass$
|
|
9985
|
+
__decorateClass$5([attr], Tabs.prototype, "size", 2);
|
|
9978
9986
|
applyMixins(Tabs, StartEnd);
|
|
9979
9987
|
|
|
9980
9988
|
function tabsTemplate(options = {}) {
|
|
9981
9989
|
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>`;
|
|
9982
9990
|
}
|
|
9983
|
-
const template$
|
|
9991
|
+
const template$5 = tabsTemplate({});
|
|
9984
9992
|
|
|
9985
|
-
const styles$
|
|
9993
|
+
const styles$5 = css`
|
|
9986
9994
|
${display("grid")}
|
|
9987
9995
|
|
|
9988
9996
|
: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}}`;
|
|
9989
9997
|
|
|
9990
|
-
const definition$
|
|
9998
|
+
const definition$5 = Tabs.compose({
|
|
9991
9999
|
name: `${FluentDesignSystem.prefix}-tabs`,
|
|
9992
|
-
template: template$
|
|
9993
|
-
styles: styles$
|
|
10000
|
+
template: template$5,
|
|
10001
|
+
styles: styles$5
|
|
9994
10002
|
});
|
|
9995
10003
|
|
|
9996
|
-
definition$
|
|
10004
|
+
definition$5.define(FluentDesignSystem.registry);
|
|
9997
10005
|
|
|
9998
10006
|
const isARIADisabledElement = el => {
|
|
9999
10007
|
return el.getAttribute("aria-disabled") === "true";
|
|
@@ -10011,12 +10019,12 @@ const TablistAppearance = {
|
|
|
10011
10019
|
};
|
|
10012
10020
|
const TablistOrientation = Orientation;
|
|
10013
10021
|
|
|
10014
|
-
var __defProp$
|
|
10015
|
-
var __getOwnPropDesc$
|
|
10016
|
-
var __decorateClass$
|
|
10017
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
10022
|
+
var __defProp$4 = Object.defineProperty;
|
|
10023
|
+
var __getOwnPropDesc$4 = Object.getOwnPropertyDescriptor;
|
|
10024
|
+
var __decorateClass$4 = (decorators, target, key, kind) => {
|
|
10025
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$4(target, key) : target;
|
|
10018
10026
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
10019
|
-
if (kind && result) __defProp$
|
|
10027
|
+
if (kind && result) __defProp$4(target, key, result);
|
|
10020
10028
|
return result;
|
|
10021
10029
|
};
|
|
10022
10030
|
class BaseTablist extends FASTElement {
|
|
@@ -10210,12 +10218,12 @@ class BaseTablist extends FASTElement {
|
|
|
10210
10218
|
this.activeTabIndex = this.getActiveIndex();
|
|
10211
10219
|
}
|
|
10212
10220
|
}
|
|
10213
|
-
__decorateClass$
|
|
10221
|
+
__decorateClass$4([attr({
|
|
10214
10222
|
mode: "boolean"
|
|
10215
10223
|
})], BaseTablist.prototype, "disabled", 2);
|
|
10216
|
-
__decorateClass$
|
|
10217
|
-
__decorateClass$
|
|
10218
|
-
__decorateClass$
|
|
10224
|
+
__decorateClass$4([attr], BaseTablist.prototype, "orientation", 2);
|
|
10225
|
+
__decorateClass$4([attr], BaseTablist.prototype, "activeid", 2);
|
|
10226
|
+
__decorateClass$4([observable], BaseTablist.prototype, "tabs", 2);
|
|
10219
10227
|
class Tablist extends BaseTablist {
|
|
10220
10228
|
constructor() {
|
|
10221
10229
|
super(...arguments);
|
|
@@ -10377,20 +10385,564 @@ class Tablist extends BaseTablist {
|
|
|
10377
10385
|
}
|
|
10378
10386
|
}
|
|
10379
10387
|
}
|
|
10380
|
-
__decorateClass$
|
|
10381
|
-
__decorateClass$
|
|
10388
|
+
__decorateClass$4([attr], Tablist.prototype, "appearance", 2);
|
|
10389
|
+
__decorateClass$4([attr], Tablist.prototype, "size", 2);
|
|
10382
10390
|
|
|
10383
|
-
const template$
|
|
10391
|
+
const template$4 = html`<template role="tablist"><slot name="tab" ${slotted("tabs")}></slot></template>`;
|
|
10384
10392
|
|
|
10385
|
-
const styles$
|
|
10393
|
+
const styles$4 = css`
|
|
10386
10394
|
${display("flex")}
|
|
10387
10395
|
|
|
10388
10396
|
: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}}`;
|
|
10389
10397
|
|
|
10390
|
-
const definition$
|
|
10398
|
+
const definition$4 = Tablist.compose({
|
|
10391
10399
|
name: `${FluentDesignSystem.prefix}-tablist`,
|
|
10400
|
+
template: template$4,
|
|
10401
|
+
styles: styles$4
|
|
10402
|
+
});
|
|
10403
|
+
|
|
10404
|
+
definition$4.define(FluentDesignSystem.registry);
|
|
10405
|
+
|
|
10406
|
+
const TextAreaAppearance = {
|
|
10407
|
+
outline: "outline",
|
|
10408
|
+
filledLighter: "filled-lighter",
|
|
10409
|
+
filledDarker: "filled-darker"
|
|
10410
|
+
};
|
|
10411
|
+
const TextAreaAppearancesForDisplayShadow = [TextAreaAppearance.filledLighter, TextAreaAppearance.filledDarker];
|
|
10412
|
+
const TextAreaResize = {
|
|
10413
|
+
none: "none",
|
|
10414
|
+
both: "both",
|
|
10415
|
+
horizontal: "horizontal",
|
|
10416
|
+
vertical: "vertical"
|
|
10417
|
+
};
|
|
10418
|
+
const TextAreaResizableResize = [TextAreaResize.both, TextAreaResize.horizontal, TextAreaResize.vertical];
|
|
10419
|
+
|
|
10420
|
+
var __defProp$3 = Object.defineProperty;
|
|
10421
|
+
var __getOwnPropDesc$3 = Object.getOwnPropertyDescriptor;
|
|
10422
|
+
var __decorateClass$3 = (decorators, target, key, kind) => {
|
|
10423
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$3(target, key) : target;
|
|
10424
|
+
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
10425
|
+
if (kind && result) __defProp$3(target, key, result);
|
|
10426
|
+
return result;
|
|
10427
|
+
};
|
|
10428
|
+
class BaseTextArea extends FASTElement {
|
|
10429
|
+
constructor() {
|
|
10430
|
+
super();
|
|
10431
|
+
/**
|
|
10432
|
+
* The internal {@link https://developer.mozilla.org/docs/Web/API/ElementInternals | `ElementInternals`} instance for the component.
|
|
10433
|
+
*
|
|
10434
|
+
* @internal
|
|
10435
|
+
*/
|
|
10436
|
+
this.elementInternals = this.attachInternals();
|
|
10437
|
+
this.userInteracted = false;
|
|
10438
|
+
this.preConnectControlEl = document.createElement("textarea");
|
|
10439
|
+
this.autoResize = false;
|
|
10440
|
+
this.disabled = false;
|
|
10441
|
+
this.displayShadow = false;
|
|
10442
|
+
this.readOnly = false;
|
|
10443
|
+
this.required = false;
|
|
10444
|
+
this.resize = TextAreaResize.none;
|
|
10445
|
+
this.spellcheck = false;
|
|
10446
|
+
}
|
|
10447
|
+
defaultSlottedNodesChanged() {
|
|
10448
|
+
const next = this.getContent();
|
|
10449
|
+
this.defaultValue = next;
|
|
10450
|
+
this.value = next;
|
|
10451
|
+
}
|
|
10452
|
+
labelSlottedNodesChanged() {
|
|
10453
|
+
if (this.labelEl) {
|
|
10454
|
+
this.labelEl.hidden = !this.labelSlottedNodes.length;
|
|
10455
|
+
}
|
|
10456
|
+
this.labelSlottedNodes.forEach(node => {
|
|
10457
|
+
node.disabled = this.disabled;
|
|
10458
|
+
node.required = this.required;
|
|
10459
|
+
});
|
|
10460
|
+
}
|
|
10461
|
+
autoResizeChanged() {
|
|
10462
|
+
this.maybeCreateAutoSizerEl();
|
|
10463
|
+
toggleState(this.elementInternals, "auto-resize", this.autoResize);
|
|
10464
|
+
}
|
|
10465
|
+
disabledChanged() {
|
|
10466
|
+
this.setDisabledSideEffect(this.disabled);
|
|
10467
|
+
}
|
|
10468
|
+
/**
|
|
10469
|
+
* The form element that’s associated to the element, or `null` if no form is associated.
|
|
10470
|
+
*
|
|
10471
|
+
* @public
|
|
10472
|
+
*/
|
|
10473
|
+
get form() {
|
|
10474
|
+
return this.elementInternals.form;
|
|
10475
|
+
}
|
|
10476
|
+
/**
|
|
10477
|
+
* A `NodeList` of `<label>` element associated with the element.
|
|
10478
|
+
* @see The {@link https://developer.mozilla.org/en-US/docs/Web/API/HTMLTextAreaElement/labels | `labels`} property
|
|
10479
|
+
*
|
|
10480
|
+
* @public
|
|
10481
|
+
*/
|
|
10482
|
+
get labels() {
|
|
10483
|
+
return this.elementInternals.labels;
|
|
10484
|
+
}
|
|
10485
|
+
readOnlyChanged() {
|
|
10486
|
+
this.elementInternals.ariaReadOnly = `${!!this.readOnly}`;
|
|
10487
|
+
}
|
|
10488
|
+
requiredChanged() {
|
|
10489
|
+
this.elementInternals.ariaRequired = `${!!this.required}`;
|
|
10490
|
+
if (this.labelSlottedNodes?.length) {
|
|
10491
|
+
this.labelSlottedNodes.forEach(node => node.required = this.required);
|
|
10492
|
+
}
|
|
10493
|
+
}
|
|
10494
|
+
resizeChanged(prev, next) {
|
|
10495
|
+
if (prev) {
|
|
10496
|
+
toggleState(this.elementInternals, `resize-${prev}`, false);
|
|
10497
|
+
}
|
|
10498
|
+
if (next) {
|
|
10499
|
+
toggleState(this.elementInternals, `resize-${next}`, true);
|
|
10500
|
+
}
|
|
10501
|
+
toggleState(this.elementInternals, `resize`, TextAreaResizableResize.includes(this.resize));
|
|
10502
|
+
}
|
|
10503
|
+
/**
|
|
10504
|
+
* The length of the current value.
|
|
10505
|
+
* @see The {@link https://developer.mozilla.org/en-US/docs/Web/API/HTMLTextAreaElement#textLength | 'textLength'} property
|
|
10506
|
+
*
|
|
10507
|
+
* @public
|
|
10508
|
+
*/
|
|
10509
|
+
get textLength() {
|
|
10510
|
+
return this.controlEl.textLength;
|
|
10511
|
+
}
|
|
10512
|
+
/**
|
|
10513
|
+
* The type of the element, which is always "textarea".
|
|
10514
|
+
* @see The {@link https://developer.mozilla.org/en-US/docs/Web/API/HTMLTextAreaElement/type | `type`} property
|
|
10515
|
+
*
|
|
10516
|
+
* @public
|
|
10517
|
+
*/
|
|
10518
|
+
get type() {
|
|
10519
|
+
return "textarea";
|
|
10520
|
+
}
|
|
10521
|
+
/**
|
|
10522
|
+
* The element's validity state.
|
|
10523
|
+
*
|
|
10524
|
+
* @public
|
|
10525
|
+
* @remarks
|
|
10526
|
+
* Reflects the {@link https://developer.mozilla.org/docs/Web/API/ElementInternals/validity | `ElementInternals.validity`} property.
|
|
10527
|
+
*/
|
|
10528
|
+
get validity() {
|
|
10529
|
+
return this.elementInternals.validity;
|
|
10530
|
+
}
|
|
10531
|
+
/**
|
|
10532
|
+
* The validation message.
|
|
10533
|
+
*
|
|
10534
|
+
* @public
|
|
10535
|
+
* @remarks
|
|
10536
|
+
* Reflects the {@link https://developer.mozilla.org/docs/Web/API/ElementInternals/validationMessage | `ElementInternals.validationMessage`} property.
|
|
10537
|
+
*/
|
|
10538
|
+
get validationMessage() {
|
|
10539
|
+
return this.elementInternals.validationMessage || this.controlEl.validationMessage;
|
|
10540
|
+
}
|
|
10541
|
+
/**
|
|
10542
|
+
* Determines if the control can be submitted for constraint validation.
|
|
10543
|
+
*
|
|
10544
|
+
* @public
|
|
10545
|
+
* @remarks
|
|
10546
|
+
* Reflects the {@link https://developer.mozilla.org/docs/Web/API/ElementInternals/willValidate | `ElementInternals.willValidate`} property.
|
|
10547
|
+
*/
|
|
10548
|
+
get willValidate() {
|
|
10549
|
+
return this.elementInternals.willValidate;
|
|
10550
|
+
}
|
|
10551
|
+
/**
|
|
10552
|
+
* The text content of the element before user interaction.
|
|
10553
|
+
* @see The {@link https://developer.mozilla.org/en-US/docs/Web/API/HTMLTextAreaElement#defaultvalue | `defaultValue`} property
|
|
10554
|
+
*
|
|
10555
|
+
* @public
|
|
10556
|
+
* @remarks
|
|
10557
|
+
* In order to set the initial/default value, an author should either add the default value in the HTML as the children
|
|
10558
|
+
* of the component, or setting this property in JavaScript. Setting `innerHTML`, `innerText`, or `textContent` on this
|
|
10559
|
+
* component will not change the default value or the content displayed inside the component.
|
|
10560
|
+
*/
|
|
10561
|
+
get defaultValue() {
|
|
10562
|
+
return this.controlEl?.defaultValue ?? this.preConnectControlEl.defaultValue;
|
|
10563
|
+
}
|
|
10564
|
+
set defaultValue(next) {
|
|
10565
|
+
const controlEl = this.controlEl ?? this.preConnectControlEl;
|
|
10566
|
+
controlEl.defaultValue = next;
|
|
10567
|
+
if (this.controlEl && !this.userInteracted) {
|
|
10568
|
+
this.controlEl.value = next;
|
|
10569
|
+
}
|
|
10570
|
+
}
|
|
10571
|
+
/**
|
|
10572
|
+
* The value of the element.
|
|
10573
|
+
*
|
|
10574
|
+
* @public
|
|
10575
|
+
* @remarks
|
|
10576
|
+
* Reflects the `value` property.
|
|
10577
|
+
*/
|
|
10578
|
+
get value() {
|
|
10579
|
+
return this.controlEl?.value ?? this.preConnectControlEl.value;
|
|
10580
|
+
}
|
|
10581
|
+
set value(next) {
|
|
10582
|
+
const controlEl = this.controlEl ?? this.preConnectControlEl;
|
|
10583
|
+
controlEl.value = next;
|
|
10584
|
+
this.setFormValue(next);
|
|
10585
|
+
this.setValidity();
|
|
10586
|
+
}
|
|
10587
|
+
/**
|
|
10588
|
+
* @internal
|
|
10589
|
+
*/
|
|
10590
|
+
connectedCallback() {
|
|
10591
|
+
super.connectedCallback();
|
|
10592
|
+
this.setDefaultValue();
|
|
10593
|
+
this.maybeCreateAutoSizerEl();
|
|
10594
|
+
this.bindEvents();
|
|
10595
|
+
this.observeControlElAttrs();
|
|
10596
|
+
}
|
|
10597
|
+
/**
|
|
10598
|
+
* @internal
|
|
10599
|
+
*/
|
|
10600
|
+
disconnectedCallback() {
|
|
10601
|
+
super.disconnectedCallback();
|
|
10602
|
+
this.autoSizerObserver?.disconnect();
|
|
10603
|
+
this.controlElAttrObserver?.disconnect();
|
|
10604
|
+
}
|
|
10605
|
+
/**
|
|
10606
|
+
* Resets the value to its initial value when the form is reset.
|
|
10607
|
+
*
|
|
10608
|
+
* @internal
|
|
10609
|
+
*/
|
|
10610
|
+
formResetCallback() {
|
|
10611
|
+
this.value = this.defaultValue;
|
|
10612
|
+
}
|
|
10613
|
+
/**
|
|
10614
|
+
* @internal
|
|
10615
|
+
*/
|
|
10616
|
+
formDisabledCallback(disabled) {
|
|
10617
|
+
this.setDisabledSideEffect(disabled);
|
|
10618
|
+
this.setValidity();
|
|
10619
|
+
}
|
|
10620
|
+
/**
|
|
10621
|
+
* Reflects the {@link https://developer.mozilla.org/docs/Web/API/ElementInternals/setFormValue | `ElementInternals.setFormValue()`} method.
|
|
10622
|
+
*
|
|
10623
|
+
* @internal
|
|
10624
|
+
*/
|
|
10625
|
+
setFormValue(value, state) {
|
|
10626
|
+
this.elementInternals.setFormValue(value, value ?? state);
|
|
10627
|
+
}
|
|
10628
|
+
/**
|
|
10629
|
+
* Checks the validity of the element and returns the result.
|
|
10630
|
+
*
|
|
10631
|
+
* @public
|
|
10632
|
+
* @remarks
|
|
10633
|
+
* Reflects the {@link https://developer.mozilla.org/docs/Web/API/ElementInternals/checkValidity | `HTMLInputElement.checkValidity()`} method.
|
|
10634
|
+
*/
|
|
10635
|
+
checkValidity() {
|
|
10636
|
+
return this.elementInternals.checkValidity();
|
|
10637
|
+
}
|
|
10638
|
+
/**
|
|
10639
|
+
* Reports the validity of the element.
|
|
10640
|
+
*
|
|
10641
|
+
* @public
|
|
10642
|
+
* @remarks
|
|
10643
|
+
* Reflects the {@link https://developer.mozilla.org/docs/Web/API/ElementInternals/reportValidity | `HTMLInputElement.reportValidity()`} method.
|
|
10644
|
+
*/
|
|
10645
|
+
reportValidity() {
|
|
10646
|
+
return this.elementInternals.reportValidity();
|
|
10647
|
+
}
|
|
10648
|
+
/**
|
|
10649
|
+
* Sets the custom validity message.
|
|
10650
|
+
* @param message - The message to set
|
|
10651
|
+
*
|
|
10652
|
+
* @public
|
|
10653
|
+
*/
|
|
10654
|
+
setCustomValidity(message) {
|
|
10655
|
+
this.elementInternals.setValidity({
|
|
10656
|
+
customError: !!message
|
|
10657
|
+
}, !!message ? message.toString() : void 0);
|
|
10658
|
+
this.reportValidity();
|
|
10659
|
+
}
|
|
10660
|
+
/**
|
|
10661
|
+
* Sets the validity of the control.
|
|
10662
|
+
*
|
|
10663
|
+
* @param flags - Validity flags. If not provided, the control's `validity` will be used.
|
|
10664
|
+
* @param message - Optional message to supply. If not provided, the control's `validationMessage` will be used. If the control does not have a `validationMessage`, the message will be empty.
|
|
10665
|
+
* @param anchor - Optional anchor to use for the validation message. If not provided, the control will be used.
|
|
10666
|
+
*
|
|
10667
|
+
* @internal
|
|
10668
|
+
*/
|
|
10669
|
+
setValidity(flags, message, anchor) {
|
|
10670
|
+
if (!this.$fastController.isConnected) {
|
|
10671
|
+
return;
|
|
10672
|
+
}
|
|
10673
|
+
if (this.disabled || this.readOnly) {
|
|
10674
|
+
this.elementInternals.setValidity({});
|
|
10675
|
+
} else {
|
|
10676
|
+
this.elementInternals.setValidity(flags ?? this.controlEl.validity, message ?? this.controlEl.validationMessage, anchor ?? this.controlEl);
|
|
10677
|
+
}
|
|
10678
|
+
if (this.userInteracted) {
|
|
10679
|
+
this.toggleUserValidityState();
|
|
10680
|
+
}
|
|
10681
|
+
}
|
|
10682
|
+
/**
|
|
10683
|
+
* Selects the content in the element.
|
|
10684
|
+
*
|
|
10685
|
+
* @public
|
|
10686
|
+
*/
|
|
10687
|
+
select() {
|
|
10688
|
+
this.controlEl.select();
|
|
10689
|
+
}
|
|
10690
|
+
setDefaultValue() {
|
|
10691
|
+
this.defaultValue = this.innerHTML.trim() || this.preConnectControlEl.defaultValue || "";
|
|
10692
|
+
this.value = this.preConnectControlEl.value || this.defaultValue;
|
|
10693
|
+
this.setFormValue(this.value);
|
|
10694
|
+
this.setValidity();
|
|
10695
|
+
this.preConnectControlEl = null;
|
|
10696
|
+
}
|
|
10697
|
+
bindEvents() {
|
|
10698
|
+
this.controlEl.addEventListener("input", () => this.userInteracted = true, {
|
|
10699
|
+
once: true
|
|
10700
|
+
});
|
|
10701
|
+
}
|
|
10702
|
+
/**
|
|
10703
|
+
* Gets the content inside the light DOM, if any HTML element is present, use its `outerHTML` value.
|
|
10704
|
+
*/
|
|
10705
|
+
getContent() {
|
|
10706
|
+
return this.defaultSlottedNodes.map(node => {
|
|
10707
|
+
switch (node.nodeType) {
|
|
10708
|
+
case Node.ELEMENT_NODE:
|
|
10709
|
+
return node.outerHTML;
|
|
10710
|
+
case Node.TEXT_NODE:
|
|
10711
|
+
return node.textContent.trim();
|
|
10712
|
+
default:
|
|
10713
|
+
return "";
|
|
10714
|
+
}
|
|
10715
|
+
}).join("") || "";
|
|
10716
|
+
}
|
|
10717
|
+
observeControlElAttrs() {
|
|
10718
|
+
this.controlElAttrObserver = new MutationObserver(() => {
|
|
10719
|
+
this.setValidity();
|
|
10720
|
+
});
|
|
10721
|
+
this.controlElAttrObserver.observe(this.controlEl, {
|
|
10722
|
+
attributes: true,
|
|
10723
|
+
attributeFilter: ["disabled", "required", "readonly", "maxlength", "minlength"]
|
|
10724
|
+
});
|
|
10725
|
+
}
|
|
10726
|
+
setDisabledSideEffect(disabled) {
|
|
10727
|
+
this.elementInternals.ariaDisabled = `${disabled}`;
|
|
10728
|
+
if (this.controlEl) {
|
|
10729
|
+
this.controlEl.disabled = disabled;
|
|
10730
|
+
}
|
|
10731
|
+
if (this.labelSlottedNodes?.length) {
|
|
10732
|
+
this.labelSlottedNodes.forEach(node => node.disabled = this.disabled);
|
|
10733
|
+
}
|
|
10734
|
+
}
|
|
10735
|
+
toggleUserValidityState() {
|
|
10736
|
+
toggleState(this.elementInternals, "user-invalid", !this.validity.valid);
|
|
10737
|
+
toggleState(this.elementInternals, "user-valid", this.validity.valid);
|
|
10738
|
+
}
|
|
10739
|
+
// Technique inspired by https://css-tricks.com/the-cleanest-trick-for-autogrowing-textareas/
|
|
10740
|
+
// TODO: This should be removed after `field-sizing: content` is widely supported
|
|
10741
|
+
// https://caniuse.com/mdn-css_properties_field-sizing_content
|
|
10742
|
+
maybeCreateAutoSizerEl() {
|
|
10743
|
+
if (CSS.supports("field-sizing: content")) {
|
|
10744
|
+
return;
|
|
10745
|
+
}
|
|
10746
|
+
if (!this.autoResize) {
|
|
10747
|
+
this.autoSizerEl?.remove();
|
|
10748
|
+
this.autoSizerObserver?.disconnect();
|
|
10749
|
+
return;
|
|
10750
|
+
}
|
|
10751
|
+
if (!this.autoSizerEl) {
|
|
10752
|
+
this.autoSizerEl = document.createElement("div");
|
|
10753
|
+
this.autoSizerEl.classList.add("auto-sizer");
|
|
10754
|
+
this.autoSizerEl.ariaHidden = "true";
|
|
10755
|
+
}
|
|
10756
|
+
this.shadowRoot.prepend(this.autoSizerEl);
|
|
10757
|
+
if (!this.autoSizerObserver) {
|
|
10758
|
+
this.autoSizerObserver = new ResizeObserver((_, observer) => {
|
|
10759
|
+
const blockSizePropName = window.getComputedStyle(this).writingMode.startsWith("horizontal") ? "height" : "width";
|
|
10760
|
+
if (this.style.getPropertyValue(blockSizePropName) !== "") {
|
|
10761
|
+
this.autoSizerEl?.remove();
|
|
10762
|
+
observer.disconnect();
|
|
10763
|
+
}
|
|
10764
|
+
});
|
|
10765
|
+
}
|
|
10766
|
+
this.autoSizerObserver.observe(this);
|
|
10767
|
+
}
|
|
10768
|
+
/**
|
|
10769
|
+
* @internal
|
|
10770
|
+
*/
|
|
10771
|
+
handleControlInput() {
|
|
10772
|
+
if (this.autoResize && this.autoSizerEl) {
|
|
10773
|
+
this.autoSizerEl.textContent = this.value + " ";
|
|
10774
|
+
}
|
|
10775
|
+
this.setFormValue(this.value);
|
|
10776
|
+
this.setValidity();
|
|
10777
|
+
}
|
|
10778
|
+
/**
|
|
10779
|
+
* @internal
|
|
10780
|
+
*/
|
|
10781
|
+
handleControlChange() {
|
|
10782
|
+
this.toggleUserValidityState();
|
|
10783
|
+
this.$emit("change");
|
|
10784
|
+
}
|
|
10785
|
+
/**
|
|
10786
|
+
* @internal
|
|
10787
|
+
*/
|
|
10788
|
+
handleControlSelect() {
|
|
10789
|
+
this.$emit("select");
|
|
10790
|
+
}
|
|
10791
|
+
}
|
|
10792
|
+
/**
|
|
10793
|
+
* The form-associated flag.
|
|
10794
|
+
* @see {@link https://html.spec.whatwg.org/multipage/custom-elements.html#custom-elements-face-example | Form-associated custom elements}
|
|
10795
|
+
*
|
|
10796
|
+
* @public
|
|
10797
|
+
*/
|
|
10798
|
+
BaseTextArea.formAssociated = true;
|
|
10799
|
+
__decorateClass$3([observable], BaseTextArea.prototype, "defaultSlottedNodes", 2);
|
|
10800
|
+
__decorateClass$3([observable], BaseTextArea.prototype, "labelSlottedNodes", 2);
|
|
10801
|
+
__decorateClass$3([attr], BaseTextArea.prototype, "autocomplete", 2);
|
|
10802
|
+
__decorateClass$3([attr({
|
|
10803
|
+
attribute: "auto-resize",
|
|
10804
|
+
mode: "boolean"
|
|
10805
|
+
})], BaseTextArea.prototype, "autoResize", 2);
|
|
10806
|
+
__decorateClass$3([attr({
|
|
10807
|
+
attribute: "dirname"
|
|
10808
|
+
})], BaseTextArea.prototype, "dirName", 2);
|
|
10809
|
+
__decorateClass$3([attr({
|
|
10810
|
+
mode: "boolean"
|
|
10811
|
+
})], BaseTextArea.prototype, "disabled", 2);
|
|
10812
|
+
__decorateClass$3([attr({
|
|
10813
|
+
attribute: "display-shadow",
|
|
10814
|
+
mode: "boolean"
|
|
10815
|
+
})], BaseTextArea.prototype, "displayShadow", 2);
|
|
10816
|
+
__decorateClass$3([attr({
|
|
10817
|
+
attribute: "form"
|
|
10818
|
+
})], BaseTextArea.prototype, "initialForm", 2);
|
|
10819
|
+
__decorateClass$3([attr({
|
|
10820
|
+
attribute: "maxlength",
|
|
10821
|
+
converter: nullableNumberConverter
|
|
10822
|
+
})], BaseTextArea.prototype, "maxLength", 2);
|
|
10823
|
+
__decorateClass$3([attr({
|
|
10824
|
+
attribute: "minlength",
|
|
10825
|
+
converter: nullableNumberConverter
|
|
10826
|
+
})], BaseTextArea.prototype, "minLength", 2);
|
|
10827
|
+
__decorateClass$3([attr], BaseTextArea.prototype, "name", 2);
|
|
10828
|
+
__decorateClass$3([attr], BaseTextArea.prototype, "placeholder", 2);
|
|
10829
|
+
__decorateClass$3([attr({
|
|
10830
|
+
attribute: "readonly",
|
|
10831
|
+
mode: "boolean"
|
|
10832
|
+
})], BaseTextArea.prototype, "readOnly", 2);
|
|
10833
|
+
__decorateClass$3([attr({
|
|
10834
|
+
mode: "boolean"
|
|
10835
|
+
})], BaseTextArea.prototype, "required", 2);
|
|
10836
|
+
__decorateClass$3([attr({
|
|
10837
|
+
mode: "fromView"
|
|
10838
|
+
})], BaseTextArea.prototype, "resize", 2);
|
|
10839
|
+
__decorateClass$3([attr({
|
|
10840
|
+
mode: "boolean"
|
|
10841
|
+
})], BaseTextArea.prototype, "spellcheck", 2);
|
|
10842
|
+
class TextArea extends BaseTextArea {
|
|
10843
|
+
constructor() {
|
|
10844
|
+
super(...arguments);
|
|
10845
|
+
this.appearance = TextAreaAppearance.outline;
|
|
10846
|
+
this.block = false;
|
|
10847
|
+
}
|
|
10848
|
+
labelSlottedNodesChanged() {
|
|
10849
|
+
super.labelSlottedNodesChanged();
|
|
10850
|
+
this.labelSlottedNodes.forEach(node => {
|
|
10851
|
+
node.size = this.size;
|
|
10852
|
+
});
|
|
10853
|
+
}
|
|
10854
|
+
appearanceChanged(prev, next) {
|
|
10855
|
+
if (prev) {
|
|
10856
|
+
toggleState(this.elementInternals, `${prev}`, false);
|
|
10857
|
+
}
|
|
10858
|
+
if (!next || !Array.from(Object.values(TextAreaAppearance)).includes(next)) {
|
|
10859
|
+
toggleState(this.elementInternals, TextAreaAppearance.outline, true);
|
|
10860
|
+
} else {
|
|
10861
|
+
toggleState(this.elementInternals, `${next}`, true);
|
|
10862
|
+
}
|
|
10863
|
+
}
|
|
10864
|
+
blockChanged() {
|
|
10865
|
+
toggleState(this.elementInternals, "block", this.block);
|
|
10866
|
+
}
|
|
10867
|
+
sizeChanged(prev, next) {
|
|
10868
|
+
if (prev) {
|
|
10869
|
+
toggleState(this.elementInternals, `${prev}`, false);
|
|
10870
|
+
}
|
|
10871
|
+
if (next) {
|
|
10872
|
+
toggleState(this.elementInternals, `${next}`, true);
|
|
10873
|
+
}
|
|
10874
|
+
}
|
|
10875
|
+
/**
|
|
10876
|
+
* @internal
|
|
10877
|
+
*/
|
|
10878
|
+
handleChange(_, propertyName) {
|
|
10879
|
+
switch (propertyName) {
|
|
10880
|
+
case "size":
|
|
10881
|
+
this.labelSlottedNodes.forEach(node => {
|
|
10882
|
+
node.size = this.size;
|
|
10883
|
+
});
|
|
10884
|
+
break;
|
|
10885
|
+
case "appearance":
|
|
10886
|
+
case "displayShadow":
|
|
10887
|
+
this.maybeDisplayShadow();
|
|
10888
|
+
break;
|
|
10889
|
+
}
|
|
10890
|
+
}
|
|
10891
|
+
/**
|
|
10892
|
+
* @internal
|
|
10893
|
+
*/
|
|
10894
|
+
connectedCallback() {
|
|
10895
|
+
super.connectedCallback();
|
|
10896
|
+
this.maybeDisplayShadow();
|
|
10897
|
+
Observable.getNotifier(this).subscribe(this, "appearance");
|
|
10898
|
+
Observable.getNotifier(this).subscribe(this, "displayShadow");
|
|
10899
|
+
Observable.getNotifier(this).subscribe(this, "size");
|
|
10900
|
+
}
|
|
10901
|
+
/**
|
|
10902
|
+
* @internal
|
|
10903
|
+
*/
|
|
10904
|
+
disconnectedCallback() {
|
|
10905
|
+
super.disconnectedCallback();
|
|
10906
|
+
Observable.getNotifier(this).unsubscribe(this, "appearance");
|
|
10907
|
+
Observable.getNotifier(this).unsubscribe(this, "displayShadow");
|
|
10908
|
+
Observable.getNotifier(this).unsubscribe(this, "size");
|
|
10909
|
+
}
|
|
10910
|
+
maybeDisplayShadow() {
|
|
10911
|
+
toggleState(this.elementInternals, "display-shadow", this.displayShadow && TextAreaAppearancesForDisplayShadow.includes(this.appearance));
|
|
10912
|
+
}
|
|
10913
|
+
}
|
|
10914
|
+
__decorateClass$3([attr({
|
|
10915
|
+
mode: "fromView"
|
|
10916
|
+
})], TextArea.prototype, "appearance", 2);
|
|
10917
|
+
__decorateClass$3([attr({
|
|
10918
|
+
mode: "boolean"
|
|
10919
|
+
})], TextArea.prototype, "block", 2);
|
|
10920
|
+
__decorateClass$3([attr], TextArea.prototype, "size", 2);
|
|
10921
|
+
|
|
10922
|
+
const styles$3 = css`
|
|
10923
|
+
${display("inline-block")}
|
|
10924
|
+
|
|
10925
|
+
: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`
|
|
10926
|
+
:host{--border-color:FieldText;--border-block-end-color:FieldText;--focus-indicator-color:Highlight;--placeholder-color:FieldText}:host(:hover),:host(:active),:host(:focus-within){--border-color:Highlight;--border-block-end-color:Highlight}:host(:disabled){--color:GrayText;--border-color:GrayText;--border-block-end-color:GrayText;--placeholder-color:GrayText}`));
|
|
10927
|
+
|
|
10928
|
+
function textAreaTemplate() {
|
|
10929
|
+
return html`<template><label ${ref("labelEl")} for="control" part="label"><slot name="label" ${slotted({
|
|
10930
|
+
property: "labelSlottedNodes",
|
|
10931
|
+
filter: whitespaceFilter
|
|
10932
|
+
})}></slot></label><div class="root" part="root"><textarea ${ref("controlEl")} id="control" class="control" part="control" ?required="${x => x.required}" ?disabled="${x => x.disabled}" ?readonly="${x => x.readOnly}" ?spellcheck="${x => x.spellcheck}" autocomplete="${x => x.autocomplete}" maxlength="${x => x.maxLength}" minlength="${x => x.minLength}" placeholder="${x => x.placeholder}" @change="${x => x.handleControlChange()}" @select="${x => x.handleControlSelect()}" @input="${x => x.handleControlInput()}"></textarea></div><div hidden><slot ${slotted({
|
|
10933
|
+
property: "defaultSlottedNodes",
|
|
10934
|
+
filter: whitespaceFilter
|
|
10935
|
+
})}></slot></div></template>`;
|
|
10936
|
+
}
|
|
10937
|
+
const template$3 = textAreaTemplate();
|
|
10938
|
+
|
|
10939
|
+
const definition$3 = TextArea.compose({
|
|
10940
|
+
name: `${FluentDesignSystem.prefix}-textarea`,
|
|
10392
10941
|
template: template$3,
|
|
10393
|
-
styles: styles$3
|
|
10942
|
+
styles: styles$3,
|
|
10943
|
+
shadowOptions: {
|
|
10944
|
+
delegatesFocus: true
|
|
10945
|
+
}
|
|
10394
10946
|
});
|
|
10395
10947
|
|
|
10396
10948
|
definition$3.define(FluentDesignSystem.registry);
|
|
@@ -11038,7 +11590,7 @@ __decorateClass([attr({
|
|
|
11038
11590
|
})], ToggleButton.prototype, "mixed", 2);
|
|
11039
11591
|
|
|
11040
11592
|
const styles = css`
|
|
11041
|
-
${styles$
|
|
11593
|
+
${styles$y}
|
|
11042
11594
|
|
|
11043
11595
|
: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`
|
|
11044
11596
|
:host(${pressedState}),:host(${pressedState}${primaryState}),:host(${pressedState}${subtleState}),:host(${pressedState}${outlineState}),:host(${pressedState}${transparentState}){background:SelectedItem;color:SelectedItemText}`));
|