UNPKG

@utrecht/web-component-library-stencil

Version:

Stencil component library bundle for the Municipality of Utrecht based on the NL Design System architecture

194 lines (182 loc) 313 kB
import { r as registerInstance, h, c as createEvent, g as getElement, H as Host } from './index-6be72d1f.js'; import { c as clsx } from './clsx-eca3fadc.js'; const actionGroupCss = ".utrecht-action-group{align-items:baseline;background-color:var(--utrecht-action-group-background-color);break-inside:avoid;column-gap:var(--utrecht-action-group-column-gap, 1em);display:flex;flex-wrap:wrap;margin-block-end:calc(var(--utrecht-space-around, 0) * var(--utrecht-action-group-margin-block-end, 0));margin-block-start:calc(var(--utrecht-space-around, 0) * var(--utrecht-action-group-margin-block-start, 0));min-block-size:var(--utrecht-button-block-size);padding-block-end:var(--utrecht-action-group-padding-block-end);padding-block-start:var(--utrecht-action-group-padding-block-start);row-gap:var(--utrecht-action-group-row-gap, 1em)}.utrecht-action-group--distanced{--utrecht-space-around:1}.utrecht-action-group__link-button--row,.utrecht-action-group--row .utrecht-link-button,.utrecht-action-group:not(.utrecht-action-group--column) .utrecht-link-button{--utrecht-button-padding-inline-end:0;--utrecht-button-padding-inline-start:0}.utrecht-action-group--column{flex-direction:column}.utrecht-action-group--column-stretch{flex-direction:column;--utrecht-button-max-inline-size:none;align-items:stretch;inline-size:fit-content}:host{display:block}:host([hidden]){display:none !important}"; const UtrechtActionGroupStyle0 = actionGroupCss; const actionGroup = class { constructor(hostRef) { registerInstance(this, hostRef); this.direction = undefined; } render() { const { direction } = this; return (h("div", { key: '3a228227c9b4d99fc57e5c1a7337ed35f549829a', class: clsx('utrecht-action-group', { 'utrecht-action-group--column': direction === 'column', 'utrecht-action-group--row': direction === 'row', }) }, h("slot", { key: '4a0d5a27e0c98fda465f7064a5e23abb105f3eb9' }))); } }; actionGroup.style = UtrechtActionGroupStyle0; const alertCss = ".utrecht-alert{background-color:var(--_utrecht-alert-background-color, var(--utrecht-alert-background-color));border-color:var(--_utrecht-alert-border-color, var(--utrecht-alert-border-color));border-radius:var(--utrecht-alert-border-radius, 0);border-style:solid;border-width:var(--_utrecht-alert-border-width, var(--utrecht-alert-border-width, 0));color:var(--_utrecht-alert-color, var(--utrecht-alert-color));column-gap:var(--utrecht-alert-column-gap);display:flex;flex-direction:row;margin-block-end:calc(var(--utrecht-space-around, 0) * var(--utrecht-alert-margin-block-end, 0));margin-block-start:calc(var(--utrecht-space-around, 0) * var(--utrecht-alert-margin-block-start, 0));padding-block-end:var(--utrecht-alert-padding-block-end);padding-block-start:var(--utrecht-alert-padding-block-start);padding-inline-end:var(--utrecht-alert-padding-inline-end);padding-inline-start:var(--utrecht-alert-padding-inline-start)}.utrecht-alert__icon{--utrecht-icon-color:var(--_utrecht-alert-icon-color, var(--utrecht-alert-icon-color));--utrecht-icon-size:var(--utrecht-alert-icon-size);--utrecht-icon-inset-block-start:var(--utrecht-alert-icon-inset-block-start)}.utrecht-alert__content{display:flex;flex-direction:column;row-gap:var(--utrecht-alert-content-row-gap)}.utrecht-alert__message{--utrecht-heading-color:var(--utrecht-alert-color);--utrecht-paragraph-color:var(--utrecht-alert-color);display:flex;flex-direction:column;row-gap:var(--utrecht-alert-message-row-gap)}.utrecht-alert--info{--_utrecht-alert-icon-color:var(--utrecht-alert-icon-info-color);--_utrecht-alert-background-color:var(--utrecht-alert-info-background-color);--_utrecht-alert-border-color:var(--utrecht-alert-info-border-color);--_utrecht-alert-border-width:var(--utrecht-alert-info-border-width);--_utrecht-alert-color:var(--utrecht-alert-info-color)}.utrecht-alert--ok{--_utrecht-alert-icon-color:var(--utrecht-alert-icon-ok-color);--_utrecht-alert-background-color:var(--utrecht-alert-ok-background-color);--_utrecht-alert-border-color:var(--utrecht-alert-ok-border-color);--_utrecht-alert-border-width:var(--utrecht-alert-ok-border-width);--_utrecht-alert-color:var(--utrecht-alert-ok-color)}.utrecht-alert--warning{--_utrecht-alert-icon-color:var(--utrecht-alert-icon-warning-color);--_utrecht-alert-background-color:var(--utrecht-alert-warning-background-color);--_utrecht-alert-border-color:var(--utrecht-alert-warning-border-color);--_utrecht-alert-border-width:var(--utrecht-alert-warning-border-width);--_utrecht-alert-color:var(--utrecht-alert-warning-color)}.utrecht-alert--error{--_utrecht-alert-icon-color:var(--utrecht-alert-icon-error-color);--_utrecht-alert-background-color:var(--utrecht-alert-error-background-color);--_utrecht-alert-border-color:var(--utrecht-alert-error-border-color);--_utrecht-alert-border-width:var(--utrecht-alert-error-border-width);--_utrecht-alert-color:var(--utrecht-alert-error-color)}:host{display:block}:host([hidden]){display:none !important}"; const UtrechtAlertStyle0 = alertCss; const enumGuard = (values) => (x) => values.includes(x); const ROLES = ['status', 'alert']; const isAlertRole = enumGuard(ROLES); const TYPES = ['error', 'warning', 'info', 'ok']; const isAlertType = enumGuard(TYPES); const typeToRole = { info: 'status', ok: 'status', warning: 'alert', error: 'alert', }; const Alert = class { constructor(hostRef) { registerInstance(this, hostRef); this.type = undefined; } render() { const computedType = isAlertType(this.type) ? this.type : 'info'; const computedRole = isAlertRole(typeToRole[computedType]) ? typeToRole[computedType] : 'status'; return (h("div", { key: 'b55c15b4ba985f5cf49b3edf8564ad698ab08332', class: clsx('utrecht-alert', `utrecht-alert--${computedType}`) }, h("div", { key: '979fba4b78603a6a46c4c61e28a0c7b0411567f7', class: "utrecht-alert__icon" }, h("slot", { key: 'fce4262e8df49413c6fc2af1448766d647988b7e', name: "icon" })), h("div", { key: '4494157b106bca1c9213b78c44c36c34b04a01a0', class: "utrecht-alert__content" }, h("div", { key: '654e071124ad372ec08fb474532da28de9ab8a2b', class: "utrecht-alert__message", role: computedRole }, h("slot", { key: '171e19b07378e008490b5db0ff2f6a9ffba5dbef' }))))); } }; Alert.style = UtrechtAlertStyle0; const articleCss = ".utrecht-article{max-inline-size:var(--utrecht-article-max-inline-size)}:host{display:block}:host([hidden]){display:none !important}"; const UtrechtArticleStyle0 = articleCss; const Article = class { constructor(hostRef) { registerInstance(this, hostRef); } render() { return (h("article", { key: 'c2dcd83843a8553522222af540aef384c6eb5906', class: "utrecht-article" }, h("slot", { key: '8844230455bd93ead62a67f52eb3839b38d0b08e' }))); } }; Article.style = UtrechtArticleStyle0; const badgeCounterCss = ".utrecht-badge-counter{background-color:var(--utrecht-badge-counter-background-color, var(--utrecht-badge-background-color, hsl(0, 0%, 0%)));border-radius:var(--utrecht-badge-counter-border-radius, var(--utrecht-badge-border-radius, 0.5ch));color:var(--utrecht-badge-counter-color, var(--utrecht-badge-color, hsl(0, 0%, 100%)));display:inline-block;font-family:var(--utrecht-badge-counter-font-family, var(--utrecht-badge-font-family, var(--utrecht-document-font-family, sans-serif)));font-size:var(--utrecht-badge-counter-font-size, var(--utrecht-badge-font-size));font-style:var(--utrecht-badge-counter-font-style, normal);font-weight:var(--utrecht-badge-counter-font-weight, var(--utrecht-badge-font-weight, bold));line-height:1;max-block-size:max-content;max-inline-size:max-content;min-block-size:var(--utrecht-badge-counter-min-block-size, var(--utrecht-badge-counter-min-inline-size, var(--utrecht-badge-counter-min-size, 1em)));min-inline-size:var(--utrecht-badge-counter-min-inline-size, var(--utrecht-badge-counter-min-size, 1em));padding-block-end:var(--utrecht-badge-counter-padding-block, var(--utrecht-badge-padding-block, 0.5ex));padding-block-start:var(--utrecht-badge-counter-padding-block, var(--utrecht-badge-padding-block, 0.5ex));padding-inline-end:var(--utrecht-badge-counter-padding-inline, var(--utrecht-badge-padding-inline, 0.5ch));padding-inline-start:var(--utrecht-badge-counter-padding-inline, var(--utrecht-badge-padding-inline, 0.5ch));text-align:center;text-decoration:none;white-space:nowrap}@media screen and (-ms-high-contrast: active), screen and (forced-colors: active){.utrecht-badge-counter{border-color:currentColor;border-style:solid;border-width:1px}}:host{display:inline-block}:host([hidden]){display:none !important}"; const UtrechtBadgeCounterStyle0 = badgeCounterCss; const BadgeCounter = class { constructor(hostRef) { registerInstance(this, hostRef); this.value = undefined; this.max = undefined; this.locale = undefined; } render() { const { locale, max, value } = this; const limited = typeof max === 'number' && typeof value === 'number' && Number(value) > Number(max); const formatNumber = (n) => (locale ? Intl.NumberFormat(locale).format(n) : String(n)); const textContent = limited ? `${formatNumber(max)}+` : typeof value === 'number' ? formatNumber(value) : ''; return h("div", { key: '69feb190325dd2c5ab694f708493b6bfcae9808f', class: "utrecht-badge-counter" }, textContent ? textContent : h("slot", null)); } }; BadgeCounter.style = UtrechtBadgeCounterStyle0; const badgeListCss = ".utrecht-badge-list{column-gap:var(--utrecht-badge-list-column-gap);display:flex;flex-wrap:wrap;row-gap:var(--utrecht-badge-list-row-gap)}:host{display:block}:host([hidden]){display:none !important}"; const UtrechtBadgeListStyle0 = badgeListCss; const BadgeList = class { constructor(hostRef) { registerInstance(this, hostRef); } render() { return (h("div", { key: '3fa401a69e43641200a07d4d60645f0f019a2d07', class: "utrecht-badge-list" }, h("slot", { key: 'b2a1f4d19cde761235baea702921f15ce62c968e' }))); } }; BadgeList.style = UtrechtBadgeListStyle0; const buttonCss = ".utrecht-button{--_utrecht-button-background-color:var(\n --_utrecht-button-hint-background-color,\n var(--_utrecht-button-appearance-background-color, var(--utrecht-button-background-color))\n );--_utrecht-button-color:var(\n --_utrecht-button-hint-color,\n var(--_utrecht-button-appearance-color, var(--utrecht-button-color))\n );--_utrecht-button-border-color:var(\n --_utrecht-button-hint-border-color,\n var(--_utrecht-button-appearance-border-color, var(--utrecht-button-border-color, transparent))\n );--_utrecht-button-border-bottom-color:var(\n --_utrecht-button-hint-border-bottom-color,\n var(\n --_utrecht-button-hint-border-color,\n var(\n --_utrecht-button-appearance-border-bottom-color,\n var(\n --_utrecht-button-appearance-border-color,\n var(--utrecht-button-border-bottom-color, var(--utrecht-button-border-color, transparent))\n )\n )\n )\n );--_utrecht-button-disabled-background-color:var(\n --_utrecht-button-hint-disabled-background-color,\n var(\n --_utrecht-button-appearance-disabled-background-color,\n var(--utrecht-button-disabled-background-color, var(--utrecht-button-background-color))\n )\n );--_utrecht-button-disabled-border-color:var(\n --_utrecht-button-hint-disabled-border-color,\n var(\n --_utrecht-button-appearance-disabled-border-color,\n var(--utrecht-button-disabled-border-color, var(--utrecht-button-border-color))\n )\n );--_utrecht-button-disabled-color:var(\n --_utrecht-button-hint-disabled-color,\n var(--_utrecht-button-appearance-disabled-color, var(--utrecht-button-disabled-color, var(--utrecht-button-color)))\n );--_utrecht-button-pressed-background-color:var(\n --_utrecht-button-hint-pressed-background-color,\n var(\n --_utrecht-button-hint-background-color,\n var(\n --_utrecht-button-appearance-pressed-background-color,\n var(\n --_utrecht-button-appearance-background-color,\n var(--utrecht-button-pressed-background-color, var(--utrecht-button-background-color))\n )\n )\n )\n );--_utrecht-button-pressed-border-color:var(\n --_utrecht-button-hint-pressed-border-color,\n var(\n --_utrecht-button-hint-border-color,\n var(\n --_utrecht-button-appearance-pressed-border-color,\n var(\n --_utrecht-button-appearance-border-color,\n var(--utrecht-button-pressed-border-color, var(--utrecht-button-border-color))\n )\n )\n )\n );--_utrecht-button-pressed-color:var(\n --_utrecht-button-hint-pressed-color,\n var(\n --_utrecht-button-hint-color,\n var(\n --_utrecht-button-appearance-pressed-color,\n var(--_utrecht-button-appearance-color, var(--utrecht-button-pressed-color, var(--utrecht-button-color)))\n )\n )\n );--_utrecht-button-focus-background-color:var(\n --_utrecht-button-hint-focus-background-color,\n var(\n --_utrecht-button-hint-background-color,\n var(\n --_utrecht-button-appearance-focus-background-color,\n var(\n --_utrecht-button-appearance-background-color,\n var(--utrecht-button-focus-background-color, var(--utrecht-button-background-color))\n )\n )\n )\n );--_utrecht-button-focus-border-color:var(\n --_utrecht-button-hint-focus-border-color,\n var(\n --_utrecht-button-hint-border-color,\n var(\n --_utrecht-button-appearance-focus-border-color,\n var(\n --_utrecht-button-appearance-border-color,\n var(--utrecht-button-focus-border-color, var(--utrecht-button-border-color))\n )\n )\n )\n );--_utrecht-button-focus-color:var(\n --_utrecht-button-hint-focus-color,\n var(\n --_utrecht-button-hint-color,\n var(\n --_utrecht-button-appearance-focus-color,\n var(--_utrecht-button-appearance-color, var(--utrecht-button-focus-color, var(--utrecht-button-color)))\n )\n )\n );--_utrecht-button-hover-background-color:var(\n --_utrecht-button-hint-hover-background-color,\n var(\n --_utrecht-button-hint-background-color,\n var(\n --_utrecht-button-appearance-hover-background-color,\n var(\n --_utrecht-button-appearance-background-color,\n var(--utrecht-button-hover-background-color, var(--utrecht-button-background-color))\n )\n )\n )\n );--_utrecht-button-hover-border-color:var(\n --_utrecht-button-hint-hover-border-color,\n var(\n --_utrecht-button-hint-border-color,\n var(\n --_utrecht-button-appearance-hover-border-color,\n var(\n --_utrecht-button-appearance-border-color,\n var(--utrecht-button-hover-border-color, var(--utrecht-button-border-color))\n )\n )\n )\n );--_utrecht-button-hover-color:var(\n --_utrecht-button-hint-hover-color,\n var(\n --_utrecht-button-hint-color,\n var(\n --_utrecht-button-appearance-hover-color,\n var(--_utrecht-button-appearance-color, var(--utrecht-button-hover-color, var(--utrecht-button-color)))\n )\n )\n );--_utrecht-button-active-background-color:var(\n --_utrecht-button-hint-active-background-color,\n var(\n --_utrecht-button-hint-background-color,\n var(\n --_utrecht-button-appearance-active-background-color,\n var(\n --_utrecht-button-appearance-background-color,\n var(--utrecht-button-active-background-color, var(--utrecht-button-background-color))\n )\n )\n )\n );--_utrecht-button-active-border-color:var(\n --_utrecht-button-hint-active-border-color,\n var(\n --_utrecht-button-hint-border-color,\n var(\n --_utrecht-button-appearance-active-border-color,\n var(\n --_utrecht-button-appearance-border-color,\n var(--utrecht-button-active-border-color, var(--utrecht-button-border-color))\n )\n )\n )\n );--_utrecht-button-active-color:var(\n --_utrecht-button-hint-active-color,\n var(\n --_utrecht-button-hint-color,\n var(\n --_utrecht-button-appearance-active-color,\n var(--_utrecht-button-appearance-color, var(--utrecht-button-active-color, var(--utrecht-button-color)))\n )\n )\n );--_utrecht-button-border-width:var(--_utrecht-button-appearance-border-width, var(--utrecht-button-border-width, 0));--_utrecht-button-border-block-end-width:var(\n --utrecht-button-border-bottom-width,\n var(--_utrecht-button-border-width, 0)\n );--_utrecht-button-font-size:var(--_utrecht-button-appearance-font-size, var(--utrecht-button-font-size));--_utrecht-button-line-height:var(--_utrecht-button-appearance-line-height, var(--utrecht-button-line-height));--utrecht-icon-size:var(--utrecht-button-icon-size, 1em);align-items:center;background-color:var(--_utrecht-button-background-color);block-size:fit-content;border-color:var(--_utrecht-button-border-color);border-radius:var(--utrecht-button-border-radius);border-style:solid;border-width:var(--_utrecht-button-border-width);border-block-end-color:var(--_utrecht-button-border-bottom-color);border-block-end-width:var(--_utrecht-button-border-block-end-width);box-sizing:border-box;color:var(--_utrecht-button-color);column-gap:var(--utrecht-button-column-gap);cursor:var(--utrecht-action-activate-cursor, revert);display:inline-flex;font-family:var(--utrecht-button-font-family, var(--utrecht-document-font-family));font-size:var(--_utrecht-button-font-size, var(--utrecht-document-font-family, inherit));font-weight:var(--_utrecht-button-appearance-font-weight, var(--utrecht-button-font-weight));inline-size:var(--utrecht-button-inline-size, auto);justify-content:var(--utrecht-button-justify-content, center);line-height:var(--_utrecht-button-line-height);max-inline-size:var(--utrecht-button-max-inline-size, fit-content);min-block-size:var(--utrecht-button-min-block-size, 44px);min-inline-size:var(--utrecht-button-min-inline-size, 44px);padding-block-end:var(--utrecht-button-padding-block-end);padding-block-start:var(--utrecht-button-padding-block-start);padding-inline-end:var(--utrecht-button-padding-inline-end);padding-inline-start:var(--utrecht-button-padding-inline-start);scale:1;text-transform:var(--utrecht-button-text-transform);-webkit-user-select:none;user-select:none}@media screen and (-ms-high-contrast: active), screen and (forced-colors: active){.utrecht-button{--_utrecht-button-disabled-border-color:GrayText;--_utrecht-button-disabled-color:GrayText;background-color:ButtonFace;border-color:buttonborder;color:ButtonText;}}.utrecht-button--distanced{margin-block-end:var(--utrecht-button-margin-block-end);margin-block-start:var(--utrecht-button-margin-block-start);margin-inline-end:var(--utrecht-button-margin-inline-end);margin-inline-start:var(--utrecht-button-margin-inline-start)}.utrecht-button--submit{cursor:var(--utrecht-action-submit-cursor, revert)}.utrecht-button--busy{cursor:var(--utrecht-action-busy-cursor, wait)}.utrecht-button--pressed{background-color:var(--_utrecht-button-pressed-background-color);border-color:var(--_utrecht-button-pressed-border-color);color:var(--_utrecht-button-pressed-color)}.utrecht-button:disabled,.utrecht-button--disabled{background-color:var(--_utrecht-button-disabled-background-color);border-color:var(--_utrecht-button-disabled-border-color);color:var(--_utrecht-button-disabled-color);cursor:var(--utrecht-action-disabled-cursor, not-allowed)}.utrecht-button--focus-visible{--_utrecht-focus-ring-box-shadow:0 0 0 var(--utrecht-focus-outline-width, 0)\n var(--utrecht-focus-inverse-outline-color, transparent);box-shadow:var(--_utrecht-focus-ring-box-shadow);outline-color:var(--utrecht-focus-outline-color, revert);outline-offset:var(--utrecht-focus-outline-offset, revert);outline-style:var(--utrecht-focus-outline-style, revert);outline-width:var(--utrecht-focus-outline-width, revert);z-index:1}.utrecht-button--focus:not(.utrecht-button--disabled){background-color:var(--_utrecht-button-focus-background-color);border-color:var(--_utrecht-button-focus-border-color);color:var(--_utrecht-button-focus-color);scale:var(--utrecht-button-focus-scale, 1)}.utrecht-button:focus-visible{--_utrecht-focus-ring-box-shadow:0 0 0 var(--utrecht-focus-outline-width, 0)\n var(--utrecht-focus-inverse-outline-color, transparent);box-shadow:var(--_utrecht-focus-ring-box-shadow);outline-color:var(--utrecht-focus-outline-color, revert);outline-offset:var(--utrecht-focus-outline-offset, revert);outline-style:var(--utrecht-focus-outline-style, revert);outline-width:var(--utrecht-focus-outline-width, revert);z-index:1}.utrecht-button:focus:not(:disabled,[aria-disabled=true],.utrecht-button--disabled){background-color:var(--_utrecht-button-focus-background-color);border-color:var(--_utrecht-button-focus-border-color);color:var(--_utrecht-button-focus-color);scale:var(--utrecht-button-focus-scale, 1)}.utrecht-button--hover:not(:disabled,.utrecht-button--disabled),.utrecht-button:hover:not(:disabled,[aria-disabled=true],.utrecht-button--disabled){background-color:var(--_utrecht-button-hover-background-color);border-color:var(--_utrecht-button-hover-border-color);color:var(--_utrecht-button-hover-color);scale:var(--utrecht-button-hover-scale, 1)}.utrecht-button:active:not(:disabled,[aria-disabled=true],.utrecht-button--disabled),.utrecht-button--active{background-color:var(--_utrecht-button-active-background-color);border-color:var(--_utrecht-button-active-border-color);color:var(--_utrecht-button-active-color)}.utrecht-button--primary-action{--_utrecht-button-appearance-active-background-color:var(--utrecht-button-primary-action-active-background-color);--_utrecht-button-appearance-active-border-color:var(--utrecht-button-primary-action-active-border-color);--_utrecht-button-appearance-active-color:var(--utrecht-button-primary-action-active-color);--_utrecht-button-appearance-background-color:var(--utrecht-button-primary-action-background-color);--_utrecht-button-appearance-border-color:var(--utrecht-button-primary-action-border-color);--_utrecht-button-appearance-border-width:var(--utrecht-button-primary-action-border-width);--_utrecht-button-appearance-color:var(--utrecht-button-primary-action-color);--_utrecht-button-appearance-font-size:var(--utrecht-button-primary-action-font-size);--_utrecht-button-appearance-font-weight:var(--utrecht-button-primary-action-font-weight);--_utrecht-button-appearance-line-height:var(--utrecht-button-primary-action-line-height);--_utrecht-button-appearance-disabled-background-color:var(--utrecht-button-primary-action-disabled-background-color);--_utrecht-button-appearance-disabled-border-color:var(--utrecht-button-primary-action-disabled-border-color);--_utrecht-button-appearance-disabled-color:var(--utrecht-button-primary-action-disabled-color);--_utrecht-button-appearance-focus-background-color:var(--utrecht-button-primary-action-focus-background-color);--_utrecht-button-appearance-focus-border-color:var(--utrecht-button-primary-action-focus-border-color);--_utrecht-button-appearance-focus-color:var(--utrecht-button-primary-action-focus-color);--_utrecht-button-appearance-hover-background-color:var(--utrecht-button-primary-action-hover-background-color);--_utrecht-button-appearance-hover-border-color:var(--utrecht-button-primary-action-hover-border-color);--_utrecht-button-appearance-hover-color:var(--utrecht-button-primary-action-hover-color);--_utrecht-button-appearance-pressed-background-color:var(--utrecht-button-primary-action-pressed-background-color);--_utrecht-button-appearance-pressed-border-color:var(--utrecht-button-primary-action-pressed-border-color);--_utrecht-button-appearance-pressed-color:var(--utrecht-button-primary-action-pressed-color)}.utrecht-button--secondary-action{--_utrecht-button-appearance-active-background-color:var(--utrecht-button-secondary-action-active-background-color);--_utrecht-button-appearance-active-border-color:var(--utrecht-button-secondary-action-active-border-color);--_utrecht-button-appearance-active-color:var(--utrecht-button-secondary-action-active-color);--_utrecht-button-appearance-background-color:var(--utrecht-button-secondary-action-background-color);--_utrecht-button-appearance-border-color:var(--utrecht-button-secondary-action-border-color);--_utrecht-button-appearance-border-width:var(--utrecht-button-secondary-action-border-width);--_utrecht-button-appearance-color:var(--utrecht-button-secondary-action-color);--_utrecht-button-appearance-font-size:var(--utrecht-button-secondary-action-font-size);--_utrecht-button-appearance-font-weight:var(--utrecht-button-secondary-action-font-weight);--_utrecht-button-appearance-line-height:var(--utrecht-button-secondary-action-line-height);--_utrecht-button-appearance-disabled-background-color:var(--utrecht-button-secondary-action-disabled-background-color);--_utrecht-button-appearance-disabled-border-color:var(--utrecht-button-secondary-action-disabled-border-color);--_utrecht-button-appearance-disabled-color:var(--utrecht-button-secondary-action-disabled-color);--_utrecht-button-appearance-focus-background-color:var(--utrecht-button-secondary-action-focus-background-color);--_utrecht-button-appearance-focus-border-color:var(--utrecht-button-secondary-action-focus-border-color);--_utrecht-button-appearance-focus-color:var(--utrecht-button-secondary-action-focus-color);--_utrecht-button-appearance-hover-background-color:var(--utrecht-button-secondary-action-hover-background-color);--_utrecht-button-appearance-hover-border-color:var(--utrecht-button-secondary-action-hover-border-color);--_utrecht-button-appearance-hover-color:var(--utrecht-button-secondary-action-hover-color);--_utrecht-button-appearance-pressed-background-color:var(--utrecht-button-secondary-action-pressed-background-color);--_utrecht-button-appearance-pressed-border-color:var(--utrecht-button-secondary-action-pressed-border-color);--_utrecht-button-appearance-pressed-color:var(--utrecht-button-secondary-action-pressed-color)}.utrecht-button--subtle{--_utrecht-button-appearance-active-background-color:var(--utrecht-button-subtle-active-background-color);--_utrecht-button-appearance-active-border-color:var(--utrecht-button-subtle-active-border-color);--_utrecht-button-appearance-active-color:var(--utrecht-button-subtle-active-color);--_utrecht-button-appearance-background-color:var(--utrecht-button-subtle-background-color);--_utrecht-button-appearance-border-color:var(--utrecht-button-subtle-border-color);--_utrecht-button-appearance-border-width:var(--utrecht-button-subtle-border-width);--_utrecht-button-appearance-color:var(--utrecht-button-subtle-color);--_utrecht-button-appearance-font-size:var(--utrecht-button-subtle-font-size);--_utrecht-button-appearance-font-weight:var(--utrecht-button-subtle-font-weight);--_utrecht-button-appearance-line-height:var(--utrecht-button-subtle-line-height);--_utrecht-button-appearance-disabled-background-color:var(--utrecht-button-subtle-disabled-background-color);--_utrecht-button-appearance-disabled-border-color:var(--utrecht-button-subtle-disabled-border-color);--_utrecht-button-appearance-disabled-color:var(--utrecht-button-subtle-disabled-color);--_utrecht-button-appearance-focus-background-color:var(--utrecht-button-subtle-focus-background-color);--_utrecht-button-appearance-focus-border-color:var(--utrecht-button-subtle-focus-border-color);--_utrecht-button-appearance-focus-color:var(--utrecht-button-subtle-focus-color);--_utrecht-button-appearance-hover-background-color:var(--utrecht-button-subtle-hover-background-color);--_utrecht-button-appearance-hover-border-color:var(--utrecht-button-subtle-hover-border-color);--_utrecht-button-appearance-hover-color:var(--utrecht-button-subtle-hover-color);--_utrecht-button-appearance-pressed-background-color:var(--utrecht-button-subtle-pressed-background-color);--_utrecht-button-appearance-pressed-border-color:var(--utrecht-button-subtle-pressed-border-color);--_utrecht-button-appearance-pressed-color:var(--utrecht-button-subtle-pressed-color)}.utrecht-button--primary-action.utrecht-button--danger{--_utrecht-button-hint-active-background-color:var(--utrecht-button-primary-action-danger-active-background-color);--_utrecht-button-hint-active-border-color:var(--utrecht-button-primary-action-danger-active-border-color);--_utrecht-button-hint-active-color:var(--utrecht-button-primary-action-danger-active-color);--_utrecht-button-hint-background-color:var(--utrecht-button-primary-action-danger-background-color);--_utrecht-button-hint-border-color:var(--utrecht-button-primary-action-danger-border-color);--_utrecht-button-hint-color:var(--utrecht-button-primary-action-danger-color);--_utrecht-button-hint-disabled-background-color:var(\n --utrecht-button-primary-action-danger-disabled-background-color\n );--_utrecht-button-hint-disabled-border-color:var(--utrecht-button-primary-action-danger-disabled-border-color);--_utrecht-button-hint-disabled-color:var(--utrecht-button-primary-action-danger-disabled-color);--_utrecht-button-hint-focus-background-color:var(--utrecht-button-primary-action-danger-focus-background-color);--_utrecht-button-hint-focus-border-color:var(--utrecht-button-primary-action-danger-focus-border-color);--_utrecht-button-hint-focus-color:var(--utrecht-button-primary-action-danger-focus-color);--_utrecht-button-hint-hover-background-color:var(--utrecht-button-primary-action-danger-hover-background-color);--_utrecht-button-hint-hover-border-color:var(--utrecht-button-primary-action-danger-hover-border-color);--_utrecht-button-hint-hover-color:var(--utrecht-button-primary-action-danger-hover-color);--_utrecht-button-hint-pressed-background-color:var(\n --utrecht-button-primary-action-danger-pressed-background-color\n );--_utrecht-button-hint-pressed-border-color:var(--utrecht-button-primary-action-danger-pressed-border-color);--_utrecht-button-hint-pressed-color:var(--utrecht-button-primary-action-danger-pressed-color)}.utrecht-button--primary-action.utrecht-button--ready{--_utrecht-button-hint-active-background-color:var(--utrecht-button-primary-action-ready-active-background-color);--_utrecht-button-hint-active-border-color:var(--utrecht-button-primary-action-ready-active-border-color);--_utrecht-button-hint-active-color:var(--utrecht-button-primary-action-ready-active-color);--_utrecht-button-hint-background-color:var(--utrecht-button-primary-action-ready-background-color);--_utrecht-button-hint-border-color:var(--utrecht-button-primary-action-ready-border-color);--_utrecht-button-hint-color:var(--utrecht-button-primary-action-ready-color);--_utrecht-button-hint-disabled-background-color:var(\n --utrecht-button-primary-action-ready-disabled-background-color\n );--_utrecht-button-hint-disabled-border-color:var(--utrecht-button-primary-action-ready-disabled-border-color);--_utrecht-button-hint-disabled-color:var(--utrecht-button-primary-action-ready-disabled-color);--_utrecht-button-hint-focus-background-color:var(--utrecht-button-primary-action-ready-focus-background-color);--_utrecht-button-hint-focus-border-color:var(--utrecht-button-primary-action-ready-focus-border-color);--_utrecht-button-hint-focus-color:var(--utrecht-button-primary-action-ready-focus-color);--_utrecht-button-hint-hover-background-color:var(--utrecht-button-primary-action-ready-hover-background-color);--_utrecht-button-hint-hover-border-color:var(--utrecht-button-primary-action-ready-hover-border-color);--_utrecht-button-hint-hover-color:var(--utrecht-button-primary-action-ready-hover-color);--_utrecht-button-hint-pressed-background-color:var(\n --utrecht-button-primary-action-ready-pressed-background-color\n );--_utrecht-button-hint-pressed-border-color:var(--utrecht-button-primary-action-ready-pressed-border-color);--_utrecht-button-hint-pressed-color:var(--utrecht-button-primary-action-ready-pressed-color)}.utrecht-button--primary-action.utrecht-button--warning{--_utrecht-button-hint-active-background-color:var(--utrecht-button-primary-action-warning-active-background-color);--_utrecht-button-hint-active-border-color:var(--utrecht-button-primary-action-warning-active-border-color);--_utrecht-button-hint-active-color:var(--utrecht-button-primary-action-warning-active-color);--_utrecht-button-hint-background-color:var(--utrecht-button-primary-action-warning-background-color);--_utrecht-button-hint-border-color:var(--utrecht-button-primary-action-warning-border-color);--_utrecht-button-hint-color:var(--utrecht-button-primary-action-warning-color);--_utrecht-button-hint-disabled-background-color:var(\n --utrecht-button-primary-action-warning-disabled-background-color\n );--_utrecht-button-hint-disabled-border-color:var(--utrecht-button-primary-action-warning-disabled-border-color);--_utrecht-button-hint-disabled-color:var(--utrecht-button-primary-action-warning-disabled-color);--_utrecht-button-hint-focus-background-color:var(--utrecht-button-primary-action-warning-focus-background-color);--_utrecht-button-hint-focus-border-color:var(--utrecht-button-primary-action-warning-focus-border-color);--_utrecht-button-hint-focus-color:var(--utrecht-button-primary-action-warning-focus-color);--_utrecht-button-hint-hover-background-color:var(--utrecht-button-primary-action-warning-hover-background-color);--_utrecht-button-hint-hover-border-color:var(--utrecht-button-primary-action-warning-hover-border-color);--_utrecht-button-hint-hover-color:var(--utrecht-button-primary-action-warning-hover-color);--_utrecht-button-hint-pressed-background-color:var(\n --utrecht-button-primary-action-warning-pressed-background-color\n );--_utrecht-button-hint-pressed-border-color:var(--utrecht-button-primary-action-warning-pressed-border-color);--_utrecht-button-hint-pressed-color:var(--utrecht-button-primary-action-warning-pressed-color)}.utrecht-button--secondary-action.utrecht-button--danger{--_utrecht-button-hint-active-background-color:var(--utrecht-button-secondary-action-danger-active-background-color);--_utrecht-button-hint-active-border-color:var(--utrecht-button-secondary-action-danger-active-border-color);--_utrecht-button-hint-active-color:var(--utrecht-button-secondary-action-danger-active-color);--_utrecht-button-hint-background-color:var(--utrecht-button-secondary-action-danger-background-color);--_utrecht-button-hint-border-color:var(--utrecht-button-secondary-action-danger-border-color);--_utrecht-button-hint-color:var(--utrecht-button-secondary-action-danger-color);--_utrecht-button-hint-disabled-background-color:var(\n --utrecht-button-secondary-action-danger-disabled-background-color\n );--_utrecht-button-hint-disabled-border-color:var(--utrecht-button-secondary-action-danger-disabled-border-color);--_utrecht-button-hint-disabled-color:var(--utrecht-button-secondary-action-danger-disabled-color);--_utrecht-button-hint-focus-background-color:var(--utrecht-button-secondary-action-danger-focus-background-color);--_utrecht-button-hint-focus-border-color:var(--utrecht-button-secondary-action-danger-focus-border-color);--_utrecht-button-hint-focus-color:var(--utrecht-button-secondary-action-danger-focus-color);--_utrecht-button-hint-hover-background-color:var(--utrecht-button-secondary-action-danger-hover-background-color);--_utrecht-button-hint-hover-border-color:var(--utrecht-button-secondary-action-danger-hover-border-color);--_utrecht-button-hint-hover-color:var(--utrecht-button-secondary-action-danger-hover-color);--_utrecht-button-hint-pressed-background-color:var(\n --utrecht-button-secondary-action-danger-pressed-background-color\n );--_utrecht-button-hint-pressed-border-color:var(--utrecht-button-secondary-action-danger-pressed-border-color);--_utrecht-button-hint-pressed-color:var(--utrecht-button-secondary-action-danger-pressed-color)}.utrecht-button--secondary-action.utrecht-button--ready{--_utrecht-button-hint-active-background-color:var(--utrecht-button-secondary-action-ready-active-background-color);--_utrecht-button-hint-active-border-color:var(--utrecht-button-secondary-action-ready-active-border-color);--_utrecht-button-hint-active-color:var(--utrecht-button-secondary-action-ready-active-color);--_utrecht-button-hint-background-color:var(--utrecht-button-secondary-action-ready-background-color);--_utrecht-button-hint-border-color:var(--utrecht-button-secondary-action-ready-border-color);--_utrecht-button-hint-color:var(--utrecht-button-secondary-action-ready-color);--_utrecht-button-hint-disabled-background-color:var(\n --utrecht-button-secondary-action-ready-disabled-background-color\n );--_utrecht-button-hint-disabled-border-color:var(--utrecht-button-secondary-action-ready-disabled-border-color);--_utrecht-button-hint-disabled-color:var(--utrecht-button-secondary-action-ready-disabled-color);--_utrecht-button-hint-focus-background-color:var(--utrecht-button-secondary-action-ready-focus-background-color);--_utrecht-button-hint-focus-border-color:var(--utrecht-button-secondary-action-ready-focus-border-color);--_utrecht-button-hint-focus-color:var(--utrecht-button-secondary-action-ready-focus-color);--_utrecht-button-hint-hover-background-color:var(--utrecht-button-secondary-action-ready-hover-background-color);--_utrecht-button-hint-hover-border-color:var(--utrecht-button-secondary-action-ready-hover-border-color);--_utrecht-button-hint-hover-color:var(--utrecht-button-secondary-action-ready-hover-color);--_utrecht-button-hint-pressed-background-color:var(\n --utrecht-button-secondary-action-ready-pressed-background-color\n );--_utrecht-button-hint-pressed-border-color:var(--utrecht-button-secondary-action-ready-pressed-border-color);--_utrecht-button-hint-pressed-color:var(--utrecht-button-secondary-action-ready-pressed-color)}.utrecht-button--secondary-action.utrecht-button--warning{--_utrecht-button-hint-active-background-color:var(--utrecht-button-secondary-action-warning-active-background-color);--_utrecht-button-hint-active-border-color:var(--utrecht-button-secondary-action-warning-active-border-color);--_utrecht-button-hint-active-color:var(--utrecht-button-secondary-action-warning-active-color);--_utrecht-button-hint-background-color:var(--utrecht-button-secondary-action-warning-background-color);--_utrecht-button-hint-border-color:var(--utrecht-button-secondary-action-warning-border-color);--_utrecht-button-hint-color:var(--utrecht-button-secondary-action-warning-color);--_utrecht-button-hint-disabled-background-color:var(\n --utrecht-button-secondary-action-warning-disabled-background-color\n );--_utrecht-button-hint-disabled-border-color:var(--utrecht-button-secondary-action-warning-disabled-border-color);--_utrecht-button-hint-disabled-color:var(--utrecht-button-secondary-action-warning-disabled-color);--_utrecht-button-hint-focus-background-color:var(--utrecht-button-secondary-action-warning-focus-background-color);--_utrecht-button-hint-focus-border-color:var(--utrecht-button-secondary-action-warning-focus-border-color);--_utrecht-button-hint-focus-color:var(--utrecht-button-secondary-action-warning-focus-color);--_utrecht-button-hint-hover-background-color:var(--utrecht-button-secondary-action-warning-hover-background-color);--_utrecht-button-hint-hover-border-color:var(--utrecht-button-secondary-action-warning-hover-border-color);--_utrecht-button-hint-hover-color:var(--utrecht-button-secondary-action-warning-hover-color);--_utrecht-button-hint-pressed-background-color:var(\n --utrecht-button-secondary-action-warning-pressed-background-color\n );--_utrecht-button-hint-pressed-border-color:var(--utrecht-button-secondary-action-warning-pressed-border-color);--_utrecht-button-hint-pressed-color:var(--utrecht-button-secondary-action-warning-pressed-color)}.utrecht-button--subtle.utrecht-button--danger{--_utrecht-button-hint-active-background-color:var(--utrecht-button-subtle-danger-active-background-color);--_utrecht-button-hint-active-border-color:var(--utrecht-button-subtle-danger-active-border-color);--_utrecht-button-hint-active-color:var(--utrecht-button-subtle-danger-active-color);--_utrecht-button-hint-background-color:var(--utrecht-button-subtle-danger-background-color);--_utrecht-button-hint-border-color:var(--utrecht-button-subtle-danger-border-color);--_utrecht-button-hint-color:var(--utrecht-button-subtle-danger-color);--_utrecht-button-hint-disabled-background-color:var(\n --utrecht-button-subtle-danger-disabled-background-color\n );--_utrecht-button-hint-disabled-border-color:var(--utrecht-button-subtle-danger-disabled-border-color);--_utrecht-button-hint-disabled-color:var(--utrecht-button-subtle-danger-disabled-color);--_utrecht-button-hint-focus-background-color:var(--utrecht-button-subtle-danger-focus-background-color);--_utrecht-button-hint-focus-border-color:var(--utrecht-button-subtle-danger-focus-border-color);--_utrecht-button-hint-focus-color:var(--utrecht-button-subtle-danger-focus-color);--_utrecht-button-hint-hover-background-color:var(--utrecht-button-subtle-danger-hover-background-color);--_utrecht-button-hint-hover-border-color:var(--utrecht-button-subtle-danger-hover-border-color);--_utrecht-button-hint-hover-color:var(--utrecht-button-subtle-danger-hover-color);--_utrecht-button-hint-pressed-background-color:var(\n --utrecht-button-subtle-danger-pressed-background-color\n );--_utrecht-button-hint-pressed-border-color:var(--utrecht-button-subtle-danger-pressed-border-color);--_utrecht-button-hint-pressed-color:var(--utrecht-button-subtle-danger-pressed-color)}.utrecht-button--subtle.utrecht-button--ready{--_utrecht-button-hint-active-background-color:var(--utrecht-button-subtle-ready-active-background-color);--_utrecht-button-hint-active-border-color:var(--utrecht-button-subtle-ready-active-border-color);--_utrecht-button-hint-active-color:var(--utrecht-button-subtle-ready-active-color);--_utrecht-button-hint-background-color:var(--utrecht-button-subtle-ready-background-color);--_utrecht-button-hint-border-color:var(--utrecht-button-subtle-ready-border-color);--_utrecht-button-hint-color:var(--utrecht-button-subtle-ready-color);--_utrecht-button-hint-disabled-background-color:var(\n --utrecht-button-subtle-ready-disabled-background-color\n );--_utrecht-button-hint-disabled-border-color:var(--utrecht-button-subtle-ready-disabled-border-color);--_utrecht-button-hint-disabled-color:var(--utrecht-button-subtle-ready-disabled-color);--_utrecht-button-hint-focus-background-color:var(--utrecht-button-subtle-ready-focus-background-color);--_utrecht-button-hint-focus-border-color:var(--utrecht-button-subtle-ready-focus-border-color);--_utrecht-button-hint-focus-color:var(--utrecht-button-subtle-ready-focus-color);--_utrecht-button-hint-hover-background-color:var(--utrecht-button-subtle-ready-hover-background-color);--_utrecht-button-hint-hover-border-color:var(--utrecht-button-subtle-ready-hover-border-color);--_utrecht-button-hint-hover-color:var(--utrecht-button-subtle-ready-hover-color);--_utrecht-button-hint-pressed-background-color:var(\n --utrecht-button-subtle-ready-pressed-background-color\n );--_utrecht-button-hint-pressed-border-color:var(--utrecht-button-subtle-ready-pressed-border-color);--_utrecht-button-hint-pressed-color:var(--utrecht-button-subtle-ready-pressed-color)}.utrecht-button--subtle.utrecht-button--warning{--_utrecht-button-hint-active-background-color:var(--utrecht-button-subtle-warning-active-background-color);--_utrecht-button-hint-active-border-color:var(--utrecht-button-subtle-warning-active-border-color);--_utrecht-button-hint-active-color:var(--utrecht-button-subtle-warning-active-color);--_utrecht-button-hint-background-color:var(--utrecht-button-subtle-warning-background-color);--_utrecht-button-hint-border-color:var(--utrecht-button-subtle-warning-border-color);--_utrecht-button-hint-color:var(--utrecht-button-subtle-warning-color);--_utrecht-button-hint-disabled-background-color:var(\n --utrecht-button-subtle-warning-disabled-background-color\n );--_utrecht-button-hint-disabled-border-color:var(--utrecht-button-subtle-warning-disabled-border-color);--_utrecht-button-hint-disabled-color:var(--utrecht-button-subtle-warning-disabled-color);--_utrecht-button-hint-focus-background-color:var(--utrecht-button-subtle-warning-focus-background-color);--_utrecht-button-hint-focus-border-color:var(--utrecht-button-subtle-warning-focus-border-color);--_utrecht-button-hint-focus-color:var(--utrecht-button-subtle-warning-focus-color);--_utrecht-button-hint-hover-background-color:var(--utrecht-button-subtle-warning-hover-background-color);--_utrecht-button-hint-hover-border-color:var(--utrecht-button-subtle-warning-hover-border-color);--_utrecht-button-hint-hover-color:var(--utrecht-button-subtle-warning-hover-color);--_utrecht-button-hint-pressed-background-color:var(\n --utrecht-button-subtle-warning-pressed-background-color\n );--_utrecht-button-hint-pressed-border-color:var(--utrecht-button-subtle-warning-pressed-border-color);--_utrecht-button-hint-pressed-color:var(--utrecht-button-subtle-warning-pressed-color)}:host{display:inline-block}:host([hidden]){display:none !important}"; const UtrechtButtonStyle0 = buttonCss; const Button = class { constructor(hostRef) { registerInstance(this, hostRef); this.utrechtRequestReset = createEvent(this, "utrechtRequestReset", 7); this.utrechtRequestSubmit = createEvent(this, "utrechtRequestSubmit", 7); this.appearance = undefined; this.busy = undefined; this.disabled = undefined; this.expanded = undefined; this.pressed = undefined; this.form = undefined; this.formAction = undefined; this.formEnctype = undefined; this.formMethod = undefined; this.formNoValidate = undefined; this.formTarget = undefined; this.popoverTarget = undefined; this.popoverTargetAction = undefined; this.name = undefined; this.value = undefined; this.type = undefined; } render() { const handleReset = () => { var _a, _b; const event = this.utrechtRequestReset.emit(); if (!event.defaultPrevented) { (_b = (_a = this.hostElement) === null || _a === void 0 ? void 0 : _a.closest('form')) === null || _b === void 0 ? void 0 : _b.reset(); } }; const handleSubmit = () => { var _a, _b; const event = this.utrechtRequestSubmit.emit(); if (!event.defaultPrevented) { (_b = (_a = this.hostElement) === null || _a === void 0 ? void 0 : _a.closest('form')) === null || _b === void 0 ? void 0 : _b.requestSubmit(); } }; const handleClick = () => { if (this.type === 'reset') { handleReset(); } else if (this.type === 'submit') { handleSubmit(); } else { const button = this.hostElement.querySelector('button[hidden]'); if (button) { button.click(); } } }; const { hostElement, expanded, pressed, name, value, form, formAction, formEnctype, formTarget, formNoValidate, formMethod, popoverTargetAction, popoverTarget, type, } = this; let button = hostElement.querySelector('button[hidden]'); const needsButton = !!(name || form || formTarget || formEnctype || formMethod || formNoValidate || popoverTarget || popoverTargetAction || type === 'submit'); if (button && !needsButton) { button.parentNode.removeChild(button); } if (!button && needsButton) { button = hostElement.ownerDocument.createElement('button'); button.hidden = true; button.tabIndex = -1; button.ariaHidden = 'true'; hostElement.appendChild(button); } const setAttribute = (el, name, value) => { if (typeof value === 'string') { el.setAttribute(name, value); } else { el.removeAttribute(name); } }; if (button) { setAttribute(button, 'name', name); setAttribute(button, 'type', type); setAttribute(button, 'form', form); setAttribute(button, 'formaction', formAction); setAttribute(button, 'form', form); setAttribute(button, 'formtarget', formTarget); setAttribute(button, 'formenctype', formEnctype); setAttribute(button, 'formmethod', formMethod); setAttribute(button, 'formnovalidate', formNoValidate ? '' : null); setAttribute(button, 'popovertargetaction', popoverTargetAction); setAttribute(button, 'popovertarget', popoverTarget); setAttribute(button, 'type', type); button.style.display = 'none'; button.value = value || ''; } return (h("button", { key: 'f9a03c6eb1802e4c95f586b904d81efab6192bc4', class: clsx('utrecht-button', this.busy && 'utrecht-button--busy', this.disabled && 'utrecht-button--disabled', pressed && 'utrecht-button--pressed', this.type === 'submit' && 'utrecht-button--submit', this.appearance === 'primary-action-button' && 'utrecht-button--primary-action', this.appearance === 'secondary-action-button' && 'utrecht-button--secondary-action', this.appearance === 'subtle-button' && 'utrecht-button--subtle'), "aria-busy": this.busy ? 'true' : null, "aria-expanded": typeof this.expanded === 'boolean' ? String(expanded) : typeof expanded === 'string' ? expanded : null, "ar