@descope/web-components-ui 1.109.0 → 1.111.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.
Files changed (87) hide show
  1. package/dist/cjs/index.cjs.js +2086 -1839
  2. package/dist/cjs/index.cjs.js.map +1 -1
  3. package/dist/index.esm.js +2452 -2204
  4. package/dist/index.esm.js.map +1 -1
  5. package/dist/umd/1995.js +7 -22
  6. package/dist/umd/1995.js.LICENSE.txt +0 -6
  7. package/dist/umd/1995.js.map +1 -1
  8. package/dist/umd/8961.js +1 -1
  9. package/dist/umd/8961.js.map +1 -1
  10. package/dist/umd/DescopeDev.js +1 -1
  11. package/dist/umd/DescopeDev.js.map +1 -1
  12. package/dist/umd/button-selection-group-fields-descope-button-selection-group-item-index-js.js +3 -3
  13. package/dist/umd/button-selection-group-fields-descope-button-selection-group-item-index-js.js.map +1 -1
  14. package/dist/umd/descope-alert-index-js.js +1 -1
  15. package/dist/umd/descope-alert-index-js.js.map +1 -1
  16. package/dist/umd/descope-apps-list.js +18 -0
  17. package/dist/umd/descope-apps-list.js.LICENSE.txt +23 -0
  18. package/dist/umd/descope-apps-list.js.map +1 -0
  19. package/dist/umd/descope-avatar.js +17 -1
  20. package/dist/umd/descope-avatar.js.LICENSE.txt +23 -0
  21. package/dist/umd/descope-avatar.js.map +1 -1
  22. package/dist/umd/descope-button.js +4 -4
  23. package/dist/umd/descope-button.js.map +1 -1
  24. package/dist/umd/descope-collapsible-container.js +1 -1
  25. package/dist/umd/descope-collapsible-container.js.map +1 -1
  26. package/dist/umd/descope-date-field-descope-calendar-index-js.js +1 -1
  27. package/dist/umd/descope-date-field-descope-calendar-index-js.js.map +1 -1
  28. package/dist/umd/descope-divider-index-js.js +1 -1
  29. package/dist/umd/descope-divider-index-js.js.map +1 -1
  30. package/dist/umd/descope-enriched-text.js +1 -1
  31. package/dist/umd/descope-enriched-text.js.map +1 -1
  32. package/dist/umd/descope-icon.js +1 -1
  33. package/dist/umd/descope-icon.js.map +1 -1
  34. package/dist/umd/descope-image.js +1 -1
  35. package/dist/umd/descope-image.js.map +1 -1
  36. package/dist/umd/descope-link.js +1 -1
  37. package/dist/umd/descope-link.js.map +1 -1
  38. package/dist/umd/descope-list-item.js +2 -0
  39. package/dist/umd/descope-list-item.js.map +1 -0
  40. package/dist/umd/descope-list.js +2 -0
  41. package/dist/umd/descope-list.js.map +1 -0
  42. package/dist/umd/descope-outbound-apps.js +339 -0
  43. package/dist/umd/descope-outbound-apps.js.LICENSE.txt +5 -0
  44. package/dist/umd/descope-outbound-apps.js.map +1 -0
  45. package/dist/umd/descope-recovery-codes.js +1 -1
  46. package/dist/umd/descope-recovery-codes.js.map +1 -1
  47. package/dist/umd/descope-scopes-list-index-js.js +1 -1
  48. package/dist/umd/descope-scopes-list-index-js.js.map +1 -1
  49. package/dist/umd/descope-security-questions-verify-index-js.js +1 -1
  50. package/dist/umd/descope-security-questions-verify-index-js.js.map +1 -1
  51. package/dist/umd/descope-text.js +1 -1
  52. package/dist/umd/descope-text.js.map +1 -1
  53. package/dist/umd/descope-third-party-app-logo-index-js.js +1 -1
  54. package/dist/umd/descope-third-party-app-logo-index-js.js.map +1 -1
  55. package/dist/umd/descope-timer-button.js +2 -2
  56. package/dist/umd/descope-timer-button.js.map +1 -1
  57. package/dist/umd/descope-timer.js +1 -1
  58. package/dist/umd/descope-timer.js.map +1 -1
  59. package/dist/umd/descope-upload-file-index-js.js +3 -3
  60. package/dist/umd/descope-upload-file-index-js.js.map +1 -1
  61. package/dist/umd/descope-user-attribute-index-js.js +4 -4
  62. package/dist/umd/descope-user-attribute-index-js.js.map +1 -1
  63. package/dist/umd/descope-user-auth-method-index-js.js +2 -2
  64. package/dist/umd/descope-user-auth-method-index-js.js.map +1 -1
  65. package/dist/umd/index.js +1 -1
  66. package/dist/umd/index.js.map +1 -1
  67. package/dist/umd/mapping-fields-descope-mappings-field-index-js.js +1 -1
  68. package/dist/umd/mapping-fields-descope-mappings-field-index-js.js.map +1 -1
  69. package/dist/umd/mapping-fields-descope-saml-group-mappings-index-js.js +1 -1
  70. package/dist/umd/mapping-fields-descope-saml-group-mappings-index-js.js.map +1 -1
  71. package/package.json +21 -17
  72. package/src/components/descope-scopes-list/index.js +2 -1
  73. package/src/index.cjs.js +0 -3
  74. package/src/index.js +0 -2
  75. package/src/theme/components/index.js +5 -3
  76. package/dist/umd/descope-apps-list-index-js.js +0 -2
  77. package/dist/umd/descope-apps-list-index-js.js.map +0 -1
  78. package/dist/umd/descope-list-index-js.js +0 -2
  79. package/dist/umd/descope-list-index-js.js.map +0 -1
  80. package/src/components/descope-apps-list/AppsListClass.js +0 -97
  81. package/src/components/descope-apps-list/index.js +0 -8
  82. package/src/components/descope-list/ListClass.js +0 -156
  83. package/src/components/descope-list/ListItemClass.js +0 -58
  84. package/src/components/descope-list/index.js +0 -7
  85. package/src/theme/components/appsList.js +0 -36
  86. package/src/theme/components/list/list.js +0 -56
  87. package/src/theme/components/list/listItem.js +0 -41
@@ -1 +1 @@
1
- {"version":3,"file":"descope-date-field-descope-calendar-index-js.js","mappings":"6LASO,MAAMA,EAAuB,IAAIC,KACtC,QACE,KACA,KACA,KACA,KAJF,EAKE,UAAmBA,G,mCCfhB,MAAMC,EAAkBC,GAC7B,cAAkCA,EAChC,aAAIC,GACF,MAAwC,SAAjCC,KAAKC,aAAa,UAC3B,CAEA,KAAAC,GACEF,KAAKD,WAAaI,MAAMD,OAC1B,E,sGCGG,MAAME,GAAgB,QAAiB,WAsCxC,KAAEC,EAAI,MAAEC,EAAK,YAAEC,GAAgB,CACnCF,KAAM,CAAEG,SAAU,IAAM,SACxBF,MAAO,CAAEE,SAAU,iBACnBD,YAAa,CAAEC,SAAU,IAAM,4BAGjC,IAAIC,EAEG,MAAMC,GAAc,SACzB,QAAiB,CACfC,SAAU,CACRC,UAAW,CAAEC,SAAU,SACvBC,WAAY,CAAED,SAAU,UACxBE,cAAe,IAAKV,EAAMQ,SAAU,aACpCG,SAAU,CAAC,E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,CACRuB,KAAM,CAAC,KAGX,KACA,KAPuB,EASvB,QAAY,CACVK,MAAO,GACPC,eAAgB,gBAChBC,MAAO,IAAM,kEAKbC,iBAAkB,CAAC,WAAY,SAC/BtC,kB","sources":["webpack://@descope/web-components-ui/./src/baseClasses/createBaseInputClass.js","webpack://@descope/web-components-ui/../components/descope-button/src/component/clickableMixin.js","webpack://@descope/web-components-ui/../components/descope-button/src/component/ButtonClass.js","webpack://@descope/web-components-ui/../components/descope-button/src/component/index.js","webpack://@descope/web-components-ui/./src/components/descope-date-field/helpers.js","webpack://@descope/web-components-ui/./src/components/descope-date-field/consts.js","webpack://@descope/web-components-ui/./src/helpers/themeHelpers/resetHelpers.js","webpack://@descope/web-components-ui/./src/components/descope-date-field/formats.js","webpack://@descope/web-components-ui/./src/components/descope-date-field/icons.js","webpack://@descope/web-components-ui/./src/components/descope-date-field/descope-calendar/helpers.js","webpack://@descope/web-components-ui/./src/components/descope-date-field/descope-calendar/CalendarClass.js","webpack://@descope/web-components-ui/./src/components/descope-date-field/descope-calendar/index.js","webpack://@descope/web-components-ui/../components/descope-icon/src/component/IconClass.js"],"sourcesContent":["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","export const clickableMixin = (superclass) =>\n class ClickableMixinClass extends superclass {\n get isLoading() {\n return this.getAttribute('loading') === 'true';\n }\n\n click() {\n this.isLoading || super.click();\n }\n };\n","import { compose } from '@descope-ui/common/utils';\nimport { getComponentName } from '@descope-ui/common/components-helpers';\nimport {\n createStyleMixin,\n draggableMixin,\n createProxy,\n componentNameValidationMixin,\n} from '@descope-ui/common/components-mixins';\nimport { IconClass } from '@descope-ui/descope-icon/class';\nimport { clickableMixin } from './clickableMixin';\n\nexport const componentName = getComponentName('button');\n\nconst resetStyles = `\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\nconst iconStyles = `\n\tvaadin-button::part(prefix),\n\tvaadin-button::part(label) {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t}\n`;\n\nconst editorOverrides = `vaadin-button::part(label) { pointer-events: none; }`;\n\nconst { host, label, slottedIcon } = {\n host: { selector: () => ':host' },\n label: { selector: '::part(label)' },\n slottedIcon: { selector: () => '::slotted(descope-icon)' },\n};\n\nlet loadingIndicatorStyles;\n\nexport const ButtonClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { property: 'width' },\n hostHeight: { property: 'height' },\n hostDirection: { ...host, property: 'direction' },\n fontSize: {},\n fontFamily: {},\n\n cursor: {},\n backgroundColor: {},\n\n outlineOffset: {},\n outlineColor: {},\n outlineStyle: {},\n outlineWidth: {},\n\n borderRadius: {},\n borderColor: {},\n borderStyle: {},\n borderWidth: {},\n\n verticalPadding: [{ property: 'padding-top' }, { property: 'padding-bottom' }],\n horizontalPadding: [\n { property: 'padding-right', fallback: '0.875em' },\n { property: 'padding-left', fallback: '0.875em' },\n ],\n\n labelTextColor: { property: 'color' },\n iconColor: {\n selector: () => `::slotted(*)`,\n property: IconClass.cssVarList.fill,\n },\n labelTextDecoration: { ...label, property: 'text-decoration' },\n labelSpacing: { ...label, property: 'gap' },\n textAlign: { ...label, property: 'justify-content', fallback: 'center' },\n\n iconSize: [\n { ...slottedIcon, property: 'width' },\n { ...slottedIcon, property: 'height' },\n ],\n },\n }),\n clickableMixin,\n draggableMixin,\n componentNameValidationMixin\n)(\n createProxy({\n slots: ['', 'prefix', 'label', 'suffix'],\n wrappedEleName: 'vaadin-button',\n style: () => `\n\t\t\t${resetStyles}\n\t\t\t${iconStyles}\n\t\t\t${loadingIndicatorStyles}\n\t\t\t${editorOverrides}\n\t\t\t:host {\n\t\t\t\tpadding: calc(var(${ButtonClass.cssVarList.outlineWidth}) + var(${ButtonClass.cssVarList.outlineOffset}));\n\t\t\t}\n :host([full-width=\"true\"]) {\n width: var(${ButtonClass.cssVarList.hostWidth});\n }\n\t\t\tvaadin-button {\n\t\t\t\theight: calc(var(${ButtonClass.cssVarList.hostHeight}) - var(${ButtonClass.cssVarList.outlineWidth}) - var(${ButtonClass.cssVarList.outlineOffset}));\n\t\t\t}\n\t\t\t[square=\"true\"]:not([full-width=\"true\"]) {\n\t\t\t\twidth: calc(var(${ButtonClass.cssVarList.hostWidth}) - var(${ButtonClass.cssVarList.outlineWidth}) - var(${ButtonClass.cssVarList.outlineOffset}));\n padding: 0;\n\t\t\t}\n\t\t`,\n excludeAttrsSync: ['tabindex'],\n componentName,\n })\n);\n\nconst { color, fontSize } = ButtonClass.cssVarList;\nloadingIndicatorStyles = `\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(${color});\n\t\ttop: calc(50% - (var(${fontSize}) / 2));\n\t\tleft: calc(50% - (var(${fontSize}) / 2));\n\t\tborder-width: calc(var(${fontSize}) / 10);\n\t\twidth: var(${fontSize});\n\t\theight: var(${fontSize});\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`;\n","import { componentName, ButtonClass } from './ButtonClass';\nimport '@vaadin/button';\n\ncustomElements.define(componentName, ButtonClass);\n\nexport { ButtonClass, componentName };\n","import { formats } from './formats';\n\nexport const isValidTimestamp = (val) => !Number.isNaN(Number(val));\n\nexport const isNumber = (val) => !!String(val || '').trim() && !Number.isNaN(Number(val));\n\nexport const getTimestampParts = (timestamp) => {\n const date = newDate(timestamp);\n const year = date.getFullYear();\n const month = date.getMonth() + 1;\n const day = date.getDate();\n return [year, month, day];\n};\n\nexport const formatTimestamp = (timestamp, format) => {\n const [year, month, day] = getTimestampParts(timestamp);\n\n const parts = {\n DD: String(day).padStart(2, '0'),\n MM: String(month).padStart(2, '0'),\n YYYY: String(year),\n };\n\n return format.replace(/DD|MM|YYYY/g, (match) => parts[match]);\n};\n\n// polyfill for safari Date API (which doesn't accept \"YYYY-MM-DD\" string as value)\nexport const newDate = (date) => {\n if (typeof date === 'number') {\n return new Date(date);\n }\n if (typeof date === 'string') {\n return new Date(date.replace(/-/g, '/'));\n }\n return new Date();\n};\n\nexport const getCurrentTime = () => newDate().getTime();\nexport const getFullYear = (timestamp) => newDate(timestamp).getFullYear().toString();\nexport const getMonth = (timestamp) => (newDate(timestamp).getMonth() + 1).toString();\nexport const getCurrentDay = () => newDate().getDate();\nexport const getCurrentYear = () => newDate().getFullYear().toString();\n\n// Vaadin uses \"constructed stylesheet\" to hide the host in dialog components.\n// To override it, we need to push an overriding constructed stylesheet to the shadow DOM\n// opened issue in vaadin: https://github.com/vaadin/web-components/issues/7979\nexport const overrideConstructedStylesheet = (ele) => {\n const cs = new CSSStyleSheet();\n cs.insertRule(':host{display:block!important;}');\n ele?.shadowRoot?.adoptedStyleSheets?.push(cs);\n};\n\nexport const parseDateString = (val, format) => {\n const trimmed = val.trim?.();\n if (!trimmed) return null;\n return formats[format].getDate(trimmed);\n};\n","export const SUPPORTED_FORMATS = ['MM/DD/YYYY', 'DD/MM/YYYY', 'YYYY/MM/DD'];\n\nexport const DEFAULT_FORMAT = SUPPORTED_FORMATS[0];\n\nexport const NATIVE_FORMAT = 'YYYY-MM-DD';\n\nexport const YEARS_RANGE = 100;\n\nexport const DIVIDER = '/';\n\nexport const months = [\n 'January',\n 'February',\n 'March',\n 'April',\n 'May',\n 'June',\n 'July',\n 'August',\n 'September',\n 'October',\n 'November',\n 'December',\n];\n\nexport const weekdays = [\n 'Sunday',\n 'Monday',\n 'Tuesday',\n 'Wednesday',\n 'Thursday',\n 'Friday',\n 'Saturday',\n];\n\nexport const counterConfig = {\n MONTH: { id: 'month', min: 1, max: 12, placeholder: 'MM' },\n DAY: { id: 'day', min: 1, max: 31, placeholder: 'DD' },\n YEAR: { id: 'year', min: 0, max: 9999, placeholder: 'YYYY' },\n};\n\nexport const valRange = {\n year: { min: 1900, max: 2099 },\n};\n\nexport const BUTTON_LABEL_DONE = 'Done';\nexport const BUTTON_LABEL_CANCEL = 'Cancel';\nexport const CALENDAR_LABEL_TODAY = 'Today';\n\nexport const MOBILE_DEVICE_INTERACTION_TIMEOUT_MS = 150;\n","export const useHostExternalPadding = (cssVarList) => `\n :host {\n padding: calc(var(${cssVarList.inputOutlineWidth}) + var(${cssVarList.inputOutlineOffset}))\n }\n`;\n\nexport const resetInputFieldUnderlayingBorder = (name) => `\n ${name}::part(input-field)::after {\n border: none;\n }\n`;\n\nexport const resetInitialHeight = (name) => `\n ${name}::before {\n\t\theight: unset;\n\t}\n`;\n\nexport const resetInputElement = (name) => `\n ${name} > input {\n -webkit-mask-image: none;\n min-height: 0;\n box-sizing: border-box;\n }\n`;\n\nexport const resetInputContainer = (name) => `\n ${name} {\n margin: 0;\n padding: 0;\n width: 100%;\n height: 100%;\n box-sizing: border-box;\n }\n`;\n\nexport const resetInputField = (name) => `\n ${name}::part(input-field) {\n overflow: hidden;\n padding: 0;\n box-shadow: none;\n }\n`;\n\nexport const resetInputCursor = (name) => `\n ${name} > label,\n ${name}::part(label),\n ${name}::part(required-indicator) {\n cursor: pointer;\n }\n`;\n\nexport const resetInputPlaceholder = (name, ele = 'input') => `\n ${name}[disabled] > ${ele}:placeholder-shown,\n\t${name}[readonly] > ${ele}:placeholder-shown {\n\t\topacity: 1;\n\t}\n`;\n\nexport const resetInputAutoFill = (name, cssVarList) => `\n ${name} input:-webkit-autofill,\n ${name} input:-webkit-autofill::first-line,\n ${name} input:-webkit-autofill:hover,\n ${name} input:-webkit-autofill:active,\n ${name} input:-webkit-autofill:focus {\n -webkit-text-fill-color: var(${cssVarList.inputValueTextColor});\n box-shadow: 0 0 0 var(${cssVarList.inputHeight}) var(${cssVarList.inputBackgroundColor}) inset;\n }\n`;\n\nexport const resetInputFieldDefaultWidth = () => `\n :host {\n --vaadin-field-default-width: auto;\n box-sizing: border-box;\n }\n`;\n\nexport const resetInputReadonlyStyle = (name) => `\n ${name}::part(input-field)::after {\n opacity: 0;\n }\n`;\n\nexport const resetInputFieldInvalidBackgroundColor = (name) => `\n ${name}::part(input-field)::after {\n background: none;\n }\n`;\n\nexport const resetInputOverrides = (name, cssVarList) => `\n ${resetInputContainer(name)}\n ${resetInputCursor(name)}\n ${resetInputPlaceholder(name)}\n ${resetInputField(name)}\n ${resetInputAutoFill(name, cssVarList)}\n ${resetInputFieldInvalidBackgroundColor(name)}\n ${resetInitialHeight(name)}\n ${resetInputElement(name)}\n ${resetInputFieldUnderlayingBorder(name)}\n`;\n\n// This function is used to support RTL correctly for input components.\n// It also fixes the error message to be displayed LTR since we currently\n// don't support RTL for error messages.\nexport const resetInputLabelPosition = (name) => `\n :host ::part(error-message) {\n direction: ltr;\n }\n :host([required]) ::part(required-indicator) {\n width: 1em;\n display: inline-flex;\n }\n :host([required]) ::part(required-indicator)::after {\n position: static;\n }\n :host([has-label]) ::part(label) {\n padding-right: 0;\n padding-bottom: 0;\n display: flex;\n width: 100%;\n }\n ${name} [slot=\"label\"] {\n max-width: calc(100% - 1em);\n overflow: hidden;\n text-overflow: ellipsis;\n padding-bottom: 0.5em;\n }\n`;\n\nexport const inputFloatingLabelStyle = () => {\n return `\n :host([label-type=\"floating\"]) {\n position: relative;\n }\n :host([label-type=\"floating\"][has-label]) > ::part(label) {\n z-index: 1;\n padding: 0;\n width: auto;\n }\n `;\n};\n","import { DIVIDER, SUPPORTED_FORMATS } from './consts';\nimport { newDate } from './helpers';\n\nconst patterns = {\n MM: '(0?[1-9]|1[0-2])',\n DD: '(0?[1-9]|[12][0-9]|3[01])',\n YYYY: '([0-9]{4})',\n};\n\nconst createPattern = (format) => {\n const pattern = format\n .split(DIVIDER)\n .map((part) => patterns[part])\n .join('\\\\D');\n\n return `^${pattern}$`;\n};\n\nconst createToValuesFn = (format) => {\n const order = format.split(DIVIDER);\n return (match) => {\n const values = {};\n order.forEach((part, index) => {\n values[part] = match[index + 1];\n });\n return [values.YYYY, values.MM, values.DD];\n };\n};\n\nconst createDate = (val, regexp, toValuesFn) => {\n const match = regexp.exec(val);\n if (!match) return null;\n const [year, month, day] = toValuesFn(match);\n return newDate([year, month, day].join(DIVIDER));\n};\n\nconst createFormat = (format) => {\n const pattern = createPattern(format);\n const toValuesFn = createToValuesFn(format);\n const regexp = new RegExp(pattern);\n\n return {\n pattern,\n validate: (val) => regexp.test(val),\n getDate: (val) => createDate(val, regexp, toValuesFn),\n };\n};\n\nexport const formats = Object.fromEntries(SUPPORTED_FORMATS.map((f) => [f, createFormat(f)]));\n","export const calendarIcon = `\n<svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M9 5H15V4.50468C15 4.21404 15.226 4 15.5047 4H16.4953C16.786 4 17 4.22595 17 4.50468V5H18.7568C19.3028 5 19.75 5.44725 19.75 5.99896V7.00104C19.75 7.55734 19.3053 8 18.7568 8H5.24317C4.69717 8 4.25 7.55275 4.25 7.00104V5.99896C4.25 5.44266 4.69466 5 5.24317 5H7V4.50468C7 4.21404 7.22596 4 7.50468 4H8.49532C8.78596 4 9 4.22595 9 4.50468V5ZM5.50468 9H6.49532C6.78596 9 7 9.22596 7 9.50468V10.4953C7 10.786 6.77404 11 6.49532 11H5.50468C5.21404 11 5 10.774 5 10.4953V9.50468C5 9.21404 5.22595 9 5.50468 9ZM8.50468 9H9.49532C9.78596 9 10 9.22596 10 9.50468V10.4953C10 10.786 9.77404 11 9.49532 11H8.50468C8.21404 11 8 10.774 8 10.4953V9.50468C8 9.21404 8.22596 9 8.50468 9ZM11.5047 9H12.4953C12.786 9 13 9.22596 13 9.50468V10.4953C13 10.786 12.774 11 12.4953 11H11.5047C11.214 11 11 10.774 11 10.4953V9.50468C11 9.21404 11.226 9 11.5047 9ZM5.50468 12H6.49532C6.78596 12 7 12.226 7 12.5047V13.4953C7 13.786 6.77404 14 6.49532 14H5.50468C5.21404 14 5 13.774 5 13.4953V12.5047C5 12.214 5.22595 12 5.50468 12ZM8.50468 12H9.49532C9.78596 12 10 12.226 10 12.5047V13.4953C10 13.786 9.77404 14 9.49532 14H8.50468C8.21404 14 8 13.774 8 13.4953V12.5047C8 12.214 8.22596 12 8.50468 12ZM11.5047 12H12.4953C12.786 12 13 12.226 13 12.5047V13.4953C13 13.786 12.774 14 12.4953 14H11.5047C11.214 14 11 13.774 11 13.4953V12.5047C11 12.214 11.226 12 11.5047 12ZM5.50468 15H6.49532C6.78596 15 7 15.226 7 15.5047V16.4953C7 16.786 6.77404 17 6.49532 17H5.50468C5.21404 17 5 16.774 5 16.4953V15.5047C5 15.214 5.22595 15 5.50468 15ZM8.50468 15H9.49532C9.78596 15 10 15.226 10 15.5047V16.4953C10 16.786 9.77404 17 9.49532 17H8.50468C8.21404 17 8 16.774 8 16.4953V15.5047C8 15.214 8.22596 15 8.50468 15ZM11.5047 15H12.4953C12.786 15 13 15.226 13 15.5047V16.4953C13 16.786 12.774 17 12.4953 17H11.5047C11.214 17 11 16.774 11 16.4953V15.5047C11 15.214 11.226 15 11.5047 15ZM14.5047 9H15.4953C15.786 9 16 9.22596 16 9.50468V10.4953C16 10.786 15.774 11 15.4953 11H14.5047C14.214 11 14 10.774 14 10.4953V9.50468C14 9.21404 14.226 9 14.5047 9ZM14.5047 12H15.4953C15.786 12 16 12.226 16 12.5047V13.4953C16 13.786 15.774 14 15.4953 14H14.5047C14.214 14 14 13.774 14 13.4953V12.5047C14 12.214 14.226 12 14.5047 12ZM14.5047 15H15.4953C15.786 15 16 15.226 16 15.5047V16.4953C16 16.786 15.774 17 15.4953 17H14.5047C14.214 17 14 16.774 14 16.4953V15.5047C14 15.214 14.226 15 14.5047 15ZM17.5047 15H18.4953C18.786 15 19 15.226 19 15.5047V16.4953C19 16.786 18.774 17 18.4953 17H17.5047C17.214 17 17 16.774 17 16.4953V15.5047C17 15.214 17.226 15 17.5047 15ZM5.50468 18H6.49532C6.78596 18 7 18.226 7 18.5047V19.4953C7 19.786 6.77404 20 6.49532 20H5.50468C5.21404 20 5 19.774 5 19.4953V18.5047C5 18.214 5.22595 18 5.50468 18ZM8.50468 18H9.49532C9.78596 18 10 18.226 10 18.5047V19.4953C10 19.786 9.77404 20 9.49532 20H8.50468C8.21404 20 8 19.774 8 19.4953V18.5047C8 18.214 8.22596 18 8.50468 18ZM11.5047 18H12.4953C12.786 18 13 18.226 13 18.5047V19.4953C13 19.786 12.774 20 12.4953 20H11.5047C11.214 20 11 19.774 11 19.4953V18.5047C11 18.214 11.226 18 11.5047 18ZM14.5047 18H15.4953C15.786 18 16 18.226 16 18.5047V19.4953C16 19.786 15.774 20 15.4953 20H14.5047C14.214 20 14 19.774 14 19.4953V18.5047C14 18.214 14.226 18 14.5047 18ZM17.5047 18H18.4953C18.786 18 19 18.226 19 18.5047V19.4953C19 19.786 18.774 20 18.4953 20H17.5047C17.214 20 17 19.774 17 19.4953V18.5047C17 18.214 17.226 18 17.5047 18ZM17.5047 12H18.4953C18.786 12 19 12.226 19 12.5047V13.4953C19 13.786 18.774 14 18.4953 14H17.5047C17.214 14 17 13.774 17 13.4953V12.5047C17 12.214 17.226 12 17.5047 12ZM17.5047 9H18.4953C18.786 9 19 9.22596 19 9.50468V10.4953C19 10.786 18.774 11 18.4953 11H17.5047C17.214 11 17 10.774 17 10.4953V9.50468C17 9.21404 17.226 9 17.5047 9Z\" fill=\"#808080\"/>\n</svg>\n`;\n\nexport const arrowRightIcon = `\n<svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M9.27283 6.78069C8.87912 6.34164 8.91587 5.66655 9.35492 5.27283C9.79397 4.87912 10.4691 4.91587 10.8628 5.35492C10.8628 5.35492 16.0022 10.9543 16.366 11.36C16.7298 11.7657 16.7298 12.2392 16.366 12.6448L10.8628 18.6451C10.4691 19.0841 9.79397 19.1209 9.35492 18.7272C8.91587 18.3334 8.87912 17.6584 9.27283 17.2193L14.1368 12L9.27283 6.78069Z\" fill=\"#808080\"/>\n</svg>`;\n\nexport const arrowLeftIcon = `<svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M14.7272 17.2193C15.1209 17.6584 15.0841 18.3334 14.6451 18.7272C14.206 19.1209 13.5309 19.0841 13.1372 18.6451C13.1372 18.6451 7.99776 13.0457 7.63399 12.64C7.27023 12.2343 7.27023 11.7608 7.63399 11.3552L13.1372 5.35492C13.5309 4.91587 14.206 4.87912 14.6451 5.27283C15.0841 5.66655 15.1209 6.34164 14.7272 6.78069L9.86322 12L14.7272 17.2193Z\" fill=\"#808080\"/>\n</svg>`;\n","import { months, weekdays } from '../consts';\nimport { getTimestampParts, newDate } from '../helpers';\n\nconst isValidAttrArr = (arr, count) =>\n Array.isArray(arr) && arr.length === count && arr.filter(Boolean).length === count;\n\nconst generateYearList = (range) => {\n const [start, end] = range;\n const years = [];\n\n for (let year = start; year <= end; year++) {\n years.push(year);\n }\n\n return years;\n};\n\nconst getMaxDaysInMonth = (year, month) => {\n return new Date(year, month, 0).getDate();\n};\n\nconst comboBoxItemTpl = ({ label, dataId, dataName }) => `\n\t<div class=\"combo-box-item\"\n\t\tdata-id=\"${dataId}\"\n\t\tdata-name=\"${dataName}\"\n\t>\n\t\t\t${label}\n\t</div>\n`;\n\nexport const createMonthView = (year, month, shortWeekdays) => {\n const daysInMonth = getMaxDaysInMonth(year, month);\n\n // Get day of the week (0 = Sunday, 1 = Monday, etc.)\n const firstDayOfMonth = new Date(year, month - 1, 1).getDay();\n\n let monthView = '<table>';\n\n // Add the table headers (days of the week)\n monthView += `<thead><tr>${shortWeekdays.reduce(\n (acc, d) => `${acc}<th><span class=\"weekday\">${d}</span></th>`,\n ''\n )}</tr></thead>`;\n\n monthView += '<tbody>';\n\n // Add empty cells for the days before the start of the month\n monthView += '<tr>';\n for (let i = 0; i < firstDayOfMonth; i++) {\n monthView += '<td></td>';\n }\n\n // Add days of the month\n let dayOfWeek = firstDayOfMonth;\n for (let i = 1; i <= daysInMonth; i++) {\n if (dayOfWeek === 7) {\n dayOfWeek = 0;\n monthView += '</tr><tr>';\n }\n\n monthView += `\n <td\n data-date-day=\"${i}\"\n class=\"day-entry\">\n <span class=\"day\" data-date-day=${i}>\n ${i}\n </span>\n </td>\n `;\n dayOfWeek++;\n }\n\n // Add empty cells for the days after the end of the month\n while (dayOfWeek < 7) {\n monthView += '<td></td>';\n dayOfWeek++;\n }\n\n monthView += '</tr></tbody></table>';\n\n return monthView;\n};\n\nexport const getYearOptions = (range) =>\n generateYearList(range)\n .map((item) => comboBoxItemTpl({ label: item, dataId: item, dataName: item }))\n .join('');\n\nexport const getMonthsOptions = (customMonths = months) =>\n customMonths\n .map((item, index) => comboBoxItemTpl({ label: item, dataId: index + 1, dataName: item }))\n .join('');\n\nexport const isViewVisible = (selectionTimestamp, previewTimestamp) => {\n const [previewYear, previewMonth] = getTimestampParts(previewTimestamp);\n const [selectedYear, selectedMonth] = getTimestampParts(selectionTimestamp);\n return selectedYear === previewYear && selectedMonth === previewMonth;\n};\n\nexport const createInputs = () => {\n const ele = document.createElement('span');\n\n ele.innerHTML = `\n <descope-combo-box\n label-type=\"static\"\n bordered=\"true\"\n item-label-path=\"data-name\"\n item-value-path=\"data-id\"\n class=\"month-input\"\n >\n ${getMonthsOptions()}\n </descope-combo-box>\n <descope-combo-box\n allow-custom-value=\"true\"\n label-type=\"static\"\n bordered=\"true\"\n item-label-path=\"data-name\"\n item-value-path=\"data-id\"\n class=\"year-input\"\n no-empty-value=\"true\"\n >\n </descope-combo-box>\n `;\n\n return ele;\n};\n\nexport const initComboBox = (input, onChange, onBlur) => {\n input.addEventListener('input', onChange);\n input.addEventListener('focusout', onBlur);\n return input;\n};\n\nexport const ensureMonthNamesArr = (attrVal) => {\n const monthArr = attrVal?.split(',');\n return isValidAttrArr(monthArr, 12) ? monthArr : months;\n};\n\nexport const ensureWeekdayNamesArr = (attrVal) => {\n const customWeekdayArr = attrVal?.split?.(',');\n const isCustomValid = isValidAttrArr(customWeekdayArr, 7);\n return isCustomValid ? customWeekdayArr : weekdays;\n};\n\nexport const ensureShortWeekdayNamesArr = (attrVal) => {\n const customShortWeekdays = attrVal;\n\n if (!attrVal || !isValidAttrArr(customShortWeekdays, 7)) {\n return weekdays.map((d) => d.substring(0, 3));\n }\n\n return customShortWeekdays.map((d) => d.substring(0, 3));\n};\n\nexport const truncateWeekdays = (arr) => arr.map((d) => d.substring(0, 3));\n\nexport const prevMonth = (timestamp) => {\n const date = newDate(timestamp);\n const month = date.getMonth();\n\n if (month === 0) {\n const year = date.getFullYear();\n date.setFullYear(year - 1);\n date.setMonth(11);\n } else {\n date.setMonth(month - 1);\n }\n\n return date;\n};\n\nexport const nextMonth = (timestamp) => {\n const date = newDate(timestamp);\n const month = date.getMonth();\n\n if (month === 11) {\n const year = date.getFullYear();\n date.setFullYear(year + 1);\n date.setMonth(0);\n } else {\n date.setMonth(month + 1);\n }\n\n return date;\n};\n","import { createBaseInputClass } from '../../../baseClasses/createBaseInputClass';\nimport { compose } from '../../../helpers';\nimport { forwardAttrs, getComponentName } from '../../../helpers/componentHelpers';\nimport { inputFloatingLabelStyle } from '../../../helpers/themeHelpers/resetHelpers';\nimport { componentNameValidationMixin, createStyleMixin, draggableMixin } from '../../../mixins';\nimport {\n getCurrentDay,\n getTimestampParts,\n isValidTimestamp,\n newDate,\n formatTimestamp,\n getCurrentTime,\n getFullYear,\n getMonth,\n} from '../helpers';\nimport { arrowLeftIcon, arrowRightIcon } from '../icons';\nimport {\n BUTTON_LABEL_CANCEL,\n BUTTON_LABEL_DONE,\n CALENDAR_LABEL_TODAY,\n NATIVE_FORMAT,\n YEARS_RANGE,\n} from '../consts';\nimport {\n createMonthView,\n createInputs,\n getMonthsOptions,\n getYearOptions,\n initComboBox,\n ensureMonthNamesArr,\n isViewVisible,\n ensureWeekdayNamesArr,\n truncateWeekdays,\n prevMonth,\n nextMonth,\n} from './helpers';\nimport { ButtonClass } from '@descope-ui/descope-button/class';\nimport { injectStyle } from '@descope-ui/common/components-helpers';\n\nexport const componentName = getComponentName('calendar');\n\nconst observedAttrs = [\n 'initial-value',\n 'initial-year',\n 'initial-month',\n 'years-range',\n 'calendar-months',\n 'calendar-weekdays',\n 'calendar-label-today',\n 'st-host-direction',\n 'disabled',\n 'full-width',\n];\n\nconst calendarUiAttrs = ['calendar-label-submit', 'calendar-label-cancel'];\n\nconst BaseInputClass = createBaseInputClass({ componentName, baseSelector: 'div' });\n\nclass RawCalendar extends BaseInputClass {\n static get observedAttributes() {\n return [].concat(BaseInputClass.observedAttributes || [], observedAttrs, calendarUiAttrs);\n }\n\n // preview state timestamp\n preview;\n\n // value timestamp\n timestamp;\n\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n <div>\n <nav class=\"nav top-nav\">\n <div class=\"nav-prev\">\n </div>\n <div class=\"selectors\"></div>\n <div class=\"nav-next\">\n </div>\n </nav>\n <div class=\"calendar\"></div>\n <nav class=\"nav bottom-nav\">\n <descope-button class=\"cancel-button\" variant=\"link\" mode=\"primary\">Cancel</descope-button>\n <descope-button class=\"submit-button\" variant=\"link\" mode=\"primary\" disabled=\"true\">Done</descope-button>\n </nav>\n </div>\n `;\n\n injectStyle(\n `\n :host {\n display: inline-block;\n box-sizing: border-box;\n max-width: 100%;\n user-select: none;\n -webkit-user-select: none;\n }\n\n :host ::slotted {\n padding: 0;\n }\n\n [data-toggle-calendar] {\n cursor: pointer;\n display: flex;\n align-self: center;\n z-index: 1;\n }\n\n [data-disabled=\"true\"] {\n pointer-events: none;\n }\n\n .calendar .day {\n display: flex;\n align-items: center;\n justify-content: center;\n }\n\n .nav {\n display: flex;\n align-items: center;\n box-sizing: border-box;\n }\n\n .selectors,\n .selectors span {\n display: flex;\n justify-content: center;\n }\n\n descope-button {\n padding: 0;\n ${ButtonClass.cssVarList.horizontalPadding}: 0;\n ${ButtonClass.cssVarList.verticalPadding}: 0;\n ${ButtonClass.cssVarList.outlineWidth}: 0;\n }\n\n .combo-box-item {\n display:flex;\n flex-direction: column;\n }\n\n ${inputFloatingLabelStyle()}\n `,\n this\n );\n }\n\n set value(val) {\n if (!val) return;\n\n const timestamp = newDate(val).getTime();\n\n if (!isValidTimestamp(timestamp) || timestamp === this.timestmap) {\n return;\n }\n\n this.timestamp = timestamp;\n\n this.renderCalendar();\n }\n\n get value() {\n return this.timestamp ? formatTimestamp(this.timestamp, NATIVE_FORMAT) : '';\n }\n\n get isSelectedView() {\n return isViewVisible(this.preview, this.timestamp);\n }\n\n get isTodayView() {\n return isViewVisible(getCurrentTime(), this.preview);\n }\n\n get monthNames() {\n return ensureMonthNamesArr(this.getAttribute('calendar-months'));\n }\n\n get weekdayNames() {\n return ensureWeekdayNamesArr(this.getAttribute('calendar-weekdays'));\n }\n\n get hasYearValue() {\n return !!this.yearInput.value;\n }\n\n get hasMonthValue() {\n return !!this.monthInput.value;\n }\n\n get yearsRange() {\n const range = this.getAttribute('years-range')?.split('-');\n\n if (range?.length === 2) {\n const [start, end] = range.map(Number);\n if (start <= end) return [start, end];\n }\n\n const currentYear = newDate().getFullYear();\n\n return [currentYear, currentYear + YEARS_RANGE];\n }\n\n init() {\n super.init?.();\n this.initCalendar();\n this.renderCalendar();\n }\n\n initCalendar() {\n this.calendar = this.shadowRoot.querySelector('.calendar');\n\n this.navPrevEle = this.shadowRoot.querySelector('.nav-prev');\n this.navNextEle = this.shadowRoot.querySelector('.nav-next');\n this.submitButton = this.shadowRoot.querySelector('.submit-button');\n this.cancelButton = this.shadowRoot.querySelector('.cancel-button');\n\n this.initInputs();\n this.initNav();\n\n this.addEventListener('day-changed', () => this.submitButton.removeAttribute('disabled'));\n // This is a workaround for descope-components inside Vaadin's Popover component.\n // When we sync attributes, the `disabled` attribute is being compared to the attribute\n // on Vaadin component; since the Vaadin component has no `disabled` attribute, we sync\n // that back to our component. This happens when using Popover, and for specific attributes,\n // namely `disabled`. This is pending a more generic fix in the way we sync attibutes.\n this.submitButton.shadowRoot.querySelector('vaadin-button').setAttribute('disabled', 'true');\n }\n\n initInputs() {\n const ele = createInputs(this.monthNames, this.yearsRange);\n this.shadowRoot.querySelector('.selectors').appendChild(ele);\n\n this.monthInput = initComboBox(\n this.shadowRoot.querySelector('.month-input'),\n this.onMonthChange.bind(this),\n this.onMonthInputBlur.bind(this)\n );\n\n this.yearInput = initComboBox(\n this.shadowRoot.querySelector('.year-input'),\n this.onYearChange.bind(this),\n this.onYearInputBlur.bind(this)\n );\n\n [this.monthInput, this.yearInput].forEach((selector) =>\n forwardAttrs(this, selector, {\n includeAttrs: ['disabled', 'size', 'st-host-direction'],\n })\n );\n }\n\n initNav() {\n this.navPrevEle.addEventListener('click', this.navPrevMonth.bind(this));\n this.navNextEle.addEventListener('click', this.navNextMonth.bind(this));\n this.cancelButton.addEventListener('click', this.onCancel.bind(this));\n this.submitButton.addEventListener('click', this.onSubmit.bind(this));\n\n [this.navPrevEle, this.navNextEle].forEach((btn) =>\n forwardAttrs(this, btn, {\n includeAttrs: ['size'],\n })\n );\n\n this.shadowRoot.querySelector('.nav-next').innerHTML = arrowRightIcon;\n this.shadowRoot.querySelector('.nav-prev').innerHTML = arrowLeftIcon;\n }\n\n onSubmit() {\n if (this.isDisabled) return;\n if (!this.value) return;\n this.dispatchEvent(new CustomEvent('date-submit', { detail: newDate(this.preview) }));\n }\n\n onCancel() {\n if (this.isDisabled) return;\n this.dispatchEvent(new CustomEvent('cancel'));\n this.dispatchEvent(new CustomEvent('date-cancel'));\n this.clearSelectedDay();\n }\n\n clearSelectedDay() {\n this.getSelectedDayEle()?.removeAttribute('data-selected');\n this.submitButton.setAttribute('disabled', 'true');\n this.timestamp = '';\n }\n\n updateInputs() {\n if (this.yearInput && this.monthInput) {\n const timestamp = this.preview || getCurrentTime();\n const year = getFullYear(timestamp);\n const month = getMonth(timestamp);\n this.monthInput.value = month;\n // For the yearInput we update the base element directly to properly trigger the change event\n // since this can be a custom value\n setTimeout(() => {\n this.yearInput.baseElement.value = year;\n });\n }\n }\n\n renderCalendar() {\n const date = newDate(this.preview || getCurrentTime());\n const timestamp = date.getTime();\n\n const [year, month] = getTimestampParts(timestamp);\n\n if (this.calendar) {\n this.calendar.innerHTML = createMonthView(year, month, truncateWeekdays(this.weekdayNames));\n }\n\n Array.from(this.calendar?.querySelectorAll('.day-entry .day') || []).forEach((ele) =>\n ele.addEventListener('click', this.onDayChange.bind(this))\n );\n\n this.updateInputs();\n this.setSelectedDay();\n this.setCurrentDay();\n }\n\n onDayChange(e) {\n if (this.isDisabled) return;\n const date = newDate(this.preview);\n date.setDate(Number(e.target.getAttribute('data-date-day')));\n this.value = formatTimestamp(date.getTime(), NATIVE_FORMAT);\n this.dispatchEvent(new CustomEvent('day-changed', { detail: date }));\n }\n\n onYearChange(e) {\n if (!e.target.value) return;\n const date = newDate(this.preview);\n date.setFullYear(Number(e.target.value.trim()));\n this.preview = date.getTime();\n this.renderCalendar();\n this.dispatchEvent(new CustomEvent('year-changed', { detail: date }));\n }\n\n onMonthChange(e) {\n if (!e.target.value) return;\n const date = newDate(this.preview);\n date.setMonth(Number(e.target.value) - 1);\n this.preview = date.getTime();\n this.renderCalendar();\n this.dispatchEvent(new CustomEvent('month-changed', { detail: date }));\n }\n\n onYearInputBlur(e) {\n this.yearInput.baseElement.value = e.target.value || getFullYear(this.preview);\n }\n\n onMonthInputBlur(e) {\n this.monthInput.baseElement.value = e.target.value || getMonth(this.preview);\n }\n\n getSelectedDayEle() {\n const day = newDate(this.timestamp).getDate();\n return this.calendar?.querySelector(`[data-date-day=\"${day}\"]`);\n }\n\n getCurrentDayEle() {\n return this.calendar?.querySelector(`[data-date-day=\"${getCurrentDay()}\"]`);\n }\n\n clearSelectedDays() {\n const cells = this.calendar?.querySelectorAll(`[data-selected]`);\n if (!cells) return;\n cells.forEach((c) => c.removeAttribute('data-selected'));\n }\n\n setSelectedDay() {\n this.clearSelectedDays();\n if (this.value && this.isSelectedView) {\n this.getSelectedDayEle().setAttribute('data-selected', 'true');\n }\n }\n\n setCurrentDay() {\n if (this.isTodayView) {\n const ele = this.getCurrentDayEle();\n const title = this.getAttribute('calendar-label-today') || CALENDAR_LABEL_TODAY;\n ele.setAttribute('data-current-day', 'true');\n ele.setAttribute('title', title);\n }\n }\n\n navPrevMonth() {\n if (this.isDisabled) {\n return;\n }\n const date = prevMonth(this.preview);\n this.preview = date.getTime();\n this.renderCalendar();\n }\n\n navNextMonth() {\n if (this.isDisabled) {\n return;\n }\n const date = nextMonth(this.preview);\n this.preview = date.getTime();\n this.renderCalendar();\n }\n\n clearValue() {\n this.timestamp = '';\n this.value = '';\n this.removeAttribute('preview');\n this.submitButton.setAttribute('disabled', 'true');\n }\n\n onInitialValueChange(newValue) {\n // if component already has a value don't re-set value\n if (this.value) {\n return;\n }\n\n const date = newDate(newValue);\n const timestamp = date.getTime();\n\n if (isValidTimestamp(timestamp)) {\n this.timestamp = timestamp;\n this.preview = timestamp;\n } else {\n this.clearValue();\n }\n }\n\n onYearsRangeChange() {\n setTimeout(() => {\n if (this.yearInput) {\n this.yearInput.innerHTML = getYearOptions(this.yearsRange);\n }\n });\n }\n\n onMonthNamesChange() {\n setTimeout(() => {\n if (this.monthInput) {\n this.monthInput.innerHTML = getMonthsOptions(this.monthNames);\n }\n });\n }\n\n onSubmitLabelChange(newValue) {\n if (this.submitButton) {\n this.submitButton.textContent = newValue || BUTTON_LABEL_DONE;\n }\n }\n\n onCancelLabelChange(newValue) {\n if (this.cancelButton) {\n this.cancelButton.textContent = newValue || BUTTON_LABEL_CANCEL;\n }\n }\n\n onInitialMonthChange(val) {\n const currYear = getFullYear(this.preview);\n this.preview = newDate(`${currYear}/${val}/1`).getTime();\n }\n\n onInitialYearChange(val) {\n const currMonth = getMonth(this.preview);\n this.preview = newDate(`${val}/${currMonth}/1`).getTime();\n }\n\n attributeChangedCallback(attrName, oldValue, newValue) {\n super.attributeChangedCallback(attrName, oldValue, newValue);\n if (oldValue !== newValue) {\n // attrs for which affect static ui parts doesn't require calendar re-render\n if (calendarUiAttrs.includes(attrName)) {\n if (attrName === 'calendar-label-submit') {\n this.onSubmitLabelChange(newValue);\n }\n if (attrName === 'calendar-label-cancel') {\n this.onCancelLabelChange(newValue);\n }\n } else {\n // we want to render the calendar for each of these attr change\n\n if (newValue && attrName === 'initial-value') {\n this.onInitialValueChange(newValue);\n }\n if (newValue && attrName === 'initial-month') {\n this.onInitialMonthChange(newValue);\n }\n if (newValue && attrName === 'initial-year') {\n this.onInitialYearChange(newValue);\n }\n if (attrName === 'years-range') {\n this.onYearsRangeChange(Number(newValue));\n }\n if (attrName === 'calendar-months') {\n this.onMonthNamesChange();\n }\n if (attrName === 'calendar-label-today') {\n this.setCurrentDay(newValue);\n }\n if (attrName === 'disabled') {\n setTimeout(() => {\n this.cancelButton?.setAttribute('disabled', newValue === 'true');\n });\n }\n\n this.renderCalendar();\n }\n }\n }\n\n getValidity() {\n if (this.isRequired && !this.value) {\n return { valueMissing: true };\n }\n return {};\n }\n}\n\nconst {\n calendar,\n day,\n dayEntry,\n currentDay,\n selectedDay,\n disabledDay,\n weekday,\n topNav,\n topNavSelectors,\n bottomNav,\n navPrev,\n navNext,\n navPrevRTL,\n navNextRTL,\n yearInput,\n monthInput,\n} = {\n calendar: { selector: () => '.calendar' },\n topNav: { selector: () => '.nav.top-nav' },\n topNavSelectors: { selector: () => '.nav.top-nav .selectors > span' },\n bottomNav: { selector: () => '.nav.bottom-nav' },\n day: { selector: () => '.day' },\n dayEntry: { selector: () => '.day-entry' },\n currentDay: { selector: () => '.day-entry[data-current-day] .day' },\n selectedDay: { selector: () => '.day-entry[data-selected] .day' },\n disabledDay: { selector: () => '.day-entry[data-disabled=\"true\"] .day' },\n weekday: { selector: () => '.weekday' },\n navPrev: { selector: () => '.nav-prev' },\n navNext: { selector: () => '.nav-next' },\n navPrevRTL: { selector: () => ':host([st-host-direction=\"rtl\"]) .nav-prev' },\n navNextRTL: { selector: () => ':host([st-host-direction=\"rtl\"]) .nav-next' },\n yearInput: { selector: () => '.year-input' },\n monthInput: { selector: () => '.month-input' },\n};\n\nexport const CalendarClass = compose(\n createStyleMixin({ componentNameOverride: getComponentName('input-wrapper') }),\n createStyleMixin({\n mappings: {\n fontSize: {},\n fontFamily: {},\n hostWidth: [\n { selector: () => ':host', property: 'width' },\n { selector: 'table', property: 'width' },\n ],\n hostDirection: { property: 'direction' },\n\n topNavVerticalPadding: [\n { ...topNav, property: 'padding-top' },\n { ...topNav, property: 'padding-bottom' },\n ],\n topNavHorizointalPadding: [\n { ...topNav, property: 'padding-right' },\n { ...topNav, property: 'padding-left' },\n ],\n topNavAlignment: { ...topNav, property: 'justify-content' },\n topNavGap: { ...topNav, property: 'gap' },\n topNavSelectorsGap: { ...topNavSelectors, property: 'gap' },\n\n bottomNavVerticalPadding: [\n { ...bottomNav, property: 'padding-top' },\n { ...bottomNav, property: 'padding-bottom' },\n ],\n bottomNavHorizontalPadding: [\n { ...bottomNav, property: 'padding-right' },\n { ...bottomNav, property: 'padding-left' },\n ],\n bottomNavAlignment: { ...bottomNav, property: 'justify-content' },\n bottomNavGap: { ...bottomNav, property: 'gap' },\n\n navMarginBottom: { ...topNav, property: 'margin-bottom' },\n\n calendarPadding: [\n { ...calendar, property: 'padding-bottom' },\n { ...calendar, property: 'padding-right' },\n { ...calendar, property: 'padding-left' },\n ],\n\n navBorderBottomWidth: { ...topNav, property: 'border-bottom-width' },\n navBorderBottomColor: { ...topNav, property: 'border-bottom-color' },\n navBorderBottomStyle: { ...topNav, property: 'border-bottom-style' },\n\n weekdayFontSize: { ...weekday, property: 'font-size' },\n weekdayFontWeight: { ...weekday, property: 'font-weight' },\n\n currentDayBorderColor: {\n ...currentDay,\n property: 'border-color',\n },\n currentDayBorderWidth: {\n ...currentDay,\n property: 'border-width',\n },\n currentDayBorderStyle: {\n ...currentDay,\n property: 'border-style',\n },\n\n dayHeight: { ...dayEntry, property: 'height' },\n daySize: [\n { ...day, property: 'height' },\n { ...day, property: 'width' },\n ],\n dayPadding: { ...day, property: 'padding' },\n dayRadius: { ...day, property: 'border-radius' },\n dayTextAlign: { ...day, property: 'text-align' },\n dayBlockAlign: { ...day, property: 'margin' },\n dayTextColor: { ...day, property: 'color' },\n dayFontWeight: { ...day, property: 'font-weight' },\n dayBackgroundColor: { ...day, property: 'background-color' },\n dayCursor: { ...day, property: 'cursor' },\n dayFontSize: { ...day, property: 'font-size' },\n\n dayBackgroundColorHover: {\n selector: () => '.day:hover',\n property: 'background-color',\n },\n\n daySelectedTextdColor: {\n ...selectedDay,\n property: 'color',\n },\n daySelectedBackgroundColor: {\n ...selectedDay,\n property: 'background-color',\n },\n dayDisabledTextdColor: {\n ...disabledDay,\n property: 'color',\n },\n\n yearInputWidth: { ...yearInput, property: 'width' },\n monthInputWidth: { ...monthInput, property: 'width' },\n\n navButtonSize: [\n { ...navPrev, property: 'width' },\n { ...navPrev, property: 'height' },\n { ...navNext, property: 'width' },\n { ...navNext, property: 'height' },\n ],\n navButtonCursor: [\n { ...navPrev, property: 'cursor' },\n { ...navNext, property: 'cursor' },\n ],\n navButtonRotation: [\n { ...navPrevRTL, property: 'transform' },\n { ...navNextRTL, property: 'transform' },\n ],\n navButtonOpacity: [\n { ...navPrev, property: 'opacity' },\n { ...navNext, property: 'opacity' },\n ],\n },\n }),\n draggableMixin,\n componentNameValidationMixin\n)(RawCalendar);\n","import '@descope-ui/descope-combo-box';\nimport '@descope-ui/descope-button';\n\nimport { componentName, CalendarClass } from './CalendarClass';\n\ncustomElements.define(componentName, CalendarClass);\n\nexport { CalendarClass, componentName };\n","import {\n componentNameValidationMixin,\n createProxy,\n createStyleMixin,\n draggableMixin,\n} from '@descope-ui/common/components-mixins';\nimport { getComponentName } from '@descope-ui/common/components-helpers';\nimport { compose } from '@descope-ui/common/utils';\n\nexport const componentName = getComponentName('icon');\n\nexport const IconClass = compose(\n createStyleMixin({\n mappings: {\n fill: {},\n },\n }),\n draggableMixin,\n componentNameValidationMixin,\n)(\n createProxy({\n slots: [],\n wrappedEleName: 'descope-image',\n style: () => `\n :host {\n display: inline-flex;\n }\n `,\n excludeAttrsSync: ['tabindex', 'class'],\n componentName,\n }),\n);\n"],"names":["createBaseInputClass","args","clickableMixin","superclass","isLoading","this","getAttribute","click","super","componentName","host","label","slottedIcon","selector","loadingIndicatorStyles","ButtonClass","mappings","hostWidth","property","hostHeight","hostDirection","fontSize","fontFamily","cursor","backgroundColor","outlineOffset","outlineColor","outlineStyle","outlineWidth","borderRadius","borderColor","borderStyle","borderWidth","verticalPadding","horizontalPadding","fallback","labelTextColor","iconColor","cssVarList","fill","labelTextDecoration","labelSpacing","textAlign","iconSize","slots","wrappedEleName","style","excludeAttrsSync","color","customElements","define","isValidTimestamp","val","Number","isNaN","isNumber","String","trim","getTimestampParts","timestamp","date","newDate","getFullYear","getMonth","getDate","formatTimestamp","format","year","month","day","parts","DD","padStart","MM","YYYY","replace","match","Date","getCurrentTime","getTime","toString","getCurrentDay","overrideConstructedStylesheet","ele","cs","CSSStyleSheet","insertRule","shadowRoot","adoptedStyleSheets","push","parseDateString","trimmed","SUPPORTED_FORMATS","DEFAULT_FORMAT","NATIVE_FORMAT","YEARS_RANGE","DIVIDER","months","weekdays","counterConfig","MONTH","id","min","max","placeholder","DAY","YEAR","valRange","BUTTON_LABEL_DONE","BUTTON_LABEL_CANCEL","CALENDAR_LABEL_TODAY","MOBILE_DEVICE_INTERACTION_TIMEOUT_MS","useHostExternalPadding","inputOutlineWidth","inputOutlineOffset","resetInputContainer","name","resetInputField","resetInputCursor","resetInputPlaceholder","resetInputFieldDefaultWidth","resetInputReadonlyStyle","resetInputFieldInvalidBackgroundColor","resetInputOverrides","inputValueTextColor","inputHeight","inputBackgroundColor","resetInputAutoFill","resetInitialHeight","resetInputElement","resetInputFieldUnderlayingBorder","resetInputLabelPosition","inputFloatingLabelStyle","patterns","createFormat","pattern","split","map","part","join","createPattern","toValuesFn","order","values","forEach","index","createToValuesFn","regexp","RegExp","validate","test","exec","createDate","formats","Object","fromEntries","f","calendarIcon","arrowRightIcon","arrowLeftIcon","isValidAttrArr","arr","count","Array","isArray","length","filter","Boolean","comboBoxItemTpl","dataId","dataName","getMonthsOptions","customMonths","item","isViewVisible","selectionTimestamp","previewTimestamp","previewYear","previewMonth","selectedYear","selectedMonth","initComboBox","input","onChange","onBlur","addEventListener","observedAttrs","calendarUiAttrs","BaseInputClass","baseSelector","calendar","dayEntry","currentDay","selectedDay","disabledDay","weekday","topNav","topNavSelectors","bottomNav","navPrev","navNext","navPrevRTL","navNextRTL","yearInput","monthInput","CalendarClass","componentNameOverride","topNavVerticalPadding","topNavHorizointalPadding","topNavAlignment","topNavGap","topNavSelectorsGap","bottomNavVerticalPadding","bottomNavHorizontalPadding","bottomNavAlignment","bottomNavGap","navMarginBottom","calendarPadding","navBorderBottomWidth","navBorderBottomColor","navBorderBottomStyle","weekdayFontSize","weekdayFontWeight","currentDayBorderColor","currentDayBorderWidth","currentDayBorderStyle","dayHeight","daySize","dayPadding","dayRadius","dayTextAlign","dayBlockAlign","dayTextColor","dayFontWeight","dayBackgroundColor","dayCursor","dayFontSize","dayBackgroundColorHover","daySelectedTextdColor","daySelectedBackgroundColor","dayDisabledTextdColor","yearInputWidth","monthInputWidth","navButtonSize","navButtonCursor","navButtonRotation","navButtonOpacity","observedAttributes","concat","preview","constructor","attachShadow","mode","innerHTML","value","timestmap","renderCalendar","isSelectedView","isTodayView","monthNames","attrVal","monthArr","ensureMonthNamesArr","weekdayNames","customWeekdayArr","ensureWeekdayNamesArr","hasYearValue","hasMonthValue","yearsRange","range","start","end","currentYear","init","initCalendar","querySelector","navPrevEle","navNextEle","submitButton","cancelButton","initInputs","initNav","removeAttribute","setAttribute","document","createElement","createInputs","appendChild","onMonthChange","bind","onMonthInputBlur","onYearChange","onYearInputBlur","includeAttrs","navPrevMonth","navNextMonth","onCancel","onSubmit","btn","isDisabled","dispatchEvent","CustomEvent","detail","clearSelectedDay","getSelectedDayEle","updateInputs","setTimeout","baseElement","shortWeekdays","daysInMonth","getMaxDaysInMonth","firstDayOfMonth","getDay","monthView","reduce","acc","d","i","dayOfWeek","createMonthView","substring","from","querySelectorAll","onDayChange","setSelectedDay","setCurrentDay","e","setDate","target","setFullYear","setMonth","getCurrentDayEle","clearSelectedDays","cells","c","title","prevMonth","nextMonth","clearValue","onInitialValueChange","newValue","onYearsRangeChange","years","generateYearList","onMonthNamesChange","onSubmitLabelChange","textContent","onCancelLabelChange","onInitialMonthChange","currYear","onInitialYearChange","currMonth","attributeChangedCallback","attrName","oldValue","includes","getValidity","isRequired","valueMissing","IconClass"],"sourceRoot":""}
1
+ {"version":3,"file":"descope-date-field-descope-calendar-index-js.js","mappings":"6LASO,MAAMA,EAAuB,IAAIC,KACtC,QACE,KACA,KACA,KACA,KAJF,EAKE,UAAmBA,G,qGCHhB,MAAMC,GAAgB,QAAiB,SAExCC,EAAW,CAAC,MAAO,YAEzB,MAAMC,WAAiB,QAAgB,C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aAAbF,GACF6T,YAAW,KACT9V,KAAKuU,cAAchT,aAAa,WAAyB,SAAbY,EAAoB,IAIpEnC,KAAKkT,kBAGX,CAEA,WAAAyF,GACE,OAAI3Y,KAAK4Y,aAAe5Y,KAAKgT,MACpB,CAAE6F,cAAc,GAElB,CAAC,CACV,IC9fFjS,eAAeC,OAAOpH,EAAe2Q,E,0FCK9B,MAAM3Q,GAAgB,QAAiB,QAEjCqZ,GAAY,SACvB,QAAiB,CACf1W,SAAU,CACRV,KAAM,CAAC,CAAC,EAAG,CAAEsD,SAAU,IAAWvD,WAAWC,UAGjD,KACA,KAPuB,EASvB,QAAY,CACV8E,MAAO,GACPC,eAAgB,gBAChBjC,MAAO,IAAM,kEAKbkC,iBAAkB,CAAC,WAAY,SAC/BjH,kB","sources":["webpack://@descope/web-components-ui/./src/baseClasses/createBaseInputClass.js","webpack://@descope/web-components-ui/../components/descope-image/src/component/ImageClass.js","webpack://@descope/web-components-ui/../components/descope-button/src/component/clickableMixin.js","webpack://@descope/web-components-ui/../components/descope-image/src/component/helpers.js","webpack://@descope/web-components-ui/../components/descope-button/src/component/ButtonClass.js","webpack://@descope/web-components-ui/../components/descope-button/src/component/index.js","webpack://@descope/web-components-ui/./src/components/descope-date-field/helpers.js","webpack://@descope/web-components-ui/./src/components/descope-date-field/consts.js","webpack://@descope/web-components-ui/./src/helpers/themeHelpers/resetHelpers.js","webpack://@descope/web-components-ui/./src/components/descope-date-field/formats.js","webpack://@descope/web-components-ui/./src/components/descope-date-field/icons.js","webpack://@descope/web-components-ui/./src/components/descope-date-field/descope-calendar/helpers.js","webpack://@descope/web-components-ui/./src/components/descope-date-field/descope-calendar/CalendarClass.js","webpack://@descope/web-components-ui/./src/components/descope-date-field/descope-calendar/index.js","webpack://@descope/web-components-ui/../components/descope-icon/src/component/IconClass.js"],"sourcesContent":["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","/* eslint-disable no-use-before-define */\nimport {\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 { getComponentName } from '@descope-ui/common/components-helpers';\nimport { createImage } from './helpers';\nimport { injectStyle } from '@descope-ui/common/components-helpers';\n\nexport const componentName = getComponentName('image');\n\nconst srcAttrs = ['src', 'src-dark'];\n\nclass RawImage extends createBaseClass({\n componentName,\n baseSelector: 'slot',\n}) {\n static get observedAttributes() {\n return srcAttrs;\n }\n\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n\t\t<slot></slot>\n\t`;\n\n injectStyle(\n `\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 `,\n this,\n );\n }\n\n init() {\n super.init?.();\n this.toggleVisibility(this.src);\n }\n\n onThemeChange() {\n this.renderImage();\n }\n\n toggleVisibility(isVisible) {\n if (isVisible) {\n this.classList.remove('hidden');\n } else {\n this.classList.add('hidden');\n }\n }\n\n get altText() {\n return this.getAttribute('alt') || '';\n }\n\n get legacySrc() {\n return this.getAttribute('src');\n }\n\n get themeSrc() {\n return this.getAttribute(`src-${this.currentThemeName}`);\n }\n\n get src() {\n return this.themeSrc || this.legacySrc;\n }\n\n // in order to fill an SVG with `currentColor` override all of its `fill` and `path` nodes\n // with the value from the `st-fill` attribute\n // eslint-disable-next-line class-methods-use-this\n updateFillColor(node) {\n // set fill to root node and all its relevant selectors\n const elementsToReplace = [node, ...node.querySelectorAll('*[fill]')];\n\n elementsToReplace.forEach((ele) => {\n ele.setAttribute(\n 'fill',\n `var(${ImageClass.cssVarList.fill}, ${ele.getAttribute('fill') || \"''\"})`,\n );\n });\n }\n\n renderImage() {\n this.toggleVisibility(this.src);\n\n createImage(this.src, this.altText).then((res) => {\n this.innerHTML = '';\n if (res) {\n this.updateFillColor(res);\n this.appendChild(res);\n }\n });\n }\n\n // render only when src attribute matches current theme\n shouldRender(src) {\n const srcVal = this.getAttribute(src);\n return this.src === srcVal;\n }\n\n attributeChangedCallback(attrName, oldValue, newValue) {\n super.attributeChangedCallback?.(attrName, oldValue, newValue);\n\n if (oldValue === newValue) return;\n\n if (this.shouldRender(attrName)) {\n this.renderImage();\n }\n }\n}\n\nexport const ImageClass = compose(\n createStyleMixin({\n mappings: {\n fill: {},\n height: { selector: () => ':host' },\n width: { selector: () => ':host' },\n },\n }),\n draggableMixin,\n componentNameValidationMixin,\n)(RawImage);\n","export const clickableMixin = (superclass) =>\n class ClickableMixinClass extends superclass {\n get isLoading() {\n return this.getAttribute('loading') === 'true';\n }\n\n click() {\n this.isLoading || super.click();\n }\n };\n","import DOMPurify from 'dompurify';\n\nconst getFileExtension = (path) => {\n const match = path.match(/\\.([0-9a-z]+)(?:[\\\\?#]|$)/i);\n return match ? match[1] : null;\n};\n\nconst base64Prefix = 'data:image/svg+xml;base64,';\n\nconst isBase64Svg = (src) => src.startsWith(base64Prefix);\n\nconst createImgEle = (src, altText) => {\n const ele = document.createElement('img');\n ele.setAttribute('src', src);\n ele.setAttribute('alt', altText);\n return ele;\n};\n\nconst createSvgEle = (text) => {\n // we want to purify the SVG to avoid XSS attacks\n const clean = DOMPurify.sanitize(text, {\n USE_PROFILES: { svg: true, svgFilters: true },\n // allow image to render\n ADD_TAGS: ['image'],\n // forbid interactiviy via `use` tags (which are sanitized by default)\n FORBID_TAGS: ['defs']\n });\n\n const parser = new DOMParser();\n const ele = parser\n .parseFromString(clean, 'image/svg+xml')\n .querySelector('svg');\n return ele;\n};\n\nexport const createImage = async (src, altText) => {\n try {\n let ele;\n if (isBase64Svg(src)) {\n // handle base64 source\n const svgXml = atob(src.slice(base64Prefix.length));\n ele = createSvgEle(svgXml);\n } else if (getFileExtension(src) === 'svg') {\n // handle urls\n const fetchedSrc = await fetch(src);\n const text = await fetchedSrc.text();\n ele = createSvgEle(text);\n } else {\n // handle binary\n ele = createImgEle(src, altText);\n }\n\n ele.style.setProperty('max-width', '100%');\n ele.style.setProperty('max-height', '100%');\n\n return ele;\n } catch {\n return null;\n }\n};\n","import { compose } from '@descope-ui/common/utils';\nimport { getComponentName } from '@descope-ui/common/components-helpers';\nimport {\n createStyleMixin,\n draggableMixin,\n createProxy,\n componentNameValidationMixin,\n} from '@descope-ui/common/components-mixins';\nimport { IconClass } from '@descope-ui/descope-icon/class';\nimport { clickableMixin } from './clickableMixin';\n\nexport const componentName = getComponentName('button');\n\nconst resetStyles = `\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\nconst iconStyles = `\n\tvaadin-button::part(prefix),\n\tvaadin-button::part(label) {\n\t\tdisplay: flex;\n\t\talign-items: center;\n\t}\n`;\n\nconst editorOverrides = `vaadin-button::part(label) { pointer-events: none; }`;\n\nconst { host, label, slottedIcon } = {\n host: { selector: () => ':host' },\n label: { selector: '::part(label)' },\n slottedIcon: { selector: () => '::slotted(descope-icon)' },\n};\n\nlet loadingIndicatorStyles;\n\nexport const ButtonClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { property: 'width' },\n hostHeight: { property: 'height' },\n hostDirection: { ...host, property: 'direction' },\n fontSize: {},\n fontFamily: {},\n\n cursor: {},\n backgroundColor: {},\n\n outlineOffset: {},\n outlineColor: {},\n outlineStyle: {},\n outlineWidth: {},\n\n borderRadius: {},\n borderColor: {},\n borderStyle: {},\n borderWidth: {},\n\n verticalPadding: [{ property: 'padding-top' }, { property: 'padding-bottom' }],\n horizontalPadding: [\n { property: 'padding-right', fallback: '0.875em' },\n { property: 'padding-left', fallback: '0.875em' },\n ],\n\n labelTextColor: { property: 'color' },\n iconColor: {\n\t\tselector: () => `::slotted(*)`,\n\t\tproperty: IconClass.cssVarList.fill\n\t },\n labelTextDecoration: { ...label, property: 'text-decoration' },\n labelSpacing: { ...label, property: 'gap' },\n textAlign: { ...label, property: 'justify-content', fallback: 'center' },\n\n iconSize: [\n { ...slottedIcon, property: 'width' },\n { ...slottedIcon, property: 'height' },\n ],\n },\n }),\n clickableMixin,\n draggableMixin,\n componentNameValidationMixin\n)(\n createProxy({\n slots: ['', 'prefix', 'label', 'suffix'],\n wrappedEleName: 'vaadin-button',\n style: () => `\n\t\t\t${resetStyles}\n\t\t\t${iconStyles}\n\t\t\t${loadingIndicatorStyles}\n\t\t\t${editorOverrides}\n\t\t\t:host {\n\t\t\t\tpadding: calc(var(${ButtonClass.cssVarList.outlineWidth}) + var(${ButtonClass.cssVarList.outlineOffset}));\n\t\t\t}\n :host([full-width=\"true\"]) {\n width: var(${ButtonClass.cssVarList.hostWidth});\n }\n\t\t\tvaadin-button {\n\t\t\t\theight: calc(var(${ButtonClass.cssVarList.hostHeight}) - var(${ButtonClass.cssVarList.outlineWidth}) - var(${ButtonClass.cssVarList.outlineOffset}));\n\t\t\t}\n\t\t\t[square=\"true\"]:not([full-width=\"true\"]) {\n\t\t\t\twidth: calc(var(${ButtonClass.cssVarList.hostWidth}) - var(${ButtonClass.cssVarList.outlineWidth}) - var(${ButtonClass.cssVarList.outlineOffset}));\n padding: 0;\n\t\t\t}\n\t\t`,\n excludeAttrsSync: ['tabindex'],\n componentName,\n })\n);\n\nconst { color, fontSize } = ButtonClass.cssVarList;\nloadingIndicatorStyles = `\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(${color});\n\t\ttop: calc(50% - (var(${fontSize}) / 2));\n\t\tleft: calc(50% - (var(${fontSize}) / 2));\n\t\tborder-width: calc(var(${fontSize}) / 10);\n\t\twidth: var(${fontSize});\n\t\theight: var(${fontSize});\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`;\n","import { componentName, ButtonClass } from './ButtonClass';\nimport '@vaadin/button';\n\ncustomElements.define(componentName, ButtonClass);\n\nexport { ButtonClass, componentName };\n","import { formats } from './formats';\n\nexport const isValidTimestamp = (val) => !Number.isNaN(Number(val));\n\nexport const isNumber = (val) => !!String(val || '').trim() && !Number.isNaN(Number(val));\n\nexport const getTimestampParts = (timestamp) => {\n const date = newDate(timestamp);\n const year = date.getFullYear();\n const month = date.getMonth() + 1;\n const day = date.getDate();\n return [year, month, day];\n};\n\nexport const formatTimestamp = (timestamp, format) => {\n const [year, month, day] = getTimestampParts(timestamp);\n\n const parts = {\n DD: String(day).padStart(2, '0'),\n MM: String(month).padStart(2, '0'),\n YYYY: String(year),\n };\n\n return format.replace(/DD|MM|YYYY/g, (match) => parts[match]);\n};\n\n// polyfill for safari Date API (which doesn't accept \"YYYY-MM-DD\" string as value)\nexport const newDate = (date) => {\n if (typeof date === 'number') {\n return new Date(date);\n }\n if (typeof date === 'string') {\n return new Date(date.replace(/-/g, '/'));\n }\n return new Date();\n};\n\nexport const getCurrentTime = () => newDate().getTime();\nexport const getFullYear = (timestamp) => newDate(timestamp).getFullYear().toString();\nexport const getMonth = (timestamp) => (newDate(timestamp).getMonth() + 1).toString();\nexport const getCurrentDay = () => newDate().getDate();\nexport const getCurrentYear = () => newDate().getFullYear().toString();\n\n// Vaadin uses \"constructed stylesheet\" to hide the host in dialog components.\n// To override it, we need to push an overriding constructed stylesheet to the shadow DOM\n// opened issue in vaadin: https://github.com/vaadin/web-components/issues/7979\nexport const overrideConstructedStylesheet = (ele) => {\n const cs = new CSSStyleSheet();\n cs.insertRule(':host{display:block!important;}');\n ele?.shadowRoot?.adoptedStyleSheets?.push(cs);\n};\n\nexport const parseDateString = (val, format) => {\n const trimmed = val.trim?.();\n if (!trimmed) return null;\n return formats[format].getDate(trimmed);\n};\n","export const SUPPORTED_FORMATS = ['MM/DD/YYYY', 'DD/MM/YYYY', 'YYYY/MM/DD'];\n\nexport const DEFAULT_FORMAT = SUPPORTED_FORMATS[0];\n\nexport const NATIVE_FORMAT = 'YYYY-MM-DD';\n\nexport const YEARS_RANGE = 100;\n\nexport const DIVIDER = '/';\n\nexport const months = [\n 'January',\n 'February',\n 'March',\n 'April',\n 'May',\n 'June',\n 'July',\n 'August',\n 'September',\n 'October',\n 'November',\n 'December',\n];\n\nexport const weekdays = [\n 'Sunday',\n 'Monday',\n 'Tuesday',\n 'Wednesday',\n 'Thursday',\n 'Friday',\n 'Saturday',\n];\n\nexport const counterConfig = {\n MONTH: { id: 'month', min: 1, max: 12, placeholder: 'MM' },\n DAY: { id: 'day', min: 1, max: 31, placeholder: 'DD' },\n YEAR: { id: 'year', min: 0, max: 9999, placeholder: 'YYYY' },\n};\n\nexport const valRange = {\n year: { min: 1900, max: 2099 },\n};\n\nexport const BUTTON_LABEL_DONE = 'Done';\nexport const BUTTON_LABEL_CANCEL = 'Cancel';\nexport const CALENDAR_LABEL_TODAY = 'Today';\n\nexport const MOBILE_DEVICE_INTERACTION_TIMEOUT_MS = 150;\n","export const useHostExternalPadding = (cssVarList) => `\n :host {\n padding: calc(var(${cssVarList.inputOutlineWidth}) + var(${cssVarList.inputOutlineOffset}))\n }\n`;\n\nexport const resetInputFieldUnderlayingBorder = (name) => `\n ${name}::part(input-field)::after {\n border: none;\n }\n`;\n\nexport const resetInitialHeight = (name) => `\n ${name}::before {\n\t\theight: unset;\n\t}\n`;\n\nexport const resetInputElement = (name) => `\n ${name} > input {\n -webkit-mask-image: none;\n min-height: 0;\n box-sizing: border-box;\n }\n`;\n\nexport const resetInputContainer = (name) => `\n ${name} {\n margin: 0;\n padding: 0;\n width: 100%;\n height: 100%;\n box-sizing: border-box;\n }\n`;\n\nexport const resetInputField = (name) => `\n ${name}::part(input-field) {\n overflow: hidden;\n padding: 0;\n box-shadow: none;\n }\n`;\n\nexport const resetInputCursor = (name) => `\n ${name} > label,\n ${name}::part(label),\n ${name}::part(required-indicator) {\n cursor: pointer;\n }\n`;\n\nexport const resetInputPlaceholder = (name, ele = 'input') => `\n ${name}[disabled] > ${ele}:placeholder-shown,\n\t${name}[readonly] > ${ele}:placeholder-shown {\n\t\topacity: 1;\n\t}\n`;\n\nexport const resetInputAutoFill = (name, cssVarList) => `\n ${name} input:-webkit-autofill,\n ${name} input:-webkit-autofill::first-line,\n ${name} input:-webkit-autofill:hover,\n ${name} input:-webkit-autofill:active,\n ${name} input:-webkit-autofill:focus {\n -webkit-text-fill-color: var(${cssVarList.inputValueTextColor});\n box-shadow: 0 0 0 var(${cssVarList.inputHeight}) var(${cssVarList.inputBackgroundColor}) inset;\n }\n`;\n\nexport const resetInputFieldDefaultWidth = () => `\n :host {\n --vaadin-field-default-width: auto;\n box-sizing: border-box;\n }\n`;\n\nexport const resetInputReadonlyStyle = (name) => `\n ${name}::part(input-field)::after {\n opacity: 0;\n }\n`;\n\nexport const resetInputFieldInvalidBackgroundColor = (name) => `\n ${name}::part(input-field)::after {\n background: none;\n }\n`;\n\nexport const resetInputOverrides = (name, cssVarList) => `\n ${resetInputContainer(name)}\n ${resetInputCursor(name)}\n ${resetInputPlaceholder(name)}\n ${resetInputField(name)}\n ${resetInputAutoFill(name, cssVarList)}\n ${resetInputFieldInvalidBackgroundColor(name)}\n ${resetInitialHeight(name)}\n ${resetInputElement(name)}\n ${resetInputFieldUnderlayingBorder(name)}\n`;\n\n// This function is used to support RTL correctly for input components.\n// It also fixes the error message to be displayed LTR since we currently\n// don't support RTL for error messages.\nexport const resetInputLabelPosition = (name) => `\n :host ::part(error-message) {\n direction: ltr;\n }\n :host([required]) ::part(required-indicator) {\n width: 1em;\n display: inline-flex;\n }\n :host([required]) ::part(required-indicator)::after {\n position: static;\n }\n :host([has-label]) ::part(label) {\n padding-right: 0;\n padding-bottom: 0;\n display: flex;\n width: 100%;\n }\n ${name} [slot=\"label\"] {\n max-width: calc(100% - 1em);\n overflow: hidden;\n text-overflow: ellipsis;\n padding-bottom: 0.5em;\n }\n`;\n\nexport const inputFloatingLabelStyle = () => {\n return `\n :host([label-type=\"floating\"]) {\n position: relative;\n }\n :host([label-type=\"floating\"][has-label]) > ::part(label) {\n z-index: 1;\n padding: 0;\n width: auto;\n }\n `;\n};\n","import { DIVIDER, SUPPORTED_FORMATS } from './consts';\nimport { newDate } from './helpers';\n\nconst patterns = {\n MM: '(0?[1-9]|1[0-2])',\n DD: '(0?[1-9]|[12][0-9]|3[01])',\n YYYY: '([0-9]{4})',\n};\n\nconst createPattern = (format) => {\n const pattern = format\n .split(DIVIDER)\n .map((part) => patterns[part])\n .join('\\\\D');\n\n return `^${pattern}$`;\n};\n\nconst createToValuesFn = (format) => {\n const order = format.split(DIVIDER);\n return (match) => {\n const values = {};\n order.forEach((part, index) => {\n values[part] = match[index + 1];\n });\n return [values.YYYY, values.MM, values.DD];\n };\n};\n\nconst createDate = (val, regexp, toValuesFn) => {\n const match = regexp.exec(val);\n if (!match) return null;\n const [year, month, day] = toValuesFn(match);\n return newDate([year, month, day].join(DIVIDER));\n};\n\nconst createFormat = (format) => {\n const pattern = createPattern(format);\n const toValuesFn = createToValuesFn(format);\n const regexp = new RegExp(pattern);\n\n return {\n pattern,\n validate: (val) => regexp.test(val),\n getDate: (val) => createDate(val, regexp, toValuesFn),\n };\n};\n\nexport const formats = Object.fromEntries(SUPPORTED_FORMATS.map((f) => [f, createFormat(f)]));\n","export const calendarIcon = `\n<svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path fill-rule=\"evenodd\" clip-rule=\"evenodd\" d=\"M9 5H15V4.50468C15 4.21404 15.226 4 15.5047 4H16.4953C16.786 4 17 4.22595 17 4.50468V5H18.7568C19.3028 5 19.75 5.44725 19.75 5.99896V7.00104C19.75 7.55734 19.3053 8 18.7568 8H5.24317C4.69717 8 4.25 7.55275 4.25 7.00104V5.99896C4.25 5.44266 4.69466 5 5.24317 5H7V4.50468C7 4.21404 7.22596 4 7.50468 4H8.49532C8.78596 4 9 4.22595 9 4.50468V5ZM5.50468 9H6.49532C6.78596 9 7 9.22596 7 9.50468V10.4953C7 10.786 6.77404 11 6.49532 11H5.50468C5.21404 11 5 10.774 5 10.4953V9.50468C5 9.21404 5.22595 9 5.50468 9ZM8.50468 9H9.49532C9.78596 9 10 9.22596 10 9.50468V10.4953C10 10.786 9.77404 11 9.49532 11H8.50468C8.21404 11 8 10.774 8 10.4953V9.50468C8 9.21404 8.22596 9 8.50468 9ZM11.5047 9H12.4953C12.786 9 13 9.22596 13 9.50468V10.4953C13 10.786 12.774 11 12.4953 11H11.5047C11.214 11 11 10.774 11 10.4953V9.50468C11 9.21404 11.226 9 11.5047 9ZM5.50468 12H6.49532C6.78596 12 7 12.226 7 12.5047V13.4953C7 13.786 6.77404 14 6.49532 14H5.50468C5.21404 14 5 13.774 5 13.4953V12.5047C5 12.214 5.22595 12 5.50468 12ZM8.50468 12H9.49532C9.78596 12 10 12.226 10 12.5047V13.4953C10 13.786 9.77404 14 9.49532 14H8.50468C8.21404 14 8 13.774 8 13.4953V12.5047C8 12.214 8.22596 12 8.50468 12ZM11.5047 12H12.4953C12.786 12 13 12.226 13 12.5047V13.4953C13 13.786 12.774 14 12.4953 14H11.5047C11.214 14 11 13.774 11 13.4953V12.5047C11 12.214 11.226 12 11.5047 12ZM5.50468 15H6.49532C6.78596 15 7 15.226 7 15.5047V16.4953C7 16.786 6.77404 17 6.49532 17H5.50468C5.21404 17 5 16.774 5 16.4953V15.5047C5 15.214 5.22595 15 5.50468 15ZM8.50468 15H9.49532C9.78596 15 10 15.226 10 15.5047V16.4953C10 16.786 9.77404 17 9.49532 17H8.50468C8.21404 17 8 16.774 8 16.4953V15.5047C8 15.214 8.22596 15 8.50468 15ZM11.5047 15H12.4953C12.786 15 13 15.226 13 15.5047V16.4953C13 16.786 12.774 17 12.4953 17H11.5047C11.214 17 11 16.774 11 16.4953V15.5047C11 15.214 11.226 15 11.5047 15ZM14.5047 9H15.4953C15.786 9 16 9.22596 16 9.50468V10.4953C16 10.786 15.774 11 15.4953 11H14.5047C14.214 11 14 10.774 14 10.4953V9.50468C14 9.21404 14.226 9 14.5047 9ZM14.5047 12H15.4953C15.786 12 16 12.226 16 12.5047V13.4953C16 13.786 15.774 14 15.4953 14H14.5047C14.214 14 14 13.774 14 13.4953V12.5047C14 12.214 14.226 12 14.5047 12ZM14.5047 15H15.4953C15.786 15 16 15.226 16 15.5047V16.4953C16 16.786 15.774 17 15.4953 17H14.5047C14.214 17 14 16.774 14 16.4953V15.5047C14 15.214 14.226 15 14.5047 15ZM17.5047 15H18.4953C18.786 15 19 15.226 19 15.5047V16.4953C19 16.786 18.774 17 18.4953 17H17.5047C17.214 17 17 16.774 17 16.4953V15.5047C17 15.214 17.226 15 17.5047 15ZM5.50468 18H6.49532C6.78596 18 7 18.226 7 18.5047V19.4953C7 19.786 6.77404 20 6.49532 20H5.50468C5.21404 20 5 19.774 5 19.4953V18.5047C5 18.214 5.22595 18 5.50468 18ZM8.50468 18H9.49532C9.78596 18 10 18.226 10 18.5047V19.4953C10 19.786 9.77404 20 9.49532 20H8.50468C8.21404 20 8 19.774 8 19.4953V18.5047C8 18.214 8.22596 18 8.50468 18ZM11.5047 18H12.4953C12.786 18 13 18.226 13 18.5047V19.4953C13 19.786 12.774 20 12.4953 20H11.5047C11.214 20 11 19.774 11 19.4953V18.5047C11 18.214 11.226 18 11.5047 18ZM14.5047 18H15.4953C15.786 18 16 18.226 16 18.5047V19.4953C16 19.786 15.774 20 15.4953 20H14.5047C14.214 20 14 19.774 14 19.4953V18.5047C14 18.214 14.226 18 14.5047 18ZM17.5047 18H18.4953C18.786 18 19 18.226 19 18.5047V19.4953C19 19.786 18.774 20 18.4953 20H17.5047C17.214 20 17 19.774 17 19.4953V18.5047C17 18.214 17.226 18 17.5047 18ZM17.5047 12H18.4953C18.786 12 19 12.226 19 12.5047V13.4953C19 13.786 18.774 14 18.4953 14H17.5047C17.214 14 17 13.774 17 13.4953V12.5047C17 12.214 17.226 12 17.5047 12ZM17.5047 9H18.4953C18.786 9 19 9.22596 19 9.50468V10.4953C19 10.786 18.774 11 18.4953 11H17.5047C17.214 11 17 10.774 17 10.4953V9.50468C17 9.21404 17.226 9 17.5047 9Z\" fill=\"#808080\"/>\n</svg>\n`;\n\nexport const arrowRightIcon = `\n<svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M9.27283 6.78069C8.87912 6.34164 8.91587 5.66655 9.35492 5.27283C9.79397 4.87912 10.4691 4.91587 10.8628 5.35492C10.8628 5.35492 16.0022 10.9543 16.366 11.36C16.7298 11.7657 16.7298 12.2392 16.366 12.6448L10.8628 18.6451C10.4691 19.0841 9.79397 19.1209 9.35492 18.7272C8.91587 18.3334 8.87912 17.6584 9.27283 17.2193L14.1368 12L9.27283 6.78069Z\" fill=\"#808080\"/>\n</svg>`;\n\nexport const arrowLeftIcon = `<svg width=\"24\" height=\"24\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n<path d=\"M14.7272 17.2193C15.1209 17.6584 15.0841 18.3334 14.6451 18.7272C14.206 19.1209 13.5309 19.0841 13.1372 18.6451C13.1372 18.6451 7.99776 13.0457 7.63399 12.64C7.27023 12.2343 7.27023 11.7608 7.63399 11.3552L13.1372 5.35492C13.5309 4.91587 14.206 4.87912 14.6451 5.27283C15.0841 5.66655 15.1209 6.34164 14.7272 6.78069L9.86322 12L14.7272 17.2193Z\" fill=\"#808080\"/>\n</svg>`;\n","import { months, weekdays } from '../consts';\nimport { getTimestampParts, newDate } from '../helpers';\n\nconst isValidAttrArr = (arr, count) =>\n Array.isArray(arr) && arr.length === count && arr.filter(Boolean).length === count;\n\nconst generateYearList = (range) => {\n const [start, end] = range;\n const years = [];\n\n for (let year = start; year <= end; year++) {\n years.push(year);\n }\n\n return years;\n};\n\nconst getMaxDaysInMonth = (year, month) => {\n return new Date(year, month, 0).getDate();\n};\n\nconst comboBoxItemTpl = ({ label, dataId, dataName }) => `\n\t<div class=\"combo-box-item\"\n\t\tdata-id=\"${dataId}\"\n\t\tdata-name=\"${dataName}\"\n\t>\n\t\t\t${label}\n\t</div>\n`;\n\nexport const createMonthView = (year, month, shortWeekdays) => {\n const daysInMonth = getMaxDaysInMonth(year, month);\n\n // Get day of the week (0 = Sunday, 1 = Monday, etc.)\n const firstDayOfMonth = new Date(year, month - 1, 1).getDay();\n\n let monthView = '<table>';\n\n // Add the table headers (days of the week)\n monthView += `<thead><tr>${shortWeekdays.reduce(\n (acc, d) => `${acc}<th><span class=\"weekday\">${d}</span></th>`,\n ''\n )}</tr></thead>`;\n\n monthView += '<tbody>';\n\n // Add empty cells for the days before the start of the month\n monthView += '<tr>';\n for (let i = 0; i < firstDayOfMonth; i++) {\n monthView += '<td></td>';\n }\n\n // Add days of the month\n let dayOfWeek = firstDayOfMonth;\n for (let i = 1; i <= daysInMonth; i++) {\n if (dayOfWeek === 7) {\n dayOfWeek = 0;\n monthView += '</tr><tr>';\n }\n\n monthView += `\n <td\n data-date-day=\"${i}\"\n class=\"day-entry\">\n <span class=\"day\" data-date-day=${i}>\n ${i}\n </span>\n </td>\n `;\n dayOfWeek++;\n }\n\n // Add empty cells for the days after the end of the month\n while (dayOfWeek < 7) {\n monthView += '<td></td>';\n dayOfWeek++;\n }\n\n monthView += '</tr></tbody></table>';\n\n return monthView;\n};\n\nexport const getYearOptions = (range) =>\n generateYearList(range)\n .map((item) => comboBoxItemTpl({ label: item, dataId: item, dataName: item }))\n .join('');\n\nexport const getMonthsOptions = (customMonths = months) =>\n customMonths\n .map((item, index) => comboBoxItemTpl({ label: item, dataId: index + 1, dataName: item }))\n .join('');\n\nexport const isViewVisible = (selectionTimestamp, previewTimestamp) => {\n const [previewYear, previewMonth] = getTimestampParts(previewTimestamp);\n const [selectedYear, selectedMonth] = getTimestampParts(selectionTimestamp);\n return selectedYear === previewYear && selectedMonth === previewMonth;\n};\n\nexport const createInputs = () => {\n const ele = document.createElement('span');\n\n ele.innerHTML = `\n <descope-combo-box\n label-type=\"static\"\n bordered=\"true\"\n item-label-path=\"data-name\"\n item-value-path=\"data-id\"\n class=\"month-input\"\n >\n ${getMonthsOptions()}\n </descope-combo-box>\n <descope-combo-box\n allow-custom-value=\"true\"\n label-type=\"static\"\n bordered=\"true\"\n item-label-path=\"data-name\"\n item-value-path=\"data-id\"\n class=\"year-input\"\n no-empty-value=\"true\"\n >\n </descope-combo-box>\n `;\n\n return ele;\n};\n\nexport const initComboBox = (input, onChange, onBlur) => {\n input.addEventListener('input', onChange);\n input.addEventListener('focusout', onBlur);\n return input;\n};\n\nexport const ensureMonthNamesArr = (attrVal) => {\n const monthArr = attrVal?.split(',');\n return isValidAttrArr(monthArr, 12) ? monthArr : months;\n};\n\nexport const ensureWeekdayNamesArr = (attrVal) => {\n const customWeekdayArr = attrVal?.split?.(',');\n const isCustomValid = isValidAttrArr(customWeekdayArr, 7);\n return isCustomValid ? customWeekdayArr : weekdays;\n};\n\nexport const ensureShortWeekdayNamesArr = (attrVal) => {\n const customShortWeekdays = attrVal;\n\n if (!attrVal || !isValidAttrArr(customShortWeekdays, 7)) {\n return weekdays.map((d) => d.substring(0, 3));\n }\n\n return customShortWeekdays.map((d) => d.substring(0, 3));\n};\n\nexport const truncateWeekdays = (arr) => arr.map((d) => d.substring(0, 3));\n\nexport const prevMonth = (timestamp) => {\n const date = newDate(timestamp);\n const month = date.getMonth();\n\n if (month === 0) {\n const year = date.getFullYear();\n date.setFullYear(year - 1);\n date.setMonth(11);\n } else {\n date.setMonth(month - 1);\n }\n\n return date;\n};\n\nexport const nextMonth = (timestamp) => {\n const date = newDate(timestamp);\n const month = date.getMonth();\n\n if (month === 11) {\n const year = date.getFullYear();\n date.setFullYear(year + 1);\n date.setMonth(0);\n } else {\n date.setMonth(month + 1);\n }\n\n return date;\n};\n","import { createBaseInputClass } from '../../../baseClasses/createBaseInputClass';\nimport { compose } from '../../../helpers';\nimport { forwardAttrs, getComponentName } from '../../../helpers/componentHelpers';\nimport { inputFloatingLabelStyle } from '../../../helpers/themeHelpers/resetHelpers';\nimport { componentNameValidationMixin, createStyleMixin, draggableMixin } from '../../../mixins';\nimport {\n getCurrentDay,\n getTimestampParts,\n isValidTimestamp,\n newDate,\n formatTimestamp,\n getCurrentTime,\n getFullYear,\n getMonth,\n} from '../helpers';\nimport { arrowLeftIcon, arrowRightIcon } from '../icons';\nimport {\n BUTTON_LABEL_CANCEL,\n BUTTON_LABEL_DONE,\n CALENDAR_LABEL_TODAY,\n NATIVE_FORMAT,\n YEARS_RANGE,\n} from '../consts';\nimport {\n createMonthView,\n createInputs,\n getMonthsOptions,\n getYearOptions,\n initComboBox,\n ensureMonthNamesArr,\n isViewVisible,\n ensureWeekdayNamesArr,\n truncateWeekdays,\n prevMonth,\n nextMonth,\n} from './helpers';\nimport { ButtonClass } from '@descope-ui/descope-button/class';\nimport { injectStyle } from '@descope-ui/common/components-helpers';\n\nexport const componentName = getComponentName('calendar');\n\nconst observedAttrs = [\n 'initial-value',\n 'initial-year',\n 'initial-month',\n 'years-range',\n 'calendar-months',\n 'calendar-weekdays',\n 'calendar-label-today',\n 'st-host-direction',\n 'disabled',\n 'full-width',\n];\n\nconst calendarUiAttrs = ['calendar-label-submit', 'calendar-label-cancel'];\n\nconst BaseInputClass = createBaseInputClass({ componentName, baseSelector: 'div' });\n\nclass RawCalendar extends BaseInputClass {\n static get observedAttributes() {\n return [].concat(BaseInputClass.observedAttributes || [], observedAttrs, calendarUiAttrs);\n }\n\n // preview state timestamp\n preview;\n\n // value timestamp\n timestamp;\n\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n <div>\n <nav class=\"nav top-nav\">\n <div class=\"nav-prev\">\n </div>\n <div class=\"selectors\"></div>\n <div class=\"nav-next\">\n </div>\n </nav>\n <div class=\"calendar\"></div>\n <nav class=\"nav bottom-nav\">\n <descope-button class=\"cancel-button\" variant=\"link\" mode=\"primary\">Cancel</descope-button>\n <descope-button class=\"submit-button\" variant=\"link\" mode=\"primary\" disabled=\"true\">Done</descope-button>\n </nav>\n </div>\n `;\n\n injectStyle(\n `\n :host {\n display: inline-block;\n box-sizing: border-box;\n max-width: 100%;\n user-select: none;\n -webkit-user-select: none;\n }\n\n :host ::slotted {\n padding: 0;\n }\n\n [data-toggle-calendar] {\n cursor: pointer;\n display: flex;\n align-self: center;\n z-index: 1;\n }\n\n [data-disabled=\"true\"] {\n pointer-events: none;\n }\n\n .calendar .day {\n display: flex;\n align-items: center;\n justify-content: center;\n }\n\n .nav {\n display: flex;\n align-items: center;\n box-sizing: border-box;\n }\n\n .selectors,\n .selectors span {\n display: flex;\n justify-content: center;\n }\n\n descope-button {\n padding: 0;\n ${ButtonClass.cssVarList.horizontalPadding}: 0;\n ${ButtonClass.cssVarList.verticalPadding}: 0;\n ${ButtonClass.cssVarList.outlineWidth}: 0;\n }\n\n .combo-box-item {\n display:flex;\n flex-direction: column;\n }\n\n ${inputFloatingLabelStyle()}\n `,\n this\n );\n }\n\n set value(val) {\n if (!val) return;\n\n const timestamp = newDate(val).getTime();\n\n if (!isValidTimestamp(timestamp) || timestamp === this.timestmap) {\n return;\n }\n\n this.timestamp = timestamp;\n\n this.renderCalendar();\n }\n\n get value() {\n return this.timestamp ? formatTimestamp(this.timestamp, NATIVE_FORMAT) : '';\n }\n\n get isSelectedView() {\n return isViewVisible(this.preview, this.timestamp);\n }\n\n get isTodayView() {\n return isViewVisible(getCurrentTime(), this.preview);\n }\n\n get monthNames() {\n return ensureMonthNamesArr(this.getAttribute('calendar-months'));\n }\n\n get weekdayNames() {\n return ensureWeekdayNamesArr(this.getAttribute('calendar-weekdays'));\n }\n\n get hasYearValue() {\n return !!this.yearInput.value;\n }\n\n get hasMonthValue() {\n return !!this.monthInput.value;\n }\n\n get yearsRange() {\n const range = this.getAttribute('years-range')?.split('-');\n\n if (range?.length === 2) {\n const [start, end] = range.map(Number);\n if (start <= end) return [start, end];\n }\n\n const currentYear = newDate().getFullYear();\n\n return [currentYear, currentYear + YEARS_RANGE];\n }\n\n init() {\n super.init?.();\n this.initCalendar();\n this.renderCalendar();\n }\n\n initCalendar() {\n this.calendar = this.shadowRoot.querySelector('.calendar');\n\n this.navPrevEle = this.shadowRoot.querySelector('.nav-prev');\n this.navNextEle = this.shadowRoot.querySelector('.nav-next');\n this.submitButton = this.shadowRoot.querySelector('.submit-button');\n this.cancelButton = this.shadowRoot.querySelector('.cancel-button');\n\n this.initInputs();\n this.initNav();\n\n this.addEventListener('day-changed', () => this.submitButton.removeAttribute('disabled'));\n // This is a workaround for descope-components inside Vaadin's Popover component.\n // When we sync attributes, the `disabled` attribute is being compared to the attribute\n // on Vaadin component; since the Vaadin component has no `disabled` attribute, we sync\n // that back to our component. This happens when using Popover, and for specific attributes,\n // namely `disabled`. This is pending a more generic fix in the way we sync attibutes.\n this.submitButton.shadowRoot.querySelector('vaadin-button').setAttribute('disabled', 'true');\n }\n\n initInputs() {\n const ele = createInputs(this.monthNames, this.yearsRange);\n this.shadowRoot.querySelector('.selectors').appendChild(ele);\n\n this.monthInput = initComboBox(\n this.shadowRoot.querySelector('.month-input'),\n this.onMonthChange.bind(this),\n this.onMonthInputBlur.bind(this)\n );\n\n this.yearInput = initComboBox(\n this.shadowRoot.querySelector('.year-input'),\n this.onYearChange.bind(this),\n this.onYearInputBlur.bind(this)\n );\n\n [this.monthInput, this.yearInput].forEach((selector) =>\n forwardAttrs(this, selector, {\n includeAttrs: ['disabled', 'size', 'st-host-direction'],\n })\n );\n }\n\n initNav() {\n this.navPrevEle.addEventListener('click', this.navPrevMonth.bind(this));\n this.navNextEle.addEventListener('click', this.navNextMonth.bind(this));\n this.cancelButton.addEventListener('click', this.onCancel.bind(this));\n this.submitButton.addEventListener('click', this.onSubmit.bind(this));\n\n [this.navPrevEle, this.navNextEle].forEach((btn) =>\n forwardAttrs(this, btn, {\n includeAttrs: ['size'],\n })\n );\n\n this.shadowRoot.querySelector('.nav-next').innerHTML = arrowRightIcon;\n this.shadowRoot.querySelector('.nav-prev').innerHTML = arrowLeftIcon;\n }\n\n onSubmit() {\n if (this.isDisabled) return;\n if (!this.value) return;\n this.dispatchEvent(new CustomEvent('date-submit', { detail: newDate(this.preview) }));\n }\n\n onCancel() {\n if (this.isDisabled) return;\n this.dispatchEvent(new CustomEvent('cancel'));\n this.dispatchEvent(new CustomEvent('date-cancel'));\n this.clearSelectedDay();\n }\n\n clearSelectedDay() {\n this.getSelectedDayEle()?.removeAttribute('data-selected');\n this.submitButton.setAttribute('disabled', 'true');\n this.timestamp = '';\n }\n\n updateInputs() {\n if (this.yearInput && this.monthInput) {\n const timestamp = this.preview || getCurrentTime();\n const year = getFullYear(timestamp);\n const month = getMonth(timestamp);\n this.monthInput.value = month;\n // For the yearInput we update the base element directly to properly trigger the change event\n // since this can be a custom value\n setTimeout(() => {\n this.yearInput.baseElement.value = year;\n });\n }\n }\n\n renderCalendar() {\n const date = newDate(this.preview || getCurrentTime());\n const timestamp = date.getTime();\n\n const [year, month] = getTimestampParts(timestamp);\n\n if (this.calendar) {\n this.calendar.innerHTML = createMonthView(year, month, truncateWeekdays(this.weekdayNames));\n }\n\n Array.from(this.calendar?.querySelectorAll('.day-entry .day') || []).forEach((ele) =>\n ele.addEventListener('click', this.onDayChange.bind(this))\n );\n\n this.updateInputs();\n this.setSelectedDay();\n this.setCurrentDay();\n }\n\n onDayChange(e) {\n if (this.isDisabled) return;\n const date = newDate(this.preview);\n date.setDate(Number(e.target.getAttribute('data-date-day')));\n this.value = formatTimestamp(date.getTime(), NATIVE_FORMAT);\n this.dispatchEvent(new CustomEvent('day-changed', { detail: date }));\n }\n\n onYearChange(e) {\n if (!e.target.value) return;\n const date = newDate(this.preview);\n date.setFullYear(Number(e.target.value.trim()));\n this.preview = date.getTime();\n this.renderCalendar();\n this.dispatchEvent(new CustomEvent('year-changed', { detail: date }));\n }\n\n onMonthChange(e) {\n if (!e.target.value) return;\n const date = newDate(this.preview);\n date.setMonth(Number(e.target.value) - 1);\n this.preview = date.getTime();\n this.renderCalendar();\n this.dispatchEvent(new CustomEvent('month-changed', { detail: date }));\n }\n\n onYearInputBlur(e) {\n this.yearInput.baseElement.value = e.target.value || getFullYear(this.preview);\n }\n\n onMonthInputBlur(e) {\n this.monthInput.baseElement.value = e.target.value || getMonth(this.preview);\n }\n\n getSelectedDayEle() {\n const day = newDate(this.timestamp).getDate();\n return this.calendar?.querySelector(`[data-date-day=\"${day}\"]`);\n }\n\n getCurrentDayEle() {\n return this.calendar?.querySelector(`[data-date-day=\"${getCurrentDay()}\"]`);\n }\n\n clearSelectedDays() {\n const cells = this.calendar?.querySelectorAll(`[data-selected]`);\n if (!cells) return;\n cells.forEach((c) => c.removeAttribute('data-selected'));\n }\n\n setSelectedDay() {\n this.clearSelectedDays();\n if (this.value && this.isSelectedView) {\n this.getSelectedDayEle().setAttribute('data-selected', 'true');\n }\n }\n\n setCurrentDay() {\n if (this.isTodayView) {\n const ele = this.getCurrentDayEle();\n const title = this.getAttribute('calendar-label-today') || CALENDAR_LABEL_TODAY;\n ele.setAttribute('data-current-day', 'true');\n ele.setAttribute('title', title);\n }\n }\n\n navPrevMonth() {\n if (this.isDisabled) {\n return;\n }\n const date = prevMonth(this.preview);\n this.preview = date.getTime();\n this.renderCalendar();\n }\n\n navNextMonth() {\n if (this.isDisabled) {\n return;\n }\n const date = nextMonth(this.preview);\n this.preview = date.getTime();\n this.renderCalendar();\n }\n\n clearValue() {\n this.timestamp = '';\n this.value = '';\n this.removeAttribute('preview');\n this.submitButton.setAttribute('disabled', 'true');\n }\n\n onInitialValueChange(newValue) {\n // if component already has a value don't re-set value\n if (this.value) {\n return;\n }\n\n const date = newDate(newValue);\n const timestamp = date.getTime();\n\n if (isValidTimestamp(timestamp)) {\n this.timestamp = timestamp;\n this.preview = timestamp;\n } else {\n this.clearValue();\n }\n }\n\n onYearsRangeChange() {\n setTimeout(() => {\n if (this.yearInput) {\n this.yearInput.innerHTML = getYearOptions(this.yearsRange);\n }\n });\n }\n\n onMonthNamesChange() {\n setTimeout(() => {\n if (this.monthInput) {\n this.monthInput.innerHTML = getMonthsOptions(this.monthNames);\n }\n });\n }\n\n onSubmitLabelChange(newValue) {\n if (this.submitButton) {\n this.submitButton.textContent = newValue || BUTTON_LABEL_DONE;\n }\n }\n\n onCancelLabelChange(newValue) {\n if (this.cancelButton) {\n this.cancelButton.textContent = newValue || BUTTON_LABEL_CANCEL;\n }\n }\n\n onInitialMonthChange(val) {\n const currYear = getFullYear(this.preview);\n this.preview = newDate(`${currYear}/${val}/1`).getTime();\n }\n\n onInitialYearChange(val) {\n const currMonth = getMonth(this.preview);\n this.preview = newDate(`${val}/${currMonth}/1`).getTime();\n }\n\n attributeChangedCallback(attrName, oldValue, newValue) {\n super.attributeChangedCallback(attrName, oldValue, newValue);\n if (oldValue !== newValue) {\n // attrs for which affect static ui parts doesn't require calendar re-render\n if (calendarUiAttrs.includes(attrName)) {\n if (attrName === 'calendar-label-submit') {\n this.onSubmitLabelChange(newValue);\n }\n if (attrName === 'calendar-label-cancel') {\n this.onCancelLabelChange(newValue);\n }\n } else {\n // we want to render the calendar for each of these attr change\n\n if (newValue && attrName === 'initial-value') {\n this.onInitialValueChange(newValue);\n }\n if (newValue && attrName === 'initial-month') {\n this.onInitialMonthChange(newValue);\n }\n if (newValue && attrName === 'initial-year') {\n this.onInitialYearChange(newValue);\n }\n if (attrName === 'years-range') {\n this.onYearsRangeChange(Number(newValue));\n }\n if (attrName === 'calendar-months') {\n this.onMonthNamesChange();\n }\n if (attrName === 'calendar-label-today') {\n this.setCurrentDay(newValue);\n }\n if (attrName === 'disabled') {\n setTimeout(() => {\n this.cancelButton?.setAttribute('disabled', newValue === 'true');\n });\n }\n\n this.renderCalendar();\n }\n }\n }\n\n getValidity() {\n if (this.isRequired && !this.value) {\n return { valueMissing: true };\n }\n return {};\n }\n}\n\nconst {\n calendar,\n day,\n dayEntry,\n currentDay,\n selectedDay,\n disabledDay,\n weekday,\n topNav,\n topNavSelectors,\n bottomNav,\n navPrev,\n navNext,\n navPrevRTL,\n navNextRTL,\n yearInput,\n monthInput,\n} = {\n calendar: { selector: () => '.calendar' },\n topNav: { selector: () => '.nav.top-nav' },\n topNavSelectors: { selector: () => '.nav.top-nav .selectors > span' },\n bottomNav: { selector: () => '.nav.bottom-nav' },\n day: { selector: () => '.day' },\n dayEntry: { selector: () => '.day-entry' },\n currentDay: { selector: () => '.day-entry[data-current-day] .day' },\n selectedDay: { selector: () => '.day-entry[data-selected] .day' },\n disabledDay: { selector: () => '.day-entry[data-disabled=\"true\"] .day' },\n weekday: { selector: () => '.weekday' },\n navPrev: { selector: () => '.nav-prev' },\n navNext: { selector: () => '.nav-next' },\n navPrevRTL: { selector: () => ':host([st-host-direction=\"rtl\"]) .nav-prev' },\n navNextRTL: { selector: () => ':host([st-host-direction=\"rtl\"]) .nav-next' },\n yearInput: { selector: () => '.year-input' },\n monthInput: { selector: () => '.month-input' },\n};\n\nexport const CalendarClass = compose(\n createStyleMixin({ componentNameOverride: getComponentName('input-wrapper') }),\n createStyleMixin({\n mappings: {\n fontSize: {},\n fontFamily: {},\n hostWidth: [\n { selector: () => ':host', property: 'width' },\n { selector: 'table', property: 'width' },\n ],\n hostDirection: { property: 'direction' },\n\n topNavVerticalPadding: [\n { ...topNav, property: 'padding-top' },\n { ...topNav, property: 'padding-bottom' },\n ],\n topNavHorizointalPadding: [\n { ...topNav, property: 'padding-right' },\n { ...topNav, property: 'padding-left' },\n ],\n topNavAlignment: { ...topNav, property: 'justify-content' },\n topNavGap: { ...topNav, property: 'gap' },\n topNavSelectorsGap: { ...topNavSelectors, property: 'gap' },\n\n bottomNavVerticalPadding: [\n { ...bottomNav, property: 'padding-top' },\n { ...bottomNav, property: 'padding-bottom' },\n ],\n bottomNavHorizontalPadding: [\n { ...bottomNav, property: 'padding-right' },\n { ...bottomNav, property: 'padding-left' },\n ],\n bottomNavAlignment: { ...bottomNav, property: 'justify-content' },\n bottomNavGap: { ...bottomNav, property: 'gap' },\n\n navMarginBottom: { ...topNav, property: 'margin-bottom' },\n\n calendarPadding: [\n { ...calendar, property: 'padding-bottom' },\n { ...calendar, property: 'padding-right' },\n { ...calendar, property: 'padding-left' },\n ],\n\n navBorderBottomWidth: { ...topNav, property: 'border-bottom-width' },\n navBorderBottomColor: { ...topNav, property: 'border-bottom-color' },\n navBorderBottomStyle: { ...topNav, property: 'border-bottom-style' },\n\n weekdayFontSize: { ...weekday, property: 'font-size' },\n weekdayFontWeight: { ...weekday, property: 'font-weight' },\n\n currentDayBorderColor: {\n ...currentDay,\n property: 'border-color',\n },\n currentDayBorderWidth: {\n ...currentDay,\n property: 'border-width',\n },\n currentDayBorderStyle: {\n ...currentDay,\n property: 'border-style',\n },\n\n dayHeight: { ...dayEntry, property: 'height' },\n daySize: [\n { ...day, property: 'height' },\n { ...day, property: 'width' },\n ],\n dayPadding: { ...day, property: 'padding' },\n dayRadius: { ...day, property: 'border-radius' },\n dayTextAlign: { ...day, property: 'text-align' },\n dayBlockAlign: { ...day, property: 'margin' },\n dayTextColor: { ...day, property: 'color' },\n dayFontWeight: { ...day, property: 'font-weight' },\n dayBackgroundColor: { ...day, property: 'background-color' },\n dayCursor: { ...day, property: 'cursor' },\n dayFontSize: { ...day, property: 'font-size' },\n\n dayBackgroundColorHover: {\n selector: () => '.day:hover',\n property: 'background-color',\n },\n\n daySelectedTextdColor: {\n ...selectedDay,\n property: 'color',\n },\n daySelectedBackgroundColor: {\n ...selectedDay,\n property: 'background-color',\n },\n dayDisabledTextdColor: {\n ...disabledDay,\n property: 'color',\n },\n\n yearInputWidth: { ...yearInput, property: 'width' },\n monthInputWidth: { ...monthInput, property: 'width' },\n\n navButtonSize: [\n { ...navPrev, property: 'width' },\n { ...navPrev, property: 'height' },\n { ...navNext, property: 'width' },\n { ...navNext, property: 'height' },\n ],\n navButtonCursor: [\n { ...navPrev, property: 'cursor' },\n { ...navNext, property: 'cursor' },\n ],\n navButtonRotation: [\n { ...navPrevRTL, property: 'transform' },\n { ...navNextRTL, property: 'transform' },\n ],\n navButtonOpacity: [\n { ...navPrev, property: 'opacity' },\n { ...navNext, property: 'opacity' },\n ],\n },\n }),\n draggableMixin,\n componentNameValidationMixin\n)(RawCalendar);\n","import '@descope-ui/descope-combo-box';\nimport '@descope-ui/descope-button';\n\nimport { componentName, CalendarClass } from './CalendarClass';\n\ncustomElements.define(componentName, CalendarClass);\n\nexport { CalendarClass, componentName };\n","import {\n componentNameValidationMixin,\n createProxy,\n createStyleMixin,\n draggableMixin,\n} from '@descope-ui/common/components-mixins';\nimport { getComponentName } from '@descope-ui/common/components-helpers';\nimport { ImageClass } from '@descope-ui/descope-image/class';\nimport { compose } from '@descope-ui/common/utils';\n\nexport const componentName = getComponentName('icon');\n\nexport const IconClass = compose(\n createStyleMixin({\n mappings: {\n fill: [{}, { property: ImageClass.cssVarList.fill }],\n },\n }),\n draggableMixin,\n componentNameValidationMixin,\n)(\n createProxy({\n slots: [],\n wrappedEleName: 'descope-image',\n style: () => `\n :host {\n display: inline-flex;\n }\n `,\n excludeAttrsSync: ['tabindex', 'class'],\n componentName,\n }),\n);\n"],"names":["createBaseInputClass","args","componentName","srcAttrs","RawImage","baseSelector","observedAttributes","constructor","super","this","attachShadow","mode","innerHTML","init","toggleVisibility","src","onThemeChange","renderImage","isVisible","classList","remove","add","altText","getAttribute","legacySrc","themeSrc","currentThemeName","updateFillColor","node","querySelectorAll","forEach","ele","setAttribute","ImageClass","cssVarList","fill","then","res","appendChild","shouldRender","srcVal","attributeChangedCallback","attrName","oldValue","newValue","mappings","height","selector","width","clickableMixin","superclass","isLoading","click","createSvgEle","text","clean","sanitize","USE_PROFILES","svg","svgFilters","ADD_TAGS","FORBID_TAGS","DOMParser","parseFromString","querySelector","createImage","async","startsWith","isBase64Svg","svgXml","atob","slice","base64Prefix","path","match","getFileExtension","fetchedSrc","fetch","document","createElement","createImgEle","style","setProperty","host","label","slottedIcon","loadingIndicatorStyles","ButtonClass","hostWidth","property","hostHeight","hostDirection","fontSize","fontFamily","cursor","backgroundColor","outlineOffset","outlineColor","outlineStyle","outlineWidth","borderRadius","borderColor","borderStyle","borderWidth","verticalPadding","horizontalPadding","fallback","labelTextColor","iconColor","labelTextDecoration","labelSpacing","textAlign","iconSize","slots","wrappedEleName","excludeAttrsSync","color","customElements","define","isValidTimestamp","val","Number","isNaN","isNumber","String","trim","getTimestampParts","timestamp","date","newDate","getFullYear","getMonth","getDate","formatTimestamp","format","year","month","day","parts","DD","padStart","MM","YYYY","replace","Date","getCurrentTime","getTime","toString","getCurrentDay","overrideConstructedStylesheet","cs","CSSStyleSheet","insertRule","shadowRoot","adoptedStyleSheets","push","parseDateString","trimmed","SUPPORTED_FORMATS","DEFAULT_FORMAT","NATIVE_FORMAT","YEARS_RANGE","DIVIDER","months","weekdays","counterConfig","MONTH","id","min","max","placeholder","DAY","YEAR","valRange","BUTTON_LABEL_DONE","BUTTON_LABEL_CANCEL","CALENDAR_LABEL_TODAY","MOBILE_DEVICE_INTERACTION_TIMEOUT_MS","useHostExternalPadding","inputOutlineWidth","inputOutlineOffset","resetInputContainer","name","resetInputField","resetInputCursor","resetInputPlaceholder","resetInputFieldDefaultWidth","resetInputReadonlyStyle","resetInputFieldInvalidBackgroundColor","resetInputOverrides","inputValueTextColor","inputHeight","inputBackgroundColor","resetInputAutoFill","resetInitialHeight","resetInputElement","resetInputFieldUnderlayingBorder","resetInputLabelPosition","inputFloatingLabelStyle","patterns","createFormat","pattern","split","map","part","join","createPattern","toValuesFn","order","values","index","createToValuesFn","regexp","RegExp","validate","test","exec","createDate","formats","Object","fromEntries","f","calendarIcon","arrowRightIcon","arrowLeftIcon","isValidAttrArr","arr","count","Array","isArray","length","filter","Boolean","comboBoxItemTpl","dataId","dataName","getMonthsOptions","customMonths","item","isViewVisible","selectionTimestamp","previewTimestamp","previewYear","previewMonth","selectedYear","selectedMonth","initComboBox","input","onChange","onBlur","addEventListener","observedAttrs","calendarUiAttrs","BaseInputClass","calendar","dayEntry","currentDay","selectedDay","disabledDay","weekday","topNav","topNavSelectors","bottomNav","navPrev","navNext","navPrevRTL","navNextRTL","yearInput","monthInput","CalendarClass","componentNameOverride","topNavVerticalPadding","topNavHorizointalPadding","topNavAlignment","topNavGap","topNavSelectorsGap","bottomNavVerticalPadding","bottomNavHorizontalPadding","bottomNavAlignment","bottomNavGap","navMarginBottom","calendarPadding","navBorderBottomWidth","navBorderBottomColor","navBorderBottomStyle","weekdayFontSize","weekdayFontWeight","currentDayBorderColor","currentDayBorderWidth","currentDayBorderStyle","dayHeight","daySize","dayPadding","dayRadius","dayTextAlign","dayBlockAlign","dayTextColor","dayFontWeight","dayBackgroundColor","dayCursor","dayFontSize","dayBackgroundColorHover","daySelectedTextdColor","daySelectedBackgroundColor","dayDisabledTextdColor","yearInputWidth","monthInputWidth","navButtonSize","navButtonCursor","navButtonRotation","navButtonOpacity","concat","preview","value","timestmap","renderCalendar","isSelectedView","isTodayView","monthNames","attrVal","monthArr","ensureMonthNamesArr","weekdayNames","customWeekdayArr","ensureWeekdayNamesArr","hasYearValue","hasMonthValue","yearsRange","range","start","end","currentYear","initCalendar","navPrevEle","navNextEle","submitButton","cancelButton","initInputs","initNav","removeAttribute","createInputs","onMonthChange","bind","onMonthInputBlur","onYearChange","onYearInputBlur","includeAttrs","navPrevMonth","navNextMonth","onCancel","onSubmit","btn","isDisabled","dispatchEvent","CustomEvent","detail","clearSelectedDay","getSelectedDayEle","updateInputs","setTimeout","baseElement","shortWeekdays","daysInMonth","getMaxDaysInMonth","firstDayOfMonth","getDay","monthView","reduce","acc","d","i","dayOfWeek","createMonthView","substring","from","onDayChange","setSelectedDay","setCurrentDay","e","setDate","target","setFullYear","setMonth","getCurrentDayEle","clearSelectedDays","cells","c","title","prevMonth","nextMonth","clearValue","onInitialValueChange","onYearsRangeChange","years","generateYearList","onMonthNamesChange","onSubmitLabelChange","textContent","onCancelLabelChange","onInitialMonthChange","currYear","onInitialYearChange","currMonth","includes","getValidity","isRequired","valueMissing","IconClass"],"sourceRoot":""}
@@ -1,2 +1,2 @@
1
- "use strict";(self.webpackChunk_descope_web_components_ui=self.webpackChunk_descope_web_components_ui||[]).push([[2294,8819],{48995:(t,e,o)=>{o.r(e),o.d(e,{DividerClass:()=>m,componentName:()=>l});var n=o(79365),r=o(81365),i=o(9696),s=o(97810),p=o(66434),h=o(25964);const l=(0,s.xE)("divider");class d extends((0,r.q)({componentName:l,baseSelector:":host > div"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML="\n\t\t\t<div>\n\t\t\t\t<descope-text>\n\t\t\t\t\t<slot></slot>\n\t\t\t\t</descope-text>\n\t\t\t</div>\n\t\t",(0,h.fz)("\n \t:host {\n\t\t\t\t\tdisplay: inline-block;\n\t\t\t\t}\n\t\t\t\t:host > div {\n\t\t\t\t\tdisplay: flex;\n\t\t\t\t\theight: 100%;\n\t\t\t\t\twidth: 100%;\n\t\t\t\t}\n\t\t\t\t:host > div::before,\n\t\t\t\t:host > div::after {\n\t\t\t\t\tcontent: '';\n\t\t\t\t\tflex-grow: 1;\n\t\t\t\t}\n\t\t\t\tdescope-text {\n\t\t\t\t\tflex-grow: 0;\n\t\t\t\t\tflex-shrink: 0;\n\t\t\t\t}\n\t\t\t\t:host(:empty) descope-text {\n\t\t\t\t\tdisplay: none;\n\t\t\t\t}\n\t\t\t\t:host([vertical=\"true\"]) div {\n\t\t\t\t\twidth: fit-content;\n\t\t\t\t}\n ",this),this.textComponent=this.shadowRoot.querySelector("descope-text"),(0,s.EA)(this,this.textComponent,{includeAttrs:["mode","variant","italic"]})}}const c=p.s.cssVarList,{host:a,before:y,after:x,text:g}={host:{selector:()=>":host"},before:{selector:"::before"},after:{selector:"::after"},text:{selector:"descope-text"}},m=(0,i.Zz)((0,n.RF)({mappings:{hostWidth:{...a,property:"width"},hostPadding:{...a,property:"padding"},hostDirection:{...g,property:"direction"},minHeight:{},alignItems:{},alignSelf:{},flexDirection:{},textAlign:{...g,property:c.textAlign},labelTextWidth:{...g,property:"width"},labelTextMaxWidth:{...g,property:"max-width"},labelTextVerticalSpacing:[{...g,property:"padding-top"},{...g,property:"padding-bottom"}],labelTextHorizontalSpacing:[{...g,property:"padding-right"},{...g,property:"padding-left"}],stripeColor:[{...y,property:"background-color"},{...x,property:"background-color"}],stripeHorizontalThickness:[{...y,property:"height"},{...x,property:"height"}],stripeVerticalThickness:[{...y,property:"width"},{...x,property:"width"}],stripeColorOpacity:[{...y,property:"opacity"},{...x,property:"opacity"}]}}),n.VO,n.tQ)(d);o(63595),customElements.define(l,m)},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)},66434:(t,e,o)=>{o.d(e,{T:()=>p,s:()=>d});var n=o(88961),r=o(63200),i=o(25964),s=o(72270);const p=(0,i.xE)("text");class h extends((0,s.qu)({componentName:p,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:l}={host:{selector:()=>":host"}},d=(0,r.Zz)((0,n.RF)({mappings:{hostWidth:{selector:()=>":host",property:"width"},hostDirection:{selector:()=>":host",property:"direction"},fontSize:{},textColor:[{property:"color"}],textLineHeight:{property:"line-height"},textLetterSpacing:{property:"letter-spacing"},textShadow:{},textAlign:{},textTransform:{},fontFamily:{},fontStyle:{},fontWeight:{},borderWidth:{},borderStyle:{},borderColor:{}}}),n.VO,n.tQ)(h)}}]);
1
+ "use strict";(self.webpackChunk_descope_web_components_ui=self.webpackChunk_descope_web_components_ui||[]).push([[2294,8819],{48995:(t,e,o)=>{o.r(e),o.d(e,{DividerClass:()=>m,componentName:()=>d});var n=o(79365),i=o(81365),r=o(9696),s=o(97810),p=o(66434),h=o(25964);const d=(0,s.xE)("divider");class l extends((0,i.q)({componentName:d,baseSelector:":host > div"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML="\n\t\t\t<div>\n\t\t\t\t<descope-text>\n\t\t\t\t\t<slot></slot>\n\t\t\t\t</descope-text>\n\t\t\t</div>\n\t\t",(0,h.fz)("\n \t:host {\n\t\t\t\t\tdisplay: inline-block;\n\t\t\t\t}\n\t\t\t\t:host > div {\n\t\t\t\t\tdisplay: flex;\n\t\t\t\t\theight: 100%;\n\t\t\t\t\twidth: 100%;\n\t\t\t\t}\n\t\t\t\t:host > div::before,\n\t\t\t\t:host > div::after {\n\t\t\t\t\tcontent: '';\n\t\t\t\t\tflex-grow: 1;\n\t\t\t\t}\n\t\t\t\tdescope-text {\n\t\t\t\t\tflex-grow: 0;\n\t\t\t\t\tflex-shrink: 0;\n\t\t\t\t}\n\t\t\t\t:host(:empty) descope-text {\n\t\t\t\t\tdisplay: none;\n\t\t\t\t}\n\t\t\t\t:host([vertical=\"true\"]) div {\n\t\t\t\t\twidth: fit-content;\n\t\t\t\t}\n ",this),this.textComponent=this.shadowRoot.querySelector("descope-text"),(0,s.EA)(this,this.textComponent,{includeAttrs:["mode","variant","italic"]})}}const a=p.s.cssVarList,{host:c,before:y,after:x,text:g}={host:{selector:()=>":host"},before:{selector:"::before"},after:{selector:"::after"},text:{selector:"descope-text"}},m=(0,r.Zz)((0,n.RF)({mappings:{hostWidth:{...c,property:"width"},hostPadding:{...c,property:"padding"},hostDirection:{...g,property:"direction"},minHeight:{},alignItems:{},alignSelf:{},flexDirection:{},textAlign:{...g,property:a.textAlign},labelTextWidth:{...g,property:"width"},labelTextMaxWidth:{...g,property:"max-width"},labelTextVerticalSpacing:[{...g,property:"padding-top"},{...g,property:"padding-bottom"}],labelTextHorizontalSpacing:[{...g,property:"padding-right"},{...g,property:"padding-left"}],stripeColor:[{...y,property:"background-color"},{...x,property:"background-color"}],stripeHorizontalThickness:[{...y,property:"height"},{...x,property:"height"}],stripeVerticalThickness:[{...y,property:"width"},{...x,property:"width"}],stripeColorOpacity:[{...y,property:"opacity"},{...x,property:"opacity"}]}}),n.VO,n.tQ)(l);o(63595),customElements.define(d,m)},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)},66434:(t,e,o)=>{o.d(e,{T:()=>p,s:()=>l});var n=o(88961),i=o(63200),r=o(25964),s=o(72270);const p=(0,r.xE)("text");class h extends((0,s.qu)({componentName:p,baseSelector:":host > slot"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <slot part="text-wrapper"></slot>\n ',(0,r.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,r.Ge)(this,(()=>{const t=!!this.childNodes.length;this.style.display=!t&&this.hideWhenEmpty?"none":""}))}}const{host:d}={host:{selector:()=>":host"}},l=(0,i.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:{}}}),n.VO,n.tQ)(h)}}]);
2
2
  //# sourceMappingURL=descope-divider-index-js.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"descope-divider-index-js.js","mappings":"0QAOO,MAAMA,GAAgB,QAAiB,WAC9C,MAAMC,WAAmB,EAAAC,EAAA,GAAgB,CAAEF,gBAAeG,aAAc,iBACtE,WAAAC,GACEC,QAEAC,KAAKC,aAAa,CAAEC,KAAM,SAAUC,UAAY,+GAQhD,QACE,wiBAyBAH,MAGFA,KAAKI,cAAgBJ,KAAKK,WAAWC,cAAc,iBAEnD,QAAaN,KAAMA,KAAKI,cAAe,CACrCG,aAAc,CAAC,OAAQ,UAAW,WAEtC,EAGF,MAAMC,EAAWC,EAAA,EAAUC,YACrB,KAAEC,EAAI,OAAEC,EAAM,MAAEC,EAAOC,KAAI,GAAK,CACpCH,KAAM,CAAEI,SAAU,IAAM,SACxBH,OAAQ,CAAEG,SAAU,YACpBF,MAAO,CAAEE,SAAU,WACnBD,KAAM,CAAEC,SAAU,iBAGPC,GAAe,SAC1B,QAAiB,CACfC,SAAU,CACRC,UAAW,IAAKP,EAAMQ,SAAU,SAChCC,YAAa,IAAKT,EAAMQ,SAAU,WAClCE,cAAe,IAAK,EAAMF,SAAU,aAEpCG,UAAW,CAAC,EACZC,WAAY,CAAC,EACbC,UAAW,CAAC,EACZC,cAAe,CAAC,EAChBC,UAAW,I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W,CACT,CAAE5B,SAAU,UAEd6B,eAAgB,CAAE7B,SAAU,eAC5B8B,kBAAmB,CAAE9B,SAAU,kBAC/B+B,WAAY,CAAC,EACbxB,UAAW,CAAC,EACZyB,cAAe,CAAC,EAChBC,WAAY,CAAC,EACbC,UAAW,CAAC,EACZC,WAAY,CAAC,EACbC,YAAa,CAAC,EACdC,YAAa,CAAC,EACdC,YAAa,CAAC,KAGlB,KACA,KAvBuB,CAwBvBpB,E","sources":["webpack://@descope/web-components-ui/./src/components/descope-divider/DividerClass.js","webpack://@descope/web-components-ui/./src/components/descope-divider/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"],"sourcesContent":["import { createStyleMixin, draggableMixin, componentNameValidationMixin } from '../../mixins';\nimport { createBaseClass } from '../../baseClasses/createBaseClass';\nimport { compose } from '../../helpers';\nimport { forwardAttrs, getComponentName } from '../../helpers/componentHelpers';\nimport { TextClass } from '@descope-ui/descope-text/class';\nimport { injectStyle } from '@descope-ui/common/components-helpers';\n\nexport const componentName = getComponentName('divider');\nclass RawDivider extends createBaseClass({ componentName, baseSelector: ':host > div' }) {\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n\t\t\t<div>\n\t\t\t\t<descope-text>\n\t\t\t\t\t<slot></slot>\n\t\t\t\t</descope-text>\n\t\t\t</div>\n\t\t`;\n\n injectStyle(\n `\n \t:host {\n\t\t\t\t\tdisplay: inline-block;\n\t\t\t\t}\n\t\t\t\t:host > div {\n\t\t\t\t\tdisplay: flex;\n\t\t\t\t\theight: 100%;\n\t\t\t\t\twidth: 100%;\n\t\t\t\t}\n\t\t\t\t:host > div::before,\n\t\t\t\t:host > div::after {\n\t\t\t\t\tcontent: '';\n\t\t\t\t\tflex-grow: 1;\n\t\t\t\t}\n\t\t\t\tdescope-text {\n\t\t\t\t\tflex-grow: 0;\n\t\t\t\t\tflex-shrink: 0;\n\t\t\t\t}\n\t\t\t\t:host(:empty) descope-text {\n\t\t\t\t\tdisplay: none;\n\t\t\t\t}\n\t\t\t\t:host([vertical=\"true\"]) div {\n\t\t\t\t\twidth: fit-content;\n\t\t\t\t}\n `,\n this\n );\n\n this.textComponent = this.shadowRoot.querySelector('descope-text');\n\n forwardAttrs(this, this.textComponent, {\n includeAttrs: ['mode', 'variant', 'italic'],\n });\n }\n}\n\nconst textVars = TextClass.cssVarList;\nconst { host, before, after, text } = {\n host: { selector: () => ':host' },\n before: { selector: '::before' },\n after: { selector: '::after' },\n text: { selector: 'descope-text' },\n};\n\nexport const DividerClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { ...host, property: 'width' },\n hostPadding: { ...host, property: 'padding' },\n hostDirection: { ...text, property: 'direction' },\n\n minHeight: {},\n alignItems: {},\n alignSelf: {},\n flexDirection: {},\n textAlign: { ...text, property: textVars.textAlign },\n\n labelTextWidth: { ...text, property: 'width' },\n labelTextMaxWidth: { ...text, property: 'max-width' },\n labelTextVerticalSpacing: [\n { ...text, property: 'padding-top' },\n { ...text, property: 'padding-bottom' },\n ],\n labelTextHorizontalSpacing: [\n { ...text, property: 'padding-right' },\n { ...text, property: 'padding-left' },\n ],\n\n stripeColor: [\n { ...before, property: 'background-color' },\n { ...after, property: 'background-color' },\n ],\n stripeHorizontalThickness: [\n { ...before, property: 'height' },\n { ...after, property: 'height' },\n ],\n stripeVerticalThickness: [\n { ...before, property: 'width' },\n { ...after, property: 'width' },\n ],\n stripeColorOpacity: [\n { ...before, property: 'opacity' },\n { ...after, property: 'opacity' },\n ],\n },\n }),\n draggableMixin,\n componentNameValidationMixin\n)(RawDivider);\n","import { componentName, DividerClass } from './DividerClass';\nimport '@descope-ui/descope-text';\n\ncustomElements.define(componentName, DividerClass);\n\nexport { DividerClass, 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: { selector: () => ':host', property: 'width' },\n hostDirection: { selector: () => ':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"],"names":["componentName","RawDivider","createBaseClass","baseSelector","constructor","super","this","attachShadow","mode","innerHTML","textComponent","shadowRoot","querySelector","includeAttrs","textVars","TextClass","cssVarList","host","before","after","text","selector","DividerClass","mappings","hostWidth","property","hostPadding","hostDirection","minHeight","alignItems","alignSelf","flexDirection","textAlign","labelTextWidth","labelTextMaxWidth","labelTextVerticalSpacing","labelTextHorizontalSpacing","stripeColor","stripeHorizontalThickness","stripeVerticalThickness","stripeColorOpacity","customElements","define","RawText","hideWhenEmpty","getAttribute","init","hasChildren","childNodes","length","style","display","fontSize","textColor","textLineHeight","textLetterSpacing","textShadow","textTransform","fontFamily","fontStyle","fontWeight","borderWidth","borderStyle","borderColor"],"sourceRoot":""}
1
+ {"version":3,"file":"descope-divider-index-js.js","mappings":"0QAOO,MAAMA,GAAgB,QAAiB,WAC9C,MAAMC,WAAmB,EAAAC,EAAA,GAAgB,CAAEF,gBAAeG,aAAc,iBACtE,WAAAC,GACEC,QAEAC,KAAKC,aAAa,CAAEC,KAAM,SAAUC,UAAY,+GAQhD,QACE,wiBAyBAH,MAGFA,KAAKI,cAAgBJ,KAAKK,WAAWC,cAAc,iBAEnD,QAAaN,KAAMA,KAAKI,cAAe,CACrCG,aAAc,CAAC,OAAQ,UAAW,WAEtC,EAGF,MAAMC,EAAWC,EAAA,EAAUC,YACrB,KAAEC,EAAI,OAAEC,EAAM,MAAEC,EAAOC,KAAI,GAAK,CACpCH,KAAM,CAAEI,SAAU,IAAM,SACxBH,OAAQ,CAAEG,SAAU,YACpBF,MAAO,CAAEE,SAAU,WACnBD,KAAM,CAAEC,SAAU,iBAGPC,GAAe,SAC1B,QAAiB,CACfC,SAAU,CACRC,UAAW,IAAKP,EAAMQ,SAAU,SAChCC,YAAa,IAAKT,EAAMQ,SAAU,WAClCE,cAAe,IAAK,EAAMF,SAAU,aAEpCG,UAAW,CAAC,EACZC,WAAY,CAAC,EACbC,UAAW,CAAC,EACZC,cAAe,CAAC,EAChBC,UAAW,IAAK,EAAMP,SAAUX,EAASkB,WAEzCC,eAAgB,IAAK,EAAMR,SAAU,SACrCS,kBAAmB,IAAK,EAAMT,SAAU,aACxCU,yBAA0B,CACxB,IAAK,EAAMV,SAAU,eACrB,IAAK,EAAMA,SAAU,mBAEvBW,2BAA4B,CAC1B,IAAK,EAAMX,SAAU,iBACrB,IAAK,EAAMA,SAAU,iBAGvBY,YAAa,CACX,IAAKnB,EAAQO,SAAU,oBACvB,IAAKN,EAAOM,SAAU,qBAExBa,0BAA2B,CACzB,IAAKpB,EAAQO,SAAU,UACvB,IAAKN,EAAOM,SAAU,WAExBc,wBAAyB,CACvB,IAAKrB,EAAQO,SAAU,SACvB,IAAKN,EAAOM,SAAU,UAExBe,mBAAoB,CAClB,IAAKtB,EAAQO,SAAU,WACvB,IAAKN,EAAOM,SAAU,eAI5B,KACA,KA3C0B,CA4C1BxB,G,SC1GFwC,eAAeC,OAAO1C,EAAesB,E,yFCDrCmB,eAAeC,OAAO,IAAe,I,2FCW9B,MAAM1C,GAAgB,QAAiB,QAE9C,MAAM2C,WAAgB,QAAgB,CACpC3C,gBACAG,aAAc,kBAEd,WAAAC,GACEC,QAEAC,KAAKC,aAAa,CAAEC,KAAM,SAAUC,UAAY,iDAIhD,QAAY,iLASTH,KACL,CAEA,iBAAIsC,GACF,MAAgD,SAAzCtC,KAAKuC,aAAa,kBAC3B,CAEA,IAAAC,GACEzC,MAAMyC,QAEN,QAAgBxC,MAAM,KACpB,MAAMyC,IAAgBzC,KAAK0C,WAAWC,OACtC3C,KAAK4C,MAAMC,SAAWJ,GAAezC,KAAKsC,cAAgB,OAAS,EAAE,GAEzE,EAGF,MAAM,KAAE3B,GAAS,CACfA,KAAM,CAAEI,SAAU,IAAM,UAGbN,GAAY,SACvB,QAAiB,CACfQ,SAAU,CACRC,UAAW,IAAKP,EAAMQ,SAAU,SAChCE,cAAe,IAAKV,EAAMQ,SAAU,aACpC2B,SAAU,CAAC,EACXC,UAAW,CACT,CAAE5B,SAAU,UAEd6B,eAAgB,CAAE7B,SAAU,eAC5B8B,kBAAmB,CAAE9B,SAAU,kBAC/B+B,WAAY,CAAC,EACbxB,UAAW,CAAC,EACZyB,cAAe,CAAC,EAChBC,WAAY,CAAC,EACbC,UAAW,CAAC,EACZC,WAAY,CAAC,EACbC,YAAa,CAAC,EACdC,YAAa,CAAC,EACdC,YAAa,CAAC,KAGlB,KACA,KAvBuB,CAwBvBpB,E","sources":["webpack://@descope/web-components-ui/./src/components/descope-divider/DividerClass.js","webpack://@descope/web-components-ui/./src/components/descope-divider/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"],"sourcesContent":["import { createStyleMixin, draggableMixin, componentNameValidationMixin } from '../../mixins';\nimport { createBaseClass } from '../../baseClasses/createBaseClass';\nimport { compose } from '../../helpers';\nimport { forwardAttrs, getComponentName } from '../../helpers/componentHelpers';\nimport { TextClass } from '@descope-ui/descope-text/class';\nimport { injectStyle } from '@descope-ui/common/components-helpers';\n\nexport const componentName = getComponentName('divider');\nclass RawDivider extends createBaseClass({ componentName, baseSelector: ':host > div' }) {\n constructor() {\n super();\n\n this.attachShadow({ mode: 'open' }).innerHTML = `\n\t\t\t<div>\n\t\t\t\t<descope-text>\n\t\t\t\t\t<slot></slot>\n\t\t\t\t</descope-text>\n\t\t\t</div>\n\t\t`;\n\n injectStyle(\n `\n \t:host {\n\t\t\t\t\tdisplay: inline-block;\n\t\t\t\t}\n\t\t\t\t:host > div {\n\t\t\t\t\tdisplay: flex;\n\t\t\t\t\theight: 100%;\n\t\t\t\t\twidth: 100%;\n\t\t\t\t}\n\t\t\t\t:host > div::before,\n\t\t\t\t:host > div::after {\n\t\t\t\t\tcontent: '';\n\t\t\t\t\tflex-grow: 1;\n\t\t\t\t}\n\t\t\t\tdescope-text {\n\t\t\t\t\tflex-grow: 0;\n\t\t\t\t\tflex-shrink: 0;\n\t\t\t\t}\n\t\t\t\t:host(:empty) descope-text {\n\t\t\t\t\tdisplay: none;\n\t\t\t\t}\n\t\t\t\t:host([vertical=\"true\"]) div {\n\t\t\t\t\twidth: fit-content;\n\t\t\t\t}\n `,\n this\n );\n\n this.textComponent = this.shadowRoot.querySelector('descope-text');\n\n forwardAttrs(this, this.textComponent, {\n includeAttrs: ['mode', 'variant', 'italic'],\n });\n }\n}\n\nconst textVars = TextClass.cssVarList;\nconst { host, before, after, text } = {\n host: { selector: () => ':host' },\n before: { selector: '::before' },\n after: { selector: '::after' },\n text: { selector: 'descope-text' },\n};\n\nexport const DividerClass = compose(\n createStyleMixin({\n mappings: {\n hostWidth: { ...host, property: 'width' },\n hostPadding: { ...host, property: 'padding' },\n hostDirection: { ...text, property: 'direction' },\n\n minHeight: {},\n alignItems: {},\n alignSelf: {},\n flexDirection: {},\n textAlign: { ...text, property: textVars.textAlign },\n\n labelTextWidth: { ...text, property: 'width' },\n labelTextMaxWidth: { ...text, property: 'max-width' },\n labelTextVerticalSpacing: [\n { ...text, property: 'padding-top' },\n { ...text, property: 'padding-bottom' },\n ],\n labelTextHorizontalSpacing: [\n { ...text, property: 'padding-right' },\n { ...text, property: 'padding-left' },\n ],\n\n stripeColor: [\n { ...before, property: 'background-color' },\n { ...after, property: 'background-color' },\n ],\n stripeHorizontalThickness: [\n { ...before, property: 'height' },\n { ...after, property: 'height' },\n ],\n stripeVerticalThickness: [\n { ...before, property: 'width' },\n { ...after, property: 'width' },\n ],\n stripeColorOpacity: [\n { ...before, property: 'opacity' },\n { ...after, property: 'opacity' },\n ],\n },\n }),\n draggableMixin,\n componentNameValidationMixin\n)(RawDivider);\n","import { componentName, DividerClass } from './DividerClass';\nimport '@descope-ui/descope-text';\n\ncustomElements.define(componentName, DividerClass);\n\nexport { DividerClass, 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"],"names":["componentName","RawDivider","createBaseClass","baseSelector","constructor","super","this","attachShadow","mode","innerHTML","textComponent","shadowRoot","querySelector","includeAttrs","textVars","TextClass","cssVarList","host","before","after","text","selector","DividerClass","mappings","hostWidth","property","hostPadding","hostDirection","minHeight","alignItems","alignSelf","flexDirection","textAlign","labelTextWidth","labelTextMaxWidth","labelTextVerticalSpacing","labelTextHorizontalSpacing","stripeColor","stripeHorizontalThickness","stripeVerticalThickness","stripeColorOpacity","customElements","define","RawText","hideWhenEmpty","getAttribute","init","hasChildren","childNodes","length","style","display","fontSize","textColor","textLineHeight","textLetterSpacing","textShadow","textTransform","fontFamily","fontStyle","fontWeight","borderWidth","borderStyle","borderColor"],"sourceRoot":""}
@@ -1,2 +1,2 @@
1
- "use strict";(self.webpackChunk_descope_web_components_ui=self.webpackChunk_descope_web_components_ui||[]).push([[2294,4159,9261],{36976:(e,t,r)=>{r.d(t,{M:()=>o});const o=["blockquote","list","image","table","code","hr","backticks","fence","reference","heading","lheading","html_block"]},54847:(e,t,r)=>{r.d(t,{G:()=>o});const o=e=>{const t=document.createElement("textarea");return t.innerHTML=e,t.value}},55838:(e,t,r)=>{r.r(t),r.d(t,{EnrichedTextClass:()=>o.m,componentName:()=>o.T}),r(74778);var o=r(76231);customElements.define(o.T,o.m)},63595:(e,t,r)=>{r.r(t),r.d(t,{TextClass:()=>o.s,componentName:()=>o.T});var o=r(66434);customElements.define(o.T,o.s)},66434:(e,t,r)=>{r.d(t,{T:()=>l,s:()=>a});var o=r(88961),n=r(63200),s=r(25964),i=r(72270);const l=(0,s.xE)("text");class h extends((0,i.qu)({componentName:l,baseSelector:":host > slot"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <slot part="text-wrapper"></slot>\n ',(0,s.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,s.Ge)(this,(()=>{const e=!!this.childNodes.length;this.style.display=!e&&this.hideWhenEmpty?"none":""}))}}const{host:c}={host:{selector:()=>":host"}},a=(0,n.Zz)((0,o.RF)({mappings:{hostWidth:{selector:()=>":host",property:"width"},hostDirection:{selector:()=>":host",property:"direction"},fontSize:{},textColor:[{property:"color"}],textLineHeight:{property:"line-height"},textLetterSpacing:{property:"letter-spacing"},textShadow:{},textAlign:{},textTransform:{},fontFamily:{},fontStyle:{},fontWeight:{},borderWidth:{},borderStyle:{},borderColor:{}}}),o.VO,o.tQ)(h)},74778:(e,t,r)=>{r.r(t),r.d(t,{LinkClass:()=>k,componentName:()=>h});var o=r(88961),n=r(63200),s=r(25964),i=r(72270),l=r(66434);const h=(0,s.xE)("link");class c extends((0,i.qu)({componentName:h,baseSelector:":host a"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML="\n\t\t<div>\n\t\t\t<descope-text>\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",(0,s.fz)("\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 ",this),(0,s.EA)(this,this.shadowRoot.querySelector("a"),{includeAttrs:["href","target","tooltip"],mapAttrs:{tooltip:"title"}}),(0,s.EA)(this,this.shadowRoot.querySelector("descope-text"),{includeAttrs:["mode","variant"]})}}const a={host:{selector:()=>":host"},link:{selector:()=>":host a"},anchor:{},wrapper:{selector:()=>":host > div"},text:{selector:()=>l.s.componentName}},{anchor:d,text:p,host:m,wrapper:u,link:g}=a,k=(0,n.Zz)((0,o.RF)({mappings:{hostWidth:{...m,property:"width"},hostDirection:{...p,property:"direction"},textAlign:u,textDecoration:{...g,property:"text-decoration",fallback:"none"},textColor:[{...d,property:"color"},{...p,property:l.s.cssVarList.textColor}],cursor:d}}),o.VO,o.tQ)(c);r(63595),customElements.define(h,k)},76231:(e,t,r)=>{r.d(t,{T:()=>a,m:()=>p});var o=r(92540),n=r(88961),s=r(63200),i=r(36976),l=r(72270),h=r(54847),c=r(25964);const a=(0,c.xE)("enriched-text");class d extends((0,l.qu)({componentName:a,baseSelector:":host > div"})){#e;#t;constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <div class="content"></div>\n ',(0,c.fz)("\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 ",this),this.#r(),(0,c.Ge)(this,this.#o.bind(this))}static get observedAttributes(){return["readonly","link-target-blank"]}attributeChangedCallback(e,t,r){super.attributeChangedCallback?.(e,t,r),r!==t&&("readonly"===e&&this.onReadOnlyChange("true"===r),"link-target-blank"===e&&this.#r())}customUnderlineRenderer(){this.processor.renderer.rules.em_open=(e,t,r,o,n)=>("_"===e[t].markup&&(e[t].tag="u"),this.#t(e,t,r,o,n)),this.processor.renderer.rules.em_close=(e,t,r,o,n)=>("_"===e[t].markup&&(e[t].tag="u"),this.#t(e,t,r,o,n))}#n(){this.linkTargetBlank?this.processor.renderer.rules.link_open=(e,t,r,o,n)=>(e[t].attrSet("target","_blank"),this.#e(e,t,r,o,n)):this.processor.renderer.rules.link_open=this.#e}#s(){this.processor&&this.processor.disable(i.M)}#i(){this.#s()}#l(){this.#e=this.processor.renderer.rules.link_open||((e,t,r,o,n)=>n.renderToken(e,t,r)),this.#t=this.processor.renderer.rules.em_open||((e,t,r,o,n)=>n.renderToken(e,t,r))}#r(){this.processor=new o.A("commonmark",{html:!0}),this.#l(),this.#i(),this.#n(),this.customUnderlineRenderer()}get linkTargetBlank(){return"true"===this.getAttribute("link-target-blank")}get contentNode(){return this.shadowRoot.querySelector(".content")}#o(){if(!this.processor)return;let e=(0,h.G)(this.innerHTML);!e?.trim()&&this.isConnected?this.setAttribute("empty","true"):this.removeAttribute("empty");try{const t=this.processor.parse(e,{references:void 0});e=this.processor.renderer.render(t,{html:!0,breaks:!0})}catch(e){console.warn("Not parsing invalid markdown token")}this.contentNode.innerHTML=e}onReadOnlyChange(e){e?this.contentNode.setAttribute("inert",e):this.contentNode.removeAttribute("inert")}}const p=(0,s.Zz)((0,n.RF)({mappings:{hostWidth:{selector:()=>":host",property:"width"},hostDisplay:{selector:()=>":host",property:"display",fallback:"inline-block"},hostDirection:{selector:()=>":host",property:"direction"},fontSize:{},fontFamily:{},fontWeight:{},fontWeightBold:[{selector:()=>":host strong",property:"font-weight"},{selector:()=>":host b",property:"font-weight"}],textColor:{property:"color"},textLineHeight:{property:"line-height"},textAlign:{},linkColor:{selector:"a",property:"color"},linkTextDecoration:{selector:"a",property:"text-decoration"},linkHoverTextDecoration:{selector:"a:hover",property:"text-decoration"},minHeight:{},minWidth:{}}}),(0,n.RF)({componentNameOverride:(0,c.xE)("link")}),(0,n.RF)({componentNameOverride:(0,c.xE)("text")}),n.VO,n.tQ)(d)}}]);
1
+ "use strict";(self.webpackChunk_descope_web_components_ui=self.webpackChunk_descope_web_components_ui||[]).push([[2294,4159,9261],{36976:(e,t,r)=>{r.d(t,{M:()=>n});const n=["blockquote","list","image","table","code","hr","backticks","fence","reference","heading","lheading","html_block"]},54847:(e,t,r)=>{r.d(t,{G:()=>n});const n=e=>{const t=document.createElement("textarea");return t.innerHTML=e,t.value}},55838:(e,t,r)=>{r.r(t),r.d(t,{EnrichedTextClass:()=>n.m,componentName:()=>n.T}),r(74778);var n=r(76231);customElements.define(n.T,n.m)},63595:(e,t,r)=>{r.r(t),r.d(t,{TextClass:()=>n.s,componentName:()=>n.T});var n=r(66434);customElements.define(n.T,n.s)},66434:(e,t,r)=>{r.d(t,{T:()=>l,s:()=>a});var n=r(88961),o=r(63200),s=r(25964),i=r(72270);const l=(0,s.xE)("text");class h extends((0,i.qu)({componentName:l,baseSelector:":host > slot"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <slot part="text-wrapper"></slot>\n ',(0,s.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,s.Ge)(this,(()=>{const e=!!this.childNodes.length;this.style.display=!e&&this.hideWhenEmpty?"none":""}))}}const{host:c}={host:{selector:()=>":host"}},a=(0,o.Zz)((0,n.RF)({mappings:{hostWidth:{...c,property:"width"},hostDirection:{...c,property:"direction"},fontSize:{},textColor:[{property:"color"}],textLineHeight:{property:"line-height"},textLetterSpacing:{property:"letter-spacing"},textShadow:{},textAlign:{},textTransform:{},fontFamily:{},fontStyle:{},fontWeight:{},borderWidth:{},borderStyle:{},borderColor:{}}}),n.VO,n.tQ)(h)},74778:(e,t,r)=>{r.r(t),r.d(t,{LinkClass:()=>k,componentName:()=>h});var n=r(88961),o=r(63200),s=r(25964),i=r(72270),l=r(66434);const h=(0,s.xE)("link");class c extends((0,i.qu)({componentName:h,baseSelector:":host a"})){constructor(){super(),this.attachShadow({mode:"open"}).innerHTML="\n\t\t<div>\n\t\t\t<descope-text>\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",(0,s.fz)("\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 ",this),(0,s.EA)(this,this.shadowRoot.querySelector("a"),{includeAttrs:["href","target","tooltip"],mapAttrs:{tooltip:"title"}}),(0,s.EA)(this,this.shadowRoot.querySelector("descope-text"),{includeAttrs:["mode","variant"]})}}const a={host:{selector:()=>":host"},link:{selector:()=>":host a"},anchor:{},wrapper:{selector:()=>":host > div"},text:{selector:()=>l.s.componentName}},{anchor:d,text:p,host:m,wrapper:u,link:g}=a,k=(0,o.Zz)((0,n.RF)({mappings:{hostWidth:{...m,property:"width"},hostDirection:{...p,property:"direction"},textAlign:u,textDecoration:{...g,property:"text-decoration",fallback:"none"},textColor:[{...d,property:"color"},{...p,property:l.s.cssVarList.textColor}],cursor:d}}),n.VO,n.tQ)(c);r(63595),customElements.define(h,k)},76231:(e,t,r)=>{r.d(t,{T:()=>a,m:()=>p});var n=r(92540),o=r(88961),s=r(63200),i=r(36976),l=r(72270),h=r(54847),c=r(25964);const a=(0,c.xE)("enriched-text");class d extends((0,l.qu)({componentName:a,baseSelector:":host > div"})){#e;#t;constructor(){super(),this.attachShadow({mode:"open"}).innerHTML='\n <div class="content"></div>\n ',(0,c.fz)("\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 ",this),this.#r(),(0,c.Ge)(this,this.#n.bind(this))}static get observedAttributes(){return["readonly","link-target-blank"]}attributeChangedCallback(e,t,r){super.attributeChangedCallback?.(e,t,r),r!==t&&("readonly"===e&&this.onReadOnlyChange("true"===r),"link-target-blank"===e&&this.#r())}customUnderlineRenderer(){this.processor.renderer.rules.em_open=(e,t,r,n,o)=>("_"===e[t].markup&&(e[t].tag="u"),this.#t(e,t,r,n,o)),this.processor.renderer.rules.em_close=(e,t,r,n,o)=>("_"===e[t].markup&&(e[t].tag="u"),this.#t(e,t,r,n,o))}#o(){this.linkTargetBlank?this.processor.renderer.rules.link_open=(e,t,r,n,o)=>(e[t].attrSet("target","_blank"),this.#e(e,t,r,n,o)):this.processor.renderer.rules.link_open=this.#e}#s(){this.processor&&this.processor.disable(i.M)}#i(){this.#s()}#l(){this.#e=this.processor.renderer.rules.link_open||((e,t,r,n,o)=>o.renderToken(e,t,r)),this.#t=this.processor.renderer.rules.em_open||((e,t,r,n,o)=>o.renderToken(e,t,r))}#r(){this.processor=new n.A("commonmark",{html:!0}),this.#l(),this.#i(),this.#o(),this.customUnderlineRenderer()}get linkTargetBlank(){return"true"===this.getAttribute("link-target-blank")}get contentNode(){return this.shadowRoot.querySelector(".content")}#n(){if(!this.processor)return;let e=(0,h.G)(this.innerHTML);!e?.trim()&&this.isConnected?this.setAttribute("empty","true"):this.removeAttribute("empty");try{const t=this.processor.parse(e,{references:void 0});e=this.processor.renderer.render(t,{html:!0,breaks:!0})}catch(e){console.warn("Not parsing invalid markdown token")}this.contentNode.innerHTML=e}onReadOnlyChange(e){e?this.contentNode.setAttribute("inert",e):this.contentNode.removeAttribute("inert")}}const p=(0,s.Zz)((0,o.RF)({mappings:{hostWidth:{selector:()=>":host",property:"width"},hostDisplay:{selector:()=>":host",property:"display",fallback:"inline-block"},hostDirection:{selector:()=>":host",property:"direction"},fontSize:{},fontFamily:{},fontWeight:{},fontWeightBold:[{selector:()=>":host strong",property:"font-weight"},{selector:()=>":host b",property:"font-weight"}],textColor:{property:"color"},textLineHeight:{property:"line-height"},textAlign:{},linkColor:{selector:"a",property:"color"},linkTextDecoration:{selector:"a",property:"text-decoration"},linkHoverTextDecoration:{selector:"a:hover",property:"text-decoration"},minHeight:{},minWidth:{}}}),(0,o.RF)({componentNameOverride:(0,c.xE)("link")}),(0,o.RF)({componentNameOverride:(0,c.xE)("text")}),o.VO,o.tQ)(d)}}]);
2
2
  //# sourceMappingURL=descope-enriched-text.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"descope-enriched-text.js","mappings":"oKAAO,MAAMA,EAAe,CAC1B,aACA,OACA,QACA,QACA,OACA,KACA,YACA,QACA,YACA,UACA,WACA,a,mCCZK,MAAMC,EAAcC,IACzB,MAAMC,EAAWC,SAASC,cAAc,YAExC,OADAF,EAASG,UAAYJ,EACdC,EAASI,KAAK,C,0GCCvBC,eAAeC,OAAO,IAAe,I,yFCFrCD,eAAeC,OAAO,IAAe,I,2FCW9B,MAAMC,GAAgB,QAAiB,QAE9C,MAAMC,WAAgB,QAAgB,CACpCD,gBACAE,aAAc,kBAEd,WAAAC,GACEC,QAEAC,KAAKC,aAAa,CAAEC,KAAM,SAAUX,UAAY,iDAIhD,QAAY,iLASTS,KACL,CAEA,iBAAIG,GACF,MAAgD,SAAzCH,KAAKI,aAAa,kBAC3B,CAEA,IAAAC,GACEN,MAAMM,QAEN,QAAgBL,MAAM,KACpB,MAAMM,IAAgBN,KAAKO,WAAWC,OACtCR,KAAKS,MAAMC,SAAWJ,GAAeN,KAAKG,cAAgB,OAAS,EAAE,GAEzE,EAGF,MAAM,KAAEQ,GAAS,CACfA,KAAM,CAAEC,SAAU,IAAM,UAGbC,GAAY,SACvB,QAAiB,CACfC,SAAU,CACRC,UAAW,CAAEH,SAAU,IAAM,QAASI,SAAU,SAChDC,cAAe,CAAEL,SAAU,IAAM,QAASI,SAAU,aACpDE,SAAU,CAAC,EACXC,UAAW,CACT,CAAEH,SAAU,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AAM,eAAgBI,SAAU,eAC5C,CAAEJ,SAAU,IAAM,UAAWI,SAAU,gBAEzCG,UAAW,CAAEH,SAAU,SACvBI,eAAgB,CAAEJ,SAAU,eAC5BO,UAAW,CAAC,EACZoE,UAAW,CAAE/E,SAAU,IAAKI,SAAU,SACtC4E,mBAAoB,CAAEhF,SAAU,IAAKI,SAAU,mBAC/C6E,wBAAyB,CAAEjF,SAAU,UAAWI,SAAU,mBAC1D8E,UAAW,CAAC,EACZC,SAAU,CAAC,MAGf,QAAiB,CAAEC,uBAAuB,QAAiB,WAC3D,QAAiB,CAAEA,uBAAuB,QAAiB,UAC3D,KACA,KA1B+B,CA2B/BjD,E","sources":["webpack://@descope/web-components-ui/../components/descope-enriched-text/src/component/consts.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"],"sourcesContent":["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","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: { selector: () => ':host', property: 'width' },\n hostDirection: { selector: () => ':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>\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 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 }\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"],"names":["disableRules","decodeHTML","html","textArea","document","createElement","innerHTML","value","customElements","define","componentName","RawText","baseSelector","constructor","super","this","attachShadow","mode","hideWhenEmpty","getAttribute","init","hasChildren","childNodes","length","style","display","host","selector","TextClass","mappings","hostWidth","property","hostDirection","fontSize","textColor","textLineHeight","textLetterSpacing","textShadow","textAlign","textTransform","fontFamily","fontStyle","fontWeight","borderWidth","borderStyle","borderColor","RawLink","shadowRoot","querySelector","includeAttrs","mapAttrs","tooltip","selectors","link","anchor","wrapper","text","LinkClass","textDecoration","fallback","cssVarList","cursor","EnrichedText","bind","observedAttributes","attributeChangedCallback","attrName","oldValue","newValue","onReadOnlyChange","customUnderlineRenderer","processor","renderer","rules","em_open","tokens","idx","options","env","self","markup","tag","em_close","linkTargetBlank","link_open","attrSet","disable","_","renderToken","contentNode","trim","isConnected","setAttribute","removeAttribute","parse","references","undefined","render","breaks","e","console","warn","isReadOnly","EnrichedTextClass","hostDisplay","fontWeightBold","linkColor","linkTextDecoration","linkHoverTextDecoration","minHeight","minWidth","componentNameOverride"],"sourceRoot":""}
1
+ {"version":3,"file":"descope-enriched-text.js","mappings":"oKAAO,MAAMA,EAAe,CAC1B,aACA,OACA,QACA,QACA,OACA,KACA,YACA,QACA,YACA,UACA,WACA,a,mCCZK,MAAMC,EAAcC,IACzB,MAAMC,EAAWC,SAASC,cAAc,YAExC,OADAF,EAASG,UAAYJ,EACdC,EAASI,KAAK,C,0GCCvBC,eAAeC,OAAO,IAAe,I,yFCFrCD,eAAeC,OAAO,IAAe,I,2FCW9B,MAAMC,GAAgB,QAAiB,QAE9C,MAAMC,WAAgB,QAAgB,CACpC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ASyB,OAAOtB,EAAQ,CAAEzE,MAAM,EAAMgG,QAAQ,GACtE,CAAE,MAAOC,GAEPC,QAAQC,KAAK,qCACf,CAEAtF,KAAK0E,YAAYnF,UAAYJ,CAC/B,CAEA,gBAAAmE,CAAiBiC,GACXA,EACFvF,KAAK0E,YAAYG,aAAa,QAASU,GAEvCvF,KAAK0E,YAAYI,gBAAgB,QAErC,EAGK,MAAMU,GAAoB,SAC/B,QAAiB,CACf1E,SAAU,CACRC,UAAW,CAAEH,SAAU,IAAM,QAASI,SAAU,SAChDyE,YAAa,CAAE7E,SAAU,IAAM,QAASI,SAAU,UAAW4B,SAAU,gBACvE3B,cAAe,CAAEL,SAAU,IAAM,QAASI,SAAU,aACpDE,SAAU,CAAC,EACXO,WAAY,CAAC,EACbE,WAAY,CAAC,EACb+D,eAAgB,CACd,CAAE9E,SAAU,IAAM,eAAgBI,SAAU,eAC5C,CAAEJ,SAAU,IAAM,UAAWI,SAAU,gBAEzCG,UAAW,CAAEH,SAAU,SACvBI,eAAgB,CAAEJ,SAAU,eAC5BO,UAAW,CAAC,EACZoE,UAAW,CAAE/E,SAAU,IAAKI,SAAU,SACtC4E,mBAAoB,CAAEhF,SAAU,IAAKI,SAAU,mBAC/C6E,wBAAyB,CAAEjF,SAAU,UAAWI,SAAU,mBAC1D8E,UAAW,CAAC,EACZC,SAAU,CAAC,MAGf,QAAiB,CAAEC,uBAAuB,QAAiB,WAC3D,QAAiB,CAAEA,uBAAuB,QAAiB,UAC3D,KACA,KA1B+B,CA2B/BjD,E","sources":["webpack://@descope/web-components-ui/../components/descope-enriched-text/src/component/consts.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"],"sourcesContent":["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","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>\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 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 }\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"],"names":["disableRules","decodeHTML","html","textArea","document","createElement","innerHTML","value","customElements","define","componentName","RawText","baseSelector","constructor","super","this","attachShadow","mode","hideWhenEmpty","getAttribute","init","hasChildren","childNodes","length","style","display","host","selector","TextClass","mappings","hostWidth","property","hostDirection","fontSize","textColor","textLineHeight","textLetterSpacing","textShadow","textAlign","textTransform","fontFamily","fontStyle","fontWeight","borderWidth","borderStyle","borderColor","RawLink","shadowRoot","querySelector","includeAttrs","mapAttrs","tooltip","selectors","link","anchor","wrapper","text","LinkClass","textDecoration","fallback","cssVarList","cursor","EnrichedText","bind","observedAttributes","attributeChangedCallback","attrName","oldValue","newValue","onReadOnlyChange","customUnderlineRenderer","processor","renderer","rules","em_open","tokens","idx","options","env","self","markup","tag","em_close","linkTargetBlank","link_open","attrSet","disable","_","renderToken","contentNode","trim","isConnected","setAttribute","removeAttribute","parse","references","undefined","render","breaks","e","console","warn","isReadOnly","EnrichedTextClass","hostDisplay","fontWeightBold","linkColor","linkTextDecoration","linkHoverTextDecoration","minHeight","minWidth","componentNameOverride"],"sourceRoot":""}