@fluentui/web-components 3.0.0-beta.26 → 3.0.0-beta.28
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +22 -2
- package/dist/dts/anchor-button/anchor-button.d.ts +82 -78
- package/dist/dts/anchor-button/anchor-button.options.d.ts +21 -0
- package/dist/dts/button/button.styles.d.ts +4 -0
- package/dist/dts/divider/divider.d.ts +24 -1
- package/dist/dts/index.d.ts +0 -1
- package/dist/dts/progress-bar/index.d.ts +0 -1
- package/dist/dts/progress-bar/progress-bar.d.ts +56 -13
- package/dist/dts/progress-bar/progress-bar.options.d.ts +1 -10
- package/dist/dts/progress-bar/progress-bar.template.d.ts +1 -2
- package/dist/esm/anchor-button/anchor-button.definition.js +0 -3
- package/dist/esm/anchor-button/anchor-button.definition.js.map +1 -1
- package/dist/esm/anchor-button/anchor-button.js +78 -67
- package/dist/esm/anchor-button/anchor-button.js.map +1 -1
- package/dist/esm/anchor-button/anchor-button.options.js +15 -0
- package/dist/esm/anchor-button/anchor-button.options.js.map +1 -1
- package/dist/esm/anchor-button/anchor-button.styles.js +6 -258
- package/dist/esm/anchor-button/anchor-button.styles.js.map +1 -1
- package/dist/esm/anchor-button/anchor-button.template.js +7 -35
- package/dist/esm/anchor-button/anchor-button.template.js.map +1 -1
- package/dist/esm/button/button.styles.js +16 -5
- package/dist/esm/button/button.styles.js.map +1 -1
- package/dist/esm/dialog-body/dialog-body.template.js +1 -1
- package/dist/esm/dialog-body/dialog-body.template.js.map +1 -1
- package/dist/esm/divider/divider.js +38 -13
- package/dist/esm/divider/divider.js.map +1 -1
- package/dist/esm/divider/divider.template.js +1 -9
- package/dist/esm/divider/divider.template.js.map +1 -1
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/progress-bar/index.js.map +1 -1
- package/dist/esm/progress-bar/progress-bar.js +62 -11
- package/dist/esm/progress-bar/progress-bar.js.map +1 -1
- package/dist/esm/progress-bar/progress-bar.styles.js +48 -127
- package/dist/esm/progress-bar/progress-bar.styles.js.map +1 -1
- package/dist/esm/progress-bar/progress-bar.template.js +8 -26
- package/dist/esm/progress-bar/progress-bar.template.js.map +1 -1
- package/dist/web-components.d.ts +159 -331
- package/dist/web-components.js +446 -371
- package/dist/web-components.min.js +214 -224
- package/package.json +1 -1
- package/dist/dts/progress-bar/base-progress.d.ts +0 -41
- package/dist/esm/progress-bar/base-progress.js +0 -56
- package/dist/esm/progress-bar/base-progress.js.map +0 -1
package/dist/web-components.js
CHANGED
|
@@ -774,6 +774,21 @@ const Observable = FAST.getById(KernelServiceId.observable, () => {
|
|
|
774
774
|
function observable(target, nameOrAccessor) {
|
|
775
775
|
Observable.defineProperty(target, nameOrAccessor);
|
|
776
776
|
}
|
|
777
|
+
/**
|
|
778
|
+
* Decorator: Marks a property getter as having volatile observable dependencies.
|
|
779
|
+
* @param target - The target that the property is defined on.
|
|
780
|
+
* @param name - The property name.
|
|
781
|
+
* @param name - The existing descriptor.
|
|
782
|
+
* @public
|
|
783
|
+
*/
|
|
784
|
+
function volatile(target, name, descriptor) {
|
|
785
|
+
return Object.assign({}, descriptor, {
|
|
786
|
+
get() {
|
|
787
|
+
Observable.trackVolatile();
|
|
788
|
+
return descriptor.get.apply(this);
|
|
789
|
+
}
|
|
790
|
+
});
|
|
791
|
+
}
|
|
777
792
|
const contextEvent = FAST.getById(KernelServiceId.contextEvent, () => {
|
|
778
793
|
let current = null;
|
|
779
794
|
return {
|
|
@@ -3386,70 +3401,70 @@ function uniqueId(prefix = "") {
|
|
|
3386
3401
|
return `${prefix}${uniqueIdCounter++}`;
|
|
3387
3402
|
}
|
|
3388
3403
|
|
|
3389
|
-
var __defProp$
|
|
3390
|
-
var __getOwnPropDesc$
|
|
3391
|
-
var __decorateClass$
|
|
3392
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
3404
|
+
var __defProp$r = Object.defineProperty;
|
|
3405
|
+
var __getOwnPropDesc$r = Object.getOwnPropertyDescriptor;
|
|
3406
|
+
var __decorateClass$r = (decorators, target, key, kind) => {
|
|
3407
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$r(target, key) : target;
|
|
3393
3408
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
3394
|
-
if (kind && result) __defProp$
|
|
3409
|
+
if (kind && result) __defProp$r(target, key, result);
|
|
3395
3410
|
return result;
|
|
3396
3411
|
};
|
|
3397
3412
|
class ARIAGlobalStatesAndProperties {}
|
|
3398
|
-
__decorateClass$
|
|
3413
|
+
__decorateClass$r([attr({
|
|
3399
3414
|
attribute: "aria-atomic"
|
|
3400
3415
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaAtomic", 2);
|
|
3401
|
-
__decorateClass$
|
|
3416
|
+
__decorateClass$r([attr({
|
|
3402
3417
|
attribute: "aria-busy"
|
|
3403
3418
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaBusy", 2);
|
|
3404
|
-
__decorateClass$
|
|
3419
|
+
__decorateClass$r([attr({
|
|
3405
3420
|
attribute: "aria-controls"
|
|
3406
3421
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaControls", 2);
|
|
3407
|
-
__decorateClass$
|
|
3422
|
+
__decorateClass$r([attr({
|
|
3408
3423
|
attribute: "aria-current"
|
|
3409
3424
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaCurrent", 2);
|
|
3410
|
-
__decorateClass$
|
|
3425
|
+
__decorateClass$r([attr({
|
|
3411
3426
|
attribute: "aria-describedby"
|
|
3412
3427
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaDescribedby", 2);
|
|
3413
|
-
__decorateClass$
|
|
3428
|
+
__decorateClass$r([attr({
|
|
3414
3429
|
attribute: "aria-details"
|
|
3415
3430
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaDetails", 2);
|
|
3416
|
-
__decorateClass$
|
|
3431
|
+
__decorateClass$r([attr({
|
|
3417
3432
|
attribute: "aria-disabled"
|
|
3418
3433
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaDisabled", 2);
|
|
3419
|
-
__decorateClass$
|
|
3434
|
+
__decorateClass$r([attr({
|
|
3420
3435
|
attribute: "aria-errormessage"
|
|
3421
3436
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaErrormessage", 2);
|
|
3422
|
-
__decorateClass$
|
|
3437
|
+
__decorateClass$r([attr({
|
|
3423
3438
|
attribute: "aria-flowto"
|
|
3424
3439
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaFlowto", 2);
|
|
3425
|
-
__decorateClass$
|
|
3440
|
+
__decorateClass$r([attr({
|
|
3426
3441
|
attribute: "aria-haspopup"
|
|
3427
3442
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaHaspopup", 2);
|
|
3428
|
-
__decorateClass$
|
|
3443
|
+
__decorateClass$r([attr({
|
|
3429
3444
|
attribute: "aria-hidden"
|
|
3430
3445
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaHidden", 2);
|
|
3431
|
-
__decorateClass$
|
|
3446
|
+
__decorateClass$r([attr({
|
|
3432
3447
|
attribute: "aria-invalid"
|
|
3433
3448
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaInvalid", 2);
|
|
3434
|
-
__decorateClass$
|
|
3449
|
+
__decorateClass$r([attr({
|
|
3435
3450
|
attribute: "aria-keyshortcuts"
|
|
3436
3451
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaKeyshortcuts", 2);
|
|
3437
|
-
__decorateClass$
|
|
3452
|
+
__decorateClass$r([attr({
|
|
3438
3453
|
attribute: "aria-label"
|
|
3439
3454
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaLabel", 2);
|
|
3440
|
-
__decorateClass$
|
|
3455
|
+
__decorateClass$r([attr({
|
|
3441
3456
|
attribute: "aria-labelledby"
|
|
3442
3457
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaLabelledby", 2);
|
|
3443
|
-
__decorateClass$
|
|
3458
|
+
__decorateClass$r([attr({
|
|
3444
3459
|
attribute: "aria-live"
|
|
3445
3460
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaLive", 2);
|
|
3446
|
-
__decorateClass$
|
|
3461
|
+
__decorateClass$r([attr({
|
|
3447
3462
|
attribute: "aria-owns"
|
|
3448
3463
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaOwns", 2);
|
|
3449
|
-
__decorateClass$
|
|
3464
|
+
__decorateClass$r([attr({
|
|
3450
3465
|
attribute: "aria-relevant"
|
|
3451
3466
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaRelevant", 2);
|
|
3452
|
-
__decorateClass$
|
|
3467
|
+
__decorateClass$r([attr({
|
|
3453
3468
|
attribute: "aria-roledescription"
|
|
3454
3469
|
})], ARIAGlobalStatesAndProperties.prototype, "ariaRoledescription", 2);
|
|
3455
3470
|
|
|
@@ -3618,12 +3633,12 @@ function applyMixins(derivedCtor, ...baseCtors) {
|
|
|
3618
3633
|
});
|
|
3619
3634
|
}
|
|
3620
3635
|
|
|
3621
|
-
var __defProp$
|
|
3622
|
-
var __getOwnPropDesc$
|
|
3623
|
-
var __decorateClass$
|
|
3624
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
3636
|
+
var __defProp$q = Object.defineProperty;
|
|
3637
|
+
var __getOwnPropDesc$q = Object.getOwnPropertyDescriptor;
|
|
3638
|
+
var __decorateClass$q = (decorators, target, key, kind) => {
|
|
3639
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$q(target, key) : target;
|
|
3625
3640
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
3626
|
-
if (kind && result) __defProp$
|
|
3641
|
+
if (kind && result) __defProp$q(target, key, result);
|
|
3627
3642
|
return result;
|
|
3628
3643
|
};
|
|
3629
3644
|
class AccordionItem extends FASTElement {
|
|
@@ -3645,23 +3660,23 @@ class AccordionItem extends FASTElement {
|
|
|
3645
3660
|
};
|
|
3646
3661
|
}
|
|
3647
3662
|
}
|
|
3648
|
-
__decorateClass$
|
|
3663
|
+
__decorateClass$q([attr({
|
|
3649
3664
|
attribute: "heading-level",
|
|
3650
3665
|
mode: "fromView",
|
|
3651
3666
|
converter: nullableNumberConverter
|
|
3652
3667
|
})], AccordionItem.prototype, "headinglevel", 2);
|
|
3653
|
-
__decorateClass$
|
|
3668
|
+
__decorateClass$q([attr({
|
|
3654
3669
|
mode: "boolean"
|
|
3655
3670
|
})], AccordionItem.prototype, "expanded", 2);
|
|
3656
|
-
__decorateClass$
|
|
3671
|
+
__decorateClass$q([attr({
|
|
3657
3672
|
mode: "boolean"
|
|
3658
3673
|
})], AccordionItem.prototype, "disabled", 2);
|
|
3659
|
-
__decorateClass$
|
|
3660
|
-
__decorateClass$
|
|
3661
|
-
__decorateClass$
|
|
3674
|
+
__decorateClass$q([attr], AccordionItem.prototype, "id", 2);
|
|
3675
|
+
__decorateClass$q([attr], AccordionItem.prototype, "size", 2);
|
|
3676
|
+
__decorateClass$q([attr({
|
|
3662
3677
|
mode: "boolean"
|
|
3663
3678
|
})], AccordionItem.prototype, "block", 2);
|
|
3664
|
-
__decorateClass$
|
|
3679
|
+
__decorateClass$q([attr({
|
|
3665
3680
|
attribute: "expand-icon-position"
|
|
3666
3681
|
})], AccordionItem.prototype, "expandIconPosition", 2);
|
|
3667
3682
|
applyMixins(AccordionItem, StartEnd);
|
|
@@ -3748,14 +3763,12 @@ const colorPaletteRedForeground1 = "var(--colorPaletteRedForeground1)";
|
|
|
3748
3763
|
const colorPaletteRedForeground2 = "var(--colorPaletteRedForeground2)";
|
|
3749
3764
|
const colorPaletteRedForeground3 = "var(--colorPaletteRedForeground3)";
|
|
3750
3765
|
const colorPaletteGreenBackground1 = "var(--colorPaletteGreenBackground1)";
|
|
3751
|
-
const colorPaletteGreenBackground2 = "var(--colorPaletteGreenBackground2)";
|
|
3752
3766
|
const colorPaletteGreenBackground3 = "var(--colorPaletteGreenBackground3)";
|
|
3753
3767
|
const colorPaletteGreenBorder2 = "var(--colorPaletteGreenBorder2)";
|
|
3754
3768
|
const colorPaletteGreenForeground1 = "var(--colorPaletteGreenForeground1)";
|
|
3755
3769
|
const colorPaletteGreenForeground2 = "var(--colorPaletteGreenForeground2)";
|
|
3756
3770
|
const colorPaletteGreenForeground3 = "var(--colorPaletteGreenForeground3)";
|
|
3757
3771
|
const colorPaletteDarkOrangeBackground1 = "var(--colorPaletteDarkOrangeBackground1)";
|
|
3758
|
-
const colorPaletteDarkOrangeBackground2 = "var(--colorPaletteDarkOrangeBackground2)";
|
|
3759
3772
|
const colorPaletteDarkOrangeBackground3 = "var(--colorPaletteDarkOrangeBackground3)";
|
|
3760
3773
|
const colorPaletteDarkOrangeBorder1 = "var(--colorPaletteDarkOrangeBorder1)";
|
|
3761
3774
|
const colorPaletteDarkOrangeForeground1 = "var(--colorPaletteDarkOrangeForeground1)";
|
|
@@ -3949,12 +3962,12 @@ const AccordionExpandMode = {
|
|
|
3949
3962
|
multi: "multi"
|
|
3950
3963
|
};
|
|
3951
3964
|
|
|
3952
|
-
var __defProp$
|
|
3953
|
-
var __getOwnPropDesc$
|
|
3954
|
-
var __decorateClass$
|
|
3955
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
3965
|
+
var __defProp$p = Object.defineProperty;
|
|
3966
|
+
var __getOwnPropDesc$p = Object.getOwnPropertyDescriptor;
|
|
3967
|
+
var __decorateClass$p = (decorators, target, key, kind) => {
|
|
3968
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$p(target, key) : target;
|
|
3956
3969
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
3957
|
-
if (kind && result) __defProp$
|
|
3970
|
+
if (kind && result) __defProp$p(target, key, result);
|
|
3958
3971
|
return result;
|
|
3959
3972
|
};
|
|
3960
3973
|
class Accordion extends FASTElement {
|
|
@@ -4132,10 +4145,10 @@ class Accordion extends FASTElement {
|
|
|
4132
4145
|
}
|
|
4133
4146
|
}
|
|
4134
4147
|
}
|
|
4135
|
-
__decorateClass$
|
|
4148
|
+
__decorateClass$p([attr({
|
|
4136
4149
|
attribute: "expand-mode"
|
|
4137
4150
|
})], Accordion.prototype, "expandmode", 2);
|
|
4138
|
-
__decorateClass$
|
|
4151
|
+
__decorateClass$p([observable], Accordion.prototype, "slottedAccordionItems", 2);
|
|
4139
4152
|
|
|
4140
4153
|
const styles$s = css`
|
|
4141
4154
|
${display("flex")}
|
|
@@ -4158,108 +4171,156 @@ const definition$t = Accordion.compose({
|
|
|
4158
4171
|
|
|
4159
4172
|
definition$t.define(FluentDesignSystem.registry);
|
|
4160
4173
|
|
|
4161
|
-
|
|
4162
|
-
|
|
4163
|
-
|
|
4164
|
-
|
|
4174
|
+
const ButtonType = {
|
|
4175
|
+
submit: "submit",
|
|
4176
|
+
reset: "reset",
|
|
4177
|
+
button: "button"
|
|
4178
|
+
};
|
|
4179
|
+
|
|
4180
|
+
const AnchorAttributes = {
|
|
4181
|
+
download: "download",
|
|
4182
|
+
href: "href",
|
|
4183
|
+
hreflang: "hreflang",
|
|
4184
|
+
ping: "ping",
|
|
4185
|
+
referrerpolicy: "referrerpolicy",
|
|
4186
|
+
rel: "rel",
|
|
4187
|
+
target: "target",
|
|
4188
|
+
type: "type"
|
|
4189
|
+
};
|
|
4190
|
+
|
|
4191
|
+
var __defProp$o = Object.defineProperty;
|
|
4192
|
+
var __getOwnPropDesc$o = Object.getOwnPropertyDescriptor;
|
|
4193
|
+
var __decorateClass$o = (decorators, target, key, kind) => {
|
|
4194
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$o(target, key) : target;
|
|
4165
4195
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
4166
|
-
if (kind && result) __defProp$
|
|
4196
|
+
if (kind && result) __defProp$o(target, key, result);
|
|
4167
4197
|
return result;
|
|
4168
4198
|
};
|
|
4169
4199
|
class AnchorButton extends FASTElement {
|
|
4170
4200
|
constructor() {
|
|
4171
|
-
super(
|
|
4172
|
-
|
|
4173
|
-
|
|
4174
|
-
|
|
4201
|
+
super();
|
|
4202
|
+
/**
|
|
4203
|
+
* The internal {@link https://developer.mozilla.org/docs/Web/API/ElementInternals | `ElementInternals`} instance for the component.
|
|
4204
|
+
*
|
|
4205
|
+
* @internal
|
|
4206
|
+
*/
|
|
4207
|
+
this.elementInternals = this.attachInternals();
|
|
4175
4208
|
/**
|
|
4176
|
-
*
|
|
4209
|
+
* The proxy anchor element
|
|
4210
|
+
* @internal
|
|
4177
4211
|
*/
|
|
4178
|
-
this.
|
|
4179
|
-
|
|
4180
|
-
|
|
4181
|
-
return;
|
|
4182
|
-
}
|
|
4183
|
-
};
|
|
4184
|
-
}
|
|
4185
|
-
disabledChanged(prev, next) {
|
|
4186
|
-
if (this.disabled) {
|
|
4187
|
-
this.setAttribute("aria-disabled", "true");
|
|
4188
|
-
this.setAttribute("tabindex", "-1");
|
|
4189
|
-
} else {
|
|
4190
|
-
this.removeAttribute("aria-disabled");
|
|
4191
|
-
this.removeAttribute("tabindex");
|
|
4192
|
-
}
|
|
4193
|
-
}
|
|
4194
|
-
disabledFocusableChanged(prev, next) {
|
|
4195
|
-
if (!this.$fastController.isConnected) {
|
|
4196
|
-
return;
|
|
4197
|
-
}
|
|
4198
|
-
if (this.disabledFocusable) {
|
|
4199
|
-
this.setAttribute("aria-disabled", "true");
|
|
4200
|
-
} else {
|
|
4201
|
-
this.removeAttribute("aria-disabled");
|
|
4202
|
-
}
|
|
4212
|
+
this.internalProxyAnchor = this.createProxyElement();
|
|
4213
|
+
this.iconOnly = false;
|
|
4214
|
+
this.elementInternals.role = "link";
|
|
4203
4215
|
}
|
|
4204
4216
|
connectedCallback() {
|
|
4205
4217
|
super.connectedCallback();
|
|
4206
|
-
this.
|
|
4218
|
+
Observable.getNotifier(this).subscribe(this);
|
|
4219
|
+
Object.keys(this.$fastController.definition.attributeLookup).forEach(key => {
|
|
4220
|
+
this.handleChange(this, key);
|
|
4221
|
+
});
|
|
4222
|
+
this.append(this.internalProxyAnchor);
|
|
4207
4223
|
}
|
|
4208
4224
|
disconnectedCallback() {
|
|
4209
4225
|
super.disconnectedCallback();
|
|
4210
|
-
this.
|
|
4211
|
-
}
|
|
4212
|
-
|
|
4213
|
-
|
|
4214
|
-
|
|
4215
|
-
|
|
4216
|
-
|
|
4217
|
-
|
|
4218
|
-
|
|
4219
|
-
|
|
4220
|
-
|
|
4221
|
-
|
|
4222
|
-
|
|
4223
|
-
|
|
4224
|
-
|
|
4225
|
-
|
|
4226
|
+
Observable.getNotifier(this).unsubscribe(this);
|
|
4227
|
+
}
|
|
4228
|
+
/**
|
|
4229
|
+
* Handles changes to observable properties
|
|
4230
|
+
* @internal
|
|
4231
|
+
* @param source
|
|
4232
|
+
* @param propertyName
|
|
4233
|
+
*/
|
|
4234
|
+
handleChange(source, propertyName) {
|
|
4235
|
+
if (propertyName in AnchorAttributes) {
|
|
4236
|
+
const attribute = this.$fastController.definition.attributeLookup[propertyName]?.attribute;
|
|
4237
|
+
if (attribute) {
|
|
4238
|
+
this.handleProxyAttributeChange(attribute, this[propertyName]);
|
|
4239
|
+
}
|
|
4240
|
+
}
|
|
4241
|
+
}
|
|
4242
|
+
/**
|
|
4243
|
+
* Handles the anchor click event.
|
|
4244
|
+
*
|
|
4245
|
+
* @param e - The event object
|
|
4246
|
+
* @internal
|
|
4247
|
+
*/
|
|
4248
|
+
clickHandler() {
|
|
4249
|
+
this.internalProxyAnchor.click();
|
|
4250
|
+
return true;
|
|
4251
|
+
}
|
|
4252
|
+
/**
|
|
4253
|
+
* Handles keypress events for the anchor.
|
|
4254
|
+
*
|
|
4255
|
+
* @param e - the keyboard event
|
|
4256
|
+
* @returns - the return value of the click handler
|
|
4257
|
+
* @public
|
|
4258
|
+
*/
|
|
4259
|
+
keypressHandler(e) {
|
|
4260
|
+
if (e.key === keyEnter) {
|
|
4261
|
+
this.internalProxyAnchor.click();
|
|
4262
|
+
return;
|
|
4263
|
+
}
|
|
4264
|
+
return true;
|
|
4265
|
+
}
|
|
4266
|
+
/**
|
|
4267
|
+
* A method for updating proxy attributes when attributes have changed
|
|
4268
|
+
* @internal
|
|
4269
|
+
* @param attribute
|
|
4270
|
+
* @param value
|
|
4271
|
+
*/
|
|
4272
|
+
handleProxyAttributeChange(attribute, value) {
|
|
4273
|
+
if (value) {
|
|
4274
|
+
this.internalProxyAnchor.setAttribute(attribute, value);
|
|
4275
|
+
} else {
|
|
4276
|
+
this.internalProxyAnchor.removeAttribute(attribute);
|
|
4277
|
+
}
|
|
4278
|
+
}
|
|
4279
|
+
createProxyElement() {
|
|
4280
|
+
const proxy = this.internalProxyAnchor ?? document.createElement("a");
|
|
4281
|
+
proxy.hidden = true;
|
|
4282
|
+
return proxy;
|
|
4283
|
+
}
|
|
4284
|
+
}
|
|
4285
|
+
__decorateClass$o([attr], AnchorButton.prototype, "download", 2);
|
|
4286
|
+
__decorateClass$o([attr], AnchorButton.prototype, "href", 2);
|
|
4287
|
+
__decorateClass$o([attr], AnchorButton.prototype, "hreflang", 2);
|
|
4288
|
+
__decorateClass$o([attr], AnchorButton.prototype, "ping", 2);
|
|
4289
|
+
__decorateClass$o([attr], AnchorButton.prototype, "referrerpolicy", 2);
|
|
4290
|
+
__decorateClass$o([attr], AnchorButton.prototype, "rel", 2);
|
|
4291
|
+
__decorateClass$o([attr], AnchorButton.prototype, "target", 2);
|
|
4292
|
+
__decorateClass$o([attr], AnchorButton.prototype, "type", 2);
|
|
4293
|
+
__decorateClass$o([attr], AnchorButton.prototype, "appearance", 2);
|
|
4294
|
+
__decorateClass$o([attr], AnchorButton.prototype, "shape", 2);
|
|
4295
|
+
__decorateClass$o([attr], AnchorButton.prototype, "size", 2);
|
|
4296
|
+
__decorateClass$o([attr({
|
|
4226
4297
|
attribute: "icon-only",
|
|
4227
4298
|
mode: "boolean"
|
|
4228
4299
|
})], AnchorButton.prototype, "iconOnly", 2);
|
|
4229
|
-
|
|
4230
|
-
mode: "boolean"
|
|
4231
|
-
})], AnchorButton.prototype, "disabled", 2);
|
|
4232
|
-
__decorateClass$p([attr({
|
|
4233
|
-
attribute: "disabled-focusable",
|
|
4234
|
-
mode: "boolean"
|
|
4235
|
-
})], AnchorButton.prototype, "disabledFocusable", 2);
|
|
4236
|
-
class DelegatesARIALink {}
|
|
4237
|
-
__decorateClass$p([attr({
|
|
4238
|
-
attribute: "aria-expanded"
|
|
4239
|
-
})], DelegatesARIALink.prototype, "ariaExpanded", 2);
|
|
4240
|
-
applyMixins(DelegatesARIALink, ARIAGlobalStatesAndProperties);
|
|
4241
|
-
applyMixins(AnchorButton, StartEnd, DelegatesARIALink);
|
|
4300
|
+
applyMixins(AnchorButton, StartEnd);
|
|
4242
4301
|
|
|
4243
|
-
const
|
|
4302
|
+
const baseButtonStyles = css`
|
|
4244
4303
|
${display("inline-flex")}
|
|
4245
4304
|
|
|
4246
|
-
:host{--icon-spacing:${spacingHorizontalSNudge};contain:layout style;vertical-align:middle
|
|
4247
|
-
|
|
4248
|
-
|
|
4249
|
-
|
|
4305
|
+
:host{--icon-spacing:${spacingHorizontalSNudge};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}[slot='start'],::slotted([slot='start']){margin-inline-end:var(--icon-spacing)}[slot='end'],::slotted([slot='end']){margin-inline-start:var(--icon-spacing)}:host([icon-only]){min-width:32px;max-width:32px}:host([size='small']){--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([size='small'][icon-only]){min-width:24px;max-width:24px}:host([size='large']){min-height:40px;border-radius:${borderRadiusLarge};padding:0 ${spacingHorizontalL};font-size:${fontSizeBase400};line-height:${lineHeightBase400}}:host([size='large'][icon-only]){min-width:40px;max-width:40px}:host([size='large']) ::slotted(svg){font-size:24px;height:24px;width:24px}:host([shape='circular']),:host([shape='circular']:focus-visible){border-radius:${borderRadiusCircular}}:host([shape='square']),:host([shape='square']:focus-visible){border-radius:${borderRadiusNone}}:host([appearance='primary']){background-color:${colorBrandBackground};color:${colorNeutralForegroundOnBrand};border-color:transparent}:host([appearance='primary']:hover){background-color:${colorBrandBackgroundHover}}:host([appearance='primary']:hover),:host([appearance='primary']:hover:active){border-color:transparent;color:${colorNeutralForegroundOnBrand}}:host([appearance='primary']:hover:active){background-color:${colorBrandBackgroundPressed}}:host([appearance='primary']:focus-visible){border-color:${colorNeutralForegroundOnBrand};box-shadow:${shadow2},0 0 0 2px ${colorStrokeFocus2}}:host([appearance='outline']){background-color:${colorTransparentBackground}}:host([appearance='outline']:hover){background-color:${colorTransparentBackgroundHover}}:host([appearance='outline']:hover:active){background-color:${colorTransparentBackgroundPressed}}:host([appearance='subtle']){background-color:${colorSubtleBackground};color:${colorNeutralForeground2};border-color:transparent}:host([appearance='subtle']:hover){background-color:${colorSubtleBackgroundHover};color:${colorNeutralForeground2Hover};border-color:transparent}:host([appearance='subtle']:hover:active){background-color:${colorSubtleBackgroundPressed};color:${colorNeutralForeground2Pressed};border-color:transparent}:host([appearance='subtle']:hover) ::slotted(svg){fill:${colorNeutralForeground2BrandHover}}:host([appearance='subtle']:hover:active) ::slotted(svg){fill:${colorNeutralForeground2BrandPressed}}:host([appearance='transparent']){background-color:${colorTransparentBackground};color:${colorNeutralForeground2}}:host([appearance='transparent']:hover){background-color:${colorTransparentBackgroundHover};color:${colorNeutralForeground2BrandHover}}:host([appearance='transparent']:hover:active){background-color:${colorTransparentBackgroundPressed};color:${colorNeutralForeground2BrandPressed}}:host([appearance='transparent']),:host([appearance='transparent']:hover),:host([appearance='transparent']:hover:active){border-color:transparent}`;
|
|
4306
|
+
const styles$r = css`
|
|
4307
|
+
${baseButtonStyles}
|
|
4308
|
+
|
|
4309
|
+
: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(:is([disabled][appearance='primary'],[disabled-focusable][appearance='primary'])),:host(:is([disabled][appearance='primary'],[disabled-focusable][appearance='primary']):hover),:host(:is([disabled][appearance='primary'],[disabled-focusable][appearance='primary']):hover:active){border-color:transparent}:host(:is([disabled][appearance='outline'],[disabled-focusable][appearance='outline'])),:host(:is([disabled][appearance='outline'],[disabled-focusable][appearance='outline']):hover),:host(:is([disabled][appearance='outline'],[disabled-focusable][appearance='outline']):hover:active){background-color:${colorTransparentBackground}}:host(:is([disabled][appearance='subtle'],[disabled-focusable][appearance='subtle'])),:host(:is([disabled][appearance='subtle'],[disabled-focusable][appearance='subtle']):hover),:host(:is([disabled][appearance='subtle'],[disabled-focusable][appearance='subtle']):hover:active){background-color:${colorTransparentBackground};border-color:transparent}:host(:is([disabled][appearance='transparent'],[disabled-focusable][appearance='transparent'])),:host(:is([disabled][appearance='transparent'],[disabled-focusable][appearance='transparent']):hover),:host(:is([disabled][appearance='transparent'],[disabled-focusable][appearance='transparent']):hover:active){border-color:transparent;background-color:${colorTransparentBackground}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
4310
|
+
:host{background:ButtonFace;color:ButtonText}:host(:is(:hover,:focus-visible)){border-color:Highlight}`));
|
|
4311
|
+
|
|
4312
|
+
const styles$q = baseButtonStyles.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
4313
|
+
:host{border-color:LinkText;color:LinkText}`));
|
|
4250
4314
|
|
|
4251
4315
|
function anchorTemplate(options = {}) {
|
|
4252
|
-
return html`<
|
|
4316
|
+
return html`<template tabindex="0" @click="${x => x.clickHandler()}" @keypress="${(x, c) => x.keypressHandler(c.event)}">${startSlotTemplate(options)}<span class="content" part="content"><slot></slot></span>${endSlotTemplate(options)}</template>`;
|
|
4253
4317
|
}
|
|
4254
4318
|
const template$s = anchorTemplate();
|
|
4255
4319
|
|
|
4256
4320
|
const definition$s = AnchorButton.compose({
|
|
4257
4321
|
name: `${FluentDesignSystem.prefix}-anchor-button`,
|
|
4258
4322
|
template: template$s,
|
|
4259
|
-
styles: styles$
|
|
4260
|
-
shadowOptions: {
|
|
4261
|
-
delegatesFocus: true
|
|
4262
|
-
}
|
|
4323
|
+
styles: styles$q
|
|
4263
4324
|
});
|
|
4264
4325
|
|
|
4265
4326
|
definition$s.define(FluentDesignSystem.registry);
|
|
@@ -4344,12 +4405,12 @@ const AvatarColor = {
|
|
|
4344
4405
|
...AvatarNamedColor
|
|
4345
4406
|
};
|
|
4346
4407
|
|
|
4347
|
-
var __defProp$
|
|
4348
|
-
var __getOwnPropDesc$
|
|
4349
|
-
var __decorateClass$
|
|
4350
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
4408
|
+
var __defProp$n = Object.defineProperty;
|
|
4409
|
+
var __getOwnPropDesc$n = Object.getOwnPropertyDescriptor;
|
|
4410
|
+
var __decorateClass$n = (decorators, target, key, kind) => {
|
|
4411
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$n(target, key) : target;
|
|
4351
4412
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
4352
|
-
if (kind && result) __defProp$
|
|
4413
|
+
if (kind && result) __defProp$n(target, key, result);
|
|
4353
4414
|
return result;
|
|
4354
4415
|
};
|
|
4355
4416
|
const _Avatar = class _Avatar extends FASTElement {
|
|
@@ -4385,16 +4446,16 @@ const _Avatar = class _Avatar extends FASTElement {
|
|
|
4385
4446
|
* An array of the available Avatar named colors
|
|
4386
4447
|
*/
|
|
4387
4448
|
_Avatar.colors = Object.values(AvatarNamedColor);
|
|
4388
|
-
__decorateClass$
|
|
4389
|
-
__decorateClass$
|
|
4390
|
-
__decorateClass$
|
|
4449
|
+
__decorateClass$n([attr], _Avatar.prototype, "name", 2);
|
|
4450
|
+
__decorateClass$n([attr], _Avatar.prototype, "initials", 2);
|
|
4451
|
+
__decorateClass$n([attr({
|
|
4391
4452
|
converter: nullableNumberConverter
|
|
4392
4453
|
})], _Avatar.prototype, "size", 2);
|
|
4393
|
-
__decorateClass$
|
|
4394
|
-
__decorateClass$
|
|
4395
|
-
__decorateClass$
|
|
4396
|
-
__decorateClass$
|
|
4397
|
-
__decorateClass$
|
|
4454
|
+
__decorateClass$n([attr], _Avatar.prototype, "shape", 2);
|
|
4455
|
+
__decorateClass$n([attr], _Avatar.prototype, "active", 2);
|
|
4456
|
+
__decorateClass$n([attr], _Avatar.prototype, "appearance", 2);
|
|
4457
|
+
__decorateClass$n([attr], _Avatar.prototype, "color", 2);
|
|
4458
|
+
__decorateClass$n([attr({
|
|
4398
4459
|
attribute: "color-id"
|
|
4399
4460
|
})], _Avatar.prototype, "colorId", 2);
|
|
4400
4461
|
let Avatar = _Avatar;
|
|
@@ -4419,7 +4480,7 @@ const animations = {
|
|
|
4419
4480
|
normalEase: curveEasyEase,
|
|
4420
4481
|
nullEasing: curveLinear
|
|
4421
4482
|
};
|
|
4422
|
-
const styles$
|
|
4483
|
+
const styles$p = css`
|
|
4423
4484
|
${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([data-color='brand']){color:${colorNeutralForegroundStaticInverted};background-color:${colorBrandBackgroundStatic}}:host([data-color='dark-red']){color:${colorPaletteDarkRedForeground2};background-color:${colorPaletteDarkRedBackground2}}:host([data-color='cranberry']){color:${colorPaletteCranberryForeground2};background-color:${colorPaletteCranberryBackground2}}:host([data-color='red']){color:${colorPaletteRedForeground2};background-color:${colorPaletteRedBackground2}}:host([data-color='pumpkin']){color:${colorPalettePumpkinForeground2};background-color:${colorPalettePumpkinBackground2}}:host([data-color='peach']){color:${colorPalettePeachForeground2};background-color:${colorPalettePeachBackground2}}:host([data-color='marigold']){color:${colorPaletteMarigoldForeground2};background-color:${colorPaletteMarigoldBackground2}}:host([data-color='gold']){color:${colorPaletteGoldForeground2};background-color:${colorPaletteGoldBackground2}}:host([data-color='brass']){color:${colorPaletteBrassForeground2};background-color:${colorPaletteBrassBackground2}}:host([data-color='brown']){color:${colorPaletteBrownForeground2};background-color:${colorPaletteBrownBackground2}}:host([data-color='forest']){color:${colorPaletteForestForeground2};background-color:${colorPaletteForestBackground2}}:host([data-color='seafoam']){color:${colorPaletteSeafoamForeground2};background-color:${colorPaletteSeafoamBackground2}}:host([data-color='dark-green']){color:${colorPaletteDarkGreenForeground2};background-color:${colorPaletteDarkGreenBackground2}}:host([data-color='light-teal']){color:${colorPaletteLightTealForeground2};background-color:${colorPaletteLightTealBackground2}}:host([data-color='teal']){color:${colorPaletteTealForeground2};background-color:${colorPaletteTealBackground2}}:host([data-color='steel']){color:${colorPaletteSteelForeground2};background-color:${colorPaletteSteelBackground2}}:host([data-color='blue']){color:${colorPaletteBlueForeground2};background-color:${colorPaletteBlueBackground2}}:host([data-color='royal-blue']){color:${colorPaletteRoyalBlueForeground2};background-color:${colorPaletteRoyalBlueBackground2}}:host([data-color='cornflower']){color:${colorPaletteCornflowerForeground2};background-color:${colorPaletteCornflowerBackground2}}:host([data-color='navy']){color:${colorPaletteNavyForeground2};background-color:${colorPaletteNavyBackground2}}:host([data-color='lavender']){color:${colorPaletteLavenderForeground2};background-color:${colorPaletteLavenderBackground2}}:host([data-color='purple']){color:${colorPalettePurpleForeground2};background-color:${colorPalettePurpleBackground2}}:host([data-color='grape']){color:${colorPaletteGrapeForeground2};background-color:${colorPaletteGrapeBackground2}}:host([data-color='lilac']){color:${colorPaletteLilacForeground2};background-color:${colorPaletteLilacBackground2}}:host([data-color='pink']){color:${colorPalettePinkForeground2};background-color:${colorPalettePinkBackground2}}:host([data-color='magenta']){color:${colorPaletteMagentaForeground2};background-color:${colorPaletteMagentaBackground2}}:host([data-color='plum']){color:${colorPalettePlumForeground2};background-color:${colorPalettePlumBackground2}}:host([data-color='beige']){color:${colorPaletteBeigeForeground2};background-color:${colorPaletteBeigeBackground2}}:host([data-color='mink']){color:${colorPaletteMinkForeground2};background-color:${colorPaletteMinkBackground2}}:host([data-color='platinum']){color:${colorPalettePlatinumForeground2};background-color:${colorPalettePlatinumBackground2}}:host([data-color='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}}`;
|
|
4424
4485
|
|
|
4425
4486
|
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>`;
|
|
@@ -4431,7 +4492,7 @@ const template$r = avatarTemplate();
|
|
|
4431
4492
|
const definition$r = Avatar.compose({
|
|
4432
4493
|
name: `${FluentDesignSystem.prefix}-avatar`,
|
|
4433
4494
|
template: template$r,
|
|
4434
|
-
styles: styles$
|
|
4495
|
+
styles: styles$p
|
|
4435
4496
|
});
|
|
4436
4497
|
|
|
4437
4498
|
definition$r.define(FluentDesignSystem.registry);
|
|
@@ -4453,12 +4514,12 @@ const BadgeColor = {
|
|
|
4453
4514
|
warning: "warning"
|
|
4454
4515
|
};
|
|
4455
4516
|
|
|
4456
|
-
var __defProp$
|
|
4457
|
-
var __getOwnPropDesc$
|
|
4458
|
-
var __decorateClass$
|
|
4459
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
4517
|
+
var __defProp$m = Object.defineProperty;
|
|
4518
|
+
var __getOwnPropDesc$m = Object.getOwnPropertyDescriptor;
|
|
4519
|
+
var __decorateClass$m = (decorators, target, key, kind) => {
|
|
4520
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$m(target, key) : target;
|
|
4460
4521
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
4461
|
-
if (kind && result) __defProp$
|
|
4522
|
+
if (kind && result) __defProp$m(target, key, result);
|
|
4462
4523
|
return result;
|
|
4463
4524
|
};
|
|
4464
4525
|
class Badge extends FASTElement {
|
|
@@ -4468,10 +4529,10 @@ class Badge extends FASTElement {
|
|
|
4468
4529
|
this.color = BadgeColor.brand;
|
|
4469
4530
|
}
|
|
4470
4531
|
}
|
|
4471
|
-
__decorateClass$
|
|
4472
|
-
__decorateClass$
|
|
4473
|
-
__decorateClass$
|
|
4474
|
-
__decorateClass$
|
|
4532
|
+
__decorateClass$m([attr], Badge.prototype, "appearance", 2);
|
|
4533
|
+
__decorateClass$m([attr], Badge.prototype, "color", 2);
|
|
4534
|
+
__decorateClass$m([attr], Badge.prototype, "shape", 2);
|
|
4535
|
+
__decorateClass$m([attr], Badge.prototype, "size", 2);
|
|
4475
4536
|
applyMixins(Badge, StartEnd);
|
|
4476
4537
|
|
|
4477
4538
|
const textPadding = spacingHorizontalXXS;
|
|
@@ -4826,7 +4887,7 @@ css.partial`
|
|
|
4826
4887
|
font-weight: ${fontWeightSemibold};
|
|
4827
4888
|
`;
|
|
4828
4889
|
|
|
4829
|
-
const styles$
|
|
4890
|
+
const styles$o = css`
|
|
4830
4891
|
:host([shape='square']){border-radius:${borderRadiusNone}}:host([shape='rounded']){border-radius:${borderRadiusMedium}}:host([shape='rounded'][size='tiny']),:host([shape='rounded'][size='extra-small']),:host([shape='rounded'][size='small']){border-radius:${borderRadiusSmall}}${badgeSizeStyles}
|
|
4831
4892
|
${badgeFilledStyles}
|
|
4832
4893
|
${badgeGhostStyles}
|
|
@@ -4844,23 +4905,17 @@ const template$q = badgeTemplate();
|
|
|
4844
4905
|
const definition$q = Badge.compose({
|
|
4845
4906
|
name: `${FluentDesignSystem.prefix}-badge`,
|
|
4846
4907
|
template: template$q,
|
|
4847
|
-
styles: styles$
|
|
4908
|
+
styles: styles$o
|
|
4848
4909
|
});
|
|
4849
4910
|
|
|
4850
4911
|
definition$q.define(FluentDesignSystem.registry);
|
|
4851
4912
|
|
|
4852
|
-
|
|
4853
|
-
|
|
4854
|
-
|
|
4855
|
-
|
|
4856
|
-
};
|
|
4857
|
-
|
|
4858
|
-
var __defProp$m = Object.defineProperty;
|
|
4859
|
-
var __getOwnPropDesc$m = Object.getOwnPropertyDescriptor;
|
|
4860
|
-
var __decorateClass$m = (decorators, target, key, kind) => {
|
|
4861
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$m(target, key) : target;
|
|
4913
|
+
var __defProp$l = Object.defineProperty;
|
|
4914
|
+
var __getOwnPropDesc$l = Object.getOwnPropertyDescriptor;
|
|
4915
|
+
var __decorateClass$l = (decorators, target, key, kind) => {
|
|
4916
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$l(target, key) : target;
|
|
4862
4917
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
4863
|
-
if (kind && result) __defProp$
|
|
4918
|
+
if (kind && result) __defProp$l(target, key, result);
|
|
4864
4919
|
return result;
|
|
4865
4920
|
};
|
|
4866
4921
|
class Button extends FASTElement {
|
|
@@ -5064,54 +5119,48 @@ class Button extends FASTElement {
|
|
|
5064
5119
|
* @public
|
|
5065
5120
|
*/
|
|
5066
5121
|
Button.formAssociated = true;
|
|
5067
|
-
__decorateClass$
|
|
5068
|
-
__decorateClass$
|
|
5122
|
+
__decorateClass$l([attr], Button.prototype, "appearance", 2);
|
|
5123
|
+
__decorateClass$l([attr({
|
|
5069
5124
|
mode: "boolean"
|
|
5070
5125
|
})], Button.prototype, "autofocus", 2);
|
|
5071
|
-
__decorateClass$
|
|
5072
|
-
__decorateClass$
|
|
5126
|
+
__decorateClass$l([observable], Button.prototype, "defaultSlottedContent", 2);
|
|
5127
|
+
__decorateClass$l([attr({
|
|
5073
5128
|
mode: "boolean"
|
|
5074
5129
|
})], Button.prototype, "disabled", 2);
|
|
5075
|
-
__decorateClass$
|
|
5130
|
+
__decorateClass$l([attr({
|
|
5076
5131
|
attribute: "disabled-focusable",
|
|
5077
5132
|
mode: "boolean"
|
|
5078
5133
|
})], Button.prototype, "disabledFocusable", 2);
|
|
5079
|
-
__decorateClass$
|
|
5134
|
+
__decorateClass$l([attr({
|
|
5080
5135
|
attribute: "formaction"
|
|
5081
5136
|
})], Button.prototype, "formAction", 2);
|
|
5082
|
-
__decorateClass$
|
|
5137
|
+
__decorateClass$l([attr({
|
|
5083
5138
|
attribute: "form"
|
|
5084
5139
|
})], Button.prototype, "formAttribute", 2);
|
|
5085
|
-
__decorateClass$
|
|
5140
|
+
__decorateClass$l([attr({
|
|
5086
5141
|
attribute: "formenctype"
|
|
5087
5142
|
})], Button.prototype, "formEnctype", 2);
|
|
5088
|
-
__decorateClass$
|
|
5143
|
+
__decorateClass$l([attr({
|
|
5089
5144
|
attribute: "formmethod"
|
|
5090
5145
|
})], Button.prototype, "formMethod", 2);
|
|
5091
|
-
__decorateClass$
|
|
5146
|
+
__decorateClass$l([attr({
|
|
5092
5147
|
attribute: "formnovalidate",
|
|
5093
5148
|
mode: "boolean"
|
|
5094
5149
|
})], Button.prototype, "formNoValidate", 2);
|
|
5095
|
-
__decorateClass$
|
|
5150
|
+
__decorateClass$l([attr({
|
|
5096
5151
|
attribute: "formtarget"
|
|
5097
5152
|
})], Button.prototype, "formTarget", 2);
|
|
5098
|
-
__decorateClass$
|
|
5153
|
+
__decorateClass$l([attr({
|
|
5099
5154
|
attribute: "icon-only",
|
|
5100
5155
|
mode: "boolean"
|
|
5101
5156
|
})], Button.prototype, "iconOnly", 2);
|
|
5102
|
-
__decorateClass$
|
|
5103
|
-
__decorateClass$
|
|
5104
|
-
__decorateClass$
|
|
5105
|
-
__decorateClass$
|
|
5106
|
-
__decorateClass$
|
|
5157
|
+
__decorateClass$l([attr], Button.prototype, "name", 2);
|
|
5158
|
+
__decorateClass$l([attr], Button.prototype, "shape", 2);
|
|
5159
|
+
__decorateClass$l([attr], Button.prototype, "size", 2);
|
|
5160
|
+
__decorateClass$l([attr], Button.prototype, "type", 2);
|
|
5161
|
+
__decorateClass$l([attr], Button.prototype, "value", 2);
|
|
5107
5162
|
applyMixins(Button, StartEnd);
|
|
5108
5163
|
|
|
5109
|
-
const styles$o = css`
|
|
5110
|
-
${display("inline-flex")}
|
|
5111
|
-
|
|
5112
|
-
:host{--icon-spacing:${spacingHorizontalSNudge};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}[slot='start'],::slotted([slot='start']){margin-inline-end:var(--icon-spacing)}[slot='end'],::slotted([slot='end']){margin-inline-start:var(--icon-spacing)}:host([icon-only]){min-width:32px;max-width:32px}:host([size='small']){--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([size='small'][icon-only]){min-width:24px;max-width:24px}:host([size='large']){min-height:40px;border-radius:${borderRadiusLarge};padding:0 ${spacingHorizontalL};font-size:${fontSizeBase400};line-height:${lineHeightBase400}}:host([size='large'][icon-only]){min-width:40px;max-width:40px}:host([size='large']) ::slotted(svg){font-size:24px;height:24px;width:24px}:host([shape='circular']),:host([shape='circular']:focus-visible){border-radius:${borderRadiusCircular}}:host([shape='square']),:host([shape='square']:focus-visible){border-radius:${borderRadiusNone}}:host([appearance='primary']){background-color:${colorBrandBackground};color:${colorNeutralForegroundOnBrand};border-color:transparent}:host([appearance='primary']:hover){background-color:${colorBrandBackgroundHover}}:host([appearance='primary']:hover),:host([appearance='primary']:hover:active){border-color:transparent;color:${colorNeutralForegroundOnBrand}}:host([appearance='primary']:hover:active){background-color:${colorBrandBackgroundPressed}}:host([appearance='primary']:focus-visible){border-color:${colorNeutralForegroundOnBrand};box-shadow:${shadow2},0 0 0 2px ${colorStrokeFocus2}}:host([appearance='outline']){background-color:${colorTransparentBackground}}:host([appearance='outline']:hover){background-color:${colorTransparentBackgroundHover}}:host([appearance='outline']:hover:active){background-color:${colorTransparentBackgroundPressed}}:host([appearance='subtle']){background-color:${colorSubtleBackground};color:${colorNeutralForeground2};border-color:transparent}:host([appearance='subtle']:hover){background-color:${colorSubtleBackgroundHover};color:${colorNeutralForeground2Hover};border-color:transparent}:host([appearance='subtle']:hover:active){background-color:${colorSubtleBackgroundPressed};color:${colorNeutralForeground2Pressed};border-color:transparent}:host([appearance='subtle']:hover) ::slotted(svg){fill:${colorNeutralForeground2BrandHover}}:host([appearance='subtle']:hover:active) ::slotted(svg){fill:${colorNeutralForeground2BrandPressed}}:host([appearance='transparent']){background-color:${colorTransparentBackground};color:${colorNeutralForeground2}}:host([appearance='transparent']:hover){background-color:${colorTransparentBackgroundHover};color:${colorNeutralForeground2BrandHover}}:host([appearance='transparent']:hover:active){background-color:${colorTransparentBackgroundPressed};color:${colorNeutralForeground2BrandPressed}}:host([appearance='transparent']),:host([appearance='transparent']:hover),:host([appearance='transparent']:hover:active){border-color:transparent}: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(:is([disabled][appearance='primary'],[disabled-focusable][appearance='primary'])),:host(:is([disabled][appearance='primary'],[disabled-focusable][appearance='primary']):hover),:host(:is([disabled][appearance='primary'],[disabled-focusable][appearance='primary']):hover:active){border-color:transparent}:host(:is([disabled][appearance='outline'],[disabled-focusable][appearance='outline'])),:host(:is([disabled][appearance='outline'],[disabled-focusable][appearance='outline']):hover),:host(:is([disabled][appearance='outline'],[disabled-focusable][appearance='outline']):hover:active){background-color:${colorTransparentBackground}}:host(:is([disabled][appearance='subtle'],[disabled-focusable][appearance='subtle'])),:host(:is([disabled][appearance='subtle'],[disabled-focusable][appearance='subtle']):hover),:host(:is([disabled][appearance='subtle'],[disabled-focusable][appearance='subtle']):hover:active){background-color:${colorTransparentBackground};border-color:transparent}:host(:is([disabled][appearance='transparent'],[disabled-focusable][appearance='transparent'])),:host(:is([disabled][appearance='transparent'],[disabled-focusable][appearance='transparent']):hover),:host(:is([disabled][appearance='transparent'],[disabled-focusable][appearance='transparent']):hover:active){border-color:transparent;background-color:${colorTransparentBackground}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
5113
|
-
:host([appearance='transparent']:hover){border-color:Highlight}`));
|
|
5114
|
-
|
|
5115
5164
|
function buttonTemplate$1(options = {}) {
|
|
5116
5165
|
return html`<template tabindex="${x => x.disabled ? -1 : 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>`;
|
|
5117
5166
|
}
|
|
@@ -5120,7 +5169,7 @@ const template$p = buttonTemplate$1();
|
|
|
5120
5169
|
const definition$p = Button.compose({
|
|
5121
5170
|
name: `${FluentDesignSystem.prefix}-button`,
|
|
5122
5171
|
template: template$p,
|
|
5123
|
-
styles: styles$
|
|
5172
|
+
styles: styles$r
|
|
5124
5173
|
});
|
|
5125
5174
|
|
|
5126
5175
|
definition$p.define(FluentDesignSystem.registry);
|
|
@@ -5139,12 +5188,12 @@ function toggleState(elementInternals, state, force) {
|
|
|
5139
5188
|
elementInternals.states.delete(state);
|
|
5140
5189
|
}
|
|
5141
5190
|
|
|
5142
|
-
var __defProp$
|
|
5143
|
-
var __getOwnPropDesc$
|
|
5144
|
-
var __decorateClass$
|
|
5145
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
5191
|
+
var __defProp$k = Object.defineProperty;
|
|
5192
|
+
var __getOwnPropDesc$k = Object.getOwnPropertyDescriptor;
|
|
5193
|
+
var __decorateClass$k = (decorators, target, key, kind) => {
|
|
5194
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$k(target, key) : target;
|
|
5146
5195
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
5147
|
-
if (kind && result) __defProp$
|
|
5196
|
+
if (kind && result) __defProp$k(target, key, result);
|
|
5148
5197
|
return result;
|
|
5149
5198
|
};
|
|
5150
5199
|
class BaseCheckbox extends FASTElement {
|
|
@@ -5471,31 +5520,31 @@ class BaseCheckbox extends FASTElement {
|
|
|
5471
5520
|
* @public
|
|
5472
5521
|
*/
|
|
5473
5522
|
BaseCheckbox.formAssociated = true;
|
|
5474
|
-
__decorateClass$
|
|
5523
|
+
__decorateClass$k([attr({
|
|
5475
5524
|
mode: "boolean"
|
|
5476
5525
|
})], BaseCheckbox.prototype, "autofocus", 2);
|
|
5477
|
-
__decorateClass$
|
|
5526
|
+
__decorateClass$k([attr({
|
|
5478
5527
|
mode: "boolean"
|
|
5479
5528
|
})], BaseCheckbox.prototype, "disabled", 2);
|
|
5480
|
-
__decorateClass$
|
|
5529
|
+
__decorateClass$k([attr({
|
|
5481
5530
|
attribute: "form"
|
|
5482
5531
|
})], BaseCheckbox.prototype, "formAttribute", 2);
|
|
5483
|
-
__decorateClass$
|
|
5484
|
-
__decorateClass$
|
|
5532
|
+
__decorateClass$k([observable], BaseCheckbox.prototype, "indeterminate", 2);
|
|
5533
|
+
__decorateClass$k([attr({
|
|
5485
5534
|
attribute: "checked",
|
|
5486
5535
|
mode: "boolean"
|
|
5487
5536
|
})], BaseCheckbox.prototype, "initialChecked", 2);
|
|
5488
|
-
__decorateClass$
|
|
5537
|
+
__decorateClass$k([attr({
|
|
5489
5538
|
attribute: "value",
|
|
5490
5539
|
mode: "fromView"
|
|
5491
5540
|
})], BaseCheckbox.prototype, "initialValue", 2);
|
|
5492
|
-
__decorateClass$
|
|
5493
|
-
__decorateClass$
|
|
5541
|
+
__decorateClass$k([attr], BaseCheckbox.prototype, "name", 2);
|
|
5542
|
+
__decorateClass$k([attr({
|
|
5494
5543
|
mode: "boolean"
|
|
5495
5544
|
})], BaseCheckbox.prototype, "required", 2);
|
|
5496
5545
|
class Checkbox extends BaseCheckbox {}
|
|
5497
|
-
__decorateClass$
|
|
5498
|
-
__decorateClass$
|
|
5546
|
+
__decorateClass$k([attr], Checkbox.prototype, "shape", 2);
|
|
5547
|
+
__decorateClass$k([attr], Checkbox.prototype, "size", 2);
|
|
5499
5548
|
|
|
5500
5549
|
const checkedState$1 = css.partial`:is([state--checked], :state(checked))`;
|
|
5501
5550
|
const indeterminateState = css.partial`:is([state--indeterminate], :state(indeterminate))`;
|
|
@@ -5541,7 +5590,7 @@ definition$o.define(FluentDesignSystem.registry);
|
|
|
5541
5590
|
class CompoundButton extends Button {}
|
|
5542
5591
|
|
|
5543
5592
|
const styles$m = css`
|
|
5544
|
-
${styles$
|
|
5593
|
+
${styles$r}
|
|
5545
5594
|
|
|
5546
5595
|
: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([size='large']) ::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([appearance='primary'],[appearance='primary']:hover,[appearance='primary']:active))
|
|
5547
5596
|
::slotted([slot='description']){color:${colorNeutralForegroundOnBrand}}:host(:is([appearance='subtle'],[appearance='subtle']:hover,[appearance='subtle']:active))
|
|
@@ -5561,12 +5610,12 @@ const definition$n = CompoundButton.compose({
|
|
|
5561
5610
|
|
|
5562
5611
|
definition$n.define(FluentDesignSystem.registry);
|
|
5563
5612
|
|
|
5564
|
-
var __defProp$
|
|
5565
|
-
var __getOwnPropDesc$
|
|
5566
|
-
var __decorateClass$
|
|
5567
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
5613
|
+
var __defProp$j = Object.defineProperty;
|
|
5614
|
+
var __getOwnPropDesc$j = Object.getOwnPropertyDescriptor;
|
|
5615
|
+
var __decorateClass$j = (decorators, target, key, kind) => {
|
|
5616
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$j(target, key) : target;
|
|
5568
5617
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
5569
|
-
if (kind && result) __defProp$
|
|
5618
|
+
if (kind && result) __defProp$j(target, key, result);
|
|
5570
5619
|
return result;
|
|
5571
5620
|
};
|
|
5572
5621
|
class CounterBadge extends FASTElement {
|
|
@@ -5597,22 +5646,22 @@ class CounterBadge extends FASTElement {
|
|
|
5597
5646
|
return;
|
|
5598
5647
|
}
|
|
5599
5648
|
}
|
|
5600
|
-
__decorateClass$
|
|
5601
|
-
__decorateClass$
|
|
5602
|
-
__decorateClass$
|
|
5603
|
-
__decorateClass$
|
|
5604
|
-
__decorateClass$
|
|
5649
|
+
__decorateClass$j([attr], CounterBadge.prototype, "appearance", 2);
|
|
5650
|
+
__decorateClass$j([attr], CounterBadge.prototype, "color", 2);
|
|
5651
|
+
__decorateClass$j([attr], CounterBadge.prototype, "shape", 2);
|
|
5652
|
+
__decorateClass$j([attr], CounterBadge.prototype, "size", 2);
|
|
5653
|
+
__decorateClass$j([attr({
|
|
5605
5654
|
converter: nullableNumberConverter
|
|
5606
5655
|
})], CounterBadge.prototype, "count", 2);
|
|
5607
|
-
__decorateClass$
|
|
5656
|
+
__decorateClass$j([attr({
|
|
5608
5657
|
attribute: "overflow-count",
|
|
5609
5658
|
converter: nullableNumberConverter
|
|
5610
5659
|
})], CounterBadge.prototype, "overflowCount", 2);
|
|
5611
|
-
__decorateClass$
|
|
5660
|
+
__decorateClass$j([attr({
|
|
5612
5661
|
attribute: "show-zero",
|
|
5613
5662
|
mode: "boolean"
|
|
5614
5663
|
})], CounterBadge.prototype, "showZero", 2);
|
|
5615
|
-
__decorateClass$
|
|
5664
|
+
__decorateClass$j([attr({
|
|
5616
5665
|
mode: "boolean"
|
|
5617
5666
|
})], CounterBadge.prototype, "dot", 2);
|
|
5618
5667
|
applyMixins(CounterBadge, StartEnd);
|
|
@@ -5646,12 +5695,12 @@ const DialogType = {
|
|
|
5646
5695
|
alert: "alert"
|
|
5647
5696
|
};
|
|
5648
5697
|
|
|
5649
|
-
var __defProp$
|
|
5650
|
-
var __getOwnPropDesc$
|
|
5651
|
-
var __decorateClass$
|
|
5652
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
5698
|
+
var __defProp$i = Object.defineProperty;
|
|
5699
|
+
var __getOwnPropDesc$i = Object.getOwnPropertyDescriptor;
|
|
5700
|
+
var __decorateClass$i = (decorators, target, key, kind) => {
|
|
5701
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$i(target, key) : target;
|
|
5653
5702
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
5654
|
-
if (kind && result) __defProp$
|
|
5703
|
+
if (kind && result) __defProp$i(target, key, result);
|
|
5655
5704
|
return result;
|
|
5656
5705
|
};
|
|
5657
5706
|
class Dialog extends FASTElement {
|
|
@@ -5719,14 +5768,14 @@ class Dialog extends FASTElement {
|
|
|
5719
5768
|
return true;
|
|
5720
5769
|
}
|
|
5721
5770
|
}
|
|
5722
|
-
__decorateClass$
|
|
5723
|
-
__decorateClass$
|
|
5771
|
+
__decorateClass$i([observable], Dialog.prototype, "dialog", 2);
|
|
5772
|
+
__decorateClass$i([attr({
|
|
5724
5773
|
attribute: "aria-describedby"
|
|
5725
5774
|
})], Dialog.prototype, "ariaDescribedby", 2);
|
|
5726
|
-
__decorateClass$
|
|
5775
|
+
__decorateClass$i([attr({
|
|
5727
5776
|
attribute: "aria-labelledby"
|
|
5728
5777
|
})], Dialog.prototype, "ariaLabelledby", 2);
|
|
5729
|
-
__decorateClass$
|
|
5778
|
+
__decorateClass$i([attr], Dialog.prototype, "type", 2);
|
|
5730
5779
|
|
|
5731
5780
|
const template$l = 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>`;
|
|
5732
5781
|
|
|
@@ -5742,12 +5791,12 @@ const definition$l = Dialog.compose({
|
|
|
5742
5791
|
|
|
5743
5792
|
definition$l.define(FluentDesignSystem.registry);
|
|
5744
5793
|
|
|
5745
|
-
var __defProp$
|
|
5746
|
-
var __getOwnPropDesc$
|
|
5747
|
-
var __decorateClass$
|
|
5748
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
5794
|
+
var __defProp$h = Object.defineProperty;
|
|
5795
|
+
var __getOwnPropDesc$h = Object.getOwnPropertyDescriptor;
|
|
5796
|
+
var __decorateClass$h = (decorators, target, key, kind) => {
|
|
5797
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$h(target, key) : target;
|
|
5749
5798
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
5750
|
-
if (kind && result) __defProp$
|
|
5799
|
+
if (kind && result) __defProp$h(target, key, result);
|
|
5751
5800
|
return result;
|
|
5752
5801
|
};
|
|
5753
5802
|
class DialogBody extends FASTElement {
|
|
@@ -5756,7 +5805,7 @@ class DialogBody extends FASTElement {
|
|
|
5756
5805
|
this.noTitleAction = false;
|
|
5757
5806
|
}
|
|
5758
5807
|
}
|
|
5759
|
-
__decorateClass$
|
|
5808
|
+
__decorateClass$h([attr({
|
|
5760
5809
|
mode: "boolean",
|
|
5761
5810
|
attribute: "no-title-action"
|
|
5762
5811
|
})], DialogBody.prototype, "noTitleAction", 2);
|
|
@@ -5775,7 +5824,7 @@ const dismissed16Regular = html.partial(`
|
|
|
5775
5824
|
fill="currentColor"
|
|
5776
5825
|
></path>
|
|
5777
5826
|
</svg>`);
|
|
5778
|
-
const template$k = html`<div class="title" part="title"><slot name="title"></slot><slot name="title-action"><fluent-button ?hidden=${x => x.noTitleAction || x.parentNode?.type
|
|
5827
|
+
const template$k = 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>`;
|
|
5779
5828
|
|
|
5780
5829
|
const styles$j = css`
|
|
5781
5830
|
${display("grid")}
|
|
@@ -5802,33 +5851,71 @@ const DividerRole = {
|
|
|
5802
5851
|
};
|
|
5803
5852
|
const DividerOrientation = Orientation;
|
|
5804
5853
|
|
|
5805
|
-
var __defProp$
|
|
5806
|
-
var __getOwnPropDesc$
|
|
5807
|
-
var __decorateClass$
|
|
5808
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
5854
|
+
var __defProp$g = Object.defineProperty;
|
|
5855
|
+
var __getOwnPropDesc$g = Object.getOwnPropertyDescriptor;
|
|
5856
|
+
var __decorateClass$g = (decorators, target, key, kind) => {
|
|
5857
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$g(target, key) : target;
|
|
5809
5858
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
5810
|
-
if (kind && result) __defProp$
|
|
5859
|
+
if (kind && result) __defProp$g(target, key, result);
|
|
5811
5860
|
return result;
|
|
5812
5861
|
};
|
|
5813
5862
|
class Divider extends FASTElement {
|
|
5814
5863
|
constructor() {
|
|
5815
5864
|
super(...arguments);
|
|
5816
|
-
|
|
5817
|
-
|
|
5865
|
+
/**
|
|
5866
|
+
* The internal {@link https://developer.mozilla.org/docs/Web/API/ElementInternals | `ElementInternals`} instance for the component.
|
|
5867
|
+
*
|
|
5868
|
+
* @internal
|
|
5869
|
+
*/
|
|
5870
|
+
this.elementInternals = this.attachInternals();
|
|
5871
|
+
}
|
|
5872
|
+
connectedCallback() {
|
|
5873
|
+
super.connectedCallback();
|
|
5874
|
+
this.elementInternals.role = this.role ?? DividerRole.separator;
|
|
5875
|
+
if (this.role !== DividerRole.presentation) {
|
|
5876
|
+
this.elementInternals.ariaOrientation = this.orientation ?? DividerOrientation.horizontal;
|
|
5877
|
+
}
|
|
5878
|
+
}
|
|
5879
|
+
/**
|
|
5880
|
+
* Sets the element's internal role when the role attribute changes.
|
|
5881
|
+
*
|
|
5882
|
+
* @param previous - the previous role value
|
|
5883
|
+
* @param next - the current role value
|
|
5884
|
+
* @internal
|
|
5885
|
+
*/
|
|
5886
|
+
roleChanged(previous, next) {
|
|
5887
|
+
if (this.$fastController.isConnected) {
|
|
5888
|
+
this.elementInternals.role = `${next ?? DividerRole.separator}`;
|
|
5889
|
+
}
|
|
5890
|
+
if (next === DividerRole.presentation) {
|
|
5891
|
+
this.elementInternals.ariaOrientation = null;
|
|
5892
|
+
}
|
|
5893
|
+
}
|
|
5894
|
+
/**
|
|
5895
|
+
* Sets the element's internal orientation when the orientation attribute changes.
|
|
5896
|
+
*
|
|
5897
|
+
* @param previous - the previous orientation value
|
|
5898
|
+
* @param next - the current orientation value
|
|
5899
|
+
* @internal
|
|
5900
|
+
*/
|
|
5901
|
+
orientationChanged(previous, next) {
|
|
5902
|
+
if (this.$fastController.isConnected) {
|
|
5903
|
+
this.elementInternals.ariaOrientation = this.role !== DividerRole.presentation ? next : null;
|
|
5904
|
+
}
|
|
5818
5905
|
}
|
|
5819
5906
|
}
|
|
5820
|
-
__decorateClass$
|
|
5821
|
-
__decorateClass$
|
|
5822
|
-
__decorateClass$
|
|
5907
|
+
__decorateClass$g([attr], Divider.prototype, "role", 2);
|
|
5908
|
+
__decorateClass$g([attr], Divider.prototype, "orientation", 2);
|
|
5909
|
+
__decorateClass$g([attr({
|
|
5823
5910
|
attribute: "align-content"
|
|
5824
5911
|
})], Divider.prototype, "alignContent", 2);
|
|
5825
|
-
__decorateClass$
|
|
5826
|
-
__decorateClass$
|
|
5912
|
+
__decorateClass$g([attr], Divider.prototype, "appearance", 2);
|
|
5913
|
+
__decorateClass$g([attr({
|
|
5827
5914
|
mode: "boolean"
|
|
5828
5915
|
})], Divider.prototype, "inset", 2);
|
|
5829
5916
|
|
|
5830
5917
|
function dividerTemplate() {
|
|
5831
|
-
return html`<
|
|
5918
|
+
return html`<slot></slot>`;
|
|
5832
5919
|
}
|
|
5833
5920
|
const template$j = dividerTemplate();
|
|
5834
5921
|
|
|
@@ -5865,12 +5952,12 @@ const ValidationFlags = {
|
|
|
5865
5952
|
valid: "valid"
|
|
5866
5953
|
};
|
|
5867
5954
|
|
|
5868
|
-
var __defProp$
|
|
5869
|
-
var __getOwnPropDesc$
|
|
5870
|
-
var __decorateClass$
|
|
5871
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
5955
|
+
var __defProp$f = Object.defineProperty;
|
|
5956
|
+
var __getOwnPropDesc$f = Object.getOwnPropertyDescriptor;
|
|
5957
|
+
var __decorateClass$f = (decorators, target, key, kind) => {
|
|
5958
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$f(target, key) : target;
|
|
5872
5959
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
5873
|
-
if (kind && result) __defProp$
|
|
5960
|
+
if (kind && result) __defProp$f(target, key, result);
|
|
5874
5961
|
return result;
|
|
5875
5962
|
};
|
|
5876
5963
|
class Field extends FASTElement {
|
|
@@ -5990,11 +6077,11 @@ class Field extends FASTElement {
|
|
|
5990
6077
|
}
|
|
5991
6078
|
}
|
|
5992
6079
|
}
|
|
5993
|
-
__decorateClass$
|
|
6080
|
+
__decorateClass$f([attr({
|
|
5994
6081
|
attribute: "label-position"
|
|
5995
6082
|
})], Field.prototype, "labelPosition", 2);
|
|
5996
|
-
__decorateClass$
|
|
5997
|
-
__decorateClass$
|
|
6083
|
+
__decorateClass$f([observable], Field.prototype, "messageSlot", 2);
|
|
6084
|
+
__decorateClass$f([observable], Field.prototype, "slottedInputs", 2);
|
|
5998
6085
|
|
|
5999
6086
|
const disabledState = css.partial`:is([state--disabled], :state(disabled))`;
|
|
6000
6087
|
const focusVisibleState = css.partial`:is([state--focus-visible], :state(focus-visible))`;
|
|
@@ -6037,26 +6124,26 @@ const definition$i = Field.compose({
|
|
|
6037
6124
|
|
|
6038
6125
|
definition$i.define(FluentDesignSystem.registry);
|
|
6039
6126
|
|
|
6040
|
-
var __defProp$
|
|
6041
|
-
var __getOwnPropDesc$
|
|
6042
|
-
var __decorateClass$
|
|
6043
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6127
|
+
var __defProp$e = Object.defineProperty;
|
|
6128
|
+
var __getOwnPropDesc$e = Object.getOwnPropertyDescriptor;
|
|
6129
|
+
var __decorateClass$e = (decorators, target, key, kind) => {
|
|
6130
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$e(target, key) : target;
|
|
6044
6131
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6045
|
-
if (kind && result) __defProp$
|
|
6132
|
+
if (kind && result) __defProp$e(target, key, result);
|
|
6046
6133
|
return result;
|
|
6047
6134
|
};
|
|
6048
6135
|
class Image extends FASTElement {}
|
|
6049
|
-
__decorateClass$
|
|
6136
|
+
__decorateClass$e([attr({
|
|
6050
6137
|
mode: "boolean"
|
|
6051
6138
|
})], Image.prototype, "block", 2);
|
|
6052
|
-
__decorateClass$
|
|
6139
|
+
__decorateClass$e([attr({
|
|
6053
6140
|
mode: "boolean"
|
|
6054
6141
|
})], Image.prototype, "bordered", 2);
|
|
6055
|
-
__decorateClass$
|
|
6142
|
+
__decorateClass$e([attr({
|
|
6056
6143
|
mode: "boolean"
|
|
6057
6144
|
})], Image.prototype, "shadow", 2);
|
|
6058
|
-
__decorateClass$
|
|
6059
|
-
__decorateClass$
|
|
6145
|
+
__decorateClass$e([attr], Image.prototype, "fit", 2);
|
|
6146
|
+
__decorateClass$e([attr], Image.prototype, "shape", 2);
|
|
6060
6147
|
|
|
6061
6148
|
const template$h = html`<slot></slot>`;
|
|
6062
6149
|
|
|
@@ -6071,12 +6158,12 @@ const definition$h = Image.compose({
|
|
|
6071
6158
|
|
|
6072
6159
|
definition$h.define(FluentDesignSystem.registry);
|
|
6073
6160
|
|
|
6074
|
-
var __defProp$
|
|
6075
|
-
var __getOwnPropDesc$
|
|
6076
|
-
var __decorateClass$
|
|
6077
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
6161
|
+
var __defProp$d = Object.defineProperty;
|
|
6162
|
+
var __getOwnPropDesc$d = Object.getOwnPropertyDescriptor;
|
|
6163
|
+
var __decorateClass$d = (decorators, target, key, kind) => {
|
|
6164
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$d(target, key) : target;
|
|
6078
6165
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
6079
|
-
if (kind && result) __defProp$
|
|
6166
|
+
if (kind && result) __defProp$d(target, key, result);
|
|
6080
6167
|
return result;
|
|
6081
6168
|
};
|
|
6082
6169
|
class Label extends FASTElement {
|
|
@@ -6086,12 +6173,12 @@ class Label extends FASTElement {
|
|
|
6086
6173
|
this.required = false;
|
|
6087
6174
|
}
|
|
6088
6175
|
}
|
|
6089
|
-
__decorateClass$
|
|
6090
|
-
__decorateClass$
|
|
6091
|
-
__decorateClass$
|
|
6176
|
+
__decorateClass$d([attr], Label.prototype, "size", 2);
|
|
6177
|
+
__decorateClass$d([attr], Label.prototype, "weight", 2);
|
|
6178
|
+
__decorateClass$d([attr({
|
|
6092
6179
|
mode: "boolean"
|
|
6093
6180
|
})], Label.prototype, "disabled", 2);
|
|
6094
|
-
__decorateClass$
|
|
6181
|
+
__decorateClass$d([attr({
|
|
6095
6182
|
mode: "boolean"
|
|
6096
6183
|
})], Label.prototype, "required", 2);
|
|
6097
6184
|
|
|
@@ -6127,7 +6214,7 @@ const template$f = buttonTemplate$1({
|
|
|
6127
6214
|
const definition$f = MenuButton.compose({
|
|
6128
6215
|
name: `${FluentDesignSystem.prefix}-menu-button`,
|
|
6129
6216
|
template: template$f,
|
|
6130
|
-
styles: styles$
|
|
6217
|
+
styles: styles$r
|
|
6131
6218
|
});
|
|
6132
6219
|
|
|
6133
6220
|
definition$f.define(FluentDesignSystem.registry);
|
|
@@ -7067,12 +7154,12 @@ const MenuItemRole = {
|
|
|
7067
7154
|
[MenuItemRole.menuitemradio]: "menuitemradio"
|
|
7068
7155
|
});
|
|
7069
7156
|
|
|
7070
|
-
var __defProp$
|
|
7071
|
-
var __getOwnPropDesc$
|
|
7072
|
-
var __decorateClass$
|
|
7073
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7157
|
+
var __defProp$c = Object.defineProperty;
|
|
7158
|
+
var __getOwnPropDesc$c = Object.getOwnPropertyDescriptor;
|
|
7159
|
+
var __decorateClass$c = (decorators, target, key, kind) => {
|
|
7160
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$c(target, key) : target;
|
|
7074
7161
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7075
|
-
if (kind && result) __defProp$
|
|
7162
|
+
if (kind && result) __defProp$c(target, key, result);
|
|
7076
7163
|
return result;
|
|
7077
7164
|
};
|
|
7078
7165
|
class MenuItem extends FASTElement {
|
|
@@ -7277,21 +7364,21 @@ class MenuItem extends FASTElement {
|
|
|
7277
7364
|
});
|
|
7278
7365
|
}
|
|
7279
7366
|
}
|
|
7280
|
-
__decorateClass$
|
|
7367
|
+
__decorateClass$c([attr({
|
|
7281
7368
|
mode: "boolean"
|
|
7282
7369
|
})], MenuItem.prototype, "disabled", 2);
|
|
7283
|
-
__decorateClass$
|
|
7370
|
+
__decorateClass$c([attr({
|
|
7284
7371
|
mode: "boolean"
|
|
7285
7372
|
})], MenuItem.prototype, "expanded", 2);
|
|
7286
|
-
__decorateClass$
|
|
7287
|
-
__decorateClass$
|
|
7373
|
+
__decorateClass$c([attr], MenuItem.prototype, "role", 2);
|
|
7374
|
+
__decorateClass$c([attr({
|
|
7288
7375
|
mode: "boolean"
|
|
7289
7376
|
})], MenuItem.prototype, "checked", 2);
|
|
7290
|
-
__decorateClass$
|
|
7377
|
+
__decorateClass$c([attr({
|
|
7291
7378
|
mode: "boolean"
|
|
7292
7379
|
})], MenuItem.prototype, "hidden", 2);
|
|
7293
|
-
__decorateClass$
|
|
7294
|
-
__decorateClass$
|
|
7380
|
+
__decorateClass$c([observable], MenuItem.prototype, "slottedSubmenu", 2);
|
|
7381
|
+
__decorateClass$c([observable], MenuItem.prototype, "submenu", 2);
|
|
7295
7382
|
applyMixins(MenuItem, StartEnd);
|
|
7296
7383
|
|
|
7297
7384
|
const styles$e = css`
|
|
@@ -7321,12 +7408,12 @@ const definition$e = MenuItem.compose({
|
|
|
7321
7408
|
|
|
7322
7409
|
definition$e.define(FluentDesignSystem.registry);
|
|
7323
7410
|
|
|
7324
|
-
var __defProp$
|
|
7325
|
-
var __getOwnPropDesc$
|
|
7326
|
-
var __decorateClass$
|
|
7327
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7411
|
+
var __defProp$b = Object.defineProperty;
|
|
7412
|
+
var __getOwnPropDesc$b = Object.getOwnPropertyDescriptor;
|
|
7413
|
+
var __decorateClass$b = (decorators, target, key, kind) => {
|
|
7414
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$b(target, key) : target;
|
|
7328
7415
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7329
|
-
if (kind && result) __defProp$
|
|
7416
|
+
if (kind && result) __defProp$b(target, key, result);
|
|
7330
7417
|
return result;
|
|
7331
7418
|
};
|
|
7332
7419
|
const _MenuList = class _MenuList extends FASTElement {
|
|
@@ -7567,7 +7654,7 @@ const _MenuList = class _MenuList extends FASTElement {
|
|
|
7567
7654
|
}
|
|
7568
7655
|
};
|
|
7569
7656
|
_MenuList.focusableElementRoles = MenuItemRole;
|
|
7570
|
-
__decorateClass$
|
|
7657
|
+
__decorateClass$b([observable], _MenuList.prototype, "items", 2);
|
|
7571
7658
|
let MenuList = _MenuList;
|
|
7572
7659
|
|
|
7573
7660
|
const styles$d = css`
|
|
@@ -7588,12 +7675,12 @@ const definition$d = MenuList.compose({
|
|
|
7588
7675
|
|
|
7589
7676
|
definition$d.define(FluentDesignSystem.registry);
|
|
7590
7677
|
|
|
7591
|
-
var __defProp$
|
|
7592
|
-
var __getOwnPropDesc$
|
|
7593
|
-
var __decorateClass$
|
|
7594
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
7678
|
+
var __defProp$a = Object.defineProperty;
|
|
7679
|
+
var __getOwnPropDesc$a = Object.getOwnPropertyDescriptor;
|
|
7680
|
+
var __decorateClass$a = (decorators, target, key, kind) => {
|
|
7681
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$a(target, key) : target;
|
|
7595
7682
|
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
7596
|
-
if (kind && result) __defProp$
|
|
7683
|
+
if (kind && result) __defProp$a(target, key, result);
|
|
7597
7684
|
return result;
|
|
7598
7685
|
};
|
|
7599
7686
|
class Menu extends FASTElement {
|
|
@@ -7929,27 +8016,27 @@ class Menu extends FASTElement {
|
|
|
7929
8016
|
}
|
|
7930
8017
|
}
|
|
7931
8018
|
}
|
|
7932
|
-
__decorateClass$
|
|
8019
|
+
__decorateClass$a([observable, attr({
|
|
7933
8020
|
attribute: "open-on-hover",
|
|
7934
8021
|
mode: "boolean"
|
|
7935
8022
|
})], Menu.prototype, "openOnHover", 2);
|
|
7936
|
-
__decorateClass$
|
|
8023
|
+
__decorateClass$a([observable, attr({
|
|
7937
8024
|
attribute: "open-on-context",
|
|
7938
8025
|
mode: "boolean"
|
|
7939
8026
|
})], Menu.prototype, "openOnContext", 2);
|
|
7940
|
-
__decorateClass$
|
|
8027
|
+
__decorateClass$a([observable, attr({
|
|
7941
8028
|
attribute: "close-on-scroll",
|
|
7942
8029
|
mode: "boolean"
|
|
7943
8030
|
})], Menu.prototype, "closeOnScroll", 2);
|
|
7944
|
-
__decorateClass$
|
|
8031
|
+
__decorateClass$a([observable, attr({
|
|
7945
8032
|
attribute: "persist-on-item-click",
|
|
7946
8033
|
mode: "boolean"
|
|
7947
8034
|
})], Menu.prototype, "persistOnItemClick", 2);
|
|
7948
|
-
__decorateClass$
|
|
8035
|
+
__decorateClass$a([observable, attr({
|
|
7949
8036
|
mode: "boolean"
|
|
7950
8037
|
})], Menu.prototype, "open", 2);
|
|
7951
|
-
__decorateClass$
|
|
7952
|
-
__decorateClass$
|
|
8038
|
+
__decorateClass$a([observable], Menu.prototype, "slottedMenuList", 2);
|
|
8039
|
+
__decorateClass$a([observable], Menu.prototype, "slottedTriggers", 2);
|
|
7953
8040
|
|
|
7954
8041
|
const styles$c = css`
|
|
7955
8042
|
:host{position:relative;z-index:var(--z-index-menu,1)}.positioning-container{position:fixed;top:0;left:0;transform:translate(0,0)}`;
|
|
@@ -7973,70 +8060,59 @@ const definition$c = Menu.compose({
|
|
|
7973
8060
|
|
|
7974
8061
|
definition$c.define(FluentDesignSystem.registry);
|
|
7975
8062
|
|
|
7976
|
-
var __defProp$
|
|
7977
|
-
var __getOwnPropDesc$
|
|
7978
|
-
var __decorateClass$
|
|
7979
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$
|
|
8063
|
+
var __defProp$9 = Object.defineProperty;
|
|
8064
|
+
var __getOwnPropDesc$9 = Object.getOwnPropertyDescriptor;
|
|
8065
|
+
var __decorateClass$9 = (decorators, target, key, kind) => {
|
|
8066
|
+
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$9(target, key) : target;
|
|
7980
8067
|
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$
|
|
8068
|
+
if (kind && result) __defProp$9(target, key, result);
|
|
7982
8069
|
return result;
|
|
7983
8070
|
};
|
|
7984
|
-
class
|
|
8071
|
+
class ProgressBar extends FASTElement {
|
|
7985
8072
|
constructor() {
|
|
7986
|
-
super(
|
|
7987
|
-
|
|
7988
|
-
|
|
7989
|
-
|
|
7990
|
-
|
|
8073
|
+
super();
|
|
8074
|
+
/**
|
|
8075
|
+
* The internal {@link https://developer.mozilla.org/docs/Web/API/ElementInternals | `ElementInternals`} instance for the component.
|
|
8076
|
+
*
|
|
8077
|
+
* @internal
|
|
8078
|
+
*/
|
|
8079
|
+
this.elementInternals = this.attachInternals();
|
|
8080
|
+
this.validationState = null;
|
|
8081
|
+
this.elementInternals.role = "progressbar";
|
|
7991
8082
|
}
|
|
7992
|
-
|
|
7993
|
-
|
|
7994
|
-
|
|
7995
|
-
|
|
8083
|
+
/**
|
|
8084
|
+
* Updates the percent complete when the `value` property changes.
|
|
8085
|
+
*
|
|
8086
|
+
* @internal
|
|
8087
|
+
*/
|
|
8088
|
+
valueChanged(prev, next) {
|
|
8089
|
+
this.elementInternals.ariaValueNow = typeof next === "number" ? `${next}` : null;
|
|
7996
8090
|
}
|
|
7997
|
-
|
|
7998
|
-
|
|
7999
|
-
|
|
8000
|
-
|
|
8091
|
+
/**
|
|
8092
|
+
* Updates the percent complete when the `min` property changes.
|
|
8093
|
+
*
|
|
8094
|
+
* @param prev - The previous min value
|
|
8095
|
+
* @param next - The current min value
|
|
8096
|
+
*/
|
|
8097
|
+
minChanged(prev, next) {
|
|
8098
|
+
this.elementInternals.ariaValueMin = typeof next === "number" ? `${next}` : null;
|
|
8001
8099
|
}
|
|
8002
8100
|
/**
|
|
8101
|
+
* Updates the percent complete when the `max` property changes.
|
|
8102
|
+
*
|
|
8103
|
+
* @param prev - The previous max value
|
|
8104
|
+
* @param next - The current max value
|
|
8003
8105
|
* @internal
|
|
8004
8106
|
*/
|
|
8005
|
-
|
|
8006
|
-
|
|
8007
|
-
this.updatePercentComplete();
|
|
8107
|
+
maxChanged(prev, next) {
|
|
8108
|
+
this.elementInternals.ariaValueMax = typeof next === "number" ? `${next}` : null;
|
|
8008
8109
|
}
|
|
8009
|
-
|
|
8010
|
-
const min =
|
|
8011
|
-
const max =
|
|
8012
|
-
const value =
|
|
8110
|
+
get percentComplete() {
|
|
8111
|
+
const min = this.min ?? 0;
|
|
8112
|
+
const max = this.max ?? 100;
|
|
8113
|
+
const value = this.value ?? 0;
|
|
8013
8114
|
const range = max - min;
|
|
8014
|
-
|
|
8015
|
-
}
|
|
8016
|
-
}
|
|
8017
|
-
__decorateClass$a([attr({
|
|
8018
|
-
converter: nullableNumberConverter
|
|
8019
|
-
})], BaseProgress.prototype, "value", 2);
|
|
8020
|
-
__decorateClass$a([attr({
|
|
8021
|
-
converter: nullableNumberConverter
|
|
8022
|
-
})], BaseProgress.prototype, "min", 2);
|
|
8023
|
-
__decorateClass$a([attr({
|
|
8024
|
-
converter: nullableNumberConverter
|
|
8025
|
-
})], BaseProgress.prototype, "max", 2);
|
|
8026
|
-
__decorateClass$a([observable], BaseProgress.prototype, "percentComplete", 2);
|
|
8027
|
-
|
|
8028
|
-
var __defProp$9 = Object.defineProperty;
|
|
8029
|
-
var __getOwnPropDesc$9 = Object.getOwnPropertyDescriptor;
|
|
8030
|
-
var __decorateClass$9 = (decorators, target, key, kind) => {
|
|
8031
|
-
var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$9(target, key) : target;
|
|
8032
|
-
for (var i = decorators.length - 1, decorator; i >= 0; i--) if (decorator = decorators[i]) result = (kind ? decorator(target, key, result) : decorator(result)) || result;
|
|
8033
|
-
if (kind && result) __defProp$9(target, key, result);
|
|
8034
|
-
return result;
|
|
8035
|
-
};
|
|
8036
|
-
class ProgressBar extends BaseProgress {
|
|
8037
|
-
constructor() {
|
|
8038
|
-
super(...arguments);
|
|
8039
|
-
this.validationState = null;
|
|
8115
|
+
return range === 0 ? 0 : Math.fround((value - min) / range * 100);
|
|
8040
8116
|
}
|
|
8041
8117
|
}
|
|
8042
8118
|
__decorateClass$9([attr], ProgressBar.prototype, "thickness", 2);
|
|
@@ -8044,30 +8120,29 @@ __decorateClass$9([attr], ProgressBar.prototype, "shape", 2);
|
|
|
8044
8120
|
__decorateClass$9([attr({
|
|
8045
8121
|
attribute: "validation-state"
|
|
8046
8122
|
})], ProgressBar.prototype, "validationState", 2);
|
|
8123
|
+
__decorateClass$9([attr({
|
|
8124
|
+
converter: nullableNumberConverter
|
|
8125
|
+
})], ProgressBar.prototype, "value", 2);
|
|
8126
|
+
__decorateClass$9([attr({
|
|
8127
|
+
converter: nullableNumberConverter
|
|
8128
|
+
})], ProgressBar.prototype, "min", 2);
|
|
8129
|
+
__decorateClass$9([attr({
|
|
8130
|
+
converter: nullableNumberConverter
|
|
8131
|
+
})], ProgressBar.prototype, "max", 2);
|
|
8132
|
+
__decorateClass$9([volatile], ProgressBar.prototype, "percentComplete", 1);
|
|
8047
8133
|
|
|
8048
8134
|
const styles$b = css`
|
|
8049
|
-
${display("
|
|
8135
|
+
${display("block")}
|
|
8050
8136
|
|
|
8051
|
-
:host{
|
|
8052
|
-
to right,${
|
|
8053
|
-
)}:host([validation-state='
|
|
8054
|
-
|
|
8055
|
-
|
|
8056
|
-
|
|
8057
|
-
|
|
8058
|
-
|
|
8059
|
-
|
|
8060
|
-
to right,${colorBrandBackground2} 0%,${colorCompoundBrandBackground} 50%,${colorBrandBackground2}
|
|
8061
|
-
);border-radius:${borderRadiusMedium};animation-timing-function:cubic-bezier(0.4,0,0.6,1);width:60%;animation:indeterminate-2 3s infinite}@keyframes indeterminate-1{0%{opacity:1;transform:translateX(-100%)}70%{opacity:1;transform:translateX(300%)}70.01%{opacity:0}100%{opacity:0;transform:translateX(300%)}}@keyframes indeterminate-2{0%{opacity:0;transform:translateX(-150%)}29.99%{opacity:0}30%{opacity:1;transform:translateX(-150%)}100%{transform:translateX(166.66%);opacity:1}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
8062
|
-
.progress{background-color:HighlightText}.determinate,:host([validation-state='success']) .determinate,:host([validation-state='warning']) .determinate,:host([validation-state='error']) .determinate,:host([validation-state='success']) ..indeterminate-indicator-1,:host([validation-state='success']) ..indeterminate-indicator-2,:host([validation-state='warning']) .indeterminate-indicator-1,:host([validation-state='warning']) .indeterminate-indicator-2,:host([validation-state='error']) .indeterminate-indicator-1,:host([validation-state='error']) .indeterminate-indicator-2{background-color:Highlight}`));
|
|
8063
|
-
|
|
8064
|
-
function progressTemplate(options = {}) {
|
|
8065
|
-
return html`<template role="progressbar" aria-valuenow="${x => x.value}" aria-valuemin="${x => x.min}" aria-valuemax="${x => x.max}">${when(x => typeof x.value === "number", html`<div class="progress" part="progress" slot="determinate"><div class="determinate" part="determinate" style="width: ${x => x.percentComplete}%"></div></div>`, html`<div class="progress" part="progress" slot="indeterminate"><slot name="indeterminate">${staticallyCompose(options.indeterminateIndicator1)} ${staticallyCompose(options.indeterminateIndicator2)}</slot></div>`)}</template>`;
|
|
8066
|
-
}
|
|
8067
|
-
const template$b = progressTemplate({
|
|
8068
|
-
indeterminateIndicator1: `<span class="indeterminate-indicator-1" part="indeterminate-indicator-1></span>`,
|
|
8069
|
-
indeterminateIndicator2: `<span class="indeterminate-indicator-2" part="indeterminate-indicator-2"></span>`
|
|
8070
|
-
});
|
|
8137
|
+
:host{width:100%;height:2px;overflow-x:hidden;background-color:${colorNeutralBackground6};border-radius:${borderRadiusMedium};contain:content}:host([thickness='large']){height:4px}:host([shape='square']){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(
|
|
8138
|
+
to right,${colorNeutralBackground6} 0%,${colorTransparentBackground} 50%,${colorNeutralBackground6} 100%
|
|
8139
|
+
);animation-name:indeterminate;animation-duration:3s;animation-timing-function:linear;animation-iteration-count:infinite}:host([validation-state='error']) .indicator{background-color:${colorPaletteRedBackground3}}:host([validation-state='warning']) .indicator{background-color:${colorPaletteDarkOrangeBackground3}}:host([validation-state='success']) .indicator{background-color:${colorPaletteGreenBackground3}}@layer animations{@media (prefers-reduced-motion:no-preference){:host([value]){transition:none}:host(:not([value])) .indicator{animation-duration:0.01ms;animation-iteration-count:1}}}@keyframes indeterminate{0%{inset-inline-start:-33%}100%{inset-inline-start:100%}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
8140
|
+
:host{background-color:CanvasText}.indicator,:host(:is([validation-state='success'],[validation-state='warning'],[validation-state='error'])) .indicator{background-color:Highlight}`));
|
|
8141
|
+
|
|
8142
|
+
function progressTemplate() {
|
|
8143
|
+
return html`<div class="indicator" part="indicator" style="${x => typeof x.value === "number" ? `width: ${x.percentComplete}%` : void 0}"></div>`;
|
|
8144
|
+
}
|
|
8145
|
+
const template$b = progressTemplate();
|
|
8071
8146
|
|
|
8072
8147
|
const definition$b = ProgressBar.compose({
|
|
8073
8148
|
name: `${FluentDesignSystem.prefix}-progress-bar`,
|
|
@@ -10430,7 +10505,7 @@ __decorateClass([attr({
|
|
|
10430
10505
|
})], ToggleButton.prototype, "mixed", 2);
|
|
10431
10506
|
|
|
10432
10507
|
const styles = css`
|
|
10433
|
-
${styles$
|
|
10508
|
+
${styles$r}
|
|
10434
10509
|
|
|
10435
10510
|
:host([aria-pressed='true']){border-color:${colorNeutralStroke1};background-color:${colorNeutralBackground1Selected};color:${colorNeutralForeground1};border-width:${strokeWidthThin}}:host([aria-pressed='true']:hover){border-color:${colorNeutralStroke1Hover};background-color:${colorNeutralBackground1Hover}}:host([aria-pressed='true']:active){border-color:${colorNeutralStroke1Pressed};background-color:${colorNeutralBackground1Pressed}}:host([aria-pressed='true'][appearance='primary']){border-color:transparent;background-color:${colorBrandBackgroundSelected};color:${colorNeutralForegroundOnBrand}}:host([aria-pressed='true'][appearance='primary']:hover){background-color:${colorBrandBackgroundHover}}:host([aria-pressed='true'][appearance='primary']:active){background-color:${colorBrandBackgroundPressed}}:host([aria-pressed='true'][appearance='subtle']){border-color:transparent;background-color:${colorSubtleBackgroundSelected};color:${colorNeutralForeground2Selected}}:host([aria-pressed='true'][appearance='subtle']:hover){background-color:${colorSubtleBackgroundHover};color:${colorNeutralForeground2Hover}}:host([aria-pressed='true'][appearance='subtle']:active){background-color:${colorSubtleBackgroundPressed};color:${colorNeutralForeground2Pressed}}:host([aria-pressed='true'][appearance='outline']),:host([aria-pressed='true'][appearance='transparent']){background-color:${colorTransparentBackgroundSelected}}:host([aria-pressed='true'][appearance='outline']:hover),:host([aria-pressed='true'][appearance='transparent']:hover){background-color:${colorTransparentBackgroundHover}}:host([aria-pressed='true'][appearance='outline']:active),:host([aria-pressed='true'][appearance='transparent']:active){background-color:${colorTransparentBackgroundPressed}}:host([aria-pressed='true'][appearance='transparent']){border-color:transparent;color:${colorNeutralForeground2BrandSelected}}:host([aria-pressed='true'][appearance='transparent']:hover){color:${colorNeutralForeground2BrandHover}}:host([aria-pressed='true'][appearance='transparent']:active){color:${colorNeutralForeground2BrandPressed}}`.withBehaviors(forcedColorsStylesheetBehavior(css`
|
|
10436
10511
|
:host([aria-pressed='true']),:host([aria-pressed='true'][appearance='primary']),:host([aria-pressed='true'][appearance='subtle']),:host([aria-pressed='true'][appearance='outline']),:host([aria-pressed='true'][appearance='transparent']){background:SelectedItem;color:SelectedItemText}`));
|