@getflip/swirl-components 0.532.0 → 0.532.1
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/components.json +28 -10
- package/dist/cjs/swirl-checkbox.cjs.entry.js +2 -1
- package/dist/cjs/swirl-radio.cjs.entry.js +2 -1
- package/dist/cjs/swirl-switch.cjs.entry.js +3 -2
- package/dist/cjs/swirl-visually-hidden.cjs.entry.js +1 -1
- package/dist/collection/components/swirl-checkbox/swirl-checkbox.js +6 -4
- package/dist/collection/components/swirl-radio/swirl-radio.js +6 -4
- package/dist/collection/components/swirl-switch/swirl-switch.js +7 -5
- package/dist/collection/components/swirl-visually-hidden/swirl-visually-hidden.css +1 -1
- package/dist/components/swirl-checkbox.js +1 -1
- package/dist/components/swirl-radio.js +1 -1
- package/dist/components/swirl-switch.js +1 -1
- package/dist/components/swirl-visually-hidden2.js +1 -1
- package/dist/esm/swirl-checkbox.entry.js +2 -1
- package/dist/esm/swirl-radio.entry.js +2 -1
- package/dist/esm/swirl-switch.entry.js +3 -2
- package/dist/esm/swirl-visually-hidden.entry.js +1 -1
- package/dist/swirl-components/{p-ffcaf25a.entry.js → p-6b8f82d2.entry.js} +1 -1
- package/dist/swirl-components/p-769d0e2e.entry.js +1 -0
- package/dist/swirl-components/p-850d71e1.entry.js +1 -0
- package/dist/swirl-components/p-bbe66770.entry.js +1 -0
- package/dist/swirl-components/swirl-components.esm.js +1 -1
- package/dist/types/components/swirl-checkbox/swirl-checkbox.d.ts +1 -1
- package/dist/types/components/swirl-radio/swirl-radio.d.ts +1 -1
- package/dist/types/components/swirl-switch/swirl-switch.d.ts +1 -1
- package/dist/types/components.d.ts +27 -9
- package/package.json +1 -1
- package/dist/swirl-components/p-090c46fe.entry.js +0 -1
- package/dist/swirl-components/p-d7be455c.entry.js +0 -1
- package/dist/swirl-components/p-d8f87ffc.entry.js +0 -1
|
@@ -729,7 +729,10 @@ export namespace Components {
|
|
|
729
729
|
* @default false
|
|
730
730
|
*/
|
|
731
731
|
"disabled"?: boolean;
|
|
732
|
-
|
|
732
|
+
/**
|
|
733
|
+
* @default crypto.randomUUID()
|
|
734
|
+
*/
|
|
735
|
+
"inputId"?: string;
|
|
733
736
|
"inputName": string;
|
|
734
737
|
"invalid"?: boolean;
|
|
735
738
|
"label"?: string;
|
|
@@ -4274,7 +4277,10 @@ export namespace Components {
|
|
|
4274
4277
|
* @default false
|
|
4275
4278
|
*/
|
|
4276
4279
|
"disabled"?: boolean;
|
|
4277
|
-
|
|
4280
|
+
/**
|
|
4281
|
+
* @default crypto.randomUUID()
|
|
4282
|
+
*/
|
|
4283
|
+
"inputId"?: string;
|
|
4278
4284
|
"inputName": string;
|
|
4279
4285
|
"invalid"?: boolean;
|
|
4280
4286
|
"label"?: string;
|
|
@@ -4666,7 +4672,10 @@ export namespace Components {
|
|
|
4666
4672
|
"disabled"?: boolean;
|
|
4667
4673
|
"hideDescription"?: boolean;
|
|
4668
4674
|
"hideLabel"?: boolean;
|
|
4669
|
-
|
|
4675
|
+
/**
|
|
4676
|
+
* @default crypto.randomUUID()
|
|
4677
|
+
*/
|
|
4678
|
+
"inputId"?: string;
|
|
4670
4679
|
"inputName": string;
|
|
4671
4680
|
"label"?: string;
|
|
4672
4681
|
/**
|
|
@@ -11296,7 +11305,10 @@ declare namespace LocalJSX {
|
|
|
11296
11305
|
* @default false
|
|
11297
11306
|
*/
|
|
11298
11307
|
"disabled"?: boolean;
|
|
11299
|
-
|
|
11308
|
+
/**
|
|
11309
|
+
* @default crypto.randomUUID()
|
|
11310
|
+
*/
|
|
11311
|
+
"inputId"?: string;
|
|
11300
11312
|
"inputName": string;
|
|
11301
11313
|
"invalid"?: boolean;
|
|
11302
11314
|
"label"?: string;
|
|
@@ -14737,7 +14749,10 @@ declare namespace LocalJSX {
|
|
|
14737
14749
|
* @default false
|
|
14738
14750
|
*/
|
|
14739
14751
|
"disabled"?: boolean;
|
|
14740
|
-
|
|
14752
|
+
/**
|
|
14753
|
+
* @default crypto.randomUUID()
|
|
14754
|
+
*/
|
|
14755
|
+
"inputId"?: string;
|
|
14741
14756
|
"inputName": string;
|
|
14742
14757
|
"invalid"?: boolean;
|
|
14743
14758
|
"label"?: string;
|
|
@@ -15138,7 +15153,10 @@ declare namespace LocalJSX {
|
|
|
15138
15153
|
"disabled"?: boolean;
|
|
15139
15154
|
"hideDescription"?: boolean;
|
|
15140
15155
|
"hideLabel"?: boolean;
|
|
15141
|
-
|
|
15156
|
+
/**
|
|
15157
|
+
* @default crypto.randomUUID()
|
|
15158
|
+
*/
|
|
15159
|
+
"inputId"?: string;
|
|
15142
15160
|
"inputName": string;
|
|
15143
15161
|
"label"?: string;
|
|
15144
15162
|
/**
|
|
@@ -19340,7 +19358,7 @@ declare namespace LocalJSX {
|
|
|
19340
19358
|
"swirl-card": Omit<SwirlCard, keyof SwirlCardAttributes> & { [K in keyof SwirlCard & keyof SwirlCardAttributes]?: SwirlCard[K] } & { [K in keyof SwirlCard & keyof SwirlCardAttributes as `attr:${K}`]?: SwirlCardAttributes[K] } & { [K in keyof SwirlCard & keyof SwirlCardAttributes as `prop:${K}`]?: SwirlCard[K] };
|
|
19341
19359
|
"swirl-carousel": Omit<SwirlCarousel, keyof SwirlCarouselAttributes> & { [K in keyof SwirlCarousel & keyof SwirlCarouselAttributes]?: SwirlCarousel[K] } & { [K in keyof SwirlCarousel & keyof SwirlCarouselAttributes as `attr:${K}`]?: SwirlCarouselAttributes[K] } & { [K in keyof SwirlCarousel & keyof SwirlCarouselAttributes as `prop:${K}`]?: SwirlCarousel[K] } & OneOf<"label", SwirlCarousel["label"], SwirlCarouselAttributes["label"]>;
|
|
19342
19360
|
"swirl-carousel-slide": Omit<SwirlCarouselSlide, keyof SwirlCarouselSlideAttributes> & { [K in keyof SwirlCarouselSlide & keyof SwirlCarouselSlideAttributes]?: SwirlCarouselSlide[K] } & { [K in keyof SwirlCarouselSlide & keyof SwirlCarouselSlideAttributes as `attr:${K}`]?: SwirlCarouselSlideAttributes[K] } & { [K in keyof SwirlCarouselSlide & keyof SwirlCarouselSlideAttributes as `prop:${K}`]?: SwirlCarouselSlide[K] };
|
|
19343
|
-
"swirl-checkbox": Omit<SwirlCheckbox, keyof SwirlCheckboxAttributes> & { [K in keyof SwirlCheckbox & keyof SwirlCheckboxAttributes]?: SwirlCheckbox[K] } & { [K in keyof SwirlCheckbox & keyof SwirlCheckboxAttributes as `attr:${K}`]?: SwirlCheckboxAttributes[K] } & { [K in keyof SwirlCheckbox & keyof SwirlCheckboxAttributes as `prop:${K}`]?: SwirlCheckbox[K] } & OneOf<"
|
|
19361
|
+
"swirl-checkbox": Omit<SwirlCheckbox, keyof SwirlCheckboxAttributes> & { [K in keyof SwirlCheckbox & keyof SwirlCheckboxAttributes]?: SwirlCheckbox[K] } & { [K in keyof SwirlCheckbox & keyof SwirlCheckboxAttributes as `attr:${K}`]?: SwirlCheckboxAttributes[K] } & { [K in keyof SwirlCheckbox & keyof SwirlCheckboxAttributes as `prop:${K}`]?: SwirlCheckbox[K] } & OneOf<"inputName", SwirlCheckbox["inputName"], SwirlCheckboxAttributes["inputName"]>;
|
|
19344
19362
|
"swirl-chip": Omit<SwirlChip, keyof SwirlChipAttributes> & { [K in keyof SwirlChip & keyof SwirlChipAttributes]?: SwirlChip[K] } & { [K in keyof SwirlChip & keyof SwirlChipAttributes as `attr:${K}`]?: SwirlChipAttributes[K] } & { [K in keyof SwirlChip & keyof SwirlChipAttributes as `prop:${K}`]?: SwirlChip[K] } & OneOf<"label", SwirlChip["label"], SwirlChipAttributes["label"]>;
|
|
19345
19363
|
"swirl-color-input": Omit<SwirlColorInput, keyof SwirlColorInputAttributes> & { [K in keyof SwirlColorInput & keyof SwirlColorInputAttributes]?: SwirlColorInput[K] } & { [K in keyof SwirlColorInput & keyof SwirlColorInputAttributes as `attr:${K}`]?: SwirlColorInputAttributes[K] } & { [K in keyof SwirlColorInput & keyof SwirlColorInputAttributes as `prop:${K}`]?: SwirlColorInput[K] };
|
|
19346
19364
|
"swirl-columns": Omit<SwirlColumns, keyof SwirlColumnsAttributes> & { [K in keyof SwirlColumns & keyof SwirlColumnsAttributes]?: SwirlColumns[K] } & { [K in keyof SwirlColumns & keyof SwirlColumnsAttributes as `attr:${K}`]?: SwirlColumnsAttributes[K] } & { [K in keyof SwirlColumns & keyof SwirlColumnsAttributes as `prop:${K}`]?: SwirlColumns[K] };
|
|
@@ -19708,7 +19726,7 @@ declare namespace LocalJSX {
|
|
|
19708
19726
|
"swirl-popover": Omit<SwirlPopover, keyof SwirlPopoverAttributes> & { [K in keyof SwirlPopover & keyof SwirlPopoverAttributes]?: SwirlPopover[K] } & { [K in keyof SwirlPopover & keyof SwirlPopoverAttributes as `attr:${K}`]?: SwirlPopoverAttributes[K] } & { [K in keyof SwirlPopover & keyof SwirlPopoverAttributes as `prop:${K}`]?: SwirlPopover[K] } & OneOf<"label", SwirlPopover["label"], SwirlPopoverAttributes["label"]>;
|
|
19709
19727
|
"swirl-popover-trigger": Omit<SwirlPopoverTrigger, keyof SwirlPopoverTriggerAttributes> & { [K in keyof SwirlPopoverTrigger & keyof SwirlPopoverTriggerAttributes]?: SwirlPopoverTrigger[K] } & { [K in keyof SwirlPopoverTrigger & keyof SwirlPopoverTriggerAttributes as `attr:${K}`]?: SwirlPopoverTriggerAttributes[K] } & { [K in keyof SwirlPopoverTrigger & keyof SwirlPopoverTriggerAttributes as `prop:${K}`]?: SwirlPopoverTrigger[K] } & OneOf<"swirlPopover", SwirlPopoverTrigger["swirlPopover"], SwirlPopoverTriggerAttributes["swirlPopover"]>;
|
|
19710
19728
|
"swirl-progress-indicator": Omit<SwirlProgressIndicator, keyof SwirlProgressIndicatorAttributes> & { [K in keyof SwirlProgressIndicator & keyof SwirlProgressIndicatorAttributes]?: SwirlProgressIndicator[K] } & { [K in keyof SwirlProgressIndicator & keyof SwirlProgressIndicatorAttributes as `attr:${K}`]?: SwirlProgressIndicatorAttributes[K] } & { [K in keyof SwirlProgressIndicator & keyof SwirlProgressIndicatorAttributes as `prop:${K}`]?: SwirlProgressIndicator[K] } & OneOf<"label", SwirlProgressIndicator["label"], SwirlProgressIndicatorAttributes["label"]>;
|
|
19711
|
-
"swirl-radio": Omit<SwirlRadio, keyof SwirlRadioAttributes> & { [K in keyof SwirlRadio & keyof SwirlRadioAttributes]?: SwirlRadio[K] } & { [K in keyof SwirlRadio & keyof SwirlRadioAttributes as `attr:${K}`]?: SwirlRadioAttributes[K] } & { [K in keyof SwirlRadio & keyof SwirlRadioAttributes as `prop:${K}`]?: SwirlRadio[K] } & OneOf<"
|
|
19729
|
+
"swirl-radio": Omit<SwirlRadio, keyof SwirlRadioAttributes> & { [K in keyof SwirlRadio & keyof SwirlRadioAttributes]?: SwirlRadio[K] } & { [K in keyof SwirlRadio & keyof SwirlRadioAttributes as `attr:${K}`]?: SwirlRadioAttributes[K] } & { [K in keyof SwirlRadio & keyof SwirlRadioAttributes as `prop:${K}`]?: SwirlRadio[K] } & OneOf<"inputName", SwirlRadio["inputName"], SwirlRadioAttributes["inputName"]> & OneOf<"value", SwirlRadio["value"], SwirlRadioAttributes["value"]>;
|
|
19712
19730
|
"swirl-radio-group": Omit<SwirlRadioGroup, keyof SwirlRadioGroupAttributes> & { [K in keyof SwirlRadioGroup & keyof SwirlRadioGroupAttributes]?: SwirlRadioGroup[K] } & { [K in keyof SwirlRadioGroup & keyof SwirlRadioGroupAttributes as `attr:${K}`]?: SwirlRadioGroupAttributes[K] } & { [K in keyof SwirlRadioGroup & keyof SwirlRadioGroupAttributes as `prop:${K}`]?: SwirlRadioGroup[K] };
|
|
19713
19731
|
"swirl-resource-list": Omit<SwirlResourceList, keyof SwirlResourceListAttributes> & { [K in keyof SwirlResourceList & keyof SwirlResourceListAttributes]?: SwirlResourceList[K] } & { [K in keyof SwirlResourceList & keyof SwirlResourceListAttributes as `attr:${K}`]?: SwirlResourceListAttributes[K] } & { [K in keyof SwirlResourceList & keyof SwirlResourceListAttributes as `prop:${K}`]?: SwirlResourceList[K] };
|
|
19714
19732
|
"swirl-resource-list-file-item": Omit<SwirlResourceListFileItem, keyof SwirlResourceListFileItemAttributes> & { [K in keyof SwirlResourceListFileItem & keyof SwirlResourceListFileItemAttributes]?: SwirlResourceListFileItem[K] } & { [K in keyof SwirlResourceListFileItem & keyof SwirlResourceListFileItemAttributes as `attr:${K}`]?: SwirlResourceListFileItemAttributes[K] } & { [K in keyof SwirlResourceListFileItem & keyof SwirlResourceListFileItemAttributes as `prop:${K}`]?: SwirlResourceListFileItem[K] } & OneOf<"label", SwirlResourceListFileItem["label"], SwirlResourceListFileItemAttributes["label"]>;
|
|
@@ -19724,7 +19742,7 @@ declare namespace LocalJSX {
|
|
|
19724
19742
|
"swirl-spinner": Omit<SwirlSpinner, keyof SwirlSpinnerAttributes> & { [K in keyof SwirlSpinner & keyof SwirlSpinnerAttributes]?: SwirlSpinner[K] } & { [K in keyof SwirlSpinner & keyof SwirlSpinnerAttributes as `attr:${K}`]?: SwirlSpinnerAttributes[K] } & { [K in keyof SwirlSpinner & keyof SwirlSpinnerAttributes as `prop:${K}`]?: SwirlSpinner[K] };
|
|
19725
19743
|
"swirl-stack": Omit<SwirlStack, keyof SwirlStackAttributes> & { [K in keyof SwirlStack & keyof SwirlStackAttributes]?: SwirlStack[K] } & { [K in keyof SwirlStack & keyof SwirlStackAttributes as `attr:${K}`]?: SwirlStackAttributes[K] } & { [K in keyof SwirlStack & keyof SwirlStackAttributes as `prop:${K}`]?: SwirlStack[K] };
|
|
19726
19744
|
"swirl-status-indicator": Omit<SwirlStatusIndicator, keyof SwirlStatusIndicatorAttributes> & { [K in keyof SwirlStatusIndicator & keyof SwirlStatusIndicatorAttributes]?: SwirlStatusIndicator[K] } & { [K in keyof SwirlStatusIndicator & keyof SwirlStatusIndicatorAttributes as `attr:${K}`]?: SwirlStatusIndicatorAttributes[K] } & { [K in keyof SwirlStatusIndicator & keyof SwirlStatusIndicatorAttributes as `prop:${K}`]?: SwirlStatusIndicator[K] } & OneOf<"intent", SwirlStatusIndicator["intent"], SwirlStatusIndicatorAttributes["intent"]> & OneOf<"label", SwirlStatusIndicator["label"], SwirlStatusIndicatorAttributes["label"]>;
|
|
19727
|
-
"swirl-switch": Omit<SwirlSwitch, keyof SwirlSwitchAttributes> & { [K in keyof SwirlSwitch & keyof SwirlSwitchAttributes]?: SwirlSwitch[K] } & { [K in keyof SwirlSwitch & keyof SwirlSwitchAttributes as `attr:${K}`]?: SwirlSwitchAttributes[K] } & { [K in keyof SwirlSwitch & keyof SwirlSwitchAttributes as `prop:${K}`]?: SwirlSwitch[K] } & OneOf<"
|
|
19745
|
+
"swirl-switch": Omit<SwirlSwitch, keyof SwirlSwitchAttributes> & { [K in keyof SwirlSwitch & keyof SwirlSwitchAttributes]?: SwirlSwitch[K] } & { [K in keyof SwirlSwitch & keyof SwirlSwitchAttributes as `attr:${K}`]?: SwirlSwitchAttributes[K] } & { [K in keyof SwirlSwitch & keyof SwirlSwitchAttributes as `prop:${K}`]?: SwirlSwitch[K] } & OneOf<"inputName", SwirlSwitch["inputName"], SwirlSwitchAttributes["inputName"]>;
|
|
19728
19746
|
"swirl-symbol": Omit<SwirlSymbol, keyof SwirlSymbolAttributes> & { [K in keyof SwirlSymbol & keyof SwirlSymbolAttributes]?: SwirlSymbol[K] } & { [K in keyof SwirlSymbol & keyof SwirlSymbolAttributes as `attr:${K}`]?: SwirlSymbolAttributes[K] } & { [K in keyof SwirlSymbol & keyof SwirlSymbolAttributes as `prop:${K}`]?: SwirlSymbol[K] } & OneOf<"glyph", SwirlSymbol["glyph"], SwirlSymbolAttributes["glyph"]>;
|
|
19729
19747
|
"swirl-symbol-ac-unit": Omit<SwirlSymbolAcUnit, keyof SwirlSymbolAcUnitAttributes> & { [K in keyof SwirlSymbolAcUnit & keyof SwirlSymbolAcUnitAttributes]?: SwirlSymbolAcUnit[K] } & { [K in keyof SwirlSymbolAcUnit & keyof SwirlSymbolAcUnitAttributes as `attr:${K}`]?: SwirlSymbolAcUnitAttributes[K] } & { [K in keyof SwirlSymbolAcUnit & keyof SwirlSymbolAcUnitAttributes as `prop:${K}`]?: SwirlSymbolAcUnit[K] };
|
|
19730
19748
|
"swirl-symbol-account-circle": Omit<SwirlSymbolAccountCircle, keyof SwirlSymbolAccountCircleAttributes> & { [K in keyof SwirlSymbolAccountCircle & keyof SwirlSymbolAccountCircleAttributes]?: SwirlSymbolAccountCircle[K] } & { [K in keyof SwirlSymbolAccountCircle & keyof SwirlSymbolAccountCircleAttributes as `attr:${K}`]?: SwirlSymbolAccountCircleAttributes[K] } & { [K in keyof SwirlSymbolAccountCircle & keyof SwirlSymbolAccountCircleAttributes as `prop:${K}`]?: SwirlSymbolAccountCircle[K] };
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as i,c as r,h as a,a as o}from"./p-Dz56lJ37.js";import{c as d}from"./p-orsBiyT_.js";const s=class{constructor(a){i(this,a),this.valueChange=r(this,"valueChange",7),this.checked=!1,this.disabled=!1,this.variant="default",this.onChange=()=>{this.checked=!0,this.valueChange.emit(this.value)}}getAriaCheckedLabel(i,r){return i?"true":r?"false":"mixed"}render(){const i=!1===this.checked||"false"===this.checked,r=!0===this.checked||"true"===this.checked,s=this.getAriaCheckedLabel(r,i),e=this.invalid,c=d("radio",`radio--variant-${this.variant}`,{"radio--checked":r,"radio--disabled":this.disabled,"radio--invalid":this.invalid,"radio--unchecked":i});return a(o,{key:"aa9c0d9bebb8e104698f5f45589f5636d6a57b25",style:{width:"card"===this.variant?"100%":void 0}},a("label",{key:"c51413a2d4cd968fbdcc2115c38ea6c38c0b4801",class:c,htmlFor:this.inputId},a("span",{key:"9f718c353d5c8046c241966fe3c9d0b2b0a1ecfa",class:"radio__control"},a("swirl-visually-hidden",{key:"599cdc2ef0c94d52a05df3f8156e56bffb73532e"},a("input",{key:"24e1da66087e39dc19506bd38ee48a14304aec19","aria-checked":s,"aria-invalid":e,checked:r,class:"radio__input",disabled:this.disabled,id:this.inputId,name:this.inputName,onChange:this.onChange,type:"radio",value:this.value})),a("span",{key:"704b7e4833980608492d696d93b03c676064ac03","aria-hidden":"true",class:"radio__box"})),a("span",{key:"771603ee81046ed3c8b9fe0c923c44f2decd1995",class:"radio__label-container"},this.label&&a("span",{key:"978ae28cbc9014c8849910db58bdc690c6ef9459",class:"radio__label"},this.label,this.tooltip&&a("swirl-tooltip",{key:"e008a4d5fe98bb9c94a6f9c0fff108722809c913",content:this.tooltip,position:"top"},a("swirl-icon-help",{key:"61f389e02e355012739b0f2e11214f0b33890746",color:"default",size:20,tabIndex:0}))),this.description&&a("span",{key:"caec71b508626e3f8d58cc1a2b9141d80899595b",class:"radio__description",innerHTML:this.description}))))}};s.style='.sc-swirl-radio-h{display:inline-flex}.sc-swirl-radio-h *.sc-swirl-radio{box-sizing:border-box}.radio.sc-swirl-radio{display:inline-flex;line-height:var(--s-line-height-base);cursor:pointer;align-items:center}.radio.sc-swirl-radio:focus-within .radio__box.sc-swirl-radio{box-shadow:0 0 0 0.0625rem var(--s-background-default), 0 0 0 0.1875rem var(--s-focus-default)}.radio--variant-card.sc-swirl-radio{width:100%;padding:var(--s-space-16);border:0.0625rem solid var(--s-border-default);border-radius:var(--s-border-radius-sm);background-color:var(--s-surface)}.radio--variant-card.sc-swirl-radio:focus-within{box-shadow:0 0 0 0.125rem var(--s-background-default), 0 0 0 0.25rem var(--s-focus-default)}.radio--variant-card.sc-swirl-radio:focus-within .radio__box.sc-swirl-radio{box-shadow:none}.radio--variant-card.sc-swirl-radio:hover:not(.radio--disabled){background-color:var(--s-state-hovered)}.radio--variant-card.sc-swirl-radio:active:not(.radio--disabled){background-color:var(--s-state-pressed)}.radio--variant-card.radio--checked.sc-swirl-radio:not(.radio--disabled){border-color:var(--s-border-highlight)}.radio--variant-card.radio--invalid.sc-swirl-radio:not(.radio--disabled){border-color:var(--s-border-critical)}.radio--checked.sc-swirl-radio .radio__control.sc-swirl-radio:hover .radio__box.sc-swirl-radio{border-color:var(--s-interactive-primary-hovered);background-color:var(--s-interactive-primary-hovered)}.radio--checked.sc-swirl-radio .radio__box.sc-swirl-radio{position:relative;border-color:var(--s-icon-highlight);background-color:var(--s-icon-highlight)}.radio--checked.sc-swirl-radio .radio__box.sc-swirl-radio:after{position:absolute;top:50%;left:50%;width:0.5rem;height:0.5rem;border-radius:50%;background-color:var(--s-background-default);content:"";transform:translate3d(-50%, -50%, 0)}.radio--invalid.radio--checked.sc-swirl-radio .radio__box.sc-swirl-radio,.radio--invalid.radio--indeterminate.sc-swirl-radio .radio__box.sc-swirl-radio{background-color:var(--s-icon-critical)}.radio--invalid.sc-swirl-radio .radio__box.sc-swirl-radio{border-color:var(--s-icon-critical)}.radio--disabled.sc-swirl-radio{cursor:default}.radio--disabled.radio--checked.sc-swirl-radio .radio__control.sc-swirl-radio:hover .radio__box.sc-swirl-radio{border-color:var(--s-icon-disabled);background-color:transparent}.radio--disabled.radio--checked.sc-swirl-radio .radio__box.sc-swirl-radio{border-color:var(--s-icon-disabled);background-color:var(--s-background-default)}.radio--disabled.radio--checked.sc-swirl-radio .radio__box.sc-swirl-radio:after{background-color:var(--s-icon-disabled)}.radio--disabled.sc-swirl-radio .radio__control.sc-swirl-radio:hover .radio__box.sc-swirl-radio{background-color:transparent}.radio--disabled.sc-swirl-radio .radio__box.sc-swirl-radio{border-color:var(--s-icon-disabled)}.radio--disabled.sc-swirl-radio .radio__description.sc-swirl-radio,.radio--disabled.sc-swirl-radio .radio__label.sc-swirl-radio{color:var(--s-text-disabled)}.radio__control.sc-swirl-radio{position:relative;display:inline-flex;width:1.5rem;height:1.5rem;padding:var(--s-space-2);flex-shrink:0}.radio__control.sc-swirl-radio:hover .radio__box.sc-swirl-radio{background-color:var(--s-action-neutral-hovered)}@media (min-width: 992px) and (max-width: 1439px) and (hover: hover),(min-width: 1440px){.radio__control.sc-swirl-radio{width:1.375rem;height:1.375rem}}.radio__box.sc-swirl-radio{position:relative;display:flex;width:100%;height:100%;justify-content:center;align-items:center;border:0.125rem solid var(--s-icon-default);border-radius:50%}.radio__label-container.sc-swirl-radio{display:inline-flex;margin-left:var(--s-space-8);padding-top:var(--s-space-2);flex-direction:column}.radio__label.sc-swirl-radio{display:flex;align-items:center;font-weight:var(--s-font-weight-medium);gap:var(--s-space-8)}@media (min-width: 992px) and (max-width: 1439px) and (hover: hover),(min-width: 1440px){.radio__label.sc-swirl-radio{font-size:var(--s-font-size-sm);line-height:var(--s-line-height-sm)}}.radio__description.sc-swirl-radio{color:var(--s-text-subdued)}@media (min-width: 992px) and (max-width: 1439px) and (hover: hover),(min-width: 1440px){.radio__description.sc-swirl-radio{font-size:var(--s-font-size-sm);line-height:var(--s-line-height-sm)}}';export{s as swirl_radio}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as s,c as i,h as t,a as c,d as e}from"./p-Dz56lJ37.js";import{c as h}from"./p-orsBiyT_.js";const r=class{constructor(t){s(this,t),this.valueChange=i(this,"valueChange",7),this.checked=!1,this.disabled=!1,this.labelPosition="end",this.onChange=()=>{this.checked=!this.checked,this.valueChange.emit(this.checked)}}async toggle(){this.inputEl.dispatchEvent(new Event("change"))}render(){const s=this.checked,i=s?"true":"false",e=h("switch",`switch--label-position-${this.labelPosition}`,{"switch--off":!this.checked,"switch--on":s,"switch--disabled":this.disabled,"switch--hide-content":this.hideLabel&&(!this.description||this.hideDescription)});return t(c,{key:"2fb5d73922f7e161d5e7c0c3b286e71909d9afa1"},t("label",{key:"06a4b812a51a1e02163bafbc79fba00cd9da1fc4",class:e,htmlFor:this.inputId},t("span",{key:"3437c3cc4ccc565cb0951217e4850912a04b81f5",class:"switch__control"},t("swirl-visually-hidden",{key:"659b48e2f404b44758e8ea5b5ced5160a4f0ed90"},t("input",{key:"bd017433558151dacb18b83077fddfaa65792ebe","aria-checked":i,"aria-label":!this.hideLabel&&this.swirlAriaLabel?this.swirlAriaLabel:void 0,checked:s,class:"switch__input",disabled:this.disabled,id:this.inputId,name:this.inputName,onChange:this.onChange,ref:s=>this.inputEl=s,role:"switch",type:"checkbox",value:this.value})),t("span",{key:"d52f7320fb0ce09f1c8cf09292241fc5548d2dbc","aria-hidden":"true",class:"switch__thumb"})),t("swirl-stack",{key:"51245072674d93191030555f25512d04d82f53dd",class:"switch__content"},this.label&&!this.hideLabel&&t("span",{key:"82428af2bfff294332b6c18eaaede1cdd7421372",class:"switch__label"},this.label),this.hideLabel&&t("swirl-visually-hidden",{key:"c33ed44f3544a3c8e9cab85658488096c7033b1b"},this.swirlAriaLabel||this.label),this.description&&!this.hideDescription&&t("span",{key:"241a8bd0dedae4ebcdf8e07fd08f8da29cceda6e",class:"switch__description"},this.description),this.description&&this.hideDescription&&t("swirl-visually-hidden",{key:"70f72067ec425857bf72995f5c35c0c72c5a326d"},this.description))))}get el(){return e(this)}};r.style=".sc-swirl-switch-h{display:inline-flex;max-width:100%}.sc-swirl-switch-h *.sc-swirl-switch{box-sizing:border-box}.switch.sc-swirl-switch{display:inline-flex;width:100%;align-items:center;touch-action:none}.switch.sc-swirl-switch:focus-within .switch__control.sc-swirl-switch{box-shadow:0 0 0 0.0625rem var(--s-background-default), 0 0 0 0.1875rem var(--s-focus-default)}.switch--label-position-start.sc-swirl-switch{flex-direction:row-reverse}.switch--label-position-start.sc-swirl-switch .switch__content.sc-swirl-switch{margin-right:var(--s-space-12);margin-left:0}.switch--on.sc-swirl-switch .switch__thumb.sc-swirl-switch{left:calc(100% - 1.25rem - var(--s-space-2))}@media (min-width: 992px) and (max-width: 1439px) and (hover: hover),(min-width: 1440px){.switch--on.sc-swirl-switch .switch__thumb.sc-swirl-switch{left:calc(100% - 0.875rem - var(--s-space-2))}}.switch--on.sc-swirl-switch .switch__control.sc-swirl-switch{background-color:var(--s-interactive-primary-default)}.switch--disabled.sc-swirl-switch .switch__control.sc-swirl-switch{background-color:var(--s-interactive-primary-disabled);cursor:default}.switch--disabled.sc-swirl-switch .switch__thumb.sc-swirl-switch{background-color:var(--s-interactive-neutral-default)}.switch--disabled.sc-swirl-switch .switch__label.sc-swirl-switch{color:var(--s-text-disabled)}.switch--hide-content.sc-swirl-switch .switch__content.sc-swirl-switch{margin-left:0}.switch__control.sc-swirl-switch{position:relative;width:2.75rem;height:1.5rem;flex-shrink:0;border-radius:calc(1.5rem / 2);background-color:var(--s-interactive-primary-disabled);cursor:pointer;transition:background-color 0.2s}@media (prefers-reduced-motion){.switch__control.sc-swirl-switch{transition:none}}@media (min-width: 992px) and (max-width: 1439px) and (hover: hover),(min-width: 1440px){.switch__control.sc-swirl-switch{width:1.875rem;height:1.125rem;border-radius:calc(1.125rem / 2)}}.switch__thumb.sc-swirl-switch{position:absolute;top:var(--s-space-2);left:var(--s-space-2);width:1.25rem;height:1.25rem;border-radius:50%;background-color:var(--s-surface-default);transition:left 0.2s;pointer-events:none}@media (prefers-reduced-motion){.switch__thumb.sc-swirl-switch{transition:none}}@media (min-width: 992px) and (max-width: 1439px) and (hover: hover),(min-width: 1440px){.switch__thumb.sc-swirl-switch{width:0.875rem;height:0.875rem}}.switch__content.sc-swirl-switch{position:relative;z-index:1;margin-left:var(--s-space-12)}.switch__label.sc-swirl-switch{overflow:hidden;font-size:var(--s-font-size-sm);font-weight:var(--s-font-weight-medium);line-height:var(--s-line-height-base);white-space:nowrap;text-overflow:ellipsis}.switch__description.sc-swirl-switch{color:var(--s-text-subdued);font-size:var(--s-font-size-sm);font-weight:var(--s-font-weight-normal);line-height:var(--s-line-height-sm)}";export{r as swirl_switch}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as c,c as e,h as o,a as i}from"./p-Dz56lJ37.js";import{c as s}from"./p-orsBiyT_.js";const r=class{constructor(o){c(this,o),this.valueChange=e(this,"valueChange",7),this.checked=!1,this.disabled=!1,this.labelWeight="medium",this.variant="default",this.onChange=()=>{this.checked=!0!==this.checked&&"true"!==this.checked,this.valueChange.emit(this.checked)}}getAriaCheckedLabel(c,e){return c?"true":e?"false":"mixed"}render(){const c=!1===this.checked||"false"===this.checked,e=!0===this.checked||"true"===this.checked,r="indeterminate"===this.checked,h=Boolean(this.label)||Boolean(this.description),b=this.getAriaCheckedLabel(e,c),a=!0===this.invalid||!1===this.invalid?String(this.invalid):void 0,t=s("checkbox",`checkbox--label-weight-${this.labelWeight}`,`checkbox--variant-${this.variant}`,{"checkbox--checked":e,"checkbox--disabled":this.disabled,"checkbox--indeterminate":r,"checkbox--invalid":this.invalid,"checkbox--unchecked":c});return o(i,{key:"3ad08c17f03d7e7687feaa98defebc8833733860",style:{width:"card"===this.variant?"100%":void 0}},o("label",{key:"055534364640f13e3f8ac701eab5c02820f174f3",class:t,htmlFor:this.inputId},o("span",{key:"dbefcd0a53167cd632fe98165e7584f3f6217a32",class:"checkbox__control"},o("swirl-visually-hidden",{key:"e52c48576f02f8a768d7e4155c9299013641b2f0"},o("input",{key:"e5b0d971bfddb2cb6f17e7c3be49c983d8059e4e","aria-checked":b,"aria-describedby":this.swirlAriaDescribedby,"aria-invalid":a,"aria-label":this.swirlAriaLabel,checked:e,class:"checkbox__input",disabled:this.disabled,id:this.inputId,indeterminate:r,name:this.inputName,onChange:this.onChange,type:"checkbox",value:this.value})),o("span",{key:"1d426b70b008a23a45a1659c86e80fc58bb4eca9","aria-hidden":"true",class:"checkbox__box"},o("span",{key:"170929e968496483f7ae40fd4d5dd4733308519d",class:"checkbox__icon"},e&&o("swirl-icon-check-strong",{key:"0f2a4937b04485630178a6cd27eb835a869969bc"}),r&&o("span",{key:"ebfc555b5034202d47424e4e56e2143f5156e041",class:"checkbox__indeterminate-icon"})))),h&&o("span",{key:"0bfed4976d10492294bf486c900b99024f22550e",class:"checkbox__label-container"},this.label&&o("span",{key:"aca721f51a214dbdbfc54a769cc37a678c5edfc3",class:"checkbox__label"},this.label),this.description&&o("span",{key:"e5892f2c2e030515627def74cf1dda9cd5b7f1a0",class:"checkbox__description"},this.description))))}};r.style='.sc-swirl-checkbox-h{display:inline-flex}.sc-swirl-checkbox-h *.sc-swirl-checkbox{box-sizing:border-box}.checkbox.sc-swirl-checkbox{display:inline-flex;line-height:var(--s-line-height-base);cursor:pointer;flex-grow:1}.checkbox.sc-swirl-checkbox:focus-within .checkbox__box.sc-swirl-checkbox{box-shadow:0 0 0 0.0625rem var(--s-background-default), 0 0 0 0.1875rem var(--s-focus-default)}.checkbox--variant-card.sc-swirl-checkbox{width:100%;padding:var(--s-space-16);border:0.0625rem solid var(--s-border-default);border-radius:var(--s-border-radius-sm);background-color:var(--s-surface)}.checkbox--variant-card.sc-swirl-checkbox:focus-within{box-shadow:0 0 0 0.125rem var(--s-background-default), 0 0 0 0.25rem var(--s-focus-default)}.checkbox--variant-card.sc-swirl-checkbox:focus-within .checkbox__box.sc-swirl-checkbox{box-shadow:none}.checkbox--variant-card.sc-swirl-checkbox:hover:not(.checkbox--disabled){background-color:var(--s-state-hovered)}.checkbox--variant-card.sc-swirl-checkbox:active:not(.checkbox--disabled){background-color:var(--s-state-pressed)}.checkbox--variant-card.checkbox--checked.sc-swirl-checkbox:not(.checkbox--disabled){border-color:var(--s-border-highlight)}.checkbox--variant-card.checkbox--invalid.sc-swirl-checkbox:not(.checkbox--disabled){border-color:var(--s-border-critical)}.checkbox--checked.sc-swirl-checkbox .checkbox__control.sc-swirl-checkbox:hover .checkbox__box.sc-swirl-checkbox,.checkbox--indeterminate.sc-swirl-checkbox .checkbox__control.sc-swirl-checkbox:hover .checkbox__box.sc-swirl-checkbox{border-color:var(--s-interactive-primary-hovered);background-color:var(--s-interactive-primary-hovered)}.checkbox--checked.sc-swirl-checkbox .checkbox__box.sc-swirl-checkbox,.checkbox--indeterminate.sc-swirl-checkbox .checkbox__box.sc-swirl-checkbox{border-color:var(--s-icon-highlight);color:var(--s-text-on-status);background-color:var(--s-icon-highlight)}.checkbox--invalid.checkbox--checked.sc-swirl-checkbox .checkbox__box.sc-swirl-checkbox,.checkbox--invalid.checkbox--indeterminate.sc-swirl-checkbox .checkbox__box.sc-swirl-checkbox{background-color:var(--s-icon-critical)}.checkbox--invalid.sc-swirl-checkbox .checkbox__box.sc-swirl-checkbox{border-color:var(--s-icon-critical)}.checkbox--disabled.sc-swirl-checkbox{cursor:default}.checkbox--disabled.checkbox--checked.sc-swirl-checkbox .checkbox__control.sc-swirl-checkbox:hover .checkbox__box.sc-swirl-checkbox,.checkbox--disabled.checkbox--indeterminate.sc-swirl-checkbox .checkbox__control.sc-swirl-checkbox:hover .checkbox__box.sc-swirl-checkbox{border-color:var(--s-icon-disabled);background-color:var(--s-icon-disabled)}.checkbox--disabled.checkbox--checked.sc-swirl-checkbox .checkbox__box.sc-swirl-checkbox,.checkbox--disabled.checkbox--indeterminate.sc-swirl-checkbox .checkbox__box.sc-swirl-checkbox{background-color:var(--s-icon-disabled)}.checkbox--disabled.sc-swirl-checkbox .checkbox__control.sc-swirl-checkbox:hover .checkbox__box.sc-swirl-checkbox{background-color:transparent}.checkbox--disabled.sc-swirl-checkbox .checkbox__box.sc-swirl-checkbox{border-color:var(--s-icon-disabled)}.checkbox--disabled.sc-swirl-checkbox .checkbox__label.sc-swirl-checkbox,.checkbox--disabled.sc-swirl-checkbox .checkbox__description.sc-swirl-checkbox{color:var(--s-text-disabled)}.checkbox--label-weight-regular.sc-swirl-checkbox .checkbox__label.sc-swirl-checkbox{font-weight:var(--s-font-weight-regular)}.checkbox__control.sc-swirl-checkbox{position:relative;width:1.5rem;height:1.5rem;padding:var(--s-space-2);flex-shrink:0}.checkbox__control.sc-swirl-checkbox:hover .checkbox__box.sc-swirl-checkbox{background-color:var(--s-action-neutral-hovered)}@media (min-width: 992px) and (max-width: 1439px) and (hover: hover),(min-width: 1440px){.checkbox__control.sc-swirl-checkbox{width:1.375rem;height:1.375rem}}.checkbox__box.sc-swirl-checkbox{position:relative;z-index:1;display:flex;width:100%;height:100%;justify-content:center;align-items:center;border:0.125rem solid var(--s-icon-default);border-radius:var(--s-border-radius-s)}.checkbox__icon.sc-swirl-checkbox{display:inline-flex;width:1.0625rem;height:1.0625rem}.checkbox__icon.sc-swirl-checkbox>*.sc-swirl-checkbox::part(icon),.checkbox__icon.sc-swirl-checkbox>*.sc-swirl-checkbox [part~="icon"]{width:1.0625rem;height:1.0625rem}.checkbox__indeterminate-icon.sc-swirl-checkbox{position:relative;width:100%;height:100%}.checkbox__indeterminate-icon.sc-swirl-checkbox:after{position:absolute;top:50%;left:50%;width:0.625rem;height:0.125rem;border-radius:0.0625rem;background-color:currentColor;content:"";transform:translate3d(-50%, -50%, 0)}.checkbox__label-container.sc-swirl-checkbox{display:inline-flex;margin-left:var(--s-space-8);align-items:flex-start;flex-direction:column}@media (min-width: 992px) and (max-width: 1439px) and (hover: hover),(min-width: 1440px){.checkbox__label-container.sc-swirl-checkbox{padding-top:var(--s-space-2)}}.checkbox__label.sc-swirl-checkbox{font-weight:var(--s-font-weight-medium)}@media (min-width: 992px) and (max-width: 1439px) and (hover: hover),(min-width: 1440px){.checkbox__label.sc-swirl-checkbox{font-size:var(--s-font-size-sm);line-height:var(--s-line-height-sm)}}.checkbox__description.sc-swirl-checkbox{color:var(--s-text-subdued)}@media (min-width: 992px) and (max-width: 1439px) and (hover: hover),(min-width: 1440px){.checkbox__description.sc-swirl-checkbox{font-size:var(--s-font-size-sm);line-height:var(--s-line-height-sm)}}';export{r as swirl_checkbox}
|