@descope/web-components-ui 2.2.0 → 2.2.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.
@@ -1 +1 @@
1
- {"version":3,"file":"boolean-fields-descope-boolean-field-internal-index-js.js","mappings":"8JAEAA,eAAeC,OAAO,IAAe,I,sECO9B,MAAMC,EAAuB,IAAIC,KACtC,QACE,KACA,KACA,KACA,KAJF,EAKE,UAAmBA,G,oECPhB,MAAMC,GAAgB,QAAiB,0BAExCC,EAAoB,CAAC,WAAY,UAAW,YAE5CC,GAAiB,OAAqB,CAAEF,gBAAeG,aAAc,QA4F3E,EA1FA,cAAmCD,EACjC,6BAAWE,GACT,MAAO,CAAC,WAAY,QACtB,CAEA,WAAAC,GACEC,QACAC,KAAKC,UAAY,yMAOjBD,KAAKE,WAAaF,KAAKG,cAAc,OACrCH,KAAKI,SAAWJ,KAAKG,cAAc,mBACnCH,KAAKK,aAAeL,KAAKG,cAAc,iBACzC,CAEA,SAAIG,GACF,OAAON,KAAKI,UAAUG,OACxB,CAEA,SAAID,CAAME,GACRR,KAAKI,SAASG,QAAUC,CAC1B,CAEA,WAAID,GACF,OAAOP,KAAKM,KACd,CAEA,WAAIC,CAAQC,GACVR,KAAKM,MAAQE,CACf,CAEA,IAAAC,GACET,KAAKU,iBAAiB,QAAUC,IAC1BA,EAAEC,WACJZ,KAAKI,SAASS,UAGlBd,MAAMU,UAEN,QAAaT,KAAMA,KAAKI,SAAU,CAAEU,aAAcpB,KAClD,QAAUM,KAAMA,KAAKI,SAAU,CAAEU,aAAc,CAAC,aAGhDd,KAAKK,aAAaK,iBAAiB,QAAUC,IACtCX,KAAKe,aAAa,aAAgBf,KAAKe,aAAa,aACvDf,KAAKI,SAASY,UAKlBhB,KAAKiB,6BAA6B,CAACjB,KAAKI,UAC1C,CAEA,wBAAAc,CAAyBC,EAAUC,EAAUC,GAC3CtB,MAAMmB,2BAA2BC,EAAUC,EAAUC,GAEpC,aAAbF,GACFnB,KAAKsB,iBAA8B,OAAbD,GAGP,UAAbF,GACFnB,KAAKuB,eAET,CAEA,aAAAA,GACE,MAAMC,EAAaxB,KAAKyB,aAAa,SAEnCzB,KAAKK,aAAaqB,YADhBF,GAG8B,EAEpC,CAEA,gBAAAF,CAAiBd,GACfR,KAAK2B,YAAYC,aAAa,QAASpB,EACzC,CAEA,WAAAqB,GACE,OAAI7B,KAAK8B,aAAe9B,KAAKM,MACpB,CAAEyB,cAAc,GAElB,CAAC,CACV,E","sources":["webpack://@descope/web-components-ui/./src/components/boolean-fields/descope-boolean-field-internal/index.js","webpack://@descope/web-components-ui/./src/baseClasses/createBaseInputClass.js","webpack://@descope/web-components-ui/./src/components/boolean-fields/descope-boolean-field-internal/BooleanFieldInternal.js"],"sourcesContent":["import BooleanFieldInternal, { componentName } from './BooleanFieldInternal';\n\ncustomElements.define(componentName, BooleanFieldInternal);\n","import { compose } from '../helpers';\nimport {\n changeMixin,\n inputEventsDispatchingMixin,\n inputValidationMixin,\n normalizeBooleanAttributesMixin,\n} from '../mixins';\nimport { createBaseClass } from './createBaseClass';\n\nexport const createBaseInputClass = (...args) =>\n compose(\n inputValidationMixin,\n changeMixin,\n normalizeBooleanAttributesMixin,\n inputEventsDispatchingMixin\n )(createBaseClass(...args));\n","import { createBaseInputClass } from '../../../baseClasses/createBaseInputClass';\nimport {\n forwardAttrs,\n observeAttributes,\n getComponentName,\n syncAttrs,\n} from '../../../helpers/componentHelpers';\n\nexport const componentName = getComponentName('boolean-field-internal');\n\nconst forwardAttributes = ['disabled', 'invalid', 'readonly'];\n\nconst BaseInputClass = createBaseInputClass({ componentName, baseSelector: 'div' });\n\nclass BooleanInputInternal extends BaseInputClass {\n static get observedAttributes() {\n return ['readonly', 'label'];\n }\n\n constructor() {\n super();\n this.innerHTML = `\n\t\t\t<div class=\"wrapper\">\n\t\t\t\t<vaadin-checkbox>\n\t\t\t\t\t<descope-enriched-text class=\"label-content\" slot=\"label\"></descope-enriched-text>\n\t\t\t\t</vaadin-checkbox>\n\t\t\t</div>\n\t\t`;\n this.wrapperEle = this.querySelector('div');\n this.checkbox = this.querySelector('vaadin-checkbox');\n this.labelContent = this.querySelector('.label-content');\n }\n\n get value() {\n return this.checkbox?.checked;\n }\n\n set value(val) {\n this.checkbox.checked = val;\n }\n\n get checked() {\n return this.value;\n }\n\n set checked(val) {\n this.value = val;\n }\n\n init() {\n this.addEventListener('focus', (e) => {\n if (e.isTrusted) {\n this.checkbox.focus();\n }\n });\n super.init?.();\n\n forwardAttrs(this, this.checkbox, { includeAttrs: forwardAttributes });\n syncAttrs(this, this.checkbox, { includeAttrs: ['checked'] });\n\n // Handle label click to toggle checkbox\n this.labelContent.addEventListener('click', (e) => {\n if (!this.hasAttribute('disabled') && !this.hasAttribute('readonly')) {\n this.checkbox.click();\n }\n });\n\n // we need it in order to set the focus ring and trigger validation on descope-checkbox\n this.handleFocusEventsDispatching([this.checkbox]);\n }\n\n attributeChangedCallback(attrName, oldValue, newValue) {\n super.attributeChangedCallback?.(attrName, oldValue, newValue);\n\n if (attrName === 'readonly') {\n this.onReadOnlyChange(newValue !== null);\n }\n\n if (attrName === 'label') {\n this.onLabelChange();\n }\n }\n\n onLabelChange() {\n const labelValue = this.getAttribute('label');\n if (labelValue) {\n this.labelContent.textContent = labelValue;\n } else {\n this.labelContent.textContent = '';\n }\n }\n\n onReadOnlyChange(val) {\n this.baseElement.setAttribute('inert', val);\n }\n\n getValidity() {\n if (this.isRequired && !this.value) {\n return { valueMissing: true };\n }\n return {};\n }\n}\n\nexport default BooleanInputInternal;\n"],"names":["customElements","define","createBaseInputClass","args","componentName","forwardAttributes","BaseInputClass","baseSelector","observedAttributes","constructor","super","this","innerHTML","wrapperEle","querySelector","checkbox","labelContent","value","checked","val","init","addEventListener","e","isTrusted","focus","includeAttrs","hasAttribute","click","handleFocusEventsDispatching","attributeChangedCallback","attrName","oldValue","newValue","onReadOnlyChange","onLabelChange","labelValue","getAttribute","textContent","baseElement","setAttribute","getValidity","isRequired","valueMissing"],"sourceRoot":""}
1
+ {"version":3,"file":"boolean-fields-descope-boolean-field-internal-index-js.js","mappings":"8JAEAA,eAAeC,OAAO,IAAe,I,sECO9B,MAAMC,EAAuB,IAAIC,KACtC,QACE,KACA,KACA,KACA,KAJF,EAKE,UAAmBA,G,oECZhB,MAAMC,GAAgB,QAAiB,0BAExCC,EAAoB,CAAC,WAAY,UAAW,YAE5CC,GAAiB,OAAqB,CAAEF,gBAAeG,aAAc,QA4F3E,EA1FA,cAAmCD,EACjC,6BAAWE,GACT,MAAO,CAAC,WAAY,QACtB,CAEA,WAAAC,GACEC,QACAC,KAAKC,UAAY,yMAOjBD,KAAKE,WAAaF,KAAKG,cAAc,OACrCH,KAAKI,SAAWJ,KAAKG,cAAc,mBACnCH,KAAKK,aAAeL,KAAKG,cAAc,iBACzC,CAEA,SAAIG,GACF,OAAON,KAAKI,UAAUG,OACxB,CAEA,SAAID,CAAME,GACRR,KAAKI,SAASG,QAAUC,CAC1B,CAEA,WAAID,GACF,OAAOP,KAAKM,KACd,CAEA,WAAIC,CAAQC,GACVR,KAAKM,MAAQE,CACf,CAEA,IAAAC,GACET,KAAKU,iBAAiB,QAAUC,IAC1BA,EAAEC,WACJZ,KAAKI,SAASS,UAGlBd,MAAMU,UAEN,QAAaT,KAAMA,KAAKI,SAAU,CAAEU,aAAcpB,KAClD,QAAUM,KAAMA,KAAKI,SAAU,CAAEU,aAAc,CAAC,aAGhDd,KAAKK,aAAaK,iBAAiB,QAAUC,IACtCX,KAAKe,aAAa,aAAgBf,KAAKe,aAAa,aACvDf,KAAKI,SAASY,UAKlBhB,KAAKiB,6BAA6B,CAACjB,KAAKI,UAC1C,CAEA,wBAAAc,CAAyBC,EAAUC,EAAUC,GAC3CtB,MAAMmB,2BAA2BC,EAAUC,EAAUC,GAEpC,aAAbF,GACFnB,KAAKsB,iBAA8B,OAAbD,GAGP,UAAbF,GACFnB,KAAKuB,eAET,CAEA,aAAAA,GACE,MAAMC,EAAaxB,KAAKyB,aAAa,SAEnCzB,KAAKK,aAAaqB,YADhBF,GAG8B,EAEpC,CAEA,gBAAAF,CAAiBd,GACfR,KAAK2B,YAAYC,aAAa,QAASpB,EACzC,CAEA,WAAAqB,GACE,OAAI7B,KAAK8B,aAAe9B,KAAKM,MACpB,CAAEyB,cAAc,GAElB,CAAC,CACV,E","sources":["webpack://@descope/web-components-ui/./src/components/boolean-fields/descope-boolean-field-internal/index.js","webpack://@descope/web-components-ui/./src/baseClasses/createBaseInputClass.js","webpack://@descope/web-components-ui/./src/components/boolean-fields/descope-boolean-field-internal/BooleanFieldInternal.js"],"sourcesContent":["import BooleanFieldInternal, { componentName } from './BooleanFieldInternal';\n\ncustomElements.define(componentName, BooleanFieldInternal);\n","import { compose } from '../helpers';\nimport {\n changeMixin,\n inputEventsDispatchingMixin,\n inputValidationMixin,\n normalizeBooleanAttributesMixin,\n} from '../mixins';\nimport { createBaseClass } from './createBaseClass';\n\nexport const createBaseInputClass = (...args) =>\n compose(\n inputValidationMixin,\n changeMixin,\n normalizeBooleanAttributesMixin,\n inputEventsDispatchingMixin\n )(createBaseClass(...args));\n","import { createBaseInputClass } from '../../../baseClasses/createBaseInputClass';\nimport { forwardAttrs, getComponentName, syncAttrs } from '../../../helpers/componentHelpers';\n\nexport const componentName = getComponentName('boolean-field-internal');\n\nconst forwardAttributes = ['disabled', 'invalid', 'readonly'];\n\nconst BaseInputClass = createBaseInputClass({ componentName, baseSelector: 'div' });\n\nclass BooleanInputInternal extends BaseInputClass {\n static get observedAttributes() {\n return ['readonly', 'label'];\n }\n\n constructor() {\n super();\n this.innerHTML = `\n\t\t\t<div class=\"wrapper\">\n\t\t\t\t<vaadin-checkbox>\n\t\t\t\t\t<descope-enriched-text class=\"label-content\" slot=\"label\"></descope-enriched-text>\n\t\t\t\t</vaadin-checkbox>\n\t\t\t</div>\n\t\t`;\n this.wrapperEle = this.querySelector('div');\n this.checkbox = this.querySelector('vaadin-checkbox');\n this.labelContent = this.querySelector('.label-content');\n }\n\n get value() {\n return this.checkbox?.checked;\n }\n\n set value(val) {\n this.checkbox.checked = val;\n }\n\n get checked() {\n return this.value;\n }\n\n set checked(val) {\n this.value = val;\n }\n\n init() {\n this.addEventListener('focus', (e) => {\n if (e.isTrusted) {\n this.checkbox.focus();\n }\n });\n super.init?.();\n\n forwardAttrs(this, this.checkbox, { includeAttrs: forwardAttributes });\n syncAttrs(this, this.checkbox, { includeAttrs: ['checked'] });\n\n // Handle label click to toggle checkbox\n this.labelContent.addEventListener('click', (e) => {\n if (!this.hasAttribute('disabled') && !this.hasAttribute('readonly')) {\n this.checkbox.click();\n }\n });\n\n // we need it in order to set the focus ring and trigger validation on descope-checkbox\n this.handleFocusEventsDispatching([this.checkbox]);\n }\n\n attributeChangedCallback(attrName, oldValue, newValue) {\n super.attributeChangedCallback?.(attrName, oldValue, newValue);\n\n if (attrName === 'readonly') {\n this.onReadOnlyChange(newValue !== null);\n }\n\n if (attrName === 'label') {\n this.onLabelChange();\n }\n }\n\n onLabelChange() {\n const labelValue = this.getAttribute('label');\n if (labelValue) {\n this.labelContent.textContent = labelValue;\n } else {\n this.labelContent.textContent = '';\n }\n }\n\n onReadOnlyChange(val) {\n this.baseElement.setAttribute('inert', val);\n }\n\n getValidity() {\n if (this.isRequired && !this.value) {\n return { valueMissing: true };\n }\n return {};\n }\n}\n\nexport default BooleanInputInternal;\n"],"names":["customElements","define","createBaseInputClass","args","componentName","forwardAttributes","BaseInputClass","baseSelector","observedAttributes","constructor","super","this","innerHTML","wrapperEle","querySelector","checkbox","labelContent","value","checked","val","init","addEventListener","e","isTrusted","focus","includeAttrs","hasAttribute","click","handleFocusEventsDispatching","attributeChangedCallback","attrName","oldValue","newValue","onReadOnlyChange","onLabelChange","labelValue","getAttribute","textContent","baseElement","setAttribute","getValidity","isRequired","valueMissing"],"sourceRoot":""}
@@ -1 +1 @@
1
- {"version":3,"file":"boolean-fields-descope-switch-toggle-index-js.js","mappings":";uLAEAA,eAAeC,OAAO,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AAY,CAAC,IAAKzB,EAAOtE,SAAU,UACnCgG,YAAa,CACX,IAAKxB,EAAMxE,SAAU,aACrB,IAAKsE,EAAOtE,SAAU,WAGxBiG,SAAU,CACR,IAAKzB,EAAMxE,SAAU,SACrB,IAAKwE,EAAMxE,SAAU,WAEvBkG,cAAe,IAAK1B,EAAMxE,SAAU,SACpCmG,WAAY,IAAK3B,EAAMxE,SAAU,iBACjCoG,uBAAwB,IAAK5B,EAAMxE,SAAU,cAC7CqG,UAAW,IAAK7B,EAAMxE,SAAU,oBAChCsG,cAAe,IAAK9B,EAAMxE,SAAU,OACpCuG,eAAgB,IAAK/B,EAAMxE,SAAU,QAErCwG,kBAAmB,IAAKlC,EAAOtE,SAAU,iBACzCyG,mBAAoB,IAAKnC,EAAOtE,SAAU,kBAC1C0G,kBAAmB,IAAKpC,EAAOtE,SAAU,iBACzC2G,kBAAmB,IAAKrC,EAAOtE,SAAU,oBAG7C,MACA,QAAgB,CAAE4G,WAAY,CAAC,QAAS,oBACxC,KACA,IA1D+B,EA4D/B,QAAY,CACVC,MAAO,GACPC,eAAgB,oBAChBpH,MAAO,IAAM,YACZ,OAAamF,EAAkBhG,uBAC/B,QAAuBgG,EAAkBhG,+/BAsD1CkI,iBAAkB,CAAC,QAAS,WAAY,SACxC9J,kB","sources":["webpack://@descope/web-components-ui/./src/components/boolean-fields/descope-boolean-field-internal/index.js","webpack://@descope/web-components-ui/./src/baseClasses/createBaseInputClass.js","webpack://@descope/web-components-ui/../../../node_modules/@vaadin/field-base/src/input-controller.js","webpack://@descope/web-components-ui/./src/components/boolean-fields/booleanFieldMixin.js","webpack://@descope/web-components-ui/./src/components/boolean-fields/descope-switch-toggle/index.js","webpack://@descope/web-components-ui/../components/descope-enriched-text/src/component/consts.js","webpack://@descope/web-components-ui/./src/components/boolean-fields/descope-boolean-field-internal/BooleanFieldInternal.js","webpack://@descope/web-components-ui/./src/components/boolean-fields/commonStyles.js","webpack://@descope/web-components-ui/../components/descope-enriched-text/src/component/helpers.js","webpack://@descope/web-components-ui/../components/descope-enriched-text/src/component/index.js","webpack://@descope/web-components-ui/../components/descope-text/src/component/index.js","webpack://@descope/web-components-ui/../components/descope-text/src/component/TextClass.js","webpack://@descope/web-components-ui/../components/descope-link/src/component/LinkClass.js","webpack://@descope/web-components-ui/../components/descope-link/src/component/index.js","webpack://@descope/web-components-ui/../components/descope-enriched-text/src/component/EnrichedTextClass.js","webpack://@descope/web-components-ui/./src/components/boolean-fields/descope-switch-toggle/SwitchToggleClass.js"],"sourcesContent":["import BooleanFieldInternal, { componentName } from './BooleanFieldInternal';\n\ncustomElements.define(componentName, BooleanFieldInternal);\n","import { compose } from '../helpers';\nimport {\n changeMixin,\n inputEventsDispatchingMixin,\n inputValidationMixin,\n normalizeBooleanAttributesMixin,\n} from '../mixins';\nimport { createBaseClass } from './createBaseClass';\n\nexport const createBaseInputClass = (...args) =>\n compose(\n inputValidationMixin,\n changeMixin,\n normalizeBooleanAttributesMixin,\n inputEventsDispatchingMixin\n )(createBaseClass(...args));\n","/**\n * @license\n * Copyright (c) 2021 - 2023 Vaadin Ltd.\n * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/\n */\nimport { SlotController } from '@vaadin/component-base/src/slot-controller.js';\n\n/**\n * A controller to create and initialize slotted `<input>` element.\n */\nexport class InputController extends SlotController {\n constructor(host, callback) {\n super(host, 'input', 'input', {\n initializer: (node, host) => {\n if (host.value) {\n node.value = host.value;\n }\n if (host.type) {\n node.setAttribute('type', host.type);\n }\n\n // Ensure every instance has unique ID\n node.id = this.defaultId;\n\n if (typeof callback === 'function') {\n callback(node);\n }\n },\n useUniqueId: true,\n });\n }\n}\n","import { forwardAttrs, forwardProps, syncAttrs } from '../../helpers/componentHelpers';\nimport { componentName as descopeInternalComponentName } from './descope-boolean-field-internal/BooleanFieldInternal';\n\nexport const booleanFieldMixin = (superclass) =>\n class BooleanFieldMixinClass extends superclass {\n init() {\n super.init?.();\n\n const template = document.createElement('template');\n template.innerHTML = `\n\t\t\t\t<${descopeInternalComponentName}\n\t\t\t\t\ttabindex=\"-1\"\n\t\t\t\t\tslot=\"input\"\n\t\t\t\t></${descopeInternalComponentName}>\n\t\t\t`;\n\n this.baseElement.appendChild(template.content.cloneNode(true));\n this.inputElement = this.shadowRoot.querySelector(descopeInternalComponentName);\n this.checkbox = this.inputElement.querySelector('vaadin-checkbox');\n\n forwardAttrs(this, this.inputElement, {\n includeAttrs: [\n 'required',\n 'full-width',\n 'size',\n 'label',\n 'invalid',\n 'disabled',\n 'readonly',\n ],\n });\n\n forwardProps(this.inputElement, this, ['checked']);\n syncAttrs(this, this.inputElement, { includeAttrs: ['checked'] });\n }\n };\n","import { componentName, SwitchToggleClass } from './SwitchToggleClass';\nimport '@vaadin/checkbox';\nimport '@vaadin/text-field';\nimport '@descope-ui/descope-enriched-text';\nimport '../descope-boolean-field-internal';\n\ncustomElements.define(componentName, SwitchToggleClass);\n\nexport { SwitchToggleClass, componentName };\n","export const disableRules = [\n 'blockquote',\n 'list',\n 'image',\n 'table',\n 'code',\n 'hr',\n 'backticks',\n 'fence',\n 'reference',\n 'heading',\n 'lheading',\n 'html_block',\n];\n","import { createBaseInputClass } from '../../../baseClasses/createBaseInputClass';\nimport {\n forwardAttrs,\n observeAttributes,\n getComponentName,\n syncAttrs,\n} from '../../../helpers/componentHelpers';\n\nexport const componentName = getComponentName('boolean-field-internal');\n\nconst forwardAttributes = ['disabled', 'invalid', 'readonly'];\n\nconst BaseInputClass = createBaseInputClass({ componentName, baseSelector: 'div' });\n\nclass BooleanInputInternal extends BaseInputClass {\n static get observedAttributes() {\n return ['readonly', 'label'];\n }\n\n constructor() {\n super();\n this.innerHTML = `\n\t\t\t<div class=\"wrapper\">\n\t\t\t\t<vaadin-checkbox>\n\t\t\t\t\t<descope-enriched-text class=\"label-content\" slot=\"label\"></descope-enriched-text>\n\t\t\t\t</vaadin-checkbox>\n\t\t\t</div>\n\t\t`;\n this.wrapperEle = this.querySelector('div');\n this.checkbox = this.querySelector('vaadin-checkbox');\n this.labelContent = this.querySelector('.label-content');\n }\n\n get value() {\n return this.checkbox?.checked;\n }\n\n set value(val) {\n this.checkbox.checked = val;\n }\n\n get checked() {\n return this.value;\n }\n\n set checked(val) {\n this.value = val;\n }\n\n init() {\n this.addEventListener('focus', (e) => {\n if (e.isTrusted) {\n this.checkbox.focus();\n }\n });\n super.init?.();\n\n forwardAttrs(this, this.checkbox, { includeAttrs: forwardAttributes });\n syncAttrs(this, this.checkbox, { includeAttrs: ['checked'] });\n\n // Handle label click to toggle checkbox\n this.labelContent.addEventListener('click', (e) => {\n if (!this.hasAttribute('disabled') && !this.hasAttribute('readonly')) {\n this.checkbox.click();\n }\n });\n\n // we need it in order to set the focus ring and trigger validation on descope-checkbox\n this.handleFocusEventsDispatching([this.checkbox]);\n }\n\n attributeChangedCallback(attrName, oldValue, newValue) {\n super.attributeChangedCallback?.(attrName, oldValue, newValue);\n\n if (attrName === 'readonly') {\n this.onReadOnlyChange(newValue !== null);\n }\n\n if (attrName === 'label') {\n this.onLabelChange();\n }\n }\n\n onLabelChange() {\n const labelValue = this.getAttribute('label');\n if (labelValue) {\n this.labelContent.textContent = labelValue;\n } else {\n this.labelContent.textContent = '';\n }\n }\n\n onReadOnlyChange(val) {\n this.baseElement.setAttribute('inert', val);\n }\n\n getValidity() {\n if (this.isRequired && !this.value) {\n return { valueMissing: true };\n }\n return {};\n }\n}\n\nexport default BooleanInputInternal;\n","import { EnrichedTextClass } from '@descope-ui/descope-enriched-text/class';\nimport { resetInputFieldDefaultWidth } from '../../helpers/themeHelpers/resetHelpers';\n\nexport default (cssVarList) => `\n:host {\n\tdisplay: inline-flex;\n}\n\n${resetInputFieldDefaultWidth()}\n\n.wrapper {\n\tdisplay: flex;\n\tbox-sizing: border-box;\n}\nvaadin-text-field {\n\tposition: relative;\n\tpadding: 0;\n\tdisplay: inline-flex;\n\talign-items: flex-start;\n}\nvaadin-text-field::before {\n content: unset;\n}\nvaadin-text-field::part(label) {\n position: absolute;\n top: 0;\n}\nvaadin-text-field::part(input-field) {\n\tpadding: 0;\n\tbackground: none;\n\tmin-height: 0;\n}\nvaadin-text-field::part(input-field)::after {\n background: none;\n}\nvaadin-text-field[focus-ring]::part(input-field) {\n\tbox-shadow: none;\n}\n\nvaadin-checkbox [slot=\"label\"] {\n align-self: flex-start;\n padding: 0;\n}\n[required] vaadin-checkbox [slot=\"label\"]:not(:empty) {\n\tpadding-inline-end: 1em;\n}\ndescope-boolean-field-internal {\n -webkit-mask-image: none;\n min-height: initial;\n}\n\ndescope-enriched-text[empty] {\n\t${EnrichedTextClass.cssVarList.hostDisplay}: none;\n}\n\ndescope-enriched-text {\n\t${EnrichedTextClass.cssVarList.hostDirection}: var(${cssVarList.hostDirection});\n}\n\n`;\n","export const decodeHTML = (html) => {\n const textArea = document.createElement('textarea');\n textArea.innerHTML = html;\n return textArea.value;\n};\n","import '@descope-ui/descope-link';\n\nimport { componentName, EnrichedTextClass } from './EnrichedTextClass';\n\ncustomElements.define(componentName, EnrichedTextClass);\n\nexport { EnrichedTextClass, componentName };\n","import { componentName, TextClass } from './TextClass';\n\ncustomElements.define(componentName, TextClass);\n\nexport { TextClass, componentName };\n","import {\n createStyleMixin,\n draggableMixin,\n componentNameValidationMixin,\n} from '@descope-ui/common/components-mixins';\nimport { compose } from '@descope-ui/common/utils';\nimport {\n getComponentName,\n injectStyle,\n observeChildren,\n} from '@descope-ui/common/components-helpers';\nimport { createBaseClass } from '@descope-ui/common/base-classes';\n\nexport const componentName = getComponentName('text');\n\nclass RawText extends createBaseClass({\n componentName,\n baseSelector: ':host > slot',\n}) {\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n <slot part=\"text-wrapper\"></slot>\n `;\n\n injectStyle(`\n :host {\n display: inline-block;\n line-height: 1em;\n }\n :host > slot {\n width: 100%;\n display: inline-block;\n }\n `, this);\n }\n\n get hideWhenEmpty() {\n return this.getAttribute('hide-when-empty') === 'true';\n }\n\n init() {\n super.init();\n\n observeChildren(this, () => {\n const hasChildren = !!this.childNodes.length;\n this.style.display = !hasChildren && this.hideWhenEmpty ? 'none' : '';\n });\n }\n}\n\nconst { host } = {\n host: { selector: () => ':host' }\n}\n\nexport const TextClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { ...host, property: 'width' },\n hostDirection: { ...host, property: 'direction' },\n fontSize: {},\n textColor: [\n { property: 'color' }\n ],\n textLineHeight: { property: 'line-height' },\n textLetterSpacing: { property: 'letter-spacing' },\n textShadow: {},\n textAlign: {},\n textTransform: {},\n fontFamily: {},\n fontStyle: {},\n fontWeight: {},\n borderWidth: {},\n borderStyle: {},\n borderColor: {},\n },\n }),\n draggableMixin,\n componentNameValidationMixin,\n)(RawText);\n","import {\n createStyleMixin,\n draggableMixin,\n componentNameValidationMixin,\n} from '@descope-ui/common/components-mixins';\nimport { compose } from '@descope-ui/common/utils';\nimport {\n getComponentName,\n forwardAttrs,\n injectStyle,\n} from '@descope-ui/common/components-helpers';\nimport { createBaseClass } from '@descope-ui/common/base-classes';\nimport { TextClass } from '@descope-ui/descope-text/class';\n\nexport const componentName = getComponentName('link');\n\nclass RawLink extends createBaseClass({ componentName, baseSelector: ':host a' }) {\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n\t\t<div>\n\t\t\t<descope-text part=\"wrapper\">\n\t\t\t\t<a>\n\t\t\t\t\t<slot></slot>\n\t\t\t\t</a>\n\t\t\t</descope-text>\n\t\t</div>\n\t\t`;\n\n injectStyle(\n `\n :host {\n\t\t\tdisplay: inline-block;\n line-height: 1em;\n\t\t}\n\t\t:host a {\n\t\t\tdisplay: inline;\n\t\t}\n\n :host([ellipsis=\"true\"]) descope-text {\n display: inline-flex;\n }\n :host([ellipsis=\"true\"]) descope-text::part(text-wrapper) {\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n }\n `,\n this\n );\n\n forwardAttrs(this, this.shadowRoot.querySelector('a'), {\n includeAttrs: ['href', 'target', 'tooltip'],\n mapAttrs: {\n tooltip: 'title',\n },\n });\n\n forwardAttrs(this, this.shadowRoot.querySelector('descope-text'), {\n includeAttrs: ['mode', 'variant'],\n });\n }\n}\n\nconst selectors = {\n host: { selector: () => ':host' },\n link: { selector: () => ':host a' },\n anchor: {},\n wrapper: { selector: () => ':host > div' },\n text: { selector: () => TextClass.componentName },\n};\n\nconst { anchor, text, host, wrapper, link } = selectors;\n\nexport const LinkClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { ...host, property: 'width' },\n hostDirection: { ...text, property: 'direction' },\n textAlign: wrapper,\n textDecoration: { ...link, property: 'text-decoration', fallback: 'none' },\n textColor: [\n { ...anchor, property: 'color' },\n { ...text, property: TextClass.cssVarList.textColor },\n ],\n cursor: anchor,\n },\n }),\n draggableMixin,\n componentNameValidationMixin\n)(RawLink);\n","import { componentName, LinkClass } from './LinkClass';\nimport '@descope-ui/descope-text';\n\ncustomElements.define(componentName, LinkClass);\n\nexport { LinkClass, componentName };\n","/* eslint-disable no-param-reassign */\n\nimport MarkdownIt from 'markdown-it';\nimport { createStyleMixin, draggableMixin, componentNameValidationMixin } from '@descope-ui/common/components-mixins';\nimport { compose } from '@descope-ui/common/utils';\nimport { disableRules } from './consts';\nimport { createBaseClass } from '@descope-ui/common/base-classes';\nimport { decodeHTML } from './helpers';\nimport { getComponentName, injectStyle, observeChildren } from '@descope-ui/common/components-helpers';\n\nexport const componentName = getComponentName('enriched-text');\n\nclass EnrichedText extends createBaseClass({ componentName, baseSelector: ':host > div' }) {\n #origLinkRenderer;\n\n #origEmRenderer;\n\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n <div class=\"content\"></div>\n `;\n\n injectStyle(\n `\n :host {\n line-height: 1em;\n word-break: break-word;\n }\n :host > slot {\n width: 100%;\n display: inline-block;\n }\n *, *:last-child {\n margin: 0;\n }\n h1,\n h2,\n h3,\n h4,\n h5,\n h6,\n p {\n margin-bottom: 1em;\n }\n a {\n cursor: pointer;\n }\n blockquote {\n padding: 0 2em;\n }\n u {\n text-decoration: underline\n }\n s {\n color: currentColor;\n }\n `,\n this\n );\n\n this.#initProcessor();\n\n observeChildren(this, this.#parseChildren.bind(this));\n }\n\n static get observedAttributes() {\n return ['readonly', 'link-target-blank'];\n }\n\n attributeChangedCallback(attrName, oldValue, newValue) {\n super.attributeChangedCallback?.(attrName, oldValue, newValue);\n\n if (newValue !== oldValue) {\n if (attrName === 'readonly') {\n this.onReadOnlyChange(newValue === 'true');\n }\n\n if (attrName === 'link-target-blank') {\n this.#initProcessor();\n }\n }\n }\n\n // We're overriding the rule for em with single underscore to perform as underline. (_underline_)\n customUnderlineRenderer() {\n this.processor.renderer.rules.em_open = (tokens, idx, options, env, self) => {\n if (tokens[idx].markup === '_') tokens[idx].tag = 'u';\n return this.#origEmRenderer(tokens, idx, options, env, self);\n };\n this.processor.renderer.rules.em_close = (tokens, idx, options, env, self) => {\n if (tokens[idx].markup === '_') tokens[idx].tag = 'u';\n return this.#origEmRenderer(tokens, idx, options, env, self);\n };\n }\n\n #customizeLinkRenderer() {\n if (this.linkTargetBlank) {\n this.processor.renderer.rules.link_open = (tokens, idx, options, env, self) => {\n // Add a new `target` attribute, or replace the value of the existing one.\n tokens[idx].attrSet('target', '_blank');\n // Pass the token to the default renderer.\n return this.#origLinkRenderer(tokens, idx, options, env, self);\n };\n } else {\n this.processor.renderer.rules.link_open = this.#origLinkRenderer;\n }\n }\n\n #disableCustomRules() {\n if (!this.processor) {\n return;\n }\n this.processor.disable(disableRules);\n }\n\n #updateProcessorRules() {\n this.#disableCustomRules();\n }\n\n #storeOrigRenderers() {\n const defaultLinkRenderer = (tokens, idx, options, _, self) =>\n self.renderToken(tokens, idx, options);\n this.#origLinkRenderer = this.processor.renderer.rules.link_open || defaultLinkRenderer;\n\n const defaultStrongRenderer = (tokens, idx, options, _, self) =>\n self.renderToken(tokens, idx, options);\n this.#origEmRenderer = this.processor.renderer.rules.em_open || defaultStrongRenderer;\n }\n\n #initProcessor() {\n this.processor = new MarkdownIt('commonmark', { html: true });\n this.#storeOrigRenderers();\n this.#updateProcessorRules();\n this.#customizeLinkRenderer();\n this.customUnderlineRenderer();\n }\n\n get linkTargetBlank() {\n return this.getAttribute('link-target-blank') === 'true';\n }\n\n get contentNode() {\n return this.shadowRoot.querySelector('.content');\n }\n\n #parseChildren() {\n if (!this.processor) {\n return;\n }\n\n let html = decodeHTML(this.innerHTML);\n\n if (!html?.trim() && this.isConnected) {\n this.setAttribute('empty', 'true');\n } else {\n this.removeAttribute('empty');\n }\n\n try {\n const tokens = this.processor.parse(html, { references: undefined });\n html = this.processor.renderer.render(tokens, { html: true, breaks: true });\n } catch (e) {\n // eslint-disable-next-line no-console\n console.warn('Not parsing invalid markdown token');\n }\n\n this.contentNode.innerHTML = html;\n this.contentNode.firstChild?.setAttribute('part', 'content');\n }\n\n onReadOnlyChange(isReadOnly) {\n if (isReadOnly) {\n this.contentNode.setAttribute('inert', isReadOnly);\n } else {\n this.contentNode.removeAttribute('inert');\n }\n }\n}\n\nexport const EnrichedTextClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { selector: () => ':host', property: 'width' },\n hostDisplay: { selector: () => ':host', property: 'display', fallback: 'inline-block' },\n hostDirection: { selector: () => ':host', property: 'direction' },\n fontSize: {},\n fontFamily: {},\n fontWeight: {},\n fontWeightBold: [\n { selector: () => ':host strong', property: 'font-weight' },\n { selector: () => ':host b', property: 'font-weight' },\n ],\n textColor: { property: 'color' },\n textLineHeight: { property: 'line-height' },\n textAlign: {},\n linkColor: { selector: 'a', property: 'color' },\n linkTextDecoration: { selector: 'a', property: 'text-decoration' },\n linkHoverTextDecoration: { selector: 'a:hover', property: 'text-decoration' },\n minHeight: {},\n minWidth: {},\n },\n }),\n createStyleMixin({ componentNameOverride: getComponentName('link') }),\n createStyleMixin({ componentNameOverride: getComponentName('text') }),\n draggableMixin,\n componentNameValidationMixin\n)(EnrichedText);\n","import { EnrichedTextClass } from '@descope-ui/descope-enriched-text/class';\nimport { getComponentName } from '../../../helpers/componentHelpers';\nimport { compose } from '../../../helpers';\nimport {\n createStyleMixin,\n proxyInputMixin,\n draggableMixin,\n componentNameValidationMixin,\n createProxy,\n} from '../../../mixins';\nimport { booleanFieldMixin } from '../booleanFieldMixin';\nimport commonStyles from '../commonStyles';\nimport { useHostExternalPadding } from '../../../helpers/themeHelpers/resetHelpers';\n\nexport const componentName = getComponentName('switch-toggle');\n\nconst {\n host,\n component,\n checkboxElement: track,\n checkboxSurface: knob,\n checkboxLabel,\n requiredIndicator,\n helperText,\n errorMessage,\n} = {\n host: { selector: () => ':host' },\n requiredIndicator: {\n selector: '[required] vaadin-checkbox [slot=\"label\"]:not(:empty)::part(content)::after',\n },\n component: { selector: 'vaadin-checkbox' },\n checkboxElement: { selector: 'vaadin-checkbox::part(checkbox)' },\n checkboxSurface: { selector: 'vaadin-checkbox::part(checkbox)::after' },\n checkboxLabel: { selector: 'vaadin-checkbox [slot=\"label\"]:not(:empty)' },\n helperText: { selector: '::part(helper-text)' },\n errorMessage: { selector: '::part(error-message)' },\n};\n\nexport const SwitchToggleClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { ...host, property: 'width' },\n hostDirection: { ...host, property: 'direction' },\n\n fontSize: [component, checkboxLabel, checkboxLabel],\n fontFamily: [checkboxLabel, helperText, errorMessage],\n\n labelTextColor: [\n { ...checkboxLabel, property: 'color' },\n { ...checkboxLabel, property: '-webkit-text-fill-color' },\n ],\n labelSpacing: { ...checkboxLabel, property: 'padding-inline-start' },\n labelLineHeight: { ...checkboxLabel, property: 'line-height' },\n labelFontWeight: { ...checkboxLabel, property: 'font-weight' },\n labelRequiredIndicator: { ...requiredIndicator, property: 'content' },\n\n errorMessageTextColor: { ...errorMessage, property: 'color' },\n\n errorMessageIcon: { ...errorMessage, property: 'background-image' },\n errorMessageIconSize: { ...errorMessage, property: 'background-size' },\n errorMessageIconPadding: { ...errorMessage, property: 'padding-inline-start' },\n errorMessageIconRepeat: { ...errorMessage, property: 'background-repeat' },\n errorMessageIconPosition: { ...errorMessage, property: 'background-position' },\n errorMessageFontSize: { ...errorMessage, property: 'font-size' },\n\n trackBorderWidth: { ...track, property: 'border-width' },\n trackBorderStyle: { ...track, property: 'border-style' },\n trackBorderColor: { ...track, property: 'border-color' },\n trackBackgroundColor: { ...track, property: 'background-color' },\n trackBorderRadius: { ...track, property: 'border-radius' },\n trackWidth: [{ ...track, property: 'width' }],\n trackHeight: [\n { ...knob, property: 'font-size' },\n { ...track, property: 'height' },\n ],\n\n knobSize: [\n { ...knob, property: 'width' },\n { ...knob, property: 'height' },\n ],\n knobTextColor: { ...knob, property: 'color' },\n knobRadius: { ...knob, property: 'border-radius' },\n knobTransitionDuration: { ...knob, property: 'transition' },\n knobColor: { ...knob, property: 'background-color' },\n knobTopOffset: { ...knob, property: 'top' },\n knobLeftOffset: { ...knob, property: 'left' },\n\n inputOutlineWidth: { ...track, property: 'outline-width' },\n inputOutlineOffset: { ...track, property: 'outline-offset' },\n inputOutlineColor: { ...track, property: 'outline-color' },\n inputOutlineStyle: { ...track, property: 'outline-style' },\n },\n }),\n draggableMixin,\n proxyInputMixin({ proxyProps: ['value', 'selectionStart'] }),\n componentNameValidationMixin,\n booleanFieldMixin\n)(\n createProxy({\n slots: [],\n wrappedEleName: 'vaadin-text-field',\n style: () => `\n\t\t\t${commonStyles(SwitchToggleClass.cssVarList)}\n\t\t\t${useHostExternalPadding(SwitchToggleClass.cssVarList)}\n\n :host {\n\t\t\t\tdisplay: inline-flex;\n\t\t\t\tmax-width: 100%;\n }\n\n :host ::part(error-message) {\n direction: ltr;\n }\n\n vaadin-text-field {\n width: 100%;\n }\n\n vaadin-text-field::part(input-field)::after {\n content: none;\n }\n\n descope-boolean-field-internal {\n\t\t\t\tpadding: 0;\n width: 100%;\n }\n\n vaadin-text-field::part(input-field) {\n cursor: pointer;\n }\n\n vaadin-checkbox {\n cursor: pointer;\n }\n\n vaadin-checkbox [slot=\"label\"]:not(:empty) {\n cursor: pointer;\n\t\t\t}\n\n vaadin-checkbox::part(checkbox) {\n margin: 0;\n\t\t\t}\n\n vaadin-checkbox::part(checkbox)::before {\n content: '';\n\t\t\t}\n\n vaadin-checkbox[active]::part(checkbox) {\n\t\t\t\ttransform: none;\n\t\t\t}\n\n vaadin-checkbox::part(checkbox)::after {\n\t\t\t\tposition: absolute;\n\t\t\t\topacity: 1;\n\t\t\t\tcontent: '';\n\t\t\t}\n\t\t`,\n excludeAttrsSync: ['label', 'tabindex', 'style'],\n componentName,\n })\n);\n"],"names":["customElements","define","createBaseInputClass","args","InputController","constructor","host","callback","super","initializer","node","value","type","setAttribute","id","this","defaultId","useUniqueId","booleanFieldMixin","superclass","init","template","document","createElement","innerHTML","baseElement","appendChild","content","cloneNode","inputElement","shadowRoot","querySelector","checkbox","includeAttrs","disableRules","componentName","forwardAttributes","BaseInputClass","baseSelector","observedAttributes","wrapperEle","labelContent","checked","val","addEventListener","e","isTrusted","focus","hasAttribute","click","handleFocusEventsDispatching","attributeChangedCallback","attrName","oldValue","newValue","onReadOnlyChange","onLabelChange","labelValue","getAttribute","textContent","getValidity","isRequired","valueMissing","cssVarList","hostDisplay","hostDirection","decodeHTML","html","textArea","RawText","attachShadow","mode","hideWhenEmpty","hasChildren","childNodes","length","style","display","selector","TextClass","mappings","hostWidth","property","fontSize","textColor","textLineHeight","textLetterSpacing","textShadow","textAlign","textTransform","fontFamily","fontStyle","fontWeight","borderWidth","borderStyle","borderColor","RawLink","mapAttrs","tooltip","selectors","link","anchor","wrapper","text","LinkClass","textDecoration","fallback","cursor","EnrichedText","bind","customUnderlineRenderer","processor","renderer","rules","em_open","tokens","idx","options","env","self","markup","tag","em_close","linkTargetBlank","link_open","attrSet","disable","_","renderToken","contentNode","trim","isConnected","removeAttribute","parse","references","undefined","render","breaks","console","warn","firstChild","isReadOnly","EnrichedTextClass","fontWeightBold","linkColor","linkTextDecoration","linkHoverTextDecoration","minHeight","minWidth","componentNameOverride","component","checkboxElement","track","checkboxSurface","knob","checkboxLabel","requiredIndicator","helperText","errorMessage","SwitchToggleClass","labelTextColor","labelSpacing","labelLineHeight","labelFontWeight","labelRequiredIndicator","errorMessageTextColor","errorMessageIcon","errorMessageIconSize","errorMessageIconPadding","errorMessageIconRepeat","errorMessageIconPosition","errorMessageFontSize","trackBorderWidth","trackBorderStyle","trackBorderColor","trackBackgroundColor","trackBorderRadius","trackWidth","trackHeight","knobSize","knobTextColor","knobRadius","knobTransitionDuration","knobColor","knobTopOffset","knobLeftOffset","inputOutlineWidth","inputOutlineOffset","inputOutlineColor","inputOutlineStyle","proxyProps","slots","wrappedEleName","excludeAttrsSync"],"sourceRoot":""}
1
+ {"version":3,"file":"boolean-fields-descope-switch-toggle-index-js.js","mappings":";uLAEAA,eAAeC,OAAO,IAAe,I,sECO9B,MAAMC,EAAuB,IAAIC,KACtC,QACE,KACA,KACA,KACA,KAJF,EAKE,UAAmBA,G,kDCLhB,MAAMC,UAAwB,IACnC,WAAAC,CAAYC,EAAMC,GAChBC,MAAMF,EAAM,QAAS,QAAS,CAC5BG,YAAa,CAACC,EAAMJ,KACdA,EAAKK,QACPD,EAAKC,MAAQL,EAAKK,OAEhBL,EAAKM,MACPF,EAAKG,aAAa,OAAQP,EAAKM,MAIjCF,EAAKI,GAAKC,KAAKC,UAES,mBAAbT,GACTA,EAASG,IAGbO,aAAa,GAEjB,E,6DC3BK,MAAMC,EAAqBC,GAChC,cAAqCA,EACnC,IAAAC,GACEZ,MAAMY,SAEN,MAAMC,EAAWC,SAASC,cAAc,YACxCF,EAASG,UAAY,cACpB,oEAGE,eAGHT,KAAKU,YAAYC,YAAYL,EAASM,QAAQC,WAAU,IACxDb,KAAKc,aAAed,KAAKe,WAAWC,cAAc,KAClDhB,KAAKiB,SAAWjB,KAAKc,aAAaE,cAAc,oBAEhD,QAAahB,KAAMA,KAAKc,aAAc,CACpCI,aAAc,CACZ,WACA,aACA,OACA,QACA,UACA,WACA,eAIJ,OAAalB,KAAKc,aAAcd,KAAM,CA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+/BAsD1CkI,iBAAkB,CAAC,QAAS,WAAY,SACxC9J,kB","sources":["webpack://@descope/web-components-ui/./src/components/boolean-fields/descope-boolean-field-internal/index.js","webpack://@descope/web-components-ui/./src/baseClasses/createBaseInputClass.js","webpack://@descope/web-components-ui/../../../node_modules/@vaadin/field-base/src/input-controller.js","webpack://@descope/web-components-ui/./src/components/boolean-fields/booleanFieldMixin.js","webpack://@descope/web-components-ui/./src/components/boolean-fields/descope-switch-toggle/index.js","webpack://@descope/web-components-ui/../components/descope-enriched-text/src/component/consts.js","webpack://@descope/web-components-ui/./src/components/boolean-fields/descope-boolean-field-internal/BooleanFieldInternal.js","webpack://@descope/web-components-ui/./src/components/boolean-fields/commonStyles.js","webpack://@descope/web-components-ui/../components/descope-enriched-text/src/component/helpers.js","webpack://@descope/web-components-ui/../components/descope-enriched-text/src/component/index.js","webpack://@descope/web-components-ui/../components/descope-text/src/component/index.js","webpack://@descope/web-components-ui/../components/descope-text/src/component/TextClass.js","webpack://@descope/web-components-ui/../components/descope-link/src/component/LinkClass.js","webpack://@descope/web-components-ui/../components/descope-link/src/component/index.js","webpack://@descope/web-components-ui/../components/descope-enriched-text/src/component/EnrichedTextClass.js","webpack://@descope/web-components-ui/./src/components/boolean-fields/descope-switch-toggle/SwitchToggleClass.js"],"sourcesContent":["import BooleanFieldInternal, { componentName } from './BooleanFieldInternal';\n\ncustomElements.define(componentName, BooleanFieldInternal);\n","import { compose } from '../helpers';\nimport {\n changeMixin,\n inputEventsDispatchingMixin,\n inputValidationMixin,\n normalizeBooleanAttributesMixin,\n} from '../mixins';\nimport { createBaseClass } from './createBaseClass';\n\nexport const createBaseInputClass = (...args) =>\n compose(\n inputValidationMixin,\n changeMixin,\n normalizeBooleanAttributesMixin,\n inputEventsDispatchingMixin\n )(createBaseClass(...args));\n","/**\n * @license\n * Copyright (c) 2021 - 2023 Vaadin Ltd.\n * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/\n */\nimport { SlotController } from '@vaadin/component-base/src/slot-controller.js';\n\n/**\n * A controller to create and initialize slotted `<input>` element.\n */\nexport class InputController extends SlotController {\n constructor(host, callback) {\n super(host, 'input', 'input', {\n initializer: (node, host) => {\n if (host.value) {\n node.value = host.value;\n }\n if (host.type) {\n node.setAttribute('type', host.type);\n }\n\n // Ensure every instance has unique ID\n node.id = this.defaultId;\n\n if (typeof callback === 'function') {\n callback(node);\n }\n },\n useUniqueId: true,\n });\n }\n}\n","import { forwardAttrs, forwardProps, syncAttrs } from '../../helpers/componentHelpers';\nimport { componentName as descopeInternalComponentName } from './descope-boolean-field-internal/BooleanFieldInternal';\n\nexport const booleanFieldMixin = (superclass) =>\n class BooleanFieldMixinClass extends superclass {\n init() {\n super.init?.();\n\n const template = document.createElement('template');\n template.innerHTML = `\n\t\t\t\t<${descopeInternalComponentName}\n\t\t\t\t\ttabindex=\"-1\"\n\t\t\t\t\tslot=\"input\"\n\t\t\t\t></${descopeInternalComponentName}>\n\t\t\t`;\n\n this.baseElement.appendChild(template.content.cloneNode(true));\n this.inputElement = this.shadowRoot.querySelector(descopeInternalComponentName);\n this.checkbox = this.inputElement.querySelector('vaadin-checkbox');\n\n forwardAttrs(this, this.inputElement, {\n includeAttrs: [\n 'required',\n 'full-width',\n 'size',\n 'label',\n 'invalid',\n 'disabled',\n 'readonly',\n ],\n });\n\n forwardProps(this.inputElement, this, ['checked']);\n syncAttrs(this, this.inputElement, { includeAttrs: ['checked'] });\n }\n };\n","import { componentName, SwitchToggleClass } from './SwitchToggleClass';\nimport '@vaadin/checkbox';\nimport '@vaadin/text-field';\nimport '@descope-ui/descope-enriched-text';\nimport '../descope-boolean-field-internal';\n\ncustomElements.define(componentName, SwitchToggleClass);\n\nexport { SwitchToggleClass, componentName };\n","export const disableRules = [\n 'blockquote',\n 'list',\n 'image',\n 'table',\n 'code',\n 'hr',\n 'backticks',\n 'fence',\n 'reference',\n 'heading',\n 'lheading',\n 'html_block',\n];\n","import { createBaseInputClass } from '../../../baseClasses/createBaseInputClass';\nimport { forwardAttrs, getComponentName, syncAttrs } from '../../../helpers/componentHelpers';\n\nexport const componentName = getComponentName('boolean-field-internal');\n\nconst forwardAttributes = ['disabled', 'invalid', 'readonly'];\n\nconst BaseInputClass = createBaseInputClass({ componentName, baseSelector: 'div' });\n\nclass BooleanInputInternal extends BaseInputClass {\n static get observedAttributes() {\n return ['readonly', 'label'];\n }\n\n constructor() {\n super();\n this.innerHTML = `\n\t\t\t<div class=\"wrapper\">\n\t\t\t\t<vaadin-checkbox>\n\t\t\t\t\t<descope-enriched-text class=\"label-content\" slot=\"label\"></descope-enriched-text>\n\t\t\t\t</vaadin-checkbox>\n\t\t\t</div>\n\t\t`;\n this.wrapperEle = this.querySelector('div');\n this.checkbox = this.querySelector('vaadin-checkbox');\n this.labelContent = this.querySelector('.label-content');\n }\n\n get value() {\n return this.checkbox?.checked;\n }\n\n set value(val) {\n this.checkbox.checked = val;\n }\n\n get checked() {\n return this.value;\n }\n\n set checked(val) {\n this.value = val;\n }\n\n init() {\n this.addEventListener('focus', (e) => {\n if (e.isTrusted) {\n this.checkbox.focus();\n }\n });\n super.init?.();\n\n forwardAttrs(this, this.checkbox, { includeAttrs: forwardAttributes });\n syncAttrs(this, this.checkbox, { includeAttrs: ['checked'] });\n\n // Handle label click to toggle checkbox\n this.labelContent.addEventListener('click', (e) => {\n if (!this.hasAttribute('disabled') && !this.hasAttribute('readonly')) {\n this.checkbox.click();\n }\n });\n\n // we need it in order to set the focus ring and trigger validation on descope-checkbox\n this.handleFocusEventsDispatching([this.checkbox]);\n }\n\n attributeChangedCallback(attrName, oldValue, newValue) {\n super.attributeChangedCallback?.(attrName, oldValue, newValue);\n\n if (attrName === 'readonly') {\n this.onReadOnlyChange(newValue !== null);\n }\n\n if (attrName === 'label') {\n this.onLabelChange();\n }\n }\n\n onLabelChange() {\n const labelValue = this.getAttribute('label');\n if (labelValue) {\n this.labelContent.textContent = labelValue;\n } else {\n this.labelContent.textContent = '';\n }\n }\n\n onReadOnlyChange(val) {\n this.baseElement.setAttribute('inert', val);\n }\n\n getValidity() {\n if (this.isRequired && !this.value) {\n return { valueMissing: true };\n }\n return {};\n }\n}\n\nexport default BooleanInputInternal;\n","import { EnrichedTextClass } from '@descope-ui/descope-enriched-text/class';\nimport { resetInputFieldDefaultWidth } from '../../helpers/themeHelpers/resetHelpers';\n\nexport default (cssVarList) => `\n:host {\n\tdisplay: inline-flex;\n}\n\n${resetInputFieldDefaultWidth()}\n\n.wrapper {\n\tdisplay: flex;\n\tbox-sizing: border-box;\n}\nvaadin-text-field {\n\tposition: relative;\n\tpadding: 0;\n\tdisplay: inline-flex;\n\talign-items: flex-start;\n}\nvaadin-text-field::before {\n content: unset;\n}\nvaadin-text-field::part(label) {\n position: absolute;\n top: 0;\n}\nvaadin-text-field::part(input-field) {\n\tpadding: 0;\n\tbackground: none;\n\tmin-height: 0;\n}\nvaadin-text-field::part(input-field)::after {\n background: none;\n}\nvaadin-text-field[focus-ring]::part(input-field) {\n\tbox-shadow: none;\n}\n\nvaadin-checkbox [slot=\"label\"] {\n align-self: flex-start;\n padding: 0;\n}\n[required] vaadin-checkbox [slot=\"label\"]:not(:empty) {\n\tpadding-inline-end: 1em;\n}\ndescope-boolean-field-internal {\n -webkit-mask-image: none;\n min-height: initial;\n}\n\ndescope-enriched-text[empty] {\n\t${EnrichedTextClass.cssVarList.hostDisplay}: none;\n}\n\ndescope-enriched-text {\n\t${EnrichedTextClass.cssVarList.hostDirection}: var(${cssVarList.hostDirection});\n}\n\n`;\n","export const decodeHTML = (html) => {\n const textArea = document.createElement('textarea');\n textArea.innerHTML = html;\n return textArea.value;\n};\n","import '@descope-ui/descope-link';\n\nimport { componentName, EnrichedTextClass } from './EnrichedTextClass';\n\ncustomElements.define(componentName, EnrichedTextClass);\n\nexport { EnrichedTextClass, componentName };\n","import { componentName, TextClass } from './TextClass';\n\ncustomElements.define(componentName, TextClass);\n\nexport { TextClass, componentName };\n","import {\n createStyleMixin,\n draggableMixin,\n componentNameValidationMixin,\n} from '@descope-ui/common/components-mixins';\nimport { compose } from '@descope-ui/common/utils';\nimport {\n getComponentName,\n injectStyle,\n observeChildren,\n} from '@descope-ui/common/components-helpers';\nimport { createBaseClass } from '@descope-ui/common/base-classes';\n\nexport const componentName = getComponentName('text');\n\nclass RawText extends createBaseClass({\n componentName,\n baseSelector: ':host > slot',\n}) {\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n <slot part=\"text-wrapper\"></slot>\n `;\n\n injectStyle(`\n :host {\n display: inline-block;\n line-height: 1em;\n }\n :host > slot {\n width: 100%;\n display: inline-block;\n }\n `, this);\n }\n\n get hideWhenEmpty() {\n return this.getAttribute('hide-when-empty') === 'true';\n }\n\n init() {\n super.init();\n\n observeChildren(this, () => {\n const hasChildren = !!this.childNodes.length;\n this.style.display = !hasChildren && this.hideWhenEmpty ? 'none' : '';\n });\n }\n}\n\nconst { host } = {\n host: { selector: () => ':host' }\n}\n\nexport const TextClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { ...host, property: 'width' },\n hostDirection: { ...host, property: 'direction' },\n fontSize: {},\n textColor: [\n { property: 'color' }\n ],\n textLineHeight: { property: 'line-height' },\n textLetterSpacing: { property: 'letter-spacing' },\n textShadow: {},\n textAlign: {},\n textTransform: {},\n fontFamily: {},\n fontStyle: {},\n fontWeight: {},\n borderWidth: {},\n borderStyle: {},\n borderColor: {},\n },\n }),\n draggableMixin,\n componentNameValidationMixin,\n)(RawText);\n","import {\n createStyleMixin,\n draggableMixin,\n componentNameValidationMixin,\n} from '@descope-ui/common/components-mixins';\nimport { compose } from '@descope-ui/common/utils';\nimport {\n getComponentName,\n forwardAttrs,\n injectStyle,\n} from '@descope-ui/common/components-helpers';\nimport { createBaseClass } from '@descope-ui/common/base-classes';\nimport { TextClass } from '@descope-ui/descope-text/class';\n\nexport const componentName = getComponentName('link');\n\nclass RawLink extends createBaseClass({ componentName, baseSelector: ':host a' }) {\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n\t\t<div>\n\t\t\t<descope-text part=\"wrapper\">\n\t\t\t\t<a>\n\t\t\t\t\t<slot></slot>\n\t\t\t\t</a>\n\t\t\t</descope-text>\n\t\t</div>\n\t\t`;\n\n injectStyle(\n `\n :host {\n\t\t\tdisplay: inline-block;\n line-height: 1em;\n\t\t}\n\t\t:host a {\n\t\t\tdisplay: inline;\n\t\t}\n\n :host([ellipsis=\"true\"]) descope-text {\n display: inline-flex;\n }\n :host([ellipsis=\"true\"]) descope-text::part(text-wrapper) {\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n }\n `,\n this\n );\n\n forwardAttrs(this, this.shadowRoot.querySelector('a'), {\n includeAttrs: ['href', 'target', 'tooltip'],\n mapAttrs: {\n tooltip: 'title',\n },\n });\n\n forwardAttrs(this, this.shadowRoot.querySelector('descope-text'), {\n includeAttrs: ['mode', 'variant'],\n });\n }\n}\n\nconst selectors = {\n host: { selector: () => ':host' },\n link: { selector: () => ':host a' },\n anchor: {},\n wrapper: { selector: () => ':host > div' },\n text: { selector: () => TextClass.componentName },\n};\n\nconst { anchor, text, host, wrapper, link } = selectors;\n\nexport const LinkClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { ...host, property: 'width' },\n hostDirection: { ...text, property: 'direction' },\n textAlign: wrapper,\n textDecoration: { ...link, property: 'text-decoration', fallback: 'none' },\n textColor: [\n { ...anchor, property: 'color' },\n { ...text, property: TextClass.cssVarList.textColor },\n ],\n cursor: anchor,\n },\n }),\n draggableMixin,\n componentNameValidationMixin\n)(RawLink);\n","import { componentName, LinkClass } from './LinkClass';\nimport '@descope-ui/descope-text';\n\ncustomElements.define(componentName, LinkClass);\n\nexport { LinkClass, componentName };\n","/* eslint-disable no-param-reassign */\n\nimport MarkdownIt from 'markdown-it';\nimport { createStyleMixin, draggableMixin, componentNameValidationMixin } from '@descope-ui/common/components-mixins';\nimport { compose } from '@descope-ui/common/utils';\nimport { disableRules } from './consts';\nimport { createBaseClass } from '@descope-ui/common/base-classes';\nimport { decodeHTML } from './helpers';\nimport { getComponentName, injectStyle, observeChildren } from '@descope-ui/common/components-helpers';\n\nexport const componentName = getComponentName('enriched-text');\n\nclass EnrichedText extends createBaseClass({ componentName, baseSelector: ':host > div' }) {\n #origLinkRenderer;\n\n #origEmRenderer;\n\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n <div class=\"content\"></div>\n `;\n\n injectStyle(\n `\n :host {\n line-height: 1em;\n word-break: break-word;\n }\n :host > slot {\n width: 100%;\n display: inline-block;\n }\n *, *:last-child {\n margin: 0;\n }\n h1,\n h2,\n h3,\n h4,\n h5,\n h6,\n p {\n margin-bottom: 1em;\n }\n a {\n cursor: pointer;\n }\n blockquote {\n padding: 0 2em;\n }\n u {\n text-decoration: underline\n }\n s {\n color: currentColor;\n }\n `,\n this\n );\n\n this.#initProcessor();\n\n observeChildren(this, this.#parseChildren.bind(this));\n }\n\n static get observedAttributes() {\n return ['readonly', 'link-target-blank'];\n }\n\n attributeChangedCallback(attrName, oldValue, newValue) {\n super.attributeChangedCallback?.(attrName, oldValue, newValue);\n\n if (newValue !== oldValue) {\n if (attrName === 'readonly') {\n this.onReadOnlyChange(newValue === 'true');\n }\n\n if (attrName === 'link-target-blank') {\n this.#initProcessor();\n }\n }\n }\n\n // We're overriding the rule for em with single underscore to perform as underline. (_underline_)\n customUnderlineRenderer() {\n this.processor.renderer.rules.em_open = (tokens, idx, options, env, self) => {\n if (tokens[idx].markup === '_') tokens[idx].tag = 'u';\n return this.#origEmRenderer(tokens, idx, options, env, self);\n };\n this.processor.renderer.rules.em_close = (tokens, idx, options, env, self) => {\n if (tokens[idx].markup === '_') tokens[idx].tag = 'u';\n return this.#origEmRenderer(tokens, idx, options, env, self);\n };\n }\n\n #customizeLinkRenderer() {\n if (this.linkTargetBlank) {\n this.processor.renderer.rules.link_open = (tokens, idx, options, env, self) => {\n // Add a new `target` attribute, or replace the value of the existing one.\n tokens[idx].attrSet('target', '_blank');\n // Pass the token to the default renderer.\n return this.#origLinkRenderer(tokens, idx, options, env, self);\n };\n } else {\n this.processor.renderer.rules.link_open = this.#origLinkRenderer;\n }\n }\n\n #disableCustomRules() {\n if (!this.processor) {\n return;\n }\n this.processor.disable(disableRules);\n }\n\n #updateProcessorRules() {\n this.#disableCustomRules();\n }\n\n #storeOrigRenderers() {\n const defaultLinkRenderer = (tokens, idx, options, _, self) =>\n self.renderToken(tokens, idx, options);\n this.#origLinkRenderer = this.processor.renderer.rules.link_open || defaultLinkRenderer;\n\n const defaultStrongRenderer = (tokens, idx, options, _, self) =>\n self.renderToken(tokens, idx, options);\n this.#origEmRenderer = this.processor.renderer.rules.em_open || defaultStrongRenderer;\n }\n\n #initProcessor() {\n this.processor = new MarkdownIt('commonmark', { html: true });\n this.#storeOrigRenderers();\n this.#updateProcessorRules();\n this.#customizeLinkRenderer();\n this.customUnderlineRenderer();\n }\n\n get linkTargetBlank() {\n return this.getAttribute('link-target-blank') === 'true';\n }\n\n get contentNode() {\n return this.shadowRoot.querySelector('.content');\n }\n\n #parseChildren() {\n if (!this.processor) {\n return;\n }\n\n let html = decodeHTML(this.innerHTML);\n\n if (!html?.trim() && this.isConnected) {\n this.setAttribute('empty', 'true');\n } else {\n this.removeAttribute('empty');\n }\n\n try {\n const tokens = this.processor.parse(html, { references: undefined });\n html = this.processor.renderer.render(tokens, { html: true, breaks: true });\n } catch (e) {\n // eslint-disable-next-line no-console\n console.warn('Not parsing invalid markdown token');\n }\n\n this.contentNode.innerHTML = html;\n this.contentNode.firstChild?.setAttribute('part', 'content');\n }\n\n onReadOnlyChange(isReadOnly) {\n if (isReadOnly) {\n this.contentNode.setAttribute('inert', isReadOnly);\n } else {\n this.contentNode.removeAttribute('inert');\n }\n }\n}\n\nexport const EnrichedTextClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { selector: () => ':host', property: 'width' },\n hostDisplay: { selector: () => ':host', property: 'display', fallback: 'inline-block' },\n hostDirection: { selector: () => ':host', property: 'direction' },\n fontSize: {},\n fontFamily: {},\n fontWeight: {},\n fontWeightBold: [\n { selector: () => ':host strong', property: 'font-weight' },\n { selector: () => ':host b', property: 'font-weight' },\n ],\n textColor: { property: 'color' },\n textLineHeight: { property: 'line-height' },\n textAlign: {},\n linkColor: { selector: 'a', property: 'color' },\n linkTextDecoration: { selector: 'a', property: 'text-decoration' },\n linkHoverTextDecoration: { selector: 'a:hover', property: 'text-decoration' },\n minHeight: {},\n minWidth: {},\n },\n }),\n createStyleMixin({ componentNameOverride: getComponentName('link') }),\n createStyleMixin({ componentNameOverride: getComponentName('text') }),\n draggableMixin,\n componentNameValidationMixin\n)(EnrichedText);\n","import { EnrichedTextClass } from '@descope-ui/descope-enriched-text/class';\nimport { getComponentName } from '../../../helpers/componentHelpers';\nimport { compose } from '../../../helpers';\nimport {\n createStyleMixin,\n proxyInputMixin,\n draggableMixin,\n componentNameValidationMixin,\n createProxy,\n} from '../../../mixins';\nimport { booleanFieldMixin } from '../booleanFieldMixin';\nimport commonStyles from '../commonStyles';\nimport { useHostExternalPadding } from '../../../helpers/themeHelpers/resetHelpers';\n\nexport const componentName = getComponentName('switch-toggle');\n\nconst {\n host,\n component,\n checkboxElement: track,\n checkboxSurface: knob,\n checkboxLabel,\n requiredIndicator,\n helperText,\n errorMessage,\n} = {\n host: { selector: () => ':host' },\n requiredIndicator: {\n selector: '[required] vaadin-checkbox [slot=\"label\"]:not(:empty)::part(content)::after',\n },\n component: { selector: 'vaadin-checkbox' },\n checkboxElement: { selector: 'vaadin-checkbox::part(checkbox)' },\n checkboxSurface: { selector: 'vaadin-checkbox::part(checkbox)::after' },\n checkboxLabel: { selector: 'vaadin-checkbox [slot=\"label\"]:not(:empty)' },\n helperText: { selector: '::part(helper-text)' },\n errorMessage: { selector: '::part(error-message)' },\n};\n\nexport const SwitchToggleClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { ...host, property: 'width' },\n hostDirection: { ...host, property: 'direction' },\n\n fontSize: [component, checkboxLabel, checkboxLabel],\n fontFamily: [checkboxLabel, helperText, errorMessage],\n\n labelTextColor: [\n { ...checkboxLabel, property: 'color' },\n { ...checkboxLabel, property: '-webkit-text-fill-color' },\n ],\n labelSpacing: { ...checkboxLabel, property: 'padding-inline-start' },\n labelLineHeight: { ...checkboxLabel, property: 'line-height' },\n labelFontWeight: { ...checkboxLabel, property: 'font-weight' },\n labelRequiredIndicator: { ...requiredIndicator, property: 'content' },\n\n errorMessageTextColor: { ...errorMessage, property: 'color' },\n\n errorMessageIcon: { ...errorMessage, property: 'background-image' },\n errorMessageIconSize: { ...errorMessage, property: 'background-size' },\n errorMessageIconPadding: { ...errorMessage, property: 'padding-inline-start' },\n errorMessageIconRepeat: { ...errorMessage, property: 'background-repeat' },\n errorMessageIconPosition: { ...errorMessage, property: 'background-position' },\n errorMessageFontSize: { ...errorMessage, property: 'font-size' },\n\n trackBorderWidth: { ...track, property: 'border-width' },\n trackBorderStyle: { ...track, property: 'border-style' },\n trackBorderColor: { ...track, property: 'border-color' },\n trackBackgroundColor: { ...track, property: 'background-color' },\n trackBorderRadius: { ...track, property: 'border-radius' },\n trackWidth: [{ ...track, property: 'width' }],\n trackHeight: [\n { ...knob, property: 'font-size' },\n { ...track, property: 'height' },\n ],\n\n knobSize: [\n { ...knob, property: 'width' },\n { ...knob, property: 'height' },\n ],\n knobTextColor: { ...knob, property: 'color' },\n knobRadius: { ...knob, property: 'border-radius' },\n knobTransitionDuration: { ...knob, property: 'transition' },\n knobColor: { ...knob, property: 'background-color' },\n knobTopOffset: { ...knob, property: 'top' },\n knobLeftOffset: { ...knob, property: 'left' },\n\n inputOutlineWidth: { ...track, property: 'outline-width' },\n inputOutlineOffset: { ...track, property: 'outline-offset' },\n inputOutlineColor: { ...track, property: 'outline-color' },\n inputOutlineStyle: { ...track, property: 'outline-style' },\n },\n }),\n draggableMixin,\n proxyInputMixin({ proxyProps: ['value', 'selectionStart'] }),\n componentNameValidationMixin,\n booleanFieldMixin\n)(\n createProxy({\n slots: [],\n wrappedEleName: 'vaadin-text-field',\n style: () => `\n\t\t\t${commonStyles(SwitchToggleClass.cssVarList)}\n\t\t\t${useHostExternalPadding(SwitchToggleClass.cssVarList)}\n\n :host {\n\t\t\t\tdisplay: inline-flex;\n\t\t\t\tmax-width: 100%;\n }\n\n :host ::part(error-message) {\n direction: ltr;\n }\n\n vaadin-text-field {\n width: 100%;\n }\n\n vaadin-text-field::part(input-field)::after {\n content: none;\n }\n\n descope-boolean-field-internal {\n\t\t\t\tpadding: 0;\n width: 100%;\n }\n\n vaadin-text-field::part(input-field) {\n cursor: pointer;\n }\n\n vaadin-checkbox {\n cursor: pointer;\n }\n\n vaadin-checkbox [slot=\"label\"]:not(:empty) {\n cursor: pointer;\n\t\t\t}\n\n vaadin-checkbox::part(checkbox) {\n margin: 0;\n\t\t\t}\n\n vaadin-checkbox::part(checkbox)::before {\n content: '';\n\t\t\t}\n\n vaadin-checkbox[active]::part(checkbox) {\n\t\t\t\ttransform: none;\n\t\t\t}\n\n vaadin-checkbox::part(checkbox)::after {\n\t\t\t\tposition: absolute;\n\t\t\t\topacity: 1;\n\t\t\t\tcontent: '';\n\t\t\t}\n\t\t`,\n excludeAttrsSync: ['label', 'tabindex', 'style'],\n componentName,\n })\n);\n"],"names":["customElements","define","createBaseInputClass","args","InputController","constructor","host","callback","super","initializer","node","value","type","setAttribute","id","this","defaultId","useUniqueId","booleanFieldMixin","superclass","init","template","document","createElement","innerHTML","baseElement","appendChild","content","cloneNode","inputElement","shadowRoot","querySelector","checkbox","includeAttrs","disableRules","componentName","forwardAttributes","BaseInputClass","baseSelector","observedAttributes","wrapperEle","labelContent","checked","val","addEventListener","e","isTrusted","focus","hasAttribute","click","handleFocusEventsDispatching","attributeChangedCallback","attrName","oldValue","newValue","onReadOnlyChange","onLabelChange","labelValue","getAttribute","textContent","getValidity","isRequired","valueMissing","cssVarList","hostDisplay","hostDirection","decodeHTML","html","textArea","RawText","attachShadow","mode","hideWhenEmpty","hasChildren","childNodes","length","style","display","selector","TextClass","mappings","hostWidth","property","fontSize","textColor","textLineHeight","textLetterSpacing","textShadow","textAlign","textTransform","fontFamily","fontStyle","fontWeight","borderWidth","borderStyle","borderColor","RawLink","mapAttrs","tooltip","selectors","link","anchor","wrapper","text","LinkClass","textDecoration","fallback","cursor","EnrichedText","bind","customUnderlineRenderer","processor","renderer","rules","em_open","tokens","idx","options","env","self","markup","tag","em_close","linkTargetBlank","link_open","attrSet","disable","_","renderToken","contentNode","trim","isConnected","removeAttribute","parse","references","undefined","render","breaks","console","warn","firstChild","isReadOnly","EnrichedTextClass","fontWeightBold","linkColor","linkTextDecoration","linkHoverTextDecoration","minHeight","minWidth","componentNameOverride","component","checkboxElement","track","checkboxSurface","knob","checkboxLabel","requiredIndicator","helperText","errorMessage","SwitchToggleClass","labelTextColor","labelSpacing","labelLineHeight","labelFontWeight","labelRequiredIndicator","errorMessageTextColor","errorMessageIcon","errorMessageIconSize","errorMessageIconPadding","errorMessageIconRepeat","errorMessageIconPosition","errorMessageFontSize","trackBorderWidth","trackBorderStyle","trackBorderColor","trackBackgroundColor","trackBorderRadius","trackWidth","trackHeight","knobSize","knobTextColor","knobRadius","knobTransitionDuration","knobColor","knobTopOffset","knobLeftOffset","inputOutlineWidth","inputOutlineOffset","inputOutlineColor","inputOutlineStyle","proxyProps","slots","wrappedEleName","excludeAttrsSync"],"sourceRoot":""}
@@ -14,5 +14,5 @@
14
14
  /* For backwards compatibility */
15
15
  --lumo-icon-size: var(--lumo-icon-size-m);
16
16
  }
17
- `;(0,i.q)("sizing-props",n)},44099:(t,e,o)=>{o.d(e,{r:()=>r});var s=o(1508),i=o(65641),n=o(11707);class r extends EventTarget{static generateId(t,e){return`${e||"default"}-${t.localName}-${(0,n.I)()}`}constructor(t,e,o,s={}){super();const{initializer:i,multiple:n,observe:r,useUniqueId:a}=s;this.host=t,this.slotName=e,this.tagName=o,this.observe="boolean"!=typeof r||r,this.multiple="boolean"==typeof n&&n,this.slotInitializer=i,n&&(this.nodes=[]),a&&(this.defaultId=this.constructor.generateId(t,e))}hostConnected(){this.initialized||(this.multiple?this.initMultiple():this.initSingle(),this.observe&&this.observeSlot(),this.initialized=!0)}initSingle(){let t=this.getSlotChild();t?(this.node=t,this.initAddedNode(t)):(t=this.attachDefaultNode(),this.initNode(t))}initMultiple(){const t=this.getSlotChildren();if(0===t.length){const t=this.attachDefaultNode();t&&(this.nodes=[t],this.initNode(t))}else this.nodes=t,t.forEach(t=>{this.initAddedNode(t)})}attachDefaultNode(){const{host:t,slotName:e,tagName:o}=this;let s=this.defaultNode;return!s&&o&&(s=document.createElement(o),s instanceof Element&&(""!==e&&s.setAttribute("slot",e),this.defaultNode=s)),s&&(this.node=s,t.appendChild(s)),s}getSlotChildren(){const{slotName:t}=this;return Array.from(this.host.childNodes).filter(e=>e.nodeType===Node.ELEMENT_NODE&&e.slot===t||e.nodeType===Node.TEXT_NODE&&e.textContent.trim()&&""===t)}getSlotChild(){return this.getSlotChildren()[0]}initNode(t){const{slotInitializer:e}=this;e&&e(t,this.host)}initCustomNode(t){}teardownNode(t){}initAddedNode(t){t!==this.defaultNode&&(this.initCustomNode(t),this.initNode(t))}observeSlot(){const{slotName:t}=this,e=""===t?"slot:not([name])":`slot[name=${t}]`,o=this.host.shadowRoot.querySelector(e);this.__slotObserver=new i.P(o,({addedNodes:t,removedNodes:e})=>{const o=this.multiple?this.nodes:[this.node],i=t.filter(t=>!(0,s.ZA)(t)&&!o.includes(t));e.length&&(this.nodes=o.filter(t=>!e.includes(t)),e.forEach(t=>{this.teardownNode(t)})),i&&i.length>0&&(this.multiple?(this.defaultNode&&this.defaultNode.remove(),this.nodes=[...o,...i].filter(t=>t!==this.defaultNode),i.forEach(t=>{this.initAddedNode(t)})):(this.node&&this.node.remove(),this.node=i[0],this.initAddedNode(this.node)))})}}},45400:(t,e,o)=>{o.r(e),o.d(e,{ListClass:()=>s.x,componentName:()=>s.T}),o(24542);var s=o(7720);customElements.define(s.T,s.x)},47477:(t,e,o)=>{o.r(e),o.d(e,{AppsListClass:()=>h,componentName:()=>l}),o(45400),o(53557),o(63595);var s=o(63200),i=o(25964),n=o(88961),r=o(66434),a=o(7720),d=o(93895);const l=(0,i.xE)("apps-list"),h=(0,s.Zz)((0,n.RF)({mappings:{maxHeight:{selector:()=>":host"},minHeight:{selector:()=>":host"},hostDirection:{selector:()=>":host",property:"direction"},itemsFontWeight:{selector:r.s.componentName,property:r.s.cssVarList.fontWeightOverride},itemsFontSize:{selector:r.s.componentName,property:r.s.cssVarList.fontSizeOverride},itemsTextAlign:{selector:r.s.componentName,property:r.s.cssVarList.textAlign},itemBackgroundColor:{selector:d.O.componentName,property:d.O.cssVarList.backgroundColor},backgroundColor:{selector:a.x.componentName,property:a.x.cssVarList.backgroundColorOverride},itemBorderStyle:{selector:d.O.componentName,property:d.O.cssVarList.borderStyleOverride},itemBorderColor:{selector:d.O.componentName,property:d.O.cssVarList.borderColorOverride},itemBorderWidth:{selector:d.O.componentName,property:d.O.cssVarList.borderWidthOverride},itemVerticalPadding:{selector:d.O.componentName,property:d.O.cssVarList.verticalPaddingOverride},itemHorizontalPadding:{selector:d.O.componentName,property:d.O.cssVarList.horizontalPaddingOverride},itemAlignment:[{selector:d.O.componentName,property:d.O.cssVarList.alignItemsOverride},{selector:r.s.componentName,property:r.s.cssVarList.textAlign}]}}),(0,n.t$)({itemRenderer:({name:t,icon:e,url:o},s,n)=>`\n <a ${o?`href="${o}" title="${o}"`:""} target="_blank">\n <descope-list-item>\n <descope-avatar\n ${e?`img="${e}"`:""}\n ${t?`display-name="${t}" abbr=${(0,i.ie)(t)}`:""}\n size="${n.logoSize||n.size}"\n ></descope-avatar>\n <descope-text\n variant="${n.itemTextVariant}"\n mode="primary"\n >${t}</descope-text>\n </descope-list-item>\n </a>\n`,rerenderAttrsList:["size","item-text-variant","logo-size"]}),n.VO,n.tQ,t=>class extends t{get size(){return this.getAttribute("size")||"sm"}get itemTextVariant(){return this.getAttribute("item-text-variant")||"body1"}get logoSize(){return this.getAttribute("logo-size")}})((0,n.tz)({slots:["empty-state"],wrappedEleName:"descope-list",excludeAttrsSync:["tabindex","class","empty","style"],componentName:l,style:()=>`\n :host {\n width: 100%;\n display: inline-flex;\n }\n\n descope-text::part(text-wrapper) {\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n overflow: hidden;\n }\n\n a {\n text-decoration: none;\n }\n\n descope-text {\n ${r.s.cssVarList.hostDirection}: var(${h.cssVarList.hostDirection});\n max-width: 100%;\n }\n `}));customElements.define(l,h)},53149:(t,e,o)=>{o.d(e,{y:()=>n});var s=o(98741),i=o(30025);const n=(0,s.y)(t=>class extends t{get _keyboardActive(){return(0,i.aJ)()}ready(){this.addEventListener("focusin",t=>{this._shouldSetFocus(t)&&this._setFocused(!0)}),this.addEventListener("focusout",t=>{this._shouldRemoveFocus(t)&&this._setFocused(!1)}),super.ready()}disconnectedCallback(){super.disconnectedCallback(),this.hasAttribute("focused")&&this._setFocused(!1)}_setFocused(t){this.toggleAttribute("focused",t),this.toggleAttribute("focus-ring",t&&this._keyboardActive)}_shouldSetFocus(t){return!0}_shouldRemoveFocus(t){return!0}})},53557:(t,e,o)=>{o.r(e),o.d(e,{AvatarClass:()=>p,componentName:()=>a});var s=o(88961),i=o(72270),n=o(63200),r=o(25964);const a=(0,r.xE)("avatar");class d extends((0,i.qu)({componentName:a,baseSelector:":host > .wrapper"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <div class="wrapper">\n <vaadin-avatar></vaadin-avatar>\n <div class="editableBadge">\n <vaadin-icon icon="vaadin:pencil"></vaadin-icon>\n </div>\n </div>\n\t\t',(0,r.fz)("\n :host {\n\t\t\t\t\tdisplay: inline-flex;\n\t\t\t\t}\n\n .editableBadge {\n border: 1px solid;\n border-radius: 100%;\n height: fit-content;\n width: 25%;\n height: 25%;\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 5%;\n box-sizing: border-box;\n position: absolute;\n bottom: 0;\n inset-inline-end: 0;\n }\n\n vaadin-icon {\n color: currentcolor;\n }\n\n vaadin-avatar {\n width: 100%;\n height: 100%;\n margin: 0;\n border: none\n }\n\n .wrapper {\n display: inline-flex;\n position: relative;\n width: 100%;\n height: 100%;\n }\n ",this),this.avatarComponent=this.shadowRoot.querySelector("vaadin-avatar"),(0,r.EA)(this,this.avatarComponent,{includeAttrs:["display-name","img","abbr"],mapAttrs:{"display-name":"name"}});const t=this.shadowRoot.querySelector(".editableBadge");(0,r.mx)(this,()=>{t.style.display=this.isEditable?"":"none"},{includeAttrs:["editable"]})}get isEditable(){return"true"===this.getAttribute("editable")}}const{host:l,editableBadge:h,avatar:c}={host:{selector:()=>":host"},editableBadge:{selector:"> .editableBadge"},avatar:{selector:"vaadin-avatar"}},p=(0,n.Zz)((0,s.RF)({mappings:{hostWidth:[{...l,property:"width"},{...l,property:"min-width"}],hostHeight:{...l,property:"height"},cursor:[c,l],hostDirection:{...l,property:"direction"},avatarTextColor:{...c,property:"color"},avatarBackgroundColor:{...c,property:"background-color"},editableIconColor:{...h,property:"color"},editableBorderColor:{...h,property:"border-color"},editableBackgroundColor:{...h,property:"background-color"}}}),s.VO,s.tQ)(d);o(4408),o(95260),o(37182),customElements.define(a,p)},63595:(t,e,o)=>{o.r(e),o.d(e,{TextClass:()=>s.s,componentName:()=>s.T});var s=o(66434);customElements.define(s.T,s.s)},65641:(t,e,o)=>{o.d(e,{P:()=>s});class s{constructor(t,e){this.slot=t,this.callback=e,this._storedNodes=[],this._connected=!1,this._scheduled=!1,this._boundSchedule=()=>{this._schedule()},this.connect(),this._schedule()}connect(){this.slot.addEventListener("slotchange",this._boundSchedule),this._connected=!0}disconnect(){this.slot.removeEventListener("slotchange",this._boundSchedule),this._connected=!1}_schedule(){this._scheduled||(this._scheduled=!0,queueMicrotask(()=>{this.flush()}))}flush(){this._connected&&(this._scheduled=!1,this._processNodes())}_processNodes(){const t=this.slot.assignedNodes({flatten:!0});let e=[];const o=[],s=[];t.length&&(e=t.filter(t=>!this._storedNodes.includes(t))),this._storedNodes.length&&this._storedNodes.forEach((e,i)=>{const n=t.indexOf(e);-1===n?o.push(e):n!==i&&s.push(e)}),(e.length||o.length||s.length)&&this.callback({addedNodes:e,movedNodes:s,removedNodes:o}),this._storedNodes=t}}},66434:(t,e,o)=>{o.d(e,{T:()=>a,s:()=>h});var s=o(88961),i=o(63200),n=o(25964),r=o(72270);const a=(0,n.xE)("text");class d extends((0,r.qu)({componentName:a,baseSelector:":host > slot"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <slot part="text-wrapper"></slot>\n ',(0,n.fz)("\n :host {\n display: inline-block;\n line-height: 1em;\n }\n :host > slot {\n width: 100%;\n display: inline-block;\n }\n ",this)}get hideWhenEmpty(){return"true"===this.getAttribute("hide-when-empty")}init(){super.init(),(0,n.Ge)(this,()=>{const t=!!this.childNodes.length;this.style.display=!t&&this.hideWhenEmpty?"none":""})}}const{host:l}={host:{selector:()=>":host"}},h=(0,i.Zz)((0,s.RF)({mappings:{hostWidth:{...l,property:"width"},hostDirection:{...l,property:"direction"},fontSize:{},textColor:[{property:"color"}],textLineHeight:{property:"line-height"},textLetterSpacing:{property:"letter-spacing"},textShadow:{},textAlign:{},textTransform:{},fontFamily:{},fontStyle:{},fontWeight:{},borderWidth:{},borderStyle:{},borderColor:{}}}),s.VO,s.tQ)(d)},81488:(t,e,o)=>{o.d(e,{I:()=>i});var s=o(44099);class i extends s.r{constructor(t){super(t,"tooltip"),this.setTarget(t)}initCustomNode(t){t.target=this.target,void 0!==this.ariaTarget&&(t.ariaTarget=this.ariaTarget),void 0!==this.context&&(t.context=this.context),void 0!==this.manual&&(t.manual=this.manual),void 0!==this.opened&&(t.opened=this.opened),void 0!==this.position&&(t._position=this.position),void 0!==this.shouldShow&&(t.shouldShow=this.shouldShow),this.__notifyChange()}teardownNode(){this.__notifyChange()}setAriaTarget(t){this.ariaTarget=t;const e=this.node;e&&(e.ariaTarget=t)}setContext(t){this.context=t;const e=this.node;e&&(e.context=t)}setManual(t){this.manual=t;const e=this.node;e&&(e.manual=t)}setOpened(t){this.opened=t;const e=this.node;e&&(e.opened=t)}setPosition(t){this.position=t;const e=this.node;e&&(e._position=t)}setShouldShow(t){this.shouldShow=t;const e=this.node;e&&(e.shouldShow=t)}setTarget(t){this.target=t;const e=this.node;e&&(e.target=t)}__notifyChange(){this.dispatchEvent(new CustomEvent("tooltip-changed",{detail:{node:this.node}}))}}},93895:(t,e,o)=>{o.d(e,{O:()=>d,T:()=>a});var s=o(88961),i=o(63200),n=o(25964),r=o(72270);const a=(0,n.xE)("list-item"),d=(0,i.Zz)((0,s.RF)({mappings:{verticalPadding:[{property:"padding-top"},{property:"padding-bottom"}],horizontalPadding:[{property:"padding-left"},{property:"padding-right"}],backgroundColor:{},borderColor:{},borderStyle:{},borderWidth:{},borderRadius:{},outline:{},cursor:{},gap:{},maxWidth:{selector:()=>":host"},alignItems:{},flexDirection:{},transition:{}}}),s.VO,s.tQ,t=>class extends t{constructor(){super(),this.attachShadow({mode:"open"}).innerHTML="\n <slot></slot>\n ",(0,n.fz)("\n slot {\n width: 100%;\n display: flex;\n overflow: hidden;\n box-sizing: border-box;\n }\n :host {\n display: block;\n }\n ",this)}},s.y)((0,r.qu)({componentName:a,baseSelector:"slot"}))}}]);
17
+ `;(0,i.q)("sizing-props",n)},44099:(t,e,o)=>{o.d(e,{r:()=>r});var s=o(1508),i=o(65641),n=o(11707);class r extends EventTarget{static generateId(t,e){return`${e||"default"}-${t.localName}-${(0,n.I)()}`}constructor(t,e,o,s={}){super();const{initializer:i,multiple:n,observe:r,useUniqueId:a}=s;this.host=t,this.slotName=e,this.tagName=o,this.observe="boolean"!=typeof r||r,this.multiple="boolean"==typeof n&&n,this.slotInitializer=i,n&&(this.nodes=[]),a&&(this.defaultId=this.constructor.generateId(t,e))}hostConnected(){this.initialized||(this.multiple?this.initMultiple():this.initSingle(),this.observe&&this.observeSlot(),this.initialized=!0)}initSingle(){let t=this.getSlotChild();t?(this.node=t,this.initAddedNode(t)):(t=this.attachDefaultNode(),this.initNode(t))}initMultiple(){const t=this.getSlotChildren();if(0===t.length){const t=this.attachDefaultNode();t&&(this.nodes=[t],this.initNode(t))}else this.nodes=t,t.forEach(t=>{this.initAddedNode(t)})}attachDefaultNode(){const{host:t,slotName:e,tagName:o}=this;let s=this.defaultNode;return!s&&o&&(s=document.createElement(o),s instanceof Element&&(""!==e&&s.setAttribute("slot",e),this.defaultNode=s)),s&&(this.node=s,t.appendChild(s)),s}getSlotChildren(){const{slotName:t}=this;return Array.from(this.host.childNodes).filter(e=>e.nodeType===Node.ELEMENT_NODE&&e.slot===t||e.nodeType===Node.TEXT_NODE&&e.textContent.trim()&&""===t)}getSlotChild(){return this.getSlotChildren()[0]}initNode(t){const{slotInitializer:e}=this;e&&e(t,this.host)}initCustomNode(t){}teardownNode(t){}initAddedNode(t){t!==this.defaultNode&&(this.initCustomNode(t),this.initNode(t))}observeSlot(){const{slotName:t}=this,e=""===t?"slot:not([name])":`slot[name=${t}]`,o=this.host.shadowRoot.querySelector(e);this.__slotObserver=new i.P(o,({addedNodes:t,removedNodes:e})=>{const o=this.multiple?this.nodes:[this.node],i=t.filter(t=>!(0,s.ZA)(t)&&!o.includes(t));e.length&&(this.nodes=o.filter(t=>!e.includes(t)),e.forEach(t=>{this.teardownNode(t)})),i&&i.length>0&&(this.multiple?(this.defaultNode&&this.defaultNode.remove(),this.nodes=[...o,...i].filter(t=>t!==this.defaultNode),i.forEach(t=>{this.initAddedNode(t)})):(this.node&&this.node.remove(),this.node=i[0],this.initAddedNode(this.node)))})}}},45400:(t,e,o)=>{o.r(e),o.d(e,{ListClass:()=>s.x,componentName:()=>s.T}),o(24542);var s=o(7720);customElements.define(s.T,s.x)},47477:(t,e,o)=>{o.r(e),o.d(e,{AppsListClass:()=>h,componentName:()=>l}),o(45400),o(53557),o(63595);var s=o(63200),i=o(25964),n=o(88961),r=o(66434),a=o(7720),d=o(93895);const l=(0,i.xE)("apps-list"),h=(0,s.Zz)((0,n.RF)({mappings:{maxHeight:{selector:()=>":host"},minHeight:{selector:()=>":host"},hostDirection:{selector:()=>":host",property:"direction"},itemsFontWeight:{selector:r.s.componentName,property:r.s.cssVarList.fontWeightOverride},itemsFontSize:{selector:r.s.componentName,property:r.s.cssVarList.fontSizeOverride},itemsTextAlign:{selector:r.s.componentName,property:r.s.cssVarList.textAlign},itemBackgroundColor:{selector:d.O.componentName,property:d.O.cssVarList.backgroundColor},backgroundColor:{selector:a.x.componentName,property:a.x.cssVarList.backgroundColorOverride},itemBorderStyle:{selector:d.O.componentName,property:d.O.cssVarList.borderStyleOverride},itemBorderColor:{selector:d.O.componentName,property:d.O.cssVarList.borderColorOverride},itemBorderWidth:{selector:d.O.componentName,property:d.O.cssVarList.borderWidthOverride},itemVerticalPadding:{selector:d.O.componentName,property:d.O.cssVarList.verticalPaddingOverride},itemHorizontalPadding:{selector:d.O.componentName,property:d.O.cssVarList.horizontalPaddingOverride},itemAlignment:[{selector:()=>".avatar-wrapper",property:"text-align"},{selector:r.s.componentName,property:r.s.cssVarList.textAlign}]}}),(0,n.t$)({itemRenderer:({name:t,icon:e,url:o},s,n)=>`\n <a ${o?`href="${o}" title="${o}"`:""} target="_blank">\n <descope-list-item>\n <div class="avatar-wrapper">\n <descope-avatar\n ${e?`img="${e}"`:""}\n ${t?`display-name="${t}" abbr=${(0,i.ie)(t)}`:""}\n size="${n.logoSize||n.size}"\n ></descope-avatar>\n </div>\n <descope-text\n variant="${n.itemTextVariant}"\n mode="primary"\n >${t}</descope-text>\n </descope-list-item>\n </a>\n`,rerenderAttrsList:["size","item-text-variant","logo-size"]}),n.VO,n.tQ,t=>class extends t{get size(){return this.getAttribute("size")||"sm"}get itemTextVariant(){return this.getAttribute("item-text-variant")||"body1"}get logoSize(){return this.getAttribute("logo-size")}})((0,n.tz)({slots:["empty-state"],wrappedEleName:"descope-list",excludeAttrsSync:["tabindex","class","empty","style"],componentName:l,style:()=>`\n :host {\n width: 100%;\n display: inline-flex;\n }\n\n descope-text::part(text-wrapper) {\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n overflow: hidden;\n }\n\n descope-list-item[variant="tile"] .avatar-wrapper {\n width: 100%;\n }\n\n .avatar-wrapper {\n line-height: 0;\n }\n\n a {\n text-decoration: none;\n }\n\n descope-text {\n ${r.s.cssVarList.hostDirection}: var(${h.cssVarList.hostDirection});\n max-width: 100%;\n width: 100%;\n }\n `}));customElements.define(l,h)},53149:(t,e,o)=>{o.d(e,{y:()=>n});var s=o(98741),i=o(30025);const n=(0,s.y)(t=>class extends t{get _keyboardActive(){return(0,i.aJ)()}ready(){this.addEventListener("focusin",t=>{this._shouldSetFocus(t)&&this._setFocused(!0)}),this.addEventListener("focusout",t=>{this._shouldRemoveFocus(t)&&this._setFocused(!1)}),super.ready()}disconnectedCallback(){super.disconnectedCallback(),this.hasAttribute("focused")&&this._setFocused(!1)}_setFocused(t){this.toggleAttribute("focused",t),this.toggleAttribute("focus-ring",t&&this._keyboardActive)}_shouldSetFocus(t){return!0}_shouldRemoveFocus(t){return!0}})},53557:(t,e,o)=>{o.r(e),o.d(e,{AvatarClass:()=>p,componentName:()=>a});var s=o(88961),i=o(72270),n=o(63200),r=o(25964);const a=(0,r.xE)("avatar");class d extends((0,i.qu)({componentName:a,baseSelector:":host > .wrapper"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <div class="wrapper">\n <vaadin-avatar></vaadin-avatar>\n <div class="editableBadge">\n <vaadin-icon icon="vaadin:pencil"></vaadin-icon>\n </div>\n </div>\n\t\t',(0,r.fz)("\n :host {\n\t\t\t\t\tdisplay: inline-flex;\n\t\t\t\t}\n\n .editableBadge {\n border: 1px solid;\n border-radius: 100%;\n height: fit-content;\n width: 25%;\n height: 25%;\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 5%;\n box-sizing: border-box;\n position: absolute;\n bottom: 0;\n inset-inline-end: 0;\n }\n\n vaadin-icon {\n color: currentcolor;\n }\n\n vaadin-avatar {\n width: 100%;\n height: 100%;\n margin: 0;\n border: none\n }\n\n .wrapper {\n display: inline-flex;\n position: relative;\n width: 100%;\n height: 100%;\n }\n ",this),this.avatarComponent=this.shadowRoot.querySelector("vaadin-avatar"),(0,r.EA)(this,this.avatarComponent,{includeAttrs:["display-name","img","abbr"],mapAttrs:{"display-name":"name"}});const t=this.shadowRoot.querySelector(".editableBadge");(0,r.mx)(this,()=>{t.style.display=this.isEditable?"":"none"},{includeAttrs:["editable"]})}get isEditable(){return"true"===this.getAttribute("editable")}}const{host:l,editableBadge:h,avatar:c}={host:{selector:()=>":host"},editableBadge:{selector:"> .editableBadge"},avatar:{selector:"vaadin-avatar"}},p=(0,n.Zz)((0,s.RF)({mappings:{hostWidth:[{...l,property:"width"},{...l,property:"min-width"}],hostHeight:{...l,property:"height"},cursor:[c,l],hostDirection:{...l,property:"direction"},avatarTextColor:{...c,property:"color"},avatarBackgroundColor:{...c,property:"background-color"},editableIconColor:{...h,property:"color"},editableBorderColor:{...h,property:"border-color"},editableBackgroundColor:{...h,property:"background-color"}}}),s.VO,s.tQ)(d);o(4408),o(95260),o(37182),customElements.define(a,p)},63595:(t,e,o)=>{o.r(e),o.d(e,{TextClass:()=>s.s,componentName:()=>s.T});var s=o(66434);customElements.define(s.T,s.s)},65641:(t,e,o)=>{o.d(e,{P:()=>s});class s{constructor(t,e){this.slot=t,this.callback=e,this._storedNodes=[],this._connected=!1,this._scheduled=!1,this._boundSchedule=()=>{this._schedule()},this.connect(),this._schedule()}connect(){this.slot.addEventListener("slotchange",this._boundSchedule),this._connected=!0}disconnect(){this.slot.removeEventListener("slotchange",this._boundSchedule),this._connected=!1}_schedule(){this._scheduled||(this._scheduled=!0,queueMicrotask(()=>{this.flush()}))}flush(){this._connected&&(this._scheduled=!1,this._processNodes())}_processNodes(){const t=this.slot.assignedNodes({flatten:!0});let e=[];const o=[],s=[];t.length&&(e=t.filter(t=>!this._storedNodes.includes(t))),this._storedNodes.length&&this._storedNodes.forEach((e,i)=>{const n=t.indexOf(e);-1===n?o.push(e):n!==i&&s.push(e)}),(e.length||o.length||s.length)&&this.callback({addedNodes:e,movedNodes:s,removedNodes:o}),this._storedNodes=t}}},66434:(t,e,o)=>{o.d(e,{T:()=>a,s:()=>h});var s=o(88961),i=o(63200),n=o(25964),r=o(72270);const a=(0,n.xE)("text");class d extends((0,r.qu)({componentName:a,baseSelector:":host > slot"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <slot part="text-wrapper"></slot>\n ',(0,n.fz)("\n :host {\n display: inline-block;\n line-height: 1em;\n }\n :host > slot {\n width: 100%;\n display: inline-block;\n }\n ",this)}get hideWhenEmpty(){return"true"===this.getAttribute("hide-when-empty")}init(){super.init(),(0,n.Ge)(this,()=>{const t=!!this.childNodes.length;this.style.display=!t&&this.hideWhenEmpty?"none":""})}}const{host:l}={host:{selector:()=>":host"}},h=(0,i.Zz)((0,s.RF)({mappings:{hostWidth:{...l,property:"width"},hostDirection:{...l,property:"direction"},fontSize:{},textColor:[{property:"color"}],textLineHeight:{property:"line-height"},textLetterSpacing:{property:"letter-spacing"},textShadow:{},textAlign:{},textTransform:{},fontFamily:{},fontStyle:{},fontWeight:{},borderWidth:{},borderStyle:{},borderColor:{}}}),s.VO,s.tQ)(d)},81488:(t,e,o)=>{o.d(e,{I:()=>i});var s=o(44099);class i extends s.r{constructor(t){super(t,"tooltip"),this.setTarget(t)}initCustomNode(t){t.target=this.target,void 0!==this.ariaTarget&&(t.ariaTarget=this.ariaTarget),void 0!==this.context&&(t.context=this.context),void 0!==this.manual&&(t.manual=this.manual),void 0!==this.opened&&(t.opened=this.opened),void 0!==this.position&&(t._position=this.position),void 0!==this.shouldShow&&(t.shouldShow=this.shouldShow),this.__notifyChange()}teardownNode(){this.__notifyChange()}setAriaTarget(t){this.ariaTarget=t;const e=this.node;e&&(e.ariaTarget=t)}setContext(t){this.context=t;const e=this.node;e&&(e.context=t)}setManual(t){this.manual=t;const e=this.node;e&&(e.manual=t)}setOpened(t){this.opened=t;const e=this.node;e&&(e.opened=t)}setPosition(t){this.position=t;const e=this.node;e&&(e._position=t)}setShouldShow(t){this.shouldShow=t;const e=this.node;e&&(e.shouldShow=t)}setTarget(t){this.target=t;const e=this.node;e&&(e.target=t)}__notifyChange(){this.dispatchEvent(new CustomEvent("tooltip-changed",{detail:{node:this.node}}))}}},93895:(t,e,o)=>{o.d(e,{O:()=>d,T:()=>a});var s=o(88961),i=o(63200),n=o(25964),r=o(72270);const a=(0,n.xE)("list-item"),d=(0,i.Zz)((0,s.RF)({mappings:{verticalPadding:[{property:"padding-top"},{property:"padding-bottom"}],horizontalPadding:[{property:"padding-left"},{property:"padding-right"}],backgroundColor:{},borderColor:{},borderStyle:{},borderWidth:{},borderRadius:{},outline:{},cursor:{},gap:{},maxWidth:{selector:()=>":host"},alignItems:{},flexDirection:{},transition:{}}}),s.VO,s.tQ,t=>class extends t{constructor(){super(),this.attachShadow({mode:"open"}).innerHTML="\n <slot></slot>\n ",(0,n.fz)("\n slot {\n width: 100%;\n display: flex;\n overflow: hidden;\n box-sizing: border-box;\n }\n :host {\n display: block;\n }\n ",this)}},s.y)((0,r.qu)({componentName:a,baseSelector:"slot"}))}}]);
18
18
  //# sourceMappingURL=descope-apps-list.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"descope-apps-list.js","mappings":";2JAgBO,SAASA,EAAqBC,GACnC,MAAMC,EAAS,GAEf,KAAOD,GAAM,CACX,GAAIA,EAAKE,WAAaC,KAAKC,cAAe,CACxCH,EAAOI,KAAKL,GACZ,KACF,CAEIA,EAAKE,WAAaC,KAAKG,uBAOzBN,EADEA,EAAKO,aACAP,EAAKO,aAIPP,EAAKQ,YAVVP,EAAOI,KAAKL,GACZA,EAAOA,EAAKS,KAUhB,CAEA,OAAOR,CACT,CAUO,SAASS,EAAqBV,GACnC,MAAMC,EAAS,GACf,IAAIU,EAQJ,MAPuB,SAAnBX,EAAKY,UACPD,EAAWX,EAAKa,oB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aA,EAElB,MAAMT,EAAc9L,KAAKhD,KACrB8O,IACFA,EAAYS,WAAaA,EAE7B,CAMA,SAAAV,CAAUE,GACR/L,KAAK+L,OAASA,EAEd,MAAMD,EAAc9L,KAAKhD,KACrB8O,IACFA,EAAYC,OAASA,EAEzB,CAGA,cAAAS,GACExM,KAAK+M,cAAc,IAAIC,YAAY,kBAAmB,CAAEC,OAAQ,CAAEjQ,KAAMgD,KAAKhD,QAC/E,E,2FCzJK,MAAM0C,GAAgB,QAAiB,aA4BjC0G,GAAgB,SAC3B,QAAiB,CACfjF,SAAU,CACRK,gBAAiB,CACf,CAAEH,SAAU,eACZ,CAAEA,SAAU,mBAEdI,kBAAmB,CACjB,CAAEJ,SAAU,gBACZ,CAAEA,SAAU,kBAEdQ,gBAAiB,CAAC,EAClBE,YAAa,CAAC,EACdC,YAAa,CAAC,EACdC,YAAa,CAAC,EACdH,aAAc,CAAC,EACfoL,QAAS,CAAC,EACV3D,OAAQ,CAAC,EACT3H,IAAK,CAAC,EACNuL,SAAU,CAAEjP,SAAU,IAAM,SAC5BkP,WAAY,CAAC,EACbC,cAAe,CAAC,EAChBC,WAAY,CAAC,KAGjB,KACA,KApDmB5F,GACnB,cAAiCA,EAC/B,WAAA5H,GACEC,QAEAC,KAAKC,aAAa,CAAEC,KAAM,SAAUC,UAAY,+BAIhD,QACE,uMAWAH,KAEJ,GA+BF,IA5B2B,EA6B3B,QAAgB,CAAEN,gBAAeE,aAAc,S","sources":["webpack://@descope/web-components-ui/../../../node_modules/@vaadin/component-base/src/dom-utils.js","webpack://@descope/web-components-ui/../components/descope-list/src/component/ListClass.js","webpack://@descope/web-components-ui/../../../node_modules/@vaadin/component-base/src/unique-id-utils.js","webpack://@descope/web-components-ui/../components/descope-list-item/src/component/index.js","webpack://@descope/web-components-ui/../../../node_modules/@vaadin/vaadin-lumo-styles/sizing.js","webpack://@descope/web-components-ui/../../../node_modules/@vaadin/component-base/src/slot-controller.js","webpack://@descope/web-components-ui/../components/descope-list/src/component/index.js","webpack://@descope/web-components-ui/../components/descope-apps-list/src/component/AppsListClass.js","webpack://@descope/web-components-ui/../components/descope-apps-list/src/component/index.js","webpack://@descope/web-components-ui/../../../node_modules/@vaadin/a11y-base/src/focus-mixin.js","webpack://@descope/web-components-ui/../components/descope-avatar/src/component/AvatarClass.js","webpack://@descope/web-components-ui/../components/descope-avatar/src/component/index.js","webpack://@descope/web-components-ui/../components/descope-text/src/component/index.js","webpack://@descope/web-components-ui/../../../node_modules/@vaadin/component-base/src/slot-observer.js","webpack://@descope/web-components-ui/../components/descope-text/src/component/TextClass.js","webpack://@descope/web-components-ui/../../../node_modules/@vaadin/component-base/src/tooltip-controller.js","webpack://@descope/web-components-ui/../components/descope-list-item/src/component/ListItemClass.js"],"sourcesContent":["/**\n * @license\n * Copyright (c) 2021 - 2023 Vaadin Ltd.\n * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/\n */\n\n/**\n * Returns an array of ancestor root nodes for the given node.\n *\n * A root node is either a document node or a document fragment node (Shadow Root).\n * The array is collected by a bottom-up DOM traversing that starts with the given node\n * and involves both the light DOM and ancestor shadow DOM trees.\n *\n * @param {Node} node\n * @return {Node[]}\n */\nexport function getAncestorRootNodes(node) {\n const result = [];\n\n while (node) {\n if (node.nodeType === Node.DOCUMENT_NODE) {\n result.push(node);\n break;\n }\n\n if (node.nodeType === Node.DOCUMENT_FRAGMENT_NODE) {\n result.push(node);\n node = node.host;\n continue;\n }\n\n if (node.assignedSlot) {\n node = node.assignedSlot;\n continue;\n }\n\n node = node.parentNode;\n }\n\n return result;\n}\n\n/**\n * Returns the list of flattened elements for the given `node`.\n * This list consists of a node's children and, for any children that are\n * `<slot>` elements, the expanded flattened list of `assignedElements`.\n *\n * @param {Node} node\n * @return {Element[]}\n */\nexport function getFlattenedElements(node) {\n const result = [];\n let elements;\n if (node.localName === 'slot') {\n elements = node.assignedElements();\n } else {\n result.push(node);\n elements = [...node.children];\n }\n elements.forEach((elem) => result.push(...getFlattenedElements(elem)));\n return result;\n}\n\n/**\n * Traverses the given node and its parents, including those that are across\n * the shadow root boundaries, until it finds a node that matches the selector.\n *\n * @param {string} selector The CSS selector to match against\n * @param {Node} node The starting node for the traversal\n * @return {Node | null} The closest matching element, or null if no match is found\n */\nexport function getClosestElement(selector, node) {\n if (!node) {\n return null;\n }\n\n return node.closest(selector) || getClosestElement(selector, node.getRootNode().host);\n}\n\n/**\n * Takes a string with values separated by space and returns a set the values\n *\n * @param {string} value\n * @return {Set<string>}\n */\nexport function deserializeAttributeValue(value) {\n if (!value) {\n return new Set();\n }\n\n return new Set(value.split(' '));\n}\n\n/**\n * Takes a set of string values and returns a string with values separated by space\n *\n * @param {Set<string>} values\n * @return {string}\n */\nexport function serializeAttributeValue(values) {\n return values ? [...values].join(' ') : '';\n}\n\n/**\n * Adds a value to an attribute containing space-delimited values.\n *\n * @param {HTMLElement} element\n * @param {string} attr\n * @param {string} value\n */\nexport function addValueToAttribute(element, attr, value) {\n const values = deserializeAttributeValue(element.getAttribute(attr));\n values.add(value);\n element.setAttribute(attr, serializeAttributeValue(values));\n}\n\n/**\n * Removes a value from an attribute containing space-delimited values.\n * If the value is the last one, the whole attribute is removed.\n *\n * @param {HTMLElement} element\n * @param {string} attr\n * @param {string} value\n */\nexport function removeValueFromAttribute(element, attr, value) {\n const values = deserializeAttributeValue(element.getAttribute(attr));\n values.delete(value);\n if (values.size === 0) {\n element.removeAttribute(attr);\n return;\n }\n element.setAttribute(attr, serializeAttributeValue(values));\n}\n\n/**\n * Returns true if the given node is an empty text node, false otherwise.\n *\n * @param {Node} node\n * @return {boolean}\n */\nexport function isEmptyTextNode(node) {\n return node.nodeType === Node.TEXT_NODE && node.textContent.trim() === '';\n}\n","import {\n createStyleMixin,\n draggableMixin,\n componentNameValidationMixin,\n} from '@descope-ui/common/components-mixins';\nimport { compose } from '@descope-ui/common/utils';\nimport {\n getComponentName,\n observeChildren,\n} from '@descope-ui/common/components-helpers';\nimport { injectStyle } from '@descope-ui/common/components-helpers';\nimport { ListItemClass } from '@descope-ui/descope-list-item/class';\nimport { createBaseClass } from '@descope-ui/common/base-classes';\n\nexport const componentName = getComponentName('list');\n\nclass RawList extends createBaseClass({\n componentName,\n baseSelector: '.wrapper',\n}) {\n static get observedAttributes() {\n return ['variant', 'readonly'];\n }\n\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n <div class=\"wrapper\">\n <slot></slot>\n <slot name=\"empty-state\">\n No item...\n </slot>\n </div>\n\t`;\n\n injectStyle(\n `\n .wrapper {\n overflow: auto;\n display: grid;\n max-height: 100%;\n width: 100%;\n }\n\n :host {\n display: inline-flex;\n width: 100%;\n }\n slot[name=\"empty-state\"] {\n justify-content: center;\n align-items: center;\n display: flex;\n flex-grow: 1;\n }\n\n :host slot[name=\"empty-state\"] {\n display: none;\n }\n :host([empty]) slot[name=\"empty-state\"] {\n display: flex;\n }\n ::slotted(:not([slot])) {\n width: 100%;\n }\n `,\n this,\n );\n }\n\n get items() {\n return this.shadowRoot.querySelector('slot').assignedElements();\n }\n\n #handleEmptyState() {\n if (this.items.length === 0) {\n this.setAttribute('empty', 'true');\n } else {\n this.removeAttribute('empty');\n }\n }\n\n get variant() {\n return this.getAttribute('variant') || 'list';\n }\n\n #handleItemsVariant() {\n this.items.forEach((item) => {\n let listItem = item;\n if (listItem.localName !== ListItemClass.componentName) {\n listItem = item.querySelector(ListItemClass.componentName);\n }\n\n const listItemVariant = this.variant === 'tiles' ? 'tile' : 'row';\n listItem?.setAttribute('variant', listItemVariant);\n });\n }\n\n init() {\n super.init?.();\n\n // we want new items to get the size\n observeChildren(this, () => {\n this.#handleEmptyState();\n this.#handleItemsVariant();\n this.#handleReadOnly();\n });\n }\n\n get isReadOnly() {\n return this.getAttribute('readonly') === 'true';\n }\n\n #handleReadOnly() {\n this.items.forEach((item) => {\n if (this.isReadOnly) item.setAttribute('inert', '');\n else item.removeAttribute('inert');\n });\n }\n\n attributeChangedCallback(name, oldValue, newValue) {\n super.attributeChangedCallback?.(name, oldValue, newValue);\n\n if (newValue === oldValue) return;\n\n if (name === 'variant') {\n this.#handleItemsVariant();\n } else if (name === 'readonly') {\n this.#handleReadOnly();\n }\n }\n}\n\nexport const ListClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { selector: () => ':host', property: 'width' },\n maxHeight: { selector: () => ':host' },\n minHeight: {},\n verticalPadding: [\n { property: 'padding-top' },\n { property: 'padding-bottom' },\n ],\n horizontalPadding: [\n { property: 'padding-left' },\n { property: 'padding-right' },\n ],\n hostDirection: { selector: () => ':host', property: 'direction' },\n fontFamily: {},\n gap: {},\n\n backgroundColor: {},\n borderRadius: {},\n borderColor: {},\n borderStyle: {},\n borderWidth: {},\n\n boxShadow: {},\n gridTemplateColumns: {},\n maxItemsWidth: {\n selector: () => '::slotted(:not([slot]))',\n property: 'max-width',\n },\n minItemsWidth: {\n selector: () => '::slotted(:not([slot]))',\n property: 'min-width',\n },\n itemsHorizontalAlign: {\n selector: () => '::slotted(*)',\n property: 'justify-self',\n },\n emptyStateTextColor: {\n selector: () => 'slot[name=\"empty-state\"]',\n property: 'color',\n },\n emptyStateTextFontFamily: {\n selector: () => 'slot[name=\"empty-state\"]',\n property: 'font-family',\n },\n },\n }),\n draggableMixin,\n componentNameValidationMixin,\n)(RawList);\n","/**\n * @license\n * Copyright (c) 2021 - 2023 Vaadin Ltd.\n * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/\n */\n\nlet uniqueId = 0;\n\n/**\n * Resets the unique id counter.\n *\n * @return {void}\n */\nexport function resetUniqueId() {\n uniqueId = 0;\n}\n\n/**\n * Returns a unique integer id.\n *\n * @return {number}\n */\nexport function generateUniqueId() {\n // eslint-disable-next-line no-plusplus\n return uniqueId++;\n}\n","import { componentName, ListItemClass } from './ListItemClass';\n\ncustomElements.define(componentName, ListItemClass);\n\nexport { ListItemClass, componentName };\n","/**\n * @license\n * Copyright (c) 2017 - 2023 Vaadin Ltd.\n * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/\n */\nimport './version.js';\nimport { css } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';\nimport { addLumoGlobalStyles } from './global.js';\n\nconst sizing = css`\n :host {\n --lumo-size-xs: 1.625rem;\n --lumo-size-s: 1.875rem;\n --lumo-size-m: 2.25rem;\n --lumo-size-l: 2.75rem;\n --lumo-size-xl: 3.5rem;\n\n /* Icons */\n --lumo-icon-size-s: 1.25em;\n --lumo-icon-size-m: 1.5em;\n --lumo-icon-size-l: 2.25em;\n /* For backwards compatibility */\n --lumo-icon-size: var(--lumo-icon-size-m);\n }\n`;\n\naddLumoGlobalStyles('sizing-props', sizing);\n\nexport { sizing };\n","/**\n * @license\n * Copyright (c) 2021 - 2023 Vaadin Ltd.\n * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/\n */\nimport { isEmptyTextNode } from './dom-utils.js';\nimport { SlotObserver } from './slot-observer.js';\nimport { generateUniqueId } from './unique-id-utils.js';\n\n/**\n * A controller for providing content to slot element and observing changes.\n */\nexport class SlotController extends EventTarget {\n /**\n * Ensure that every instance has unique ID.\n *\n * @param {HTMLElement} host\n * @param {string} slotName\n * @return {string}\n * @protected\n */\n static generateId(host, slotName) {\n const prefix = slotName || 'default';\n return `${prefix}-${host.localName}-${generateUniqueId()}`;\n }\n\n constructor(host, slotName, tagName, config = {}) {\n super();\n\n const { initializer, multiple, observe, useUniqueId } = config;\n\n this.host = host;\n this.slotName = slotName;\n this.tagName = tagName;\n this.observe = typeof observe === 'boolean' ? observe : true;\n this.multiple = typeof multiple === 'boolean' ? multiple : false;\n this.slotInitializer = initializer;\n\n if (multiple) {\n this.nodes = [];\n }\n\n // Only generate the default ID if requested by the controller.\n if (useUniqueId) {\n this.defaultId = this.constructor.generateId(host, slotName);\n }\n }\n\n hostConnected() {\n if (!this.initialized) {\n if (this.multiple) {\n this.initMultiple();\n } else {\n this.initSingle();\n }\n\n if (this.observe) {\n this.observeSlot();\n }\n\n this.initialized = true;\n }\n }\n\n /** @protected */\n initSingle() {\n let node = this.getSlotChild();\n\n if (!node) {\n node = this.attachDefaultNode();\n this.initNode(node);\n } else {\n this.node = node;\n this.initAddedNode(node);\n }\n }\n\n /** @protected */\n initMultiple() {\n const children = this.getSlotChildren();\n\n if (children.length === 0) {\n const defaultNode = this.attachDefaultNode();\n if (defaultNode) {\n this.nodes = [defaultNode];\n this.initNode(defaultNode);\n }\n } else {\n this.nodes = children;\n children.forEach((node) => {\n this.initAddedNode(node);\n });\n }\n }\n\n /**\n * Create and attach default node using the provided tag name, if any.\n * @return {Node | undefined}\n * @protected\n */\n attachDefaultNode() {\n const { host, slotName, tagName } = this;\n\n // Check if the node was created previously and if so, reuse it.\n let node = this.defaultNode;\n\n // Tag name is optional, sometimes we don't init default content.\n if (!node && tagName) {\n node = document.createElement(tagName);\n if (node instanceof Element) {\n if (slotName !== '') {\n node.setAttribute('slot', slotName);\n }\n this.defaultNode = node;\n }\n }\n\n if (node) {\n this.node = node;\n host.appendChild(node);\n }\n\n return node;\n }\n\n /**\n * Return the list of nodes matching the slot managed by the controller.\n * @return {Node}\n */\n getSlotChildren() {\n const { slotName } = this;\n return Array.from(this.host.childNodes).filter((node) => {\n // Either an element (any slot) or a text node (only un-named slot).\n return (\n (node.nodeType === Node.ELEMENT_NODE && node.slot === slotName) ||\n (node.nodeType === Node.TEXT_NODE && node.textContent.trim() && slotName === '')\n );\n });\n }\n\n /**\n * Return a reference to the node managed by the controller.\n * @return {Node}\n */\n getSlotChild() {\n return this.getSlotChildren()[0];\n }\n\n /**\n * Run `slotInitializer` for the node managed by the controller.\n *\n * @param {Node} node\n * @protected\n */\n initNode(node) {\n const { slotInitializer } = this;\n // Don't try to bind `this` to initializer (normally it's arrow function).\n // Instead, pass the host as a first argument to access component's state.\n if (slotInitializer) {\n slotInitializer(node, this.host);\n }\n }\n\n /**\n * Override to initialize the newly added custom node.\n *\n * @param {Node} _node\n * @protected\n */\n initCustomNode(_node) {}\n\n /**\n * Override to teardown slotted node when it's removed.\n *\n * @param {Node} _node\n * @protected\n */\n teardownNode(_node) {}\n\n /**\n * Run both `initCustomNode` and `initNode` for a custom slotted node.\n *\n * @param {Node} node\n * @protected\n */\n initAddedNode(node) {\n if (node !== this.defaultNode) {\n this.initCustomNode(node);\n this.initNode(node);\n }\n }\n\n /**\n * Setup the observer to manage slot content changes.\n * @protected\n */\n observeSlot() {\n const { slotName } = this;\n const selector = slotName === '' ? 'slot:not([name])' : `slot[name=${slotName}]`;\n const slot = this.host.shadowRoot.querySelector(selector);\n\n this.__slotObserver = new SlotObserver(slot, ({ addedNodes, removedNodes }) => {\n const current = this.multiple ? this.nodes : [this.node];\n\n // Calling `slot.assignedNodes()` includes whitespace text nodes in case of default slot:\n // unlike comment nodes, they are not filtered out. So we need to manually ignore them.\n const newNodes = addedNodes.filter((node) => !isEmptyTextNode(node) && !current.includes(node));\n\n if (removedNodes.length) {\n this.nodes = current.filter((node) => !removedNodes.includes(node));\n\n removedNodes.forEach((node) => {\n this.teardownNode(node);\n });\n }\n\n if (newNodes && newNodes.length > 0) {\n if (this.multiple) {\n // Remove default node if exists\n if (this.defaultNode) {\n this.defaultNode.remove();\n }\n this.nodes = [...current, ...newNodes].filter((node) => node !== this.defaultNode);\n newNodes.forEach((node) => {\n this.initAddedNode(node);\n });\n } else {\n // Remove previous node if exists\n if (this.node) {\n this.node.remove();\n }\n this.node = newNodes[0];\n this.initAddedNode(this.node);\n }\n }\n });\n }\n}\n","import '@descope-ui/descope-list-item';\n\nimport { componentName, ListClass } from './ListClass';\n\ncustomElements.define(componentName, ListClass);\n\nexport { ListClass, componentName };\n","import { compose } from '@descope-ui/common/utils';\nimport { getComponentName, limitAbbreviation } from '@descope-ui/common/components-helpers';\nimport {\n createStyleMixin,\n draggableMixin,\n createProxy,\n componentNameValidationMixin,\n createDynamicDataMixin,\n} from '@descope-ui/common/components-mixins';\nimport { TextClass } from '@descope-ui/descope-text/class';\nimport { ListClass } from '@descope-ui/descope-list/class';\nimport { ListItemClass } from '@descope-ui/descope-list-item/class';\n\nexport const componentName = getComponentName('apps-list');\n\nconst itemRenderer = ({ name, icon, url }, _, ref) => `\n <a ${url ? `href=\"${url}\" title=\"${url}\"` : ''} target=\"_blank\">\n <descope-list-item>\n <descope-avatar\n ${icon ? `img=\"${icon}\"` : ''}\n ${name ? `display-name=\"${name}\" abbr=${limitAbbreviation(name)}` : ''}\n size=\"${ref.logoSize || ref.size}\"\n ></descope-avatar>\n <descope-text\n variant=\"${ref.itemTextVariant}\"\n mode=\"primary\"\n >${name}</descope-text>\n </descope-list-item>\n </a>\n`;\n\nconst customMixin = (superclass) =>\n class AppsListMixinClass extends superclass {\n // size controls both item logo size and font size\n get size() {\n return this.getAttribute('size') || 'sm';\n }\n\n get itemTextVariant() {\n return this.getAttribute('item-text-variant') || 'body1';\n }\n\n get logoSize() {\n return this.getAttribute('logo-size');\n }\n };\n\nexport const AppsListClass = compose(\n createStyleMixin({\n mappings: {\n maxHeight: { selector: () => ':host' },\n minHeight: { selector: () => ':host' },\n hostDirection: { selector: () => ':host', property: 'direction' },\n itemsFontWeight: {\n selector: TextClass.componentName,\n property: TextClass.cssVarList.fontWeightOverride,\n },\n itemsFontSize: {\n selector: TextClass.componentName,\n property: TextClass.cssVarList.fontSizeOverride,\n },\n itemsTextAlign: {\n selector: TextClass.componentName,\n property: TextClass.cssVarList.textAlign,\n },\n itemBackgroundColor: {\n selector: ListItemClass.componentName,\n property: ListItemClass.cssVarList.backgroundColor,\n },\n backgroundColor: {\n selector: ListClass.componentName,\n property: ListClass.cssVarList.backgroundColorOverride,\n },\n itemBorderStyle: {\n selector: ListItemClass.componentName,\n property: ListItemClass.cssVarList.borderStyleOverride,\n },\n itemBorderColor: {\n selector: ListItemClass.componentName,\n property: ListItemClass.cssVarList.borderColorOverride,\n },\n itemBorderWidth: {\n selector: ListItemClass.componentName,\n property: ListItemClass.cssVarList.borderWidthOverride,\n },\n itemVerticalPadding: {\n selector: ListItemClass.componentName,\n property: ListItemClass.cssVarList.verticalPaddingOverride,\n },\n itemHorizontalPadding: {\n selector: ListItemClass.componentName,\n property: ListItemClass.cssVarList.horizontalPaddingOverride,\n },\n itemAlignment: [\n { selector: ListItemClass.componentName, property: ListItemClass.cssVarList.alignItemsOverride },\n { selector: TextClass.componentName, property: TextClass.cssVarList.textAlign },\n ]\n },\n }),\n createDynamicDataMixin({ itemRenderer, rerenderAttrsList: ['size', 'item-text-variant', 'logo-size'] }),\n draggableMixin,\n componentNameValidationMixin,\n customMixin\n)(\n createProxy({\n slots: ['empty-state'],\n wrappedEleName: 'descope-list',\n excludeAttrsSync: ['tabindex', 'class', 'empty', 'style'],\n componentName,\n style: () => `\n :host {\n width: 100%;\n display: inline-flex;\n }\n\n descope-text::part(text-wrapper) {\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n overflow: hidden;\n }\n\n a {\n text-decoration: none;\n }\n\n descope-text {\n ${TextClass.cssVarList.hostDirection}: var(${AppsListClass.cssVarList.hostDirection});\n max-width: 100%;\n }\n `,\n })\n);\n","import '@descope-ui/descope-list';\nimport '@descope-ui/descope-avatar';\nimport '@descope-ui/descope-text';\nimport { componentName, AppsListClass } from './AppsListClass';\n\ncustomElements.define(componentName, AppsListClass);\n\nexport { AppsListClass, componentName };\n","/**\n * @license\n * Copyright (c) 2021 - 2023 Vaadin Ltd.\n * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/\n */\nimport { dedupingMixin } from '@polymer/polymer/lib/utils/mixin.js';\nimport { isKeyboardActive } from './focus-utils.js';\n\n/**\n * A mixin to handle `focused` and `focus-ring` attributes based on focus.\n *\n * @polymerMixin\n */\nexport const FocusMixin = dedupingMixin(\n (superclass) =>\n class FocusMixinClass extends superclass {\n /**\n * @protected\n * @return {boolean}\n */\n get _keyboardActive() {\n return isKeyboardActive();\n }\n\n /** @protected */\n ready() {\n this.addEventListener('focusin', (e) => {\n if (this._shouldSetFocus(e)) {\n this._setFocused(true);\n }\n });\n\n this.addEventListener('focusout', (e) => {\n if (this._shouldRemoveFocus(e)) {\n this._setFocused(false);\n }\n });\n\n // In super.ready() other 'focusin' and 'focusout' listeners might be\n // added, so we call it after our own ones to ensure they execute first.\n // Issue to watch out: when incorrect, <vaadin-combo-box> refocuses the\n // input field on iOS after \"Done\" is pressed.\n super.ready();\n }\n\n /** @protected */\n disconnectedCallback() {\n super.disconnectedCallback();\n\n // In non-Chrome browsers, blur does not fire on the element when it is disconnected.\n // reproducible in `<vaadin-date-picker>` when closing on `Cancel` or `Today` click.\n if (this.hasAttribute('focused')) {\n this._setFocused(false);\n }\n }\n\n /**\n * Override to change how focused and focus-ring attributes are set.\n *\n * @param {boolean} focused\n * @protected\n */\n _setFocused(focused) {\n this.toggleAttribute('focused', focused);\n\n // Focus-ring is true when the element was focused from the keyboard.\n // Focus Ring [A11ycasts]: https://youtu.be/ilj2P5-5CjI\n this.toggleAttribute('focus-ring', focused && this._keyboardActive);\n }\n\n /**\n * Override to define if the field receives focus based on the event.\n *\n * @param {FocusEvent} _event\n * @return {boolean}\n * @protected\n */\n _shouldSetFocus(_event) {\n return true;\n }\n\n /**\n * Override to define if the field loses focus based on the event.\n *\n * @param {FocusEvent} _event\n * @return {boolean}\n * @protected\n */\n _shouldRemoveFocus(_event) {\n return true;\n }\n },\n);\n","import {\n createStyleMixin,\n draggableMixin,\n componentNameValidationMixin,\n} from '@descope-ui/common/components-mixins';\nimport { createBaseClass } from '@descope-ui/common/base-classes';\nimport { compose } from '@descope-ui/common/utils';\nimport {\n forwardAttrs,\n getComponentName,\n injectStyle,\n observeAttributes,\n} from '@descope-ui/common/components-helpers';\n\nexport const componentName = getComponentName('avatar');\nclass RawAvatar extends createBaseClass({\n componentName,\n baseSelector: ':host > .wrapper',\n}) {\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n <div class=\"wrapper\">\n <vaadin-avatar></vaadin-avatar>\n <div class=\"editableBadge\">\n <vaadin-icon icon=\"vaadin:pencil\"></vaadin-icon>\n </div>\n </div>\n\t\t`;\n\n injectStyle(`\n :host {\n\t\t\t\t\tdisplay: inline-flex;\n\t\t\t\t}\n\n .editableBadge {\n border: 1px solid;\n border-radius: 100%;\n height: fit-content;\n width: 25%;\n height: 25%;\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 5%;\n box-sizing: border-box;\n position: absolute;\n bottom: 0;\n inset-inline-end: 0;\n }\n\n vaadin-icon {\n color: currentcolor;\n }\n\n vaadin-avatar {\n width: 100%;\n height: 100%;\n margin: 0;\n border: none\n }\n\n .wrapper {\n display: inline-flex;\n position: relative;\n width: 100%;\n height: 100%;\n }\n `, this);\n\n this.avatarComponent = this.shadowRoot.querySelector('vaadin-avatar');\n\n forwardAttrs(this, this.avatarComponent, {\n includeAttrs: ['display-name', 'img', 'abbr'],\n mapAttrs: { 'display-name': 'name' },\n });\n\n const editableIcon = this.shadowRoot.querySelector('.editableBadge');\n\n observeAttributes(\n this,\n () => {\n editableIcon.style.display = this.isEditable ? '' : 'none';\n },\n { includeAttrs: ['editable'] },\n );\n }\n\n get isEditable() {\n return this.getAttribute('editable') === 'true';\n }\n}\n\nconst { host, editableBadge, avatar } = {\n host: { selector: () => ':host' },\n editableBadge: { selector: '> .editableBadge' },\n avatar: { selector: 'vaadin-avatar' },\n};\n\nexport const AvatarClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: [\n { ...host, property: 'width' },\n { ...host, property: 'min-width' },\n ],\n hostHeight: { ...host, property: 'height' },\n cursor: [avatar, host],\n hostDirection: { ...host, property: 'direction' },\n avatarTextColor: { ...avatar, property: 'color' },\n avatarBackgroundColor: { ...avatar, property: 'background-color' },\n editableIconColor: { ...editableBadge, property: 'color' },\n editableBorderColor: { ...editableBadge, property: 'border-color' },\n editableBackgroundColor: {\n ...editableBadge,\n property: 'background-color',\n },\n },\n }),\n draggableMixin,\n componentNameValidationMixin,\n)(RawAvatar);\n","import { componentName, AvatarClass } from './AvatarClass';\nimport '@vaadin/avatar';\nimport '@vaadin/icon';\nimport '@vaadin/icons';\n\ncustomElements.define(componentName, AvatarClass);\n\nexport { AvatarClass, componentName };\n","import { componentName, TextClass } from './TextClass';\n\ncustomElements.define(componentName, TextClass);\n\nexport { TextClass, componentName };\n","/**\n * @license\n * Copyright (c) 2023 Vaadin Ltd.\n * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/\n */\n\n/**\n * A helper for observing slot changes.\n */\nexport class SlotObserver {\n constructor(slot, callback) {\n /** @type HTMLSlotElement */\n this.slot = slot;\n\n /** @type Function */\n this.callback = callback;\n\n /** @type {Node[]} */\n this._storedNodes = [];\n\n this._connected = false;\n this._scheduled = false;\n\n this._boundSchedule = () => {\n this._schedule();\n };\n\n this.connect();\n this._schedule();\n }\n\n /**\n * Activates an observer. This method is automatically called when\n * a `SlotObserver` is created. It should only be called to re-activate\n * an observer that has been deactivated via the `disconnect` method.\n */\n connect() {\n this.slot.addEventListener('slotchange', this._boundSchedule);\n this._connected = true;\n }\n\n /**\n * Deactivates the observer. After calling this method the observer callback\n * will not be called when changes to slotted nodes occur. The `connect` method\n * may be subsequently called to reactivate the observer.\n */\n disconnect() {\n this.slot.removeEventListener('slotchange', this._boundSchedule);\n this._connected = false;\n }\n\n /** @private */\n _schedule() {\n if (!this._scheduled) {\n this._scheduled = true;\n\n queueMicrotask(() => {\n this.flush();\n });\n }\n }\n\n /**\n * Run the observer callback synchronously.\n */\n flush() {\n if (!this._connected) {\n return;\n }\n\n this._scheduled = false;\n\n this._processNodes();\n }\n\n /** @private */\n _processNodes() {\n const currentNodes = this.slot.assignedNodes({ flatten: true });\n\n let addedNodes = [];\n const removedNodes = [];\n const movedNodes = [];\n\n if (currentNodes.length) {\n addedNodes = currentNodes.filter((node) => !this._storedNodes.includes(node));\n }\n\n if (this._storedNodes.length) {\n this._storedNodes.forEach((node, index) => {\n const idx = currentNodes.indexOf(node);\n if (idx === -1) {\n removedNodes.push(node);\n } else if (idx !== index) {\n movedNodes.push(node);\n }\n });\n }\n\n if (addedNodes.length || removedNodes.length || movedNodes.length) {\n this.callback({ addedNodes, movedNodes, removedNodes });\n }\n\n this._storedNodes = currentNodes;\n }\n}\n","import {\n createStyleMixin,\n draggableMixin,\n componentNameValidationMixin,\n} from '@descope-ui/common/components-mixins';\nimport { compose } from '@descope-ui/common/utils';\nimport {\n getComponentName,\n injectStyle,\n observeChildren,\n} from '@descope-ui/common/components-helpers';\nimport { createBaseClass } from '@descope-ui/common/base-classes';\n\nexport const componentName = getComponentName('text');\n\nclass RawText extends createBaseClass({\n componentName,\n baseSelector: ':host > slot',\n}) {\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n <slot part=\"text-wrapper\"></slot>\n `;\n\n injectStyle(`\n :host {\n display: inline-block;\n line-height: 1em;\n }\n :host > slot {\n width: 100%;\n display: inline-block;\n }\n `, this);\n }\n\n get hideWhenEmpty() {\n return this.getAttribute('hide-when-empty') === 'true';\n }\n\n init() {\n super.init();\n\n observeChildren(this, () => {\n const hasChildren = !!this.childNodes.length;\n this.style.display = !hasChildren && this.hideWhenEmpty ? 'none' : '';\n });\n }\n}\n\nconst { host } = {\n host: { selector: () => ':host' }\n}\n\nexport const TextClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { ...host, property: 'width' },\n hostDirection: { ...host, property: 'direction' },\n fontSize: {},\n textColor: [\n { property: 'color' }\n ],\n textLineHeight: { property: 'line-height' },\n textLetterSpacing: { property: 'letter-spacing' },\n textShadow: {},\n textAlign: {},\n textTransform: {},\n fontFamily: {},\n fontStyle: {},\n fontWeight: {},\n borderWidth: {},\n borderStyle: {},\n borderColor: {},\n },\n }),\n draggableMixin,\n componentNameValidationMixin,\n)(RawText);\n","/**\n * @license\n * Copyright (c) 2022 - 2023 Vaadin Ltd.\n * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/\n */\nimport { SlotController } from './slot-controller.js';\n\n/**\n * A controller that manages the slotted tooltip element.\n */\nexport class TooltipController extends SlotController {\n constructor(host) {\n // Do not provide slot factory to create tooltip lazily.\n super(host, 'tooltip');\n\n this.setTarget(host);\n }\n\n /**\n * Override to initialize the newly added custom tooltip.\n *\n * @param {Node} tooltipNode\n * @protected\n * @override\n */\n initCustomNode(tooltipNode) {\n tooltipNode.target = this.target;\n\n if (this.ariaTarget !== undefined) {\n tooltipNode.ariaTarget = this.ariaTarget;\n }\n\n if (this.context !== undefined) {\n tooltipNode.context = this.context;\n }\n\n if (this.manual !== undefined) {\n tooltipNode.manual = this.manual;\n }\n\n if (this.opened !== undefined) {\n tooltipNode.opened = this.opened;\n }\n\n if (this.position !== undefined) {\n tooltipNode._position = this.position;\n }\n\n if (this.shouldShow !== undefined) {\n tooltipNode.shouldShow = this.shouldShow;\n }\n\n this.__notifyChange();\n }\n\n /**\n * Override to notify the host when the tooltip is removed.\n *\n * @param {Node} tooltipNode\n * @protected\n * @override\n */\n teardownNode() {\n this.__notifyChange();\n }\n\n /**\n * Set an HTML element for linking with the tooltip overlay\n * via `aria-describedby` attribute used by screen readers.\n * @param {HTMLElement} ariaTarget\n */\n setAriaTarget(ariaTarget) {\n this.ariaTarget = ariaTarget;\n\n const tooltipNode = this.node;\n if (tooltipNode) {\n tooltipNode.ariaTarget = ariaTarget;\n }\n }\n\n /**\n * Set a context object to be used by generator.\n * @param {object} context\n */\n setContext(context) {\n this.context = context;\n\n const tooltipNode = this.node;\n if (tooltipNode) {\n tooltipNode.context = context;\n }\n }\n\n /**\n * Toggle manual state on the slotted tooltip.\n * @param {boolean} manual\n */\n setManual(manual) {\n this.manual = manual;\n\n const tooltipNode = this.node;\n if (tooltipNode) {\n tooltipNode.manual = manual;\n }\n }\n\n /**\n * Toggle opened state on the slotted tooltip.\n * @param {boolean} opened\n */\n setOpened(opened) {\n this.opened = opened;\n\n const tooltipNode = this.node;\n if (tooltipNode) {\n tooltipNode.opened = opened;\n }\n }\n\n /**\n * Set default position for the slotted tooltip.\n * This can be overridden by setting the position\n * using corresponding property or attribute.\n * @param {string} position\n */\n setPosition(position) {\n this.position = position;\n\n const tooltipNode = this.node;\n if (tooltipNode) {\n tooltipNode._position = position;\n }\n }\n\n /**\n * Set function used to detect whether to show\n * the tooltip based on a condition.\n * @param {Function} shouldShow\n */\n setShouldShow(shouldShow) {\n this.shouldShow = shouldShow;\n\n const tooltipNode = this.node;\n if (tooltipNode) {\n tooltipNode.shouldShow = shouldShow;\n }\n }\n\n /**\n * Set an HTML element to attach the tooltip to.\n * @param {HTMLElement} target\n */\n setTarget(target) {\n this.target = target;\n\n const tooltipNode = this.node;\n if (tooltipNode) {\n tooltipNode.target = target;\n }\n }\n\n /** @private */\n __notifyChange() {\n this.dispatchEvent(new CustomEvent('tooltip-changed', { detail: { node: this.node } }));\n }\n}\n","import {\n createStyleMixin,\n draggableMixin,\n componentNameValidationMixin,\n activeableMixin,\n} from '@descope-ui/common/components-mixins';\nimport { compose } from '@descope-ui/common/utils';\nimport { getComponentName } from '@descope-ui/common/components-helpers';\nimport { injectStyle } from '@descope-ui/common/components-helpers';\nimport { createBaseClass } from '@descope-ui/common/base-classes';\n\nexport const componentName = getComponentName('list-item');\n\nconst customMixin = (superclass) =>\n class ListItemMixinClass extends superclass {\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n <slot></slot>\n `;\n\n injectStyle(\n `\n slot {\n width: 100%;\n display: flex;\n overflow: hidden;\n box-sizing: border-box;\n }\n :host {\n display: block;\n }\n `,\n this,\n );\n }\n };\n\nexport const ListItemClass = compose(\n createStyleMixin({\n mappings: {\n verticalPadding: [\n { property: 'padding-top' },\n { property: 'padding-bottom' },\n ],\n horizontalPadding: [\n { property: 'padding-left' },\n { property: 'padding-right' },\n ],\n backgroundColor: {},\n borderColor: {},\n borderStyle: {},\n borderWidth: {},\n borderRadius: {},\n outline: {},\n cursor: {},\n gap: {},\n maxWidth: { selector: () => ':host' },\n alignItems: {},\n flexDirection: {},\n transition: {},\n },\n }),\n draggableMixin,\n componentNameValidationMixin,\n customMixin,\n activeableMixin,\n)(createBaseClass({ componentName, baseSelector: 'slot' }));\n"],"names":["getAncestorRootNodes","node","result","nodeType","Node","DOCUMENT_NODE","push","DOCUMENT_FRAGMENT_NODE","assignedSlot","parentNode","host","getFlattenedElements","elements","localName","assignedElements","children","forEach","elem","getClosestElement","selector","closest","getRootNode","deserializeAttributeValue","value","Set","split","serializeAttributeValue","values","join","addValueToAttribute","element","attr","getAttribute","add","setAttribute","removeValueFromAttribute","delete","size","removeAttribute","isEmptyTextNode","TEXT_NODE","textContent","trim","componentName","RawList","baseSelector","observedAttributes","constructor","super","this","attachShadow","mode","innerHTML","items","shadowRoot","querySelector","length","variant","item","listItem","listItemVariant","init","isReadOnly","attributeChangedCallback","name","oldValue","newValue","ListClass","mappings","hostWidth","property","maxHeight","minHeight","verticalPadding","horizontalPadding","hostDirection","fontFamily","gap","backgroundColor","borderRadius","borderColor","borderStyle","borderWidth","boxShadow","gridTemplateColumns","maxItemsWidth","minItemsWidth","itemsHorizontalAlign","emptyStateTextColor","emptyStateTextFontFamily","uniqueId","generateUniqueId","customElements","define","sizing","SlotController","EventTarget","generateId","slotName","tagName","config","initializer","multiple","observe","useUniqueId","slotInitializer","nodes","defaultId","hostConnected","initialized","initMultiple","initSingle","observeSlot","getSlotChild","initAddedNode","attachDefaultNode","initNode","getSlotChildren","defaultNode","document","createElement","Element","appendChild","Array","from","childNodes","filter","ELEMENT_NODE","slot","initCustomNode","_node","teardownNode","__slotObserver","addedNodes","removedNodes","current","newNodes","includes","remove","AppsListClass","itemsFontWeight","TextClass","cssVarList","fontWeightOverride","itemsFontSize","fontSizeOverride","itemsTextAlign","textAlign","itemBackgroundColor","ListItemClass","backgroundColorOverride","itemBorderStyle","borderStyleOverride","itemBorderColor","borderColorOverride","itemBorderWidth","borderWidthOverride","itemVerticalPadding","verticalPaddingOverride","itemHorizontalPadding","horizontalPaddingOverride","itemAlignment","alignItemsOverride","itemRenderer","icon","url","_","ref","logoSize","itemTextVariant","rerenderAttrsList","superclass","slots","wrappedEleName","excludeAttrsSync","style","FocusMixin","_keyboardActive","ready","addEventListener","e","_shouldSetFocus","_setFocused","_shouldRemoveFocus","disconnectedCallback","hasAttribute","focused","toggleAttribute","_event","RawAvatar","avatarComponent","includeAttrs","mapAttrs","editableIcon","display","isEditable","editableBadge","avatar","AvatarClass","hostHeight","cursor","avatarTextColor","avatarBackgroundColor","editableIconColor","editableBorderColor","editableBackgroundColor","SlotObserver","callback","_storedNodes","_connected","_scheduled","_boundSchedule","_schedule","connect","disconnect","removeEventListener","queueMicrotask","flush","_processNodes","currentNodes","assignedNodes","flatten","movedNodes","index","idx","indexOf","RawText","hideWhenEmpty","hasChildren","fontSize","textColor","textLineHeight","textLetterSpacing","textShadow","textTransform","fontStyle","fontWeight","TooltipController","setTarget","tooltipNode","target","undefined","ariaTarget","context","manual","opened","position","_position","shouldShow","__notifyChange","setAriaTarget","setContext","setManual","setOpened","setPosition","setShouldShow","dispatchEvent","CustomEvent","detail","outline","maxWidth","alignItems","flexDirection","transition"],"sourceRoot":""}
1
+ {"version":3,"file":"descope-apps-list.js","mappings":";2JAgBO,SAASA,EAAqBC,GACnC,MAAMC,EAAS,GAEf,KAAOD,GAAM,CACX,GAAIA,EAAKE,WAAaC,KAAKC,cAAe,CACxCH,EAAOI,KAAKL,GACZ,KACF,CAEIA,EAAKE,WAAaC,KAAKG,uBAOzBN,EADEA,EAAKO,aACAP,EAAKO,aAIPP,EAAKQ,YAVVP,EAAOI,KAAKL,GACZA,EAAOA,EAAKS,KAUhB,CAEA,OAAOR,CACT,CAUO,SAASS,EAAqBV,GACnC,MAAMC,EAAS,GACf,IAAIU,EAQJ,MAPuB,SAAnBX,EAAKY,UACPD,EAAWX,EAAKa,oBAEhBZ,EAAOI,KAAKL,GACZW,EAAW,IAAIX,EAAKc,WAEtBH,EAASI,QAASC,GAASf,EAAOI,QAAQK,EAAqBM,KACxDf,CACT,CAUO,SAASgB,EAAkBC,EAAUlB,GAC1C,OAAKA,EAIEA,EAAKmB,QAAQD,IAAaD,EAAkBC,EAAU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AAY,kBAAmB,CAAEC,OAAQ,CAAEhQ,KAAMgD,KAAKhD,QAC/E,E,2FCzJK,MAAM0C,GAAgB,QAAiB,aA4BjC0G,GAAgB,SAC3B,QAAiB,CACfjF,SAAU,CACRK,gBAAiB,CACf,CAAEH,SAAU,eACZ,CAAEA,SAAU,mBAEdI,kBAAmB,CACjB,CAAEJ,SAAU,gBACZ,CAAEA,SAAU,kBAEdQ,gBAAiB,CAAC,EAClBE,YAAa,CAAC,EACdC,YAAa,CAAC,EACdC,YAAa,CAAC,EACdH,aAAc,CAAC,EACfmL,QAAS,CAAC,EACV3D,OAAQ,CAAC,EACT1H,IAAK,CAAC,EACNsL,SAAU,CAAEhP,SAAU,IAAM,SAC5BiP,WAAY,CAAC,EACbC,cAAe,CAAC,EAChBC,WAAY,CAAC,KAGjB,KACA,KApDmB5F,GACnB,cAAiCA,EAC/B,WAAA3H,GACEC,QAEAC,KAAKC,aAAa,CAAEC,KAAM,SAAUC,UAAY,+BAIhD,QACE,uMAWAH,KAEJ,GA+BF,IA5B2B,EA6B3B,QAAgB,CAAEN,gBAAeE,aAAc,S","sources":["webpack://@descope/web-components-ui/../../../node_modules/@vaadin/component-base/src/dom-utils.js","webpack://@descope/web-components-ui/../components/descope-list/src/component/ListClass.js","webpack://@descope/web-components-ui/../../../node_modules/@vaadin/component-base/src/unique-id-utils.js","webpack://@descope/web-components-ui/../components/descope-list-item/src/component/index.js","webpack://@descope/web-components-ui/../../../node_modules/@vaadin/vaadin-lumo-styles/sizing.js","webpack://@descope/web-components-ui/../../../node_modules/@vaadin/component-base/src/slot-controller.js","webpack://@descope/web-components-ui/../components/descope-list/src/component/index.js","webpack://@descope/web-components-ui/../components/descope-apps-list/src/component/AppsListClass.js","webpack://@descope/web-components-ui/../components/descope-apps-list/src/component/index.js","webpack://@descope/web-components-ui/../../../node_modules/@vaadin/a11y-base/src/focus-mixin.js","webpack://@descope/web-components-ui/../components/descope-avatar/src/component/AvatarClass.js","webpack://@descope/web-components-ui/../components/descope-avatar/src/component/index.js","webpack://@descope/web-components-ui/../components/descope-text/src/component/index.js","webpack://@descope/web-components-ui/../../../node_modules/@vaadin/component-base/src/slot-observer.js","webpack://@descope/web-components-ui/../components/descope-text/src/component/TextClass.js","webpack://@descope/web-components-ui/../../../node_modules/@vaadin/component-base/src/tooltip-controller.js","webpack://@descope/web-components-ui/../components/descope-list-item/src/component/ListItemClass.js"],"sourcesContent":["/**\n * @license\n * Copyright (c) 2021 - 2023 Vaadin Ltd.\n * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/\n */\n\n/**\n * Returns an array of ancestor root nodes for the given node.\n *\n * A root node is either a document node or a document fragment node (Shadow Root).\n * The array is collected by a bottom-up DOM traversing that starts with the given node\n * and involves both the light DOM and ancestor shadow DOM trees.\n *\n * @param {Node} node\n * @return {Node[]}\n */\nexport function getAncestorRootNodes(node) {\n const result = [];\n\n while (node) {\n if (node.nodeType === Node.DOCUMENT_NODE) {\n result.push(node);\n break;\n }\n\n if (node.nodeType === Node.DOCUMENT_FRAGMENT_NODE) {\n result.push(node);\n node = node.host;\n continue;\n }\n\n if (node.assignedSlot) {\n node = node.assignedSlot;\n continue;\n }\n\n node = node.parentNode;\n }\n\n return result;\n}\n\n/**\n * Returns the list of flattened elements for the given `node`.\n * This list consists of a node's children and, for any children that are\n * `<slot>` elements, the expanded flattened list of `assignedElements`.\n *\n * @param {Node} node\n * @return {Element[]}\n */\nexport function getFlattenedElements(node) {\n const result = [];\n let elements;\n if (node.localName === 'slot') {\n elements = node.assignedElements();\n } else {\n result.push(node);\n elements = [...node.children];\n }\n elements.forEach((elem) => result.push(...getFlattenedElements(elem)));\n return result;\n}\n\n/**\n * Traverses the given node and its parents, including those that are across\n * the shadow root boundaries, until it finds a node that matches the selector.\n *\n * @param {string} selector The CSS selector to match against\n * @param {Node} node The starting node for the traversal\n * @return {Node | null} The closest matching element, or null if no match is found\n */\nexport function getClosestElement(selector, node) {\n if (!node) {\n return null;\n }\n\n return node.closest(selector) || getClosestElement(selector, node.getRootNode().host);\n}\n\n/**\n * Takes a string with values separated by space and returns a set the values\n *\n * @param {string} value\n * @return {Set<string>}\n */\nexport function deserializeAttributeValue(value) {\n if (!value) {\n return new Set();\n }\n\n return new Set(value.split(' '));\n}\n\n/**\n * Takes a set of string values and returns a string with values separated by space\n *\n * @param {Set<string>} values\n * @return {string}\n */\nexport function serializeAttributeValue(values) {\n return values ? [...values].join(' ') : '';\n}\n\n/**\n * Adds a value to an attribute containing space-delimited values.\n *\n * @param {HTMLElement} element\n * @param {string} attr\n * @param {string} value\n */\nexport function addValueToAttribute(element, attr, value) {\n const values = deserializeAttributeValue(element.getAttribute(attr));\n values.add(value);\n element.setAttribute(attr, serializeAttributeValue(values));\n}\n\n/**\n * Removes a value from an attribute containing space-delimited values.\n * If the value is the last one, the whole attribute is removed.\n *\n * @param {HTMLElement} element\n * @param {string} attr\n * @param {string} value\n */\nexport function removeValueFromAttribute(element, attr, value) {\n const values = deserializeAttributeValue(element.getAttribute(attr));\n values.delete(value);\n if (values.size === 0) {\n element.removeAttribute(attr);\n return;\n }\n element.setAttribute(attr, serializeAttributeValue(values));\n}\n\n/**\n * Returns true if the given node is an empty text node, false otherwise.\n *\n * @param {Node} node\n * @return {boolean}\n */\nexport function isEmptyTextNode(node) {\n return node.nodeType === Node.TEXT_NODE && node.textContent.trim() === '';\n}\n","import {\n createStyleMixin,\n draggableMixin,\n componentNameValidationMixin,\n} from '@descope-ui/common/components-mixins';\nimport { compose } from '@descope-ui/common/utils';\nimport {\n getComponentName,\n observeChildren,\n} from '@descope-ui/common/components-helpers';\nimport { injectStyle } from '@descope-ui/common/components-helpers';\nimport { ListItemClass } from '@descope-ui/descope-list-item/class';\nimport { createBaseClass } from '@descope-ui/common/base-classes';\n\nexport const componentName = getComponentName('list');\n\nclass RawList extends createBaseClass({\n componentName,\n baseSelector: '.wrapper',\n}) {\n static get observedAttributes() {\n return ['variant', 'readonly'];\n }\n\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n <div class=\"wrapper\">\n <slot></slot>\n <slot name=\"empty-state\">\n No item...\n </slot>\n </div>\n\t`;\n\n injectStyle(\n `\n .wrapper {\n overflow: auto;\n display: grid;\n max-height: 100%;\n width: 100%;\n }\n\n :host {\n display: inline-flex;\n width: 100%;\n }\n slot[name=\"empty-state\"] {\n justify-content: center;\n align-items: center;\n display: flex;\n flex-grow: 1;\n }\n\n :host slot[name=\"empty-state\"] {\n display: none;\n }\n :host([empty]) slot[name=\"empty-state\"] {\n display: flex;\n }\n ::slotted(:not([slot])) {\n width: 100%;\n }\n `,\n this,\n );\n }\n\n get items() {\n return this.shadowRoot.querySelector('slot').assignedElements();\n }\n\n #handleEmptyState() {\n if (this.items.length === 0) {\n this.setAttribute('empty', 'true');\n } else {\n this.removeAttribute('empty');\n }\n }\n\n get variant() {\n return this.getAttribute('variant') || 'list';\n }\n\n #handleItemsVariant() {\n this.items.forEach((item) => {\n let listItem = item;\n if (listItem.localName !== ListItemClass.componentName) {\n listItem = item.querySelector(ListItemClass.componentName);\n }\n\n const listItemVariant = this.variant === 'tiles' ? 'tile' : 'row';\n listItem?.setAttribute('variant', listItemVariant);\n });\n }\n\n init() {\n super.init?.();\n\n // we want new items to get the size\n observeChildren(this, () => {\n this.#handleEmptyState();\n this.#handleItemsVariant();\n this.#handleReadOnly();\n });\n }\n\n get isReadOnly() {\n return this.getAttribute('readonly') === 'true';\n }\n\n #handleReadOnly() {\n this.items.forEach((item) => {\n if (this.isReadOnly) item.setAttribute('inert', '');\n else item.removeAttribute('inert');\n });\n }\n\n attributeChangedCallback(name, oldValue, newValue) {\n super.attributeChangedCallback?.(name, oldValue, newValue);\n\n if (newValue === oldValue) return;\n\n if (name === 'variant') {\n this.#handleItemsVariant();\n } else if (name === 'readonly') {\n this.#handleReadOnly();\n }\n }\n}\n\nexport const ListClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { selector: () => ':host', property: 'width' },\n maxHeight: { selector: () => ':host' },\n minHeight: {},\n verticalPadding: [\n { property: 'padding-top' },\n { property: 'padding-bottom' },\n ],\n horizontalPadding: [\n { property: 'padding-left' },\n { property: 'padding-right' },\n ],\n hostDirection: { selector: () => ':host', property: 'direction' },\n fontFamily: {},\n gap: {},\n\n backgroundColor: {},\n borderRadius: {},\n borderColor: {},\n borderStyle: {},\n borderWidth: {},\n\n boxShadow: {},\n gridTemplateColumns: {},\n maxItemsWidth: {\n selector: () => '::slotted(:not([slot]))',\n property: 'max-width',\n },\n minItemsWidth: {\n selector: () => '::slotted(:not([slot]))',\n property: 'min-width',\n },\n itemsHorizontalAlign: {\n selector: () => '::slotted(*)',\n property: 'justify-self',\n },\n emptyStateTextColor: {\n selector: () => 'slot[name=\"empty-state\"]',\n property: 'color',\n },\n emptyStateTextFontFamily: {\n selector: () => 'slot[name=\"empty-state\"]',\n property: 'font-family',\n },\n },\n }),\n draggableMixin,\n componentNameValidationMixin,\n)(RawList);\n","/**\n * @license\n * Copyright (c) 2021 - 2023 Vaadin Ltd.\n * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/\n */\n\nlet uniqueId = 0;\n\n/**\n * Resets the unique id counter.\n *\n * @return {void}\n */\nexport function resetUniqueId() {\n uniqueId = 0;\n}\n\n/**\n * Returns a unique integer id.\n *\n * @return {number}\n */\nexport function generateUniqueId() {\n // eslint-disable-next-line no-plusplus\n return uniqueId++;\n}\n","import { componentName, ListItemClass } from './ListItemClass';\n\ncustomElements.define(componentName, ListItemClass);\n\nexport { ListItemClass, componentName };\n","/**\n * @license\n * Copyright (c) 2017 - 2023 Vaadin Ltd.\n * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/\n */\nimport './version.js';\nimport { css } from '@vaadin/vaadin-themable-mixin/vaadin-themable-mixin.js';\nimport { addLumoGlobalStyles } from './global.js';\n\nconst sizing = css`\n :host {\n --lumo-size-xs: 1.625rem;\n --lumo-size-s: 1.875rem;\n --lumo-size-m: 2.25rem;\n --lumo-size-l: 2.75rem;\n --lumo-size-xl: 3.5rem;\n\n /* Icons */\n --lumo-icon-size-s: 1.25em;\n --lumo-icon-size-m: 1.5em;\n --lumo-icon-size-l: 2.25em;\n /* For backwards compatibility */\n --lumo-icon-size: var(--lumo-icon-size-m);\n }\n`;\n\naddLumoGlobalStyles('sizing-props', sizing);\n\nexport { sizing };\n","/**\n * @license\n * Copyright (c) 2021 - 2023 Vaadin Ltd.\n * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/\n */\nimport { isEmptyTextNode } from './dom-utils.js';\nimport { SlotObserver } from './slot-observer.js';\nimport { generateUniqueId } from './unique-id-utils.js';\n\n/**\n * A controller for providing content to slot element and observing changes.\n */\nexport class SlotController extends EventTarget {\n /**\n * Ensure that every instance has unique ID.\n *\n * @param {HTMLElement} host\n * @param {string} slotName\n * @return {string}\n * @protected\n */\n static generateId(host, slotName) {\n const prefix = slotName || 'default';\n return `${prefix}-${host.localName}-${generateUniqueId()}`;\n }\n\n constructor(host, slotName, tagName, config = {}) {\n super();\n\n const { initializer, multiple, observe, useUniqueId } = config;\n\n this.host = host;\n this.slotName = slotName;\n this.tagName = tagName;\n this.observe = typeof observe === 'boolean' ? observe : true;\n this.multiple = typeof multiple === 'boolean' ? multiple : false;\n this.slotInitializer = initializer;\n\n if (multiple) {\n this.nodes = [];\n }\n\n // Only generate the default ID if requested by the controller.\n if (useUniqueId) {\n this.defaultId = this.constructor.generateId(host, slotName);\n }\n }\n\n hostConnected() {\n if (!this.initialized) {\n if (this.multiple) {\n this.initMultiple();\n } else {\n this.initSingle();\n }\n\n if (this.observe) {\n this.observeSlot();\n }\n\n this.initialized = true;\n }\n }\n\n /** @protected */\n initSingle() {\n let node = this.getSlotChild();\n\n if (!node) {\n node = this.attachDefaultNode();\n this.initNode(node);\n } else {\n this.node = node;\n this.initAddedNode(node);\n }\n }\n\n /** @protected */\n initMultiple() {\n const children = this.getSlotChildren();\n\n if (children.length === 0) {\n const defaultNode = this.attachDefaultNode();\n if (defaultNode) {\n this.nodes = [defaultNode];\n this.initNode(defaultNode);\n }\n } else {\n this.nodes = children;\n children.forEach((node) => {\n this.initAddedNode(node);\n });\n }\n }\n\n /**\n * Create and attach default node using the provided tag name, if any.\n * @return {Node | undefined}\n * @protected\n */\n attachDefaultNode() {\n const { host, slotName, tagName } = this;\n\n // Check if the node was created previously and if so, reuse it.\n let node = this.defaultNode;\n\n // Tag name is optional, sometimes we don't init default content.\n if (!node && tagName) {\n node = document.createElement(tagName);\n if (node instanceof Element) {\n if (slotName !== '') {\n node.setAttribute('slot', slotName);\n }\n this.defaultNode = node;\n }\n }\n\n if (node) {\n this.node = node;\n host.appendChild(node);\n }\n\n return node;\n }\n\n /**\n * Return the list of nodes matching the slot managed by the controller.\n * @return {Node}\n */\n getSlotChildren() {\n const { slotName } = this;\n return Array.from(this.host.childNodes).filter((node) => {\n // Either an element (any slot) or a text node (only un-named slot).\n return (\n (node.nodeType === Node.ELEMENT_NODE && node.slot === slotName) ||\n (node.nodeType === Node.TEXT_NODE && node.textContent.trim() && slotName === '')\n );\n });\n }\n\n /**\n * Return a reference to the node managed by the controller.\n * @return {Node}\n */\n getSlotChild() {\n return this.getSlotChildren()[0];\n }\n\n /**\n * Run `slotInitializer` for the node managed by the controller.\n *\n * @param {Node} node\n * @protected\n */\n initNode(node) {\n const { slotInitializer } = this;\n // Don't try to bind `this` to initializer (normally it's arrow function).\n // Instead, pass the host as a first argument to access component's state.\n if (slotInitializer) {\n slotInitializer(node, this.host);\n }\n }\n\n /**\n * Override to initialize the newly added custom node.\n *\n * @param {Node} _node\n * @protected\n */\n initCustomNode(_node) {}\n\n /**\n * Override to teardown slotted node when it's removed.\n *\n * @param {Node} _node\n * @protected\n */\n teardownNode(_node) {}\n\n /**\n * Run both `initCustomNode` and `initNode` for a custom slotted node.\n *\n * @param {Node} node\n * @protected\n */\n initAddedNode(node) {\n if (node !== this.defaultNode) {\n this.initCustomNode(node);\n this.initNode(node);\n }\n }\n\n /**\n * Setup the observer to manage slot content changes.\n * @protected\n */\n observeSlot() {\n const { slotName } = this;\n const selector = slotName === '' ? 'slot:not([name])' : `slot[name=${slotName}]`;\n const slot = this.host.shadowRoot.querySelector(selector);\n\n this.__slotObserver = new SlotObserver(slot, ({ addedNodes, removedNodes }) => {\n const current = this.multiple ? this.nodes : [this.node];\n\n // Calling `slot.assignedNodes()` includes whitespace text nodes in case of default slot:\n // unlike comment nodes, they are not filtered out. So we need to manually ignore them.\n const newNodes = addedNodes.filter((node) => !isEmptyTextNode(node) && !current.includes(node));\n\n if (removedNodes.length) {\n this.nodes = current.filter((node) => !removedNodes.includes(node));\n\n removedNodes.forEach((node) => {\n this.teardownNode(node);\n });\n }\n\n if (newNodes && newNodes.length > 0) {\n if (this.multiple) {\n // Remove default node if exists\n if (this.defaultNode) {\n this.defaultNode.remove();\n }\n this.nodes = [...current, ...newNodes].filter((node) => node !== this.defaultNode);\n newNodes.forEach((node) => {\n this.initAddedNode(node);\n });\n } else {\n // Remove previous node if exists\n if (this.node) {\n this.node.remove();\n }\n this.node = newNodes[0];\n this.initAddedNode(this.node);\n }\n }\n });\n }\n}\n","import '@descope-ui/descope-list-item';\n\nimport { componentName, ListClass } from './ListClass';\n\ncustomElements.define(componentName, ListClass);\n\nexport { ListClass, componentName };\n","import { compose } from '@descope-ui/common/utils';\nimport { getComponentName, limitAbbreviation } from '@descope-ui/common/components-helpers';\nimport {\n createStyleMixin,\n draggableMixin,\n createProxy,\n componentNameValidationMixin,\n createDynamicDataMixin,\n} from '@descope-ui/common/components-mixins';\nimport { TextClass } from '@descope-ui/descope-text/class';\nimport { ListClass } from '@descope-ui/descope-list/class';\nimport { ListItemClass } from '@descope-ui/descope-list-item/class';\n\nexport const componentName = getComponentName('apps-list');\n\nconst itemRenderer = ({ name, icon, url }, _, ref) => `\n <a ${url ? `href=\"${url}\" title=\"${url}\"` : ''} target=\"_blank\">\n <descope-list-item>\n <div class=\"avatar-wrapper\">\n <descope-avatar\n ${icon ? `img=\"${icon}\"` : ''}\n ${name ? `display-name=\"${name}\" abbr=${limitAbbreviation(name)}` : ''}\n size=\"${ref.logoSize || ref.size}\"\n ></descope-avatar>\n </div>\n <descope-text\n variant=\"${ref.itemTextVariant}\"\n mode=\"primary\"\n >${name}</descope-text>\n </descope-list-item>\n </a>\n`;\n\nconst customMixin = (superclass) =>\n class AppsListMixinClass extends superclass {\n // size controls both item logo size and font size\n get size() {\n return this.getAttribute('size') || 'sm';\n }\n\n get itemTextVariant() {\n return this.getAttribute('item-text-variant') || 'body1';\n }\n\n get logoSize() {\n return this.getAttribute('logo-size');\n }\n };\n\nexport const AppsListClass = compose(\n createStyleMixin({\n mappings: {\n maxHeight: { selector: () => ':host' },\n minHeight: { selector: () => ':host' },\n hostDirection: { selector: () => ':host', property: 'direction' },\n itemsFontWeight: {\n selector: TextClass.componentName,\n property: TextClass.cssVarList.fontWeightOverride,\n },\n itemsFontSize: {\n selector: TextClass.componentName,\n property: TextClass.cssVarList.fontSizeOverride,\n },\n itemsTextAlign: {\n selector: TextClass.componentName,\n property: TextClass.cssVarList.textAlign,\n },\n itemBackgroundColor: {\n selector: ListItemClass.componentName,\n property: ListItemClass.cssVarList.backgroundColor,\n },\n backgroundColor: {\n selector: ListClass.componentName,\n property: ListClass.cssVarList.backgroundColorOverride,\n },\n itemBorderStyle: {\n selector: ListItemClass.componentName,\n property: ListItemClass.cssVarList.borderStyleOverride,\n },\n itemBorderColor: {\n selector: ListItemClass.componentName,\n property: ListItemClass.cssVarList.borderColorOverride,\n },\n itemBorderWidth: {\n selector: ListItemClass.componentName,\n property: ListItemClass.cssVarList.borderWidthOverride,\n },\n itemVerticalPadding: {\n selector: ListItemClass.componentName,\n property: ListItemClass.cssVarList.verticalPaddingOverride,\n },\n itemHorizontalPadding: {\n selector: ListItemClass.componentName,\n property: ListItemClass.cssVarList.horizontalPaddingOverride,\n },\n itemAlignment: [\n { selector: () => '.avatar-wrapper', property: 'text-align' },\n { selector: TextClass.componentName, property: TextClass.cssVarList.textAlign },\n ]\n },\n }),\n createDynamicDataMixin({ itemRenderer, rerenderAttrsList: ['size', 'item-text-variant', 'logo-size'] }),\n draggableMixin,\n componentNameValidationMixin,\n customMixin\n)(\n createProxy({\n slots: ['empty-state'],\n wrappedEleName: 'descope-list',\n excludeAttrsSync: ['tabindex', 'class', 'empty', 'style'],\n componentName,\n style: () => `\n :host {\n width: 100%;\n display: inline-flex;\n }\n\n descope-text::part(text-wrapper) {\n display: -webkit-box;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n overflow: hidden;\n }\n\n descope-list-item[variant=\"tile\"] .avatar-wrapper {\n width: 100%;\n }\n\n .avatar-wrapper {\n line-height: 0;\n }\n\n a {\n text-decoration: none;\n }\n\n descope-text {\n ${TextClass.cssVarList.hostDirection}: var(${AppsListClass.cssVarList.hostDirection});\n max-width: 100%;\n width: 100%;\n }\n `,\n })\n);\n","import '@descope-ui/descope-list';\nimport '@descope-ui/descope-avatar';\nimport '@descope-ui/descope-text';\nimport { componentName, AppsListClass } from './AppsListClass';\n\ncustomElements.define(componentName, AppsListClass);\n\nexport { AppsListClass, componentName };\n","/**\n * @license\n * Copyright (c) 2021 - 2023 Vaadin Ltd.\n * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/\n */\nimport { dedupingMixin } from '@polymer/polymer/lib/utils/mixin.js';\nimport { isKeyboardActive } from './focus-utils.js';\n\n/**\n * A mixin to handle `focused` and `focus-ring` attributes based on focus.\n *\n * @polymerMixin\n */\nexport const FocusMixin = dedupingMixin(\n (superclass) =>\n class FocusMixinClass extends superclass {\n /**\n * @protected\n * @return {boolean}\n */\n get _keyboardActive() {\n return isKeyboardActive();\n }\n\n /** @protected */\n ready() {\n this.addEventListener('focusin', (e) => {\n if (this._shouldSetFocus(e)) {\n this._setFocused(true);\n }\n });\n\n this.addEventListener('focusout', (e) => {\n if (this._shouldRemoveFocus(e)) {\n this._setFocused(false);\n }\n });\n\n // In super.ready() other 'focusin' and 'focusout' listeners might be\n // added, so we call it after our own ones to ensure they execute first.\n // Issue to watch out: when incorrect, <vaadin-combo-box> refocuses the\n // input field on iOS after \"Done\" is pressed.\n super.ready();\n }\n\n /** @protected */\n disconnectedCallback() {\n super.disconnectedCallback();\n\n // In non-Chrome browsers, blur does not fire on the element when it is disconnected.\n // reproducible in `<vaadin-date-picker>` when closing on `Cancel` or `Today` click.\n if (this.hasAttribute('focused')) {\n this._setFocused(false);\n }\n }\n\n /**\n * Override to change how focused and focus-ring attributes are set.\n *\n * @param {boolean} focused\n * @protected\n */\n _setFocused(focused) {\n this.toggleAttribute('focused', focused);\n\n // Focus-ring is true when the element was focused from the keyboard.\n // Focus Ring [A11ycasts]: https://youtu.be/ilj2P5-5CjI\n this.toggleAttribute('focus-ring', focused && this._keyboardActive);\n }\n\n /**\n * Override to define if the field receives focus based on the event.\n *\n * @param {FocusEvent} _event\n * @return {boolean}\n * @protected\n */\n _shouldSetFocus(_event) {\n return true;\n }\n\n /**\n * Override to define if the field loses focus based on the event.\n *\n * @param {FocusEvent} _event\n * @return {boolean}\n * @protected\n */\n _shouldRemoveFocus(_event) {\n return true;\n }\n },\n);\n","import {\n createStyleMixin,\n draggableMixin,\n componentNameValidationMixin,\n} from '@descope-ui/common/components-mixins';\nimport { createBaseClass } from '@descope-ui/common/base-classes';\nimport { compose } from '@descope-ui/common/utils';\nimport {\n forwardAttrs,\n getComponentName,\n injectStyle,\n observeAttributes,\n} from '@descope-ui/common/components-helpers';\n\nexport const componentName = getComponentName('avatar');\nclass RawAvatar extends createBaseClass({\n componentName,\n baseSelector: ':host > .wrapper',\n}) {\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n <div class=\"wrapper\">\n <vaadin-avatar></vaadin-avatar>\n <div class=\"editableBadge\">\n <vaadin-icon icon=\"vaadin:pencil\"></vaadin-icon>\n </div>\n </div>\n\t\t`;\n\n injectStyle(`\n :host {\n\t\t\t\t\tdisplay: inline-flex;\n\t\t\t\t}\n\n .editableBadge {\n border: 1px solid;\n border-radius: 100%;\n height: fit-content;\n width: 25%;\n height: 25%;\n display: flex;\n justify-content: center;\n align-items: center;\n padding: 5%;\n box-sizing: border-box;\n position: absolute;\n bottom: 0;\n inset-inline-end: 0;\n }\n\n vaadin-icon {\n color: currentcolor;\n }\n\n vaadin-avatar {\n width: 100%;\n height: 100%;\n margin: 0;\n border: none\n }\n\n .wrapper {\n display: inline-flex;\n position: relative;\n width: 100%;\n height: 100%;\n }\n `, this);\n\n this.avatarComponent = this.shadowRoot.querySelector('vaadin-avatar');\n\n forwardAttrs(this, this.avatarComponent, {\n includeAttrs: ['display-name', 'img', 'abbr'],\n mapAttrs: { 'display-name': 'name' },\n });\n\n const editableIcon = this.shadowRoot.querySelector('.editableBadge');\n\n observeAttributes(\n this,\n () => {\n editableIcon.style.display = this.isEditable ? '' : 'none';\n },\n { includeAttrs: ['editable'] },\n );\n }\n\n get isEditable() {\n return this.getAttribute('editable') === 'true';\n }\n}\n\nconst { host, editableBadge, avatar } = {\n host: { selector: () => ':host' },\n editableBadge: { selector: '> .editableBadge' },\n avatar: { selector: 'vaadin-avatar' },\n};\n\nexport const AvatarClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: [\n { ...host, property: 'width' },\n { ...host, property: 'min-width' },\n ],\n hostHeight: { ...host, property: 'height' },\n cursor: [avatar, host],\n hostDirection: { ...host, property: 'direction' },\n avatarTextColor: { ...avatar, property: 'color' },\n avatarBackgroundColor: { ...avatar, property: 'background-color' },\n editableIconColor: { ...editableBadge, property: 'color' },\n editableBorderColor: { ...editableBadge, property: 'border-color' },\n editableBackgroundColor: {\n ...editableBadge,\n property: 'background-color',\n },\n },\n }),\n draggableMixin,\n componentNameValidationMixin,\n)(RawAvatar);\n","import { componentName, AvatarClass } from './AvatarClass';\nimport '@vaadin/avatar';\nimport '@vaadin/icon';\nimport '@vaadin/icons';\n\ncustomElements.define(componentName, AvatarClass);\n\nexport { AvatarClass, componentName };\n","import { componentName, TextClass } from './TextClass';\n\ncustomElements.define(componentName, TextClass);\n\nexport { TextClass, componentName };\n","/**\n * @license\n * Copyright (c) 2023 Vaadin Ltd.\n * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/\n */\n\n/**\n * A helper for observing slot changes.\n */\nexport class SlotObserver {\n constructor(slot, callback) {\n /** @type HTMLSlotElement */\n this.slot = slot;\n\n /** @type Function */\n this.callback = callback;\n\n /** @type {Node[]} */\n this._storedNodes = [];\n\n this._connected = false;\n this._scheduled = false;\n\n this._boundSchedule = () => {\n this._schedule();\n };\n\n this.connect();\n this._schedule();\n }\n\n /**\n * Activates an observer. This method is automatically called when\n * a `SlotObserver` is created. It should only be called to re-activate\n * an observer that has been deactivated via the `disconnect` method.\n */\n connect() {\n this.slot.addEventListener('slotchange', this._boundSchedule);\n this._connected = true;\n }\n\n /**\n * Deactivates the observer. After calling this method the observer callback\n * will not be called when changes to slotted nodes occur. The `connect` method\n * may be subsequently called to reactivate the observer.\n */\n disconnect() {\n this.slot.removeEventListener('slotchange', this._boundSchedule);\n this._connected = false;\n }\n\n /** @private */\n _schedule() {\n if (!this._scheduled) {\n this._scheduled = true;\n\n queueMicrotask(() => {\n this.flush();\n });\n }\n }\n\n /**\n * Run the observer callback synchronously.\n */\n flush() {\n if (!this._connected) {\n return;\n }\n\n this._scheduled = false;\n\n this._processNodes();\n }\n\n /** @private */\n _processNodes() {\n const currentNodes = this.slot.assignedNodes({ flatten: true });\n\n let addedNodes = [];\n const removedNodes = [];\n const movedNodes = [];\n\n if (currentNodes.length) {\n addedNodes = currentNodes.filter((node) => !this._storedNodes.includes(node));\n }\n\n if (this._storedNodes.length) {\n this._storedNodes.forEach((node, index) => {\n const idx = currentNodes.indexOf(node);\n if (idx === -1) {\n removedNodes.push(node);\n } else if (idx !== index) {\n movedNodes.push(node);\n }\n });\n }\n\n if (addedNodes.length || removedNodes.length || movedNodes.length) {\n this.callback({ addedNodes, movedNodes, removedNodes });\n }\n\n this._storedNodes = currentNodes;\n }\n}\n","import {\n createStyleMixin,\n draggableMixin,\n componentNameValidationMixin,\n} from '@descope-ui/common/components-mixins';\nimport { compose } from '@descope-ui/common/utils';\nimport {\n getComponentName,\n injectStyle,\n observeChildren,\n} from '@descope-ui/common/components-helpers';\nimport { createBaseClass } from '@descope-ui/common/base-classes';\n\nexport const componentName = getComponentName('text');\n\nclass RawText extends createBaseClass({\n componentName,\n baseSelector: ':host > slot',\n}) {\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n <slot part=\"text-wrapper\"></slot>\n `;\n\n injectStyle(`\n :host {\n display: inline-block;\n line-height: 1em;\n }\n :host > slot {\n width: 100%;\n display: inline-block;\n }\n `, this);\n }\n\n get hideWhenEmpty() {\n return this.getAttribute('hide-when-empty') === 'true';\n }\n\n init() {\n super.init();\n\n observeChildren(this, () => {\n const hasChildren = !!this.childNodes.length;\n this.style.display = !hasChildren && this.hideWhenEmpty ? 'none' : '';\n });\n }\n}\n\nconst { host } = {\n host: { selector: () => ':host' }\n}\n\nexport const TextClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { ...host, property: 'width' },\n hostDirection: { ...host, property: 'direction' },\n fontSize: {},\n textColor: [\n { property: 'color' }\n ],\n textLineHeight: { property: 'line-height' },\n textLetterSpacing: { property: 'letter-spacing' },\n textShadow: {},\n textAlign: {},\n textTransform: {},\n fontFamily: {},\n fontStyle: {},\n fontWeight: {},\n borderWidth: {},\n borderStyle: {},\n borderColor: {},\n },\n }),\n draggableMixin,\n componentNameValidationMixin,\n)(RawText);\n","/**\n * @license\n * Copyright (c) 2022 - 2023 Vaadin Ltd.\n * This program is available under Apache License Version 2.0, available at https://vaadin.com/license/\n */\nimport { SlotController } from './slot-controller.js';\n\n/**\n * A controller that manages the slotted tooltip element.\n */\nexport class TooltipController extends SlotController {\n constructor(host) {\n // Do not provide slot factory to create tooltip lazily.\n super(host, 'tooltip');\n\n this.setTarget(host);\n }\n\n /**\n * Override to initialize the newly added custom tooltip.\n *\n * @param {Node} tooltipNode\n * @protected\n * @override\n */\n initCustomNode(tooltipNode) {\n tooltipNode.target = this.target;\n\n if (this.ariaTarget !== undefined) {\n tooltipNode.ariaTarget = this.ariaTarget;\n }\n\n if (this.context !== undefined) {\n tooltipNode.context = this.context;\n }\n\n if (this.manual !== undefined) {\n tooltipNode.manual = this.manual;\n }\n\n if (this.opened !== undefined) {\n tooltipNode.opened = this.opened;\n }\n\n if (this.position !== undefined) {\n tooltipNode._position = this.position;\n }\n\n if (this.shouldShow !== undefined) {\n tooltipNode.shouldShow = this.shouldShow;\n }\n\n this.__notifyChange();\n }\n\n /**\n * Override to notify the host when the tooltip is removed.\n *\n * @param {Node} tooltipNode\n * @protected\n * @override\n */\n teardownNode() {\n this.__notifyChange();\n }\n\n /**\n * Set an HTML element for linking with the tooltip overlay\n * via `aria-describedby` attribute used by screen readers.\n * @param {HTMLElement} ariaTarget\n */\n setAriaTarget(ariaTarget) {\n this.ariaTarget = ariaTarget;\n\n const tooltipNode = this.node;\n if (tooltipNode) {\n tooltipNode.ariaTarget = ariaTarget;\n }\n }\n\n /**\n * Set a context object to be used by generator.\n * @param {object} context\n */\n setContext(context) {\n this.context = context;\n\n const tooltipNode = this.node;\n if (tooltipNode) {\n tooltipNode.context = context;\n }\n }\n\n /**\n * Toggle manual state on the slotted tooltip.\n * @param {boolean} manual\n */\n setManual(manual) {\n this.manual = manual;\n\n const tooltipNode = this.node;\n if (tooltipNode) {\n tooltipNode.manual = manual;\n }\n }\n\n /**\n * Toggle opened state on the slotted tooltip.\n * @param {boolean} opened\n */\n setOpened(opened) {\n this.opened = opened;\n\n const tooltipNode = this.node;\n if (tooltipNode) {\n tooltipNode.opened = opened;\n }\n }\n\n /**\n * Set default position for the slotted tooltip.\n * This can be overridden by setting the position\n * using corresponding property or attribute.\n * @param {string} position\n */\n setPosition(position) {\n this.position = position;\n\n const tooltipNode = this.node;\n if (tooltipNode) {\n tooltipNode._position = position;\n }\n }\n\n /**\n * Set function used to detect whether to show\n * the tooltip based on a condition.\n * @param {Function} shouldShow\n */\n setShouldShow(shouldShow) {\n this.shouldShow = shouldShow;\n\n const tooltipNode = this.node;\n if (tooltipNode) {\n tooltipNode.shouldShow = shouldShow;\n }\n }\n\n /**\n * Set an HTML element to attach the tooltip to.\n * @param {HTMLElement} target\n */\n setTarget(target) {\n this.target = target;\n\n const tooltipNode = this.node;\n if (tooltipNode) {\n tooltipNode.target = target;\n }\n }\n\n /** @private */\n __notifyChange() {\n this.dispatchEvent(new CustomEvent('tooltip-changed', { detail: { node: this.node } }));\n }\n}\n","import {\n createStyleMixin,\n draggableMixin,\n componentNameValidationMixin,\n activeableMixin,\n} from '@descope-ui/common/components-mixins';\nimport { compose } from '@descope-ui/common/utils';\nimport { getComponentName } from '@descope-ui/common/components-helpers';\nimport { injectStyle } from '@descope-ui/common/components-helpers';\nimport { createBaseClass } from '@descope-ui/common/base-classes';\n\nexport const componentName = getComponentName('list-item');\n\nconst customMixin = (superclass) =>\n class ListItemMixinClass extends superclass {\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n <slot></slot>\n `;\n\n injectStyle(\n `\n slot {\n width: 100%;\n display: flex;\n overflow: hidden;\n box-sizing: border-box;\n }\n :host {\n display: block;\n }\n `,\n this,\n );\n }\n };\n\nexport const ListItemClass = compose(\n createStyleMixin({\n mappings: {\n verticalPadding: [\n { property: 'padding-top' },\n { property: 'padding-bottom' },\n ],\n horizontalPadding: [\n { property: 'padding-left' },\n { property: 'padding-right' },\n ],\n backgroundColor: {},\n borderColor: {},\n borderStyle: {},\n borderWidth: {},\n borderRadius: {},\n outline: {},\n cursor: {},\n gap: {},\n maxWidth: { selector: () => ':host' },\n alignItems: {},\n flexDirection: {},\n transition: {},\n },\n }),\n draggableMixin,\n componentNameValidationMixin,\n customMixin,\n activeableMixin,\n)(createBaseClass({ componentName, baseSelector: 'slot' }));\n"],"names":["getAncestorRootNodes","node","result","nodeType","Node","DOCUMENT_NODE","push","DOCUMENT_FRAGMENT_NODE","assignedSlot","parentNode","host","getFlattenedElements","elements","localName","assignedElements","children","forEach","elem","getClosestElement","selector","closest","getRootNode","deserializeAttributeValue","value","Set","split","serializeAttributeValue","values","join","addValueToAttribute","element","attr","getAttribute","add","setAttribute","removeValueFromAttribute","delete","size","removeAttribute","isEmptyTextNode","TEXT_NODE","textContent","trim","componentName","RawList","baseSelector","observedAttributes","constructor","super","this","attachShadow","mode","innerHTML","items","shadowRoot","querySelector","length","variant","item","listItem","listItemVariant","init","isReadOnly","attributeChangedCallback","name","oldValue","newValue","ListClass","mappings","hostWidth","property","maxHeight","minHeight","verticalPadding","horizontalPadding","hostDirection","fontFamily","gap","backgroundColor","borderRadius","borderColor","borderStyle","borderWidth","boxShadow","gridTemplateColumns","maxItemsWidth","minItemsWidth","itemsHorizontalAlign","emptyStateTextColor","emptyStateTextFontFamily","uniqueId","generateUniqueId","customElements","define","sizing","SlotController","EventTarget","generateId","slotName","tagName","config","initializer","multiple","observe","useUniqueId","slotInitializer","nodes","defaultId","hostConnected","initialized","initMultiple","initSingle","observeSlot","getSlotChild","initAddedNode","attachDefaultNode","initNode","getSlotChildren","defaultNode","document","createElement","Element","appendChild","Array","from","childNodes","filter","ELEMENT_NODE","slot","initCustomNode","_node","teardownNode","__slotObserver","addedNodes","removedNodes","current","newNodes","includes","remove","AppsListClass","itemsFontWeight","TextClass","cssVarList","fontWeightOverride","itemsFontSize","fontSizeOverride","itemsTextAlign","textAlign","itemBackgroundColor","ListItemClass","backgroundColorOverride","itemBorderStyle","borderStyleOverride","itemBorderColor","borderColorOverride","itemBorderWidth","borderWidthOverride","itemVerticalPadding","verticalPaddingOverride","itemHorizontalPadding","horizontalPaddingOverride","itemAlignment","itemRenderer","icon","url","_","ref","logoSize","itemTextVariant","rerenderAttrsList","superclass","slots","wrappedEleName","excludeAttrsSync","style","FocusMixin","_keyboardActive","ready","addEventListener","e","_shouldSetFocus","_setFocused","_shouldRemoveFocus","disconnectedCallback","hasAttribute","focused","toggleAttribute","_event","RawAvatar","avatarComponent","includeAttrs","mapAttrs","editableIcon","display","isEditable","editableBadge","avatar","AvatarClass","hostHeight","cursor","avatarTextColor","avatarBackgroundColor","editableIconColor","editableBorderColor","editableBackgroundColor","SlotObserver","callback","_storedNodes","_connected","_scheduled","_boundSchedule","_schedule","connect","disconnect","removeEventListener","queueMicrotask","flush","_processNodes","currentNodes","assignedNodes","flatten","movedNodes","index","idx","indexOf","RawText","hideWhenEmpty","hasChildren","fontSize","textColor","textLineHeight","textLetterSpacing","textShadow","textTransform","fontStyle","fontWeight","TooltipController","setTarget","tooltipNode","target","undefined","ariaTarget","context","manual","opened","position","_position","shouldShow","__notifyChange","setAriaTarget","setContext","setManual","setOpened","setPosition","setShouldShow","dispatchEvent","CustomEvent","detail","outline","maxWidth","alignItems","flexDirection","transition"],"sourceRoot":""}