@haiilo/catalyst 10.30.0 → 10.30.2

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.
@@ -19,7 +19,7 @@ var patchBrowser = () => {
19
19
 
20
20
  patchBrowser().then(async (options) => {
21
21
  await appGlobals.globalScripts();
22
- return index.bootstrapLazy(JSON.parse("[[\"cat-alert_30.cjs\",[[0,\"cat-select-demo\"],[17,\"cat-date\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"clearable\":[4],\"disabled\":[4],\"hint\":[1],\"icon\":[1],\"iconRight\":[4,\"icon-right\"],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"max\":[1],\"min\":[1],\"name\":[1],\"placeholder\":[1],\"textPrefix\":[1,\"text-prefix\"],\"textSuffix\":[1,\"text-suffix\"],\"readonly\":[4],\"required\":[4],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"placement\":[1],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64]},null,{\"min\":[\"onMinChanged\"],\"max\":[\"onMaxChanged\"]}],[17,\"cat-time\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"clearable\":[4],\"disabled\":[4],\"hint\":[1],\"icon\":[1],\"iconRight\":[4,\"icon-right\"],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"max\":[1],\"min\":[1],\"name\":[1],\"placeholder\":[1],\"textPrefix\":[1,\"text-prefix\"],\"textSuffix\":[1,\"text-suffix\"],\"readonly\":[4],\"required\":[4],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"placement\":[1],\"step\":[2],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"selectionTime\":[32],\"isAm\":[32],\"valueChangedBySelection\":[32],\"select\":[64],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64]},[[0,\"catOpen\",\"onOpen\"]],{\"min\":[\"onMinChanged\"],\"max\":[\"onMaxChanged\"],\"value\":[\"onValueChanged\"]}],[1,\"cat-datepicker\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"clearable\":[4],\"disabled\":[4],\"hint\":[1],\"icon\":[1],\"iconRight\":[4,\"icon-right\"],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"max\":[1],\"min\":[1],\"mode\":[1],\"name\":[1],\"placeholder\":[1],\"textPrefix\":[1,\"text-prefix\"],\"textSuffix\":[1,\"text-suffix\"],\"readonly\":[4],\"required\":[4],\"step\":[2],\"attachToElement\":[4,\"attach-to-element\"],\"position\":[1],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"nativePickerAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"doFocus\":[64],\"doBlur\":[64]},null,{\"value\":[\"onValueChanged\"],\"disabled\":[\"onDisabledChanged\"],\"readonly\":[\"onDisabledChanged\"],\"mode\":[\"onDisabledChanged\"],\"min\":[\"onMinChanged\"],\"max\":[\"onMinChanged\"]}],[17,\"cat-pagination\",{\"page\":[1026],\"pageCount\":[2,\"page-count\"],\"activePadding\":[2,\"active-padding\"],\"sidePadding\":[2,\"side-padding\"],\"size\":[1],\"variant\":[1],\"round\":[4],\"compact\":[4],\"iconPrev\":[1,\"icon-prev\"],\"iconNext\":[1,\"icon-next\"]}],[17,\"cat-tabs\",{\"activeTab\":[1537,\"active-tab\"],\"tabsAlign\":[1,\"tabs-align\"],\"tabs\":[32],\"setActive\":[64],\"setActiveIndex\":[64]},[[0,\"keydown\",\"onKeydown\"]],{\"activeTab\":[\"onActiveTabChange\"]}],[17,\"cat-tag\",{\"requiredMarker\":[1,\"required-marker\"],\"disabled\":[4],\"placeholder\":[1],\"hint\":[1],\"identifier\":[1],\"label\":[1],\"name\":[1],\"labelHidden\":[4,\"label-hidden\"],\"required\":[4],\"nativeAttributes\":[16],\"value\":[1040],\"clearable\":[4],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"tagCreationChars\":[16],\"addOnBlur\":[4,\"add-on-blur\"],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"tags\":[32],\"errorMap\":[32]},[[0,\"keydown\",\"onKeyDown\"]],{\"errors\":[\"onErrorsChanged\"]}],[1,\"cat-alert\",{\"color\":[513],\"icon\":[1],\"noIcon\":[4,\"no-icon\"]}],[1,\"cat-badge\",{\"variant\":[513],\"color\":[513],\"size\":[513],\"round\":[516],\"pulse\":[516],\"icon\":[1],\"iconOnly\":[8,\"icon-only\"],\"iconRight\":[4,\"icon-right\"],\"_iconOnly\":[32]},null,{\"iconOnly\":[\"onIconOnlyChanged\"]}],[17,\"cat-textarea\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"disabled\":[4],\"hint\":[1],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"maxLength\":[2,\"max-length\"],\"minLength\":[2,\"min-length\"],\"name\":[1],\"placeholder\":[1],\"readonly\":[4],\"required\":[4],\"rows\":[2],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"hasSlottedCounter\":[32],\"errorMap\":[32],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64]},null,{\"errors\":[\"onErrorsChanged\"]}],[1,\"cat-button-group\",{\"a11yLabel\":[1,\"a11y-label\"]}],[1,\"cat-card\"],[1,\"cat-datepicker-inline\",{\"disabled\":[4],\"max\":[1],\"min\":[1],\"mode\":[1],\"readonly\":[4],\"step\":[2],\"value\":[1025],\"nativePickerAttributes\":[16]},null,{\"value\":[\"onValueChanged\"],\"disabled\":[\"onDisabledChanged\"],\"readonly\":[\"onDisabledChanged\"]}],[1,\"cat-form-group\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"labelSize\":[1,\"label-size\"]},null,{\"requiredMarker\":[\"onRequiredMarkerChanged\"],\"horizontal\":[\"onHorizontalChanged\"]}],[17,\"cat-radio\",{\"checked\":[1028],\"disabled\":[4],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"name\":[1],\"required\":[4],\"value\":[8],\"hint\":[1],\"labelLeft\":[4,\"label-left\"],\"alignment\":[1],\"nativeAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"doFocus\":[64],\"doBlur\":[64]}],[1,\"cat-radio-group\",{\"name\":[1],\"value\":[1032],\"disabled\":[4],\"a11yLabel\":[1,\"a11y-label\"],\"labelLeft\":[4,\"label-left\"]},[[0,\"keydown\",\"onKeydown\"],[0,\"input\",\"onInput\"],[2,\"focus\",\"onFocus\"],[2,\"blur\",\"onBlur\"]],{\"name\":[\"onNameChanged\"],\"value\":[\"onValueChanged\"],\"disabled\":[\"onDisabledChanged\"],\"labelLeft\":[\"onLabelLeftChanged\"]}],[1,\"cat-tab\",{\"label\":[513],\"icon\":[513],\"iconOnly\":[520,\"icon-only\"],\"iconRight\":[516,\"icon-right\"],\"url\":[513],\"urlTarget\":[513,\"url-target\"],\"deactivated\":[516],\"noActive\":[516,\"no-active\"],\"error\":[516],\"nativeAttributes\":[16]},[[0,\"click\",\"onClick\"]]],[17,\"cat-toggle\",{\"checked\":[1028],\"disabled\":[4],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"name\":[1],\"required\":[4],\"value\":[8],\"noValue\":[8,\"no-value\"],\"resolvedValue\":[1032,\"resolved-value\"],\"hint\":[1],\"labelLeft\":[4,\"label-left\"],\"alignment\":[1],\"nativeAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"doFocus\":[64],\"doBlur\":[64]}],[1,\"cat-tooltip\",{\"content\":[1],\"disabled\":[4],\"placement\":[1],\"round\":[4],\"size\":[1],\"showDelay\":[2,\"show-delay\"],\"hideDelay\":[2,\"hide-delay\"],\"longTouchDuration\":[2,\"long-touch-duration\"],\"open\":[32]},[[8,\"keydown\",\"handleKeyDown\"]]],[17,\"cat-select\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"multiple\":[4],\"debounce\":[2],\"placement\":[1],\"value\":[1025],\"disabled\":[4],\"placeholder\":[1],\"hint\":[1],\"identifier\":[1],\"label\":[1],\"name\":[1],\"labelHidden\":[4,\"label-hidden\"],\"required\":[4],\"clearable\":[4],\"tags\":[4],\"tagHint\":[1,\"tag-hint\"],\"noItems\":[1,\"no-items\"],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"connector\":[32],\"state\":[32],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"errorMap\":[32],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64],\"connect\":[64]},[[0,\"blur\",\"onBlur\"],[0,\"keydown\",\"onKeyDown\"],[0,\"keyup\",\"onKeyUp\"]],{\"connector\":[\"onConnectorChanged\"],\"value\":[\"onValueChanged\"],\"errors\":[\"onErrorsChanged\"],\"state\":[\"onStateChanged\"]}],[17,\"cat-date-inline\",{\"noClear\":[4,\"no-clear\"],\"identifier\":[1],\"hint\":[4],\"noToday\":[4,\"no-today\"],\"weeks\":[4],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"min\":[1],\"max\":[1],\"range\":[4],\"required\":[4],\"a11yLabel\":[1,\"a11y-label\"],\"requiredMarker\":[1,\"required-marker\"],\"value\":[1025],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"viewDate\":[32],\"select\":[64],\"clear\":[64],\"resetView\":[64],\"doFocus\":[64]},[[0,\"keydown\",\"onKeyDown\"]]],[17,\"cat-avatar\",{\"size\":[1],\"round\":[4],\"label\":[1],\"initials\":[1],\"src\":[1],\"icon\":[1],\"url\":[1],\"urlTarget\":[1,\"url-target\"],\"backgroundImage\":[32]},null,{\"src\":[\"onSrcChanged\"]}],[17,\"cat-checkbox\",{\"checked\":[1028],\"indeterminate\":[1028],\"disabled\":[4],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"name\":[1],\"required\":[4],\"value\":[8],\"noValue\":[8,\"no-value\"],\"resolvedValue\":[1032,\"resolved-value\"],\"hint\":[1],\"labelLeft\":[4,\"label-left\"],\"alignment\":[1],\"nativeAttributes\":[16],\"requiredMarker\":[1,\"required-marker\"],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"doFocus\":[64],\"doBlur\":[64]}],[1,\"cat-scrollable\",{\"noShadowX\":[4,\"no-shadow-x\"],\"noShadowY\":[4,\"no-shadow-y\"],\"noOverflowX\":[4,\"no-overflow-x\"],\"noOverflowY\":[4,\"no-overflow-y\"],\"noOverscroll\":[4,\"no-overscroll\"],\"noScrolledInit\":[4,\"no-scrolled-init\"],\"scrolledBuffer\":[2,\"scrolled-buffer\"]}],[1,\"cat-skeleton\",{\"effect\":[1],\"variant\":[1],\"size\":[1],\"lines\":[2]}],[17,\"cat-input\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"clearable\":[4],\"togglePassword\":[4,\"toggle-password\"],\"disabled\":[4],\"loading\":[4],\"hint\":[1],\"icon\":[1],\"iconRight\":[4,\"icon-right\"],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"max\":[8],\"maxLength\":[2,\"max-length\"],\"min\":[8],\"minLength\":[2,\"min-length\"],\"name\":[1],\"placeholder\":[1],\"textPrefix\":[1,\"text-prefix\"],\"textSuffix\":[1,\"text-suffix\"],\"readonly\":[4],\"required\":[4],\"round\":[4],\"type\":[1],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"hasSlottedCounter\":[32],\"isPasswordShown\":[32],\"errorMap\":[32],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64],\"mask\":[64]},null,{\"errors\":[\"onErrorsChanged\"]}],[1,\"cat-dropdown\",{\"placement\":[1],\"noAutoClose\":[4,\"no-auto-close\"],\"arrowNavigation\":[1,\"arrow-navigation\"],\"noResize\":[4,\"no-resize\"],\"overflow\":[4],\"noInitialFocus\":[4,\"no-initial-focus\"],\"noReturnFocus\":[4,\"no-return-focus\"],\"toggle\":[64],\"open\":[64],\"close\":[64]},[[0,\"catClick\",\"clickHandler\"]]],[17,\"cat-button\",{\"variant\":[1],\"color\":[1],\"active\":[4],\"size\":[1],\"name\":[1],\"value\":[1],\"disabled\":[4],\"loading\":[4],\"submit\":[4],\"noEllipsis\":[4,\"no-ellipsis\"],\"round\":[4],\"url\":[1],\"urlTarget\":[1,\"url-target\"],\"icon\":[1],\"iconOnly\":[8,\"icon-only\"],\"iconRight\":[4,\"icon-right\"],\"buttonId\":[1,\"button-id\"],\"a11yLabel\":[1,\"a11y-label\"],\"a11yCurrent\":[1,\"a11y-current\"],\"nativeAttributes\":[16],\"nativeContentAttributes\":[16],\"buttonGroupPosition\":[1,\"button-group-position\"],\"_iconOnly\":[32],\"hasSlottedContent\":[32],\"doFocus\":[64],\"doBlur\":[64],\"doClick\":[64]},[[0,\"click\",\"haltDisabledEvents\"]],{\"iconOnly\":[\"onIconOnlyChanged\"]}],[1,\"cat-spinner\",{\"size\":[1],\"a11yLabel\":[1,\"a11y-label\"],\"value\":[2]}],[1,\"cat-icon\",{\"icon\":[1],\"iconSrc\":[1,\"icon-src\"],\"size\":[1],\"a11yLabel\":[1,\"a11y-label\"]}]]]]"), options);
22
+ return index.bootstrapLazy(JSON.parse("[[\"cat-alert_30.cjs\",[[0,\"cat-select-demo\"],[17,\"cat-date\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"clearable\":[4],\"disabled\":[4],\"hint\":[1],\"icon\":[1],\"iconRight\":[4,\"icon-right\"],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"max\":[1],\"min\":[1],\"name\":[1],\"placeholder\":[1],\"textPrefix\":[1,\"text-prefix\"],\"textSuffix\":[1,\"text-suffix\"],\"readonly\":[4],\"required\":[4],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"placement\":[1],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64]},null,{\"min\":[\"onMinChanged\"],\"max\":[\"onMaxChanged\"]}],[17,\"cat-time\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"clearable\":[4],\"disabled\":[4],\"hint\":[1],\"icon\":[1],\"iconRight\":[4,\"icon-right\"],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"max\":[1],\"min\":[1],\"name\":[1],\"placeholder\":[1],\"textPrefix\":[1,\"text-prefix\"],\"textSuffix\":[1,\"text-suffix\"],\"readonly\":[4],\"required\":[4],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"placement\":[1],\"step\":[2],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"selectionTime\":[32],\"isAm\":[32],\"valueChangedBySelection\":[32],\"select\":[64],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64]},[[0,\"catOpen\",\"onOpen\"]],{\"min\":[\"onMinChanged\"],\"max\":[\"onMaxChanged\"],\"value\":[\"onValueChanged\"]}],[1,\"cat-datepicker\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"clearable\":[4],\"disabled\":[4],\"hint\":[1],\"icon\":[1],\"iconRight\":[4,\"icon-right\"],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"max\":[1],\"min\":[1],\"mode\":[1],\"name\":[1],\"placeholder\":[1],\"textPrefix\":[1,\"text-prefix\"],\"textSuffix\":[1,\"text-suffix\"],\"readonly\":[4],\"required\":[4],\"step\":[2],\"attachToElement\":[4,\"attach-to-element\"],\"position\":[1],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"nativePickerAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"doFocus\":[64],\"doBlur\":[64]},null,{\"value\":[\"onValueChanged\"],\"disabled\":[\"onDisabledChanged\"],\"readonly\":[\"onDisabledChanged\"],\"mode\":[\"onDisabledChanged\"],\"min\":[\"onMinChanged\"],\"max\":[\"onMinChanged\"]}],[17,\"cat-pagination\",{\"page\":[1026],\"pageCount\":[2,\"page-count\"],\"activePadding\":[2,\"active-padding\"],\"sidePadding\":[2,\"side-padding\"],\"size\":[1],\"variant\":[1],\"round\":[4],\"compact\":[4],\"iconPrev\":[1,\"icon-prev\"],\"iconNext\":[1,\"icon-next\"]}],[17,\"cat-tabs\",{\"activeTab\":[1537,\"active-tab\"],\"tabsAlign\":[1,\"tabs-align\"],\"tabs\":[32],\"setActive\":[64],\"setActiveIndex\":[64]},[[0,\"keydown\",\"onKeydown\"]],{\"activeTab\":[\"onActiveTabChange\"]}],[17,\"cat-tag\",{\"requiredMarker\":[1,\"required-marker\"],\"disabled\":[4],\"placeholder\":[1],\"hint\":[1],\"identifier\":[1],\"label\":[1],\"name\":[1],\"labelHidden\":[4,\"label-hidden\"],\"required\":[4],\"nativeAttributes\":[16],\"value\":[1040],\"clearable\":[4],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"tagCreationChars\":[16],\"addOnBlur\":[4,\"add-on-blur\"],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"tags\":[32],\"errorMap\":[32]},[[0,\"keydown\",\"onKeyDown\"]],{\"errors\":[\"onErrorsChanged\"]}],[1,\"cat-alert\",{\"color\":[513],\"icon\":[1],\"noIcon\":[4,\"no-icon\"]}],[1,\"cat-badge\",{\"variant\":[513],\"color\":[513],\"size\":[513],\"round\":[516],\"pulse\":[516],\"icon\":[1],\"iconOnly\":[8,\"icon-only\"],\"iconRight\":[4,\"icon-right\"],\"_iconOnly\":[32]},null,{\"iconOnly\":[\"onIconOnlyChanged\"]}],[17,\"cat-textarea\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"disabled\":[4],\"hint\":[1],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"maxLength\":[2,\"max-length\"],\"minLength\":[2,\"min-length\"],\"name\":[1],\"placeholder\":[1],\"readonly\":[4],\"required\":[4],\"rows\":[2],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"hasSlottedCounter\":[32],\"errorMap\":[32],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64]},null,{\"errors\":[\"onErrorsChanged\"]}],[1,\"cat-button-group\",{\"a11yLabel\":[1,\"a11y-label\"]}],[1,\"cat-card\"],[1,\"cat-datepicker-inline\",{\"disabled\":[4],\"max\":[1],\"min\":[1],\"mode\":[1],\"readonly\":[4],\"step\":[2],\"value\":[1025],\"nativePickerAttributes\":[16]},null,{\"value\":[\"onValueChanged\"],\"disabled\":[\"onDisabledChanged\"],\"readonly\":[\"onDisabledChanged\"]}],[1,\"cat-form-group\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"labelSize\":[1,\"label-size\"]},null,{\"requiredMarker\":[\"onRequiredMarkerChanged\"],\"horizontal\":[\"onHorizontalChanged\"]}],[17,\"cat-radio\",{\"checked\":[1028],\"disabled\":[4],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"name\":[1],\"required\":[4],\"value\":[8],\"hint\":[1],\"labelLeft\":[4,\"label-left\"],\"alignment\":[1],\"nativeAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"doFocus\":[64],\"doBlur\":[64]}],[1,\"cat-radio-group\",{\"name\":[1],\"value\":[1032],\"disabled\":[4],\"a11yLabel\":[1,\"a11y-label\"],\"labelLeft\":[4,\"label-left\"]},[[0,\"keydown\",\"onKeydown\"],[0,\"input\",\"onInput\"],[2,\"focus\",\"onFocus\"],[2,\"blur\",\"onBlur\"]],{\"name\":[\"onNameChanged\"],\"value\":[\"onValueChanged\"],\"disabled\":[\"onDisabledChanged\"],\"labelLeft\":[\"onLabelLeftChanged\"]}],[1,\"cat-tab\",{\"label\":[513],\"icon\":[513],\"iconOnly\":[520,\"icon-only\"],\"iconRight\":[516,\"icon-right\"],\"url\":[513],\"urlTarget\":[513,\"url-target\"],\"deactivated\":[516],\"noActive\":[516,\"no-active\"],\"error\":[516],\"nativeAttributes\":[16]},[[0,\"click\",\"onClick\"]]],[17,\"cat-toggle\",{\"checked\":[1028],\"disabled\":[4],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"name\":[1],\"required\":[4],\"value\":[8],\"noValue\":[8,\"no-value\"],\"resolvedValue\":[1032,\"resolved-value\"],\"hint\":[1],\"labelLeft\":[4,\"label-left\"],\"alignment\":[1],\"nativeAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"doFocus\":[64],\"doBlur\":[64]}],[1,\"cat-tooltip\",{\"content\":[1],\"disabled\":[4],\"placement\":[1],\"round\":[4],\"size\":[1],\"showDelay\":[2,\"show-delay\"],\"hideDelay\":[2,\"hide-delay\"],\"longTouchDuration\":[2,\"long-touch-duration\"],\"open\":[32]},[[8,\"keydown\",\"handleKeyDown\"]]],[17,\"cat-select\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"multiple\":[4],\"debounce\":[2],\"placement\":[1],\"value\":[1025],\"disabled\":[4],\"placeholder\":[1],\"hint\":[1],\"identifier\":[1],\"label\":[1],\"name\":[1],\"labelHidden\":[4,\"label-hidden\"],\"required\":[4],\"clearable\":[4],\"tags\":[4],\"tagHint\":[1,\"tag-hint\"],\"noItems\":[1,\"no-items\"],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"connector\":[32],\"state\":[32],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"errorMap\":[32],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64],\"connect\":[64]},[[0,\"blur\",\"onBlur\"],[0,\"keydown\",\"onKeyDown\"],[0,\"keyup\",\"onKeyUp\"]],{\"connector\":[\"onConnectorChanged\"],\"value\":[\"onValueChanged\"],\"errors\":[\"onErrorsChanged\"],\"state\":[\"onStateChanged\"]}],[17,\"cat-date-inline\",{\"noClear\":[4,\"no-clear\"],\"identifier\":[1],\"hint\":[4],\"noToday\":[4,\"no-today\"],\"weeks\":[4],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"min\":[1],\"max\":[1],\"range\":[4],\"required\":[4],\"a11yLabel\":[1,\"a11y-label\"],\"requiredMarker\":[1,\"required-marker\"],\"value\":[1025],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"viewDate\":[32],\"select\":[64],\"clear\":[64],\"resetView\":[64],\"doFocus\":[64]},[[0,\"keydown\",\"onKeyDown\"]]],[17,\"cat-avatar\",{\"size\":[1],\"round\":[4],\"label\":[1],\"initials\":[1],\"src\":[1],\"icon\":[1],\"url\":[1],\"urlTarget\":[1,\"url-target\"],\"backgroundImage\":[32]},null,{\"src\":[\"onSrcChanged\"]}],[1,\"cat-checkbox\",{\"checked\":[1028],\"indeterminate\":[1028],\"disabled\":[4],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"name\":[1],\"required\":[4],\"value\":[8],\"noValue\":[8,\"no-value\"],\"resolvedValue\":[1032,\"resolved-value\"],\"hint\":[1],\"labelLeft\":[4,\"label-left\"],\"alignment\":[1],\"nativeAttributes\":[16],\"requiredMarker\":[1,\"required-marker\"],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"doFocus\":[64],\"doBlur\":[64]}],[1,\"cat-scrollable\",{\"noShadowX\":[4,\"no-shadow-x\"],\"noShadowY\":[4,\"no-shadow-y\"],\"noOverflowX\":[4,\"no-overflow-x\"],\"noOverflowY\":[4,\"no-overflow-y\"],\"noOverscroll\":[4,\"no-overscroll\"],\"noScrolledInit\":[4,\"no-scrolled-init\"],\"scrolledBuffer\":[2,\"scrolled-buffer\"]}],[1,\"cat-skeleton\",{\"effect\":[1],\"variant\":[1],\"size\":[1],\"lines\":[2]}],[17,\"cat-input\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"clearable\":[4],\"togglePassword\":[4,\"toggle-password\"],\"disabled\":[4],\"loading\":[4],\"hint\":[1],\"icon\":[1],\"iconRight\":[4,\"icon-right\"],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"max\":[8],\"maxLength\":[2,\"max-length\"],\"min\":[8],\"minLength\":[2,\"min-length\"],\"name\":[1],\"placeholder\":[1],\"textPrefix\":[1,\"text-prefix\"],\"textSuffix\":[1,\"text-suffix\"],\"readonly\":[4],\"required\":[4],\"round\":[4],\"type\":[1],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"hasSlottedCounter\":[32],\"isPasswordShown\":[32],\"errorMap\":[32],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64],\"mask\":[64]},null,{\"errors\":[\"onErrorsChanged\"]}],[1,\"cat-dropdown\",{\"placement\":[1],\"noAutoClose\":[4,\"no-auto-close\"],\"arrowNavigation\":[1,\"arrow-navigation\"],\"noResize\":[4,\"no-resize\"],\"overflow\":[4],\"noInitialFocus\":[4,\"no-initial-focus\"],\"noReturnFocus\":[4,\"no-return-focus\"],\"toggle\":[64],\"open\":[64],\"close\":[64]},[[0,\"catClick\",\"clickHandler\"]]],[17,\"cat-button\",{\"variant\":[1],\"color\":[1],\"active\":[4],\"size\":[1],\"name\":[1],\"value\":[1],\"disabled\":[4],\"loading\":[4],\"submit\":[4],\"noEllipsis\":[4,\"no-ellipsis\"],\"round\":[4],\"url\":[1],\"urlTarget\":[1,\"url-target\"],\"icon\":[1],\"iconOnly\":[8,\"icon-only\"],\"iconRight\":[4,\"icon-right\"],\"buttonId\":[1,\"button-id\"],\"a11yLabel\":[1,\"a11y-label\"],\"a11yCurrent\":[1,\"a11y-current\"],\"nativeAttributes\":[16],\"nativeContentAttributes\":[16],\"buttonGroupPosition\":[1,\"button-group-position\"],\"_iconOnly\":[32],\"hasSlottedContent\":[32],\"doFocus\":[64],\"doBlur\":[64],\"doClick\":[64]},[[0,\"click\",\"haltDisabledEvents\"]],{\"iconOnly\":[\"onIconOnlyChanged\"]}],[1,\"cat-spinner\",{\"size\":[1],\"a11yLabel\":[1,\"a11y-label\"],\"value\":[2]}],[1,\"cat-icon\",{\"icon\":[1],\"iconSrc\":[1,\"icon-src\"],\"size\":[1],\"a11yLabel\":[1,\"a11y-label\"]}]]]]"), options);
23
23
  });
24
24
 
25
25
  exports.setNonce = index.setNonce;
@@ -8,7 +8,7 @@ const appGlobals = require('./app-globals-3a1e7e63.js');
8
8
  const defineCustomElements = async (win, options) => {
9
9
  if (typeof window === 'undefined') return undefined;
10
10
  await appGlobals.globalScripts();
11
- return index.bootstrapLazy(JSON.parse("[[\"cat-alert_30.cjs\",[[0,\"cat-select-demo\"],[17,\"cat-date\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"clearable\":[4],\"disabled\":[4],\"hint\":[1],\"icon\":[1],\"iconRight\":[4,\"icon-right\"],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"max\":[1],\"min\":[1],\"name\":[1],\"placeholder\":[1],\"textPrefix\":[1,\"text-prefix\"],\"textSuffix\":[1,\"text-suffix\"],\"readonly\":[4],\"required\":[4],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"placement\":[1],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64]},null,{\"min\":[\"onMinChanged\"],\"max\":[\"onMaxChanged\"]}],[17,\"cat-time\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"clearable\":[4],\"disabled\":[4],\"hint\":[1],\"icon\":[1],\"iconRight\":[4,\"icon-right\"],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"max\":[1],\"min\":[1],\"name\":[1],\"placeholder\":[1],\"textPrefix\":[1,\"text-prefix\"],\"textSuffix\":[1,\"text-suffix\"],\"readonly\":[4],\"required\":[4],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"placement\":[1],\"step\":[2],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"selectionTime\":[32],\"isAm\":[32],\"valueChangedBySelection\":[32],\"select\":[64],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64]},[[0,\"catOpen\",\"onOpen\"]],{\"min\":[\"onMinChanged\"],\"max\":[\"onMaxChanged\"],\"value\":[\"onValueChanged\"]}],[1,\"cat-datepicker\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"clearable\":[4],\"disabled\":[4],\"hint\":[1],\"icon\":[1],\"iconRight\":[4,\"icon-right\"],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"max\":[1],\"min\":[1],\"mode\":[1],\"name\":[1],\"placeholder\":[1],\"textPrefix\":[1,\"text-prefix\"],\"textSuffix\":[1,\"text-suffix\"],\"readonly\":[4],\"required\":[4],\"step\":[2],\"attachToElement\":[4,\"attach-to-element\"],\"position\":[1],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"nativePickerAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"doFocus\":[64],\"doBlur\":[64]},null,{\"value\":[\"onValueChanged\"],\"disabled\":[\"onDisabledChanged\"],\"readonly\":[\"onDisabledChanged\"],\"mode\":[\"onDisabledChanged\"],\"min\":[\"onMinChanged\"],\"max\":[\"onMinChanged\"]}],[17,\"cat-pagination\",{\"page\":[1026],\"pageCount\":[2,\"page-count\"],\"activePadding\":[2,\"active-padding\"],\"sidePadding\":[2,\"side-padding\"],\"size\":[1],\"variant\":[1],\"round\":[4],\"compact\":[4],\"iconPrev\":[1,\"icon-prev\"],\"iconNext\":[1,\"icon-next\"]}],[17,\"cat-tabs\",{\"activeTab\":[1537,\"active-tab\"],\"tabsAlign\":[1,\"tabs-align\"],\"tabs\":[32],\"setActive\":[64],\"setActiveIndex\":[64]},[[0,\"keydown\",\"onKeydown\"]],{\"activeTab\":[\"onActiveTabChange\"]}],[17,\"cat-tag\",{\"requiredMarker\":[1,\"required-marker\"],\"disabled\":[4],\"placeholder\":[1],\"hint\":[1],\"identifier\":[1],\"label\":[1],\"name\":[1],\"labelHidden\":[4,\"label-hidden\"],\"required\":[4],\"nativeAttributes\":[16],\"value\":[1040],\"clearable\":[4],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"tagCreationChars\":[16],\"addOnBlur\":[4,\"add-on-blur\"],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"tags\":[32],\"errorMap\":[32]},[[0,\"keydown\",\"onKeyDown\"]],{\"errors\":[\"onErrorsChanged\"]}],[1,\"cat-alert\",{\"color\":[513],\"icon\":[1],\"noIcon\":[4,\"no-icon\"]}],[1,\"cat-badge\",{\"variant\":[513],\"color\":[513],\"size\":[513],\"round\":[516],\"pulse\":[516],\"icon\":[1],\"iconOnly\":[8,\"icon-only\"],\"iconRight\":[4,\"icon-right\"],\"_iconOnly\":[32]},null,{\"iconOnly\":[\"onIconOnlyChanged\"]}],[17,\"cat-textarea\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"disabled\":[4],\"hint\":[1],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"maxLength\":[2,\"max-length\"],\"minLength\":[2,\"min-length\"],\"name\":[1],\"placeholder\":[1],\"readonly\":[4],\"required\":[4],\"rows\":[2],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"hasSlottedCounter\":[32],\"errorMap\":[32],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64]},null,{\"errors\":[\"onErrorsChanged\"]}],[1,\"cat-button-group\",{\"a11yLabel\":[1,\"a11y-label\"]}],[1,\"cat-card\"],[1,\"cat-datepicker-inline\",{\"disabled\":[4],\"max\":[1],\"min\":[1],\"mode\":[1],\"readonly\":[4],\"step\":[2],\"value\":[1025],\"nativePickerAttributes\":[16]},null,{\"value\":[\"onValueChanged\"],\"disabled\":[\"onDisabledChanged\"],\"readonly\":[\"onDisabledChanged\"]}],[1,\"cat-form-group\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"labelSize\":[1,\"label-size\"]},null,{\"requiredMarker\":[\"onRequiredMarkerChanged\"],\"horizontal\":[\"onHorizontalChanged\"]}],[17,\"cat-radio\",{\"checked\":[1028],\"disabled\":[4],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"name\":[1],\"required\":[4],\"value\":[8],\"hint\":[1],\"labelLeft\":[4,\"label-left\"],\"alignment\":[1],\"nativeAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"doFocus\":[64],\"doBlur\":[64]}],[1,\"cat-radio-group\",{\"name\":[1],\"value\":[1032],\"disabled\":[4],\"a11yLabel\":[1,\"a11y-label\"],\"labelLeft\":[4,\"label-left\"]},[[0,\"keydown\",\"onKeydown\"],[0,\"input\",\"onInput\"],[2,\"focus\",\"onFocus\"],[2,\"blur\",\"onBlur\"]],{\"name\":[\"onNameChanged\"],\"value\":[\"onValueChanged\"],\"disabled\":[\"onDisabledChanged\"],\"labelLeft\":[\"onLabelLeftChanged\"]}],[1,\"cat-tab\",{\"label\":[513],\"icon\":[513],\"iconOnly\":[520,\"icon-only\"],\"iconRight\":[516,\"icon-right\"],\"url\":[513],\"urlTarget\":[513,\"url-target\"],\"deactivated\":[516],\"noActive\":[516,\"no-active\"],\"error\":[516],\"nativeAttributes\":[16]},[[0,\"click\",\"onClick\"]]],[17,\"cat-toggle\",{\"checked\":[1028],\"disabled\":[4],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"name\":[1],\"required\":[4],\"value\":[8],\"noValue\":[8,\"no-value\"],\"resolvedValue\":[1032,\"resolved-value\"],\"hint\":[1],\"labelLeft\":[4,\"label-left\"],\"alignment\":[1],\"nativeAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"doFocus\":[64],\"doBlur\":[64]}],[1,\"cat-tooltip\",{\"content\":[1],\"disabled\":[4],\"placement\":[1],\"round\":[4],\"size\":[1],\"showDelay\":[2,\"show-delay\"],\"hideDelay\":[2,\"hide-delay\"],\"longTouchDuration\":[2,\"long-touch-duration\"],\"open\":[32]},[[8,\"keydown\",\"handleKeyDown\"]]],[17,\"cat-select\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"multiple\":[4],\"debounce\":[2],\"placement\":[1],\"value\":[1025],\"disabled\":[4],\"placeholder\":[1],\"hint\":[1],\"identifier\":[1],\"label\":[1],\"name\":[1],\"labelHidden\":[4,\"label-hidden\"],\"required\":[4],\"clearable\":[4],\"tags\":[4],\"tagHint\":[1,\"tag-hint\"],\"noItems\":[1,\"no-items\"],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"connector\":[32],\"state\":[32],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"errorMap\":[32],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64],\"connect\":[64]},[[0,\"blur\",\"onBlur\"],[0,\"keydown\",\"onKeyDown\"],[0,\"keyup\",\"onKeyUp\"]],{\"connector\":[\"onConnectorChanged\"],\"value\":[\"onValueChanged\"],\"errors\":[\"onErrorsChanged\"],\"state\":[\"onStateChanged\"]}],[17,\"cat-date-inline\",{\"noClear\":[4,\"no-clear\"],\"identifier\":[1],\"hint\":[4],\"noToday\":[4,\"no-today\"],\"weeks\":[4],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"min\":[1],\"max\":[1],\"range\":[4],\"required\":[4],\"a11yLabel\":[1,\"a11y-label\"],\"requiredMarker\":[1,\"required-marker\"],\"value\":[1025],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"viewDate\":[32],\"select\":[64],\"clear\":[64],\"resetView\":[64],\"doFocus\":[64]},[[0,\"keydown\",\"onKeyDown\"]]],[17,\"cat-avatar\",{\"size\":[1],\"round\":[4],\"label\":[1],\"initials\":[1],\"src\":[1],\"icon\":[1],\"url\":[1],\"urlTarget\":[1,\"url-target\"],\"backgroundImage\":[32]},null,{\"src\":[\"onSrcChanged\"]}],[17,\"cat-checkbox\",{\"checked\":[1028],\"indeterminate\":[1028],\"disabled\":[4],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"name\":[1],\"required\":[4],\"value\":[8],\"noValue\":[8,\"no-value\"],\"resolvedValue\":[1032,\"resolved-value\"],\"hint\":[1],\"labelLeft\":[4,\"label-left\"],\"alignment\":[1],\"nativeAttributes\":[16],\"requiredMarker\":[1,\"required-marker\"],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"doFocus\":[64],\"doBlur\":[64]}],[1,\"cat-scrollable\",{\"noShadowX\":[4,\"no-shadow-x\"],\"noShadowY\":[4,\"no-shadow-y\"],\"noOverflowX\":[4,\"no-overflow-x\"],\"noOverflowY\":[4,\"no-overflow-y\"],\"noOverscroll\":[4,\"no-overscroll\"],\"noScrolledInit\":[4,\"no-scrolled-init\"],\"scrolledBuffer\":[2,\"scrolled-buffer\"]}],[1,\"cat-skeleton\",{\"effect\":[1],\"variant\":[1],\"size\":[1],\"lines\":[2]}],[17,\"cat-input\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"clearable\":[4],\"togglePassword\":[4,\"toggle-password\"],\"disabled\":[4],\"loading\":[4],\"hint\":[1],\"icon\":[1],\"iconRight\":[4,\"icon-right\"],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"max\":[8],\"maxLength\":[2,\"max-length\"],\"min\":[8],\"minLength\":[2,\"min-length\"],\"name\":[1],\"placeholder\":[1],\"textPrefix\":[1,\"text-prefix\"],\"textSuffix\":[1,\"text-suffix\"],\"readonly\":[4],\"required\":[4],\"round\":[4],\"type\":[1],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"hasSlottedCounter\":[32],\"isPasswordShown\":[32],\"errorMap\":[32],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64],\"mask\":[64]},null,{\"errors\":[\"onErrorsChanged\"]}],[1,\"cat-dropdown\",{\"placement\":[1],\"noAutoClose\":[4,\"no-auto-close\"],\"arrowNavigation\":[1,\"arrow-navigation\"],\"noResize\":[4,\"no-resize\"],\"overflow\":[4],\"noInitialFocus\":[4,\"no-initial-focus\"],\"noReturnFocus\":[4,\"no-return-focus\"],\"toggle\":[64],\"open\":[64],\"close\":[64]},[[0,\"catClick\",\"clickHandler\"]]],[17,\"cat-button\",{\"variant\":[1],\"color\":[1],\"active\":[4],\"size\":[1],\"name\":[1],\"value\":[1],\"disabled\":[4],\"loading\":[4],\"submit\":[4],\"noEllipsis\":[4,\"no-ellipsis\"],\"round\":[4],\"url\":[1],\"urlTarget\":[1,\"url-target\"],\"icon\":[1],\"iconOnly\":[8,\"icon-only\"],\"iconRight\":[4,\"icon-right\"],\"buttonId\":[1,\"button-id\"],\"a11yLabel\":[1,\"a11y-label\"],\"a11yCurrent\":[1,\"a11y-current\"],\"nativeAttributes\":[16],\"nativeContentAttributes\":[16],\"buttonGroupPosition\":[1,\"button-group-position\"],\"_iconOnly\":[32],\"hasSlottedContent\":[32],\"doFocus\":[64],\"doBlur\":[64],\"doClick\":[64]},[[0,\"click\",\"haltDisabledEvents\"]],{\"iconOnly\":[\"onIconOnlyChanged\"]}],[1,\"cat-spinner\",{\"size\":[1],\"a11yLabel\":[1,\"a11y-label\"],\"value\":[2]}],[1,\"cat-icon\",{\"icon\":[1],\"iconSrc\":[1,\"icon-src\"],\"size\":[1],\"a11yLabel\":[1,\"a11y-label\"]}]]]]"), options);
11
+ return index.bootstrapLazy(JSON.parse("[[\"cat-alert_30.cjs\",[[0,\"cat-select-demo\"],[17,\"cat-date\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"clearable\":[4],\"disabled\":[4],\"hint\":[1],\"icon\":[1],\"iconRight\":[4,\"icon-right\"],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"max\":[1],\"min\":[1],\"name\":[1],\"placeholder\":[1],\"textPrefix\":[1,\"text-prefix\"],\"textSuffix\":[1,\"text-suffix\"],\"readonly\":[4],\"required\":[4],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"placement\":[1],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64]},null,{\"min\":[\"onMinChanged\"],\"max\":[\"onMaxChanged\"]}],[17,\"cat-time\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"clearable\":[4],\"disabled\":[4],\"hint\":[1],\"icon\":[1],\"iconRight\":[4,\"icon-right\"],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"max\":[1],\"min\":[1],\"name\":[1],\"placeholder\":[1],\"textPrefix\":[1,\"text-prefix\"],\"textSuffix\":[1,\"text-suffix\"],\"readonly\":[4],\"required\":[4],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"placement\":[1],\"step\":[2],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"selectionTime\":[32],\"isAm\":[32],\"valueChangedBySelection\":[32],\"select\":[64],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64]},[[0,\"catOpen\",\"onOpen\"]],{\"min\":[\"onMinChanged\"],\"max\":[\"onMaxChanged\"],\"value\":[\"onValueChanged\"]}],[1,\"cat-datepicker\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"clearable\":[4],\"disabled\":[4],\"hint\":[1],\"icon\":[1],\"iconRight\":[4,\"icon-right\"],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"max\":[1],\"min\":[1],\"mode\":[1],\"name\":[1],\"placeholder\":[1],\"textPrefix\":[1,\"text-prefix\"],\"textSuffix\":[1,\"text-suffix\"],\"readonly\":[4],\"required\":[4],\"step\":[2],\"attachToElement\":[4,\"attach-to-element\"],\"position\":[1],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"nativePickerAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"doFocus\":[64],\"doBlur\":[64]},null,{\"value\":[\"onValueChanged\"],\"disabled\":[\"onDisabledChanged\"],\"readonly\":[\"onDisabledChanged\"],\"mode\":[\"onDisabledChanged\"],\"min\":[\"onMinChanged\"],\"max\":[\"onMinChanged\"]}],[17,\"cat-pagination\",{\"page\":[1026],\"pageCount\":[2,\"page-count\"],\"activePadding\":[2,\"active-padding\"],\"sidePadding\":[2,\"side-padding\"],\"size\":[1],\"variant\":[1],\"round\":[4],\"compact\":[4],\"iconPrev\":[1,\"icon-prev\"],\"iconNext\":[1,\"icon-next\"]}],[17,\"cat-tabs\",{\"activeTab\":[1537,\"active-tab\"],\"tabsAlign\":[1,\"tabs-align\"],\"tabs\":[32],\"setActive\":[64],\"setActiveIndex\":[64]},[[0,\"keydown\",\"onKeydown\"]],{\"activeTab\":[\"onActiveTabChange\"]}],[17,\"cat-tag\",{\"requiredMarker\":[1,\"required-marker\"],\"disabled\":[4],\"placeholder\":[1],\"hint\":[1],\"identifier\":[1],\"label\":[1],\"name\":[1],\"labelHidden\":[4,\"label-hidden\"],\"required\":[4],\"nativeAttributes\":[16],\"value\":[1040],\"clearable\":[4],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"tagCreationChars\":[16],\"addOnBlur\":[4,\"add-on-blur\"],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"tags\":[32],\"errorMap\":[32]},[[0,\"keydown\",\"onKeyDown\"]],{\"errors\":[\"onErrorsChanged\"]}],[1,\"cat-alert\",{\"color\":[513],\"icon\":[1],\"noIcon\":[4,\"no-icon\"]}],[1,\"cat-badge\",{\"variant\":[513],\"color\":[513],\"size\":[513],\"round\":[516],\"pulse\":[516],\"icon\":[1],\"iconOnly\":[8,\"icon-only\"],\"iconRight\":[4,\"icon-right\"],\"_iconOnly\":[32]},null,{\"iconOnly\":[\"onIconOnlyChanged\"]}],[17,\"cat-textarea\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"disabled\":[4],\"hint\":[1],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"maxLength\":[2,\"max-length\"],\"minLength\":[2,\"min-length\"],\"name\":[1],\"placeholder\":[1],\"readonly\":[4],\"required\":[4],\"rows\":[2],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"hasSlottedCounter\":[32],\"errorMap\":[32],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64]},null,{\"errors\":[\"onErrorsChanged\"]}],[1,\"cat-button-group\",{\"a11yLabel\":[1,\"a11y-label\"]}],[1,\"cat-card\"],[1,\"cat-datepicker-inline\",{\"disabled\":[4],\"max\":[1],\"min\":[1],\"mode\":[1],\"readonly\":[4],\"step\":[2],\"value\":[1025],\"nativePickerAttributes\":[16]},null,{\"value\":[\"onValueChanged\"],\"disabled\":[\"onDisabledChanged\"],\"readonly\":[\"onDisabledChanged\"]}],[1,\"cat-form-group\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"labelSize\":[1,\"label-size\"]},null,{\"requiredMarker\":[\"onRequiredMarkerChanged\"],\"horizontal\":[\"onHorizontalChanged\"]}],[17,\"cat-radio\",{\"checked\":[1028],\"disabled\":[4],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"name\":[1],\"required\":[4],\"value\":[8],\"hint\":[1],\"labelLeft\":[4,\"label-left\"],\"alignment\":[1],\"nativeAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"doFocus\":[64],\"doBlur\":[64]}],[1,\"cat-radio-group\",{\"name\":[1],\"value\":[1032],\"disabled\":[4],\"a11yLabel\":[1,\"a11y-label\"],\"labelLeft\":[4,\"label-left\"]},[[0,\"keydown\",\"onKeydown\"],[0,\"input\",\"onInput\"],[2,\"focus\",\"onFocus\"],[2,\"blur\",\"onBlur\"]],{\"name\":[\"onNameChanged\"],\"value\":[\"onValueChanged\"],\"disabled\":[\"onDisabledChanged\"],\"labelLeft\":[\"onLabelLeftChanged\"]}],[1,\"cat-tab\",{\"label\":[513],\"icon\":[513],\"iconOnly\":[520,\"icon-only\"],\"iconRight\":[516,\"icon-right\"],\"url\":[513],\"urlTarget\":[513,\"url-target\"],\"deactivated\":[516],\"noActive\":[516,\"no-active\"],\"error\":[516],\"nativeAttributes\":[16]},[[0,\"click\",\"onClick\"]]],[17,\"cat-toggle\",{\"checked\":[1028],\"disabled\":[4],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"name\":[1],\"required\":[4],\"value\":[8],\"noValue\":[8,\"no-value\"],\"resolvedValue\":[1032,\"resolved-value\"],\"hint\":[1],\"labelLeft\":[4,\"label-left\"],\"alignment\":[1],\"nativeAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"doFocus\":[64],\"doBlur\":[64]}],[1,\"cat-tooltip\",{\"content\":[1],\"disabled\":[4],\"placement\":[1],\"round\":[4],\"size\":[1],\"showDelay\":[2,\"show-delay\"],\"hideDelay\":[2,\"hide-delay\"],\"longTouchDuration\":[2,\"long-touch-duration\"],\"open\":[32]},[[8,\"keydown\",\"handleKeyDown\"]]],[17,\"cat-select\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"multiple\":[4],\"debounce\":[2],\"placement\":[1],\"value\":[1025],\"disabled\":[4],\"placeholder\":[1],\"hint\":[1],\"identifier\":[1],\"label\":[1],\"name\":[1],\"labelHidden\":[4,\"label-hidden\"],\"required\":[4],\"clearable\":[4],\"tags\":[4],\"tagHint\":[1,\"tag-hint\"],\"noItems\":[1,\"no-items\"],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"connector\":[32],\"state\":[32],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"errorMap\":[32],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64],\"connect\":[64]},[[0,\"blur\",\"onBlur\"],[0,\"keydown\",\"onKeyDown\"],[0,\"keyup\",\"onKeyUp\"]],{\"connector\":[\"onConnectorChanged\"],\"value\":[\"onValueChanged\"],\"errors\":[\"onErrorsChanged\"],\"state\":[\"onStateChanged\"]}],[17,\"cat-date-inline\",{\"noClear\":[4,\"no-clear\"],\"identifier\":[1],\"hint\":[4],\"noToday\":[4,\"no-today\"],\"weeks\":[4],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"min\":[1],\"max\":[1],\"range\":[4],\"required\":[4],\"a11yLabel\":[1,\"a11y-label\"],\"requiredMarker\":[1,\"required-marker\"],\"value\":[1025],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"viewDate\":[32],\"select\":[64],\"clear\":[64],\"resetView\":[64],\"doFocus\":[64]},[[0,\"keydown\",\"onKeyDown\"]]],[17,\"cat-avatar\",{\"size\":[1],\"round\":[4],\"label\":[1],\"initials\":[1],\"src\":[1],\"icon\":[1],\"url\":[1],\"urlTarget\":[1,\"url-target\"],\"backgroundImage\":[32]},null,{\"src\":[\"onSrcChanged\"]}],[1,\"cat-checkbox\",{\"checked\":[1028],\"indeterminate\":[1028],\"disabled\":[4],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"name\":[1],\"required\":[4],\"value\":[8],\"noValue\":[8,\"no-value\"],\"resolvedValue\":[1032,\"resolved-value\"],\"hint\":[1],\"labelLeft\":[4,\"label-left\"],\"alignment\":[1],\"nativeAttributes\":[16],\"requiredMarker\":[1,\"required-marker\"],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"doFocus\":[64],\"doBlur\":[64]}],[1,\"cat-scrollable\",{\"noShadowX\":[4,\"no-shadow-x\"],\"noShadowY\":[4,\"no-shadow-y\"],\"noOverflowX\":[4,\"no-overflow-x\"],\"noOverflowY\":[4,\"no-overflow-y\"],\"noOverscroll\":[4,\"no-overscroll\"],\"noScrolledInit\":[4,\"no-scrolled-init\"],\"scrolledBuffer\":[2,\"scrolled-buffer\"]}],[1,\"cat-skeleton\",{\"effect\":[1],\"variant\":[1],\"size\":[1],\"lines\":[2]}],[17,\"cat-input\",{\"requiredMarker\":[1,\"required-marker\"],\"horizontal\":[4],\"autoComplete\":[1,\"auto-complete\"],\"clearable\":[4],\"togglePassword\":[4,\"toggle-password\"],\"disabled\":[4],\"loading\":[4],\"hint\":[1],\"icon\":[1],\"iconRight\":[4,\"icon-right\"],\"identifier\":[1],\"label\":[1],\"labelHidden\":[4,\"label-hidden\"],\"max\":[8],\"maxLength\":[2,\"max-length\"],\"min\":[8],\"minLength\":[2,\"min-length\"],\"name\":[1],\"placeholder\":[1],\"textPrefix\":[1,\"text-prefix\"],\"textSuffix\":[1,\"text-suffix\"],\"readonly\":[4],\"required\":[4],\"round\":[4],\"type\":[1],\"value\":[1025],\"errors\":[4],\"errorUpdate\":[8,\"error-update\"],\"nativeAttributes\":[16],\"hasSlottedLabel\":[32],\"hasSlottedHint\":[32],\"hasSlottedCounter\":[32],\"isPasswordShown\":[32],\"errorMap\":[32],\"doFocus\":[64],\"doBlur\":[64],\"clear\":[64],\"mask\":[64]},null,{\"errors\":[\"onErrorsChanged\"]}],[1,\"cat-dropdown\",{\"placement\":[1],\"noAutoClose\":[4,\"no-auto-close\"],\"arrowNavigation\":[1,\"arrow-navigation\"],\"noResize\":[4,\"no-resize\"],\"overflow\":[4],\"noInitialFocus\":[4,\"no-initial-focus\"],\"noReturnFocus\":[4,\"no-return-focus\"],\"toggle\":[64],\"open\":[64],\"close\":[64]},[[0,\"catClick\",\"clickHandler\"]]],[17,\"cat-button\",{\"variant\":[1],\"color\":[1],\"active\":[4],\"size\":[1],\"name\":[1],\"value\":[1],\"disabled\":[4],\"loading\":[4],\"submit\":[4],\"noEllipsis\":[4,\"no-ellipsis\"],\"round\":[4],\"url\":[1],\"urlTarget\":[1,\"url-target\"],\"icon\":[1],\"iconOnly\":[8,\"icon-only\"],\"iconRight\":[4,\"icon-right\"],\"buttonId\":[1,\"button-id\"],\"a11yLabel\":[1,\"a11y-label\"],\"a11yCurrent\":[1,\"a11y-current\"],\"nativeAttributes\":[16],\"nativeContentAttributes\":[16],\"buttonGroupPosition\":[1,\"button-group-position\"],\"_iconOnly\":[32],\"hasSlottedContent\":[32],\"doFocus\":[64],\"doBlur\":[64],\"doClick\":[64]},[[0,\"click\",\"haltDisabledEvents\"]],{\"iconOnly\":[\"onIconOnlyChanged\"]}],[1,\"cat-spinner\",{\"size\":[1],\"a11yLabel\":[1,\"a11y-label\"],\"value\":[2]}],[1,\"cat-icon\",{\"icon\":[1],\"iconSrc\":[1,\"icon-src\"],\"size\":[1],\"a11yLabel\":[1,\"a11y-label\"]}]]]]"), options);
12
12
  };
13
13
 
14
14
  exports.setNonce = index.setNonce;
@@ -433,7 +433,7 @@
433
433
  padding: 0.875rem 1rem;
434
434
  font-size: 0.9375rem;
435
435
  line-height: 1.25rem;
436
- gap: 0.25rem;
436
+ gap: 0.5rem;
437
437
  }
438
438
  .cat-button-l cat-icon {
439
439
  margin-top: -0.125rem;
@@ -480,7 +480,7 @@
480
480
  padding: 1rem 1.25rem;
481
481
  font-size: 1.125rem;
482
482
  line-height: 1.5rem;
483
- gap: 0.5rem;
483
+ gap: 0.75rem;
484
484
  }
485
485
  .cat-button-xl.cat-button-icon {
486
486
  width: 3.5rem;
@@ -61,14 +61,13 @@ export class CatCheckbox {
61
61
  this.input.blur();
62
62
  }
63
63
  render() {
64
- this.hostElement.tabIndex = Number(this.hostElement.getAttribute('tabindex')) || 0;
65
- return (h(Host, { key: 'ab6bd1bb1b74998b5202e57ba6b32da9dd0135c8' }, h("label", { key: '5554806b29bbdea219869d043f9c41469390720d', htmlFor: this.id, class: {
64
+ return (h(Host, { key: '8c0eb5c93eb3c1afd12a482cef1d00b693aaaa6b' }, h("label", { key: 'b547cfd3a6aec8c312f4cfbb12304749f4bb130a', htmlFor: this.id, class: {
66
65
  'is-hidden': this.labelHidden,
67
66
  'is-disabled': this.disabled,
68
67
  'label-left': this.labelLeft,
69
68
  'align-center': this.alignment === 'center',
70
69
  'align-end': this.alignment === 'bottom'
71
- } }, h("input", { key: 'cccc0ef488d141b6eb4859fcc58433174f7ce21b', ...this.nativeAttributes, part: "input", ref: el => (this.input = el), id: this.id, type: "checkbox", name: this.name, value: this.value, checked: this.checked, required: this.required, disabled: this.disabled, indeterminate: this.indeterminate, onInput: this.onInput.bind(this), onFocus: this.onFocus.bind(this), onBlur: this.onBlur.bind(this), "aria-describedby": this.hasHint ? this.id + '-hint' : undefined }), h("span", { key: 'c6c568ebc80618b4acc3e28793c1844284d4a831', class: "box", "aria-hidden": "true" }, h("svg", { key: '5c8c2ae933fecab8b9c826ef2493b2dec129f49c', class: "check", viewBox: "0 0 12 10" }, h("polyline", { key: '4ed298a1e0377c4ca771940b7da867c5e72017af', points: "1.5 6 4.5 9 10.5 1" })), h("svg", { key: '4ca83993e600c99f4651333ce9f86c0f2b85754a', class: "dash", viewBox: "0 0 12 10" }, h("polyline", { key: '32d6a98f6247ce1605baa1c0fcb66325300d0118', points: "1.5 5 10.5 5" }))), h("span", { key: 'cdf8717a98a756e4ae204d08fd186cf49ea7d101', class: { label: true, 'label-wrapper': !this.hasSlottedLabel }, part: "label" }, (this.hasSlottedLabel && h("slot", { key: '967c87e44e4bb119b46ae70edf2eb47d63177a90', name: "label" })) || this.label, h("span", { key: '04a85b99e78e8db04e4080d54ff1690051ce2a50', class: "label-metadata" }, !this.required && (this.requiredMarker ?? 'optional').startsWith('optional') && (h("span", { key: 'caf9a8682262079edf06957ca2a2c9d14abc9130', class: "label-optional", "aria-hidden": "true" }, "(", i18n.t('input.optional'), ")")), this.required && this.requiredMarker?.startsWith('required') && (h("span", { key: 'd073fb49348c5561984c73bafbf7fd7e17f01ba5', class: "label-optional", "aria-hidden": "true" }, "(", i18n.t('input.required'), ")"))))), this.hasHint && (h("div", { key: '9fb0531829e03683accb07fdc675975feb709577', class: { 'hint-wrapper': true, 'label-left': this.labelLeft } }, h("div", { key: 'e72ad8ae3b9048ef6a58d74eb9593d511fad03c6', class: "box-placeholder" }), h(CatFormHint, { key: 'b10a09f94fe13f1cc7602191c0e7b3d2066a8364', id: this.id, hint: this.hint, slottedHint: this.hasSlottedHint && h("slot", { name: "hint" }) })))));
70
+ } }, h("input", { key: 'ba2e7b5af1943fe8c6ad4489edc2a0973ddda065', ...this.nativeAttributes, part: "input", ref: el => (this.input = el), id: this.id, type: "checkbox", name: this.name, value: this.value, checked: this.checked, required: this.required, disabled: this.disabled, indeterminate: this.indeterminate, onInput: this.onInput.bind(this), onFocus: this.onFocus.bind(this), onBlur: this.onBlur.bind(this), "aria-describedby": this.hasHint ? this.id + '-hint' : undefined }), h("span", { key: '9df445a24845020c80a0f52383de1720dd7d867e', class: "box", "aria-hidden": "true" }, h("svg", { key: '30000e8be49bec99d68a543963cf351c7ff3fd7c', class: "check", viewBox: "0 0 12 10" }, h("polyline", { key: '793e1b85f1df92af1168696f5470c74b4ac56ebb', points: "1.5 6 4.5 9 10.5 1" })), h("svg", { key: '28519cf606fd5c4f1ce87e6682c49192d9c7ccdd', class: "dash", viewBox: "0 0 12 10" }, h("polyline", { key: 'ef38c2175504c86bbcc930ab4e3e259600675849', points: "1.5 5 10.5 5" }))), h("span", { key: '34b01f1d76b7d840245822340e6cf15a3745d948', class: { label: true, 'label-wrapper': !this.hasSlottedLabel }, part: "label" }, (this.hasSlottedLabel && h("slot", { key: '088699ea29bf4fc53b784b798afc698f848343d2', name: "label" })) || this.label, h("span", { key: '4e4dfcc4b985ab4962fe42e88c09abd60170e5f2', class: "label-metadata" }, !this.required && (this.requiredMarker ?? 'optional').startsWith('optional') && (h("span", { key: '5762ff2168f759ff2fd0d566eb99bd23e9a3154d', class: "label-optional", "aria-hidden": "true" }, "(", i18n.t('input.optional'), ")")), this.required && this.requiredMarker?.startsWith('required') && (h("span", { key: '11b3596d3b6e7ae1b4356fc029f861e2407ff9ab', class: "label-optional", "aria-hidden": "true" }, "(", i18n.t('input.required'), ")"))))), this.hasHint && (h("div", { key: '8814d349c83078c76a948bd91fb66a593824ba87', class: { 'hint-wrapper': true, 'label-left': this.labelLeft } }, h("div", { key: '99fc171926a6d467140824b22fb3d66848c9a1a3', class: "box-placeholder" }), h(CatFormHint, { key: '09b2a51545a4d0f731f0d42930c9d18f5e0cb512', id: this.id, hint: this.hint, slottedHint: this.hasSlottedHint && h("slot", { name: "hint" }) })))));
72
71
  }
73
72
  get hasHint() {
74
73
  return !!this.hint || !!this.hasSlottedHint;
@@ -90,7 +89,6 @@ export class CatCheckbox {
90
89
  }
91
90
  static get is() { return "cat-checkbox"; }
92
91
  static get encapsulation() { return "shadow"; }
93
- static get delegatesFocus() { return true; }
94
92
  static get originalStyleUrls() {
95
93
  return {
96
94
  "$": ["cat-checkbox.scss"]
@@ -1 +1 @@
1
- {"version":3,"file":"cat-checkbox.js","sourceRoot":"","sources":["../../../src/components/cat-checkbox/cat-checkbox.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACtG,OAAO,EAAE,WAAW,EAAE,MAAM,gCAAgC,CAAC;AAC7D,OAAO,EAAE,eAAe,IAAI,IAAI,EAAE,MAAM,+BAA+B,CAAC;AAExE,IAAI,YAAY,GAAG,CAAC,CAAC;AAErB;;;;;;;;GAQG;AAQH,MAAM,OAAO,WAAW;;QACL,QAAG,GAAG,gBAAgB,YAAY,EAAE,EAAE,CAAC;+BAS7B,KAAK;8BAEN,KAAK;uBAKI,KAAK;6BAKC,KAAK;wBAK3B,KAAK;;qBAUR,EAAE;2BAKI,KAAK;;wBAUR,KAAK;;;6BAkBsB,IAAI;;yBAU9B,KAAK;yBAKwB,KAAK;;8BAU4C,MAAM;;IA7FxG,IAAY,EAAE;QACZ,OAAO,IAAI,CAAC,UAAU,IAAI,IAAI,CAAC,GAAG,CAAC;IACrC,CAAC;IA6GD,iBAAiB;QACf,IAAI,CAAC,cAAc,EAAE,CAAC;IACxB,CAAC;IAED,mBAAmB;QACjB,IAAI,CAAC,eAAe,GAAG,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,aAAa,CAAC,gBAAgB,CAAC,CAAC;QAC1E,IAAI,CAAC,cAAc,GAAG,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,aAAa,CAA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, Event, EventEmitter, h, Host, Method, Prop, State } from '@stencil/core';\nimport { CatFormHint } from '../cat-form-hint/cat-form-hint';\nimport { catI18nRegistry as i18n } from '../cat-i18n/cat-i18n-registry';\n\nlet nextUniqueId = 0;\n\n/**\n * Checkboxes are used to let a user choose one or more options from a limited\n * number of options.\n *\n * @slot hint - Optional hint element to be displayed with the checkbox.\n * @slot label - The slotted label. If both the label property and the label slot are present, only the label slot will be displayed.\n * @part label - The label content.\n * @part input - The native input element.\n */\n@Component({\n tag: 'cat-checkbox',\n styleUrls: ['cat-checkbox.scss'],\n shadow: {\n delegatesFocus: true\n }\n})\nexport class CatCheckbox {\n private readonly _id = `cat-checkbox-${nextUniqueId++}`;\n private get id() {\n return this.identifier || this._id;\n }\n\n private input!: HTMLInputElement;\n\n @Element() hostElement!: HTMLElement;\n\n @State() hasSlottedLabel = false;\n\n @State() hasSlottedHint = false;\n\n /**\n * Checked state of the checkbox\n */\n @Prop({ mutable: true }) checked = false;\n\n /**\n * Indeterminate state of the checkbox\n */\n @Prop({ mutable: true }) indeterminate = false;\n\n /**\n * Disabled state of the checkbox\n */\n @Prop() disabled = false;\n\n /**\n * A unique identifier for the input.\n */\n @Prop() identifier?: string;\n\n /**\n * Label of the checkbox which is presented in the UI\n */\n @Prop() label = '';\n\n /**\n * Visually hide the label, but still show it to assistive technologies like screen readers.\n */\n @Prop() labelHidden = false;\n\n /**\n * The name of the input.\n */\n @Prop() name?: string;\n\n /**\n * Required state of the checkbox.\n */\n @Prop() required = false;\n\n /**\n * The value of the checked checkbox.\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n @Prop() value?: any;\n\n /**\n * The value of the unchecked checkbox.\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n @Prop() noValue?: any;\n\n /**\n * The resolved value of the checkbox, based on the checked state and value.\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n @Prop({ mutable: true }) resolvedValue: any = null;\n\n /**\n * Optional hint text(s) to be displayed with the checkbox.\n */\n @Prop() hint?: string | string[];\n\n /**\n * Whether the label should appear to the left of the checkbox.\n */\n @Prop() labelLeft = false;\n\n /**\n * The alignment of the checkbox.\n */\n @Prop() alignment: 'center' | 'top' | 'bottom' = 'top';\n\n /**\n * Attributes that will be added to the native HTML input element.\n */\n @Prop() nativeAttributes?: { [key: string]: string };\n\n /**\n * Whether the label need a marker to shown if the input is required or optional.\n */\n @Prop() requiredMarker?: 'none' | 'required' | 'optional' | 'none!' | 'optional!' | 'required!' = 'none';\n\n /**\n * Emitted when the checked status of the checkbox is changed.\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n @Event() catChange!: EventEmitter<any>;\n\n /**\n * Emitted when the checkbox received focus.\n */\n @Event() catFocus!: EventEmitter<FocusEvent>;\n\n /**\n * Emitted when the checkbox loses focus.\n */\n @Event() catBlur!: EventEmitter<FocusEvent>;\n\n componentWillLoad() {\n this.updateResolved();\n }\n\n componentWillRender(): void {\n this.hasSlottedLabel = !!this.hostElement.querySelector('[slot=\"label\"]');\n this.hasSlottedHint = !!this.hostElement.querySelector('[slot=\"hint\"]');\n }\n\n /**\n * Programmatically move focus to the checkbox. Use this method instead of\n * `input.focus()`.\n *\n * @param options An optional object providing options to control aspects of\n * the focusing process.\n */\n @Method()\n async doFocus(options?: FocusOptions): Promise<void> {\n this.input.focus(options);\n }\n\n /**\n * Programmatically remove focus from the checkbox. Use this method instead of\n * `input.blur()`.\n */\n @Method()\n async doBlur(): Promise<void> {\n this.input.blur();\n }\n\n render() {\n this.hostElement.tabIndex = Number(this.hostElement.getAttribute('tabindex')) || 0;\n return (\n <Host>\n <label\n htmlFor={this.id}\n class={{\n 'is-hidden': this.labelHidden,\n 'is-disabled': this.disabled,\n 'label-left': this.labelLeft,\n 'align-center': this.alignment === 'center',\n 'align-end': this.alignment === 'bottom'\n }}\n >\n <input\n {...this.nativeAttributes}\n part=\"input\"\n ref={el => (this.input = el as HTMLInputElement)}\n id={this.id}\n type=\"checkbox\"\n name={this.name}\n value={this.value}\n checked={this.checked}\n required={this.required}\n disabled={this.disabled}\n indeterminate={this.indeterminate}\n onInput={this.onInput.bind(this)}\n onFocus={this.onFocus.bind(this)}\n onBlur={this.onBlur.bind(this)}\n aria-describedby={this.hasHint ? this.id + '-hint' : undefined}\n />\n <span class=\"box\" aria-hidden=\"true\">\n <svg class=\"check\" viewBox=\"0 0 12 10\">\n <polyline points=\"1.5 6 4.5 9 10.5 1\"></polyline>\n </svg>\n <svg class=\"dash\" viewBox=\"0 0 12 10\">\n <polyline points=\"1.5 5 10.5 5\"></polyline>\n </svg>\n </span>\n <span class={{ label: true, 'label-wrapper': !this.hasSlottedLabel }} part=\"label\">\n {(this.hasSlottedLabel && <slot name=\"label\"></slot>) || this.label}\n <span class=\"label-metadata\">\n {!this.required && (this.requiredMarker ?? 'optional').startsWith('optional') && (\n <span class=\"label-optional\" aria-hidden=\"true\">\n ({i18n.t('input.optional')})\n </span>\n )}\n {this.required && this.requiredMarker?.startsWith('required') && (\n <span class=\"label-optional\" aria-hidden=\"true\">\n ({i18n.t('input.required')})\n </span>\n )}\n </span>\n </span>\n </label>\n {this.hasHint && (\n <div class={{ 'hint-wrapper': true, 'label-left': this.labelLeft }}>\n <div class=\"box-placeholder\"></div>\n <CatFormHint id={this.id} hint={this.hint} slottedHint={this.hasSlottedHint && <slot name=\"hint\"></slot>} />\n </div>\n )}\n </Host>\n );\n }\n\n private get hasHint() {\n return !!this.hint || !!this.hasSlottedHint;\n }\n\n private onInput() {\n this.checked = this.input.checked;\n this.indeterminate = this.input.indeterminate;\n this.updateResolved();\n this.catChange.emit(this.resolvedValue);\n }\n\n private onFocus(event: FocusEvent) {\n this.catFocus.emit(event);\n }\n\n private onBlur(event: FocusEvent) {\n this.catBlur.emit(event);\n }\n\n private updateResolved() {\n this.resolvedValue = this.checked ? (this.value ?? true) : (this.noValue ?? false);\n }\n}\n"]}
1
+ {"version":3,"file":"cat-checkbox.js","sourceRoot":"","sources":["../../../src/components/cat-checkbox/cat-checkbox.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAC;AACtG,OAAO,EAAE,WAAW,EAAE,MAAM,gCAAgC,CAAC;AAC7D,OAAO,EAAE,eAAe,IAAI,IAAI,EAAE,MAAM,+BAA+B,CAAC;AAExE,IAAI,YAAY,GAAG,CAAC,CAAC;AAErB;;;;;;;;GAQG;AAMH,MAAM,OAAO,WAAW;;QACL,QAAG,GAAG,gBAAgB,YAAY,EAAE,EAAE,CAAC;+BAS7B,KAAK;8BAEN,KAAK;uBAKI,KAAK;6BAKC,KAAK;wBAK3B,KAAK;;qBAUR,EAAE;2BAKI,KAAK;;wBAUR,KAAK;;;6BAkBsB,IAAI;;yBAU9B,KAAK;yBAKwB,KAAK;;8BAU4C,MAAM;;IA7FxG,IAAY,EAAE;QACZ,OAAO,IAAI,CAAC,UAAU,IAAI,IAAI,CAAC,GAAG,CAAC;IACrC,CAAC;IA6GD,iBAAiB;QACf,IAAI,CAAC,cAAc,EAAE,CAAC;IACxB,CAAC;IAED,mBAAmB;QACjB,IAAI,CAAC,eAAe,GAAG,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,aAAa,CAAC,gBAAgB,CAAC,CAAC;QAC1E,IAAI,CAAC,cAAc,GAAG,CAAC,CAAC,IAAI,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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACF","sourcesContent":["import { Component, Element, Event, EventEmitter, h, Host, Method, Prop, State } from '@stencil/core';\nimport { CatFormHint } from '../cat-form-hint/cat-form-hint';\nimport { catI18nRegistry as i18n } from '../cat-i18n/cat-i18n-registry';\n\nlet nextUniqueId = 0;\n\n/**\n * Checkboxes are used to let a user choose one or more options from a limited\n * number of options.\n *\n * @slot hint - Optional hint element to be displayed with the checkbox.\n * @slot label - The slotted label. If both the label property and the label slot are present, only the label slot will be displayed.\n * @part label - The label content.\n * @part input - The native input element.\n */\n@Component({\n tag: 'cat-checkbox',\n styleUrls: ['cat-checkbox.scss'],\n shadow: true\n})\nexport class CatCheckbox {\n private readonly _id = `cat-checkbox-${nextUniqueId++}`;\n private get id() {\n return this.identifier || this._id;\n }\n\n private input!: HTMLInputElement;\n\n @Element() hostElement!: HTMLElement;\n\n @State() hasSlottedLabel = false;\n\n @State() hasSlottedHint = false;\n\n /**\n * Checked state of the checkbox\n */\n @Prop({ mutable: true }) checked = false;\n\n /**\n * Indeterminate state of the checkbox\n */\n @Prop({ mutable: true }) indeterminate = false;\n\n /**\n * Disabled state of the checkbox\n */\n @Prop() disabled = false;\n\n /**\n * A unique identifier for the input.\n */\n @Prop() identifier?: string;\n\n /**\n * Label of the checkbox which is presented in the UI\n */\n @Prop() label = '';\n\n /**\n * Visually hide the label, but still show it to assistive technologies like screen readers.\n */\n @Prop() labelHidden = false;\n\n /**\n * The name of the input.\n */\n @Prop() name?: string;\n\n /**\n * Required state of the checkbox.\n */\n @Prop() required = false;\n\n /**\n * The value of the checked checkbox.\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n @Prop() value?: any;\n\n /**\n * The value of the unchecked checkbox.\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n @Prop() noValue?: any;\n\n /**\n * The resolved value of the checkbox, based on the checked state and value.\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n @Prop({ mutable: true }) resolvedValue: any = null;\n\n /**\n * Optional hint text(s) to be displayed with the checkbox.\n */\n @Prop() hint?: string | string[];\n\n /**\n * Whether the label should appear to the left of the checkbox.\n */\n @Prop() labelLeft = false;\n\n /**\n * The alignment of the checkbox.\n */\n @Prop() alignment: 'center' | 'top' | 'bottom' = 'top';\n\n /**\n * Attributes that will be added to the native HTML input element.\n */\n @Prop() nativeAttributes?: { [key: string]: string };\n\n /**\n * Whether the label need a marker to shown if the input is required or optional.\n */\n @Prop() requiredMarker?: 'none' | 'required' | 'optional' | 'none!' | 'optional!' | 'required!' = 'none';\n\n /**\n * Emitted when the checked status of the checkbox is changed.\n */\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n @Event() catChange!: EventEmitter<any>;\n\n /**\n * Emitted when the checkbox received focus.\n */\n @Event() catFocus!: EventEmitter<FocusEvent>;\n\n /**\n * Emitted when the checkbox loses focus.\n */\n @Event() catBlur!: EventEmitter<FocusEvent>;\n\n componentWillLoad() {\n this.updateResolved();\n }\n\n componentWillRender(): void {\n this.hasSlottedLabel = !!this.hostElement.querySelector('[slot=\"label\"]');\n this.hasSlottedHint = !!this.hostElement.querySelector('[slot=\"hint\"]');\n }\n\n /**\n * Programmatically move focus to the checkbox. Use this method instead of\n * `input.focus()`.\n *\n * @param options An optional object providing options to control aspects of\n * the focusing process.\n */\n @Method()\n async doFocus(options?: FocusOptions): Promise<void> {\n this.input.focus(options);\n }\n\n /**\n * Programmatically remove focus from the checkbox. Use this method instead of\n * `input.blur()`.\n */\n @Method()\n async doBlur(): Promise<void> {\n this.input.blur();\n }\n\n render() {\n return (\n <Host>\n <label\n htmlFor={this.id}\n class={{\n 'is-hidden': this.labelHidden,\n 'is-disabled': this.disabled,\n 'label-left': this.labelLeft,\n 'align-center': this.alignment === 'center',\n 'align-end': this.alignment === 'bottom'\n }}\n >\n <input\n {...this.nativeAttributes}\n part=\"input\"\n ref={el => (this.input = el as HTMLInputElement)}\n id={this.id}\n type=\"checkbox\"\n name={this.name}\n value={this.value}\n checked={this.checked}\n required={this.required}\n disabled={this.disabled}\n indeterminate={this.indeterminate}\n onInput={this.onInput.bind(this)}\n onFocus={this.onFocus.bind(this)}\n onBlur={this.onBlur.bind(this)}\n aria-describedby={this.hasHint ? this.id + '-hint' : undefined}\n />\n <span class=\"box\" aria-hidden=\"true\">\n <svg class=\"check\" viewBox=\"0 0 12 10\">\n <polyline points=\"1.5 6 4.5 9 10.5 1\"></polyline>\n </svg>\n <svg class=\"dash\" viewBox=\"0 0 12 10\">\n <polyline points=\"1.5 5 10.5 5\"></polyline>\n </svg>\n </span>\n <span class={{ label: true, 'label-wrapper': !this.hasSlottedLabel }} part=\"label\">\n {(this.hasSlottedLabel && <slot name=\"label\"></slot>) || this.label}\n <span class=\"label-metadata\">\n {!this.required && (this.requiredMarker ?? 'optional').startsWith('optional') && (\n <span class=\"label-optional\" aria-hidden=\"true\">\n ({i18n.t('input.optional')})\n </span>\n )}\n {this.required && this.requiredMarker?.startsWith('required') && (\n <span class=\"label-optional\" aria-hidden=\"true\">\n ({i18n.t('input.required')})\n </span>\n )}\n </span>\n </span>\n </label>\n {this.hasHint && (\n <div class={{ 'hint-wrapper': true, 'label-left': this.labelLeft }}>\n <div class=\"box-placeholder\"></div>\n <CatFormHint id={this.id} hint={this.hint} slottedHint={this.hasSlottedHint && <slot name=\"hint\"></slot>} />\n </div>\n )}\n </Host>\n );\n }\n\n private get hasHint() {\n return !!this.hint || !!this.hasSlottedHint;\n }\n\n private onInput() {\n this.checked = this.input.checked;\n this.indeterminate = this.input.indeterminate;\n this.updateResolved();\n this.catChange.emit(this.resolvedValue);\n }\n\n private onFocus(event: FocusEvent) {\n this.catFocus.emit(event);\n }\n\n private onBlur(event: FocusEvent) {\n this.catBlur.emit(event);\n }\n\n private updateResolved() {\n this.resolvedValue = this.checked ? (this.value ?? true) : (this.noValue ?? false);\n }\n}\n"]}
@@ -7,7 +7,7 @@ describe('cat-checkbox', () => {
7
7
  html: `<cat-checkbox label="Label"></cat-checkbox>`
8
8
  });
9
9
  expect(page.root).toEqualLightHtml(`
10
- <cat-checkbox label="Label" tabindex="0"></cat-checkbox>
10
+ <cat-checkbox label="Label"></cat-checkbox>
11
11
  `);
12
12
  });
13
13
  });
@@ -1 +1 @@
1
- {"version":3,"file":"cat-checkbox.spec.js","sourceRoot":"","sources":["../../../src/components/cat-checkbox/cat-checkbox.spec.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACpD,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,QAAQ,CAAC,cAAc,EAAE,GAAG,EAAE;IAC5B,EAAE,CAAC,SAAS,EAAE,KAAK,IAAI,EAAE;QACvB,MAAM,IAAI,GAAG,MAAM,WAAW,CAAC;YAC7B,UAAU,EAAE,CAAC,WAAW,CAAC;YACzB,IAAI,EAAE,6CAA6C;SACpD,CAAC,CAAC;QACH,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,gBAAgB,CAAC;;KAElC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC","sourcesContent":["import { newSpecPage } from '@stencil/core/testing';\nimport { CatCheckbox } from './cat-checkbox';\n\ndescribe('cat-checkbox', () => {\n it('renders', async () => {\n const page = await newSpecPage({\n components: [CatCheckbox],\n html: `<cat-checkbox label=\"Label\"></cat-checkbox>`\n });\n expect(page.root).toEqualLightHtml(`\n <cat-checkbox label=\"Label\" tabindex=\"0\"></cat-checkbox>\n `);\n });\n});\n"]}
1
+ {"version":3,"file":"cat-checkbox.spec.js","sourceRoot":"","sources":["../../../src/components/cat-checkbox/cat-checkbox.spec.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACpD,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAE7C,QAAQ,CAAC,cAAc,EAAE,GAAG,EAAE;IAC5B,EAAE,CAAC,SAAS,EAAE,KAAK,IAAI,EAAE;QACvB,MAAM,IAAI,GAAG,MAAM,WAAW,CAAC;YAC7B,UAAU,EAAE,CAAC,WAAW,CAAC;YACzB,IAAI,EAAE,6CAA6C;SACpD,CAAC,CAAC;QACH,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,gBAAgB,CAAC;;KAElC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC","sourcesContent":["import { newSpecPage } from '@stencil/core/testing';\nimport { CatCheckbox } from './cat-checkbox';\n\ndescribe('cat-checkbox', () => {\n it('renders', async () => {\n const page = await newSpecPage({\n components: [CatCheckbox],\n html: `<cat-checkbox label=\"Label\"></cat-checkbox>`\n });\n expect(page.root).toEqualLightHtml(`\n <cat-checkbox label=\"Label\"></cat-checkbox>\n `);\n });\n});\n"]}
@@ -11,18 +11,18 @@
11
11
  }
12
12
 
13
13
  @mixin cat-visually-hidden-focusable {
14
- &:not(:focus):not(:focus-within) {
14
+ &:not(:focus-visible):not(:has(:focus-visible)) {
15
15
  @include cat-visually-hidden;
16
16
  }
17
17
  }
18
18
 
19
19
  @mixin cat-visually-hidden-hoverable($container: null) {
20
20
  @if $container {
21
- #{$container}:not(:hover):not(:focus):not(:focus-within) & {
21
+ #{$container}:not(:hover):not(:focus-visible):not(:has(:focus-visible)) & {
22
22
  @include cat-visually-hidden;
23
23
  }
24
24
  } @else {
25
- *:not(:hover):not(:focus):not(:focus-within) > & {
25
+ *:not(:hover):not(:focus-visible):not(:has(:focus-visible)) > & {
26
26
  @include cat-visually-hidden;
27
27
  }
28
28
  }
@@ -16,7 +16,7 @@ function findClosest(selector, element) {
16
16
  return nextElement ? findClosest(selector, nextElement) : null;
17
17
  }
18
18
 
19
- const catButtonCss = ":host{display:inline-block;max-width:100%;vertical-align:middle;-webkit-user-select:none;-ms-user-select:none;user-select:none;}:host([hidden]){display:none}:host([data-button-group=middle]),:host([data-button-group=last]){margin-left:-1px}.cat-button{position:relative;font:inherit;display:flex;align-items:center;justify-content:center;border:none;border-radius:var(--cat-border-radius-m, 0.25rem);text-decoration:none;width:100%;box-sizing:border-box;cursor:pointer;transition:color 125ms linear, border-color 125ms linear, background-color 125ms linear, box-shadow 125ms linear}.cat-button:focus-visible{outline:2px solid rgb(var(--cat-border-color-focus, 0, 113, 255));outline-offset:1px}.cat-button-content{display:flex;flex-direction:column;min-width:0}.cat-button-empty .cat-button-content{display:none}.cat-button-content-inner{word-wrap:break-word;word-break:break-word}.cat-button-ellipsed .cat-button-content-inner{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}.cat-button-disabled{cursor:not-allowed}.cat-button-round{border-radius:10rem}.cat-button-loading{cursor:default}.cat-button-loading cat-spinner{position:absolute}.cat-button-loading>*:not(cat-spinner){visibility:hidden}.cat-button-group-first{border-top-right-radius:0;border-bottom-right-radius:0}.cat-button-group-middle{border-radius:0}.cat-button-group-last{border-top-left-radius:0;border-bottom-left-radius:0}.cat-button-group:hover{z-index:1}.cat-button-group:focus-visible{z-index:2}.cat-button-filled{background-color:rgb(var(--bg));color:rgb(var(--fill));font-weight:var(--cat-font-weight-button, 600);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:greyscale}.cat-button-filled.cat-button-disabled{--bg:242, 244, 247;--fill:var(--cat-font-color-muted, 81, 92, 108)}.cat-button-outlined{background-color:white;box-shadow:inset 0 0 0 1px color-mix(in srgb, rgb(var(--base)) 20%, #fff);color:rgb(var(--text))}.cat-button-outlined.cat-button-disabled{--base:var(--cat-font-color-muted, 81, 92, 108);--text:var(--cat-font-color-muted, 81, 92, 108)}.cat-button-outlined:hover:not(.cat-button-disabled):not(.cat-button-loading){background-color:color-mix(in srgb, rgb(var(--base)) 10%, #fff)}.cat-button-outlined.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading){background-color:color-mix(in srgb, rgb(var(--base)) 10%, #fff)}.cat-button-outlined:active:not(.cat-button-disabled):not(.cat-button-loading){background-color:color-mix(in srgb, rgb(var(--base)) 10%, #fff)}.cat-button-text{background-color:transparent;color:rgb(var(--text));text-decoration:var(--cat-link-button-decoration, none)}.cat-button-text.cat-button-disabled{--text:var(--cat-font-color-muted, 81, 92, 108)}.cat-button-text:hover:not(.cat-button-disabled):not(.cat-button-loading){background-color:rgba(var(--base), 0.1)}.cat-button-text.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading){background-color:rgba(var(--base), 0.1)}.cat-button-link{background-color:transparent;color:rgb(var(--text))}.cat-button-link.cat-button-disabled{--text:var(--cat-font-color-muted, 81, 92, 108)}.cat-button-link:hover:not(.cat-button-disabled):not(.cat-button-loading){text-decoration:var(--cat-link-decoration-hover, underline)}.cat-button-link.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading){text-decoration:var(--cat-link-decoration-hover, underline)}.cat-button-primary{--bg:var(--cat-primary-bg, 0, 129, 148);--fill:var(--cat-primary-fill, 255, 255, 255);--text:var(--cat-primary-text, 0, 129, 148);--base:var(--cat-primary-text, 0, 129, 148)}.cat-button-primary:hover:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-primary-bg-hover, 1, 115, 132);--fill:var(--cat-primary-fill-hover, 255, 255, 255);--text:var(--cat-primary-text-hover, 1, 115, 132)}.cat-button-primary.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading),.cat-button-primary:active:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-primary-bg-active, 2, 99, 113);--fill:var(--cat-primary-fill-active, 255, 255, 255);--text:var(--cat-primary-text-active, 2, 99, 113)}.cat-button-secondary{--bg:var(--cat-secondary-bg, 105, 118, 135);--fill:var(--cat-secondary-fill, 255, 255, 255);--text:var(--cat-secondary-text, 0, 0, 0);--base:var(--cat-secondary-bg, 105, 118, 135)}.cat-button-secondary:hover:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-secondary-bg-hover, 105, 118, 135);--fill:var(--cat-secondary-fill-hover, 255, 255, 255);--text:var(--cat-secondary-text-hover, 0, 0, 0)}.cat-button-secondary.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading),.cat-button-secondary:active:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-secondary-bg-active, 105, 118, 135);--fill:var(--cat-secondary-fill-active, 255, 255, 255);--text:var(--cat-secondary-text-active, 0, 0, 0)}.cat-button-info{--bg:var(--cat-info-bg, 0, 115, 230);--fill:var(--cat-info-fill, 255, 255, 255);--text:var(--cat-info-text, 0, 115, 230);--base:var(--cat-info-text, 0, 115, 230)}.cat-button-info:hover:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-info-bg-hover, 0, 107, 227);--fill:var(--cat-info-fill-hover, 255, 255, 255);--text:var(--cat-info-text-hover, 0, 107, 227)}.cat-button-info.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading),.cat-button-info:active:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-info-bg-active, 0, 96, 223);--fill:var(--cat-info-fill-active, 255, 255, 255);--text:var(--cat-info-text-active, 0, 96, 223)}.cat-button-success{--bg:var(--cat-success-bg, 0, 132, 88);--fill:var(--cat-success-fill, 255, 255, 255);--text:var(--cat-success-text, 0, 132, 88);--base:var(--cat-success-text, 0, 132, 88)}.cat-button-success:hover:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-success-bg-hover, 0, 117, 78);--fill:var(--cat-success-fill-hover, 255, 255, 255);--text:var(--cat-success-text-hover, 0, 117, 78)}.cat-button-success.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading),.cat-button-success:active:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-success-bg-active, 0, 105, 70);--fill:var(--cat-success-fill-active, 255, 255, 255);--text:var(--cat-success-text-active, 0, 105, 70)}.cat-button-warning{--bg:var(--cat-warning-bg, 255, 206, 128);--fill:var(--cat-warning-fill, 0, 0, 0);--text:var(--cat-warning-text, 159, 97, 0);--base:var(--cat-warning-text, 159, 97, 0)}.cat-button-warning:hover:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-warning-bg-hover, 255, 214, 148);--fill:var(--cat-warning-fill-hover, 0, 0, 0);--text:var(--cat-warning-text-hover, 159, 97, 0)}.cat-button-warning.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading),.cat-button-warning:active:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-warning-bg-active, 255, 222, 168);--fill:var(--cat-warning-fill-active, 0, 0, 0);--text:var(--cat-warning-text-active, 159, 97, 0)}.cat-button-danger{--bg:var(--cat-danger-bg, 217, 52, 13);--fill:var(--cat-danger-fill, 255, 255, 255);--text:var(--cat-danger-text, 217, 52, 13);--base:var(--cat-danger-text, 217, 52, 13)}.cat-button-danger:hover:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-danger-bg-hover, 194, 46, 11);--fill:var(--cat-danger-fill-hover, 255, 255, 255);--text:var(--cat-danger-text-hover, 194, 46, 11)}.cat-button-danger.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading),.cat-button-danger:active:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-danger-bg-active, 174, 42, 10);--fill:var(--cat-danger-fill-active, 255, 255, 255);--text:var(--cat-danger-text-active, 174, 42, 10)}:host(.cat-button-pull:not([size])){margin:-0.625rem -0.75rem}:host(.cat-button-pull-h:not([size])){margin-left:-0.75rem;margin-right:-0.75rem}:host(.cat-button-pull-v:not([size])){margin-top:-0.625rem;margin-bottom:-0.625rem}:host(.cat-button-pull-t:not([size])){margin-top:-0.625rem}:host(.cat-button-pull-l:not([size])){margin-left:-0.75rem}:host(.cat-button-pull-b:not([size])){margin-bottom:-0.625rem}:host(.cat-button-pull-r:not([size])){margin-right:-0.75rem}.cat-button-xs{min-width:1.5rem;padding:0.1875rem 0.25rem;font-size:0.875rem;line-height:1.125rem;gap:0.25rem}.cat-button-xs.cat-button-icon{width:1.5rem;height:1.5rem;padding:0}:host(.cat-button-pull[size=xs]){margin:-0.1875rem -0.25rem}:host(.cat-button-pull-h[size=xs]){margin-left:-0.25rem;margin-right:-0.25rem}:host(.cat-button-pull-v[size=xs]){margin-top:-0.1875rem;margin-bottom:-0.1875rem}:host(.cat-button-pull-t[size=xs]){margin-top:-0.1875rem}:host(.cat-button-pull-l[size=xs]){margin-left:-0.25rem}:host(.cat-button-pull-b[size=xs]){margin-bottom:-0.1875rem}:host(.cat-button-pull-r[size=xs]){margin-right:-0.25rem}.cat-button-s{min-width:2rem;padding:0.375rem 0.5rem;font-size:0.9375rem;line-height:1.25rem;gap:0.25rem}.cat-button-s cat-icon{margin-top:-0.125rem;margin-bottom:-0.125rem}.cat-button-s.cat-button-icon{width:2rem;height:2rem;padding:0}:host(.cat-button-pull[size=s]){margin:-0.375rem -0.5rem}:host(.cat-button-pull-h[size=s]){margin-left:-0.5rem;margin-right:-0.5rem}:host(.cat-button-pull-v[size=s]){margin-top:-0.375rem;margin-bottom:-0.375rem}:host(.cat-button-pull-t[size=s]){margin-top:-0.375rem}:host(.cat-button-pull-l[size=s]){margin-left:-0.5rem}:host(.cat-button-pull-b[size=s]){margin-bottom:-0.375rem}:host(.cat-button-pull-r[size=s]){margin-right:-0.5rem}.cat-button-m{min-width:2.5rem;padding:0.625rem 0.75rem;font-size:0.9375rem;line-height:1.25rem;gap:0.25rem}.cat-button-m cat-icon{margin-top:-0.125rem;margin-bottom:-0.125rem}.cat-button-m.cat-button-icon{width:2.5rem;height:2.5rem;padding:0}:host(.cat-button-pull[size=m]){margin:-0.625rem -0.75rem}:host(.cat-button-pull-h[size=m]){margin-left:-0.75rem;margin-right:-0.75rem}:host(.cat-button-pull-v[size=m]){margin-top:-0.625rem;margin-bottom:-0.625rem}:host(.cat-button-pull-t[size=m]){margin-top:-0.625rem}:host(.cat-button-pull-l[size=m]){margin-left:-0.75rem}:host(.cat-button-pull-b[size=m]){margin-bottom:-0.625rem}:host(.cat-button-pull-r[size=m]){margin-right:-0.75rem}.cat-button-l{min-width:3rem;padding:0.875rem 1rem;font-size:0.9375rem;line-height:1.25rem;gap:0.25rem}.cat-button-l cat-icon{margin-top:-0.125rem;margin-bottom:-0.125rem}.cat-button-l.cat-button-icon{width:3rem;height:3rem;padding:0}:host(.cat-button-pull[size=l]){margin:-0.875rem -1rem}:host(.cat-button-pull-h[size=l]){margin-left:-1rem;margin-right:-1rem}:host(.cat-button-pull-v[size=l]){margin-top:-0.875rem;margin-bottom:-0.875rem}:host(.cat-button-pull-t[size=l]){margin-top:-0.875rem}:host(.cat-button-pull-l[size=l]){margin-left:-1rem}:host(.cat-button-pull-b[size=l]){margin-bottom:-0.875rem}:host(.cat-button-pull-r[size=l]){margin-right:-1rem}.cat-button-xl{min-width:3.5rem;padding:1rem 1.25rem;font-size:1.125rem;line-height:1.5rem;gap:0.5rem}.cat-button-xl.cat-button-icon{width:3.5rem;height:3.5rem;padding:0}:host(.cat-button-pull[size=xl]){margin:-1rem -1.25rem}:host(.cat-button-pull-h[size=xl]){margin-left:-1.25rem;margin-right:-1.25rem}:host(.cat-button-pull-v[size=xl]){margin-top:-1rem;margin-bottom:-1rem}:host(.cat-button-pull-t[size=xl]){margin-top:-1rem}:host(.cat-button-pull-l[size=xl]){margin-left:-1.25rem}:host(.cat-button-pull-b[size=xl]){margin-bottom:-1rem}:host(.cat-button-pull-r[size=xl]){margin-right:-1.25rem}:host(.cat-tab)::part(button){padding:1.125rem 0.75rem;--cat-secondary-bg:transparent;--cat-primary-text:transparent;--cat-danger-text:transparent}:host(.cat-tab)::part(content)::before{content:attr(data-text);content:attr(data-text)/\"\";height:0;visibility:hidden;overflow:hidden;user-select:none;pointer-events:none;font-weight:700}:host(.cat-text-left) .cat-button{justify-content:left;text-align:left}:host(.cat-text-right) .cat-button{justify-content:right;text-align:right}:host(.cat-nav-item){width:100%}:host(.cat-nav-item) .cat-button{box-shadow:none;justify-content:left;gap:0.5rem}:host(.cat-nav-item) .cat-button:focus-visible{outline-offset:-2px}:host(.cat-time-format) .cat-button{border-radius:0}:host(.cat-date-toggle) .cat-button,:host(.cat-time-toggle) .cat-button{margin-left:-1px;border-top-left-radius:0;border-bottom-left-radius:0}:host(.cat-date-item) .cat-button:hover,:host(.cat-date-toggle) .cat-button:hover,:host(.cat-time-format) .cat-button:hover,:host(.cat-time-toggle) .cat-button:hover{z-index:1}:host(.cat-date-item) .cat-button:focus-visible,:host(.cat-date-toggle) .cat-button:focus-visible,:host(.cat-time-format) .cat-button:focus-visible,:host(.cat-time-toggle) .cat-button:focus-visible{z-index:2}:host(.cat-date-item) .cat-button{padding:0;min-width:2rem;max-height:3rem;aspect-ratio:1}:host(.date-start:not(.date-end)) .cat-button{border-top-right-radius:0;border-bottom-right-radius:0}:host(.date-end:not(.date-start)) .cat-button{border-top-left-radius:0;border-bottom-left-radius:0}";
19
+ const catButtonCss = ":host{display:inline-block;max-width:100%;vertical-align:middle;-webkit-user-select:none;-ms-user-select:none;user-select:none;}:host([hidden]){display:none}:host([data-button-group=middle]),:host([data-button-group=last]){margin-left:-1px}.cat-button{position:relative;font:inherit;display:flex;align-items:center;justify-content:center;border:none;border-radius:var(--cat-border-radius-m, 0.25rem);text-decoration:none;width:100%;box-sizing:border-box;cursor:pointer;transition:color 125ms linear, border-color 125ms linear, background-color 125ms linear, box-shadow 125ms linear}.cat-button:focus-visible{outline:2px solid rgb(var(--cat-border-color-focus, 0, 113, 255));outline-offset:1px}.cat-button-content{display:flex;flex-direction:column;min-width:0}.cat-button-empty .cat-button-content{display:none}.cat-button-content-inner{word-wrap:break-word;word-break:break-word}.cat-button-ellipsed .cat-button-content-inner{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}.cat-button-disabled{cursor:not-allowed}.cat-button-round{border-radius:10rem}.cat-button-loading{cursor:default}.cat-button-loading cat-spinner{position:absolute}.cat-button-loading>*:not(cat-spinner){visibility:hidden}.cat-button-group-first{border-top-right-radius:0;border-bottom-right-radius:0}.cat-button-group-middle{border-radius:0}.cat-button-group-last{border-top-left-radius:0;border-bottom-left-radius:0}.cat-button-group:hover{z-index:1}.cat-button-group:focus-visible{z-index:2}.cat-button-filled{background-color:rgb(var(--bg));color:rgb(var(--fill));font-weight:var(--cat-font-weight-button, 600);-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:greyscale}.cat-button-filled.cat-button-disabled{--bg:242, 244, 247;--fill:var(--cat-font-color-muted, 81, 92, 108)}.cat-button-outlined{background-color:white;box-shadow:inset 0 0 0 1px color-mix(in srgb, rgb(var(--base)) 20%, #fff);color:rgb(var(--text))}.cat-button-outlined.cat-button-disabled{--base:var(--cat-font-color-muted, 81, 92, 108);--text:var(--cat-font-color-muted, 81, 92, 108)}.cat-button-outlined:hover:not(.cat-button-disabled):not(.cat-button-loading){background-color:color-mix(in srgb, rgb(var(--base)) 10%, #fff)}.cat-button-outlined.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading){background-color:color-mix(in srgb, rgb(var(--base)) 10%, #fff)}.cat-button-outlined:active:not(.cat-button-disabled):not(.cat-button-loading){background-color:color-mix(in srgb, rgb(var(--base)) 10%, #fff)}.cat-button-text{background-color:transparent;color:rgb(var(--text));text-decoration:var(--cat-link-button-decoration, none)}.cat-button-text.cat-button-disabled{--text:var(--cat-font-color-muted, 81, 92, 108)}.cat-button-text:hover:not(.cat-button-disabled):not(.cat-button-loading){background-color:rgba(var(--base), 0.1)}.cat-button-text.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading){background-color:rgba(var(--base), 0.1)}.cat-button-link{background-color:transparent;color:rgb(var(--text))}.cat-button-link.cat-button-disabled{--text:var(--cat-font-color-muted, 81, 92, 108)}.cat-button-link:hover:not(.cat-button-disabled):not(.cat-button-loading){text-decoration:var(--cat-link-decoration-hover, underline)}.cat-button-link.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading){text-decoration:var(--cat-link-decoration-hover, underline)}.cat-button-primary{--bg:var(--cat-primary-bg, 0, 129, 148);--fill:var(--cat-primary-fill, 255, 255, 255);--text:var(--cat-primary-text, 0, 129, 148);--base:var(--cat-primary-text, 0, 129, 148)}.cat-button-primary:hover:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-primary-bg-hover, 1, 115, 132);--fill:var(--cat-primary-fill-hover, 255, 255, 255);--text:var(--cat-primary-text-hover, 1, 115, 132)}.cat-button-primary.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading),.cat-button-primary:active:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-primary-bg-active, 2, 99, 113);--fill:var(--cat-primary-fill-active, 255, 255, 255);--text:var(--cat-primary-text-active, 2, 99, 113)}.cat-button-secondary{--bg:var(--cat-secondary-bg, 105, 118, 135);--fill:var(--cat-secondary-fill, 255, 255, 255);--text:var(--cat-secondary-text, 0, 0, 0);--base:var(--cat-secondary-bg, 105, 118, 135)}.cat-button-secondary:hover:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-secondary-bg-hover, 105, 118, 135);--fill:var(--cat-secondary-fill-hover, 255, 255, 255);--text:var(--cat-secondary-text-hover, 0, 0, 0)}.cat-button-secondary.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading),.cat-button-secondary:active:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-secondary-bg-active, 105, 118, 135);--fill:var(--cat-secondary-fill-active, 255, 255, 255);--text:var(--cat-secondary-text-active, 0, 0, 0)}.cat-button-info{--bg:var(--cat-info-bg, 0, 115, 230);--fill:var(--cat-info-fill, 255, 255, 255);--text:var(--cat-info-text, 0, 115, 230);--base:var(--cat-info-text, 0, 115, 230)}.cat-button-info:hover:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-info-bg-hover, 0, 107, 227);--fill:var(--cat-info-fill-hover, 255, 255, 255);--text:var(--cat-info-text-hover, 0, 107, 227)}.cat-button-info.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading),.cat-button-info:active:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-info-bg-active, 0, 96, 223);--fill:var(--cat-info-fill-active, 255, 255, 255);--text:var(--cat-info-text-active, 0, 96, 223)}.cat-button-success{--bg:var(--cat-success-bg, 0, 132, 88);--fill:var(--cat-success-fill, 255, 255, 255);--text:var(--cat-success-text, 0, 132, 88);--base:var(--cat-success-text, 0, 132, 88)}.cat-button-success:hover:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-success-bg-hover, 0, 117, 78);--fill:var(--cat-success-fill-hover, 255, 255, 255);--text:var(--cat-success-text-hover, 0, 117, 78)}.cat-button-success.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading),.cat-button-success:active:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-success-bg-active, 0, 105, 70);--fill:var(--cat-success-fill-active, 255, 255, 255);--text:var(--cat-success-text-active, 0, 105, 70)}.cat-button-warning{--bg:var(--cat-warning-bg, 255, 206, 128);--fill:var(--cat-warning-fill, 0, 0, 0);--text:var(--cat-warning-text, 159, 97, 0);--base:var(--cat-warning-text, 159, 97, 0)}.cat-button-warning:hover:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-warning-bg-hover, 255, 214, 148);--fill:var(--cat-warning-fill-hover, 0, 0, 0);--text:var(--cat-warning-text-hover, 159, 97, 0)}.cat-button-warning.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading),.cat-button-warning:active:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-warning-bg-active, 255, 222, 168);--fill:var(--cat-warning-fill-active, 0, 0, 0);--text:var(--cat-warning-text-active, 159, 97, 0)}.cat-button-danger{--bg:var(--cat-danger-bg, 217, 52, 13);--fill:var(--cat-danger-fill, 255, 255, 255);--text:var(--cat-danger-text, 217, 52, 13);--base:var(--cat-danger-text, 217, 52, 13)}.cat-button-danger:hover:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-danger-bg-hover, 194, 46, 11);--fill:var(--cat-danger-fill-hover, 255, 255, 255);--text:var(--cat-danger-text-hover, 194, 46, 11)}.cat-button-danger.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading),.cat-button-danger:active:not(.cat-button-disabled):not(.cat-button-loading){--bg:var(--cat-danger-bg-active, 174, 42, 10);--fill:var(--cat-danger-fill-active, 255, 255, 255);--text:var(--cat-danger-text-active, 174, 42, 10)}:host(.cat-button-pull:not([size])){margin:-0.625rem -0.75rem}:host(.cat-button-pull-h:not([size])){margin-left:-0.75rem;margin-right:-0.75rem}:host(.cat-button-pull-v:not([size])){margin-top:-0.625rem;margin-bottom:-0.625rem}:host(.cat-button-pull-t:not([size])){margin-top:-0.625rem}:host(.cat-button-pull-l:not([size])){margin-left:-0.75rem}:host(.cat-button-pull-b:not([size])){margin-bottom:-0.625rem}:host(.cat-button-pull-r:not([size])){margin-right:-0.75rem}.cat-button-xs{min-width:1.5rem;padding:0.1875rem 0.25rem;font-size:0.875rem;line-height:1.125rem;gap:0.25rem}.cat-button-xs.cat-button-icon{width:1.5rem;height:1.5rem;padding:0}:host(.cat-button-pull[size=xs]){margin:-0.1875rem -0.25rem}:host(.cat-button-pull-h[size=xs]){margin-left:-0.25rem;margin-right:-0.25rem}:host(.cat-button-pull-v[size=xs]){margin-top:-0.1875rem;margin-bottom:-0.1875rem}:host(.cat-button-pull-t[size=xs]){margin-top:-0.1875rem}:host(.cat-button-pull-l[size=xs]){margin-left:-0.25rem}:host(.cat-button-pull-b[size=xs]){margin-bottom:-0.1875rem}:host(.cat-button-pull-r[size=xs]){margin-right:-0.25rem}.cat-button-s{min-width:2rem;padding:0.375rem 0.5rem;font-size:0.9375rem;line-height:1.25rem;gap:0.25rem}.cat-button-s cat-icon{margin-top:-0.125rem;margin-bottom:-0.125rem}.cat-button-s.cat-button-icon{width:2rem;height:2rem;padding:0}:host(.cat-button-pull[size=s]){margin:-0.375rem -0.5rem}:host(.cat-button-pull-h[size=s]){margin-left:-0.5rem;margin-right:-0.5rem}:host(.cat-button-pull-v[size=s]){margin-top:-0.375rem;margin-bottom:-0.375rem}:host(.cat-button-pull-t[size=s]){margin-top:-0.375rem}:host(.cat-button-pull-l[size=s]){margin-left:-0.5rem}:host(.cat-button-pull-b[size=s]){margin-bottom:-0.375rem}:host(.cat-button-pull-r[size=s]){margin-right:-0.5rem}.cat-button-m{min-width:2.5rem;padding:0.625rem 0.75rem;font-size:0.9375rem;line-height:1.25rem;gap:0.25rem}.cat-button-m cat-icon{margin-top:-0.125rem;margin-bottom:-0.125rem}.cat-button-m.cat-button-icon{width:2.5rem;height:2.5rem;padding:0}:host(.cat-button-pull[size=m]){margin:-0.625rem -0.75rem}:host(.cat-button-pull-h[size=m]){margin-left:-0.75rem;margin-right:-0.75rem}:host(.cat-button-pull-v[size=m]){margin-top:-0.625rem;margin-bottom:-0.625rem}:host(.cat-button-pull-t[size=m]){margin-top:-0.625rem}:host(.cat-button-pull-l[size=m]){margin-left:-0.75rem}:host(.cat-button-pull-b[size=m]){margin-bottom:-0.625rem}:host(.cat-button-pull-r[size=m]){margin-right:-0.75rem}.cat-button-l{min-width:3rem;padding:0.875rem 1rem;font-size:0.9375rem;line-height:1.25rem;gap:0.5rem}.cat-button-l cat-icon{margin-top:-0.125rem;margin-bottom:-0.125rem}.cat-button-l.cat-button-icon{width:3rem;height:3rem;padding:0}:host(.cat-button-pull[size=l]){margin:-0.875rem -1rem}:host(.cat-button-pull-h[size=l]){margin-left:-1rem;margin-right:-1rem}:host(.cat-button-pull-v[size=l]){margin-top:-0.875rem;margin-bottom:-0.875rem}:host(.cat-button-pull-t[size=l]){margin-top:-0.875rem}:host(.cat-button-pull-l[size=l]){margin-left:-1rem}:host(.cat-button-pull-b[size=l]){margin-bottom:-0.875rem}:host(.cat-button-pull-r[size=l]){margin-right:-1rem}.cat-button-xl{min-width:3.5rem;padding:1rem 1.25rem;font-size:1.125rem;line-height:1.5rem;gap:0.75rem}.cat-button-xl.cat-button-icon{width:3.5rem;height:3.5rem;padding:0}:host(.cat-button-pull[size=xl]){margin:-1rem -1.25rem}:host(.cat-button-pull-h[size=xl]){margin-left:-1.25rem;margin-right:-1.25rem}:host(.cat-button-pull-v[size=xl]){margin-top:-1rem;margin-bottom:-1rem}:host(.cat-button-pull-t[size=xl]){margin-top:-1rem}:host(.cat-button-pull-l[size=xl]){margin-left:-1.25rem}:host(.cat-button-pull-b[size=xl]){margin-bottom:-1rem}:host(.cat-button-pull-r[size=xl]){margin-right:-1.25rem}:host(.cat-tab)::part(button){padding:1.125rem 0.75rem;--cat-secondary-bg:transparent;--cat-primary-text:transparent;--cat-danger-text:transparent}:host(.cat-tab)::part(content)::before{content:attr(data-text);content:attr(data-text)/\"\";height:0;visibility:hidden;overflow:hidden;user-select:none;pointer-events:none;font-weight:700}:host(.cat-text-left) .cat-button{justify-content:left;text-align:left}:host(.cat-text-right) .cat-button{justify-content:right;text-align:right}:host(.cat-nav-item){width:100%}:host(.cat-nav-item) .cat-button{box-shadow:none;justify-content:left;gap:0.5rem}:host(.cat-nav-item) .cat-button:focus-visible{outline-offset:-2px}:host(.cat-time-format) .cat-button{border-radius:0}:host(.cat-date-toggle) .cat-button,:host(.cat-time-toggle) .cat-button{margin-left:-1px;border-top-left-radius:0;border-bottom-left-radius:0}:host(.cat-date-item) .cat-button:hover,:host(.cat-date-toggle) .cat-button:hover,:host(.cat-time-format) .cat-button:hover,:host(.cat-time-toggle) .cat-button:hover{z-index:1}:host(.cat-date-item) .cat-button:focus-visible,:host(.cat-date-toggle) .cat-button:focus-visible,:host(.cat-time-format) .cat-button:focus-visible,:host(.cat-time-toggle) .cat-button:focus-visible{z-index:2}:host(.cat-date-item) .cat-button{padding:0;min-width:2rem;max-height:3rem;aspect-ratio:1}:host(.date-start:not(.date-end)) .cat-button{border-top-right-radius:0;border-bottom-right-radius:0}:host(.date-end:not(.date-start)) .cat-button{border-top-left-radius:0;border-bottom-left-radius:0}";
20
20
  const CatButtonStyle0 = catButtonCss;
21
21
 
22
22
  const CatButton = /*@__PURE__*/ pro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EAAC,QAAQ,GAAY,GAAG,IAAI;YACrG,IAAI,CAAC,YAAY,IACf,gBAAU,IAAI,EAAE,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,QAAQ,GAAa,KAE3D,YAAM,KAAK,EAAC,oBAAoB,EAAC,IAAI,EAAC,SAAS,KAAK,IAAI,CAAC,uBAAuB,IAC9E,YAAM,KAAK,EAAC,0BAA0B,IACpC,eAAa,CACR,CACF,CACR;YACD,IAAI,CAAC,aAAa,GAAG,gBAAU,IAAI,EAAE,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,QAAQ,EAAE,IAAI,EAAC,QAAQ,GAAY,GAAG,IAAI;YACrG,IAAI,CAAC,OAAO,GAAG,mBAAa,IAAI,EAAE,IAAI,CAAC,WAAW,GAAgB,GAAG,IAAI;SAC1E,CAAC;KACH;IAEO,OAAO,CAAC,KAAiB;QAC/B,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;KAC3B;IAEO,OAAO,CAAC,KAAiB;QAC/B,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;KAC3B;IAEO,MAAM,CAAC,KAAiB;QAC9B,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;KAC1B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":[],"sources":["src/utils/find-closest.ts","src/components/cat-button/cat-button.scss?tag=cat-button&encapsulation=shadow","src/components/cat-button/cat-button.tsx"],"sourcesContent":["/**\n * Find the closest parent element matching the given selector while traversing\n * up the DOM tree (including Shadow DOM).\n */\nexport function findClosest(selector: string, element: Element | ShadowRoot): Element | null {\n if (element instanceof Element && element.matches(selector)) {\n return element;\n }\n\n // Search in parent element or Shadow DOM host\n const nextElement =\n element instanceof ShadowRoot ? element.host : element.parentElement || (element.getRootNode() as ShadowRoot).host;\n return nextElement ? findClosest(selector, nextElement) : null;\n}\n","@use 'variables' as *;\n@use 'mixins' as *;\n@use 'sass:map';\n\n$button-sizes: (\n 'xl': 3.5rem,\n 'l': 3rem,\n 'm': 2.5rem,\n 's': 2rem,\n 'xs': 1.5rem\n);\n\n:host {\n display: inline-block;\n max-width: 100%;\n vertical-align: middle;\n @include cat-select(none);\n}\n\n:host([hidden]) {\n display: none;\n}\n\n:host([data-button-group='middle']),\n:host([data-button-group='last']) {\n margin-left: -1px;\n}\n\n.cat-button {\n position: relative;\n font: inherit;\n display: flex;\n align-items: center;\n justify-content: center;\n border: none;\n border-radius: cat-border-radius('m');\n text-decoration: none;\n width: 100%;\n box-sizing: border-box;\n cursor: pointer;\n transition:\n color cat-token('time.transition.s') linear,\n border-color cat-token('time.transition.s') linear,\n background-color cat-token('time.transition.s') linear,\n box-shadow cat-token('time.transition.s') linear;\n\n &:focus-visible {\n outline: 2px solid cat-token('color.ui.border.focus');\n outline-offset: 1px;\n }\n}\n\n// ----- content\n\n.cat-button-content {\n display: flex;\n flex-direction: column;\n min-width: 0;\n\n .cat-button-empty & {\n display: none;\n }\n}\n\n.cat-button-content-inner {\n @include cat-break-word;\n\n .cat-button-ellipsed & {\n @include cat-ellipsis;\n }\n}\n\n// ----- disabled\n\n.cat-button-disabled {\n cursor: not-allowed;\n}\n\n// ----- round\n\n.cat-button-round {\n border-radius: 10rem;\n}\n\n// ----- loading\n\n.cat-button-loading {\n cursor: default;\n\n cat-spinner {\n position: absolute;\n }\n\n > *:not(cat-spinner) {\n visibility: hidden;\n }\n}\n\n// ----- group button\n\n.cat-button-group {\n &-first {\n border-top-right-radius: 0;\n border-bottom-right-radius: 0;\n }\n\n &-middle {\n border-radius: 0;\n }\n\n &-last {\n border-top-left-radius: 0;\n border-bottom-left-radius: 0;\n }\n\n &:hover {\n z-index: 1;\n }\n\n &:focus-visible {\n z-index: 2;\n }\n}\n\n// ----- theme\n\n.cat-button-filled {\n background-color: cat-token-wrap(var(--bg));\n color: cat-token-wrap(var(--fill));\n font-weight: var(--cat-font-weight-button, 600);\n @include cat-font-smooth;\n\n &.cat-button-disabled {\n --bg: #{cat-token('color.ui.background.muted', $wrap: false)};\n --fill: #{cat-token('color.ui.font.muted', $wrap: false)};\n }\n}\n\n.cat-button-outlined {\n background-color: cat-token('color.ui.background.surface');\n box-shadow: inset 0 0 0 1px color-mix(in srgb, cat-token-wrap(var(--base)) 20%, #fff);\n color: cat-token-wrap(var(--text));\n\n &.cat-button-disabled {\n --base: #{cat-token('color.ui.font.muted', $wrap: false)};\n --text: #{cat-token('color.ui.font.muted', $wrap: false)};\n }\n\n &:hover:not(.cat-button-disabled):not(.cat-button-loading) {\n background-color: color-mix(in srgb, cat-token-wrap(var(--base)) 10%, #fff);\n }\n\n &.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading) {\n background-color: color-mix(in srgb, cat-token-wrap(var(--base)) 10%, #fff);\n }\n\n &:active:not(.cat-button-disabled):not(.cat-button-loading) {\n background-color: color-mix(in srgb, cat-token-wrap(var(--base)) 10%, #fff);\n }\n}\n\n.cat-button-text {\n background-color: transparent;\n color: cat-token-wrap(var(--text));\n text-decoration: cat-token('font.decoration.linkButton');\n\n &.cat-button-disabled {\n --text: #{cat-token('color.ui.font.muted', $wrap: false)};\n }\n\n &:hover:not(.cat-button-disabled):not(.cat-button-loading) {\n background-color: rgba(var(--base), 0.1);\n }\n\n &.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading) {\n background-color: rgba(var(--base), 0.1);\n }\n}\n\n.cat-button-link {\n background-color: transparent;\n color: cat-token-wrap(var(--text));\n\n &.cat-button-disabled {\n --text: #{cat-token('color.ui.font.muted', $wrap: false)};\n }\n\n &:hover:not(.cat-button-disabled):not(.cat-button-loading) {\n text-decoration: cat-token('font.decoration.linkHover');\n }\n\n &.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading) {\n text-decoration: cat-token('font.decoration.linkHover');\n }\n}\n\n@mixin theme($theme) {\n .cat-button-#{$theme} {\n --bg: #{cat-token('color.theme.#{$theme}.bg', $wrap: false)};\n --fill: #{cat-token('color.theme.#{$theme}.fill', $wrap: false)};\n --text: #{cat-token('color.theme.#{$theme}.text', $wrap: false)};\n @if $theme == 'secondary' {\n --base: #{cat-token('color.theme.#{$theme}.bg', $wrap: false)};\n } @else {\n --base: #{cat-token('color.theme.#{$theme}.text', $wrap: false)};\n }\n\n &:hover:not(.cat-button-disabled):not(.cat-button-loading) {\n --bg: #{cat-token('color.theme.#{$theme}.bgHover', $wrap: false)};\n --fill: #{cat-token('color.theme.#{$theme}.fillHover', $wrap: false)};\n --text: #{cat-token('color.theme.#{$theme}.textHover', $wrap: false)};\n }\n\n &.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading),\n &:active:not(.cat-button-disabled):not(.cat-button-loading) {\n --bg: #{cat-token('color.theme.#{$theme}.bgActive', $wrap: false)};\n --fill: #{cat-token('color.theme.#{$theme}.fillActive', $wrap: false)};\n --text: #{cat-token('color.theme.#{$theme}.textActive', $wrap: false)};\n }\n }\n}\n\n@include theme('primary');\n@include theme('secondary');\n@include theme('info');\n@include theme('success');\n@include theme('warning');\n@include theme('danger');\n\n// ----- size\n\n@mixin size($size, $fontSize, $padding, $gap: 0.25rem) {\n $-line-height: cat-body-line-height($fontSize);\n\n $-total-height: map.get($button-sizes, $size);\n $-padding-v: ($-total-height - $-line-height) * 0.5;\n $-padding-h: $padding;\n\n .cat-button-#{$size} {\n min-width: map.get($button-sizes, $size);\n padding: $-padding-v $-padding-h;\n @include cat-body($fontSize, null);\n gap: $gap;\n\n // normalize icon size for line height\n @if $fontSize == 'm' {\n cat-icon {\n margin-top: -0.125rem;\n margin-bottom: -0.125rem;\n }\n }\n\n &.cat-button-icon {\n width: $-total-height;\n height: $-total-height;\n padding: 0;\n }\n }\n\n :host(.cat-button-pull[size='#{$size}']) {\n margin: $-padding-v * -1 $-padding-h * -1;\n }\n\n :host(.cat-button-pull-h[size='#{$size}']) {\n margin-left: $-padding-h * -1;\n margin-right: $-padding-h * -1;\n }\n\n :host(.cat-button-pull-v[size='#{$size}']) {\n margin-top: $-padding-v * -1;\n margin-bottom: $-padding-v * -1;\n }\n\n :host(.cat-button-pull-t[size='#{$size}']) {\n margin-top: $-padding-v * -1;\n }\n\n :host(.cat-button-pull-l[size='#{$size}']) {\n margin-left: $-padding-h * -1;\n }\n\n :host(.cat-button-pull-b[size='#{$size}']) {\n margin-bottom: $-padding-v * -1;\n }\n\n :host(.cat-button-pull-r[size='#{$size}']) {\n margin-right: $-padding-h * -1;\n }\n}\n\n:host(.cat-button-pull:not([size])) {\n margin: -0.625rem -0.75rem;\n}\n\n:host(.cat-button-pull-h:not([size])) {\n margin-left: -0.75rem;\n margin-right: -0.75rem;\n}\n\n:host(.cat-button-pull-v:not([size])) {\n margin-top: -0.625rem;\n margin-bottom: -0.625rem;\n}\n\n:host(.cat-button-pull-t:not([size])) {\n margin-top: -0.625rem;\n}\n\n:host(.cat-button-pull-l:not([size])) {\n margin-left: -0.75rem;\n}\n\n:host(.cat-button-pull-b:not([size])) {\n margin-bottom: -0.625rem;\n}\n\n:host(.cat-button-pull-r:not([size])) {\n margin-right: -0.75rem;\n}\n\n@include size('xs', 's', 0.25rem);\n@include size('s', 'm', 0.5rem);\n@include size('m', 'm', 0.75rem);\n@include size('l', 'm', 1rem);\n@include size('xl', 'l', 1.25rem, 0.5rem);\n\n// ----- tabs\n\n:host(.cat-tab) {\n &::part(button) {\n padding: 1.125rem 0.75rem;\n --cat-secondary-bg: transparent;\n --cat-primary-text: transparent;\n --cat-danger-text: transparent;\n }\n\n &::part(content) {\n &::before {\n content: attr(data-text);\n content: attr(data-text) / '';\n height: 0;\n visibility: hidden;\n overflow: hidden;\n user-select: none;\n pointer-events: none;\n font-weight: 700;\n }\n }\n}\n\n// ----- alignment\n\n:host(.cat-text-left) .cat-button {\n justify-content: left;\n text-align: left;\n}\n\n:host(.cat-text-right) .cat-button {\n justify-content: right;\n text-align: right;\n}\n\n// ----- navigation\n\n:host(.cat-nav-item) {\n width: 100%;\n\n .cat-button {\n box-shadow: none;\n justify-content: left;\n gap: 0.5rem;\n\n &:focus-visible {\n outline-offset: -2px;\n }\n }\n}\n\n// ----- datepicker\n\n:host(.cat-time-format) {\n .cat-button {\n border-radius: 0;\n }\n}\n\n:host(.cat-date-toggle),\n:host(.cat-time-toggle) {\n .cat-button {\n margin-left: -1px;\n border-top-left-radius: 0;\n border-bottom-left-radius: 0;\n }\n}\n\n:host(.cat-date-item),\n:host(.cat-date-toggle),\n:host(.cat-time-format),\n:host(.cat-time-toggle) {\n .cat-button {\n &:hover {\n z-index: 1;\n }\n\n &:focus-visible {\n z-index: 2;\n }\n }\n}\n\n:host(.cat-date-item) {\n .cat-button {\n padding: 0;\n min-width: 2rem;\n max-height: 3rem;\n aspect-ratio: 1;\n }\n}\n\n:host(.date-start:not(.date-end)) {\n .cat-button {\n border-top-right-radius: 0;\n border-bottom-right-radius: 0;\n }\n}\n\n:host(.date-end:not(.date-start)) {\n .cat-button {\n border-top-left-radius: 0;\n border-bottom-left-radius: 0;\n }\n}\n","import { Component, Element, Event, EventEmitter, h, Host, Listen, Method, Prop, State, Watch } from '@stencil/core';\nimport { Breakpoint, Breakpoints, isBreakpoint } from '../../utils/breakpoints';\nimport { MediaMatcher } from '../../utils/media-matcher';\nimport { findClosest } from '../../utils/find-closest';\n\n/**\n * Buttons are used for interface actions. Primary style should be used only\n * once per view for main call-to-action.\n *\n * @part button - The native anchor or button element.\n * @part content - The textual content of the button.\n * @part prefix - The prefix icon.\n * @part suffix - The suffix icon.\n */\n@Component({\n tag: 'cat-button',\n styleUrl: 'cat-button.scss',\n shadow: {\n delegatesFocus: true\n }\n})\nexport class CatButton {\n private button!: HTMLButtonElement | HTMLAnchorElement;\n private mediaMatcher?: MediaMatcher;\n private mediaQueryList?: MediaQueryList;\n private mediaQueryListener?: (event: MediaQueryListEvent) => void;\n\n @Element() hostElement!: HTMLElement;\n\n @State() _iconOnly = true;\n\n @State() hasSlottedContent = false;\n\n /**\n * The rendering style of the button.\n */\n @Prop() variant: 'filled' | 'outlined' | 'text' | 'link' = 'outlined';\n\n /**\n * The color palette of the button.\n */\n @Prop() color: 'primary' | 'secondary' | 'info' | 'success' | 'warning' | 'danger' = 'secondary';\n\n /**\n * Set the button into an active state.\n */\n @Prop() active = false;\n\n /**\n * The size of the button.\n */\n @Prop() size: 'xs' | 's' | 'm' | 'l' | 'xl' = 'm';\n\n /**\n * The name of the button, which gets paired with the button's value when\n * submitted as part of a form. Corresponds with the native HTML name\n * attribute.\n */\n @Prop() name?: string;\n\n /**\n * The value of the button, which gets paired with the button's name when\n * submitted as part of a form. Corresponds with the native HTML value\n * attribute.\n */\n @Prop() value?: string;\n\n /**\n * Specifies that the button should be disabled. A disabled button is unusable\n * and un-clickable. Corresponds with the native HTML disabled attribute.\n */\n @Prop() disabled = false;\n\n /**\n * Displays the button in a loading state with a spinner. Just like a disabled\n * button, an inactive button is unusable and un-clickable. However, it\n * retains the current focus state.\n */\n @Prop() loading = false;\n\n /**\n * Allows the button to submit a form.\n */\n @Prop() submit = false;\n\n /**\n * Disables ellipse overflowing button content.\n */\n @Prop() noEllipsis = false;\n\n /**\n * Use round button edges.\n */\n @Prop() round = false;\n\n /**\n * A destination to link to, rendered in the href attribute of a link.\n */\n @Prop() url?: string;\n\n /**\n * Specifies where to open the linked document.\n */\n @Prop() urlTarget?: '_blank' | '_self';\n\n /**\n * The name of an icon to be displayed in the button.\n */\n @Prop() icon?: string;\n\n /**\n * Hide the actual button content and only display the icon.\n */\n @Prop() iconOnly: boolean | Breakpoint = false;\n\n /**\n * Display the icon on the right.\n */\n @Prop() iconRight = false;\n\n /**\n * Adds a unique identifier for the button. Please note that with this\n * particular component this ID is added inside the web component. If you need\n * an ID on the HTML element, use the regular `id` attribute instead.\n */\n @Prop() buttonId?: string;\n\n /**\n * Adds accessible label for the button that is only shown for screen\n * readers. Typically, this label text replaces the visible text on the\n * button for users who use assistive technology.\n */\n @Prop({ attribute: 'a11y-label' }) a11yLabel?: string;\n\n /**\n * Sets the `aria-current` attribute on the button.\n */\n @Prop({ attribute: 'a11y-current' }) a11yCurrent?: string;\n\n /**\n * Attributes that will be added to the native HTML button element\n */\n @Prop() nativeAttributes?: { [key: string]: string };\n\n /**\n * Attributes that will be added to the native HTML button content element\n */\n @Prop() nativeContentAttributes?: { [key: string]: string };\n\n /**\n * The index of a button that is used inside a cat-button-group component\n */\n @Prop() buttonGroupPosition?: 'first' | 'last' | 'middle';\n\n @Watch('iconOnly')\n onIconOnlyChanged(value: boolean | Breakpoint): void {\n // teardown\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n this.mediaQueryList?.removeEventListener('change', this.mediaQueryListener!);\n this.mediaQueryList = undefined;\n this.mediaQueryListener = undefined;\n // setup\n if (isBreakpoint(value)) {\n this.mediaMatcher ??= new MediaMatcher();\n this.mediaQueryList = this.mediaMatcher.matchMedia(Breakpoints[value]);\n this.mediaQueryListener = (event: MediaQueryListEvent) => (this._iconOnly = event.matches);\n this.mediaQueryList.addEventListener('change', this.mediaQueryListener);\n this._iconOnly = this.mediaQueryList.matches;\n } else {\n this._iconOnly = value;\n }\n }\n\n /**\n * Emitted when the button is clicked.\n */\n @Event() catClick!: EventEmitter<MouseEvent>;\n\n /**\n * Emitted when the button received focus.\n */\n @Event() catFocus!: EventEmitter<FocusEvent>;\n\n /**\n * Emitted when the button loses focus.\n */\n @Event() catBlur!: EventEmitter<FocusEvent>;\n\n componentWillLoad(): void {\n this.onIconOnlyChanged(this.iconOnly);\n }\n\n componentWillRender(): void {\n this.hasSlottedContent = this.hostElement.hasChildNodes();\n }\n\n @Listen('click')\n haltDisabledEvents(event: Event): void {\n if (this.disabled || this.loading) {\n event.preventDefault();\n event.stopImmediatePropagation();\n } else if (this.submit) {\n const form = findClosest('form', this.hostElement);\n if (form && form instanceof HTMLFormElement) {\n // we can't provide a submitter as it is hidden in the shadow DOM\n form.requestSubmit();\n }\n }\n }\n\n /**\n * Programmatically move focus to the button. Use this method instead of\n * `button.focus()`.\n *\n * @param options An optional object providing options to control aspects of\n * the focusing process.\n */\n @Method()\n async doFocus(options?: FocusOptions): Promise<void> {\n this.button.focus(options);\n }\n\n /**\n * Programmatically remove focus from the button. Use this method instead of\n * `button.blur()`.\n */\n @Method()\n async doBlur(): Promise<void> {\n this.button.blur();\n }\n\n /**\n * Programmatically simulate a click on the button.\n */\n @Method()\n async doClick(): Promise<void> {\n this.button.click();\n }\n\n render() {\n this.hostElement.tabIndex = Number(this.hostElement.getAttribute('tabindex')) || 0;\n if (this.url) {\n return (\n <Host data-button-group={this.buttonGroupPosition}>\n <a\n {...this.nativeAttributes}\n ref={el => (this.button = el as HTMLAnchorElement)}\n href={this.disabled ? undefined : this.url}\n target={this.urlTarget}\n aria-disabled={this.disabled ? 'true' : null}\n aria-label={this.a11yLabel}\n aria-current={this.a11yCurrent}\n id={this.buttonId}\n part=\"button\"\n class={{\n 'cat-button': true,\n 'cat-button-empty': !this.hasSlottedContent,\n 'cat-button-active': this.active,\n 'cat-button-icon': this.isIconButton,\n 'cat-button-round': this.round,\n 'cat-button-loading': this.loading,\n 'cat-button-disabled': this.disabled,\n 'cat-button-ellipsed': !this.noEllipsis && !this.isIconButton,\n [`cat-button-${this.variant}`]: Boolean(this.variant),\n [`cat-button-${this.color}`]: Boolean(this.color),\n [`cat-button-${this.size}`]: Boolean(this.size),\n [`cat-button-group-${this.buttonGroupPosition}`]: Boolean(this.buttonGroupPosition)\n }}\n onClick={this.onClick.bind(this)}\n onFocus={this.onFocus.bind(this)}\n onBlur={this.onBlur.bind(this)}\n >\n {this.content}\n </a>\n </Host>\n );\n } else {\n return (\n <Host data-button-group={this.buttonGroupPosition}>\n <button\n {...this.nativeAttributes}\n ref={el => (this.button = el as HTMLButtonElement)}\n type={this.submit ? 'submit' : 'button'}\n name={this.name}\n value={this.value}\n disabled={this.disabled}\n aria-disabled={this.disabled ? 'true' : null}\n aria-label={this.a11yLabel}\n aria-current={this.a11yCurrent}\n id={this.buttonId}\n part=\"button\"\n class={{\n 'cat-button': true,\n 'cat-button-empty': !this.hasSlottedContent,\n 'cat-button-active': this.active,\n 'cat-button-icon': this.isIconButton,\n 'cat-button-round': this.round ?? this.isIconButton,\n 'cat-button-loading': this.loading,\n 'cat-button-disabled': this.disabled,\n 'cat-button-ellipsed': !this.noEllipsis && !this.isIconButton,\n [`cat-button-${this.variant}`]: Boolean(this.variant),\n [`cat-button-${this.color}`]: Boolean(this.color),\n [`cat-button-${this.size}`]: Boolean(this.size),\n [`cat-button-group-${this.buttonGroupPosition}`]: Boolean(this.buttonGroupPosition)\n }}\n onClick={this.onClick.bind(this)}\n onFocus={this.onFocus.bind(this)}\n onBlur={this.onBlur.bind(this)}\n >\n {this.content}\n </button>\n </Host>\n );\n }\n }\n\n private get iconSize(): 'xs' | 's' | 'm' | 'l' | 'xl' {\n switch (this.size) {\n case 'xs':\n return 's';\n default:\n return 'l';\n }\n }\n\n private get spinnerSize(): 'xs' | 's' | 'm' | 'l' | 'xl' {\n switch (this.size) {\n case 'xs':\n return 'xs';\n default:\n return 'm';\n }\n }\n\n private get isIconButton() {\n return Boolean(this.icon) && this._iconOnly;\n }\n\n private get hasPrefixIcon() {\n return Boolean(this.icon) && !this._iconOnly && !this.iconRight;\n }\n\n private get hasSuffixIcon() {\n return Boolean(this.icon) && !this._iconOnly && this.iconRight;\n }\n\n private get content() {\n return [\n this.hasPrefixIcon ? <cat-icon icon={this.icon} size={this.iconSize} part=\"prefix\"></cat-icon> : null,\n this.isIconButton ? (\n <cat-icon icon={this.icon} size={this.iconSize}></cat-icon>\n ) : (\n <span class=\"cat-button-content\" part=\"content\" {...this.nativeContentAttributes}>\n <span class=\"cat-button-content-inner\">\n <slot></slot>\n </span>\n </span>\n ),\n this.hasSuffixIcon ? <cat-icon icon={this.icon} size={this.iconSize} part=\"suffix\"></cat-icon> : null,\n this.loading ? <cat-spinner size={this.spinnerSize}></cat-spinner> : null\n ];\n }\n\n private onClick(event: MouseEvent) {\n this.catClick.emit(event);\n }\n\n private onFocus(event: FocusEvent) {\n this.catFocus.emit(event);\n }\n\n private onBlur(event: FocusEvent) {\n this.catBlur.emit(event);\n }\n}\n"],"version":3}
1
+ {"file":"cat-button2.js","mappings":";;;;;AAAA;;;;SAIgB,WAAW,CAAC,QAAgB,EAAE,OAA6B;IACzE,IAAI,OAAO,YAAY,OAAO,IAAI,OAAO,CAAC,OAAO,CAAC,QAAQ,CAAC,EAAE;QAC3D,OAAO,OAAO,CAAC;KAChB;;IAGD,MAAM,WAAW,GACf,OAAO,YAAY,UAAU,GAAG,OAAO,CAAC,IAAI,GAAG,OAAO,CAAC,aAAa,IAAK,OAAO,CAAC,WAAW,EAAiB,CAAC,IAAI,CAAC;IACrH,OAAO,WAAW,GAAG,WAAW,CAAC,QAAQ,EAAE,WAAW,CAAC,GAAG,IAAI,CAAC;AACjE;;ACbA,MAAM,YAAY,GAAG,kqZAAkqZ,CAAC;AACxrZ,wBAAe,YAAY;;MCoBd,SAAS;;;;;;;;yBAQC,IAAI;iCAEI,KAAK;uBAKyB,UAAU;qBAKgB,WAAW;sBAK/E,KAAK;oBAKwB,GAAG;;;wBAoB9B,KAAK;uBAON,KAAK;sBAKN,KAAK;0BAKD,KAAK;qBAKV,KAAK;;;;wBAoBoB,KAAK;yBAK1B,KAAK;;;;;;;;IAqCzB,iBAAiB,CAAC,KAA2B;;;QAG3C,IAAI,CAAC,cAAc,EAAE,mBAAmB,CAAC,QAAQ,EAAE,IAAI,CAAC,kBAAmB,CAAC,CAAC;QAC7E,IAAI,CAAC,cAAc,GAAG,SAAS,CAAC;QAChC,IAAI,CAAC,kBAAkB,GAAG,SAAS,CAAC;;QAEpC,IAAI,YAAY,CAAC,KAAK,CAAC,EAAE;YACvB,IAAI,CAAC,YAAY,KAAjB,IAAI,CAAC,YAAY,GAAK,IAAI,YAAY,EAAE,EAAC;YACzC,IAAI,CAAC,cAAc,GAAG,IAAI,CAAC,YAAY,CAAC,UAAU,CAAC,WAAW,CAAC,K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I,EAAE,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,QAAQ,EAAE,IAAI,EAAC,QAAQ,GAAY,GAAG,IAAI;YACrG,IAAI,CAAC,YAAY,IACf,gBAAU,IAAI,EAAE,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,QAAQ,GAAa,KAE3D,YAAM,KAAK,EAAC,oBAAoB,EAAC,IAAI,EAAC,SAAS,KAAK,IAAI,CAAC,uBAAuB,IAC9E,YAAM,KAAK,EAAC,0BAA0B,IACpC,eAAa,CACR,CACF,CACR;YACD,IAAI,CAAC,aAAa,GAAG,gBAAU,IAAI,EAAE,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,IAAI,CAAC,QAAQ,EAAE,IAAI,EAAC,QAAQ,GAAY,GAAG,IAAI;YACrG,IAAI,CAAC,OAAO,GAAG,mBAAa,IAAI,EAAE,IAAI,CAAC,WAAW,GAAgB,GAAG,IAAI;SAC1E,CAAC;KACH;IAEO,OAAO,CAAC,KAAiB;QAC/B,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;KAC3B;IAEO,OAAO,CAAC,KAAiB;QAC/B,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;KAC3B;IAEO,MAAM,CAAC,KAAiB;QAC9B,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;KAC1B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","names":[],"sources":["src/utils/find-closest.ts","src/components/cat-button/cat-button.scss?tag=cat-button&encapsulation=shadow","src/components/cat-button/cat-button.tsx"],"sourcesContent":["/**\n * Find the closest parent element matching the given selector while traversing\n * up the DOM tree (including Shadow DOM).\n */\nexport function findClosest(selector: string, element: Element | ShadowRoot): Element | null {\n if (element instanceof Element && element.matches(selector)) {\n return element;\n }\n\n // Search in parent element or Shadow DOM host\n const nextElement =\n element instanceof ShadowRoot ? element.host : element.parentElement || (element.getRootNode() as ShadowRoot).host;\n return nextElement ? findClosest(selector, nextElement) : null;\n}\n","@use 'variables' as *;\n@use 'mixins' as *;\n@use 'sass:map';\n\n$button-sizes: (\n 'xl': 3.5rem,\n 'l': 3rem,\n 'm': 2.5rem,\n 's': 2rem,\n 'xs': 1.5rem\n);\n\n:host {\n display: inline-block;\n max-width: 100%;\n vertical-align: middle;\n @include cat-select(none);\n}\n\n:host([hidden]) {\n display: none;\n}\n\n:host([data-button-group='middle']),\n:host([data-button-group='last']) {\n margin-left: -1px;\n}\n\n.cat-button {\n position: relative;\n font: inherit;\n display: flex;\n align-items: center;\n justify-content: center;\n border: none;\n border-radius: cat-border-radius('m');\n text-decoration: none;\n width: 100%;\n box-sizing: border-box;\n cursor: pointer;\n transition:\n color cat-token('time.transition.s') linear,\n border-color cat-token('time.transition.s') linear,\n background-color cat-token('time.transition.s') linear,\n box-shadow cat-token('time.transition.s') linear;\n\n &:focus-visible {\n outline: 2px solid cat-token('color.ui.border.focus');\n outline-offset: 1px;\n }\n}\n\n// ----- content\n\n.cat-button-content {\n display: flex;\n flex-direction: column;\n min-width: 0;\n\n .cat-button-empty & {\n display: none;\n }\n}\n\n.cat-button-content-inner {\n @include cat-break-word;\n\n .cat-button-ellipsed & {\n @include cat-ellipsis;\n }\n}\n\n// ----- disabled\n\n.cat-button-disabled {\n cursor: not-allowed;\n}\n\n// ----- round\n\n.cat-button-round {\n border-radius: 10rem;\n}\n\n// ----- loading\n\n.cat-button-loading {\n cursor: default;\n\n cat-spinner {\n position: absolute;\n }\n\n > *:not(cat-spinner) {\n visibility: hidden;\n }\n}\n\n// ----- group button\n\n.cat-button-group {\n &-first {\n border-top-right-radius: 0;\n border-bottom-right-radius: 0;\n }\n\n &-middle {\n border-radius: 0;\n }\n\n &-last {\n border-top-left-radius: 0;\n border-bottom-left-radius: 0;\n }\n\n &:hover {\n z-index: 1;\n }\n\n &:focus-visible {\n z-index: 2;\n }\n}\n\n// ----- theme\n\n.cat-button-filled {\n background-color: cat-token-wrap(var(--bg));\n color: cat-token-wrap(var(--fill));\n font-weight: var(--cat-font-weight-button, 600);\n @include cat-font-smooth;\n\n &.cat-button-disabled {\n --bg: #{cat-token('color.ui.background.muted', $wrap: false)};\n --fill: #{cat-token('color.ui.font.muted', $wrap: false)};\n }\n}\n\n.cat-button-outlined {\n background-color: cat-token('color.ui.background.surface');\n box-shadow: inset 0 0 0 1px color-mix(in srgb, cat-token-wrap(var(--base)) 20%, #fff);\n color: cat-token-wrap(var(--text));\n\n &.cat-button-disabled {\n --base: #{cat-token('color.ui.font.muted', $wrap: false)};\n --text: #{cat-token('color.ui.font.muted', $wrap: false)};\n }\n\n &:hover:not(.cat-button-disabled):not(.cat-button-loading) {\n background-color: color-mix(in srgb, cat-token-wrap(var(--base)) 10%, #fff);\n }\n\n &.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading) {\n background-color: color-mix(in srgb, cat-token-wrap(var(--base)) 10%, #fff);\n }\n\n &:active:not(.cat-button-disabled):not(.cat-button-loading) {\n background-color: color-mix(in srgb, cat-token-wrap(var(--base)) 10%, #fff);\n }\n}\n\n.cat-button-text {\n background-color: transparent;\n color: cat-token-wrap(var(--text));\n text-decoration: cat-token('font.decoration.linkButton');\n\n &.cat-button-disabled {\n --text: #{cat-token('color.ui.font.muted', $wrap: false)};\n }\n\n &:hover:not(.cat-button-disabled):not(.cat-button-loading) {\n background-color: rgba(var(--base), 0.1);\n }\n\n &.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading) {\n background-color: rgba(var(--base), 0.1);\n }\n}\n\n.cat-button-link {\n background-color: transparent;\n color: cat-token-wrap(var(--text));\n\n &.cat-button-disabled {\n --text: #{cat-token('color.ui.font.muted', $wrap: false)};\n }\n\n &:hover:not(.cat-button-disabled):not(.cat-button-loading) {\n text-decoration: cat-token('font.decoration.linkHover');\n }\n\n &.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading) {\n text-decoration: cat-token('font.decoration.linkHover');\n }\n}\n\n@mixin theme($theme) {\n .cat-button-#{$theme} {\n --bg: #{cat-token('color.theme.#{$theme}.bg', $wrap: false)};\n --fill: #{cat-token('color.theme.#{$theme}.fill', $wrap: false)};\n --text: #{cat-token('color.theme.#{$theme}.text', $wrap: false)};\n @if $theme == 'secondary' {\n --base: #{cat-token('color.theme.#{$theme}.bg', $wrap: false)};\n } @else {\n --base: #{cat-token('color.theme.#{$theme}.text', $wrap: false)};\n }\n\n &:hover:not(.cat-button-disabled):not(.cat-button-loading) {\n --bg: #{cat-token('color.theme.#{$theme}.bgHover', $wrap: false)};\n --fill: #{cat-token('color.theme.#{$theme}.fillHover', $wrap: false)};\n --text: #{cat-token('color.theme.#{$theme}.textHover', $wrap: false)};\n }\n\n &.cat-button-active:not(.cat-button-disabled):not(.cat-button-loading),\n &:active:not(.cat-button-disabled):not(.cat-button-loading) {\n --bg: #{cat-token('color.theme.#{$theme}.bgActive', $wrap: false)};\n --fill: #{cat-token('color.theme.#{$theme}.fillActive', $wrap: false)};\n --text: #{cat-token('color.theme.#{$theme}.textActive', $wrap: false)};\n }\n }\n}\n\n@include theme('primary');\n@include theme('secondary');\n@include theme('info');\n@include theme('success');\n@include theme('warning');\n@include theme('danger');\n\n// ----- size\n\n@mixin size($size, $fontSize, $padding, $gap: 0.25rem) {\n $-line-height: cat-body-line-height($fontSize);\n\n $-total-height: map.get($button-sizes, $size);\n $-padding-v: ($-total-height - $-line-height) * 0.5;\n $-padding-h: $padding;\n\n .cat-button-#{$size} {\n min-width: map.get($button-sizes, $size);\n padding: $-padding-v $-padding-h;\n @include cat-body($fontSize, null);\n gap: $gap;\n\n // normalize icon size for line height\n @if $fontSize == 'm' {\n cat-icon {\n margin-top: -0.125rem;\n margin-bottom: -0.125rem;\n }\n }\n\n &.cat-button-icon {\n width: $-total-height;\n height: $-total-height;\n padding: 0;\n }\n }\n\n :host(.cat-button-pull[size='#{$size}']) {\n margin: $-padding-v * -1 $-padding-h * -1;\n }\n\n :host(.cat-button-pull-h[size='#{$size}']) {\n margin-left: $-padding-h * -1;\n margin-right: $-padding-h * -1;\n }\n\n :host(.cat-button-pull-v[size='#{$size}']) {\n margin-top: $-padding-v * -1;\n margin-bottom: $-padding-v * -1;\n }\n\n :host(.cat-button-pull-t[size='#{$size}']) {\n margin-top: $-padding-v * -1;\n }\n\n :host(.cat-button-pull-l[size='#{$size}']) {\n margin-left: $-padding-h * -1;\n }\n\n :host(.cat-button-pull-b[size='#{$size}']) {\n margin-bottom: $-padding-v * -1;\n }\n\n :host(.cat-button-pull-r[size='#{$size}']) {\n margin-right: $-padding-h * -1;\n }\n}\n\n:host(.cat-button-pull:not([size])) {\n margin: -0.625rem -0.75rem;\n}\n\n:host(.cat-button-pull-h:not([size])) {\n margin-left: -0.75rem;\n margin-right: -0.75rem;\n}\n\n:host(.cat-button-pull-v:not([size])) {\n margin-top: -0.625rem;\n margin-bottom: -0.625rem;\n}\n\n:host(.cat-button-pull-t:not([size])) {\n margin-top: -0.625rem;\n}\n\n:host(.cat-button-pull-l:not([size])) {\n margin-left: -0.75rem;\n}\n\n:host(.cat-button-pull-b:not([size])) {\n margin-bottom: -0.625rem;\n}\n\n:host(.cat-button-pull-r:not([size])) {\n margin-right: -0.75rem;\n}\n\n@include size('xs', 's', 0.25rem);\n@include size('s', 'm', 0.5rem);\n@include size('m', 'm', 0.75rem);\n@include size('l', 'm', 1rem, 0.5rem);\n@include size('xl', 'l', 1.25rem, 0.75rem);\n\n// ----- tabs\n\n:host(.cat-tab) {\n &::part(button) {\n padding: 1.125rem 0.75rem;\n --cat-secondary-bg: transparent;\n --cat-primary-text: transparent;\n --cat-danger-text: transparent;\n }\n\n &::part(content) {\n &::before {\n content: attr(data-text);\n content: attr(data-text) / '';\n height: 0;\n visibility: hidden;\n overflow: hidden;\n user-select: none;\n pointer-events: none;\n font-weight: 700;\n }\n }\n}\n\n// ----- alignment\n\n:host(.cat-text-left) .cat-button {\n justify-content: left;\n text-align: left;\n}\n\n:host(.cat-text-right) .cat-button {\n justify-content: right;\n text-align: right;\n}\n\n// ----- navigation\n\n:host(.cat-nav-item) {\n width: 100%;\n\n .cat-button {\n box-shadow: none;\n justify-content: left;\n gap: 0.5rem;\n\n &:focus-visible {\n outline-offset: -2px;\n }\n }\n}\n\n// ----- datepicker\n\n:host(.cat-time-format) {\n .cat-button {\n border-radius: 0;\n }\n}\n\n:host(.cat-date-toggle),\n:host(.cat-time-toggle) {\n .cat-button {\n margin-left: -1px;\n border-top-left-radius: 0;\n border-bottom-left-radius: 0;\n }\n}\n\n:host(.cat-date-item),\n:host(.cat-date-toggle),\n:host(.cat-time-format),\n:host(.cat-time-toggle) {\n .cat-button {\n &:hover {\n z-index: 1;\n }\n\n &:focus-visible {\n z-index: 2;\n }\n }\n}\n\n:host(.cat-date-item) {\n .cat-button {\n padding: 0;\n min-width: 2rem;\n max-height: 3rem;\n aspect-ratio: 1;\n }\n}\n\n:host(.date-start:not(.date-end)) {\n .cat-button {\n border-top-right-radius: 0;\n border-bottom-right-radius: 0;\n }\n}\n\n:host(.date-end:not(.date-start)) {\n .cat-button {\n border-top-left-radius: 0;\n border-bottom-left-radius: 0;\n }\n}\n","import { Component, Element, Event, EventEmitter, h, Host, Listen, Method, Prop, State, Watch } from '@stencil/core';\nimport { Breakpoint, Breakpoints, isBreakpoint } from '../../utils/breakpoints';\nimport { MediaMatcher } from '../../utils/media-matcher';\nimport { findClosest } from '../../utils/find-closest';\n\n/**\n * Buttons are used for interface actions. Primary style should be used only\n * once per view for main call-to-action.\n *\n * @part button - The native anchor or button element.\n * @part content - The textual content of the button.\n * @part prefix - The prefix icon.\n * @part suffix - The suffix icon.\n */\n@Component({\n tag: 'cat-button',\n styleUrl: 'cat-button.scss',\n shadow: {\n delegatesFocus: true\n }\n})\nexport class CatButton {\n private button!: HTMLButtonElement | HTMLAnchorElement;\n private mediaMatcher?: MediaMatcher;\n private mediaQueryList?: MediaQueryList;\n private mediaQueryListener?: (event: MediaQueryListEvent) => void;\n\n @Element() hostElement!: HTMLElement;\n\n @State() _iconOnly = true;\n\n @State() hasSlottedContent = false;\n\n /**\n * The rendering style of the button.\n */\n @Prop() variant: 'filled' | 'outlined' | 'text' | 'link' = 'outlined';\n\n /**\n * The color palette of the button.\n */\n @Prop() color: 'primary' | 'secondary' | 'info' | 'success' | 'warning' | 'danger' = 'secondary';\n\n /**\n * Set the button into an active state.\n */\n @Prop() active = false;\n\n /**\n * The size of the button.\n */\n @Prop() size: 'xs' | 's' | 'm' | 'l' | 'xl' = 'm';\n\n /**\n * The name of the button, which gets paired with the button's value when\n * submitted as part of a form. Corresponds with the native HTML name\n * attribute.\n */\n @Prop() name?: string;\n\n /**\n * The value of the button, which gets paired with the button's name when\n * submitted as part of a form. Corresponds with the native HTML value\n * attribute.\n */\n @Prop() value?: string;\n\n /**\n * Specifies that the button should be disabled. A disabled button is unusable\n * and un-clickable. Corresponds with the native HTML disabled attribute.\n */\n @Prop() disabled = false;\n\n /**\n * Displays the button in a loading state with a spinner. Just like a disabled\n * button, an inactive button is unusable and un-clickable. However, it\n * retains the current focus state.\n */\n @Prop() loading = false;\n\n /**\n * Allows the button to submit a form.\n */\n @Prop() submit = false;\n\n /**\n * Disables ellipse overflowing button content.\n */\n @Prop() noEllipsis = false;\n\n /**\n * Use round button edges.\n */\n @Prop() round = false;\n\n /**\n * A destination to link to, rendered in the href attribute of a link.\n */\n @Prop() url?: string;\n\n /**\n * Specifies where to open the linked document.\n */\n @Prop() urlTarget?: '_blank' | '_self';\n\n /**\n * The name of an icon to be displayed in the button.\n */\n @Prop() icon?: string;\n\n /**\n * Hide the actual button content and only display the icon.\n */\n @Prop() iconOnly: boolean | Breakpoint = false;\n\n /**\n * Display the icon on the right.\n */\n @Prop() iconRight = false;\n\n /**\n * Adds a unique identifier for the button. Please note that with this\n * particular component this ID is added inside the web component. If you need\n * an ID on the HTML element, use the regular `id` attribute instead.\n */\n @Prop() buttonId?: string;\n\n /**\n * Adds accessible label for the button that is only shown for screen\n * readers. Typically, this label text replaces the visible text on the\n * button for users who use assistive technology.\n */\n @Prop({ attribute: 'a11y-label' }) a11yLabel?: string;\n\n /**\n * Sets the `aria-current` attribute on the button.\n */\n @Prop({ attribute: 'a11y-current' }) a11yCurrent?: string;\n\n /**\n * Attributes that will be added to the native HTML button element\n */\n @Prop() nativeAttributes?: { [key: string]: string };\n\n /**\n * Attributes that will be added to the native HTML button content element\n */\n @Prop() nativeContentAttributes?: { [key: string]: string };\n\n /**\n * The index of a button that is used inside a cat-button-group component\n */\n @Prop() buttonGroupPosition?: 'first' | 'last' | 'middle';\n\n @Watch('iconOnly')\n onIconOnlyChanged(value: boolean | Breakpoint): void {\n // teardown\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n this.mediaQueryList?.removeEventListener('change', this.mediaQueryListener!);\n this.mediaQueryList = undefined;\n this.mediaQueryListener = undefined;\n // setup\n if (isBreakpoint(value)) {\n this.mediaMatcher ??= new MediaMatcher();\n this.mediaQueryList = this.mediaMatcher.matchMedia(Breakpoints[value]);\n this.mediaQueryListener = (event: MediaQueryListEvent) => (this._iconOnly = event.matches);\n this.mediaQueryList.addEventListener('change', this.mediaQueryListener);\n this._iconOnly = this.mediaQueryList.matches;\n } else {\n this._iconOnly = value;\n }\n }\n\n /**\n * Emitted when the button is clicked.\n */\n @Event() catClick!: EventEmitter<MouseEvent>;\n\n /**\n * Emitted when the button received focus.\n */\n @Event() catFocus!: EventEmitter<FocusEvent>;\n\n /**\n * Emitted when the button loses focus.\n */\n @Event() catBlur!: EventEmitter<FocusEvent>;\n\n componentWillLoad(): void {\n this.onIconOnlyChanged(this.iconOnly);\n }\n\n componentWillRender(): void {\n this.hasSlottedContent = this.hostElement.hasChildNodes();\n }\n\n @Listen('click')\n haltDisabledEvents(event: Event): void {\n if (this.disabled || this.loading) {\n event.preventDefault();\n event.stopImmediatePropagation();\n } else if (this.submit) {\n const form = findClosest('form', this.hostElement);\n if (form && form instanceof HTMLFormElement) {\n // we can't provide a submitter as it is hidden in the shadow DOM\n form.requestSubmit();\n }\n }\n }\n\n /**\n * Programmatically move focus to the button. Use this method instead of\n * `button.focus()`.\n *\n * @param options An optional object providing options to control aspects of\n * the focusing process.\n */\n @Method()\n async doFocus(options?: FocusOptions): Promise<void> {\n this.button.focus(options);\n }\n\n /**\n * Programmatically remove focus from the button. Use this method instead of\n * `button.blur()`.\n */\n @Method()\n async doBlur(): Promise<void> {\n this.button.blur();\n }\n\n /**\n * Programmatically simulate a click on the button.\n */\n @Method()\n async doClick(): Promise<void> {\n this.button.click();\n }\n\n render() {\n this.hostElement.tabIndex = Number(this.hostElement.getAttribute('tabindex')) || 0;\n if (this.url) {\n return (\n <Host data-button-group={this.buttonGroupPosition}>\n <a\n {...this.nativeAttributes}\n ref={el => (this.button = el as HTMLAnchorElement)}\n href={this.disabled ? undefined : this.url}\n target={this.urlTarget}\n aria-disabled={this.disabled ? 'true' : null}\n aria-label={this.a11yLabel}\n aria-current={this.a11yCurrent}\n id={this.buttonId}\n part=\"button\"\n class={{\n 'cat-button': true,\n 'cat-button-empty': !this.hasSlottedContent,\n 'cat-button-active': this.active,\n 'cat-button-icon': this.isIconButton,\n 'cat-button-round': this.round,\n 'cat-button-loading': this.loading,\n 'cat-button-disabled': this.disabled,\n 'cat-button-ellipsed': !this.noEllipsis && !this.isIconButton,\n [`cat-button-${this.variant}`]: Boolean(this.variant),\n [`cat-button-${this.color}`]: Boolean(this.color),\n [`cat-button-${this.size}`]: Boolean(this.size),\n [`cat-button-group-${this.buttonGroupPosition}`]: Boolean(this.buttonGroupPosition)\n }}\n onClick={this.onClick.bind(this)}\n onFocus={this.onFocus.bind(this)}\n onBlur={this.onBlur.bind(this)}\n >\n {this.content}\n </a>\n </Host>\n );\n } else {\n return (\n <Host data-button-group={this.buttonGroupPosition}>\n <button\n {...this.nativeAttributes}\n ref={el => (this.button = el as HTMLButtonElement)}\n type={this.submit ? 'submit' : 'button'}\n name={this.name}\n value={this.value}\n disabled={this.disabled}\n aria-disabled={this.disabled ? 'true' : null}\n aria-label={this.a11yLabel}\n aria-current={this.a11yCurrent}\n id={this.buttonId}\n part=\"button\"\n class={{\n 'cat-button': true,\n 'cat-button-empty': !this.hasSlottedContent,\n 'cat-button-active': this.active,\n 'cat-button-icon': this.isIconButton,\n 'cat-button-round': this.round ?? this.isIconButton,\n 'cat-button-loading': this.loading,\n 'cat-button-disabled': this.disabled,\n 'cat-button-ellipsed': !this.noEllipsis && !this.isIconButton,\n [`cat-button-${this.variant}`]: Boolean(this.variant),\n [`cat-button-${this.color}`]: Boolean(this.color),\n [`cat-button-${this.size}`]: Boolean(this.size),\n [`cat-button-group-${this.buttonGroupPosition}`]: Boolean(this.buttonGroupPosition)\n }}\n onClick={this.onClick.bind(this)}\n onFocus={this.onFocus.bind(this)}\n onBlur={this.onBlur.bind(this)}\n >\n {this.content}\n </button>\n </Host>\n );\n }\n }\n\n private get iconSize(): 'xs' | 's' | 'm' | 'l' | 'xl' {\n switch (this.size) {\n case 'xs':\n return 's';\n default:\n return 'l';\n }\n }\n\n private get spinnerSize(): 'xs' | 's' | 'm' | 'l' | 'xl' {\n switch (this.size) {\n case 'xs':\n return 'xs';\n default:\n return 'm';\n }\n }\n\n private get isIconButton() {\n return Boolean(this.icon) && this._iconOnly;\n }\n\n private get hasPrefixIcon() {\n return Boolean(this.icon) && !this._iconOnly && !this.iconRight;\n }\n\n private get hasSuffixIcon() {\n return Boolean(this.icon) && !this._iconOnly && this.iconRight;\n }\n\n private get content() {\n return [\n this.hasPrefixIcon ? <cat-icon icon={this.icon} size={this.iconSize} part=\"prefix\"></cat-icon> : null,\n this.isIconButton ? (\n <cat-icon icon={this.icon} size={this.iconSize}></cat-icon>\n ) : (\n <span class=\"cat-button-content\" part=\"content\" {...this.nativeContentAttributes}>\n <span class=\"cat-button-content-inner\">\n <slot></slot>\n </span>\n </span>\n ),\n this.hasSuffixIcon ? <cat-icon icon={this.icon} size={this.iconSize} part=\"suffix\"></cat-icon> : null,\n this.loading ? <cat-spinner size={this.spinnerSize}></cat-spinner> : null\n ];\n }\n\n private onClick(event: MouseEvent) {\n this.catClick.emit(event);\n }\n\n private onFocus(event: FocusEvent) {\n this.catFocus.emit(event);\n }\n\n private onBlur(event: FocusEvent) {\n this.catBlur.emit(event);\n }\n}\n"],"version":3}
@@ -62,14 +62,13 @@ const CatCheckbox = /*@__PURE__*/ proxyCustomElement(class CatCheckbox extends H
62
62
  this.input.blur();
63
63
  }
64
64
  render() {
65
- this.hostElement.tabIndex = Number(this.hostElement.getAttribute('tabindex')) || 0;
66
- return (h(Host, { key: 'ab6bd1bb1b74998b5202e57ba6b32da9dd0135c8' }, h("label", { key: '5554806b29bbdea219869d043f9c41469390720d', htmlFor: this.id, class: {
65
+ return (h(Host, { key: '8c0eb5c93eb3c1afd12a482cef1d00b693aaaa6b' }, h("label", { key: 'b547cfd3a6aec8c312f4cfbb12304749f4bb130a', htmlFor: this.id, class: {
67
66
  'is-hidden': this.labelHidden,
68
67
  'is-disabled': this.disabled,
69
68
  'label-left': this.labelLeft,
70
69
  'align-center': this.alignment === 'center',
71
70
  'align-end': this.alignment === 'bottom'
72
- } }, h("input", { key: 'cccc0ef488d141b6eb4859fcc58433174f7ce21b', ...this.nativeAttributes, part: "input", ref: el => (this.input = el), id: this.id, type: "checkbox", name: this.name, value: this.value, checked: this.checked, required: this.required, disabled: this.disabled, indeterminate: this.indeterminate, onInput: this.onInput.bind(this), onFocus: this.onFocus.bind(this), onBlur: this.onBlur.bind(this), "aria-describedby": this.hasHint ? this.id + '-hint' : undefined }), h("span", { key: 'c6c568ebc80618b4acc3e28793c1844284d4a831', class: "box", "aria-hidden": "true" }, h("svg", { key: '5c8c2ae933fecab8b9c826ef2493b2dec129f49c', class: "check", viewBox: "0 0 12 10" }, h("polyline", { key: '4ed298a1e0377c4ca771940b7da867c5e72017af', points: "1.5 6 4.5 9 10.5 1" })), h("svg", { key: '4ca83993e600c99f4651333ce9f86c0f2b85754a', class: "dash", viewBox: "0 0 12 10" }, h("polyline", { key: '32d6a98f6247ce1605baa1c0fcb66325300d0118', points: "1.5 5 10.5 5" }))), h("span", { key: 'cdf8717a98a756e4ae204d08fd186cf49ea7d101', class: { label: true, 'label-wrapper': !this.hasSlottedLabel }, part: "label" }, (this.hasSlottedLabel && h("slot", { key: '967c87e44e4bb119b46ae70edf2eb47d63177a90', name: "label" })) || this.label, h("span", { key: '04a85b99e78e8db04e4080d54ff1690051ce2a50', class: "label-metadata" }, !this.required && (this.requiredMarker ?? 'optional').startsWith('optional') && (h("span", { key: 'caf9a8682262079edf06957ca2a2c9d14abc9130', class: "label-optional", "aria-hidden": "true" }, "(", catI18nRegistry.t('input.optional'), ")")), this.required && this.requiredMarker?.startsWith('required') && (h("span", { key: 'd073fb49348c5561984c73bafbf7fd7e17f01ba5', class: "label-optional", "aria-hidden": "true" }, "(", catI18nRegistry.t('input.required'), ")"))))), this.hasHint && (h("div", { key: '9fb0531829e03683accb07fdc675975feb709577', class: { 'hint-wrapper': true, 'label-left': this.labelLeft } }, h("div", { key: 'e72ad8ae3b9048ef6a58d74eb9593d511fad03c6', class: "box-placeholder" }), h(CatFormHint, { key: 'b10a09f94fe13f1cc7602191c0e7b3d2066a8364', id: this.id, hint: this.hint, slottedHint: this.hasSlottedHint && h("slot", { name: "hint" }) })))));
71
+ } }, h("input", { key: 'ba2e7b5af1943fe8c6ad4489edc2a0973ddda065', ...this.nativeAttributes, part: "input", ref: el => (this.input = el), id: this.id, type: "checkbox", name: this.name, value: this.value, checked: this.checked, required: this.required, disabled: this.disabled, indeterminate: this.indeterminate, onInput: this.onInput.bind(this), onFocus: this.onFocus.bind(this), onBlur: this.onBlur.bind(this), "aria-describedby": this.hasHint ? this.id + '-hint' : undefined }), h("span", { key: '9df445a24845020c80a0f52383de1720dd7d867e', class: "box", "aria-hidden": "true" }, h("svg", { key: '30000e8be49bec99d68a543963cf351c7ff3fd7c', class: "check", viewBox: "0 0 12 10" }, h("polyline", { key: '793e1b85f1df92af1168696f5470c74b4ac56ebb', points: "1.5 6 4.5 9 10.5 1" })), h("svg", { key: '28519cf606fd5c4f1ce87e6682c49192d9c7ccdd', class: "dash", viewBox: "0 0 12 10" }, h("polyline", { key: 'ef38c2175504c86bbcc930ab4e3e259600675849', points: "1.5 5 10.5 5" }))), h("span", { key: '34b01f1d76b7d840245822340e6cf15a3745d948', class: { label: true, 'label-wrapper': !this.hasSlottedLabel }, part: "label" }, (this.hasSlottedLabel && h("slot", { key: '088699ea29bf4fc53b784b798afc698f848343d2', name: "label" })) || this.label, h("span", { key: '4e4dfcc4b985ab4962fe42e88c09abd60170e5f2', class: "label-metadata" }, !this.required && (this.requiredMarker ?? 'optional').startsWith('optional') && (h("span", { key: '5762ff2168f759ff2fd0d566eb99bd23e9a3154d', class: "label-optional", "aria-hidden": "true" }, "(", catI18nRegistry.t('input.optional'), ")")), this.required && this.requiredMarker?.startsWith('required') && (h("span", { key: '11b3596d3b6e7ae1b4356fc029f861e2407ff9ab', class: "label-optional", "aria-hidden": "true" }, "(", catI18nRegistry.t('input.required'), ")"))))), this.hasHint && (h("div", { key: '8814d349c83078c76a948bd91fb66a593824ba87', class: { 'hint-wrapper': true, 'label-left': this.labelLeft } }, h("div", { key: '99fc171926a6d467140824b22fb3d66848c9a1a3', class: "box-placeholder" }), h(CatFormHint, { key: '09b2a51545a4d0f731f0d42930c9d18f5e0cb512', id: this.id, hint: this.hint, slottedHint: this.hasSlottedHint && h("slot", { name: "hint" }) })))));
73
72
  }
74
73
  get hasHint() {
75
74
  return !!this.hint || !!this.hasSlottedHint;
@@ -89,10 +88,9 @@ const CatCheckbox = /*@__PURE__*/ proxyCustomElement(class CatCheckbox extends H
89
88
  updateResolved() {
90
89
  this.resolvedValue = this.checked ? (this.value ?? true) : (this.noValue ?? false);
91
90
  }
92
- static get delegatesFocus() { return true; }
93
91
  get hostElement() { return this; }
94
92
  static get style() { return CatCheckboxStyle0; }
95
- }, [17, "cat-checkbox", {
93
+ }, [1, "cat-checkbox", {
96
94
  "checked": [1028],
97
95
  "indeterminate": [1028],
98
96
  "disabled": [4],