@db-ux/wc-core-components 2.0.8 → 2.0.10-popover-d7e8b9a

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 (312) hide show
  1. package/dist/cjs/db-accordion-item.cjs.entry.js +1 -1
  2. package/dist/cjs/db-accordion.cjs.entry.js +1 -1
  3. package/dist/cjs/db-badge.cjs.entry.js +1 -1
  4. package/dist/cjs/db-brand.cjs.entry.js +1 -1
  5. package/dist/cjs/db-button.cjs.entry.js +3 -3
  6. package/dist/cjs/db-button.cjs.entry.js.map +1 -1
  7. package/dist/cjs/db-button.entry.cjs.js.map +1 -1
  8. package/dist/cjs/db-card.cjs.entry.js +4 -4
  9. package/dist/cjs/db-card.cjs.entry.js.map +1 -1
  10. package/dist/cjs/db-card.entry.cjs.js.map +1 -1
  11. package/dist/cjs/db-checkbox.cjs.entry.js +4 -3
  12. package/dist/cjs/db-checkbox.cjs.entry.js.map +1 -1
  13. package/dist/cjs/db-checkbox.entry.cjs.js.map +1 -1
  14. package/dist/cjs/db-custom-select-dropdown.db-custom-select-list.db-custom-select-list-item.db-input.db-tag.db-tooltip.entry.cjs.js.map +1 -1
  15. package/dist/cjs/db-custom-select-dropdown_6.cjs.entry.js +65 -13
  16. package/dist/cjs/db-custom-select-dropdown_6.cjs.entry.js.map +1 -1
  17. package/dist/cjs/db-custom-select-form-field.cjs.entry.js +1 -1
  18. package/dist/cjs/db-custom-select.cjs.entry.js +104 -67
  19. package/dist/cjs/db-custom-select.cjs.entry.js.map +1 -1
  20. package/dist/cjs/db-custom-select.entry.cjs.js.map +1 -1
  21. package/dist/cjs/db-divider.cjs.entry.js +1 -1
  22. package/dist/cjs/db-drawer.cjs.entry.js +1 -1
  23. package/dist/cjs/db-header.cjs.entry.js +3 -2
  24. package/dist/cjs/db-header.cjs.entry.js.map +1 -1
  25. package/dist/cjs/db-header.entry.cjs.js.map +1 -1
  26. package/dist/cjs/db-icon.cjs.entry.js +1 -1
  27. package/dist/cjs/db-infotext.cjs.entry.js +1 -1
  28. package/dist/cjs/db-link.cjs.entry.js +3 -3
  29. package/dist/cjs/db-link.cjs.entry.js.map +1 -1
  30. package/dist/cjs/db-link.entry.cjs.js.map +1 -1
  31. package/dist/cjs/db-navigation-item.cjs.entry.js +5 -4
  32. package/dist/cjs/db-navigation-item.cjs.entry.js.map +1 -1
  33. package/dist/cjs/db-navigation-item.entry.cjs.js.map +1 -1
  34. package/dist/cjs/db-navigation.cjs.entry.js +1 -1
  35. package/dist/cjs/db-notification.cjs.entry.js +1 -1
  36. package/dist/cjs/db-page.cjs.entry.js +1 -1
  37. package/dist/cjs/db-popover.cjs.entry.js +64 -10
  38. package/dist/cjs/db-popover.cjs.entry.js.map +1 -1
  39. package/dist/cjs/db-popover.entry.cjs.js.map +1 -1
  40. package/dist/cjs/db-radio.cjs.entry.js +4 -3
  41. package/dist/cjs/db-radio.cjs.entry.js.map +1 -1
  42. package/dist/cjs/db-radio.entry.cjs.js.map +1 -1
  43. package/dist/cjs/db-section.cjs.entry.js +1 -1
  44. package/dist/cjs/db-select.cjs.entry.js +6 -6
  45. package/dist/cjs/db-select.cjs.entry.js.map +1 -1
  46. package/dist/cjs/db-select.entry.cjs.js.map +1 -1
  47. package/dist/cjs/db-stack.cjs.entry.js +1 -1
  48. package/dist/cjs/db-switch.cjs.entry.js +4 -3
  49. package/dist/cjs/db-switch.cjs.entry.js.map +1 -1
  50. package/dist/cjs/db-switch.entry.cjs.js.map +1 -1
  51. package/dist/cjs/db-tab-item_3.cjs.entry.js +1 -1
  52. package/dist/cjs/db-tabs.cjs.entry.js +1 -1
  53. package/dist/cjs/db-textarea.cjs.entry.js +4 -4
  54. package/dist/cjs/db-textarea.cjs.entry.js.map +1 -1
  55. package/dist/cjs/db-textarea.entry.cjs.js.map +1 -1
  56. package/dist/cjs/db-ux.cjs.js +1 -1
  57. package/dist/cjs/{document-click-listener-BbGE8WyV.js → document-click-listener-BqewuQFB.js} +7 -7
  58. package/dist/cjs/document-click-listener-BqewuQFB.js.map +1 -0
  59. package/dist/cjs/document-scroll-listener-DsZwE3e9.js +46 -0
  60. package/dist/cjs/document-scroll-listener-DsZwE3e9.js.map +1 -0
  61. package/dist/cjs/floating-components-BNCfdqZJ.js +299 -0
  62. package/dist/cjs/floating-components-BNCfdqZJ.js.map +1 -0
  63. package/dist/cjs/{index-7lbP4BU6.js → index-4GRgVEnx.js} +2 -76
  64. package/dist/cjs/index-4GRgVEnx.js.map +1 -0
  65. package/dist/cjs/index.cjs.js +5 -7
  66. package/dist/cjs/index.cjs.js.map +1 -1
  67. package/dist/cjs/loader.cjs.js +1 -1
  68. package/dist/cjs/{navigation-BLjJ1vaO.js → navigation-U4SBgT7D.js} +4 -4
  69. package/dist/cjs/navigation-U4SBgT7D.js.map +1 -0
  70. package/dist/collection/components/button/button.js +2 -2
  71. package/dist/collection/components/button/button.js.map +1 -1
  72. package/dist/collection/components/card/card.js +3 -3
  73. package/dist/collection/components/card/card.js.map +1 -1
  74. package/dist/collection/components/checkbox/checkbox.js +28 -2
  75. package/dist/collection/components/checkbox/checkbox.js.map +1 -1
  76. package/dist/collection/components/custom-select/custom-select.js +144 -80
  77. package/dist/collection/components/custom-select/custom-select.js.map +1 -1
  78. package/dist/collection/components/custom-select/model.js.map +1 -1
  79. package/dist/collection/components/icon/icon.js +1 -1
  80. package/dist/collection/components/icon/model.js +0 -1
  81. package/dist/collection/components/icon/model.js.map +1 -1
  82. package/dist/collection/components/link/link.js +2 -2
  83. package/dist/collection/components/link/link.js.map +1 -1
  84. package/dist/collection/components/navigation-item/navigation-item.js +2 -2
  85. package/dist/collection/components/navigation-item/navigation-item.js.map +1 -1
  86. package/dist/collection/components/popover/model.js.map +1 -1
  87. package/dist/collection/components/popover/popover.js +92 -36
  88. package/dist/collection/components/popover/popover.js.map +1 -1
  89. package/dist/collection/components/radio/model.js.map +1 -1
  90. package/dist/collection/components/radio/radio.js +28 -2
  91. package/dist/collection/components/radio/radio.js.map +1 -1
  92. package/dist/collection/components/select/model.js.map +1 -1
  93. package/dist/collection/components/select/select.js +30 -5
  94. package/dist/collection/components/select/select.js.map +1 -1
  95. package/dist/collection/components/switch/switch.js +28 -2
  96. package/dist/collection/components/switch/switch.js.map +1 -1
  97. package/dist/collection/components/textarea/textarea.js +28 -3
  98. package/dist/collection/components/textarea/textarea.js.map +1 -1
  99. package/dist/collection/components/tooltip/model.js.map +1 -1
  100. package/dist/collection/components/tooltip/tooltip.js +93 -39
  101. package/dist/collection/components/tooltip/tooltip.js.map +1 -1
  102. package/dist/collection/shared/model.js.map +1 -1
  103. package/dist/collection/utils/document-click-listener.js +4 -4
  104. package/dist/collection/utils/document-click-listener.js.map +1 -1
  105. package/dist/collection/utils/document-scroll-listener.js +39 -0
  106. package/dist/collection/utils/document-scroll-listener.js.map +1 -0
  107. package/dist/collection/utils/floating-components.js +291 -0
  108. package/dist/collection/utils/floating-components.js.map +1 -0
  109. package/dist/collection/utils/index.js +0 -70
  110. package/dist/collection/utils/index.js.map +1 -1
  111. package/dist/collection/utils/navigation.js +1 -1
  112. package/dist/collection/utils/navigation.js.map +1 -1
  113. package/dist/custom-elements.json +425 -114
  114. package/dist/db-ux/db-button.entry.esm.js.map +1 -1
  115. package/dist/db-ux/db-card.entry.esm.js.map +1 -1
  116. package/dist/db-ux/db-checkbox.entry.esm.js.map +1 -1
  117. package/dist/db-ux/db-custom-select-dropdown.db-custom-select-list.db-custom-select-list-item.db-input.db-tag.db-tooltip.entry.esm.js.map +1 -1
  118. package/dist/db-ux/db-custom-select.entry.esm.js.map +1 -1
  119. package/dist/db-ux/db-header.entry.esm.js.map +1 -1
  120. package/dist/db-ux/db-link.entry.esm.js.map +1 -1
  121. package/dist/db-ux/db-navigation-item.entry.esm.js.map +1 -1
  122. package/dist/db-ux/db-popover.entry.esm.js.map +1 -1
  123. package/dist/db-ux/db-radio.entry.esm.js.map +1 -1
  124. package/dist/db-ux/db-select.entry.esm.js.map +1 -1
  125. package/dist/db-ux/db-switch.entry.esm.js.map +1 -1
  126. package/dist/db-ux/db-textarea.entry.esm.js.map +1 -1
  127. package/dist/db-ux/db-ux.esm.js +1 -1
  128. package/dist/db-ux/index.esm.js +1 -1
  129. package/dist/db-ux/index.esm.js.map +1 -1
  130. package/dist/db-ux/{p-8b7d868b.entry.js → p-00ae6c1c.entry.js} +2 -2
  131. package/dist/db-ux/{p-50c9112b.entry.js → p-0bf63ec2.entry.js} +2 -2
  132. package/dist/db-ux/p-0bf63ec2.entry.js.map +1 -0
  133. package/dist/db-ux/p-166b337e.entry.js +2 -0
  134. package/dist/db-ux/{p-39d957bb.entry.js.map → p-166b337e.entry.js.map} +1 -1
  135. package/dist/db-ux/p-16f8a2d5.entry.js +2 -0
  136. package/dist/db-ux/p-16f8a2d5.entry.js.map +1 -0
  137. package/dist/db-ux/p-199c8a0f.entry.js +2 -0
  138. package/dist/db-ux/p-199c8a0f.entry.js.map +1 -0
  139. package/dist/db-ux/{p-55b02c80.entry.js → p-240497d9.entry.js} +2 -2
  140. package/dist/db-ux/p-2e0f291f.entry.js +2 -0
  141. package/dist/db-ux/p-2e0f291f.entry.js.map +1 -0
  142. package/dist/db-ux/p-3df47dd9.entry.js +2 -0
  143. package/dist/db-ux/p-3df47dd9.entry.js.map +1 -0
  144. package/dist/db-ux/p-423bf8f8.entry.js +2 -0
  145. package/dist/db-ux/p-423bf8f8.entry.js.map +1 -0
  146. package/dist/db-ux/p-4aa47b47.entry.js +2 -0
  147. package/dist/db-ux/p-4aa47b47.entry.js.map +1 -0
  148. package/dist/db-ux/{p-b3148401.entry.js → p-4b52b854.entry.js} +2 -2
  149. package/dist/db-ux/{p-63f30576.entry.js → p-57c4486c.entry.js} +2 -2
  150. package/dist/db-ux/p-5fdc8db6.entry.js +2 -0
  151. package/dist/db-ux/p-5fdc8db6.entry.js.map +1 -0
  152. package/dist/db-ux/{p-49cc4a11.entry.js → p-63f1d771.entry.js} +2 -2
  153. package/dist/db-ux/p-75a55c2c.entry.js +2 -0
  154. package/dist/db-ux/{p-5c2e9373.entry.js.map → p-75a55c2c.entry.js.map} +1 -1
  155. package/dist/db-ux/{p-d7ccd983.entry.js → p-7636be02.entry.js} +2 -2
  156. package/dist/db-ux/{p-52e736c3.entry.js → p-769c530c.entry.js} +2 -2
  157. package/dist/db-ux/p-80f23995.entry.js +2 -0
  158. package/dist/db-ux/p-80f23995.entry.js.map +1 -0
  159. package/dist/db-ux/{p-6wgV8aKO.js → p-BDA9dlfd.js} +2 -2
  160. package/dist/db-ux/p-BDA9dlfd.js.map +1 -0
  161. package/dist/db-ux/p-C8WY_RwJ.js +2 -0
  162. package/dist/db-ux/p-C8WY_RwJ.js.map +1 -0
  163. package/dist/db-ux/p-CQCQcuvr.js +2 -0
  164. package/dist/db-ux/p-CQCQcuvr.js.map +1 -0
  165. package/dist/db-ux/p-CqteyeC3.js +2 -0
  166. package/dist/db-ux/p-CqteyeC3.js.map +1 -0
  167. package/dist/db-ux/p-DYeQU2bY.js +2 -0
  168. package/dist/db-ux/p-DYeQU2bY.js.map +1 -0
  169. package/dist/db-ux/{p-c151750e.entry.js → p-a4d62218.entry.js} +2 -2
  170. package/dist/db-ux/{p-6b6dbd54.entry.js → p-aae2a35a.entry.js} +2 -2
  171. package/dist/db-ux/{p-61410d87.entry.js → p-ab7f29be.entry.js} +2 -2
  172. package/dist/db-ux/p-ab7f29be.entry.js.map +1 -0
  173. package/dist/db-ux/{p-c5909b40.entry.js → p-b5e12faa.entry.js} +2 -2
  174. package/dist/db-ux/{p-33aaf986.entry.js → p-c615e5e6.entry.js} +2 -2
  175. package/dist/db-ux/p-c615e5e6.entry.js.map +1 -0
  176. package/dist/db-ux/{p-b4bc8f26.entry.js → p-cc6df17e.entry.js} +2 -2
  177. package/dist/db-ux/{p-4400f077.entry.js → p-d28395c3.entry.js} +2 -2
  178. package/dist/db-ux/p-d45c03e4.entry.js +2 -0
  179. package/dist/db-ux/p-d45c03e4.entry.js.map +1 -0
  180. package/dist/db-ux/{p-5c4d25b8.entry.js → p-d64ea737.entry.js} +2 -2
  181. package/dist/db-ux/{p-14c44b94.entry.js → p-da2d2518.entry.js} +2 -2
  182. package/dist/db-ux/p-f17426ab.entry.js +2 -0
  183. package/dist/db-ux/{p-01112955.entry.js.map → p-f17426ab.entry.js.map} +1 -1
  184. package/dist/esm/db-accordion-item.entry.js +1 -1
  185. package/dist/esm/db-accordion.entry.js +1 -1
  186. package/dist/esm/db-badge.entry.js +1 -1
  187. package/dist/esm/db-brand.entry.js +1 -1
  188. package/dist/esm/db-button.entry.js +3 -3
  189. package/dist/esm/db-button.entry.js.map +1 -1
  190. package/dist/esm/db-card.entry.js +4 -4
  191. package/dist/esm/db-card.entry.js.map +1 -1
  192. package/dist/esm/db-checkbox.entry.js +4 -3
  193. package/dist/esm/db-checkbox.entry.js.map +1 -1
  194. package/dist/esm/db-custom-select-dropdown.db-custom-select-list.db-custom-select-list-item.db-input.db-tag.db-tooltip.entry.js.map +1 -1
  195. package/dist/esm/db-custom-select-dropdown_6.entry.js +65 -13
  196. package/dist/esm/db-custom-select-dropdown_6.entry.js.map +1 -1
  197. package/dist/esm/db-custom-select-form-field.entry.js +1 -1
  198. package/dist/esm/db-custom-select.entry.js +104 -67
  199. package/dist/esm/db-custom-select.entry.js.map +1 -1
  200. package/dist/esm/db-divider.entry.js +1 -1
  201. package/dist/esm/db-drawer.entry.js +1 -1
  202. package/dist/esm/db-header.entry.js +3 -2
  203. package/dist/esm/db-header.entry.js.map +1 -1
  204. package/dist/esm/db-icon.entry.js +1 -1
  205. package/dist/esm/db-infotext.entry.js +1 -1
  206. package/dist/esm/db-link.entry.js +3 -3
  207. package/dist/esm/db-link.entry.js.map +1 -1
  208. package/dist/esm/db-navigation-item.entry.js +5 -4
  209. package/dist/esm/db-navigation-item.entry.js.map +1 -1
  210. package/dist/esm/db-navigation.entry.js +1 -1
  211. package/dist/esm/db-notification.entry.js +1 -1
  212. package/dist/esm/db-page.entry.js +1 -1
  213. package/dist/esm/db-popover.entry.js +64 -10
  214. package/dist/esm/db-popover.entry.js.map +1 -1
  215. package/dist/esm/db-radio.entry.js +4 -3
  216. package/dist/esm/db-radio.entry.js.map +1 -1
  217. package/dist/esm/db-section.entry.js +1 -1
  218. package/dist/esm/db-select.entry.js +6 -6
  219. package/dist/esm/db-select.entry.js.map +1 -1
  220. package/dist/esm/db-stack.entry.js +1 -1
  221. package/dist/esm/db-switch.entry.js +4 -3
  222. package/dist/esm/db-switch.entry.js.map +1 -1
  223. package/dist/esm/db-tab-item_3.entry.js +1 -1
  224. package/dist/esm/db-tabs.entry.js +1 -1
  225. package/dist/esm/db-textarea.entry.js +4 -4
  226. package/dist/esm/db-textarea.entry.js.map +1 -1
  227. package/dist/esm/db-ux.js +1 -1
  228. package/dist/esm/{document-click-listener-Bn3nIGhA.js → document-click-listener-CsfOzbMG.js} +7 -7
  229. package/dist/esm/document-click-listener-CsfOzbMG.js.map +1 -0
  230. package/dist/esm/document-scroll-listener-QnsLRkL2.js +44 -0
  231. package/dist/esm/document-scroll-listener-QnsLRkL2.js.map +1 -0
  232. package/dist/esm/floating-components-DYeQU2bY.js +295 -0
  233. package/dist/esm/floating-components-DYeQU2bY.js.map +1 -0
  234. package/dist/esm/{index-pglUTSkG.js → index-CQCQcuvr.js} +3 -73
  235. package/dist/esm/index-CQCQcuvr.js.map +1 -0
  236. package/dist/esm/index.js +5 -3
  237. package/dist/esm/index.js.map +1 -1
  238. package/dist/esm/loader.js +1 -1
  239. package/dist/esm/{navigation-C1ssnmpm.js → navigation-CE_2IUA4.js} +3 -3
  240. package/dist/esm/navigation-CE_2IUA4.js.map +1 -0
  241. package/dist/types/components/checkbox/checkbox.d.ts +1 -0
  242. package/dist/types/components/custom-select/custom-select.d.ts +10 -6
  243. package/dist/types/components/custom-select/model.d.ts +6 -5
  244. package/dist/types/components/icon/model.d.ts +1 -3
  245. package/dist/types/components/popover/model.d.ts +0 -1
  246. package/dist/types/components/popover/popover.d.ts +7 -2
  247. package/dist/types/components/radio/model.d.ts +1 -3
  248. package/dist/types/components/radio/radio.d.ts +1 -0
  249. package/dist/types/components/select/model.d.ts +2 -1
  250. package/dist/types/components/select/select.d.ts +1 -0
  251. package/dist/types/components/switch/switch.d.ts +1 -0
  252. package/dist/types/components/textarea/textarea.d.ts +1 -0
  253. package/dist/types/components/tooltip/model.d.ts +5 -3
  254. package/dist/types/components/tooltip/tooltip.d.ts +9 -2
  255. package/dist/types/components.d.ts +12 -0
  256. package/dist/types/shared/model.d.ts +12 -3
  257. package/dist/types/utils/document-scroll-listener.d.ts +9 -0
  258. package/dist/types/utils/floating-components.d.ts +7 -0
  259. package/dist/types/utils/index.d.ts +0 -13
  260. package/dist/types/utils/navigation.d.ts +1 -1
  261. package/dist/vscode.html-custom-data.json +52 -41
  262. package/dist/web-types.json +110 -58
  263. package/package.json +3 -3
  264. package/dist/cjs/document-click-listener-BbGE8WyV.js.map +0 -1
  265. package/dist/cjs/index-7lbP4BU6.js.map +0 -1
  266. package/dist/cjs/navigation-BLjJ1vaO.js.map +0 -1
  267. package/dist/db-ux/p-01112955.entry.js +0 -2
  268. package/dist/db-ux/p-049844c6.entry.js +0 -2
  269. package/dist/db-ux/p-049844c6.entry.js.map +0 -1
  270. package/dist/db-ux/p-1d40e8cd.entry.js +0 -2
  271. package/dist/db-ux/p-1d40e8cd.entry.js.map +0 -1
  272. package/dist/db-ux/p-33aaf986.entry.js.map +0 -1
  273. package/dist/db-ux/p-39d957bb.entry.js +0 -2
  274. package/dist/db-ux/p-44f6404b.entry.js +0 -2
  275. package/dist/db-ux/p-44f6404b.entry.js.map +0 -1
  276. package/dist/db-ux/p-50c9112b.entry.js.map +0 -1
  277. package/dist/db-ux/p-5c2e9373.entry.js +0 -2
  278. package/dist/db-ux/p-61410d87.entry.js.map +0 -1
  279. package/dist/db-ux/p-623a9409.entry.js +0 -2
  280. package/dist/db-ux/p-623a9409.entry.js.map +0 -1
  281. package/dist/db-ux/p-6wgV8aKO.js.map +0 -1
  282. package/dist/db-ux/p-DszXleuv.js +0 -2
  283. package/dist/db-ux/p-DszXleuv.js.map +0 -1
  284. package/dist/db-ux/p-a1ee66b3.entry.js +0 -2
  285. package/dist/db-ux/p-a1ee66b3.entry.js.map +0 -1
  286. package/dist/db-ux/p-b5a8e9c3.entry.js +0 -2
  287. package/dist/db-ux/p-b5a8e9c3.entry.js.map +0 -1
  288. package/dist/db-ux/p-c989b5d8.entry.js +0 -2
  289. package/dist/db-ux/p-c989b5d8.entry.js.map +0 -1
  290. package/dist/db-ux/p-d9ff0c75.entry.js +0 -2
  291. package/dist/db-ux/p-d9ff0c75.entry.js.map +0 -1
  292. package/dist/db-ux/p-f2ef5e71.entry.js +0 -2
  293. package/dist/db-ux/p-f2ef5e71.entry.js.map +0 -1
  294. package/dist/db-ux/p-pglUTSkG.js +0 -2
  295. package/dist/db-ux/p-pglUTSkG.js.map +0 -1
  296. package/dist/esm/document-click-listener-Bn3nIGhA.js.map +0 -1
  297. package/dist/esm/index-pglUTSkG.js.map +0 -1
  298. package/dist/esm/navigation-C1ssnmpm.js.map +0 -1
  299. /package/dist/db-ux/{p-8b7d868b.entry.js.map → p-00ae6c1c.entry.js.map} +0 -0
  300. /package/dist/db-ux/{p-55b02c80.entry.js.map → p-240497d9.entry.js.map} +0 -0
  301. /package/dist/db-ux/{p-b3148401.entry.js.map → p-4b52b854.entry.js.map} +0 -0
  302. /package/dist/db-ux/{p-63f30576.entry.js.map → p-57c4486c.entry.js.map} +0 -0
  303. /package/dist/db-ux/{p-49cc4a11.entry.js.map → p-63f1d771.entry.js.map} +0 -0
  304. /package/dist/db-ux/{p-d7ccd983.entry.js.map → p-7636be02.entry.js.map} +0 -0
  305. /package/dist/db-ux/{p-52e736c3.entry.js.map → p-769c530c.entry.js.map} +0 -0
  306. /package/dist/db-ux/{p-c151750e.entry.js.map → p-a4d62218.entry.js.map} +0 -0
  307. /package/dist/db-ux/{p-6b6dbd54.entry.js.map → p-aae2a35a.entry.js.map} +0 -0
  308. /package/dist/db-ux/{p-c5909b40.entry.js.map → p-b5e12faa.entry.js.map} +0 -0
  309. /package/dist/db-ux/{p-b4bc8f26.entry.js.map → p-cc6df17e.entry.js.map} +0 -0
  310. /package/dist/db-ux/{p-4400f077.entry.js.map → p-d28395c3.entry.js.map} +0 -0
  311. /package/dist/db-ux/{p-5c4d25b8.entry.js.map → p-d64ea737.entry.js.map} +0 -0
  312. /package/dist/db-ux/{p-14c44b94.entry.js.map → p-da2d2518.entry.js.map} +0 -0
@@ -1 +1 @@
1
- {"version":3,"file":"db-select.entry.esm.js","sources":["src/components/select/select.tsx"],"sourcesContent":["import { DBSelectOptionType, DBSelectProps, DBSelectState } from \"./model\";\nimport {\n cls,\n delay,\n getBoolean,\n getHideProp,\n hasVoiceOver,\n stringPropVisible,\n uuid,\n} from \"../../utils\";\nimport {\n DEFAULT_INVALID_MESSAGE,\n DEFAULT_INVALID_MESSAGE_ID_SUFFIX,\n DEFAULT_LABEL,\n DEFAULT_MESSAGE_ID_SUFFIX,\n DEFAULT_PLACEHOLDER_ID_SUFFIX,\n DEFAULT_VALID_MESSAGE,\n DEFAULT_VALID_MESSAGE_ID_SUFFIX,\n} from \"../../shared/constants\";\nimport { DBInfotext } from \"../infotext/infotext\";\nimport {\n ChangeEvent,\n ClickEvent,\n InputEvent,\n InteractionEvent,\n} from \"../../shared/model\";\nimport {\n handleFrameworkEventAngular,\n handleFrameworkEventVue,\n} from \"../../utils/form-components\";\n\nimport {\n Component,\n h,\n Fragment,\n Watch,\n Event,\n EventEmitter,\n Prop,\n State,\n} from \"@stencil/core\";\n\n\n/**\n * @slot children - This is a default/unnamed slot\n\n */\n @Component({\n tag: \"db-select\",\n})\nexport class DBSelect {\n private _ref!: HTMLSelectElement | any;\n @Prop() id: DBSelectProps[\"id\"];\n @Prop() invalidMessage: DBSelectProps[\"invalidMessage\"];\n @Prop() message: DBSelectProps[\"message\"];\n @Prop() showMessage: DBSelectProps[\"showMessage\"];\n @Prop() value: DBSelectProps[\"value\"];\n @Prop() validMessage: DBSelectProps[\"validMessage\"];\n @Prop() validation: DBSelectProps[\"validation\"];\n @Prop() required: DBSelectProps[\"required\"];\n @Event() click: EventEmitter<\n Parameters<Required<DBSelectProps>[\"onClick\"]>[number]\n > | void;\n @Event() input: EventEmitter<\n Parameters<Required<DBSelectProps>[\"onInput\"]>[number]\n > | void;\n @Event() change: EventEmitter<\n Parameters<Required<DBSelectProps>[\"onChange\"]>[number]\n > | void;\n @Event() blur: EventEmitter<\n Parameters<Required<DBSelectProps>[\"onBlur\"]>[number]\n > | void;\n @Event() focus: EventEmitter<\n Parameters<Required<DBSelectProps>[\"onFocus\"]>[number]\n > | void;\n @Prop({attribute: \"classname\"}) className: DBSelectProps[\"className\"];\n @Prop() variant: DBSelectProps[\"variant\"];\n @Prop() showLabel: DBSelectProps[\"showLabel\"];\n @Prop() icon: DBSelectProps[\"icon\"];\n @Prop() showIcon: DBSelectProps[\"showIcon\"];\n @Prop() label: DBSelectProps[\"label\"];\n @Prop() disabled: DBSelectProps[\"disabled\"];\n @Prop() name: DBSelectProps[\"name\"];\n @Prop() size: DBSelectProps[\"size\"];\n @Prop() autocomplete: DBSelectProps[\"autocomplete\"];\n @Prop() multiple: DBSelectProps[\"multiple\"];\n @Prop() options: DBSelectProps[\"options\"];\n @Prop() placeholder: DBSelectProps[\"placeholder\"];\n @Prop() messageIcon: DBSelectProps[\"messageIcon\"];\n @State() _id = undefined;\n @State() _messageId = undefined;\n @State() _validMessageId = undefined;\n @State() _invalidMessageId = undefined;\n @State() _invalidMessage = undefined;\n @State() _placeholderId = \"\";\n @State() _descByIds = \"\";\n @State() _value = \"\";\n @State() initialized = false;\n @State() _voiceOverFallback = \"\";\n\n hasValidState() {\n return !!(this.validMessage ?? this.validation === \"valid\");\n }\n handleValidation() {\n /* For a11y reasons we need to map the correct message with the select */\n if (!this._ref?.validity.valid || this.validation === \"invalid\") {\n this._descByIds = this._invalidMessageId;\n this._invalidMessage =\n this.invalidMessage ||\n this._ref?.validationMessage ||\n DEFAULT_INVALID_MESSAGE;\n if (hasVoiceOver()) {\n this._voiceOverFallback = this._invalidMessage;\n delay(() => (this._voiceOverFallback = \"\"), 1000);\n }\n } else if (\n this.hasValidState() &&\n this._ref?.validity.valid &&\n this.required\n ) {\n this._descByIds = this._validMessageId;\n if (hasVoiceOver()) {\n this._voiceOverFallback = this.validMessage ?? DEFAULT_VALID_MESSAGE;\n delay(() => (this._voiceOverFallback = \"\"), 1000);\n }\n } else if (stringPropVisible(this.message, this.showMessage)) {\n this._descByIds = this._messageId;\n } else {\n this._descByIds = this._placeholderId;\n }\n }\n handleClick(event: ClickEvent<HTMLSelectElement> | any) {\n event.stopPropagation();\n if (this.click) {\n this.click.emit(event);\n }\n }\n handleInput(event: InputEvent<HTMLSelectElement> | any) {\n event.stopPropagation();\n if (this.input) {\n this.input.emit(event);\n }\n this.handleValidation();\n }\n handleChange(event: ChangeEvent<HTMLSelectElement> | any) {\n event.stopPropagation();\n if (this.change) {\n this.change.emit(event);\n }\n this.handleValidation();\n }\n handleBlur(event: InteractionEvent<HTMLSelectElement> | any) {\n event.stopPropagation();\n if (this.blur) {\n this.blur.emit(event);\n }\n }\n handleFocus(event: InteractionEvent<HTMLSelectElement> | any) {\n event.stopPropagation();\n if (this.focus) {\n this.focus.emit(event);\n }\n }\n getOptionLabel(option: DBSelectOptionType) {\n return option.label ?? option.value?.toString();\n }\n\n /**\n * Passes `aria-*`, `data-*` & `class` attributes to correct child. Used in angular and stencil.\n * @param element the ref for the component\n * @param customElementSelector the custom element like `my-component`\n */\n private enableAttributePassing(\n element: HTMLSelectElement | null,\n customElementSelector: string\n ) {\n const parent = element?.closest(customElementSelector);\n if (element && parent) {\n const attributes = parent.attributes;\n for (let i = 0; i < attributes.length; i++) {\n const attr = attributes.item(i);\n if (\n attr &&\n (attr.name.startsWith(\"data-\") || attr.name.startsWith(\"aria-\"))\n ) {\n element.setAttribute(attr.name, attr.value);\n parent.removeAttribute(attr.name);\n }\n if (attr && attr.name === \"class\") {\n const isWebComponent = attr.value.includes(\"hydrated\");\n const value = attr.value.replace(\"hydrated\", \"\").trim();\n const currentClass = element.getAttribute(\"class\");\n element.setAttribute(\n attr.name,\n `${currentClass ? `${currentClass} ` : \"\"}${value}`\n );\n if (isWebComponent) {\n // Stencil is using this class for lazy loading component\n parent.setAttribute(\"class\", \"hydrated\");\n } else {\n parent.removeAttribute(attr.name);\n }\n }\n }\n }\n }\n\n watch0Fn() {\n this._invalidMessage =\n this.invalidMessage ||\n this._ref?.validationMessage ||\n DEFAULT_INVALID_MESSAGE;\n }\n\n @Watch(\"_ref\")\n @Watch(\"invalidMessage\")\n watch0() {\n this.watch0Fn();\n }\n\n watch1Fn() {\n if (this._id && this.initialized) {\n const messageId = this._id + DEFAULT_MESSAGE_ID_SUFFIX;\n const placeholderId = this._id + DEFAULT_PLACEHOLDER_ID_SUFFIX;\n this._messageId = messageId;\n this._validMessageId = this._id + DEFAULT_VALID_MESSAGE_ID_SUFFIX;\n this._invalidMessageId = this._id + DEFAULT_INVALID_MESSAGE_ID_SUFFIX;\n this._placeholderId = placeholderId;\n if (stringPropVisible(this.message, this.showMessage)) {\n this._descByIds = messageId;\n } else {\n this._descByIds = placeholderId;\n }\n this.initialized = false;\n }\n }\n\n @Watch(\"_id\")\n @Watch(\"initialized\")\n watch1() {\n this.watch1Fn();\n }\n\n watch2Fn() {\n this._value = this.value;\n }\n\n @Watch(\"value\")\n watch2() {\n this.watch2Fn();\n }\n\n componentDidLoad() {\n this.enableAttributePassing(this._ref, \"db-select\");\n this.initialized = true;\n const mId = this.id ?? `select-${uuid()}`;\n this._id = mId;\n this._messageId = mId + DEFAULT_MESSAGE_ID_SUFFIX;\n this._validMessageId = mId + DEFAULT_VALID_MESSAGE_ID_SUFFIX;\n this._invalidMessageId = mId + DEFAULT_INVALID_MESSAGE_ID_SUFFIX;\n this._placeholderId = mId + DEFAULT_PLACEHOLDER_ID_SUFFIX;\n this._invalidMessage = this.invalidMessage || DEFAULT_INVALID_MESSAGE;\n this.watch0Fn();\n this.watch1Fn();\n this.watch2Fn();\n }\n\n render() {\n return (\n <div\n class={cls(\"db-select\", this.className)}\n data-variant={this.variant}\n data-hide-label={getHideProp(this.showLabel)}\n data-icon={this.icon}\n data-hide-icon={getHideProp(this.showIcon)}\n >\n <label htmlFor={this._id}>{this.label ?? DEFAULT_LABEL}</label>\n <select\n aria-invalid={this.validation === \"invalid\"}\n data-custom-validity={this.validation}\n ref={(el: any) => {\n this._ref = el;\n }}\n required={getBoolean(this.required, \"required\")}\n disabled={getBoolean(this.disabled, \"disabled\")}\n id={this._id}\n name={this.name}\n size={this.size}\n /* @ts-ignore */\nvalue={this.value ?? this._value}\n autocomplete={this.autocomplete}\n multiple={this.multiple}\n onInput={(event) => this.handleInput(event)}\n onClick={(event) => this.handleClick(event)}\n onChange={(event) => this.handleChange(event)}\n onBlur={(event) => this.handleBlur(event)}\n onFocus={(event) => this.handleFocus(event)}\n aria-describedby={this._descByIds}\n >\n <option hidden={true}></option>\n {this.options ? (\n this.options?.map((option) => (\n <Fragment>\n {option.options ? (\n <optgroup label={this.getOptionLabel(option)}>\n {option.options?.map((optgroupOption) => (\n <option\n key={optgroupOption.value.toString()}\n value={optgroupOption.value}\n selected={optgroupOption.selected}\n disabled={optgroupOption.disabled}\n >\n {this.getOptionLabel(optgroupOption)}\n </option>\n ))}\n </optgroup>\n ) : null}\n {!option.options ? (\n <option\n value={option.value}\n disabled={option.disabled}\n selected={option.selected}\n >\n {this.getOptionLabel(option)}\n </option>\n ) : null}\n </Fragment>\n ))\n ) : (\n <slot></slot>\n )}\n </select>\n <span id={this._placeholderId}>{this.placeholder ?? this.label}</span>\n {stringPropVisible(this.message, this.showMessage) ? (\n <db-infotext\n size=\"small\"\n icon={this.messageIcon}\n id={this._messageId}\n >\n {this.message}\n </db-infotext>\n ) : null}\n {this.hasValidState() ? (\n <db-infotext\n size=\"small\"\n semantic=\"successful\"\n id={this._validMessageId}\n >\n {this.validMessage || DEFAULT_VALID_MESSAGE}\n </db-infotext>\n ) : null}\n <db-infotext\n size=\"small\"\n semantic=\"critical\"\n id={this._invalidMessageId}\n >\n {this._invalidMessage}\n </db-infotext>\n <span data-visually-hidden=\"true\" role=\"status\">\n {this._voiceOverFallback}\n </span>\n </div>\n );\n }\n}\n"],"names":[],"mappings":";;;;MAkDa,QAAQ,GAAA,MAAA;AAHpB,IAAA,WAAA,CAAA,OAAA,EAAA;;;;;;;AA0CU,QAAA,IAAG,CAAA,GAAA,GAAG,SAAS;AACf,QAAA,IAAU,CAAA,UAAA,GAAG,SAAS;AACtB,QAAA,IAAe,CAAA,eAAA,GAAG,SAAS;AAC3B,QAAA,IAAiB,CAAA,iBAAA,GAAG,SAAS;AAC7B,QAAA,IAAe,CAAA,eAAA,GAAG,SAAS;AAC3B,QAAA,IAAc,CAAA,cAAA,GAAG,EAAE;AACnB,QAAA,IAAU,CAAA,UAAA,GAAG,EAAE;AACf,QAAA,IAAM,CAAA,MAAA,GAAG,EAAE;AACX,QAAA,IAAW,CAAA,WAAA,GAAG,KAAK;AACnB,QAAA,IAAkB,CAAA,kBAAA,GAAG,EAAE;AA0QjC;IAxQC,aAAa,GAAA;;AACX,QAAA,OAAO,CAAC,EAAE,CAAA,EAAA,GAAA,IAAI,CAAC,YAAY,MAAI,IAAA,IAAA,EAAA,KAAA,MAAA,GAAA,EAAA,GAAA,IAAI,CAAC,UAAU,KAAK,OAAO,CAAC;;IAE7D,gBAAgB,GAAA;;;AAEd,QAAA,IAAI,EAAC,CAAA,EAAA,GAAA,IAAI,CAAC,IAAI,0CAAE,QAAQ,CAAC,KAAK,CAAA,IAAI,IAAI,CAAC,UAAU,KAAK,SAAS,EAAE;AAC/D,YAAA,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,iBAAiB;AACxC,YAAA,IAAI,CAAC,eAAe;AAClB,gBAAA,IAAI,CAAC,cAAc;qBACnB,CAAA,EAAA,GAAA,IAAI,CAAC,IAAI,MAAA,IAAA,IAAA,EAAA,KAAA,MAAA,GAA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,EAAA,0CAAA,EACE,IAAI,EAAC,OAAO,EACZ,QAAQ,EAAC,UAAU,EACnB,EAAE,EAAE,IAAI,CAAC,iBAAiB,IAEzB,IAAI,CAAC,eAAe,CACT,EACd,CAAA,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,sBAAA,EAA2B,MAAM,EAAC,IAAI,EAAC,QAAQ,EAAA,EAC5C,IAAI,CAAC,kBAAkB,CACnB,CACH;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"db-select.entry.esm.js","sources":["src/components/select/select.tsx"],"sourcesContent":["import { DBSelectOptionType, DBSelectProps, DBSelectState } from \"./model\";\nimport {\n cls,\n delay,\n getBoolean,\n getHideProp,\n hasVoiceOver,\n stringPropVisible,\n uuid,\n} from \"../../utils\";\nimport {\n DEFAULT_INVALID_MESSAGE,\n DEFAULT_INVALID_MESSAGE_ID_SUFFIX,\n DEFAULT_LABEL,\n DEFAULT_MESSAGE_ID_SUFFIX,\n DEFAULT_PLACEHOLDER_ID_SUFFIX,\n DEFAULT_VALID_MESSAGE,\n DEFAULT_VALID_MESSAGE_ID_SUFFIX,\n} from \"../../shared/constants\";\nimport { DBInfotext } from \"../infotext/infotext\";\nimport {\n ChangeEvent,\n ClickEvent,\n InputEvent,\n InteractionEvent,\n} from \"../../shared/model\";\nimport {\n handleFrameworkEventAngular,\n handleFrameworkEventVue,\n} from \"../../utils/form-components\";\n\nimport {\n Component,\n h,\n Fragment,\n Watch,\n Event,\n EventEmitter,\n Prop,\n State,\n} from \"@stencil/core\";\n\n\n/**\n * @slot children - This is a default/unnamed slot\n\n */\n @Component({\n tag: \"db-select\",\n})\nexport class DBSelect {\n private _ref!: HTMLSelectElement | any;\n @Prop() id: DBSelectProps[\"id\"];\n @Prop() invalidMessage: DBSelectProps[\"invalidMessage\"];\n @Prop() message: DBSelectProps[\"message\"];\n @Prop() showMessage: DBSelectProps[\"showMessage\"];\n @Prop() value: DBSelectProps[\"value\"];\n @Prop() validMessage: DBSelectProps[\"validMessage\"];\n @Prop() validation: DBSelectProps[\"validation\"];\n @Prop() required: DBSelectProps[\"required\"];\n @Event() click: EventEmitter<\n Parameters<Required<DBSelectProps>[\"onClick\"]>[number]\n > | void;\n @Event() input: EventEmitter<\n Parameters<Required<DBSelectProps>[\"onInput\"]>[number]\n > | void;\n @Event() change: EventEmitter<\n Parameters<Required<DBSelectProps>[\"onChange\"]>[number]\n > | void;\n @Event() blur: EventEmitter<\n Parameters<Required<DBSelectProps>[\"onBlur\"]>[number]\n > | void;\n @Event() focus: EventEmitter<\n Parameters<Required<DBSelectProps>[\"onFocus\"]>[number]\n > | void;\n @Prop({attribute: \"classname\"}) className: DBSelectProps[\"className\"];\n @Prop() variant: DBSelectProps[\"variant\"];\n @Prop() showLabel: DBSelectProps[\"showLabel\"];\n @Prop() icon: DBSelectProps[\"icon\"];\n @Prop() showIcon: DBSelectProps[\"showIcon\"];\n @Prop() label: DBSelectProps[\"label\"];\n @Prop() disabled: DBSelectProps[\"disabled\"];\n @Prop() name: DBSelectProps[\"name\"];\n @Prop() size: DBSelectProps[\"size\"];\n @Prop() autocomplete: DBSelectProps[\"autocomplete\"];\n @Prop() multiple: DBSelectProps[\"multiple\"];\n @Prop() ariaDescribedBy: DBSelectProps[\"ariaDescribedBy\"];\n @Prop() options: DBSelectProps[\"options\"];\n @Prop() placeholder: DBSelectProps[\"placeholder\"];\n @Prop() messageIcon: DBSelectProps[\"messageIcon\"];\n @State() _id = undefined;\n @State() _messageId = undefined;\n @State() _validMessageId = undefined;\n @State() _invalidMessageId = undefined;\n @State() _invalidMessage = undefined;\n @State() _placeholderId = \"\";\n @State() _descByIds = \"\";\n @State() _value = \"\";\n @State() initialized = false;\n @State() _voiceOverFallback = \"\";\n\n hasValidState() {\n return !!(this.validMessage ?? this.validation === \"valid\");\n }\n handleValidation() {\n /* For a11y reasons we need to map the correct message with the select */\n if (!this._ref?.validity.valid || this.validation === \"invalid\") {\n this._descByIds = this._invalidMessageId;\n this._invalidMessage =\n this.invalidMessage ||\n this._ref?.validationMessage ||\n DEFAULT_INVALID_MESSAGE;\n if (hasVoiceOver()) {\n this._voiceOverFallback = this._invalidMessage;\n delay(() => (this._voiceOverFallback = \"\"), 1000);\n }\n } else if (\n this.hasValidState() &&\n this._ref?.validity.valid &&\n this.required\n ) {\n this._descByIds = this._validMessageId;\n if (hasVoiceOver()) {\n this._voiceOverFallback = this.validMessage ?? DEFAULT_VALID_MESSAGE;\n delay(() => (this._voiceOverFallback = \"\"), 1000);\n }\n } else if (stringPropVisible(this.message, this.showMessage)) {\n this._descByIds = this._messageId;\n } else {\n this._descByIds = this._placeholderId;\n }\n }\n handleClick(event: ClickEvent<HTMLSelectElement> | any) {\n if (this.click) {\n event.stopPropagation();\n this.click.emit(event);\n }\n }\n handleInput(event: InputEvent<HTMLSelectElement> | any) {\n event.stopPropagation();\n if (this.input) {\n this.input.emit(event);\n }\n this.handleValidation();\n }\n handleChange(event: ChangeEvent<HTMLSelectElement> | any) {\n event.stopPropagation();\n if (this.change) {\n this.change.emit(event);\n }\n this.handleValidation();\n }\n handleBlur(event: InteractionEvent<HTMLSelectElement> | any) {\n event.stopPropagation();\n if (this.blur) {\n this.blur.emit(event);\n }\n }\n handleFocus(event: InteractionEvent<HTMLSelectElement> | any) {\n event.stopPropagation();\n if (this.focus) {\n this.focus.emit(event);\n }\n }\n getOptionLabel(option: DBSelectOptionType) {\n return option.label ?? option.value?.toString();\n }\n\n /**\n * Passes `aria-*`, `data-*` & `class` attributes to correct child. Used in angular and stencil.\n * @param element the ref for the component\n * @param customElementSelector the custom element like `my-component`\n */\n private enableAttributePassing(\n element: HTMLSelectElement | null,\n customElementSelector: string\n ) {\n const parent = element?.closest(customElementSelector);\n if (element && parent) {\n const attributes = parent.attributes;\n for (let i = 0; i < attributes.length; i++) {\n const attr = attributes.item(i);\n if (\n attr &&\n (attr.name.startsWith(\"data-\") || attr.name.startsWith(\"aria-\"))\n ) {\n element.setAttribute(attr.name, attr.value);\n parent.removeAttribute(attr.name);\n }\n if (attr && attr.name === \"class\") {\n const isWebComponent = attr.value.includes(\"hydrated\");\n const value = attr.value.replace(\"hydrated\", \"\").trim();\n const currentClass = element.getAttribute(\"class\");\n element.setAttribute(\n attr.name,\n `${currentClass ? `${currentClass} ` : \"\"}${value}`\n );\n if (isWebComponent) {\n // Stencil is using this class for lazy loading component\n parent.setAttribute(\"class\", \"hydrated\");\n } else {\n parent.removeAttribute(attr.name);\n }\n }\n }\n }\n }\n\n watch0Fn() {\n this._invalidMessage =\n this.invalidMessage ||\n this._ref?.validationMessage ||\n DEFAULT_INVALID_MESSAGE;\n }\n\n @Watch(\"_ref\")\n @Watch(\"invalidMessage\")\n watch0() {\n this.watch0Fn();\n }\n\n watch1Fn() {\n if (this._id && this.initialized) {\n const messageId = this._id + DEFAULT_MESSAGE_ID_SUFFIX;\n const placeholderId = this._id + DEFAULT_PLACEHOLDER_ID_SUFFIX;\n this._messageId = messageId;\n this._validMessageId = this._id + DEFAULT_VALID_MESSAGE_ID_SUFFIX;\n this._invalidMessageId = this._id + DEFAULT_INVALID_MESSAGE_ID_SUFFIX;\n this._placeholderId = placeholderId;\n if (stringPropVisible(this.message, this.showMessage)) {\n this._descByIds = messageId;\n } else {\n this._descByIds = placeholderId;\n }\n this.initialized = false;\n }\n }\n\n @Watch(\"_id\")\n @Watch(\"initialized\")\n watch1() {\n this.watch1Fn();\n }\n\n watch2Fn() {\n this._value = this.value;\n }\n\n @Watch(\"value\")\n watch2() {\n this.watch2Fn();\n }\n\n componentDidLoad() {\n this.enableAttributePassing(this._ref, \"db-select\");\n this.initialized = true;\n const mId = this.id ?? `select-${uuid()}`;\n this._id = mId;\n this._messageId = mId + DEFAULT_MESSAGE_ID_SUFFIX;\n this._validMessageId = mId + DEFAULT_VALID_MESSAGE_ID_SUFFIX;\n this._invalidMessageId = mId + DEFAULT_INVALID_MESSAGE_ID_SUFFIX;\n this._placeholderId = mId + DEFAULT_PLACEHOLDER_ID_SUFFIX;\n this._invalidMessage = this.invalidMessage || DEFAULT_INVALID_MESSAGE;\n this.watch0Fn();\n this.watch1Fn();\n this.watch2Fn();\n }\n\n render() {\n return (\n <div\n class={cls(\"db-select\", this.className)}\n data-variant={this.variant}\n data-hide-label={getHideProp(this.showLabel)}\n data-icon={this.icon}\n data-hide-icon={getHideProp(this.showIcon)}\n >\n <label htmlFor={this._id}>{this.label ?? DEFAULT_LABEL}</label>\n <select\n aria-invalid={this.validation === \"invalid\"}\n data-custom-validity={this.validation}\n ref={(el: any) => {\n this._ref = el;\n }}\n required={getBoolean(this.required, \"required\")}\n disabled={getBoolean(this.disabled, \"disabled\")}\n id={this._id}\n name={this.name}\n size={this.size}\n /* @ts-ignore */\nvalue={this.value ?? this._value}\n autocomplete={this.autocomplete}\n multiple={this.multiple}\n onInput={(event) => this.handleInput(event)}\n onClick={(event) => this.handleClick(event)}\n onChange={(event) => this.handleChange(event)}\n onBlur={(event) => this.handleBlur(event)}\n onFocus={(event) => this.handleFocus(event)}\n aria-describedby={this.ariaDescribedBy ?? this._descByIds}\n >\n <option hidden={true}></option>\n {this.options ? (\n this.options?.map((option) => (\n <Fragment>\n {option.options ? (\n <optgroup label={this.getOptionLabel(option)}>\n {option.options?.map((optgroupOption) => (\n <option\n key={optgroupOption.value.toString()}\n value={optgroupOption.value}\n selected={optgroupOption.selected}\n disabled={optgroupOption.disabled}\n >\n {this.getOptionLabel(optgroupOption)}\n </option>\n ))}\n </optgroup>\n ) : null}\n {!option.options ? (\n <option\n value={option.value}\n disabled={option.disabled}\n selected={option.selected}\n >\n {this.getOptionLabel(option)}\n </option>\n ) : null}\n </Fragment>\n ))\n ) : (\n <slot></slot>\n )}\n </select>\n <span id={this._placeholderId}>{this.placeholder ?? this.label}</span>\n {stringPropVisible(this.message, this.showMessage) ? (\n <db-infotext\n size=\"small\"\n icon={this.messageIcon}\n id={this._messageId}\n >\n {this.message}\n </db-infotext>\n ) : null}\n {this.hasValidState() ? (\n <db-infotext\n size=\"small\"\n semantic=\"successful\"\n id={this._validMessageId}\n >\n {this.validMessage || DEFAULT_VALID_MESSAGE}\n </db-infotext>\n ) : null}\n <db-infotext\n size=\"small\"\n semantic=\"critical\"\n id={this._invalidMessageId}\n >\n {this._invalidMessage}\n </db-infotext>\n <span data-visually-hidden=\"true\" role=\"status\">\n {this._voiceOverFallback}\n </span>\n </div>\n );\n }\n}\n"],"names":[],"mappings":";;;;MAkDa,QAAQ,GAAA,MAAA;AAHpB,IAAA,WAAA,CAAA,OAAA,EAAA;;;;;;;AA2CU,QAAA,IAAG,CAAA,GAAA,GAAG,SAAS;AACf,QAAA,IAAU,CAAA,UAAA,GAAG,SAAS;AACtB,QAAA,IAAe,CAAA,eAAA,GAAG,SAAS;AAC3B,QAAA,IAAiB,CAAA,iBAAA,GAAG,SAAS;AAC7B,QAAA,IAAe,CAAA,eAAA,GAAG,SAAS;AAC3B,QAAA,IAAc,CAAA,cAAA,GAAG,EAAE;AACnB,QAAA,IAAU,CAAA,UAAA,GAAG,EAAE;AACf,QAAA,IAAM,CAAA,MAAA,GAAG,EAAE;AACX,QAAA,IAAW,CAAA,WAAA,GAAG,KAAK;AACnB,QAAA,IAAkB,CAAA,kBAAA,GAAG,EAAE;AA0QjC;IAxQC,aAAa,GAAA;;AACX,QAAA,OAAO,CAAC,EAAE,CAAA,EAAA,GAAA,IAAI,CAAC,YAAY,MAAI,IAAA,IAAA,EAAA,KAAA,MAAA,GAAA,EAAA,GAAA,IAAI,CAAC,UAAU,KAAK,OAAO,CAAC;;IAE7D,gBAAgB,GAAA;;;AAEd,QAAA,IAAI,EAAC,CAAA,EAAA,GAAA,IAAI,CAAC,IAAI,0CAAE,QAAQ,CAAC,KAAK,CAAA,IAAI,IAAI,CAAC,UAAU,KAAK,SAAS,EAAE;AAC/D,YAAA,IAAI,CAAC,UAAU,GAAG,IAAI,CAAC,iBAAiB;AACxC,YAAA,IAAI,CAAC,eAAe;AAClB,gBAAA,IAAI,CAAC,cAAc;qBACnB,CAAA,EAAA,G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EACrB,EAAE,EAAE,IAAI,CAAC,eAAe,EAAA,EAEvB,IAAI,CAAC,YAAY,IAAI,qBAAqB,CAC/B,IACZ,IAAI,EACR,CAAA,CAAA,aAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EACE,IAAI,EAAC,OAAO,EACZ,QAAQ,EAAC,UAAU,EACnB,EAAE,EAAE,IAAI,CAAC,iBAAiB,IAEzB,IAAI,CAAC,eAAe,CACT,EACd,CAAA,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,sBAAA,EAA2B,MAAM,EAAC,IAAI,EAAC,QAAQ,EAAA,EAC5C,IAAI,CAAC,kBAAkB,CACnB,CACH;;;;;;;;;;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"db-switch.entry.esm.js","sources":["src/components/switch/switch.tsx"],"sourcesContent":["import { DBSwitchProps, DBSwitchState } from \"./model\";\nimport {\n cls,\n getBoolean,\n getBooleanAsString,\n getHideProp,\n uuid,\n} from \"../../utils\";\nimport { ChangeEvent, InteractionEvent } from \"../../shared/model\";\nimport {\n handleFrameworkEventAngular,\n handleFrameworkEventVue,\n} from \"../../utils/form-components\";\n\nimport {\n Component,\n h,\n Fragment,\n Watch,\n Event,\n EventEmitter,\n Prop,\n State,\n} from \"@stencil/core\";\n\n\n/**\n * @slot children - This is a default/unnamed slot\n\n */\n @Component({\n tag: \"db-switch\",\n})\nexport class DBSwitch {\n private _ref!: HTMLInputElement | any;\n @Prop() id: DBSwitchProps[\"id\"];\n @Prop() checked: DBSwitchProps[\"checked\"];\n @Event() change: EventEmitter<\n Parameters<Required<DBSwitchProps>[\"onChange\"]>[number]\n > | void;\n @Event() blur: EventEmitter<\n Parameters<Required<DBSwitchProps>[\"onBlur\"]>[number]\n > | void;\n @Event() focus: EventEmitter<\n Parameters<Required<DBSwitchProps>[\"onFocus\"]>[number]\n > | void;\n @Prop() visualAid: DBSwitchProps[\"visualAid\"];\n @Prop() size: DBSwitchProps[\"size\"];\n @Prop() showLabel: DBSwitchProps[\"showLabel\"];\n @Prop() emphasis: DBSwitchProps[\"emphasis\"];\n @Prop({attribute: \"classname\"}) className: DBSwitchProps[\"className\"];\n @Prop() value: DBSwitchProps[\"value\"];\n @Prop() disabled: DBSwitchProps[\"disabled\"];\n @Prop() describedbyid: DBSwitchProps[\"describedbyid\"];\n @Prop() validation: DBSwitchProps[\"validation\"];\n @Prop() name: DBSwitchProps[\"name\"];\n @Prop() required: DBSwitchProps[\"required\"];\n @Prop() icon: DBSwitchProps[\"icon\"];\n @Prop() iconAfter: DBSwitchProps[\"iconAfter\"];\n @Prop() label: DBSwitchProps[\"label\"];\n @State() _id = undefined;\n @State() _checked = false;\n\n handleChange(event: ChangeEvent<HTMLInputElement>) {\n event.stopPropagation();\n if (this.change) {\n this.change.emit(event);\n }\n\n // We have different ts types in different frameworks, so we need to use any here\n this._checked = (event.target as any)?.[\"checked\"];\n }\n handleBlur(event: InteractionEvent<HTMLInputElement>) {\n event.stopPropagation();\n if (this.blur) {\n this.blur.emit(event);\n }\n }\n handleFocus(event: InteractionEvent<HTMLInputElement>) {\n event.stopPropagation();\n if (this.focus) {\n this.focus.emit(event);\n }\n }\n\n /**\n * Passes `aria-*`, `data-*` & `class` attributes to correct child. Used in angular and stencil.\n * @param element the ref for the component\n * @param customElementSelector the custom element like `my-component`\n */\n private enableAttributePassing(\n element: HTMLInputElement | null,\n customElementSelector: string\n ) {\n const parent = element?.closest(customElementSelector);\n if (element && parent) {\n const attributes = parent.attributes;\n for (let i = 0; i < attributes.length; i++) {\n const attr = attributes.item(i);\n if (\n attr &&\n (attr.name.startsWith(\"data-\") || attr.name.startsWith(\"aria-\"))\n ) {\n element.setAttribute(attr.name, attr.value);\n parent.removeAttribute(attr.name);\n }\n if (attr && attr.name === \"class\") {\n const isWebComponent = attr.value.includes(\"hydrated\");\n const value = attr.value.replace(\"hydrated\", \"\").trim();\n const currentClass = element.getAttribute(\"class\");\n element.setAttribute(\n attr.name,\n `${currentClass ? `${currentClass} ` : \"\"}${value}`\n );\n if (isWebComponent) {\n // Stencil is using this class for lazy loading component\n parent.setAttribute(\"class\", \"hydrated\");\n } else {\n parent.removeAttribute(attr.name);\n }\n }\n }\n }\n }\n\n watch0Fn() {\n if (this.checked !== undefined && this.checked !== null) {\n this._checked = getBoolean(this.checked);\n }\n }\n\n @Watch(\"checked\")\n watch0() {\n this.watch0Fn();\n }\n\n componentDidLoad() {\n this.enableAttributePassing(this._ref, \"db-switch\");\n this._id = this.id ?? `switch-${uuid()}`;\n this.watch0Fn();\n }\n\n render() {\n return (\n <label\n class={cls(\"db-switch\", this.className)}\n data-visual-aid={getBooleanAsString(this.visualAid)}\n data-size={this.size}\n data-hide-label={getHideProp(this.showLabel)}\n data-emphasis={this.emphasis}\n htmlFor={this._id}\n >\n <input\n type=\"checkbox\"\n role=\"switch\"\n id={this._id}\n aria-checked={getBooleanAsString(this._checked)}\n ref={(el: any) => {\n this._ref = el;\n }}\n checked={getBoolean(this.checked, \"checked\")}\n value={this.value}\n disabled={getBoolean(this.disabled, \"disabled\")}\n aria-describedby={this.describedbyid}\n aria-invalid={this.validation === \"invalid\"}\n data-custom-validity={this.validation}\n name={this.name}\n required={getBoolean(this.required, \"required\")}\n data-aid-icon={this.icon}\n data-aid-icon-after={this.iconAfter}\n onChange={(event) => this.handleChange(event)}\n onBlur={(event) => this.handleBlur(event)}\n onFocus={(event) => this.handleFocus(event)}\n />\n {this.label ? this.label : <slot></slot>}\n </label>\n );\n }\n}\n"],"names":[],"mappings":";;;MAiCa,QAAQ,GAAA,MAAA;AAHpB,IAAA,WAAA,CAAA,OAAA,EAAA;;;;;AA8BU,QAAA,IAAG,CAAA,GAAA,GAAG,SAAS;AACf,QAAA,IAAQ,CAAA,QAAA,GAAG,KAAK;AAqH1B;AAnHC,IAAA,YAAY,CAAC,KAAoC,EAAA;;QAC/C,KAAK,CAAC,eAAe,EAAE;AACvB,QAAA,IAAI,IAAI,CAAC,MAAM,EAAE;AACf,YAAA,IAAI,CAA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C,EACzC,OAAO,EAAE,CAAC,KAAK,KAAK,IAAI,CAAC,WAAW,CAAC,KAAK,CAAC,EAC3C,CAAA,EACD,IAAI,CAAC,KAAK,GAAG,IAAI,CAAC,KAAK,GAAG,CAAa,CAAA,MAAA,EAAA,IAAA,CAAA,CAClC;;;;;;;;;"}
1
+ {"version":3,"file":"db-switch.entry.esm.js","sources":["src/components/switch/switch.tsx"],"sourcesContent":["import { DBSwitchProps, DBSwitchState } from \"./model\";\nimport {\n cls,\n getBoolean,\n getBooleanAsString,\n getHideProp,\n uuid,\n} from \"../../utils\";\nimport { ChangeEvent, InteractionEvent } from \"../../shared/model\";\nimport {\n handleFrameworkEventAngular,\n handleFrameworkEventVue,\n} from \"../../utils/form-components\";\n\nimport {\n Component,\n h,\n Fragment,\n Watch,\n Event,\n EventEmitter,\n Prop,\n State,\n} from \"@stencil/core\";\n\n\n/**\n * @slot children - This is a default/unnamed slot\n\n */\n @Component({\n tag: \"db-switch\",\n})\nexport class DBSwitch {\n private _ref!: HTMLInputElement | any;\n @Prop() id: DBSwitchProps[\"id\"];\n @Prop() checked: DBSwitchProps[\"checked\"];\n @Event() change: EventEmitter<\n Parameters<Required<DBSwitchProps>[\"onChange\"]>[number]\n > | void;\n @Event() blur: EventEmitter<\n Parameters<Required<DBSwitchProps>[\"onBlur\"]>[number]\n > | void;\n @Event() focus: EventEmitter<\n Parameters<Required<DBSwitchProps>[\"onFocus\"]>[number]\n > | void;\n @Prop() visualAid: DBSwitchProps[\"visualAid\"];\n @Prop() size: DBSwitchProps[\"size\"];\n @Prop() showLabel: DBSwitchProps[\"showLabel\"];\n @Prop() emphasis: DBSwitchProps[\"emphasis\"];\n @Prop({attribute: \"classname\"}) className: DBSwitchProps[\"className\"];\n @Prop() value: DBSwitchProps[\"value\"];\n @Prop() disabled: DBSwitchProps[\"disabled\"];\n @Prop() describedbyid: DBSwitchProps[\"describedbyid\"];\n @Prop() ariaDescribedBy: DBSwitchProps[\"ariaDescribedBy\"];\n @Prop() validation: DBSwitchProps[\"validation\"];\n @Prop() name: DBSwitchProps[\"name\"];\n @Prop() required: DBSwitchProps[\"required\"];\n @Prop() icon: DBSwitchProps[\"icon\"];\n @Prop() iconAfter: DBSwitchProps[\"iconAfter\"];\n @Prop() label: DBSwitchProps[\"label\"];\n @State() _id = undefined;\n @State() _checked = false;\n\n handleChange(event: ChangeEvent<HTMLInputElement>) {\n event.stopPropagation();\n if (this.change) {\n this.change.emit(event);\n }\n\n // We have different ts types in different frameworks, so we need to use any here\n this._checked = (event.target as any)?.[\"checked\"];\n }\n handleBlur(event: InteractionEvent<HTMLInputElement>) {\n event.stopPropagation();\n if (this.blur) {\n this.blur.emit(event);\n }\n }\n handleFocus(event: InteractionEvent<HTMLInputElement>) {\n event.stopPropagation();\n if (this.focus) {\n this.focus.emit(event);\n }\n }\n\n /**\n * Passes `aria-*`, `data-*` & `class` attributes to correct child. Used in angular and stencil.\n * @param element the ref for the component\n * @param customElementSelector the custom element like `my-component`\n */\n private enableAttributePassing(\n element: HTMLInputElement | null,\n customElementSelector: string\n ) {\n const parent = element?.closest(customElementSelector);\n if (element && parent) {\n const attributes = parent.attributes;\n for (let i = 0; i < attributes.length; i++) {\n const attr = attributes.item(i);\n if (\n attr &&\n (attr.name.startsWith(\"data-\") || attr.name.startsWith(\"aria-\"))\n ) {\n element.setAttribute(attr.name, attr.value);\n parent.removeAttribute(attr.name);\n }\n if (attr && attr.name === \"class\") {\n const isWebComponent = attr.value.includes(\"hydrated\");\n const value = attr.value.replace(\"hydrated\", \"\").trim();\n const currentClass = element.getAttribute(\"class\");\n element.setAttribute(\n attr.name,\n `${currentClass ? `${currentClass} ` : \"\"}${value}`\n );\n if (isWebComponent) {\n // Stencil is using this class for lazy loading component\n parent.setAttribute(\"class\", \"hydrated\");\n } else {\n parent.removeAttribute(attr.name);\n }\n }\n }\n }\n }\n\n watch0Fn() {\n if (this.checked !== undefined && this.checked !== null) {\n this._checked = getBoolean(this.checked);\n }\n }\n\n @Watch(\"checked\")\n watch0() {\n this.watch0Fn();\n }\n\n componentDidLoad() {\n this.enableAttributePassing(this._ref, \"db-switch\");\n this._id = this.id ?? `switch-${uuid()}`;\n this.watch0Fn();\n }\n\n render() {\n return (\n <label\n class={cls(\"db-switch\", this.className)}\n data-visual-aid={getBooleanAsString(this.visualAid)}\n data-size={this.size}\n data-hide-label={getHideProp(this.showLabel)}\n data-emphasis={this.emphasis}\n htmlFor={this._id}\n >\n <input\n type=\"checkbox\"\n role=\"switch\"\n id={this._id}\n aria-checked={getBooleanAsString(this._checked)}\n ref={(el: any) => {\n this._ref = el;\n }}\n checked={getBoolean(this.checked, \"checked\")}\n value={this.value}\n disabled={getBoolean(this.disabled, \"disabled\")}\n aria-describedby={this.describedbyid ?? this.ariaDescribedBy}\n aria-invalid={this.validation === \"invalid\"}\n data-custom-validity={this.validation}\n name={this.name}\n required={getBoolean(this.required, \"required\")}\n data-aid-icon={this.icon}\n data-aid-icon-after={this.iconAfter}\n onChange={(event) => this.handleChange(event)}\n onBlur={(event) => this.handleBlur(event)}\n onFocus={(event) => this.handleFocus(event)}\n />\n {this.label ? this.label : <slot></slot>}\n </label>\n );\n }\n}\n"],"names":[],"mappings":";;;MAiCa,QAAQ,GAAA,MAAA;AAHpB,IAAA,WAAA,CAAA,OAAA,EAAA;;;;;AA+BU,QAAA,IAAG,CAAA,GAAA,GAAG,SAAS;AACf,QAAA,IAAQ,CAAA,QAAA,GAAG,KAAK;AAqH1B;AAnHC,IAAA,YAAY,CAAC,KAAoC,EAAA;;QAC/C,KAAK,CAAC,eAAe,EAAE;AACvB,QAAA,IAAI,IAAI,CAAC,MAAM,EAAE;AACf,YAAA,IAAI,CAAC,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC;;;AAIzB,QAAA,IAAI,CAAC,QAAQ,GAAG,CAAC,EAAA,GAAA,KAAK,CAAC,MAAc,MAAA,IAAA,IAAA,EAAA,KAAA,MAAA,GAAA,MAAA,GAAA,EAAA,CAAG,SAAS,CAAC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GAAG,IAAI,CAAC,KAAK,GAAG,CAAa,CAAA,MAAA,EAAA,IAAA,CAAA,CAClC;;;;;;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"db-textarea.entry.esm.js","sources":["src/components/textarea/textarea.tsx"],"sourcesContent":["import { DBTextareaProps, DBTextareaState } from \"./model\";\nimport { DBInfotext } from \"../infotext/infotext\";\nimport {\n cls,\n delay,\n getBoolean,\n getHideProp,\n getNumber,\n hasVoiceOver,\n stringPropVisible,\n uuid,\n} from \"../../utils\";\nimport {\n DEFAULT_INVALID_MESSAGE,\n DEFAULT_INVALID_MESSAGE_ID_SUFFIX,\n DEFAULT_LABEL,\n DEFAULT_MESSAGE_ID_SUFFIX,\n DEFAULT_PLACEHOLDER,\n DEFAULT_ROWS,\n DEFAULT_VALID_MESSAGE,\n DEFAULT_VALID_MESSAGE_ID_SUFFIX,\n} from \"../../shared/constants\";\nimport { ChangeEvent, InputEvent, InteractionEvent } from \"../../shared/model\";\nimport {\n handleFrameworkEventAngular,\n handleFrameworkEventVue,\n} from \"../../utils/form-components\";\n\nimport {\n Component,\n h,\n Fragment,\n Watch,\n Event,\n EventEmitter,\n Prop,\n State,\n} from \"@stencil/core\";\n\n\n/**\n * @slot children - This is a default/unnamed slot\n\n */\n @Component({\n tag: \"db-textarea\",\n})\nexport class DBTextarea {\n private _ref!: HTMLTextAreaElement | any;\n @Prop() id: DBTextareaProps[\"id\"];\n @Prop() invalidMessage: DBTextareaProps[\"invalidMessage\"];\n @Prop() message: DBTextareaProps[\"message\"];\n @Prop() showMessage: DBTextareaProps[\"showMessage\"];\n @Prop() value: DBTextareaProps[\"value\"];\n @Prop() validMessage: DBTextareaProps[\"validMessage\"];\n @Prop() validation: DBTextareaProps[\"validation\"];\n @Prop() required: DBTextareaProps[\"required\"];\n @Prop() minLength: DBTextareaProps[\"minLength\"];\n @Prop() maxLength: DBTextareaProps[\"maxLength\"];\n @Event() input: EventEmitter<\n Parameters<Required<DBTextareaProps>[\"onInput\"]>[number]\n > | void;\n @Event() change: EventEmitter<\n Parameters<Required<DBTextareaProps>[\"onChange\"]>[number]\n > | void;\n @Event() blur: EventEmitter<\n Parameters<Required<DBTextareaProps>[\"onBlur\"]>[number]\n > | void;\n @Event() focus: EventEmitter<\n Parameters<Required<DBTextareaProps>[\"onFocus\"]>[number]\n > | void;\n @Prop({attribute: \"classname\"}) className: DBTextareaProps[\"className\"];\n @Prop() variant: DBTextareaProps[\"variant\"];\n @Prop() showLabel: DBTextareaProps[\"showLabel\"];\n @Prop() label: DBTextareaProps[\"label\"];\n @Prop() resize: DBTextareaProps[\"resize\"];\n @Prop() disabled: DBTextareaProps[\"disabled\"];\n @Prop() readOnly: DBTextareaProps[\"readOnly\"];\n @Prop() readonly: DBTextareaProps[\"readonly\"];\n @Prop() form: DBTextareaProps[\"form\"];\n @Prop() maxlength: DBTextareaProps[\"maxlength\"];\n @Prop() minlength: DBTextareaProps[\"minlength\"];\n @Prop() name: DBTextareaProps[\"name\"];\n @Prop() wrap: DBTextareaProps[\"wrap\"];\n @Prop() spellCheck: DBTextareaProps[\"spellCheck\"];\n @Prop() autocomplete: DBTextareaProps[\"autocomplete\"];\n @Prop() placeholder: DBTextareaProps[\"placeholder\"];\n @Prop() rows: DBTextareaProps[\"rows\"];\n @Prop() cols: DBTextareaProps[\"cols\"];\n @Prop() messageIcon: DBTextareaProps[\"messageIcon\"];\n @State() _id = undefined;\n @State() _messageId = undefined;\n @State() _validMessageId = undefined;\n @State() _invalidMessageId = undefined;\n @State() _invalidMessage = undefined;\n @State() _descByIds = \"\";\n @State() _value = \"\";\n @State() _voiceOverFallback = \"\";\n\n hasValidState() {\n return !!(this.validMessage ?? this.validation === \"valid\");\n }\n handleValidation() {\n /* For a11y reasons we need to map the correct message with the textarea */\n if (!this._ref?.validity.valid || this.validation === \"invalid\") {\n this._descByIds = this._invalidMessageId;\n this._invalidMessage =\n this.invalidMessage ||\n this._ref?.validationMessage ||\n DEFAULT_INVALID_MESSAGE;\n if (hasVoiceOver()) {\n this._voiceOverFallback = this._invalidMessage;\n delay(() => (this._voiceOverFallback = \"\"), 1000);\n }\n } else if (\n this.hasValidState() &&\n this._ref?.validity.valid &&\n (this.required || this.minLength || this.maxLength)\n ) {\n this._descByIds = this._validMessageId;\n if (hasVoiceOver()) {\n this._voiceOverFallback = this.validMessage ?? DEFAULT_VALID_MESSAGE;\n delay(() => (this._voiceOverFallback = \"\"), 1000);\n }\n } else if (stringPropVisible(this.message, this.showMessage)) {\n this._descByIds = this._messageId;\n } else {\n this._descByIds = \"\";\n }\n }\n handleInput(event: InputEvent<HTMLTextAreaElement>) {\n event.stopPropagation();\n if (this.input) {\n this.input.emit(event);\n }\n this.handleValidation();\n }\n handleChange(event: ChangeEvent<HTMLTextAreaElement>) {\n event.stopPropagation();\n if (this.change) {\n this.change.emit(event);\n }\n this.handleValidation();\n }\n handleBlur(event: InteractionEvent<HTMLTextAreaElement> | any) {\n event.stopPropagation();\n if (this.blur) {\n this.blur.emit(event);\n }\n }\n handleFocus(event: InteractionEvent<HTMLTextAreaElement> | any) {\n event.stopPropagation();\n if (this.focus) {\n this.focus.emit(event);\n }\n }\n\n /**\n * Passes `aria-*`, `data-*` & `class` attributes to correct child. Used in angular and stencil.\n * @param element the ref for the component\n * @param customElementSelector the custom element like `my-component`\n */\n private enableAttributePassing(\n element: HTMLTextAreaElement | null,\n customElementSelector: string\n ) {\n const parent = element?.closest(customElementSelector);\n if (element && parent) {\n const attributes = parent.attributes;\n for (let i = 0; i < attributes.length; i++) {\n const attr = attributes.item(i);\n if (\n attr &&\n (attr.name.startsWith(\"data-\") || attr.name.startsWith(\"aria-\"))\n ) {\n element.setAttribute(attr.name, attr.value);\n parent.removeAttribute(attr.name);\n }\n if (attr && attr.name === \"class\") {\n const isWebComponent = attr.value.includes(\"hydrated\");\n const value = attr.value.replace(\"hydrated\", \"\").trim();\n const currentClass = element.getAttribute(\"class\");\n element.setAttribute(\n attr.name,\n `${currentClass ? `${currentClass} ` : \"\"}${value}`\n );\n if (isWebComponent) {\n // Stencil is using this class for lazy loading component\n parent.setAttribute(\"class\", \"hydrated\");\n } else {\n parent.removeAttribute(attr.name);\n }\n }\n }\n }\n }\n\n watch0Fn() {\n this._invalidMessage =\n this.invalidMessage ||\n this._ref?.validationMessage ||\n DEFAULT_INVALID_MESSAGE;\n }\n\n @Watch(\"_ref\")\n @Watch(\"invalidMessage\")\n watch0() {\n this.watch0Fn();\n }\n\n watch1Fn() {\n if (this._id) {\n const messageId = this._id + DEFAULT_MESSAGE_ID_SUFFIX;\n this._messageId = messageId;\n this._validMessageId = this._id + DEFAULT_VALID_MESSAGE_ID_SUFFIX;\n this._invalidMessageId = this._id + DEFAULT_INVALID_MESSAGE_ID_SUFFIX;\n if (stringPropVisible(this.message, this.showMessage)) {\n this._descByIds = messageId;\n }\n }\n }\n\n @Watch(\"_id\")\n watch1() {\n this.watch1Fn();\n }\n\n watch2Fn() {\n this._value = this.value;\n }\n\n @Watch(\"value\")\n watch2() {\n this.watch2Fn();\n }\n\n componentDidLoad() {\n this.enableAttributePassing(this._ref, \"db-textarea\");\n const mId = this.id ?? `textarea-${uuid()}`;\n this._id = mId;\n this._messageId = mId + DEFAULT_MESSAGE_ID_SUFFIX;\n this._validMessageId = mId + DEFAULT_VALID_MESSAGE_ID_SUFFIX;\n this._invalidMessageId = mId + DEFAULT_INVALID_MESSAGE_ID_SUFFIX;\n this._invalidMessage = this.invalidMessage || DEFAULT_INVALID_MESSAGE;\n this.watch0Fn();\n this.watch1Fn();\n this.watch2Fn();\n }\n\n render() {\n return (\n <div\n class={cls(\"db-textarea\", this.className)}\n data-variant={this.variant}\n data-hide-label={getHideProp(this.showLabel)}\n >\n <label htmlFor={this._id}>{this.label ?? DEFAULT_LABEL}</label>\n <textarea\n aria-invalid={this.validation === \"invalid\"}\n data-custom-validity={this.validation}\n ref={(el: any) => {\n this._ref = el;\n }}\n id={this._id}\n data-resize={this.resize}\n disabled={getBoolean(this.disabled, \"disabled\")}\n required={getBoolean(this.required, \"required\")}\n readOnly={\n getBoolean(this.readOnly, \"readOnly\") ||\n getBoolean(this.readonly, \"readonly\")\n }\n form={this.form}\n maxLength={getNumber(this.maxLength, this.maxlength)}\n minLength={getNumber(this.minLength, this.minlength)}\n name={this.name}\n wrap={this.wrap}\n spellcheck={this.spellCheck}\n autocomplete={this.autocomplete}\n onInput={(event) => this.handleInput(event)}\n onChange={(event) => this.handleChange(event)}\n onBlur={(event) => this.handleBlur(event)}\n onFocus={(event) => this.handleFocus(event)}\n value={this.value ?? this._value}\n aria-describedby={this._descByIds}\n placeholder={this.placeholder ?? DEFAULT_PLACEHOLDER}\n rows={getNumber(this.rows, DEFAULT_ROWS)}\n cols={getNumber(this.cols)}\n ></textarea>\n {stringPropVisible(this.message, this.showMessage) ? (\n <db-infotext\n size=\"small\"\n icon={this.messageIcon}\n id={this._messageId}\n >\n {this.message}\n </db-infotext>\n ) : null}\n {this.hasValidState() ? (\n <db-infotext\n size=\"small\"\n semantic=\"successful\"\n id={this._validMessageId}\n >\n {this.validMessage || DEFAULT_VALID_MESSAGE}\n </db-infotext>\n ) : null}\n <db-infotext\n size=\"small\"\n semantic=\"critical\"\n id={this._invalidMessageId}\n >\n {this._invalidMessage}\n </db-infotext>\n <span data-visually-hidden=\"true\" role=\"status\">\n {this._voiceOverFallback}\n </span>\n </div>\n );\n }\n}\n"],"names":[],"mappings":";;;;MA+Ca,UAAU,GAAA,MAAA;AAHtB,IAAA,WAAA,CAAA,OAAA,EAAA;;;;;;AA8CU,QAAA,IAAG,CAAA,GAAA,GAAG,SAAS;AACf,QAAA,IAAU,CAAA,UAAA,GAAG,SAAS;AACtB,QAAA,IAAe,CAAA,eAAA,GAAG,SAAS;AAC3B,QAAA,IAAiB,CAAA,iBAAA,GAAG,SAAS;AAC7B,QAAA,IAAe,CAAA,eAAA,GAAG,SAAS;AAC3B,QAAA,IAAU,CAAA,UAAA,GAAG,EAAE;AACf,QAAA,IAAM,CAAA,MAAA,GAAG,EAAE;AAC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,QAAQ,EAAC,YAAY,EACrB,EAAE,EAAE,IAAI,CAAC,eAAe,EAAA,EAEvB,IAAI,CAAC,YAAY,IAAI,qBAAqB,CAC/B,IACZ,IAAI,EACR,CAAA,CAAA,aAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EACE,IAAI,EAAC,OAAO,EACZ,QAAQ,EAAC,UAAU,EACnB,EAAE,EAAE,IAAI,CAAC,iBAAiB,IAEzB,IAAI,CAAC,eAAe,CACT,EACd,CAAA,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,sBAAA,EAA2B,MAAM,EAAC,IAAI,EAAC,QAAQ,EAAA,EAC5C,IAAI,CAAC,kBAAkB,CACnB,CACH;;;;;;;;;;;;"}
1
+ {"version":3,"file":"db-textarea.entry.esm.js","sources":["src/components/textarea/textarea.tsx"],"sourcesContent":["import { DBTextareaProps, DBTextareaState } from \"./model\";\nimport { DBInfotext } from \"../infotext/infotext\";\nimport {\n cls,\n delay,\n getBoolean,\n getHideProp,\n getNumber,\n hasVoiceOver,\n stringPropVisible,\n uuid,\n} from \"../../utils\";\nimport {\n DEFAULT_INVALID_MESSAGE,\n DEFAULT_INVALID_MESSAGE_ID_SUFFIX,\n DEFAULT_LABEL,\n DEFAULT_MESSAGE_ID_SUFFIX,\n DEFAULT_PLACEHOLDER,\n DEFAULT_ROWS,\n DEFAULT_VALID_MESSAGE,\n DEFAULT_VALID_MESSAGE_ID_SUFFIX,\n} from \"../../shared/constants\";\nimport { ChangeEvent, InputEvent, InteractionEvent } from \"../../shared/model\";\nimport {\n handleFrameworkEventAngular,\n handleFrameworkEventVue,\n} from \"../../utils/form-components\";\n\nimport {\n Component,\n h,\n Fragment,\n Watch,\n Event,\n EventEmitter,\n Prop,\n State,\n} from \"@stencil/core\";\n\n\n/**\n * @slot children - This is a default/unnamed slot\n\n */\n @Component({\n tag: \"db-textarea\",\n})\nexport class DBTextarea {\n private _ref!: HTMLTextAreaElement | any;\n @Prop() id: DBTextareaProps[\"id\"];\n @Prop() invalidMessage: DBTextareaProps[\"invalidMessage\"];\n @Prop() message: DBTextareaProps[\"message\"];\n @Prop() showMessage: DBTextareaProps[\"showMessage\"];\n @Prop() value: DBTextareaProps[\"value\"];\n @Prop() validMessage: DBTextareaProps[\"validMessage\"];\n @Prop() validation: DBTextareaProps[\"validation\"];\n @Prop() required: DBTextareaProps[\"required\"];\n @Prop() minLength: DBTextareaProps[\"minLength\"];\n @Prop() maxLength: DBTextareaProps[\"maxLength\"];\n @Event() input: EventEmitter<\n Parameters<Required<DBTextareaProps>[\"onInput\"]>[number]\n > | void;\n @Event() change: EventEmitter<\n Parameters<Required<DBTextareaProps>[\"onChange\"]>[number]\n > | void;\n @Event() blur: EventEmitter<\n Parameters<Required<DBTextareaProps>[\"onBlur\"]>[number]\n > | void;\n @Event() focus: EventEmitter<\n Parameters<Required<DBTextareaProps>[\"onFocus\"]>[number]\n > | void;\n @Prop({attribute: \"classname\"}) className: DBTextareaProps[\"className\"];\n @Prop() variant: DBTextareaProps[\"variant\"];\n @Prop() showLabel: DBTextareaProps[\"showLabel\"];\n @Prop() label: DBTextareaProps[\"label\"];\n @Prop() resize: DBTextareaProps[\"resize\"];\n @Prop() disabled: DBTextareaProps[\"disabled\"];\n @Prop() readOnly: DBTextareaProps[\"readOnly\"];\n @Prop() readonly: DBTextareaProps[\"readonly\"];\n @Prop() form: DBTextareaProps[\"form\"];\n @Prop() maxlength: DBTextareaProps[\"maxlength\"];\n @Prop() minlength: DBTextareaProps[\"minlength\"];\n @Prop() name: DBTextareaProps[\"name\"];\n @Prop() wrap: DBTextareaProps[\"wrap\"];\n @Prop() spellCheck: DBTextareaProps[\"spellCheck\"];\n @Prop() autocomplete: DBTextareaProps[\"autocomplete\"];\n @Prop() ariaDescribedBy: DBTextareaProps[\"ariaDescribedBy\"];\n @Prop() placeholder: DBTextareaProps[\"placeholder\"];\n @Prop() rows: DBTextareaProps[\"rows\"];\n @Prop() cols: DBTextareaProps[\"cols\"];\n @Prop() messageIcon: DBTextareaProps[\"messageIcon\"];\n @State() _id = undefined;\n @State() _messageId = undefined;\n @State() _validMessageId = undefined;\n @State() _invalidMessageId = undefined;\n @State() _invalidMessage = undefined;\n @State() _descByIds = \"\";\n @State() _value = \"\";\n @State() _voiceOverFallback = \"\";\n\n hasValidState() {\n return !!(this.validMessage ?? this.validation === \"valid\");\n }\n handleValidation() {\n /* For a11y reasons we need to map the correct message with the textarea */\n if (!this._ref?.validity.valid || this.validation === \"invalid\") {\n this._descByIds = this._invalidMessageId;\n this._invalidMessage =\n this.invalidMessage ||\n this._ref?.validationMessage ||\n DEFAULT_INVALID_MESSAGE;\n if (hasVoiceOver()) {\n this._voiceOverFallback = this._invalidMessage;\n delay(() => (this._voiceOverFallback = \"\"), 1000);\n }\n } else if (\n this.hasValidState() &&\n this._ref?.validity.valid &&\n (this.required || this.minLength || this.maxLength)\n ) {\n this._descByIds = this._validMessageId;\n if (hasVoiceOver()) {\n this._voiceOverFallback = this.validMessage ?? DEFAULT_VALID_MESSAGE;\n delay(() => (this._voiceOverFallback = \"\"), 1000);\n }\n } else if (stringPropVisible(this.message, this.showMessage)) {\n this._descByIds = this._messageId;\n } else {\n this._descByIds = \"\";\n }\n }\n handleInput(event: InputEvent<HTMLTextAreaElement>) {\n event.stopPropagation();\n if (this.input) {\n this.input.emit(event);\n }\n this.handleValidation();\n }\n handleChange(event: ChangeEvent<HTMLTextAreaElement>) {\n event.stopPropagation();\n if (this.change) {\n this.change.emit(event);\n }\n this.handleValidation();\n }\n handleBlur(event: InteractionEvent<HTMLTextAreaElement> | any) {\n event.stopPropagation();\n if (this.blur) {\n this.blur.emit(event);\n }\n }\n handleFocus(event: InteractionEvent<HTMLTextAreaElement> | any) {\n event.stopPropagation();\n if (this.focus) {\n this.focus.emit(event);\n }\n }\n\n /**\n * Passes `aria-*`, `data-*` & `class` attributes to correct child. Used in angular and stencil.\n * @param element the ref for the component\n * @param customElementSelector the custom element like `my-component`\n */\n private enableAttributePassing(\n element: HTMLTextAreaElement | null,\n customElementSelector: string\n ) {\n const parent = element?.closest(customElementSelector);\n if (element && parent) {\n const attributes = parent.attributes;\n for (let i = 0; i < attributes.length; i++) {\n const attr = attributes.item(i);\n if (\n attr &&\n (attr.name.startsWith(\"data-\") || attr.name.startsWith(\"aria-\"))\n ) {\n element.setAttribute(attr.name, attr.value);\n parent.removeAttribute(attr.name);\n }\n if (attr && attr.name === \"class\") {\n const isWebComponent = attr.value.includes(\"hydrated\");\n const value = attr.value.replace(\"hydrated\", \"\").trim();\n const currentClass = element.getAttribute(\"class\");\n element.setAttribute(\n attr.name,\n `${currentClass ? `${currentClass} ` : \"\"}${value}`\n );\n if (isWebComponent) {\n // Stencil is using this class for lazy loading component\n parent.setAttribute(\"class\", \"hydrated\");\n } else {\n parent.removeAttribute(attr.name);\n }\n }\n }\n }\n }\n\n watch0Fn() {\n this._invalidMessage =\n this.invalidMessage ||\n this._ref?.validationMessage ||\n DEFAULT_INVALID_MESSAGE;\n }\n\n @Watch(\"_ref\")\n @Watch(\"invalidMessage\")\n watch0() {\n this.watch0Fn();\n }\n\n watch1Fn() {\n if (this._id) {\n const messageId = this._id + DEFAULT_MESSAGE_ID_SUFFIX;\n this._messageId = messageId;\n this._validMessageId = this._id + DEFAULT_VALID_MESSAGE_ID_SUFFIX;\n this._invalidMessageId = this._id + DEFAULT_INVALID_MESSAGE_ID_SUFFIX;\n if (stringPropVisible(this.message, this.showMessage)) {\n this._descByIds = messageId;\n }\n }\n }\n\n @Watch(\"_id\")\n watch1() {\n this.watch1Fn();\n }\n\n watch2Fn() {\n this._value = this.value;\n }\n\n @Watch(\"value\")\n watch2() {\n this.watch2Fn();\n }\n\n componentDidLoad() {\n this.enableAttributePassing(this._ref, \"db-textarea\");\n const mId = this.id ?? `textarea-${uuid()}`;\n this._id = mId;\n this._messageId = mId + DEFAULT_MESSAGE_ID_SUFFIX;\n this._validMessageId = mId + DEFAULT_VALID_MESSAGE_ID_SUFFIX;\n this._invalidMessageId = mId + DEFAULT_INVALID_MESSAGE_ID_SUFFIX;\n this._invalidMessage = this.invalidMessage || DEFAULT_INVALID_MESSAGE;\n this.watch0Fn();\n this.watch1Fn();\n this.watch2Fn();\n }\n\n render() {\n return (\n <div\n class={cls(\"db-textarea\", this.className)}\n data-variant={this.variant}\n data-hide-label={getHideProp(this.showLabel)}\n >\n <label htmlFor={this._id}>{this.label ?? DEFAULT_LABEL}</label>\n <textarea\n aria-invalid={this.validation === \"invalid\"}\n data-custom-validity={this.validation}\n ref={(el: any) => {\n this._ref = el;\n }}\n id={this._id}\n data-resize={this.resize}\n disabled={getBoolean(this.disabled, \"disabled\")}\n required={getBoolean(this.required, \"required\")}\n readOnly={\n getBoolean(this.readOnly, \"readOnly\") ||\n getBoolean(this.readonly, \"readonly\")\n }\n form={this.form}\n maxLength={getNumber(this.maxLength, this.maxlength)}\n minLength={getNumber(this.minLength, this.minlength)}\n name={this.name}\n wrap={this.wrap}\n spellcheck={this.spellCheck}\n autocomplete={this.autocomplete}\n onInput={(event) => this.handleInput(event)}\n onChange={(event) => this.handleChange(event)}\n onBlur={(event) => this.handleBlur(event)}\n onFocus={(event) => this.handleFocus(event)}\n value={this.value ?? this._value}\n aria-describedby={this.ariaDescribedBy ?? this._descByIds}\n placeholder={this.placeholder ?? DEFAULT_PLACEHOLDER}\n rows={getNumber(this.rows, DEFAULT_ROWS)}\n cols={getNumber(this.cols)}\n ></textarea>\n {stringPropVisible(this.message, this.showMessage) ? (\n <db-infotext\n size=\"small\"\n icon={this.messageIcon}\n id={this._messageId}\n >\n {this.message}\n </db-infotext>\n ) : null}\n {this.hasValidState() ? (\n <db-infotext\n size=\"small\"\n semantic=\"successful\"\n id={this._validMessageId}\n >\n {this.validMessage || DEFAULT_VALID_MESSAGE}\n </db-infotext>\n ) : null}\n <db-infotext\n size=\"small\"\n semantic=\"critical\"\n id={this._invalidMessageId}\n >\n {this._invalidMessage}\n </db-infotext>\n <span data-visually-hidden=\"true\" role=\"status\">\n {this._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,GAAA,IAAI,CAAC,UAAU,EACzD,WAAW,EAAE,MAAA,IAAI,CAAC,WAAW,MAAI,IAAA,IAAA,EAAA,KAAA,MAAA,GAAA,EAAA,GAAA,mBAAmB,EACpD,IAAI,EAAE,SAAS,CAAC,IAAI,CAAC,IAAI,EAAE,YAAY,CAAC,EACxC,IAAI,EAAE,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,EAChB,CAAA,EACX,iBAAiB,CAAC,IAAI,CAAC,OAAO,EAAE,IAAI,CAAC,WAAW,CAAC,IAChD,mBACE,IAAI,EAAC,OAAO,EACZ,IAAI,EAAE,IAAI,CAAC,WAAW,EACtB,EAAE,EAAE,IAAI,CAAC,UAAU,EAElB,EAAA,IAAI,CAAC,OAAO,CACD,IACZ,IAAI,EACP,IAAI,CAAC,aAAa,EAAE,IACnB,CACE,CAAA,aAAA,EAAA,EAAA,IAAI,EAAC,OAAO,EACZ,QAAQ,EAAC,YAAY,EACrB,EAAE,EAAE,IAAI,CAAC,eAAe,EAAA,EAEvB,IAAI,CAAC,YAAY,IAAI,qBAAqB,CAC/B,IACZ,IAAI,EACR,CAAA,CAAA,aAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EACE,IAAI,EAAC,OAAO,EACZ,QAAQ,EAAC,UAAU,EACnB,EAAE,EAAE,IAAI,CAAC,iBAAiB,IAEzB,IAAI,CAAC,eAAe,CACT,EACd,CAAA,CAAA,MAAA,EAAA,EAAA,GAAA,EAAA,0CAAA,EAAA,sBAAA,EAA2B,MAAM,EAAC,IAAI,EAAC,QAAQ,EAAA,EAC5C,IAAI,CAAC,kBAAkB,CACnB,CACH;;;;;;;;;;;;"}
@@ -1,2 +1,2 @@
1
- import{p as e,b as a}from"./p-bH2PZLSq.js";export{s as setNonce}from"./p-bH2PZLSq.js";import{g as i}from"./p-DQuL1Twl.js";var l=()=>{const a=import.meta.url;const i={};if(a!==""){i.resourcesUrl=new URL(".",a).href}return e(i)};l().then((async e=>{await i();return a(JSON.parse('[["p-b5a8e9c3",[[4,"db-custom-select",{"id":[1],"invalidMessage":[1,"invalid-message"],"message":[1],"showMessage":[8,"show-message"],"showNoResults":[4,"show-no-results"],"multiple":[8],"showSelectAll":[4,"show-select-all"],"showSearch":[4,"show-search"],"values":[16],"validation":[1],"options":[16],"selectedType":[1,"selected-type"],"amountText":[1,"amount-text"],"validMessage":[1,"valid-message"],"required":[8],"selectAllLabel":[1,"select-all-label"],"removeTagsTexts":[16,"remove-tags-texts"],"className":[1,"classname"],"formFieldWidth":[1,"form-field-width"],"variant":[1],"placement":[1],"showLabel":[8,"show-label"],"icon":[1],"showIcon":[8,"show-icon"],"label":[1],"form":[1],"name":[1],"disabled":[8],"open":[4],"dropdownWidth":[1,"dropdown-width"],"searchLabel":[1,"search-label"],"searchPlaceholder":[1,"search-placeholder"],"showLoading":[4,"show-loading"],"ariaListLabel":[1,"aria-list-label"],"noResultsText":[1,"no-results-text"],"loadingText":[1,"loading-text"],"mobileCloseButtonText":[1,"mobile-close-button-text"],"showClearSelection":[4,"show-clear-selection"],"clearSelectionText":[1,"clear-selection-text"],"placeholder":[1],"messageIcon":[1,"message-icon"],"_id":[32],"_messageId":[32],"_validMessageId":[32],"_invalidMessageId":[32],"_invalidMessage":[32],"_selectId":[32],"_labelId":[32],"_summaryId":[32],"_placeholderId":[32],"_infoTextId":[32],"_validity":[32],"_descByIds":[32],"_selectedLabels":[32],"_selectedLabelsId":[32],"_voiceOverFallback":[32],"_selectedOptions":[32],"selectAllEnabled":[32],"searchEnabled":[32],"amountOptions":[32],"_values":[32],"_options":[32],"_hasNoOptions":[32],"_documentClickListenerCallbackId":[32],"_internalChangeTimestamp":[32],"selectAllChecked":[32],"selectAllIndeterminate":[32]},null,{"detailsRef":["watch0","watch2"],"_id":["watch1"],"_descByIds":["watch2"],"showNoResults":["watch3"],"_options":["watch3","watch11"],"showSelectAll":["watch4"],"amountOptions":["watch4","watch5","watch9"],"multiple":["watch4"],"showSearch":["watch5"],"values":["watch6"],"_values":["watch7","watch9","watch11"],"validation":["watch8"],"options":["watch10"],"_selectedOptions":["watch12","watch13"],"selectedType":["watch12"],"amountText":["watch12"],"selectAllIndeterminate":["watch14"],"selectAllRef":["watch14"],"selectRef":["watch15"],"invalidMessage":["watch15"]}]]],["p-c151750e",[[4,"db-tabs",{"id":[1],"name":[1],"tabs":[1],"arrowScrollDistance":[8,"arrow-scroll-distance"],"orientation":[1],"behavior":[1],"initialSelectedMode":[1,"initial-selected-mode"],"initialSelectedIndex":[8,"initial-selected-index"],"className":[1,"classname"],"alignment":[1],"width":[1],"_id":[32],"_name":[32],"initialized":[32],"showScrollLeft":[32],"showScrollRight":[32],"scrollContainer":[32]},null,{"_ref":["watch0"],"initialized":["watch0"]}]]],["p-5c2e9373",[[4,"db-header",{"id":[1],"forceMobile":[8,"force-mobile"],"drawerOpen":[8,"drawer-open"],"className":[1,"classname"],"width":[1],"burgerMenuLabel":[1,"burger-menu-label"],"_id":[32],"initialized":[32],"forcedToMobile":[32]},null,{"initialized":["watch0"]}]]],["p-d7ccd983",[[4,"db-accordion",{"id":[1],"name":[1],"behavior":[1],"initOpenIndex":[16,"init-open-index"],"items":[1],"className":[1,"classname"],"variant":[1],"_id":[32],"_name":[32],"initialized":[32],"_initOpenIndexDone":[32]},null,{"initialized":["watch0"],"name":["watch0"],"behavior":["watch0"],"_id":["watch0"],"_ref":["watch1","watch2"],"_name":["watch1"],"_initOpenIndexDone":["watch2"],"initOpenIndex":["watch2"]}]]],["p-44f6404b",[[4,"db-checkbox",{"id":[1],"invalidMessage":[1,"invalid-message"],"message":[1],"showMessage":[8,"show-message"],"indeterminate":[8],"checked":[8],"validMessage":[1,"valid-message"],"validation":[1],"required":[8],"className":[1,"classname"],"size":[1],"showLabel":[8,"show-label"],"name":[1],"disabled":[8],"value":[8],"label":[1],"messageIcon":[1,"message-icon"],"initialized":[32],"_id":[32],"_messageId":[32],"_validMessageId":[32],"_invalidMessageId":[32],"_invalidMessage":[32],"_descByIds":[32],"_voiceOverFallback":[32]},null,{"_ref":["watch0","watch2","watch3"],"invalidMessage":["watch0"],"_id":["watch1"],"initialized":["watch2","watch3"],"indeterminate":["watch2"],"checked":["watch3"]}]]],["p-c989b5d8",[[4,"db-navigation-item",{"subNavigationExpanded":[8,"sub-navigation-expanded"],"id":[1],"className":[1,"classname"],"width":[1],"icon":[1],"showIcon":[8,"show-icon"],"active":[4],"wrap":[8],"disabled":[8],"text":[1],"backButtonId":[1,"back-button-id"],"backButtonText":[1,"back-button-text"],"initialized":[32],"hasAreaPopup":[32],"hasSubNavigation":[32],"isSubNavigationExpanded":[32],"autoClose":[32],"subNavigationId":[32],"navigationItemSafeTriangle":[32]},null,{"subNavigationExpanded":["watch0"],"initialized":["watch1"],"_ref":["watch1"]}]]],["p-39d957bb",[[4,"db-notification",{"id":[1],"className":[1,"classname"],"ariaLive":[1,"aria-live"],"semantic":[1],"variant":[1],"icon":[1],"showIcon":[8,"show-icon"],"linkVariant":[1,"link-variant"],"headline":[8],"showHeadline":[8,"show-headline"],"text":[1],"timestamp":[1],"showTimestamp":[8,"show-timestamp"],"closeable":[8],"closeButtonId":[1,"close-button-id"],"closeButtonText":[1,"close-button-text"]}]]],["p-1d40e8cd",[[4,"db-select",{"id":[1],"invalidMessage":[1,"invalid-message"],"message":[1],"showMessage":[8,"show-message"],"value":[8],"validMessage":[1,"valid-message"],"validation":[1],"required":[8],"className":[1,"classname"],"variant":[1],"showLabel":[8,"show-label"],"icon":[1],"showIcon":[8,"show-icon"],"label":[1],"disabled":[8],"name":[1],"size":[2],"autocomplete":[1],"multiple":[4],"options":[16],"placeholder":[1],"messageIcon":[1,"message-icon"],"_id":[32],"_messageId":[32],"_validMessageId":[32],"_invalidMessageId":[32],"_invalidMessage":[32],"_placeholderId":[32],"_descByIds":[32],"_value":[32],"initialized":[32],"_voiceOverFallback":[32]},null,{"_ref":["watch0"],"invalidMessage":["watch0"],"_id":["watch1"],"initialized":["watch1"],"value":["watch2"]}]]],["p-a1ee66b3",[[0,"db-textarea",{"id":[1],"invalidMessage":[1,"invalid-message"],"message":[1],"showMessage":[8,"show-message"],"value":[8],"validMessage":[1,"valid-message"],"validation":[1],"required":[8],"minLength":[8,"min-length"],"maxLength":[8,"max-length"],"className":[1,"classname"],"variant":[1],"showLabel":[8,"show-label"],"label":[1],"resize":[1],"disabled":[8],"readOnly":[8,"read-only"],"readonly":[8],"form":[1],"maxlength":[8],"minlength":[8],"name":[1],"wrap":[1],"spellCheck":[4,"spell-check"],"autocomplete":[1],"placeholder":[1],"rows":[8],"cols":[8],"messageIcon":[1,"message-icon"],"_id":[32],"_messageId":[32],"_validMessageId":[32],"_invalidMessageId":[32],"_invalidMessage":[32],"_descByIds":[32],"_value":[32],"_voiceOverFallback":[32]},null,{"_ref":["watch0"],"invalidMessage":["watch0"],"_id":["watch1"],"value":["watch2"]}]]],["p-6b6dbd54",[[4,"db-badge",{"placement":[1],"id":[1],"className":[1,"classname"],"semantic":[1],"size":[1],"emphasis":[1],"label":[1],"text":[1],"initialized":[32]},null,{"_ref":["watch0"],"initialized":["watch0"]}]]],["p-8b7d868b",[[4,"db-brand",{"hideLogo":[4,"hide-logo"],"icon":[1],"showIcon":[8,"show-icon"],"id":[1],"className":[1,"classname"],"text":[1]}]]],["p-623a9409",[[4,"db-card",{"id":[1],"className":[1,"classname"],"behavior":[1],"elevationLevel":[1,"elevation-level"],"spacing":[1]}]]],["p-c5909b40",[[4,"db-custom-select-form-field",{"id":[1],"className":[1,"classname"]}]]],["p-52e736c3",[[0,"db-divider",{"id":[1],"margin":[1],"variant":[1],"emphasis":[1],"width":[1],"className":[1,"classname"]}]]],["p-14c44b94",[[4,"db-icon",{"id":[1],"className":[1,"classname"],"icon":[1],"weight":[1],"variant":[1],"text":[1]}]]],["p-33aaf986",[[4,"db-link",{"id":[1],"className":[1,"classname"],"href":[1],"target":[1],"rel":[1],"role":[1],"hreflang":[1],"disabled":[8],"selected":[8],"label":[1],"current":[8],"size":[1],"showIcon":[8,"show-icon"],"variant":[1],"content":[1],"text":[1]}]]],["p-49cc4a11",[[4,"db-navigation",{"id":[1],"labelledBy":[1,"labelled-by"],"className":[1,"classname"],"_id":[32]}]]],["p-63f30576",[[4,"db-page",{"fadeIn":[8,"fade-in"],"documentOverflow":[1,"document-overflow"],"variant":[1],"id":[1],"className":[1,"classname"],"mainClass":[1,"main-class"],"fontsLoaded":[32]}]]],["p-f2ef5e71",[[4,"db-popover",{"id":[1],"className":[1,"classname"],"spacing":[1],"gap":[8],"animation":[8],"open":[8],"delay":[1],"width":[1],"placement":[1],"initialized":[32],"isExpanded":[32]},null,{"_ref":["watch0","watch1"],"initialized":["watch0"],"isExpanded":["watch1"]}]]],["p-50c9112b",[[4,"db-radio",{"id":[1],"checked":[8],"size":[1],"showLabel":[8,"show-label"],"className":[1,"classname"],"validation":[1],"name":[1],"disabled":[8],"describedbyid":[1],"value":[8],"required":[8],"label":[1],"initialized":[32],"_id":[32]},null,{"initialized":["watch0"],"_ref":["watch0"],"checked":["watch0"]}]]],["p-5c4d25b8",[[4,"db-section",{"id":[1],"className":[1,"classname"],"spacing":[1],"width":[1],"_id":[32]}]]],["p-01112955",[[4,"db-stack",{"id":[1],"className":[1,"classname"],"gap":[1],"variant":[1],"direction":[1],"alignment":[1],"justifyContent":[1,"justify-content"],"wrap":[8]}]]],["p-049844c6",[[4,"db-switch",{"id":[1],"checked":[8],"visualAid":[8,"visual-aid"],"size":[1],"showLabel":[8,"show-label"],"emphasis":[1],"className":[1,"classname"],"value":[8],"disabled":[8],"describedbyid":[1],"validation":[1],"name":[1],"required":[8],"icon":[1],"iconAfter":[1,"icon-after"],"label":[1],"_id":[32],"_checked":[32]},null,{"checked":["watch0"]}]]],["p-b3148401",[[4,"db-drawer",{"open":[8],"backdrop":[1],"variant":[1],"id":[1],"className":[1,"classname"],"spacing":[1],"width":[1],"direction":[1],"rounded":[8],"closeButtonId":[1,"close-button-id"],"closeButtonText":[1,"close-button-text"]},null,{"open":["watch0"]}]]],["p-4400f077",[[4,"db-accordion-item",{"id":[1],"defaultOpen":[4,"default-open"],"name":[1],"className":[1,"classname"],"disabled":[8],"headlinePlain":[1,"headline-plain"],"text":[1],"_id":[32],"_open":[32],"_name":[32],"initialized":[32]},null,{"_ref":["watch0"],"initialized":["watch0"],"name":["watch1"]}]]],["p-55b02c80",[[4,"db-tab-item",{"active":[8],"name":[1],"className":[1,"classname"],"id":[1],"icon":[1],"iconAfter":[1,"icon-after"],"showIcon":[8,"show-icon"],"noText":[8,"no-text"],"disabled":[8],"controls":[1],"checked":[8],"label":[1],"_selected":[32],"_name":[32],"initialized":[32]},null,{"_ref":["watch0"],"initialized":["watch0"],"name":["watch1"]}],[4,"db-tab-list",{"id":[1],"className":[1,"classname"],"_id":[32]}],[4,"db-tab-panel",{"className":[1,"classname"],"id":[1],"labelledBy":[1,"labelled-by"],"content":[1]}]]],["p-b4bc8f26",[[4,"db-infotext",{"id":[1],"className":[1,"classname"],"icon":[1],"semantic":[1],"size":[1],"showIcon":[8,"show-icon"],"text":[1]}]]],["p-d9ff0c75",[[4,"db-input",{"id":[1],"invalidMessage":[1,"invalid-message"],"dataListId":[1,"data-list-id"],"message":[1],"showMessage":[8,"show-message"],"value":[8],"validMessage":[1,"valid-message"],"validation":[1],"required":[8],"minLength":[8,"min-length"],"maxLength":[8,"max-length"],"pattern":[1],"dataList":[16,"data-list"],"className":[1,"classname"],"variant":[1],"showLabel":[8,"show-label"],"showIcon":[8,"show-icon"],"icon":[1],"iconAfter":[1,"icon-after"],"label":[1],"name":[1],"type":[1],"placeholder":[1],"disabled":[8],"step":[8],"maxlength":[8],"minlength":[8],"max":[8],"min":[8],"readOnly":[8,"read-only"],"readonly":[8],"form":[1],"size":[2],"autocomplete":[1],"autofocus":[8],"ariaDescribedBy":[1,"aria-described-by"],"messageIcon":[1,"message-icon"],"_id":[32],"_messageId":[32],"_validMessageId":[32],"_invalidMessageId":[32],"_invalidMessage":[32],"_dataListId":[32],"_descByIds":[32],"_value":[32],"_voiceOverFallback":[32]},null,{"_ref":["watch0"],"invalidMessage":["watch0"],"_id":["watch1"],"value":["watch2"]}],[4,"db-custom-select-dropdown",{"id":[1],"className":[1,"classname"],"width":[1]}],[4,"db-custom-select-list",{"multiple":[4],"label":[1],"id":[1],"className":[1,"classname"]}],[4,"db-custom-select-list-item",{"id":[1],"isGroupTitle":[4,"is-group-title"],"showDivider":[4,"show-divider"],"type":[1],"checked":[8],"className":[1,"classname"],"groupTitle":[1,"group-title"],"icon":[1],"showIcon":[8,"show-icon"],"name":[1],"disabled":[8],"value":[8],"label":[1],"_id":[32],"hasDivider":[32]},null,{"isGroupTitle":["watch0"],"showDivider":["watch0"]}],[4,"db-tag",{"disabled":[8],"removeButton":[1,"remove-button"],"id":[1],"className":[1,"classname"],"semantic":[1],"emphasis":[1],"icon":[1],"showCheckState":[8,"show-check-state"],"showIcon":[8,"show-icon"],"noText":[8,"no-text"],"overflow":[8],"text":[1],"behavior":[1],"initialized":[32]},null,{"initialized":["watch0"],"disabled":["watch0"],"_ref":["watch0"]}],[4,"db-tooltip",{"id":[1],"className":[1,"classname"],"emphasis":[1],"animation":[8],"delay":[1],"width":[1],"showArrow":[8,"show-arrow"],"placement":[1],"_id":[32],"initialized":[32]},null,{"_ref":["watch0"],"initialized":["watch0"]}]]],["p-61410d87",[[4,"db-button",{"id":[1],"className":[1,"classname"],"type":[1],"disabled":[8],"label":[1],"icon":[1],"showIcon":[8,"show-icon"],"size":[1],"state":[1],"width":[1],"variant":[1],"noText":[8,"no-text"],"name":[1],"form":[1],"value":[1],"describedbyid":[1],"ariaexpanded":[4],"ariapressed":[4],"text":[1]}]]]]'),e)}));
1
+ import{p as e,b as a}from"./p-bH2PZLSq.js";export{s as setNonce}from"./p-bH2PZLSq.js";import{g as i}from"./p-DQuL1Twl.js";var l=()=>{const a=import.meta.url;const i={};if(a!==""){i.resourcesUrl=new URL(".",a).href}return e(i)};l().then((async e=>{await i();return a(JSON.parse('[["p-5fdc8db6",[[4,"db-custom-select",{"id":[1],"invalidMessage":[1,"invalid-message"],"message":[1],"showMessage":[8,"show-message"],"ariaDescribedBy":[1,"aria-described-by"],"showNoResults":[4,"show-no-results"],"multiple":[8],"showSelectAll":[4,"show-select-all"],"showSearch":[4,"show-search"],"values":[16],"validation":[1],"options":[16],"selectedType":[1,"selected-type"],"amountText":[1,"amount-text"],"validMessage":[1,"valid-message"],"required":[8],"selectAllLabel":[1,"select-all-label"],"removeTagsTexts":[16,"remove-tags-texts"],"placement":[1],"className":[1,"classname"],"formFieldWidth":[1,"form-field-width"],"variant":[1],"showLabel":[8,"show-label"],"icon":[1],"showIcon":[8,"show-icon"],"label":[1],"form":[1],"name":[1],"disabled":[8],"open":[4],"dropdownWidth":[1,"dropdown-width"],"searchLabel":[1,"search-label"],"searchPlaceholder":[1,"search-placeholder"],"showLoading":[4,"show-loading"],"ariaListLabel":[1,"aria-list-label"],"noResultsText":[1,"no-results-text"],"loadingText":[1,"loading-text"],"mobileCloseButtonText":[1,"mobile-close-button-text"],"showClearSelection":[4,"show-clear-selection"],"clearSelectionText":[1,"clear-selection-text"],"placeholder":[1],"messageIcon":[1,"message-icon"],"_id":[32],"_messageId":[32],"_validMessageId":[32],"_invalidMessageId":[32],"_invalidMessage":[32],"_selectId":[32],"_labelId":[32],"_summaryId":[32],"_placeholderId":[32],"_infoTextId":[32],"_validity":[32],"_descByIds":[32],"_selectedLabels":[32],"_selectedLabelsId":[32],"_voiceOverFallback":[32],"_selectedOptions":[32],"selectAllEnabled":[32],"searchEnabled":[32],"amountOptions":[32],"_values":[32],"_options":[32],"_hasNoOptions":[32],"_documentClickListenerCallbackId":[32],"_internalChangeTimestamp":[32],"_documentScrollListenerCallbackId":[32],"_observer":[32],"selectAllChecked":[32],"selectAllIndeterminate":[32]},null,{"detailsRef":["watch0","watch2"],"_id":["watch1"],"_descByIds":["watch2"],"showNoResults":["watch3"],"_options":["watch3"],"showSelectAll":["watch4"],"amountOptions":["watch4","watch5","watch9"],"multiple":["watch4"],"showSearch":["watch5"],"values":["watch6"],"_values":["watch7","watch9","watch11"],"validation":["watch8"],"options":["watch10","watch11"],"_selectedOptions":["watch12","watch13"],"selectedType":["watch12"],"amountText":["watch12"],"selectAllIndeterminate":["watch14"],"selectAllRef":["watch14"],"selectRef":["watch15"],"invalidMessage":["watch15"]}]]],["p-a4d62218",[[4,"db-tabs",{"id":[1],"name":[1],"tabs":[1],"arrowScrollDistance":[8,"arrow-scroll-distance"],"orientation":[1],"behavior":[1],"initialSelectedMode":[1,"initial-selected-mode"],"initialSelectedIndex":[8,"initial-selected-index"],"className":[1,"classname"],"alignment":[1],"width":[1],"_id":[32],"_name":[32],"initialized":[32],"showScrollLeft":[32],"showScrollRight":[32],"scrollContainer":[32]},null,{"_ref":["watch0"],"initialized":["watch0"]}]]],["p-75a55c2c",[[4,"db-header",{"id":[1],"forceMobile":[8,"force-mobile"],"drawerOpen":[8,"drawer-open"],"className":[1,"classname"],"width":[1],"burgerMenuLabel":[1,"burger-menu-label"],"_id":[32],"initialized":[32],"forcedToMobile":[32]},null,{"initialized":["watch0"]}]]],["p-7636be02",[[4,"db-accordion",{"id":[1],"name":[1],"behavior":[1],"initOpenIndex":[16,"init-open-index"],"items":[1],"className":[1,"classname"],"variant":[1],"_id":[32],"_name":[32],"initialized":[32],"_initOpenIndexDone":[32]},null,{"initialized":["watch0"],"name":["watch0"],"behavior":["watch0"],"_id":["watch0"],"_ref":["watch1","watch2"],"_name":["watch1"],"_initOpenIndexDone":["watch2"],"initOpenIndex":["watch2"]}]]],["p-4aa47b47",[[4,"db-checkbox",{"id":[1],"invalidMessage":[1,"invalid-message"],"message":[1],"showMessage":[8,"show-message"],"indeterminate":[8],"checked":[8],"validMessage":[1,"valid-message"],"validation":[1],"required":[8],"className":[1,"classname"],"size":[1],"showLabel":[8,"show-label"],"name":[1],"disabled":[8],"value":[8],"ariaDescribedBy":[1,"aria-described-by"],"label":[1],"messageIcon":[1,"message-icon"],"initialized":[32],"_id":[32],"_messageId":[32],"_validMessageId":[32],"_invalidMessageId":[32],"_invalidMessage":[32],"_descByIds":[32],"_voiceOverFallback":[32]},null,{"_ref":["watch0","watch2","watch3"],"invalidMessage":["watch0"],"_id":["watch1"],"initialized":["watch2","watch3"],"indeterminate":["watch2"],"checked":["watch3"]}]]],["p-16f8a2d5",[[4,"db-navigation-item",{"subNavigationExpanded":[8,"sub-navigation-expanded"],"id":[1],"className":[1,"classname"],"width":[1],"icon":[1],"showIcon":[8,"show-icon"],"active":[4],"wrap":[8],"disabled":[8],"text":[1],"backButtonId":[1,"back-button-id"],"backButtonText":[1,"back-button-text"],"initialized":[32],"hasAreaPopup":[32],"hasSubNavigation":[32],"isSubNavigationExpanded":[32],"autoClose":[32],"subNavigationId":[32],"navigationItemSafeTriangle":[32]},null,{"subNavigationExpanded":["watch0"],"initialized":["watch1"],"_ref":["watch1"]}]]],["p-166b337e",[[4,"db-notification",{"id":[1],"className":[1,"classname"],"ariaLive":[1,"aria-live"],"semantic":[1],"variant":[1],"icon":[1],"showIcon":[8,"show-icon"],"linkVariant":[1,"link-variant"],"headline":[8],"showHeadline":[8,"show-headline"],"text":[1],"timestamp":[1],"showTimestamp":[8,"show-timestamp"],"closeable":[8],"closeButtonId":[1,"close-button-id"],"closeButtonText":[1,"close-button-text"]}]]],["p-199c8a0f",[[4,"db-select",{"id":[1],"invalidMessage":[1,"invalid-message"],"message":[1],"showMessage":[8,"show-message"],"value":[8],"validMessage":[1,"valid-message"],"validation":[1],"required":[8],"className":[1,"classname"],"variant":[1],"showLabel":[8,"show-label"],"icon":[1],"showIcon":[8,"show-icon"],"label":[1],"disabled":[8],"name":[1],"size":[2],"autocomplete":[1],"multiple":[4],"ariaDescribedBy":[1,"aria-described-by"],"options":[16],"placeholder":[1],"messageIcon":[1,"message-icon"],"_id":[32],"_messageId":[32],"_validMessageId":[32],"_invalidMessageId":[32],"_invalidMessage":[32],"_placeholderId":[32],"_descByIds":[32],"_value":[32],"initialized":[32],"_voiceOverFallback":[32]},null,{"_ref":["watch0"],"invalidMessage":["watch0"],"_id":["watch1"],"initialized":["watch1"],"value":["watch2"]}]]],["p-d45c03e4",[[0,"db-textarea",{"id":[1],"invalidMessage":[1,"invalid-message"],"message":[1],"showMessage":[8,"show-message"],"value":[8],"validMessage":[1,"valid-message"],"validation":[1],"required":[8],"minLength":[8,"min-length"],"maxLength":[8,"max-length"],"className":[1,"classname"],"variant":[1],"showLabel":[8,"show-label"],"label":[1],"resize":[1],"disabled":[8],"readOnly":[8,"read-only"],"readonly":[8],"form":[1],"maxlength":[8],"minlength":[8],"name":[1],"wrap":[1],"spellCheck":[4,"spell-check"],"autocomplete":[1],"ariaDescribedBy":[1,"aria-described-by"],"placeholder":[1],"rows":[8],"cols":[8],"messageIcon":[1,"message-icon"],"_id":[32],"_messageId":[32],"_validMessageId":[32],"_invalidMessageId":[32],"_invalidMessage":[32],"_descByIds":[32],"_value":[32],"_voiceOverFallback":[32]},null,{"_ref":["watch0"],"invalidMessage":["watch0"],"_id":["watch1"],"value":["watch2"]}]]],["p-aae2a35a",[[4,"db-badge",{"placement":[1],"id":[1],"className":[1,"classname"],"semantic":[1],"size":[1],"emphasis":[1],"label":[1],"text":[1],"initialized":[32]},null,{"_ref":["watch0"],"initialized":["watch0"]}]]],["p-00ae6c1c",[[4,"db-brand",{"hideLogo":[4,"hide-logo"],"icon":[1],"showIcon":[8,"show-icon"],"id":[1],"className":[1,"classname"],"text":[1]}]]],["p-80f23995",[[4,"db-card",{"id":[1],"className":[1,"classname"],"behavior":[1],"elevationLevel":[1,"elevation-level"],"spacing":[1]}]]],["p-b5e12faa",[[4,"db-custom-select-form-field",{"id":[1],"className":[1,"classname"]}]]],["p-769c530c",[[0,"db-divider",{"id":[1],"margin":[1],"variant":[1],"emphasis":[1],"width":[1],"className":[1,"classname"]}]]],["p-da2d2518",[[4,"db-icon",{"id":[1],"className":[1,"classname"],"icon":[1],"weight":[1],"variant":[1],"text":[1]}]]],["p-c615e5e6",[[4,"db-link",{"id":[1],"className":[1,"classname"],"href":[1],"target":[1],"rel":[1],"role":[1],"hreflang":[1],"disabled":[8],"selected":[8],"label":[1],"current":[8],"size":[1],"showIcon":[8,"show-icon"],"variant":[1],"content":[1],"text":[1]}]]],["p-63f1d771",[[4,"db-navigation",{"id":[1],"labelledBy":[1,"labelled-by"],"className":[1,"classname"],"_id":[32]}]]],["p-57c4486c",[[4,"db-page",{"fadeIn":[8,"fade-in"],"documentOverflow":[1,"document-overflow"],"variant":[1],"id":[1],"className":[1,"classname"],"mainClass":[1,"main-class"],"fontsLoaded":[32]}]]],["p-2e0f291f",[[4,"db-popover",{"placement":[1],"id":[1],"className":[1,"classname"],"spacing":[1],"gap":[8],"animation":[8],"open":[8],"delay":[1],"width":[1],"initialized":[32],"isExpanded":[32],"_documentScrollListenerCallbackId":[32],"_observer":[32]},null,{"_ref":["watch0","watch1"],"initialized":["watch0"],"isExpanded":["watch1"]}]]],["p-0bf63ec2",[[4,"db-radio",{"id":[1],"checked":[8],"size":[1],"showLabel":[8,"show-label"],"className":[1,"classname"],"validation":[1],"name":[1],"disabled":[8],"describedbyid":[1],"ariaDescribedBy":[1,"aria-described-by"],"value":[8],"required":[8],"label":[1],"initialized":[32],"_id":[32]},null,{"initialized":["watch0"],"_ref":["watch0"],"checked":["watch0"]}]]],["p-d64ea737",[[4,"db-section",{"id":[1],"className":[1,"classname"],"spacing":[1],"width":[1],"_id":[32]}]]],["p-f17426ab",[[4,"db-stack",{"id":[1],"className":[1,"classname"],"gap":[1],"variant":[1],"direction":[1],"alignment":[1],"justifyContent":[1,"justify-content"],"wrap":[8]}]]],["p-423bf8f8",[[4,"db-switch",{"id":[1],"checked":[8],"visualAid":[8,"visual-aid"],"size":[1],"showLabel":[8,"show-label"],"emphasis":[1],"className":[1,"classname"],"value":[8],"disabled":[8],"describedbyid":[1],"ariaDescribedBy":[1,"aria-described-by"],"validation":[1],"name":[1],"required":[8],"icon":[1],"iconAfter":[1,"icon-after"],"label":[1],"_id":[32],"_checked":[32]},null,{"checked":["watch0"]}]]],["p-4b52b854",[[4,"db-drawer",{"open":[8],"backdrop":[1],"variant":[1],"id":[1],"className":[1,"classname"],"spacing":[1],"width":[1],"direction":[1],"rounded":[8],"closeButtonId":[1,"close-button-id"],"closeButtonText":[1,"close-button-text"]},null,{"open":["watch0"]}]]],["p-d28395c3",[[4,"db-accordion-item",{"id":[1],"defaultOpen":[4,"default-open"],"name":[1],"className":[1,"classname"],"disabled":[8],"headlinePlain":[1,"headline-plain"],"text":[1],"_id":[32],"_open":[32],"_name":[32],"initialized":[32]},null,{"_ref":["watch0"],"initialized":["watch0"],"name":["watch1"]}]]],["p-240497d9",[[4,"db-tab-item",{"active":[8],"name":[1],"className":[1,"classname"],"id":[1],"icon":[1],"iconAfter":[1,"icon-after"],"showIcon":[8,"show-icon"],"noText":[8,"no-text"],"disabled":[8],"controls":[1],"checked":[8],"label":[1],"_selected":[32],"_name":[32],"initialized":[32]},null,{"_ref":["watch0"],"initialized":["watch0"],"name":["watch1"]}],[4,"db-tab-list",{"id":[1],"className":[1,"classname"],"_id":[32]}],[4,"db-tab-panel",{"className":[1,"classname"],"id":[1],"labelledBy":[1,"labelled-by"],"content":[1]}]]],["p-cc6df17e",[[4,"db-infotext",{"id":[1],"className":[1,"classname"],"icon":[1],"semantic":[1],"size":[1],"showIcon":[8,"show-icon"],"text":[1]}]]],["p-3df47dd9",[[4,"db-input",{"id":[1],"invalidMessage":[1,"invalid-message"],"dataListId":[1,"data-list-id"],"message":[1],"showMessage":[8,"show-message"],"value":[8],"validMessage":[1,"valid-message"],"validation":[1],"required":[8],"minLength":[8,"min-length"],"maxLength":[8,"max-length"],"pattern":[1],"dataList":[16,"data-list"],"className":[1,"classname"],"variant":[1],"showLabel":[8,"show-label"],"showIcon":[8,"show-icon"],"icon":[1],"iconAfter":[1,"icon-after"],"label":[1],"name":[1],"type":[1],"placeholder":[1],"disabled":[8],"step":[8],"maxlength":[8],"minlength":[8],"max":[8],"min":[8],"readOnly":[8,"read-only"],"readonly":[8],"form":[1],"size":[2],"autocomplete":[1],"autofocus":[8],"ariaDescribedBy":[1,"aria-described-by"],"messageIcon":[1,"message-icon"],"_id":[32],"_messageId":[32],"_validMessageId":[32],"_invalidMessageId":[32],"_invalidMessage":[32],"_dataListId":[32],"_descByIds":[32],"_value":[32],"_voiceOverFallback":[32]},null,{"_ref":["watch0"],"invalidMessage":["watch0"],"_id":["watch1"],"value":["watch2"]}],[4,"db-custom-select-dropdown",{"id":[1],"className":[1,"classname"],"width":[1]}],[4,"db-custom-select-list",{"multiple":[4],"label":[1],"id":[1],"className":[1,"classname"]}],[4,"db-custom-select-list-item",{"id":[1],"isGroupTitle":[4,"is-group-title"],"showDivider":[4,"show-divider"],"type":[1],"checked":[8],"className":[1,"classname"],"groupTitle":[1,"group-title"],"icon":[1],"showIcon":[8,"show-icon"],"name":[1],"disabled":[8],"value":[8],"label":[1],"_id":[32],"hasDivider":[32]},null,{"isGroupTitle":["watch0"],"showDivider":["watch0"]}],[4,"db-tag",{"disabled":[8],"removeButton":[1,"remove-button"],"id":[1],"className":[1,"classname"],"semantic":[1],"emphasis":[1],"icon":[1],"showCheckState":[8,"show-check-state"],"showIcon":[8,"show-icon"],"noText":[8,"no-text"],"overflow":[8],"text":[1],"behavior":[1],"initialized":[32]},null,{"initialized":["watch0"],"disabled":["watch0"],"_ref":["watch0"]}],[4,"db-tooltip",{"id":[1],"placement":[1],"className":[1,"classname"],"emphasis":[1],"animation":[8],"delay":[1],"width":[1],"showArrow":[8,"show-arrow"],"_id":[32],"initialized":[32],"_documentScrollListenerCallbackId":[32],"_observer":[32]},null,{"_ref":["watch0"],"initialized":["watch0"]}]]],["p-ab7f29be",[[4,"db-button",{"id":[1],"className":[1,"classname"],"type":[1],"disabled":[8],"label":[1],"icon":[1],"showIcon":[8,"show-icon"],"size":[1],"state":[1],"width":[1],"variant":[1],"noText":[8,"no-text"],"name":[1],"form":[1],"value":[1],"describedbyid":[1],"ariaexpanded":[4],"ariapressed":[4],"text":[1]}]]]]'),e)}));
2
2
  //# sourceMappingURL=db-ux.esm.js.map
@@ -1,2 +1,2 @@
1
- import"./p-bH2PZLSq.js";export{x as COLOR,y as COLORS,z as COLORS_SIMPLE,C as COLOR_CONST,w as COLOR_SIMPLE,n as DEFAULT_BACK,p as DEFAULT_BURGER_MENU,s as DEFAULT_CLOSE_BUTTON,j as DEFAULT_DATALIST_ID_SUFFIX,q as DEFAULT_ICON,D as DEFAULT_ID,l as DEFAULT_INVALID_MESSAGE,h as DEFAULT_INVALID_MESSAGE_ID_SUFFIX,a as DEFAULT_LABEL,d as DEFAULT_LABEL_ID_SUFFIX,c as DEFAULT_MESSAGE,f as DEFAULT_MESSAGE_ID_SUFFIX,b as DEFAULT_PLACEHOLDER,i as DEFAULT_PLACEHOLDER_ID_SUFFIX,m as DEFAULT_REMOVE,r as DEFAULT_ROWS,o as DEFAULT_SELECTED,e as DEFAULT_SELECT_ID_SUFFIX,k as DEFAULT_VALID_MESSAGE,g as DEFAULT_VALID_MESSAGE_ID_SUFFIX,B as DEFAULT_VIEWPORT,v as DENSITIES,u as DENSITY,t as DENSITY_CONST,E as DESKTOP_VIEWPORT,S as SEMANTIC,A as SEMANTICS,T as TESTING_VIEWPORTS}from"./p-DC9V_oNU.js";export{a as addAttributeToChildren,c as cls,f as delay,j as getBoolean,g as getBooleanAsString,m as getHideProp,l as getInputValue,k as getNumber,n as getSearchInput,h as handleDataOutside,e as hasVoiceOver,d as isArrayOfStrings,i as isInView,s as stringPropVisible,u as uuid,v as visibleInVX,b as visibleInVY}from"./p-pglUTSkG.js";export{N as NavigationItemSafeTriangle,i as isEventTargetNavigationItem}from"./p-6wgV8aKO.js";import"./p-DszXleuv.js";const _=["adaptive","neutral","critical","informational","warning","successful"];const L=["medium","small","large","none"];const I=["medium","small","large","none"];const F=["left","right","left-start","left-end","right-start","right-end"];const U=["top","bottom","top-start","top-end","bottom-start","bottom-end"];const O=[...F,...U];const V=["none","3x-large","2x-large","x-large","large","medium","small","x-small","2x-small","3x-small"];const R=["horizontal","vertical"];const M=["full","auto"];const P=["full","medium","large","small"];const G=["none","slow","fast"];const X=["auto","fixed"];const H=["small","medium"];const W=["weak","strong"];const K=["invalid","valid","no-validation"];const Y=["above","floating"];const Z=["off","on","name","honorific-prefix","given-name","additional-name","family-name","honorific-suffix","nickname","email","username","new-password","current-password","one-time-code","organization-title","organization","street-address","shipping","billing","address-line1","address-line2","address-line3","address-level4","address-level3","address-level2","address-level1","country","country-name","postal-code","cc-name","cc-given-name","cc-additional-name","cc-family-name","cc-number","cc-exp","cc-exp-month","cc-exp-year","cc-csc","cc-type","transaction-currency","transaction-amount","language","bday","bday-day","bday-month","bday-year","sex","tel","tel-country-code","tel-national","tel-area-code","tel-local","tel-extension","impp","url","photo","webauthn"];const J=["time","true","false","date","page","step","location"];const Q=["_self","_blank","_parent","_top"];const $=["no-referrer","no-referrer-when-downgrade","origin","origin-when-cross-origin","same-origin","strict-origin","strict-origin-when-cross-origin","unsafe-url"];const aa=["start","center"];export{aa as AlignmentList,Z as AutoCompleteList,W as EmphasisList,V as GapSpacingList,Y as LabelVariantList,J as LinkCurrentList,$ as LinkReferrerPolicyList,Q as LinkTargetList,I as MarginList,P as MaxWidthList,R as OrientationList,F as PlacementHorizontalList,O as PlacementList,U as PlacementVerticalList,G as PopoverDelayList,X as PopoverWidthList,_ as SemanticList,H as SizeList,L as SpacingList,K as ValidationList,M as WidthList};
1
+ import"./p-bH2PZLSq.js";export{x as COLOR,y as COLORS,z as COLORS_SIMPLE,C as COLOR_CONST,w as COLOR_SIMPLE,n as DEFAULT_BACK,p as DEFAULT_BURGER_MENU,s as DEFAULT_CLOSE_BUTTON,j as DEFAULT_DATALIST_ID_SUFFIX,q as DEFAULT_ICON,D as DEFAULT_ID,l as DEFAULT_INVALID_MESSAGE,h as DEFAULT_INVALID_MESSAGE_ID_SUFFIX,a as DEFAULT_LABEL,d as DEFAULT_LABEL_ID_SUFFIX,c as DEFAULT_MESSAGE,f as DEFAULT_MESSAGE_ID_SUFFIX,b as DEFAULT_PLACEHOLDER,i as DEFAULT_PLACEHOLDER_ID_SUFFIX,m as DEFAULT_REMOVE,r as DEFAULT_ROWS,o as DEFAULT_SELECTED,e as DEFAULT_SELECT_ID_SUFFIX,k as DEFAULT_VALID_MESSAGE,g as DEFAULT_VALID_MESSAGE_ID_SUFFIX,B as DEFAULT_VIEWPORT,v as DENSITIES,u as DENSITY,t as DENSITY_CONST,E as DESKTOP_VIEWPORT,S as SEMANTIC,A as SEMANTICS,T as TESTING_VIEWPORTS}from"./p-DC9V_oNU.js";export{a as addAttributeToChildren,c as cls,d as delay,b as getBoolean,g as getBooleanAsString,j as getHideProp,f as getInputValue,e as getNumber,k as getSearchInput,h as hasVoiceOver,i as isArrayOfStrings,s as stringPropVisible,u as uuid}from"./p-CQCQcuvr.js";export{N as NavigationItemSafeTriangle,i as isEventTargetNavigationItem}from"./p-BDA9dlfd.js";import"./p-C8WY_RwJ.js";import"./p-CqteyeC3.js";import"./p-DYeQU2bY.js";const _=["adaptive","neutral","critical","informational","warning","successful"];const L=["medium","small","large","none"];const I=["medium","small","large","none"];const F=["left","right","left-start","left-end","right-start","right-end"];const U=["top","bottom","top-start","top-end","bottom-start","bottom-end"];const O=[...F,...U];const R=["none","3x-large","2x-large","x-large","large","medium","small","x-small","2x-small","3x-small"];const M=["horizontal","vertical"];const V=["full","auto"];const P=["full","medium","large","small"];const G=["none","slow","fast"];const X=["auto","fixed"];const W=["small","medium"];const Y=["weak","strong"];const H=["invalid","valid","no-validation"];const Q=["above","floating"];const K=["off","on","name","honorific-prefix","given-name","additional-name","family-name","honorific-suffix","nickname","email","username","new-password","current-password","one-time-code","organization-title","organization","street-address","shipping","billing","address-line1","address-line2","address-line3","address-level4","address-level3","address-level2","address-level1","country","country-name","postal-code","cc-name","cc-given-name","cc-additional-name","cc-family-name","cc-number","cc-exp","cc-exp-month","cc-exp-year","cc-csc","cc-type","transaction-currency","transaction-amount","language","bday","bday-day","bday-month","bday-year","sex","tel","tel-country-code","tel-national","tel-area-code","tel-local","tel-extension","impp","url","photo","webauthn"];const J=["time","true","false","date","page","step","location"];const Z=["_self","_blank","_parent","_top"];const $=["no-referrer","no-referrer-when-downgrade","origin","origin-when-cross-origin","same-origin","strict-origin","strict-origin-when-cross-origin","unsafe-url"];const aa=["start","center"];export{aa as AlignmentList,K as AutoCompleteList,Y as EmphasisList,R as GapSpacingList,Q as LabelVariantList,J as LinkCurrentList,$ as LinkReferrerPolicyList,Z as LinkTargetList,I as MarginList,P as MaxWidthList,M as OrientationList,F as PlacementHorizontalList,O as PlacementList,U as PlacementVerticalList,G as PopoverDelayList,X as PopoverWidthList,_ as SemanticList,W as SizeList,L as SpacingList,H as ValidationList,V as WidthList};
2
2
  //# sourceMappingURL=index.esm.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.esm.js","sources":["src/shared/model.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-explicit-any */\n\nimport { IconTypes } from '@db-ux/core-foundations';\nexport type GlobalProps = {\n /**\n * default slot\n */\n\n children?: any;\n\n /**\n * React specific for adding className to the component.\n */\n className?: string;\n\n /**\n * Workaround for TypeScript using class for all components.\n */\n class?: string | any;\n\n /**\n * [`aria-describedby`](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-describedby) is used to link to the elements that describe the element with the set attribute.\n */\n describedbyid?: string;\n\n /**\n * [ID](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/id) of the component, generated automatically for some components as a fallback if unset.\n */\n id?: string;\n\n /**\n * Before using please check for the [accessibility concerns](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/autofocus#accessibility_concerns)\n */\n autofocus?: boolean | string;\n};\nexport type GlobalState = {\n _id?: string;\n};\nexport const SemanticList = ['adaptive', 'neutral', 'critical', 'informational', 'warning', 'successful'] as const;\nexport type SemanticType = (typeof SemanticList)[number];\nexport type SemanticProps = {\n /**\n * The semantic defines the default variants for most components.\n */\n semantic?: SemanticType;\n};\nexport type IconProps = {\n /**\n * Define an icon by its identifier (like e.g. _user_, compare to [Icons](https://design-system.deutschebahn.com/core-web/review/main/foundations/icons/overview)) to get displayed in front of the elements content.\n */\n icon?: IconTypes;\n};\nexport type ShowIconProps = {\n /**\n * Enables or disables the visibility of the icon. The default value depends on the component.\n * For many components this property is optional to reflect Figma properties.\n */\n showIcon?: boolean | string;\n};\nexport type IconAfterProps = {\n /**\n * Define an icon by its identifier (like e.g. _user_, compare to [Icons](https://design-system.deutschebahn.com/core-web/review/main/foundations/icons/overview)) to get displayed in front of the elements content.\n */\n iconAfter?: IconTypes;\n};\nexport const SpacingList = ['medium', 'small', 'large', 'none'] as const;\nexport type SpacingType = (typeof SpacingList)[number];\nexport type SpacingProps = {\n /**\n * The spacing attribute changes the padding of the component.\n */\n spacing?: SpacingType | string;\n};\nexport const MarginList = ['medium', 'small', 'large', 'none'] as const;\nexport type MarginType = (typeof MarginList)[number];\nexport type MarginProps = {\n /**\n * The margin attribute changes the margin of the component.\n */\n margin?: MarginType;\n};\nexport const PlacementHorizontalList = ['left', 'right', 'left-start', 'left-end', 'right-start', 'right-end'] as const;\nexport type PlacementHorizontalType = (typeof PlacementHorizontalList)[number];\nexport const PlacementVerticalList = ['top', 'bottom', 'top-start', 'top-end', 'bottom-start', 'bottom-end'] as const;\nexport type PlacementVerticalType = (typeof PlacementVerticalList)[number];\nexport const PlacementList = [...PlacementHorizontalList, ...PlacementVerticalList] as const;\nexport type PlacementType = (typeof PlacementList)[number];\nexport type PlacementProps = {\n /**\n * The `placement` attributes values change the position to absolute and adds a transform based on the placement.\n */\n placement?: PlacementType;\n};\nexport type NavigationBehaviorState = {\n handleNavigationItemClick: (event: unknown) => void;\n};\nexport type GapProps = {\n /**\n * If the absolute element should have a gap between the parent element.\n */\n gap?: boolean | string;\n};\nexport const GapSpacingList = ['none', '3x-large', '2x-large', 'x-large', 'large', 'medium', 'small', 'x-small', '2x-small', '3x-small'] as const;\nexport type GapSpacingType = (typeof GapSpacingList)[number];\nexport type GapSpacingProps = {\n /**\n * Set the gap/spacing between elements\n */\n gap?: GapSpacingType;\n};\nexport type OverflowProps = {\n /**\n * The overflow attribute sets a max-width and longer text will be dotted.\n */\n overflow?: boolean | string;\n};\nexport const OrientationList = ['horizontal', 'vertical'] as const;\nexport type OrientationType = (typeof OrientationList)[number];\nexport type OrientationProps = {\n /**\n * Change the orientation. Defaults to horizontal.\n */\n orientation?: OrientationType;\n};\nexport const WidthList = ['full', 'auto'] as const;\nexport type WidthType = (typeof WidthList)[number];\nexport type WidthProps = {\n /**\n * Width of the component. Auto width based on children size, full width based on parent elements width.\n */\n width?: WidthType | string;\n};\nexport const MaxWidthList = ['full', 'medium', 'large', 'small'] as const;\nexport type MaxWidthType = (typeof MaxWidthList)[number];\nexport type ContainerWidthProps = {\n /**\n * Set max width for the component\n */\n width?: MaxWidthType;\n};\nexport const PopoverDelayList = ['none', 'slow', 'fast'] as const;\nexport type PopoverDelayType = (typeof PopoverDelayList)[number];\nexport const PopoverWidthList = ['auto', 'fixed'] as const;\nexport type PopoverWidthType = (typeof PopoverWidthList)[number];\nexport type PopoverProps = {\n /**\n * Add a delay before showing the tooltip\n */\n delay?: PopoverDelayType;\n /**\n * Disable animation\n */\n animation?: boolean | string;\n /**\n * Use fixed with for default max-width\n */\n width?: PopoverWidthType;\n};\nexport type PopoverState = {\n handleAutoPlacement: () => void;\n};\nexport type NameProps = {\n /**\n * The name attribute gives the name of the element to group it.\n */\n name?: string;\n};\nexport type NameState = {\n _name?: string;\n handleNameAttribute: () => void;\n};\nexport type ContentSlotProps = {\n /**\n * Default slot which is used to pass in additional content.\n */\n content?: any;\n};\nexport const SizeList = ['small', 'medium'] as const;\nexport type SizeType = (typeof SizeList)[number];\nexport type SizeProps = {\n /**\n * The size attribute changes the font-size and other related sizes of the component.\n */\n size?: SizeType;\n};\nexport const EmphasisList = ['weak', 'strong'] as const;\nexport type EmphasisType = (typeof EmphasisList)[number];\nexport type EmphasisProps = {\n /**\n * The emphasis attribute divides in between a weak or strong importance.\n */\n emphasis?: EmphasisType;\n};\nexport const ValidationList = ['invalid', 'valid', 'no-validation'] as const;\nexport type ValidationType = (typeof ValidationList)[number];\nexport type RequiredProps = {\n /**\n * When the required attribute specified, the user will be required to fill the form element before submitting the form.\n */\n required?: boolean | string;\n};\nexport type ShowLabelProps = {\n /**\n * Enables/disables the visibility of the label\n */\n showLabel?: boolean | string;\n};\nexport type ValueProps = {\n /**\n * The value property is to receive results from the native form element.\n */\n value?: any;\n};\nexport type BaseFormProps = {\n /**\n * The disabled attribute can be set to keep a user from clicking on the form element.\n */\n disabled?: boolean | string;\n /**\n * The label attribute specifies the caption of the form element.\n */\n label?: string;\n\n /**\n * The name attribute gives the name of the form control, as used in form submission and in the form element's elements object.\n */\n name?: string;\n};\nexport type CustomFormProps = {\n /**\n * Overwrites auto handling for aria-describedby.\n */\n ariaDescribedBy?: string;\n /**\n * \tAssociates the control with a form element\n */\n form?: string;\n\n /**\n * Marks an input element as invalid (red) / valid (green) / no-validation (grey). Overwrites the :user-valid selector.\n */\n validation?: ValidationType;\n};\nexport type FormProps = CustomFormProps & BaseFormProps & RequiredProps & ShowLabelProps & ValueProps;\nexport type FormTextProps = {\n /**\n * Maximum length (number of characters) of value\n */\n maxLength?: number | string;\n /**\n * Minimum length (number of characters) of value\n */\n minLength?: number | string;\n /**\n * Maximum length (number of characters) of value\n */\n maxlength?: number | string;\n /**\n * Minimum length (number of characters) of value\n */\n minlength?: number | string;\n /**\n * The disabled attribute can be set to keep a user from edit on the form element\n */\n readOnly?: boolean | string;\n /**\n * The disabled attribute can be set to keep a user from edit on the form element\n */\n readonly?: boolean | string;\n};\nexport type FormSizeProps = {\n /**\n * Size of the control\n */\n size?: number;\n};\nexport type FormCheckProps = {\n /**\n * Define the radio or checkbox elements checked state\n */\n checked?: boolean | string;\n};\nexport const LabelVariantList = ['above', 'floating'] as const;\nexport type LabelVariantType = (typeof LabelVariantList)[number];\nexport const AutoCompleteList = ['off', 'on', 'name', 'honorific-prefix', 'given-name', 'additional-name', 'family-name', 'honorific-suffix', 'nickname', 'email', 'username', 'new-password', 'current-password', 'one-time-code', 'organization-title', 'organization', 'street-address', 'shipping', 'billing', 'address-line1', 'address-line2', 'address-line3', 'address-level4', 'address-level3', 'address-level2', 'address-level1', 'country', 'country-name', 'postal-code', 'cc-name', 'cc-given-name', 'cc-additional-name', 'cc-family-name', 'cc-number', 'cc-exp', 'cc-exp-month', 'cc-exp-year', 'cc-csc', 'cc-type', 'transaction-currency', 'transaction-amount', 'language', 'bday', 'bday-day', 'bday-month', 'bday-year', 'sex', 'tel', 'tel-country-code', 'tel-national', 'tel-area-code', 'tel-local', 'tel-extension', 'impp', 'url', 'photo', 'webauthn'] as const;\nexport type AutoCompleteType = (typeof AutoCompleteList)[number];\nexport type FormMessageProps = {\n /**\n * Change the variant of the label to float or hidden\n */\n variant?: LabelVariantType;\n /**\n * Text that appears in the form control when it has no value set\n */\n placeholder?: string;\n /**\n * Optional helper message for form components\n */\n message?: string;\n\n /**\n * Helper message for valid form components\n */\n validMessage?: string;\n\n /**\n * Helper message for invalid form components\n */\n invalidMessage?: string;\n\n /**\n * Set/overwrite icon for helper message for form components\n */\n messageIcon?: IconTypes;\n\n /**\n * See https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete\n */\n autocomplete?: string | AutoCompleteType;\n\n /**\n * Enables or disables the visibility of the message.\n */\n showMessage?: boolean | string;\n};\nexport type FromValidState = {\n hasValidState: () => boolean;\n handleValidation: () => void;\n _invalidMessage?: string;\n};\nexport type FormState = {\n _messageId?: string;\n _validMessageId?: string;\n _invalidMessageId?: string;\n _descByIds?: string;\n _value?: string;\n _invalidMessage?: string;\n /**\n * https://www.davidmacd.com/blog/test-aria-describedby-errormessage-aria-live.html\n * Currently VoiceOver isn't supporting changes from aria-describedby.\n * This is an internal Fallback\n */\n _voiceOverFallback?: string;\n};\nexport type InitializedState = {\n initialized: boolean;\n};\nexport const LinkCurrentList = ['time', 'true', 'false', 'date', 'page', 'step', 'location'] as const;\nexport type LinkCurrentType = (typeof LinkCurrentList)[number];\nexport const LinkTargetList = ['_self', '_blank', '_parent', '_top'] as const;\nexport type LinkTargetType = (typeof LinkTargetList)[number];\nexport const LinkReferrerPolicyList = ['no-referrer', 'no-referrer-when-downgrade', 'origin', 'origin-when-cross-origin', 'same-origin', 'strict-origin', 'strict-origin-when-cross-origin', 'unsafe-url'] as const;\nexport type LinkReferrerPolicyType = (typeof LinkReferrerPolicyList)[number];\nexport type LinkProps = {\n /**\n * Sets aria attribute based on [`aria-current`](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-current).\n */\n current?: boolean | LinkCurrentType;\n /**\n * Disables the link.\n */\n disabled?: boolean | string;\n /**\n * The [URL that the hyperlink points to](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#href).\n */\n href?: string;\n /**\n * Hints for the human [language of the linked page or document](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#hreflang).\n */\n hreflang?: string;\n /**\n * Sets aria attribute based on [`aria-label`](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-label).\n */\n label?: string;\n /**\n * Where to open the linked URL, as the name for a [browsing context](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target).\n */\n target?: LinkTargetType;\n /**\n * The relationship of the linked URL as space-separated link types.\n */\n rel?: string;\n /**\n * Sets aria role based on [`aria-role`](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles).\n */\n role?: string;\n /**\n * How much of the referrer to send when following the link.\n */\n referrerpolicy?: LinkReferrerPolicyType;\n /**\n * Sets aria role based on [`aria-selected`](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-selected).\n */\n selected?: boolean | string;\n};\nexport type TextProps = {\n /**\n * Alternative for default slot/children.\n */\n text?: string;\n};\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport type ClickEvent<T> = MouseEvent;\nexport type ClickEventProps<T> = {\n /**\n * React specific onClick to pass to forward ref.\n */\n onClick?: (event: ClickEvent<T>) => void;\n};\nexport type ClickEventState<T> = {\n handleClick: (event: ClickEvent<T> | any) => void;\n};\nexport type ToggleEventProps = {\n toggle?: (open: boolean | any) => void;\n onToggle?: (open: boolean | any) => void;\n};\nexport type ToggleEventState<T> = {\n handleToggle: (event?: ClickEvent<T> | any) => void;\n};\nexport type CloseEventProps = {\n /**\n * Function to handle button click (close).\n */\n onClose?: (event?: any) => void;\n /**\n * Function to handle button click (close).\n */\n close?: (event?: any) => void;\n};\nexport type CloseEventState = {\n handleClose: (event: any) => void;\n};\nexport const AlignmentList = ['start', 'center'] as const;\nexport type AlignmentType = (typeof AlignmentList)[number];\nexport type AlignmentProps = {\n /**\n * Define the content alignment in full width\n */\n alignment?: AlignmentType | string;\n};\nexport type ActiveProps = {\n /**\n * If the tab is checked/active.\n */\n active?: boolean | string;\n};\nexport type InputEvent<T> = Event;\nexport type InputEventProps<T> = {\n input?: (event: InputEvent<T>) => void;\n onInput?: (event: InputEvent<T>) => void;\n};\nexport type InputEventState<T> = {\n handleInput: (event: InputEvent<T> | any) => void;\n};\nexport type ChangeEvent<T> = Event;\nexport type ChangeEventProps<T> = {\n change?: (event: ChangeEvent<T>) => void;\n onChange?: (event: ChangeEvent<T>) => void;\n};\nexport type ChangeEventState<T> = {\n handleChange: (event: ChangeEvent<T> | any) => void;\n};\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport type InteractionEvent<T> = FocusEvent;\nexport type FocusEventProps<T> = {\n blur?: (event: InteractionEvent<T>) => void;\n onBlur?: (event: InteractionEvent<T>) => void;\n focus?: (event: InteractionEvent<T>) => void;\n onFocus?: (event: InteractionEvent<T>) => void;\n};\nexport type FocusEventState<T> = {\n handleBlur: (event: InteractionEvent<T> | any) => void;\n handleFocus: (event: InteractionEvent<T> | any) => void;\n};\nexport type InnerCloseButtonProps = {\n /**\n * The closeButtonId attribute changes the id inside the close button.\n */\n closeButtonId?: string;\n /**\n * The closeButtonText attribute changes the text inside the close button.\n */\n closeButtonText?: string;\n};\nexport type NavigationBackButtonProps = {\n /**\n * The backButtonId attribute changes the id inside the back button.\n */\n backButtonId?: string;\n /**\n * The backButtonText attribute changes the text inside the back button.\n */\n backButtonText?: string;\n};\nexport type AriaLabelledByProps = {\n /**\n * Pass aria-labelledby to inner element\n */\n labelledBy?: string;\n};\nexport type AriaControlsProps = {\n /**\n * Pass aria-controls to inner element\n */\n controls?: string;\n};\nexport type ValueLabelType = {\n value: string;\n label?: string;\n}"],"names":[],"mappings":";;;;;;AAAA;AAsCa,MAAA,YAAY,GAAG,CAAC,UAAU,EAAE,SAAS,EAAE,UAAU,EAAE,eAAe,EAAE,SAAS,EAAE,YAAY;AA2BjG,MAAM,WAAW,GAAG,CAAC,QAAQ,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM;AAQvD,MAAM,UAAU,GAAG,CAAC,QAAQ,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM;AAQhD,MAAA,uBAAuB,GAAG,CAAC,MAAM,EAAE,OAAO,EAAE,YAAY,EAAE,UAAU,EAAE,aAAa,EAAE,WAAW;AAEhG,MAAA,qBAAqB,GAAG,CAAC,KAAK,EAAE,QAAQ,EAAE,WAAW,EAAE,SAAS,EAAE,cAAc,EAAE,YAAY;AAE9F,MAAA,aAAa,GAAG,CAAC,GAAG,uBAAuB,EAAE,GAAG,qBAAqB;AAiBrE,MAAA,cAAc,GAAG,CAAC,MAAM,EAAE,UAAU,EAAE,UAAU,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,UAAU;MAc1H,eAAe,GAAG,CAAC,YAAY,EAAE,UAAU;MAQ3C,SAAS,GAAG,CAAC,MAAM,EAAE,MAAM;AAQjC,MAAM,YAAY,GAAG,CAAC,MAAM,EAAE,QAAQ,EAAE,OAAO,EAAE,OAAO;AAQlD,MAAA,gBAAgB,GAAG,CAAC,MAA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G,CAAC,aAAa,EAAE,4BAA4B,EAAE,QAAQ,EAAE,0BAA0B,EAAE,aAAa,EAAE,eAAe,EAAE,iCAAiC,EAAE,YAAY;MAkF5L,aAAa,GAAG,CAAC,OAAO,EAAE,QAAQ;;;;"}
1
+ {"version":3,"file":"index.esm.js","sources":["src/shared/model.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-explicit-any */\n\nimport { IconTypes } from '@db-ux/core-foundations';\nexport type GlobalProps = {\n /**\n * default slot\n */\n\n children?: any;\n\n /**\n * React specific for adding className to the component.\n */\n className?: string;\n\n /**\n * Workaround for TypeScript using class for all components.\n */\n class?: string | any;\n\n /**\n * @deprecated\n * [`aria-describedby`](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-describedby) is used to link to the elements that describe the element with the set attribute.\n */\n describedbyid?: string;\n\n /**\n * [ID](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/id) of the component, generated automatically for some components as a fallback if unset.\n */\n id?: string;\n\n /**\n * Before using please check for the [accessibility concerns](https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/autofocus#accessibility_concerns)\n */\n autofocus?: boolean | string;\n};\nexport type GlobalState = {\n _id?: string;\n};\nexport const SemanticList = ['adaptive', 'neutral', 'critical', 'informational', 'warning', 'successful'] as const;\nexport type SemanticType = (typeof SemanticList)[number];\nexport type SemanticProps = {\n /**\n * The semantic defines the default variants for most components.\n */\n semantic?: SemanticType;\n};\nexport type IconProps = {\n /**\n * Define an icon by its identifier (like e.g. _user_, compare to [Icons](https://design-system.deutschebahn.com/core-web/review/main/foundations/icons/overview)) to get displayed in front of the elements content.\n */\n icon?: IconTypes;\n};\nexport type ShowIconProps = {\n /**\n * Enables or disables the visibility of the icon. The default value depends on the component.\n * For many components this property is optional to reflect Figma properties.\n */\n showIcon?: boolean | string;\n};\nexport type IconAfterProps = {\n /**\n * Define an icon by its identifier (like e.g. _user_, compare to [Icons](https://design-system.deutschebahn.com/core-web/review/main/foundations/icons/overview)) to get displayed in front of the elements content.\n */\n iconAfter?: IconTypes;\n};\nexport const SpacingList = ['medium', 'small', 'large', 'none'] as const;\nexport type SpacingType = (typeof SpacingList)[number];\nexport type SpacingProps = {\n /**\n * The spacing attribute changes the padding of the component.\n */\n spacing?: SpacingType | string;\n};\nexport const MarginList = ['medium', 'small', 'large', 'none'] as const;\nexport type MarginType = (typeof MarginList)[number];\nexport type MarginProps = {\n /**\n * The margin attribute changes the margin of the component.\n */\n margin?: MarginType;\n};\nexport const PlacementHorizontalList = ['left', 'right', 'left-start', 'left-end', 'right-start', 'right-end'] as const;\nexport type PlacementHorizontalType = (typeof PlacementHorizontalList)[number];\nexport const PlacementVerticalList = ['top', 'bottom', 'top-start', 'top-end', 'bottom-start', 'bottom-end'] as const;\nexport type PlacementVerticalType = (typeof PlacementVerticalList)[number];\nexport const PlacementList = [...PlacementHorizontalList, ...PlacementVerticalList] as const;\nexport type PlacementType = (typeof PlacementList)[number];\nexport type PlacementProps = {\n /**\n * The `placement` attributes values change the position to absolute and adds a transform based on the placement.\n */\n placement?: PlacementType;\n};\nexport type NavigationBehaviorState = {\n handleNavigationItemClick: (event: unknown) => void;\n};\nexport type GapProps = {\n /**\n * If the absolute element should have a gap between the parent element.\n */\n gap?: boolean | string;\n};\nexport const GapSpacingList = ['none', '3x-large', '2x-large', 'x-large', 'large', 'medium', 'small', 'x-small', '2x-small', '3x-small'] as const;\nexport type GapSpacingType = (typeof GapSpacingList)[number];\nexport type GapSpacingProps = {\n /**\n * Set the gap/spacing between elements\n */\n gap?: GapSpacingType;\n};\nexport type OverflowProps = {\n /**\n * The overflow attribute sets a max-width and longer text will be dotted.\n */\n overflow?: boolean | string;\n};\nexport const OrientationList = ['horizontal', 'vertical'] as const;\nexport type OrientationType = (typeof OrientationList)[number];\nexport type OrientationProps = {\n /**\n * Change the orientation. Defaults to horizontal.\n */\n orientation?: OrientationType;\n};\nexport const WidthList = ['full', 'auto'] as const;\nexport type WidthType = (typeof WidthList)[number];\nexport type WidthProps = {\n /**\n * Width of the component. Auto width based on children size, full width based on parent elements width.\n */\n width?: WidthType | string;\n};\nexport const MaxWidthList = ['full', 'medium', 'large', 'small'] as const;\nexport type MaxWidthType = (typeof MaxWidthList)[number];\nexport type ContainerWidthProps = {\n /**\n * Set max width for the component\n */\n width?: MaxWidthType;\n};\nexport const PopoverDelayList = ['none', 'slow', 'fast'] as const;\nexport type PopoverDelayType = (typeof PopoverDelayList)[number];\nexport const PopoverWidthList = ['auto', 'fixed'] as const;\nexport type PopoverWidthType = (typeof PopoverWidthList)[number];\nexport type PopoverProps = {\n /**\n * Add a delay before showing the tooltip\n */\n delay?: PopoverDelayType;\n /**\n * Disable animation\n */\n animation?: boolean | string;\n /**\n * Use fixed with for default max-width\n */\n width?: PopoverWidthType;\n};\nexport type NameProps = {\n /**\n * The name attribute gives the name of the element to group it.\n */\n name?: string;\n};\nexport type NameState = {\n _name?: string;\n handleNameAttribute: () => void;\n};\nexport type ContentSlotProps = {\n /**\n * Default slot which is used to pass in additional content.\n */\n content?: any;\n};\nexport const SizeList = ['small', 'medium'] as const;\nexport type SizeType = (typeof SizeList)[number];\nexport type SizeProps = {\n /**\n * The size attribute changes the font-size and other related sizes of the component.\n */\n size?: SizeType;\n};\nexport const EmphasisList = ['weak', 'strong'] as const;\nexport type EmphasisType = (typeof EmphasisList)[number];\nexport type EmphasisProps = {\n /**\n * The emphasis attribute divides in between a weak or strong importance.\n */\n emphasis?: EmphasisType;\n};\nexport const ValidationList = ['invalid', 'valid', 'no-validation'] as const;\nexport type ValidationType = (typeof ValidationList)[number];\nexport type RequiredProps = {\n /**\n * When the required attribute specified, the user will be required to fill the form element before submitting the form.\n */\n required?: boolean | string;\n};\nexport type ShowLabelProps = {\n /**\n * Enables/disables the visibility of the label\n */\n showLabel?: boolean | string;\n};\nexport type ValueProps = {\n /**\n * The value property is to receive results from the native form element.\n */\n value?: any;\n};\nexport type BaseFormProps = {\n /**\n * The disabled attribute can be set to keep a user from clicking on the form element.\n */\n disabled?: boolean | string;\n /**\n * The label attribute specifies the caption of the form element.\n */\n label?: string;\n\n /**\n * The name attribute gives the name of the form control, as used in form submission and in the form element's elements object.\n */\n name?: string;\n};\nexport type CustomFormProps = {\n /**\n * Overwrites auto handling for aria-describedby.\n */\n ariaDescribedBy?: string;\n /**\n * \tAssociates the control with a form element\n */\n form?: string;\n\n /**\n * Marks an input element as invalid (red) / valid (green) / no-validation (grey). Overwrites the :user-valid selector.\n */\n validation?: ValidationType;\n};\nexport type FormProps = CustomFormProps & BaseFormProps & RequiredProps & ShowLabelProps & ValueProps;\nexport type FormTextProps = {\n /**\n * Maximum length (number of characters) of value\n */\n maxLength?: number | string;\n /**\n * Minimum length (number of characters) of value\n */\n minLength?: number | string;\n /**\n * Maximum length (number of characters) of value\n */\n maxlength?: number | string;\n /**\n * Minimum length (number of characters) of value\n */\n minlength?: number | string;\n /**\n * The disabled attribute can be set to keep a user from edit on the form element\n */\n readOnly?: boolean | string;\n /**\n * The disabled attribute can be set to keep a user from edit on the form element\n */\n readonly?: boolean | string;\n};\nexport type FormSizeProps = {\n /**\n * Size of the control\n */\n size?: number;\n};\nexport type FormCheckProps = {\n /**\n * Define the radio or checkbox elements checked state\n */\n checked?: boolean | string;\n};\nexport const LabelVariantList = ['above', 'floating'] as const;\nexport type LabelVariantType = (typeof LabelVariantList)[number];\nexport const AutoCompleteList = ['off', 'on', 'name', 'honorific-prefix', 'given-name', 'additional-name', 'family-name', 'honorific-suffix', 'nickname', 'email', 'username', 'new-password', 'current-password', 'one-time-code', 'organization-title', 'organization', 'street-address', 'shipping', 'billing', 'address-line1', 'address-line2', 'address-line3', 'address-level4', 'address-level3', 'address-level2', 'address-level1', 'country', 'country-name', 'postal-code', 'cc-name', 'cc-given-name', 'cc-additional-name', 'cc-family-name', 'cc-number', 'cc-exp', 'cc-exp-month', 'cc-exp-year', 'cc-csc', 'cc-type', 'transaction-currency', 'transaction-amount', 'language', 'bday', 'bday-day', 'bday-month', 'bday-year', 'sex', 'tel', 'tel-country-code', 'tel-national', 'tel-area-code', 'tel-local', 'tel-extension', 'impp', 'url', 'photo', 'webauthn'] as const;\nexport type AutoCompleteType = (typeof AutoCompleteList)[number];\nexport type FormMessageProps = {\n /**\n * Change the variant of the label to float or hidden\n */\n variant?: LabelVariantType;\n /**\n * Text that appears in the form control when it has no value set\n */\n placeholder?: string;\n /**\n * Optional helper message for form components\n */\n message?: string;\n\n /**\n * Helper message for valid form components\n */\n validMessage?: string;\n\n /**\n * Helper message for invalid form components\n */\n invalidMessage?: string;\n\n /**\n * Set/overwrite icon for helper message for form components\n */\n messageIcon?: IconTypes;\n\n /**\n * See https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/autocomplete\n */\n autocomplete?: string | AutoCompleteType;\n\n /**\n * Enables or disables the visibility of the message.\n */\n showMessage?: boolean | string;\n};\nexport type FromValidState = {\n hasValidState: () => boolean;\n handleValidation: () => void;\n _invalidMessage?: string;\n};\nexport type FormState = {\n _messageId?: string;\n _validMessageId?: string;\n _invalidMessageId?: string;\n _descByIds?: string;\n _value?: string;\n _invalidMessage?: string;\n /**\n * https://www.davidmacd.com/blog/test-aria-describedby-errormessage-aria-live.html\n * Currently VoiceOver isn't supporting changes from aria-describedby.\n * This is an internal Fallback\n */\n _voiceOverFallback?: string;\n};\nexport type InitializedState = {\n initialized: boolean;\n};\nexport const LinkCurrentList = ['time', 'true', 'false', 'date', 'page', 'step', 'location'] as const;\nexport type LinkCurrentType = (typeof LinkCurrentList)[number];\nexport const LinkTargetList = ['_self', '_blank', '_parent', '_top'] as const;\nexport type LinkTargetType = (typeof LinkTargetList)[number];\nexport const LinkReferrerPolicyList = ['no-referrer', 'no-referrer-when-downgrade', 'origin', 'origin-when-cross-origin', 'same-origin', 'strict-origin', 'strict-origin-when-cross-origin', 'unsafe-url'] as const;\nexport type LinkReferrerPolicyType = (typeof LinkReferrerPolicyList)[number];\nexport type LinkProps = {\n /**\n * Sets aria attribute based on [`aria-current`](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-current).\n */\n current?: boolean | LinkCurrentType;\n /**\n * Disables the link.\n */\n disabled?: boolean | string;\n /**\n * The [URL that the hyperlink points to](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#href).\n */\n href?: string;\n /**\n * Hints for the human [language of the linked page or document](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#hreflang).\n */\n hreflang?: string;\n /**\n * Sets aria attribute based on [`aria-label`](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-label).\n */\n label?: string;\n /**\n * Where to open the linked URL, as the name for a [browsing context](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/a#target).\n */\n target?: LinkTargetType;\n /**\n * The relationship of the linked URL as space-separated link types.\n */\n rel?: string;\n /**\n * Sets aria role based on [`aria-role`](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Roles).\n */\n role?: string;\n /**\n * How much of the referrer to send when following the link.\n */\n referrerpolicy?: LinkReferrerPolicyType;\n /**\n * Sets aria role based on [`aria-selected`](https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Attributes/aria-selected).\n */\n selected?: boolean | string;\n};\nexport type TextProps = {\n /**\n * Alternative for default slot/children.\n */\n text?: string;\n};\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport type ClickEvent<T> = MouseEvent;\nexport type ClickEventProps<T> = {\n /**\n * React specific onClick to pass to forward ref.\n */\n onClick?: (event: ClickEvent<T>) => void;\n};\nexport type ClickEventState<T> = {\n handleClick: (event: ClickEvent<T> | any) => void;\n};\nexport type ToggleEventProps = {\n toggle?: (open: boolean | any) => void;\n onToggle?: (open: boolean | any) => void;\n};\nexport type ToggleEventState<T> = {\n handleToggle: (event?: ClickEvent<T> | any) => void;\n};\nexport type CloseEventProps = {\n /**\n * Function to handle button click (close).\n */\n onClose?: (event?: any) => void;\n /**\n * Function to handle button click (close).\n */\n close?: (event?: any) => void;\n};\nexport type CloseEventState = {\n handleClose: (event: any) => void;\n};\nexport const AlignmentList = ['start', 'center'] as const;\nexport type AlignmentType = (typeof AlignmentList)[number];\nexport type AlignmentProps = {\n /**\n * Define the content alignment in full width\n */\n alignment?: AlignmentType | string;\n};\nexport type ActiveProps = {\n /**\n * If the tab is checked/active.\n */\n active?: boolean | string;\n};\nexport type InputEvent<T> = Event;\nexport type InputEventProps<T> = {\n input?: (event: InputEvent<T>) => void;\n onInput?: (event: InputEvent<T>) => void;\n};\nexport type InputEventState<T> = {\n handleInput: (event: InputEvent<T> | any) => void;\n};\nexport type ChangeEvent<T> = Event;\nexport type ChangeEventProps<T> = {\n change?: (event: ChangeEvent<T>) => void;\n onChange?: (event: ChangeEvent<T>) => void;\n};\nexport type ChangeEventState<T> = {\n handleChange: (event: ChangeEvent<T> | any) => void;\n};\n\n// eslint-disable-next-line @typescript-eslint/no-unused-vars\nexport type InteractionEvent<T> = FocusEvent;\nexport type FocusEventProps<T> = {\n blur?: (event: InteractionEvent<T>) => void;\n onBlur?: (event: InteractionEvent<T>) => void;\n focus?: (event: InteractionEvent<T>) => void;\n onFocus?: (event: InteractionEvent<T>) => void;\n};\nexport type FocusEventState<T> = {\n handleBlur: (event: InteractionEvent<T> | any) => void;\n handleFocus: (event: InteractionEvent<T> | any) => void;\n};\nexport type InnerCloseButtonProps = {\n /**\n * The closeButtonId attribute changes the id inside the close button.\n */\n closeButtonId?: string;\n /**\n * The closeButtonText attribute changes the text inside the close button.\n */\n closeButtonText?: string;\n};\nexport type NavigationBackButtonProps = {\n /**\n * The backButtonId attribute changes the id inside the back button.\n */\n backButtonId?: string;\n /**\n * The backButtonText attribute changes the text inside the back button.\n */\n backButtonText?: string;\n};\nexport type AriaLabelledByProps = {\n /**\n * Pass aria-labelledby to inner element\n */\n labelledBy?: string;\n};\nexport type AriaControlsProps = {\n /**\n * Pass aria-controls to inner element\n */\n controls?: string;\n};\nexport type ValueLabelType = {\n value: string;\n label?: string;\n};\nexport type DocumentScrollState = {\n _documentScrollListenerCallbackId?: string;\n handleDocumentScroll: (event: any, parent?: HTMLElement) => void;\n _observer?: IntersectionObserver;\n};\nexport type PopoverState = {\n handleEscape: (event: any) => void;\n handleAutoPlacement: (parent?: HTMLElement) => void;\n handleEnter: (parent?: HTMLElement) => void;\n handleLeave: (event?: any) => void;\n} & DocumentScrollState"],"names":[],"mappings":";;;;;;;;AAAA;AAuCa,MAAA,YAAY,GAAG,CAAC,UAAU,EAAE,SAAS,EAAE,UAAU,EAAE,eAAe,EAAE,SAAS,EAAE,YAAY;AA2BjG,MAAM,WAAW,GAAG,CAAC,QAAQ,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM;AAQvD,MAAM,UAAU,GAAG,CAAC,QAAQ,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM;AAQhD,MAAA,uBAAuB,GAAG,CAAC,MAAM,EAAE,OAAO,EAAE,YAAY,EAAE,UAAU,EAAE,aAAa,EAAE,WAAW;AAEhG,MAAA,qBAAqB,GAAG,CAAC,KAAK,EAAE,QAAQ,EAAE,WAAW,EAAE,SAAS,EAAE,cAAc,EAAE,YAAY;AAE9F,MAAA,aAAa,GAAG,CAAC,GAAG,uBAAuB,EAAE,GAAG,qBAAqB;AAiBrE,MAAA,cAAc,GAAG,CAAC,MAAM,EAAE,UAAU,EAAE,UAAU,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,UAAU;MAc1H,eAAe,GAAG,CAAC,YAAY,EAAE,UAAU;MAQ3C,SAAS,GAAG,CAAC,MAAM,EAAE,MAAM;AAQjC,MAAM,YAAY,GAAG,CAAC,MAAM,EAAE,QAAQ,EAAE,OAAO,EAAE,OAAO;AAQlD,MAAA,gBAAgB,GAAG,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM;MAE1C,gBAAgB,GAAG,CAAC,MAAM,EAAE,OAAO;MAgCnC,QAAQ,GAAG,CAAC,OAAO,EAAE,QAAQ;MAQ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AAG,CAAC,OAAO,EAAE,QAAQ;;;;"}
@@ -1,2 +1,2 @@
1
- import{r as s,h as t}from"./p-bH2PZLSq.js";import{m as a,c as i}from"./p-pglUTSkG.js";import{q as o}from"./p-DC9V_oNU.js";const d=class{constructor(t){s(this,t)}enableAttributePassing(s,t){const a=s===null||s===void 0?void 0:s.closest(t);if(s&&a){const t=a.attributes;for(let i=0;i<t.length;i++){const o=t.item(i);if(o&&(o.name.startsWith("data-")||o.name.startsWith("aria-"))){s.setAttribute(o.name,o.value);a.removeAttribute(o.name)}if(o&&o.name==="class"){const t=o.value.includes("hydrated");const i=o.value.replace("hydrated","").trim();const d=s.getAttribute("class");s.setAttribute(o.name,`${d?`${d} `:""}${i}`);if(t){a.setAttribute("class","hydrated")}else{a.removeAttribute(o.name)}}}}}componentDidLoad(){this.enableAttributePassing(this._ref,"db-brand")}render(){var s;return t("div",{key:"fce3522d92cfce50d3a45e8240fa8fa5b9d71ec2",class:i("db-brand",this.className),ref:s=>{this._ref=s},"data-icon":this.hideLogo?"none":(s=this.icon)!==null&&s!==void 0?s:o,"data-hide-icon":a(this.showIcon),id:this.id},this.text?this.text:t("slot",null))}};export{d as db_brand};
2
- //# sourceMappingURL=p-8b7d868b.entry.js.map
1
+ import{r as s,h as t}from"./p-bH2PZLSq.js";import{j as a,c as i}from"./p-CQCQcuvr.js";import{q as o}from"./p-DC9V_oNU.js";const d=class{constructor(t){s(this,t)}enableAttributePassing(s,t){const a=s===null||s===void 0?void 0:s.closest(t);if(s&&a){const t=a.attributes;for(let i=0;i<t.length;i++){const o=t.item(i);if(o&&(o.name.startsWith("data-")||o.name.startsWith("aria-"))){s.setAttribute(o.name,o.value);a.removeAttribute(o.name)}if(o&&o.name==="class"){const t=o.value.includes("hydrated");const i=o.value.replace("hydrated","").trim();const d=s.getAttribute("class");s.setAttribute(o.name,`${d?`${d} `:""}${i}`);if(t){a.setAttribute("class","hydrated")}else{a.removeAttribute(o.name)}}}}}componentDidLoad(){this.enableAttributePassing(this._ref,"db-brand")}render(){var s;return t("div",{key:"fce3522d92cfce50d3a45e8240fa8fa5b9d71ec2",class:i("db-brand",this.className),ref:s=>{this._ref=s},"data-icon":this.hideLogo?"none":(s=this.icon)!==null&&s!==void 0?s:o,"data-hide-icon":a(this.showIcon),id:this.id},this.text?this.text:t("slot",null))}};export{d as db_brand};
2
+ //# sourceMappingURL=p-00ae6c1c.entry.js.map
@@ -1,2 +1,2 @@
1
- import{r as i,c as t,h as s}from"./p-bH2PZLSq.js";import{u as a,j as h,m as e,c as d}from"./p-pglUTSkG.js";const r=class{constructor(s){i(this,s);this.change=t(this,"change");this.blur=t(this,"blur");this.focus=t(this,"focus");this.initialized=false;this._id=undefined}handleChange(i){i.stopPropagation();if(this.change){this.change.emit(i)}}handleBlur(i){i.stopPropagation();if(this.blur){this.blur.emit(i)}}handleFocus(i){i.stopPropagation();if(this.focus){this.focus.emit(i)}}enableAttributePassing(i,t){const s=i===null||i===void 0?void 0:i.closest(t);if(i&&s){const t=s.attributes;for(let a=0;a<t.length;a++){const h=t.item(a);if(h&&(h.name.startsWith("data-")||h.name.startsWith("aria-"))){i.setAttribute(h.name,h.value);s.removeAttribute(h.name)}if(h&&h.name==="class"){const t=h.value.includes("hydrated");const a=h.value.replace("hydrated","").trim();const e=i.getAttribute("class");i.setAttribute(h.name,`${e?`${e} `:""}${a}`);if(t){s.setAttribute("class","hydrated")}else{s.removeAttribute(h.name)}}}}}watch0Fn(){if(this.checked&&this.initialized&&this._ref){this._ref.checked=true}}watch0(){this.watch0Fn()}componentDidLoad(){var i;this.enableAttributePassing(this._ref,"db-radio");this.initialized=true;this._id=(i=this.id)!==null&&i!==void 0?i:`radio-${a()}`;this.watch0Fn()}render(){return s("label",{key:"54f6104923ffbb7d0443be431634ae8803f2f893",class:d("db-radio",this.className),"data-size":this.size,"data-hide-label":e(this.showLabel),htmlFor:this._id},s("input",{key:"4bd48549054a70f69330e91e69111adef353f75a",type:"radio","aria-invalid":this.validation==="invalid","data-custom-validity":this.validation,ref:i=>{this._ref=i},id:this._id,name:this.name,checked:h(this.checked,"checked"),disabled:h(this.disabled,"disabled"),"aria-describedby":this.describedbyid,value:this.value,required:h(this.required,"required"),onChange:i=>this.handleChange(i),onBlur:i=>this.handleBlur(i),onFocus:i=>this.handleFocus(i)}),this.label?this.label:s("slot",null))}static get watchers(){return{initialized:["watch0"],_ref:["watch0"],checked:["watch0"]}}};export{r as db_radio};
2
- //# sourceMappingURL=p-50c9112b.entry.js.map
1
+ import{r as i,c as t,h as s}from"./p-bH2PZLSq.js";import{u as a,b as h,j as e,c as d}from"./p-CQCQcuvr.js";const r=class{constructor(s){i(this,s);this.change=t(this,"change");this.blur=t(this,"blur");this.focus=t(this,"focus");this.initialized=false;this._id=undefined}handleChange(i){i.stopPropagation();if(this.change){this.change.emit(i)}}handleBlur(i){i.stopPropagation();if(this.blur){this.blur.emit(i)}}handleFocus(i){i.stopPropagation();if(this.focus){this.focus.emit(i)}}enableAttributePassing(i,t){const s=i===null||i===void 0?void 0:i.closest(t);if(i&&s){const t=s.attributes;for(let a=0;a<t.length;a++){const h=t.item(a);if(h&&(h.name.startsWith("data-")||h.name.startsWith("aria-"))){i.setAttribute(h.name,h.value);s.removeAttribute(h.name)}if(h&&h.name==="class"){const t=h.value.includes("hydrated");const a=h.value.replace("hydrated","").trim();const e=i.getAttribute("class");i.setAttribute(h.name,`${e?`${e} `:""}${a}`);if(t){s.setAttribute("class","hydrated")}else{s.removeAttribute(h.name)}}}}}watch0Fn(){if(this.checked&&this.initialized&&this._ref){this._ref.checked=true}}watch0(){this.watch0Fn()}componentDidLoad(){var i;this.enableAttributePassing(this._ref,"db-radio");this.initialized=true;this._id=(i=this.id)!==null&&i!==void 0?i:`radio-${a()}`;this.watch0Fn()}render(){var i;return s("label",{key:"f990c46f99b54491b2db9b56a214d69ac126fc33",class:d("db-radio",this.className),"data-size":this.size,"data-hide-label":e(this.showLabel),htmlFor:this._id},s("input",{key:"3f38c3e9fa2790144754a2626f3a5109d810bcda",type:"radio","aria-invalid":this.validation==="invalid","data-custom-validity":this.validation,ref:i=>{this._ref=i},id:this._id,name:this.name,checked:h(this.checked,"checked"),disabled:h(this.disabled,"disabled"),"aria-describedby":(i=this.describedbyid)!==null&&i!==void 0?i:this.ariaDescribedBy,value:this.value,required:h(this.required,"required"),onChange:i=>this.handleChange(i),onBlur:i=>this.handleBlur(i),onFocus:i=>this.handleFocus(i)}),this.label?this.label:s("slot",null))}static get watchers(){return{initialized:["watch0"],_ref:["watch0"],checked:["watch0"]}}};export{r as db_radio};
2
+ //# sourceMappingURL=p-0bf63ec2.entry.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["DBRadio","constructor","hostRef","this","initialized","_id","undefined","handleChange","event","stopPropagation","change","emit","handleBlur","blur","handleFocus","focus","enableAttributePassing","element","customElementSelector","parent","closest","attributes","i","length","attr","item","name","startsWith","setAttribute","value","removeAttribute","isWebComponent","includes","replace","trim","currentClass","getAttribute","watch0Fn","checked","_ref","watch0","componentDidLoad","_a","id","uuid","render","h","key","class","cls","className","size","getHideProp","showLabel","htmlFor","type","validation","ref","el","getBoolean","disabled","describedbyid","ariaDescribedBy","required","onChange","onBlur","onFocus","label"],"sources":["src/components/radio/radio.tsx"],"sourcesContent":["import { DBRadioProps, DBRadioState } from \"./model\";\nimport { cls, getBoolean, getHideProp, uuid } from \"../../utils\";\nimport { ChangeEvent, InteractionEvent } from \"../../shared/model\";\nimport {\n handleFrameworkEventAngular,\n handleFrameworkEventVue,\n} from \"../../utils/form-components\";\n\nimport {\n Component,\n h,\n Fragment,\n Watch,\n Event,\n EventEmitter,\n Prop,\n State,\n} from \"@stencil/core\";\n\n\n/**\n * @slot children - This is a default/unnamed slot\n\n */\n @Component({\n tag: \"db-radio\",\n})\nexport class DBRadio {\n private _ref!: HTMLInputElement | any;\n @Prop() id: DBRadioProps[\"id\"];\n @Prop() checked: DBRadioProps[\"checked\"];\n @Event() change: EventEmitter<\n Parameters<Required<DBRadioProps>[\"onChange\"]>[number]\n > | void;\n @Event() blur: EventEmitter<\n Parameters<Required<DBRadioProps>[\"onBlur\"]>[number]\n > | void;\n @Event() focus: EventEmitter<\n Parameters<Required<DBRadioProps>[\"onFocus\"]>[number]\n > | void;\n @Prop() size: DBRadioProps[\"size\"];\n @Prop() showLabel: DBRadioProps[\"showLabel\"];\n @Prop({attribute: \"classname\"}) className: DBRadioProps[\"className\"];\n @Prop() validation: DBRadioProps[\"validation\"];\n @Prop() name: DBRadioProps[\"name\"];\n @Prop() disabled: DBRadioProps[\"disabled\"];\n @Prop() describedbyid: DBRadioProps[\"describedbyid\"];\n @Prop() ariaDescribedBy: DBRadioProps[\"ariaDescribedBy\"];\n @Prop() value: DBRadioProps[\"value\"];\n @Prop() required: DBRadioProps[\"required\"];\n @Prop() label: DBRadioProps[\"label\"];\n @State() initialized = false;\n @State() _id = undefined;\n\n handleChange(event: ChangeEvent<HTMLInputElement> | any) {\n event.stopPropagation();\n if (this.change) {\n this.change.emit(event);\n }\n }\n handleBlur(event: InteractionEvent<HTMLInputElement> | any) {\n event.stopPropagation();\n if (this.blur) {\n this.blur.emit(event);\n }\n }\n handleFocus(event: InteractionEvent<HTMLInputElement> | any) {\n event.stopPropagation();\n if (this.focus) {\n this.focus.emit(event);\n }\n }\n\n /**\n * Passes `aria-*`, `data-*` & `class` attributes to correct child. Used in angular and stencil.\n * @param element the ref for the component\n * @param customElementSelector the custom element like `my-component`\n */\n private enableAttributePassing(\n element: HTMLInputElement | null,\n customElementSelector: string\n ) {\n const parent = element?.closest(customElementSelector);\n if (element && parent) {\n const attributes = parent.attributes;\n for (let i = 0; i < attributes.length; i++) {\n const attr = attributes.item(i);\n if (\n attr &&\n (attr.name.startsWith(\"data-\") || attr.name.startsWith(\"aria-\"))\n ) {\n element.setAttribute(attr.name, attr.value);\n parent.removeAttribute(attr.name);\n }\n if (attr && attr.name === \"class\") {\n const isWebComponent = attr.value.includes(\"hydrated\");\n const value = attr.value.replace(\"hydrated\", \"\").trim();\n const currentClass = element.getAttribute(\"class\");\n element.setAttribute(\n attr.name,\n `${currentClass ? `${currentClass} ` : \"\"}${value}`\n );\n if (isWebComponent) {\n // Stencil is using this class for lazy loading component\n parent.setAttribute(\"class\", \"hydrated\");\n } else {\n parent.removeAttribute(attr.name);\n }\n }\n }\n }\n }\n\n watch0Fn() {\n if (this.checked && this.initialized && this._ref) {\n this._ref.checked = true;\n }\n }\n\n @Watch(\"initialized\")\n @Watch(\"_ref\")\n @Watch(\"checked\")\n watch0() {\n this.watch0Fn();\n }\n\n componentDidLoad() {\n this.enableAttributePassing(this._ref, \"db-radio\");\n this.initialized = true;\n this._id = this.id ?? `radio-${uuid()}`;\n this.watch0Fn();\n }\n\n render() {\n return (\n <label\n class={cls(\"db-radio\", this.className)}\n data-size={this.size}\n data-hide-label={getHideProp(this.showLabel)}\n htmlFor={this._id}\n >\n <input\n type=\"radio\"\n aria-invalid={this.validation === \"invalid\"}\n data-custom-validity={this.validation}\n ref={(el: any) => {\n this._ref = el;\n }}\n id={this._id}\n name={this.name}\n checked={getBoolean(this.checked, \"checked\")}\n disabled={getBoolean(this.disabled, \"disabled\")}\n aria-describedby={this.describedbyid ?? this.ariaDescribedBy}\n value={this.value}\n required={getBoolean(this.required, \"required\")}\n onChange={(event) => this.handleChange(event)}\n onBlur={(event) => this.handleBlur(event)}\n onFocus={(event) => this.handleFocus(event)}\n />\n {this.label ? this.label : <slot></slot>}\n </label>\n );\n }\n}\n"],"mappings":"iHA2BaA,EAAO,MAHnB,WAAAC,CAAAC,G,2FA2BUC,KAAWC,YAAG,MACdD,KAAGE,IAAGC,SA+GhB,CA7GC,YAAAC,CAAaC,GACXA,EAAMC,kBACN,GAAIN,KAAKO,OAAQ,CACfP,KAAKO,OAAOC,KAAKH,E,EAGrB,UAAAI,CAAWJ,GACTA,EAAMC,kBACN,GAAIN,KAAKU,KAAM,CACbV,KAAKU,KAAKF,KAAKH,E,EAGnB,WAAAM,CAAYN,GACVA,EAAMC,kBACN,GAA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D,KAAKE,KAEdyC,EAAA,SAAAC,IAAA,2CACEQ,KAAK,QAAO,eACEpD,KAAKqD,aAAe,UAAS,uBACrBrD,KAAKqD,WAC3BC,IAAMC,IACJvD,KAAKoC,KAAOmB,CAAE,EAEhBf,GAAIxC,KAAKE,IACTqB,KAAMvB,KAAKuB,KACXY,QAASqB,EAAWxD,KAAKmC,QAAS,WAClCsB,SAAUD,EAAWxD,KAAKyD,SAAU,YAAW,oBAC7BlB,EAAAvC,KAAK0D,iBAAa,MAAAnB,SAAA,EAAAA,EAAIvC,KAAK2D,gBAC7CjC,MAAO1B,KAAK0B,MACZkC,SAAUJ,EAAWxD,KAAK4D,SAAU,YACpCC,SAAWxD,GAAUL,KAAKI,aAAaC,GACvCyD,OAASzD,GAAUL,KAAKS,WAAWJ,GACnC0D,QAAU1D,GAAUL,KAAKW,YAAYN,KAEtCL,KAAKgE,MAAQhE,KAAKgE,MAAQrB,EAAa,a","ignoreList":[]}
@@ -0,0 +1,2 @@
1
+ import{r as s,c as t,h as i}from"./p-bH2PZLSq.js";import{s as a}from"./p-DC9V_oNU.js";import{b as e,s as c,j as n,c as o}from"./p-CQCQcuvr.js";const l=class{constructor(i){s(this,i);this.close=t(this,"close")}handleClose(s){s.stopPropagation();if(this.close){this.close.emit(s)}}enableAttributePassing(s,t){const i=s===null||s===void 0?void 0:s.closest(t);if(s&&i){const t=i.attributes;for(let a=0;a<t.length;a++){const e=t.item(a);if(e&&(e.name.startsWith("data-")||e.name.startsWith("aria-"))){s.setAttribute(e.name,e.value);i.removeAttribute(e.name)}if(e&&e.name==="class"){const t=e.value.includes("hydrated");const a=e.value.replace("hydrated","").trim();const c=s.getAttribute("class");s.setAttribute(e.name,`${c?`${c} `:""}${a}`);if(t){i.setAttribute("class","hydrated")}else{i.removeAttribute(e.name)}}}}}componentDidLoad(){this.enableAttributePassing(this._ref,"db-notification")}render(){var s;return i("article",{key:"c3a9ffcbcbb1b4565916b8cde6e21a1eb51a11c4",class:o("db-notification",this.className),ref:s=>{this._ref=s},id:this.id,"aria-live":this.ariaLive,"data-semantic":this.semantic,"data-variant":this.variant,"data-icon":this.icon,"data-hide-icon":n(this.showIcon),"data-link-variant":this.linkVariant},i("slot",{key:"88b949c8458db7ec2d313ea0c27c4f296d23cb0a",name:"image"}),c(this.headline,this.showHeadline)?i("header",null,this.headline):null,i("p",{key:"50a4b06908d9505c8c15a80b64ad651cb98d203e"},this.text?this.text:i("slot",null)),c(this.timestamp,this.showTimestamp)?i("span",null,this.timestamp):null,i("slot",{key:"e6fa5ef24470f2a5686f52ef4adb452f251ceda4",name:"link"}),e(this.closeable,"closeable")?i("db-button",{icon:"cross",variant:"ghost",size:"small",id:this.closeButtonId,noText:true,onClick:s=>this.handleClose(s)},(s=this.closeButtonText)!==null&&s!==void 0?s:a):null)}};export{l as db_notification};
2
+ //# sourceMappingURL=p-166b337e.entry.js.map