@descope/web-components-ui 3.17.0 → 3.18.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/index.cjs.js +2807 -1010
- package/dist/cjs/index.cjs.js.map +1 -1
- package/dist/index.esm.js +3244 -1442
- package/dist/index.esm.js.map +1 -1
- package/dist/umd/1408.js +8 -8
- package/dist/umd/1408.js.map +1 -1
- package/dist/umd/5260.js +1 -1
- package/dist/umd/5260.js.map +1 -1
- package/dist/umd/6618.js +1 -1
- package/dist/umd/6618.js.map +1 -1
- package/dist/umd/67.js +2 -0
- package/dist/umd/67.js.map +1 -0
- package/dist/umd/7092.js +1 -1
- package/dist/umd/7092.js.map +1 -1
- package/dist/umd/7939.js +1 -1
- package/dist/umd/7939.js.map +1 -1
- package/dist/umd/8350.js +1 -1
- package/dist/umd/8350.js.map +1 -1
- package/dist/umd/9439.js +2 -0
- package/dist/umd/9439.js.map +1 -0
- package/dist/umd/DescopeDev.js +1 -1
- package/dist/umd/DescopeDev.js.map +1 -1
- package/dist/umd/descope-attachment.js +1 -1
- package/dist/umd/descope-attachment.js.map +1 -1
- package/dist/umd/descope-badge.js +1 -1
- package/dist/umd/descope-badge.js.map +1 -1
- package/dist/umd/descope-date-field-descope-calendar-index-js.js +10 -10
- package/dist/umd/descope-date-field-descope-calendar-index-js.js.map +1 -1
- package/dist/umd/descope-date-field-index-js.js +1 -1
- package/dist/umd/descope-date-field-index-js.js.map +1 -1
- package/dist/umd/descope-filter.js +2 -0
- package/dist/umd/descope-filter.js.map +1 -0
- package/dist/umd/descope-month-day-field.js +1 -1
- package/dist/umd/descope-month-day-field.js.map +1 -1
- package/dist/umd/descope-multi-line-mappings.js +4 -4
- package/dist/umd/descope-multi-line-mappings.js.LICENSE.txt +6 -0
- package/dist/umd/descope-multi-line-mappings.js.map +1 -1
- package/dist/umd/descope-multi-select-combo-box.js +2 -1
- package/dist/umd/descope-multi-select-combo-box.js.LICENSE.txt +5 -0
- package/dist/umd/descope-multi-select-combo-box.js.map +1 -1
- package/dist/umd/descope-multi-sso.js +1 -1
- package/dist/umd/descope-multi-sso.js.map +1 -1
- package/dist/umd/descope-new-password-index-js.js +1 -1
- package/dist/umd/descope-new-password-index-js.js.map +1 -1
- package/dist/umd/descope-passcode-index-js.js +1 -1
- package/dist/umd/descope-passcode-index-js.js.map +1 -1
- package/dist/umd/descope-security-questions-setup-index-js.js +1 -1
- package/dist/umd/descope-security-questions-setup-index-js.js.map +1 -1
- package/dist/umd/descope-security-questions-verify-index-js.js +1 -1
- package/dist/umd/descope-security-questions-verify-index-js.js.map +1 -1
- package/dist/umd/descope-text-field.js +1 -1
- package/dist/umd/descope-text-field.js.map +1 -1
- package/dist/umd/descope-trusted-devices.js +1 -1
- package/dist/umd/descope-trusted-devices.js.map +1 -1
- package/dist/umd/descope-user-attribute-index-js.js +1 -1
- package/dist/umd/descope-user-attribute-index-js.js.map +1 -1
- package/dist/umd/descope-user-auth-method-index-js.js +1 -1
- package/dist/umd/descope-user-auth-method-index-js.js.map +1 -1
- package/dist/umd/index.js +1 -1
- package/dist/umd/index.js.map +1 -1
- package/dist/umd/mapping-fields-descope-mappings-field-index-js.js +1 -1
- package/dist/umd/mapping-fields-descope-mappings-field-index-js.js.map +1 -1
- package/dist/umd/mapping-fields-descope-saml-group-mappings-index-js.js +1 -1
- package/dist/umd/mapping-fields-descope-saml-group-mappings-index-js.js.map +1 -1
- package/dist/umd/phone-fields-descope-phone-field-descope-phone-field-internal-index-js.js +1 -1
- package/dist/umd/phone-fields-descope-phone-field-descope-phone-field-internal-index-js.js.map +1 -1
- package/dist/umd/phone-fields-descope-phone-field-index-js.js +1 -1
- package/dist/umd/phone-fields-descope-phone-field-index-js.js.map +1 -1
- package/dist/umd/phone-fields-descope-phone-input-box-field-descope-phone-input-box-internal-index-js.js +1 -1
- package/dist/umd/phone-fields-descope-phone-input-box-field-descope-phone-input-box-internal-index-js.js.map +1 -1
- package/dist/umd/phone-fields-descope-phone-input-box-field-index-js.js +1 -1
- package/dist/umd/phone-fields-descope-phone-input-box-field-index-js.js.map +1 -1
- package/package.json +42 -41
- package/src/theme/components/index.js +2 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"descope-multi-select-combo-box.js","mappings":"+MAyBO,MAAMA,GAAgB,QAAiB,2BA0XxC,KACJC,EAAI,WACJC,EAAU,aACVC,EAAY,YACZC,EAAW,OACXC,EAAM,YACNC,EAAW,MACXC,EAAK,kBACLC,EAAiB,WACjBC,EAAU,aACVC,EAAY,KACZC,EAAI,UACJC,EAAS,wBACTC,EAAuB,yBACvBC,GACE,CACFb,KAAM,CAAEc,SAAU,IAAM,SACxBb,WAAY,CAAEa,SAAU,uBACxBZ,aAAc,CAAEY,SAAU,SAC1BX,YAAa,CAAEW,SAAU,6BACzBV,OAAQ,CAAEU,SAAU,yBACpBT,YAAa,CAAES,SAAU,wBACzBR,MAAO,CAAEQ,SAAU,iBACnBP,kBAAmB,CACjBO,SAAU,+CAEZN,WAAY,CAAEM,SAAU,uBACxBL,aAAc,CAAEK,SAAU,yBAC1BJ,KAAM,CAAEI,SAAU,sCAClBH,UAAW,CAAEG,SAAU,mDACvBF,wBAAyB,CACvBE,SAAU,+DAEZD,yBAA0B,CACxBC,SAAU,+DAIDC,GAA2B,SACtC,QAAiB,CACfC,SAAU,CACRC,UAAW,IAAKjB,EAAMkB,SAAU,SAChCC,cAAe,IAAKnB,EAAMkB,SAAU,aACpCE,SAAU,CAAC,CAAC,EAAGpB,GACfqB,aAAc,IAAKV,EAAWO,SAAU,aACxCI,WAAY,CACVhB,EACAH,EACAF,EACAO,EACAC,EACAE,GAEFY,cAAe,IAAKjB,EAAOY,SAAU,aACrCM,gBAAiB,IAAKlB,EAAOY,SAAU,eACvCO,qBAAsB,IAAKxB,EAAYiB,SAAU,eACjDQ,2BAA4B,IAAKvB,EAAae,SAAU,eACxDS,qBAAsB,IAAKnB,EAAYU,SAAU,eACjDU,uBAAwB,I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components/descope-multi-select-combo-box/src/component/MultiSelectComboBoxClass.js","webpack://@descope/web-components-ui/../components/descope-multi-select-combo-box/src/component/index.js"],"sourcesContent":["import { compose, compareArraysUnordered } from '@descope-ui/common/utils';\nimport {\n forwardAttrs,\n getComponentName,\n observeAttributes,\n observeChildren,\n} from '@descope-ui/common/components-helpers';\nimport {\n resetInputLabelPosition,\n resetInputCursor,\n resetInputPlaceholder,\n resetInputReadonlyStyle,\n useHostExternalPadding,\n inputFloatingLabelStyle,\n} from '@descope-ui/common/theme-helpers';\nimport {\n createStyleMixin,\n draggableMixin,\n createProxy,\n componentNameValidationMixin,\n portalMixin,\n proxyInputMixin,\n changeMixin,\n} from '@descope-ui/common/components-mixins';\n\nexport const componentName = getComponentName('multi-select-combo-box');\n\nconst multiSelectComboBoxMixin = (superclass) =>\n class MultiSelectComboBoxMixinClass extends superclass {\n static get observedAttributes() {\n return ['readonly'];\n }\n\n #renderItem = ({ displayName, value, label }) => {\n const ele = document.createElement('span');\n ele.setAttribute('data-name', label);\n ele.setAttribute('data-id', value);\n ele.textContent = displayName || label;\n\n return ele.outerHTML;\n };\n\n #data;\n\n #value = [];\n\n get defaultValues() {\n const defaultValuesAttr = this.getAttribute('default-values');\n if (defaultValuesAttr) {\n try {\n const defaultValues = JSON.parse(defaultValuesAttr);\n if (this.isValidDataType(defaultValues)) {\n return defaultValues;\n }\n } catch (e) {\n console.error(\n 'could not parse data string from attribute \"default-values\" -',\n e.message,\n );\n }\n }\n return [];\n }\n\n get renderItem() {\n return this.#renderItem;\n }\n\n set renderItem(renderFn) {\n this.#renderItem = renderFn;\n this.renderItems();\n }\n\n get data() {\n if (this.#data) return this.#data;\n\n const dataAttr = this.getAttribute('data');\n\n if (dataAttr) {\n try {\n const data = JSON.parse(dataAttr);\n if (this.isValidDataType(data)) {\n return data;\n }\n } catch (e) {\n console.error(\n 'could not parse data string from attribute \"data\" -',\n e.message,\n );\n }\n }\n\n return [];\n }\n\n set data(data) {\n if (this.isValidDataType(data)) {\n this.#data = data;\n this.renderItems();\n }\n }\n\n get allowCustomValues() {\n return this.getAttribute('allow-custom-value') === 'true';\n }\n\n get minItemsSelection() {\n return parseInt(this.getAttribute('min-items-selection'), 10) || 0;\n }\n\n get maxItemsSelection() {\n return parseInt(this.getAttribute('max-items-selection'), 10) || 0;\n }\n\n isValidDataType(data) {\n const isValid = Array.isArray(data);\n if (!isValid) {\n console.error(\n 'data and default-values must be an array, received:',\n data,\n );\n }\n\n return isValid;\n }\n\n getItemsTemplate() {\n return this.data?.reduce?.(\n (acc, item) => acc + (this.renderItem?.(item || {}) || ''),\n '',\n );\n }\n\n renderItems() {\n const template = this.getItemsTemplate();\n if (template) this.innerHTML = template;\n }\n\n updateSelectedItems() {\n const currentSelected =\n this.baseElement.selectedItems?.map((item) =>\n item.getAttribute('data-id'),\n ) || [];\n\n if (currentSelected.length > 0) {\n this.value = currentSelected;\n }\n\n if (this.value.length === 0) {\n this.setDefaultValues();\n }\n }\n\n customValueTransformFn(val) {\n return val;\n }\n\n setComboBoxDescriptor() {\n const valueDescriptor = Object.getOwnPropertyDescriptor(\n this.inputElement.constructor.prototype,\n 'value',\n );\n\n const comboBox = this;\n\n Object.defineProperties(this.inputElement, {\n value: {\n ...valueDescriptor,\n set(val) {\n const transformedValue = comboBox.customValueTransformFn(val) || '';\n\n if (transformedValue === this.value) {\n return;\n }\n\n valueDescriptor.set.call(this, transformedValue);\n },\n },\n });\n }\n\n #dedupItems(items) {\n return Array.from(\n new Map(\n items.map((item) => [item.getAttribute('data-id'), item]),\n ).values(),\n );\n }\n\n #onChildrenChange() {\n const items = Array.from(this.children);\n const dedupItems = this.#dedupItems(items);\n\n if (items.length) {\n this.removeAttribute('has-no-options');\n\n dedupItems.forEach((node) => {\n Object.defineProperty(node, 'data-name', {\n value: node.getAttribute('data-name'),\n configurable: true,\n writable: true,\n });\n Object.defineProperty(node, 'data-id', {\n value: node.getAttribute('data-id'),\n configurable: true,\n writable: true,\n });\n });\n\n this.baseElement.items = dedupItems;\n\n setTimeout(() => {\n this.updateSelectedItems();\n }, 0);\n } else {\n this.baseElement.items = [];\n this.setAttribute('has-no-options', '');\n }\n\n this.baseElement.renderer = (root, combo, model) => {\n root.innerHTML = model.item.outerHTML;\n };\n }\n\n #overrideOverlaySettings() {\n const overlay = this.baseElement.shadowRoot\n .querySelector('vaadin-multi-select-combo-box-internal')\n .shadowRoot.querySelector('vaadin-multi-select-combo-box-overlay');\n overlay._attachOverlay = () => {\n overlay.bringToFront();\n };\n overlay._detachOverlay = () => {};\n overlay._enterModalState = () => {};\n }\n\n #handleCustomValues() {\n if (this.allowCustomValues) {\n this.baseElement.addEventListener('custom-value-set', (e) => {\n const newItemHtml = this.#renderItem({\n label: e.detail,\n displayName: e.detail,\n value: e.detail,\n });\n this.innerHTML += newItemHtml;\n this.baseElement._lastFilter = '';\n setTimeout(() => {\n this.value = [...this.value, e.detail];\n }, 0);\n });\n }\n }\n\n setGetValidity() {\n this.getValidity = function () {\n if (this.pattern) {\n const patternRegex = new RegExp(this.pattern);\n if (this.value.some((val) => !patternRegex.test(val)))\n return {\n patternMismatch: true,\n };\n }\n\n if (this.isRequired && !this.value.length) {\n return {\n valueMissing: true,\n };\n }\n if (\n this.isRequired &&\n this.minItemsSelection &&\n this.value.length < this.minItemsSelection\n ) {\n return {\n rangeUnderflow: true,\n };\n }\n if (\n this.maxItemsSelection &&\n this.value.length > this.maxItemsSelection\n ) {\n return {\n rangeOverflow: true,\n };\n }\n return {};\n };\n\n const that = this;\n\n this.baseElement.checkValidity = () => that.validity.valid;\n }\n\n init() {\n super.init?.();\n\n this.setGetValidity();\n\n this.#handleCustomValues();\n\n this.renderItems();\n\n observeAttributes(this, this.renderItems.bind(this), {\n includeAttrs: ['data'],\n });\n\n observeChildren(this, this.#onChildrenChange.bind(this));\n\n forwardAttrs(this, this.baseElement, { includeAttrs: ['placeholder'] });\n\n setTimeout(() => {\n this.setComboBoxDescriptor();\n this.#overrideOverlaySettings();\n });\n\n this.setDefaultValues();\n\n this.baseElement.addEventListener('selected-items-changed', () => {\n this.#updateInternalValue();\n this.dispatchEvent(new CustomEvent('input', { bubbles: true }));\n });\n }\n\n setDefaultValues() {\n const initialDefaultValues = this.defaultValues;\n if (initialDefaultValues.length > 0) {\n this.value = this.defaultValues;\n }\n }\n\n #updateInternalValue() {\n this.#value =\n this.baseElement.selectedItems?.map((elem) =>\n elem.getAttribute('data-id'),\n ) || [];\n }\n\n set value(vals) {\n if (vals && vals.length > 0) {\n const selectedChildren = this.baseElement.items?.filter((item) =>\n vals.includes(item['data-id']),\n );\n\n if (this.allowCustomValues) {\n const existingValues =\n selectedChildren?.map((child) => child.getAttribute('data-id')) ||\n [];\n const missingValues = vals.filter(\n (val) => !existingValues.includes(val),\n );\n\n if (missingValues.length) {\n const newItemsHtml = missingValues.reduce((acc, val) => {\n const newItemHtml = this.#renderItem({\n label: val,\n displayName: val,\n value: val,\n });\n return acc + newItemHtml;\n }, '');\n this.innerHTML += newItemsHtml;\n\n setTimeout(() => {\n this.value = vals;\n }, 0);\n return;\n }\n }\n\n const newSelectedValues =\n selectedChildren?.map((child) => child.getAttribute('data-id')) || [];\n if (!compareArraysUnordered(this.#value, newSelectedValues)) {\n this.baseElement.selectedItems = selectedChildren;\n }\n } else {\n this.baseElement.selectedItems = [];\n }\n }\n\n get value() {\n return this.#value;\n }\n\n attributeChangedCallback(attrName, oldValue, newValue) {\n super.attributeChangedCallback?.(attrName, oldValue, newValue);\n\n if (attrName === 'readonly') {\n this.onReadOnlyChange(newValue !== null && newValue === 'true');\n }\n }\n\n onReadOnlyChange(val) {\n if (val) {\n this.baseElement?.shadowRoot\n ?.querySelector('vaadin-multi-select-combo-box-internal')\n ?.setAttribute('inert', val);\n } else {\n this.baseElement?.shadowRoot\n ?.querySelector('vaadin-multi-select-combo-box-internal')\n ?.removeAttribute('inert');\n }\n }\n };\n\nconst {\n host,\n inputField,\n inputElement,\n placeholder,\n toggle,\n clearButton,\n label,\n requiredIndicator,\n helperText,\n errorMessage,\n chip,\n chipLabel,\n overflowChipFirstBorder,\n overflowChipSecondBorder,\n} = {\n host: { selector: () => ':host' },\n inputField: { selector: '::part(input-field)' },\n inputElement: { selector: 'input' },\n placeholder: { selector: '> input:placeholder-shown' },\n toggle: { selector: '::part(toggle-button)' },\n clearButton: { selector: '::part(clear-button)' },\n label: { selector: '::part(label)' },\n requiredIndicator: {\n selector: '[required]::part(required-indicator)::after',\n },\n helperText: { selector: '::part(helper-text)' },\n errorMessage: { selector: '::part(error-message)' },\n chip: { selector: 'vaadin-multi-select-combo-box-chip' },\n chipLabel: { selector: 'vaadin-multi-select-combo-box-chip::part(label)' },\n overflowChipFirstBorder: {\n selector: \"vaadin-multi-select-combo-box-chip[slot='overflow']::before\",\n },\n overflowChipSecondBorder: {\n selector: \"vaadin-multi-select-combo-box-chip[slot='overflow']::after\",\n },\n};\n\nexport const MultiSelectComboBoxClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { ...host, property: 'width' },\n hostDirection: { ...host, property: 'direction' },\n fontSize: [{}, host],\n chipFontSize: { ...chipLabel, property: 'font-size' },\n fontFamily: [\n label,\n placeholder,\n inputField,\n helperText,\n errorMessage,\n chipLabel,\n ],\n labelFontSize: { ...label, property: 'font-size' },\n labelFontWeight: { ...label, property: 'font-weight' },\n inputValueFontWeight: { ...inputField, property: 'font-weight' },\n inputPlaceholderFontWeight: { ...placeholder, property: 'font-weight' },\n helperTextFontWeight: { ...helperText, property: 'font-weight' },\n errorMessageFontWeight: { ...errorMessage, property: 'font-weight' },\n labelTextColor: [\n { ...label, property: 'color' },\n { ...requiredIndicator, property: 'color' },\n ],\n errorMessageTextColor: { ...errorMessage, property: 'color' },\n errorMessageIcon: { ...errorMessage, property: 'background-image' },\n errorMessageIconSize: { ...errorMessage, property: 'background-size' },\n errorMessageIconPadding: {\n ...errorMessage,\n property: 'padding-inline-start',\n },\n errorMessageIconRepeat: {\n ...errorMessage,\n property: 'background-repeat',\n },\n errorMessageIconPosition: {\n ...errorMessage,\n property: 'background-position',\n },\n errorMessageFontSize: { ...errorMessage, property: 'font-size' },\n inputHeight: { ...inputField, property: 'min-height' },\n inputBackgroundColor: { ...inputField, property: 'background-color' },\n inputBorderColor: { ...inputField, property: 'border-color' },\n inputBorderWidth: { ...inputField, property: 'border-width' },\n inputBorderStyle: { ...inputField, property: 'border-style' },\n inputBorderRadius: { ...inputField, property: 'border-radius' },\n labelRequiredIndicator: { ...requiredIndicator, property: 'content' },\n inputValueTextColor: { ...inputField, property: 'color' },\n inputPlaceholderTextColor: { ...placeholder, property: 'color' },\n inputDropdownButtonCursor: [\n { ...toggle, property: 'cursor' },\n { ...clearButton, property: 'cursor' },\n ],\n inputDropdownButtonColor: [\n { ...toggle, property: 'color' },\n { ...clearButton, property: 'color' },\n ],\n inputDropdownButtonSize: [\n { ...toggle, property: 'font-size' },\n { ...clearButton, property: 'font-size' },\n ],\n inputDropdownButtonOffset: [\n { ...toggle, property: 'margin-right' },\n { ...toggle, property: 'margin-left' },\n ],\n inputOutlineColor: { ...inputField, property: 'outline-color' },\n inputOutlineWidth: { ...inputField, property: 'outline-width' },\n inputOutlineStyle: { ...inputField, property: 'outline-style' },\n inputOutlineOffset: { ...inputField, property: 'outline-offset' },\n inputHorizontalPadding: [\n { ...inputElement, property: 'padding-left' },\n { ...inputElement, property: 'padding-right' },\n { ...inputField, property: 'padding-inline-start' },\n ],\n inputVerticalPadding: [\n { ...inputField, property: 'padding-top' },\n { ...inputField, property: 'padding-bottom' },\n ],\n chipTextColor: { ...chipLabel, property: 'color' },\n chipBackgroundColor: [\n { ...chip, property: 'background-color' },\n { ...overflowChipFirstBorder, property: 'border-color' },\n { ...overflowChipSecondBorder, property: 'border-color' },\n ],\n\n labelPosition: { ...label, property: 'position' },\n labelTopPosition: { ...label, property: 'top' },\n labelLeftPosition: { ...label, property: 'left' },\n labelHorizontalPosition: [\n { ...label, property: 'left' },\n { ...label, property: 'right' },\n ],\n inputTransformY: { ...label, property: 'transform' },\n inputTransition: { ...label, property: 'transition' },\n marginInlineStart: { ...label, property: 'margin-inline-start' },\n placeholderOpacity: { ...placeholder, property: 'opacity' },\n inputVerticalAlignment: { ...inputField, property: 'align-items' },\n\n overlayBackground: {\n property: () =>\n MultiSelectComboBoxClass.cssVarList.overlay.backgroundColor,\n },\n overlayTextColor: {\n property: () => MultiSelectComboBoxClass.cssVarList.overlay.textColor,\n },\n overlayBorder: {\n property: () => MultiSelectComboBoxClass.cssVarList.overlay.border,\n },\n overlayFontSize: {\n property: () => MultiSelectComboBoxClass.cssVarList.overlay.fontSize,\n },\n overlayFontFamily: {\n property: () => MultiSelectComboBoxClass.cssVarList.overlay.fontFamily,\n },\n overlayCursor: {\n property: () => MultiSelectComboBoxClass.cssVarList.overlay.cursor,\n },\n overlayItemBoxShadow: {\n property: () =>\n MultiSelectComboBoxClass.cssVarList.overlay.itemBoxShadow,\n },\n overlayItemPaddingInlineStart: {\n property: () =>\n MultiSelectComboBoxClass.cssVarList.overlay.itemPaddingInlineStart,\n },\n overlayItemPaddingInlineEnd: {\n property: () =>\n MultiSelectComboBoxClass.cssVarList.overlay.itemPaddingInlineEnd,\n },\n },\n }),\n draggableMixin,\n portalMixin({\n name: 'overlay',\n selector: 'vaadin-multi-select-combo-box-internal',\n mappings: {\n backgroundColor: { selector: 'vaadin-multi-select-combo-box-scroller' },\n minHeight: { selector: 'vaadin-multi-select-combo-box-overlay' },\n margin: { selector: 'vaadin-multi-select-combo-box-overlay' },\n cursor: { selector: 'vaadin-multi-select-combo-box-item' },\n fontFamily: { selector: 'vaadin-multi-select-combo-box-item' },\n textColor: {\n selector: 'vaadin-multi-select-combo-box-item',\n property: 'color',\n },\n fontSize: { selector: 'vaadin-multi-select-combo-box-item' },\n itemBoxShadow: {\n selector: 'vaadin-multi-select-combo-box-item',\n property: 'box-shadow',\n },\n itemPaddingInlineStart: {\n selector: 'vaadin-multi-select-combo-box-item',\n property: 'padding-inline-start',\n },\n itemPaddingInlineEnd: {\n selector: 'vaadin-multi-select-combo-box-item',\n property: 'padding-inline-end',\n },\n },\n forward: {\n include: false,\n attributes: ['size'],\n },\n }),\n proxyInputMixin({\n proxyProps: ['selectionStart'],\n inputEvent: 'selected-items-changed',\n }),\n changeMixin,\n componentNameValidationMixin,\n multiSelectComboBoxMixin,\n)(\n createProxy({\n slots: ['', 'prefix'],\n wrappedEleName: 'vaadin-multi-select-combo-box',\n style: () => `\n\t\t:host {\n\t\t\tdisplay: inline-flex;\n\t\t\tbox-sizing: border-box;\n\t\t\t-webkit-mask-image: none;\n\t\t}\n\t\t${useHostExternalPadding(MultiSelectComboBoxClass.cssVarList)}\n\t\t${resetInputReadonlyStyle('vaadin-multi-select-combo-box')}\n\t\t${resetInputPlaceholder('vaadin-multi-select-combo-box')}\n\t\t${resetInputCursor('vaadin-multi-select-combo-box')}\n\n\t\tvaadin-multi-select-combo-box {\n\t\t\tpadding: 0;\n\t\t\twidth: 100%;\n\t\t}\n\t\tvaadin-multi-select-combo-box::before {\n\t\t\theight: initial;\n\t\t}\n\t\tvaadin-multi-select-combo-box [slot=\"input\"] {\n\t\t\t-webkit-mask-image: none;\n\t\t\tmin-height: 0;\n align-self: center;\n\t\t\tbox-sizing: border-box;\n\t\t}\n\t\tvaadin-multi-select-combo-box[readonly] [slot=\"input\"] {\n flex-grow: 1;\n flex-basis: 4em;\n\t\t}\n\n\t\t::part(input-field) {\n padding: 0;\n\t\t\tbox-shadow: none;\n\t\t}\n ${resetInputLabelPosition('vaadin-multi-select-combo-box')}\n :host([has-label]) vaadin-multi-select-combo-box-chip::part(label) {\n display: block;\n }\n\n vaadin-multi-select-combo-box vaadin-multi-select-combo-box-chip[slot='overflow']::before,\n vaadin-multi-select-combo-box vaadin-multi-select-combo-box-chip[slot='overflow']::after {\n left: -4px;\n right: -4px;\n border-left-width: 0;\n border-inline-start-style: solid;\n border-inline-start-width: 2px;\n }\n vaadin-multi-select-combo-box vaadin-multi-select-combo-box-chip[slot='overflow']::after {\n left: -8px;\n right: -8px;\n }\n\n :host([has-no-options][allow-custom-value='true']) ::part(toggle-button) {\n display: none;\n }\n\n ${inputFloatingLabelStyle()}\n\n vaadin-multi-select-combo-box::part(toggle-button),\n vaadin-multi-select-combo-box::part(clear-button) {\n align-self: center;\n }\n\n vaadin-multi-select-combo-box[label-type=\"floating\"]:not([focused])[readonly] > input:placeholder-shown {\n opacity: 0;\n }\n vaadin-multi-select-combo-box[label-type=\"floating\"]:not([focused])[disabled] > input:placeholder-shown {\n opacity: 0;\n }\n\n\t\t`,\n excludeAttrsSync: ['tabindex', 'size', 'data', 'placeholder', 'style'],\n componentName,\n includeForwardProps: ['items', 'renderer', 'selectedItems'],\n }),\n);\n","import '@vaadin/multi-select-combo-box';\nimport {\n componentName,\n MultiSelectComboBoxClass,\n} from './MultiSelectComboBoxClass';\n\ncustomElements.define(componentName, MultiSelectComboBoxClass);\n\nexport { MultiSelectComboBoxClass, componentName };\n"],"names":["componentName","host","inputField","inputElement","placeholder","toggle","clearButton","label","requiredIndicator","helperText","errorMessage","chip","chipLabel","overflowChipFirstBorder","overflowChipSecondBorder","selector","MultiSelectComboBoxClass","mappings","hostWidth","property","hostDirection","fontSize","chipFontSize","fontFamily","labelFontSize","labelFontWeight","inputValueFontWeight","inputPlaceholderFontWeight","helperTextFontWeight","errorMessageFontWeight","labelTextColor","errorMessageTextColor","errorMessageIcon","errorMessageIconSize","errorMessageIconPadding","errorMessageIconRepeat","errorMessageIconPosition","errorMessageFontSize","inputHeight","inputBackgroundColor","inputBorderColor","inputBorderWidth","inputBorderStyle","inputBorderRadius","labelRequiredIndicator","inputValueTextColor","inputPlaceholderTextColor","inputDropdownButtonCursor","inputDropdownButtonColor","inputDropdownButtonSize","inputDropdownButtonOffset","inputOutlineColor","inputOutlineWidth","inputOutlineStyle","inputOutlineOffset","inputHorizontalPadding","inputVerticalPadding","chipTextColor","chipBackgroundColor","labelPosition","labelTopPosition","labelLeftPosition","labelHorizontalPosition","inputTransformY","inputTransition","marginInlineStart","placeholderOpacity","inputVerticalAlignment","overlayBackground","cssVarList","overlay","backgroundColor","overlayTextColor","textColor","overlayBorder","border","overlayFontSize","overlayFontFamily","overlayCursor","cursor","overlayItemBoxShadow","itemBoxShadow","overlayItemPaddingInlineStart","itemPaddingInlineStart","overlayItemPaddingInlineEnd","itemPaddingInlineEnd","name","minHeight","margin","forward","include","attributes","proxyProps","inputEvent","superclass","observedAttributes","displayName","value","ele","document","createElement","setAttribute","textContent","outerHTML","defaultValues","defaultValuesAttr","this","getAttribute","JSON","parse","isValidDataType","e","console","error","message","renderItem","renderFn","renderItems","data","dataAttr","allowCustomValues","minItemsSelection","parseInt","maxItemsSelection","isValid","Array","isArray","getItemsTemplate","reduce","acc","item","template","innerHTML","updateSelectedItems","currentSelected","baseElement","selectedItems","map","length","setDefaultValues","customValueTransformFn","val","setComboBoxDescriptor","valueDescriptor","Object","getOwnPropertyDescriptor","constructor","prototype","comboBox","defineProperties","set","transformedValue","call","items","from","Map","values","children","dedupItems","removeAttribute","forEach","node","defineProperty","configurable","writable","setTimeout","renderer","root","combo","model","shadowRoot","querySelector","_attachOverlay","bringToFront","_detachOverlay","_enterModalState","addEventListener","newItemHtml","detail","_lastFilter","setGetValidity","getValidity","pattern","patternRegex","RegExp","some","test","patternMismatch","isRequired","valueMissing","rangeUnderflow","rangeOverflow","that","checkValidity","validity","valid","init","super","bind","includeAttrs","dispatchEvent","CustomEvent","bubbles","elem","vals","selectedChildren","filter","includes","existingValues","child","missingValues","newItemsHtml","newSelectedValues","attributeChangedCallback","attrName","oldValue","newValue","onReadOnlyChange","slots","wrappedEleName","style","excludeAttrsSync","includeForwardProps","customElements","define"],"sourceRoot":""}
|
|
1
|
+
{"version":3,"file":"descope-multi-select-combo-box.js","mappings":";sKAOA,MAAMA,EAAW,IAAIC,eAAgBC,IACnCC,WAAW,KACTD,EAAQE,QAASC,IAEXA,EAAMC,OAAOC,WACfF,EAAMC,OAAOC,WAAWH,QAASI,IAC/BA,EAAUC,UAAUJ,EAAMK,eAG5BL,EAAMC,OAAOG,UAAUJ,EAAMK,mBAWxBC,GAAc,OACxBC,GACC,cAA+BA,EAO7B,kBAAIC,GACF,OAAO,CACT,CAGA,iBAAAC,GAIE,GAHAC,MAAMD,oBACNd,EAASgB,QAAQC,MAEbA,KAAKJ,eAAgB,CACvB,MAAMK,EAASD,KAAKE,sBAAsBC,WAAaH,KAAKE,WAAWE,KAAOJ,KAAKE,WAE9ED,EAAOX,aACVW,EAAOX,WAAa,IAAIe,IACxBtB,EAASgB,QAAQE,IAGnBA,EAAOX,WAAWgB,IAAIN,MACtBA,KAAKO,SAAWN,CAClB,CACF,CAGA,oBAAAO,GACEV,MAAMU,uBACNzB,EAAS0B,UAAUT,MAEnB,MAAMC,EAASD,KAAKO,SACpB,GAAIP,KAAKJ,gBAAkBK,EAAQ,CACjC,MAAMX,EAAaW,EAAOX,WAEtBA,IACFA,EAAWoB,OAAOV,MAEM,IAApBV,EAAWqB,MACb5B,EAAS0B,UAAUR,IAIvBD,KAAKO,SAAW,IAClB,CACF,CAQA,SAAAf,CAAUoB,GAEV,G","sources":["webpack://@descope/web-components-ui/../../../node_modules/@vaadin/component-base/src/resize-mixin.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 */\nimport { dedupingMixin } from '@polymer/polymer/lib/utils/mixin.js';\n\nconst observer = new ResizeObserver((entries) => {\n setTimeout(() => {\n entries.forEach((entry) => {\n // Notify child resizables, if any\n if (entry.target.resizables) {\n entry.target.resizables.forEach((resizable) => {\n resizable._onResize(entry.contentRect);\n });\n } else {\n entry.target._onResize(entry.contentRect);\n }\n });\n });\n});\n\n/**\n * A mixin that uses a ResizeObserver to listen to host size changes.\n *\n * @polymerMixin\n */\nexport const ResizeMixin = dedupingMixin(\n (superclass) =>\n class ResizeMixinClass extends superclass {\n /**\n * When true, the parent element resize will be also observed.\n * Override this getter and return `true` to enable this.\n *\n * @protected\n */\n get _observeParent() {\n return false;\n }\n\n /** @protected */\n connectedCallback() {\n super.connectedCallback();\n observer.observe(this);\n\n if (this._observeParent) {\n const parent = this.parentNode instanceof ShadowRoot ? this.parentNode.host : this.parentNode;\n\n if (!parent.resizables) {\n parent.resizables = new Set();\n observer.observe(parent);\n }\n\n parent.resizables.add(this);\n this.__parent = parent;\n }\n }\n\n /** @protected */\n disconnectedCallback() {\n super.disconnectedCallback();\n observer.unobserve(this);\n\n const parent = this.__parent;\n if (this._observeParent && parent) {\n const resizables = parent.resizables;\n\n if (resizables) {\n resizables.delete(this);\n\n if (resizables.size === 0) {\n observer.unobserve(parent);\n }\n }\n\n this.__parent = null;\n }\n }\n\n /**\n * A handler invoked on host resize. By default, it does nothing.\n * Override the method to implement your own behavior.\n *\n * @protected\n */\n _onResize(_contentRect) {\n // To be implemented.\n }\n },\n);\n"],"names":["observer","ResizeObserver","entries","setTimeout","forEach","entry","target","resizables","resizable","_onResize","contentRect","ResizeMixin","superclass","_observeParent","connectedCallback","super","observe","this","parent","parentNode","ShadowRoot","host","Set","add","__parent","disconnectedCallback","unobserve","delete","size","_contentRect"],"sourceRoot":""}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*! For license information please see descope-multi-sso.js.LICENSE.txt */
|
|
2
|
-
"use strict";(self.webpackChunk_descope_web_components_ui=self.webpackChunk_descope_web_components_ui||[]).push([[461,1202,2294,4188,4551,5087,6724,9536],{77888(t,e,o){o.d(e,{T:()=>s,e:()=>d});var n=o(88961),r=o(72270),i=o(25964),a=o(63200);const s=(0,i.xE)("badge");class l extends((0,r.qu)({componentName:s,baseSelector:":host > div"})){static get observedAttributes(){return["data-attachment-size","shrink-to-indicator-threshold"]}constructor(){super(),this.attachShadow({mode:"open"}).innerHTML="\n\t\t<div>\n <slot></slot>\n\t\t</div>\n\t\t",(0,i.fz)("\n :host {\n display: inline-flex;\n }\n :host > div {\n position: relative;\n width: 100%;\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n }\n ",this)}get shrinkToIndicatorThreshold(){return this.getAttribute("shrink-to-indicator-threshold")||65}#t(t){this.toggleAttribute("shrink-to-indicator",parseFloat(t)<this.shrinkToIndicatorThreshold)}attributeChangedCallback(t,e,o){super.attributeChangedCallback?.(t,e,o),"data-attachment-size"===t&&e!==o&&this.#t(o)}}const d=(0,a.Zz)((0,n.RF)({mappings:{hostWidth:[{selector:()=>":host",property:"width"}],hostHeight:[{selector:()=>":host",property:"height"}],hostDirection:{property:"direction"},fontFamily:{},fontSize:{},fontWeight:{},textTransform:{},verticalPadding:[{property:"padding-top"},{property:"padding-bottom"}],horizontalPadding:[{property:"padding-left"},{property:"padding-right"}],borderWidth:{},borderStyle:{},borderColor:{},borderRadius:{},backgroundColor:{},textColor:{property:"color"},textAlign:{},boxShadow:{},textIndent:{}}}),n.VO,n.tQ)(l)},11065(t,e,o){o.r(e),o.d(e,{BadgeClass:()=>n.e,componentName:()=>n.T});var n=o(77888);customElements.define(n.T,n.e)},19624(t,e,o){o.d(e,{J:()=>u,T:()=>l});var n=o(63200),r=o(25964),i=o(88961),a=o(98538),s=o(10767);const l=(0,r.xE)("button"),{host:d,label:c,slottedIcon:p}={host:{selector:()=>":host"},label:{selector:"::part(label)"},slottedIcon:{selector:()=>"::slotted(descope-icon)"}};let h;const u=(0,n.Zz)((0,i.DM)({triggers:[{attr:"full-width",value:"true"}]}),(0,i.RF)({mappings:{hostWidth:{property:"width"},hostMaxWidth:{...d,property:"max-width"},hostHeight:{property:"height"},hostDirection:{...d,property:"direction"},fontSize:{},fontFamily:{},fontWeight:{},cursor:{},backgroundColor:{},outlineOffset:{},outlineColor:{},outlineStyle:{},outlineWidth:{},borderRadius:{},borderColor:{},borderStyle:{},borderWidth:{},verticalPadding:[{property:"padding-top"},{property:"padding-bottom"}],horizontalPadding:[{property:"padding-right",fallback:"0.875em"},{property:"padding-left",fallback:"0.875em"}],labelTextColor:{property:"color"},iconColor:{selector:()=>"::slotted(*)",property:a.S.cssVarList.fill},labelTextDecoration:{...c,property:"text-decoration"},labelSpacing:{...c,property:"gap"},textAlign:{...c,property:"justify-content",fallback:"center"},iconSize:[{...p,property:"width"},{...p,property:"height"}]}}),s.G,i.VO,i.tQ)((0,i.tz)({slots:["","prefix","label","suffix"],wrappedEleName:"vaadin-button",style:()=>`\n\t\t\t\n\t:host {\n\t\tdisplay: inline-block;\n\t\tbox-sizing: border-box;\n\t}\n\tvaadin-button::before,\n\tvaadin-button::after {\n\t\topacity: 0;\n\t}\n\tvaadin-button {\n\t\tmargin: 0;\n\t\tmin-width: 0;\n\t\twidth: 100%;\n\t\theight: auto;\n\t\tbox-shadow: none;\n\t}\n\tvaadin-button::part(label) {\n\t\tpadding: 0;\n width: 100%;\n\t}\n\tvaadin-button::part(prefix) {\n\t\tmargin-left: 0;\n\t\tmargin-right: 0;\n\t}\n\n\t\t\t\n\tvaadin-button::part(prefix),\n\tvaadin-button::part(label) {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t}\n\n\t\t\t${h}\n\t\t\tvaadin-button::part(label) { pointer-events: none; }\n\t\t\t:host {\n\t\t\t\tpadding: calc(var(${u.cssVarList.outlineWidth}) + var(${u.cssVarList.outlineOffset}));\n\t\t\t}\n :host([full-width="true"]) {\n width: var(${u.cssVarList.hostWidth});\n }\n\t\t\tvaadin-button {\n\t\t\t\theight: calc(var(${u.cssVarList.hostHeight}) - var(${u.cssVarList.outlineWidth}) - var(${u.cssVarList.outlineOffset}));\n\t\t\t}\n\t\t\t[square="true"]:not([full-width="true"]) {\n\t\t\t\twidth: calc(var(${u.cssVarList.hostWidth}) - var(${u.cssVarList.outlineWidth}) - var(${u.cssVarList.outlineOffset}));\n padding: 0;\n\t\t\t}\n\t\t`,excludeAttrsSync:["tabindex","class","style"],componentName:l})),{color:m,fontSize:b}=u.cssVarList;h=`\n\t@keyframes spin {\n\t\t0% { -webkit-transform: rotate(0deg); }\n\t\t100% { -webkit-transform: rotate(360deg); }\n\t}\n\t:host([loading="true"]) ::before {\n\t\tanimation: spin 2s linear infinite;\n\t\tposition: absolute;\n\t\tcontent: '';\n\t\tz-index: 1;\n\t\tbox-sizing: border-box;\n\t\tborder-radius: 50%;\n\t\tborder-bottom-color: transparent;\n\t\tborder-left-color: transparent;\n\t\tborder-style: solid;\n\t\tcolor: var(${m});\n\t\ttop: calc(50% - (var(${b}) / 2));\n\t\tleft: calc(50% - (var(${b}) / 2));\n\t\tborder-width: calc(var(${b}) / 10);\n\t\twidth: var(${b});\n\t\theight: var(${b});\n\t}\n\t:host([disabled="true"]),\n\t:host([loading="true"]) {\n\t\tpointer-events: none;\n\t}\n\t:host([loading="true"]) ::part(prefix),\n\t:host([loading="true"]) ::part(label) {\n\t\tvisibility: hidden;\n\t}\n`},10767(t,e,o){o.d(e,{G:()=>n});const n=t=>class extends t{get isLoading(){return"true"===this.getAttribute("loading")}click(){this.isLoading||super.click()}}},30576(t,e,o){o.r(e),o.d(e,{ButtonClass:()=>n.J,componentName:()=>n.T});var n=o(19624);o(83799),customElements.define(n.T,n.J)},98538(t,e,o){o.d(e,{S:()=>l,T:()=>s});var n=o(88961),r=o(25964),i=o(8512),a=o(63200);const s=(0,r.xE)("icon"),l=(0,a.Zz)((0,n.RF)({mappings:{fill:[{},{property:i.q.cssVarList.fill}],height:{selector:()=>":host"},width:{selector:()=>":host"}}}),n.VO,n.tQ)((0,n.tz)({slots:[],wrappedEleName:"descope-image",style:()=>"\n :host {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n max-height: 100%;\n }\n ",excludeAttrsSync:["tabindex","class","style","st-height","st-width"],componentName:s}))},56737(t,e,o){o.r(e),o.d(e,{IconClass:()=>n.S,componentName:()=>n.T}),o(53455);var n=o(98538);customElements.define(n.T,n.S)},8512(t,e,o){o.d(e,{T:()=>l,q:()=>p});var n=o(88961),r=o(72270),i=o(63200),a=o(25964),s=o(18782);const l=(0,a.xE)("image"),d=["src","src-dark"];class c extends((0,r.qu)({componentName:l,baseSelector:"slot"})){static get observedAttributes(){return d}constructor(){super(),this.attachShadow({mode:"open"}).innerHTML="\n\t\t<slot></slot>\n\t",(0,a.fz)("\n\t\t\t:host {\n\t\t\t\tdisplay: inline-flex;\n\t\t\t}\n :host > slot {\n width: 100%;\n height: 100%;\n\t\t\t\tbox-sizing: border-box;\n\t\t\t\tdisplay: flex;\n\t\t\t\toverflow: hidden;\n\t\t\t}\n\n ::slotted(*) {\n width: 100%;\n\t\t\t}\n\n .hidden {\n display: none;\n }\n ",this)}init(){super.init?.(),this.toggleVisibility(this.getSrc)}onThemeChange(){this.renderImage()}toggleVisibility(t){t?this.classList.remove("hidden"):this.classList.add("hidden")}get altText(){return this.getAttribute("alt")||""}get legacySrc(){return this.getAttribute("src")}get themeSrc(){return this.getAttribute(`src-${this.currentThemeName}`)}get getSrc(){return this.themeSrc||this.legacySrc}updateFillColor(t){[t,...t.querySelectorAll("*[fill]")].forEach(t=>{t.setAttribute("fill",`var(${p.cssVarList.fill}, ${t.getAttribute("fill")||"''"})`)})}renderImage(){this.toggleVisibility(this.getSrc),(0,s.m)(this.getSrc,this.altText).then(t=>{this.innerHTML="",t&&(this.updateFillColor(t),this.appendChild(t))})}shouldRender(t){const e=this.getAttribute(t);return this.getSrc===e}attributeChangedCallback(t,e,o){super.attributeChangedCallback?.(t,e,o),e!==o&&this.shouldRender(t)&&this.renderImage()}}const p=(0,i.Zz)((0,n.RF)({mappings:{fill:{},height:{selector:()=>":host"},width:{selector:()=>":host"}}}),n.VO,n.tQ)(c)},18782(t,e,o){o.d(e,{m:()=>i});var n=o(25414);const r=t=>{const e=n.A.sanitize(t,{USE_PROFILES:{svg:!0,svgFilters:!0},ADD_TAGS:["image"],FORBID_TAGS:["defs"]});return(new DOMParser).parseFromString(e,"image/svg+xml").querySelector("svg")},i=async(t,e)=>{try{let o;if((t=>t.startsWith("data:image/svg+xml;base64,"))(t)){const e=atob(t.slice(26));o=r(e)}else if("svg"===(t=>{const e=t.match(/\.([0-9a-z]+)(?:[\\?#]|$)/i);return e?e[1]:null})(t)){const e=await fetch(t),n=await e.text();o=r(n)}else o=((t,e)=>{const o=document.createElement("img");return o.setAttribute("src",t),o.setAttribute("alt",e),o})(t,e);return o.style.setProperty("max-width","100%"),o.style.setProperty("max-height","100%"),o}catch{return null}}},53455(t,e,o){o.r(e),o.d(e,{ImageClass:()=>n.q,componentName:()=>n.T});var n=o(8512);customElements.define(n.T,n.q)},93895(t,e,o){o.d(e,{O:()=>l,T:()=>s});var n=o(88961),r=o(63200),i=o(25964),a=o(72270);const s=(0,i.xE)("list-item"),l=(0,r.Zz)((0,n.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:{}}}),n.VO,n.tQ,t=>class extends t{constructor(){super(),this.attachShadow({mode:"open"}).innerHTML="\n <slot></slot>\n ",(0,i.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)}},n.y)((0,a.qu)({componentName:s,baseSelector:"slot"}))},24542(t,e,o){o.r(e),o.d(e,{ListItemClass:()=>n.O,componentName:()=>n.T});var n=o(93895);customElements.define(n.T,n.O)},7720(t,e,o){o.d(e,{T:()=>l,x:()=>c});var n=o(88961),r=o(63200),i=o(25964),a=o(93895),s=o(72270);const l=(0,i.xE)("list");class d extends((0,s.qu)({componentName:l,baseSelector:".wrapper"})){static get observedAttributes(){return["variant","readonly"]}constructor(){super(),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',(0,i.fz)('\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 ',this)}get items(){return this.shadowRoot.querySelector("slot").assignedElements()}#e(){0===this.items.length?this.setAttribute("empty","true"):this.removeAttribute("empty")}get variant(){return this.getAttribute("variant")||"list"}#o(){this.items.forEach(t=>{let e=t;e.localName!==a.O.componentName&&(e=t.querySelector(a.O.componentName));const o="tiles"===this.variant?"tile":"row";e?.setAttribute("variant",o)})}init(){super.init?.(),(0,i.Ge)(this,()=>{this.#e(),this.#o(),this.#n()})}get isReadOnly(){return"true"===this.getAttribute("readonly")}#n(){this.items.forEach(t=>{this.isReadOnly?t.setAttribute("inert",""):t.removeAttribute("inert")})}attributeChangedCallback(t,e,o){super.attributeChangedCallback?.(t,e,o),o!==e&&("variant"===t?this.#o():"readonly"===t&&this.#n())}}const c=(0,r.Zz)((0,n.RF)({mappings:{hostWidth:{selector:()=>":host",property:"width"},maxHeight:{selector:()=>":host"},minHeight:{},verticalPadding:[{property:"padding-top"},{property:"padding-bottom"}],horizontalPadding:[{property:"padding-left"},{property:"padding-right"}],hostDirection:{selector:()=>":host",property:"direction"},fontFamily:{},gap:{},backgroundColor:{},borderRadius:{},borderColor:{},borderStyle:{},borderWidth:{},boxShadow:{},gridTemplateColumns:{},maxItemsWidth:{selector:()=>"::slotted(:not([slot]))",property:"max-width"},minItemsWidth:{selector:()=>"::slotted(:not([slot]))",property:"min-width"},maxRowItems:{property:"max-row-items"},itemsHorizontalAlign:{selector:()=>"::slotted(*)",property:"justify-self"},emptyStateTextColor:{selector:()=>'slot[name="empty-state"]',property:"color"},emptyStateTextFontFamily:{selector:()=>'slot[name="empty-state"]',property:"font-family"},emptyStateVerticalPadding:[{selector:()=>'slot[name="empty-state"]',property:"padding-top"},{selector:()=>'slot[name="empty-state"]',property:"padding-bottom"}]}}),n.VO,n.tQ)(d)},45400(t,e,o){o.r(e),o.d(e,{ListClass:()=>n.x,componentName:()=>n.T}),o(24542);var n=o(7720);customElements.define(n.T,n.x)},91779(t,e,o){o.r(e),o.d(e,{MultiSsoClass:()=>y,componentName:()=>u}),o(45400),o(24542),o(63595),o(56737),o(30576),o(11065);var n=o(63200),r=o(25964),i=o(88961),a=o(72270),s=o(19624),l=o(7720),d=o(98538),c=o(93895),p=o(77888),h=o(66434);const u=(0,r.xE)("multi-sso"),m=({id:t,name:e,isDefault:o,link:n,authType:i},a,s)=>{const l=!o&&s?.allowDelete?`<span\n class="delete-btn delete-icon"\n data-action="delete"\n role="button"\n tabindex="0"\n title="${s.deleteTooltipLabel}"\n ></span>`:"",d=n&&s?.allowConfigure?`<a\n class="external-link external-link-icon"\n target="_blank"\n rel="noopener noreferrer"\n title="${s.configureTooltipLabel}"\n ></a>`:"",{label:c,configured:p}=(t=>t&&"none"!==t?{label:t.toUpperCase(),configured:!0}:{label:"Not Configured",configured:!1})(i),h=p?'<div class="auth-type-row">\n <descope-badge class="auth-type-badge" size="xs"></descope-badge>\n </div>':`<div class="auth-type-row">\n <descope-text\n not-configured\n variant="body2"\n mode="secondary"\n >${s?.notConfiguredLabel}</descope-text>\n </div>`,u=document.createElement("template");u.innerHTML=`\n <descope-list-item>\n <div class="content">\n <div class="top-row">\n <descope-text\n class="config-name"\n variant="body1"\n mode="primary"\n ></descope-text>\n <span class="action">\n ${l}\n ${d}\n </span>\n </div>\n ${h}\n </div>\n </descope-list-item>\n `,u.content.querySelector(".config-name").textContent=e;const m=u.content.querySelector(".delete-btn");if(m){m.dataset.id=t,m.dataset.name=e,m.setAttribute("aria-label",s.deleteTooltipLabel);const o=(0,r.I7)(s,"delete-icon");o&&m.append(o)}const b=u.content.querySelector(".external-link");if(b){b.setAttribute("aria-label",s.configureTooltipLabel),n&&b.setAttribute("href",n);const t=(0,r.I7)(s,"external-link-icon");t&&b.append(t)}const g=u.content.querySelector(".auth-type-badge");return g&&(g.textContent=c),u},b=(0,a.qu)({componentName:u,baseSelector:"span.wrapper"}),{host:g}={host:{selector:()=>":host"}},y=(0,n.Zz)((0,i.RF)({mappings:{hostWidth:{...g,property:"width"},hostMinWidth:{...g,property:"min-width"},hostDirection:[{...g,property:"direction"},{selector:()=>"descope-list-item",property:"direction"},{selector:()=>"descope-text",property:"direction"}],headerGap:{selector:()=>".header",property:"gap"},headerListGap:{selector:()=>"descope-list",property:"margin-top"},itemContentGap:{selector:()=>".content",property:"gap"},actionGap:{selector:()=>".action",property:"gap"},unconfiguredAuthTypeTextColor:{selector:()=>"[not-configured]",property:h.s.cssVarList.textColor},unconfiguredAuthTypeTextFontStyle:{selector:()=>"[not-configured]",property:"font-style"},buttonMaxWidth:{selector:s.J.componentName,property:s.J.cssVarList.hostMaxWidth},listItemsGap:{property:l.x.cssVarList.gap},listBackgroundColor:{selector:()=>l.x.componentName,property:l.x.cssVarList.backgroundColor},listBorderRadius:{selector:()=>l.x.componentName,property:l.x.cssVarList.borderRadius},listBorderWidth:{selector:()=>l.x.componentName,property:l.x.cssVarList.borderWidth},listBoxShadow:{selector:()=>l.x.componentName,property:l.x.cssVarList.boxShadow},listPadding:[{selector:()=>l.x.componentName,property:l.x.cssVarList.verticalPadding},{selector:()=>l.x.componentName,property:l.x.cssVarList.horizontalPadding}],itemVerticalPadding:{selector:c.O.componentName,property:c.O.cssVarList.verticalPadding},itemHorizontalPadding:{selector:c.O.componentName,property:c.O.cssVarList.horizontalPadding},itemCursor:{selector:c.O.componentName,property:c.O.cssVarList.cursor},itemOutline:{selector:c.O.componentName,property:c.O.cssVarList.outline},itemBorderColor:{selector:c.O.componentName,property:c.O.cssVarList.borderColor},itemBorderRadius:{selector:c.O.componentName,property:c.O.cssVarList.borderRadius},itemBackgroundColor:{selector:c.O.componentName,property:c.O.cssVarList.backgroundColor},badgeBorderColor:{selector:()=>p.e.componentName,property:p.e.cssVarList.borderColor},badgeTextColor:{selector:()=>p.e.componentName,property:p.e.cssVarList.textColor},badgeBackgroundColor:{selector:()=>p.e.componentName,property:p.e.cssVarList.backgroundColor},badgeBorderRadius:{selector:()=>p.e.componentName,property:p.e.cssVarList.borderRadius},titleIconSize:[{selector:()=>'::slotted([slot="title-icon"])',property:"width"},{selector:()=>'::slotted([slot="title-icon"])',property:"height"}],createButtonIconSize:[{selector:()=>'::slotted([slot="create-button-icon"])',property:"width"},{selector:()=>'::slotted([slot="create-button-icon"])',property:"height"}],actionIconSize:[{selector:()=>".delete-icon",property:"width"},{selector:()=>".delete-icon",property:"height"},{selector:()=>".external-link-icon",property:"width"},{selector:()=>".external-link-icon",property:"height"}],actionIconColor:[{selector:()=>".delete-icon",property:d.S.cssVarList.fill},{selector:()=>".external-link-icon",property:d.S.cssVarList.fill}]}}),i.VO,(0,i.t$)({targetSelector:"descope-list",itemRenderer:m,rerenderAttrsList:["allow-delete","allow-configure","not-configured-label","delete-tooltip-label","configure-tooltip-label"]}),i.tQ)(class extends b{static get observedAttributes(){return["label","create-button-label","not-configured-label","delete-tooltip-label","configure-tooltip-label","empty"].concat(super.observedAttributes)}constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <span class="wrapper">\n <div class="header">\n <slot name="title-icon"></slot>\n <descope-text class="title" variant="body1" mode="primary"></descope-text>\n <descope-button\n class="create-button"\n size="sm"\n variant="link"\n mode="primary"\n data-action="create"\n >\n <slot name="create-button-icon" slot="prefix"></slot>\n <span class="create-button-label"></span>\n </descope-button>\n </div>\n <descope-list></descope-list>\n <slot name="delete-icon" class="hidden"></slot>\n <slot name="external-link-icon" class="hidden"></slot>\n </span>\n ',this.listEl=this.shadowRoot.querySelector("descope-list"),this.deleteIconSlot=this.shadowRoot.querySelector('slot[name="delete-icon"]'),this.externalLinkIconSlot=this.shadowRoot.querySelector('slot[name="external-link-icon"]'),(0,r.fz)('\n :host {\n display: inline-block;\n }\n\n :host(:not([allow-create="true"])) .create-button {\n display: none;\n }\n\n .create-button {\n min-width: 0;\n flex-shrink:1;\n }\n\n .header {\n width: 100%;\n display: flex;\n align-items: center;\n justify-content: space-between;\n }\n\n slot[name="title-icon"] {\n display: inline-flex;\n align-items: center;\n flex-shrink: 0;\n }\n\n .title {\n flex: 1;\n min-width: 0;\n width:0;\n flex-shrink: 0;\n\n }\n\n .title::part(text-wrapper) {\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n }\n\n .content {\n display: flex;\n flex-direction: column;\n align-items: stretch;\n width: 100%;\n }\n\n .top-row {\n display: flex;\n align-items: center;\n justify-content: space-between;\n min-width: 0;\n }\n\n .config-name {\n display: flex;\n align-items: center;\n min-width: 0;\n }\n\n .config-name::part(text-wrapper) {\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n }\n\n .auth-type-row {\n display: flex;\n align-items: center;\n }\n\n .action {\n display: flex;\n align-items: center;\n flex-shrink: 0;\n }\n\n .hidden {\n display: none;\n }\n\n .delete-btn {\n cursor: pointer;\n display: flex;\n }\n\n .delete-icon > *,\n .external-link-icon > * {\n width: 100%;\n height: 100%;\n }\n\n .external-link {\n cursor: pointer;\n color: inherit;\n display: flex;\n }\n\n descope-text {\n display: flex;\n align-items: center;\n min-width: 0;\n }\n ',this)}get deleteTooltipLabel(){return this.getAttribute("delete-tooltip-label")??""}get configureTooltipLabel(){return this.getAttribute("configure-tooltip-label")??""}init(){super.init?.(),this.shadowRoot.querySelector(".title").textContent=this.label,this.shadowRoot.querySelector(".create-button-label").textContent=this.createButtonLabel,this.listEl.itemRenderer=(t,e)=>m(t,0,this),this.shadowRoot.querySelector('[data-action="create"]').addEventListener("click",this.onCreateClick.bind(this)),this.listEl.addEventListener("click",this.onItemClick.bind(this)),(0,r.EA)(this.listEl,this,{includeAttrs:["empty"]});const t=()=>{this.data&&(this.data=[...this.data])};this.deleteIconSlot.addEventListener("slotchange",t),this.externalLinkIconSlot.addEventListener("slotchange",t)}onCreateClick(){this.dispatchEvent(new CustomEvent("create-clicked",{bubbles:!0,detail:{}}))}onItemClick(t){const e=t.target.closest('[data-action="delete"]');if(!e)return;const o=e.getAttribute("data-id"),n=e.getAttribute("data-name");o&&this.dispatchEvent(new CustomEvent("delete-clicked",{bubbles:!0,detail:{id:o,name:n}}))}get allowCreate(){return"true"===this.getAttribute("allow-create")}get allowDelete(){return"true"===this.getAttribute("allow-delete")}get allowConfigure(){return"true"===this.getAttribute("allow-configure")}get label(){return this.getAttribute("label")}get createButtonLabel(){return this.getAttribute("create-button-label")}get notConfiguredLabel(){return this.getAttribute("not-configured-label")||"Not Configured"}attributeChangedCallback(t,e,o){if(super.attributeChangedCallback?.(t,e,o),e!==o)if("label"===t){const t=this.shadowRoot?.querySelector(".title");t&&(t.textContent=this.label)}else if("create-button-label"===t){const t=this.shadowRoot?.querySelector(".create-button-label");t&&(t.textContent=this.createButtonLabel)}else"empty"===t&&this.listEl.classList.toggle("hidden","true"===o)}});customElements.define(u,y)},66434(t,e,o){o.d(e,{T:()=>s,s:()=>c});var n=o(88961),r=o(63200),i=o(25964),a=o(72270);const s=(0,i.xE)("text");class l extends((0,a.qu)({componentName:s,baseSelector:":host > slot"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <slot part="text-wrapper"></slot>\n ',(0,i.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,i.Ge)(this,()=>{const t=!!this.childNodes.length;this.style.display=!t&&this.hideWhenEmpty?"none":""})}}const{host:d}={host:{selector:()=>":host"}},c=(0,r.Zz)((0,n.RF)({mappings:{hostWidth:{...d,property:"width"},hostDirection:{...d,property:"direction"},fontSize:{},textColor:[{property:"color"}],textLineHeight:{property:"line-height"},textLetterSpacing:{property:"letter-spacing"},textShadow:{},textAlign:{},textTransform:{},fontFamily:{},fontStyle:{},fontWeight:{},borderWidth:{},borderStyle:{},borderColor:{}}}),(0,n.DM)({triggers:[{attr:"full-width",value:"true"}]}),n.VO,n.tQ)(l)},63595(t,e,o){o.r(e),o.d(e,{TextClass:()=>n.s,componentName:()=>n.T});var n=o(66434);customElements.define(n.T,n.s)},89389(t,e,o){o.d(e,{$:()=>m});var n=o(13256),r=o(55774),i=o(82901),a=o(72562),s=o(81488),l=o(87550);const d=o(51450).AH`
|
|
2
|
+
"use strict";(self.webpackChunk_descope_web_components_ui=self.webpackChunk_descope_web_components_ui||[]).push([[461,1202,2294,4188,4551,5087,6724,9536],{77888(t,e,o){o.d(e,{T:()=>s,e:()=>d});var n=o(88961),r=o(72270),i=o(25964),a=o(63200);const s=(0,i.xE)("badge");class l extends((0,r.qu)({componentName:s,baseSelector:":host > div"})){static get observedAttributes(){return["data-attachment-size","shrink-to-indicator-threshold"]}constructor(){super(),this.attachShadow({mode:"open"}).innerHTML="\n\t\t<div>\n <slot></slot>\n\t\t</div>\n\t\t",(0,i.fz)("\n :host {\n display: inline-flex;\n }\n :host > div {\n position: relative;\n width: 100%;\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n }\n ",this)}get shrinkToIndicatorThreshold(){return this.getAttribute("shrink-to-indicator-threshold")||65}#t(t){this.toggleAttribute("shrink-to-indicator",parseFloat(t)<this.shrinkToIndicatorThreshold)}attributeChangedCallback(t,e,o){super.attributeChangedCallback?.(t,e,o),"data-attachment-size"===t&&e!==o&&this.#t(o)}}const d=(0,a.Zz)((0,n.RF)({mappings:{hostWidth:[{selector:()=>":host",property:"width"}],hostHeight:[{selector:()=>":host",property:"height"}],hostDirection:{property:"direction"},fontFamily:{},fontSize:{},fontWeight:{},lineHeight:{},textTransform:{},verticalPadding:[{property:"padding-top"},{property:"padding-bottom"}],horizontalPadding:[{property:"padding-left"},{property:"padding-right"}],borderWidth:{},borderStyle:{},borderColor:{},borderRadius:{},backgroundColor:{},textColor:{property:"color"},textAlign:{},boxShadow:{},textIndent:{}}}),n.VO,n.tQ)(l)},11065(t,e,o){o.r(e),o.d(e,{BadgeClass:()=>n.e,componentName:()=>n.T});var n=o(77888);customElements.define(n.T,n.e)},19624(t,e,o){o.d(e,{J:()=>u,T:()=>l});var n=o(63200),r=o(25964),i=o(88961),a=o(98538),s=o(10767);const l=(0,r.xE)("button"),{host:d,label:c,slottedIcon:p}={host:{selector:()=>":host"},label:{selector:"::part(label)"},slottedIcon:{selector:()=>"::slotted(descope-icon)"}};let h;const u=(0,n.Zz)((0,i.DM)({triggers:[{attr:"full-width",value:"true"}]}),(0,i.RF)({mappings:{hostWidth:{property:"width"},hostMaxWidth:{...d,property:"max-width"},hostHeight:{property:"height"},hostDirection:{...d,property:"direction"},fontSize:{},fontFamily:{},fontWeight:{},cursor:{},backgroundColor:{},outlineOffset:{},outlineColor:{},outlineStyle:{},outlineWidth:{},borderRadius:{},borderColor:{},borderStyle:{},borderWidth:{},verticalPadding:[{property:"padding-top"},{property:"padding-bottom"}],horizontalPadding:[{property:"padding-right",fallback:"0.875em"},{property:"padding-left",fallback:"0.875em"}],labelTextColor:{property:"color"},iconColor:{selector:()=>"::slotted(*)",property:a.S.cssVarList.fill},labelTextDecoration:{...c,property:"text-decoration"},labelSpacing:{...c,property:"gap"},textAlign:{...c,property:"justify-content",fallback:"center"},iconSize:[{...p,property:"width"},{...p,property:"height"}]}}),s.G,i.VO,i.tQ)((0,i.tz)({slots:["","prefix","label","suffix"],wrappedEleName:"vaadin-button",style:()=>`\n\t\t\t\n\t:host {\n\t\tdisplay: inline-block;\n\t\tbox-sizing: border-box;\n\t}\n\tvaadin-button::before,\n\tvaadin-button::after {\n\t\topacity: 0;\n\t}\n\tvaadin-button {\n\t\tmargin: 0;\n\t\tmin-width: 0;\n\t\twidth: 100%;\n\t\theight: auto;\n\t\tbox-shadow: none;\n\t}\n\tvaadin-button::part(label) {\n\t\tpadding: 0;\n width: 100%;\n\t}\n\tvaadin-button::part(prefix) {\n\t\tmargin-left: 0;\n\t\tmargin-right: 0;\n\t}\n\n\t\t\t\n\tvaadin-button::part(prefix),\n\tvaadin-button::part(label) {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t}\n\n\t\t\t${h}\n\t\t\tvaadin-button::part(label) { pointer-events: none; }\n\t\t\t:host {\n\t\t\t\tpadding: calc(var(${u.cssVarList.outlineWidth}) + var(${u.cssVarList.outlineOffset}));\n\t\t\t}\n :host([full-width="true"]) {\n width: var(${u.cssVarList.hostWidth});\n }\n\t\t\tvaadin-button {\n\t\t\t\theight: calc(var(${u.cssVarList.hostHeight}) - var(${u.cssVarList.outlineWidth}) - var(${u.cssVarList.outlineOffset}));\n\t\t\t}\n\t\t\t[square="true"]:not([full-width="true"]) {\n\t\t\t\twidth: calc(var(${u.cssVarList.hostWidth}) - var(${u.cssVarList.outlineWidth}) - var(${u.cssVarList.outlineOffset}));\n padding: 0;\n\t\t\t}\n\t\t`,excludeAttrsSync:["tabindex","class","style"],componentName:l})),{color:m,fontSize:b}=u.cssVarList;h=`\n\t@keyframes spin {\n\t\t0% { -webkit-transform: rotate(0deg); }\n\t\t100% { -webkit-transform: rotate(360deg); }\n\t}\n\t:host([loading="true"]) ::before {\n\t\tanimation: spin 2s linear infinite;\n\t\tposition: absolute;\n\t\tcontent: '';\n\t\tz-index: 1;\n\t\tbox-sizing: border-box;\n\t\tborder-radius: 50%;\n\t\tborder-bottom-color: transparent;\n\t\tborder-left-color: transparent;\n\t\tborder-style: solid;\n\t\tcolor: var(${m});\n\t\ttop: calc(50% - (var(${b}) / 2));\n\t\tleft: calc(50% - (var(${b}) / 2));\n\t\tborder-width: calc(var(${b}) / 10);\n\t\twidth: var(${b});\n\t\theight: var(${b});\n\t}\n\t:host([disabled="true"]),\n\t:host([loading="true"]) {\n\t\tpointer-events: none;\n\t}\n\t:host([loading="true"]) ::part(prefix),\n\t:host([loading="true"]) ::part(label) {\n\t\tvisibility: hidden;\n\t}\n`},10767(t,e,o){o.d(e,{G:()=>n});const n=t=>class extends t{get isLoading(){return"true"===this.getAttribute("loading")}click(){this.isLoading||super.click()}}},30576(t,e,o){o.r(e),o.d(e,{ButtonClass:()=>n.J,componentName:()=>n.T});var n=o(19624);o(83799),customElements.define(n.T,n.J)},98538(t,e,o){o.d(e,{S:()=>l,T:()=>s});var n=o(88961),r=o(25964),i=o(8512),a=o(63200);const s=(0,r.xE)("icon"),l=(0,a.Zz)((0,n.RF)({mappings:{fill:[{},{property:i.q.cssVarList.fill}],height:{selector:()=>":host"},width:{selector:()=>":host"}}}),n.VO,n.tQ)((0,n.tz)({slots:[],wrappedEleName:"descope-image",style:()=>"\n :host {\n display: inline-flex;\n align-items: center;\n justify-content: center;\n max-height: 100%;\n }\n ",excludeAttrsSync:["tabindex","class","style","st-height","st-width"],componentName:s}))},56737(t,e,o){o.r(e),o.d(e,{IconClass:()=>n.S,componentName:()=>n.T}),o(53455);var n=o(98538);customElements.define(n.T,n.S)},8512(t,e,o){o.d(e,{T:()=>l,q:()=>p});var n=o(88961),r=o(72270),i=o(63200),a=o(25964),s=o(18782);const l=(0,a.xE)("image"),d=["src","src-dark"];class c extends((0,r.qu)({componentName:l,baseSelector:"slot"})){static get observedAttributes(){return d}constructor(){super(),this.attachShadow({mode:"open"}).innerHTML="\n\t\t<slot></slot>\n\t",(0,a.fz)("\n\t\t\t:host {\n\t\t\t\tdisplay: inline-flex;\n\t\t\t}\n :host > slot {\n width: 100%;\n height: 100%;\n\t\t\t\tbox-sizing: border-box;\n\t\t\t\tdisplay: flex;\n\t\t\t\toverflow: hidden;\n\t\t\t}\n\n ::slotted(*) {\n width: 100%;\n\t\t\t}\n\n .hidden {\n display: none;\n }\n ",this)}init(){super.init?.(),this.toggleVisibility(this.getSrc)}onThemeChange(){this.renderImage()}toggleVisibility(t){t?this.classList.remove("hidden"):this.classList.add("hidden")}get altText(){return this.getAttribute("alt")||""}get legacySrc(){return this.getAttribute("src")}get themeSrc(){return this.getAttribute(`src-${this.currentThemeName}`)}get getSrc(){return this.themeSrc||this.legacySrc}updateFillColor(t){[t,...t.querySelectorAll("*[fill]")].forEach(t=>{t.setAttribute("fill",`var(${p.cssVarList.fill}, ${t.getAttribute("fill")||"''"})`)})}renderImage(){this.toggleVisibility(this.getSrc),(0,s.m)(this.getSrc,this.altText).then(t=>{this.innerHTML="",t&&(this.updateFillColor(t),this.appendChild(t))})}shouldRender(t){const e=this.getAttribute(t);return this.getSrc===e}attributeChangedCallback(t,e,o){super.attributeChangedCallback?.(t,e,o),e!==o&&this.shouldRender(t)&&this.renderImage()}}const p=(0,i.Zz)((0,n.RF)({mappings:{fill:{},height:{selector:()=>":host"},width:{selector:()=>":host"}}}),n.VO,n.tQ)(c)},18782(t,e,o){o.d(e,{m:()=>i});var n=o(25414);const r=t=>{const e=n.A.sanitize(t,{USE_PROFILES:{svg:!0,svgFilters:!0},ADD_TAGS:["image"],FORBID_TAGS:["defs"]});return(new DOMParser).parseFromString(e,"image/svg+xml").querySelector("svg")},i=async(t,e)=>{try{let o;if((t=>t.startsWith("data:image/svg+xml;base64,"))(t)){const e=atob(t.slice(26));o=r(e)}else if("svg"===(t=>{const e=t.match(/\.([0-9a-z]+)(?:[\\?#]|$)/i);return e?e[1]:null})(t)){const e=await fetch(t),n=await e.text();o=r(n)}else o=((t,e)=>{const o=document.createElement("img");return o.setAttribute("src",t),o.setAttribute("alt",e),o})(t,e);return o.style.setProperty("max-width","100%"),o.style.setProperty("max-height","100%"),o}catch{return null}}},53455(t,e,o){o.r(e),o.d(e,{ImageClass:()=>n.q,componentName:()=>n.T});var n=o(8512);customElements.define(n.T,n.q)},93895(t,e,o){o.d(e,{O:()=>l,T:()=>s});var n=o(88961),r=o(63200),i=o(25964),a=o(72270);const s=(0,i.xE)("list-item"),l=(0,r.Zz)((0,n.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:{}}}),n.VO,n.tQ,t=>class extends t{constructor(){super(),this.attachShadow({mode:"open"}).innerHTML="\n <slot></slot>\n ",(0,i.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)}},n.y)((0,a.qu)({componentName:s,baseSelector:"slot"}))},24542(t,e,o){o.r(e),o.d(e,{ListItemClass:()=>n.O,componentName:()=>n.T});var n=o(93895);customElements.define(n.T,n.O)},7720(t,e,o){o.d(e,{T:()=>l,x:()=>c});var n=o(88961),r=o(63200),i=o(25964),a=o(93895),s=o(72270);const l=(0,i.xE)("list");class d extends((0,s.qu)({componentName:l,baseSelector:".wrapper"})){static get observedAttributes(){return["variant","readonly"]}constructor(){super(),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',(0,i.fz)('\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 ',this)}get items(){return this.shadowRoot.querySelector("slot").assignedElements()}#e(){0===this.items.length?this.setAttribute("empty","true"):this.removeAttribute("empty")}get variant(){return this.getAttribute("variant")||"list"}#o(){this.items.forEach(t=>{let e=t;e.localName!==a.O.componentName&&(e=t.querySelector(a.O.componentName));const o="tiles"===this.variant?"tile":"row";e?.setAttribute("variant",o)})}init(){super.init?.(),(0,i.Ge)(this,()=>{this.#e(),this.#o(),this.#n()})}get isReadOnly(){return"true"===this.getAttribute("readonly")}#n(){this.items.forEach(t=>{this.isReadOnly?t.setAttribute("inert",""):t.removeAttribute("inert")})}attributeChangedCallback(t,e,o){super.attributeChangedCallback?.(t,e,o),o!==e&&("variant"===t?this.#o():"readonly"===t&&this.#n())}}const c=(0,r.Zz)((0,n.RF)({mappings:{hostWidth:{selector:()=>":host",property:"width"},maxHeight:{selector:()=>":host"},minHeight:{},verticalPadding:[{property:"padding-top"},{property:"padding-bottom"}],horizontalPadding:[{property:"padding-left"},{property:"padding-right"}],hostDirection:{selector:()=>":host",property:"direction"},fontFamily:{},gap:{},backgroundColor:{},borderRadius:{},borderColor:{},borderStyle:{},borderWidth:{},boxShadow:{},gridTemplateColumns:{},maxItemsWidth:{selector:()=>"::slotted(:not([slot]))",property:"max-width"},minItemsWidth:{selector:()=>"::slotted(:not([slot]))",property:"min-width"},maxRowItems:{property:"max-row-items"},itemsHorizontalAlign:{selector:()=>"::slotted(*)",property:"justify-self"},emptyStateTextColor:{selector:()=>'slot[name="empty-state"]',property:"color"},emptyStateTextFontFamily:{selector:()=>'slot[name="empty-state"]',property:"font-family"},emptyStateVerticalPadding:[{selector:()=>'slot[name="empty-state"]',property:"padding-top"},{selector:()=>'slot[name="empty-state"]',property:"padding-bottom"}]}}),n.VO,n.tQ)(d)},45400(t,e,o){o.r(e),o.d(e,{ListClass:()=>n.x,componentName:()=>n.T}),o(24542);var n=o(7720);customElements.define(n.T,n.x)},91779(t,e,o){o.r(e),o.d(e,{MultiSsoClass:()=>y,componentName:()=>u}),o(45400),o(24542),o(63595),o(56737),o(30576),o(11065);var n=o(63200),r=o(25964),i=o(88961),a=o(72270),s=o(19624),l=o(7720),d=o(98538),c=o(93895),p=o(77888),h=o(66434);const u=(0,r.xE)("multi-sso"),m=({id:t,name:e,isDefault:o,link:n,authType:i},a,s)=>{const l=!o&&s?.allowDelete?`<span\n class="delete-btn delete-icon"\n data-action="delete"\n role="button"\n tabindex="0"\n title="${s.deleteTooltipLabel}"\n ></span>`:"",d=n&&s?.allowConfigure?`<a\n class="external-link external-link-icon"\n target="_blank"\n rel="noopener noreferrer"\n title="${s.configureTooltipLabel}"\n ></a>`:"",{label:c,configured:p}=(t=>t&&"none"!==t?{label:t.toUpperCase(),configured:!0}:{label:"Not Configured",configured:!1})(i),h=p?'<div class="auth-type-row">\n <descope-badge class="auth-type-badge" size="xs"></descope-badge>\n </div>':`<div class="auth-type-row">\n <descope-text\n not-configured\n variant="body2"\n mode="secondary"\n >${s?.notConfiguredLabel}</descope-text>\n </div>`,u=document.createElement("template");u.innerHTML=`\n <descope-list-item>\n <div class="content">\n <div class="top-row">\n <descope-text\n class="config-name"\n variant="body1"\n mode="primary"\n ></descope-text>\n <span class="action">\n ${l}\n ${d}\n </span>\n </div>\n ${h}\n </div>\n </descope-list-item>\n `,u.content.querySelector(".config-name").textContent=e;const m=u.content.querySelector(".delete-btn");if(m){m.dataset.id=t,m.dataset.name=e,m.setAttribute("aria-label",s.deleteTooltipLabel);const o=(0,r.I7)(s,"delete-icon");o&&m.append(o)}const b=u.content.querySelector(".external-link");if(b){b.setAttribute("aria-label",s.configureTooltipLabel),n&&b.setAttribute("href",n);const t=(0,r.I7)(s,"external-link-icon");t&&b.append(t)}const g=u.content.querySelector(".auth-type-badge");return g&&(g.textContent=c),u},b=(0,a.qu)({componentName:u,baseSelector:"span.wrapper"}),{host:g}={host:{selector:()=>":host"}},y=(0,n.Zz)((0,i.RF)({mappings:{hostWidth:{...g,property:"width"},hostMinWidth:{...g,property:"min-width"},hostDirection:[{...g,property:"direction"},{selector:()=>"descope-list-item",property:"direction"},{selector:()=>"descope-text",property:"direction"}],headerGap:{selector:()=>".header",property:"gap"},headerListGap:{selector:()=>"descope-list",property:"margin-top"},itemContentGap:{selector:()=>".content",property:"gap"},actionGap:{selector:()=>".action",property:"gap"},unconfiguredAuthTypeTextColor:{selector:()=>"[not-configured]",property:h.s.cssVarList.textColor},unconfiguredAuthTypeTextFontStyle:{selector:()=>"[not-configured]",property:"font-style"},buttonMaxWidth:{selector:s.J.componentName,property:s.J.cssVarList.hostMaxWidth},listItemsGap:{property:l.x.cssVarList.gap},listBackgroundColor:{selector:()=>l.x.componentName,property:l.x.cssVarList.backgroundColor},listBorderRadius:{selector:()=>l.x.componentName,property:l.x.cssVarList.borderRadius},listBorderWidth:{selector:()=>l.x.componentName,property:l.x.cssVarList.borderWidth},listBoxShadow:{selector:()=>l.x.componentName,property:l.x.cssVarList.boxShadow},listPadding:[{selector:()=>l.x.componentName,property:l.x.cssVarList.verticalPadding},{selector:()=>l.x.componentName,property:l.x.cssVarList.horizontalPadding}],itemVerticalPadding:{selector:c.O.componentName,property:c.O.cssVarList.verticalPadding},itemHorizontalPadding:{selector:c.O.componentName,property:c.O.cssVarList.horizontalPadding},itemCursor:{selector:c.O.componentName,property:c.O.cssVarList.cursor},itemOutline:{selector:c.O.componentName,property:c.O.cssVarList.outline},itemBorderColor:{selector:c.O.componentName,property:c.O.cssVarList.borderColor},itemBorderRadius:{selector:c.O.componentName,property:c.O.cssVarList.borderRadius},itemBackgroundColor:{selector:c.O.componentName,property:c.O.cssVarList.backgroundColor},badgeBorderColor:{selector:()=>p.e.componentName,property:p.e.cssVarList.borderColor},badgeTextColor:{selector:()=>p.e.componentName,property:p.e.cssVarList.textColor},badgeBackgroundColor:{selector:()=>p.e.componentName,property:p.e.cssVarList.backgroundColor},badgeBorderRadius:{selector:()=>p.e.componentName,property:p.e.cssVarList.borderRadius},titleIconSize:[{selector:()=>'::slotted([slot="title-icon"])',property:"width"},{selector:()=>'::slotted([slot="title-icon"])',property:"height"}],createButtonIconSize:[{selector:()=>'::slotted([slot="create-button-icon"])',property:"width"},{selector:()=>'::slotted([slot="create-button-icon"])',property:"height"}],actionIconSize:[{selector:()=>".delete-icon",property:"width"},{selector:()=>".delete-icon",property:"height"},{selector:()=>".external-link-icon",property:"width"},{selector:()=>".external-link-icon",property:"height"}],actionIconColor:[{selector:()=>".delete-icon",property:d.S.cssVarList.fill},{selector:()=>".external-link-icon",property:d.S.cssVarList.fill}]}}),i.VO,(0,i.t$)({targetSelector:"descope-list",itemRenderer:m,rerenderAttrsList:["allow-delete","allow-configure","not-configured-label","delete-tooltip-label","configure-tooltip-label"]}),i.tQ)(class extends b{static get observedAttributes(){return["label","create-button-label","not-configured-label","delete-tooltip-label","configure-tooltip-label","empty"].concat(super.observedAttributes)}constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <span class="wrapper">\n <div class="header">\n <slot name="title-icon"></slot>\n <descope-text class="title" variant="body1" mode="primary"></descope-text>\n <descope-button\n class="create-button"\n size="sm"\n variant="link"\n mode="primary"\n data-action="create"\n >\n <slot name="create-button-icon" slot="prefix"></slot>\n <span class="create-button-label"></span>\n </descope-button>\n </div>\n <descope-list></descope-list>\n <slot name="delete-icon" class="hidden"></slot>\n <slot name="external-link-icon" class="hidden"></slot>\n </span>\n ',this.listEl=this.shadowRoot.querySelector("descope-list"),this.deleteIconSlot=this.shadowRoot.querySelector('slot[name="delete-icon"]'),this.externalLinkIconSlot=this.shadowRoot.querySelector('slot[name="external-link-icon"]'),(0,r.fz)('\n :host {\n display: inline-block;\n }\n\n :host(:not([allow-create="true"])) .create-button {\n display: none;\n }\n\n .create-button {\n min-width: 0;\n flex-shrink:1;\n }\n\n .header {\n width: 100%;\n display: flex;\n align-items: center;\n justify-content: space-between;\n }\n\n slot[name="title-icon"] {\n display: inline-flex;\n align-items: center;\n flex-shrink: 0;\n }\n\n .title {\n flex: 1;\n min-width: 0;\n width:0;\n flex-shrink: 0;\n\n }\n\n .title::part(text-wrapper) {\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n }\n\n .content {\n display: flex;\n flex-direction: column;\n align-items: stretch;\n width: 100%;\n }\n\n .top-row {\n display: flex;\n align-items: center;\n justify-content: space-between;\n min-width: 0;\n }\n\n .config-name {\n display: flex;\n align-items: center;\n min-width: 0;\n }\n\n .config-name::part(text-wrapper) {\n text-overflow: ellipsis;\n overflow: hidden;\n white-space: nowrap;\n }\n\n .auth-type-row {\n display: flex;\n align-items: center;\n }\n\n .action {\n display: flex;\n align-items: center;\n flex-shrink: 0;\n }\n\n .hidden {\n display: none;\n }\n\n .delete-btn {\n cursor: pointer;\n display: flex;\n }\n\n .delete-icon > *,\n .external-link-icon > * {\n width: 100%;\n height: 100%;\n }\n\n .external-link {\n cursor: pointer;\n color: inherit;\n display: flex;\n }\n\n descope-text {\n display: flex;\n align-items: center;\n min-width: 0;\n }\n ',this)}get deleteTooltipLabel(){return this.getAttribute("delete-tooltip-label")??""}get configureTooltipLabel(){return this.getAttribute("configure-tooltip-label")??""}init(){super.init?.(),this.shadowRoot.querySelector(".title").textContent=this.label,this.shadowRoot.querySelector(".create-button-label").textContent=this.createButtonLabel,this.listEl.itemRenderer=(t,e)=>m(t,0,this),this.shadowRoot.querySelector('[data-action="create"]').addEventListener("click",this.onCreateClick.bind(this)),this.listEl.addEventListener("click",this.onItemClick.bind(this)),(0,r.EA)(this.listEl,this,{includeAttrs:["empty"]});const t=()=>{this.data&&(this.data=[...this.data])};this.deleteIconSlot.addEventListener("slotchange",t),this.externalLinkIconSlot.addEventListener("slotchange",t)}onCreateClick(){this.dispatchEvent(new CustomEvent("create-clicked",{bubbles:!0,detail:{}}))}onItemClick(t){const e=t.target.closest('[data-action="delete"]');if(!e)return;const o=e.getAttribute("data-id"),n=e.getAttribute("data-name");o&&this.dispatchEvent(new CustomEvent("delete-clicked",{bubbles:!0,detail:{id:o,name:n}}))}get allowCreate(){return"true"===this.getAttribute("allow-create")}get allowDelete(){return"true"===this.getAttribute("allow-delete")}get allowConfigure(){return"true"===this.getAttribute("allow-configure")}get label(){return this.getAttribute("label")}get createButtonLabel(){return this.getAttribute("create-button-label")}get notConfiguredLabel(){return this.getAttribute("not-configured-label")||"Not Configured"}attributeChangedCallback(t,e,o){if(super.attributeChangedCallback?.(t,e,o),e!==o)if("label"===t){const t=this.shadowRoot?.querySelector(".title");t&&(t.textContent=this.label)}else if("create-button-label"===t){const t=this.shadowRoot?.querySelector(".create-button-label");t&&(t.textContent=this.createButtonLabel)}else"empty"===t&&this.listEl.classList.toggle("hidden","true"===o)}});customElements.define(u,y)},66434(t,e,o){o.d(e,{T:()=>s,s:()=>c});var n=o(88961),r=o(63200),i=o(25964),a=o(72270);const s=(0,i.xE)("text");class l extends((0,a.qu)({componentName:s,baseSelector:":host > slot"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <slot part="text-wrapper"></slot>\n ',(0,i.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,i.Ge)(this,()=>{const t=!!this.childNodes.length;this.style.display=!t&&this.hideWhenEmpty?"none":""})}}const{host:d}={host:{selector:()=>":host"}},c=(0,r.Zz)((0,n.RF)({mappings:{hostWidth:{...d,property:"width"},hostDirection:{...d,property:"direction"},fontSize:{},textColor:[{property:"color"}],textLineHeight:{property:"line-height"},textLetterSpacing:{property:"letter-spacing"},textShadow:{},textAlign:{},textTransform:{},fontFamily:{},fontStyle:{},fontWeight:{},borderWidth:{},borderStyle:{},borderColor:{}}}),(0,n.DM)({triggers:[{attr:"full-width",value:"true"}]}),n.VO,n.tQ)(l)},63595(t,e,o){o.r(e),o.d(e,{TextClass:()=>n.s,componentName:()=>n.T});var n=o(66434);customElements.define(n.T,n.s)},89389(t,e,o){o.d(e,{$:()=>m});var n=o(13256),r=o(55774),i=o(82901),a=o(72562),s=o(81488),l=o(87550);const d=o(51450).AH`
|
|
3
3
|
:host {
|
|
4
4
|
display: inline-block;
|
|
5
5
|
position: relative;
|