@rededor/cura 0.5.2 → 0.5.3

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 (283) hide show
  1. package/dist/assets/icons/iconset-default-list.ts +1 -1
  2. package/dist/assets/icons/iconset-default-tmp.svg +4 -0
  3. package/dist/assets/icons/iconset-default.svg +1 -1
  4. package/dist/cjs/cura-accordion_8.cjs.entry.js +10 -17
  5. package/dist/cjs/cura-accordion_8.cjs.entry.js.map +1 -1
  6. package/dist/cjs/cura-alert.cjs.entry.js +67 -0
  7. package/dist/cjs/cura-alert.cjs.entry.js.map +1 -0
  8. package/dist/cjs/cura-button-outline.cjs.entry.js +1 -1
  9. package/dist/cjs/cura-button-select.cjs.entry.js +97 -0
  10. package/dist/cjs/cura-button-select.cjs.entry.js.map +1 -0
  11. package/dist/cjs/cura-button-transparent.cjs.entry.js +1 -1
  12. package/dist/cjs/cura-checkbox.cjs.entry.js +144 -0
  13. package/dist/cjs/cura-checkbox.cjs.entry.js.map +1 -0
  14. package/dist/cjs/cura-display.cjs.entry.js +1 -1
  15. package/dist/cjs/cura-forms.definitions-11be2ebd.js +20 -0
  16. package/dist/cjs/cura-forms.definitions-11be2ebd.js.map +1 -0
  17. package/dist/cjs/cura-icon.definitions-b73b0178.js +21 -0
  18. package/dist/cjs/cura-icon.definitions-b73b0178.js.map +1 -0
  19. package/dist/cjs/cura-icons-view.cjs.entry.js +13 -6
  20. package/dist/cjs/cura-icons-view.cjs.entry.js.map +1 -1
  21. package/dist/cjs/cura-input-text.cjs.entry.js +3907 -0
  22. package/dist/cjs/cura-input-text.cjs.entry.js.map +1 -0
  23. package/dist/cjs/cura-label.cjs.entry.js +1 -1
  24. package/dist/cjs/cura-radio.cjs.entry.js +114 -0
  25. package/dist/cjs/cura-radio.cjs.entry.js.map +1 -0
  26. package/dist/cjs/cura-switch.cjs.entry.js +89 -0
  27. package/dist/cjs/cura-switch.cjs.entry.js.map +1 -0
  28. package/dist/cjs/cura.cjs.js +2 -2
  29. package/dist/cjs/{index-404d93e9.js → index-7616f620.js} +35 -1
  30. package/dist/cjs/index-7616f620.js.map +1 -0
  31. package/dist/cjs/loader.cjs.js +2 -2
  32. package/dist/collection/assets/icons/iconset-default-list.js +1 -1
  33. package/dist/collection/assets/icons/iconset-default-list.js.map +1 -1
  34. package/dist/collection/assets/icons/iconset-default-tmp.svg +4 -0
  35. package/dist/collection/assets/icons/iconset-default.svg +1 -1
  36. package/dist/collection/assets-raw/icons/default/swap.svg +3 -0
  37. package/dist/collection/collection-manifest.json +6 -0
  38. package/dist/collection/components/buttons/cura-button/cura-button.css +4 -0
  39. package/dist/collection/components/buttons/cura-button/cura-button.stories.js +2 -2
  40. package/dist/collection/components/buttons/cura-button/cura-button.stories.js.map +1 -1
  41. package/dist/collection/components/buttons/cura-button-outline/cura-button-outline.css +4 -0
  42. package/dist/collection/components/buttons/cura-button-outline/cura-button-outline.stories.js +2 -2
  43. package/dist/collection/components/buttons/cura-button-outline/cura-button-outline.stories.js.map +1 -1
  44. package/dist/collection/components/buttons/cura-button-select/cura-button-select.css +139 -0
  45. package/dist/collection/components/buttons/cura-button-select/cura-button-select.js +263 -0
  46. package/dist/collection/components/buttons/cura-button-select/cura-button-select.js.map +1 -0
  47. package/dist/collection/components/buttons/cura-button-transparent/cura-button-transparent.css +4 -0
  48. package/dist/collection/components/buttons/cura-button-transparent/cura-button-transparent.stories.js +2 -2
  49. package/dist/collection/components/buttons/cura-button-transparent/cura-button-transparent.stories.js.map +1 -1
  50. package/dist/collection/components/cura-alert/cura-alert.css +30 -0
  51. package/dist/collection/components/cura-alert/cura-alert.js +167 -0
  52. package/dist/collection/components/cura-alert/cura-alert.js.map +1 -0
  53. package/dist/collection/components/cura-alert/cura-alert.stories.js +95 -0
  54. package/dist/collection/components/cura-alert/cura-alert.stories.js.map +1 -0
  55. package/dist/collection/components/cura-icon/cura-icon.definitions.js +15 -0
  56. package/dist/collection/components/cura-icon/cura-icon.definitions.js.map +1 -0
  57. package/dist/collection/components/cura-icon/cura-icon.js +9 -16
  58. package/dist/collection/components/cura-icon/cura-icon.js.map +1 -1
  59. package/dist/collection/components/cura-icon/cura-icon.stories.js +7 -6
  60. package/dist/collection/components/cura-icon/cura-icon.stories.js.map +1 -1
  61. package/dist/collection/components/cura-icons-view/cura-icons-view.css +16 -17
  62. package/dist/collection/components/cura-icons-view/cura-icons-view.js +10 -3
  63. package/dist/collection/components/cura-icons-view/cura-icons-view.js.map +1 -1
  64. package/dist/collection/components/forms/cura-checkbox/cura-checkbox.css +163 -0
  65. package/dist/collection/components/forms/cura-checkbox/cura-checkbox.js +431 -0
  66. package/dist/collection/components/forms/cura-checkbox/cura-checkbox.js.map +1 -0
  67. package/dist/collection/components/forms/cura-checkbox/cura-checkbox.stories.js +196 -0
  68. package/dist/collection/components/forms/cura-checkbox/cura-checkbox.stories.js.map +1 -0
  69. package/dist/collection/components/forms/cura-forms.definitions.js +15 -0
  70. package/dist/collection/components/forms/cura-forms.definitions.js.map +1 -0
  71. package/dist/collection/components/forms/cura-input-text/cura-input-text.css +326 -0
  72. package/dist/collection/components/forms/cura-input-text/cura-input-text.js +655 -0
  73. package/dist/collection/components/forms/cura-input-text/cura-input-text.js.map +1 -0
  74. package/dist/collection/components/forms/cura-input-text/cura-input-text.stories.js +224 -0
  75. package/dist/collection/components/forms/cura-input-text/cura-input-text.stories.js.map +1 -0
  76. package/dist/collection/components/forms/cura-input-text/mask-presets/input-mask-presets.js +46 -0
  77. package/dist/collection/components/forms/cura-input-text/mask-presets/input-mask-presets.js.map +1 -0
  78. package/dist/collection/components/forms/cura-radio/cura-radio.css +146 -0
  79. package/dist/collection/components/forms/cura-radio/cura-radio.js +365 -0
  80. package/dist/collection/components/forms/cura-radio/cura-radio.js.map +1 -0
  81. package/dist/collection/components/forms/cura-radio/cura-radio.stories.js +175 -0
  82. package/dist/collection/components/forms/cura-radio/cura-radio.stories.js.map +1 -0
  83. package/dist/collection/components/forms/cura-switch/cura-switch.css +100 -0
  84. package/dist/collection/components/forms/cura-switch/cura-switch.js +266 -0
  85. package/dist/collection/components/forms/cura-switch/cura-switch.js.map +1 -0
  86. package/dist/collection/components/forms/cura-switch/cura-switch.stories.js +137 -0
  87. package/dist/collection/components/forms/cura-switch/cura-switch.stories.js.map +1 -0
  88. package/dist/components/cura-alert.d.ts +11 -0
  89. package/dist/components/cura-alert.js +105 -0
  90. package/dist/components/cura-alert.js.map +1 -0
  91. package/dist/components/cura-button-select.d.ts +11 -0
  92. package/dist/components/cura-button-select.js +127 -0
  93. package/dist/components/cura-button-select.js.map +1 -0
  94. package/dist/components/cura-checkbox.d.ts +11 -0
  95. package/dist/components/cura-checkbox.js +192 -0
  96. package/dist/components/cura-checkbox.js.map +1 -0
  97. package/dist/components/cura-forms.definitions.js +18 -0
  98. package/dist/components/cura-forms.definitions.js.map +1 -0
  99. package/dist/components/cura-heading.js +1 -100
  100. package/dist/components/cura-heading.js.map +1 -1
  101. package/dist/components/cura-heading2.js +104 -0
  102. package/dist/components/cura-heading2.js.map +1 -0
  103. package/dist/components/cura-icon2.js +24 -17
  104. package/dist/components/cura-icon2.js.map +1 -1
  105. package/dist/components/cura-icons-view.js +31 -7
  106. package/dist/components/cura-icons-view.js.map +1 -1
  107. package/dist/components/cura-input-text.d.ts +11 -0
  108. package/dist/components/cura-input-text.js +3961 -0
  109. package/dist/components/cura-input-text.js.map +1 -0
  110. package/dist/components/cura-label.js +1 -84
  111. package/dist/components/cura-label.js.map +1 -1
  112. package/dist/components/cura-label2.js +88 -0
  113. package/dist/components/cura-label2.js.map +1 -0
  114. package/dist/components/cura-paragraph.js +1 -82
  115. package/dist/components/cura-paragraph.js.map +1 -1
  116. package/dist/components/cura-paragraph2.js +86 -0
  117. package/dist/components/cura-paragraph2.js.map +1 -0
  118. package/dist/components/cura-radio.d.ts +11 -0
  119. package/dist/components/cura-radio.js +154 -0
  120. package/dist/components/cura-radio.js.map +1 -0
  121. package/dist/components/cura-switch.d.ts +11 -0
  122. package/dist/components/cura-switch.js +119 -0
  123. package/dist/components/cura-switch.js.map +1 -0
  124. package/dist/components/index.js +12 -0
  125. package/dist/components/index.js.map +1 -1
  126. package/dist/cura/cura.esm.js +1 -1
  127. package/dist/cura/cura.esm.js.map +1 -1
  128. package/dist/cura/cura.js +1 -1
  129. package/dist/cura/p-1228e771.entry.js +2 -0
  130. package/dist/cura/p-1228e771.entry.js.map +1 -0
  131. package/dist/cura/p-2d42ccf4.entry.js +2 -0
  132. package/dist/cura/p-2d42ccf4.entry.js.map +1 -0
  133. package/dist/cura/p-3688570d.js +2 -0
  134. package/dist/cura/p-3688570d.js.map +1 -0
  135. package/dist/cura/p-36a83bc7.system.js +3 -0
  136. package/dist/cura/p-36a83bc7.system.js.map +1 -0
  137. package/dist/cura/p-3f3355f3.system.entry.js +2 -0
  138. package/dist/cura/p-3f3355f3.system.entry.js.map +1 -0
  139. package/dist/cura/p-4df84c9e.entry.js +2 -0
  140. package/dist/cura/p-4df84c9e.entry.js.map +1 -0
  141. package/dist/cura/p-70cefaf8.entry.js +2 -0
  142. package/dist/cura/p-70cefaf8.entry.js.map +1 -0
  143. package/dist/cura/{p-0c79c54e.entry.js → p-72a9ed55.entry.js} +2 -2
  144. package/dist/cura/{p-7c8f3c77.system.entry.js → p-75b2e4d1.system.entry.js} +2 -2
  145. package/dist/cura/{p-03047b3e.entry.js → p-880917c1.entry.js} +2 -2
  146. package/dist/cura/{p-d47b9cfe.system.entry.js → p-9471c93e.system.entry.js} +2 -2
  147. package/dist/cura/p-98014544.entry.js +2 -0
  148. package/dist/cura/p-98014544.entry.js.map +1 -0
  149. package/dist/cura/{p-223924fb.system.entry.js → p-98352c92.system.entry.js} +2 -2
  150. package/dist/cura/p-a32889a4.system.js +2 -0
  151. package/dist/cura/p-a32889a4.system.js.map +1 -0
  152. package/dist/cura/p-a6d20c12.system.entry.js +2 -0
  153. package/dist/cura/p-a6d20c12.system.entry.js.map +1 -0
  154. package/dist/cura/p-ab8c9a8f.system.entry.js +2 -0
  155. package/dist/cura/p-ab8c9a8f.system.entry.js.map +1 -0
  156. package/dist/cura/{p-91b0f78e.entry.js → p-ad194144.entry.js} +2 -2
  157. package/dist/cura/p-b0e13882.system.entry.js +2 -0
  158. package/dist/cura/p-b0e13882.system.entry.js.map +1 -0
  159. package/dist/cura/p-ba66d7be.js +3 -0
  160. package/dist/cura/{p-c0c00396.system.js.map → p-ba66d7be.js.map} +1 -1
  161. package/dist/cura/p-bb3f9d05.entry.js +2 -0
  162. package/dist/cura/p-bb3f9d05.entry.js.map +1 -0
  163. package/dist/cura/p-c791725b.js +2 -0
  164. package/dist/cura/p-c791725b.js.map +1 -0
  165. package/dist/cura/p-c9afb94f.entry.js +2 -0
  166. package/dist/cura/p-c9afb94f.entry.js.map +1 -0
  167. package/dist/cura/p-d3f9c888.system.js +2 -0
  168. package/dist/cura/p-d3f9c888.system.js.map +1 -0
  169. package/dist/cura/{p-ca054b07.system.entry.js → p-e5e259fd.system.entry.js} +2 -2
  170. package/dist/cura/{p-49813052.entry.js → p-edeffbfc.entry.js} +2 -2
  171. package/dist/cura/p-eea5ca70.system.entry.js +2 -0
  172. package/dist/cura/p-eea5ca70.system.entry.js.map +1 -0
  173. package/dist/cura/p-f6e61abf.system.entry.js +2 -0
  174. package/dist/cura/p-f6e61abf.system.entry.js.map +1 -0
  175. package/dist/cura/p-f89f2ecc.system.entry.js +2 -0
  176. package/dist/cura/p-f89f2ecc.system.entry.js.map +1 -0
  177. package/dist/cura/p-fc4ba4ce.system.js +2 -0
  178. package/dist/cura/p-fc4ba4ce.system.js.map +1 -0
  179. package/dist/cura/p-fef52079.entry.js +2 -0
  180. package/dist/cura/p-fef52079.entry.js.map +1 -0
  181. package/dist/cura/p-ffd41520.system.entry.js +2 -0
  182. package/dist/cura/p-ffd41520.system.entry.js.map +1 -0
  183. package/dist/esm/cura-accordion_8.entry.js +10 -17
  184. package/dist/esm/cura-accordion_8.entry.js.map +1 -1
  185. package/dist/esm/cura-alert.entry.js +63 -0
  186. package/dist/esm/cura-alert.entry.js.map +1 -0
  187. package/dist/esm/cura-button-outline.entry.js +1 -1
  188. package/dist/esm/cura-button-select.entry.js +93 -0
  189. package/dist/esm/cura-button-select.entry.js.map +1 -0
  190. package/dist/esm/cura-button-transparent.entry.js +1 -1
  191. package/dist/esm/cura-checkbox.entry.js +140 -0
  192. package/dist/esm/cura-checkbox.entry.js.map +1 -0
  193. package/dist/esm/cura-display.entry.js +1 -1
  194. package/dist/esm/cura-forms.definitions-0f774253.js +18 -0
  195. package/dist/esm/cura-forms.definitions-0f774253.js.map +1 -0
  196. package/dist/esm/cura-icon.definitions-a63d1862.js +18 -0
  197. package/dist/esm/cura-icon.definitions-a63d1862.js.map +1 -0
  198. package/dist/esm/cura-icons-view.entry.js +13 -6
  199. package/dist/esm/cura-icons-view.entry.js.map +1 -1
  200. package/dist/esm/cura-input-text.entry.js +3903 -0
  201. package/dist/esm/cura-input-text.entry.js.map +1 -0
  202. package/dist/esm/cura-label.entry.js +1 -1
  203. package/dist/esm/cura-radio.entry.js +110 -0
  204. package/dist/esm/cura-radio.entry.js.map +1 -0
  205. package/dist/esm/cura-switch.entry.js +85 -0
  206. package/dist/esm/cura-switch.entry.js.map +1 -0
  207. package/dist/esm/cura.js +3 -3
  208. package/dist/esm/{index-d99da69e.js → index-81f1a268.js} +35 -2
  209. package/dist/{esm-es5/index-d99da69e.js.map → esm/index-81f1a268.js.map} +1 -1
  210. package/dist/esm/loader.js +3 -3
  211. package/dist/esm-es5/cura-accordion_8.entry.js +1 -1
  212. package/dist/esm-es5/cura-accordion_8.entry.js.map +1 -1
  213. package/dist/esm-es5/cura-alert.entry.js +2 -0
  214. package/dist/esm-es5/cura-alert.entry.js.map +1 -0
  215. package/dist/esm-es5/cura-button-outline.entry.js +1 -1
  216. package/dist/esm-es5/cura-button-select.entry.js +2 -0
  217. package/dist/esm-es5/cura-button-select.entry.js.map +1 -0
  218. package/dist/esm-es5/cura-button-transparent.entry.js +1 -1
  219. package/dist/esm-es5/cura-checkbox.entry.js +2 -0
  220. package/dist/esm-es5/cura-checkbox.entry.js.map +1 -0
  221. package/dist/esm-es5/cura-display.entry.js +1 -1
  222. package/dist/esm-es5/cura-forms.definitions-0f774253.js +2 -0
  223. package/dist/esm-es5/cura-forms.definitions-0f774253.js.map +1 -0
  224. package/dist/esm-es5/cura-icon.definitions-a63d1862.js +2 -0
  225. package/dist/esm-es5/cura-icon.definitions-a63d1862.js.map +1 -0
  226. package/dist/esm-es5/cura-icons-view.entry.js +1 -1
  227. package/dist/esm-es5/cura-icons-view.entry.js.map +1 -1
  228. package/dist/esm-es5/cura-input-text.entry.js +2 -0
  229. package/dist/esm-es5/cura-input-text.entry.js.map +1 -0
  230. package/dist/esm-es5/cura-label.entry.js +1 -1
  231. package/dist/esm-es5/cura-radio.entry.js +2 -0
  232. package/dist/esm-es5/cura-radio.entry.js.map +1 -0
  233. package/dist/esm-es5/cura-switch.entry.js +2 -0
  234. package/dist/esm-es5/cura-switch.entry.js.map +1 -0
  235. package/dist/esm-es5/cura.js +1 -1
  236. package/dist/esm-es5/cura.js.map +1 -1
  237. package/dist/esm-es5/index-81f1a268.js +3 -0
  238. package/dist/esm-es5/index-81f1a268.js.map +1 -0
  239. package/dist/esm-es5/loader.js +1 -1
  240. package/dist/esm-es5/loader.js.map +1 -1
  241. package/dist/types/components/buttons/cura-button/cura-button.d.ts +1 -1
  242. package/dist/types/components/buttons/cura-button-select/cura-button-select.d.ts +51 -0
  243. package/dist/types/components/cura-alert/cura-alert.d.ts +16 -0
  244. package/dist/types/components/cura-alert/cura-alert.stories.d.ts +79 -0
  245. package/dist/types/components/cura-icon/cura-icon.d.ts +0 -42
  246. package/dist/types/components/cura-icon/cura-icon.definitions.d.ts +47 -0
  247. package/dist/types/components/cura-icons-view/cura-icons-view.d.ts +2 -1
  248. package/dist/types/components/forms/cura-checkbox/cura-checkbox.d.ts +100 -0
  249. package/dist/types/components/forms/cura-checkbox/cura-checkbox.stories.d.ts +199 -0
  250. package/dist/types/components/forms/cura-forms.definitions.d.ts +14 -0
  251. package/dist/types/components/forms/cura-input-text/cura-input-text.d.ts +138 -0
  252. package/dist/types/components/forms/cura-input-text/cura-input-text.stories.d.ts +224 -0
  253. package/dist/types/components/forms/cura-input-text/mask-presets/input-mask-presets.d.ts +5 -0
  254. package/dist/types/components/forms/cura-radio/cura-radio.d.ts +81 -0
  255. package/dist/types/components/forms/cura-radio/cura-radio.stories.d.ts +180 -0
  256. package/dist/types/components/forms/cura-switch/cura-switch.d.ts +62 -0
  257. package/dist/types/components/forms/cura-switch/cura-switch.stories.d.ts +135 -0
  258. package/dist/types/components.d.ts +602 -0
  259. package/package.json +5 -4
  260. package/dist/cjs/index-404d93e9.js.map +0 -1
  261. package/dist/cura/p-46d20db3.js +0 -3
  262. package/dist/cura/p-46d20db3.js.map +0 -1
  263. package/dist/cura/p-4bdbcdf0.system.entry.js +0 -2
  264. package/dist/cura/p-4bdbcdf0.system.entry.js.map +0 -1
  265. package/dist/cura/p-8b18b5f7.system.js +0 -2
  266. package/dist/cura/p-8b18b5f7.system.js.map +0 -1
  267. package/dist/cura/p-a0395f90.entry.js +0 -2
  268. package/dist/cura/p-a0395f90.entry.js.map +0 -1
  269. package/dist/cura/p-a7ef255f.entry.js +0 -2
  270. package/dist/cura/p-a7ef255f.entry.js.map +0 -1
  271. package/dist/cura/p-c0c00396.system.js +0 -3
  272. package/dist/cura/p-fc77814b.system.entry.js +0 -2
  273. package/dist/cura/p-fc77814b.system.entry.js.map +0 -1
  274. package/dist/esm/index-d99da69e.js.map +0 -1
  275. package/dist/esm-es5/index-d99da69e.js +0 -3
  276. /package/dist/cura/{p-0c79c54e.entry.js.map → p-72a9ed55.entry.js.map} +0 -0
  277. /package/dist/cura/{p-7c8f3c77.system.entry.js.map → p-75b2e4d1.system.entry.js.map} +0 -0
  278. /package/dist/cura/{p-03047b3e.entry.js.map → p-880917c1.entry.js.map} +0 -0
  279. /package/dist/cura/{p-d47b9cfe.system.entry.js.map → p-9471c93e.system.entry.js.map} +0 -0
  280. /package/dist/cura/{p-223924fb.system.entry.js.map → p-98352c92.system.entry.js.map} +0 -0
  281. /package/dist/cura/{p-91b0f78e.entry.js.map → p-ad194144.entry.js.map} +0 -0
  282. /package/dist/cura/{p-ca054b07.system.entry.js.map → p-e5e259fd.system.entry.js.map} +0 -0
  283. /package/dist/cura/{p-49813052.entry.js.map → p-edeffbfc.entry.js.map} +0 -0
@@ -0,0 +1,2 @@
1
+ import{r as registerInstance,c as createEvent,h,H as Host}from"./index-81f1a268.js";var curaButtonSelectCss=':host{--border-radius:4px;display:inline-block;vertical-align:middle}:host button,:host a{outline:none;-webkit-box-shadow:none;box-shadow:none;-webkit-box-sizing:border-box;box-sizing:border-box;display:-ms-flexbox;display:flex;width:100%;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;text-decoration:none !important;font-size:var(--font-size);cursor:pointer;-webkit-transition:background-color 0.07s linear, border-color 0.07s linear, -webkit-box-shadow 0.07s linear;transition:background-color 0.07s linear, border-color 0.07s linear, -webkit-box-shadow 0.07s linear;transition:background-color 0.07s linear, box-shadow 0.07s linear, border-color 0.07s linear;transition:background-color 0.07s linear, box-shadow 0.07s linear, border-color 0.07s linear, -webkit-box-shadow 0.07s linear;border-radius:var(--border-radius);background-color:var(--neutral-purewhite);border:none;-webkit-box-shadow:inset 0px 0px 0px 2px var(--primary-base);box-shadow:inset 0px 0px 0px 2px var(--primary-base);padding:calc(var(--base-spacing) * 3.5px) calc(var(--base-spacing) * 4px);min-height:calc(var(--base-spacing) * 13px);min-width:calc(var(--base-spacing) * 13px)}:host button:not(.disabled):hover,:host a:not(.disabled):hover{background-color:var(--color-lighter);-webkit-box-shadow:inset 0px 0px 0px 2px var(--color-base);box-shadow:inset 0px 0px 0px 2px var(--color-base)}:host button:not(.disabled):hover .label,:host a:not(.disabled):hover .label{color:var(--neutral-purewhite-black)}:host button:focus,:host a:focus{-webkit-box-shadow:inset 0px 0px 0px 2px var(--info-base) !important;box-shadow:inset 0px 0px 0px 2px var(--info-base) !important}:host button.medium,:host a.medium{padding:calc(var(--base-spacing) * 2.75px) calc(var(--base-spacing) * 4px);min-height:calc(var(--base-spacing) * 11px);min-width:calc(var(--base-spacing) * 11px)}:host button.small,:host a.small{padding:calc(var(--base-spacing) * 1.5px) calc(var(--base-spacing) * 3px);min-height:calc(var(--base-spacing) * 8px);min-width:calc(var(--base-spacing) * 8px)}:host button .label,:host a .label{-ms-flex:1;flex:1;font-family:var(--font-family);font-weight:var(--font-weight-medium);font-size:1.43em;line-height:1.2em;text-align:var(--text-align, "left");color:var(--primary-base)}:host button.medium .label,:host a.medium .label{font-size:1.14em}:host button.small .label,:host a.small .label{font-size:1em}:host button .button-container,:host a .button-container{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;opacity:1;-webkit-transition:opacity 0.2s linear;transition:opacity 0.2s linear;gap:5px}:host button.icon-right .button-container,:host a.icon-right .button-container{-ms-flex-direction:row-reverse;flex-direction:row-reverse}:host button.selected,:host a.selected{cursor:pointer;background-color:var(--color-base);-webkit-box-shadow:inset 0px 0px 0px 2px var(--color-darker);box-shadow:inset 0px 0px 0px 2px var(--color-darker)}:host button.selected .label,:host a.selected .label{color:var(--neutral-purewhite-black)}:host button.disabled,:host a.disabled{cursor:not-allowed;background-color:var(--neutral-white-primary-darker);-webkit-box-shadow:inset 0px 0px 0px 2px var(--neutral-medium-primary-base);box-shadow:inset 0px 0px 0px 2px var(--neutral-medium-primary-base)}:host button.disabled .label,:host a.disabled .label{color:var(--neutral-medium-primary-base)}';var CuraButtonOutline=function(){function e(e){registerInstance(this,e);this.onclick=createEvent(this,"onclick",7);this.theme=window.CuraAPI.theme;this.size="medium";this.disabled=false;this.selected=false;this.iconPosition="right";this.color="accent";this.background="light";this.fontcolor="dark";this.hovered=false;this.styles={}}e.prototype.setColors=function(){var e=this;var t=[{name:"--color-base",theme:"".concat(this.color,"-base")},{name:"--color-darker",theme:"".concat(this.color,"-darker")},{name:"--color-lighter",theme:"".concat(this.color,"-lighter")},{name:"--neutral-purewhite-black",theme:this.fontcolor==="light"?"neutral-purewhite":"neutral-black"},{name:"--neutral-white-primary-darker",theme:this.background==="light"?"neutral-white":"primary-darker"},{name:"--neutral-medium-primary-base",theme:this.background==="light"?"neutral-medium":"primary-base"}];t.forEach((function(t){var o;e.styles=Object.assign(Object.assign({},e.styles),(o={},o[t.name]=e.theme.colors.getColor(t.theme),o))}))};e.prototype.setStyles=function(){this.weights=this.theme.fonts.getWeights();this.styles["--base-spacing"]=this.theme.spacing.getSpacing();this.styles["--font-size"]=this.theme.fonts.getSize();this.styles["--font-family"]=this.theme.fonts.getFamily();this.styles["--font-weight-medium"]=this.weights.medium;this.styles["--neutral-purewhite"]=this.theme.colors.getColor("neutral-purewhite");this.styles["--neutral-black"]=this.theme.colors.getColor("neutral-black");this.styles["--primary-base"]=this.theme.colors.getColor("primary-base");this.styles["--info-base"]=this.theme.colors.getColor("info-base")};e.prototype.connectedCallback=function(){this.setStyles();this.setColors()};e.prototype.handleMouseEnter=function(){if(this.disabled)return;this.hovered=true};e.prototype.handleMouseLeave=function(){this.hovered=false};e.prototype.getIcon=function(){if(!this.selected)return"";var e=this.size==="small"?16:this.size==="medium"?20:24;var t=this.hovered?"closeCircle":"checkCircle";var o=this.disabled?this.background==="light"?"neutral-medium":"primary-base":this.selected&&this.fontcolor==="dark"?"neutral-black":"neutral-purewhite";return h("cura-icon",{class:"button-icon",name:t,size:e,color:o})};e.prototype.handleClick=function(e){if(this.disabled)e.preventDefault();this.selected=!this.selected;this.onclick.emit({selected:this.selected})};e.prototype.getClasses=function(){var e={};e["".concat(this.size.toLowerCase())]=true;e["icon-".concat(this.iconPosition.toLowerCase())]=true;e["disabled"]=this.disabled;e["selected"]=this.selected;return e};e.prototype.render=function(){var e=this;return h(Host,null,h("button",{class:this.getClasses(),style:this.styles,disabled:this.disabled,onClick:function(t){return e.handleClick(t)},onMouseEnter:function(){return e.handleMouseEnter()},onMouseLeave:function(){return e.handleMouseLeave()}},h("div",{class:"button-container"},this.getIcon(),h("span",{class:"label"},h("slot",null)))))};Object.defineProperty(e,"watchers",{get:function(){return{background:["setColors","getIcon"],color:["setColors"],fontcolor:["setColors","getIcon"]}},enumerable:false,configurable:true});return e}();CuraButtonOutline.style=curaButtonSelectCss;export{CuraButtonOutline as cura_button_select};
2
+ //# sourceMappingURL=cura-button-select.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["curaButtonSelectCss","CuraButtonOutline","this","theme","window","CuraAPI","prototype","setColors","_this","colors","name","concat","color","fontcolor","background","forEach","styles","Object","assign","_a","getColor","setStyles","weights","fonts","getWeights","spacing","getSpacing","getSize","getFamily","medium","connectedCallback","handleMouseEnter","disabled","hovered","handleMouseLeave","getIcon","selected","iconSize","size","iconName","h","class","handleClick","e","preventDefault","onclick","emit","getClasses","classes","toLowerCase","iconPosition","render","Host","style","onClick","onMouseEnter","onMouseLeave"],"sources":["src/components/buttons/cura-button-select/cura-button-select.scss?tag=cura-button-select&encapsulation=shadow","src/components/buttons/cura-button-select/cura-button-select.tsx"],"sourcesContent":["@import \"../../../scss/mixins/buttons.scss\";\n\n:host {\n @include button-host();\n\n button, a {\n @include button-element() {\n background-color: var(--neutral-purewhite);\n border: none;\n box-shadow: inset 0px 0px 0px 2px var(--primary-base);\n\n &:not(.disabled):hover {\n background-color: var(--color-lighter);\n box-shadow: inset 0px 0px 0px 2px var(--color-base);\n .label {\n color: var(--neutral-purewhite-black);\n }\n }\n\n &:focus {\n box-shadow: inset 0px 0px 0px 2px var(--info-base) !important;\n }\n }\n\n @include button-sizes();\n\n @include button-label() {\n color: var(--primary-base);\n }\n\n // Children Elements\n @include button-container() {\n gap: 5px;\n }\n\n @mixin button-icon() {\n margin: 0;\n }\n\n // selected state\n @include button-selected() {\n background-color: var(--color-base);\n box-shadow: inset 0px 0px 0px 2px var(--color-darker);\n .label {\n color: var(--neutral-purewhite-black);\n }\n }\n\n // Disabled state\n @include button-disabled() {\n background-color: var(--neutral-white-primary-darker);\n box-shadow: inset 0px 0px 0px 2px var(--neutral-medium-primary-base);\n .label {\n color: var(--neutral-medium-primary-base);\n }\n }\n\n }\n}\n","import { Component, Host, h, Prop, Watch, State, Event, EventEmitter } from '@stencil/core';\n\n@Component({\n tag: 'cura-button-select',\n styleUrl: 'cura-button-select.scss',\n shadow: true,\n})\n\nexport class CuraButtonOutline {\n /**\n * Button size: small | medium (default) | large = medium\n */\n @Prop({ reflect: true }) size: 'small' | 'medium' | 'large' = 'medium';\n /**\n * Disabled state. Boolean.\n */\n @Prop({ reflect: true }) disabled = false;\n /**\n * selected state. Boolean.\n */\n @Prop({ reflect: true }) selected = false;\n /**\n * Icon position: left (default) | right.\n */\n @Prop({ reflect: true }) iconPosition: 'left' | 'right' = 'right';\n /**\n * Color base from color scheme. Default: accent.\n */\n @Prop() color = 'accent';\n /**\n * Set the font color to dark or light.\n */\n @Prop() background: 'dark' | 'light' = 'light';\n /**\n * fontcolor theme of the checkbox.\n * Can be 'dark' or 'light'.\n */\n @Prop() fontcolor: 'dark' | 'light' = 'dark';\n /**\n * hovered state. Boolean.\n */\n @State() hovered = false;\n\n @State() styles = {};\n\n @Event({ eventName: \"onclick\" }) onclick: EventEmitter<{ selected: boolean; }>;\n\n theme = window.CuraAPI.theme\n\n weights;\n\n @Watch('background')\n @Watch('color')\n @Watch('fontcolor')\n setColors() {\n const colors = [\n { name: '--color-base', theme: `${this.color}-base` },\n { name: '--color-darker', theme: `${this.color}-darker` },\n { name: '--color-lighter', theme: `${this.color}-lighter` },\n { name: '--neutral-purewhite-black', theme: this.fontcolor === 'light' ? 'neutral-purewhite' : 'neutral-black' },\n { name: '--neutral-white-primary-darker', theme: this.background === 'light' ? 'neutral-white' : 'primary-darker' },\n { name: '--neutral-medium-primary-base', theme: this.background === 'light' ? 'neutral-medium' : 'primary-base' },\n ];\n\n colors.forEach(color => {\n this.styles = {\n ...this.styles,\n [color.name]: this.theme.colors.getColor(color.theme)\n };\n });\n }\n\n setStyles() {\n this.weights = this.theme.fonts.getWeights();\n this.styles['--base-spacing'] = this.theme.spacing.getSpacing();\n this.styles['--font-size'] = this.theme.fonts.getSize();\n this.styles['--font-family'] = this.theme.fonts.getFamily();\n this.styles['--font-weight-medium'] = this.weights.medium;\n this.styles['--neutral-purewhite'] = this.theme.colors.getColor(\"neutral-purewhite\");\n this.styles['--neutral-black'] = this.theme.colors.getColor(\"neutral-black\");\n this.styles['--primary-base'] = this.theme.colors.getColor(\"primary-base\");\n this.styles['--info-base'] = this.theme.colors.getColor(\"info-base\");\n }\n\n connectedCallback() {\n this.setStyles()\n this.setColors();\n }\n\n handleMouseEnter() {\n if (this.disabled) return;\n this.hovered = true;\n }\n\n handleMouseLeave() {\n this.hovered = false;\n }\n\n @Watch('background')\n @Watch('fontcolor')\n getIcon() {\n if (!this.selected) return '';\n\n const iconSize = this.size === 'small' ? 16 : this.size === 'medium' ? 20 : 24;\n const iconName = this.hovered ? 'closeCircle' : 'checkCircle';\n const fontcolor =\n this.disabled\n ? (this.background === 'light' ? 'neutral-medium' : 'primary-base')\n : this.selected && this.fontcolor === \"dark\" ? 'neutral-black' : \"neutral-purewhite\";\n\n return <cura-icon class=\"button-icon\" name={iconName} size={iconSize} color={fontcolor}></cura-icon>;\n }\n\n\n handleClick(e: Event) {\n if (this.disabled) e.preventDefault();\n this.selected = !this.selected;\n this.onclick.emit({ selected: this.selected });\n }\n\n\n getClasses() {\n const classes = {};\n classes[`${this.size.toLowerCase()}`] = true;\n classes[`icon-${this.iconPosition.toLowerCase()}`] = true;\n classes['disabled'] = this.disabled;\n classes['selected'] = this.selected;\n return classes;\n }\n\n render() {\n return (\n <Host>\n <button class={this.getClasses()}\n style={this.styles}\n disabled={this.disabled}\n onClick={(e) => this.handleClick(e)}\n onMouseEnter={() => this.handleMouseEnter()}\n onMouseLeave={() => this.handleMouseLeave()}>\n <div class=\"button-container\">\n {this.getIcon()}\n <span class=\"label\"><slot></slot></span>\n </div>\n </button>\n </Host>\n );\n }\n\n}\n"],"mappings":"oFAAA,IAAMA,oBAAsB,w1G,ICQfC,kBAAiB,W,kFAuC5BC,KAAAC,MAAQC,OAAOC,QAAQF,M,UAnCuC,S,cAI1B,M,cAIA,M,kBAIsB,Q,WAI1C,S,gBAIuB,Q,eAKD,O,aAInB,M,YAED,E,CAWlBF,EAAAK,UAAAC,UAAA,eAAAC,EAAAN,KACE,IAAMO,EAAS,CACb,CAAEC,KAAM,eAAgBP,MAAO,GAAAQ,OAAGT,KAAKU,MAAK,UAC5C,CAAEF,KAAM,iBAAkBP,MAAO,GAAAQ,OAAGT,KAAKU,MAAK,YAC9C,CAAEF,KAAM,kBAAmBP,MAAO,GAAAQ,OAAGT,KAAKU,MAAK,aAC/C,CAAEF,KAAM,4BAA6BP,MAAOD,KAAKW,YAAc,QAAU,oBAAsB,iBAC/F,CAAEH,KAAM,iCAAkCP,MAAOD,KAAKY,aAAe,QAAU,gBAAkB,kBACjG,CAAEJ,KAAM,gCAAiCP,MAAOD,KAAKY,aAAe,QAAU,iBAAmB,iBAGnGL,EAAOM,SAAQ,SAAAH,G,MACbJ,EAAKQ,OAAMC,OAAAC,OAAAD,OAAAC,OAAA,GACNV,EAAKQ,SAAMG,EAAA,GACdA,EAACP,EAAMF,MAAOF,EAAKL,MAAMM,OAAOW,SAASR,EAAMT,OAAMgB,G,KAK3DlB,EAAAK,UAAAe,UAAA,WACEnB,KAAKoB,QAAUpB,KAAKC,MAAMoB,MAAMC,aAChCtB,KAAKc,OAAO,kBAAoBd,KAAKC,MAAMsB,QAAQC,aACnDxB,KAAKc,OAAO,eAAiBd,KAAKC,MAAMoB,MAAMI,UAC9CzB,KAAKc,OAAO,iBAAmBd,KAAKC,MAAMoB,MAAMK,YAChD1B,KAAKc,OAAO,wBAA0Bd,KAAKoB,QAAQO,OACnD3B,KAAKc,OAAO,uBAAyBd,KAAKC,MAAMM,OAAOW,SAAS,qBAChElB,KAAKc,OAAO,mBAAqBd,KAAKC,MAAMM,OAAOW,SAAS,iBAC5DlB,KAAKc,OAAO,kBAAoBd,KAAKC,MAAMM,OAAOW,SAAS,gBAC3DlB,KAAKc,OAAO,eAAiBd,KAAKC,MAAMM,OAAOW,SAAS,Y,EAG1DnB,EAAAK,UAAAwB,kBAAA,WACE5B,KAAKmB,YACLnB,KAAKK,W,EAGPN,EAAAK,UAAAyB,iBAAA,WACE,GAAI7B,KAAK8B,SAAU,OACnB9B,KAAK+B,QAAU,I,EAGjBhC,EAAAK,UAAA4B,iBAAA,WACEhC,KAAK+B,QAAU,K,EAKjBhC,EAAAK,UAAA6B,QAAA,WACE,IAAKjC,KAAKkC,SAAU,MAAO,GAE3B,IAAMC,EAAWnC,KAAKoC,OAAS,QAAU,GAAKpC,KAAKoC,OAAS,SAAW,GAAK,GAC5E,IAAMC,EAAWrC,KAAK+B,QAAU,cAAgB,cAChD,IAAMpB,EACJX,KAAK8B,SACA9B,KAAKY,aAAe,QAAU,iBAAmB,eAClDZ,KAAKkC,UAAYlC,KAAKW,YAAc,OAAS,gBAAkB,oBAErE,OAAO2B,EAAA,aAAWC,MAAM,cAAc/B,KAAM6B,EAAUD,KAAMD,EAAUzB,MAAOC,G,EAI/EZ,EAAAK,UAAAoC,YAAA,SAAYC,GACV,GAAIzC,KAAK8B,SAAUW,EAAEC,iBACrB1C,KAAKkC,UAAYlC,KAAKkC,SACtBlC,KAAK2C,QAAQC,KAAK,CAAEV,SAAUlC,KAAKkC,U,EAIrCnC,EAAAK,UAAAyC,WAAA,WACE,IAAMC,EAAU,GAChBA,EAAQ,GAAArC,OAAGT,KAAKoC,KAAKW,gBAAmB,KACxCD,EAAQ,QAAArC,OAAQT,KAAKgD,aAAaD,gBAAmB,KACrDD,EAAQ,YAAc9C,KAAK8B,SAC3BgB,EAAQ,YAAc9C,KAAKkC,SAC3B,OAAOY,C,EAGT/C,EAAAK,UAAA6C,OAAA,eAAA3C,EAAAN,KACE,OACEsC,EAACY,KAAI,KACHZ,EAAA,UAAQC,MAAOvC,KAAK6C,aAClBM,MAAOnD,KAAKc,OACZgB,SAAU9B,KAAK8B,SACfsB,QAAS,SAACX,GAAM,OAAAnC,EAAKkC,YAAYC,EAAjB,EAChBY,aAAc,WAAM,OAAA/C,EAAKuB,kBAAL,EACpByB,aAAc,WAAM,OAAAhD,EAAK0B,kBAAL,GACpBM,EAAA,OAAKC,MAAM,oBACRvC,KAAKiC,UACNK,EAAA,QAAMC,MAAM,SAAQD,EAAA,gB,qMArIF,G"}
@@ -1,2 +1,2 @@
1
- import{r as registerInstance,h,H as Host}from"./index-d99da69e.js";var curaButtonTransparentCss=':host{--border-radius:4px;display:inline-block;vertical-align:middle}:host button,:host a{outline:none;-webkit-box-shadow:none;box-shadow:none;-webkit-box-sizing:border-box;box-sizing:border-box;display:-ms-flexbox;display:flex;width:100%;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;text-decoration:none !important;font-size:var(--font-size);cursor:pointer;-webkit-transition:background-color 0.07s linear, border-color 0.07s linear, -webkit-box-shadow 0.07s linear;transition:background-color 0.07s linear, border-color 0.07s linear, -webkit-box-shadow 0.07s linear;transition:background-color 0.07s linear, box-shadow 0.07s linear, border-color 0.07s linear;transition:background-color 0.07s linear, box-shadow 0.07s linear, border-color 0.07s linear, -webkit-box-shadow 0.07s linear;border-radius:var(--border-radius);background-color:transparent;border-width:0px;border-color:transparent;padding:calc(var(--base-spacing) * 3.5px) calc(var(--base-spacing) * 4px);min-height:calc(var(--base-spacing) * 13px);min-width:calc(var(--base-spacing) * 13px)}:host button:not(.disabled):not(.isLoading):hover .label,:host a:not(.disabled):not(.isLoading):hover .label{color:var(--color-light)}:host button:not(.disabled):not(.isLoading):hover cura-icon,:host a:not(.disabled):not(.isLoading):hover cura-icon{--color:var(--color-light) !important}:host button:not(.disabled):not(.inverted):not(.isLoading):active .label,:host a:not(.disabled):not(.inverted):not(.isLoading):active .label{color:var(--color-dark)}:host button:not(.disabled):not(.inverted):not(.isLoading):active cura-icon,:host a:not(.disabled):not(.inverted):not(.isLoading):active cura-icon{--color:var(--color-dark) !important}:host button.medium,:host a.medium{padding:calc(var(--base-spacing) * 2.75px) calc(var(--base-spacing) * 4px);min-height:calc(var(--base-spacing) * 11px);min-width:calc(var(--base-spacing) * 11px)}:host button.small,:host a.small{padding:calc(var(--base-spacing) * 1.5px) calc(var(--base-spacing) * 3px);min-height:calc(var(--base-spacing) * 8px);min-width:calc(var(--base-spacing) * 8px)}:host button .button-container,:host a .button-container{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;opacity:1;-webkit-transition:opacity 0.2s linear;transition:opacity 0.2s linear}:host button.icon-right .button-container,:host a.icon-right .button-container{-ms-flex-direction:row-reverse;flex-direction:row-reverse}:host button .label,:host a .label{-ms-flex:1;flex:1;font-family:var(--font-family);font-weight:var(--font-weight-medium);font-size:1.43em;line-height:1.2em;text-align:var(--text-align, "left");color:var(--color-base)}:host button .label.inverted,:host a .label.inverted{color:var(--neutral-white)}:host button.medium .label,:host a.medium .label{font-size:1.14em}:host button.small .label,:host a.small .label{font-size:1em}:host button.icon-left cura-icon,:host a.icon-left cura-icon{margin-right:calc(var(--base-spacing) * 3px)}:host button.icon-right cura-icon,:host a.icon-right cura-icon{margin-left:calc(var(--base-spacing) * 3px)}:host button.medium.icon-left cura-icon,:host a.medium.icon-left cura-icon{margin-right:calc(var(--base-spacing) * 2.7px)}:host button.medium.icon-right cura-icon,:host a.medium.icon-right cura-icon{margin-left:calc(var(--base-spacing) * 2.7px)}:host button.small.icon-left cura-icon,:host a.small.icon-left cura-icon{margin-right:calc(var(--base-spacing) * 2.5px)}:host button.small.icon-right cura-icon,:host a.small.icon-right cura-icon{margin-left:calc(var(--base-spacing) * 2.5px)}:host button.disabled,:host a.disabled{cursor:not-allowed;border-color:var(--neutral-base)}:host button.disabled .label,:host button.disabled .label.inverted,:host a.disabled .label,:host a.disabled .label.inverted{color:var(--neutral-dark)}:host button.disabled.inverted,:host a.disabled.inverted{opacity:0.6}:host button.disabled.inverted .label,:host button.disabled.inverted .label.inverted,:host a.disabled.inverted .label,:host a.disabled.inverted .label.inverted{color:var(--neutral-white)}:host button.disabled.inverted cura-icon,:host a.disabled.inverted cura-icon{--color:var(--neutral-white) !important}:host button.disabled.inverted cura-loader-circle,:host a.disabled.inverted cura-loader-circle{--color:var(--neutral-white) !important}:host button.icon-only,:host a.icon-only{padding:calc(var(--base-spacing) * 3.5px)}:host button.icon-only .label,:host a.icon-only .label{display:none}:host button.icon-only cura-icon,:host a.icon-only cura-icon{margin-left:0 !important;margin-right:0 !important}:host button.icon-only.medium,:host a.icon-only.medium{padding:calc(var(--base-spacing) * 2.75px)}:host button.icon-only.small,:host a.icon-only.small{padding:calc(var(--base-spacing) * 1.5px)}:host button.inverted:not(.isLoading):not(.disabled):hover .label,:host a.inverted:not(.isLoading):not(.disabled):hover .label{color:var(--color-lighter)}:host button.inverted:not(.isLoading):not(.disabled):hover cura-icon,:host a.inverted:not(.isLoading):not(.disabled):hover cura-icon{--color:var(--color-lighter) !important}:host button.inverted:not(.isLoading):not(.disabled):active .label,:host a.inverted:not(.isLoading):not(.disabled):active .label{color:var(--color-light)}:host button.inverted:not(.isLoading):not(.disabled):active cura-icon,:host a.inverted:not(.isLoading):not(.disabled):active cura-icon{--color:var(--color-light) !important}:host button cura-loader-circle,:host a cura-loader-circle{position:absolute;display:none}:host button.isLoading,:host a.isLoading{cursor:wait}:host button.isLoading .button-container,:host a.isLoading .button-container{opacity:0.3}:host button.isLoading.icon-only .button-container,:host a.isLoading.icon-only .button-container{opacity:0}:host button.isLoading cura-loader-circle,:host a.isLoading cura-loader-circle{display:block}';var CuraButtonTransparent=function(){function t(t){registerInstance(this,t);this.size="large";this.disabled=false;this.isLoading=false;this.iconName=undefined;this.iconset="default";this.iconPosition="left";this.iconOnly=false;this.href=undefined;this.target="_self";this.color="accent";this.fontColor="dark";this.textAlign="left";this.styles={}}t.prototype.handleChangeColor=function(){this.setColors()};t.prototype.connectedCallback=function(){this.weights=window.CuraAPI.theme.fonts.getWeights();this.styles["--base-spacing"]=window.CuraAPI.theme.spacing.getSpacing();this.styles["--neutral-white"]=window.CuraAPI.theme.colors.getColor("neutral-white");this.styles["--neutral-base"]=window.CuraAPI.theme.colors.getColor("neutral-base");this.styles["--neutral-dark"]=window.CuraAPI.theme.colors.getColor("neutral-dark");this.styles["--font-size"]=window.CuraAPI.theme.fonts.getSize();this.styles["--font-family"]=window.CuraAPI.theme.fonts.getFamily();this.styles["--font-weight-medium"]=this.weights.medium;this.styles["--text-align"]=this.textAlign;this.setColors()};t.prototype.getClasses=function(){var t={};t["".concat(this.size.toLowerCase())]=true;t["icon-".concat(this.iconPosition.toLowerCase())]=true;t["icon-only"]=this.iconOnly;t["inverted"]=this.fontColor==="light";t["disabled"]=this.disabled;t["isLoading"]=this.isLoading;return t};t.prototype.setColors=function(){this.styles=Object.assign(Object.assign({},this.styles),{"--color-lighter":window.CuraAPI.theme.colors.getColor("".concat(this.color,"-lighter")),"--color-light":window.CuraAPI.theme.colors.getColor("".concat(this.color,"-light")),"--color-base":window.CuraAPI.theme.colors.getColor("".concat(this.color,"-base")),"--color-dark":window.CuraAPI.theme.colors.getColor("".concat(this.color,"-dark"))})};t.prototype.getIcon=function(){if(!this.iconName)return"";var t=this.size==="small"?16:this.size==="medium"?20:24;var o=this.getSymbolColor();return h("cura-icon",{name:this.iconName,iconset:this.iconset,size:t,color:o})};t.prototype.getSymbolColor=function(){return this.disabled?"neutral-dark":this.fontColor==="light"?"neutral-white":"".concat(this.color,"-base")};t.prototype.handleClick=function(t){if(this.disabled||this.isLoading)t.preventDefault()};t.prototype.render=function(){var t=this;return h(Host,null,this.href?h("a",{href:this.disabled?"":this.href,target:this.target,class:this.getClasses(),style:this.styles,onClick:function(o){return t.handleClick(o)}},h("span",{class:"button-container"},this.getIcon(),h("span",{class:{label:true,inverted:this.fontColor==="light"}},h("slot",null))),h("cura-loader-circle",{size:this.size,color:this.getSymbolColor()})):h("button",{class:this.getClasses(),style:this.styles,disabled:this.disabled||null,onClick:function(o){return t.handleClick(o)}},h("span",{class:"button-container"},this.getIcon(),h("span",{class:{label:true,inverted:this.fontColor==="light"}},h("slot",null))),h("cura-loader-circle",{size:this.size,color:this.getSymbolColor()})))};Object.defineProperty(t,"watchers",{get:function(){return{color:["handleChangeColor"]}},enumerable:false,configurable:true});return t}();CuraButtonTransparent.style=curaButtonTransparentCss;export{CuraButtonTransparent as cura_button_transparent};
1
+ import{r as registerInstance,h,H as Host}from"./index-81f1a268.js";var curaButtonTransparentCss=':host{--border-radius:4px;display:inline-block;vertical-align:middle}:host button,:host a{outline:none;-webkit-box-shadow:none;box-shadow:none;-webkit-box-sizing:border-box;box-sizing:border-box;display:-ms-flexbox;display:flex;width:100%;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;text-decoration:none !important;font-size:var(--font-size);cursor:pointer;-webkit-transition:background-color 0.07s linear, border-color 0.07s linear, -webkit-box-shadow 0.07s linear;transition:background-color 0.07s linear, border-color 0.07s linear, -webkit-box-shadow 0.07s linear;transition:background-color 0.07s linear, box-shadow 0.07s linear, border-color 0.07s linear;transition:background-color 0.07s linear, box-shadow 0.07s linear, border-color 0.07s linear, -webkit-box-shadow 0.07s linear;border-radius:var(--border-radius);background-color:transparent;border-width:0px;border-color:transparent;padding:calc(var(--base-spacing) * 3.5px) calc(var(--base-spacing) * 4px);min-height:calc(var(--base-spacing) * 13px);min-width:calc(var(--base-spacing) * 13px)}:host button:not(.disabled):not(.isLoading):hover .label,:host a:not(.disabled):not(.isLoading):hover .label{color:var(--color-light)}:host button:not(.disabled):not(.isLoading):hover cura-icon,:host a:not(.disabled):not(.isLoading):hover cura-icon{--color:var(--color-light) !important}:host button:not(.disabled):not(.inverted):not(.isLoading):active .label,:host a:not(.disabled):not(.inverted):not(.isLoading):active .label{color:var(--color-dark)}:host button:not(.disabled):not(.inverted):not(.isLoading):active cura-icon,:host a:not(.disabled):not(.inverted):not(.isLoading):active cura-icon{--color:var(--color-dark) !important}:host button.medium,:host a.medium{padding:calc(var(--base-spacing) * 2.75px) calc(var(--base-spacing) * 4px);min-height:calc(var(--base-spacing) * 11px);min-width:calc(var(--base-spacing) * 11px)}:host button.small,:host a.small{padding:calc(var(--base-spacing) * 1.5px) calc(var(--base-spacing) * 3px);min-height:calc(var(--base-spacing) * 8px);min-width:calc(var(--base-spacing) * 8px)}:host button .button-container,:host a .button-container{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;opacity:1;-webkit-transition:opacity 0.2s linear;transition:opacity 0.2s linear}:host button.icon-right .button-container,:host a.icon-right .button-container{-ms-flex-direction:row-reverse;flex-direction:row-reverse}:host button .label,:host a .label{-ms-flex:1;flex:1;font-family:var(--font-family);font-weight:var(--font-weight-medium);font-size:1.43em;line-height:1.2em;text-align:var(--text-align, "left");color:var(--color-base)}:host button .label.inverted,:host a .label.inverted{color:var(--neutral-white)}:host button.medium .label,:host a.medium .label{font-size:1.14em}:host button.small .label,:host a.small .label{font-size:1em}:host button.icon-left cura-icon,:host a.icon-left cura-icon{margin-right:calc(var(--base-spacing) * 3px)}:host button.icon-right cura-icon,:host a.icon-right cura-icon{margin-left:calc(var(--base-spacing) * 3px)}:host button.medium.icon-left cura-icon,:host a.medium.icon-left cura-icon{margin-right:calc(var(--base-spacing) * 2.7px)}:host button.medium.icon-right cura-icon,:host a.medium.icon-right cura-icon{margin-left:calc(var(--base-spacing) * 2.7px)}:host button.small.icon-left cura-icon,:host a.small.icon-left cura-icon{margin-right:calc(var(--base-spacing) * 2.5px)}:host button.small.icon-right cura-icon,:host a.small.icon-right cura-icon{margin-left:calc(var(--base-spacing) * 2.5px)}:host button.disabled,:host a.disabled{cursor:not-allowed;border-color:var(--neutral-base)}:host button.disabled .label,:host button.disabled .label.inverted,:host a.disabled .label,:host a.disabled .label.inverted{color:var(--neutral-dark)}:host button.disabled.inverted,:host a.disabled.inverted{opacity:0.6}:host button.disabled.inverted .label,:host button.disabled.inverted .label.inverted,:host a.disabled.inverted .label,:host a.disabled.inverted .label.inverted{color:var(--neutral-white)}:host button.disabled.inverted cura-icon,:host a.disabled.inverted cura-icon{--color:var(--neutral-white) !important}:host button.disabled.inverted cura-loader-circle,:host a.disabled.inverted cura-loader-circle{--color:var(--neutral-white) !important}:host button.icon-only,:host a.icon-only{padding:calc(var(--base-spacing) * 3.5px)}:host button.icon-only .label,:host a.icon-only .label{display:none}:host button.icon-only cura-icon,:host a.icon-only cura-icon{margin-left:0 !important;margin-right:0 !important}:host button.icon-only.medium,:host a.icon-only.medium{padding:calc(var(--base-spacing) * 2.75px)}:host button.icon-only.small,:host a.icon-only.small{padding:calc(var(--base-spacing) * 1.5px)}:host button.inverted:not(.isLoading):not(.disabled):hover .label,:host a.inverted:not(.isLoading):not(.disabled):hover .label{color:var(--color-lighter)}:host button.inverted:not(.isLoading):not(.disabled):hover cura-icon,:host a.inverted:not(.isLoading):not(.disabled):hover cura-icon{--color:var(--color-lighter) !important}:host button.inverted:not(.isLoading):not(.disabled):active .label,:host a.inverted:not(.isLoading):not(.disabled):active .label{color:var(--color-light)}:host button.inverted:not(.isLoading):not(.disabled):active cura-icon,:host a.inverted:not(.isLoading):not(.disabled):active cura-icon{--color:var(--color-light) !important}:host button cura-loader-circle,:host a cura-loader-circle{position:absolute;display:none}:host button.isLoading,:host a.isLoading{cursor:wait}:host button.isLoading .button-container,:host a.isLoading .button-container{opacity:0.3}:host button.isLoading.icon-only .button-container,:host a.isLoading.icon-only .button-container{opacity:0}:host button.isLoading cura-loader-circle,:host a.isLoading cura-loader-circle{display:block}';var CuraButtonTransparent=function(){function t(t){registerInstance(this,t);this.size="large";this.disabled=false;this.isLoading=false;this.iconName=undefined;this.iconset="default";this.iconPosition="left";this.iconOnly=false;this.href=undefined;this.target="_self";this.color="accent";this.fontColor="dark";this.textAlign="left";this.styles={}}t.prototype.handleChangeColor=function(){this.setColors()};t.prototype.connectedCallback=function(){this.weights=window.CuraAPI.theme.fonts.getWeights();this.styles["--base-spacing"]=window.CuraAPI.theme.spacing.getSpacing();this.styles["--neutral-white"]=window.CuraAPI.theme.colors.getColor("neutral-white");this.styles["--neutral-base"]=window.CuraAPI.theme.colors.getColor("neutral-base");this.styles["--neutral-dark"]=window.CuraAPI.theme.colors.getColor("neutral-dark");this.styles["--font-size"]=window.CuraAPI.theme.fonts.getSize();this.styles["--font-family"]=window.CuraAPI.theme.fonts.getFamily();this.styles["--font-weight-medium"]=this.weights.medium;this.styles["--text-align"]=this.textAlign;this.setColors()};t.prototype.getClasses=function(){var t={};t["".concat(this.size.toLowerCase())]=true;t["icon-".concat(this.iconPosition.toLowerCase())]=true;t["icon-only"]=this.iconOnly;t["inverted"]=this.fontColor==="light";t["disabled"]=this.disabled;t["isLoading"]=this.isLoading;return t};t.prototype.setColors=function(){this.styles=Object.assign(Object.assign({},this.styles),{"--color-lighter":window.CuraAPI.theme.colors.getColor("".concat(this.color,"-lighter")),"--color-light":window.CuraAPI.theme.colors.getColor("".concat(this.color,"-light")),"--color-base":window.CuraAPI.theme.colors.getColor("".concat(this.color,"-base")),"--color-dark":window.CuraAPI.theme.colors.getColor("".concat(this.color,"-dark"))})};t.prototype.getIcon=function(){if(!this.iconName)return"";var t=this.size==="small"?16:this.size==="medium"?20:24;var o=this.getSymbolColor();return h("cura-icon",{name:this.iconName,iconset:this.iconset,size:t,color:o})};t.prototype.getSymbolColor=function(){return this.disabled?"neutral-dark":this.fontColor==="light"?"neutral-white":"".concat(this.color,"-base")};t.prototype.handleClick=function(t){if(this.disabled||this.isLoading)t.preventDefault()};t.prototype.render=function(){var t=this;return h(Host,null,this.href?h("a",{href:this.disabled?"":this.href,target:this.target,class:this.getClasses(),style:this.styles,onClick:function(o){return t.handleClick(o)}},h("span",{class:"button-container"},this.getIcon(),h("span",{class:{label:true,inverted:this.fontColor==="light"}},h("slot",null))),h("cura-loader-circle",{size:this.size,color:this.getSymbolColor()})):h("button",{class:this.getClasses(),style:this.styles,disabled:this.disabled||null,onClick:function(o){return t.handleClick(o)}},h("span",{class:"button-container"},this.getIcon(),h("span",{class:{label:true,inverted:this.fontColor==="light"}},h("slot",null))),h("cura-loader-circle",{size:this.size,color:this.getSymbolColor()})))};Object.defineProperty(t,"watchers",{get:function(){return{color:["handleChangeColor"]}},enumerable:false,configurable:true});return t}();CuraButtonTransparent.style=curaButtonTransparentCss;export{CuraButtonTransparent as cura_button_transparent};
2
2
  //# sourceMappingURL=cura-button-transparent.entry.js.map
@@ -0,0 +1,2 @@
1
+ import{r as registerInstance,c as createEvent,h,H as Host,g as getElement}from"./index-81f1a268.js";import{f as formsSizes}from"./cura-forms.definitions-0f774253.js";var curaCheckboxCss='@charset "UTF-8";:host{display:block;width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;-webkit-box-sizing:border-box;box-sizing:border-box}.container{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-direction:row-reverse;flex-direction:row-reverse;gap:var(--gap)}.position.container{-ms-flex-direction:row;flex-direction:row}.position .label-wrapper{-ms-flex-pack:end;justify-content:end}.position .message{text-align:right}.position .label{-ms-flex-order:1;order:1}.info{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column}.label-wrapper{display:-ms-flexbox;display:flex;-ms-flex-pack:start;justify-content:start;-ms-flex-align:center;align-items:center;gap:5px}.control{width:-webkit-fit-content;width:-moz-fit-content;width:fit-content;cursor:pointer;position:relative}.checkbox{-webkit-appearance:none;-moz-appearance:none;appearance:none;border:2px solid var(--primary-base-neutral-medium);border-radius:4px;background:var(--neutral-lighter-neutral-purewhite);-ms-flex:1 0;flex:1 0;display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center;-ms-flex-pack:center;justify-content:center;position:relative;cursor:pointer;-webkit-box-sizing:border-box;box-sizing:border-box;width:var(--size);height:var(--size);-ms-flex:0 0 var(--size);flex:0 0 var(--size)}.icon{position:absolute;display:-ms-flexbox;display:flex;opacity:0;-webkit-transition:opacity 0.3s;transition:opacity 0.3s}.checkbox:focus{border-color:var(--info-base) !important}.disabled .checkbox{background:var(--primary-darker-neutral-white);border-color:var(--primary-base-neutral-base);cursor:not-allowed}.disabled .checkbox:hover{border-color:var(--primary-base-neutral-base) !important}.disabled.checked .checkbox,.disabled.indeterminate .checkbox{background:var(--primary-base-neutral-white);border-color:var(--primary-base-neutral-base)}.disabled.checked .checkbox:hover,.disabled.indeterminate .checkbox:hover{border-color:var(--primary-base-neutral-base) !important;background:var(--primary-base-neutral-white)}.disabled .checkbox:focus{border-color:var(--primary-base-neutral-base)}.checked .checkbox,.indeterminate .checkbox{border-color:var(--color-dark);background:var(--color-base)}.checked .checkbox:hover,.indeterminate .checkbox:hover{border-color:var(--color-light) !important;background:var(--color-lighter)}.checked .icon,.indeterminate .icon{opacity:1}:not(.disabled):not(.checked):not(.indeterminate) .checkbox:hover{border-color:var(--primary-base-neutral-dark)}.success .checkbox{border-color:var(--success-base);background:var(--success-lighter)}.success .checkbox:hover{border-color:var(--success-base) !important}.success.checked .checkbox{border-color:var(--success-dark-base);background:var(--success-base-lighter)}.success.checked .checkbox:hover{border-color:var(--success-dark-base)}.error .checkbox{border-color:var(--error-base);background:var(--error-lighter)}.error .checkbox:hover{border-color:var(--error-base) !important}.error.checked .checkbox{border-color:var(--error-dark-base);background:var(--error-base-lighter)}.error.checked .checkbox:hover{border-color:var(--error-dark-base)}input{appearance:none;-webkit-appearance:none;-moz-appearance:none}';var CuraCheckbox=function(){function e(e){var r=this;registerInstance(this,e);this.onchange=createEvent(this,"onchange",7);this.isDarkbackground=function(){return r.background==="dark"};this.isDarkIconColor=function(){return r.iconColor==="dark"};this.handleClick=function(){if(r.disabled)return;r.indeterminate=false;r.checked=!r.checked;r.onchange.emit({value:r.value,checked:r.checked,indeterminate:r.indeterminate})};this.checked=false;this.indeterminate=false;this.status="default";this.disabled=false;this.required=false;this.label=undefined;this.ontabindex=0;this.position="left";this.value=undefined;this.name=undefined;this.size="medium";this.background="light";this.iconColor="dark";this.color="accent";this.styles={}}e.prototype.sizeHandler=function(){this.styles["--size"]="".concat(formsSizes[this.size].size,"px");this.styles["--gap"]="".concat(formsSizes[this.size].gap,"px")};e.prototype.setColors=function(){var e=this;var r=[{name:"--color-base",background:"".concat(this.color,"-base")},{name:"--color-lighter",background:"".concat(this.color,"-lighter")},{name:"--color-light",background:"".concat(this.color,"-light")},{name:"--color-dark",background:"".concat(this.color,"-dark")},{name:"--info-base",background:"info-base"},{name:"--error-base",background:"error-base"},{name:"--success-lighter",background:"success-lighter"},{name:"--success-base",background:"success-base"},{name:"--success-dark",background:"success-dark"},{name:"--error-lighter",background:"error-lighter"},{name:"--primary-base-neutral-white",background:this.isDarkbackground()?"primary-base":"neutral-white"},{name:"--primary-base-neutral-medium",background:this.isDarkbackground()?"primary-base":"neutral-medium"},{name:"--neutral-lighter-neutral-purewhite",background:this.isDarkbackground()?"neutral-lighter":"neutral-purewhite"},{name:"--primary-darker-neutral-white",background:this.isDarkbackground()?"primary-darker":"neutral-white"},{name:"--primary-base-neutral-base",background:this.isDarkbackground()?"primary-base":"neutral-base"},{name:"--primary-base-neutral-dark",background:this.isDarkbackground()?"primary-base":"neutral-dark"},{name:"--primary-base-neutral-medium",background:this.isDarkbackground()?"primary-base":"neutral-medium"},{name:"--success-base-lighter",background:this.isDarkbackground()?"success-base":"success-lighter"},{name:"--success-dark-base",background:this.isDarkbackground()?"success-dark":"success-base"},{name:"--error-base-lighter",background:this.isDarkbackground()?"error-base":"error-lighter"},{name:"--error-dark-base",background:this.isDarkbackground()?"error-dark":"error-base"}];r.forEach((function(r){return e.styles[r.name]=window.CuraAPI.theme.colors.getColor(r.background)}));this.styles=Object.assign({},this.styles)};e.prototype.connectedCallback=function(){this.sizeHandler();this.setColors()};e.prototype.getClasses=function(){var e={};e["container"]=true;e["checked"]=this.checked;e["disabled"]=this.disabled;e["indeterminate"]=this.indeterminate;e["position"]=this.position==="right";e[this.status]=true;return e};e.prototype.assignColor=function(e){if(this.disabled)return this.isDarkbackground()?"primary-darker":"neutral-medium";var r={success:{icon:"success-dark",label:this.isDarkbackground()?"success-lighter":"success-darker",message:this.isDarkbackground()?"success-base":"success-dark"},error:{icon:"error-dark",label:this.isDarkbackground()?"error-lighter":"neutral-darker",message:this.isDarkbackground()?"error-base":"error-dark"},default:{icon:this.isDarkIconColor()?"neutral-black":"neutral-purewhite",label:this.isDarkbackground()?"neutral-white":"neutral-black",message:this.isDarkbackground()?"primary-lighter":"neutral-dark"}};return r[this.status][e]};e.prototype.getIcon=function(){var e=this.indeterminate?"minus":"check";var r=this.assignColor("icon");var a=this.size==="large"?20:"micro";return h("cura-icon",{class:"icon",name:e,size:a,color:r})};e.prototype.render=function(){return h(Host,null,h("div",{class:this.getClasses(),style:this.styles},h("div",{class:"info"},h("div",{class:"label-wrapper"},h("cura-label",{class:"label",size:this.size==="large"?"medium":"xsmall",color:this.assignColor("label")},this.label),this.required&&h("cura-paragraph",{lineHeight:"0%",marginBlock:"0",color:"error-base"},"* ")),h("cura-label",{color:this.assignColor("message"),size:"xsmall",class:"message"},h("slot",null))),h("div",{class:"checkbox",onClick:this.handleClick,tabIndex:this.ontabindex},h("input",{type:"checkbox",name:this.name,value:this.value,disabled:this.disabled,required:this.required,checked:this.checked,indeterminate:this.indeterminate}),this.getIcon())))};Object.defineProperty(e.prototype,"host",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{size:["sizeHandler"],color:["setColors"],background:["setColors","assignColor"],iconColor:["assignColor"]}},enumerable:false,configurable:true});return e}();CuraCheckbox.style=curaCheckboxCss;export{CuraCheckbox as cura_checkbox};
2
+ //# sourceMappingURL=cura-checkbox.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["curaCheckboxCss","CuraCheckbox","this","isDarkbackground","_this","background","isDarkIconColor","iconColor","handleClick","disabled","indeterminate","checked","onchange","emit","value","prototype","sizeHandler","styles","concat","formsSizes","size","gap","setColors","colors","name","color","forEach","window","CuraAPI","theme","getColor","Object","assign","connectedCallback","getClasses","classes","position","status","assignColor","type","statusColors","success","icon","label","message","error","default","getIcon","iconName","iconSize","h","class","render","Host","style","required","lineHeight","marginBlock","onClick","tabIndex","ontabindex"],"sources":["src/components/forms/cura-checkbox/cura-checkbox.scss?tag=cura-checkbox&encapsulation=shadow","src/components/forms/cura-checkbox/cura-checkbox.tsx"],"sourcesContent":[":host {\n display: block;\n width: fit-content;\n box-sizing: border-box;\n}\n\n/* Container e Layout */\n.container {\n display: flex;\n align-items: center;\n flex-direction: row-reverse;\n gap: var(--gap);\n\n}\n\n.position {\n\n &.container {\n flex-direction: row;\n }\n\n .label-wrapper {\n justify-content: end;\n }\n\n .message {\n text-align: right;\n }\n\n .label {\n order:1\n }\n\n}\n\n.info {\n display: flex;\n flex-direction: column;\n}\n\n.label-wrapper {\n display: flex;\n justify-content: start;\n align-items: center;\n gap: 5px;\n}\n\n/* Control e Checkbox */\n.control {\n width: fit-content;\n cursor: pointer;\n position: relative;\n}\n\n.checkbox {\n appearance: none;\n border: 2px solid var(--primary-base-neutral-medium);\n border-radius: 4px;\n background: var(--neutral-lighter-neutral-purewhite);\n flex: 1 0;\n display: flex;\n align-items: center;\n justify-content: center;\n position: relative;\n cursor: pointer;\n box-sizing: border-box;\n width: var(--size);\n height: var(--size);\n flex: 0 0 var(--size);\n}\n\n.icon {\n position: absolute;\n display: flex;\n opacity: 0;\n transition: opacity 0.3s;\n}\n\n/* Estados de Foco */\n.checkbox:focus {\n border-color: var(--info-base) !important;\n}\n\n/* Estado Disabled */\n.disabled .checkbox {\n background: var(--primary-darker-neutral-white);\n border-color: var(--primary-base-neutral-base);\n cursor: not-allowed;\n\n &:hover {\n border-color: var(--primary-base-neutral-base) !important;\n }\n}\n\n.disabled.checked .checkbox,\n.disabled.indeterminate .checkbox {\n background: var(--primary-base-neutral-white);\n border-color: var(--primary-base-neutral-base);\n\n &:hover {\n border-color: var(--primary-base-neutral-base) !important;\n background: var(--primary-base-neutral-white);\n\n }\n}\n\n.disabled .checkbox:focus {\n border-color: var(--primary-base-neutral-base);\n}\n\n/* Estado Checked */\n.checked .checkbox,\n.indeterminate .checkbox {\n border-color: var(--color-dark);\n background: var(--color-base);\n\n &:hover {\n border-color: var(--color-light) !important;\n background: var(--color-lighter);\n }\n}\n\n.checked .icon,\n.indeterminate .icon {\n opacity: 1;\n}\n\n/* Hover para não disabled, checked, indeterminate */\n:not(.disabled):not(.checked):not(.indeterminate) .checkbox:hover {\n border-color: var(--primary-base-neutral-dark);\n}\n\n/* Estado Success */\n.success .checkbox {\n border-color: var(--success-base) ;\n background: var(--success-lighter);\n\n &:hover{\n border-color: var(--success-base) !important;\n }\n}\n\n.success.checked .checkbox {\n border-color: var(--success-dark-base);\n background: var(--success-base-lighter);\n\n &:hover {\n border-color: var(--success-dark-base);\n }\n}\n\n/* Estado Error */\n.error .checkbox {\n border-color: var(--error-base);\n background: var(--error-lighter);\n\n &:hover {\n border-color: var(--error-base) !important;\n }\n}\n\n.error.checked .checkbox {\n border-color: var(--error-dark-base);\n background: var(--error-base-lighter);\n\n &:hover {\n border-color: var(--error-dark-base);\n }\n}\n\n/* Input */\ninput {\n appearance: none;\n -webkit-appearance: none;\n -moz-appearance: none;\n}\n","import { Component, Prop, Event, Element, h, Host, Watch, EventEmitter, State } from '@stencil/core';\nimport { formsSizes } from '../cura-forms.definitions';\n\n@Component({\n tag: 'cura-checkbox',\n styleUrl: 'cura-checkbox.scss',\n shadow: true,\n})\n\nexport class CuraCheckbox {\n /**\n * Reflects the checked state of the checkbox.\n * Mutable property allowing state change.\n */\n @Prop({ reflect: true, mutable: true }) checked: boolean = false;\n /**\n * Reflects the indeterminate state of the checkbox.\n * Mutable property allowing state change.\n */\n @Prop({ reflect: true, mutable: true }) indeterminate: boolean = false;\n /**\n * Status of the checkbox.\n * Can be 'error', 'success', or 'default'.\n */\n @Prop({ reflect: true, mutable: true }) status: 'error' | 'success' | 'default' = 'default';\n /**\n * Reflects the disabled state of the checkbox.\n */\n @Prop({ reflect: true }) disabled: boolean = false;\n /**\n * Reflects the required state of the checkbox.\n */\n @Prop({ reflect: true }) required: boolean = false;\n /**\n * Text label associated with the checkbox.\n */\n @Prop({ reflect: true }) label: string;\n /**\n * Specifies the tabindex of the checkbox.\n */\n @Prop({ reflect: true }) ontabindex: number = 0;\n /**\n * Position of the label relative to the checkbox.\n * Can be 'left' or 'right'.\n */\n @Prop({ reflect: true }) position: 'left' | 'right' = 'left';\n /**\n * Value associated with the checkbox.\n */\n @Prop({ reflect: true }) value: string;\n /**\n * Name attribute of the checkbox.\n */\n @Prop({ reflect: true }) name: string;\n /**\n * Size of the checkbox.\n * Can be 'small', 'medium', or 'large'.\n */\n @Prop({ reflect: true }) size: 'small' | 'medium' | 'large' = 'medium';\n /**\n * Background theme of the checkbox.\n * Can be 'dark' or 'light'.\n */\n @Prop() background: 'dark' | 'light' = 'light';\n /**\n * iconColor theme of the checkbox.\n * Can be 'dark' or 'light'.\n */\n @Prop() iconColor: 'dark' | 'light' = 'dark';\n /**\n * Color theme of the checkbox.\n */\n @Prop() color = 'accent';\n\n @State() styles = {};\n\n @Element() host: HTMLElement;\n\n @Event() onchange: EventEmitter<{ value: string, checked: boolean, indeterminate: boolean }>;\n\n isDarkbackground = () => this.background === 'dark';\n\n isDarkIconColor = () => this.iconColor === 'dark';\n\n @Watch('size')\n sizeHandler() {\n this.styles['--size'] = `${formsSizes[this.size].size}px`\n this.styles['--gap'] = `${formsSizes[this.size].gap}px`\n }\n\n /**\n * Watches changes in color and background properties to update styles.\n */\n @Watch('color')\n @Watch('background')\n setColors() {\n const colors = [\n { name: '--color-base', background: `${this.color}-base` },\n { name: '--color-lighter', background: `${this.color}-lighter` },\n { name: '--color-light', background: `${this.color}-light` },\n { name: '--color-dark', background: `${this.color}-dark` },\n { name: '--info-base', background: 'info-base' },\n { name: '--error-base', background: 'error-base' },\n { name: '--success-lighter', background: 'success-lighter' },\n { name: '--success-base', background: 'success-base' },\n { name: '--success-dark', background: 'success-dark' },\n { name: '--error-lighter', background: 'error-lighter' },\n { name: '--primary-base-neutral-white', background: this.isDarkbackground() ? 'primary-base' : 'neutral-white' },\n { name: '--primary-base-neutral-medium', background: this.isDarkbackground() ? 'primary-base' : 'neutral-medium' },\n { name: '--neutral-lighter-neutral-purewhite', background: this.isDarkbackground() ? 'neutral-lighter' : 'neutral-purewhite' },\n { name: '--primary-darker-neutral-white', background: this.isDarkbackground() ? 'primary-darker' : 'neutral-white' },\n { name: '--primary-base-neutral-base', background: this.isDarkbackground() ? 'primary-base' : 'neutral-base' },\n { name: '--primary-base-neutral-dark', background: this.isDarkbackground() ? 'primary-base' : 'neutral-dark' },\n { name: '--primary-base-neutral-medium', background: this.isDarkbackground() ? 'primary-base' : 'neutral-medium' },\n { name: '--success-base-lighter', background: this.isDarkbackground() ? 'success-base' : 'success-lighter' },\n { name: '--success-dark-base', background: this.isDarkbackground() ? 'success-dark' : 'success-base' },\n { name: '--error-base-lighter', background: this.isDarkbackground() ? 'error-base' : 'error-lighter' },\n { name: '--error-dark-base', background: this.isDarkbackground() ? 'error-dark' : 'error-base' },\n ];\n\n colors.forEach(color => this.styles[color.name] = window.CuraAPI.theme.colors.getColor(color.background));\n this.styles = { ...this.styles };\n }\n\n connectedCallback() {\n this.sizeHandler()\n this.setColors();\n }\n\n /**\n * Handles click event on the checkbox.\n * Emits onchange event with value, checked, and indeterminate states.\n */\n handleClick = () => {\n if (this.disabled) return;\n\n this.indeterminate = false;\n this.checked = !this.checked;\n this.onchange.emit({ value: this.value, checked: this.checked, indeterminate: this.indeterminate });\n };\n\n /**\n * Retrieves classes based on component state for conditional styling.\n */\n getClasses() {\n const classes = {};\n classes['container'] = true;\n classes['checked'] = this.checked;\n classes['disabled'] = this.disabled;\n classes['indeterminate'] = this.indeterminate;\n classes['position'] = this.position === 'right';\n classes[this.status] = true;\n\n return classes;\n }\n\n /**\n * Assigns color based on status and background theme.\n * @param defaultColor Default color.\n */\n\n @Watch('background')\n @Watch('iconColor')\n assignColor(type: 'icon' | 'label' | 'message',) {\n if (this.disabled) return this.isDarkbackground() ? 'primary-darker' : 'neutral-medium';\n\n const statusColors = {\n success: {\n icon: 'success-dark',\n label: this.isDarkbackground() ? 'success-lighter' : 'success-darker',\n message: this.isDarkbackground() ? 'success-base' : 'success-dark'\n },\n error: {\n icon: 'error-dark',\n label: this.isDarkbackground() ? 'error-lighter' : 'neutral-darker',\n message: this.isDarkbackground() ? 'error-base' : 'error-dark'\n },\n default: {\n icon: this.isDarkIconColor() ? 'neutral-black' : 'neutral-purewhite',\n label: this.isDarkbackground() ? 'neutral-white' : 'neutral-black',\n message: this.isDarkbackground() ? 'primary-lighter' : 'neutral-dark'\n }\n };\n\n return statusColors[this.status][type];\n }\n\n /**\n * Retrieves icon element based on checkbox state.\n */\n getIcon() {\n const iconName = this.indeterminate ? 'minus' : \"check\"\n const iconColor = this.assignColor('icon');\n const iconSize = this.size === 'large' ? 20 : \"micro\"\n\n return <cura-icon class=\"icon\" name={iconName} size={iconSize} color={iconColor}></cura-icon>\n }\n\n\n render() {\n return (\n <Host>\n <div class={this.getClasses()} style={this.styles}>\n <div class=\"info\">\n <div class=\"label-wrapper\">\n <cura-label\n class=\"label\"\n size={this.size === 'large' ? 'medium' : 'xsmall'}\n color={this.assignColor('label')}>\n {this.label}\n </cura-label>\n {this.required && <cura-paragraph lineHeight='0%' marginBlock='0' color=\"error-base\" >* </cura-paragraph>}\n </div>\n <cura-label\n color={this.assignColor('message')}\n size=\"xsmall\"\n class=\"message\">\n <slot></slot>\n </cura-label>\n </div>\n <div class={\"checkbox\"} onClick={this.handleClick} tabIndex={this.ontabindex}>\n <input\n type=\"checkbox\"\n name={this.name}\n value={this.value}\n disabled={this.disabled}\n required={this.required}\n checked={this.checked}\n indeterminate={this.indeterminate}\n />\n {this.getIcon()}\n </div>\n </div>\n </Host>\n );\n }\n}\n"],"mappings":"sKAAA,IAAMA,gBAAkB,orG,ICSXC,aAAY,W,+FAuEvBC,KAAAC,iBAAmB,WAAM,OAAAC,EAAKC,aAAe,MAApB,EAEzBH,KAAAI,gBAAkB,WAAM,OAAAF,EAAKG,YAAc,MAAnB,EAmDxBL,KAAAM,YAAc,WACZ,GAAIJ,EAAKK,SAAU,OAEnBL,EAAKM,cAAgB,MACrBN,EAAKO,SAAWP,EAAKO,QACrBP,EAAKQ,SAASC,KAAK,CAAEC,MAAOV,EAAKU,MAAOH,QAASP,EAAKO,QAASD,cAAeN,EAAKM,e,eA5H1B,M,mBAKM,M,YAKiB,U,cAIrC,M,cAIA,M,qCAQC,E,cAKQ,O,mDAaQ,S,gBAKvB,Q,eAKD,O,WAItB,S,YAEE,E,CAWlBT,EAAAc,UAAAC,YAAA,WACEd,KAAKe,OAAO,UAAY,GAAAC,OAAGC,WAAWjB,KAAKkB,MAAMA,KAAI,MACrDlB,KAAKe,OAAO,SAAW,GAAAC,OAAGC,WAAWjB,KAAKkB,MAAMC,IAAG,K,EAQrDpB,EAAAc,UAAAO,UAAA,eAAAlB,EAAAF,KACE,IAAMqB,EAAS,CACb,CAAEC,KAAM,eAAgBnB,WAAY,GAAAa,OAAGhB,KAAKuB,MAAK,UACjD,CAAED,KAAM,kBAAmBnB,WAAY,GAAAa,OAAGhB,KAAKuB,MAAK,aACpD,CAAED,KAAM,gBAAiBnB,WAAY,GAAAa,OAAGhB,KAAKuB,MAAK,WAClD,CAAED,KAAM,eAAgBnB,WAAY,GAAAa,OAAGhB,KAAKuB,MAAK,UACjD,CAAED,KAAM,cAAenB,WAAY,aACnC,CAAEmB,KAAM,eAAgBnB,WAAY,cACpC,CAAEmB,KAAM,oBAAqBnB,WAAY,mBACzC,CAAEmB,KAAM,iBAAkBnB,WAAY,gBACtC,CAAEmB,KAAM,iBAAkBnB,WAAY,gBACtC,CAAEmB,KAAM,kBAAmBnB,WAAY,iBACvC,CAAEmB,KAAM,+BAAgCnB,WAAYH,KAAKC,mBAAqB,eAAiB,iBAC/F,CAAEqB,KAAM,gCAAiCnB,WAAYH,KAAKC,mBAAqB,eAAiB,kBAChG,CAAEqB,KAAM,sCAAuCnB,WAAYH,KAAKC,mBAAqB,kBAAoB,qBACzG,CAAEqB,KAAM,iCAAkCnB,WAAYH,KAAKC,mBAAqB,iBAAmB,iBACnG,CAAEqB,KAAM,8BAA+BnB,WAAYH,KAAKC,mBAAqB,eAAiB,gBAC9F,CAAEqB,KAAM,8BAA+BnB,WAAYH,KAAKC,mBAAqB,eAAiB,gBAC9F,CAAEqB,KAAM,gCAAiCnB,WAAYH,KAAKC,mBAAqB,eAAiB,kBAChG,CAAEqB,KAAM,yBAA0BnB,WAAYH,KAAKC,mBAAqB,eAAiB,mBACzF,CAAEqB,KAAM,sBAAuBnB,WAAYH,KAAKC,mBAAqB,eAAiB,gBACtF,CAAEqB,KAAM,uBAAwBnB,WAAYH,KAAKC,mBAAqB,aAAe,iBACrF,CAAEqB,KAAM,oBAAqBnB,WAAYH,KAAKC,mBAAqB,aAAe,eAGpFoB,EAAOG,SAAQ,SAAAD,GAAS,OAAArB,EAAKa,OAAOQ,EAAMD,MAAQG,OAAOC,QAAQC,MAAMN,OAAOO,SAASL,EAAMpB,WAArE,IACxBH,KAAKe,OAAMc,OAAAC,OAAA,GAAQ9B,KAAKe,O,EAG1BhB,EAAAc,UAAAkB,kBAAA,WACE/B,KAAKc,cACLd,KAAKoB,W,EAkBPrB,EAAAc,UAAAmB,WAAA,WACE,IAAMC,EAAU,GAChBA,EAAQ,aAAe,KACvBA,EAAQ,WAAajC,KAAKS,QAC1BwB,EAAQ,YAAcjC,KAAKO,SAC3B0B,EAAQ,iBAAmBjC,KAAKQ,cAChCyB,EAAQ,YAAcjC,KAAKkC,WAAa,QACxCD,EAAQjC,KAAKmC,QAAU,KAEvB,OAAOF,C,EAUTlC,EAAAc,UAAAuB,YAAA,SAAYC,GACV,GAAIrC,KAAKO,SAAU,OAAOP,KAAKC,mBAAqB,iBAAmB,iBAEvE,IAAMqC,EAAe,CACnBC,QAAS,CACPC,KAAM,eACNC,MAAOzC,KAAKC,mBAAqB,kBAAoB,iBACrDyC,QAAS1C,KAAKC,mBAAqB,eAAiB,gBAEtD0C,MAAO,CACLH,KAAM,aACNC,MAAOzC,KAAKC,mBAAqB,gBAAkB,iBACnDyC,QAAS1C,KAAKC,mBAAqB,aAAe,cAEpD2C,QAAS,CACPJ,KAAMxC,KAAKI,kBAAoB,gBAAkB,oBACjDqC,MAAOzC,KAAKC,mBAAqB,gBAAkB,gBACnDyC,QAAS1C,KAAKC,mBAAqB,kBAAoB,iBAI3D,OAAOqC,EAAatC,KAAKmC,QAAQE,E,EAMnCtC,EAAAc,UAAAgC,QAAA,WACE,IAAMC,EAAW9C,KAAKQ,cAAgB,QAAU,QAChD,IAAMH,EAAYL,KAAKoC,YAAY,QACnC,IAAMW,EAAW/C,KAAKkB,OAAS,QAAU,GAAK,QAE9C,OAAO8B,EAAA,aAAWC,MAAM,OAAO3B,KAAMwB,EAAU5B,KAAM6B,EAAUxB,MAAOlB,G,EAIxEN,EAAAc,UAAAqC,OAAA,WACE,OACEF,EAACG,KAAI,KACHH,EAAA,OAAKC,MAAOjD,KAAKgC,aAAcoB,MAAOpD,KAAKe,QACzCiC,EAAA,OAAKC,MAAM,QACTD,EAAA,OAAKC,MAAM,iBACTD,EAAA,cACEC,MAAM,QACN/B,KAAMlB,KAAKkB,OAAS,QAAU,SAAW,SACzCK,MAAOvB,KAAKoC,YAAY,UACvBpC,KAAKyC,OAEPzC,KAAKqD,UAAYL,EAAA,kBAAgBM,WAAW,KAAKC,YAAY,IAAIhC,MAAM,cAAY,OAEtFyB,EAAA,cACEzB,MAAOvB,KAAKoC,YAAY,WACxBlB,KAAK,SACL+B,MAAM,WACND,EAAA,eAGJA,EAAA,OAAKC,MAAO,WAAYO,QAASxD,KAAKM,YAAamD,SAAUzD,KAAK0D,YAChEV,EAAA,SACEX,KAAK,WACLf,KAAMtB,KAAKsB,KACXV,MAAOZ,KAAKY,MACZL,SAAUP,KAAKO,SACf8C,SAAUrD,KAAKqD,SACf5C,QAAST,KAAKS,QACdD,cAAeR,KAAKQ,gBAErBR,KAAK6C,Y,6UA7NO,G"}
@@ -1,2 +1,2 @@
1
- import{r as registerInstance,h,H as Host,g as getElement}from"./index-d99da69e.js";var curaDisplayCss=":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:3em;font-weight:var(--font-weight-bold);color:var(--color-body);line-height:var(--line-height);margin-block:var(--margin-block);letter-spacing:0px}@media (min-width: 769px) and (max-width: 1920px){:host h1,:host h2,:host h3,:host h4,:host h5,:host h6{font-size:3.429em}}@media (min-width: 1921px){:host h1,:host h2,:host h3,:host h4,:host h5,:host h6{font-size:4.286em;line-height:calc(var(--line-height) + 5%)}}:host ::slotted(b),:host ::slotted(strong){font-weight:var(--font-weight-bold)}:host ::slotted(a){font-weight:var(--font-weight-bold);color:var(--color-link);text-underline-offset:10%;cursor:pointer}:host ::slotted(u){text-underline-offset:10%}:host ::slotted(abbr){color:var(--color-link);-webkit-text-decoration:underline dashed 1px var(--color-link);text-decoration:underline dashed 1px var(--color-link);text-underline-offset:10%;cursor:default}";var CuraDisplay=function(){function t(t){registerInstance(this,t);this.theme=window.CuraAPI.theme;this.level=1;this.spotColor="accent-dark";this.color=undefined;this.marginBlock="1.25em";this.lineHeight="120%";this.styles={}}t.prototype.handleChangeColor=function(){this.setColors()};t.prototype.connectedCallback=function(){this.setFontProperties();this.setColors()};t.prototype.setFontProperties=function(){this.weights=this.theme.fonts.getWeights();this.fontSizeBase=this.theme.fonts.getSize();this.styles={"--font-family":window.CuraAPI.theme.fonts.getFamily("display"),"--font-size":window.CuraAPI.theme.fonts.getSize(),"--font-weight-bold":this.weights.bold}};t.prototype.hostCSSProperties=function(){return{"--margin-block":this.marginBlock,"--font-size-base":this.fontSizeBase,"--line-height":this.lineHeight}};t.prototype.setColors=function(){var t=this.color?this.theme.colors.getColor(this.color):this.theme.fonts.getColor();this.styles=Object.assign(Object.assign({},this.styles),{"--color-body":t||this.theme.colors.getColor("neutral-darker"),"--color-link":this.theme.colors.getColor("".concat(this.spotColor))})};t.prototype.getHeadingTag=function(){var t={1:h("h1",{style:this.styles},h("slot",null)),2:h("h2",{style:this.styles},h("slot",null)),3:h("h3",{style:this.styles},h("slot",null)),4:h("h4",{style:this.styles},h("slot",null)),5:h("h5",{style:this.styles},h("slot",null)),6:h("h6",{style:this.styles},h("slot",null)),default:h("h1",{style:this.styles},h("slot",null))};return t["".concat(this.level)]||t["default"]};t.prototype.render=function(){return h(Host,{style:this.hostCSSProperties()},this.getHeadingTag())};Object.defineProperty(t.prototype,"host",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(t,"watchers",{get:function(){return{color:["handleChangeColor"],spotColor:["handleChangeColor"]}},enumerable:false,configurable:true});return t}();CuraDisplay.style=curaDisplayCss;export{CuraDisplay as cura_display};
1
+ import{r as registerInstance,h,H as Host,g as getElement}from"./index-81f1a268.js";var curaDisplayCss=":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:3em;font-weight:var(--font-weight-bold);color:var(--color-body);line-height:var(--line-height);margin-block:var(--margin-block);letter-spacing:0px}@media (min-width: 769px) and (max-width: 1920px){:host h1,:host h2,:host h3,:host h4,:host h5,:host h6{font-size:3.429em}}@media (min-width: 1921px){:host h1,:host h2,:host h3,:host h4,:host h5,:host h6{font-size:4.286em;line-height:calc(var(--line-height) + 5%)}}:host ::slotted(b),:host ::slotted(strong){font-weight:var(--font-weight-bold)}:host ::slotted(a){font-weight:var(--font-weight-bold);color:var(--color-link);text-underline-offset:10%;cursor:pointer}:host ::slotted(u){text-underline-offset:10%}:host ::slotted(abbr){color:var(--color-link);-webkit-text-decoration:underline dashed 1px var(--color-link);text-decoration:underline dashed 1px var(--color-link);text-underline-offset:10%;cursor:default}";var CuraDisplay=function(){function t(t){registerInstance(this,t);this.theme=window.CuraAPI.theme;this.level=1;this.spotColor="accent-dark";this.color=undefined;this.marginBlock="1.25em";this.lineHeight="120%";this.styles={}}t.prototype.handleChangeColor=function(){this.setColors()};t.prototype.connectedCallback=function(){this.setFontProperties();this.setColors()};t.prototype.setFontProperties=function(){this.weights=this.theme.fonts.getWeights();this.fontSizeBase=this.theme.fonts.getSize();this.styles={"--font-family":window.CuraAPI.theme.fonts.getFamily("display"),"--font-size":window.CuraAPI.theme.fonts.getSize(),"--font-weight-bold":this.weights.bold}};t.prototype.hostCSSProperties=function(){return{"--margin-block":this.marginBlock,"--font-size-base":this.fontSizeBase,"--line-height":this.lineHeight}};t.prototype.setColors=function(){var t=this.color?this.theme.colors.getColor(this.color):this.theme.fonts.getColor();this.styles=Object.assign(Object.assign({},this.styles),{"--color-body":t||this.theme.colors.getColor("neutral-darker"),"--color-link":this.theme.colors.getColor("".concat(this.spotColor))})};t.prototype.getHeadingTag=function(){var t={1:h("h1",{style:this.styles},h("slot",null)),2:h("h2",{style:this.styles},h("slot",null)),3:h("h3",{style:this.styles},h("slot",null)),4:h("h4",{style:this.styles},h("slot",null)),5:h("h5",{style:this.styles},h("slot",null)),6:h("h6",{style:this.styles},h("slot",null)),default:h("h1",{style:this.styles},h("slot",null))};return t["".concat(this.level)]||t["default"]};t.prototype.render=function(){return h(Host,{style:this.hostCSSProperties()},this.getHeadingTag())};Object.defineProperty(t.prototype,"host",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(t,"watchers",{get:function(){return{color:["handleChangeColor"],spotColor:["handleChangeColor"]}},enumerable:false,configurable:true});return t}();CuraDisplay.style=curaDisplayCss;export{CuraDisplay as cura_display};
2
2
  //# sourceMappingURL=cura-display.entry.js.map
@@ -0,0 +1,2 @@
1
+ var formsSizes={large:{size:32,gap:16},medium:{size:24,gap:12},small:{size:20,gap:8}};export{formsSizes as f};
2
+ //# sourceMappingURL=cura-forms.definitions-0f774253.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["formsSizes","large","size","gap","medium","small"],"sources":["src/components/forms/cura-forms.definitions.tsx"],"sourcesContent":["export const formsSizes = {\n \"large\": {\n size: 32,\n gap: 16,\n },\n \"medium\": {\n size: 24,\n gap: 12,\n },\n \"small\": {\n size: 20,\n gap: 8,\n },\n};\n"],"mappings":"IAAaA,WAAa,CACxBC,MAAS,CACPC,KAAM,GACNC,IAAK,IAEPC,OAAU,CACRF,KAAM,GACNC,IAAK,IAEPE,MAAS,CACPH,KAAM,GACNC,IAAK,W"}
@@ -0,0 +1,2 @@
1
+ var microIcons=["arrowDown","arrowLeft","arrowRight","arrowUp","check","checkDouble","close","closeCircle","collapse","down","expand","linkExternal","link","left","minus","minusCircle","minusSquare","order","subItem","right","plus","plusCircle","plusSquare","up","filter","swap"];var iconSizes={128:{size:128,stroke:5.25},72:{size:72,stroke:3.5},64:{size:64,stroke:3.25},48:{size:48,stroke:2.75},40:{size:40,stroke:2.5},32:{size:32,stroke:2.25},24:{size:24,stroke:2},20:{size:20,stroke:1.75},16:{size:16,stroke:1.5},micro:{size:12,stroke:1.5},default:{size:24,stroke:2}};export{iconSizes as i,microIcons as m};
2
+ //# sourceMappingURL=cura-icon.definitions-a63d1862.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["microIcons","iconSizes","size","stroke","micro","default"],"sources":["src/components/cura-icon/cura-icon.definitions.tsx"],"sourcesContent":["export const microIcons = ['arrowDown','arrowLeft','arrowRight','arrowUp','check','checkDouble','close','closeCircle','collapse','down','expand','linkExternal','link','left','minus','minusCircle','minusSquare','order','subItem','right','plus','plusCircle','plusSquare','up','filter','swap'];\n\nexport const iconSizes = {\n \"128\": {size: 128, stroke: 5.25},\n \"72\": {size: 72, stroke: 3.5},\n \"64\": {size: 64, stroke: 3.25},\n \"48\": {size: 48, stroke: 2.75},\n \"40\": {size: 40, stroke: 2.5},\n \"32\": {size: 32, stroke: 2.25},\n \"24\": {size: 24, stroke: 2},\n \"20\": {size: 20, stroke: 1.75},\n \"16\": {size: 16, stroke: 1.5},\n \"micro\": {size: 12, stroke: 1.5 },\n \"default\": {size: 24, stroke: 2}\n};\n"],"mappings":"IAAaA,WAAa,CAAC,YAAY,YAAY,aAAa,UAAU,QAAQ,cAAc,QAAQ,cAAc,WAAW,OAAO,SAAS,eAAe,OAAO,OAAO,QAAQ,cAAc,cAAc,QAAQ,UAAU,QAAQ,OAAO,aAAa,aAAa,KAAK,SAAS,Q,IAE9QC,UAAY,CACvB,IAAO,CAACC,KAAM,IAAKC,OAAQ,MAC3B,GAAM,CAACD,KAAM,GAAIC,OAAQ,KACzB,GAAM,CAACD,KAAM,GAAIC,OAAQ,MACzB,GAAM,CAACD,KAAM,GAAIC,OAAQ,MACzB,GAAM,CAACD,KAAM,GAAIC,OAAQ,KACzB,GAAM,CAACD,KAAM,GAAIC,OAAQ,MACzB,GAAM,CAACD,KAAM,GAAIC,OAAQ,GACzB,GAAM,CAACD,KAAM,GAAIC,OAAQ,MACzB,GAAM,CAACD,KAAM,GAAIC,OAAQ,KACzBC,MAAS,CAACF,KAAM,GAAIC,OAAQ,KAC5BE,QAAW,CAACH,KAAM,GAAIC,OAAQ,W"}
@@ -1,2 +1,2 @@
1
- import{r as registerInstance,h,H as Host}from"./index-d99da69e.js";var iconsetdefaulticons=["360","accessibility","addUser","airdrop","alertCircle","alertTriangle","arrowDown","arrowDownCircle","arrowLeft","arrowLeftCircle","arrowRight","arrowRightCircle","arrowUp","arrowUpCircle","attach","avatarF","avatarM","biometry","bloodGroup","calendar","cam","camOff","central","chatCircle","check","checkBadge","checkCircle","checkDouble","clock","close","closeCircle","collapse","config","currency","delete","desktop","doc","down","download","duplicate","edit","exam","examDoc","expand","facebook","fileBmp","fileJpg","filePdf","filePng","fileUpload","fileXls","filter","fullscreen","gallery","geotag","geotagUnity","geotagUnityGroup","google","graph","healthPlan","heart","height","height2","home","horizontalList","imageUp","infoCircle","instagram","key","lamp","language","language2","languageEN","languagePT","lattes","left","like","link","linkExternal","linkedin","list","login","logout","mail","maintenance","medDoc","medEspec","medImg","medUser","medical","menuHamburguer","menuKebab","menuMeatballs","mic","micOff","minus","minusCircle","minusSquare","mobile","news","notification","npsDeslike","npsHate","npsLike","npsLove","npsNeutral","order","partner","phone","play","plus","plusCircle","plusSquare","print","profile","profileCircle","questionCircle","questionSquare","range","reload","ribbon","right","schedule","scheduleCheck","scheduleHistorico","search","secure","share","siren","sound","soundOff","subItem","target","team","telegram","twitter","unLink","unSecure","unity","unlike","up","upload","verticalList","viewFalse","viewTrue","weight","whatsapp","wifi","wifiOff","youtube","zoomIn","zoomOut"];var curaIconsViewCss=':host{display:block;padding:24px;font-family:"Roboto", Arial, Helvetica, sans-serif}.iconDetail{display:block}.iconSizes{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.iconSizes .size{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;text-align:center;margin-right:9px;padding:8px}.iconSizes .size:last-child{margin-right:0}.iconSizes .size span{font-size:10px}.iconSizes.invert{margin-top:12px}.iconSizes.invert .size{background-color:#262626;color:#F6F6F6;border-radius:3px}.icons{margin-top:28px;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;position:relative}.icons .icon{position:relative;padding:4px;cursor:pointer;opacity:0.6;-webkit-transition:opacity 0.2s linear;transition:opacity 0.2s linear}.icons .icon span{font-size:12px;padding:6px;-webkit-box-sizing:border-box;box-sizing:border-box;background:#000;color:#FFF;border-radius:2px;position:absolute;top:-2px;left:50%;-webkit-transform:translateX(-50%) translateY(-100%);transform:translateX(-50%) translateY(-100%);display:none}.icons .icon:hover{opacity:1}.icons .icon:hover span{display:block}';var CuraIconsView=function(){function e(e){var i=this;registerInstance(this,e);this.sizes=[16,20,24,32,40,48,64,72,128];this.colors=["primary","secondary","accent","info","warning","error","success","neutral"];this.setSelected=function(e){i.selected=e};this.selected="360"}e.prototype.render=function(){var e=this;return h(Host,null,h("div",{class:"iconDetail"},h("h4",null,this.selected),h("div",{class:"iconSizes"},this.sizes.map((function(i){return h("div",{class:"size"},h("cura-icon",{name:e.selected,size:i}),h("span",null,i))}))),h("div",{class:"iconSizes invert"},this.sizes.map((function(i){return h("div",{class:"size"},h("cura-icon",{name:e.selected,size:i,color:"neutral-white"}),h("span",null,i))}))),h("div",{class:"iconSizes"},this.colors.map((function(i){return h("div",{class:"size"},h("cura-icon",{name:e.selected,color:i}),h("span",null,i))})),h("div",{class:"size"},h("cura-icon",{name:this.selected,disabled:true}),h("span",null,"Disabled")))),h("div",{class:"icons"},iconsetdefaulticons.map((function(i){return h("div",{class:"icon",onClick:function(){return e.setSelected(i)}},h("cura-icon",{name:i}),h("span",null,i))}))))};return e}();CuraIconsView.style=curaIconsViewCss;export{CuraIconsView as cura_icons_view};
1
+ import{r as registerInstance,h,H as Host}from"./index-81f1a268.js";import{i as iconSizes,m as microIcons}from"./cura-icon.definitions-a63d1862.js";var iconsetdefaulticons=["360","accessibility","addUser","airdrop","alertCircle","alertTriangle","arrowDown","arrowDownCircle","arrowLeft","arrowLeftCircle","arrowRight","arrowRightCircle","arrowUp","arrowUpCircle","attach","avatarF","avatarM","biometry","bloodGroup","calendar","cam","camOff","central","chatCircle","check","checkBadge","checkCircle","checkDouble","clock","close","closeCircle","collapse","config","currency","delete","desktop","doc","down","download","duplicate","edit","exam","examDoc","expand","facebook","fileBmp","fileJpg","filePdf","filePng","fileUpload","fileXls","filter","fullscreen","gallery","geotag","geotagUnity","geotagUnityGroup","google","graph","healthPlan","heart","height","height2","home","horizontalList","imageUp","infoCircle","instagram","key","lamp","language","language2","languageEN","languagePT","lattes","left","like","link","linkExternal","linkedin","list","login","logout","mail","maintenance","medDoc","medEspec","medImg","medUser","medical","menuHamburguer","menuKebab","menuMeatballs","mic","micOff","minus","minusCircle","minusSquare","mobile","news","notification","npsDeslike","npsHate","npsLike","npsLove","npsNeutral","order","partner","phone","play","plus","plusCircle","plusSquare","print","profile","profileCircle","questionCircle","questionSquare","range","reload","ribbon","right","schedule","scheduleCheck","scheduleHistorico","search","secure","share","siren","sound","soundOff","subItem","swap","target","team","telegram","twitter","unLink","unSecure","unity","unlike","up","upload","verticalList","viewFalse","viewTrue","weight","whatsapp","wifi","wifiOff","youtube","zoomIn","zoomOut"];var curaIconsViewCss=':host{display:block;padding:24px;font-family:"Roboto", Arial, Helvetica, sans-serif}.iconDetail{display:block}.iconSizes{display:-ms-flexbox;display:flex;-ms-flex-align:center;align-items:center}.iconSizes .size{display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;text-align:center;-ms-flex-align:center;align-items:center;margin-right:9px;padding:8px}.iconSizes .size:last-child{margin-right:0}.iconSizes .size span{font-size:10px;margin:8px 0}.iconSizes.invert{margin-top:12px}.iconSizes.invert .size{background-color:#2d2d2d;color:#F6F6F6;border-radius:3px}.icons{margin-top:28px;display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap;position:relative}.icons .icon{position:relative;padding:4px;cursor:pointer;opacity:0.6;-webkit-transition:opacity 0.2s linear;transition:opacity 0.2s linear;width:105px;display:-ms-flexbox;display:flex;-ms-flex-direction:column;flex-direction:column;text-align:center;-ms-flex-align:center;align-items:center;margin-bottom:16px;-webkit-box-sizing:border-box;box-sizing:border-box;}.icons .icon cura-label{margin-top:8px}.icons .icon cura-paragraph{margin-top:4px}';var CuraIconsView=function(){function e(e){var i=this;registerInstance(this,e);this.sizes=Object.keys(iconSizes).filter((function(e){return e!=="default"}));this.colors=["primary","secondary","accent","info","warning","error","success","neutral"];this.setSelected=function(e){i.selected=e};this.selected=iconsetdefaulticons[0]}e.prototype.connectedCallback=function(){this.sizes.unshift(this.sizes.pop())};e.prototype.render=function(){var e=this;return h(Host,null,h("div",{class:"iconDetail"},h("cura-heading",{size:"small","margin-block":"0 24px"},"Icon: ",h("b",null,this.selected)),h("div",{class:"iconSizes"},this.sizes.map((function(i){return i==="micro"&&!microIcons.includes(e.selected)?"":h("div",{class:"size"},h("cura-icon",{name:e.selected,size:i}),h("span",null,i))}))),h("div",{class:"iconSizes invert"},this.sizes.map((function(i){return i==="micro"&&!microIcons.includes(e.selected)?"":h("div",{class:"size"},h("cura-icon",{name:e.selected,size:i,color:"neutral-white"}),h("span",null,i))})))),h("div",{class:"icons"},iconsetdefaulticons.map((function(i){return h("div",{class:{icon:true,selected:i===e.selected},onClick:function(){return e.setSelected(i)}},h("cura-icon",{name:i,size:"32",color:i===e.selected?"accent-dark":"neutral-dark"}),h("cura-label",{size:"xsmall",weight:i===e.selected?"bold":"regular",color:i===e.selected?"accent-dark":"neutral-dark"},i),!microIcons.includes(i)?"":h("cura-paragraph",{color:"success-dark",size:"xsmall","margin-block":"0px","line-height":"100%"},"MICRO"))}))))};return e}();CuraIconsView.style=curaIconsViewCss;export{CuraIconsView as cura_icons_view};
2
2
  //# sourceMappingURL=cura-icons-view.entry.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["iconsetdefaulticons","curaIconsViewCss","CuraIconsView","this","sizes","colors","setSelected","icon","_this","selected","prototype","render","h","Host","class","map","size","name","color","disabled","onClick"],"sources":["src/assets/icons/iconset-default-list.ts","src/components/cura-icons-view/cura-icons-view.scss?tag=cura-icons-view&encapsulation=shadow","src/components/cura-icons-view/cura-icons-view.tsx"],"sourcesContent":["export default [\"360\",\"accessibility\",\"addUser\",\"airdrop\",\"alertCircle\",\"alertTriangle\",\"arrowDown\",\"arrowDownCircle\",\"arrowLeft\",\"arrowLeftCircle\",\"arrowRight\",\"arrowRightCircle\",\"arrowUp\",\"arrowUpCircle\",\"attach\",\"avatarF\",\"avatarM\",\"biometry\",\"bloodGroup\",\"calendar\",\"cam\",\"camOff\",\"central\",\"chatCircle\",\"check\",\"checkBadge\",\"checkCircle\",\"checkDouble\",\"clock\",\"close\",\"closeCircle\",\"collapse\",\"config\",\"currency\",\"delete\",\"desktop\",\"doc\",\"down\",\"download\",\"duplicate\",\"edit\",\"exam\",\"examDoc\",\"expand\",\"facebook\",\"fileBmp\",\"fileJpg\",\"filePdf\",\"filePng\",\"fileUpload\",\"fileXls\",\"filter\",\"fullscreen\",\"gallery\",\"geotag\",\"geotagUnity\",\"geotagUnityGroup\",\"google\",\"graph\",\"healthPlan\",\"heart\",\"height\",\"height2\",\"home\",\"horizontalList\",\"imageUp\",\"infoCircle\",\"instagram\",\"key\",\"lamp\",\"language\",\"language2\",\"languageEN\",\"languagePT\",\"lattes\",\"left\",\"like\",\"link\",\"linkExternal\",\"linkedin\",\"list\",\"login\",\"logout\",\"mail\",\"maintenance\",\"medDoc\",\"medEspec\",\"medImg\",\"medUser\",\"medical\",\"menuHamburguer\",\"menuKebab\",\"menuMeatballs\",\"mic\",\"micOff\",\"minus\",\"minusCircle\",\"minusSquare\",\"mobile\",\"news\",\"notification\",\"npsDeslike\",\"npsHate\",\"npsLike\",\"npsLove\",\"npsNeutral\",\"order\",\"partner\",\"phone\",\"play\",\"plus\",\"plusCircle\",\"plusSquare\",\"print\",\"profile\",\"profileCircle\",\"questionCircle\",\"questionSquare\",\"range\",\"reload\",\"ribbon\",\"right\",\"schedule\",\"scheduleCheck\",\"scheduleHistorico\",\"search\",\"secure\",\"share\",\"siren\",\"sound\",\"soundOff\",\"subItem\",\"target\",\"team\",\"telegram\",\"twitter\",\"unLink\",\"unSecure\",\"unity\",\"unlike\",\"up\",\"upload\",\"verticalList\",\"viewFalse\",\"viewTrue\",\"weight\",\"whatsapp\",\"wifi\",\"wifiOff\",\"youtube\",\"zoomIn\",\"zoomOut\"];",":host {\n display: block;\n padding: 24px;\n font-family: 'Roboto', Arial, Helvetica, sans-serif;\n}\n\n.iconDetail {\n display: block;\n}\n\n.iconSizes {\n display: flex;\n align-items: center;\n\n\n .size {\n display: flex;\n flex-direction: column;\n text-align: center;\n margin-right: 9px;\n padding: 8px;\n\n &:last-child { margin-right: 0; }\n span {\n font-size: 10px;\n }\n }\n\n &.invert {\n margin-top: 12px;\n\n .size {\n background-color: #262626;\n color: #F6F6F6;\n border-radius: 3px;\n }\n }\n}\n\n.icons {\n margin-top: 28px;\n display: flex;\n flex-wrap: wrap;\n position: relative;\n\n .icon {\n position: relative;\n padding: 4px;\n cursor: pointer;\n opacity: .6;\n transition: opacity .2s linear;\n span {\n font-size: 12px;\n padding: 6px;\n box-sizing: border-box;\n background: #000;\n color: #FFF;\n border-radius: 2px;\n position: absolute;\n top: -2px;\n left: 50%;\n transform: translateX(-50%) translateY(-100%);\n display: none;\n }\n\n &:hover {\n opacity: 1;\n\n span { display: block; }\n }\n }\n}\n\n","import { Component, Host, h, State } from '@stencil/core';\nimport iconsetdefaulticons from '../../assets/icons/iconset-default-list';\n\n@Component({\n tag: 'cura-icons-view',\n styleUrl: 'cura-icons-view.scss',\n shadow: true,\n})\nexport class CuraIconsView {\n\n sizes = [16, 20, 24, 32, 40, 48, 64, 72, 128];\n colors = ['primary', 'secondary', 'accent', 'info', 'warning', 'error', 'success', 'neutral'];\n @State() selected = '360';\n\n setSelected = (icon) => {\n this.selected = icon;\n }\n\n render() {\n return (\n <Host>\n <div class=\"iconDetail\">\n <h4>{ this.selected }</h4>\n <div class=\"iconSizes\">\n { this.sizes.map( size =>\n\n <div class=\"size\">\n <cura-icon name={this.selected} size={size}></cura-icon>\n <span>{ size }</span>\n </div>\n )}\n </div>\n <div class=\"iconSizes invert\">\n { this.sizes.map( size =>\n\n <div class=\"size\">\n <cura-icon name={this.selected} size={size} color=\"neutral-white\"></cura-icon>\n <span>{ size }</span>\n </div>\n )}\n </div>\n <div class=\"iconSizes\">\n { this.colors.map( color =>\n <div class=\"size\">\n <cura-icon name={this.selected} color={color}></cura-icon>\n <span>{ color }</span>\n </div>\n )}\n <div class=\"size\">\n <cura-icon name={this.selected} disabled></cura-icon>\n <span>Disabled</span>\n </div>\n </div>\n </div>\n <div class=\"icons\">\n { iconsetdefaulticons.map(icon =>\n <div class=\"icon\" onClick={() => this.setSelected(icon)}>\n <cura-icon name={icon}></cura-icon>\n <span>{icon}</span>\n </div>\n )}\n </div>\n </Host>\n );\n }\n\n}\n"],"mappings":"mEAAA,IAAAA,oBAAe,CAAC,MAAM,gBAAgB,UAAU,UAAU,cAAc,gBAAgB,YAAY,kBAAkB,YAAY,kBAAkB,aAAa,mBAAmB,UAAU,gBAAgB,SAAS,UAAU,UAAU,WAAW,aAAa,WAAW,MAAM,SAAS,UAAU,aAAa,QAAQ,aAAa,cAAc,cAAc,QAAQ,QAAQ,cAAc,WAAW,SAAS,WAAW,SAAS,UAAU,MAAM,OAAO,WAAW,YAAY,OAAO,OAAO,UAAU,SAAS,WAAW,UAAU,UAAU,UAAU,UAAU,aAAa,UAAU,SAAS,aAAa,UAAU,SAAS,cAAc,mBAAmB,SAAS,QAAQ,aAAa,QAAQ,SAAS,UAAU,OAAO,iBAAiB,UAAU,aAAa,YAAY,MAAM,OAAO,WAAW,YAAY,aAAa,aAAa,SAAS,OAAO,OAAO,OAAO,eAAe,WAAW,OAAO,QAAQ,SAAS,OAAO,cAAc,SAAS,WAAW,SAAS,UAAU,UAAU,iBAAiB,YAAY,gBAAgB,MAAM,SAAS,QAAQ,cAAc,cAAc,SAAS,OAAO,eAAe,aAAa,UAAU,UAAU,UAAU,aAAa,QAAQ,UAAU,QAAQ,OAAO,OAAO,aAAa,aAAa,QAAQ,UAAU,gBAAgB,iBAAiB,iBAAiB,QAAQ,SAAS,SAAS,QAAQ,WAAW,gBAAgB,oBAAoB,SAAS,SAAS,QAAQ,QAAQ,QAAQ,WAAW,UAAU,SAAS,OAAO,WAAW,UAAU,SAAS,WAAW,QAAQ,SAAS,KAAK,SAAS,eAAe,YAAY,WAAW,SAAS,WAAW,OAAO,UAAU,UAAU,SAAS,WCAzlD,IAAMC,iBAAmB,snC,ICQZC,cAAa,W,kDAExBC,KAAAC,MAAQ,CAAC,GAAI,GAAI,GAAI,GAAI,GAAI,GAAI,GAAI,GAAI,KACzCD,KAAAE,OAAS,CAAC,UAAW,YAAa,SAAU,OAAQ,UAAW,QAAS,UAAW,WAGnFF,KAAAG,YAAc,SAACC,GACbC,EAAKC,SAAWF,C,gBAHE,K,CAMpBL,EAAAQ,UAAAC,OAAA,eAAAH,EAAAL,KACE,OACES,EAACC,KAAI,KACHD,EAAA,OAAKE,MAAM,cACTF,EAAA,UAAMT,KAAKM,UACXG,EAAA,OAAKE,MAAM,aACPX,KAAKC,MAAMW,KAAK,SAAAC,GAEhB,OAAAJ,EAAA,OAAKE,MAAM,QACTF,EAAA,aAAWK,KAAMT,EAAKC,SAAUO,KAAMA,IACtCJ,EAAA,YAAQI,GAFV,KAMJJ,EAAA,OAAKE,MAAM,oBACPX,KAAKC,MAAMW,KAAK,SAAAC,GAEhB,OAAAJ,EAAA,OAAKE,MAAM,QACTF,EAAA,aAAWK,KAAMT,EAAKC,SAAUO,KAAMA,EAAME,MAAM,kBAClDN,EAAA,YAAQI,GAFV,KAMJJ,EAAA,OAAKE,MAAM,aACPX,KAAKE,OAAOU,KAAK,SAAAG,GACjB,OAAAN,EAAA,OAAKE,MAAM,QACTF,EAAA,aAAWK,KAAMT,EAAKC,SAAUS,MAAOA,IACvCN,EAAA,YAAQM,GAFV,IAKFN,EAAA,OAAKE,MAAM,QACTF,EAAA,aAAWK,KAAMd,KAAKM,SAAUU,SAAQ,OACxCP,EAAA,2BAINA,EAAA,OAAKE,MAAM,SACPd,oBAAoBe,KAAI,SAAAR,GACxB,OAAAK,EAAA,OAAKE,MAAM,OAAOM,QAAS,WAAM,OAAAZ,EAAKF,YAAYC,EAAjB,GAC/BK,EAAA,aAAWK,KAAMV,IACjBK,EAAA,YAAOL,GAFT,K,WAhDc,G"}
1
+ {"version":3,"names":["iconsetdefaulticons","curaIconsViewCss","CuraIconsView","this","sizes","Object","keys","iconSizes","filter","key","colors","setSelected","icon","_this","selected","prototype","connectedCallback","unshift","pop","render","h","Host","class","size","map","microIcons","includes","name","color","onClick","weight"],"sources":["src/assets/icons/iconset-default-list.ts","src/components/cura-icons-view/cura-icons-view.scss?tag=cura-icons-view&encapsulation=shadow","src/components/cura-icons-view/cura-icons-view.tsx"],"sourcesContent":["export default [\"360\",\"accessibility\",\"addUser\",\"airdrop\",\"alertCircle\",\"alertTriangle\",\"arrowDown\",\"arrowDownCircle\",\"arrowLeft\",\"arrowLeftCircle\",\"arrowRight\",\"arrowRightCircle\",\"arrowUp\",\"arrowUpCircle\",\"attach\",\"avatarF\",\"avatarM\",\"biometry\",\"bloodGroup\",\"calendar\",\"cam\",\"camOff\",\"central\",\"chatCircle\",\"check\",\"checkBadge\",\"checkCircle\",\"checkDouble\",\"clock\",\"close\",\"closeCircle\",\"collapse\",\"config\",\"currency\",\"delete\",\"desktop\",\"doc\",\"down\",\"download\",\"duplicate\",\"edit\",\"exam\",\"examDoc\",\"expand\",\"facebook\",\"fileBmp\",\"fileJpg\",\"filePdf\",\"filePng\",\"fileUpload\",\"fileXls\",\"filter\",\"fullscreen\",\"gallery\",\"geotag\",\"geotagUnity\",\"geotagUnityGroup\",\"google\",\"graph\",\"healthPlan\",\"heart\",\"height\",\"height2\",\"home\",\"horizontalList\",\"imageUp\",\"infoCircle\",\"instagram\",\"key\",\"lamp\",\"language\",\"language2\",\"languageEN\",\"languagePT\",\"lattes\",\"left\",\"like\",\"link\",\"linkExternal\",\"linkedin\",\"list\",\"login\",\"logout\",\"mail\",\"maintenance\",\"medDoc\",\"medEspec\",\"medImg\",\"medUser\",\"medical\",\"menuHamburguer\",\"menuKebab\",\"menuMeatballs\",\"mic\",\"micOff\",\"minus\",\"minusCircle\",\"minusSquare\",\"mobile\",\"news\",\"notification\",\"npsDeslike\",\"npsHate\",\"npsLike\",\"npsLove\",\"npsNeutral\",\"order\",\"partner\",\"phone\",\"play\",\"plus\",\"plusCircle\",\"plusSquare\",\"print\",\"profile\",\"profileCircle\",\"questionCircle\",\"questionSquare\",\"range\",\"reload\",\"ribbon\",\"right\",\"schedule\",\"scheduleCheck\",\"scheduleHistorico\",\"search\",\"secure\",\"share\",\"siren\",\"sound\",\"soundOff\",\"subItem\",\"swap\",\"target\",\"team\",\"telegram\",\"twitter\",\"unLink\",\"unSecure\",\"unity\",\"unlike\",\"up\",\"upload\",\"verticalList\",\"viewFalse\",\"viewTrue\",\"weight\",\"whatsapp\",\"wifi\",\"wifiOff\",\"youtube\",\"zoomIn\",\"zoomOut\"];",":host {\n display: block;\n padding: 24px;\n font-family: 'Roboto', Arial, Helvetica, sans-serif;\n}\n\n.iconDetail {\n display: block;\n}\n\n.iconSizes {\n display: flex;\n align-items: center;\n\n\n .size {\n display: flex;\n flex-direction: column;\n text-align: center;\n align-items: center;\n margin-right: 9px;\n padding: 8px;\n\n &:last-child { margin-right: 0; }\n span {\n font-size: 10px;\n margin: 8px 0;\n }\n }\n\n &.invert {\n margin-top: 12px;\n\n .size {\n background-color: #2d2d2d;\n color: #F6F6F6;\n border-radius: 3px;\n }\n }\n}\n\n.icons {\n margin-top: 28px;\n display: flex;\n flex-wrap: wrap;\n position: relative;\n\n .icon {\n position: relative;\n padding: 4px;\n cursor: pointer;\n opacity: .6;\n transition: opacity .2s linear;\n width: 105px;\n display: flex;\n flex-direction: column;\n text-align: center;\n align-items: center;\n margin-bottom: 16px;\n box-sizing: border-box;\n cura-label {\n margin-top: 8px;\n }\n cura-paragraph {\n margin-top: 4px;\n }\n /* &.selected {\n transform: scale(1.2);\n } */\n }\n}\n\n","import { Component, Host, h, State } from '@stencil/core';\nimport iconsetdefaulticons from '../../assets/icons/iconset-default-list';\nimport { microIcons, iconSizes } from '../cura-icon/cura-icon.definitions';\n\n@Component({\n tag: 'cura-icons-view',\n styleUrl: 'cura-icons-view.scss',\n shadow: true,\n})\nexport class CuraIconsView {\n\n sizes = Object.keys(iconSizes).filter(key => key !== 'default');\n colors = ['primary', 'secondary', 'accent', 'info', 'warning', 'error', 'success', 'neutral'];\n @State() selected = iconsetdefaulticons[0];\n\n connectedCallback() {\n this.sizes.unshift(this.sizes.pop());\n }\n\n setSelected = (icon) => {\n this.selected = icon;\n }\n\n render() {\n return (\n <Host>\n <div class=\"iconDetail\">\n <cura-heading size=\"small\" margin-block=\"0 24px\">Icon: <b>{ this.selected }</b></cura-heading>\n <div class=\"iconSizes\">\n { this.sizes.map( size =>\n size === 'micro' && !microIcons.includes(this.selected) ? '' :\n <div class=\"size\">\n <cura-icon name={this.selected} size={size}></cura-icon>\n <span>{ size }</span>\n </div>\n )}\n </div>\n <div class=\"iconSizes invert\">\n { this.sizes.map( size =>\n size === 'micro' && !microIcons.includes(this.selected) ? '' :\n <div class=\"size\">\n <cura-icon name={this.selected} size={size} color=\"neutral-white\"></cura-icon>\n <span>{ size }</span>\n </div>\n )}\n </div>\n </div>\n <div class=\"icons\">\n { iconsetdefaulticons.map(icon =>\n <div class={{icon: true, selected: icon === this.selected }} onClick={() => this.setSelected(icon)}>\n <cura-icon\n name={icon}\n size=\"32\"\n color={icon === this.selected ? 'accent-dark' : 'neutral-dark'}></cura-icon>\n <cura-label\n size=\"xsmall\"\n weight={icon === this.selected ? 'bold' : 'regular'}\n color={icon === this.selected ? 'accent-dark' : 'neutral-dark'}>{icon}</cura-label>\n { !microIcons.includes(icon) ? '' :\n <cura-paragraph\n color='success-dark'\n size=\"xsmall\"\n margin-block=\"0px\"\n line-height='100%'>MICRO</cura-paragraph>\n }\n </div>\n )}\n </div>\n </Host>\n );\n }\n\n}\n"],"mappings":"mJAAA,IAAAA,oBAAe,CAAC,MAAM,gBAAgB,UAAU,UAAU,cAAc,gBAAgB,YAAY,kBAAkB,YAAY,kBAAkB,aAAa,mBAAmB,UAAU,gBAAgB,SAAS,UAAU,UAAU,WAAW,aAAa,WAAW,MAAM,SAAS,UAAU,aAAa,QAAQ,aAAa,cAAc,cAAc,QAAQ,QAAQ,cAAc,WAAW,SAAS,WAAW,SAAS,UAAU,MAAM,OAAO,WAAW,YAAY,OAAO,OAAO,UAAU,SAAS,WAAW,UAAU,UAAU,UAAU,UAAU,aAAa,UAAU,SAAS,aAAa,UAAU,SAAS,cAAc,mBAAmB,SAAS,QAAQ,aAAa,QAAQ,SAAS,UAAU,OAAO,iBAAiB,UAAU,aAAa,YAAY,MAAM,OAAO,WAAW,YAAY,aAAa,aAAa,SAAS,OAAO,OAAO,OAAO,eAAe,WAAW,OAAO,QAAQ,SAAS,OAAO,cAAc,SAAS,WAAW,SAAS,UAAU,UAAU,iBAAiB,YAAY,gBAAgB,MAAM,SAAS,QAAQ,cAAc,cAAc,SAAS,OAAO,eAAe,aAAa,UAAU,UAAU,UAAU,aAAa,QAAQ,UAAU,QAAQ,OAAO,OAAO,aAAa,aAAa,QAAQ,UAAU,gBAAgB,iBAAiB,iBAAiB,QAAQ,SAAS,SAAS,QAAQ,WAAW,gBAAgB,oBAAoB,SAAS,SAAS,QAAQ,QAAQ,QAAQ,WAAW,UAAU,OAAO,SAAS,OAAO,WAAW,UAAU,SAAS,WAAW,QAAQ,SAAS,KAAK,SAAS,eAAe,YAAY,WAAW,SAAS,WAAW,OAAO,UAAU,UAAU,SAAS,WCAhmD,IAAMC,iBAAmB,0nC,ICSZC,cAAa,W,kDAExBC,KAAAC,MAAQC,OAAOC,KAAKC,WAAWC,QAAO,SAAAC,GAAO,OAAAA,IAAQ,SAAR,IAC7CN,KAAAO,OAAS,CAAC,UAAW,YAAa,SAAU,OAAQ,UAAW,QAAS,UAAW,WAOnFP,KAAAQ,YAAc,SAACC,GACbC,EAAKC,SAAWF,C,gBAPEZ,oBAAoB,E,CAExCE,EAAAa,UAAAC,kBAAA,WACEb,KAAKC,MAAMa,QAAQd,KAAKC,MAAMc,M,EAOhChB,EAAAa,UAAAI,OAAA,eAAAN,EAAAV,KACE,OACEiB,EAACC,KAAI,KACHD,EAAA,OAAKE,MAAM,cACTF,EAAA,gBAAcG,KAAK,QAAO,eAAc,UAAQ,SAAOH,EAAA,SAAKjB,KAAKW,WACjEM,EAAA,OAAKE,MAAM,aACPnB,KAAKC,MAAMoB,KAAK,SAAAD,GAChB,OAAAA,IAAS,UAAYE,WAAWC,SAASb,EAAKC,UAAY,GAC1DM,EAAA,OAAKE,MAAM,QACTF,EAAA,aAAWO,KAAMd,EAAKC,SAAUS,KAAMA,IACtCH,EAAA,YAAQG,GAHV,KAOJH,EAAA,OAAKE,MAAM,oBACPnB,KAAKC,MAAMoB,KAAK,SAAAD,GAChB,OAAAA,IAAS,UAAYE,WAAWC,SAASb,EAAKC,UAAY,GAC1DM,EAAA,OAAKE,MAAM,QACTF,EAAA,aAAWO,KAAMd,EAAKC,SAAUS,KAAMA,EAAMK,MAAM,kBAClDR,EAAA,YAAQG,GAHV,MAQNH,EAAA,OAAKE,MAAM,SACPtB,oBAAoBwB,KAAI,SAAAZ,GACxB,OAAAQ,EAAA,OAAKE,MAAO,CAACV,KAAM,KAAME,SAAUF,IAASC,EAAKC,UAAYe,QAAS,WAAM,OAAAhB,EAAKF,YAAYC,EAAjB,GAC1EQ,EAAA,aACEO,KAAMf,EACNW,KAAK,KACLK,MAAOhB,IAASC,EAAKC,SAAW,cAAgB,iBAClDM,EAAA,cACEG,KAAK,SACLO,OAAQlB,IAASC,EAAKC,SAAW,OAAS,UAC1Cc,MAAOhB,IAASC,EAAKC,SAAW,cAAgB,gBAAiBF,IAChEa,WAAWC,SAASd,GAAQ,GAC7BQ,EAAA,kBACEQ,MAAM,eACNL,KAAK,SAAQ,eACA,MAAK,cACN,QAAM,SAdxB,K,WAxCc,G"}
@@ -0,0 +1,2 @@
1
+ var __extends=this&&this.__extends||function(){var t=function(e,r){t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var r in e)if(Object.prototype.hasOwnProperty.call(e,r))t[r]=e[r]};return t(e,r)};return function(e,r){if(typeof r!=="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function i(){this.constructor=e}e.prototype=r===null?Object.create(r):(i.prototype=r.prototype,new i)}}();var __assign=this&&this.__assign||function(){__assign=Object.assign||function(t){for(var e,r=1,i=arguments.length;r<i;r++){e=arguments[r];for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n))t[n]=e[n]}return t};return __assign.apply(this,arguments)};var __rest=this&&this.__rest||function(t,e){var r={};for(var i in t)if(Object.prototype.hasOwnProperty.call(t,i)&&e.indexOf(i)<0)r[i]=t[i];if(t!=null&&typeof Object.getOwnPropertySymbols==="function")for(var n=0,i=Object.getOwnPropertySymbols(t);n<i.length;n++){if(e.indexOf(i[n])<0&&Object.prototype.propertyIsEnumerable.call(t,i[n]))r[i[n]]=t[i[n]]}return r};var __spreadArray=this&&this.__spreadArray||function(t,e,r){if(r||arguments.length===2)for(var i=0,n=e.length,a;i<n;i++){if(a||!(i in e)){if(!a)a=Array.prototype.slice.call(e,0,i);a[i]=e[i]}}return t.concat(a||Array.prototype.slice.call(e))};import{r as registerInstance,c as createEvent,h,H as Host}from"./index-81f1a268.js";function isString(t){return typeof t==="string"||t instanceof String}function isObject(t){var e;return typeof t==="object"&&t!=null&&(t==null||(e=t.constructor)==null?void 0:e.name)==="Object"}function pick(t,e){if(Array.isArray(e))return pick(t,(function(t,r){return e.includes(r)}));return Object.entries(t).reduce((function(t,r){var i=r[0],n=r[1];if(e(n,i))t[i]=n;return t}),{})}var DIRECTION={NONE:"NONE",LEFT:"LEFT",FORCE_LEFT:"FORCE_LEFT",RIGHT:"RIGHT",FORCE_RIGHT:"FORCE_RIGHT"};function forceDirection(t){switch(t){case DIRECTION.LEFT:return DIRECTION.FORCE_LEFT;case DIRECTION.RIGHT:return DIRECTION.FORCE_RIGHT;default:return t}}function escapeRegExp(t){return t.replace(/([.*+?^=!:${}()|[\]/\\])/g,"\\$1")}function objectIncludes(t,e){if(e===t)return true;var r=Array.isArray(e),i=Array.isArray(t);var n;if(r&&i){if(e.length!=t.length)return false;for(n=0;n<e.length;n++)if(!objectIncludes(e[n],t[n]))return false;return true}if(r!=i)return false;if(e&&t&&typeof e==="object"&&typeof t==="object"){var a=e instanceof Date,s=t instanceof Date;if(a&&s)return e.getTime()==t.getTime();if(a!=s)return false;var u=e instanceof RegExp,o=t instanceof RegExp;if(u&&o)return e.toString()==t.toString();if(u!=o)return false;var l=Object.keys(e);for(n=0;n<l.length;n++)if(!Object.prototype.hasOwnProperty.call(t,l[n]))return false;for(n=0;n<l.length;n++)if(!objectIncludes(t[l[n]],e[l[n]]))return false;return true}else if(e&&t&&typeof e==="function"&&typeof t==="function"){return e.toString()===t.toString()}return false}var ActionDetails=function(){function t(t){Object.assign(this,t);while(this.value.slice(0,this.startChangePos)!==this.oldValue.slice(0,this.startChangePos)){--this.oldSelection.start}if(this.insertedCount){while(this.value.slice(this.cursorPos)!==this.oldValue.slice(this.oldSelection.end)){if(this.value.length-this.cursorPos<this.oldValue.length-this.oldSelection.end)++this.oldSelection.end;else++this.cursorPos}}}Object.defineProperty(t.prototype,"startChangePos",{get:function(){return Math.min(this.cursorPos,this.oldSelection.start)},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"insertedCount",{get:function(){return this.cursorPos-this.startChangePos},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"inserted",{get:function(){return this.value.substr(this.startChangePos,this.insertedCount)},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"removedCount",{get:function(){return Math.max(this.oldSelection.end-this.startChangePos||this.oldValue.length-this.value.length,0)},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"removed",{get:function(){return this.oldValue.substr(this.startChangePos,this.removedCount)},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"head",{get:function(){return this.value.substring(0,this.startChangePos)},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"tail",{get:function(){return this.value.substring(this.startChangePos+this.insertedCount)},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"removeDirection",{get:function(){if(!this.removedCount||this.insertedCount)return DIRECTION.NONE;return(this.oldSelection.end===this.cursorPos||this.oldSelection.start===this.cursorPos)&&this.oldSelection.end===this.oldSelection.start?DIRECTION.RIGHT:DIRECTION.LEFT},enumerable:false,configurable:true});return t}();function IMask(t,e){return new IMask.InputMask(t,e)}function maskedClass(t){if(t==null)throw new Error("mask property should be defined");if(t instanceof RegExp)return IMask.MaskedRegExp;if(isString(t))return IMask.MaskedPattern;if(t===Date)return IMask.MaskedDate;if(t===Number)return IMask.MaskedNumber;if(Array.isArray(t)||t===Array)return IMask.MaskedDynamic;if(IMask.Masked&&t.prototype instanceof IMask.Masked)return t;if(IMask.Masked&&t instanceof IMask.Masked)return t.constructor;if(t instanceof Function)return IMask.MaskedFunction;console.warn("Mask not found for mask",t);return IMask.Masked}function normalizeOpts(t){if(!t)throw new Error("Options in not defined");if(IMask.Masked){if(t.prototype instanceof IMask.Masked)return{mask:t};var e=t instanceof IMask.Masked?{mask:t}:isObject(t)&&t.mask instanceof IMask.Masked?t:{},r=e.mask,i=r===void 0?undefined:r,n=__rest(e,["mask"]);if(i){var a=i.mask;return __assign(__assign(__assign({},pick(i,(function(t,e){return!e.startsWith("_")}))),{mask:i.constructor,_mask:a}),n)}}if(!isObject(t))return{mask:t};return __assign({},t)}function createMask(t){if(IMask.Masked&&t instanceof IMask.Masked)return t;var e=normalizeOpts(t);var r=maskedClass(e.mask);if(!r)throw new Error("Masked class is not found for provided mask "+e.mask+", appropriate module needs to be imported manually before creating mask.");if(e.mask===r)delete e.mask;if(e._mask){e.mask=e._mask;delete e._mask}return new r(e)}IMask.createMask=createMask;var MaskElement=function(){function t(){}Object.defineProperty(t.prototype,"selectionStart",{get:function(){var t;try{t=this._unsafeSelectionStart}catch(t){}return t!=null?t:this.value.length},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"selectionEnd",{get:function(){var t;try{t=this._unsafeSelectionEnd}catch(t){}return t!=null?t:this.value.length},enumerable:false,configurable:true});t.prototype.select=function(t,e){if(t==null||e==null||t===this.selectionStart&&e===this.selectionEnd)return;try{this._unsafeSelect(t,e)}catch(t){}};Object.defineProperty(t.prototype,"isActive",{get:function(){return false},enumerable:false,configurable:true});return t}();IMask.MaskElement=MaskElement;var KEY_Z=90;var KEY_Y=89;var HTMLMaskElement=function(t){__extends(e,t);function e(e){var r=t.call(this)||this;r.input=e;r._onKeydown=r._onKeydown.bind(r);r._onInput=r._onInput.bind(r);r._onBeforeinput=r._onBeforeinput.bind(r);r._onCompositionEnd=r._onCompositionEnd.bind(r);return r}Object.defineProperty(e.prototype,"rootElement",{get:function(){var t,e,r;return(t=(e=(r=this.input).getRootNode)==null?void 0:e.call(r))!=null?t:document},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"isActive",{get:function(){return this.input===this.rootElement.activeElement},enumerable:false,configurable:true});e.prototype.bindEvents=function(t){this.input.addEventListener("keydown",this._onKeydown);this.input.addEventListener("input",this._onInput);this.input.addEventListener("beforeinput",this._onBeforeinput);this.input.addEventListener("compositionend",this._onCompositionEnd);this.input.addEventListener("drop",t.drop);this.input.addEventListener("click",t.click);this.input.addEventListener("focus",t.focus);this.input.addEventListener("blur",t.commit);this._handlers=t};e.prototype._onKeydown=function(t){if(this._handlers.redo&&(t.keyCode===KEY_Z&&t.shiftKey&&(t.metaKey||t.ctrlKey)||t.keyCode===KEY_Y&&t.ctrlKey)){t.preventDefault();return this._handlers.redo(t)}if(this._handlers.undo&&t.keyCode===KEY_Z&&(t.metaKey||t.ctrlKey)){t.preventDefault();return this._handlers.undo(t)}if(!t.isComposing)this._handlers.selectionChange(t)};e.prototype._onBeforeinput=function(t){if(t.inputType==="historyUndo"&&this._handlers.undo){t.preventDefault();return this._handlers.undo(t)}if(t.inputType==="historyRedo"&&this._handlers.redo){t.preventDefault();return this._handlers.redo(t)}};e.prototype._onCompositionEnd=function(t){this._handlers.input(t)};e.prototype._onInput=function(t){if(!t.isComposing)this._handlers.input(t)};e.prototype.unbindEvents=function(){this.input.removeEventListener("keydown",this._onKeydown);this.input.removeEventListener("input",this._onInput);this.input.removeEventListener("beforeinput",this._onBeforeinput);this.input.removeEventListener("compositionend",this._onCompositionEnd);this.input.removeEventListener("drop",this._handlers.drop);this.input.removeEventListener("click",this._handlers.click);this.input.removeEventListener("focus",this._handlers.focus);this.input.removeEventListener("blur",this._handlers.commit);this._handlers={}};return e}(MaskElement);IMask.HTMLMaskElement=HTMLMaskElement;var HTMLInputMaskElement=function(t){__extends(e,t);function e(e){var r=t.call(this,e)||this;r.input=e;return r}Object.defineProperty(e.prototype,"_unsafeSelectionStart",{get:function(){return this.input.selectionStart!=null?this.input.selectionStart:this.value.length},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"_unsafeSelectionEnd",{get:function(){return this.input.selectionEnd},enumerable:false,configurable:true});e.prototype._unsafeSelect=function(t,e){this.input.setSelectionRange(t,e)};Object.defineProperty(e.prototype,"value",{get:function(){return this.input.value},set:function(t){this.input.value=t},enumerable:false,configurable:true});return e}(HTMLMaskElement);IMask.HTMLMaskElement=HTMLMaskElement;var HTMLContenteditableMaskElement=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}Object.defineProperty(e.prototype,"_unsafeSelectionStart",{get:function(){var t=this.rootElement;var e=t.getSelection&&t.getSelection();var r=e&&e.anchorOffset;var i=e&&e.focusOffset;if(i==null||r==null||r<i){return r}return i},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"_unsafeSelectionEnd",{get:function(){var t=this.rootElement;var e=t.getSelection&&t.getSelection();var r=e&&e.anchorOffset;var i=e&&e.focusOffset;if(i==null||r==null||r>i){return r}return i},enumerable:false,configurable:true});e.prototype._unsafeSelect=function(t,e){if(!this.rootElement.createRange)return;var r=this.rootElement.createRange();r.setStart(this.input.firstChild||this.input,t);r.setEnd(this.input.lastChild||this.input,e);var i=this.rootElement;var n=i.getSelection&&i.getSelection();if(n){n.removeAllRanges();n.addRange(r)}};Object.defineProperty(e.prototype,"value",{get:function(){return this.input.textContent||""},set:function(t){this.input.textContent=t},enumerable:false,configurable:true});return e}(HTMLMaskElement);IMask.HTMLContenteditableMaskElement=HTMLContenteditableMaskElement;var InputHistory=function(){function t(){this.states=[];this.currentIndex=0}Object.defineProperty(t.prototype,"currentState",{get:function(){return this.states[this.currentIndex]},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"isEmpty",{get:function(){return this.states.length===0},enumerable:false,configurable:true});t.prototype.push=function(e){if(this.currentIndex<this.states.length-1)this.states.length=this.currentIndex+1;this.states.push(e);if(this.states.length>t.MAX_LENGTH)this.states.shift();this.currentIndex=this.states.length-1};t.prototype.go=function(t){this.currentIndex=Math.min(Math.max(this.currentIndex+t,0),this.states.length-1);return this.currentState};t.prototype.undo=function(){return this.go(-1)};t.prototype.redo=function(){return this.go(+1)};t.prototype.clear=function(){this.states.length=0;this.currentIndex=0};return t}();InputHistory.MAX_LENGTH=100;var InputMask=function(){function t(t,e){this.el=t instanceof MaskElement?t:t.isContentEditable&&t.tagName!=="INPUT"&&t.tagName!=="TEXTAREA"?new HTMLContenteditableMaskElement(t):new HTMLInputMaskElement(t);this.masked=createMask(e);this._listeners={};this._value="";this._unmaskedValue="";this._rawInputValue="";this.history=new InputHistory;this._saveSelection=this._saveSelection.bind(this);this._onInput=this._onInput.bind(this);this._onChange=this._onChange.bind(this);this._onDrop=this._onDrop.bind(this);this._onFocus=this._onFocus.bind(this);this._onClick=this._onClick.bind(this);this._onUndo=this._onUndo.bind(this);this._onRedo=this._onRedo.bind(this);this.alignCursor=this.alignCursor.bind(this);this.alignCursorFriendly=this.alignCursorFriendly.bind(this);this._bindEvents();this.updateValue();this._onChange()}t.prototype.maskEquals=function(t){var e;return t==null||((e=this.masked)==null?void 0:e.maskEquals(t))};Object.defineProperty(t.prototype,"mask",{get:function(){return this.masked.mask},set:function(t){if(this.maskEquals(t))return;if(!(t instanceof IMask.Masked)&&this.masked.constructor===maskedClass(t)){this.masked.updateOptions({mask:t});return}var e=t instanceof IMask.Masked?t:createMask({mask:t});e.unmaskedValue=this.masked.unmaskedValue;this.masked=e},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"value",{get:function(){return this._value},set:function(t){if(this.value===t)return;this.masked.value=t;this.updateControl("auto")},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"unmaskedValue",{get:function(){return this._unmaskedValue},set:function(t){if(this.unmaskedValue===t)return;this.masked.unmaskedValue=t;this.updateControl("auto")},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"rawInputValue",{get:function(){return this._rawInputValue},set:function(t){if(this.rawInputValue===t)return;this.masked.rawInputValue=t;this.updateControl();this.alignCursor()},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"typedValue",{get:function(){return this.masked.typedValue},set:function(t){if(this.masked.typedValueEquals(t))return;this.masked.typedValue=t;this.updateControl("auto")},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"displayValue",{get:function(){return this.masked.displayValue},enumerable:false,configurable:true});t.prototype._bindEvents=function(){this.el.bindEvents({selectionChange:this._saveSelection,input:this._onInput,drop:this._onDrop,click:this._onClick,focus:this._onFocus,commit:this._onChange,undo:this._onUndo,redo:this._onRedo})};t.prototype._unbindEvents=function(){if(this.el)this.el.unbindEvents()};t.prototype._fireEvent=function(t,e){var r=this._listeners[t];if(!r)return;r.forEach((function(t){return t(e)}))};Object.defineProperty(t.prototype,"selectionStart",{get:function(){return this._cursorChanging?this._changingCursorPos:this.el.selectionStart},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"cursorPos",{get:function(){return this._cursorChanging?this._changingCursorPos:this.el.selectionEnd},set:function(t){if(!this.el||!this.el.isActive)return;this.el.select(t,t);this._saveSelection()},enumerable:false,configurable:true});t.prototype._saveSelection=function(){if(this.displayValue!==this.el.value){console.warn("Element value was changed outside of mask. Syncronize mask using `mask.updateValue()` to work properly.")}this._selection={start:this.selectionStart,end:this.cursorPos}};t.prototype.updateValue=function(){this.masked.value=this.el.value;this._value=this.masked.value;this._unmaskedValue=this.masked.unmaskedValue;this._rawInputValue=this.masked.rawInputValue};t.prototype.updateControl=function(t){var e=this.masked.unmaskedValue;var r=this.masked.value;var i=this.masked.rawInputValue;var n=this.displayValue;var a=this.unmaskedValue!==e||this.value!==r||this._rawInputValue!==i;this._unmaskedValue=e;this._value=r;this._rawInputValue=i;if(this.el.value!==n)this.el.value=n;if(t==="auto")this.alignCursor();else if(t!=null)this.cursorPos=t;if(a)this._fireChangeEvents();if(!this._historyChanging&&(a||this.history.isEmpty))this.history.push({unmaskedValue:e,selection:{start:this.selectionStart,end:this.cursorPos}})};t.prototype.updateOptions=function(t){var e=t.mask,r=__rest(t,["mask"]);var i=!this.maskEquals(e);var n=this.masked.optionsIsChanged(r);if(i)this.mask=e;if(n)this.masked.updateOptions(r);if(i||n)this.updateControl()};t.prototype.updateCursor=function(t){if(t==null)return;this.cursorPos=t;this._delayUpdateCursor(t)};t.prototype._delayUpdateCursor=function(t){var e=this;this._abortUpdateCursor();this._changingCursorPos=t;this._cursorChanging=setTimeout((function(){if(!e.el)return;e.cursorPos=e._changingCursorPos;e._abortUpdateCursor()}),10)};t.prototype._fireChangeEvents=function(){this._fireEvent("accept",this._inputEvent);if(this.masked.isComplete)this._fireEvent("complete",this._inputEvent)};t.prototype._abortUpdateCursor=function(){if(this._cursorChanging){clearTimeout(this._cursorChanging);delete this._cursorChanging}};t.prototype.alignCursor=function(){this.cursorPos=this.masked.nearestInputPos(this.masked.nearestInputPos(this.cursorPos,DIRECTION.LEFT))};t.prototype.alignCursorFriendly=function(){if(this.selectionStart!==this.cursorPos)return;this.alignCursor()};t.prototype.on=function(t,e){if(!this._listeners[t])this._listeners[t]=[];this._listeners[t].push(e);return this};t.prototype.off=function(t,e){if(!this._listeners[t])return this;if(!e){delete this._listeners[t];return this}var r=this._listeners[t].indexOf(e);if(r>=0)this._listeners[t].splice(r,1);return this};t.prototype._onInput=function(t){this._inputEvent=t;this._abortUpdateCursor();var e=new ActionDetails({value:this.el.value,cursorPos:this.cursorPos,oldValue:this.displayValue,oldSelection:this._selection});var r=this.masked.rawInputValue;var i=this.masked.splice(e.startChangePos,e.removed.length,e.inserted,e.removeDirection,{input:true,raw:true}).offset;var n=r===this.masked.rawInputValue?e.removeDirection:DIRECTION.NONE;var a=this.masked.nearestInputPos(e.startChangePos+i,n);if(n!==DIRECTION.NONE)a=this.masked.nearestInputPos(a,DIRECTION.NONE);this.updateControl(a);delete this._inputEvent};t.prototype._onChange=function(){if(this.displayValue!==this.el.value)this.updateValue();this.masked.doCommit();this.updateControl();this._saveSelection()};t.prototype._onDrop=function(t){t.preventDefault();t.stopPropagation()};t.prototype._onFocus=function(t){this.alignCursorFriendly()};t.prototype._onClick=function(t){this.alignCursorFriendly()};t.prototype._onUndo=function(){this._applyHistoryState(this.history.undo())};t.prototype._onRedo=function(){this._applyHistoryState(this.history.redo())};t.prototype._applyHistoryState=function(t){if(!t)return;this._historyChanging=true;this.unmaskedValue=t.unmaskedValue;this.el.select(t.selection.start,t.selection.end);this._saveSelection();this._historyChanging=false};t.prototype.destroy=function(){this._unbindEvents();this._listeners.length=0;delete this.el};return t}();IMask.InputMask=InputMask;var ChangeDetails=function(){function t(t){Object.assign(this,{inserted:"",rawInserted:"",tailShift:0,skip:false},t)}t.normalize=function(e){return Array.isArray(e)?e:[e,new t]};t.prototype.aggregate=function(t){this.inserted+=t.inserted;this.rawInserted+=t.rawInserted;this.tailShift+=t.tailShift;this.skip=this.skip||t.skip;return this};Object.defineProperty(t.prototype,"offset",{get:function(){return this.tailShift+this.inserted.length},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"consumed",{get:function(){return Boolean(this.rawInserted)||this.skip},enumerable:false,configurable:true});t.prototype.equals=function(t){return this.inserted===t.inserted&&this.tailShift===t.tailShift&&this.rawInserted===t.rawInserted&&this.skip===t.skip};return t}();IMask.ChangeDetails=ChangeDetails;var ContinuousTailDetails=function(){function t(t,e,r){if(t===void 0){t=""}if(e===void 0){e=0}this.value=t;this.from=e;this.stop=r}t.prototype.toString=function(){return this.value};t.prototype.extend=function(t){this.value+=String(t)};t.prototype.appendTo=function(t){return t.append(this.toString(),{tail:true}).aggregate(t._appendPlaceholder())};Object.defineProperty(t.prototype,"state",{get:function(){return{value:this.value,from:this.from,stop:this.stop}},set:function(t){Object.assign(this,t)},enumerable:false,configurable:true});t.prototype.unshift=function(t){if(!this.value.length||t!=null&&this.from>=t)return"";var e=this.value[0];this.value=this.value.slice(1);return e};t.prototype.shift=function(){if(!this.value.length)return"";var t=this.value[this.value.length-1];this.value=this.value.slice(0,-1);return t};return t}();var Masked=function(){function t(e){this._value="";this._update(__assign(__assign({},t.DEFAULTS),e));this._initialized=true}t.prototype.updateOptions=function(t){if(!this.optionsIsChanged(t))return;this.withValueRefresh(this._update.bind(this,t))};t.prototype._update=function(t){Object.assign(this,t)};Object.defineProperty(t.prototype,"state",{get:function(){return{_value:this.value,_rawInputValue:this.rawInputValue}},set:function(t){this._value=t._value},enumerable:false,configurable:true});t.prototype.reset=function(){this._value=""};Object.defineProperty(t.prototype,"value",{get:function(){return this._value},set:function(t){this.resolve(t,{input:true})},enumerable:false,configurable:true});t.prototype.resolve=function(t,e){if(e===void 0){e={input:true}}this.reset();this.append(t,e,"");this.doCommit()};Object.defineProperty(t.prototype,"unmaskedValue",{get:function(){return this.value},set:function(t){this.resolve(t,{})},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"typedValue",{get:function(){return this.parse?this.parse(this.value,this):this.unmaskedValue},set:function(t){if(this.format){this.value=this.format(t,this)}else{this.unmaskedValue=String(t)}},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"rawInputValue",{get:function(){return this.extractInput(0,this.displayValue.length,{raw:true})},set:function(t){this.resolve(t,{raw:true})},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"displayValue",{get:function(){return this.value},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"isComplete",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"isFilled",{get:function(){return this.isComplete},enumerable:false,configurable:true});t.prototype.nearestInputPos=function(t,e){return t};t.prototype.totalInputPositions=function(t,e){if(t===void 0){t=0}if(e===void 0){e=this.displayValue.length}return Math.min(this.displayValue.length,e-t)};t.prototype.extractInput=function(t,e,r){if(t===void 0){t=0}if(e===void 0){e=this.displayValue.length}return this.displayValue.slice(t,e)};t.prototype.extractTail=function(t,e){if(t===void 0){t=0}if(e===void 0){e=this.displayValue.length}return new ContinuousTailDetails(this.extractInput(t,e),t)};t.prototype.appendTail=function(t){if(isString(t))t=new ContinuousTailDetails(String(t));return t.appendTo(this)};t.prototype._appendCharRaw=function(t,e){if(!t)return new ChangeDetails;this._value+=t;return new ChangeDetails({inserted:t,rawInserted:t})};t.prototype._appendChar=function(t,e,r){var i;if(e===void 0){e={}}var n=this.state;var a;i=this.doPrepareChar(t,e),t=i[0],a=i[1];if(t){a=a.aggregate(this._appendCharRaw(t,e));if(!a.rawInserted&&this.autofix==="pad"){var s=this.state;this.state=n;var u=this.pad(e);var o=this._appendCharRaw(t,e);u=u.aggregate(o);if(o.rawInserted||u.equals(a)){a=u}else{this.state=s}}}if(a.inserted){var l=void 0;var p=this.doValidate(e)!==false;if(p&&r!=null){var h=this.state;if(this.overwrite===true){l=r.state;for(var c=0;c<a.rawInserted.length;++c){r.unshift(this.displayValue.length-a.tailShift)}}var d=this.appendTail(r);p=d.rawInserted.length===r.toString().length;if(!(p&&d.inserted)&&this.overwrite==="shift"){this.state=h;l=r.state;for(var c=0;c<a.rawInserted.length;++c){r.shift()}d=this.appendTail(r);p=d.rawInserted.length===r.toString().length}if(p&&d.inserted)this.state=h}if(!p){a=new ChangeDetails;this.state=n;if(r&&l)r.state=l}}return a};t.prototype._appendPlaceholder=function(){return new ChangeDetails};t.prototype._appendEager=function(){return new ChangeDetails};t.prototype.append=function(t,e,r){var i;if(!isString(t))throw new Error("value should be string");var n=isString(r)?new ContinuousTailDetails(String(r)):r;if(e!=null&&e.tail)e._beforeTailState=this.state;var a;i=this.doPrepare(t,e),t=i[0],a=i[1];for(var s=0;s<t.length;++s){var u=this._appendChar(t[s],e,n);if(!u.rawInserted&&!this.doSkipInvalid(t[s],e,n))break;a.aggregate(u)}if((this.eager===true||this.eager==="append")&&e!=null&&e.input&&t){a.aggregate(this._appendEager())}if(n!=null){a.tailShift+=this.appendTail(n).tailShift}return a};t.prototype.remove=function(t,e){if(t===void 0){t=0}if(e===void 0){e=this.displayValue.length}this._value=this.displayValue.slice(0,t)+this.displayValue.slice(e);return new ChangeDetails};t.prototype.withValueRefresh=function(t){if(this._refreshing||!this._initialized)return t();this._refreshing=true;var e=this.rawInputValue;var r=this.value;var i=t();this.rawInputValue=e;if(this.value&&this.value!==r&&r.indexOf(this.value)===0){this.append(r.slice(this.displayValue.length),{},"");this.doCommit()}delete this._refreshing;return i};t.prototype.runIsolated=function(t){if(this._isolated||!this._initialized)return t(this);this._isolated=true;var e=this.state;var r=t(this);this.state=e;delete this._isolated;return r};t.prototype.doSkipInvalid=function(t,e,r){return Boolean(this.skipInvalid)};t.prototype.doPrepare=function(t,e){if(e===void 0){e={}}return ChangeDetails.normalize(this.prepare?this.prepare(t,this,e):t)};t.prototype.doPrepareChar=function(t,e){if(e===void 0){e={}}return ChangeDetails.normalize(this.prepareChar?this.prepareChar(t,this,e):t)};t.prototype.doValidate=function(t){return(!this.validate||this.validate(this.value,this,t))&&(!this.parent||this.parent.doValidate(t))};t.prototype.doCommit=function(){if(this.commit)this.commit(this.value,this)};t.prototype.splice=function(t,e,r,i,n){if(r===void 0){r=""}if(i===void 0){i=DIRECTION.NONE}if(n===void 0){n={input:true}}var a=t+e;var s=this.extractTail(a);var u=this.eager===true||this.eager==="remove";var o;if(u){i=forceDirection(i);o=this.extractInput(0,a,{raw:true})}var l=t;var p=new ChangeDetails;if(i!==DIRECTION.NONE){l=this.nearestInputPos(t,e>1&&t!==0&&!u?DIRECTION.NONE:i);p.tailShift=l-t}p.aggregate(this.remove(l));if(u&&i!==DIRECTION.NONE&&o===this.rawInputValue){if(i===DIRECTION.FORCE_LEFT){var h=void 0;while(o===this.rawInputValue&&(h=this.displayValue.length)){p.aggregate(new ChangeDetails({tailShift:-1})).aggregate(this.remove(h-1))}}else if(i===DIRECTION.FORCE_RIGHT){s.unshift()}}return p.aggregate(this.append(r,n,s))};t.prototype.maskEquals=function(t){return this.mask===t};t.prototype.optionsIsChanged=function(t){return!objectIncludes(this,t)};t.prototype.typedValueEquals=function(e){var r=this.typedValue;return e===r||t.EMPTY_VALUES.includes(e)&&t.EMPTY_VALUES.includes(r)||(this.format?this.format(e,this)===this.format(this.typedValue,this):false)};t.prototype.pad=function(t){return new ChangeDetails};return t}();Masked.DEFAULTS={skipInvalid:true};Masked.EMPTY_VALUES=[undefined,null,""];IMask.Masked=Masked;var ChunksTailDetails=function(){function t(t,e){if(t===void 0){t=[]}if(e===void 0){e=0}this.chunks=t;this.from=e}t.prototype.toString=function(){return this.chunks.map(String).join("")};t.prototype.extend=function(e){if(!String(e))return;e=isString(e)?new ContinuousTailDetails(String(e)):e;var r=this.chunks[this.chunks.length-1];var i=r&&(r.stop===e.stop||e.stop==null)&&e.from===r.from+r.toString().length;if(e instanceof ContinuousTailDetails){if(i){r.extend(e.toString())}else{this.chunks.push(e)}}else if(e instanceof t){if(e.stop==null){var n=void 0;while(e.chunks.length&&e.chunks[0].stop==null){n=e.chunks.shift();n.from+=e.from;this.extend(n)}}if(e.toString()){e.stop=e.blockIndex;this.chunks.push(e)}}};t.prototype.appendTo=function(e){if(!(e instanceof IMask.MaskedPattern)){var r=new ContinuousTailDetails(this.toString());return r.appendTo(e)}var i=new ChangeDetails;for(var n=0;n<this.chunks.length;++n){var a=this.chunks[n];var s=e._mapPosToBlock(e.displayValue.length);var u=a.stop;var o=void 0;if(u!=null&&(!s||s.index<=u)){if(a instanceof t||e._stops.indexOf(u)>=0){i.aggregate(e._appendPlaceholder(u))}o=a instanceof t&&e._blocks[u]}if(o){var l=o.appendTail(a);i.aggregate(l);var p=a.toString().slice(l.rawInserted.length);if(p)i.aggregate(e.append(p,{tail:true}))}else{i.aggregate(e.append(a.toString(),{tail:true}))}}return i};Object.defineProperty(t.prototype,"state",{get:function(){return{chunks:this.chunks.map((function(t){return t.state})),from:this.from,stop:this.stop,blockIndex:this.blockIndex}},set:function(e){var r=e.chunks,i=__rest(e,["chunks"]);Object.assign(this,i);this.chunks=r.map((function(e){var r="chunks"in e?new t:new ContinuousTailDetails;r.state=e;return r}))},enumerable:false,configurable:true});t.prototype.unshift=function(t){if(!this.chunks.length||t!=null&&this.from>=t)return"";var e=t!=null?t-this.from:t;var r=0;while(r<this.chunks.length){var i=this.chunks[r];var n=i.unshift(e);if(i.toString()){if(!n)break;++r}else{this.chunks.splice(r,1)}if(n)return n}return""};t.prototype.shift=function(){if(!this.chunks.length)return"";var t=this.chunks.length-1;while(0<=t){var e=this.chunks[t];var r=e.shift();if(e.toString()){if(!r)break;--t}else{this.chunks.splice(t,1)}if(r)return r}return""};return t}();var PatternCursor=function(){function t(t,e){this.masked=t;this._log=[];var r=t._mapPosToBlock(e)||(e<0?{index:0,offset:0}:{index:this.masked._blocks.length,offset:0}),i=r.offset,n=r.index;this.offset=i;this.index=n;this.ok=false}Object.defineProperty(t.prototype,"block",{get:function(){return this.masked._blocks[this.index]},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"pos",{get:function(){return this.masked._blockStartPos(this.index)+this.offset},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"state",{get:function(){return{index:this.index,offset:this.offset,ok:this.ok}},set:function(t){Object.assign(this,t)},enumerable:false,configurable:true});t.prototype.pushState=function(){this._log.push(this.state)};t.prototype.popState=function(){var t=this._log.pop();if(t)this.state=t;return t};t.prototype.bindBlock=function(){if(this.block)return;if(this.index<0){this.index=0;this.offset=0}if(this.index>=this.masked._blocks.length){this.index=this.masked._blocks.length-1;this.offset=this.block.displayValue.length}};t.prototype._pushLeft=function(t){this.pushState();for(this.bindBlock();0<=this.index;--this.index,this.offset=((e=this.block)==null?void 0:e.displayValue.length)||0){var e;if(t())return this.ok=true}return this.ok=false};t.prototype._pushRight=function(t){this.pushState();for(this.bindBlock();this.index<this.masked._blocks.length;++this.index,this.offset=0){if(t())return this.ok=true}return this.ok=false};t.prototype.pushLeftBeforeFilled=function(){var t=this;return this._pushLeft((function(){if(t.block.isFixed||!t.block.value)return;t.offset=t.block.nearestInputPos(t.offset,DIRECTION.FORCE_LEFT);if(t.offset!==0)return true}))};t.prototype.pushLeftBeforeInput=function(){var t=this;return this._pushLeft((function(){if(t.block.isFixed)return;t.offset=t.block.nearestInputPos(t.offset,DIRECTION.LEFT);return true}))};t.prototype.pushLeftBeforeRequired=function(){var t=this;return this._pushLeft((function(){if(t.block.isFixed||t.block.isOptional&&!t.block.value)return;t.offset=t.block.nearestInputPos(t.offset,DIRECTION.LEFT);return true}))};t.prototype.pushRightBeforeFilled=function(){var t=this;return this._pushRight((function(){if(t.block.isFixed||!t.block.value)return;t.offset=t.block.nearestInputPos(t.offset,DIRECTION.FORCE_RIGHT);if(t.offset!==t.block.value.length)return true}))};t.prototype.pushRightBeforeInput=function(){var t=this;return this._pushRight((function(){if(t.block.isFixed)return;t.offset=t.block.nearestInputPos(t.offset,DIRECTION.NONE);return true}))};t.prototype.pushRightBeforeRequired=function(){var t=this;return this._pushRight((function(){if(t.block.isFixed||t.block.isOptional&&!t.block.value)return;t.offset=t.block.nearestInputPos(t.offset,DIRECTION.NONE);return true}))};return t}();var PatternFixedDefinition=function(){function t(t){Object.assign(this,t);this._value="";this.isFixed=true}Object.defineProperty(t.prototype,"value",{get:function(){return this._value},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"unmaskedValue",{get:function(){return this.isUnmasking?this.value:""},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"rawInputValue",{get:function(){return this._isRawInput?this.value:""},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"displayValue",{get:function(){return this.value},enumerable:false,configurable:true});t.prototype.reset=function(){this._isRawInput=false;this._value=""};t.prototype.remove=function(t,e){if(t===void 0){t=0}if(e===void 0){e=this._value.length}this._value=this._value.slice(0,t)+this._value.slice(e);if(!this._value)this._isRawInput=false;return new ChangeDetails};t.prototype.nearestInputPos=function(t,e){if(e===void 0){e=DIRECTION.NONE}var r=0;var i=this._value.length;switch(e){case DIRECTION.LEFT:case DIRECTION.FORCE_LEFT:return r;case DIRECTION.NONE:case DIRECTION.RIGHT:case DIRECTION.FORCE_RIGHT:default:return i}};t.prototype.totalInputPositions=function(t,e){if(t===void 0){t=0}if(e===void 0){e=this._value.length}return this._isRawInput?e-t:0};t.prototype.extractInput=function(t,e,r){if(t===void 0){t=0}if(e===void 0){e=this._value.length}if(r===void 0){r={}}return r.raw&&this._isRawInput&&this._value.slice(t,e)||""};Object.defineProperty(t.prototype,"isComplete",{get:function(){return true},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"isFilled",{get:function(){return Boolean(this._value)},enumerable:false,configurable:true});t.prototype._appendChar=function(t,e){if(e===void 0){e={}}if(this.isFilled)return new ChangeDetails;var r=this.eager===true||this.eager==="append";var i=this.char===t;var n=i&&(this.isUnmasking||e.input||e.raw)&&(!e.raw||!r)&&!e.tail;var a=new ChangeDetails({inserted:this.char,rawInserted:n?this.char:""});this._value=this.char;this._isRawInput=n&&(e.raw||e.input);return a};t.prototype._appendEager=function(){return this._appendChar(this.char,{tail:true})};t.prototype._appendPlaceholder=function(){var t=new ChangeDetails;if(this.isFilled)return t;this._value=t.inserted=this.char;return t};t.prototype.extractTail=function(){return new ContinuousTailDetails("")};t.prototype.appendTail=function(t){if(isString(t))t=new ContinuousTailDetails(String(t));return t.appendTo(this)};t.prototype.append=function(t,e,r){var i=this._appendChar(t[0],e);if(r!=null){i.tailShift+=this.appendTail(r).tailShift}return i};t.prototype.doCommit=function(){};Object.defineProperty(t.prototype,"state",{get:function(){return{_value:this._value,_rawInputValue:this.rawInputValue}},set:function(t){this._value=t._value;this._isRawInput=Boolean(t._rawInputValue)},enumerable:false,configurable:true});t.prototype.pad=function(t){return this._appendPlaceholder()};return t}();var PatternInputDefinition=function(){function t(t){var e=t.parent,r=t.isOptional,i=t.placeholderChar,n=t.displayChar,a=t.lazy,s=t.eager,u=__rest(t,["parent","isOptional","placeholderChar","displayChar","lazy","eager"]);this.masked=createMask(u);Object.assign(this,{parent:e,isOptional:r,placeholderChar:i,displayChar:n,lazy:a,eager:s})}t.prototype.reset=function(){this.isFilled=false;this.masked.reset()};t.prototype.remove=function(t,e){if(t===void 0){t=0}if(e===void 0){e=this.value.length}if(t===0&&e>=1){this.isFilled=false;return this.masked.remove(t,e)}return new ChangeDetails};Object.defineProperty(t.prototype,"value",{get:function(){return this.masked.value||(this.isFilled&&!this.isOptional?this.placeholderChar:"")},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"unmaskedValue",{get:function(){return this.masked.unmaskedValue},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"rawInputValue",{get:function(){return this.masked.rawInputValue},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"displayValue",{get:function(){return this.masked.value&&this.displayChar||this.value},enumerable:false,configurable:true});Object.defineProperty(t.prototype,"isComplete",{get:function(){return Boolean(this.masked.value)||this.isOptional},enumerable:false,configurable:true});t.prototype._appendChar=function(t,e){if(e===void 0){e={}}if(this.isFilled)return new ChangeDetails;var r=this.masked.state;var i=this.masked._appendChar(t,this.currentMaskFlags(e));if(i.inserted&&this.doValidate(e)===false){i=new ChangeDetails;this.masked.state=r}if(!i.inserted&&!this.isOptional&&!this.lazy&&!e.input){i.inserted=this.placeholderChar}i.skip=!i.inserted&&!this.isOptional;this.isFilled=Boolean(i.inserted);return i};t.prototype.append=function(t,e,r){return this.masked.append(t,this.currentMaskFlags(e),r)};t.prototype._appendPlaceholder=function(){if(this.isFilled||this.isOptional)return new ChangeDetails;this.isFilled=true;return new ChangeDetails({inserted:this.placeholderChar})};t.prototype._appendEager=function(){return new ChangeDetails};t.prototype.extractTail=function(t,e){return this.masked.extractTail(t,e)};t.prototype.appendTail=function(t){return this.masked.appendTail(t)};t.prototype.extractInput=function(t,e,r){if(t===void 0){t=0}if(e===void 0){e=this.value.length}return this.masked.extractInput(t,e,r)};t.prototype.nearestInputPos=function(t,e){if(e===void 0){e=DIRECTION.NONE}var r=0;var i=this.value.length;var n=Math.min(Math.max(t,r),i);switch(e){case DIRECTION.LEFT:case DIRECTION.FORCE_LEFT:return this.isComplete?n:r;case DIRECTION.RIGHT:case DIRECTION.FORCE_RIGHT:return this.isComplete?n:i;case DIRECTION.NONE:default:return n}};t.prototype.totalInputPositions=function(t,e){if(t===void 0){t=0}if(e===void 0){e=this.value.length}return this.value.slice(t,e).length};t.prototype.doValidate=function(t){return this.masked.doValidate(this.currentMaskFlags(t))&&(!this.parent||this.parent.doValidate(this.currentMaskFlags(t)))};t.prototype.doCommit=function(){this.masked.doCommit()};Object.defineProperty(t.prototype,"state",{get:function(){return{_value:this.value,_rawInputValue:this.rawInputValue,masked:this.masked.state,isFilled:this.isFilled}},set:function(t){this.masked.state=t.masked;this.isFilled=t.isFilled},enumerable:false,configurable:true});t.prototype.currentMaskFlags=function(t){var e;return __assign(__assign({},t),{_beforeTailState:(t==null||(e=t._beforeTailState)==null?void 0:e.masked)||(t==null?void 0:t._beforeTailState)})};t.prototype.pad=function(t){return new ChangeDetails};return t}();PatternInputDefinition.DEFAULT_DEFINITIONS={0:/\d/,a:/[\u0041-\u005A\u0061-\u007A\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]/,"*":/./};var MaskedRegExp=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}e.prototype.updateOptions=function(e){t.prototype.updateOptions.call(this,e)};e.prototype._update=function(e){var r=e.mask;if(r)e.validate=function(t){return t.search(r)>=0};t.prototype._update.call(this,e)};return e}(Masked);IMask.MaskedRegExp=MaskedRegExp;var MaskedPattern=function(t){__extends(e,t);function e(r){return t.call(this,__assign(__assign(__assign({},e.DEFAULTS),r),{definitions:Object.assign({},PatternInputDefinition.DEFAULT_DEFINITIONS,r==null?void 0:r.definitions)}))||this}e.prototype.updateOptions=function(e){t.prototype.updateOptions.call(this,e)};e.prototype._update=function(e){e.definitions=Object.assign({},this.definitions,e.definitions);t.prototype._update.call(this,e);this._rebuildMask()};e.prototype._rebuildMask=function(){var t=this.definitions;this._blocks=[];this.exposeBlock=undefined;this._stops=[];this._maskedBlocks={};var r=this.mask;if(!r||!t)return;var i=false;var n=false;var a=function(a){if(s.blocks){var o=r.slice(a);var l=Object.keys(s.blocks).filter((function(t){return o.indexOf(t)===0}));l.sort((function(t,e){return e.length-t.length}));var p=l[0];if(p){var h=normalizeOpts(s.blocks[p]),c=h.expose,d=h.repeat,f=__rest(h,["expose","repeat"]);var g=__assign(__assign({lazy:s.lazy,eager:s.eager,placeholderChar:s.placeholderChar,displayChar:s.displayChar,overwrite:s.overwrite,autofix:s.autofix},f),{repeat:d,parent:s});var m=d!=null?new IMask.RepeatBlock(g):createMask(g);if(m){s._blocks.push(m);if(c)s.exposeBlock=m;if(!s._maskedBlocks[p])s._maskedBlocks[p]=[];s._maskedBlocks[p].push(s._blocks.length-1)}a+=p.length-1;return u=a,"continue"}}var v=r[a];var k=v in t;if(v===e.STOP_CHAR){s._stops.push(s._blocks.length);return u=a,"continue"}if(v==="{"||v==="}"){i=!i;return u=a,"continue"}if(v==="["||v==="]"){n=!n;return u=a,"continue"}if(v===e.ESCAPE_CHAR){++a;v=r[a];if(!v)return u=a,"break";k=false}var y=k?new PatternInputDefinition(__assign(__assign({isOptional:n,lazy:s.lazy,eager:s.eager,placeholderChar:s.placeholderChar,displayChar:s.displayChar},normalizeOpts(t[v])),{parent:s})):new PatternFixedDefinition({char:v,eager:s.eager,isUnmasking:i});s._blocks.push(y);u=a};var s=this,u;for(var o=0;o<r.length;++o){var l=a(o);o=u;if(l==="break")break}};Object.defineProperty(e.prototype,"state",{get:function(){return __assign(__assign({},t.prototype.state),{_blocks:this._blocks.map((function(t){return t.state}))})},set:function(e){if(!e){this.reset();return}var r=e._blocks,i=__rest(e,["_blocks"]);this._blocks.forEach((function(t,e){return t.state=r[e]}));t.prototype.state=i},enumerable:false,configurable:true});e.prototype.reset=function(){t.prototype.reset.call(this);this._blocks.forEach((function(t){return t.reset()}))};Object.defineProperty(e.prototype,"isComplete",{get:function(){return this.exposeBlock?this.exposeBlock.isComplete:this._blocks.every((function(t){return t.isComplete}))},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"isFilled",{get:function(){return this._blocks.every((function(t){return t.isFilled}))},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"isFixed",{get:function(){return this._blocks.every((function(t){return t.isFixed}))},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"isOptional",{get:function(){return this._blocks.every((function(t){return t.isOptional}))},enumerable:false,configurable:true});e.prototype.doCommit=function(){this._blocks.forEach((function(t){return t.doCommit()}));t.prototype.doCommit.call(this)};Object.defineProperty(e.prototype,"unmaskedValue",{get:function(){return this.exposeBlock?this.exposeBlock.unmaskedValue:this._blocks.reduce((function(t,e){return t+=e.unmaskedValue}),"")},set:function(e){if(this.exposeBlock){var r=this.extractTail(this._blockStartPos(this._blocks.indexOf(this.exposeBlock))+this.exposeBlock.displayValue.length);this.exposeBlock.unmaskedValue=e;this.appendTail(r);this.doCommit()}else t.prototype.unmaskedValue=e},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"value",{get:function(){return this.exposeBlock?this.exposeBlock.value:this._blocks.reduce((function(t,e){return t+=e.value}),"")},set:function(e){if(this.exposeBlock){var r=this.extractTail(this._blockStartPos(this._blocks.indexOf(this.exposeBlock))+this.exposeBlock.displayValue.length);this.exposeBlock.value=e;this.appendTail(r);this.doCommit()}else t.prototype.value=e},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"typedValue",{get:function(){return this.exposeBlock?this.exposeBlock.typedValue:t.prototype.typedValue},set:function(e){if(this.exposeBlock){var r=this.extractTail(this._blockStartPos(this._blocks.indexOf(this.exposeBlock))+this.exposeBlock.displayValue.length);this.exposeBlock.typedValue=e;this.appendTail(r);this.doCommit()}else t.prototype.typedValue=e},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"displayValue",{get:function(){return this._blocks.reduce((function(t,e){return t+=e.displayValue}),"")},enumerable:false,configurable:true});e.prototype.appendTail=function(e){return t.prototype.appendTail.call(this,e).aggregate(this._appendPlaceholder())};e.prototype._appendEager=function(){var t;var e=new ChangeDetails;var r=(t=this._mapPosToBlock(this.displayValue.length))==null?void 0:t.index;if(r==null)return e;if(this._blocks[r].isFilled)++r;for(var i=r;i<this._blocks.length;++i){var n=this._blocks[i]._appendEager();if(!n.inserted)break;e.aggregate(n)}return e};e.prototype._appendCharRaw=function(t,e){if(e===void 0){e={}}var r=this._mapPosToBlock(this.displayValue.length);var i=new ChangeDetails;if(!r)return i;for(var n=r.index,a=void 0;a=this._blocks[n];++n){var s;var u=a._appendChar(t,__assign(__assign({},e),{_beforeTailState:(s=e._beforeTailState)==null||(s=s._blocks)==null?void 0:s[n]}));i.aggregate(u);if(u.consumed)break}return i};e.prototype.extractTail=function(t,e){var r=this;if(t===void 0){t=0}if(e===void 0){e=this.displayValue.length}var i=new ChunksTailDetails;if(t===e)return i;this._forEachBlocksInRange(t,e,(function(t,e,n,a){var s=t.extractTail(n,a);s.stop=r._findStopBefore(e);s.from=r._blockStartPos(e);if(s instanceof ChunksTailDetails)s.blockIndex=e;i.extend(s)}));return i};e.prototype.extractInput=function(t,e,r){if(t===void 0){t=0}if(e===void 0){e=this.displayValue.length}if(r===void 0){r={}}if(t===e)return"";var i="";this._forEachBlocksInRange(t,e,(function(t,e,n,a){i+=t.extractInput(n,a,r)}));return i};e.prototype._findStopBefore=function(t){var e;for(var r=0;r<this._stops.length;++r){var i=this._stops[r];if(i<=t)e=i;else break}return e};e.prototype._appendPlaceholder=function(t){var e=new ChangeDetails;if(this.lazy&&t==null)return e;var r=this._mapPosToBlock(this.displayValue.length);if(!r)return e;var i=r.index;var n=t!=null?t:this._blocks.length;this._blocks.slice(i,n).forEach((function(r){if(!r.lazy||t!=null){var i;e.aggregate(r._appendPlaceholder((i=r._blocks)==null?void 0:i.length))}}));return e};e.prototype._mapPosToBlock=function(t){var e="";for(var r=0;r<this._blocks.length;++r){var i=this._blocks[r];var n=e.length;e+=i.displayValue;if(t<=e.length){return{index:r,offset:t-n}}}};e.prototype._blockStartPos=function(t){return this._blocks.slice(0,t).reduce((function(t,e){return t+=e.displayValue.length}),0)};e.prototype._forEachBlocksInRange=function(t,e,r){if(e===void 0){e=this.displayValue.length}var i=this._mapPosToBlock(t);if(i){var n=this._mapPosToBlock(e);var a=n&&i.index===n.index;var s=i.offset;var u=n&&a?n.offset:this._blocks[i.index].displayValue.length;r(this._blocks[i.index],i.index,s,u);if(n&&!a){for(var o=i.index+1;o<n.index;++o){r(this._blocks[o],o,0,this._blocks[o].displayValue.length)}r(this._blocks[n.index],n.index,0,n.offset)}}};e.prototype.remove=function(e,r){if(e===void 0){e=0}if(r===void 0){r=this.displayValue.length}var i=t.prototype.remove.call(this,e,r);this._forEachBlocksInRange(e,r,(function(t,e,r,n){i.aggregate(t.remove(r,n))}));return i};e.prototype.nearestInputPos=function(t,e){if(e===void 0){e=DIRECTION.NONE}if(!this._blocks.length)return 0;var r=new PatternCursor(this,t);if(e===DIRECTION.NONE){if(r.pushRightBeforeInput())return r.pos;r.popState();if(r.pushLeftBeforeInput())return r.pos;return this.displayValue.length}if(e===DIRECTION.LEFT||e===DIRECTION.FORCE_LEFT){if(e===DIRECTION.LEFT){r.pushRightBeforeFilled();if(r.ok&&r.pos===t)return t;r.popState()}r.pushLeftBeforeInput();r.pushLeftBeforeRequired();r.pushLeftBeforeFilled();if(e===DIRECTION.LEFT){r.pushRightBeforeInput();r.pushRightBeforeRequired();if(r.ok&&r.pos<=t)return r.pos;r.popState();if(r.ok&&r.pos<=t)return r.pos;r.popState()}if(r.ok)return r.pos;if(e===DIRECTION.FORCE_LEFT)return 0;r.popState();if(r.ok)return r.pos;r.popState();if(r.ok)return r.pos;return 0}if(e===DIRECTION.RIGHT||e===DIRECTION.FORCE_RIGHT){r.pushRightBeforeInput();r.pushRightBeforeRequired();if(r.pushRightBeforeFilled())return r.pos;if(e===DIRECTION.FORCE_RIGHT)return this.displayValue.length;r.popState();if(r.ok)return r.pos;r.popState();if(r.ok)return r.pos;return this.nearestInputPos(t,DIRECTION.LEFT)}return t};e.prototype.totalInputPositions=function(t,e){if(t===void 0){t=0}if(e===void 0){e=this.displayValue.length}var r=0;this._forEachBlocksInRange(t,e,(function(t,e,i,n){r+=t.totalInputPositions(i,n)}));return r};e.prototype.maskedBlock=function(t){return this.maskedBlocks(t)[0]};e.prototype.maskedBlocks=function(t){var e=this;var r=this._maskedBlocks[t];if(!r)return[];return r.map((function(t){return e._blocks[t]}))};e.prototype.pad=function(t){var e=new ChangeDetails;this._forEachBlocksInRange(0,this.displayValue.length,(function(r){return e.aggregate(r.pad(t))}));return e};return e}(Masked);MaskedPattern.DEFAULTS=__assign(__assign({},Masked.DEFAULTS),{lazy:true,placeholderChar:"_"});MaskedPattern.STOP_CHAR="`";MaskedPattern.ESCAPE_CHAR="\\";MaskedPattern.InputDefinition=PatternInputDefinition;MaskedPattern.FixedDefinition=PatternFixedDefinition;IMask.MaskedPattern=MaskedPattern;var MaskedRange=function(t){__extends(e,t);function e(e){return t.call(this,e)||this}Object.defineProperty(e.prototype,"_matchFrom",{get:function(){return this.maxLength-String(this.from).length},enumerable:false,configurable:true});e.prototype.updateOptions=function(e){t.prototype.updateOptions.call(this,e)};e.prototype._update=function(e){var r=e.to,i=r===void 0?this.to||0:r,n=e.from,a=n===void 0?this.from||0:n,s=e.maxLength,u=s===void 0?this.maxLength||0:s,o=e.autofix,l=o===void 0?this.autofix:o,p=__rest(e,["to","from","maxLength","autofix"]);this.to=i;this.from=a;this.maxLength=Math.max(String(i).length,u);this.autofix=l;var h=String(this.from).padStart(this.maxLength,"0");var c=String(this.to).padStart(this.maxLength,"0");var d=0;while(d<c.length&&c[d]===h[d])++d;p.mask=c.slice(0,d).replace(/0/g,"\\0")+"0".repeat(this.maxLength-d);t.prototype._update.call(this,p)};Object.defineProperty(e.prototype,"isComplete",{get:function(){return t.prototype.isComplete&&Boolean(this.value)},enumerable:false,configurable:true});e.prototype.boundaries=function(t){var e="";var r="";var i=t.match(/^(\D*)(\d*)(\D*)/)||[],n=i[1],a=i[2];if(a){e="0".repeat(n.length)+a;r="9".repeat(n.length)+a}e=e.padEnd(this.maxLength,"0");r=r.padEnd(this.maxLength,"9");return[e,r]};e.prototype.doPrepareChar=function(e,r){var i;if(r===void 0){r={}}var n;i=t.prototype.doPrepareChar.call(this,e.replace(/\D/g,""),r),e=i[0],n=i[1];if(!e)n.skip=!this.isComplete;return[e,n]};e.prototype._appendCharRaw=function(e,r){if(r===void 0){r={}}if(!this.autofix||this.value.length+1>this.maxLength)return t.prototype._appendCharRaw.call(this,e,r);var i=String(this.from).padStart(this.maxLength,"0");var n=String(this.to).padStart(this.maxLength,"0");var a=this.boundaries(this.value+e),s=a[0],u=a[1];if(Number(u)<this.from)return t.prototype._appendCharRaw.call(this,i[this.value.length],r);if(Number(s)>this.to){if(!r.tail&&this.autofix==="pad"&&this.value.length+1<this.maxLength){return t.prototype._appendCharRaw.call(this,i[this.value.length],r).aggregate(this._appendCharRaw(e,r))}return t.prototype._appendCharRaw.call(this,n[this.value.length],r)}return t.prototype._appendCharRaw.call(this,e,r)};e.prototype.doValidate=function(e){var r=this.value;var i=r.search(/[^0]/);if(i===-1&&r.length<=this._matchFrom)return true;var n=this.boundaries(r),a=n[0],s=n[1];return this.from<=Number(s)&&Number(a)<=this.to&&t.prototype.doValidate.call(this,e)};e.prototype.pad=function(e){var r=this;var i=new ChangeDetails;if(this.value.length===this.maxLength)return i;var n=this.value;var a=this.maxLength-this.value.length;if(a){this.reset();for(var s=0;s<a;++s){i.aggregate(t.prototype._appendCharRaw.call(this,"0",e))}n.split("").forEach((function(t){return r._appendCharRaw(t)}))}return i};return e}(MaskedPattern);IMask.MaskedRange=MaskedRange;var DefaultPattern="d{.}`m{.}`Y";var MaskedDate=function(t){__extends(e,t);function e(r){return t.call(this,e.extractPatternOptions(__assign(__assign({},e.DEFAULTS),r)))||this}e.extractPatternOptions=function(t){var e=t.mask,r=t.pattern,i=__rest(t,["mask","pattern"]);return __assign(__assign({},i),{mask:isString(e)?e:r})};e.prototype.updateOptions=function(e){t.prototype.updateOptions.call(this,e)};e.prototype._update=function(r){var i=__assign(__assign({},e.DEFAULTS),r),n=i.mask,a=i.pattern,s=i.blocks,u=__rest(i,["mask","pattern","blocks"]);var o=Object.assign({},e.GET_DEFAULT_BLOCKS());if(r.min)o.Y.from=r.min.getFullYear();if(r.max)o.Y.to=r.max.getFullYear();if(r.min&&r.max&&o.Y.from===o.Y.to){o.m.from=r.min.getMonth()+1;o.m.to=r.max.getMonth()+1;if(o.m.from===o.m.to){o.d.from=r.min.getDate();o.d.to=r.max.getDate()}}Object.assign(o,this.blocks,s);t.prototype._update.call(this,__assign(__assign({},u),{mask:isString(n)?n:a,blocks:o}))};e.prototype.doValidate=function(e){var r=this.date;return t.prototype.doValidate.call(this,e)&&(!this.isComplete||this.isDateExist(this.value)&&r!=null&&(this.min==null||this.min<=r)&&(this.max==null||r<=this.max))};e.prototype.isDateExist=function(t){return this.format(this.parse(t,this),this).indexOf(t)>=0};Object.defineProperty(e.prototype,"date",{get:function(){return this.typedValue},set:function(t){this.typedValue=t},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"typedValue",{get:function(){return this.isComplete?t.prototype.typedValue:null},set:function(e){t.prototype.typedValue=e},enumerable:false,configurable:true});e.prototype.maskEquals=function(e){return e===Date||t.prototype.maskEquals.call(this,e)};e.prototype.optionsIsChanged=function(r){return t.prototype.optionsIsChanged.call(this,e.extractPatternOptions(r))};return e}(MaskedPattern);MaskedDate.GET_DEFAULT_BLOCKS=function(){return{d:{mask:MaskedRange,from:1,to:31,maxLength:2},m:{mask:MaskedRange,from:1,to:12,maxLength:2},Y:{mask:MaskedRange,from:1900,to:9999}}};MaskedDate.DEFAULTS=__assign(__assign({},MaskedPattern.DEFAULTS),{mask:Date,pattern:DefaultPattern,format:function(t,e){if(!t)return"";var r=String(t.getDate()).padStart(2,"0");var i=String(t.getMonth()+1).padStart(2,"0");var n=t.getFullYear();return[r,i,n].join(".")},parse:function(t,e){var r=t.split(".").map(Number),i=r[0],n=r[1],a=r[2];return new Date(a,n-1,i)}});IMask.MaskedDate=MaskedDate;var MaskedDynamic=function(t){__extends(e,t);function e(r){var i=t.call(this,__assign(__assign({},e.DEFAULTS),r))||this;i.currentMask=undefined;return i}e.prototype.updateOptions=function(e){t.prototype.updateOptions.call(this,e)};e.prototype._update=function(e){var r=this;t.prototype._update.call(this,e);if("mask"in e){this.exposeMask=undefined;this.compiledMasks=Array.isArray(e.mask)?e.mask.map((function(t){var e=normalizeOpts(t),i=e.expose,n=__rest(e,["expose"]);var a=createMask(__assign({overwrite:r._overwrite,eager:r._eager,skipInvalid:r._skipInvalid},n));if(i)r.exposeMask=a;return a})):[]}};e.prototype._appendCharRaw=function(t,e){if(e===void 0){e={}}var r=this._applyDispatch(t,e);if(this.currentMask){r.aggregate(this.currentMask._appendChar(t,this.currentMaskFlags(e)))}return r};e.prototype._applyDispatch=function(t,e,r){if(t===void 0){t=""}if(e===void 0){e={}}if(r===void 0){r=""}var i=e.tail&&e._beforeTailState!=null?e._beforeTailState._value:this.value;var n=this.rawInputValue;var a=e.tail&&e._beforeTailState!=null?e._beforeTailState._rawInputValue:n;var s=n.slice(a.length);var u=this.currentMask;var o=new ChangeDetails;var l=u==null?void 0:u.state;this.currentMask=this.doDispatch(t,__assign({},e),r);if(this.currentMask){if(this.currentMask!==u){this.currentMask.reset();if(a){this.currentMask.append(a,{raw:true});o.tailShift=this.currentMask.value.length-i.length}if(s){o.tailShift+=this.currentMask.append(s,{raw:true,tail:true}).tailShift}}else if(l){this.currentMask.state=l}}return o};e.prototype._appendPlaceholder=function(){var t=this._applyDispatch();if(this.currentMask){t.aggregate(this.currentMask._appendPlaceholder())}return t};e.prototype._appendEager=function(){var t=this._applyDispatch();if(this.currentMask){t.aggregate(this.currentMask._appendEager())}return t};e.prototype.appendTail=function(e){var r=new ChangeDetails;if(e)r.aggregate(this._applyDispatch("",{},e));return r.aggregate(this.currentMask?this.currentMask.appendTail(e):t.prototype.appendTail.call(this,e))};e.prototype.currentMaskFlags=function(t){var e,r;return __assign(__assign({},t),{_beforeTailState:((e=t._beforeTailState)==null?void 0:e.currentMaskRef)===this.currentMask&&((r=t._beforeTailState)==null?void 0:r.currentMask)||t._beforeTailState})};e.prototype.doDispatch=function(t,e,r){if(e===void 0){e={}}if(r===void 0){r=""}return this.dispatch(t,this,e,r)};e.prototype.doValidate=function(e){return t.prototype.doValidate.call(this,e)&&(!this.currentMask||this.currentMask.doValidate(this.currentMaskFlags(e)))};e.prototype.doPrepare=function(e,r){var i;if(r===void 0){r={}}var n=t.prototype.doPrepare.call(this,e,r),a=n[0],s=n[1];if(this.currentMask){var u=void 0;i=t.prototype.doPrepare.call(this,a,this.currentMaskFlags(r)),a=i[0],u=i[1];s=s.aggregate(u)}return[a,s]};e.prototype.doPrepareChar=function(e,r){var i;if(r===void 0){r={}}var n=t.prototype.doPrepareChar.call(this,e,r),a=n[0],s=n[1];if(this.currentMask){var u=void 0;i=t.prototype.doPrepareChar.call(this,a,this.currentMaskFlags(r)),a=i[0],u=i[1];s=s.aggregate(u)}return[a,s]};e.prototype.reset=function(){var t;(t=this.currentMask)==null||t.reset();this.compiledMasks.forEach((function(t){return t.reset()}))};Object.defineProperty(e.prototype,"value",{get:function(){return this.exposeMask?this.exposeMask.value:this.currentMask?this.currentMask.value:""},set:function(e){if(this.exposeMask){this.exposeMask.value=e;this.currentMask=this.exposeMask;this._applyDispatch()}else t.prototype.value=e},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"unmaskedValue",{get:function(){return this.exposeMask?this.exposeMask.unmaskedValue:this.currentMask?this.currentMask.unmaskedValue:""},set:function(e){if(this.exposeMask){this.exposeMask.unmaskedValue=e;this.currentMask=this.exposeMask;this._applyDispatch()}else t.prototype.unmaskedValue=e},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"typedValue",{get:function(){return this.exposeMask?this.exposeMask.typedValue:this.currentMask?this.currentMask.typedValue:""},set:function(t){if(this.exposeMask){this.exposeMask.typedValue=t;this.currentMask=this.exposeMask;this._applyDispatch();return}var e=String(t);if(this.currentMask){this.currentMask.typedValue=t;e=this.currentMask.unmaskedValue}this.unmaskedValue=e},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"displayValue",{get:function(){return this.currentMask?this.currentMask.displayValue:""},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"isComplete",{get:function(){var t;return Boolean((t=this.currentMask)==null?void 0:t.isComplete)},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"isFilled",{get:function(){var t;return Boolean((t=this.currentMask)==null?void 0:t.isFilled)},enumerable:false,configurable:true});e.prototype.remove=function(t,e){var r=new ChangeDetails;if(this.currentMask){r.aggregate(this.currentMask.remove(t,e)).aggregate(this._applyDispatch())}return r};Object.defineProperty(e.prototype,"state",{get:function(){var e;return __assign(__assign({},t.prototype.state),{_rawInputValue:this.rawInputValue,compiledMasks:this.compiledMasks.map((function(t){return t.state})),currentMaskRef:this.currentMask,currentMask:(e=this.currentMask)==null?void 0:e.state})},set:function(e){var r=e.compiledMasks,i=e.currentMaskRef,n=e.currentMask,a=__rest(e,["compiledMasks","currentMaskRef","currentMask"]);if(r)this.compiledMasks.forEach((function(t,e){return t.state=r[e]}));if(i!=null){this.currentMask=i;this.currentMask.state=n}t.prototype.state=a},enumerable:false,configurable:true});e.prototype.extractInput=function(t,e,r){return this.currentMask?this.currentMask.extractInput(t,e,r):""};e.prototype.extractTail=function(e,r){return this.currentMask?this.currentMask.extractTail(e,r):t.prototype.extractTail.call(this,e,r)};e.prototype.doCommit=function(){if(this.currentMask)this.currentMask.doCommit();t.prototype.doCommit.call(this)};e.prototype.nearestInputPos=function(e,r){return this.currentMask?this.currentMask.nearestInputPos(e,r):t.prototype.nearestInputPos.call(this,e,r)};Object.defineProperty(e.prototype,"overwrite",{get:function(){return this.currentMask?this.currentMask.overwrite:this._overwrite},set:function(t){this._overwrite=t},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"eager",{get:function(){return this.currentMask?this.currentMask.eager:this._eager},set:function(t){this._eager=t},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"skipInvalid",{get:function(){return this.currentMask?this.currentMask.skipInvalid:this._skipInvalid},set:function(t){this._skipInvalid=t},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"autofix",{get:function(){return this.currentMask?this.currentMask.autofix:this._autofix},set:function(t){this._autofix=t},enumerable:false,configurable:true});e.prototype.maskEquals=function(e){return Array.isArray(e)?this.compiledMasks.every((function(t,r){if(!e[r])return;var i=e[r],n=i.mask,a=__rest(i,["mask"]);return objectIncludes(t,a)&&t.maskEquals(n)})):t.prototype.maskEquals.call(this,e)};e.prototype.typedValueEquals=function(t){var e;return Boolean((e=this.currentMask)==null?void 0:e.typedValueEquals(t))};return e}(Masked);MaskedDynamic.DEFAULTS=__assign(__assign({},Masked.DEFAULTS),{dispatch:function(t,e,r,i){if(!e.compiledMasks.length)return;var n=e.rawInputValue;var a=e.compiledMasks.map((function(a,s){var u=e.currentMask===a;var o=u?a.displayValue.length:a.nearestInputPos(a.displayValue.length,DIRECTION.FORCE_LEFT);if(a.rawInputValue!==n){a.reset();a.append(n,{raw:true})}else if(!u){a.remove(o)}a.append(t,e.currentMaskFlags(r));a.appendTail(i);return{index:s,weight:a.rawInputValue.length,totalInputPositions:a.totalInputPositions(0,Math.max(o,a.nearestInputPos(a.displayValue.length,DIRECTION.FORCE_LEFT)))}}));a.sort((function(t,e){return e.weight-t.weight||e.totalInputPositions-t.totalInputPositions}));return e.compiledMasks[a[0].index]}});IMask.MaskedDynamic=MaskedDynamic;var MaskedEnum=function(t){__extends(e,t);function e(r){return t.call(this,__assign(__assign({},e.DEFAULTS),r))||this}e.prototype.updateOptions=function(e){t.prototype.updateOptions.call(this,e)};e.prototype._update=function(e){var r=e.enum,i=__rest(e,["enum"]);if(r){var n=r.map((function(t){return t.length}));var a=Math.min.apply(Math,n);var s=Math.max.apply(Math,n)-a;i.mask="*".repeat(a);if(s)i.mask+="["+"*".repeat(s)+"]";this.enum=r}t.prototype._update.call(this,i)};e.prototype._appendCharRaw=function(e,r){var i=this;if(r===void 0){r={}}var n=Math.min(this.nearestInputPos(0,DIRECTION.FORCE_RIGHT),this.value.length);var a=this.enum.filter((function(t){return i.matchValue(t,i.unmaskedValue+e,n)}));if(a.length){if(a.length===1){this._forEachBlocksInRange(0,this.value.length,(function(t,e){var n=a[0][e];if(e>=i.value.length||n===t.value)return;t.reset();t._appendChar(n,r)}))}var s=t.prototype._appendCharRaw.call(this,a[0][this.value.length],r);if(a.length===1){a[0].slice(this.unmaskedValue.length).split("").forEach((function(e){return s.aggregate(t.prototype._appendCharRaw.call(i,e))}))}return s}return new ChangeDetails({skip:!this.isComplete})};e.prototype.extractTail=function(t,e){if(t===void 0){t=0}return new ContinuousTailDetails("",t)};e.prototype.remove=function(e,r){var i=this;if(e===void 0){e=0}if(r===void 0){r=this.displayValue.length}if(e===r)return new ChangeDetails;var n=Math.min(t.prototype.nearestInputPos.call(this,0,DIRECTION.FORCE_RIGHT),this.value.length);var a;for(a=e;a>=0;--a){var s=this.enum.filter((function(t){return i.matchValue(t,i.value.slice(n,a),n)}));if(s.length>1)break}var u=t.prototype.remove.call(this,a,r);u.tailShift+=a-e;return u};Object.defineProperty(e.prototype,"isComplete",{get:function(){return this.enum.indexOf(this.value)>=0},enumerable:false,configurable:true});return e}(MaskedPattern);MaskedEnum.DEFAULTS=__assign(__assign({},MaskedPattern.DEFAULTS),{matchValue:function(t,e,r){return t.indexOf(e,r)===r}});IMask.MaskedEnum=MaskedEnum;var MaskedFunction=function(t){__extends(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}e.prototype.updateOptions=function(e){t.prototype.updateOptions.call(this,e)};e.prototype._update=function(e){t.prototype._update.call(this,__assign(__assign({},e),{validate:e.mask}))};return e}(Masked);IMask.MaskedFunction=MaskedFunction;var _MaskedNumber;var MaskedNumber=function(t){__extends(e,t);function e(r){return t.call(this,__assign(__assign({},e.DEFAULTS),r))||this}e.prototype.updateOptions=function(e){t.prototype.updateOptions.call(this,e)};e.prototype._update=function(e){t.prototype._update.call(this,e);this._updateRegExps()};e.prototype._updateRegExps=function(){var t="^"+(this.allowNegative?"[+|\\-]?":"");var e="\\d*";var r=(this.scale?"("+escapeRegExp(this.radix)+"\\d{0,"+this.scale+"})?":"")+"$";this._numberRegExp=new RegExp(t+e+r);this._mapToRadixRegExp=new RegExp("["+this.mapToRadix.map(escapeRegExp).join("")+"]","g");this._thousandsSeparatorRegExp=new RegExp(escapeRegExp(this.thousandsSeparator),"g")};e.prototype._removeThousandsSeparators=function(t){return t.replace(this._thousandsSeparatorRegExp,"")};e.prototype._insertThousandsSeparators=function(t){var e=t.split(this.radix);e[0]=e[0].replace(/\B(?=(\d{3})+(?!\d))/g,this.thousandsSeparator);return e.join(this.radix)};e.prototype.doPrepareChar=function(e,r){if(r===void 0){r={}}var i=t.prototype.doPrepareChar.call(this,this._removeThousandsSeparators(this.scale&&this.mapToRadix.length&&(r.input&&r.raw||!r.input&&!r.raw)?e.replace(this._mapToRadixRegExp,this.radix):e),r),n=i[0],a=i[1];if(e&&!n)a.skip=true;if(n&&!this.allowPositive&&!this.value&&n!=="-")a.aggregate(this._appendChar("-"));return[n,a]};e.prototype._separatorsCount=function(t,e){if(e===void 0){e=false}var r=0;for(var i=0;i<t;++i){if(this._value.indexOf(this.thousandsSeparator,i)===i){++r;if(e)t+=this.thousandsSeparator.length}}return r};e.prototype._separatorsCountFromSlice=function(t){if(t===void 0){t=this._value}return this._separatorsCount(this._removeThousandsSeparators(t).length,true)};e.prototype.extractInput=function(e,r,i){var n;if(e===void 0){e=0}if(r===void 0){r=this.displayValue.length}n=this._adjustRangeWithSeparators(e,r),e=n[0],r=n[1];return this._removeThousandsSeparators(t.prototype.extractInput.call(this,e,r,i))};e.prototype._appendCharRaw=function(t,r){if(r===void 0){r={}}var i=r.tail&&r._beforeTailState?r._beforeTailState._value:this._value;var n=this._separatorsCountFromSlice(i);this._value=this._removeThousandsSeparators(this.value);var a=this._value;this._value+=t;var s=this.number;var u=!isNaN(s);var o=false;if(u){var l=void 0;if(this.min!=null&&this.min<0&&this.number<this.min)l=this.min;if(this.max!=null&&this.max>0&&this.number>this.max)l=this.max;if(l!=null){if(this.autofix){this._value=this.format(l,this).replace(e.UNMASKED_RADIX,this.radix);o||(o=a===this._value&&!r.tail)}else{u=false}}u&&(u=Boolean(this._value.match(this._numberRegExp)))}var p;if(!u){this._value=a;p=new ChangeDetails}else{p=new ChangeDetails({inserted:this._value.slice(a.length),rawInserted:o?"":t,skip:o})}this._value=this._insertThousandsSeparators(this._value);var h=r.tail&&r._beforeTailState?r._beforeTailState._value:this._value;var c=this._separatorsCountFromSlice(h);p.tailShift+=(c-n)*this.thousandsSeparator.length;return p};e.prototype._findSeparatorAround=function(t){if(this.thousandsSeparator){var e=t-this.thousandsSeparator.length+1;var r=this.value.indexOf(this.thousandsSeparator,e);if(r<=t)return r}return-1};e.prototype._adjustRangeWithSeparators=function(t,e){var r=this._findSeparatorAround(t);if(r>=0)t=r;var i=this._findSeparatorAround(e);if(i>=0)e=i+this.thousandsSeparator.length;return[t,e]};e.prototype.remove=function(t,e){var r;if(t===void 0){t=0}if(e===void 0){e=this.displayValue.length}r=this._adjustRangeWithSeparators(t,e),t=r[0],e=r[1];var i=this.value.slice(0,t);var n=this.value.slice(e);var a=this._separatorsCount(i.length);this._value=this._insertThousandsSeparators(this._removeThousandsSeparators(i+n));var s=this._separatorsCountFromSlice(i);return new ChangeDetails({tailShift:(s-a)*this.thousandsSeparator.length})};e.prototype.nearestInputPos=function(t,e){if(!this.thousandsSeparator)return t;switch(e){case DIRECTION.NONE:case DIRECTION.LEFT:case DIRECTION.FORCE_LEFT:{var r=this._findSeparatorAround(t-1);if(r>=0){var i=r+this.thousandsSeparator.length;if(t<i||this.value.length<=i||e===DIRECTION.FORCE_LEFT){return r}}break}case DIRECTION.RIGHT:case DIRECTION.FORCE_RIGHT:{var n=this._findSeparatorAround(t);if(n>=0){return n+this.thousandsSeparator.length}}}return t};e.prototype.doCommit=function(){if(this.value){var e=this.number;var r=e;if(this.min!=null)r=Math.max(r,this.min);if(this.max!=null)r=Math.min(r,this.max);if(r!==e)this.unmaskedValue=this.format(r,this);var i=this.value;if(this.normalizeZeros)i=this._normalizeZeros(i);if(this.padFractionalZeros&&this.scale>0)i=this._padFractionalZeros(i);this._value=i}t.prototype.doCommit.call(this)};e.prototype._normalizeZeros=function(t){var e=this._removeThousandsSeparators(t).split(this.radix);e[0]=e[0].replace(/^(\D*)(0*)(\d*)/,(function(t,e,r,i){return e+i}));if(t.length&&!/\d$/.test(e[0]))e[0]=e[0]+"0";if(e.length>1){e[1]=e[1].replace(/0*$/,"");if(!e[1].length)e.length=1}return this._insertThousandsSeparators(e.join(this.radix))};e.prototype._padFractionalZeros=function(t){if(!t)return t;var e=t.split(this.radix);if(e.length<2)e.push("");e[1]=e[1].padEnd(this.scale,"0");return e.join(this.radix)};e.prototype.doSkipInvalid=function(r,i,n){if(i===void 0){i={}}var a=this.scale===0&&r!==this.thousandsSeparator&&(r===this.radix||r===e.UNMASKED_RADIX||this.mapToRadix.includes(r));return t.prototype.doSkipInvalid.call(this,r,i,n)&&!a};Object.defineProperty(e.prototype,"unmaskedValue",{get:function(){return this._removeThousandsSeparators(this._normalizeZeros(this.value)).replace(this.radix,e.UNMASKED_RADIX)},set:function(e){t.prototype.unmaskedValue=e},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"typedValue",{get:function(){return this.parse(this.unmaskedValue,this)},set:function(t){this.rawInputValue=this.format(t,this).replace(e.UNMASKED_RADIX,this.radix)},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"number",{get:function(){return this.typedValue},set:function(t){this.typedValue=t},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"allowNegative",{get:function(){return this.min!=null&&this.min<0||this.max!=null&&this.max<0},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"allowPositive",{get:function(){return this.min!=null&&this.min>0||this.max!=null&&this.max>0},enumerable:false,configurable:true});e.prototype.typedValueEquals=function(r){return(t.prototype.typedValueEquals.call(this,r)||e.EMPTY_VALUES.includes(r)&&e.EMPTY_VALUES.includes(this.typedValue))&&!(r===0&&this.value==="")};return e}(Masked);_MaskedNumber=MaskedNumber;MaskedNumber.UNMASKED_RADIX=".";MaskedNumber.EMPTY_VALUES=__spreadArray(__spreadArray([],Masked.EMPTY_VALUES,true),[0],false);MaskedNumber.DEFAULTS=__assign(__assign({},Masked.DEFAULTS),{mask:Number,radix:",",thousandsSeparator:"",mapToRadix:[_MaskedNumber.UNMASKED_RADIX],min:Number.MIN_SAFE_INTEGER,max:Number.MAX_SAFE_INTEGER,scale:2,normalizeZeros:true,padFractionalZeros:false,parse:Number,format:function(t){return t.toLocaleString("en-US",{useGrouping:false,maximumFractionDigits:20})}});IMask.MaskedNumber=MaskedNumber;var PIPE_TYPE={MASKED:"value",UNMASKED:"unmaskedValue",TYPED:"typedValue"};function createPipe(t,e,r){if(e===void 0){e=PIPE_TYPE.MASKED}if(r===void 0){r=PIPE_TYPE.MASKED}var i=createMask(t);return function(t){return i.runIsolated((function(i){i[e]=t;return i[r]}))}}function pipe(t,e,r,i){return createPipe(e,r,i)(t)}IMask.PIPE_TYPE=PIPE_TYPE;IMask.createPipe=createPipe;IMask.pipe=pipe;var RepeatBlock=function(t){__extends(e,t);function e(e){return t.call(this,e)||this}Object.defineProperty(e.prototype,"repeatFrom",{get:function(){var t;return(t=Array.isArray(this.repeat)?this.repeat[0]:this.repeat===Infinity?0:this.repeat)!=null?t:0},enumerable:false,configurable:true});Object.defineProperty(e.prototype,"repeatTo",{get:function(){var t;return(t=Array.isArray(this.repeat)?this.repeat[1]:this.repeat)!=null?t:Infinity},enumerable:false,configurable:true});e.prototype.updateOptions=function(e){t.prototype.updateOptions.call(this,e)};e.prototype._update=function(e){var r,i,n;var a=normalizeOpts(e),s=a.repeat,u=__rest(a,["repeat"]);this._blockOpts=Object.assign({},this._blockOpts,u);var o=createMask(this._blockOpts);this.repeat=(r=(i=s!=null?s:o.repeat)!=null?i:this.repeat)!=null?r:Infinity;t.prototype._update.call(this,{mask:"m".repeat(Math.max(this.repeatTo===Infinity&&((n=this._blocks)==null?void 0:n.length)||0,this.repeatFrom)),blocks:{m:o},eager:o.eager,overwrite:o.overwrite,skipInvalid:o.skipInvalid,lazy:o.lazy,placeholderChar:o.placeholderChar,displayChar:o.displayChar})};e.prototype._allocateBlock=function(t){if(t<this._blocks.length)return this._blocks[t];if(this.repeatTo===Infinity||this._blocks.length<this.repeatTo){this._blocks.push(createMask(this._blockOpts));this.mask+="m";return this._blocks[this._blocks.length-1]}};e.prototype._appendCharRaw=function(t,e){if(e===void 0){e={}}var r=new ChangeDetails;for(var i=(s=(u=this._mapPosToBlock(this.displayValue.length))==null?void 0:u.index)!=null?s:Math.max(this._blocks.length-1,0),n=void 0,a=void 0;n=(o=this._blocks[i])!=null?o:a=!a&&this._allocateBlock(i);++i){var s,u,o,l;var p=n._appendChar(t,__assign(__assign({},e),{_beforeTailState:(l=e._beforeTailState)==null||(l=l._blocks)==null?void 0:l[i]}));if(p.skip&&a){this._blocks.pop();this.mask=this.mask.slice(1);break}r.aggregate(p);if(p.consumed)break}return r};e.prototype._trimEmptyTail=function(t,e){var r,i;if(t===void 0){t=0}var n=Math.max(((r=this._mapPosToBlock(t))==null?void 0:r.index)||0,this.repeatFrom,0);var a;if(e!=null)a=(i=this._mapPosToBlock(e))==null?void 0:i.index;if(a==null)a=this._blocks.length-1;var s=0;for(var u=a;n<=u;--u,++s){if(this._blocks[u].unmaskedValue)break}if(s){this._blocks.splice(a-s+1,s);this.mask=this.mask.slice(s)}};e.prototype.reset=function(){t.prototype.reset.call(this);this._trimEmptyTail()};e.prototype.remove=function(e,r){if(e===void 0){e=0}if(r===void 0){r=this.displayValue.length}var i=t.prototype.remove.call(this,e,r);this._trimEmptyTail(e,r);return i};e.prototype.totalInputPositions=function(e,r){if(e===void 0){e=0}if(r==null&&this.repeatTo===Infinity)return Infinity;return t.prototype.totalInputPositions.call(this,e,r)};Object.defineProperty(e.prototype,"state",{get:function(){return t.prototype.state},set:function(e){this._blocks.length=e._blocks.length;this.mask=this.mask.slice(0,this._blocks.length);t.prototype.state=e},enumerable:false,configurable:true});return e}(MaskedPattern);IMask.RepeatBlock=RepeatBlock;try{globalThis.IMask=IMask}catch(t){}var maskOptions={cpf_cnpj:{mask:[{mask:"000.000.000-00"},{mask:"00.000.000/0000-00"}],placeholderChar:"_"},cpf:{mask:"000.000.000-00",placeholderChar:"_"},cnpj:{mask:"00.000.000/0000-00",placeholderChar:"_"},phone:{mask:"(00) 00000-0000",blocks:{"(00)":{mask:"(00)",maxLength:2,placeholderChar:""},"00000":{mask:"00000",maxLength:5,placeholderChar:"_"},"-":{mask:"-"},"0000":{mask:"0000",maxLength:4,placeholderChar:"_"}},placeholderChar:"_"},date:{mask:Date,min:new Date(1900,0,1),max:new Date(2099,11,31),lazy:false,placeholderChar:"_"}};var curaInputTextCss=":host{display:block;width:100%}.required{color:var(--error-base)}.cura-input-group{width:100%;font-family:var(--font-family);text-align:left !important}.cura-input-group cura-label{margin-bottom:8px}.cura-input-group .helper-text{margin-top:8px;font-size:12px;font-family:var(--font-family);color:var(--neutral-dark)}.cura-input-group .cura-input-field{width:100%;height:44px;display:-ms-flexbox;display:flex;-ms-flex-direction:row;flex-direction:row;-ms-flex-align:center;align-items:center;background-color:var(--neutral-purewhite);border:2px solid var(--neutral-medium);border-radius:4px;color:var(--primary-base);letter-spacing:0.32px;line-height:20px;overflow:hidden}.cura-input-group .cura-input-field input{width:100%;height:100%;background:transparent;border:none;outline:none;text-overflow:ellipsis;color:var(--neutral-dark);font-family:var(--font-family);font-weight:var(--font-weight-medium);font-size:16px;font-style:normal;line-height:20px;letter-spacing:0.32px;padding:0px 12px 0px 8px}.cura-input-group .cura-input-field input input::-webkit-input-placeholder{color:var(--neutral-dark)}.cura-input-group .cura-input-field input input::-moz-placeholder{color:var(--neutral-dark)}.cura-input-group .cura-input-field input input:-ms-input-placeholder{color:var(--neutral-dark)}.cura-input-group .cura-input-field input input::-ms-input-placeholder{color:var(--neutral-dark)}.cura-input-group .cura-input-field input input::placeholder{color:var(--neutral-dark)}.cura-input-group .cura-input-field cura-loader-circle{margin:0px 12px}.cura-input-group .cura-input-field .feedback-icon{padding-left:12px;padding-top:6px}.cura-input-group .cura-input-field .clear-button{padding-right:12px;cursor:pointer}.cura-input-group:hover:not(.disabled):not(.isLoading):not(.isSuccess):not(.isError):not(.isFocused):not(.readOnly):not(.transparent) .cura-input-field{border-color:var(--neutral-dark)}.cura-input-group:hover:not(.disabled):not(.isLoading):not(.isSuccess):not(.isError):not(.isFocused):not(.readOnly):not(.transparent) .cura-input-field input{color:var(--neutral-dark)}.cura-input-group:hover:not(.disabled):not(.isLoading):not(.isSuccess):not(.isError):not(.isFocused):not(.readOnly):not(.transparent) .cura-input-field input::-webkit-input-placeholder{color:var(--neutral-dark)}.cura-input-group:hover:not(.disabled):not(.isLoading):not(.isSuccess):not(.isError):not(.isFocused):not(.readOnly):not(.transparent) .cura-input-field input::-moz-placeholder{color:var(--neutral-dark)}.cura-input-group:hover:not(.disabled):not(.isLoading):not(.isSuccess):not(.isError):not(.isFocused):not(.readOnly):not(.transparent) .cura-input-field input:-ms-input-placeholder{color:var(--neutral-dark)}.cura-input-group:hover:not(.disabled):not(.isLoading):not(.isSuccess):not(.isError):not(.isFocused):not(.readOnly):not(.transparent) .cura-input-field input::-ms-input-placeholder{color:var(--neutral-dark)}.cura-input-group:hover:not(.disabled):not(.isLoading):not(.isSuccess):not(.isError):not(.isFocused):not(.readOnly):not(.transparent) .cura-input-field input::placeholder{color:var(--neutral-dark)}.cura-input-group:hover:not(.disabled):not(.isLoading):not(.isSuccess):not(.isError):not(.isFocused):not(.readOnly):not(.transparent) ::slotted(cura-label){color:var(--neutral-black)}.cura-input-group.isFocused .cura-input-field,.cura-input-group :focus-within :not(.readOnly) .cura-input-field{border:2px solid var(--info-base);background-color:var(--neutral-purewhite);outline:none}.cura-input-group.isFocused .cura-input-field input,.cura-input-group :focus-within :not(.readOnly) .cura-input-field input{letter-spacing:0.32px;line-height:20px;color:var(--neutral-black)}.cura-input-group.isFocused .helper-text,.cura-input-group :focus-within :not(.readOnly) .helper-text{color:var(--neutral-black)}.cura-input-group.isSuccess .cura-input-field{border:2px solid var(--success-dark);background-color:var(--success-lighter);overflow:hidden}.cura-input-group.isSuccess .cura-input-field input{letter-spacing:0.32px;line-height:20px;color:var(--success-darker)}.cura-input-group.isSuccess .cura-input-field input::-webkit-input-placeholder{color:var(--success-darker)}.cura-input-group.isSuccess .cura-input-field input::-moz-placeholder{color:var(--success-darker)}.cura-input-group.isSuccess .cura-input-field input:-ms-input-placeholder{color:var(--success-darker)}.cura-input-group.isSuccess .cura-input-field input::-ms-input-placeholder{color:var(--success-darker)}.cura-input-group.isSuccess .cura-input-field input::placeholder{color:var(--success-darker)}.cura-input-group.isSuccess .helper-text{color:var(--success-dark)}.cura-input-group.isError .cura-input-field{border:2px solid var(--error-dark);background-color:var(--error-lighter);letter-spacing:0.32px;line-height:20px;overflow:hidden}.cura-input-group.isError .cura-input-field input{letter-spacing:0.32px;line-height:20px;color:var(--error-darker)}.cura-input-group.isError .cura-input-field input::-webkit-input-placeholder{color:var(--error-darker)}.cura-input-group.isError .cura-input-field input::-moz-placeholder{color:var(--error-darker)}.cura-input-group.isError .cura-input-field input:-ms-input-placeholder{color:var(--error-darker)}.cura-input-group.isError .cura-input-field input::-ms-input-placeholder{color:var(--error-darker)}.cura-input-group.isError .cura-input-field input::placeholder{color:var(--error-darker)}.cura-input-group.isError .helper-text{color:var(--error-dark)}.cura-input-group.isLoading{cursor:wait}.cura-input-group.isLoading .cura-input-field{background-color:var(--neutral-white);border:2px solid var(--primary-base);color:var(--primary-base);letter-spacing:0.32px;line-height:20px;overflow:hidden}.cura-input-group.isLoading .cura-input-field input{cursor:wait;color:var(--primary-base)}.cura-input-group.isLoading input::-webkit-input-placeholder{color:var(--primary-base)}.cura-input-group.isLoading input::-moz-placeholder{color:var(--primary-base)}.cura-input-group.isLoading input:-ms-input-placeholder{color:var(--primary-base)}.cura-input-group.isLoading input::-ms-input-placeholder{color:var(--primary-base)}.cura-input-group.isLoading input::placeholder{color:var(--primary-base)}.cura-input-group.isLoading .helper-text{color:var(--primary-base)}.cura-input-group.disabled .cura-input-field{background-color:var(--neutral-white);border:2px solid var(--neutral-base);color:var(--neutral-medium)}.cura-input-group.disabled .cura-input-field input{color:var(--neutral-medium)}.cura-input-group.disabled .cura-input-field input::-webkit-input-placeholder{color:var(--neutral-medium)}.cura-input-group.disabled .cura-input-field input::-moz-placeholder{color:var(--neutral-medium)}.cura-input-group.disabled .cura-input-field input:-ms-input-placeholder{color:var(--neutral-medium)}.cura-input-group.disabled .cura-input-field input::-ms-input-placeholder{color:var(--neutral-medium)}.cura-input-group.disabled .cura-input-field input::placeholder{color:var(--neutral-medium)}.cura-input-group.readOnly[read-only] .cura-input-field{cursor:default}.cura-input-group.readOnly[read-only] .cura-input-field input{cursor:default}.cura-input-group.readOnly[read-only] .helper-text{color:var(--neutral-dark)}.cura-input-group.transparent{display:-ms-flexbox;display:flex;background-color:transparent;padding:0px;-ms-flex-pack:start;justify-content:start;-ms-flex-align:center;align-items:center;min-width:300px;max-height:80px;gap:4px}.cura-input-group.transparent .input-wrapper{display:-ms-flexbox;display:flex;width:100%;-ms-flex-direction:column;flex-direction:column;-ms-flex-pack:start;justify-content:start}.cura-input-group.transparent cura-label{margin-bottom:4px}.cura-input-group.transparent .cura-input-field{display:-ms-flexbox;display:flex;width:100%;background-color:transparent;border:none;border-radius:0;color:var(--primary-base);height:27px;letter-spacing:0.32px;line-height:20px;overflow:hidden}.cura-input-group.transparent .cura-input-field input{-ms-flex-order:1;order:1;color:var(--neutral-black);font-size:16px;font-weight:var(--font-weight-bold);line-height:20px;letter-spacing:0.32px;padding:0}.cura-input-group.transparent .cura-input-field input::-webkit-input-placeholder{overflow:hidden;text-overflow:ellipsis;font-size:16px;font-style:normal;font-weight:var(--font-weight-medium);line-height:20px;letter-spacing:0.32px;color:var(--neutral-black)}.cura-input-group.transparent .cura-input-field input::-moz-placeholder{overflow:hidden;text-overflow:ellipsis;font-size:16px;font-style:normal;font-weight:var(--font-weight-medium);line-height:20px;letter-spacing:0.32px;color:var(--neutral-black)}.cura-input-group.transparent .cura-input-field input:-ms-input-placeholder{overflow:hidden;text-overflow:ellipsis;font-size:16px;font-style:normal;font-weight:var(--font-weight-medium);line-height:20px;letter-spacing:0.32px;color:var(--neutral-black)}.cura-input-group.transparent .cura-input-field input::-ms-input-placeholder{overflow:hidden;text-overflow:ellipsis;font-size:16px;font-style:normal;font-weight:var(--font-weight-medium);line-height:20px;letter-spacing:0.32px;color:var(--neutral-black)}.cura-input-group.transparent .cura-input-field input::placeholder{overflow:hidden;text-overflow:ellipsis;font-size:16px;font-style:normal;font-weight:var(--font-weight-medium);line-height:20px;letter-spacing:0.32px;color:var(--neutral-black)}.cura-input-group.transparent .cura-input-field .clear-button{-ms-flex-order:2;order:2;cursor:pointer;margin:0 20px 0 0;padding:0}.cura-input-group.transparent .cura-input-field .feedback-icon{-ms-flex-order:3;order:3;margin:0 20px 0 0;padding:6px 0 0 0}.cura-input-group.transparent .cura-input-field cura-loader-circle{-ms-flex-order:2;order:2;margin:0 20px 0 0}.cura-input-group.transparent .helper-text{margin-top:0px}.cura-input-group.transparent.isError .cura-input-field{overflow:hidden}.cura-input-group.transparent.isError .clear-button{cursor:pointer;margin:0 16px 0 0}.cura-input-group.transparent.isError input{letter-spacing:0.32px;line-height:20px;color:var(--error-darker)}.cura-input-group.transparent.isError input::-webkit-input-placeholder{color:var(--error-darker)}.cura-input-group.transparent.isError input::-moz-placeholder{color:var(--error-darker)}.cura-input-group.transparent.isError input:-ms-input-placeholder{color:var(--error-darker)}.cura-input-group.transparent.isError input::-ms-input-placeholder{color:var(--error-darker)}.cura-input-group.transparent.isError input::placeholder{color:var(--error-darker)}.cura-input-group.transparent.isSuccess .cura-input-field{overflow:hidden}.cura-input-group.transparent.isSuccess .clear-button{cursor:pointer;margin:0 16px 0 0}.cura-input-group.transparent.isSuccess input{letter-spacing:0.32px;line-height:20px;color:var(--success-darker)}.cura-input-group.transparent.isSuccess input::-webkit-input-placeholder{color:var(--success-darker)}.cura-input-group.transparent.isSuccess input::-moz-placeholder{color:var(--success-darker)}.cura-input-group.transparent.isSuccess input:-ms-input-placeholder{color:var(--success-darker)}.cura-input-group.transparent.isSuccess input::-ms-input-placeholder{color:var(--success-darker)}.cura-input-group.transparent.isSuccess input::placeholder{color:var(--success-darker)}.cura-input-group.transparent.disabled .cura-input-field{color:var(--neutral-medium)}.cura-input-group.transparent.disabled .cura-input-field input{color:var(--neutral-medium)}.cura-input-group.transparent.disabled .cura-input-field input::-webkit-input-placeholder{color:var(--neutral-medium)}.cura-input-group.transparent.disabled .cura-input-field input::-moz-placeholder{color:var(--neutral-medium)}.cura-input-group.transparent.disabled .cura-input-field input:-ms-input-placeholder{color:var(--neutral-medium)}.cura-input-group.transparent.disabled .cura-input-field input::-ms-input-placeholder{color:var(--neutral-medium)}.cura-input-group.transparent.disabled .cura-input-field input::placeholder{color:var(--neutral-medium)}.cura-input-group.transparent.disabled .cura-input-field .helper-text{color:var(--neutral-medium)}.cura-input-group.small .cura-input-field{height:32px}.cura-input-group.small .cura-input-field input{font-family:var(--font-family);font-weight:var(--font-weight-medium);font-size:12px;font-style:normal;line-height:13px;letter-spacing:0.72px}.cura-input-group.small .helper-text{font-weight:var(--font-weight-regular)}.cura-input-group.medium .cura-input-field{height:40px}.cura-input-group.medium .cura-input-field input{font-family:var(--font-family);font-weight:var(--font-weight-medium);font-size:14px;font-style:normal;line-height:16px;letter-spacing:0.56px}.cura-input-group.medium .helper-text{font-weight:var(--font-weight-regular)}.cura-input-group.large .cura-input-field{height:44px}.cura-input-group.large input::-webkit-input-placeholder{font-family:var(--font-family);font-weight:var(--font-weight-medium);font-size:16px;font-style:normal;line-height:20px;letter-spacing:0.32px}.cura-input-group.large input::-moz-placeholder{font-family:var(--font-family);font-weight:var(--font-weight-medium);font-size:16px;font-style:normal;line-height:20px;letter-spacing:0.32px}.cura-input-group.large input:-ms-input-placeholder{font-family:var(--font-family);font-weight:var(--font-weight-medium);font-size:16px;font-style:normal;line-height:20px;letter-spacing:0.32px}.cura-input-group.large input::-ms-input-placeholder{font-family:var(--font-family);font-weight:var(--font-weight-medium);font-size:16px;font-style:normal;line-height:20px;letter-spacing:0.32px}.cura-input-group.large input::placeholder{font-family:var(--font-family);font-weight:var(--font-weight-medium);font-size:16px;font-style:normal;line-height:20px;letter-spacing:0.32px}.cura-input-group.large .helper-text{font-weight:var(--font-weight-bold)}.cura-input-group input::-webkit-outer-spin-button,.cura-input-group input::-webkit-inner-spin-button{-webkit-appearance:none}";var CuraInputText=function(){function t(t){registerInstance(this,t);this.valueChange=createEvent(this,"valueChange",7);this.mode="default";this.status="default";this.size="medium";this.type="text";this.label="";this.placeholder=null;this.value=undefined;this.iconName="";this.helperText=undefined;this.disabled=false;this.required=false;this.maskPreset=undefined;this.maskRegex=undefined;this.maskAdvanced=undefined;this.maxlength=undefined;this.readOnly=false;this.isLoading=false;this.isHovered=false;this.isFocused=false;this.styles={};this.clearIcon=true}t.prototype.connectedCallback=function(){this.styles["--primary-base"]=window.CuraAPI.theme.colors.getColor("primary-base");this.styles["--neutral-purewhite"]=window.CuraAPI.theme.colors.getColor("neutral-purewhite");this.styles["--neutral-white"]=window.CuraAPI.theme.colors.getColor("neutral-white");this.styles["--neutral-black"]=window.CuraAPI.theme.colors.getColor("neutral-black");this.styles["--neutral-medium"]=window.CuraAPI.theme.colors.getColor("neutral-medium");this.styles["--neutral-base"]=window.CuraAPI.theme.colors.getColor("neutral-base");this.styles["--neutral-dark"]=window.CuraAPI.theme.colors.getColor("neutral-dark");this.styles["--success-dark"]=window.CuraAPI.theme.colors.getColor("success-dark");this.styles["--success-darker"]=window.CuraAPI.theme.colors.getColor("success-darker");this.styles["--success-lighter"]=window.CuraAPI.theme.colors.getColor("success-lighter");this.styles["--error-lighter"]=window.CuraAPI.theme.colors.getColor("error-lighter");this.styles["--error-dark"]=window.CuraAPI.theme.colors.getColor("error-dark");this.styles["--error-darker"]=window.CuraAPI.theme.colors.getColor("error-darker");this.styles["--error-base"]=window.CuraAPI.theme.colors.getColor("error-base");this.styles["--info-base"]=window.CuraAPI.theme.colors.getColor("info-base");this.styles["--font-family"]=window.CuraAPI.theme.fonts.getFamily();this.styles["--font-size"]=window.CuraAPI.theme.fonts.getSize();this.styles["--font-color"]=window.CuraAPI.theme.fonts.getColor();this.weights=window.CuraAPI.theme.fonts.getWeights();this.styles["--font-weight-medium"]=this.weights.medium;this.styles["--font-weight-bold"]=this.weights.bold;this.styles["--font-weight-regular"]=this.weights.regular};t.prototype.getClasses=function(){var t;return t={},t[this.size.toLowerCase()]=this.mode==="default",t.disabled=this.disabled,t.isLoading=this.isLoading,t.isFocused=this.isFocused&&!this.disabled&&!this.readOnly&&!this.isLoading,t.isHovered=this.isHovered,t.isSuccess=this.status==="success",t.isError=this.status==="error",t.transparent=this.mode==="transparent",t};t.prototype.getLabelColor=function(){if(!!this.disabled){return"neutral-medium"}else if(this.isLoading&&this.mode==="transparent"&&!this.isHovered){return"neutral-dark"}else if((this.isFocused||this.isHovered||this.status==="success"||this.status==="error")&&!this.readOnly||this.isHovered){return"neutral-black"}else{return"neutral-dark"}};t.prototype.renderIcon=function(){if(!this.iconName&&this.status==="default"||this.mode==="transparent"&&this.isLoading||this.mode==="transparent"&&this.status==="default"){return}var t=this.size==="large"?20:16;var e=this.mode==="transparent"?20:t;var r={loading:{name:this.iconName,color:"primary-base"},success:{name:"checkCircle",color:"success-dark"},error:{name:"alertCircle",color:"error-dark"},default:{name:this.iconName,color:"neutral-dark"}};var i=r[this.isLoading?"loading":this.status||"default"];return h("div",{class:"feedback-icon",style:this.styles},h("cura-icon",{name:i.name,iconset:"default",size:e,color:i.color}))};t.prototype.renderHelperText=function(){var t=this;var e=this.status==="error";var r=this.status==="success";var i=this.status==="default";var n=this.size==="large"?"small":"xsmall";var a=this.mode==="transparent"?"bold":"regular";var s=function(){if(t.disabled)return"neutral-medium";if(t.isLoading)return"primary-base";if(t.isFocused||t.isHovered)return"neutral-black";return"neutral-dark"}();return h("div",{style:this.styles,class:"helper-text"},i&&h("cura-label",{size:n,color:s,weight:a},h("slot",null)),e&&h("cura-label",{size:n,lineHeight:"xsmall",color:"error-dark",weight:a},h("slot",null)),r&&h("cura-label",{size:n,color:"success-dark",weight:a},h("slot",null)))};t.prototype.componentDidLoad=function(){this.initializeMask()};t.prototype.handleMouseEnter=function(){this.isHovered=true};t.prototype.handleMouseLeave=function(){this.isHovered=false};t.prototype.handleMaskUpdate=function(){if(!!this.maskedInput){this.maskedInput.updateValue()}};t.prototype.handleClearInput=function(){this.handleMaskUpdate();this.value="";this.inputRef.value="";this.handleMaskUpdate()};t.prototype.handleInputFocus=function(){this.handleMaskUpdate();this.isFocused=true};t.prototype.handleInputBlur=function(){var t=this;this.handleMaskUpdate();setTimeout((function(){t.isFocused=false}),150)};t.prototype.handleMaskPresetChange=function(){this.initializeMask()};t.prototype.handleMaskRegexChange=function(){this.initializeMask()};t.prototype.handlemaskAdvancedChange=function(){this.initializeMask()};t.prototype.handleValueChange=function(t){if(this.maskedInput&&this.maskedInput.value!==t){this.maskedInput.value=t}};t.prototype.initializeMask=function(){if(this.maskedInput){this.maskedInput.destroy()}if(!!this.maskRegex){if(typeof this.maskRegex==="string"){var t=this.maskRegex.replace(/^\/|\/[gimsuy]*$/g,"");var e=(this.maskRegex.match(/\/[gimsuy]*$/g)||[""])[0].slice(1);this.maskedInput=IMask(this.inputRef,{mask:new RegExp(t,e)});this.handleMaskUpdate()}else{this.maskedInput=IMask(this.inputRef,{mask:this.maskRegex});this.handleMaskUpdate()}}else if(!!this.maskPreset){var r=maskOptions[this.maskPreset];if(!r){console.error('Mask preset "'.concat(this.maskPreset,'" not found.'));return}this.maskedInput=IMask(this.inputRef,r);if(r===Date){if(this.value){this.maskedInput.typedValue=this.value}}else if(r===Number){if(this.value){this.maskedInput.typedValue=this.value}}else{this.maskedInput.value=this.value||""}}else if(!!this.maskAdvanced){try{if(this.maskAdvanced.constructor===Object){this.maskedInput=IMask(this.inputRef,this.maskAdvanced)}else if(typeof this.maskAdvanced==="string"){this.maskedInput=IMask(this.inputRef,JSON.parse(this.maskAdvanced))}}catch(t){console.error("Erro ao definir a maskAdvanced:",t)}}this.handleMaskUpdate()};t.prototype.handleInputChange=function(t){var e=t.target.value;if(this.type==="number"){var r=parseFloat(e);if(!isNaN(r)){this.value=r;this.valueChange.emit(r)}else{console.error("Invalid input:",e)}}if(this.maskedInput){if(this.maskedInput.mask instanceof Date||this.maskedInput.mask===Number){this.maskedInput.typedValue=e;this.value=this.maskedInput.typedValue}else{this.maskedInput.value=e;this.value=this.maskedInput.value}}this.value=e;this.valueChange.emit(this.value)};t.prototype.handleKeyDown=function(t){this.handleMaskUpdate();this.type==="number"?this.handleBlockInvalidNumber(t):undefined};t.prototype.handleBlockInvalidNumber=function(t){return["e","E","+","-"].includes(t.key)&&t.preventDefault()};t.prototype.render=function(){var t=this;return h(Host,null,h("div",{style:this.styles,onMouseEnter:function(){return t.handleMouseEnter()},onMouseLeave:function(){return t.handleMouseLeave()},class:Object.assign({"cura-input-group":true},this.getClasses())},h("div",{class:"input-wrapper"},this.label&&h("cura-label",{class:"label",weight:"bold",size:this.size==="large"?"small":"xsmall",color:this.getLabelColor()},this.label," ",this.required&&h("span",{class:"required"},"* ")),h("div",{class:"cura-input-field",style:this.styles},this.renderIcon(),h("input",{type:this.type,autocomplete:"off","aria-autocomplete":"none","aria-required":this.required?"true":"false","aria-disabled":this.disabled?"true":"false","aria-invalid":this.status==="error"?"true":"false","aria-readonly":this.readOnly?"true":"false",onKeyDown:function(e){return t.handleKeyDown(e)},onBlur:this.handleInputBlur.bind(this),onFocus:this.handleInputFocus.bind(this),onInput:function(e){return t.handleInputChange(e)},class:this.getClasses(),style:this.styles,placeholder:this.placeholder,disabled:this.disabled||this.isLoading,required:this.required,readonly:this.readOnly,maxlength:this.maxlength,value:this.value,ref:function(e){return t.inputRef=e}}),!!this.clearIcon&&!this.readOnly&&!this.isLoading&&!this.disabled&&this.value&&this.isFocused&&h("cura-icon",{size:this.size==="large"?20:16,color:"primary-base",name:"closeCircle",iconset:"default",class:"clear-button",onClick:function(){return t.handleClearInput()}}),this.isLoading&&h("cura-loader-circle",{size:this.size==="large"?"medium":"small",color:"primary-base"})),this.renderHelperText())))};Object.defineProperty(t,"watchers",{get:function(){return{styles:["connectedCallback"],size:["getClasses"],status:["renderIcon"],mode:["renderIcon"],maskPreset:["handleMaskPresetChange"],maskRegex:["handleMaskRegexChange"],maskAdvanced:["handlemaskAdvancedChange"],value:["handleValueChange"]}},enumerable:false,configurable:true});return t}();CuraInputText.style=curaInputTextCss;export{CuraInputText as cura_input_text};
2
+ //# sourceMappingURL=cura-input-text.entry.js.map