@rededor/cura 2.0.0-alpha.12 → 2.0.0-alpha.14

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 (161) hide show
  1. package/dist/cjs/{cura-accordion_21.cjs.entry.js → cura-accordion_22.cjs.entry.js} +6923 -16
  2. package/dist/cjs/cura-checkbox.cjs.entry.js +1 -1
  3. package/dist/cjs/cura-display.cjs.entry.js +1 -1
  4. package/dist/cjs/cura-dropdown-search-not-found.cjs.entry.js +1 -1
  5. package/dist/cjs/cura-icons-view.cjs.entry.js +1 -1
  6. package/dist/cjs/cura-input-date.cjs.entry.js +1 -1
  7. package/dist/cjs/cura-loader-bar.cjs.entry.js +1 -1
  8. package/dist/cjs/cura-modal.cjs.entry.js +1 -1
  9. package/dist/cjs/cura-progress-bar_2.cjs.entry.js +2 -2
  10. package/dist/cjs/cura-radio.cjs.entry.js +1 -1
  11. package/dist/cjs/cura-stepper.cjs.entry.js +1 -1
  12. package/dist/cjs/cura-switch.cjs.entry.js +1 -1
  13. package/dist/cjs/cura-tabs-button.cjs.entry.js +1 -1
  14. package/dist/cjs/cura-tabs-transparent.cjs.entry.js +1 -1
  15. package/dist/cjs/cura-toast.cjs.entry.js +1 -1
  16. package/dist/cjs/cura-tooltip.cjs.entry.js +1 -1
  17. package/dist/cjs/cura.cjs.js +1 -1
  18. package/dist/cjs/index.cjs.js +1140 -0
  19. package/dist/cjs/loader.cjs.js +1 -1
  20. package/dist/collection/components/cura-calendar/cura-calendar.css +40 -1
  21. package/dist/collection/components/cura-calendar/cura-calendar.js +154 -3
  22. package/dist/collection/components/cura-calendar/cura-calendar.stories.js +39 -1
  23. package/dist/collection/components/cura-calendar/cura-calendar.type.js +1 -0
  24. package/dist/collection/components/cura-card/cura-card.js +1 -1
  25. package/dist/collection/components/cura-dropdown-search/cura-dropdown-search-category/cura-dropdown-search-category.js +1 -1
  26. package/dist/collection/components/cura-dropdown-search/cura-dropdown-search-not-found/cura-dropdown-search-not-found.js +1 -1
  27. package/dist/collection/components/cura-dropdown-search/cura-dropdown-search-option/cura-dropdown-search-option.js +1 -1
  28. package/dist/collection/components/cura-dropdown-search/cura-dropdown-search.js +1 -1
  29. package/dist/collection/components/cura-icon/cura-icon.js +1 -1
  30. package/dist/collection/components/cura-icons-view/cura-icons-view.js +1 -1
  31. package/dist/collection/components/cura-modal/cura-modal.js +1 -1
  32. package/dist/collection/components/cura-page-template/cura-page-template.js +1 -1
  33. package/dist/collection/components/cura-stepper/cura-progress-bar/cura-progress-bar.js +1 -1
  34. package/dist/collection/components/cura-stepper/cura-stepper-item/cura-stepper-item.js +1 -1
  35. package/dist/collection/components/cura-stepper/cura-stepper.js +1 -1
  36. package/dist/collection/components/cura-toast/cura-toast.js +1 -1
  37. package/dist/collection/components/cura-tooltip/cura-tooltip.js +1 -1
  38. package/dist/collection/components/forms/cura-checkbox/cura-checkbox.js +1 -1
  39. package/dist/collection/components/forms/cura-input-date/cura-input-date.js +1 -1
  40. package/dist/collection/components/forms/cura-label/cura-label.js +1 -1
  41. package/dist/collection/components/forms/cura-radio/cura-radio.js +1 -1
  42. package/dist/collection/components/forms/cura-select/cura-select.js +3 -3
  43. package/dist/collection/components/forms/cura-select-options/cura-select-option.js +1 -1
  44. package/dist/collection/components/forms/cura-switch/cura-switch.js +1 -1
  45. package/dist/collection/components/loaders/cura-loader-bar/cura-loader-bar.js +1 -1
  46. package/dist/collection/components/loaders/cura-loader-circle/cura-loader-circle.js +1 -1
  47. package/dist/collection/components/tabs/cura-tabs/cura-tabs.js +1 -1
  48. package/dist/collection/components/tabs/cura-tabs-button/cura-tabs-button.js +1 -1
  49. package/dist/collection/components/tabs/cura-tabs-group/cura-tabs-group.js +1 -1
  50. package/dist/collection/components/tabs/cura-tabs-transparent/cura-tabs-transparent.js +1 -1
  51. package/dist/collection/components/text/cura-display/cura-display.js +1 -1
  52. package/dist/collection/components/text/cura-heading/cura-heading.js +1 -1
  53. package/dist/collection/components/text/cura-paragraph/cura-paragraph.js +1 -1
  54. package/dist/collection/index.js +2 -0
  55. package/dist/components/cura-accordion-item.js +1 -1
  56. package/dist/components/cura-alert.js +1 -1
  57. package/dist/components/cura-badge-counter.js +1 -1
  58. package/dist/components/cura-badge-distance.js +1 -1
  59. package/dist/components/cura-badge-pill.js +1 -1
  60. package/dist/components/cura-button-outline.js +1 -1
  61. package/dist/components/cura-button-select.js +1 -1
  62. package/dist/components/cura-button-transparent.js +1 -1
  63. package/dist/components/cura-button.js +1 -1
  64. package/dist/components/cura-calendar.js +1 -1
  65. package/dist/components/cura-card.js +1 -1
  66. package/dist/components/cura-checkbox.js +1 -1
  67. package/dist/components/cura-display.js +1 -1
  68. package/dist/components/cura-dropdown-search-category.js +1 -1
  69. package/dist/components/cura-dropdown-search-not-found.js +1 -1
  70. package/dist/components/cura-dropdown-search-option.js +1 -1
  71. package/dist/components/cura-dropdown-search.js +1 -1
  72. package/dist/components/cura-heading.js +1 -1
  73. package/dist/components/cura-icon.js +1 -1
  74. package/dist/components/cura-icons-view.js +1 -1
  75. package/dist/components/cura-input-date.js +1 -1
  76. package/dist/components/cura-input-text.js +1 -1
  77. package/dist/components/cura-label.js +1 -1
  78. package/dist/components/cura-loader-bar.js +1 -1
  79. package/dist/components/cura-loader-circle.js +1 -1
  80. package/dist/components/cura-modal.js +1 -1
  81. package/dist/components/cura-page-template.js +1 -1
  82. package/dist/components/cura-paragraph.js +1 -1
  83. package/dist/components/cura-progress-bar.js +1 -1
  84. package/dist/components/cura-radio.js +1 -1
  85. package/dist/components/cura-select-option.js +1 -1
  86. package/dist/components/cura-select.js +1 -1
  87. package/dist/components/cura-stepper-item.js +1 -1
  88. package/dist/components/cura-stepper.js +1 -1
  89. package/dist/components/cura-switch.js +1 -1
  90. package/dist/components/cura-tabs-button.js +1 -1
  91. package/dist/components/cura-tabs-group.js +1 -1
  92. package/dist/components/cura-tabs-transparent.js +1 -1
  93. package/dist/components/cura-tabs.js +1 -1
  94. package/dist/components/cura-toast.js +1 -1
  95. package/dist/components/cura-tooltip.js +1 -1
  96. package/dist/components/index.js +1 -1
  97. package/dist/components/{p-B2RN7oe_.js → p-BBtCzdwH.js} +1 -1
  98. package/dist/components/{p-fR02COZb.js → p-BFGkepgq.js} +1 -1
  99. package/dist/components/{p-CCkEqDZb.js → p-BGBnVlL3.js} +1 -1
  100. package/dist/components/{p-B8xnU6YS.js → p-BJafC0R3.js} +1 -1
  101. package/dist/components/{p-BYA8glxD.js → p-BOQ-9WHP.js} +1 -1
  102. package/dist/components/{p-DXlGQp3a.js → p-BXFxWVl3.js} +1 -1
  103. package/dist/components/{p-D7WNwjv-.js → p-Bac-rr_f.js} +1 -1
  104. package/dist/components/{p-C7so9xnO.js → p-BmMvoH-m.js} +1 -1
  105. package/dist/components/p-CalvBU-U.js +1 -0
  106. package/dist/components/{p-BSdkRryc.js → p-Cm1Vfoc6.js} +1 -1
  107. package/dist/components/{p-fn4zJrKE.js → p-DI66_jP6.js} +1 -1
  108. package/dist/components/{p-D6xuYQiO.js → p-DbZtk_CM.js} +1 -1
  109. package/dist/components/{p-DxJedO3K.js → p-I4AXUk2V.js} +1 -1
  110. package/dist/components/{p-CpmZ68rD.js → p-Oyg5hynZ.js} +1 -1
  111. package/dist/components/p-nqT7t82E.js +1 -0
  112. package/dist/cura/cura.esm.js +1 -1
  113. package/dist/cura/index.esm.js +1 -1
  114. package/dist/cura/{p-b14ae206.entry.js → p-04b5c710.entry.js} +1 -1
  115. package/dist/cura/{p-bf99e8bf.entry.js → p-18a1cadf.entry.js} +1 -1
  116. package/dist/cura/{p-2e2e2b4d.entry.js → p-1ecb2249.entry.js} +1 -1
  117. package/dist/cura/{p-b7369d04.entry.js → p-2572a4f9.entry.js} +1 -1
  118. package/dist/cura/{p-42e72d12.entry.js → p-604f1c1d.entry.js} +1 -1
  119. package/dist/cura/{p-ddf4d240.entry.js → p-71fffffa.entry.js} +1 -1
  120. package/dist/cura/{p-c247c93b.entry.js → p-8b29b763.entry.js} +1 -1
  121. package/dist/cura/{p-9de85de6.entry.js → p-906c8b66.entry.js} +1 -1
  122. package/dist/cura/{p-7965fe63.entry.js → p-a5c4849c.entry.js} +1 -1
  123. package/dist/cura/{p-3a3202f0.entry.js → p-a72db13d.entry.js} +1 -1
  124. package/dist/cura/{p-f911a6c5.entry.js → p-b447fca2.entry.js} +1 -1
  125. package/dist/cura/p-c287c69e.entry.js +1 -0
  126. package/dist/cura/{p-c18d7f16.entry.js → p-c987ddde.entry.js} +1 -1
  127. package/dist/cura/{p-1dc9c478.entry.js → p-f072b011.entry.js} +1 -1
  128. package/dist/cura/{p-5357f7bd.entry.js → p-f407bd73.entry.js} +1 -1
  129. package/dist/cura/p-f638eda8.entry.js +1 -0
  130. package/dist/esm/{cura-accordion_21.entry.js → cura-accordion_22.entry.js} +6923 -17
  131. package/dist/esm/cura-checkbox.entry.js +1 -1
  132. package/dist/esm/cura-display.entry.js +1 -1
  133. package/dist/esm/cura-dropdown-search-not-found.entry.js +1 -1
  134. package/dist/esm/cura-icons-view.entry.js +1 -1
  135. package/dist/esm/cura-input-date.entry.js +1 -1
  136. package/dist/esm/cura-loader-bar.entry.js +1 -1
  137. package/dist/esm/cura-modal.entry.js +1 -1
  138. package/dist/esm/cura-progress-bar_2.entry.js +2 -2
  139. package/dist/esm/cura-radio.entry.js +1 -1
  140. package/dist/esm/cura-stepper.entry.js +1 -1
  141. package/dist/esm/cura-switch.entry.js +1 -1
  142. package/dist/esm/cura-tabs-button.entry.js +1 -1
  143. package/dist/esm/cura-tabs-transparent.entry.js +1 -1
  144. package/dist/esm/cura-toast.entry.js +1 -1
  145. package/dist/esm/cura-tooltip.entry.js +1 -1
  146. package/dist/esm/cura.js +1 -1
  147. package/dist/esm/index.js +1140 -0
  148. package/dist/esm/loader.js +1 -1
  149. package/dist/types/components/cura-calendar/cura-calendar.d.ts +32 -0
  150. package/dist/types/components/cura-calendar/cura-calendar.stories.d.ts +40 -0
  151. package/dist/types/components/cura-calendar/cura-calendar.type.d.ts +4 -0
  152. package/dist/types/components.d.ts +35 -0
  153. package/dist/types/index.d.ts +1 -0
  154. package/package.json +2 -2
  155. package/dist/cjs/cura-calendar.cjs.entry.js +0 -6840
  156. package/dist/components/p-Bf21UQXV.js +0 -1
  157. package/dist/components/p-CG1lz5DR.js +0 -1
  158. package/dist/cura/p-27ba7ef5.entry.js +0 -1
  159. package/dist/cura/p-54624944.entry.js +0 -1
  160. package/dist/cura/p-cbe8c690.entry.js +0 -1
  161. package/dist/esm/cura-calendar.entry.js +0 -6838
@@ -1 +1 @@
1
- import{p as t,H as e,k as o,i as s,j as r,t as a}from"./p-DBXUEjWh.js";import{l as i}from"./p-CHcd-uKK.js";import{d as n}from"./p-fn4zJrKE.js";import{d as c}from"./p-BSdkRryc.js";const d=t(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.tabSelect=o(this,"tabSelect"),this.selected=!1,this.disabled=!1,this.borderBottom=!0,this.size="large",this.colorMode="light",this.hovered=!1,this.styles={}}setColors(){[{name:"--border-bottom-color",theme:"light"===this.colorMode?"neutral-base":"primary"},{name:"--border-bottom-color-selected",theme:"light"===this.colorMode?"primary-dark":"primary-lighter"}].forEach((t=>{t.theme&&(this.styles[t.name]=window.CuraAPI.theme.colors.getColor(t.theme))})),this.styles=Object.assign({},this.styles)}computeContentColor(){return this.disabled?"neutral-dark":"dark"===this.colorMode?this.hovered&&!this.selected?"neutral-purewhite":this.selected?"primary-lighter":"neutral-purewhite":this.hovered&&!this.selected?"primary-dark":this.selected?"primary-base":"neutral-black"}getIcon(){if(!this.iconName)return"";const t="large"===this.size?20:16,e=this.computeContentColor();return s("cura-icon",{name:this.iconName,size:t,color:e})}getClasses(){return{[this.size]:!0,[this.colorMode]:!0,selected:this.selected,disabled:this.disabled,"border-bottom":this.borderBottom}}connectedCallback(){this.styles=Object.assign(Object.assign({},this.styles),{"--primary-dark":window.CuraAPI.theme.colors.getColor("primary-dark"),"--neutral-purewhite":window.CuraAPI.theme.colors.getColor("neutral-purewhite"),"--base-spacing":window.CuraAPI.theme.spacing.getSpacing()}),this.setColors()}handleMouseEnter(){this.disabled||(this.hovered=!0)}handleMouseLeave(){this.hovered=!1}handleClick(t){this.disabled?t.preventDefault():(this.selected=!this.selected,this.tabSelect.emit({name:this.name}))}render(){const t=i[this.size]||i.default,e=this.computeContentColor();return s(r,{key:"d3c9e277a079381def09397dc922d697aa99d70a",role:"button","aria-pressed":this.selected,"aria-disabled":this.disabled},s("button",{key:"ab4cac9782f48c367c4ada4e303f9422971dc38e",class:this.getClasses(),style:this.styles,onClick:t=>this.handleClick(t),disabled:this.disabled,onMouseEnter:this.handleMouseEnter.bind(this),onMouseLeave:this.handleMouseLeave.bind(this)},this.getIcon(),s("cura-label",{key:"c6567bdf7b80efc3380a8a93bf52de966e1caa7d",size:t,color:e,lineHeight:"0",marginBlock:"0"},s("slot",{key:"93c392107790a2c0e3499e5b7bd742219203a980"}))))}static get watchers(){return{colorMode:[{setColors:0}]}}static get style(){return":host button,:host a{outline:none;box-shadow:none;box-sizing:border-box;display:flex;width:100%;align-items:center;justify-content:center;text-decoration:none !important;font-size:var(--font-size);cursor:pointer;transition:background-color 0.07s linear, box-shadow 0.07s linear, border-color 0.07s linear;border-radius:var(--border-radius);position:relative;background-color:transparent;box-sizing:border-box;border:none;min-width:120px;width:fit-content;display:flex;align-items:center;justify-content:center}:host button:focus,:host a:focus{outline:2px solid #6EA8FF}:host button.border-bottom,:host a.border-bottom{border-bottom:1px solid var(--border-bottom-color)}:host button.small,:host a.small{padding:calc(var(--cura-spacing-base) * 2px) calc(var(--cura-spacing-base) * 2px)}:host button.medium,:host a.medium{padding:calc(var(--cura-spacing-base) * 3px) calc(var(--cura-spacing-base) * 3px)}:host button.large,:host a.large{padding:calc(var(--cura-spacing-base) * 3px) calc(var(--cura-spacing-base) * 4px)}:host button:not(.selected),:host a:not(.selected){border-color:var(--border-color)}:host button:focus,:host a:focus{border-color:var(--primary-light)}:host button:not(.disabled,.selected):hover,:host a:not(.disabled,.selected):hover{background-color:var(--background-color-hover)}:host button:not(.disabled,.selected):hover.dark,:host a:not(.disabled,.selected):hover.dark{border-color:var(--neutral-purewhite)}:host button cura-icon,:host a cura-icon{margin-right:calc(var(--cura-spacing-base) * 2px)}:host button.selected,:host a.selected{cursor:pointer}:host button.selected:not(.disabled),:host a.selected:not(.disabled){border-bottom:1px solid var(--border-bottom-color-selected)}:host button.disabled,:host a.disabled{cursor:not-allowed}"}},[257,"cura-tabs-transparent",{name:[513],iconName:[513,"icon-name"],selected:[1540],disabled:[1540],borderBottom:[1540,"border-bottom"],size:[513],colorMode:[1537,"color-mode"],hovered:[32],styles:[32]},void 0,{colorMode:[{setColors:0}]}]),l=d,h=function(){"undefined"!=typeof customElements&&["cura-tabs-transparent","cura-icon","cura-label"].forEach((t=>{switch(t){case"cura-tabs-transparent":customElements.get(a(t))||customElements.define(a(t),d);break;case"cura-icon":customElements.get(a(t))||n();break;case"cura-label":customElements.get(a(t))||c()}}))};export{l as CuraTabsTransparent,h as defineCustomElement}
1
+ import{p as t,H as e,k as o,i as s,j as r,t as a}from"./p-DBXUEjWh.js";import{l as i}from"./p-CHcd-uKK.js";import{d as n}from"./p-DI66_jP6.js";import{d as c}from"./p-Cm1Vfoc6.js";const l=t(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.tabSelect=o(this,"tabSelect"),this.selected=!1,this.disabled=!1,this.borderBottom=!0,this.size="large",this.colorMode="light",this.hovered=!1,this.styles={}}setColors(){[{name:"--border-bottom-color",theme:"light"===this.colorMode?"neutral-base":"primary"},{name:"--border-bottom-color-selected",theme:"light"===this.colorMode?"primary-dark":"primary-lighter"}].forEach((t=>{t.theme&&(this.styles[t.name]=window.CuraAPI.theme.colors.getColor(t.theme))})),this.styles=Object.assign({},this.styles)}computeContentColor(){return this.disabled?"neutral-dark":"dark"===this.colorMode?this.hovered&&!this.selected?"neutral-purewhite":this.selected?"primary-lighter":"neutral-purewhite":this.hovered&&!this.selected?"primary-dark":this.selected?"primary-base":"neutral-black"}getIcon(){if(!this.iconName)return"";const t="large"===this.size?20:16,e=this.computeContentColor();return s("cura-icon",{name:this.iconName,size:t,color:e})}getClasses(){return{[this.size]:!0,[this.colorMode]:!0,selected:this.selected,disabled:this.disabled,"border-bottom":this.borderBottom}}connectedCallback(){this.styles=Object.assign(Object.assign({},this.styles),{"--primary-dark":window.CuraAPI.theme.colors.getColor("primary-dark"),"--neutral-purewhite":window.CuraAPI.theme.colors.getColor("neutral-purewhite"),"--base-spacing":window.CuraAPI.theme.spacing.getSpacing()}),this.setColors()}handleMouseEnter(){this.disabled||(this.hovered=!0)}handleMouseLeave(){this.hovered=!1}handleClick(t){this.disabled?t.preventDefault():(this.selected=!this.selected,this.tabSelect.emit({name:this.name}))}render(){const t=i[this.size]||i.default,e=this.computeContentColor();return s(r,{key:"09e06aa0e52ca852fa5e4409429f50242fa5c6a9",role:"button","aria-pressed":this.selected,"aria-disabled":this.disabled},s("button",{key:"a4c5f800f22b23e24b89366766660c02abfd7091",class:this.getClasses(),style:this.styles,onClick:t=>this.handleClick(t),disabled:this.disabled,onMouseEnter:this.handleMouseEnter.bind(this),onMouseLeave:this.handleMouseLeave.bind(this)},this.getIcon(),s("cura-label",{key:"73de8c0f84a1128a92fd840c4b6d9b3415071a99",size:t,color:e,lineHeight:"0",marginBlock:"0"},s("slot",{key:"2514d0f1bd9752635fcc2d453c8994d09ef7f5d1"}))))}static get watchers(){return{colorMode:[{setColors:0}]}}static get style(){return":host button,:host a{outline:none;box-shadow:none;box-sizing:border-box;display:flex;width:100%;align-items:center;justify-content:center;text-decoration:none !important;font-size:var(--font-size);cursor:pointer;transition:background-color 0.07s linear, box-shadow 0.07s linear, border-color 0.07s linear;border-radius:var(--border-radius);position:relative;background-color:transparent;box-sizing:border-box;border:none;min-width:120px;width:fit-content;display:flex;align-items:center;justify-content:center}:host button:focus,:host a:focus{outline:2px solid #6EA8FF}:host button.border-bottom,:host a.border-bottom{border-bottom:1px solid var(--border-bottom-color)}:host button.small,:host a.small{padding:calc(var(--cura-spacing-base) * 2px) calc(var(--cura-spacing-base) * 2px)}:host button.medium,:host a.medium{padding:calc(var(--cura-spacing-base) * 3px) calc(var(--cura-spacing-base) * 3px)}:host button.large,:host a.large{padding:calc(var(--cura-spacing-base) * 3px) calc(var(--cura-spacing-base) * 4px)}:host button:not(.selected),:host a:not(.selected){border-color:var(--border-color)}:host button:focus,:host a:focus{border-color:var(--primary-light)}:host button:not(.disabled,.selected):hover,:host a:not(.disabled,.selected):hover{background-color:var(--background-color-hover)}:host button:not(.disabled,.selected):hover.dark,:host a:not(.disabled,.selected):hover.dark{border-color:var(--neutral-purewhite)}:host button cura-icon,:host a cura-icon{margin-right:calc(var(--cura-spacing-base) * 2px)}:host button.selected,:host a.selected{cursor:pointer}:host button.selected:not(.disabled),:host a.selected:not(.disabled){border-bottom:1px solid var(--border-bottom-color-selected)}:host button.disabled,:host a.disabled{cursor:not-allowed}"}},[257,"cura-tabs-transparent",{name:[513],iconName:[513,"icon-name"],selected:[1540],disabled:[1540],borderBottom:[1540,"border-bottom"],size:[513],colorMode:[1537,"color-mode"],hovered:[32],styles:[32]},void 0,{colorMode:[{setColors:0}]}]),d=l,h=function(){"undefined"!=typeof customElements&&["cura-tabs-transparent","cura-icon","cura-label"].forEach((t=>{switch(t){case"cura-tabs-transparent":customElements.get(a(t))||customElements.define(a(t),l);break;case"cura-icon":customElements.get(a(t))||n();break;case"cura-label":customElements.get(a(t))||c()}}))};export{d as CuraTabsTransparent,h as defineCustomElement}
@@ -1 +1 @@
1
- import{p as t,H as e,k as o,i as s,j as r,t as a}from"./p-DBXUEjWh.js";import{l as i}from"./p-CHcd-uKK.js";import{d as c}from"./p-fn4zJrKE.js";import{d as n}from"./p-BSdkRryc.js";const l=t(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.tabSelect=o(this,"tabSelect"),this.selected=!1,this.disabled=!1,this.borderBottom=!0,this.size="large",this.colorMode="light",this.hovered=!1,this.styles={}}setColors(){[{name:"--background-color-selected",theme:"light"===this.colorMode?"primary-base":"primary-lighter"},{name:"--background-color-hover",theme:"light"===this.colorMode?"primary-lighter":null},{name:"--background-disabled-selected",theme:"light"===this.colorMode?"neutral-pale":"neutral-black"},{name:"--border-bottom-color",theme:"light"===this.colorMode?"neutral-base":"primary"}].forEach((t=>{t.theme&&(this.styles[t.name]=window.CuraAPI.theme.colors.getColor(t.theme))})),this.styles=Object.assign({},this.styles)}computeContentColor(){return this.disabled?"neutral-dark":"dark"===this.colorMode?this.hovered&&!this.selected?"neutral-purewhite":this.selected?"neutral-black":"primary-lighter":this.selected?"neutral-purewhite":"primary-dark"}updateDynamicStyles(){"dark"===this.colorMode&&this.hovered&&!this.selected&&(this.styles=Object.assign(Object.assign({},this.styles),{"--border-bottom-color":window.CuraAPI.theme.colors.getColor("neutral-purewhite")}))}getIcon(){if(!this.iconName)return"";const t="large"===this.size?20:16,e=this.computeContentColor();return s("cura-icon",{name:this.iconName,size:t,color:e})}getClasses(){return{[this.size]:!0,[this.colorMode]:!0,selected:this.selected,disabled:this.disabled,"border-bottom":this.borderBottom}}connectedCallback(){this.styles=Object.assign(Object.assign({},this.styles),{"--primary-dark":window.CuraAPI.theme.colors.getColor("primary-dark"),"--neutral-purewhite":window.CuraAPI.theme.colors.getColor("neutral-purewhite"),"--base-spacing":window.CuraAPI.theme.spacing.getSpacing()}),this.setColors()}handleMouseEnter(){this.disabled||(this.hovered=!0)}handleMouseLeave(){this.hovered=!1}handleClick(t){this.disabled?t.preventDefault():(this.selected=!this.selected,this.tabSelect.emit({name:this.name}))}render(){const t=i[this.size]||i.default,e=this.computeContentColor();return this.updateDynamicStyles(),s(r,{key:"3966968b73a9a51ec26f3206cdb09fbfcb3d3daf",role:"button","aria-pressed":this.selected,"aria-disabled":this.disabled},s("button",{key:"00cc6382c635a05c52fd74b3e02e968c2d94cacb",class:this.getClasses(),style:this.styles,onClick:t=>this.handleClick(t),disabled:this.disabled,onMouseEnter:this.handleMouseEnter.bind(this),onMouseLeave:this.handleMouseLeave.bind(this)},this.getIcon(),s("cura-label",{key:"e193500f156c10cf0442e6f504e19d552c19f849",size:t,color:e,lineHeight:"0",marginBlock:"0"},s("slot",{key:"8a0ac7c4b2ff4990093d13b4110e370616cf39f4"}))))}static get watchers(){return{colorMode:[{setColors:0}]}}static get style(){return":host button,:host a{outline:none;box-shadow:none;box-sizing:border-box;display:flex;width:100%;align-items:center;justify-content:center;text-decoration:none !important;font-size:var(--font-size);cursor:pointer;transition:background-color 0.07s linear, box-shadow 0.07s linear, border-color 0.07s linear;border-radius:var(--border-radius);position:relative;background-color:transparent;box-sizing:border-box;border:none;min-width:120px;width:fit-content;display:flex;align-items:center;justify-content:center;border-radius:4px 4px 0 0}:host button:focus,:host a:focus{outline:2px solid #6EA8FF}:host button.border-bottom,:host a.border-bottom{border-bottom:1px solid var(--border-bottom-color)}:host button:not(.disabled,.selected):hover,:host a:not(.disabled,.selected):hover{background-color:var(--background-color-hover)}:host button:not(.disabled,.selected):hover.light,:host a:not(.disabled,.selected):hover.light{border-bottom-color:var(--primary-dark)}:host button:not(.disabled,.selected):hover.dark,:host a:not(.disabled,.selected):hover.dark{border-bottom-color:var(--neutral-purewhite)}:host button.small,:host a.small{padding:calc(var(--cura-spacing-base) * 2px) calc(var(--cura-spacing-base) * 2px)}:host button.medium,:host a.medium{padding:calc(var(--cura-spacing-base) * 3px) calc(var(--cura-spacing-base) * 3px)}:host button.large,:host a.large{padding:calc(var(--cura-spacing-base) * 3px) calc(var(--cura-spacing-base) * 4px)}:host button:focus,:host a:focus{border:2px solid var(--primary-light)}:host button cura-icon,:host a cura-icon{margin-right:calc(var(--cura-spacing-base) * 2px)}:host button.selected,:host a.selected{cursor:pointer;background-color:var(--background-color-selected)}:host button.selected.disabled,:host a.selected.disabled{background-color:var(--background-disabled-selected)}:host button.disabled,:host a.disabled{cursor:not-allowed}"}},[257,"cura-tabs",{name:[513],iconName:[513,"icon-name"],selected:[1540],disabled:[1540],borderBottom:[1540,"border-bottom"],size:[513],colorMode:[1537,"color-mode"],hovered:[32],styles:[32]},void 0,{colorMode:[{setColors:0}]}]),d=l,h=function(){"undefined"!=typeof customElements&&["cura-tabs","cura-icon","cura-label"].forEach((t=>{switch(t){case"cura-tabs":customElements.get(a(t))||customElements.define(a(t),l);break;case"cura-icon":customElements.get(a(t))||c();break;case"cura-label":customElements.get(a(t))||n()}}))};export{d as CuraTabs,h as defineCustomElement}
1
+ import{p as t,H as e,k as o,i as s,j as r,t as a}from"./p-DBXUEjWh.js";import{l as i}from"./p-CHcd-uKK.js";import{d as c}from"./p-DI66_jP6.js";import{d as n}from"./p-Cm1Vfoc6.js";const l=t(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.tabSelect=o(this,"tabSelect"),this.selected=!1,this.disabled=!1,this.borderBottom=!0,this.size="large",this.colorMode="light",this.hovered=!1,this.styles={}}setColors(){[{name:"--background-color-selected",theme:"light"===this.colorMode?"primary-base":"primary-lighter"},{name:"--background-color-hover",theme:"light"===this.colorMode?"primary-lighter":null},{name:"--background-disabled-selected",theme:"light"===this.colorMode?"neutral-pale":"neutral-black"},{name:"--border-bottom-color",theme:"light"===this.colorMode?"neutral-base":"primary"}].forEach((t=>{t.theme&&(this.styles[t.name]=window.CuraAPI.theme.colors.getColor(t.theme))})),this.styles=Object.assign({},this.styles)}computeContentColor(){return this.disabled?"neutral-dark":"dark"===this.colorMode?this.hovered&&!this.selected?"neutral-purewhite":this.selected?"neutral-black":"primary-lighter":this.selected?"neutral-purewhite":"primary-dark"}updateDynamicStyles(){"dark"===this.colorMode&&this.hovered&&!this.selected&&(this.styles=Object.assign(Object.assign({},this.styles),{"--border-bottom-color":window.CuraAPI.theme.colors.getColor("neutral-purewhite")}))}getIcon(){if(!this.iconName)return"";const t="large"===this.size?20:16,e=this.computeContentColor();return s("cura-icon",{name:this.iconName,size:t,color:e})}getClasses(){return{[this.size]:!0,[this.colorMode]:!0,selected:this.selected,disabled:this.disabled,"border-bottom":this.borderBottom}}connectedCallback(){this.styles=Object.assign(Object.assign({},this.styles),{"--primary-dark":window.CuraAPI.theme.colors.getColor("primary-dark"),"--neutral-purewhite":window.CuraAPI.theme.colors.getColor("neutral-purewhite"),"--base-spacing":window.CuraAPI.theme.spacing.getSpacing()}),this.setColors()}handleMouseEnter(){this.disabled||(this.hovered=!0)}handleMouseLeave(){this.hovered=!1}handleClick(t){this.disabled?t.preventDefault():(this.selected=!this.selected,this.tabSelect.emit({name:this.name}))}render(){const t=i[this.size]||i.default,e=this.computeContentColor();return this.updateDynamicStyles(),s(r,{key:"fc0a87968ffd898bd8fc7b287eca4c43183d5b22",role:"button","aria-pressed":this.selected,"aria-disabled":this.disabled},s("button",{key:"00fe656ab46b7f57dae2a7a1dead6a55759ec729",class:this.getClasses(),style:this.styles,onClick:t=>this.handleClick(t),disabled:this.disabled,onMouseEnter:this.handleMouseEnter.bind(this),onMouseLeave:this.handleMouseLeave.bind(this)},this.getIcon(),s("cura-label",{key:"c291da87ab7e8beda3c547570a80914bba5e5836",size:t,color:e,lineHeight:"0",marginBlock:"0"},s("slot",{key:"7233f8f990b33a841e815746f0c18fad27b907f1"}))))}static get watchers(){return{colorMode:[{setColors:0}]}}static get style(){return":host button,:host a{outline:none;box-shadow:none;box-sizing:border-box;display:flex;width:100%;align-items:center;justify-content:center;text-decoration:none !important;font-size:var(--font-size);cursor:pointer;transition:background-color 0.07s linear, box-shadow 0.07s linear, border-color 0.07s linear;border-radius:var(--border-radius);position:relative;background-color:transparent;box-sizing:border-box;border:none;min-width:120px;width:fit-content;display:flex;align-items:center;justify-content:center;border-radius:4px 4px 0 0}:host button:focus,:host a:focus{outline:2px solid #6EA8FF}:host button.border-bottom,:host a.border-bottom{border-bottom:1px solid var(--border-bottom-color)}:host button:not(.disabled,.selected):hover,:host a:not(.disabled,.selected):hover{background-color:var(--background-color-hover)}:host button:not(.disabled,.selected):hover.light,:host a:not(.disabled,.selected):hover.light{border-bottom-color:var(--primary-dark)}:host button:not(.disabled,.selected):hover.dark,:host a:not(.disabled,.selected):hover.dark{border-bottom-color:var(--neutral-purewhite)}:host button.small,:host a.small{padding:calc(var(--cura-spacing-base) * 2px) calc(var(--cura-spacing-base) * 2px)}:host button.medium,:host a.medium{padding:calc(var(--cura-spacing-base) * 3px) calc(var(--cura-spacing-base) * 3px)}:host button.large,:host a.large{padding:calc(var(--cura-spacing-base) * 3px) calc(var(--cura-spacing-base) * 4px)}:host button:focus,:host a:focus{border:2px solid var(--primary-light)}:host button cura-icon,:host a cura-icon{margin-right:calc(var(--cura-spacing-base) * 2px)}:host button.selected,:host a.selected{cursor:pointer;background-color:var(--background-color-selected)}:host button.selected.disabled,:host a.selected.disabled{background-color:var(--background-disabled-selected)}:host button.disabled,:host a.disabled{cursor:not-allowed}"}},[257,"cura-tabs",{name:[513],iconName:[513,"icon-name"],selected:[1540],disabled:[1540],borderBottom:[1540,"border-bottom"],size:[513],colorMode:[1537,"color-mode"],hovered:[32],styles:[32]},void 0,{colorMode:[{setColors:0}]}]),d=l,h=function(){"undefined"!=typeof customElements&&["cura-tabs","cura-icon","cura-label"].forEach((t=>{switch(t){case"cura-tabs":customElements.get(a(t))||customElements.define(a(t),l);break;case"cura-icon":customElements.get(a(t))||c();break;case"cura-label":customElements.get(a(t))||n()}}))};export{d as CuraTabs,h as defineCustomElement}
@@ -1 +1 @@
1
- import{p as t,H as e,k as a,i as o,j as s,t as i}from"./p-DBXUEjWh.js";import{d as r}from"./p-fR02COZb.js";import{d as n}from"./p-fn4zJrKE.js";import{d as c}from"./p-CCkEqDZb.js";import{d as l}from"./p-D7WNwjv-.js";const h=t(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.toastClosed=a(this,"toastClosed"),this.type="info",this.position="top-right",this.closeButton=!0,this.loader=!0,this.autoCloseDelay=1e4,this.styles={},this.progress=0,this.handleClose=()=>{this.closeContainer()}}async close(){this.closeContainer()}handleChangeType(){this.setStyle()}connectedCallback(){this.setStyle()}render(){return o(s,{key:"c65f4295ed41485cdeb992dc29a76b4aeef87a39",role:"alert","aria-live":"polite","aria-atomic":"true","aria-label":this.label},o("div",{key:"62ec0a3170f862d0634df42ac4ccf0708c80fa32",class:this.getClasses(),style:this.styles},o("cura-icon",{key:"bdb68633080a0032c4fdc2f3bb53a668e5b8ab1b",class:"default-icon",name:this.getNameIcon(),size:16,color:this.type+"-dark"}),o("div",{key:"42516aa76455a7b2c7e96613d6e0f38d8f9fbfba",class:"content"},o("cura-heading",{key:"07402cf186ed3626248d682239b1105378dc2ae6",level:4,size:"xsmall",color:this.type+"-dark",weight:"bold","margin-block":"0"},this.label),o("cura-paragraph",{key:"f8239bb5c4ca52e3ce55cc50fab46bd45440e2ee",color:this.type+"-darker",size:"xsmall",marginBlock:"0",lineHeight:"133.33%"},o("slot",{key:"d0491202942530967ddb5d34ecf1333975c8dda0"})),o("slot",{key:"3024563fbc18c2b4a4954849f74014b0be6b34ee",name:"actions"})),this.closeButton&&o("cura-icon",{key:"20b315655b9d8ff4ddfc6c2cec6ebc8981f64643",class:"close-icon",name:"close",size:16,color:"error-dark",onClick:this.handleClose}),this.loader&&!!this.autoCloseDelay&&o("cura-loader-bar",{key:"a81f9da8704799af13009fa046b58e9d6eeb453c",color:this.type+"-base",progress:this.progress})))}componentDidLoad(){this.openContainer(),this.startAnimation()}setStyle(){this.styles=Object.assign(Object.assign({},this.styles),{"--neutral-purewhite":window.CuraAPI.theme.colors.getColor("neutral-purewhite"),"--neutral-base":window.CuraAPI.theme.colors.getColor("neutral-base",.2),"--primary-base":window.CuraAPI.theme.colors.getColor("primary-base"),"--color-base":window.CuraAPI.theme.colors.getColor(this.type+"-base")})}getClasses(){const[t,e]=this.position.split("-"),a={container:!0};return a[t]=!0,a[e]=!0,this.loader&&(a.loader=!0),a}getNameIcon(){return this.icon?this.icon:{info:"infoCircle",success:"checkCircle",warning:"alertCircle",error:"alertTriangle"}[this.type]}openContainer(){this.container=this.host.shadowRoot.querySelector(".container"),this.container.classList.add("active")}closeContainer(){this.container.classList.remove("active"),setTimeout((()=>{this.toastClosed.emit(),this.host.remove()}),500)}startAnimation(){if(this.autoCloseDelay)if(this.loader){this.progress=0;let t=setInterval((()=>{this.progress>=100?(clearInterval(t),this.closeContainer()):this.progress++}),this.autoCloseDelay/100)}else{let t=setInterval((()=>{clearInterval(t),this.closeContainer()}),this.autoCloseDelay)}}get host(){return this}static get watchers(){return{type:[{handleChangeType:0}],position:[{handleChangeType:0}]}}static get style(){return":host{display:block;box-sizing:border-box}:host .container{position:fixed;z-index:99999;display:flex;box-sizing:border-box;min-width:320px;height:fit-content;padding:16px;border:1px solid var(--color-base);border-radius:12px;background-color:var(--neutral-purewhite);overflow:hidden;box-shadow:0px 8px 16px 0px var(--neutral-black-shadow-4, rgba(38, 38, 38, 0.12))}:host .container.loader{padding:16px 16px 20px}:host .container.top{top:24px}:host .container.top.center{top:-100%;left:50%;transform:translateX(-50%);opacity:0;transition:opacity 0.5s ease-in-out, top 0.5s ease-in-out}:host .container.top.center.active{top:24px;opacity:1}:host .container.bottom{bottom:24px}:host .container.bottom.center{bottom:-100%;left:50%;transform:translateX(-50%);opacity:0;transition:opacity 0.5s ease-in-out, bottom 0.5s ease-in-out}:host .container.bottom.center.active{bottom:24px;opacity:1}:host .container.left{left:-100%;opacity:0;transition:opacity 0.5s ease-in-out, left 0.5s ease-in-out}@media (max-width: 768px){:host .container.left{right:unset;left:50%;transform:translateX(-50%)}}:host .container.left.active{left:24px;opacity:1}:host .container.right{right:-100%;opacity:0;transition:opacity 0.5s ease-in-out, right 0.5s ease-in-out}@media (max-width: 768px){:host .container.right{right:unset;left:50%;transform:translateX(-50%)}}:host .container.right.active{right:24px;opacity:1}:host .container .content{flex:1 1 0;display:flex;flex-direction:column;gap:4px}:host .container .default-icon{margin-right:12px}:host .container .close-icon{margin-left:12px;cursor:pointer}"}},[257,"cura-toast",{type:[1],position:[1],icon:[513],label:[513],closeButton:[516,"close-button"],loader:[516],autoCloseDelay:[514,"auto-close-delay"],styles:[32],progress:[32],close:[64]},void 0,{type:[{handleChangeType:0}],position:[{handleChangeType:0}]}]),p=h,d=function(){"undefined"!=typeof customElements&&["cura-toast","cura-heading","cura-icon","cura-loader-bar","cura-paragraph"].forEach((t=>{switch(t){case"cura-toast":customElements.get(i(t))||customElements.define(i(t),h);break;case"cura-heading":customElements.get(i(t))||r();break;case"cura-icon":customElements.get(i(t))||n();break;case"cura-loader-bar":customElements.get(i(t))||c();break;case"cura-paragraph":customElements.get(i(t))||l()}}))};export{p as CuraToast,d as defineCustomElement}
1
+ import{p as t,H as e,k as a,i as o,j as s,t as i}from"./p-DBXUEjWh.js";import{d as r}from"./p-BFGkepgq.js";import{d as n}from"./p-DI66_jP6.js";import{d as c}from"./p-BGBnVlL3.js";import{d as l}from"./p-Bac-rr_f.js";const h=t(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.toastClosed=a(this,"toastClosed"),this.type="info",this.position="top-right",this.closeButton=!0,this.loader=!0,this.autoCloseDelay=1e4,this.styles={},this.progress=0,this.handleClose=()=>{this.closeContainer()}}async close(){this.closeContainer()}handleChangeType(){this.setStyle()}connectedCallback(){this.setStyle()}render(){return o(s,{key:"3ed410c2082acf963a9bc034ba0698d3d5a8c05e",role:"alert","aria-live":"polite","aria-atomic":"true","aria-label":this.label},o("div",{key:"7da959ad2aa5d8b57e509bfc5c1241cfe2aab078",class:this.getClasses(),style:this.styles},o("cura-icon",{key:"f88bbe2ad57d6d5a2cdd707a753fe6a37d2fb13a",class:"default-icon",name:this.getNameIcon(),size:16,color:this.type+"-dark"}),o("div",{key:"b6d1cf4f6d5cd42b331f19c7996f3de36c29f09e",class:"content"},o("cura-heading",{key:"ab72f2ffea1f653cd956c5ac1b1c80a053e07673",level:4,size:"xsmall",color:this.type+"-dark",weight:"bold","margin-block":"0"},this.label),o("cura-paragraph",{key:"29e40bf6759c4a2c53beed9028d4d4a5472c8d1d",color:this.type+"-darker",size:"xsmall",marginBlock:"0",lineHeight:"133.33%"},o("slot",{key:"b76073439ef46c084eb681a1639d3644b862db00"})),o("slot",{key:"a5d6b28128d692d84990654e5b74c13c91f1fcb5",name:"actions"})),this.closeButton&&o("cura-icon",{key:"bd46e61b4280815f9cb8a683838cceda7b3349c1",class:"close-icon",name:"close",size:16,color:"error-dark",onClick:this.handleClose}),this.loader&&!!this.autoCloseDelay&&o("cura-loader-bar",{key:"bffd92fb6e1c162ff5ead3d3fa84168ef80ca240",color:this.type+"-base",progress:this.progress})))}componentDidLoad(){this.openContainer(),this.startAnimation()}setStyle(){this.styles=Object.assign(Object.assign({},this.styles),{"--neutral-purewhite":window.CuraAPI.theme.colors.getColor("neutral-purewhite"),"--neutral-base":window.CuraAPI.theme.colors.getColor("neutral-base",.2),"--primary-base":window.CuraAPI.theme.colors.getColor("primary-base"),"--color-base":window.CuraAPI.theme.colors.getColor(this.type+"-base")})}getClasses(){const[t,e]=this.position.split("-"),a={container:!0};return a[t]=!0,a[e]=!0,this.loader&&(a.loader=!0),a}getNameIcon(){return this.icon?this.icon:{info:"infoCircle",success:"checkCircle",warning:"alertCircle",error:"alertTriangle"}[this.type]}openContainer(){this.container=this.host.shadowRoot.querySelector(".container"),this.container.classList.add("active")}closeContainer(){this.container.classList.remove("active"),setTimeout((()=>{this.toastClosed.emit(),this.host.remove()}),500)}startAnimation(){if(this.autoCloseDelay)if(this.loader){this.progress=0;let t=setInterval((()=>{this.progress>=100?(clearInterval(t),this.closeContainer()):this.progress++}),this.autoCloseDelay/100)}else{let t=setInterval((()=>{clearInterval(t),this.closeContainer()}),this.autoCloseDelay)}}get host(){return this}static get watchers(){return{type:[{handleChangeType:0}],position:[{handleChangeType:0}]}}static get style(){return":host{display:block;box-sizing:border-box}:host .container{position:fixed;z-index:99999;display:flex;box-sizing:border-box;min-width:320px;height:fit-content;padding:16px;border:1px solid var(--color-base);border-radius:12px;background-color:var(--neutral-purewhite);overflow:hidden;box-shadow:0px 8px 16px 0px var(--neutral-black-shadow-4, rgba(38, 38, 38, 0.12))}:host .container.loader{padding:16px 16px 20px}:host .container.top{top:24px}:host .container.top.center{top:-100%;left:50%;transform:translateX(-50%);opacity:0;transition:opacity 0.5s ease-in-out, top 0.5s ease-in-out}:host .container.top.center.active{top:24px;opacity:1}:host .container.bottom{bottom:24px}:host .container.bottom.center{bottom:-100%;left:50%;transform:translateX(-50%);opacity:0;transition:opacity 0.5s ease-in-out, bottom 0.5s ease-in-out}:host .container.bottom.center.active{bottom:24px;opacity:1}:host .container.left{left:-100%;opacity:0;transition:opacity 0.5s ease-in-out, left 0.5s ease-in-out}@media (max-width: 768px){:host .container.left{right:unset;left:50%;transform:translateX(-50%)}}:host .container.left.active{left:24px;opacity:1}:host .container.right{right:-100%;opacity:0;transition:opacity 0.5s ease-in-out, right 0.5s ease-in-out}@media (max-width: 768px){:host .container.right{right:unset;left:50%;transform:translateX(-50%)}}:host .container.right.active{right:24px;opacity:1}:host .container .content{flex:1 1 0;display:flex;flex-direction:column;gap:4px}:host .container .default-icon{margin-right:12px}:host .container .close-icon{margin-left:12px;cursor:pointer}"}},[257,"cura-toast",{type:[1],position:[1],icon:[513],label:[513],closeButton:[516,"close-button"],loader:[516],autoCloseDelay:[514,"auto-close-delay"],styles:[32],progress:[32],close:[64]},void 0,{type:[{handleChangeType:0}],position:[{handleChangeType:0}]}]),d=h,p=function(){"undefined"!=typeof customElements&&["cura-toast","cura-heading","cura-icon","cura-loader-bar","cura-paragraph"].forEach((t=>{switch(t){case"cura-toast":customElements.get(i(t))||customElements.define(i(t),h);break;case"cura-heading":customElements.get(i(t))||r();break;case"cura-icon":customElements.get(i(t))||n();break;case"cura-loader-bar":customElements.get(i(t))||c();break;case"cura-paragraph":customElements.get(i(t))||l()}}))};export{d as CuraToast,p as defineCustomElement}
@@ -1 +1 @@
1
- import{p as t,H as a,k as r,i as e,j as o,t as s}from"./p-DBXUEjWh.js";import{d as i}from"./p-DXlGQp3a.js";import{d as n}from"./p-fR02COZb.js";import{d as c}from"./p-fn4zJrKE.js";import{d as l}from"./p-BSdkRryc.js";import{d as p}from"./p-Bf21UQXV.js";import{d as h}from"./p-D7WNwjv-.js";const d=t(class extends a{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.tooltipClosed=r(this,"tooltipClosed"),this.elementId="",this.interactive=!0,this.delay=250,this.maxWidth="280px",this.position="top",this.closeButton=!1,this.isMobile=!1,this.styles={},this.handleClose=()=>{this.closeContainer()}}onWindowResize(){this.setPosition(this.targetElement)}onWindowScroll(){this.setPosition(this.targetElement)}connectedCallback(){this.setStyle()}render(){return e(o,{key:"655c6aae9efc3aad790c6a45a7192ef01baeac97",role:"tooltip",id:this.elementId},e("div",{key:"c552ffd20262eed5e71f4cd93c078852cc52c1ca",class:"container",style:this.styles},e("div",{key:"110f11205496428b674431e1b2bc8c3f95f9397a",class:"content"},e("cura-heading",{key:"d2a0caf6a338c9c0b839ea8671c6d524b943ca86",level:4,size:"xsmall",color:"neutral-black",weight:"bold","margin-block":"0"},this.label),e("cura-paragraph",{key:"bd7addb352119fead424151294e01eae111915e2",color:"neutral-dark","spot-color":"secondary-darker",size:"xsmall",marginBlock:"0",lineHeight:"133.33%"},e("slot",{key:"2323f1af541803e16caa042e9969953557a28976"}))),this.closeButton&&!this.isMobile&&e("cura-icon",{key:"92a672d383b057c53ce1771bea1ff9374a9a50a7",class:"close-icon",name:"close",size:16,color:"error-dark",onClick:this.handleClose}),this.isMobile&&e("cura-button-transparent",{key:"a31de7e78e092b4fbf6b0e0b85c0c664399081a0",class:"close-button",size:"small",type:"button",color:"error","icon-name":"close","icon-position":"right",onClick:this.handleClose},"OK, entendi.")))}componentDidLoad(){var t,a,r,e,o;if(this.targetElement=document.querySelector(`[aria-labelledby="${this.elementId}"]`),this.interactive){this.host.style.visibility="hidden";let s=null,i=null;null===(t=this.targetElement)||void 0===t||t.addEventListener("mouseenter",(()=>{clearTimeout(i),s=setTimeout((()=>{this.host.style.visibility="visible"}),"number"==typeof this.delay&&this.delay>250?this.delay:250)})),null===(a=this.targetElement)||void 0===a||a.addEventListener("mouseleave",(()=>{clearTimeout(s),i=setTimeout((()=>{this.handleClose()}),"number"==typeof this.delay&&this.delay>250?this.delay:250)})),null===(r=this.host)||void 0===r||r.addEventListener("mouseenter",(()=>{"visible"===window.getComputedStyle(this.host).visibility&&clearTimeout(i)})),null===(e=this.host)||void 0===e||e.addEventListener("mouseleave",(()=>{clearTimeout(s),this.handleClose()})),null===(o=this.targetElement)||void 0===o||o.addEventListener("click",(()=>{"hidden"===window.getComputedStyle(this.host).visibility?s=setTimeout((()=>{this.host.style.visibility="visible"}),"number"==typeof this.delay&&this.delay>250?this.delay:250):(clearTimeout(s),this.handleClose())})),null===document||void 0===document||document.addEventListener("click",(t=>{this.targetElement.contains(t.target)||this.host.contains(t.target)||(clearTimeout(s),this.handleClose())}))}else this.host.style.visibility="visible";setTimeout((()=>{this.setPosition(this.targetElement)}),100)}setStyle(){this.styles=Object.assign(Object.assign({},this.styles),{"--max-width":this.maxWidth,"--base-spacing":window.CuraAPI.theme.spacing.getSpacing(),"--neutral-purewhite":window.CuraAPI.theme.colors.getColor("neutral-purewhite"),"--neutral-light":window.CuraAPI.theme.colors.getColor("neutral-light"),"--neutral-black-shadow":window.CuraAPI.theme.colors.getColor("neutral-black",.16)})}getClasses(){const[t,a]=this.position.split("-"),r={container:!0};return t&&(r[t]=!0),a&&(r[a]=!0),r}setPosition(t){const a=window.innerWidth,r=window.innerHeight,e=this.host.shadowRoot.querySelector(".container");if(this.isMobile=a<=768,this.host.style.position=this.isMobile?"fixed":"absolute",this.host.style.bottom=this.isMobile?"0":"unset",e.style.flexDirection=this.isMobile?"column":"row",this.isMobile)return this.host.style.left="0",void(this.host.style.top="unset");const o=t.offsetTop,s=t.offsetLeft,i=t.offsetWidth,n=t.offsetHeight,c=this.host.getBoundingClientRect(),l=10,p=10,h=.5*i+18,d=.5*n+18,u=this.styles["--neutral-light"];let b=0,m=0;const w=Object.keys(this.getClasses()).filter((t=>["top","left","bottom","right","start","end"].includes(t))),x=({arrowTop:t="",arrowLeft:a="",translate:r="",borderColor:e=""})=>{a&&this.host.style.setProperty("--arrow-left",a),t&&this.host.style.setProperty("--arrow-top",t),r&&this.host.style.setProperty("--arrow-translate",r),e&&this.host.style.setProperty("--arrow-border-color",e)};(w.includes("top")||w.includes("bottom"))&&(x({arrowLeft:"50%",translate:"translateX(-50%)"}),w.includes("top")&&(m=o-c.height-p,x({arrowTop:"calc(100% - 6px)",borderColor:`transparent ${u} ${u} transparent`}),m<l&&(m=o+n+p,x({arrowTop:"-6px",borderColor:`${u} transparent transparent ${u}`}))),w.includes("bottom")&&(m=o+n+p,x({arrowTop:"-6px",borderColor:`${u} transparent transparent ${u}`}),m+c.height>r-l&&(m=o-c.height-p,x({arrowTop:"calc(100% - 6px)",borderColor:`transparent ${u} ${u} transparent`}))),b=s+(i-c.width)/2,w.includes("start")&&(b=s-c.width+h,x({arrowLeft:"calc(100% - 18px)"}),b<l&&(b=s+i-h,x({arrowLeft:"18px"}))),w.includes("end")&&(b=s+i-h,x({arrowLeft:"18px"}),b+c.width>a-l&&(b=s-c.width+h,x({arrowLeft:"calc(100% - 18px)"})))),(w.includes("right")||w.includes("left"))&&(x({arrowTop:"50%",translate:"translateY(-50%)"}),w.includes("right")&&(b=s+i+p,x({arrowLeft:"-6px",borderColor:`transparent transparent ${u} ${u}`}),b+c.width>a-l&&(b=s-c.width-p,x({arrowLeft:"calc(100% - 6px)",borderColor:`${u} ${u} transparent transparent`}))),w.includes("left")&&(b=s-c.width-p,x({arrowLeft:"calc(100% - 6px)",borderColor:`${u} ${u} transparent transparent`}),b<l&&(b=s+i+p,x({arrowLeft:"-6px",borderColor:`transparent transparent ${u} ${u}`}))),m=o+(n-c.height)/2,w.includes("start")&&(m=o-c.height+d,x({arrowTop:"calc(100% - 18px)"}),m<l&&(m=o+n-d,x({arrowTop:"18px"}))),w.includes("end")&&(m=o+n-d,x({arrowTop:"18px"}),m+c.height>r-l&&(m=o-c.height+d,x({arrowTop:"calc(100% - 18px)"})))),this.host.style.left=b+"px",this.host.style.top=m+"px"}closeContainer(){this.host.style.visibility="hidden",this.tooltipClosed.emit()}get host(){return this}static get style(){return':host{position:absolute;z-index:99998;display:block;width:fit-content;height:fit-content;box-sizing:border-box}@media (max-width: 768px){:host{width:100%}}:host .container{display:flex;box-sizing:border-box;max-width:var(--max-width);height:auto;padding:calc(var(--cura-spacing-base) * 2px);border:1px solid var(--neutral-light);border-radius:calc(var(--cura-spacing-base) * 1px);background-color:var(--neutral-purewhite);box-shadow:0px 4px 8px 0px var(--neutral-black-shadow, rgba(38, 38, 38, 0.16))}@media (max-width: 768px){:host .container{max-width:90%;height:fit-content;padding:calc(var(--cura-spacing-base) * 4px) calc(var(--cura-spacing-base) * 4px) 0 calc(var(--cura-spacing-base) * 4px);margin:0 auto;border:2px solid;border-radius:calc(var(--cura-spacing-base) * 3px) calc(var(--cura-spacing-base) * 3px) 0 0;border-color:var(--neutral-light) var(--neutral-light) transparent var(--neutral-light)}}:host .container::after{content:"";position:absolute;z-index:99999;width:calc(var(--cura-spacing-base) * 2.5px);height:calc(var(--cura-spacing-base) * 2.5px);border:1px solid;border-radius:2px;background-color:var(--neutral-purewhite);left:var(--arrow-left);top:var(--arrow-top);border-color:var(--arrow-border-color);transform:var(--arrow-translate) rotate(45deg)}@media (max-width: 768px){:host .container::after{display:none}}:host .container .content{flex:1 1 0;display:flex;flex-direction:column;gap:calc(var(--cura-spacing-base) * 1px)}@media (max-width: 768px){:host .container .content{padding-bottom:calc(var(--cura-spacing-base) * 4px);border-bottom:1px dashed var(--neutral-light)}}:host .container .close-icon{margin-left:calc(var(--cura-spacing-base) * 3px);cursor:pointer}:host .container .close-button{padding:calc(var(--cura-spacing-base) * 2px) 0}'}},[257,"cura-tooltip",{elementId:[1,"element-id"],interactive:[4],delay:[2],maxWidth:[1,"max-width"],position:[513],label:[513],closeButton:[516,"close-button"],isMobile:[32]},[[9,"resize","onWindowResize"],[9,"scroll","onWindowScroll"]]]),u=d,b=function(){"undefined"!=typeof customElements&&["cura-tooltip","cura-button-transparent","cura-heading","cura-icon","cura-label","cura-loader-circle","cura-paragraph"].forEach((t=>{switch(t){case"cura-tooltip":customElements.get(s(t))||customElements.define(s(t),d);break;case"cura-button-transparent":customElements.get(s(t))||i();break;case"cura-heading":customElements.get(s(t))||n();break;case"cura-icon":customElements.get(s(t))||c();break;case"cura-label":customElements.get(s(t))||l();break;case"cura-loader-circle":customElements.get(s(t))||p();break;case"cura-paragraph":customElements.get(s(t))||h()}}))};export{u as CuraTooltip,b as defineCustomElement}
1
+ import{p as t,H as a,k as r,i as e,j as o,t as s}from"./p-DBXUEjWh.js";import{d as i}from"./p-BXFxWVl3.js";import{d as n}from"./p-BFGkepgq.js";import{d as c}from"./p-DI66_jP6.js";import{d as l}from"./p-Cm1Vfoc6.js";import{d}from"./p-nqT7t82E.js";import{d as p}from"./p-Bac-rr_f.js";const h=t(class extends a{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.tooltipClosed=r(this,"tooltipClosed"),this.elementId="",this.interactive=!0,this.delay=250,this.maxWidth="280px",this.position="top",this.closeButton=!1,this.isMobile=!1,this.styles={},this.handleClose=()=>{this.closeContainer()}}onWindowResize(){this.setPosition(this.targetElement)}onWindowScroll(){this.setPosition(this.targetElement)}connectedCallback(){this.setStyle()}render(){return e(o,{key:"721cf76abdc6eb079edbc8540d2deaa74559c809",role:"tooltip",id:this.elementId},e("div",{key:"51c94531a0d28de3844ac109f0b941062b17c013",class:"container",style:this.styles},e("div",{key:"b80521a83e983ba8939fb21183570de5dfacf544",class:"content"},e("cura-heading",{key:"fc16d66d76800d5c8b778bea1cf325d1ce500f72",level:4,size:"xsmall",color:"neutral-black",weight:"bold","margin-block":"0"},this.label),e("cura-paragraph",{key:"1e0bd7fcbec98be145c83ef8cfa62e2b8e40211c",color:"neutral-dark","spot-color":"secondary-darker",size:"xsmall",marginBlock:"0",lineHeight:"133.33%"},e("slot",{key:"4c4509441c4aa22b3810e1b66939e4cea05f48aa"}))),this.closeButton&&!this.isMobile&&e("cura-icon",{key:"35910c2bb5122c25f10c38ed90c5c633daeb7891",class:"close-icon",name:"close",size:16,color:"error-dark",onClick:this.handleClose}),this.isMobile&&e("cura-button-transparent",{key:"1cec8c66efb24e8eda4e09354dd335e03abd99ed",class:"close-button",size:"small",type:"button",color:"error","icon-name":"close","icon-position":"right",onClick:this.handleClose},"OK, entendi.")))}componentDidLoad(){var t,a,r,e,o;if(this.targetElement=document.querySelector(`[aria-labelledby="${this.elementId}"]`),this.interactive){this.host.style.visibility="hidden";let s=null,i=null;null===(t=this.targetElement)||void 0===t||t.addEventListener("mouseenter",(()=>{clearTimeout(i),s=setTimeout((()=>{this.host.style.visibility="visible"}),"number"==typeof this.delay&&this.delay>250?this.delay:250)})),null===(a=this.targetElement)||void 0===a||a.addEventListener("mouseleave",(()=>{clearTimeout(s),i=setTimeout((()=>{this.handleClose()}),"number"==typeof this.delay&&this.delay>250?this.delay:250)})),null===(r=this.host)||void 0===r||r.addEventListener("mouseenter",(()=>{"visible"===window.getComputedStyle(this.host).visibility&&clearTimeout(i)})),null===(e=this.host)||void 0===e||e.addEventListener("mouseleave",(()=>{clearTimeout(s),this.handleClose()})),null===(o=this.targetElement)||void 0===o||o.addEventListener("click",(()=>{"hidden"===window.getComputedStyle(this.host).visibility?s=setTimeout((()=>{this.host.style.visibility="visible"}),"number"==typeof this.delay&&this.delay>250?this.delay:250):(clearTimeout(s),this.handleClose())})),null===document||void 0===document||document.addEventListener("click",(t=>{this.targetElement.contains(t.target)||this.host.contains(t.target)||(clearTimeout(s),this.handleClose())}))}else this.host.style.visibility="visible";setTimeout((()=>{this.setPosition(this.targetElement)}),100)}setStyle(){this.styles=Object.assign(Object.assign({},this.styles),{"--max-width":this.maxWidth,"--base-spacing":window.CuraAPI.theme.spacing.getSpacing(),"--neutral-purewhite":window.CuraAPI.theme.colors.getColor("neutral-purewhite"),"--neutral-light":window.CuraAPI.theme.colors.getColor("neutral-light"),"--neutral-black-shadow":window.CuraAPI.theme.colors.getColor("neutral-black",.16)})}getClasses(){const[t,a]=this.position.split("-"),r={container:!0};return t&&(r[t]=!0),a&&(r[a]=!0),r}setPosition(t){const a=window.innerWidth,r=window.innerHeight,e=this.host.shadowRoot.querySelector(".container");if(this.isMobile=a<=768,this.host.style.position=this.isMobile?"fixed":"absolute",this.host.style.bottom=this.isMobile?"0":"unset",e.style.flexDirection=this.isMobile?"column":"row",this.isMobile)return this.host.style.left="0",void(this.host.style.top="unset");const o=t.offsetTop,s=t.offsetLeft,i=t.offsetWidth,n=t.offsetHeight,c=this.host.getBoundingClientRect(),l=10,d=10,p=.5*i+18,h=.5*n+18,u=this.styles["--neutral-light"];let b=0,m=0;const x=Object.keys(this.getClasses()).filter((t=>["top","left","bottom","right","start","end"].includes(t))),w=({arrowTop:t="",arrowLeft:a="",translate:r="",borderColor:e=""})=>{a&&this.host.style.setProperty("--arrow-left",a),t&&this.host.style.setProperty("--arrow-top",t),r&&this.host.style.setProperty("--arrow-translate",r),e&&this.host.style.setProperty("--arrow-border-color",e)};(x.includes("top")||x.includes("bottom"))&&(w({arrowLeft:"50%",translate:"translateX(-50%)"}),x.includes("top")&&(m=o-c.height-d,w({arrowTop:"calc(100% - 6px)",borderColor:`transparent ${u} ${u} transparent`}),m<l&&(m=o+n+d,w({arrowTop:"-6px",borderColor:`${u} transparent transparent ${u}`}))),x.includes("bottom")&&(m=o+n+d,w({arrowTop:"-6px",borderColor:`${u} transparent transparent ${u}`}),m+c.height>r-l&&(m=o-c.height-d,w({arrowTop:"calc(100% - 6px)",borderColor:`transparent ${u} ${u} transparent`}))),b=s+(i-c.width)/2,x.includes("start")&&(b=s-c.width+p,w({arrowLeft:"calc(100% - 18px)"}),b<l&&(b=s+i-p,w({arrowLeft:"18px"}))),x.includes("end")&&(b=s+i-p,w({arrowLeft:"18px"}),b+c.width>a-l&&(b=s-c.width+p,w({arrowLeft:"calc(100% - 18px)"})))),(x.includes("right")||x.includes("left"))&&(w({arrowTop:"50%",translate:"translateY(-50%)"}),x.includes("right")&&(b=s+i+d,w({arrowLeft:"-6px",borderColor:`transparent transparent ${u} ${u}`}),b+c.width>a-l&&(b=s-c.width-d,w({arrowLeft:"calc(100% - 6px)",borderColor:`${u} ${u} transparent transparent`}))),x.includes("left")&&(b=s-c.width-d,w({arrowLeft:"calc(100% - 6px)",borderColor:`${u} ${u} transparent transparent`}),b<l&&(b=s+i+d,w({arrowLeft:"-6px",borderColor:`transparent transparent ${u} ${u}`}))),m=o+(n-c.height)/2,x.includes("start")&&(m=o-c.height+h,w({arrowTop:"calc(100% - 18px)"}),m<l&&(m=o+n-h,w({arrowTop:"18px"}))),x.includes("end")&&(m=o+n-h,w({arrowTop:"18px"}),m+c.height>r-l&&(m=o-c.height+h,w({arrowTop:"calc(100% - 18px)"})))),this.host.style.left=b+"px",this.host.style.top=m+"px"}closeContainer(){this.host.style.visibility="hidden",this.tooltipClosed.emit()}get host(){return this}static get style(){return':host{position:absolute;z-index:99998;display:block;width:fit-content;height:fit-content;box-sizing:border-box}@media (max-width: 768px){:host{width:100%}}:host .container{display:flex;box-sizing:border-box;max-width:var(--max-width);height:auto;padding:calc(var(--cura-spacing-base) * 2px);border:1px solid var(--neutral-light);border-radius:calc(var(--cura-spacing-base) * 1px);background-color:var(--neutral-purewhite);box-shadow:0px 4px 8px 0px var(--neutral-black-shadow, rgba(38, 38, 38, 0.16))}@media (max-width: 768px){:host .container{max-width:90%;height:fit-content;padding:calc(var(--cura-spacing-base) * 4px) calc(var(--cura-spacing-base) * 4px) 0 calc(var(--cura-spacing-base) * 4px);margin:0 auto;border:2px solid;border-radius:calc(var(--cura-spacing-base) * 3px) calc(var(--cura-spacing-base) * 3px) 0 0;border-color:var(--neutral-light) var(--neutral-light) transparent var(--neutral-light)}}:host .container::after{content:"";position:absolute;z-index:99999;width:calc(var(--cura-spacing-base) * 2.5px);height:calc(var(--cura-spacing-base) * 2.5px);border:1px solid;border-radius:2px;background-color:var(--neutral-purewhite);left:var(--arrow-left);top:var(--arrow-top);border-color:var(--arrow-border-color);transform:var(--arrow-translate) rotate(45deg)}@media (max-width: 768px){:host .container::after{display:none}}:host .container .content{flex:1 1 0;display:flex;flex-direction:column;gap:calc(var(--cura-spacing-base) * 1px)}@media (max-width: 768px){:host .container .content{padding-bottom:calc(var(--cura-spacing-base) * 4px);border-bottom:1px dashed var(--neutral-light)}}:host .container .close-icon{margin-left:calc(var(--cura-spacing-base) * 3px);cursor:pointer}:host .container .close-button{padding:calc(var(--cura-spacing-base) * 2px) 0}'}},[257,"cura-tooltip",{elementId:[1,"element-id"],interactive:[4],delay:[2],maxWidth:[1,"max-width"],position:[513],label:[513],closeButton:[516,"close-button"],isMobile:[32]},[[9,"resize","onWindowResize"],[9,"scroll","onWindowScroll"]]]),u=h,b=function(){"undefined"!=typeof customElements&&["cura-tooltip","cura-button-transparent","cura-heading","cura-icon","cura-label","cura-loader-circle","cura-paragraph"].forEach((t=>{switch(t){case"cura-tooltip":customElements.get(s(t))||customElements.define(s(t),h);break;case"cura-button-transparent":customElements.get(s(t))||i();break;case"cura-heading":customElements.get(s(t))||n();break;case"cura-icon":customElements.get(s(t))||c();break;case"cura-label":customElements.get(s(t))||l();break;case"cura-loader-circle":customElements.get(s(t))||d();break;case"cura-paragraph":customElements.get(s(t))||p()}}))};export{u as CuraTooltip,b as defineCustomElement}
@@ -1 +1 @@
1
- import{T as t,a as o,b as i,c as e,d as a,e as n,t as c}from"./p-DBXUEjWh.js";export{g as getAssetPath,r as render,s as setAssetPath,f as setNonce,h as setPlatformOptions}from"./p-DBXUEjWh.js";import{S as u}from"./p-B8xnU6YS.js";import{CuraAccordion as m}from"./cura-accordion.js";import{CuraAccordionItem as l}from"./cura-accordion-item.js";import{CuraAlert as p}from"./cura-alert.js";import{CuraAvatar as d}from"./cura-avatar.js";import{CuraBadgeCounter as j}from"./cura-badge-counter.js";import{CuraBadgeDistance as b}from"./cura-badge-distance.js";import{CuraBadgeDot as w}from"./cura-badge-dot.js";import{CuraBadgePill as v}from"./cura-badge-pill.js";import{CuraButton as y}from"./cura-button.js";import{CuraButtonOutline as $}from"./cura-button-outline.js";import{CuraButtonSelect as S}from"./cura-button-select.js";import{CuraButtonTransparent as C}from"./cura-button-transparent.js";import{CuraCalendar as k}from"./cura-calendar.js";import{CuraCard as x}from"./cura-card.js";import{CuraCheckbox as E}from"./cura-checkbox.js";import{CuraDisplay as O}from"./cura-display.js";import{CuraDropdownSearch as D}from"./cura-dropdown-search.js";import{CuraDropdownSearchCategory as A}from"./cura-dropdown-search-category.js";import{CuraDropdownSearchNotFound as P}from"./cura-dropdown-search-not-found.js";import{CuraDropdownSearchOption as W}from"./cura-dropdown-search-option.js";import{CuraHeading as B}from"./cura-heading.js";import{CuraIcon as N}from"./cura-icon.js";import{CuraIconsView as T}from"./cura-icons-view.js";import{CuraInputDate as U}from"./cura-input-date.js";import{CuraInputText as _}from"./cura-input-text.js";import{CuraLabel as z}from"./cura-label.js";import{CuraLoaderBar as F}from"./cura-loader-bar.js";import{CuraLoaderCircle as J}from"./cura-loader-circle.js";import{CuraModal as R}from"./cura-modal.js";import{CuraPageTemplate as X}from"./cura-page-template.js";import{CuraParagraph as G}from"./cura-paragraph.js";import{CuraProgressBar as I}from"./cura-progress-bar.js";import{CuraRadio as L}from"./cura-radio.js";import{CuraSelect as V}from"./cura-select.js";import{CuraSelectOption as Y}from"./cura-select-option.js";import{CuraStepper as q}from"./cura-stepper.js";import{CuraStepperItem as H}from"./cura-stepper-item.js";import{CuraSwitch as K}from"./cura-switch.js";import{CuraTabs as M}from"./cura-tabs.js";import{CuraTabsButton as Q}from"./cura-tabs-button.js";import{CuraTabsGroup as Z}from"./cura-tabs-group.js";import{CuraTabsTransparent as tt}from"./cura-tabs-transparent.js";import{CuraToast as rt}from"./cura-toast.js";import{CuraTooltip as ot}from"./cura-tooltip.js";const st={default:n,maternidade:a,oncologia:e,richet:i,perinatalTemp:o,legacyDefault:t};class it{constructor(){this.NeutralDepthAlias={purewhite:"0",white:"100",pale:"200",lighter:"300",light:"400",base:"500",medium:"600",dark:"700",darker:"800",black:"900"},this.ColorDepthAlias={lighter:"100",light:"300",base:"500",dark:"700",darker:"900"}}getColor(t="primary-base",r=1){const{color:o,depth:s}=this.splitColorDepth(t);return this.getStatic(o,s,r)||this.getDynamic(o,s,r)}getStatic(t,r,o=1){var s,i,e;if(!u.color[t])return null;const a="neutral"===t?this.NeutralDepthAlias[r]:this.ColorDepthAlias[r];return(null===(s=u.color[t])||void 0===s?void 0:s[a])?`rgba(${null===(i=u.color[t])||void 0===i?void 0:i[a]}, ${o})`:`rgba(${null===(e=u.color[t])||void 0===e?void 0:e[r]}, ${o})`}getDynamic(t,r,o){const s=this.ColorDepthAlias[r]?`--cura-color-${t}-${this.ColorDepthAlias[r]}`:`--cura-color-${t}-${r}`;return getComputedStyle(document.documentElement).getPropertyValue(s)?`rgba(var(${s}), ${o})`:`rgba(var(--cura-color-primary-500), ${o})`}splitColorDepth(t){const[r,o]=t.toLowerCase().split(/-(.*)/);return{color:null!=r?r:"primary",depth:null!=o?o:"base"}}}class et{constructor(){this.curaSpacing="--cura-spacing-base"}getSpacing(){return getComputedStyle(document.body).getPropertyValue(this.curaSpacing)?`var(${this.curaSpacing})`:"4"}}class at{constructor(){this.getSize=()=>"var(--cura-font-size)",this.getColor=()=>"var(--cura-font-color)"}getFamily(t="body"){const r="--cura-font-"+t.toLowerCase();return getComputedStyle(document.body).getPropertyValue(r)?`var(${r})`:"var(--cura-font-body)"}getWeights(){const t={};return Object.keys(n.font.weights).forEach((r=>t[r]=`var(--cura-font-weights-${r})`)),t}}class nt{constructor(){}get(t=null,r=null){if(t){const o=r?u.breakpoints[t][r]:u.breakpoints[t];if(o||0===o)return o}return u.breakpoints}}class ct{constructor(){var t;this.prefix="--cura",this.colors=new it,this.spacing=new et,this.fonts=new at,this.breakpoints=new nt,this.groupObject={},this.setCssVar=(t,r)=>{const o=this.groupPath(r,t[0]);this.rootElement.style.setProperty(o,t[1])},this.groupPath=(t,r)=>`${t}-${r}`,this.isObject=t=>t&&"object"==typeof t&&!Array.isArray(t),this.mergeObject=(t,r)=>{const o=Object.entries(t);for(let t of o)this.isObject(t[1])?this.mergeObject(t[1],r[t[0]]):r[t[0]]=t[1]},this.buildCssVars=(t,r,o=!1)=>{const s=Object.entries(r);for(let r of s)if(this.isObject(r[1]))this.buildCssVars(this.groupPath(t,r[0]),r[1],o);else if(o){const o=this.groupPath(t,r[0]);this.groupObject[o]=r[1]}else this.setCssVar(r,t)},"undefined"!=typeof window&&(this.rootElement=null===(t=null===window||void 0===window?void 0:window.document)||void 0===t?void 0:t.documentElement)}load(t="default"){this.buildCssVars(this.prefix,st[t]?st[t]:st.default)}loadVarsSSR(t="default"){return this.buildCssVars(this.prefix,st[t]?st[t]:st.default,!0),this.groupObject}setCustom(t){const r=t.name;if(r in st)console.log("Error building custom theme. Theme %s already exists. Loading default theme.",r),this.load("default");else{const o=Object.assign({},JSON.parse(JSON.stringify(t.fromPreset&&t.fromPreset in st?st[t.fromPreset]:st.default)));this.mergeObject(t.definitions,o),st[r]=o,this.load(r)}}}class ut{constructor(t){this.localAssetsPath=t&&t.localAssetsPath?t.localAssetsPath:"/assets";const r=new ct;this.theme={load:function(t){r.load(t)},setCustom:function(t){r.setCustom(t)},colors:{getColor:function(t,o){return r.colors.getColor(t,o)}},fonts:{getFamily:function(t){return r.fonts.getFamily(t)},getWeights:function(){return r.fonts.getWeights()},getSize:function(){return r.fonts.getSize()},getColor:function(){return r.fonts.getColor()}},spacing:{getSpacing:function(){return r.spacing.getSpacing()}},breakpoints:{get:function(t,o){return r.breakpoints.get(t,o)}}},this._addGlobalClasses(),t&&t.customTheme?this.theme.setCustom(t.customTheme):this.theme.load(t&&t.theme?t.theme:"default")}_addGlobalClasses(){const t="cura_global_classes";let r=document.head.querySelector("#"+t);r||(r=document.createElement("style"),r.id=t,r.textContent="\n .cura-body-scroll-lock {\n overflow: hidden;\n position: fixed;\n left: 0;\n right: 0;\n top: 0;\n }\n ",document.head.appendChild(r))}}function mt(t,r=window){r.CuraInit=t}function lt(t){return(new ct).loadVarsSSR(t)}(function(){const t=window.CuraInit;window.CuraAPI=t?new ut(t):new ut;const r=window.CuraAPI;window.dispatchEvent(new CustomEvent("CuraAPIReady",{detail:{api:r}})),t&&"function"==typeof t.onReady&&t.onReady(r)}||(()=>{}))();const pt=t=>{"undefined"!=typeof customElements&&[m,l,p,d,j,b,w,v,y,$,S,C,k,x,E,O,D,A,P,W,B,N,T,U,_,z,F,J,R,X,G,I,L,V,Y,q,H,K,M,Q,Z,tt,rt,ot].forEach((r=>{customElements.get(c(r.is))||customElements.define(c(r.is),r,t)}))};export{mt as CuraInit,lt as InitVarsTheme,pt as defineCustomElements}
1
+ import{T as t,a as e,b as a,c as i,d as o,e as n,t as l}from"./p-DBXUEjWh.js";export{g as getAssetPath,r as render,s as setAssetPath,f as setNonce,h as setPlatformOptions}from"./p-DBXUEjWh.js";import{S as c}from"./p-BJafC0R3.js";import{CuraAccordion as u}from"./cura-accordion.js";import{CuraAccordionItem as d}from"./cura-accordion-item.js";import{CuraAlert as m}from"./cura-alert.js";import{CuraAvatar as p}from"./cura-avatar.js";import{CuraBadgeCounter as w}from"./cura-badge-counter.js";import{CuraBadgeDistance as b}from"./cura-badge-distance.js";import{CuraBadgeDot as y}from"./cura-badge-dot.js";import{CuraBadgePill as v}from"./cura-badge-pill.js";import{CuraButton as j}from"./cura-button.js";import{CuraButtonOutline as E}from"./cura-button-outline.js";import{CuraButtonSelect as M}from"./cura-button-select.js";import{CuraButtonTransparent as T}from"./cura-button-transparent.js";import{CuraCalendar as x}from"./cura-calendar.js";import{CuraCard as F}from"./cura-card.js";import{CuraCheckbox as k}from"./cura-checkbox.js";import{CuraDisplay as O}from"./cura-display.js";import{CuraDropdownSearch as C}from"./cura-dropdown-search.js";import{CuraDropdownSearchCategory as S}from"./cura-dropdown-search-category.js";import{CuraDropdownSearchNotFound as I}from"./cura-dropdown-search-not-found.js";import{CuraDropdownSearchOption as V}from"./cura-dropdown-search-option.js";import{CuraHeading as L}from"./cura-heading.js";import{CuraIcon as $}from"./cura-icon.js";import{CuraIconsView as W}from"./cura-icons-view.js";import{CuraInputDate as D}from"./cura-input-date.js";import{CuraInputText as R}from"./cura-input-text.js";import{CuraLabel as H}from"./cura-label.js";import{CuraLoaderBar as A}from"./cura-loader-bar.js";import{CuraLoaderCircle as N}from"./cura-loader-circle.js";import{CuraModal as P}from"./cura-modal.js";import{CuraPageTemplate as B}from"./cura-page-template.js";import{CuraParagraph as z}from"./cura-paragraph.js";import{CuraProgressBar as _}from"./cura-progress-bar.js";import{CuraRadio as q}from"./cura-radio.js";import{CuraSelect as J}from"./cura-select.js";import{CuraSelectOption as U}from"./cura-select-option.js";import{CuraStepper as X}from"./cura-stepper.js";import{CuraStepperItem as G}from"./cura-stepper-item.js";import{CuraSwitch as K}from"./cura-switch.js";import{CuraTabs as Q}from"./cura-tabs.js";import{CuraTabsButton as Y}from"./cura-tabs-button.js";import{CuraTabsGroup as Z}from"./cura-tabs-group.js";import{CuraTabsTransparent as tt}from"./cura-tabs-transparent.js";import{CuraToast as et}from"./cura-toast.js";import{CuraTooltip as rt}from"./cura-tooltip.js";const at={default:n,maternidade:o,oncologia:i,richet:a,perinatalTemp:e,legacyDefault:t};class it{constructor(){this.NeutralDepthAlias={purewhite:"0",white:"100",pale:"200",lighter:"300",light:"400",base:"500",medium:"600",dark:"700",darker:"800",black:"900"},this.ColorDepthAlias={lighter:"100",light:"300",base:"500",dark:"700",darker:"900"}}getColor(t="primary-base",e=1){const{color:r,depth:a}=this.splitColorDepth(t);return this.getStatic(r,a,e)||this.getDynamic(r,a,e)}getStatic(t,e,r=1){var a,i,o;if(!c.color[t])return null;const n="neutral"===t?this.NeutralDepthAlias[e]:this.ColorDepthAlias[e];return(null===(a=c.color[t])||void 0===a?void 0:a[n])?`rgba(${null===(i=c.color[t])||void 0===i?void 0:i[n]}, ${r})`:`rgba(${null===(o=c.color[t])||void 0===o?void 0:o[e]}, ${r})`}getDynamic(t,e,r){const a=this.ColorDepthAlias[e]?`--cura-color-${t}-${this.ColorDepthAlias[e]}`:`--cura-color-${t}-${e}`;return getComputedStyle(document.documentElement).getPropertyValue(a)?`rgba(var(${a}), ${r})`:`rgba(var(--cura-color-primary-500), ${r})`}splitColorDepth(t){const[e,r]=t.toLowerCase().split(/-(.*)/);return{color:null!=e?e:"primary",depth:null!=r?r:"base"}}}class ot{constructor(){this.curaSpacing="--cura-spacing-base"}getSpacing(){return getComputedStyle(document.body).getPropertyValue(this.curaSpacing)?`var(${this.curaSpacing})`:"4"}}class nt{constructor(){this.getSize=()=>"var(--cura-font-size)",this.getColor=()=>"var(--cura-font-color)"}getFamily(t="body"){const e="--cura-font-"+t.toLowerCase();return getComputedStyle(document.body).getPropertyValue(e)?`var(${e})`:"var(--cura-font-body)"}getWeights(){const t={};return Object.keys(n.font.weights).forEach((e=>t[e]=`var(--cura-font-weights-${e})`)),t}}class st{constructor(){}get(t=null,e=null){if(t){const r=e?c.breakpoints[t][e]:c.breakpoints[t];if(r||0===r)return r}return c.breakpoints}}class lt{constructor(){var t;this.prefix="--cura",this.colors=new it,this.spacing=new ot,this.fonts=new nt,this.breakpoints=new st,this.groupObject={},this.setCssVar=(t,e)=>{const r=this.groupPath(e,t[0]);this.rootElement.style.setProperty(r,t[1])},this.groupPath=(t,e)=>`${t}-${e}`,this.isObject=t=>t&&"object"==typeof t&&!Array.isArray(t),this.mergeObject=(t,e)=>{const r=Object.entries(t);for(let t of r)this.isObject(t[1])?this.mergeObject(t[1],e[t[0]]):e[t[0]]=t[1]},this.buildCssVars=(t,e,r=!1)=>{const a=Object.entries(e);for(let e of a)if(this.isObject(e[1]))this.buildCssVars(this.groupPath(t,e[0]),e[1],r);else if(r){const r=this.groupPath(t,e[0]);this.groupObject[r]=e[1]}else this.setCssVar(e,t)},"undefined"!=typeof window&&(this.rootElement=null===(t=null===window||void 0===window?void 0:window.document)||void 0===t?void 0:t.documentElement)}load(t="default"){this.buildCssVars(this.prefix,at[t]?at[t]:at.default)}loadVarsSSR(t="default"){return this.buildCssVars(this.prefix,at[t]?at[t]:at.default,!0),this.groupObject}setCustom(t){const e=t.name;if(e in at)console.log("Error building custom theme. Theme %s already exists. Loading default theme.",e),this.load("default");else{const r=Object.assign({},JSON.parse(JSON.stringify(t.fromPreset&&t.fromPreset in at?at[t.fromPreset]:at.default)));this.mergeObject(t.definitions,r),at[e]=r,this.load(e)}}}class ct{constructor(t){this.localAssetsPath=t&&t.localAssetsPath?t.localAssetsPath:"/assets";const e=new lt;this.theme={load:function(t){e.load(t)},setCustom:function(t){e.setCustom(t)},colors:{getColor:function(t,r){return e.colors.getColor(t,r)}},fonts:{getFamily:function(t){return e.fonts.getFamily(t)},getWeights:function(){return e.fonts.getWeights()},getSize:function(){return e.fonts.getSize()},getColor:function(){return e.fonts.getColor()}},spacing:{getSpacing:function(){return e.spacing.getSpacing()}},breakpoints:{get:function(t,r){return e.breakpoints.get(t,r)}}},this._addGlobalClasses(),t&&t.customTheme?this.theme.setCustom(t.customTheme):this.theme.load(t&&t.theme?t.theme:"default")}_addGlobalClasses(){const t="cura_global_classes";let e=document.head.querySelector("#"+t);e||(e=document.createElement("style"),e.id=t,e.textContent="\n .cura-body-scroll-lock {\n overflow: hidden;\n position: fixed;\n left: 0;\n right: 0;\n top: 0;\n }\n ",document.head.appendChild(e))}}const ut=function(){const t=window.CuraInit;window.CuraAPI=t?new ct(t):new ct;const e=window.CuraAPI;window.dispatchEvent(new CustomEvent("CuraAPIReady",{detail:{api:e}})),t&&"function"==typeof t.onReady&&t.onReady(e)}||(()=>{}),dt=new WeakMap,mt=new WeakMap,ft=new WeakMap,ht=new WeakMap,pt=new WeakMap,wt=new WeakMap,bt=new WeakMap,yt=new WeakMap,gt=new WeakMap,vt=new WeakMap,jt=new WeakMap,Et=new WeakMap,Mt=new WeakMap,Tt=new WeakMap,xt=new WeakMap,Ft=(t,e,r)=>{t.getAttribute(e)!==r&&t.setAttribute(e,r)},kt=(t,e)=>{t.toggleAttribute("internals-disabled",e),e?Ft(t,"aria-disabled","true"):t.removeAttribute("aria-disabled"),t.formDisabledCallback&&t.formDisabledCallback.call(t,e)},Ot=t=>{ft.get(t).forEach((t=>{t.remove()})),ft.set(t,[])},Ct=(t,e)=>{const r=document.createElement("input");return r.type="hidden",r.name=t.getAttribute("name"),t.after(r),ft.get(e).push(r),r},St=(t,e)=>{if(e.length){const r=Array.from(e);r.forEach((e=>e.addEventListener("click",t.click.bind(t))));const[a]=r;let i=a.id;a.id||(i=a.htmlFor+"_Label",a.id=i),Ft(t,"aria-labelledby",i)}},It=t=>{const e=Array.from(t.elements).filter((t=>!t.tagName.includes("-")&&t.validity)).map((t=>t.validity.valid)),r=yt.get(t)||[],a=[...e,...Array.from(r).filter((t=>t.isConnected)).map((t=>ht.get(t).validity.valid))].includes(!1);t.toggleAttribute("internals-invalid",a),t.toggleAttribute("internals-valid",!a)},Vt=t=>{It(Dt(t.target))},Lt=t=>{It(Dt(t.target))},$t=t=>{const e=yt.get(t.target);e&&e.size&&e.forEach((t=>{t.constructor.formAssociated&&t.formResetCallback&&t.formResetCallback.apply(t)}))},Wt=(t,e,r)=>{if(e){const a=yt.get(e);if(a)a.add(t);else{const r=new Set;r.add(t),yt.set(e,r),(t=>{const e=["button[type=submit]","input[type=submit]","button:not([type])"].map((t=>t+":not([disabled])")).map((e=>`${e}:not([form])${t.id?`,${e}[form='${t.id}']`:""}`)).join(",");t.addEventListener("click",(r=>{if(r.target.closest(e)){const e=yt.get(t);if(t.noValidate)return;e.size&&Array.from(e).reverse().map((t=>ht.get(t).reportValidity())).includes(!1)&&r.preventDefault()}}))})(e),e.addEventListener("reset",$t),e.addEventListener("input",Vt),e.addEventListener("change",Lt)}wt.set(e,{ref:t,internals:r}),t.constructor.formAssociated&&t.formAssociatedCallback&&setTimeout((()=>{t.formAssociatedCallback.call(t,e)}),0),It(e)}},Dt=t=>{let e=t.parentNode;return e&&"FORM"!==e.tagName&&(e=Dt(e)),e},Rt=(t,e,r=DOMException)=>{if(!t.constructor.formAssociated)throw new r(e)},Ht=(t,e,r)=>{const a=yt.get(t);return a&&a.size&&a.forEach((t=>{ht.get(t)[r]()||(e=!1)})),e},At=t=>{let e=!1;if(t.constructor.formAssociated){let r=ht.get(t);void 0===r&&(t.attachInternals(),r=ht.get(t),e=!0);const{labels:a,form:i}=r;St(t,a),Wt(t,i,r)}return e};function Nt(){return"undefined"!=typeof MutationObserver}const Pt={ariaAtomic:"aria-atomic",ariaAutoComplete:"aria-autocomplete",ariaBrailleLabel:"aria-braillelabel",ariaBrailleRoleDescription:"aria-brailleroledescription",ariaBusy:"aria-busy",ariaChecked:"aria-checked",ariaColCount:"aria-colcount",ariaColIndex:"aria-colindex",ariaColIndexText:"aria-colindextext",ariaColSpan:"aria-colspan",ariaCurrent:"aria-current",ariaDescription:"aria-description",ariaDisabled:"aria-disabled",ariaExpanded:"aria-expanded",ariaHasPopup:"aria-haspopup",ariaHidden:"aria-hidden",ariaInvalid:"aria-invalid",ariaKeyShortcuts:"aria-keyshortcuts",ariaLabel:"aria-label",ariaLevel:"aria-level",ariaLive:"aria-live",ariaModal:"aria-modal",ariaMultiLine:"aria-multiline",ariaMultiSelectable:"aria-multiselectable",ariaOrientation:"aria-orientation",ariaPlaceholder:"aria-placeholder",ariaPosInSet:"aria-posinset",ariaPressed:"aria-pressed",ariaReadOnly:"aria-readonly",ariaRelevant:"aria-relevant",ariaRequired:"aria-required",ariaRoleDescription:"aria-roledescription",ariaRowCount:"aria-rowcount",ariaRowIndex:"aria-rowindex",ariaRowIndexText:"aria-rowindextext",ariaRowSpan:"aria-rowspan",ariaSelected:"aria-selected",ariaSetSize:"aria-setsize",ariaSort:"aria-sort",ariaValueMax:"aria-valuemax",ariaValueMin:"aria-valuemin",ariaValueNow:"aria-valuenow",ariaValueText:"aria-valuetext",role:"role"};function Bt(t){const e=ht.get(t),{form:r}=e;Wt(t,r,e),St(t,e.labels)}const zt=(t,e=!1)=>{const r=document.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,{acceptNode:t=>ht.has(t)?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP});let a=r.nextNode();const i=!e||t.disabled;for(;a;)a.formDisabledCallback&&i&&kt(a,t.disabled),a=r.nextNode()},_t={attributes:!0,attributeFilter:["disabled","name"]},qt=Nt()?new MutationObserver((t=>{for(const e of t){const t=e.target;if("disabled"===e.attributeName&&(t.constructor.formAssociated?kt(t,t.hasAttribute("disabled")):"fieldset"===t.localName&&zt(t)),"name"===e.attributeName&&t.constructor.formAssociated){const e=ht.get(t),r=gt.get(t);e.setFormValue(r)}}})):{};function Jt(t){t.forEach((t=>{const{addedNodes:e,removedNodes:r}=t,a=Array.from(e),i=Array.from(r);a.forEach((t=>{if(ht.has(t)&&t.constructor.formAssociated&&Bt(t),vt.has(t)){const e=vt.get(t);Object.keys(Pt).filter((t=>null!==e[t])).forEach((r=>{Ft(t,Pt[r],e[r])})),vt.delete(t)}if(xt.has(t)){const e=xt.get(t);Ft(t,"internals-valid",""+e.validity.valid),Ft(t,"internals-invalid",""+!e.validity.valid),Ft(t,"aria-invalid",""+!e.validity.valid),xt.delete(t)}if("form"===t.localName){const e=yt.get(t),r=document.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,{acceptNode:t=>!ht.has(t)||!t.constructor.formAssociated||e&&e.has(t)?NodeFilter.FILTER_SKIP:NodeFilter.FILTER_ACCEPT});let a=r.nextNode();for(;a;)Bt(a),a=r.nextNode()}"fieldset"===t.localName&&(qt.observe?.(t,_t),zt(t,!0))})),i.forEach((t=>{const e=ht.get(t);e&&ft.get(e)&&Ot(e),bt.has(t)&&bt.get(t).disconnect()}))}))}function Ut(t){t.forEach((t=>{const{removedNodes:e}=t;e.forEach((e=>{const r=Mt.get(t.target);ht.has(e)&&At(e),r.disconnect()}))}))}!Nt()||new MutationObserver(Jt);const Xt={childList:!0,subtree:!0};class Gt{constructor(){this.badInput=!1,this.customError=!1,this.patternMismatch=!1,this.rangeOverflow=!1,this.rangeUnderflow=!1,this.stepMismatch=!1,this.tooLong=!1,this.tooShort=!1,this.typeMismatch=!1,this.valid=!0,this.valueMissing=!1,Object.seal(this)}}const Kt=new WeakMap;function Qt(t,e){t.toggleAttribute(e,!0),t.part&&t.part.add(e)}class Yt extends Set{static get isPolyfilled(){return!0}constructor(t){if(super(),!t||!t.tagName||-1===t.tagName.indexOf("-"))throw new TypeError("Illegal constructor");Kt.set(this,t)}add(t){if(!/^--/.test(t)||"string"!=typeof t)throw new DOMException(`Failed to execute 'add' on 'CustomStateSet': The specified value ${t} must start with '--'.`);const e=super.add(t),r=Kt.get(this),a="state"+t;return r.isConnected?Qt(r,a):setTimeout((()=>{Qt(r,a)})),e}clear(){for(let[t]of this.entries())this.delete(t);super.clear()}delete(t){const e=super.delete(t),r=Kt.get(this);return r.isConnected?(r.toggleAttribute("state"+t,!1),r.part&&r.part.remove("state"+t)):setTimeout((()=>{r.toggleAttribute("state"+t,!1),r.part&&r.part.remove("state"+t)})),e}}var Zt,te=function(t,e,r,a){if("a"===r&&!a)throw new TypeError("Private accessor was defined without a getter");if("function"==typeof e?t!==e||!a:!e.has(t))throw new TypeError("Cannot read private member from an object whose class did not declare it");return"m"===r?a:"a"===r?a.call(t):a?a.value:e.get(t)};class ee{constructor(t){Zt.set(this,void 0),function(t,e,r,a,i){if("m"===a)throw new TypeError("Private method is not writable");if("a"===a&&!i)throw new TypeError("Private accessor was defined without a setter");if("function"==typeof e?t!==e||!i:!e.has(t))throw new TypeError("Cannot write private member to an object whose class did not declare it");"a"===a?i.call(t,r):i?i.value=r:e.set(t,r)}(this,Zt,t,"f");for(let e=0;e<t.length;e++){let r=t[e];this[e]=r,r.hasAttribute("name")&&(this[r.getAttribute("name")]=r)}Object.freeze(this)}get length(){return te(this,Zt,"f").length}[(Zt=new WeakMap,Symbol.iterator)](){return te(this,Zt,"f")[Symbol.iterator]()}item(t){return null==this[t]?null:this[t]}namedItem(t){return null==this[t]?null:this[t]}}class re{static get isPolyfilled(){return!0}constructor(t){if(!t||!t.tagName||-1===t.tagName.indexOf("-"))throw new TypeError("Illegal constructor");const e=t.getRootNode(),r=new Gt;this.states=new Yt(t),dt.set(this,t),mt.set(this,r),ht.set(t,this),((t,e)=>{for(let r in Pt){e[r]=null;let a=null;const i=Pt[r];Object.defineProperty(e,r,{get:()=>a,set(r){a=r,t.isConnected?Ft(t,i,r):vt.set(t,e)}})}})(t,this),(t=>{ft.set(this,[]),qt.observe?.(t,_t)})(t),Object.seal(this),e instanceof DocumentFragment&&(t=>{const e=new MutationObserver(Ut);window?.ShadyDOM?.inUse&&t.mode&&t.host&&(t=t.host),e.observe?.(t,{childList:!0}),Mt.set(t,e)})(e)}checkValidity(){const t=dt.get(this);if(Rt(t,"Failed to execute 'checkValidity' on 'ElementInternals': The target element is not a form-associated custom element."),!this.willValidate)return!0;const e=mt.get(this);if(!e.valid){const e=new Event("invalid",{bubbles:!1,cancelable:!0,composed:!1});t.dispatchEvent(e)}return e.valid}get form(){const t=dt.get(this);let e;return Rt(t,"Failed to read the 'form' property from 'ElementInternals': The target element is not a form-associated custom element."),!0===t.constructor.formAssociated&&(e=Dt(t)),e}get labels(){const t=dt.get(this);Rt(t,"Failed to read the 'labels' property from 'ElementInternals': The target element is not a form-associated custom element.");const e=t.getAttribute("id"),r=t.getRootNode();return r&&e?r.querySelectorAll(`[for="${e}"]`):[]}reportValidity(){const t=dt.get(this);if(Rt(t,"Failed to execute 'reportValidity' on 'ElementInternals': The target element is not a form-associated custom element."),!this.willValidate)return!0;const e=this.checkValidity(),r=Et.get(this);if(r&&!t.constructor.formAssociated)throw new DOMException("Failed to execute 'reportValidity' on 'ElementInternals': The target element is not a form-associated custom element.");return!e&&r&&(t.focus(),r.focus()),e}setFormValue(t){const e=dt.get(this);Rt(e,"Failed to execute 'setFormValue' on 'ElementInternals': The target element is not a form-associated custom element."),Ot(this),null==t||t instanceof FormData?null!=t&&t instanceof FormData&&Array.from(t).reverse().forEach((([t,r])=>{if("string"==typeof r){const a=Ct(e,this);a.name=t,a.value=r}})):e.getAttribute("name")&&(Ct(e,this).value=t),gt.set(e,t)}setValidity(t,e,r){const a=dt.get(this);if(Rt(a,"Failed to execute 'setValidity' on 'ElementInternals': The target element is not a form-associated custom element."),!t)throw new TypeError("Failed to execute 'setValidity' on 'ElementInternals': 1 argument required, but only 0 present.");Et.set(this,r);const i=mt.get(this),o={};for(const e in t)o[e]=t[e];0===Object.keys(o).length&&(t=>{t.badInput=!1,t.customError=!1,t.patternMismatch=!1,t.rangeOverflow=!1,t.rangeUnderflow=!1,t.stepMismatch=!1,t.tooLong=!1,t.tooShort=!1,t.typeMismatch=!1,t.valid=!0,t.valueMissing=!1})(i);const n={...i,...o};delete n.valid;const{valid:s}=((t,e,r)=>(t.valid=(t=>{let e=!0;for(let r in t)"valid"!==r&&!1!==t[r]&&(e=!1);return e})(e),Object.keys(e).forEach((r=>t[r]=e[r])),r&&It(r),t))(i,n,this.form);if(!s&&!e)throw new DOMException("Failed to execute 'setValidity' on 'ElementInternals': The second argument should not be empty if one or more flags in the first argument are true.");pt.set(this,s?"":e),a.isConnected?(a.toggleAttribute("internals-invalid",!s),a.toggleAttribute("internals-valid",s),Ft(a,"aria-invalid",""+!s)):xt.set(a,this)}get shadowRoot(){const t=dt.get(this);return jt.get(t)||null}get validationMessage(){const t=dt.get(this);return Rt(t,"Failed to read the 'validationMessage' property from 'ElementInternals': The target element is not a form-associated custom element."),pt.get(this)}get validity(){const t=dt.get(this);return Rt(t,"Failed to read the 'validity' property from 'ElementInternals': The target element is not a form-associated custom element."),mt.get(this)}get willValidate(){const t=dt.get(this);return Rt(t,"Failed to read the 'willValidate' property from 'ElementInternals': The target element is not a form-associated custom element."),!(t.matches(":disabled")||t.disabled||t.hasAttribute("disabled")||t.hasAttribute("readonly"))}}let ae=!1,ie=!1;function oe(t){ie||(ie=!0,window.CustomStateSet=Yt,t&&(HTMLElement.prototype.attachInternals=function(...e){const r=t.call(this,e);return r.states=new Yt(this),r}))}function ne(t,e=window){e.CuraInit=t}function se(t){return(new lt).loadVarsSSR(t)}!!customElements.polyfillWrapFlushCallback||(function(){if("undefined"==typeof window||!window.ElementInternals||!HTMLElement.prototype.attachInternals)return!1;class t extends HTMLElement{constructor(){super(),this.internals=this.attachInternals()}}const e="element-internals-feature-detection-"+Math.random().toString(36).replace(/[^a-z]+/g,"");customElements.define(e,t);const r=new t;return["shadowRoot","form","willValidate","validity","validationMessage","labels","setFormValue","setValidity","checkValidity","reportValidity"].every((t=>t in r.internals))}()?"undefined"==typeof window||window.CustomStateSet||oe(HTMLElement.prototype.attachInternals):function(t=!0){let e=!1;if(!ae){if(ae=!0,"undefined"!=typeof window&&(window.ElementInternals=re),"undefined"!=typeof CustomElementRegistry){const r=CustomElementRegistry.prototype.define;CustomElementRegistry.prototype.define=function(t,a,i){if(a.formAssociated){const t=a.prototype.connectedCallback;a.prototype.connectedCallback=function(){Tt.has(this)||(Tt.set(this,!0),this.hasAttribute("disabled")&&kt(this,!0)),null!=t&&t.apply(this),e=At(this)}}r.call(this,t,a,i)}}if("undefined"!=typeof HTMLElement&&(HTMLElement.prototype.attachInternals=function(){if(!this.tagName)return{};if(-1===this.tagName.indexOf("-"))throw Error("Failed to execute 'attachInternals' on 'HTMLElement': Unable to attach ElementInternals to non-custom elements.");if(ht.has(this)&&!e)throw new DOMException("DOMException: Failed to execute 'attachInternals' on 'HTMLElement': ElementInternals for the specified element was already attached.");return new re(this)}),"undefined"!=typeof Element){function a(...t){const e=i.apply(this,t);if(jt.set(this,e),Nt()){const t=new MutationObserver(Jt);window.ShadyDOM?t.observe(this,Xt):t.observe(e,Xt),bt.set(this,t)}return e}const i=Element.prototype.attachShadow;Element.prototype.attachShadow=a}Nt()&&"undefined"!=typeof document&&new MutationObserver(Jt).observe(document.documentElement,Xt),"undefined"!=typeof HTMLFormElement&&function(){const t=HTMLFormElement.prototype.checkValidity;HTMLFormElement.prototype.checkValidity=function(...e){let r=t.apply(this,e);return Ht(this,r,"checkValidity")};const e=HTMLFormElement.prototype.reportValidity;HTMLFormElement.prototype.reportValidity=function(...t){let r=e.apply(this,t);return Ht(this,r,"reportValidity")};const{get:r}=Object.getOwnPropertyDescriptor(HTMLFormElement.prototype,"elements");Object.defineProperty(HTMLFormElement.prototype,"elements",{get(...t){const e=r.call(this,...t),a=Array.from(yt.get(this)||[]);if(0===a.length)return e;const i=Array.from(e).concat(a).sort(((t,e)=>t.compareDocumentPosition?2&t.compareDocumentPosition(e)?1:-1:0));return new ee(i)}})}(),(t||"undefined"!=typeof window&&!window.CustomStateSet)&&oe()}}(!1)),ut();const le=t=>{"undefined"!=typeof customElements&&[u,d,m,p,w,b,y,v,j,E,M,T,x,F,k,O,C,S,I,V,L,$,W,D,R,H,A,N,P,B,z,_,q,J,U,X,G,K,Q,Y,Z,tt,et,rt].forEach((e=>{customElements.get(l(e.is))||customElements.define(l(e.is),e,t)}))};export{ne as CuraInit,se as InitVarsTheme,le as defineCustomElements}
@@ -1 +1 @@
1
- import{p as t,H as e,i as a,j as s,t as r}from"./p-DBXUEjWh.js";import{d as i}from"./p-BSdkRryc.js";const n=t(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.theme=window.CuraAPI.theme,this.color="primary",this.disabled=!1,this.type="solid",this.styles={},this.labelColor="primary-darker",this.bgColorName="primary-lighter"}handleColorChange(){this.setColors()}setColors(){const t=this.color.toLowerCase();"outline"===this.type||"transparent"===this.type?(this.bgColorName=this.disabled?"neutral-medium":`${t}-dark`,this.labelColor=this.bgColorName):(this.bgColorName="neutral"===t||this.disabled?"neutral-pale":`${t}-lighter`,this.labelColor=this.disabled?"neutral-medium":`${t}-dark`),this.styles=Object.assign(Object.assign({},this.styles),{"--background-color":this.theme.colors.getColor(`${this.bgColorName}`)})}connectedCallback(){this.styles["--base-spacing"]=this.theme.spacing.getSpacing(),this.setColors()}getClasses(){const t={container:!0};return t[this.type.toLowerCase()]=!0,t}render(){return a(s,{key:"8b67f2b913a10de53a519cdafcfbcb140b2adda5"},this.number&&this.number<=0?"":a("div",{class:this.getClasses(),style:this.styles},a("cura-label",{size:"xsmall","line-height":"none",color:this.labelColor},this.number>=100?"99+":this.number)))}static get watchers(){return{disabled:[{handleColorChange:0}],color:[{handleColorChange:0}],type:[{handleColorChange:0}]}}static get style(){return':host{width:fit-content;display:inline-block;height:calc(var(--cura-spacing-base) * 4px);position:relative}:host .container{display:flex;min-width:calc(var(--cura-spacing-base) * 4px);width:fit-content;height:calc(var(--cura-spacing-base) * 4px);justify-content:center;align-items:center;border-radius:calc(calc(var(--cura-spacing-base) * 4px) / 2);background:var(--background-color);box-sizing:border-box;padding:0 calc(var(--cura-spacing-base) * 1px);position:relative}:host .container.outline,:host .container.transparent{background:transparent !important}:host .container.outline::before{content:"";width:100%;height:100%;position:absolute;left:0px;top:0px;box-sizing:border-box;border:1px solid var(--background-color);border-radius:calc(calc(var(--cura-spacing-base) * 4px) / 2)}'}},[1,"cura-badge-counter",{number:[514],color:[1],disabled:[4],type:[1],styles:[32]},void 0,{disabled:[{handleColorChange:0}],color:[{handleColorChange:0}],type:[{handleColorChange:0}]}]);function o(){"undefined"!=typeof customElements&&["cura-badge-counter","cura-label"].forEach((t=>{switch(t){case"cura-badge-counter":customElements.get(r(t))||customElements.define(r(t),n);break;case"cura-label":customElements.get(r(t))||i()}}))}export{n as C,o as d}
1
+ import{p as t,H as e,i as a,j as s,t as i}from"./p-DBXUEjWh.js";import{d as r}from"./p-Cm1Vfoc6.js";const o=t(class extends e{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.theme=window.CuraAPI.theme,this.color="primary",this.disabled=!1,this.type="solid",this.styles={},this.labelColor="primary-darker",this.bgColorName="primary-lighter"}handleColorChange(){this.setColors()}setColors(){const t=this.color.toLowerCase();"outline"===this.type||"transparent"===this.type?(this.bgColorName=this.disabled?"neutral-medium":`${t}-dark`,this.labelColor=this.bgColorName):(this.bgColorName="neutral"===t||this.disabled?"neutral-pale":`${t}-lighter`,this.labelColor=this.disabled?"neutral-medium":`${t}-dark`),this.styles=Object.assign(Object.assign({},this.styles),{"--background-color":this.theme.colors.getColor(`${this.bgColorName}`)})}connectedCallback(){this.styles["--base-spacing"]=this.theme.spacing.getSpacing(),this.setColors()}getClasses(){const t={container:!0};return t[this.type.toLowerCase()]=!0,t}render(){return a(s,{key:"8b67f2b913a10de53a519cdafcfbcb140b2adda5"},this.number&&this.number<=0?"":a("div",{class:this.getClasses(),style:this.styles},a("cura-label",{size:"xsmall","line-height":"none",color:this.labelColor},this.number>=100?"99+":this.number)))}static get watchers(){return{disabled:[{handleColorChange:0}],color:[{handleColorChange:0}],type:[{handleColorChange:0}]}}static get style(){return':host{width:fit-content;display:inline-block;height:calc(var(--cura-spacing-base) * 4px);position:relative}:host .container{display:flex;min-width:calc(var(--cura-spacing-base) * 4px);width:fit-content;height:calc(var(--cura-spacing-base) * 4px);justify-content:center;align-items:center;border-radius:calc(calc(var(--cura-spacing-base) * 4px) / 2);background:var(--background-color);box-sizing:border-box;padding:0 calc(var(--cura-spacing-base) * 1px);position:relative}:host .container.outline,:host .container.transparent{background:transparent !important}:host .container.outline::before{content:"";width:100%;height:100%;position:absolute;left:0px;top:0px;box-sizing:border-box;border:1px solid var(--background-color);border-radius:calc(calc(var(--cura-spacing-base) * 4px) / 2)}'}},[1,"cura-badge-counter",{number:[514],color:[1],disabled:[4],type:[1],styles:[32]},void 0,{disabled:[{handleColorChange:0}],color:[{handleColorChange:0}],type:[{handleColorChange:0}]}]);function n(){"undefined"!=typeof customElements&&["cura-badge-counter","cura-label"].forEach((t=>{switch(t){case"cura-badge-counter":customElements.get(i(t))||customElements.define(i(t),o);break;case"cura-label":customElements.get(i(t))||r()}}))}export{o as C,n as d}
@@ -1 +1 @@
1
- import{p as t,H as s,i as h,j as o,t as l}from"./p-DBXUEjWh.js";const e=t(class extends s{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.level=1,this.size="medium",this.weight="regular",this.spotColor="accent-dark",this.marginBlock="1.25em",this.lineHeight="130%",this.textOverflow="none",this.styles={},this.theme=window.CuraAPI.theme}connectedCallback(){this.setFontProperties()}getClasses(){const t={"textoverflow-single":"single"===this.textOverflow};return t[this.size.toLowerCase()]=!0,t[`${this.weight.toLowerCase()}-weight`]=!0,t}setFontProperties(){this.weights=this.theme.fonts.getWeights(),this.fontSizeBase=this.theme.fonts.getSize(),this.styles={"--font-family":window.CuraAPI.theme.fonts.getFamily("heading"),"--font-weight-regular":this.weights.regular,"--font-weight-medium":this.weights.medium,"--font-weight-bold":this.weights.bold,"--font-weight-black":this.weights.black}}hostCSSProperties(){const t=this.color?this.theme.colors.getColor(this.color):this.theme.fonts.getColor();return{"--margin-block":this.marginBlock,"--font-size-base":this.fontSizeBase,"--line-height":this.lineHeight,"--color-body":t||this.theme.colors.getColor("neutral-darker"),"--color-spot":this.theme.colors.getColor(`${this.spotColor}`)}}getHeadingTag(){const t={1:h("h1",{style:this.styles,class:this.getClasses()},h("slot",null)),2:h("h2",{style:this.styles,class:this.getClasses()},h("slot",null)),3:h("h3",{style:this.styles,class:this.getClasses()},h("slot",null)),4:h("h4",{style:this.styles,class:this.getClasses()},h("slot",null)),5:h("h5",{style:this.styles,class:this.getClasses()},h("slot",null)),6:h("h6",{style:this.styles,class:this.getClasses()},h("slot",null)),default:h("h1",{style:this.styles,class:this.getClasses()},h("slot",null))};return t[`${this.level}`]||t.default}render(){return h(o,{key:"d32c25d0110f82182f4559789f3d2db04e040afe",style:this.hostCSSProperties(),role:"heading","aria-level":this.level},this.getHeadingTag())}get host(){return this}static get style(){return":host{display:block;font-size:var(--font-size-base)}:host h1,:host h2,:host h3,:host h4,:host h5,:host h6{font-family:var(--font-family);font-size:1.714em;font-weight:var(--font-weight-regular);color:var(--color-body);line-height:var(--line-height);margin-block:var(--margin-block);letter-spacing:0px}:host h1.bold-weight,:host h2.bold-weight,:host h3.bold-weight,:host h4.bold-weight,:host h5.bold-weight,:host h6.bold-weight{font-weight:var(--font-weight-medium)}:host h1.large,:host h2.large,:host h3.large,:host h4.large,:host h5.large,:host h6.large{font-size:2.071em;letter-spacing:-0.58px}:host h1.small,:host h2.small,:host h3.small,:host h4.small,:host h5.small,:host h6.small{font-size:1.214em;line-height:calc(var(--line-height) + 20%)}:host h1.small.bold-weight,:host h1.small ::slotted(b),:host h1.small ::slotted(strong),:host h2.small.bold-weight,:host h2.small ::slotted(b),:host h2.small ::slotted(strong),:host h3.small.bold-weight,:host h3.small ::slotted(b),:host h3.small ::slotted(strong),:host h4.small.bold-weight,:host h4.small ::slotted(b),:host h4.small ::slotted(strong),:host h5.small.bold-weight,:host h5.small ::slotted(b),:host h5.small ::slotted(strong),:host h6.small.bold-weight,:host h6.small ::slotted(b),:host h6.small ::slotted(strong){font-weight:var(--font-weight-bold)}:host h1.xsmall,:host h2.xsmall,:host h3.xsmall,:host h4.xsmall,:host h5.xsmall,:host h6.xsmall{font-size:0.8571428571em;font-weight:var(--font-weight-medium);letter-spacing:0.6px}:host h1.xsmall.bold-weight,:host h1.xsmall ::slotted(b),:host h1.xsmall ::slotted(strong),:host h2.xsmall.bold-weight,:host h2.xsmall ::slotted(b),:host h2.xsmall ::slotted(strong),:host h3.xsmall.bold-weight,:host h3.xsmall ::slotted(b),:host h3.xsmall ::slotted(strong),:host h4.xsmall.bold-weight,:host h4.xsmall ::slotted(b),:host h4.xsmall ::slotted(strong),:host h5.xsmall.bold-weight,:host h5.xsmall ::slotted(b),:host h5.xsmall ::slotted(strong),:host h6.xsmall.bold-weight,:host h6.xsmall ::slotted(b),:host h6.xsmall ::slotted(strong){font-weight:var(--font-weight-bold)}:host h1.textoverflow-single,:host h2.textoverflow-single,:host h3.textoverflow-single,:host h4.textoverflow-single,:host h5.textoverflow-single,:host h6.textoverflow-single{text-overflow:ellipsis;white-space:nowrap;overflow:hidden;display:block}:host h1 ::slotted(b),:host h1 ::slotted(strong),:host h2 ::slotted(b),:host h2 ::slotted(strong),:host h3 ::slotted(b),:host h3 ::slotted(strong),:host h4 ::slotted(b),:host h4 ::slotted(strong),:host h5 ::slotted(b),:host h5 ::slotted(strong),:host h6 ::slotted(b),:host h6 ::slotted(strong){font-weight:var(--font-weight-medium)}:host h1 ::slotted(a),:host h2 ::slotted(a),:host h3 ::slotted(a),:host h4 ::slotted(a),:host h5 ::slotted(a),:host h6 ::slotted(a){font-weight:var(--font-weight-bold);color:var(--color-spot);text-underline-offset:10%;cursor:pointer}:host h1 ::slotted(u),:host h2 ::slotted(u),:host h3 ::slotted(u),:host h4 ::slotted(u),:host h5 ::slotted(u),:host h6 ::slotted(u){text-underline-offset:10%}:host h1 ::slotted(abbr),:host h2 ::slotted(abbr),:host h3 ::slotted(abbr),:host h4 ::slotted(abbr),:host h5 ::slotted(abbr),:host h6 ::slotted(abbr){color:var(--color-spot);text-decoration:underline dashed 1px var(--color-spot);text-underline-offset:10%;cursor:default}:host h1 ::slotted(i),:host h2 ::slotted(i),:host h3 ::slotted(i),:host h4 ::slotted(i),:host h5 ::slotted(i),:host h6 ::slotted(i){font-weight:var(--font-weight-medium)}:host h1 ::slotted(em),:host h2 ::slotted(em),:host h3 ::slotted(em),:host h4 ::slotted(em),:host h5 ::slotted(em),:host h6 ::slotted(em){color:var(--color-spot);font-weight:var(--font-weight-bold);font-style:normal}@media (min-width: 769px) and (max-width: 1920px){:host h1,:host h2,:host h3,:host h4,:host h5,:host h6{font-size:2em}:host h1.large,:host h2.large,:host h3.large,:host h4.large,:host h5.large,:host h6.large{font-size:2.357em;letter-spacing:-0.66px}:host h1.small,:host h2.small,:host h3.small,:host h4.small,:host h5.small,:host h6.small{font-size:1.357em}:host h1.xsmall,:host h2.xsmall,:host h3.xsmall,:host h4.xsmall,:host h5.xsmall,:host h6.xsmall{font-size:0.8571428571em;line-height:calc(var(--line-height) + 3%);letter-spacing:0.72px}}@media (min-width: 1921px){:host h1,:host h2,:host h3,:host h4,:host h5,:host h6{font-size:2.5em;line-height:calc(var(--line-height) + 5%);letter-spacing:-0.82px}:host h1.large,:host h2.large,:host h3.large,:host h4.large,:host h5.large,:host h6.large{font-size:2.929em}:host h1.small,:host h2.small,:host h3.small,:host h4.small,:host h5.small,:host h6.small{font-size:1.714em;line-height:calc(var(--line-height) + 30%);letter-spacing:0%}:host h1.xsmall,:host h2.xsmall,:host h3.xsmall,:host h4.xsmall,:host h5.xsmall,:host h6.xsmall{font-size:1em;line-height:calc(var(--line-height) + 12.857%);letter-spacing:0.28px}}"}},[257,"cura-heading",{level:[514],size:[513],weight:[513],spotColor:[513,"spot-color"],color:[513],marginBlock:[513,"margin-block"],lineHeight:[513,"line-height"],textOverflow:[513,"text-overflow"],styles:[32]}]);function i(){"undefined"!=typeof customElements&&["cura-heading"].forEach((t=>{"cura-heading"===t&&(customElements.get(l(t))||customElements.define(l(t),e))}))}export{e as C,i as d}
1
+ import{p as t,H as s,i as h,j as o,t as l}from"./p-DBXUEjWh.js";const e=t(class extends s{constructor(t){super(),!1!==t&&this.__registerHost(),this.__attachShadow(),this.level=1,this.size="medium",this.weight="regular",this.spotColor="accent-dark",this.marginBlock="1.25em",this.lineHeight="130%",this.textOverflow="none",this.styles={},this.theme=window.CuraAPI.theme}connectedCallback(){this.setFontProperties()}getClasses(){const t={"textoverflow-single":"single"===this.textOverflow};return t[this.size.toLowerCase()]=!0,t[`${this.weight.toLowerCase()}-weight`]=!0,t}setFontProperties(){this.weights=this.theme.fonts.getWeights(),this.fontSizeBase=this.theme.fonts.getSize(),this.styles={"--font-family":window.CuraAPI.theme.fonts.getFamily("heading"),"--font-weight-regular":this.weights.regular,"--font-weight-medium":this.weights.medium,"--font-weight-bold":this.weights.bold,"--font-weight-black":this.weights.black}}hostCSSProperties(){const t=this.color?this.theme.colors.getColor(this.color):this.theme.fonts.getColor();return{"--margin-block":this.marginBlock,"--font-size-base":this.fontSizeBase,"--line-height":this.lineHeight,"--color-body":t||this.theme.colors.getColor("neutral-darker"),"--color-spot":this.theme.colors.getColor(`${this.spotColor}`)}}getHeadingTag(){const t={1:h("h1",{style:this.styles,class:this.getClasses()},h("slot",null)),2:h("h2",{style:this.styles,class:this.getClasses()},h("slot",null)),3:h("h3",{style:this.styles,class:this.getClasses()},h("slot",null)),4:h("h4",{style:this.styles,class:this.getClasses()},h("slot",null)),5:h("h5",{style:this.styles,class:this.getClasses()},h("slot",null)),6:h("h6",{style:this.styles,class:this.getClasses()},h("slot",null)),default:h("h1",{style:this.styles,class:this.getClasses()},h("slot",null))};return t[`${this.level}`]||t.default}render(){return h(o,{key:"e28268e7d797af495f6accb8536e88ac49ef608f",style:this.hostCSSProperties(),role:"heading","aria-level":this.level},this.getHeadingTag())}get host(){return this}static get style(){return":host{display:block;font-size:var(--font-size-base)}:host h1,:host h2,:host h3,:host h4,:host h5,:host h6{font-family:var(--font-family);font-size:1.714em;font-weight:var(--font-weight-regular);color:var(--color-body);line-height:var(--line-height);margin-block:var(--margin-block);letter-spacing:0px}:host h1.bold-weight,:host h2.bold-weight,:host h3.bold-weight,:host h4.bold-weight,:host h5.bold-weight,:host h6.bold-weight{font-weight:var(--font-weight-medium)}:host h1.large,:host h2.large,:host h3.large,:host h4.large,:host h5.large,:host h6.large{font-size:2.071em;letter-spacing:-0.58px}:host h1.small,:host h2.small,:host h3.small,:host h4.small,:host h5.small,:host h6.small{font-size:1.214em;line-height:calc(var(--line-height) + 20%)}:host h1.small.bold-weight,:host h1.small ::slotted(b),:host h1.small ::slotted(strong),:host h2.small.bold-weight,:host h2.small ::slotted(b),:host h2.small ::slotted(strong),:host h3.small.bold-weight,:host h3.small ::slotted(b),:host h3.small ::slotted(strong),:host h4.small.bold-weight,:host h4.small ::slotted(b),:host h4.small ::slotted(strong),:host h5.small.bold-weight,:host h5.small ::slotted(b),:host h5.small ::slotted(strong),:host h6.small.bold-weight,:host h6.small ::slotted(b),:host h6.small ::slotted(strong){font-weight:var(--font-weight-bold)}:host h1.xsmall,:host h2.xsmall,:host h3.xsmall,:host h4.xsmall,:host h5.xsmall,:host h6.xsmall{font-size:0.8571428571em;font-weight:var(--font-weight-medium);letter-spacing:0.6px}:host h1.xsmall.bold-weight,:host h1.xsmall ::slotted(b),:host h1.xsmall ::slotted(strong),:host h2.xsmall.bold-weight,:host h2.xsmall ::slotted(b),:host h2.xsmall ::slotted(strong),:host h3.xsmall.bold-weight,:host h3.xsmall ::slotted(b),:host h3.xsmall ::slotted(strong),:host h4.xsmall.bold-weight,:host h4.xsmall ::slotted(b),:host h4.xsmall ::slotted(strong),:host h5.xsmall.bold-weight,:host h5.xsmall ::slotted(b),:host h5.xsmall ::slotted(strong),:host h6.xsmall.bold-weight,:host h6.xsmall ::slotted(b),:host h6.xsmall ::slotted(strong){font-weight:var(--font-weight-bold)}:host h1.textoverflow-single,:host h2.textoverflow-single,:host h3.textoverflow-single,:host h4.textoverflow-single,:host h5.textoverflow-single,:host h6.textoverflow-single{text-overflow:ellipsis;white-space:nowrap;overflow:hidden;display:block}:host h1 ::slotted(b),:host h1 ::slotted(strong),:host h2 ::slotted(b),:host h2 ::slotted(strong),:host h3 ::slotted(b),:host h3 ::slotted(strong),:host h4 ::slotted(b),:host h4 ::slotted(strong),:host h5 ::slotted(b),:host h5 ::slotted(strong),:host h6 ::slotted(b),:host h6 ::slotted(strong){font-weight:var(--font-weight-medium)}:host h1 ::slotted(a),:host h2 ::slotted(a),:host h3 ::slotted(a),:host h4 ::slotted(a),:host h5 ::slotted(a),:host h6 ::slotted(a){font-weight:var(--font-weight-bold);color:var(--color-spot);text-underline-offset:10%;cursor:pointer}:host h1 ::slotted(u),:host h2 ::slotted(u),:host h3 ::slotted(u),:host h4 ::slotted(u),:host h5 ::slotted(u),:host h6 ::slotted(u){text-underline-offset:10%}:host h1 ::slotted(abbr),:host h2 ::slotted(abbr),:host h3 ::slotted(abbr),:host h4 ::slotted(abbr),:host h5 ::slotted(abbr),:host h6 ::slotted(abbr){color:var(--color-spot);text-decoration:underline dashed 1px var(--color-spot);text-underline-offset:10%;cursor:default}:host h1 ::slotted(i),:host h2 ::slotted(i),:host h3 ::slotted(i),:host h4 ::slotted(i),:host h5 ::slotted(i),:host h6 ::slotted(i){font-weight:var(--font-weight-medium)}:host h1 ::slotted(em),:host h2 ::slotted(em),:host h3 ::slotted(em),:host h4 ::slotted(em),:host h5 ::slotted(em),:host h6 ::slotted(em){color:var(--color-spot);font-weight:var(--font-weight-bold);font-style:normal}@media (min-width: 769px) and (max-width: 1920px){:host h1,:host h2,:host h3,:host h4,:host h5,:host h6{font-size:2em}:host h1.large,:host h2.large,:host h3.large,:host h4.large,:host h5.large,:host h6.large{font-size:2.357em;letter-spacing:-0.66px}:host h1.small,:host h2.small,:host h3.small,:host h4.small,:host h5.small,:host h6.small{font-size:1.357em}:host h1.xsmall,:host h2.xsmall,:host h3.xsmall,:host h4.xsmall,:host h5.xsmall,:host h6.xsmall{font-size:0.8571428571em;line-height:calc(var(--line-height) + 3%);letter-spacing:0.72px}}@media (min-width: 1921px){:host h1,:host h2,:host h3,:host h4,:host h5,:host h6{font-size:2.5em;line-height:calc(var(--line-height) + 5%);letter-spacing:-0.82px}:host h1.large,:host h2.large,:host h3.large,:host h4.large,:host h5.large,:host h6.large{font-size:2.929em}:host h1.small,:host h2.small,:host h3.small,:host h4.small,:host h5.small,:host h6.small{font-size:1.714em;line-height:calc(var(--line-height) + 30%);letter-spacing:0%}:host h1.xsmall,:host h2.xsmall,:host h3.xsmall,:host h4.xsmall,:host h5.xsmall,:host h6.xsmall{font-size:1em;line-height:calc(var(--line-height) + 12.857%);letter-spacing:0.28px}}"}},[257,"cura-heading",{level:[514],size:[513],weight:[513],spotColor:[513,"spot-color"],color:[513],marginBlock:[513,"margin-block"],lineHeight:[513,"line-height"],textOverflow:[513,"text-overflow"],styles:[32]}]);function i(){"undefined"!=typeof customElements&&["cura-heading"].forEach((t=>{"cura-heading"===t&&(customElements.get(l(t))||customElements.define(l(t),e))}))}export{e as C,i as d}
@@ -1 +1 @@
1
- import{p as s,H as e,i as r,j as t,t as a}from"./p-DBXUEjWh.js";const o=s(class extends e{constructor(s){super(),!1!==s&&this.__registerHost(),this.__attachShadow(),this.color="primary-base",this.progress=0,this.styles={}}handleChangeColor(){this.setColor()}handleProgress(){this.setProgress()}connectedCallback(){this.setColor(),this.setProgress()}render(){return r(t,{key:"397073d5ad18c49fedee1832e89c15108b693e01",role:"progressbar","aria-valuenow":this.progress,"aria-valuemin":0,"aria-valuemax":100},r("div",{key:"e3c46bc440ee9c54b308679fa8358df4f10c6a9c",id:"progress-bar",class:"progress-bar",style:this.styles},r("span",{key:"1635e7d72dd6b34455a1891f6a1907f603c91cb7",class:"progress-bar-fill"})))}setColor(){this.styles=Object.assign(Object.assign({},this.styles),{"--neutral-base":window.CuraAPI.theme.colors.getColor("neutral-base",.2),"--color-base":window.CuraAPI.theme.colors.getColor(this.color)})}setProgress(){this.styles=Object.assign(Object.assign({},this.styles),{"--bar-width":`${this.progress}%`})}get host(){return this}static get watchers(){return{color:[{handleChangeColor:0}],progress:[{handleProgress:0}]}}static get style(){return":host{display:block}:host .progress-bar{position:absolute;left:0;bottom:0;width:100%;height:4px;background-color:var(--neutral-base)}:host .progress-bar span{position:absolute;left:0;bottom:0;width:var(--bar-width);height:100%;border-radius:0 2px 2px 0;background-color:var(--color-base);transition:width 0.2s linear}"}},[1,"cura-loader-bar",{color:[1],progress:[2],styles:[32]},void 0,{color:[{handleChangeColor:0}],progress:[{handleProgress:0}]}]);function i(){"undefined"!=typeof customElements&&["cura-loader-bar"].forEach((s=>{"cura-loader-bar"===s&&(customElements.get(a(s))||customElements.define(a(s),o))}))}export{o as C,i as d}
1
+ import{p as s,H as e,i as r,j as t,t as a}from"./p-DBXUEjWh.js";const o=s(class extends e{constructor(s){super(),!1!==s&&this.__registerHost(),this.__attachShadow(),this.color="primary-base",this.progress=0,this.styles={}}handleChangeColor(){this.setColor()}handleProgress(){this.setProgress()}connectedCallback(){this.setColor(),this.setProgress()}render(){return r(t,{key:"dd27615093a7ab333175afb1e48bbe5455d7406b",role:"progressbar","aria-valuenow":this.progress,"aria-valuemin":0,"aria-valuemax":100},r("div",{key:"c3c76b76826c558769d43e441d9e0c573fb7eb7b",id:"progress-bar",class:"progress-bar",style:this.styles},r("span",{key:"0e8e361bdf63e558fa34cca67c3446b1147c2643",class:"progress-bar-fill"})))}setColor(){this.styles=Object.assign(Object.assign({},this.styles),{"--neutral-base":window.CuraAPI.theme.colors.getColor("neutral-base",.2),"--color-base":window.CuraAPI.theme.colors.getColor(this.color)})}setProgress(){this.styles=Object.assign(Object.assign({},this.styles),{"--bar-width":`${this.progress}%`})}get host(){return this}static get watchers(){return{color:[{handleChangeColor:0}],progress:[{handleProgress:0}]}}static get style(){return":host{display:block}:host .progress-bar{position:absolute;left:0;bottom:0;width:100%;height:4px;background-color:var(--neutral-base)}:host .progress-bar span{position:absolute;left:0;bottom:0;width:var(--bar-width);height:100%;border-radius:0 2px 2px 0;background-color:var(--color-base);transition:width 0.2s linear}"}},[1,"cura-loader-bar",{color:[1],progress:[2],styles:[32]},void 0,{color:[{handleChangeColor:0}],progress:[{handleProgress:0}]}]);function i(){"undefined"!=typeof customElements&&["cura-loader-bar"].forEach((s=>{"cura-loader-bar"===s&&(customElements.get(a(s))||customElements.define(a(s),o))}))}export{o as C,i as d}