@gov-design-system-ce/components 4.1.3-BETA-8 → 4.1.3-BETA-10

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 (349) hide show
  1. package/dist/cjs/core.cjs.js +2 -2
  2. package/dist/cjs/gov-accordion-item.cjs.entry.js +1 -1
  3. package/dist/cjs/gov-accordion.cjs.entry.js +1 -1
  4. package/dist/cjs/gov-attachments_3.cjs.entry.js +1 -1
  5. package/dist/cjs/gov-backdrop.cjs.entry.js +1 -1
  6. package/dist/cjs/gov-breadcrumbs.cjs.entry.js +1 -1
  7. package/dist/cjs/gov-button.cjs.entry.js +1 -1
  8. package/dist/cjs/gov-card.cjs.entry.js +1 -1
  9. package/dist/cjs/gov-chip.cjs.entry.js +1 -1
  10. package/dist/cjs/gov-container.cjs.entry.js +1 -1
  11. package/dist/cjs/gov-control-group.cjs.entry.js +1 -1
  12. package/dist/cjs/gov-cookiebar.cjs.entry.js +1 -1
  13. package/dist/cjs/gov-dialog.cjs.entry.js +1 -1
  14. package/dist/cjs/gov-dropdown.cjs.entry.js +1 -1
  15. package/dist/cjs/gov-empty.cjs.entry.js +1 -1
  16. package/dist/cjs/gov-error-code.cjs.entry.js +1 -1
  17. package/dist/cjs/gov-flex_3.cjs.entry.js +5 -22
  18. package/dist/cjs/gov-flex_3.cjs.entry.js.map +1 -1
  19. package/dist/cjs/gov-form-autocomplete.cjs.entry.js +1 -1
  20. package/dist/cjs/gov-form-checkbox-group.cjs.entry.js +1 -1
  21. package/dist/cjs/gov-form-checkbox.cjs.entry.js +1 -1
  22. package/dist/cjs/gov-form-control.cjs.entry.js +1 -1
  23. package/dist/cjs/gov-form-file.cjs.entry.js +1 -1
  24. package/dist/cjs/gov-form-group.cjs.entry.js +1 -1
  25. package/dist/cjs/gov-form-input_2.cjs.entry.js +1 -1
  26. package/dist/cjs/gov-form-label.cjs.entry.js +1 -1
  27. package/dist/cjs/gov-form-multi-select.cjs.entry.js +1 -1
  28. package/dist/cjs/gov-form-password-power.cjs.entry.js +1 -1
  29. package/dist/cjs/gov-form-radio-group.cjs.entry.js +1 -1
  30. package/dist/cjs/gov-form-radio.cjs.entry.js +1 -1
  31. package/dist/cjs/gov-form-search.cjs.entry.js +1 -1
  32. package/dist/cjs/gov-form-select.cjs.entry.js +1 -1
  33. package/dist/cjs/gov-form-switch.cjs.entry.js +1 -1
  34. package/dist/cjs/gov-grid-item.cjs.entry.js +1 -1
  35. package/dist/cjs/gov-grid.cjs.entry.js +1 -1
  36. package/dist/cjs/gov-infobar.cjs.entry.js +1 -1
  37. package/dist/cjs/gov-layout-column.cjs.entry.js +1 -1
  38. package/dist/cjs/gov-layout.cjs.entry.js +1 -1
  39. package/dist/cjs/gov-lifecycle.cjs.entry.js +1 -1
  40. package/dist/cjs/gov-link.cjs.entry.js +1 -1
  41. package/dist/cjs/gov-loading.cjs.entry.js +1 -1
  42. package/dist/cjs/gov-message.cjs.entry.js +1 -1
  43. package/dist/cjs/gov-pagination.cjs.entry.js +1 -1
  44. package/dist/cjs/gov-spacer.cjs.entry.js +1 -1
  45. package/dist/cjs/gov-stepper-item.cjs.entry.js +1 -1
  46. package/dist/cjs/gov-stepper.cjs.entry.js +1 -1
  47. package/dist/cjs/gov-tabs-item.cjs.entry.js +1 -1
  48. package/dist/cjs/gov-tabs.cjs.entry.js +1 -1
  49. package/dist/cjs/gov-tag.cjs.entry.js +1 -1
  50. package/dist/cjs/gov-tile.cjs.entry.js +1 -1
  51. package/dist/cjs/gov-tiles.cjs.entry.js +1 -1
  52. package/dist/cjs/gov-toast.cjs.entry.js +1 -1
  53. package/dist/cjs/gov-tooltip-content.cjs.entry.js +1 -1
  54. package/dist/cjs/gov-tooltip.cjs.entry.js +1 -1
  55. package/dist/cjs/gov-wizard-item.cjs.entry.js +1 -1
  56. package/dist/cjs/gov-wizard.cjs.entry.js +1 -1
  57. package/dist/cjs/{index-67e87c27.js → index-0e4f24f9.js} +1 -15
  58. package/dist/cjs/index-0e4f24f9.js.map +1 -0
  59. package/dist/cjs/loader.cjs.js +2 -2
  60. package/dist/collection/components/gov-icon/gov-icon.js +2 -15
  61. package/dist/collection/components/gov-icon/gov-icon.js.map +1 -1
  62. package/dist/collection/utils/icon.utils.js +1 -8
  63. package/dist/collection/utils/icon.utils.js.map +1 -1
  64. package/dist/components/gov-accordion-item.js +1 -1
  65. package/dist/components/gov-accordion.js +1 -1
  66. package/dist/components/gov-attachments-item.js +1 -1
  67. package/dist/components/gov-attachments.js +1 -1
  68. package/dist/components/gov-backdrop.js +1 -1
  69. package/dist/components/gov-breadcrumbs.js +1 -1
  70. package/dist/components/gov-breadcrumbs.js.map +1 -1
  71. package/dist/components/gov-button.js +1 -1
  72. package/dist/components/gov-card.js +1 -1
  73. package/dist/components/gov-chip.js +1 -1
  74. package/dist/components/gov-container.js +1 -1
  75. package/dist/components/gov-control-group.js +1 -1
  76. package/dist/components/gov-cookiebar.js +1 -1
  77. package/dist/components/gov-dialog.js +1 -1
  78. package/dist/components/gov-dropdown.js +1 -1
  79. package/dist/components/gov-dropdown.js.map +1 -1
  80. package/dist/components/gov-empty.js +1 -1
  81. package/dist/components/gov-error-code.js +1 -1
  82. package/dist/components/gov-flex.js +1 -1
  83. package/dist/components/gov-form-autocomplete.js +1 -1
  84. package/dist/components/gov-form-checkbox-group.js +1 -1
  85. package/dist/components/gov-form-checkbox.js +1 -1
  86. package/dist/components/gov-form-control.js +1 -1
  87. package/dist/components/gov-form-file.js +1 -1
  88. package/dist/components/gov-form-file.js.map +1 -1
  89. package/dist/components/gov-form-group.js +1 -1
  90. package/dist/components/gov-form-input.js +1 -1
  91. package/dist/components/gov-form-label.js +1 -1
  92. package/dist/components/gov-form-message.js +1 -1
  93. package/dist/components/gov-form-multi-select.js +1 -1
  94. package/dist/components/gov-form-password-power.js +1 -1
  95. package/dist/components/gov-form-radio-group.js +1 -1
  96. package/dist/components/gov-form-radio.js +1 -1
  97. package/dist/components/gov-form-search.js +1 -1
  98. package/dist/components/gov-form-select.js +1 -1
  99. package/dist/components/gov-form-switch.js +1 -1
  100. package/dist/components/gov-grid-item.js +1 -1
  101. package/dist/components/gov-grid.js +1 -1
  102. package/dist/components/gov-icon.js +1 -1
  103. package/dist/components/gov-infobar.js +1 -1
  104. package/dist/components/gov-layout-column.js +1 -1
  105. package/dist/components/gov-layout.js +1 -1
  106. package/dist/components/gov-lifecycle.js +1 -1
  107. package/dist/components/gov-link.js +1 -1
  108. package/dist/components/gov-loading.js +1 -1
  109. package/dist/components/gov-message.js +1 -1
  110. package/dist/components/gov-pagination.js +1 -1
  111. package/dist/components/gov-skeleton.js +1 -1
  112. package/dist/components/gov-spacer.js +1 -1
  113. package/dist/components/gov-stepper-item.js +1 -1
  114. package/dist/components/gov-stepper.js +1 -1
  115. package/dist/components/gov-tabs-item.js +1 -1
  116. package/dist/components/gov-tabs.js +1 -1
  117. package/dist/components/gov-tag.js +1 -1
  118. package/dist/components/gov-theme-switch.js +1 -1
  119. package/dist/components/gov-tile.js +1 -1
  120. package/dist/components/gov-tiles.js +1 -1
  121. package/dist/components/gov-toast.js +1 -1
  122. package/dist/components/gov-tooltip-content.js +1 -1
  123. package/dist/components/gov-tooltip.js +1 -1
  124. package/dist/components/gov-wizard-item.js +1 -1
  125. package/dist/components/gov-wizard.js +1 -1
  126. package/dist/components/index.js +1 -1
  127. package/dist/components/{p-0679f3d6.js → p-076c8b31.js} +2 -2
  128. package/dist/components/{p-51693b62.js → p-13a70392.js} +2 -2
  129. package/dist/components/p-42200001.js +3 -0
  130. package/dist/components/p-42200001.js.map +1 -0
  131. package/dist/components/{p-887df980.js → p-4d513423.js} +2 -2
  132. package/dist/components/{p-8f40dfec.js → p-4faecdb2.js} +2 -2
  133. package/dist/components/{p-9b0f446d.js → p-558cbab0.js} +2 -2
  134. package/dist/components/{p-03ad4e0f.js → p-73938936.js} +2 -2
  135. package/dist/components/{p-384c7f2a.js → p-7be2301a.js} +2 -2
  136. package/dist/components/p-a877bf8a.js +2 -0
  137. package/dist/components/p-a877bf8a.js.map +1 -0
  138. package/dist/components/{p-350e060c.js → p-b97d8edd.js} +2 -2
  139. package/dist/components/{p-8ee6f2f3.js → p-c438a723.js} +2 -2
  140. package/dist/components/{p-884d8f16.js → p-c5e91e5a.js} +2 -2
  141. package/dist/core/core.esm.js +1 -1
  142. package/dist/core/core.esm.js.map +1 -1
  143. package/dist/core/p-07b1fa1c.entry.js +2 -0
  144. package/dist/core/{p-347d15d5.entry.js.map → p-07b1fa1c.entry.js.map} +1 -1
  145. package/dist/core/{p-ee55932a.entry.js → p-0932c74d.entry.js} +2 -2
  146. package/dist/core/{p-d9b42773.entry.js → p-13c6da90.entry.js} +2 -2
  147. package/dist/core/{p-33310735.entry.js → p-15a7b952.entry.js} +2 -2
  148. package/dist/core/{p-fcac8531.entry.js → p-2470194a.entry.js} +2 -2
  149. package/dist/core/{p-10f773c2.entry.js → p-2abdce2d.entry.js} +2 -2
  150. package/dist/core/{p-017ff5a5.entry.js → p-2ae8b8d5.entry.js} +2 -2
  151. package/dist/core/{p-f54edd6c.entry.js → p-3627773f.entry.js} +2 -2
  152. package/dist/core/{p-7a21fb90.entry.js → p-36b35592.entry.js} +2 -2
  153. package/dist/core/{p-4e29744a.entry.js → p-3974176f.entry.js} +2 -2
  154. package/dist/core/{p-4fa0320d.entry.js → p-3b8b331f.entry.js} +2 -2
  155. package/dist/core/p-41e0ad2e.entry.js +2 -0
  156. package/dist/core/p-41e0ad2e.entry.js.map +1 -0
  157. package/dist/core/p-49ebfe10.entry.js +2 -0
  158. package/dist/core/{p-967a1094.entry.js.map → p-49ebfe10.entry.js.map} +1 -1
  159. package/dist/core/{p-6b7c3a96.entry.js → p-4aa5db49.entry.js} +2 -2
  160. package/dist/core/{p-0f0f7302.entry.js → p-52042c7e.entry.js} +2 -2
  161. package/dist/core/{p-e0a199ff.entry.js → p-5e42395f.entry.js} +2 -2
  162. package/dist/core/{p-7baee44f.entry.js → p-5ff7f0c4.entry.js} +2 -2
  163. package/dist/core/{p-77daba72.entry.js → p-6f1ea21d.entry.js} +2 -2
  164. package/dist/core/{p-4c60e125.entry.js → p-72c4ebcd.entry.js} +2 -2
  165. package/dist/core/{p-b62e49ee.entry.js → p-72cdac94.entry.js} +2 -2
  166. package/dist/core/{p-058e6fe2.entry.js → p-77bf7b01.entry.js} +2 -2
  167. package/dist/core/{p-0724cb6a.entry.js → p-7a44bd0a.entry.js} +2 -2
  168. package/dist/core/{p-032accfb.entry.js → p-7c0be05a.entry.js} +2 -2
  169. package/dist/core/p-80c7db1f.entry.js +2 -0
  170. package/dist/core/{p-d795a421.entry.js.map → p-80c7db1f.entry.js.map} +1 -1
  171. package/dist/core/{p-37473c34.entry.js → p-8e5f45d0.entry.js} +2 -2
  172. package/dist/core/{p-50af9ae8.entry.js → p-8ede0622.entry.js} +2 -2
  173. package/dist/core/p-9256cf6c.entry.js +2 -0
  174. package/dist/core/p-93179cbf.entry.js +2 -0
  175. package/dist/core/{p-8cc5ad01.entry.js.map → p-93179cbf.entry.js.map} +1 -1
  176. package/dist/core/p-93b747c1.entry.js +2 -0
  177. package/dist/core/{p-3849ca02.entry.js → p-9514520c.entry.js} +2 -2
  178. package/dist/core/{p-8bb6c816.entry.js → p-9897ac81.entry.js} +2 -2
  179. package/dist/core/p-9dea2efa.js +3 -0
  180. package/dist/core/p-9dea2efa.js.map +1 -0
  181. package/dist/core/{p-ed02945f.entry.js → p-9e77f076.entry.js} +2 -2
  182. package/dist/core/p-9fcb2ba7.entry.js +2 -0
  183. package/dist/core/{p-45b759f4.entry.js.map → p-9fcb2ba7.entry.js.map} +1 -1
  184. package/dist/core/{p-5c3f4cfe.entry.js → p-a0728f09.entry.js} +2 -2
  185. package/dist/core/p-a22517e2.entry.js +2 -0
  186. package/dist/core/{p-cecbe73f.entry.js.map → p-a22517e2.entry.js.map} +1 -1
  187. package/dist/core/{p-1aa7450e.entry.js → p-a5648769.entry.js} +2 -2
  188. package/dist/core/{p-a6a9de9a.entry.js → p-a58f4e2b.entry.js} +2 -2
  189. package/dist/core/{p-14d66f26.entry.js → p-a8a5e8ca.entry.js} +2 -2
  190. package/dist/core/{p-c0800e6d.entry.js → p-ab500948.entry.js} +2 -2
  191. package/dist/core/{p-9f8d69a9.entry.js → p-b319674e.entry.js} +2 -2
  192. package/dist/core/{p-0c076b21.entry.js → p-b404f53c.entry.js} +2 -2
  193. package/dist/core/{p-f7f60f91.entry.js → p-bd667900.entry.js} +2 -2
  194. package/dist/core/{p-e215f3ee.entry.js → p-c34dad75.entry.js} +2 -2
  195. package/dist/core/{p-269071f5.entry.js → p-c9d70c7a.entry.js} +2 -2
  196. package/dist/core/{p-063b70a2.entry.js → p-d512059d.entry.js} +2 -2
  197. package/dist/core/p-e078dab3.entry.js +2 -0
  198. package/dist/core/{p-3a7381e7.entry.js.map → p-e078dab3.entry.js.map} +1 -1
  199. package/dist/core/{p-9846fd13.entry.js → p-e4ac787c.entry.js} +2 -2
  200. package/dist/core/{p-994385ca.entry.js → p-e7b3b5db.entry.js} +2 -2
  201. package/dist/core/p-eed4e606.entry.js +2 -0
  202. package/dist/core/{p-237a5b91.entry.js.map → p-eed4e606.entry.js.map} +1 -1
  203. package/dist/core/{p-7dfb7e36.entry.js → p-f60265c3.entry.js} +2 -2
  204. package/dist/core/p-f6863a64.entry.js +2 -0
  205. package/dist/core/{p-f2bb8c29.entry.js → p-f9474bb3.entry.js} +2 -2
  206. package/dist/core/p-f98f19f6.entry.js +2 -0
  207. package/dist/core/{p-906865d0.entry.js.map → p-f98f19f6.entry.js.map} +1 -1
  208. package/dist/core/{p-927c31dd.entry.js → p-fd7a3951.entry.js} +2 -2
  209. package/dist/esm/core.js +3 -3
  210. package/dist/esm/gov-accordion-item.entry.js +1 -1
  211. package/dist/esm/gov-accordion.entry.js +1 -1
  212. package/dist/esm/gov-attachments_3.entry.js +1 -1
  213. package/dist/esm/gov-backdrop.entry.js +1 -1
  214. package/dist/esm/gov-breadcrumbs.entry.js +1 -1
  215. package/dist/esm/gov-button.entry.js +1 -1
  216. package/dist/esm/gov-card.entry.js +1 -1
  217. package/dist/esm/gov-chip.entry.js +1 -1
  218. package/dist/esm/gov-container.entry.js +1 -1
  219. package/dist/esm/gov-control-group.entry.js +1 -1
  220. package/dist/esm/gov-cookiebar.entry.js +1 -1
  221. package/dist/esm/gov-dialog.entry.js +1 -1
  222. package/dist/esm/gov-dropdown.entry.js +1 -1
  223. package/dist/esm/gov-empty.entry.js +1 -1
  224. package/dist/esm/gov-error-code.entry.js +1 -1
  225. package/dist/esm/gov-flex_3.entry.js +5 -22
  226. package/dist/esm/gov-flex_3.entry.js.map +1 -1
  227. package/dist/esm/gov-form-autocomplete.entry.js +1 -1
  228. package/dist/esm/gov-form-checkbox-group.entry.js +1 -1
  229. package/dist/esm/gov-form-checkbox.entry.js +1 -1
  230. package/dist/esm/gov-form-control.entry.js +1 -1
  231. package/dist/esm/gov-form-file.entry.js +1 -1
  232. package/dist/esm/gov-form-group.entry.js +1 -1
  233. package/dist/esm/gov-form-input_2.entry.js +1 -1
  234. package/dist/esm/gov-form-label.entry.js +1 -1
  235. package/dist/esm/gov-form-multi-select.entry.js +1 -1
  236. package/dist/esm/gov-form-password-power.entry.js +1 -1
  237. package/dist/esm/gov-form-radio-group.entry.js +1 -1
  238. package/dist/esm/gov-form-radio.entry.js +1 -1
  239. package/dist/esm/gov-form-search.entry.js +1 -1
  240. package/dist/esm/gov-form-select.entry.js +1 -1
  241. package/dist/esm/gov-form-switch.entry.js +1 -1
  242. package/dist/esm/gov-grid-item.entry.js +1 -1
  243. package/dist/esm/gov-grid.entry.js +1 -1
  244. package/dist/esm/gov-infobar.entry.js +1 -1
  245. package/dist/esm/gov-layout-column.entry.js +1 -1
  246. package/dist/esm/gov-layout.entry.js +1 -1
  247. package/dist/esm/gov-lifecycle.entry.js +1 -1
  248. package/dist/esm/gov-link.entry.js +1 -1
  249. package/dist/esm/gov-loading.entry.js +1 -1
  250. package/dist/esm/gov-message.entry.js +1 -1
  251. package/dist/esm/gov-pagination.entry.js +1 -1
  252. package/dist/esm/gov-spacer.entry.js +1 -1
  253. package/dist/esm/gov-stepper-item.entry.js +1 -1
  254. package/dist/esm/gov-stepper.entry.js +1 -1
  255. package/dist/esm/gov-tabs-item.entry.js +1 -1
  256. package/dist/esm/gov-tabs.entry.js +1 -1
  257. package/dist/esm/gov-tag.entry.js +1 -1
  258. package/dist/esm/gov-tile.entry.js +1 -1
  259. package/dist/esm/gov-tiles.entry.js +1 -1
  260. package/dist/esm/gov-toast.entry.js +1 -1
  261. package/dist/esm/gov-tooltip-content.entry.js +1 -1
  262. package/dist/esm/gov-tooltip.entry.js +1 -1
  263. package/dist/esm/gov-wizard-item.entry.js +1 -1
  264. package/dist/esm/gov-wizard.entry.js +1 -1
  265. package/dist/esm/{index-087b155c.js → index-bf8a6f64.js} +2 -14
  266. package/dist/esm/index-bf8a6f64.js.map +1 -0
  267. package/dist/esm/loader.js +3 -3
  268. package/dist/hydrate/index.js +4 -34
  269. package/dist/hydrate/index.mjs +4 -34
  270. package/dist/types/components/gov-icon/gov-icon.d.ts +0 -1
  271. package/package.json +1 -1
  272. package/dist/cjs/index-67e87c27.js.map +0 -1
  273. package/dist/components/p-115b9cf3.js +0 -3
  274. package/dist/components/p-115b9cf3.js.map +0 -1
  275. package/dist/components/p-7f0c6ba3.js +0 -2
  276. package/dist/components/p-7f0c6ba3.js.map +0 -1
  277. package/dist/components/p-bfce6f99.js +0 -2
  278. package/dist/components/p-bfce6f99.js.map +0 -1
  279. package/dist/core/p-09c9eba6.entry.js +0 -2
  280. package/dist/core/p-237a5b91.entry.js +0 -2
  281. package/dist/core/p-2642cc66.entry.js +0 -2
  282. package/dist/core/p-2642cc66.entry.js.map +0 -1
  283. package/dist/core/p-2ee042d4.js +0 -3
  284. package/dist/core/p-2ee042d4.js.map +0 -1
  285. package/dist/core/p-347d15d5.entry.js +0 -2
  286. package/dist/core/p-3a7381e7.entry.js +0 -2
  287. package/dist/core/p-43d3dbc0.entry.js +0 -2
  288. package/dist/core/p-45b759f4.entry.js +0 -2
  289. package/dist/core/p-71f5d4ff.entry.js +0 -2
  290. package/dist/core/p-8cc5ad01.entry.js +0 -2
  291. package/dist/core/p-906865d0.entry.js +0 -2
  292. package/dist/core/p-967a1094.entry.js +0 -2
  293. package/dist/core/p-cecbe73f.entry.js +0 -2
  294. package/dist/core/p-d795a421.entry.js +0 -2
  295. package/dist/esm/index-087b155c.js.map +0 -1
  296. /package/dist/components/{p-0679f3d6.js.map → p-076c8b31.js.map} +0 -0
  297. /package/dist/components/{p-51693b62.js.map → p-13a70392.js.map} +0 -0
  298. /package/dist/components/{p-887df980.js.map → p-4d513423.js.map} +0 -0
  299. /package/dist/components/{p-8f40dfec.js.map → p-4faecdb2.js.map} +0 -0
  300. /package/dist/components/{p-9b0f446d.js.map → p-558cbab0.js.map} +0 -0
  301. /package/dist/components/{p-03ad4e0f.js.map → p-73938936.js.map} +0 -0
  302. /package/dist/components/{p-384c7f2a.js.map → p-7be2301a.js.map} +0 -0
  303. /package/dist/components/{p-350e060c.js.map → p-b97d8edd.js.map} +0 -0
  304. /package/dist/components/{p-8ee6f2f3.js.map → p-c438a723.js.map} +0 -0
  305. /package/dist/components/{p-884d8f16.js.map → p-c5e91e5a.js.map} +0 -0
  306. /package/dist/core/{p-ee55932a.entry.js.map → p-0932c74d.entry.js.map} +0 -0
  307. /package/dist/core/{p-d9b42773.entry.js.map → p-13c6da90.entry.js.map} +0 -0
  308. /package/dist/core/{p-33310735.entry.js.map → p-15a7b952.entry.js.map} +0 -0
  309. /package/dist/core/{p-fcac8531.entry.js.map → p-2470194a.entry.js.map} +0 -0
  310. /package/dist/core/{p-10f773c2.entry.js.map → p-2abdce2d.entry.js.map} +0 -0
  311. /package/dist/core/{p-017ff5a5.entry.js.map → p-2ae8b8d5.entry.js.map} +0 -0
  312. /package/dist/core/{p-f54edd6c.entry.js.map → p-3627773f.entry.js.map} +0 -0
  313. /package/dist/core/{p-7a21fb90.entry.js.map → p-36b35592.entry.js.map} +0 -0
  314. /package/dist/core/{p-4e29744a.entry.js.map → p-3974176f.entry.js.map} +0 -0
  315. /package/dist/core/{p-4fa0320d.entry.js.map → p-3b8b331f.entry.js.map} +0 -0
  316. /package/dist/core/{p-6b7c3a96.entry.js.map → p-4aa5db49.entry.js.map} +0 -0
  317. /package/dist/core/{p-0f0f7302.entry.js.map → p-52042c7e.entry.js.map} +0 -0
  318. /package/dist/core/{p-e0a199ff.entry.js.map → p-5e42395f.entry.js.map} +0 -0
  319. /package/dist/core/{p-7baee44f.entry.js.map → p-5ff7f0c4.entry.js.map} +0 -0
  320. /package/dist/core/{p-77daba72.entry.js.map → p-6f1ea21d.entry.js.map} +0 -0
  321. /package/dist/core/{p-4c60e125.entry.js.map → p-72c4ebcd.entry.js.map} +0 -0
  322. /package/dist/core/{p-b62e49ee.entry.js.map → p-72cdac94.entry.js.map} +0 -0
  323. /package/dist/core/{p-058e6fe2.entry.js.map → p-77bf7b01.entry.js.map} +0 -0
  324. /package/dist/core/{p-0724cb6a.entry.js.map → p-7a44bd0a.entry.js.map} +0 -0
  325. /package/dist/core/{p-032accfb.entry.js.map → p-7c0be05a.entry.js.map} +0 -0
  326. /package/dist/core/{p-37473c34.entry.js.map → p-8e5f45d0.entry.js.map} +0 -0
  327. /package/dist/core/{p-50af9ae8.entry.js.map → p-8ede0622.entry.js.map} +0 -0
  328. /package/dist/core/{p-71f5d4ff.entry.js.map → p-9256cf6c.entry.js.map} +0 -0
  329. /package/dist/core/{p-43d3dbc0.entry.js.map → p-93b747c1.entry.js.map} +0 -0
  330. /package/dist/core/{p-3849ca02.entry.js.map → p-9514520c.entry.js.map} +0 -0
  331. /package/dist/core/{p-8bb6c816.entry.js.map → p-9897ac81.entry.js.map} +0 -0
  332. /package/dist/core/{p-ed02945f.entry.js.map → p-9e77f076.entry.js.map} +0 -0
  333. /package/dist/core/{p-5c3f4cfe.entry.js.map → p-a0728f09.entry.js.map} +0 -0
  334. /package/dist/core/{p-1aa7450e.entry.js.map → p-a5648769.entry.js.map} +0 -0
  335. /package/dist/core/{p-a6a9de9a.entry.js.map → p-a58f4e2b.entry.js.map} +0 -0
  336. /package/dist/core/{p-14d66f26.entry.js.map → p-a8a5e8ca.entry.js.map} +0 -0
  337. /package/dist/core/{p-c0800e6d.entry.js.map → p-ab500948.entry.js.map} +0 -0
  338. /package/dist/core/{p-9f8d69a9.entry.js.map → p-b319674e.entry.js.map} +0 -0
  339. /package/dist/core/{p-0c076b21.entry.js.map → p-b404f53c.entry.js.map} +0 -0
  340. /package/dist/core/{p-f7f60f91.entry.js.map → p-bd667900.entry.js.map} +0 -0
  341. /package/dist/core/{p-e215f3ee.entry.js.map → p-c34dad75.entry.js.map} +0 -0
  342. /package/dist/core/{p-269071f5.entry.js.map → p-c9d70c7a.entry.js.map} +0 -0
  343. /package/dist/core/{p-063b70a2.entry.js.map → p-d512059d.entry.js.map} +0 -0
  344. /package/dist/core/{p-9846fd13.entry.js.map → p-e4ac787c.entry.js.map} +0 -0
  345. /package/dist/core/{p-994385ca.entry.js.map → p-e7b3b5db.entry.js.map} +0 -0
  346. /package/dist/core/{p-7dfb7e36.entry.js.map → p-f60265c3.entry.js.map} +0 -0
  347. /package/dist/core/{p-09c9eba6.entry.js.map → p-f6863a64.entry.js.map} +0 -0
  348. /package/dist/core/{p-f2bb8c29.entry.js.map → p-f9474bb3.entry.js.map} +0 -0
  349. /package/dist/core/{p-927c31dd.entry.js.map → p-fd7a3951.entry.js.map} +0 -0
@@ -1 +1 @@
1
- {"version":3,"names":["FormFileClass","root","area","input","attachments","formatBytes","bytes","units","l","n","parseInt","toFixed","fileAcceptValidation","file","accept","length","replace","split","filter","RegExp","test","type","fileSizeValidation","maxSize","fileSize","Math","round","size","GovFormFile","proxyCustomElement","H","constructor","this","eventsRegistered","fileId","createID","h","govHost","host","f","govForm","watchControlAttrs","passControlAttrs","passAttrToControl","toBoolAttr","invalid","disabled","registerListeners","highlight","areaRef","classList","add","unhighlight","remove","inputRef","addEventListener","e","preventDefault","stopPropagation","files","target","resetAfterPick","validateFiles","expanded","events","inEvents","outEvents","map","eventName","preventDefaults","bind","forEach","handleDrop","dataTransfer","filesBuffer","Array","from","isFile","find","item","name","ignoreFileDuplicationCheck","isSizeValid","maxFileSize","isAcceptValid","newFile","id","acceptValid","sizeValid","displayAttachments","govAddFile","emit","component","govFiles","reset","finally","componentDidLoad","attributeObserver","AttributeObserver","attributeName","newValue","onAriaAttributeChange","startObserving","ariaAttributes","componentWillLoad","passAttrToLabel","String","required","inheritedAttributes","inheritAriaAttributes","componentDidRender","disconnectedCallback","stopObserving","removeAttribute","Object","assign","render","Host","key","class","classes","toBoolAttrIfDefined","ref","el","identifier","multiple","onChange","onChangeHandler","onFocus","onFocusHandler","onBlur","onBlurHandler","hasSlot","label","accessibleAttachmentsLabel","onRemoveFileHandler","accessibleRemoveLabel","slot","color","errorAccept","errorSize","index","findIndex","removeFile","splice","govRemoveFile","govFocus","originalEvent","govBlur","getRef","getAreaRef","value"],"sources":["../../../packages/core/src/components/gov-form/file/constants.ts","../../../packages/core/src/utils/file.utils.ts","../../../packages/core/src/components/gov-form/file/gov-form-file.tsx"],"sourcesContent":["export const FormFileClass = {\n\troot: 'gov-form-file',\n\tarea: 'gov-form-file__area',\n\tinput: 'gov-form-file__input',\n\tattachments: 'gov-form-file__attachments',\n}\n","export function formatBytes(bytes: any): string {\n\tconst units = ['bytes', 'KiB', 'MiB', 'GiB', 'TiB', 'PiB', 'EiB', 'ZiB', 'YiB']\n\tlet l = 0,\n\t\tn = parseInt(bytes, 10) || 0\n\n\twhile (n >= 1024 && ++l) {\n\t\tn = n / 1024\n\t}\n\n\treturn n.toFixed(n < 10 && l > 0 ? 1 : 0) + ' ' + units[l]\n}\n\nexport function fileAcceptValidation(file: File, accept: string): boolean {\n\tif (typeof accept === 'string' && accept.length) {\n\t\treturn (\n\t\t\taccept\n\t\t\t\t.replace(/\\s/g, '')\n\t\t\t\t.split(',')\n\t\t\t\t.filter(accept => {\n\t\t\t\t\treturn new RegExp(accept.replace('*', '.*')).test(file.type)\n\t\t\t\t}).length > 0\n\t\t)\n\t} else {\n\t\treturn true\n\t}\n}\n\nexport function fileSizeValidation(file: File, maxSize: number): boolean {\n\tconst fileSize = Math.round(file.size)\n\treturn fileSize <= maxSize\n}\n","import {Component, Element, Event, EventEmitter, h, Host, Method, Prop, State, Watch} from \"@stencil/core\"\nimport {createID} from \"../../../utils/string.utils\"\nimport {FormFileClass} from \"./constants\"\nimport {govHost, toBoolAttr, toBoolAttrIfDefined} from \"../../../helpers/Dom/template\"\nimport {fileAcceptValidation, fileSizeValidation, formatBytes} from \"../../../utils/file.utils\"\nimport {GovForm} from \"../../../helpers/Dom/form.types\"\nimport {GovHost} from \"../../../helpers/Dom/template.types\"\nimport {govForm} from \"../../../helpers/Dom/form\"\nimport {GovFormFileEvent, GovFormFileItem} from \"./gov-form-file.types\"\nimport {inheritAriaAttributes} from \"../../../helpers/Accessibility/accessibility\";\nimport {AttributeObserver, Attributes} from \"../../../helpers/Dom/attribute\";\nimport {ariaAttributes} from \"../../../helpers/Accessibility/attributes\";\n\n@Component({\n\ttag: \"gov-form-file\",\n})\nexport class GovFormFile {\n\tprivate f: GovForm\n\tprivate readonly h: GovHost\n\n\tprivate areaRef?: HTMLDivElement\n\tprivate inputRef?: HTMLInputElement\n\tprivate readonly fileId: string\n\tprivate attributeObserver: AttributeObserver\n\tprivate eventsRegistered = false\n\n\tconstructor() {\n\t\tthis.fileId = createID(\"GovInputFile\")\n\n\t\tthis.h = govHost(this.host)\n\t\tthis.f = govForm(this.h)\n\t}\n\n\t@Element() host: HTMLGovFormFileElement\n\t/**\n\t * Expands the file input to fill 100% of the container width.\n\t */\n\t@Prop() readonly expanded: boolean = false\n\t/**\n\t * Set whether the input is required or not. Please note that this is necessary for accessible inputs when the user is required to fill them.\n\t * When using this property you need to also set “novalidate” attribute to your form element to prevent browser from displaying its own validation errors.\n\t */\n\t@Prop() readonly required: boolean = false\n\t/**\n\t * Makes the File component disabled.\n\t * This prevents users from being able to interact with the File, and conveys its inactive state to assistive technologies.\n\t */\n\t@Prop({reflect: true}) readonly disabled: boolean = false\n\t/**\n\t * After selecting the files, the main input element will be reset.\n\t * The propagation of the event with the selected files will not be affected.\n\t */\n\t@Prop({attribute: \"reset-after-pick\"}) readonly resetAfterPick: boolean = false\n\t/**\n\t * Selected files will not be checked for duplicates based on name and size.\n\t */\n\t@Prop({attribute: \"ignore-file-duplication-check\"}) readonly ignoreFileDuplicationCheck: boolean = false\n\t/**\n\t * Show list of attachments\n\t */\n\t@Prop({attribute: \"display-attachments\"}) readonly displayAttachments: boolean = true\n\t/**\n\t * Name of the input.\n\t */\n\t@Prop() readonly name: string\n\t/**\n\t * Same as original parameter\n\t * @link https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/accept\n\t */\n\t@Prop() readonly accept: string\n\t/**\n\t * Same as original parameter\n\t * @link https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/multiple\n\t */\n\t@Prop() readonly multiple: boolean = false\n\t/**\n\t * Maximum embedded file size\n\t */\n\t@Prop({attribute: \"max-file-size\"}) readonly maxFileSize: number = -1\n\t/**\n\t * Custom File identifier.\n\t */\n\t@Prop({attribute: \"identifier\"}) readonly identifier: string\n\t/**\n\t * Indicates the entered value does not conform to the format expected by the application.\n\t */\n\t@Prop() readonly invalid: boolean\n\t/**\n\t * Error message when the maximum file size is exceeded\n\t */\n\t@Prop({attribute: \"error-size\"}) readonly errorSize: string = \"Soubor je větší než povolená velikost {FILE_SIZE}\"\n\t/**\n\t * Insert unsupported file error message\n\t */\n\t@Prop({attribute: \"error-accept\"}) readonly errorAccept: string = \"Soubor tohoto typu není povolen\"\n\t/**\n\t * Adds accessible label for the remove button that is only shown for screen readers.\n\t */\n\t@Prop({attribute: \"accessible-remove-label\"}) readonly accessibleRemoveLabel: string = \"Odebrat soubor {FILE_NAME}\"\n\t/**\n\t * Adds accessible label for the list of attachments.\n\t */\n\t@Prop({attribute: \"accessible-attachments-label\"}) readonly accessibleAttachmentsLabel: string = \"Přílohy\"\n\t/**\n\t * Emitted when the File has focus.\n\t */\n\t@Event({eventName: \"gov-focus\"}) govFocus: EventEmitter<GovFormFileEvent>\n\t/**\n\t * Emitted when the File loses focus.\n\t */\n\t@Event({eventName: \"gov-blur\"}) govBlur: EventEmitter<GovFormFileEvent>\n\t/**\n\t * Called when the list of inserted files is changed\n\t */\n\t@Event({eventName: \"gov-files\"}) govFiles: EventEmitter<GovFormFileEvent>\n\t/**\n\t * Called when a new file is added\n\t */\n\t@Event({eventName: \"gov-add-file\"}) govAddFile: EventEmitter<GovFormFileEvent>\n\t/**\n\t * Called when a file is removed from the list\n\t */\n\t@Event({eventName: \"gov-remove-file\"}) govRemoveFile: EventEmitter<GovFormFileEvent>\n\n\n\t@Watch(\"disabled\")\n\t@Watch(\"invalid\")\n\twatchControlAttrs(): void {\n\t\tthis.passControlAttrs()\n\t}\n\n\t@State() files: GovFormFileItem[] = []\n\t@State() inheritedAttributes: Attributes = {}\n\n\n\n\tprivate passControlAttrs() {\n\t\tthis.f.passAttrToControl(\"invalid\", toBoolAttr(this.invalid))\n\t\tthis.f.passAttrToControl(\"disabled\", toBoolAttr(this.disabled))\n\t\tthis.f.passAttrToControl(\"type\", \"File\")\n\t}\n\n\n\tprivate registerListeners() {\n\t\tif (this.eventsRegistered) {\n\t\t\treturn\n\t\t}\n\t\tthis.eventsRegistered = true\n\n\t\tfunction highlight() {\n\t\t\tthis.areaRef.classList.add(\"highlight\")\n\t\t}\n\n\t\tfunction unhighlight() {\n\t\t\tthis.areaRef.classList.remove(\"highlight\")\n\t\t}\n\n\t\tthis.inputRef.addEventListener(\n\t\t\t\"change\",\n\t\t\te => {\n\t\t\t\te.preventDefault()\n\t\t\t\te.stopPropagation()\n\t\t\t\tconst files = (e.target as HTMLInputElement).files\n\t\t\t\tif (this.resetAfterPick) {\n\t\t\t\t\tif (files.length) {\n\t\t\t\t\t\tthis.validateFiles(files)\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tthis.validateFiles(files)\n\t\t\t\t}\n\t\t\t},\n\t\t\tfalse,\n\t\t)\n\n\t\tif (this.expanded) {\n\t\t\tconst events = [\"dragover\", \"dragleave\"]\n\t\t\tconst inEvents = [\"dragenter\", \"dragover\", \"mouseenter\"]\n\t\t\tconst outEvents = [\"dragleave\", \"mouseleave\"]\n\n\t\t\tevents.map(eventName => this.inputRef.addEventListener(eventName, this.preventDefaults.bind(this), false))\n\t\t\tinEvents.map(eventName => this.inputRef.addEventListener(eventName, highlight.bind(this), false))\n\t\t\toutEvents.forEach(eventName => this.inputRef.addEventListener(eventName, unhighlight.bind(this), false))\n\t\t}\n\t}\n\n\tpreventDefaults(e) {\n\t\te.preventDefault()\n\t\te.stopPropagation()\n\t}\n\n\thandleDrop(e: DragEvent) {\n\t\tconst dataTransfer = e.dataTransfer\n\t\tthis.validateFiles(dataTransfer.files)\n\t}\n\n\tprivate validateFiles(files: FileList) {\n\t\tlet filesBuffer: GovFormFileItem[] = []\n\t\tArray.from(files).map(file => {\n\t\t\tconst isFile = this.files.find(item => item.file.name === file.name && item.file.size === file.size) || null\n\t\t\tif (isFile === null || this.ignoreFileDuplicationCheck) {\n\t\t\t\tconst isSizeValid = typeof this.maxFileSize === \"number\" && this.maxFileSize > 0 ? fileSizeValidation(file, this.maxFileSize) : true\n\t\t\t\tconst isAcceptValid = fileAcceptValidation(file, this.accept)\n\t\t\t\tconst newFile = {\n\t\t\t\t\tid: createID(\"GovFormFile\"),\n\t\t\t\t\tfile,\n\t\t\t\t\tacceptValid: isAcceptValid,\n\t\t\t\t\tsizeValid: isSizeValid,\n\t\t\t\t}\n\t\t\t\tif (this.displayAttachments) {\n\t\t\t\t\tthis.files = [...this.files, newFile]\n\t\t\t\t} else {\n\t\t\t\t\tfilesBuffer = [...filesBuffer, newFile]\n\t\t\t\t}\n\t\t\t\tthis.govAddFile.emit({\n\t\t\t\t\tcomponent: FormFileClass.root,\n\t\t\t\t\tfile: newFile,\n\t\t\t\t})\n\t\t\t}\n\t\t})\n\n\t\tthis.govFiles.emit({\n\t\t\tcomponent: FormFileClass.root,\n\t\t\tfiles: filesBuffer.length ? filesBuffer : this.files,\n\t\t})\n\n\t\tif (this.resetAfterPick) {\n\t\t\tthis.reset().finally()\n\t\t}\n\t}\n\n\tcomponentDidLoad() {\n\t\tthis.attributeObserver = new AttributeObserver(this.host, (attributeName, newValue) => {\n\t\t\tthis.onAriaAttributeChange(attributeName, newValue);\n\t\t});\n\n\t\tthis.attributeObserver.startObserving(ariaAttributes);\n\t}\n\n\tcomponentWillLoad() {\n\t\tthis.f.passAttrToLabel(\"required\", String(this.required))\n\t\tthis.passControlAttrs()\n\t\tthis.inheritedAttributes = inheritAriaAttributes(this.host);\n\t}\n\n\tasync componentDidRender() {\n\t\tthis.registerListeners()\n\t}\n\n\tdisconnectedCallback() {\n\t\tthis.attributeObserver.stopObserving();\n\t}\n\n\tonAriaAttributeChange(attributeName: string, newValue: string) {\n\t\tthis.host.removeAttribute(attributeName)\n\t\tthis.inheritedAttributes = {...this.inheritedAttributes, [attributeName]: newValue};\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<Host class={this.h.classes([FormFileClass.root])}\n\t\t\t\t invalid={toBoolAttrIfDefined(this.invalid)}\n\t\t\t\t expanded={toBoolAttrIfDefined(this.expanded)}>\n\t\t\t\t<div class={FormFileClass.area} ref={el => (this.areaRef = el as HTMLDivElement)}>\n\t\t\t\t\t<slot/>\n\t\t\t\t\t<input\n\t\t\t\t\t\tclass={FormFileClass.input}\n\t\t\t\t\t\tref={el => (this.inputRef = el as HTMLInputElement)}\n\t\t\t\t\t\tid={this.identifier || this.fileId}\n\t\t\t\t\t\ttype=\"file\"\n\t\t\t\t\t\tname={this.name}\n\t\t\t\t\t\taccept={this.accept}\n\t\t\t\t\t\tmultiple={this.multiple}\n\t\t\t\t\t\tonChange={this.onChangeHandler.bind(this)}\n\t\t\t\t\t\tonFocus={this.onFocusHandler.bind(this)}\n\t\t\t\t\t\tonBlur={this.onBlurHandler.bind(this)}\n\t\t\t\t\t\trequired={this.required}\n\t\t\t\t\t\tdisabled={this.disabled}\n\t\t\t\t\t\t{...this.inheritedAttributes}\n\t\t\t\t\t\taria-required={toBoolAttrIfDefined(this.required)}\n\t\t\t\t\t\taria-invalid={toBoolAttrIfDefined(this.invalid)}\n\t\t\t\t\t\taria-disabled={toBoolAttrIfDefined(this.disabled)}\n\t\t\t\t\t/>\n\t\t\t\t</div>\n\n\t\t\t\t{this.h.hasSlot(\"attachments\") ? (\n\t\t\t\t\t<div class={FormFileClass.attachments}>\n\t\t\t\t\t\t<slot name={\"attachments\"}/>\n\t\t\t\t\t</div>\n\t\t\t\t) : null}\n\n\t\t\t\t{this.files.length && this.displayAttachments ? (\n\t\t\t\t\t<div class={FormFileClass.attachments}>\n\t\t\t\t\t\t<gov-attachments label={this.accessibleAttachmentsLabel}\n\t\t\t\t\t\t\t\t\t\t accessible-label={this.accessibleAttachmentsLabel}>\n\t\t\t\t\t\t\t{this.files.map(item => (\n\t\t\t\t\t\t\t\t<gov-attachments-item accessible-remove-labelledby={item.id}\n\t\t\t\t\t\t\t\t\t\t\t\t\t on-gov-remove={() => this.onRemoveFileHandler(item)}>\n\t\t\t\t\t\t\t\t\t<span class={\"sr-only\"} id={item.id}>\n\t\t\t\t\t\t\t\t\t\t{this.accessibleRemoveLabel.replace(\"{FILE_NAME}\", item.file.name)}\n\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t\t{item.file.name}\n\t\t\t\t\t\t\t\t\t{item.acceptValid === false ? (\n\t\t\t\t\t\t\t\t\t\t<gov-form-message slot=\"message\" color=\"error\">\n\t\t\t\t\t\t\t\t\t\t\t<gov-icon slot=\"icon\" name=\"exclamation-triangle-fill\" type=\"components\"></gov-icon>\n\t\t\t\t\t\t\t\t\t\t\t{item.acceptValid === false ? this.errorAccept : null}\n\t\t\t\t\t\t\t\t\t\t</gov-form-message>\n\t\t\t\t\t\t\t\t\t) : null}\n\t\t\t\t\t\t\t\t\t{item.sizeValid === false ? (\n\t\t\t\t\t\t\t\t\t\t<gov-form-message slot=\"message\" color=\"error\">\n\t\t\t\t\t\t\t\t\t\t\t<gov-icon slot=\"icon\" name=\"exclamation-triangle-fill\" type=\"components\"></gov-icon>\n\t\t\t\t\t\t\t\t\t\t\t{this.errorSize.replace(\"{FILE_SIZE}\", formatBytes(this.maxFileSize))}\n\t\t\t\t\t\t\t\t\t\t</gov-form-message>\n\t\t\t\t\t\t\t\t\t) : null}\n\t\t\t\t\t\t\t\t\t<span slot=\"info\">({formatBytes(item.file.size)})</span>\n\t\t\t\t\t\t\t\t</gov-attachments-item>\n\t\t\t\t\t\t\t))}\n\t\t\t\t\t\t</gov-attachments>\n\t\t\t\t\t</div>\n\t\t\t\t) : null}\n\t\t\t</Host>\n\t\t)\n\t}\n\n\tprivate onRemoveFileHandler(file: GovFormFileItem) {\n\t\tconst index = this.files.findIndex(item => item.id === file.id)\n\t\tif (index !== -1) {\n\t\t\tconst files = this.files\n\t\t\tconst removeFile = this.files[index]\n\t\t\tfiles.splice(index, 1)\n\t\t\tthis.files = [...files]\n\t\t\tthis.govRemoveFile.emit({\n\t\t\t\tcomponent: FormFileClass.root,\n\t\t\t\tfile: removeFile,\n\t\t\t})\n\t\t\tthis.govFiles.emit({\n\t\t\t\tcomponent: FormFileClass.root,\n\t\t\t\tfiles,\n\t\t\t})\n\t\t}\n\t}\n\n\tprivate onFocusHandler(e: FocusEvent) {\n\t\te.stopPropagation()\n\t\tthis.govFocus.emit({\n\t\t\tcomponent: FormFileClass.root,\n\t\t\toriginalEvent: e,\n\t\t})\n\t}\n\n\tprivate onBlurHandler(e: FocusEvent) {\n\t\te.stopPropagation()\n\t\tthis.govBlur.emit({\n\t\t\tcomponent: FormFileClass.root,\n\t\t\toriginalEvent: e,\n\t\t})\n\t}\n\n\tprivate onChangeHandler(e: Event) {\n\t\te.stopPropagation()\n\t}\n\n\t/**\n\t * Returns the reference of the native element\n\t */\n\t@Method()\n\tasync getRef(): Promise<HTMLInputElement> {\n\t\treturn this.inputRef\n\t}\n\n\t/**\n\t * Returns the reference of the native area element\n\t */\n\t@Method()\n\tasync getAreaRef(): Promise<HTMLDivElement> {\n\t\treturn this.areaRef\n\t}\n\n\t/**\n\t * Remove all files from component state\n\t */\n\t@Method()\n\tasync reset(): Promise<void> {\n\t\tthis.files = []\n\t\tthis.inputRef.value = '';\n\t}\n}\n"],"mappings":"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","ignoreList":[]}
1
+ {"version":3,"names":["FormFileClass","root","area","input","attachments","formatBytes","bytes","units","l","n","parseInt","toFixed","fileAcceptValidation","file","accept","length","replace","split","filter","RegExp","test","type","fileSizeValidation","maxSize","fileSize","Math","round","size","GovFormFile","proxyCustomElement","H","constructor","this","eventsRegistered","fileId","createID","h","govHost","host","f","govForm","watchControlAttrs","passControlAttrs","passAttrToControl","toBoolAttr","invalid","disabled","registerListeners","highlight","areaRef","classList","add","unhighlight","remove","inputRef","addEventListener","e","preventDefault","stopPropagation","files","target","resetAfterPick","validateFiles","expanded","events","inEvents","outEvents","map","eventName","preventDefaults","bind","forEach","handleDrop","dataTransfer","filesBuffer","Array","from","isFile","find","item","name","ignoreFileDuplicationCheck","isSizeValid","maxFileSize","isAcceptValid","newFile","id","acceptValid","sizeValid","displayAttachments","govAddFile","emit","component","govFiles","reset","finally","componentDidLoad","attributeObserver","AttributeObserver","attributeName","newValue","onAriaAttributeChange","startObserving","ariaAttributes","componentWillLoad","passAttrToLabel","String","required","inheritedAttributes","inheritAriaAttributes","componentDidRender","disconnectedCallback","stopObserving","removeAttribute","Object","assign","render","Host","key","class","classes","toBoolAttrIfDefined","ref","el","identifier","multiple","onChange","onChangeHandler","onFocus","onFocusHandler","onBlur","onBlurHandler","hasSlot","label","accessibleAttachmentsLabel","onRemoveFileHandler","accessibleRemoveLabel","slot","color","errorAccept","errorSize","index","findIndex","removeFile","splice","govRemoveFile","govFocus","originalEvent","govBlur","getRef","getAreaRef","value"],"sources":["../../../packages/core/src/components/gov-form/file/constants.ts","../../../packages/core/src/utils/file.utils.ts","../../../packages/core/src/components/gov-form/file/gov-form-file.tsx"],"sourcesContent":["export const FormFileClass = {\n\troot: 'gov-form-file',\n\tarea: 'gov-form-file__area',\n\tinput: 'gov-form-file__input',\n\tattachments: 'gov-form-file__attachments',\n}\n","export function formatBytes(bytes: any): string {\n\tconst units = ['bytes', 'KiB', 'MiB', 'GiB', 'TiB', 'PiB', 'EiB', 'ZiB', 'YiB']\n\tlet l = 0,\n\t\tn = parseInt(bytes, 10) || 0\n\n\twhile (n >= 1024 && ++l) {\n\t\tn = n / 1024\n\t}\n\n\treturn n.toFixed(n < 10 && l > 0 ? 1 : 0) + ' ' + units[l]\n}\n\nexport function fileAcceptValidation(file: File, accept: string): boolean {\n\tif (typeof accept === 'string' && accept.length) {\n\t\treturn (\n\t\t\taccept\n\t\t\t\t.replace(/\\s/g, '')\n\t\t\t\t.split(',')\n\t\t\t\t.filter(accept => {\n\t\t\t\t\treturn new RegExp(accept.replace('*', '.*')).test(file.type)\n\t\t\t\t}).length > 0\n\t\t)\n\t} else {\n\t\treturn true\n\t}\n}\n\nexport function fileSizeValidation(file: File, maxSize: number): boolean {\n\tconst fileSize = Math.round(file.size)\n\treturn fileSize <= maxSize\n}\n","import {Component, Element, Event, EventEmitter, h, Host, Method, Prop, State, Watch} from \"@stencil/core\"\nimport {createID} from \"../../../utils/string.utils\"\nimport {FormFileClass} from \"./constants\"\nimport {govHost, toBoolAttr, toBoolAttrIfDefined} from \"../../../helpers/Dom/template\"\nimport {fileAcceptValidation, fileSizeValidation, formatBytes} from \"../../../utils/file.utils\"\nimport {GovForm} from \"../../../helpers/Dom/form.types\"\nimport {GovHost} from \"../../../helpers/Dom/template.types\"\nimport {govForm} from \"../../../helpers/Dom/form\"\nimport {GovFormFileEvent, GovFormFileItem} from \"./gov-form-file.types\"\nimport {inheritAriaAttributes} from \"../../../helpers/Accessibility/accessibility\";\nimport {AttributeObserver, Attributes} from \"../../../helpers/Dom/attribute\";\nimport {ariaAttributes} from \"../../../helpers/Accessibility/attributes\";\n\n@Component({\n\ttag: \"gov-form-file\",\n})\nexport class GovFormFile {\n\tprivate f: GovForm\n\tprivate readonly h: GovHost\n\n\tprivate areaRef?: HTMLDivElement\n\tprivate inputRef?: HTMLInputElement\n\tprivate readonly fileId: string\n\tprivate attributeObserver: AttributeObserver\n\tprivate eventsRegistered = false\n\n\tconstructor() {\n\t\tthis.fileId = createID(\"GovInputFile\")\n\n\t\tthis.h = govHost(this.host)\n\t\tthis.f = govForm(this.h)\n\t}\n\n\t@Element() host: HTMLGovFormFileElement\n\t/**\n\t * Expands the file input to fill 100% of the container width.\n\t */\n\t@Prop() readonly expanded: boolean = false\n\t/**\n\t * Set whether the input is required or not. Please note that this is necessary for accessible inputs when the user is required to fill them.\n\t * When using this property you need to also set “novalidate” attribute to your form element to prevent browser from displaying its own validation errors.\n\t */\n\t@Prop() readonly required: boolean = false\n\t/**\n\t * Makes the File component disabled.\n\t * This prevents users from being able to interact with the File, and conveys its inactive state to assistive technologies.\n\t */\n\t@Prop({reflect: true}) readonly disabled: boolean = false\n\t/**\n\t * After selecting the files, the main input element will be reset.\n\t * The propagation of the event with the selected files will not be affected.\n\t */\n\t@Prop({attribute: \"reset-after-pick\"}) readonly resetAfterPick: boolean = false\n\t/**\n\t * Selected files will not be checked for duplicates based on name and size.\n\t */\n\t@Prop({attribute: \"ignore-file-duplication-check\"}) readonly ignoreFileDuplicationCheck: boolean = false\n\t/**\n\t * Show list of attachments\n\t */\n\t@Prop({attribute: \"display-attachments\"}) readonly displayAttachments: boolean = true\n\t/**\n\t * Name of the input.\n\t */\n\t@Prop() readonly name: string\n\t/**\n\t * Same as original parameter\n\t * @link https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/accept\n\t */\n\t@Prop() readonly accept: string\n\t/**\n\t * Same as original parameter\n\t * @link https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes/multiple\n\t */\n\t@Prop() readonly multiple: boolean = false\n\t/**\n\t * Maximum embedded file size\n\t */\n\t@Prop({attribute: \"max-file-size\"}) readonly maxFileSize: number = -1\n\t/**\n\t * Custom File identifier.\n\t */\n\t@Prop({attribute: \"identifier\"}) readonly identifier: string\n\t/**\n\t * Indicates the entered value does not conform to the format expected by the application.\n\t */\n\t@Prop() readonly invalid: boolean\n\t/**\n\t * Error message when the maximum file size is exceeded\n\t */\n\t@Prop({attribute: \"error-size\"}) readonly errorSize: string = \"Soubor je větší než povolená velikost {FILE_SIZE}\"\n\t/**\n\t * Insert unsupported file error message\n\t */\n\t@Prop({attribute: \"error-accept\"}) readonly errorAccept: string = \"Soubor tohoto typu není povolen\"\n\t/**\n\t * Adds accessible label for the remove button that is only shown for screen readers.\n\t */\n\t@Prop({attribute: \"accessible-remove-label\"}) readonly accessibleRemoveLabel: string = \"Odebrat soubor {FILE_NAME}\"\n\t/**\n\t * Adds accessible label for the list of attachments.\n\t */\n\t@Prop({attribute: \"accessible-attachments-label\"}) readonly accessibleAttachmentsLabel: string = \"Přílohy\"\n\t/**\n\t * Emitted when the File has focus.\n\t */\n\t@Event({eventName: \"gov-focus\"}) govFocus: EventEmitter<GovFormFileEvent>\n\t/**\n\t * Emitted when the File loses focus.\n\t */\n\t@Event({eventName: \"gov-blur\"}) govBlur: EventEmitter<GovFormFileEvent>\n\t/**\n\t * Called when the list of inserted files is changed\n\t */\n\t@Event({eventName: \"gov-files\"}) govFiles: EventEmitter<GovFormFileEvent>\n\t/**\n\t * Called when a new file is added\n\t */\n\t@Event({eventName: \"gov-add-file\"}) govAddFile: EventEmitter<GovFormFileEvent>\n\t/**\n\t * Called when a file is removed from the list\n\t */\n\t@Event({eventName: \"gov-remove-file\"}) govRemoveFile: EventEmitter<GovFormFileEvent>\n\n\n\t@Watch(\"disabled\")\n\t@Watch(\"invalid\")\n\twatchControlAttrs(): void {\n\t\tthis.passControlAttrs()\n\t}\n\n\t@State() files: GovFormFileItem[] = []\n\t@State() inheritedAttributes: Attributes = {}\n\n\n\n\tprivate passControlAttrs() {\n\t\tthis.f.passAttrToControl(\"invalid\", toBoolAttr(this.invalid))\n\t\tthis.f.passAttrToControl(\"disabled\", toBoolAttr(this.disabled))\n\t\tthis.f.passAttrToControl(\"type\", \"File\")\n\t}\n\n\n\tprivate registerListeners() {\n\t\tif (this.eventsRegistered) {\n\t\t\treturn\n\t\t}\n\t\tthis.eventsRegistered = true\n\n\t\tfunction highlight() {\n\t\t\tthis.areaRef.classList.add(\"highlight\")\n\t\t}\n\n\t\tfunction unhighlight() {\n\t\t\tthis.areaRef.classList.remove(\"highlight\")\n\t\t}\n\n\t\tthis.inputRef.addEventListener(\n\t\t\t\"change\",\n\t\t\te => {\n\t\t\t\te.preventDefault()\n\t\t\t\te.stopPropagation()\n\t\t\t\tconst files = (e.target as HTMLInputElement).files\n\t\t\t\tif (this.resetAfterPick) {\n\t\t\t\t\tif (files.length) {\n\t\t\t\t\t\tthis.validateFiles(files)\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tthis.validateFiles(files)\n\t\t\t\t}\n\t\t\t},\n\t\t\tfalse,\n\t\t)\n\n\t\tif (this.expanded) {\n\t\t\tconst events = [\"dragover\", \"dragleave\"]\n\t\t\tconst inEvents = [\"dragenter\", \"dragover\", \"mouseenter\"]\n\t\t\tconst outEvents = [\"dragleave\", \"mouseleave\"]\n\n\t\t\tevents.map(eventName => this.inputRef.addEventListener(eventName, this.preventDefaults.bind(this), false))\n\t\t\tinEvents.map(eventName => this.inputRef.addEventListener(eventName, highlight.bind(this), false))\n\t\t\toutEvents.forEach(eventName => this.inputRef.addEventListener(eventName, unhighlight.bind(this), false))\n\t\t}\n\t}\n\n\tpreventDefaults(e) {\n\t\te.preventDefault()\n\t\te.stopPropagation()\n\t}\n\n\thandleDrop(e: DragEvent) {\n\t\tconst dataTransfer = e.dataTransfer\n\t\tthis.validateFiles(dataTransfer.files)\n\t}\n\n\tprivate validateFiles(files: FileList) {\n\t\tlet filesBuffer: GovFormFileItem[] = []\n\t\tArray.from(files).map(file => {\n\t\t\tconst isFile = this.files.find(item => item.file.name === file.name && item.file.size === file.size) || null\n\t\t\tif (isFile === null || this.ignoreFileDuplicationCheck) {\n\t\t\t\tconst isSizeValid = typeof this.maxFileSize === \"number\" && this.maxFileSize > 0 ? fileSizeValidation(file, this.maxFileSize) : true\n\t\t\t\tconst isAcceptValid = fileAcceptValidation(file, this.accept)\n\t\t\t\tconst newFile = {\n\t\t\t\t\tid: createID(\"GovFormFile\"),\n\t\t\t\t\tfile,\n\t\t\t\t\tacceptValid: isAcceptValid,\n\t\t\t\t\tsizeValid: isSizeValid,\n\t\t\t\t}\n\t\t\t\tif (this.displayAttachments) {\n\t\t\t\t\tthis.files = [...this.files, newFile]\n\t\t\t\t} else {\n\t\t\t\t\tfilesBuffer = [...filesBuffer, newFile]\n\t\t\t\t}\n\t\t\t\tthis.govAddFile.emit({\n\t\t\t\t\tcomponent: FormFileClass.root,\n\t\t\t\t\tfile: newFile,\n\t\t\t\t})\n\t\t\t}\n\t\t})\n\n\t\tthis.govFiles.emit({\n\t\t\tcomponent: FormFileClass.root,\n\t\t\tfiles: filesBuffer.length ? filesBuffer : this.files,\n\t\t})\n\n\t\tif (this.resetAfterPick) {\n\t\t\tthis.reset().finally()\n\t\t}\n\t}\n\n\tcomponentDidLoad() {\n\t\tthis.attributeObserver = new AttributeObserver(this.host, (attributeName, newValue) => {\n\t\t\tthis.onAriaAttributeChange(attributeName, newValue);\n\t\t});\n\n\t\tthis.attributeObserver.startObserving(ariaAttributes);\n\t}\n\n\tcomponentWillLoad() {\n\t\tthis.f.passAttrToLabel(\"required\", String(this.required))\n\t\tthis.passControlAttrs()\n\t\tthis.inheritedAttributes = inheritAriaAttributes(this.host);\n\t}\n\n\tasync componentDidRender() {\n\t\tthis.registerListeners()\n\t}\n\n\tdisconnectedCallback() {\n\t\tthis.attributeObserver.stopObserving();\n\t}\n\n\tonAriaAttributeChange(attributeName: string, newValue: string) {\n\t\tthis.host.removeAttribute(attributeName)\n\t\tthis.inheritedAttributes = {...this.inheritedAttributes, [attributeName]: newValue};\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<Host class={this.h.classes([FormFileClass.root])}\n\t\t\t\t invalid={toBoolAttrIfDefined(this.invalid)}\n\t\t\t\t expanded={toBoolAttrIfDefined(this.expanded)}>\n\t\t\t\t<div class={FormFileClass.area} ref={el => (this.areaRef = el as HTMLDivElement)}>\n\t\t\t\t\t<slot/>\n\t\t\t\t\t<input\n\t\t\t\t\t\tclass={FormFileClass.input}\n\t\t\t\t\t\tref={el => (this.inputRef = el as HTMLInputElement)}\n\t\t\t\t\t\tid={this.identifier || this.fileId}\n\t\t\t\t\t\ttype=\"file\"\n\t\t\t\t\t\tname={this.name}\n\t\t\t\t\t\taccept={this.accept}\n\t\t\t\t\t\tmultiple={this.multiple}\n\t\t\t\t\t\tonChange={this.onChangeHandler.bind(this)}\n\t\t\t\t\t\tonFocus={this.onFocusHandler.bind(this)}\n\t\t\t\t\t\tonBlur={this.onBlurHandler.bind(this)}\n\t\t\t\t\t\trequired={this.required}\n\t\t\t\t\t\tdisabled={this.disabled}\n\t\t\t\t\t\t{...this.inheritedAttributes}\n\t\t\t\t\t\taria-required={toBoolAttrIfDefined(this.required)}\n\t\t\t\t\t\taria-invalid={toBoolAttrIfDefined(this.invalid)}\n\t\t\t\t\t\taria-disabled={toBoolAttrIfDefined(this.disabled)}\n\t\t\t\t\t/>\n\t\t\t\t</div>\n\n\t\t\t\t{this.h.hasSlot(\"attachments\") ? (\n\t\t\t\t\t<div class={FormFileClass.attachments}>\n\t\t\t\t\t\t<slot name={\"attachments\"}/>\n\t\t\t\t\t</div>\n\t\t\t\t) : null}\n\n\t\t\t\t{this.files.length && this.displayAttachments ? (\n\t\t\t\t\t<div class={FormFileClass.attachments}>\n\t\t\t\t\t\t<gov-attachments label={this.accessibleAttachmentsLabel}\n\t\t\t\t\t\t\t\t\t\t accessible-label={this.accessibleAttachmentsLabel}>\n\t\t\t\t\t\t\t{this.files.map(item => (\n\t\t\t\t\t\t\t\t<gov-attachments-item accessible-remove-labelledby={item.id}\n\t\t\t\t\t\t\t\t\t\t\t\t\t on-gov-remove={() => this.onRemoveFileHandler(item)}>\n\t\t\t\t\t\t\t\t\t<span class={\"sr-only\"} id={item.id}>\n\t\t\t\t\t\t\t\t\t\t{this.accessibleRemoveLabel.replace(\"{FILE_NAME}\", item.file.name)}\n\t\t\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t\t\t\t{item.file.name}\n\t\t\t\t\t\t\t\t\t{item.acceptValid === false ? (\n\t\t\t\t\t\t\t\t\t\t<gov-form-message slot=\"message\" color=\"error\">\n\t\t\t\t\t\t\t\t\t\t\t<gov-icon slot=\"icon\" name=\"exclamation-triangle-fill\" type=\"components\"></gov-icon>\n\t\t\t\t\t\t\t\t\t\t\t{item.acceptValid === false ? this.errorAccept : null}\n\t\t\t\t\t\t\t\t\t\t</gov-form-message>\n\t\t\t\t\t\t\t\t\t) : null}\n\t\t\t\t\t\t\t\t\t{item.sizeValid === false ? (\n\t\t\t\t\t\t\t\t\t\t<gov-form-message slot=\"message\" color=\"error\">\n\t\t\t\t\t\t\t\t\t\t\t<gov-icon slot=\"icon\" name=\"exclamation-triangle-fill\" type=\"components\"></gov-icon>\n\t\t\t\t\t\t\t\t\t\t\t{this.errorSize.replace(\"{FILE_SIZE}\", formatBytes(this.maxFileSize))}\n\t\t\t\t\t\t\t\t\t\t</gov-form-message>\n\t\t\t\t\t\t\t\t\t) : null}\n\t\t\t\t\t\t\t\t\t<span slot=\"info\">({formatBytes(item.file.size)})</span>\n\t\t\t\t\t\t\t\t</gov-attachments-item>\n\t\t\t\t\t\t\t))}\n\t\t\t\t\t\t</gov-attachments>\n\t\t\t\t\t</div>\n\t\t\t\t) : null}\n\t\t\t</Host>\n\t\t)\n\t}\n\n\tprivate onRemoveFileHandler(file: GovFormFileItem) {\n\t\tconst index = this.files.findIndex(item => item.id === file.id)\n\t\tif (index !== -1) {\n\t\t\tconst files = this.files\n\t\t\tconst removeFile = this.files[index]\n\t\t\tfiles.splice(index, 1)\n\t\t\tthis.files = [...files]\n\t\t\tthis.govRemoveFile.emit({\n\t\t\t\tcomponent: FormFileClass.root,\n\t\t\t\tfile: removeFile,\n\t\t\t})\n\t\t\tthis.govFiles.emit({\n\t\t\t\tcomponent: FormFileClass.root,\n\t\t\t\tfiles,\n\t\t\t})\n\t\t}\n\t}\n\n\tprivate onFocusHandler(e: FocusEvent) {\n\t\te.stopPropagation()\n\t\tthis.govFocus.emit({\n\t\t\tcomponent: FormFileClass.root,\n\t\t\toriginalEvent: e,\n\t\t})\n\t}\n\n\tprivate onBlurHandler(e: FocusEvent) {\n\t\te.stopPropagation()\n\t\tthis.govBlur.emit({\n\t\t\tcomponent: FormFileClass.root,\n\t\t\toriginalEvent: e,\n\t\t})\n\t}\n\n\tprivate onChangeHandler(e: Event) {\n\t\te.stopPropagation()\n\t}\n\n\t/**\n\t * Returns the reference of the native element\n\t */\n\t@Method()\n\tasync getRef(): Promise<HTMLInputElement> {\n\t\treturn this.inputRef\n\t}\n\n\t/**\n\t * Returns the reference of the native area element\n\t */\n\t@Method()\n\tasync getAreaRef(): Promise<HTMLDivElement> {\n\t\treturn this.areaRef\n\t}\n\n\t/**\n\t * Remove all files from component state\n\t */\n\t@Method()\n\tasync reset(): Promise<void> {\n\t\tthis.files = []\n\t\tthis.inputRef.value = '';\n\t}\n}\n"],"mappings":"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","ignoreList":[]}
@@ -1,2 +1,2 @@
1
- import{p as t,H as e,h as a,d as i}from"./p-115b9cf3.js";import{a as s,b as o,c as r}from"./p-e44a0fee.js";import{g as n}from"./p-ea7fdd2e.js";import{v as c}from"./p-0b3574c2.js";const f=t(class t extends e{constructor(){super();this.__registerHost();this.gap=undefined;this.orientation="vertical";this.h=n(this.host)}validateGap(t){if(t){c(o,t,s.root)}}validateOrientation(t){if(t){c(r,t,s.root)}}componentWillLoad(){this.validateGap(this.gap);this.validateOrientation(this.orientation)}render(){return a(i,{key:"b7a379997ac1f4080471c42c23cad6f0ed055fd7",gap:this.gap,class:this.h.classes(s.root)},a("slot",{key:"a36809822e81913ec6c8cabdee9eaf64c9f9f471"}))}get host(){return this}static get watchers(){return{gap:["validateGap"],orientation:["validateOrientation"]}}},[4,"gov-form-group",{gap:[1],orientation:[1]},undefined,{gap:["validateGap"],orientation:["validateOrientation"]}]);function p(){if(typeof customElements==="undefined"){return}const t=["gov-form-group"];t.forEach((t=>{switch(t){case"gov-form-group":if(!customElements.get(t)){customElements.define(t,f)}break}}))}p();const d=f;const m=p;export{d as GovFormGroup,m as defineCustomElement};
1
+ import{p as t,H as e,h as a,d as i}from"./p-42200001.js";import{a as s,b as o,c as r}from"./p-e44a0fee.js";import{g as n}from"./p-ea7fdd2e.js";import{v as c}from"./p-0b3574c2.js";const f=t(class t extends e{constructor(){super();this.__registerHost();this.gap=undefined;this.orientation="vertical";this.h=n(this.host)}validateGap(t){if(t){c(o,t,s.root)}}validateOrientation(t){if(t){c(r,t,s.root)}}componentWillLoad(){this.validateGap(this.gap);this.validateOrientation(this.orientation)}render(){return a(i,{key:"b7a379997ac1f4080471c42c23cad6f0ed055fd7",gap:this.gap,class:this.h.classes(s.root)},a("slot",{key:"a36809822e81913ec6c8cabdee9eaf64c9f9f471"}))}get host(){return this}static get watchers(){return{gap:["validateGap"],orientation:["validateOrientation"]}}},[4,"gov-form-group",{gap:[1],orientation:[1]},undefined,{gap:["validateGap"],orientation:["validateOrientation"]}]);function p(){if(typeof customElements==="undefined"){return}const t=["gov-form-group"];t.forEach((t=>{switch(t){case"gov-form-group":if(!customElements.get(t)){customElements.define(t,f)}break}}))}p();const d=f;const m=p;export{d as GovFormGroup,m as defineCustomElement};
2
2
  //# sourceMappingURL=gov-form-group.js.map
@@ -1,2 +1,2 @@
1
- import{G as o,d as s}from"./p-884d8f16.js";const t=o;const p=s;export{t as GovFormInput,p as defineCustomElement};
1
+ import{G as o,d as s}from"./p-c5e91e5a.js";const t=o;const a=s;export{t as GovFormInput,a as defineCustomElement};
2
2
  //# sourceMappingURL=gov-form-input.js.map
@@ -1,2 +1,2 @@
1
- import{p as s,H as e,c as t,h as c,d as o}from"./p-115b9cf3.js";import{F as i}from"./p-7ba4daf4.js";const a=s(class s extends e{constructor(){super();this.__registerHost();this.govClick=t(this,"gov-click",7);this.identifier=undefined;this.size="m";this.required=false;this.legend=false}render(){const s=this.legend?"legend":"label";return c(o,{key:"3f52c93a7721a458d430874b447421f7a5d30a41",class:i.root,size:this.size},c(s,{key:"c122a9bce9b9a98b0c8c336190b70bc4bf5389cf",class:i.label,htmlFor:this.identifier,onClick:()=>this.govClick.emit()},c("slot",{key:"de892d47334dbd3448a33d18586c77248b08b036"}),this.required?c("span",{class:"gov-color--error-500"}," *"):null))}},[4,"gov-form-label",{identifier:[1],size:[1],required:[4],legend:[4]}]);function l(){if(typeof customElements==="undefined"){return}const s=["gov-form-label"];s.forEach((s=>{switch(s){case"gov-form-label":if(!customElements.get(s)){customElements.define(s,a)}break}}))}l();const r=a;const n=l;export{r as GovFormLabel,n as defineCustomElement};
1
+ import{p as s,H as e,c as t,h as o,d as c}from"./p-42200001.js";import{F as i}from"./p-7ba4daf4.js";const a=s(class s extends e{constructor(){super();this.__registerHost();this.govClick=t(this,"gov-click",7);this.identifier=undefined;this.size="m";this.required=false;this.legend=false}render(){const s=this.legend?"legend":"label";return o(c,{key:"3f52c93a7721a458d430874b447421f7a5d30a41",class:i.root,size:this.size},o(s,{key:"c122a9bce9b9a98b0c8c336190b70bc4bf5389cf",class:i.label,htmlFor:this.identifier,onClick:()=>this.govClick.emit()},o("slot",{key:"de892d47334dbd3448a33d18586c77248b08b036"}),this.required?o("span",{class:"gov-color--error-500"}," *"):null))}},[4,"gov-form-label",{identifier:[1],size:[1],required:[4],legend:[4]}]);function l(){if(typeof customElements==="undefined"){return}const s=["gov-form-label"];s.forEach((s=>{switch(s){case"gov-form-label":if(!customElements.get(s)){customElements.define(s,a)}break}}))}l();const r=a;const n=l;export{r as GovFormLabel,n as defineCustomElement};
2
2
  //# sourceMappingURL=gov-form-label.js.map
@@ -1,2 +1,2 @@
1
- import{G as o,d as s}from"./p-8ee6f2f3.js";const t=o;const e=s;export{t as GovFormMessage,e as defineCustomElement};
1
+ import{G as o,d as s}from"./p-c438a723.js";const t=o;const a=s;export{t as GovFormMessage,a as defineCustomElement};
2
2
  //# sourceMappingURL=gov-form-message.js.map
@@ -1,2 +1,2 @@
1
- import{p as t,H as e,c as i,h as s,d as o}from"./p-115b9cf3.js";import{g as n,h as a,i as h}from"./p-9908b9f0.js";import{g as l,c as r,t as c}from"./p-ea7fdd2e.js";import{v as d}from"./p-0b3574c2.js";import{c as u,r as f}from"./p-cd6c2938.js";import{p as m}from"./p-ded281e6.js";import{t as v}from"./p-26618322.js";import{A as p,a as g}from"./p-33d5d1ed.js";import{d as b}from"./p-9b0f446d.js";import{d as y}from"./p-8f40dfec.js";import{d as k}from"./p-884d8f16.js";import{d as j}from"./p-7f0c6ba3.js";import{d as w}from"./p-350e060c.js";const O=t(class t extends e{constructor(){super();this.__registerHost();this.govFocus=i(this,"gov-focus",7);this.govBlur=i(this,"gov-blur",7);this.govChange=i(this,"gov-change",7);this.govSelect=i(this,"gov-select",7);this.govRemove=i(this,"gov-remove",7);this.value=undefined;this.options=undefined;this.identifier=undefined;this.placeholder=undefined;this.size="m";this.name=undefined;this.hideSelectedList=false;this.required=false;this.disabled=false;this.invalid=undefined;this.success=undefined;this.messageEmpty="Nebyly nalezeny žádné výsledky";this.messageLoading="Načítám...";this.focused=undefined;this.valueState=undefined;this.selectedOptionsState=[];this.optionsState=[];this.inheritedAttributes={};this.selectId=u("GovSelect");this.listId=u("GovMultiList");this.h=l(this.host);this.f=n(this.h)}validateSize(t){d(h,t,a.root)}watchOptions(t){this.optionsState=m(t)}watchValue(t){this.selectedOptionsState=m(t)}componentDidLoad(){this.attributeObserver=new p(this.host,((t,e)=>{this.onAriaAttributeChange(t,e)}));this.attributeObserver.startObserving(g);this.initAutocomplete()}componentWillLoad(){this.validateSize(this.size);this.optionsState=m(this.options);this.selectedOptionsState=m(this.value)}disconnectedCallback(){this.attributeObserver.stopObserving()}onAriaAttributeChange(t,e){this.host.removeAttribute(t);this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{[t]:e})}getAvailableOptions(t=false){if(Array.isArray(this.optionsState)&&this.optionsState.length){if(t){return this.optionsState}return this.optionsState.filter((t=>{const e=this.selectedValueIndex(t.value);return e!==-1||(t===null||t===void 0?void 0:t.disabled)?false:true})).map((t=>{var e;return{name:(e=t.label)!==null&&e!==void 0?e:t.value,value:t.value}}))}return Array.from(this.selectRef.querySelectorAll("option")).filter((e=>{if(t){return true}const i=this.selectedValueIndex(e.value);return!(e.disabled||e.selected||i>-1)})).map((t=>({name:t.textContent,value:t.value})))}initAutocomplete(){var t,e,i,s,o;(t=this.autocompleteRef)===null||t===void 0?void 0:t.addEventListener("gov-select",this.onSelectHandler.bind(this));(e=this.autocompleteRef)===null||e===void 0?void 0:e.addEventListener("gov-input",this.onInputHandler.bind(this));(i=this.autocompleteRef)===null||i===void 0?void 0:i.addEventListener("gov-focus",this.onFocusHandler.bind(this));(s=this.autocompleteRef)===null||s===void 0?void 0:s.addEventListener("gov-blur",this.onBlurHandler.bind(this));(o=this.autocompleteRef)===null||o===void 0?void 0:o.setSearchCallback((t=>new Promise((e=>{const i=this.getAvailableOptions();if(String(t).length===0){return e(i)}e(i.filter((({label:e,value:i})=>{if(!e)e=i;return f(e).toLowerCase().indexOf(f(t).toLowerCase())>-1})))})))).finally()}selectedValueIndex(t){return this.selectedOptionsState.findIndex((e=>e===t))}getOptionElement(t){return this.selectRef.querySelector('option[value="'+t+'"]')}getOption(t){var e;return(e=this.getAvailableOptions(true).find((e=>e.value===t)))!==null&&e!==void 0?e:null}selectOption(t,e=true){const i=this.selectedValueIndex(t);if(i===-1){this.selectedOptionsState=[...this.selectedOptionsState,t];this.value=this.selectedOptionsState;if(e){this.govChange.emit({component:a.root,value:this.selectedOptionsState});this.govSelect.emit({component:a.root,value:this.selectedOptionsState})}const i=this.getOptionElement(t);if(i){i.selected=true}}}removeOption(t,e=true){const i=this.selectedValueIndex(t);if(i!==-1){this.selectedOptionsState.splice(i,1);this.selectedOptionsState=[...this.selectedOptionsState];this.value=this.selectedOptionsState;if(e){this.govChange.emit({component:a.root,value:this.selectedOptionsState});this.govRemove.emit({component:a.root,value:this.selectedOptionsState})}const s=this.getOptionElement(t);if(s){s.selected=false}}}async componentDidRender(){this.f.passAttrToLabel("required",String(this.required));v((()=>{this.selectRef.querySelectorAll("option").forEach((t=>{if(t.selected){this.selectOption(t.value,false)}}))}))}render(){return s(o,{key:"e112f9d20d170e70616fd4f089b93dd040e737fa",class:a.root,size:this.size},s("div",{key:"ffc5af48051e7d24559e0c77a595b48e287771f5",class:a.wrap},this.h.hasSlot("prefix")&&s("slot",{key:"3c22442cfbcb010f240a014ba7c9c48ec4522555",name:"prefix"}),s("gov-form-autocomplete",{key:"c02857a7ea06c203aa94b317837ea2c7c921b505",value:this.valueState,disabled:this.disabled,identifier:this.identifier||this.selectId,required:false,invalid:this.invalid,success:this.success,size:this.size,placeholder:this.placeholder,"message-empty":this.messageEmpty,"message-loading":this.messageLoading,ref:t=>this.autocompleteRef=t,minlength:0,"aria-owns":this.listId},this.success&&s("gov-icon",{key:"2b06057b6343fce21d08731f5a6675ffccfa3f6e",slot:"validation-icon",class:"validation-icon",name:"check-lg",type:"components"}),this.invalid&&s("gov-icon",{key:"6f33cb3764c0df058b0743ba617c950cf7909cdc",slot:"validation-icon",class:"validation-icon",name:"exclamation-lg",type:"components"}),s("gov-icon",{key:"05be66ee199dee177d0b18a7a6a59e25a724571f",slot:"icon-end",class:"arrow-icon",name:"chevron-down",type:"components"})),s("select",Object.assign({key:"d50fe47c2c859561b8aba62e6d6dedd7bceed6ae",hidden:true,class:"hidden-select-list","aria-hidden":r(true),multiple:true,required:this.required,name:this.name,disabled:this.disabled,ref:t=>this.selectRef=t},this.inheritedAttributes,{"aria-disabled":c(this.disabled),"aria-required":c(this.required),"aria-invalid":c(this.invalid)}),s("slot",{key:"cf2ebfd8dc2cdf49c3581ba0ba3fff959a50a221"}),Array.isArray(this.optionsState)&&this.optionsState.map((t=>{var e;const i=this.selectedValueIndex(t.value);return s("option",{value:t.value,selected:i>-1,disabled:t===null||t===void 0?void 0:t.disabled},(e=t.label)!==null&&e!==void 0?e:t.value)}))),this.h.hasSlot("sufix")&&s("slot",{key:"dddc8a99daeb345be9d778ade22622ae9ed35769",name:"sufix"})),this.hideSelectedList===false?s("ul",{role:"listbox",id:this.listId,class:a.list},Array.isArray(this.selectedOptionsState)&&this.selectedOptionsState.map((t=>{var e,i;const o=this.getOption(t);if(!o)return null;return s("li",{class:a.item,role:"option"},(e=o.label)!==null&&e!==void 0?e:o.value,s("gov-button",{"aria-label":(i="Odebrat vybranou položku "+o.label)!==null&&i!==void 0?i:o.value,color:"primary",type:"base",size:this.size,"on-gov-click":()=>this.onTagRemove(t)},s("gov-icon",{name:"x-lg",type:"components"})))}))):null)}onFocusHandler(t){t.stopPropagation();this.focused=true;this.govFocus.emit({component:a.root,originalEvent:t,value:this.selectedOptionsState})}onBlurHandler(t){t.stopPropagation();t.stopPropagation();this.focused=false;this.govBlur.emit({component:a.root,originalEvent:t,value:this.selectedOptionsState})}onInputHandler(t){this.valueState=t.detail.value;t.stopPropagation()}onSelectHandler(t){t.stopPropagation();const e=t.detail.selected;this.selectOption(e.value);this.valueState="";this.autocompleteRef.clearValue().finally();this.autocompleteRef.focus()}onTagRemove(t){this.removeOption(t)}async setFocus(t){return this.selectRef.focus(t)}async setValue(t){this.valueState=t}async getRef(){return this.selectRef}get host(){return this}static get watchers(){return{size:["validateSize"],options:["watchOptions"],value:["watchValue"]}}},[4,"gov-form-multi-select",{value:[1537],options:[1537],identifier:[1],placeholder:[1],size:[1],name:[1],hideSelectedList:[4,"hide-selected-list"],required:[4],disabled:[516],invalid:[516],success:[4],messageEmpty:[1,"message-empty"],messageLoading:[1,"message-loading"],focused:[32],valueState:[32],selectedOptionsState:[32],optionsState:[32],inheritedAttributes:[32],setFocus:[64],setValue:[64],getRef:[64]},undefined,{size:["validateSize"],options:["watchOptions"],value:["watchValue"]}]);function E(){if(typeof customElements==="undefined"){return}const t=["gov-form-multi-select","gov-button","gov-form-autocomplete","gov-form-input","gov-icon","gov-skeleton"];t.forEach((t=>{switch(t){case"gov-form-multi-select":if(!customElements.get(t)){customElements.define(t,O)}break;case"gov-button":if(!customElements.get(t)){b()}break;case"gov-form-autocomplete":if(!customElements.get(t)){y()}break;case"gov-form-input":if(!customElements.get(t)){k()}break;case"gov-icon":if(!customElements.get(t)){j()}break;case"gov-skeleton":if(!customElements.get(t)){w()}break}}))}E();const S=O;const x=E;export{S as GovFormMultiSelect,x as defineCustomElement};
1
+ import{p as t,H as e,c as i,h as s,d as o}from"./p-42200001.js";import{g as a,h as n,i as h}from"./p-9908b9f0.js";import{g as l,c as r,t as c}from"./p-ea7fdd2e.js";import{v as d}from"./p-0b3574c2.js";import{c as u,r as f}from"./p-cd6c2938.js";import{p as m}from"./p-ded281e6.js";import{t as v}from"./p-26618322.js";import{A as p,a as b}from"./p-33d5d1ed.js";import{d as g}from"./p-558cbab0.js";import{d as y}from"./p-4faecdb2.js";import{d as k}from"./p-c5e91e5a.js";import{d as j}from"./p-a877bf8a.js";import{d as w}from"./p-b97d8edd.js";const O=t(class t extends e{constructor(){super();this.__registerHost();this.govFocus=i(this,"gov-focus",7);this.govBlur=i(this,"gov-blur",7);this.govChange=i(this,"gov-change",7);this.govSelect=i(this,"gov-select",7);this.govRemove=i(this,"gov-remove",7);this.value=undefined;this.options=undefined;this.identifier=undefined;this.placeholder=undefined;this.size="m";this.name=undefined;this.hideSelectedList=false;this.required=false;this.disabled=false;this.invalid=undefined;this.success=undefined;this.messageEmpty="Nebyly nalezeny žádné výsledky";this.messageLoading="Načítám...";this.focused=undefined;this.valueState=undefined;this.selectedOptionsState=[];this.optionsState=[];this.inheritedAttributes={};this.selectId=u("GovSelect");this.listId=u("GovMultiList");this.h=l(this.host);this.f=a(this.h)}validateSize(t){d(h,t,n.root)}watchOptions(t){this.optionsState=m(t)}watchValue(t){this.selectedOptionsState=m(t)}componentDidLoad(){this.attributeObserver=new p(this.host,((t,e)=>{this.onAriaAttributeChange(t,e)}));this.attributeObserver.startObserving(b);this.initAutocomplete()}componentWillLoad(){this.validateSize(this.size);this.optionsState=m(this.options);this.selectedOptionsState=m(this.value)}disconnectedCallback(){this.attributeObserver.stopObserving()}onAriaAttributeChange(t,e){this.host.removeAttribute(t);this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{[t]:e})}getAvailableOptions(t=false){if(Array.isArray(this.optionsState)&&this.optionsState.length){if(t){return this.optionsState}return this.optionsState.filter((t=>{const e=this.selectedValueIndex(t.value);return e!==-1||(t===null||t===void 0?void 0:t.disabled)?false:true})).map((t=>{var e;return{name:(e=t.label)!==null&&e!==void 0?e:t.value,value:t.value}}))}return Array.from(this.selectRef.querySelectorAll("option")).filter((e=>{if(t){return true}const i=this.selectedValueIndex(e.value);return!(e.disabled||e.selected||i>-1)})).map((t=>({name:t.textContent,value:t.value})))}initAutocomplete(){var t,e,i,s,o;(t=this.autocompleteRef)===null||t===void 0?void 0:t.addEventListener("gov-select",this.onSelectHandler.bind(this));(e=this.autocompleteRef)===null||e===void 0?void 0:e.addEventListener("gov-input",this.onInputHandler.bind(this));(i=this.autocompleteRef)===null||i===void 0?void 0:i.addEventListener("gov-focus",this.onFocusHandler.bind(this));(s=this.autocompleteRef)===null||s===void 0?void 0:s.addEventListener("gov-blur",this.onBlurHandler.bind(this));(o=this.autocompleteRef)===null||o===void 0?void 0:o.setSearchCallback((t=>new Promise((e=>{const i=this.getAvailableOptions();if(String(t).length===0){return e(i)}e(i.filter((({label:e,value:i})=>{if(!e)e=i;return f(e).toLowerCase().indexOf(f(t).toLowerCase())>-1})))})))).finally()}selectedValueIndex(t){return this.selectedOptionsState.findIndex((e=>e===t))}getOptionElement(t){return this.selectRef.querySelector('option[value="'+t+'"]')}getOption(t){var e;return(e=this.getAvailableOptions(true).find((e=>e.value===t)))!==null&&e!==void 0?e:null}selectOption(t,e=true){const i=this.selectedValueIndex(t);if(i===-1){this.selectedOptionsState=[...this.selectedOptionsState,t];this.value=this.selectedOptionsState;if(e){this.govChange.emit({component:n.root,value:this.selectedOptionsState});this.govSelect.emit({component:n.root,value:this.selectedOptionsState})}const i=this.getOptionElement(t);if(i){i.selected=true}}}removeOption(t,e=true){const i=this.selectedValueIndex(t);if(i!==-1){this.selectedOptionsState.splice(i,1);this.selectedOptionsState=[...this.selectedOptionsState];this.value=this.selectedOptionsState;if(e){this.govChange.emit({component:n.root,value:this.selectedOptionsState});this.govRemove.emit({component:n.root,value:this.selectedOptionsState})}const s=this.getOptionElement(t);if(s){s.selected=false}}}async componentDidRender(){this.f.passAttrToLabel("required",String(this.required));v((()=>{this.selectRef.querySelectorAll("option").forEach((t=>{if(t.selected){this.selectOption(t.value,false)}}))}))}render(){return s(o,{key:"e112f9d20d170e70616fd4f089b93dd040e737fa",class:n.root,size:this.size},s("div",{key:"ffc5af48051e7d24559e0c77a595b48e287771f5",class:n.wrap},this.h.hasSlot("prefix")&&s("slot",{key:"3c22442cfbcb010f240a014ba7c9c48ec4522555",name:"prefix"}),s("gov-form-autocomplete",{key:"c02857a7ea06c203aa94b317837ea2c7c921b505",value:this.valueState,disabled:this.disabled,identifier:this.identifier||this.selectId,required:false,invalid:this.invalid,success:this.success,size:this.size,placeholder:this.placeholder,"message-empty":this.messageEmpty,"message-loading":this.messageLoading,ref:t=>this.autocompleteRef=t,minlength:0,"aria-owns":this.listId},this.success&&s("gov-icon",{key:"2b06057b6343fce21d08731f5a6675ffccfa3f6e",slot:"validation-icon",class:"validation-icon",name:"check-lg",type:"components"}),this.invalid&&s("gov-icon",{key:"6f33cb3764c0df058b0743ba617c950cf7909cdc",slot:"validation-icon",class:"validation-icon",name:"exclamation-lg",type:"components"}),s("gov-icon",{key:"05be66ee199dee177d0b18a7a6a59e25a724571f",slot:"icon-end",class:"arrow-icon",name:"chevron-down",type:"components"})),s("select",Object.assign({key:"d50fe47c2c859561b8aba62e6d6dedd7bceed6ae",hidden:true,class:"hidden-select-list","aria-hidden":r(true),multiple:true,required:this.required,name:this.name,disabled:this.disabled,ref:t=>this.selectRef=t},this.inheritedAttributes,{"aria-disabled":c(this.disabled),"aria-required":c(this.required),"aria-invalid":c(this.invalid)}),s("slot",{key:"cf2ebfd8dc2cdf49c3581ba0ba3fff959a50a221"}),Array.isArray(this.optionsState)&&this.optionsState.map((t=>{var e;const i=this.selectedValueIndex(t.value);return s("option",{value:t.value,selected:i>-1,disabled:t===null||t===void 0?void 0:t.disabled},(e=t.label)!==null&&e!==void 0?e:t.value)}))),this.h.hasSlot("sufix")&&s("slot",{key:"dddc8a99daeb345be9d778ade22622ae9ed35769",name:"sufix"})),this.hideSelectedList===false?s("ul",{role:"listbox",id:this.listId,class:n.list},Array.isArray(this.selectedOptionsState)&&this.selectedOptionsState.map((t=>{var e,i;const o=this.getOption(t);if(!o)return null;return s("li",{class:n.item,role:"option"},(e=o.label)!==null&&e!==void 0?e:o.value,s("gov-button",{"aria-label":(i="Odebrat vybranou položku "+o.label)!==null&&i!==void 0?i:o.value,color:"primary",type:"base",size:this.size,"on-gov-click":()=>this.onTagRemove(t)},s("gov-icon",{name:"x-lg",type:"components"})))}))):null)}onFocusHandler(t){t.stopPropagation();this.focused=true;this.govFocus.emit({component:n.root,originalEvent:t,value:this.selectedOptionsState})}onBlurHandler(t){t.stopPropagation();t.stopPropagation();this.focused=false;this.govBlur.emit({component:n.root,originalEvent:t,value:this.selectedOptionsState})}onInputHandler(t){this.valueState=t.detail.value;t.stopPropagation()}onSelectHandler(t){t.stopPropagation();const e=t.detail.selected;this.selectOption(e.value);this.valueState="";this.autocompleteRef.clearValue().finally();this.autocompleteRef.focus()}onTagRemove(t){this.removeOption(t)}async setFocus(t){return this.selectRef.focus(t)}async setValue(t){this.valueState=t}async getRef(){return this.selectRef}get host(){return this}static get watchers(){return{size:["validateSize"],options:["watchOptions"],value:["watchValue"]}}},[4,"gov-form-multi-select",{value:[1537],options:[1537],identifier:[1],placeholder:[1],size:[1],name:[1],hideSelectedList:[4,"hide-selected-list"],required:[4],disabled:[516],invalid:[516],success:[4],messageEmpty:[1,"message-empty"],messageLoading:[1,"message-loading"],focused:[32],valueState:[32],selectedOptionsState:[32],optionsState:[32],inheritedAttributes:[32],setFocus:[64],setValue:[64],getRef:[64]},undefined,{size:["validateSize"],options:["watchOptions"],value:["watchValue"]}]);function E(){if(typeof customElements==="undefined"){return}const t=["gov-form-multi-select","gov-button","gov-form-autocomplete","gov-form-input","gov-icon","gov-skeleton"];t.forEach((t=>{switch(t){case"gov-form-multi-select":if(!customElements.get(t)){customElements.define(t,O)}break;case"gov-button":if(!customElements.get(t)){g()}break;case"gov-form-autocomplete":if(!customElements.get(t)){y()}break;case"gov-form-input":if(!customElements.get(t)){k()}break;case"gov-icon":if(!customElements.get(t)){j()}break;case"gov-skeleton":if(!customElements.get(t)){w()}break}}))}E();const S=O;const x=E;export{S as GovFormMultiSelect,x as defineCustomElement};
2
2
  //# sourceMappingURL=gov-form-multi-select.js.map
@@ -1,2 +1,2 @@
1
- import{p as e,H as s,h as o,d as c}from"./p-115b9cf3.js";const a={root:"gov-form-password-power",bar:"gov-form-password-power__bar",text:"gov-form-password-power__text"};const r=e(class e extends s{constructor(){super();this.__registerHost();this.power=undefined}render(){return o(c,{key:"ca17606a7f29175d97da93daed3005a27b38d607",class:a.root},o("span",{key:"b2b80382c10034b88adb971db02c7e3f901453ee",class:a.bar},o("span",{key:"0c0de35b5c257c175281792765d3fec89f5ee498"}),o("span",{key:"92847bc51174d38543a2e0f9a1a7c3ba37fec6f4"}),o("span",{key:"7cc7a9cbda4c54c4d1269874a1f8d2b91e533bad"})),o("span",{key:"de62cf845c51d870e4fa1b1b6156348be8460d6b",class:a.text},o("slot",{key:"8132df44d6ce3f83f89d1d45b34c182850663571"})))}},[4,"gov-form-password-power",{power:[514]}]);function d(){if(typeof customElements==="undefined"){return}const e=["gov-form-password-power"];e.forEach((e=>{switch(e){case"gov-form-password-power":if(!customElements.get(e)){customElements.define(e,r)}break}}))}d();const t=r;const f=d;export{t as GovFormPasswordPower,f as defineCustomElement};
1
+ import{p as e,H as s,h as o,d as a}from"./p-42200001.js";const c={root:"gov-form-password-power",bar:"gov-form-password-power__bar",text:"gov-form-password-power__text"};const r=e(class e extends s{constructor(){super();this.__registerHost();this.power=undefined}render(){return o(a,{key:"ca17606a7f29175d97da93daed3005a27b38d607",class:c.root},o("span",{key:"b2b80382c10034b88adb971db02c7e3f901453ee",class:c.bar},o("span",{key:"0c0de35b5c257c175281792765d3fec89f5ee498"}),o("span",{key:"92847bc51174d38543a2e0f9a1a7c3ba37fec6f4"}),o("span",{key:"7cc7a9cbda4c54c4d1269874a1f8d2b91e533bad"})),o("span",{key:"de62cf845c51d870e4fa1b1b6156348be8460d6b",class:c.text},o("slot",{key:"8132df44d6ce3f83f89d1d45b34c182850663571"})))}},[4,"gov-form-password-power",{power:[514]}]);function d(){if(typeof customElements==="undefined"){return}const e=["gov-form-password-power"];e.forEach((e=>{switch(e){case"gov-form-password-power":if(!customElements.get(e)){customElements.define(e,r)}break}}))}d();const t=r;const f=d;export{t as GovFormPasswordPower,f as defineCustomElement};
2
2
  //# sourceMappingURL=gov-form-password-power.js.map
@@ -1,2 +1,2 @@
1
- import{p as o,H as r,c as a,h as g,d as e}from"./p-115b9cf3.js";import{d as i,a as t,b as p,c as n}from"./p-e44a0fee.js";import{g as m}from"./p-ea7fdd2e.js";import{v as l}from"./p-0b3574c2.js";import{t as f}from"./p-26618322.js";const v="gov-form-group,.gov-form-group,gov-form-radio-group,.gov-form-radio-group,gov-form-checkbox-group,.gov-form-checkbox-group{margin-top:0;margin-bottom:0;position:relative;display:flex;width:100%;flex-direction:column;align-items:flex-start}gov-form-group .gov-form-label__label,.gov-form-group .gov-form-label__label,gov-form-radio-group .gov-form-label__label,.gov-form-radio-group .gov-form-label__label,gov-form-checkbox-group .gov-form-label__label,.gov-form-checkbox-group .gov-form-label__label{margin:0}gov-form-group[orientation=horizontal],.gov-form-group[orientation=horizontal],gov-form-radio-group[orientation=horizontal],.gov-form-radio-group[orientation=horizontal],gov-form-checkbox-group[orientation=horizontal],.gov-form-checkbox-group[orientation=horizontal]{flex-direction:row;flex-wrap:wrap}gov-form-group[orientation=horizontal] .gov-form-label__label,.gov-form-group[orientation=horizontal] .gov-form-label__label,gov-form-radio-group[orientation=horizontal] .gov-form-label__label,.gov-form-radio-group[orientation=horizontal] .gov-form-label__label,gov-form-checkbox-group[orientation=horizontal] .gov-form-label__label,.gov-form-checkbox-group[orientation=horizontal] .gov-form-label__label{white-space:nowrap}gov-form-group[gap=xs],.gov-form-group[gap=xs],gov-form-radio-group[gap=xs],.gov-form-radio-group[gap=xs],gov-form-checkbox-group[gap=xs],.gov-form-checkbox-group[gap=xs]{gap:var(--gap, var(--spacing-xs-nudge))}gov-form-group[gap=s],.gov-form-group[gap=s],gov-form-radio-group[gap=s],.gov-form-radio-group[gap=s],gov-form-checkbox-group[gap=s],.gov-form-checkbox-group[gap=s]{gap:var(--gap, var(--spacing-s))}gov-form-group[gap=m],.gov-form-group[gap=m],gov-form-radio-group[gap=m],.gov-form-radio-group[gap=m],gov-form-checkbox-group[gap=m],.gov-form-checkbox-group[gap=m]{gap:var(--gap, var(--spacing-s-nudge))}gov-form-group[gap=l],.gov-form-group[gap=l],gov-form-radio-group[gap=l],.gov-form-radio-group[gap=l],gov-form-checkbox-group[gap=l],.gov-form-checkbox-group[gap=l]{gap:var(--gap, var(--spacing-m))}gov-form-group[gap=xl],.gov-form-group[gap=xl],gov-form-radio-group[gap=xl],.gov-form-radio-group[gap=xl],gov-form-checkbox-group[gap=xl],.gov-form-checkbox-group[gap=xl]{gap:var(--gap, var(--spacing-m-nudge))}";const s=v;const c=o(class o extends r{constructor(){super();this.__registerHost();this.govChange=a(this,"gov-change",7);this.handleChange=o=>{o.stopPropagation();this.value=o.detail.value;this.govChange.emit({value:this.value,component:i.root})};this.gap=undefined;this.orientation="vertical";this.value=undefined;this.h=m(this.host)}validateGap(o){if(o){l(p,o,t.root)}}validateOrientation(o){if(o){l(n,o,t.root)}}componentWillLoad(){this.validateGap(this.gap);this.validateOrientation(this.orientation)}componentDidRender(){f((()=>this.rerenderComponent()))}rerenderComponent(){this.host.querySelectorAll("gov-form-radio").forEach((o=>{if(!o.hasAttribute("listener-attached")){o.addEventListener("gov-change",this.handleChange)}o.setAttribute("listener-attached","true");o.checked=o.value===this.value}))}render(){return g(e,{key:"0526062e74e480edc22bdbbdf8c1f82a91ff463d",gap:this.gap,class:this.h.classes(t.root),value:this.value},g("slot",{key:"f11696b75d4f0c4bc72da3ca70d3111825edd36a"}))}get host(){return this}static get watchers(){return{gap:["validateGap"],orientation:["validateOrientation"]}}static get style(){return s}},[4,"gov-form-radio-group",{gap:[1],orientation:[1],value:[1025]},undefined,{gap:["validateGap"],orientation:["validateOrientation"]}]);function u(){if(typeof customElements==="undefined"){return}const o=["gov-form-radio-group"];o.forEach((o=>{switch(o){case"gov-form-radio-group":if(!customElements.get(o)){customElements.define(o,c)}break}}))}u();const d=c;const h=u;export{d as GovFormRadioGroup,h as defineCustomElement};
1
+ import{p as o,H as r,c as a,h as g,d as e}from"./p-42200001.js";import{d as i,a as t,b as p,c as n}from"./p-e44a0fee.js";import{g as m}from"./p-ea7fdd2e.js";import{v as l}from"./p-0b3574c2.js";import{t as f}from"./p-26618322.js";const v="gov-form-group,.gov-form-group,gov-form-radio-group,.gov-form-radio-group,gov-form-checkbox-group,.gov-form-checkbox-group{margin-top:0;margin-bottom:0;position:relative;display:flex;width:100%;flex-direction:column;align-items:flex-start}gov-form-group .gov-form-label__label,.gov-form-group .gov-form-label__label,gov-form-radio-group .gov-form-label__label,.gov-form-radio-group .gov-form-label__label,gov-form-checkbox-group .gov-form-label__label,.gov-form-checkbox-group .gov-form-label__label{margin:0}gov-form-group[orientation=horizontal],.gov-form-group[orientation=horizontal],gov-form-radio-group[orientation=horizontal],.gov-form-radio-group[orientation=horizontal],gov-form-checkbox-group[orientation=horizontal],.gov-form-checkbox-group[orientation=horizontal]{flex-direction:row;flex-wrap:wrap}gov-form-group[orientation=horizontal] .gov-form-label__label,.gov-form-group[orientation=horizontal] .gov-form-label__label,gov-form-radio-group[orientation=horizontal] .gov-form-label__label,.gov-form-radio-group[orientation=horizontal] .gov-form-label__label,gov-form-checkbox-group[orientation=horizontal] .gov-form-label__label,.gov-form-checkbox-group[orientation=horizontal] .gov-form-label__label{white-space:nowrap}gov-form-group[gap=xs],.gov-form-group[gap=xs],gov-form-radio-group[gap=xs],.gov-form-radio-group[gap=xs],gov-form-checkbox-group[gap=xs],.gov-form-checkbox-group[gap=xs]{gap:var(--gap, var(--spacing-xs-nudge))}gov-form-group[gap=s],.gov-form-group[gap=s],gov-form-radio-group[gap=s],.gov-form-radio-group[gap=s],gov-form-checkbox-group[gap=s],.gov-form-checkbox-group[gap=s]{gap:var(--gap, var(--spacing-s))}gov-form-group[gap=m],.gov-form-group[gap=m],gov-form-radio-group[gap=m],.gov-form-radio-group[gap=m],gov-form-checkbox-group[gap=m],.gov-form-checkbox-group[gap=m]{gap:var(--gap, var(--spacing-s-nudge))}gov-form-group[gap=l],.gov-form-group[gap=l],gov-form-radio-group[gap=l],.gov-form-radio-group[gap=l],gov-form-checkbox-group[gap=l],.gov-form-checkbox-group[gap=l]{gap:var(--gap, var(--spacing-m))}gov-form-group[gap=xl],.gov-form-group[gap=xl],gov-form-radio-group[gap=xl],.gov-form-radio-group[gap=xl],gov-form-checkbox-group[gap=xl],.gov-form-checkbox-group[gap=xl]{gap:var(--gap, var(--spacing-m-nudge))}";const s=v;const c=o(class o extends r{constructor(){super();this.__registerHost();this.govChange=a(this,"gov-change",7);this.handleChange=o=>{o.stopPropagation();this.value=o.detail.value;this.govChange.emit({value:this.value,component:i.root})};this.gap=undefined;this.orientation="vertical";this.value=undefined;this.h=m(this.host)}validateGap(o){if(o){l(p,o,t.root)}}validateOrientation(o){if(o){l(n,o,t.root)}}componentWillLoad(){this.validateGap(this.gap);this.validateOrientation(this.orientation)}componentDidRender(){f((()=>this.rerenderComponent()))}rerenderComponent(){this.host.querySelectorAll("gov-form-radio").forEach((o=>{if(!o.hasAttribute("listener-attached")){o.addEventListener("gov-change",this.handleChange)}o.setAttribute("listener-attached","true");o.checked=o.value===this.value}))}render(){return g(e,{key:"0526062e74e480edc22bdbbdf8c1f82a91ff463d",gap:this.gap,class:this.h.classes(t.root),value:this.value},g("slot",{key:"f11696b75d4f0c4bc72da3ca70d3111825edd36a"}))}get host(){return this}static get watchers(){return{gap:["validateGap"],orientation:["validateOrientation"]}}static get style(){return s}},[4,"gov-form-radio-group",{gap:[1],orientation:[1],value:[1025]},undefined,{gap:["validateGap"],orientation:["validateOrientation"]}]);function u(){if(typeof customElements==="undefined"){return}const o=["gov-form-radio-group"];o.forEach((o=>{switch(o){case"gov-form-radio-group":if(!customElements.get(o)){customElements.define(o,c)}break}}))}u();const d=c;const h=u;export{d as GovFormRadioGroup,h as defineCustomElement};
2
2
  //# sourceMappingURL=gov-form-radio-group.js.map
@@ -1,2 +1,2 @@
1
- import{p as t,H as i,c as s,h as e,d as h}from"./p-115b9cf3.js";import{c as a}from"./p-cd6c2938.js";import{v as n}from"./p-0b3574c2.js";import{g as o,j as r,k as d}from"./p-9908b9f0.js";import{g as c,c as l,t as u}from"./p-ea7fdd2e.js";import{F as f}from"./p-1c1d0bbe.js";import{i as m,A as p,a as v}from"./p-33d5d1ed.js";const b=t(class t extends i{constructor(){super();this.__registerHost();this.govFocus=s(this,"gov-focus",7);this.govBlur=s(this,"gov-blur",7);this.govChange=s(this,"gov-change",7);this.hydrated=false;this.value=undefined;this.noLabel=false;this.checked=false;this.required=false;this.disabled=false;this.name=undefined;this.size="m";this.identifier=undefined;this.invalid=undefined;this.inheritedAttributes={};this.radioId=a("GovRadio");this.h=c(this.host);this.f=o(this.h)}validateSize(t){n(d,t,r.root)}watchControlAttrs(){this.passControlAttrs()}passControlAttrs(){this.f.passAttrToControl("size",this.size);this.f.passAttrToControl("invalid",l(this.invalid));this.f.passAttrToControl("disabled",l(this.disabled));this.f.passAttrToControl("type","radio")}componentWillLoad(){this.inheritedAttributes=m(this.host)}componentDidLoad(){this.attributeObserver=new p(this.host,((t,i)=>{this.onAriaAttributeChange(t,i)}));this.attributeObserver.startObserving(v)}async componentDidRender(){this.f.passAttrToLabel("identifier",this.identifier||this.radioId);this.f.passAttrToLabel("required",String(this.required));this.passControlAttrs()}connectedCallback(){this.hydrated=true}disconnectedCallback(){this.attributeObserver.stopObserving()}onAriaAttributeChange(t,i){this.host.removeAttribute(t);this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{[t]:i})}render(){const t=t=>{if(this.noLabel){return e("label",{class:r.label},t)}return t};return e(h,{class:r.root,hydrated:this.hydrated,checked:this.checked,size:this.size,invalid:u(this.invalid)},t(e(f,null,e("input",Object.assign({class:r.input,id:this.identifier||this.radioId,type:"radio",value:this.value,name:this.name,checked:this.checked,disabled:this.disabled,onClick:this.onClickHandler.bind(this),onChange:this.onChangeHandler.bind(this),onFocus:this.onFocusHandler.bind(this),onBlur:this.onBlurHandler.bind(this),ref:t=>this.inputRef=t,required:this.required},this.inheritedAttributes,{"aria-checked":this.checked,"aria-required":u(this.required),"aria-invalid":u(this.invalid),"aria-disabled":u(this.disabled)})),e("span",null,e("slot",{name:"label"})))))}onClickHandler(t){t.stopPropagation()}onFocusHandler(t){t.stopPropagation();this.govFocus.emit({component:r.root,value:this.value,checked:this.checked,originalEvent:t})}onBlurHandler(t){t.stopPropagation();this.govBlur.emit({component:r.root,value:this.value,checked:this.checked,originalEvent:t})}onChangeHandler(t){this.checked=t.target.checked;t.stopPropagation();this.govChange.emit({component:r.root,value:this.value,checked:this.checked,originalEvent:t})}async getRef(){return this.inputRef}get host(){return this}static get watchers(){return{size:["validateSize","watchControlAttrs"],disabled:["watchControlAttrs"],invalid:["watchControlAttrs"]}}},[4,"gov-form-radio",{value:[1],noLabel:[4,"no-label"],checked:[1540],required:[4],disabled:[516],name:[1],size:[1],identifier:[1],invalid:[4],inheritedAttributes:[32],getRef:[64]},undefined,{size:["validateSize","watchControlAttrs"],disabled:["watchControlAttrs"],invalid:["watchControlAttrs"]}]);function g(){if(typeof customElements==="undefined"){return}const t=["gov-form-radio"];t.forEach((t=>{switch(t){case"gov-form-radio":if(!customElements.get(t)){customElements.define(t,b)}break}}))}g();const C=b;const k=g;export{C as GovFormRadio,k as defineCustomElement};
1
+ import{p as t,H as i,c as s,h as e,d as h}from"./p-42200001.js";import{c as a}from"./p-cd6c2938.js";import{v as n}from"./p-0b3574c2.js";import{g as o,j as r,k as d}from"./p-9908b9f0.js";import{g as c,c as l,t as u}from"./p-ea7fdd2e.js";import{F as f}from"./p-1c1d0bbe.js";import{i as m,A as p,a as v}from"./p-33d5d1ed.js";const b=t(class t extends i{constructor(){super();this.__registerHost();this.govFocus=s(this,"gov-focus",7);this.govBlur=s(this,"gov-blur",7);this.govChange=s(this,"gov-change",7);this.hydrated=false;this.value=undefined;this.noLabel=false;this.checked=false;this.required=false;this.disabled=false;this.name=undefined;this.size="m";this.identifier=undefined;this.invalid=undefined;this.inheritedAttributes={};this.radioId=a("GovRadio");this.h=c(this.host);this.f=o(this.h)}validateSize(t){n(d,t,r.root)}watchControlAttrs(){this.passControlAttrs()}passControlAttrs(){this.f.passAttrToControl("size",this.size);this.f.passAttrToControl("invalid",l(this.invalid));this.f.passAttrToControl("disabled",l(this.disabled));this.f.passAttrToControl("type","radio")}componentWillLoad(){this.inheritedAttributes=m(this.host)}componentDidLoad(){this.attributeObserver=new p(this.host,((t,i)=>{this.onAriaAttributeChange(t,i)}));this.attributeObserver.startObserving(v)}async componentDidRender(){this.f.passAttrToLabel("identifier",this.identifier||this.radioId);this.f.passAttrToLabel("required",String(this.required));this.passControlAttrs()}connectedCallback(){this.hydrated=true}disconnectedCallback(){this.attributeObserver.stopObserving()}onAriaAttributeChange(t,i){this.host.removeAttribute(t);this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{[t]:i})}render(){const t=t=>{if(this.noLabel){return e("label",{class:r.label},t)}return t};return e(h,{class:r.root,hydrated:this.hydrated,checked:this.checked,size:this.size,invalid:u(this.invalid)},t(e(f,null,e("input",Object.assign({class:r.input,id:this.identifier||this.radioId,type:"radio",value:this.value,name:this.name,checked:this.checked,disabled:this.disabled,onClick:this.onClickHandler.bind(this),onChange:this.onChangeHandler.bind(this),onFocus:this.onFocusHandler.bind(this),onBlur:this.onBlurHandler.bind(this),ref:t=>this.inputRef=t,required:this.required},this.inheritedAttributes,{"aria-checked":this.checked,"aria-required":u(this.required),"aria-invalid":u(this.invalid),"aria-disabled":u(this.disabled)})),e("span",null,e("slot",{name:"label"})))))}onClickHandler(t){t.stopPropagation()}onFocusHandler(t){t.stopPropagation();this.govFocus.emit({component:r.root,value:this.value,checked:this.checked,originalEvent:t})}onBlurHandler(t){t.stopPropagation();this.govBlur.emit({component:r.root,value:this.value,checked:this.checked,originalEvent:t})}onChangeHandler(t){this.checked=t.target.checked;t.stopPropagation();this.govChange.emit({component:r.root,value:this.value,checked:this.checked,originalEvent:t})}async getRef(){return this.inputRef}get host(){return this}static get watchers(){return{size:["validateSize","watchControlAttrs"],disabled:["watchControlAttrs"],invalid:["watchControlAttrs"]}}},[4,"gov-form-radio",{value:[1],noLabel:[4,"no-label"],checked:[1540],required:[4],disabled:[516],name:[1],size:[1],identifier:[1],invalid:[4],inheritedAttributes:[32],getRef:[64]},undefined,{size:["validateSize","watchControlAttrs"],disabled:["watchControlAttrs"],invalid:["watchControlAttrs"]}]);function g(){if(typeof customElements==="undefined"){return}const t=["gov-form-radio"];t.forEach((t=>{switch(t){case"gov-form-radio":if(!customElements.get(t)){customElements.define(t,b)}break}}))}g();const C=b;const k=g;export{C as GovFormRadio,k as defineCustomElement};
2
2
  //# sourceMappingURL=gov-form-radio.js.map
@@ -1,2 +1,2 @@
1
- import{p as e,H as s,h as t,d as o}from"./p-115b9cf3.js";import{C as r}from"./p-5aad3497.js";import{p as c}from"./p-e0e2e9c1.js";import{S as a}from"./p-92f420cb.js";c(a,["_S","_M","_L"]);c(r,["PRIMARY","NEUTRAL"]);const f={root:"gov-form-search"};const n=e(class e extends s{constructor(){super();this.__registerHost();this.size="m";this.color="neutral"}render(){return t(o,{key:"05f033c30dffd615b36b181535329704d46665ae",class:f.root,color:this.color,size:this.size},t("slot",{key:"7c7fb4e2d90ace38aef4b63454e1f9513903977c",name:"input"}),t("slot",{key:"92484cbbbae29ba45bb963f80da8237d9406a91b",name:"button-erase"}),t("slot",{key:"92ebb818ee922d790534ffb7816be400ff4a1f98",name:"button"}))}get host(){return this}},[4,"gov-form-search",{size:[1],color:[513]}]);function m(){if(typeof customElements==="undefined"){return}const e=["gov-form-search"];e.forEach((e=>{switch(e){case"gov-form-search":if(!customElements.get(e)){customElements.define(e,n)}break}}))}m();const b=n;const i=m;export{b as GovFormSearch,i as defineCustomElement};
1
+ import{p as e,H as s,h as t,d as o}from"./p-42200001.js";import{C as r}from"./p-5aad3497.js";import{p as a}from"./p-e0e2e9c1.js";import{S as c}from"./p-92f420cb.js";a(c,["_S","_M","_L"]);a(r,["PRIMARY","NEUTRAL"]);const f={root:"gov-form-search"};const n=e(class e extends s{constructor(){super();this.__registerHost();this.size="m";this.color="neutral"}render(){return t(o,{key:"05f033c30dffd615b36b181535329704d46665ae",class:f.root,color:this.color,size:this.size},t("slot",{key:"7c7fb4e2d90ace38aef4b63454e1f9513903977c",name:"input"}),t("slot",{key:"92484cbbbae29ba45bb963f80da8237d9406a91b",name:"button-erase"}),t("slot",{key:"92ebb818ee922d790534ffb7816be400ff4a1f98",name:"button"}))}get host(){return this}},[4,"gov-form-search",{size:[1],color:[513]}]);function m(){if(typeof customElements==="undefined"){return}const e=["gov-form-search"];e.forEach((e=>{switch(e){case"gov-form-search":if(!customElements.get(e)){customElements.define(e,n)}break}}))}m();const b=n;const i=m;export{b as GovFormSearch,i as defineCustomElement};
2
2
  //# sourceMappingURL=gov-form-search.js.map
@@ -1,2 +1,2 @@
1
- import{G as o,d as s}from"./p-51693b62.js";const t=o;const p=s;export{t as GovFormSelect,p as defineCustomElement};
1
+ import{G as o,d as s}from"./p-13a70392.js";const t=o;const a=s;export{t as GovFormSelect,a as defineCustomElement};
2
2
  //# sourceMappingURL=gov-form-select.js.map
@@ -1,2 +1,2 @@
1
- import{p as i,H as s,c as t,h as e,d as h}from"./p-115b9cf3.js";import{c as a}from"./p-cd6c2938.js";import{v as n}from"./p-0b3574c2.js";import{g as c,n as o,o as d}from"./p-9908b9f0.js";import{g as r,c as l,t as u}from"./p-ea7fdd2e.js";import{F as m}from"./p-1c1d0bbe.js";import{A as f,a as b,i as p}from"./p-33d5d1ed.js";import{d as v}from"./p-7f0c6ba3.js";const g=i(class i extends s{constructor(){super();this.__registerHost();this.govFocus=t(this,"gov-focus",7);this.govBlur=t(this,"gov-blur",7);this.govChange=t(this,"gov-change",7);this.hydrated=false;this.value=undefined;this.noLabel=false;this.checked=false;this.required=false;this.disabled=false;this.name=undefined;this.size="m";this.identifier=undefined;this.invalid=undefined;this.inheritedAttributes={};this.checkboxId=a("GovCheckbox");this.h=r(this.host);this.f=c(this.h)}validateSize(i){n(d,i,o.root)}watchDisabled(){this.passControlAttrs()}passControlAttrs(){this.f.passAttrToControl("size",this.size);this.f.passAttrToControl("invalid",l(this.invalid));this.f.passAttrToControl("disabled",l(this.disabled));this.f.passAttrToControl("type","switch")}componentDidLoad(){this.attributeObserver=new f(this.host,((i,s)=>{this.onAriaAttributeChange(i,s)}));this.attributeObserver.startObserving(b)}componentWillLoad(){this.passControlAttrs();this.inheritedAttributes=p(this.host)}disconnectedCallback(){this.attributeObserver.stopObserving()}async componentDidRender(){this.f.passAttrToLabel("identifier",this.identifier||this.checkboxId);this.f.passAttrToLabel("required",String(this.required));this.passControlAttrs()}connectedCallback(){this.hydrated=true}onAriaAttributeChange(i,s){this.host.removeAttribute(i);this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{[i]:s})}render(){const i=i=>{if(this.noLabel){return e("label",{class:o.label},i)}return i};return e(h,{class:this.h.classes(o.root),hydrated:this.hydrated,checked:this.checked,size:this.size,invalid:u(this.invalid)},i(e(m,null,e("input",Object.assign({class:o.input,id:this.identifier||this.checkboxId,type:"checkbox",value:this.value,name:this.name,disabled:this.disabled,checked:this.checked,onClick:this.onClickHandler.bind(this),onChange:this.onChangeHandler.bind(this),onFocus:this.onFocusHandler.bind(this),onBlur:this.onBlurHandler.bind(this),ref:i=>this.inputRef=i,required:this.required},this.inheritedAttributes,{"aria-checked":this.checked,"aria-required":u(this.required),"aria-invalid":u(this.invalid),"aria-disabled":u(this.disabled)})),e("span",null,e("span",{class:o.indicator},this.checked&&e("gov-icon",{name:"check-lg",type:"components"})),e("slot",{name:"label"})))))}onClickHandler(i){i.stopPropagation()}onFocusHandler(i){i.stopPropagation();this.govFocus.emit({component:o.root,checked:this.checked,value:this.value,originalEvent:i})}onBlurHandler(i){i.stopPropagation();this.govBlur.emit({component:o.root,checked:this.checked,value:this.value,originalEvent:i})}onChangeHandler(i){this.checked=i.target.checked;i.stopPropagation();this.govChange.emit({component:o.root,checked:this.checked,value:this.value,originalEvent:i})}async getRef(){return this.inputRef}get host(){return this}static get watchers(){return{size:["validateSize","watchDisabled"],disabled:["watchDisabled"],invalid:["watchDisabled"]}}},[4,"gov-form-switch",{value:[1],noLabel:[4,"no-label"],checked:[1540],required:[4],disabled:[516],name:[1],size:[513],identifier:[1],invalid:[4],inheritedAttributes:[32],getRef:[64]},undefined,{size:["validateSize","watchDisabled"],disabled:["watchDisabled"],invalid:["watchDisabled"]}]);function k(){if(typeof customElements==="undefined"){return}const i=["gov-form-switch","gov-icon"];i.forEach((i=>{switch(i){case"gov-form-switch":if(!customElements.get(i)){customElements.define(i,g)}break;case"gov-icon":if(!customElements.get(i)){v()}break}}))}k();const w=g;const j=k;export{w as GovFormSwitch,j as defineCustomElement};
1
+ import{p as i,H as s,c as t,h as e,d as h}from"./p-42200001.js";import{c as a}from"./p-cd6c2938.js";import{v as n}from"./p-0b3574c2.js";import{g as o,n as c,o as d}from"./p-9908b9f0.js";import{g as r,c as l,t as u}from"./p-ea7fdd2e.js";import{F as m}from"./p-1c1d0bbe.js";import{A as f,a as b,i as p}from"./p-33d5d1ed.js";import{d as v}from"./p-a877bf8a.js";const g=i(class i extends s{constructor(){super();this.__registerHost();this.govFocus=t(this,"gov-focus",7);this.govBlur=t(this,"gov-blur",7);this.govChange=t(this,"gov-change",7);this.hydrated=false;this.value=undefined;this.noLabel=false;this.checked=false;this.required=false;this.disabled=false;this.name=undefined;this.size="m";this.identifier=undefined;this.invalid=undefined;this.inheritedAttributes={};this.checkboxId=a("GovCheckbox");this.h=r(this.host);this.f=o(this.h)}validateSize(i){n(d,i,c.root)}watchDisabled(){this.passControlAttrs()}passControlAttrs(){this.f.passAttrToControl("size",this.size);this.f.passAttrToControl("invalid",l(this.invalid));this.f.passAttrToControl("disabled",l(this.disabled));this.f.passAttrToControl("type","switch")}componentDidLoad(){this.attributeObserver=new f(this.host,((i,s)=>{this.onAriaAttributeChange(i,s)}));this.attributeObserver.startObserving(b)}componentWillLoad(){this.passControlAttrs();this.inheritedAttributes=p(this.host)}disconnectedCallback(){this.attributeObserver.stopObserving()}async componentDidRender(){this.f.passAttrToLabel("identifier",this.identifier||this.checkboxId);this.f.passAttrToLabel("required",String(this.required));this.passControlAttrs()}connectedCallback(){this.hydrated=true}onAriaAttributeChange(i,s){this.host.removeAttribute(i);this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{[i]:s})}render(){const i=i=>{if(this.noLabel){return e("label",{class:c.label},i)}return i};return e(h,{class:this.h.classes(c.root),hydrated:this.hydrated,checked:this.checked,size:this.size,invalid:u(this.invalid)},i(e(m,null,e("input",Object.assign({class:c.input,id:this.identifier||this.checkboxId,type:"checkbox",value:this.value,name:this.name,disabled:this.disabled,checked:this.checked,onClick:this.onClickHandler.bind(this),onChange:this.onChangeHandler.bind(this),onFocus:this.onFocusHandler.bind(this),onBlur:this.onBlurHandler.bind(this),ref:i=>this.inputRef=i,required:this.required},this.inheritedAttributes,{"aria-checked":this.checked,"aria-required":u(this.required),"aria-invalid":u(this.invalid),"aria-disabled":u(this.disabled)})),e("span",null,e("span",{class:c.indicator},this.checked&&e("gov-icon",{name:"check-lg",type:"components"})),e("slot",{name:"label"})))))}onClickHandler(i){i.stopPropagation()}onFocusHandler(i){i.stopPropagation();this.govFocus.emit({component:c.root,checked:this.checked,value:this.value,originalEvent:i})}onBlurHandler(i){i.stopPropagation();this.govBlur.emit({component:c.root,checked:this.checked,value:this.value,originalEvent:i})}onChangeHandler(i){this.checked=i.target.checked;i.stopPropagation();this.govChange.emit({component:c.root,checked:this.checked,value:this.value,originalEvent:i})}async getRef(){return this.inputRef}get host(){return this}static get watchers(){return{size:["validateSize","watchDisabled"],disabled:["watchDisabled"],invalid:["watchDisabled"]}}},[4,"gov-form-switch",{value:[1],noLabel:[4,"no-label"],checked:[1540],required:[4],disabled:[516],name:[1],size:[513],identifier:[1],invalid:[4],inheritedAttributes:[32],getRef:[64]},undefined,{size:["validateSize","watchDisabled"],disabled:["watchDisabled"],invalid:["watchDisabled"]}]);function k(){if(typeof customElements==="undefined"){return}const i=["gov-form-switch","gov-icon"];i.forEach((i=>{switch(i){case"gov-form-switch":if(!customElements.get(i)){customElements.define(i,g)}break;case"gov-icon":if(!customElements.get(i)){v()}break}}))}k();const w=g;const j=k;export{w as GovFormSwitch,j as defineCustomElement};
2
2
  //# sourceMappingURL=gov-form-switch.js.map
@@ -1,2 +1,2 @@
1
- import{p as s,H as e,h as i,d as t}from"./p-115b9cf3.js";import{a as d}from"./p-880743a5.js";import{g as n}from"./p-ea7fdd2e.js";const o=s(class s extends e{constructor(){super();this.__registerHost();this.size="12/12";this.sizeSm=undefined;this.sizeMd=undefined;this.sizeLg=undefined;this.sizeXl=undefined;this.h=n(this.host)}render(){return i(t,{key:"e1dc6e3517618361ab3b5e3ad499a5bbbaae3d6a",class:this.h.classes(d.root),role:"listitem",size:this.size,"size-sm":this.sizeSm,"size-md":this.sizeMd,"size-lg":this.sizeLg,"size-xl":this.sizeXl},i("slot",{key:"53780db95fa728f252302cb86923ad9e9fcd9b66"}))}get host(){return this}},[4,"gov-grid-item",{size:[1],sizeSm:[1,"size-sm"],sizeMd:[1,"size-md"],sizeLg:[1,"size-lg"],sizeXl:[1,"size-xl"]}]);function r(){if(typeof customElements==="undefined"){return}const s=["gov-grid-item"];s.forEach((s=>{switch(s){case"gov-grid-item":if(!customElements.get(s)){customElements.define(s,o)}break}}))}r();const m=o;const a=r;export{m as GovGridItem,a as defineCustomElement};
1
+ import{p as s,H as e,h as i,d as t}from"./p-42200001.js";import{a as d}from"./p-880743a5.js";import{g as n}from"./p-ea7fdd2e.js";const o=s(class s extends e{constructor(){super();this.__registerHost();this.size="12/12";this.sizeSm=undefined;this.sizeMd=undefined;this.sizeLg=undefined;this.sizeXl=undefined;this.h=n(this.host)}render(){return i(t,{key:"e1dc6e3517618361ab3b5e3ad499a5bbbaae3d6a",class:this.h.classes(d.root),role:"listitem",size:this.size,"size-sm":this.sizeSm,"size-md":this.sizeMd,"size-lg":this.sizeLg,"size-xl":this.sizeXl},i("slot",{key:"53780db95fa728f252302cb86923ad9e9fcd9b66"}))}get host(){return this}},[4,"gov-grid-item",{size:[1],sizeSm:[1,"size-sm"],sizeMd:[1,"size-md"],sizeLg:[1,"size-lg"],sizeXl:[1,"size-xl"]}]);function r(){if(typeof customElements==="undefined"){return}const s=["gov-grid-item"];s.forEach((s=>{switch(s){case"gov-grid-item":if(!customElements.get(s)){customElements.define(s,o)}break}}))}r();const m=o;const a=r;export{m as GovGridItem,a as defineCustomElement};
2
2
  //# sourceMappingURL=gov-grid-item.js.map
@@ -1,2 +1,2 @@
1
- import{p as e,H as s,h as t,d as i}from"./p-115b9cf3.js";import{G as n}from"./p-880743a5.js";import{g as a}from"./p-ea7fdd2e.js";const o=e(class e extends s{constructor(){super();this.__registerHost();this.alignX=undefined;this.alignY=undefined;this.h=a(this.host)}render(){return t(i,{key:"d2f4e42a186e0d8020abc96ef3ca0956e1492d05",class:this.h.classes(n.root),"align-x":this.alignX,"align-y":this.alignY,role:"list"},t("slot",{key:"46c60ccdda81ce271aeaca46bead1bf33e22c041"}))}get host(){return this}},[4,"gov-grid",{alignX:[1,"align-x"],alignY:[1,"align-y"]}]);function c(){if(typeof customElements==="undefined"){return}const e=["gov-grid"];e.forEach((e=>{switch(e){case"gov-grid":if(!customElements.get(e)){customElements.define(e,o)}break}}))}c();const r=o;const d=c;export{r as GovGrid,d as defineCustomElement};
1
+ import{p as e,H as s,h as t,d as i}from"./p-42200001.js";import{G as n}from"./p-880743a5.js";import{g as a}from"./p-ea7fdd2e.js";const o=e(class e extends s{constructor(){super();this.__registerHost();this.alignX=undefined;this.alignY=undefined;this.h=a(this.host)}render(){return t(i,{key:"d2f4e42a186e0d8020abc96ef3ca0956e1492d05",class:this.h.classes(n.root),"align-x":this.alignX,"align-y":this.alignY,role:"list"},t("slot",{key:"46c60ccdda81ce271aeaca46bead1bf33e22c041"}))}get host(){return this}},[4,"gov-grid",{alignX:[1,"align-x"],alignY:[1,"align-y"]}]);function r(){if(typeof customElements==="undefined"){return}const e=["gov-grid"];e.forEach((e=>{switch(e){case"gov-grid":if(!customElements.get(e)){customElements.define(e,o)}break}}))}r();const c=o;const d=r;export{c as GovGrid,d as defineCustomElement};
2
2
  //# sourceMappingURL=gov-grid.js.map
@@ -1,2 +1,2 @@
1
- import{G as o,d as s}from"./p-7f0c6ba3.js";const t=o;const a=s;export{t as GovIcon,a as defineCustomElement};
1
+ import{G as o,d as s}from"./p-a877bf8a.js";const a=o;const t=s;export{a as GovIcon,t as defineCustomElement};
2
2
  //# sourceMappingURL=gov-icon.js.map
@@ -1,2 +1,2 @@
1
- import{p as t,H as e,c as s,h as o,d as i}from"./p-115b9cf3.js";import{g as a,c as n}from"./p-ea7fdd2e.js";import{F as c}from"./p-1c1d0bbe.js";import{v as l}from"./p-0b3574c2.js";import{C as r}from"./p-5aad3497.js";import{p as b}from"./p-e0e2e9c1.js";import{A as d,a as h,i as f}from"./p-33d5d1ed.js";import{d as m}from"./p-9b0f446d.js";import{d as p}from"./p-7f0c6ba3.js";const g=b(r,["PRIMARY","SECONDARY","NEUTRAL","ERROR","SUCCESS","WARNING"]);var v;(function(t){t["BOLD"]="bold";t["SUBTLE"]="subtle"})(v||(v={}));const u={root:"gov-infobar",section:"gov-infobar__section",content:"gov-infobar__content",headline:"gov-infobar__headline",close:"gov-infobar__close"};const y=t(class t extends e{constructor(){super();this.__registerHost();this.govClose=s(this,"gov-close",7);this.color="primary";this.type="bold";this.role=undefined;this.accessibleCloseLabel="Zavřít informační lištu";this.accessibleToggleLabel="Zobrazit více informací";this.closable=false;this.toggleContent=false;this.inheritedAttributes={};this.h=a(this.host)}validateColor(t){l(g,t,u.root)}componentDidLoad(){this.attributeObserver=new d(this.host,((t,e)=>{this.onAriaAttributeChange(t,e)}));this.attributeObserver.startObserving(h)}componentWillLoad(){this.validateColor(this.color);this.inheritedAttributes=f(this.host)}disconnectedCallback(){this.attributeObserver.stopObserving()}onAriaAttributeChange(t,e){this.host.removeAttribute(t);this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{[t]:e})}render(){const t=o("gov-button",{key:"2d0597a56f6edb97e7feff654ba98885fa48033a",size:"s","aria-label":this.accessibleCloseLabel,type:"base",color:this.isBold?this.color:"neutral","on-gov-click":this.onCloseHandler.bind(this),class:u.close},o("gov-icon",{key:"c17ba542b02a4910a136eec6cb4556d1857dffb2",name:"x-lg",type:"components"}));return o(i,{key:"d71d1b8ffe158de90f3fb520bd996a8246988d3d",class:this.h.classes(u.root),color:this.color,type:this.type},o("section",Object.assign({key:"12cce82faa13fa39135fe92b0ab61bc2b01fa083",class:u.section},this.inheritedAttributes,{role:this.role}),o("slot",{key:"bc48d4e5dfad03cd9c54054225a4c3db0ec09cd9",name:"icon"}),o("div",{key:"70422e59cb69504d1aca5d45b9f9700b35b344f0",class:u.content},this.h.hasSlot("headline")?o(c,null,o("div",{class:u.headline},o("slot",{name:"headline"}),o("gov-button",{size:"s",type:"base",color:this.isBold?this.color:"neutral","aria-label":this.accessibleToggleLabel,"on-gov-click":()=>this.toggleContent=!this.toggleContent},o("gov-icon",{name:this.toggleContent?"chevron-up":"chevron-down",type:"components"}))),o("div",{hidden:!this.toggleContent,"aria-hidden":n(this.toggleContent)},o("slot",null))):o("slot",null)),this.closable&&t))}onCloseHandler(t){this.govClose.emit({component:u.root,ref:this.host,originalEvent:t})}get isBold(){return this.type==="bold"}get host(){return this}static get watchers(){return{color:["validateColor"]}}},[4,"gov-infobar",{color:[1],type:[1],role:[1],accessibleCloseLabel:[1,"accessible-close-label"],accessibleToggleLabel:[1,"accessible-toggle-label"],closable:[4],toggleContent:[32],inheritedAttributes:[32]},undefined,{color:["validateColor"]}]);function j(){if(typeof customElements==="undefined"){return}const t=["gov-infobar","gov-button","gov-icon"];t.forEach((t=>{switch(t){case"gov-infobar":if(!customElements.get(t)){customElements.define(t,y)}break;case"gov-button":if(!customElements.get(t)){m()}break;case"gov-icon":if(!customElements.get(t)){p()}break}}))}j();const k=y;const C=j;export{k as GovInfobar,C as defineCustomElement};
1
+ import{p as t,H as e,c as s,h as o,d as i}from"./p-42200001.js";import{g as a,c as n}from"./p-ea7fdd2e.js";import{F as c}from"./p-1c1d0bbe.js";import{v as l}from"./p-0b3574c2.js";import{C as r}from"./p-5aad3497.js";import{p as b}from"./p-e0e2e9c1.js";import{A as d,a as h,i as f}from"./p-33d5d1ed.js";import{d as m}from"./p-558cbab0.js";import{d as p}from"./p-a877bf8a.js";const g=b(r,["PRIMARY","SECONDARY","NEUTRAL","ERROR","SUCCESS","WARNING"]);var v;(function(t){t["BOLD"]="bold";t["SUBTLE"]="subtle"})(v||(v={}));const u={root:"gov-infobar",section:"gov-infobar__section",content:"gov-infobar__content",headline:"gov-infobar__headline",close:"gov-infobar__close"};const y=t(class t extends e{constructor(){super();this.__registerHost();this.govClose=s(this,"gov-close",7);this.color="primary";this.type="bold";this.role=undefined;this.accessibleCloseLabel="Zavřít informační lištu";this.accessibleToggleLabel="Zobrazit více informací";this.closable=false;this.toggleContent=false;this.inheritedAttributes={};this.h=a(this.host)}validateColor(t){l(g,t,u.root)}componentDidLoad(){this.attributeObserver=new d(this.host,((t,e)=>{this.onAriaAttributeChange(t,e)}));this.attributeObserver.startObserving(h)}componentWillLoad(){this.validateColor(this.color);this.inheritedAttributes=f(this.host)}disconnectedCallback(){this.attributeObserver.stopObserving()}onAriaAttributeChange(t,e){this.host.removeAttribute(t);this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{[t]:e})}render(){const t=o("gov-button",{key:"2d0597a56f6edb97e7feff654ba98885fa48033a",size:"s","aria-label":this.accessibleCloseLabel,type:"base",color:this.isBold?this.color:"neutral","on-gov-click":this.onCloseHandler.bind(this),class:u.close},o("gov-icon",{key:"c17ba542b02a4910a136eec6cb4556d1857dffb2",name:"x-lg",type:"components"}));return o(i,{key:"d71d1b8ffe158de90f3fb520bd996a8246988d3d",class:this.h.classes(u.root),color:this.color,type:this.type},o("section",Object.assign({key:"12cce82faa13fa39135fe92b0ab61bc2b01fa083",class:u.section},this.inheritedAttributes,{role:this.role}),o("slot",{key:"bc48d4e5dfad03cd9c54054225a4c3db0ec09cd9",name:"icon"}),o("div",{key:"70422e59cb69504d1aca5d45b9f9700b35b344f0",class:u.content},this.h.hasSlot("headline")?o(c,null,o("div",{class:u.headline},o("slot",{name:"headline"}),o("gov-button",{size:"s",type:"base",color:this.isBold?this.color:"neutral","aria-label":this.accessibleToggleLabel,"on-gov-click":()=>this.toggleContent=!this.toggleContent},o("gov-icon",{name:this.toggleContent?"chevron-up":"chevron-down",type:"components"}))),o("div",{hidden:!this.toggleContent,"aria-hidden":n(this.toggleContent)},o("slot",null))):o("slot",null)),this.closable&&t))}onCloseHandler(t){this.govClose.emit({component:u.root,ref:this.host,originalEvent:t})}get isBold(){return this.type==="bold"}get host(){return this}static get watchers(){return{color:["validateColor"]}}},[4,"gov-infobar",{color:[1],type:[1],role:[1],accessibleCloseLabel:[1,"accessible-close-label"],accessibleToggleLabel:[1,"accessible-toggle-label"],closable:[4],toggleContent:[32],inheritedAttributes:[32]},undefined,{color:["validateColor"]}]);function j(){if(typeof customElements==="undefined"){return}const t=["gov-infobar","gov-button","gov-icon"];t.forEach((t=>{switch(t){case"gov-infobar":if(!customElements.get(t)){customElements.define(t,y)}break;case"gov-button":if(!customElements.get(t)){m()}break;case"gov-icon":if(!customElements.get(t)){p()}break}}))}j();const k=y;const C=j;export{k as GovInfobar,C as defineCustomElement};
2
2
  //# sourceMappingURL=gov-infobar.js.map
@@ -1,2 +1,2 @@
1
- import{p as e,H as t,h as s,d as o}from"./p-115b9cf3.js";import{a as c}from"./p-13ebd887.js";import{g as n}from"./p-ea7fdd2e.js";const a=e(class e extends t{constructor(){super();this.__registerHost();this.h=n(this.host)}render(){return s(o,{key:"ebef4ca76b1308a566c862b5a49eecf1eb3fce99",class:this.h.classes(c.root)},s("slot",{key:"aaeefeb1a56b294d91b1327fd52eb16486cfb918"}))}get host(){return this}},[4,"gov-layout-column"]);function r(){if(typeof customElements==="undefined"){return}const e=["gov-layout-column"];e.forEach((e=>{switch(e){case"gov-layout-column":if(!customElements.get(e)){customElements.define(e,a)}break}}))}r();const f=a;const u=r;export{f as GovLayoutColumn,u as defineCustomElement};
1
+ import{p as e,H as t,h as s,d as o}from"./p-42200001.js";import{a as c}from"./p-13ebd887.js";import{g as n}from"./p-ea7fdd2e.js";const a=e(class e extends t{constructor(){super();this.__registerHost();this.h=n(this.host)}render(){return s(o,{key:"ebef4ca76b1308a566c862b5a49eecf1eb3fce99",class:this.h.classes(c.root)},s("slot",{key:"aaeefeb1a56b294d91b1327fd52eb16486cfb918"}))}get host(){return this}},[4,"gov-layout-column"]);function r(){if(typeof customElements==="undefined"){return}const e=["gov-layout-column"];e.forEach((e=>{switch(e){case"gov-layout-column":if(!customElements.get(e)){customElements.define(e,a)}break}}))}r();const u=a;const f=r;export{u as GovLayoutColumn,f as defineCustomElement};
2
2
  //# sourceMappingURL=gov-layout-column.js.map
@@ -1,2 +1,2 @@
1
- import{p as s,H as t,h as e,d as c}from"./p-115b9cf3.js";import{L as o}from"./p-13ebd887.js";import{g as n}from"./p-ea7fdd2e.js";const i=s(class s extends t{constructor(){super();this.__registerHost();this.type="stretch";this.variant=undefined;this.inverse=false;this.h=n(this.host)}typeClass(s,t,e,c){const o=t?"-"+t:"";const n=e?"-"+e:"";const i=c?"-inverse":"";return s+" "+s+o+n+i}render(){return e(c,{key:"c35fc39e07229363bdf36be5856165e7e8eb7985",type:this.type,class:this.h.classes(o.root)},e("section",{key:"dc50cf9cba8bd4e879291fddfbd41955f2d10330",class:this.typeClass(o.section,this.type,this.variant,this.inverse)},e("slot",{key:"017a329c119529d3893e187b6a8bbccfbbc76679"})))}get host(){return this}},[4,"gov-layout",{type:[1],variant:[1],inverse:[4]}]);function r(){if(typeof customElements==="undefined"){return}const s=["gov-layout"];s.forEach((s=>{switch(s){case"gov-layout":if(!customElements.get(s)){customElements.define(s,i)}break}}))}r();const a=i;const f=r;export{a as GovLayout,f as defineCustomElement};
1
+ import{p as s,H as t,h as e,d as o}from"./p-42200001.js";import{L as c}from"./p-13ebd887.js";import{g as n}from"./p-ea7fdd2e.js";const i=s(class s extends t{constructor(){super();this.__registerHost();this.type="stretch";this.variant=undefined;this.inverse=false;this.h=n(this.host)}typeClass(s,t,e,o){const c=t?"-"+t:"";const n=e?"-"+e:"";const i=o?"-inverse":"";return s+" "+s+c+n+i}render(){return e(o,{key:"c35fc39e07229363bdf36be5856165e7e8eb7985",type:this.type,class:this.h.classes(c.root)},e("section",{key:"dc50cf9cba8bd4e879291fddfbd41955f2d10330",class:this.typeClass(c.section,this.type,this.variant,this.inverse)},e("slot",{key:"017a329c119529d3893e187b6a8bbccfbbc76679"})))}get host(){return this}},[4,"gov-layout",{type:[1],variant:[1],inverse:[4]}]);function r(){if(typeof customElements==="undefined"){return}const s=["gov-layout"];s.forEach((s=>{switch(s){case"gov-layout":if(!customElements.get(s)){customElements.define(s,i)}break}}))}r();const a=i;const d=r;export{a as GovLayout,d as defineCustomElement};
2
2
  //# sourceMappingURL=gov-layout.js.map
@@ -1,2 +1,2 @@
1
- import{p as e,H as o,h as n,d as c}from"./p-115b9cf3.js";import{a as t}from"./p-cd6c2938.js";const s=e(class e extends o{constructor(){super();this.__registerHost();this.uniqueId="lifecycle-"+t()}connectedCallback(){console.log("connectedCallback",this.uniqueId)}disconnectedCallback(){console.log("disconnectedCallback",this.uniqueId)}componentWillLoad(){console.log("componentWillLoad",this.uniqueId)}componentDidLoad(){console.log("componentDidLoad",this.uniqueId)}componentShouldUpdate(){console.log("componentShouldUpdate",this.uniqueId)}componentWillRender(){console.log("componentWillRender",this.uniqueId)}componentDidRender(){console.log("componentDidRender",this.uniqueId)}componentWillUpdate(){console.log("componentWillUpdate",this.uniqueId)}componentDidUpdate(){console.log("componentDidUpdate",this.uniqueId)}render(){return n(c,{key:"506eabaae01ae888fa838c10572e55bbe6fb7015",identifier:this.uniqueId},n("span",{key:"7604a29214fdffb1a470d83d7db37a583e5072ed"},"lifecycle ",this.uniqueId))}},[0,"gov-lifecycle"]);function l(){if(typeof customElements==="undefined"){return}const e=["gov-lifecycle"];e.forEach((e=>{switch(e){case"gov-lifecycle":if(!customElements.get(e)){customElements.define(e,s)}break}}))}l();const i=s;const d=l;export{i as GovLifecycle,d as defineCustomElement};
1
+ import{p as e,H as o,h as n,d as c}from"./p-42200001.js";import{a as t}from"./p-cd6c2938.js";const s=e(class e extends o{constructor(){super();this.__registerHost();this.uniqueId="lifecycle-"+t()}connectedCallback(){console.log("connectedCallback",this.uniqueId)}disconnectedCallback(){console.log("disconnectedCallback",this.uniqueId)}componentWillLoad(){console.log("componentWillLoad",this.uniqueId)}componentDidLoad(){console.log("componentDidLoad",this.uniqueId)}componentShouldUpdate(){console.log("componentShouldUpdate",this.uniqueId)}componentWillRender(){console.log("componentWillRender",this.uniqueId)}componentDidRender(){console.log("componentDidRender",this.uniqueId)}componentWillUpdate(){console.log("componentWillUpdate",this.uniqueId)}componentDidUpdate(){console.log("componentDidUpdate",this.uniqueId)}render(){return n(c,{key:"506eabaae01ae888fa838c10572e55bbe6fb7015",identifier:this.uniqueId},n("span",{key:"7604a29214fdffb1a470d83d7db37a583e5072ed"},"lifecycle ",this.uniqueId))}},[0,"gov-lifecycle"]);function l(){if(typeof customElements==="undefined"){return}const e=["gov-lifecycle"];e.forEach((e=>{switch(e){case"gov-lifecycle":if(!customElements.get(e)){customElements.define(e,s)}break}}))}l();const i=s;const d=l;export{i as GovLifecycle,d as defineCustomElement};
2
2
  //# sourceMappingURL=gov-lifecycle.js.map
@@ -1,2 +1,2 @@
1
- import{p as t,H as e,h as s,d as i}from"./p-115b9cf3.js";import{p as o}from"./p-e0e2e9c1.js";import{S as n}from"./p-92f420cb.js";import{g as r}from"./p-ea7fdd2e.js";import{v as a}from"./p-0b3574c2.js";import{i as c}from"./p-33d5d1ed.js";import{d as h}from"./p-7f0c6ba3.js";const f=o(n,["_S","_M","_L"]);const m={root:"gov-link"};const d=t(class t extends e{constructor(){super();this.__registerHost();this.size="m";this.external=false;this.href=undefined;this.target=undefined;this.inheritedAttributes={};this.h=r(this.host)}validateSize(t){a(f,t,m.root)}componentWillLoad(){this.validateSize(this.size);this.inheritedAttributes=c(this.host)}onAriaAttributeChange(t,e){this.host.removeAttribute(t);this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{[t]:e})}render(){return s(i,{key:"233af48c179501fe03ee2e5931806e1955913b59",class:this.h.classes(m.root),size:this.size,href:this.href,external:this.external},s("a",Object.assign({key:"679067805205d76500979620b1ef4405139bb339",class:"element",href:this.href,target:this.target},this.inheritedAttributes),s("slot",{key:"d24c4ab99451f317a453c8131bd0506606322553",name:"icon-start"}),s("slot",{key:"276923f48cdc13985115e8d4e8860a2fb0c692e2"}),this.external?s("gov-icon",{name:"box-arrow-up-right",type:"components"}):s("slot",{name:"icon-end"})))}get host(){return this}static get watchers(){return{size:["validateSize"]}}},[4,"gov-link",{size:[1],external:[4],href:[1],target:[1],inheritedAttributes:[32]},undefined,{size:["validateSize"]}]);function l(){if(typeof customElements==="undefined"){return}const t=["gov-link","gov-icon"];t.forEach((t=>{switch(t){case"gov-link":if(!customElements.get(t)){customElements.define(t,d)}break;case"gov-icon":if(!customElements.get(t)){h()}break}}))}l();const p=d;const b=l;export{p as GovLink,b as defineCustomElement};
1
+ import{p as t,H as e,h as s,d as i}from"./p-42200001.js";import{p as o}from"./p-e0e2e9c1.js";import{S as n}from"./p-92f420cb.js";import{g as r}from"./p-ea7fdd2e.js";import{v as a}from"./p-0b3574c2.js";import{i as c}from"./p-33d5d1ed.js";import{d as h}from"./p-a877bf8a.js";const f=o(n,["_S","_M","_L"]);const m={root:"gov-link"};const d=t(class t extends e{constructor(){super();this.__registerHost();this.size="m";this.external=false;this.href=undefined;this.target=undefined;this.inheritedAttributes={};this.h=r(this.host)}validateSize(t){a(f,t,m.root)}componentWillLoad(){this.validateSize(this.size);this.inheritedAttributes=c(this.host)}onAriaAttributeChange(t,e){this.host.removeAttribute(t);this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{[t]:e})}render(){return s(i,{key:"233af48c179501fe03ee2e5931806e1955913b59",class:this.h.classes(m.root),size:this.size,href:this.href,external:this.external},s("a",Object.assign({key:"679067805205d76500979620b1ef4405139bb339",class:"element",href:this.href,target:this.target},this.inheritedAttributes),s("slot",{key:"d24c4ab99451f317a453c8131bd0506606322553",name:"icon-start"}),s("slot",{key:"276923f48cdc13985115e8d4e8860a2fb0c692e2"}),this.external?s("gov-icon",{name:"box-arrow-up-right",type:"components"}):s("slot",{name:"icon-end"})))}get host(){return this}static get watchers(){return{size:["validateSize"]}}},[4,"gov-link",{size:[1],external:[4],href:[1],target:[1],inheritedAttributes:[32]},undefined,{size:["validateSize"]}]);function l(){if(typeof customElements==="undefined"){return}const t=["gov-link","gov-icon"];t.forEach((t=>{switch(t){case"gov-link":if(!customElements.get(t)){customElements.define(t,d)}break;case"gov-icon":if(!customElements.get(t)){h()}break}}))}l();const p=d;const b=l;export{p as GovLink,b as defineCustomElement};
2
2
  //# sourceMappingURL=gov-link.js.map
@@ -1,2 +1,2 @@
1
- import{p as e,H as o,h as s,d as t}from"./p-115b9cf3.js";import{p as a}from"./p-e0e2e9c1.js";import{S as c}from"./p-92f420cb.js";import{g as i,p as n}from"./p-ea7fdd2e.js";import{v as d}from"./p-0b3574c2.js";import{d as r}from"./p-384c7f2a.js";import{d as m}from"./p-7f0c6ba3.js";const f=a(c,["_S","_M","_L"]);const p={root:"gov-loading",content:"gov-loading__content",icon:"gov-loading__icon"};const g=e(class e extends o{constructor(){super();this.__registerHost();this.size="m";this.h=i(this.host)}validateSize(e){d(f,e,p.root)}componentWillLoad(){this.validateSize(this.size)}render(){return s(t,{key:"4c33339523674f2f2415dfb326131858de9eecf9",class:this.h.classes(p.root),size:this.size},s("div",{key:"8c25628dd3072fd89665ccfedb9596383181b13d",class:p.content},s("gov-icon",{key:"a9969874350b5316c61a94b12d41a0130eeded0f",class:n([p.icon,"gov-spin-animation"]),name:"loader",type:"components"}),s("slot",{key:"14c716ecc352a0d947a6e3d932d2ab9075dedb97"})),s("gov-backdrop",{key:"507610e5a61b34be2166fb4a30539a134dc1b262",inverse:true}))}get host(){return this}static get watchers(){return{size:["validateSize"]}}},[4,"gov-loading",{size:[1]},undefined,{size:["validateSize"]}]);function l(){if(typeof customElements==="undefined"){return}const e=["gov-loading","gov-backdrop","gov-icon"];e.forEach((e=>{switch(e){case"gov-loading":if(!customElements.get(e)){customElements.define(e,g)}break;case"gov-backdrop":if(!customElements.get(e)){r()}break;case"gov-icon":if(!customElements.get(e)){m()}break}}))}l();const b=g;const v=l;export{b as GovLoading,v as defineCustomElement};
1
+ import{p as e,H as o,h as s,d as t}from"./p-42200001.js";import{p as a}from"./p-e0e2e9c1.js";import{S as i}from"./p-92f420cb.js";import{g as c,p as n}from"./p-ea7fdd2e.js";import{v as d}from"./p-0b3574c2.js";import{d as r}from"./p-7be2301a.js";import{d as m}from"./p-a877bf8a.js";const p=a(i,["_S","_M","_L"]);const f={root:"gov-loading",content:"gov-loading__content",icon:"gov-loading__icon"};const g=e(class e extends o{constructor(){super();this.__registerHost();this.size="m";this.h=c(this.host)}validateSize(e){d(p,e,f.root)}componentWillLoad(){this.validateSize(this.size)}render(){return s(t,{key:"4c33339523674f2f2415dfb326131858de9eecf9",class:this.h.classes(f.root),size:this.size},s("div",{key:"8c25628dd3072fd89665ccfedb9596383181b13d",class:f.content},s("gov-icon",{key:"a9969874350b5316c61a94b12d41a0130eeded0f",class:n([f.icon,"gov-spin-animation"]),name:"loader",type:"components"}),s("slot",{key:"14c716ecc352a0d947a6e3d932d2ab9075dedb97"})),s("gov-backdrop",{key:"507610e5a61b34be2166fb4a30539a134dc1b262",inverse:true}))}get host(){return this}static get watchers(){return{size:["validateSize"]}}},[4,"gov-loading",{size:[1]},undefined,{size:["validateSize"]}]);function l(){if(typeof customElements==="undefined"){return}const e=["gov-loading","gov-backdrop","gov-icon"];e.forEach((e=>{switch(e){case"gov-loading":if(!customElements.get(e)){customElements.define(e,g)}break;case"gov-backdrop":if(!customElements.get(e)){r()}break;case"gov-icon":if(!customElements.get(e)){m()}break}}))}l();const b=g;const v=l;export{b as GovLoading,v as defineCustomElement};
2
2
  //# sourceMappingURL=gov-loading.js.map
@@ -1,2 +1,2 @@
1
- import{p as e,H as s,h as t,d as o}from"./p-115b9cf3.js";import{v as c}from"./p-0b3574c2.js";import{C as a}from"./p-5aad3497.js";import{p as r}from"./p-e0e2e9c1.js";import{g as n}from"./p-ea7fdd2e.js";r(a,["PRIMARY","NEUTRAL","ERROR","SUCCESS","WARNING"]);var i;(function(e){e["BOLD"]="bold";e["SUBTLE"]="subtle"})(i||(i={}));const f={root:"gov-message",content:"gov-message__content"};const l=e(class e extends s{constructor(){super();this.__registerHost();this.color=a.PRIMARY;this.type="subtle";this.h=n(this.host)}validateColor(e){c(a,e,f.root)}render(){return t(o,{key:"b9e06c8f94940edf9d2c60119c35ec32baa23fc9",class:this.h.classes(f.root),color:this.color,type:this.type,role:"status"},this.h.hasSlot("icon")&&t("slot",{key:"d478f414de8eaa276cc867ae5bb325c1090b08ac",name:"icon"}),t("div",{key:"d5a113ca4061b445c583fb1b4f22fff594570b1e",class:f.content},t("slot",{key:"e9be2f4ff3603c5f77d46e042455174e6ccfb7be"})))}get host(){return this}static get watchers(){return{color:["validateColor"]}}},[4,"gov-message",{color:[1],type:[1]},undefined,{color:["validateColor"]}]);function m(){if(typeof customElements==="undefined"){return}const e=["gov-message"];e.forEach((e=>{switch(e){case"gov-message":if(!customElements.get(e)){customElements.define(e,l)}break}}))}m();const d=l;const b=m;export{d as GovMessage,b as defineCustomElement};
1
+ import{p as e,H as s,h as t,d as o}from"./p-42200001.js";import{v as c}from"./p-0b3574c2.js";import{C as a}from"./p-5aad3497.js";import{p as r}from"./p-e0e2e9c1.js";import{g as n}from"./p-ea7fdd2e.js";r(a,["PRIMARY","NEUTRAL","ERROR","SUCCESS","WARNING"]);var i;(function(e){e["BOLD"]="bold";e["SUBTLE"]="subtle"})(i||(i={}));const f={root:"gov-message",content:"gov-message__content"};const l=e(class e extends s{constructor(){super();this.__registerHost();this.color=a.PRIMARY;this.type="subtle";this.h=n(this.host)}validateColor(e){c(a,e,f.root)}render(){return t(o,{key:"b9e06c8f94940edf9d2c60119c35ec32baa23fc9",class:this.h.classes(f.root),color:this.color,type:this.type,role:"status"},this.h.hasSlot("icon")&&t("slot",{key:"d478f414de8eaa276cc867ae5bb325c1090b08ac",name:"icon"}),t("div",{key:"d5a113ca4061b445c583fb1b4f22fff594570b1e",class:f.content},t("slot",{key:"e9be2f4ff3603c5f77d46e042455174e6ccfb7be"})))}get host(){return this}static get watchers(){return{color:["validateColor"]}}},[4,"gov-message",{color:[1],type:[1]},undefined,{color:["validateColor"]}]);function m(){if(typeof customElements==="undefined"){return}const e=["gov-message"];e.forEach((e=>{switch(e){case"gov-message":if(!customElements.get(e)){customElements.define(e,l)}break}}))}m();const d=l;const b=m;export{d as GovMessage,b as defineCustomElement};
2
2
  //# sourceMappingURL=gov-message.js.map
@@ -1,2 +1,2 @@
1
- import{p as t,H as e,c as s,h as i,d as a}from"./p-115b9cf3.js";import{F as o}from"./p-1c1d0bbe.js";import{v as n}from"./p-0b3574c2.js";import{S as l}from"./p-92f420cb.js";import{C as r}from"./p-5aad3497.js";import{p as c}from"./p-e0e2e9c1.js";import{g as h,p,t as d}from"./p-ea7fdd2e.js";import{c as g}from"./p-cd6c2938.js";import{c as m}from"./p-ded281e6.js";import{A as u,a as f,i as v}from"./p-33d5d1ed.js";import{d as b}from"./p-9b0f446d.js";import{d as j}from"./p-51693b62.js";import{d as y}from"./p-7f0c6ba3.js";const S=c(l,["_S","_M"]);const P=c(r,["PRIMARY","NEUTRAL"]);var z;(function(t){t["BUTTON"]="button";t["SELECT"]="select"})(z||(z={}));const _={root:"gov-pagination",list:"gov-pagination__list",item:"gov-pagination__item",itemArrow:"gov-pagination__item--arrow",itemMore:"gov-pagination__item--more",itemSelect:"gov-pagination__item--select",inner:"gov-pagination__inner",arrow:"gov-pagination__arrow"};function k(t,e=1,s=10,i=10){const a=Math.ceil(t/s);if(e<1){e=1}else if(e>a){e=a}let o,n;if(a<=i){o=1;n=a}else{const t=Math.floor(i/2);const s=Math.ceil(i/2)-1;if(e<=t){o=1;n=i}else if(e+s>=a){o=a-i+1;n=a}else{o=e-t;n=e+s}}const l=(e-1)*s;const r=Math.min(l+s-1,t-1);const c=Array.from(Array(n+1-o).keys()).map((t=>o+t));return{totalItems:t,currentPage:e,pageSize:s,totalPages:a,startPage:o,endPage:n,startIndex:l,endIndex:r,pages:c}}const A=t(class t extends e{constructor(){super();this.__registerHost();this.govPage=s(this,"gov-page",7);this.type="button";this.current=1;this.total=0;this.selectIdentifier=undefined;this.size="m";this.color="primary";this.pageSize=10;this.maxPages=5;this.link=undefined;this.accessibleSelectLabel="Vybrat stranu";this.accessiblePageLabel="Strana";this.labelPrev="Přejít o stranu zpět";this.labelStart="Přejít na začátek";this.labelNext="Přejít na další stranu";this.labelEnd="Přejít na konec";this.pagination=undefined;this.inheritedAttributes={};this.h=h(this.host);this.pageSelectId=g("GovPageSelect");this.selectId=g("GovSelect")}validateType(t){n(z,t,_.root)}validateSize(t){n(S,t,_.root)}validateColor(t){n(P,t,_.root)}recalculate(){this.recalculatePagination(this.current)}componentDidLoad(){this.attributeObserver=new u(this.host,((t,e)=>{this.onAriaAttributeChange(t,e)}));this.attributeObserver.startObserving(f)}componentWillLoad(){this.recalculatePagination(this.current);this.validateSize(this.size);this.validateColor(this.color);this.inheritedAttributes=v(this.host)}disconnectedCallback(){this.attributeObserver.stopObserving()}onAriaAttributeChange(t,e){this.host.removeAttribute(t);this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{[t]:e})}recalculatePagination(t){this.pagination=k(this.total,t,this.pageSize,this.maxPages)}isActivePageClass(t,e){if(this.pagination.currentPage===e){return t+" is-active"}else{return t}}prepareLinkUrl(t){if(this.link){return String(this.link).replace("{PAGE}",String(t))}return undefined}resetSelectValue(){if(this.spreadSelectRef){this.spreadSelectRef.getRef().then((t=>{t.value="..."}))}}render(){const t=(t,e,s)=>{const a=t===-1;const o=d(this.pagination.currentPage===t?true:undefined);return i("gov-button",{href:this.prepareLinkUrl(t),color:this.color,size:this.size,type:"base",disabled:a,"on-gov-click":e=>this.onClickHandler(e,t),"aria-label":s?s:t>-1?`${this.accessiblePageLabel} ${t}`:undefined,"aria-current":o,class:_.inner,focusable:true},e)};return i(a,{class:this.h.classes(_.root),type:this.type,color:this.color,size:this.size},i("nav",Object.assign({},this.inheritedAttributes),i("ul",{class:_.list},i("li",{class:p([_.item,_.itemArrow])},t(this.pagination.currentPage>1?1:-1,i("gov-icon",{class:_.arrow,name:"chevron-double-left",type:"components"}),this.labelStart)),i("li",{class:p([_.item,_.itemArrow])},t(this.pagination.startPage<this.pagination.currentPage?this.pagination.currentPage-1:-1,i("gov-icon",{class:_.arrow,name:"chevron-left",type:"components"}),this.labelPrev)),this.type=="select"?i("li",{class:p([_.item,_.itemSelect])},i("span",{class:_.inner},i("span",{id:this.pageSelectId,hidden:true},this.accessibleSelectLabel),i("gov-form-select",{size:this.size,color:this.color,identifier:this.selectIdentifier||this.selectId,"aria-labelledby":this.pageSelectId,"on-gov-change":this.onSelectHandler.bind(this)},m(1,this.pagination.totalPages).map((t=>i("option",{value:t,selected:this.pagination.currentPage===t},t)))))):i(o,null,this.pagination.pages.map((e=>i("li",{class:this.isActivePageClass(_.item,e)},t(e,e,"")))),this.pagination.totalPages?i("li",{class:p([_.item,_.itemMore])},i("span",{class:_.inner},i("span",{id:this.pageSelectId,hidden:true},this.accessibleSelectLabel),i("gov-form-select",{size:this.size,color:this.color,identifier:this.selectIdentifier||this.selectId,"aria-labelledby":this.pageSelectId,ref:t=>this.spreadSelectRef=t,"on-gov-change":this.onSelectHandler.bind(this)},i("option",{selected:true,hidden:true},"..."),m(1,this.pagination.totalPages).map((t=>i("option",{value:t,selected:false},t)))))):null),i("li",{class:p([_.item,_.itemArrow])},t(this.pagination.totalPages>this.pagination.currentPage?this.pagination.currentPage+1:-1,i("gov-icon",{class:_.arrow,name:"chevron-right",type:"components"}),this.labelNext)),i("li",{class:p([_.item,_.itemArrow])},t(this.pagination.totalPages>this.pagination.currentPage?this.pagination.totalPages:-1,i("gov-icon",{class:_.arrow,name:"chevron-double-right",type:"components"}),this.labelEnd)))))}onClickHandler(t,e){t.stopPropagation();this.recalculatePagination(e);this.govPage.emit({component:_.root,pagination:this.pagination})}onSelectHandler(t){t.stopPropagation();const e=t.detail.value;const s=parseInt(e);this.resetSelectValue();if(isNaN(s)===false){this.recalculatePagination(s);if(this.link){window.location.href=this.prepareLinkUrl(s)}else{this.govPage.emit({component:_.root,pagination:this.pagination})}}}get host(){return this}static get watchers(){return{type:["validateType"],size:["validateSize"],color:["validateColor"],current:["recalculate"],total:["recalculate"],pageSize:["recalculate"],maxPages:["recalculate"]}}},[0,"gov-pagination",{type:[1],current:[2],total:[2],selectIdentifier:[1,"select-identifier"],size:[1],color:[1],pageSize:[2,"page-size"],maxPages:[2,"max-pages"],link:[1],accessibleSelectLabel:[1,"accessible-select-label"],accessiblePageLabel:[1,"accessible-page-label"],labelPrev:[1,"label-prev"],labelStart:[1,"label-start"],labelNext:[1,"label-next"],labelEnd:[1,"label-end"],pagination:[32],inheritedAttributes:[32]},undefined,{type:["validateType"],size:["validateSize"],color:["validateColor"],current:["recalculate"],total:["recalculate"],pageSize:["recalculate"],maxPages:["recalculate"]}]);function x(){if(typeof customElements==="undefined"){return}const t=["gov-pagination","gov-button","gov-form-select","gov-icon"];t.forEach((t=>{switch(t){case"gov-pagination":if(!customElements.get(t)){customElements.define(t,A)}break;case"gov-button":if(!customElements.get(t)){b()}break;case"gov-form-select":if(!customElements.get(t)){j()}break;case"gov-icon":if(!customElements.get(t)){y()}break}}))}x();const w=A;const E=x;export{w as GovPagination,E as defineCustomElement};
1
+ import{p as t,H as e,c as s,h as i,d as a}from"./p-42200001.js";import{F as o}from"./p-1c1d0bbe.js";import{v as n}from"./p-0b3574c2.js";import{S as l}from"./p-92f420cb.js";import{C as r}from"./p-5aad3497.js";import{p as c}from"./p-e0e2e9c1.js";import{g as h,p,t as d}from"./p-ea7fdd2e.js";import{c as g}from"./p-cd6c2938.js";import{c as m}from"./p-ded281e6.js";import{A as u,a as f,i as v}from"./p-33d5d1ed.js";import{d as b}from"./p-558cbab0.js";import{d as j}from"./p-13a70392.js";import{d as y}from"./p-a877bf8a.js";const S=c(l,["_S","_M"]);const P=c(r,["PRIMARY","NEUTRAL"]);var z;(function(t){t["BUTTON"]="button";t["SELECT"]="select"})(z||(z={}));const _={root:"gov-pagination",list:"gov-pagination__list",item:"gov-pagination__item",itemArrow:"gov-pagination__item--arrow",itemMore:"gov-pagination__item--more",itemSelect:"gov-pagination__item--select",inner:"gov-pagination__inner",arrow:"gov-pagination__arrow"};function k(t,e=1,s=10,i=10){const a=Math.ceil(t/s);if(e<1){e=1}else if(e>a){e=a}let o,n;if(a<=i){o=1;n=a}else{const t=Math.floor(i/2);const s=Math.ceil(i/2)-1;if(e<=t){o=1;n=i}else if(e+s>=a){o=a-i+1;n=a}else{o=e-t;n=e+s}}const l=(e-1)*s;const r=Math.min(l+s-1,t-1);const c=Array.from(Array(n+1-o).keys()).map((t=>o+t));return{totalItems:t,currentPage:e,pageSize:s,totalPages:a,startPage:o,endPage:n,startIndex:l,endIndex:r,pages:c}}const A=t(class t extends e{constructor(){super();this.__registerHost();this.govPage=s(this,"gov-page",7);this.type="button";this.current=1;this.total=0;this.selectIdentifier=undefined;this.size="m";this.color="primary";this.pageSize=10;this.maxPages=5;this.link=undefined;this.accessibleSelectLabel="Vybrat stranu";this.accessiblePageLabel="Strana";this.labelPrev="Přejít o stranu zpět";this.labelStart="Přejít na začátek";this.labelNext="Přejít na další stranu";this.labelEnd="Přejít na konec";this.pagination=undefined;this.inheritedAttributes={};this.h=h(this.host);this.pageSelectId=g("GovPageSelect");this.selectId=g("GovSelect")}validateType(t){n(z,t,_.root)}validateSize(t){n(S,t,_.root)}validateColor(t){n(P,t,_.root)}recalculate(){this.recalculatePagination(this.current)}componentDidLoad(){this.attributeObserver=new u(this.host,((t,e)=>{this.onAriaAttributeChange(t,e)}));this.attributeObserver.startObserving(f)}componentWillLoad(){this.recalculatePagination(this.current);this.validateSize(this.size);this.validateColor(this.color);this.inheritedAttributes=v(this.host)}disconnectedCallback(){this.attributeObserver.stopObserving()}onAriaAttributeChange(t,e){this.host.removeAttribute(t);this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{[t]:e})}recalculatePagination(t){this.pagination=k(this.total,t,this.pageSize,this.maxPages)}isActivePageClass(t,e){if(this.pagination.currentPage===e){return t+" is-active"}else{return t}}prepareLinkUrl(t){if(this.link){return String(this.link).replace("{PAGE}",String(t))}return undefined}resetSelectValue(){if(this.spreadSelectRef){this.spreadSelectRef.getRef().then((t=>{t.value="..."}))}}render(){const t=(t,e,s)=>{const a=t===-1;const o=d(this.pagination.currentPage===t?true:undefined);return i("gov-button",{href:this.prepareLinkUrl(t),color:this.color,size:this.size,type:"base",disabled:a,"on-gov-click":e=>this.onClickHandler(e,t),"aria-label":s?s:t>-1?`${this.accessiblePageLabel} ${t}`:undefined,"aria-current":o,class:_.inner,focusable:true},e)};return i(a,{class:this.h.classes(_.root),type:this.type,color:this.color,size:this.size},i("nav",Object.assign({},this.inheritedAttributes),i("ul",{class:_.list},i("li",{class:p([_.item,_.itemArrow])},t(this.pagination.currentPage>1?1:-1,i("gov-icon",{class:_.arrow,name:"chevron-double-left",type:"components"}),this.labelStart)),i("li",{class:p([_.item,_.itemArrow])},t(this.pagination.startPage<this.pagination.currentPage?this.pagination.currentPage-1:-1,i("gov-icon",{class:_.arrow,name:"chevron-left",type:"components"}),this.labelPrev)),this.type=="select"?i("li",{class:p([_.item,_.itemSelect])},i("span",{class:_.inner},i("span",{id:this.pageSelectId,hidden:true},this.accessibleSelectLabel),i("gov-form-select",{size:this.size,color:this.color,identifier:this.selectIdentifier||this.selectId,"aria-labelledby":this.pageSelectId,"on-gov-change":this.onSelectHandler.bind(this)},m(1,this.pagination.totalPages).map((t=>i("option",{value:t,selected:this.pagination.currentPage===t},t)))))):i(o,null,this.pagination.pages.map((e=>i("li",{class:this.isActivePageClass(_.item,e)},t(e,e,"")))),this.pagination.totalPages?i("li",{class:p([_.item,_.itemMore])},i("span",{class:_.inner},i("span",{id:this.pageSelectId,hidden:true},this.accessibleSelectLabel),i("gov-form-select",{size:this.size,color:this.color,identifier:this.selectIdentifier||this.selectId,"aria-labelledby":this.pageSelectId,ref:t=>this.spreadSelectRef=t,"on-gov-change":this.onSelectHandler.bind(this)},i("option",{selected:true,hidden:true},"..."),m(1,this.pagination.totalPages).map((t=>i("option",{value:t,selected:false},t)))))):null),i("li",{class:p([_.item,_.itemArrow])},t(this.pagination.totalPages>this.pagination.currentPage?this.pagination.currentPage+1:-1,i("gov-icon",{class:_.arrow,name:"chevron-right",type:"components"}),this.labelNext)),i("li",{class:p([_.item,_.itemArrow])},t(this.pagination.totalPages>this.pagination.currentPage?this.pagination.totalPages:-1,i("gov-icon",{class:_.arrow,name:"chevron-double-right",type:"components"}),this.labelEnd)))))}onClickHandler(t,e){t.stopPropagation();this.recalculatePagination(e);this.govPage.emit({component:_.root,pagination:this.pagination})}onSelectHandler(t){t.stopPropagation();const e=t.detail.value;const s=parseInt(e);this.resetSelectValue();if(isNaN(s)===false){this.recalculatePagination(s);if(this.link){window.location.href=this.prepareLinkUrl(s)}else{this.govPage.emit({component:_.root,pagination:this.pagination})}}}get host(){return this}static get watchers(){return{type:["validateType"],size:["validateSize"],color:["validateColor"],current:["recalculate"],total:["recalculate"],pageSize:["recalculate"],maxPages:["recalculate"]}}},[0,"gov-pagination",{type:[1],current:[2],total:[2],selectIdentifier:[1,"select-identifier"],size:[1],color:[1],pageSize:[2,"page-size"],maxPages:[2,"max-pages"],link:[1],accessibleSelectLabel:[1,"accessible-select-label"],accessiblePageLabel:[1,"accessible-page-label"],labelPrev:[1,"label-prev"],labelStart:[1,"label-start"],labelNext:[1,"label-next"],labelEnd:[1,"label-end"],pagination:[32],inheritedAttributes:[32]},undefined,{type:["validateType"],size:["validateSize"],color:["validateColor"],current:["recalculate"],total:["recalculate"],pageSize:["recalculate"],maxPages:["recalculate"]}]);function x(){if(typeof customElements==="undefined"){return}const t=["gov-pagination","gov-button","gov-form-select","gov-icon"];t.forEach((t=>{switch(t){case"gov-pagination":if(!customElements.get(t)){customElements.define(t,A)}break;case"gov-button":if(!customElements.get(t)){b()}break;case"gov-form-select":if(!customElements.get(t)){j()}break;case"gov-icon":if(!customElements.get(t)){y()}break}}))}x();const w=A;const E=x;export{w as GovPagination,E as defineCustomElement};
2
2
  //# sourceMappingURL=gov-pagination.js.map
@@ -1,2 +1,2 @@
1
- import{G as o,d as s}from"./p-350e060c.js";const t=o;const c=s;export{t as GovSkeleton,c as defineCustomElement};
1
+ import{G as o,d as s}from"./p-b97d8edd.js";const d=o;const t=s;export{d as GovSkeleton,t as defineCustomElement};
2
2
  //# sourceMappingURL=gov-skeleton.js.map
@@ -1,2 +1,2 @@
1
- import{p as e,H as t,h as s,d as i}from"./p-115b9cf3.js";import{v as a}from"./p-0b3574c2.js";import{S as o}from"./p-92f420cb.js";import{p as n}from"./p-e0e2e9c1.js";import{g as r}from"./p-ea7fdd2e.js";const c=n(o,["_2XS","_XS","_S","_M","_L","_XL","_2XL","_3XL","_4XL"]);var p;(function(e){e["NONE"]="none";e["SM"]="sm";e["MD"]="md";e["LG"]="lg";e["XL"]="xl"})(p||(p={}));const d={root:"gov-spacer"};const f=e(class e extends t{constructor(){super();this.__registerHost();this.size=undefined;this.breakpoint=undefined;this.h=r(this.host)}validateSize(e){a(c,e,d.root)}validateBreakpoint(e){a(p,e,d.root)}componentWillLoad(){this.validateSize(this.size);this.validateBreakpoint(this.breakpoint)}render(){return s(i,{key:"23aedb7f3b112a356319aba076eedf9a4743e25b",class:this.h.classes(d.root),size:this.size,breakpoint:this.breakpoint})}get host(){return this}static get watchers(){return{size:["validateSize"],breakpoint:["validateBreakpoint"]}}},[0,"gov-spacer",{size:[1],breakpoint:[1]},undefined,{size:["validateSize"],breakpoint:["validateBreakpoint"]}]);function m(){if(typeof customElements==="undefined"){return}const e=["gov-spacer"];e.forEach((e=>{switch(e){case"gov-spacer":if(!customElements.get(e)){customElements.define(e,f)}break}}))}m();const h=f;const l=m;export{h as GovSpacer,l as defineCustomElement};
1
+ import{p as e,H as t,h as s,d as i}from"./p-42200001.js";import{v as a}from"./p-0b3574c2.js";import{S as o}from"./p-92f420cb.js";import{p as n}from"./p-e0e2e9c1.js";import{g as r}from"./p-ea7fdd2e.js";const c=n(o,["_2XS","_XS","_S","_M","_L","_XL","_2XL","_3XL","_4XL"]);var p;(function(e){e["NONE"]="none";e["SM"]="sm";e["MD"]="md";e["LG"]="lg";e["XL"]="xl"})(p||(p={}));const d={root:"gov-spacer"};const m=e(class e extends t{constructor(){super();this.__registerHost();this.size=undefined;this.breakpoint=undefined;this.h=r(this.host)}validateSize(e){a(c,e,d.root)}validateBreakpoint(e){a(p,e,d.root)}componentWillLoad(){this.validateSize(this.size);this.validateBreakpoint(this.breakpoint)}render(){return s(i,{key:"23aedb7f3b112a356319aba076eedf9a4743e25b",class:this.h.classes(d.root),size:this.size,breakpoint:this.breakpoint})}get host(){return this}static get watchers(){return{size:["validateSize"],breakpoint:["validateBreakpoint"]}}},[0,"gov-spacer",{size:[1],breakpoint:[1]},undefined,{size:["validateSize"],breakpoint:["validateBreakpoint"]}]);function f(){if(typeof customElements==="undefined"){return}const e=["gov-spacer"];e.forEach((e=>{switch(e){case"gov-spacer":if(!customElements.get(e)){customElements.define(e,m)}break}}))}f();const h=m;const l=f;export{h as GovSpacer,l as defineCustomElement};
2
2
  //# sourceMappingURL=gov-spacer.js.map
@@ -1,2 +1,2 @@
1
- import{p as e,H as t,c as s,h as a,d as c}from"./p-115b9cf3.js";import{v as o}from"./p-0b3574c2.js";import{S as i,c as d}from"./p-a521c59a.js";import{c as r}from"./p-cd6c2938.js";import{g as n}from"./p-ea7fdd2e.js";const f=e(class e extends t{constructor(){super();this.__registerHost();this.govChange=s(this,"gov-change",7);this.hydrated=false;this.color="primary";this.size="m";this.identifier=undefined;this.h=n(this.host);this.triggerId=r("GovStepperItem");this.contentId=r("GovStepperContent")}validateColor(e){o(d,e,i.root)}componentWillLoad(){this.validateColor(this.color)}connectedCallback(){this.hydrated=true}render(){const e=this.identifier||this.triggerId;const t=this.contentId;return a(c,{key:"c24400b8ee5917005e6e3a21f47024c7ebad2960",id:e,class:this.h.classes(i.root),color:this.color,role:"listitem",hydrated:this.hydrated},this.h.hasSlot("prefix")&&a("span",{key:"010401daa60b44eed322de007fdd6e4ca035ff8d",class:i.prefix},a("slot",{key:"27287e54365c7e72e01dd21f8d07f7144dc03f3c",name:"prefix"})),a("div",{key:"b50e23ee80b270bb5bb781c46e2cf2de73cad1bb"},a("span",{key:"84500822ca2e529bff5e5cf4eb7ac7c9f0fc9d97",class:i.headline},a("slot",{key:"18410e07be87715a96540789a82403bfab45e55c",name:"headline"})),a("slot",{key:"dd2c20b9f07d2bcbf4223eca8de0d7592d178e86",name:"annotation"}),this.h.hasSlot("content")&&a("div",{key:"cd34d17b5a14816dd91ee84f91a14217952bcfe5",class:i.content,id:t,"aria-labelledby":e,role:"tabpanel"},a("slot",{key:"c90f411f8d63c6381f55a0e6ac819369a9bfd2e5",name:"content"}))))}get host(){return this}static get watchers(){return{color:["validateColor"]}}},[4,"gov-stepper-item",{color:[1],size:[1],identifier:[1]},undefined,{color:["validateColor"]}]);function l(){if(typeof customElements==="undefined"){return}const e=["gov-stepper-item"];e.forEach((e=>{switch(e){case"gov-stepper-item":if(!customElements.get(e)){customElements.define(e,f)}break}}))}l();const p=f;const b=l;export{p as GovStepperItem,b as defineCustomElement};
1
+ import{p as e,H as t,c as s,h as a,d as c}from"./p-42200001.js";import{v as o}from"./p-0b3574c2.js";import{S as i,c as d}from"./p-a521c59a.js";import{c as r}from"./p-cd6c2938.js";import{g as n}from"./p-ea7fdd2e.js";const f=e(class e extends t{constructor(){super();this.__registerHost();this.govChange=s(this,"gov-change",7);this.hydrated=false;this.color="primary";this.size="m";this.identifier=undefined;this.h=n(this.host);this.triggerId=r("GovStepperItem");this.contentId=r("GovStepperContent")}validateColor(e){o(d,e,i.root)}componentWillLoad(){this.validateColor(this.color)}connectedCallback(){this.hydrated=true}render(){const e=this.identifier||this.triggerId;const t=this.contentId;return a(c,{key:"c24400b8ee5917005e6e3a21f47024c7ebad2960",id:e,class:this.h.classes(i.root),color:this.color,role:"listitem",hydrated:this.hydrated},this.h.hasSlot("prefix")&&a("span",{key:"010401daa60b44eed322de007fdd6e4ca035ff8d",class:i.prefix},a("slot",{key:"27287e54365c7e72e01dd21f8d07f7144dc03f3c",name:"prefix"})),a("div",{key:"b50e23ee80b270bb5bb781c46e2cf2de73cad1bb"},a("span",{key:"84500822ca2e529bff5e5cf4eb7ac7c9f0fc9d97",class:i.headline},a("slot",{key:"18410e07be87715a96540789a82403bfab45e55c",name:"headline"})),a("slot",{key:"dd2c20b9f07d2bcbf4223eca8de0d7592d178e86",name:"annotation"}),this.h.hasSlot("content")&&a("div",{key:"cd34d17b5a14816dd91ee84f91a14217952bcfe5",class:i.content,id:t,"aria-labelledby":e,role:"tabpanel"},a("slot",{key:"c90f411f8d63c6381f55a0e6ac819369a9bfd2e5",name:"content"}))))}get host(){return this}static get watchers(){return{color:["validateColor"]}}},[4,"gov-stepper-item",{color:[1],size:[1],identifier:[1]},undefined,{color:["validateColor"]}]);function l(){if(typeof customElements==="undefined"){return}const e=["gov-stepper-item"];e.forEach((e=>{switch(e){case"gov-stepper-item":if(!customElements.get(e)){customElements.define(e,f)}break}}))}l();const p=f;const h=l;export{p as GovStepperItem,h as defineCustomElement};
2
2
  //# sourceMappingURL=gov-stepper-item.js.map
@@ -1,2 +1,2 @@
1
- import{p as s,H as e,c as t,h as i,d as a}from"./p-115b9cf3.js";import{v as o}from"./p-0b3574c2.js";import{S as c,a as r,b as n}from"./p-a521c59a.js";import{g as d}from"./p-ea7fdd2e.js";const h=s(class s extends e{constructor(){super();this.__registerHost();this.govChange=t(this,"gov-change",7);this.hydrated=false;this.size="m";this.h=d(this.host)}validateSize(s){o(n,s,r.root)}componentWillLoad(){this.validateSize(this.size)}componentDidLoad(){this.host.querySelectorAll(c.root).forEach((s=>{s.setAttribute("size",this.size);s.addEventListener("gov-change",(s=>{s.stopPropagation();this.govChange.emit(s.detail)}))}))}connectedCallback(){this.hydrated=true}render(){return i(a,{key:"0815470dbe86e888ab922139e6f02347f89f4700",class:this.h.classes(r.root),role:"list",size:this.size,hydrated:this.hydrated},i("slot",{key:"2585c79a48236a8c2d333a437beb4d7f1d9d9d6c"}))}get host(){return this}static get watchers(){return{size:["validateSize"]}}},[4,"gov-stepper",{size:[1]},undefined,{size:["validateSize"]}]);function p(){if(typeof customElements==="undefined"){return}const s=["gov-stepper"];s.forEach((s=>{switch(s){case"gov-stepper":if(!customElements.get(s)){customElements.define(s,h)}break}}))}p();const f=h;const m=p;export{f as GovStepper,m as defineCustomElement};
1
+ import{p as s,H as e,c as t,h as i,d as a}from"./p-42200001.js";import{v as o}from"./p-0b3574c2.js";import{S as r,a as c,b as n}from"./p-a521c59a.js";import{g as d}from"./p-ea7fdd2e.js";const h=s(class s extends e{constructor(){super();this.__registerHost();this.govChange=t(this,"gov-change",7);this.hydrated=false;this.size="m";this.h=d(this.host)}validateSize(s){o(n,s,c.root)}componentWillLoad(){this.validateSize(this.size)}componentDidLoad(){this.host.querySelectorAll(r.root).forEach((s=>{s.setAttribute("size",this.size);s.addEventListener("gov-change",(s=>{s.stopPropagation();this.govChange.emit(s.detail)}))}))}connectedCallback(){this.hydrated=true}render(){return i(a,{key:"0815470dbe86e888ab922139e6f02347f89f4700",class:this.h.classes(c.root),role:"list",size:this.size,hydrated:this.hydrated},i("slot",{key:"2585c79a48236a8c2d333a437beb4d7f1d9d9d6c"}))}get host(){return this}static get watchers(){return{size:["validateSize"]}}},[4,"gov-stepper",{size:[1]},undefined,{size:["validateSize"]}]);function p(){if(typeof customElements==="undefined"){return}const s=["gov-stepper"];s.forEach((s=>{switch(s){case"gov-stepper":if(!customElements.get(s)){customElements.define(s,h)}break}}))}p();const m=h;const f=p;export{m as GovStepper,f as defineCustomElement};
2
2
  //# sourceMappingURL=gov-stepper.js.map
@@ -1,2 +1,2 @@
1
- import{p as e,H as t,h as i,d as s}from"./p-115b9cf3.js";import{c as r}from"./p-cd6c2938.js";import{g as a,t as n}from"./p-ea7fdd2e.js";import{a as d,T as c}from"./p-860520b0.js";const h=e(class e extends t{constructor(){super();this.__registerHost();this.identifier=undefined;this.triggerIdentifier=undefined;this.label=undefined;this.disabled=false;this.iconStart=undefined;this.iconEnd=undefined;this.default=false;this.isActive=false;this.h=a(this.host);this.contentId=r("GovTabContent");this.triggerId=r("GovTabTrigger")}rerenderParent(){const e=this.h.getParent(d.root);if(e){e.rerender().catch()}}render(){return i(s,{key:"89b01b0d025a89f89085dba24db6b8fadcd97e68",class:this.h.classes(c.root),default:this.default},i("div",{key:"8868371d0da63c1727c8b3a55b930a4d0ce30a3c",class:c.inner,role:"tabpanel",id:this.identifier||this.contentId,hidden:!this.isActive,"aria-labelledby":this.triggerIdentifier||this.triggerId,"aria-hidden":n(!this.isActive)},i("slot",{key:"0d47bea8c416b1c57aac006f9eea9101ade9427d"})))}async getIdentifier(){return this.identifier||this.contentId}async getTriggerIdentifier(){return this.triggerIdentifier||this.triggerId}async getDisableState(){return this.disabled}async setActiveStatus(e){this.isActive=e}get host(){return this}static get watchers(){return{label:["rerenderParent"],disabled:["rerenderParent"]}}},[4,"gov-tabs-item",{identifier:[1],triggerIdentifier:[1,"trigger-identifier"],label:[513],disabled:[516],iconStart:[513,"icon-start"],iconEnd:[513,"icon-end"],default:[4],isActive:[32],getIdentifier:[64],getTriggerIdentifier:[64],getDisableState:[64],setActiveStatus:[64]},undefined,{label:["rerenderParent"],disabled:["rerenderParent"]}]);function o(){if(typeof customElements==="undefined"){return}const e=["gov-tabs-item"];e.forEach((e=>{switch(e){case"gov-tabs-item":if(!customElements.get(e)){customElements.define(e,h)}break}}))}o();const f=h;const b=o;export{f as GovTabsItem,b as defineCustomElement};
1
+ import{p as e,H as t,h as i,d as s}from"./p-42200001.js";import{c as r}from"./p-cd6c2938.js";import{g as a,t as n}from"./p-ea7fdd2e.js";import{a as d,T as c}from"./p-860520b0.js";const h=e(class e extends t{constructor(){super();this.__registerHost();this.identifier=undefined;this.triggerIdentifier=undefined;this.label=undefined;this.disabled=false;this.iconStart=undefined;this.iconEnd=undefined;this.default=false;this.isActive=false;this.h=a(this.host);this.contentId=r("GovTabContent");this.triggerId=r("GovTabTrigger")}rerenderParent(){const e=this.h.getParent(d.root);if(e){e.rerender().catch()}}render(){return i(s,{key:"89b01b0d025a89f89085dba24db6b8fadcd97e68",class:this.h.classes(c.root),default:this.default},i("div",{key:"8868371d0da63c1727c8b3a55b930a4d0ce30a3c",class:c.inner,role:"tabpanel",id:this.identifier||this.contentId,hidden:!this.isActive,"aria-labelledby":this.triggerIdentifier||this.triggerId,"aria-hidden":n(!this.isActive)},i("slot",{key:"0d47bea8c416b1c57aac006f9eea9101ade9427d"})))}async getIdentifier(){return this.identifier||this.contentId}async getTriggerIdentifier(){return this.triggerIdentifier||this.triggerId}async getDisableState(){return this.disabled}async setActiveStatus(e){this.isActive=e}get host(){return this}static get watchers(){return{label:["rerenderParent"],disabled:["rerenderParent"]}}},[4,"gov-tabs-item",{identifier:[1],triggerIdentifier:[1,"trigger-identifier"],label:[513],disabled:[516],iconStart:[513,"icon-start"],iconEnd:[513,"icon-end"],default:[4],isActive:[32],getIdentifier:[64],getTriggerIdentifier:[64],getDisableState:[64],setActiveStatus:[64]},undefined,{label:["rerenderParent"],disabled:["rerenderParent"]}]);function o(){if(typeof customElements==="undefined"){return}const e=["gov-tabs-item"];e.forEach((e=>{switch(e){case"gov-tabs-item":if(!customElements.get(e)){customElements.define(e,h)}break}}))}o();const f=h;const l=o;export{f as GovTabsItem,l as defineCustomElement};
2
2
  //# sourceMappingURL=gov-tabs-item.js.map
@@ -1,2 +1,2 @@
1
- import{p as t,H as s,c as i,h as e,d as o}from"./p-115b9cf3.js";import{v as a}from"./p-0b3574c2.js";import{T as r,a as n,b as h,c,d as l}from"./p-860520b0.js";import{g as d,c as f,b}from"./p-ea7fdd2e.js";import{h as p}from"./p-2aedc81e.js";import{p as u}from"./p-016bbea6.js";import{A as m,a as v,i as g}from"./p-33d5d1ed.js";import{d as y}from"./p-0679f3d6.js";import{d as j}from"./p-7f0c6ba3.js";const k=t(class t extends s{constructor(){super();this.__registerHost();this.govChange=i(this,"gov-change",7);this.triggerRefs={};this.type="text";this.size="m";this.color="primary";this.orientation="horizontal";this.direction="row";this.controllers=[];this.focusIndex=0;this.inheritedAttributes={};this.h=d(this.host)}validateType(t){a(h,t,n.root)}validateColor(t){a(c,t,n.root)}validateSize(t){a(l,t,n.root)}componentDidLoad(){this.attributeObserver=new m(this.host,((t,s)=>{this.onAriaAttributeChange(t,s)}));this.attributeObserver.startObserving(v)}componentWillLoad(){this.prepareControllers();this.validateSize(this.size);this.inheritedAttributes=g(this.host)}disconnectedCallback(){this.attributeObserver.stopObserving()}onAriaAttributeChange(t,s){this.host.removeAttribute(t);this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{[t]:s})}prepareControllers(t=false){this.controllers=[];const s=[];this.host.querySelectorAll(r.root).forEach((t=>{const i=Promise.all([t.getIdentifier(),t.getTriggerIdentifier(),t.getDisableState()]).then((([s,i,e])=>{const o=typeof t.getAttribute("default")==="string";const a=u(t.getAttribute("icon-start"));const r=u(t.getAttribute("icon-end"));return{label:t.getAttribute("label"),direction:t.getAttribute("direction"),contentIdentifier:s,disabled:e,triggerIdentifier:i,element:t,active:false,default:o,iconStart:a,iconEnd:r}}));s.push(i)}));Promise.all(s).then((s=>{if(t===false){let t=s.findIndex((t=>t.default));if(t===-1)t=0;this.focusIndex=t;s[t].active=true}else if(this.focusIndex>-1&&p(s,this.focusIndex)){s[this.focusIndex].active=true}const i=s.findIndex((t=>t.active&&t.disabled));if(i>-1){s[i].active=false;const t=s.findIndex((t=>!t.disabled));if(t>-1){s[t].active=true;this.focusIndex=t}}this.controllers=[...s];this.reRender()}))}setActiveByIdentifier(t){const s=[];this.controllers.map((i=>{i.active=t===i.triggerIdentifier||t===i.contentIdentifier;s.push(i)}));this.controllers=[...s]}reRender(){this.controllers.map((t=>{t.element.setActiveStatus(t.active).catch()}))}render(){return e(o,{key:"4efcbedcc355a74456cc899bc48c7aaf8c604c12",class:this.h.classes(n.root),size:this.size,color:this.color,type:this.type,direction:this.direction,onKeyDown:this.onKeydownHandler.bind(this)},e("div",Object.assign({key:"a64d1a7cadd5950ebc687c3f3d741ea0a59a3684",class:n.tabs,role:"tablist"},this.inheritedAttributes),e("ul",{key:"adab5148c97b041e11f3e7d11a4d87492df5320a",class:n.list},this.controllers.map((t=>e("li",{class:n.item},this.type=="text"?e("button",{class:n.btn,id:t.triggerIdentifier,role:"tab",onClick:()=>this.onSelectHandler(t),disabled:t.disabled,"aria-disabled":f(t.disabled),"aria-selected":f(t.active),"aria-controls":t.contentIdentifier,tabindex:t.active&&!t.disabled?0:-1,ref:s=>this.triggerRefs[t.triggerIdentifier]=s},t.iconStart?e("gov-icon",{name:t.iconStart.name,type:t.iconStart.type}):null,t.label,t.iconEnd?e("gov-icon",{name:t.iconEnd.name,type:t.iconEnd.type}):null):e("gov-chip",{role:"tab",tag:"button",identifier:t.triggerIdentifier,"aria-selected":b(t.active),"aria-controls":t.contentIdentifier,focusable:t.active,disabled:t.disabled,color:this.color,size:this.size==="xs"?"xs":this.size==="s"?"s":"m",type:t.active?"solid":"outlined",ref:s=>this.triggerRefs[t.triggerIdentifier]=s,"on-gov-click":()=>this.onSelectHandler(t)},t.iconStart?e("gov-icon",{name:t.iconStart.name,type:t.iconStart.type,slot:"icon-start"}):null,t.label,t.iconEnd?e("gov-icon",{name:t.iconEnd.name,type:t.iconEnd.type,slot:"icon-end"}):null)))))),e("slot",{key:"2a3720ce9449d62ecd1d58bac806bf356d37375a"}))}getCurrentTab(){return this.controllers.find((t=>t.active))||null}onSelectHandler(t){const s=this.controllers.findIndex((s=>s.triggerIdentifier===t.triggerIdentifier));this.focusIndex=s;this.setActiveByIdentifier(t.triggerIdentifier);this.reRender();this.govChange.emit(this.getCurrentTab().element)}onKeydownHandler(t){const s=t.keyCode;t.stopPropagation();this.goToPrevNext(s)}goToPrevNext(t){if([37,38,39,40].includes(t)){if(false===(this.focusIndex>=0&&this.focusIndex<=this.controllers.length-1)){return}this.controllers[this.focusIndex].active=false;if(t===39||t===40){this.focusIndex++;if(this.focusIndex>=this.controllers.length){this.focusIndex=0}if(this.controllers[this.focusIndex].disabled){this.goToPrevNext(40)}}else if(t===37||t===38){this.focusIndex--;if(this.focusIndex<0){this.focusIndex=this.controllers.length-1}if(this.controllers[this.focusIndex].disabled){this.goToPrevNext(38)}}if(this.focusIndex>=0&&this.focusIndex<=this.controllers.length-1){const t=this.controllers[this.focusIndex];t.active=true;const s=this.triggerRefs[t.triggerIdentifier];if(s.nodeName.toLowerCase()==="gov-chip"){this.triggerRefs[t.triggerIdentifier].setFocus()}else{this.triggerRefs[t.triggerIdentifier].focus()}this.controllers=[...this.controllers];this.reRender();this.govChange.emit(this.getCurrentTab().element)}}}async refresh(){this.prepareControllers()}async currentTab(){return this.getCurrentTab().element||null}async setActiveTab(t){this.setActiveByIdentifier(t);this.reRender()}async rerender(){this.prepareControllers(true)}get host(){return this}static get watchers(){return{type:["validateType"],color:["validateColor"],size:["validateSize"]}}},[4,"gov-tabs",{type:[1],size:[1],color:[1],orientation:[1],direction:[513],controllers:[32],focusIndex:[32],inheritedAttributes:[32],refresh:[64],currentTab:[64],setActiveTab:[64],rerender:[64]},undefined,{type:["validateType"],color:["validateColor"],size:["validateSize"]}]);function T(){if(typeof customElements==="undefined"){return}const t=["gov-tabs","gov-chip","gov-icon"];t.forEach((t=>{switch(t){case"gov-tabs":if(!customElements.get(t)){customElements.define(t,k)}break;case"gov-chip":if(!customElements.get(t)){y()}break;case"gov-icon":if(!customElements.get(t)){j()}break}}))}T();const x=k;const z=T;export{x as GovTabs,z as defineCustomElement};
1
+ import{p as t,H as s,c as i,h as e,d as o}from"./p-42200001.js";import{v as a}from"./p-0b3574c2.js";import{T as r,a as n,b as h,c,d as l}from"./p-860520b0.js";import{g as d,c as f,b}from"./p-ea7fdd2e.js";import{h as p}from"./p-2aedc81e.js";import{p as u}from"./p-016bbea6.js";import{A as m,a as v,i as g}from"./p-33d5d1ed.js";import{d as y}from"./p-076c8b31.js";import{d as j}from"./p-a877bf8a.js";const k=t(class t extends s{constructor(){super();this.__registerHost();this.govChange=i(this,"gov-change",7);this.triggerRefs={};this.type="text";this.size="m";this.color="primary";this.orientation="horizontal";this.direction="row";this.controllers=[];this.focusIndex=0;this.inheritedAttributes={};this.h=d(this.host)}validateType(t){a(h,t,n.root)}validateColor(t){a(c,t,n.root)}validateSize(t){a(l,t,n.root)}componentDidLoad(){this.attributeObserver=new m(this.host,((t,s)=>{this.onAriaAttributeChange(t,s)}));this.attributeObserver.startObserving(v)}componentWillLoad(){this.prepareControllers();this.validateSize(this.size);this.inheritedAttributes=g(this.host)}disconnectedCallback(){this.attributeObserver.stopObserving()}onAriaAttributeChange(t,s){this.host.removeAttribute(t);this.inheritedAttributes=Object.assign(Object.assign({},this.inheritedAttributes),{[t]:s})}prepareControllers(t=false){this.controllers=[];const s=[];this.host.querySelectorAll(r.root).forEach((t=>{const i=Promise.all([t.getIdentifier(),t.getTriggerIdentifier(),t.getDisableState()]).then((([s,i,e])=>{const o=typeof t.getAttribute("default")==="string";const a=u(t.getAttribute("icon-start"));const r=u(t.getAttribute("icon-end"));return{label:t.getAttribute("label"),direction:t.getAttribute("direction"),contentIdentifier:s,disabled:e,triggerIdentifier:i,element:t,active:false,default:o,iconStart:a,iconEnd:r}}));s.push(i)}));Promise.all(s).then((s=>{if(t===false){let t=s.findIndex((t=>t.default));if(t===-1)t=0;this.focusIndex=t;s[t].active=true}else if(this.focusIndex>-1&&p(s,this.focusIndex)){s[this.focusIndex].active=true}const i=s.findIndex((t=>t.active&&t.disabled));if(i>-1){s[i].active=false;const t=s.findIndex((t=>!t.disabled));if(t>-1){s[t].active=true;this.focusIndex=t}}this.controllers=[...s];this.reRender()}))}setActiveByIdentifier(t){const s=[];this.controllers.map((i=>{i.active=t===i.triggerIdentifier||t===i.contentIdentifier;s.push(i)}));this.controllers=[...s]}reRender(){this.controllers.map((t=>{t.element.setActiveStatus(t.active).catch()}))}render(){return e(o,{key:"4efcbedcc355a74456cc899bc48c7aaf8c604c12",class:this.h.classes(n.root),size:this.size,color:this.color,type:this.type,direction:this.direction,onKeyDown:this.onKeydownHandler.bind(this)},e("div",Object.assign({key:"a64d1a7cadd5950ebc687c3f3d741ea0a59a3684",class:n.tabs,role:"tablist"},this.inheritedAttributes),e("ul",{key:"adab5148c97b041e11f3e7d11a4d87492df5320a",class:n.list},this.controllers.map((t=>e("li",{class:n.item},this.type=="text"?e("button",{class:n.btn,id:t.triggerIdentifier,role:"tab",onClick:()=>this.onSelectHandler(t),disabled:t.disabled,"aria-disabled":f(t.disabled),"aria-selected":f(t.active),"aria-controls":t.contentIdentifier,tabindex:t.active&&!t.disabled?0:-1,ref:s=>this.triggerRefs[t.triggerIdentifier]=s},t.iconStart?e("gov-icon",{name:t.iconStart.name,type:t.iconStart.type}):null,t.label,t.iconEnd?e("gov-icon",{name:t.iconEnd.name,type:t.iconEnd.type}):null):e("gov-chip",{role:"tab",tag:"button",identifier:t.triggerIdentifier,"aria-selected":b(t.active),"aria-controls":t.contentIdentifier,focusable:t.active,disabled:t.disabled,color:this.color,size:this.size==="xs"?"xs":this.size==="s"?"s":"m",type:t.active?"solid":"outlined",ref:s=>this.triggerRefs[t.triggerIdentifier]=s,"on-gov-click":()=>this.onSelectHandler(t)},t.iconStart?e("gov-icon",{name:t.iconStart.name,type:t.iconStart.type,slot:"icon-start"}):null,t.label,t.iconEnd?e("gov-icon",{name:t.iconEnd.name,type:t.iconEnd.type,slot:"icon-end"}):null)))))),e("slot",{key:"2a3720ce9449d62ecd1d58bac806bf356d37375a"}))}getCurrentTab(){return this.controllers.find((t=>t.active))||null}onSelectHandler(t){const s=this.controllers.findIndex((s=>s.triggerIdentifier===t.triggerIdentifier));this.focusIndex=s;this.setActiveByIdentifier(t.triggerIdentifier);this.reRender();this.govChange.emit(this.getCurrentTab().element)}onKeydownHandler(t){const s=t.keyCode;t.stopPropagation();this.goToPrevNext(s)}goToPrevNext(t){if([37,38,39,40].includes(t)){if(false===(this.focusIndex>=0&&this.focusIndex<=this.controllers.length-1)){return}this.controllers[this.focusIndex].active=false;if(t===39||t===40){this.focusIndex++;if(this.focusIndex>=this.controllers.length){this.focusIndex=0}if(this.controllers[this.focusIndex].disabled){this.goToPrevNext(40)}}else if(t===37||t===38){this.focusIndex--;if(this.focusIndex<0){this.focusIndex=this.controllers.length-1}if(this.controllers[this.focusIndex].disabled){this.goToPrevNext(38)}}if(this.focusIndex>=0&&this.focusIndex<=this.controllers.length-1){const t=this.controllers[this.focusIndex];t.active=true;const s=this.triggerRefs[t.triggerIdentifier];if(s.nodeName.toLowerCase()==="gov-chip"){this.triggerRefs[t.triggerIdentifier].setFocus()}else{this.triggerRefs[t.triggerIdentifier].focus()}this.controllers=[...this.controllers];this.reRender();this.govChange.emit(this.getCurrentTab().element)}}}async refresh(){this.prepareControllers()}async currentTab(){return this.getCurrentTab().element||null}async setActiveTab(t){this.setActiveByIdentifier(t);this.reRender()}async rerender(){this.prepareControllers(true)}get host(){return this}static get watchers(){return{type:["validateType"],color:["validateColor"],size:["validateSize"]}}},[4,"gov-tabs",{type:[1],size:[1],color:[1],orientation:[1],direction:[513],controllers:[32],focusIndex:[32],inheritedAttributes:[32],refresh:[64],currentTab:[64],setActiveTab:[64],rerender:[64]},undefined,{type:["validateType"],color:["validateColor"],size:["validateSize"]}]);function T(){if(typeof customElements==="undefined"){return}const t=["gov-tabs","gov-chip","gov-icon"];t.forEach((t=>{switch(t){case"gov-tabs":if(!customElements.get(t)){customElements.define(t,k)}break;case"gov-chip":if(!customElements.get(t)){y()}break;case"gov-icon":if(!customElements.get(t)){j()}break}}))}T();const x=k;const z=T;export{x as GovTabs,z as defineCustomElement};
2
2
  //# sourceMappingURL=gov-tabs.js.map