@gov-design-system-ce/components 0.0.49 → 0.0.50

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 (799) hide show
  1. package/dist/cjs/core.cjs.js +6 -2
  2. package/dist/cjs/core.cjs.js.map +1 -1
  3. package/dist/cjs/gov-accordion-item.cjs.entry.js +1 -1
  4. package/dist/cjs/gov-accordion.cjs.entry.js +1 -1
  5. package/dist/cjs/gov-alert.cjs.entry.js +1 -1
  6. package/dist/cjs/gov-app.cjs.entry.js +1 -1
  7. package/dist/cjs/gov-app.cjs.entry.js.map +1 -1
  8. package/dist/cjs/gov-attachments_3.cjs.entry.js +1 -1
  9. package/dist/cjs/gov-backdrop.cjs.entry.js +1 -1
  10. package/dist/cjs/gov-badge.cjs.entry.js +1 -1
  11. package/dist/cjs/gov-breadcrumbs.cjs.entry.js +1 -1
  12. package/dist/cjs/gov-button.cjs.entry.js +1 -1
  13. package/dist/cjs/gov-card.cjs.entry.js +1 -1
  14. package/dist/cjs/gov-container.cjs.entry.js +1 -1
  15. package/dist/cjs/gov-control-group.cjs.entry.js +1 -1
  16. package/dist/cjs/gov-cookiebar.cjs.entry.js +1 -1
  17. package/dist/cjs/gov-dropdown.cjs.entry.js +1 -1
  18. package/dist/cjs/gov-empty.cjs.entry.js +1 -1
  19. package/dist/cjs/gov-error-code.cjs.entry.js +1 -1
  20. package/dist/cjs/gov-form-autocomplete.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.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.cjs.entry.js +1 -1
  30. package/dist/cjs/gov-form-search.cjs.entry.js +1 -1
  31. package/dist/cjs/gov-form-select.cjs.entry.js +1 -1
  32. package/dist/cjs/gov-form-switch.cjs.entry.js +1 -1
  33. package/dist/cjs/gov-grid-item.cjs.entry.js +1 -1
  34. package/dist/cjs/gov-grid.cjs.entry.js +1 -1
  35. package/dist/cjs/gov-icon.cjs.entry.js +1 -1
  36. package/dist/cjs/gov-layout-column.cjs.entry.js +1 -1
  37. package/dist/cjs/gov-layout.cjs.entry.js +1 -1
  38. package/dist/cjs/gov-loading.cjs.entry.js +1 -1
  39. package/dist/cjs/gov-message.cjs.entry.js +1 -1
  40. package/dist/cjs/gov-modal.cjs.entry.js +1 -1
  41. package/dist/cjs/gov-nav-item.cjs.entry.js +1 -1
  42. package/dist/cjs/gov-nav.cjs.entry.js +1 -1
  43. package/dist/cjs/gov-pagination.cjs.entry.js +1 -1
  44. package/dist/cjs/gov-prompt.cjs.entry.js +1 -1
  45. package/dist/cjs/gov-side-nav-item.cjs.entry.js +1 -1
  46. package/dist/cjs/gov-side-nav.cjs.entry.js +1 -1
  47. package/dist/cjs/gov-skeleton.cjs.entry.js +1 -1
  48. package/dist/cjs/gov-spacer.cjs.entry.js +1 -1
  49. package/dist/cjs/gov-statsbar-item.cjs.entry.js +1 -1
  50. package/dist/cjs/gov-statsbar.cjs.entry.js +1 -1
  51. package/dist/cjs/gov-stepper-item.cjs.entry.js +1 -1
  52. package/dist/cjs/gov-stepper.cjs.entry.js +1 -1
  53. package/dist/cjs/gov-tabs-item.cjs.entry.js +1 -1
  54. package/dist/cjs/gov-tabs.cjs.entry.js +1 -1
  55. package/dist/cjs/gov-tabs.cjs.entry.js.map +1 -1
  56. package/dist/cjs/gov-tile.cjs.entry.js +1 -1
  57. package/dist/cjs/gov-tiles.cjs.entry.js +1 -1
  58. package/dist/cjs/gov-toast.cjs.entry.js +1 -1
  59. package/dist/cjs/gov-tooltip-content.cjs.entry.js +1 -1
  60. package/dist/cjs/gov-tooltip.cjs.entry.js +1 -1
  61. package/dist/cjs/gov-wizzard-item.cjs.entry.js +1 -1
  62. package/dist/cjs/gov-wizzard.cjs.entry.js +1 -1
  63. package/dist/cjs/{index-7ba43a19.js → index-83edd4fe.js} +305 -52
  64. package/dist/cjs/index-83edd4fe.js.map +1 -0
  65. package/dist/cjs/loader.cjs.js +3 -11
  66. package/dist/cjs/loader.cjs.js.map +1 -1
  67. package/dist/collection/collection-manifest.json +62 -62
  68. package/dist/collection/components/gov-accordion/constants.js +3 -3
  69. package/dist/collection/components/gov-accordion/gov-accordion-item.js +14 -7
  70. package/dist/collection/components/gov-accordion/gov-accordion-item.js.map +1 -1
  71. package/dist/collection/components/gov-accordion/gov-accordion.js +16 -12
  72. package/dist/collection/components/gov-accordion/gov-accordion.js.map +1 -1
  73. package/dist/collection/components/gov-alert/constants.js +2 -2
  74. package/dist/collection/components/gov-alert/gov-alert.js +6 -3
  75. package/dist/collection/components/gov-alert/gov-alert.js.map +1 -1
  76. package/dist/collection/components/gov-app/gov-app.js +37 -37
  77. package/dist/collection/components/gov-app/gov-app.js.map +1 -1
  78. package/dist/collection/components/gov-attachments/gov-attachments-item.js +10 -8
  79. package/dist/collection/components/gov-attachments/gov-attachments-item.js.map +1 -1
  80. package/dist/collection/components/gov-attachments/gov-attachments.js +8 -7
  81. package/dist/collection/components/gov-attachments/gov-attachments.js.map +1 -1
  82. package/dist/collection/components/gov-backdrop/gov-backdrop.js +10 -8
  83. package/dist/collection/components/gov-backdrop/gov-backdrop.js.map +1 -1
  84. package/dist/collection/components/gov-badge/gov-badge.js +18 -9
  85. package/dist/collection/components/gov-badge/gov-badge.js.map +1 -1
  86. package/dist/collection/components/gov-breadcrumbs/gov-breadcrumbs.js +10 -8
  87. package/dist/collection/components/gov-breadcrumbs/gov-breadcrumbs.js.map +1 -1
  88. package/dist/collection/components/gov-button/default/constants.js +3 -3
  89. package/dist/collection/components/gov-button/default/gov-button.js +26 -13
  90. package/dist/collection/components/gov-button/default/gov-button.js.map +1 -1
  91. package/dist/collection/components/gov-button/dropdown/gov-dropdown.js +8 -4
  92. package/dist/collection/components/gov-button/dropdown/gov-dropdown.js.map +1 -1
  93. package/dist/collection/components/gov-card/gov-card.js +16 -12
  94. package/dist/collection/components/gov-card/gov-card.js.map +1 -1
  95. package/dist/collection/components/gov-container/gov-container.js +7 -5
  96. package/dist/collection/components/gov-container/gov-container.js.map +1 -1
  97. package/dist/collection/components/gov-control-group/constants.js +2 -2
  98. package/dist/collection/components/gov-control-group/gov-control-group.js +2 -1
  99. package/dist/collection/components/gov-control-group/gov-control-group.js.map +1 -1
  100. package/dist/collection/components/gov-cookiebar/gov-cookiebar.js +3 -3
  101. package/dist/collection/components/gov-empty/gov-empty.js +3 -3
  102. package/dist/collection/components/gov-error-code/gov-error-code.js +3 -3
  103. package/dist/collection/components/gov-form/autocomplete/constants.js +3 -3
  104. package/dist/collection/components/gov-form/autocomplete/gov-form-autocomplete.js +30 -15
  105. package/dist/collection/components/gov-form/autocomplete/gov-form-autocomplete.js.map +1 -1
  106. package/dist/collection/components/gov-form/checkbox/constants.js +2 -2
  107. package/dist/collection/components/gov-form/checkbox/gov-form-checkbox.js +14 -7
  108. package/dist/collection/components/gov-form/checkbox/gov-form-checkbox.js.map +1 -1
  109. package/dist/collection/components/gov-form/control/constants.js +2 -2
  110. package/dist/collection/components/gov-form/control/gov-form-control.js +4 -2
  111. package/dist/collection/components/gov-form/control/gov-form-control.js.map +1 -1
  112. package/dist/collection/components/gov-form/file/gov-form-file.js +20 -10
  113. package/dist/collection/components/gov-form/file/gov-form-file.js.map +1 -1
  114. package/dist/collection/components/gov-form/group/gov-form-group.js +2 -1
  115. package/dist/collection/components/gov-form/group/gov-form-group.js.map +1 -1
  116. package/dist/collection/components/gov-form/input/constants.js +3 -3
  117. package/dist/collection/components/gov-form/input/gov-form-input.js +40 -24
  118. package/dist/collection/components/gov-form/input/gov-form-input.js.map +1 -1
  119. package/dist/collection/components/gov-form/label/gov-form-label.js +6 -4
  120. package/dist/collection/components/gov-form/label/gov-form-label.js.map +1 -1
  121. package/dist/collection/components/gov-form/message/constants.js +2 -2
  122. package/dist/collection/components/gov-form/message/gov-form-message.js +9 -7
  123. package/dist/collection/components/gov-form/message/gov-form-message.js.map +1 -1
  124. package/dist/collection/components/gov-form/multiselect/constants.js +3 -3
  125. package/dist/collection/components/gov-form/multiselect/gov-form-multi-select.js +22 -11
  126. package/dist/collection/components/gov-form/multiselect/gov-form-multi-select.js.map +1 -1
  127. package/dist/collection/components/gov-form/password-power/gov-form-password-power.js +2 -2
  128. package/dist/collection/components/gov-form/radio/constants.js +2 -2
  129. package/dist/collection/components/gov-form/radio/gov-form-radio.js +14 -7
  130. package/dist/collection/components/gov-form/radio/gov-form-radio.js.map +1 -1
  131. package/dist/collection/components/gov-form/search/constants.js +2 -2
  132. package/dist/collection/components/gov-form/search/gov-form-search.js +4 -3
  133. package/dist/collection/components/gov-form/search/gov-form-search.js.map +1 -1
  134. package/dist/collection/components/gov-form/select/constants.js +3 -3
  135. package/dist/collection/components/gov-form/select/gov-form-select.js +22 -11
  136. package/dist/collection/components/gov-form/select/gov-form-select.js.map +1 -1
  137. package/dist/collection/components/gov-form/switch/constants.js +2 -2
  138. package/dist/collection/components/gov-form/switch/gov-form-switch.js +14 -7
  139. package/dist/collection/components/gov-form/switch/gov-form-switch.js.map +1 -1
  140. package/dist/collection/components/gov-grid/gov-grid-item.css +0 -44
  141. package/dist/collection/components/gov-grid/gov-grid-item.js +3 -3
  142. package/dist/collection/components/gov-grid/gov-grid.js +3 -3
  143. package/dist/collection/components/gov-icon/gov-icon.js +6 -5
  144. package/dist/collection/components/gov-icon/gov-icon.js.map +1 -1
  145. package/dist/collection/components/gov-layout/gov-layout-column.js +3 -3
  146. package/dist/collection/components/gov-layout/gov-layout.js +7 -5
  147. package/dist/collection/components/gov-layout/gov-layout.js.map +1 -1
  148. package/dist/collection/components/gov-loading/loading/gov-loading.js +3 -3
  149. package/dist/collection/components/gov-loading/skeleton/gov-skeleton.js +8 -4
  150. package/dist/collection/components/gov-loading/skeleton/gov-skeleton.js.map +1 -1
  151. package/dist/collection/components/gov-message/constants.js +2 -2
  152. package/dist/collection/components/gov-message/gov-message.js +7 -6
  153. package/dist/collection/components/gov-message/gov-message.js.map +1 -1
  154. package/dist/collection/components/gov-modal/gov-modal.js +8 -4
  155. package/dist/collection/components/gov-modal/gov-modal.js.map +1 -1
  156. package/dist/collection/components/gov-nav/gov-nav-item.js +3 -3
  157. package/dist/collection/components/gov-nav/gov-nav.js +7 -6
  158. package/dist/collection/components/gov-nav/gov-nav.js.map +1 -1
  159. package/dist/collection/components/gov-pagination/constants.js +3 -3
  160. package/dist/collection/components/gov-pagination/gov-pagination.js +10 -5
  161. package/dist/collection/components/gov-pagination/gov-pagination.js.map +1 -1
  162. package/dist/collection/components/gov-promp/gov-prompt.js +8 -4
  163. package/dist/collection/components/gov-promp/gov-prompt.js.map +1 -1
  164. package/dist/collection/components/gov-side-nav/gov-side-nav-item.js +15 -10
  165. package/dist/collection/components/gov-side-nav/gov-side-nav-item.js.map +1 -1
  166. package/dist/collection/components/gov-side-nav/gov-side-nav.js +10 -8
  167. package/dist/collection/components/gov-side-nav/gov-side-nav.js.map +1 -1
  168. package/dist/collection/components/gov-spacer/constants.js +2 -2
  169. package/dist/collection/components/gov-spacer/gov-spacer.js +8 -6
  170. package/dist/collection/components/gov-spacer/gov-spacer.js.map +1 -1
  171. package/dist/collection/components/gov-statsbar/constants.js +2 -2
  172. package/dist/collection/components/gov-statsbar/gov-statsbar-item.js +6 -5
  173. package/dist/collection/components/gov-statsbar/gov-statsbar-item.js.map +1 -1
  174. package/dist/collection/components/gov-statsbar/gov-statsbar.js +8 -6
  175. package/dist/collection/components/gov-statsbar/gov-statsbar.js.map +1 -1
  176. package/dist/collection/components/gov-stepper/constants.js +3 -3
  177. package/dist/collection/components/gov-stepper/gov-stepper-item.js +14 -10
  178. package/dist/collection/components/gov-stepper/gov-stepper-item.js.map +1 -1
  179. package/dist/collection/components/gov-stepper/gov-stepper.js +8 -6
  180. package/dist/collection/components/gov-stepper/gov-stepper.js.map +1 -1
  181. package/dist/collection/components/gov-tabs/constants.js +2 -2
  182. package/dist/collection/components/gov-tabs/gov-tabs-item.js +10 -7
  183. package/dist/collection/components/gov-tabs/gov-tabs-item.js.map +1 -1
  184. package/dist/collection/components/gov-tabs/gov-tabs.js +29 -19
  185. package/dist/collection/components/gov-tabs/gov-tabs.js.map +1 -1
  186. package/dist/collection/components/gov-tile/container/gov-tiles.js +4 -4
  187. package/dist/collection/components/gov-tile/gov-tile.js +6 -3
  188. package/dist/collection/components/gov-tile/gov-tile.js.map +1 -1
  189. package/dist/collection/components/gov-toast/constants.js +2 -2
  190. package/dist/collection/components/gov-toast/gov-toast.js +11 -8
  191. package/dist/collection/components/gov-toast/gov-toast.js.map +1 -1
  192. package/dist/collection/components/gov-tooltip/constants.js +3 -3
  193. package/dist/collection/components/gov-tooltip/gov-tooltip-content.js +3 -3
  194. package/dist/collection/components/gov-tooltip/gov-tooltip.js +15 -10
  195. package/dist/collection/components/gov-tooltip/gov-tooltip.js.map +1 -1
  196. package/dist/collection/components/gov-wizzard/constants.js +3 -3
  197. package/dist/collection/components/gov-wizzard/gov-wizzard-item.js +14 -7
  198. package/dist/collection/components/gov-wizzard/gov-wizzard-item.js.map +1 -1
  199. package/dist/collection/components/gov-wizzard/gov-wizzard.js +6 -3
  200. package/dist/collection/components/gov-wizzard/gov-wizzard.js.map +1 -1
  201. package/dist/collection/helpers/Dom/form.js +9 -9
  202. package/dist/collection/helpers/Dom/win.js +1 -1
  203. package/dist/collection/helpers/StorybookDocsTemplate.js +3 -3
  204. package/dist/collection/helpers/Validate/props.js +1 -1
  205. package/dist/collection/helpers/Validate/wcag.js +3 -3
  206. package/dist/collection/utils/ds.utils.js +1 -1
  207. package/dist/collection/utils/icon.utils.js +3 -3
  208. package/dist/components/gov-accordion-item.js +1 -156
  209. package/dist/components/gov-accordion-item.js.map +1 -1
  210. package/dist/components/gov-accordion.js +1 -94
  211. package/dist/components/gov-accordion.js.map +1 -1
  212. package/dist/components/gov-alert.js +1 -122
  213. package/dist/components/gov-alert.js.map +1 -1
  214. package/dist/components/gov-app.js +1 -8924
  215. package/dist/components/gov-app.js.map +1 -1
  216. package/dist/components/gov-attachments-item.js +1 -7
  217. package/dist/components/gov-attachments-item.js.map +1 -1
  218. package/dist/components/gov-attachments.js +1 -7
  219. package/dist/components/gov-attachments.js.map +1 -1
  220. package/dist/components/gov-backdrop.js +1 -7
  221. package/dist/components/gov-backdrop.js.map +1 -1
  222. package/dist/components/gov-badge.js +1 -7
  223. package/dist/components/gov-badge.js.map +1 -1
  224. package/dist/components/gov-breadcrumbs.js +1 -67
  225. package/dist/components/gov-breadcrumbs.js.map +1 -1
  226. package/dist/components/gov-button.js +1 -7
  227. package/dist/components/gov-button.js.map +1 -1
  228. package/dist/components/gov-card.js +1 -143
  229. package/dist/components/gov-card.js.map +1 -1
  230. package/dist/components/gov-container.js +1 -51
  231. package/dist/components/gov-container.js.map +1 -1
  232. package/dist/components/gov-control-group.js +1 -57
  233. package/dist/components/gov-control-group.js.map +1 -1
  234. package/dist/components/gov-cookiebar.js +1 -46
  235. package/dist/components/gov-cookiebar.js.map +1 -1
  236. package/dist/components/gov-dropdown.js +1 -150
  237. package/dist/components/gov-dropdown.js.map +1 -1
  238. package/dist/components/gov-empty.js +1 -44
  239. package/dist/components/gov-empty.js.map +1 -1
  240. package/dist/components/gov-error-code.js +1 -44
  241. package/dist/components/gov-error-code.js.map +1 -1
  242. package/dist/components/gov-form-autocomplete.js +1 -7
  243. package/dist/components/gov-form-autocomplete.js.map +1 -1
  244. package/dist/components/gov-form-checkbox.js +1 -159
  245. package/dist/components/gov-form-checkbox.js.map +1 -1
  246. package/dist/components/gov-form-control.js +1 -139
  247. package/dist/components/gov-form-control.js.map +1 -1
  248. package/dist/components/gov-form-file.js +1 -288
  249. package/dist/components/gov-form-file.js.map +1 -1
  250. package/dist/components/gov-form-group.js +1 -57
  251. package/dist/components/gov-form-group.js.map +1 -1
  252. package/dist/components/gov-form-input.js +1 -7
  253. package/dist/components/gov-form-input.js.map +1 -1
  254. package/dist/components/gov-form-label.js +1 -46
  255. package/dist/components/gov-form-label.js.map +1 -1
  256. package/dist/components/gov-form-message.js +1 -7
  257. package/dist/components/gov-form-message.js.map +1 -1
  258. package/dist/components/gov-form-multi-select.js +1 -270
  259. package/dist/components/gov-form-multi-select.js.map +1 -1
  260. package/dist/components/gov-form-password-power.js +1 -43
  261. package/dist/components/gov-form-password-power.js.map +1 -1
  262. package/dist/components/gov-form-radio.js +1 -153
  263. package/dist/components/gov-form-radio.js.map +1 -1
  264. package/dist/components/gov-form-search.js +1 -47
  265. package/dist/components/gov-form-search.js.map +1 -1
  266. package/dist/components/gov-form-select.js +1 -7
  267. package/dist/components/gov-form-select.js.map +1 -1
  268. package/dist/components/gov-form-switch.js +1 -153
  269. package/dist/components/gov-form-switch.js.map +1 -1
  270. package/dist/components/gov-grid-item.js +1 -49
  271. package/dist/components/gov-grid-item.js.map +1 -1
  272. package/dist/components/gov-grid.js +1 -44
  273. package/dist/components/gov-grid.js.map +1 -1
  274. package/dist/components/gov-icon.js +1 -7
  275. package/dist/components/gov-icon.js.map +1 -1
  276. package/dist/components/gov-layout-column.js +1 -38
  277. package/dist/components/gov-layout-column.js.map +1 -1
  278. package/dist/components/gov-layout.js +1 -51
  279. package/dist/components/gov-layout.js.map +1 -1
  280. package/dist/components/gov-loading.js +1 -58
  281. package/dist/components/gov-loading.js.map +1 -1
  282. package/dist/components/gov-message.js +1 -57
  283. package/dist/components/gov-message.js.map +1 -1
  284. package/dist/components/gov-modal.js +1 -146
  285. package/dist/components/gov-modal.js.map +1 -1
  286. package/dist/components/gov-nav-item.js +1 -53
  287. package/dist/components/gov-nav-item.js.map +1 -1
  288. package/dist/components/gov-nav.js +1 -57
  289. package/dist/components/gov-nav.js.map +1 -1
  290. package/dist/components/gov-pagination.js +1 -270
  291. package/dist/components/gov-pagination.js.map +1 -1
  292. package/dist/components/gov-prompt.js +1 -146
  293. package/dist/components/gov-prompt.js.map +1 -1
  294. package/dist/components/gov-side-nav-item.js +1 -124
  295. package/dist/components/gov-side-nav-item.js.map +1 -1
  296. package/dist/components/gov-side-nav.js +1 -73
  297. package/dist/components/gov-side-nav.js.map +1 -1
  298. package/dist/components/gov-skeleton.js +1 -137
  299. package/dist/components/gov-skeleton.js.map +1 -1
  300. package/dist/components/gov-spacer.js +1 -72
  301. package/dist/components/gov-spacer.js.map +1 -1
  302. package/dist/components/gov-statsbar-item.js +1 -51
  303. package/dist/components/gov-statsbar-item.js.map +1 -1
  304. package/dist/components/gov-statsbar.js +1 -65
  305. package/dist/components/gov-statsbar.js.map +1 -1
  306. package/dist/components/gov-stepper-item.js +1 -96
  307. package/dist/components/gov-stepper-item.js.map +1 -1
  308. package/dist/components/gov-stepper.js +1 -61
  309. package/dist/components/gov-stepper.js.map +1 -1
  310. package/dist/components/gov-tabs-item.js +1 -73
  311. package/dist/components/gov-tabs-item.js.map +1 -1
  312. package/dist/components/gov-tabs.js +1 -232
  313. package/dist/components/gov-tabs.js.map +1 -1
  314. package/dist/components/gov-tile.js +1 -80
  315. package/dist/components/gov-tile.js.map +1 -1
  316. package/dist/components/gov-tiles.js +1 -49
  317. package/dist/components/gov-tiles.js.map +1 -1
  318. package/dist/components/gov-toast.js +1 -136
  319. package/dist/components/gov-toast.js.map +1 -1
  320. package/dist/components/gov-tooltip-content.js +1 -54
  321. package/dist/components/gov-tooltip-content.js.map +1 -1
  322. package/dist/components/gov-tooltip.js +1 -176
  323. package/dist/components/gov-tooltip.js.map +1 -1
  324. package/dist/components/gov-wizzard-item.js +1 -144
  325. package/dist/components/gov-wizzard-item.js.map +1 -1
  326. package/dist/components/gov-wizzard.js +1 -83
  327. package/dist/components/gov-wizzard.js.map +1 -1
  328. package/dist/components/index.d.ts +14 -62
  329. package/dist/components/index.js +1 -62
  330. package/dist/components/index.js.map +1 -1
  331. package/dist/components/p-03990da5.js +2 -0
  332. package/dist/components/p-03990da5.js.map +1 -0
  333. package/dist/components/p-0f5e2b0a.js +2 -0
  334. package/dist/components/p-0f5e2b0a.js.map +1 -0
  335. package/dist/components/p-1020a160.js +2 -0
  336. package/dist/components/p-1020a160.js.map +1 -0
  337. package/dist/components/p-16e8c053.js +2 -0
  338. package/dist/components/p-16e8c053.js.map +1 -0
  339. package/dist/components/p-17c1ffc1.js +2 -0
  340. package/dist/components/p-17c1ffc1.js.map +1 -0
  341. package/dist/components/p-1b4f2520.js +2 -0
  342. package/dist/components/p-1b4f2520.js.map +1 -0
  343. package/dist/components/p-1c1d0bbe.js +2 -0
  344. package/dist/components/p-1c1d0bbe.js.map +1 -0
  345. package/dist/components/p-20853eff.js +2 -0
  346. package/dist/components/{gov-form-select2.js.map → p-20853eff.js.map} +1 -1
  347. package/dist/components/p-24636c53.js +2 -0
  348. package/dist/components/p-24636c53.js.map +1 -0
  349. package/dist/components/p-2692b1ff.js +2 -0
  350. package/dist/components/p-2692b1ff.js.map +1 -0
  351. package/dist/components/p-26acf964.js +2 -0
  352. package/dist/components/p-26acf964.js.map +1 -0
  353. package/dist/components/p-34152b51.js +2 -0
  354. package/dist/components/p-34152b51.js.map +1 -0
  355. package/dist/components/p-3464136c.js +2 -0
  356. package/dist/components/p-3464136c.js.map +1 -0
  357. package/dist/components/p-36be8f6e.js +2 -0
  358. package/dist/components/p-36be8f6e.js.map +1 -0
  359. package/dist/components/p-386409dc.js +2 -0
  360. package/dist/components/p-386409dc.js.map +1 -0
  361. package/dist/components/p-3dbf7f49.js +2 -0
  362. package/dist/components/p-3dbf7f49.js.map +1 -0
  363. package/dist/components/p-3f37ddb6.js +2 -0
  364. package/dist/components/p-3f37ddb6.js.map +1 -0
  365. package/dist/components/p-404f469e.js +2 -0
  366. package/dist/components/p-404f469e.js.map +1 -0
  367. package/dist/components/p-47172f0a.js +2 -0
  368. package/dist/components/p-47172f0a.js.map +1 -0
  369. package/dist/components/p-55500e5a.js +2 -0
  370. package/dist/components/p-55500e5a.js.map +1 -0
  371. package/dist/components/p-561fa17b.js +2 -0
  372. package/dist/components/p-561fa17b.js.map +1 -0
  373. package/dist/components/p-5bf5a42e.js +2 -0
  374. package/dist/components/p-5bf5a42e.js.map +1 -0
  375. package/dist/components/p-5defdc5e.js +2 -0
  376. package/dist/components/p-5defdc5e.js.map +1 -0
  377. package/dist/components/p-6278531b.js +2 -0
  378. package/dist/components/p-6278531b.js.map +1 -0
  379. package/dist/components/p-64ced668.js +2 -0
  380. package/dist/components/p-64ced668.js.map +1 -0
  381. package/dist/components/p-80c0109d.js +2 -0
  382. package/dist/components/p-80c0109d.js.map +1 -0
  383. package/dist/components/p-80e30702.js +2 -0
  384. package/dist/components/{constants13.js.map → p-80e30702.js.map} +1 -1
  385. package/dist/components/p-9144dde1.js +2 -0
  386. package/dist/components/p-9144dde1.js.map +1 -0
  387. package/dist/components/p-9331532e.js +2 -0
  388. package/dist/components/p-9331532e.js.map +1 -0
  389. package/dist/components/p-a5d69694.js +2 -0
  390. package/dist/components/p-a5d69694.js.map +1 -0
  391. package/dist/components/p-a6d14a47.js +2 -0
  392. package/dist/components/p-a6d14a47.js.map +1 -0
  393. package/dist/components/p-b72a7bed.js +2 -0
  394. package/dist/components/p-b72a7bed.js.map +1 -0
  395. package/dist/components/p-be4aab0e.js +2 -0
  396. package/dist/components/p-be4aab0e.js.map +1 -0
  397. package/dist/components/p-ccc44ac1.js +2 -0
  398. package/dist/components/p-ccc44ac1.js.map +1 -0
  399. package/dist/components/p-efcdfed8.js +2 -0
  400. package/dist/components/p-efcdfed8.js.map +1 -0
  401. package/dist/components/p-ff7365ae.js +2 -0
  402. package/dist/components/p-ff7365ae.js.map +1 -0
  403. package/dist/components/p-ffb7495c.js +2 -0
  404. package/dist/components/p-ffb7495c.js.map +1 -0
  405. package/dist/core/core.esm.js +1 -1
  406. package/dist/core/core.esm.js.map +1 -1
  407. package/dist/core/index.esm.js.map +1 -1
  408. package/dist/core/{p-f2d22b62.entry.js → p-02c3a3fd.entry.js} +2 -2
  409. package/dist/core/p-02c3a3fd.entry.js.map +1 -0
  410. package/dist/core/p-03990da5.js.map +1 -1
  411. package/dist/core/{p-24ba5c7b.entry.js → p-041d30b1.entry.js} +2 -2
  412. package/dist/core/p-041d30b1.entry.js.map +1 -0
  413. package/dist/core/{p-818bb0f5.entry.js → p-0eadfb3e.entry.js} +2 -2
  414. package/dist/core/p-0eadfb3e.entry.js.map +1 -0
  415. package/dist/core/{p-88c10472.entry.js → p-0eb11cfc.entry.js} +2 -2
  416. package/dist/core/p-0eb11cfc.entry.js.map +1 -0
  417. package/dist/core/p-0f5e2b0a.js.map +1 -1
  418. package/dist/core/p-1020a160.js.map +1 -1
  419. package/dist/core/p-10cbc3fe.js +3 -0
  420. package/dist/core/p-10cbc3fe.js.map +1 -0
  421. package/dist/core/{p-c0c9b349.entry.js → p-11be550d.entry.js} +2 -2
  422. package/dist/core/p-11be550d.entry.js.map +1 -0
  423. package/dist/core/{p-024fa230.entry.js → p-1ae47d62.entry.js} +2 -2
  424. package/dist/core/p-1ae47d62.entry.js.map +1 -0
  425. package/dist/core/p-1c1d0bbe.js.map +1 -1
  426. package/dist/core/{p-2713b83e.entry.js → p-1c62f175.entry.js} +2 -2
  427. package/dist/core/p-1c62f175.entry.js.map +1 -0
  428. package/dist/core/{p-7d7dab2e.entry.js → p-1da9f871.entry.js} +2 -2
  429. package/dist/core/p-1da9f871.entry.js.map +1 -0
  430. package/dist/core/{p-21375e02.entry.js → p-1e3cad4b.entry.js} +2 -2
  431. package/dist/core/p-1e3cad4b.entry.js.map +1 -0
  432. package/dist/core/{p-34508063.entry.js → p-228da18e.entry.js} +2 -2
  433. package/dist/core/p-228da18e.entry.js.map +1 -0
  434. package/dist/core/p-24636c53.js.map +1 -1
  435. package/dist/core/p-26acf964.js.map +1 -1
  436. package/dist/core/{p-439340f9.entry.js → p-2790d89e.entry.js} +2 -2
  437. package/dist/core/p-2790d89e.entry.js.map +1 -0
  438. package/dist/core/{p-a008979f.entry.js → p-2fe9d3ea.entry.js} +2 -2
  439. package/dist/core/p-2fe9d3ea.entry.js.map +1 -0
  440. package/dist/core/{p-1f883c31.entry.js → p-33895061.entry.js} +2 -2
  441. package/dist/core/p-33895061.entry.js.map +1 -0
  442. package/dist/core/p-34152b51.js.map +1 -1
  443. package/dist/core/p-3464136c.js.map +1 -1
  444. package/dist/core/p-34ed07f6.js.map +1 -1
  445. package/dist/core/{p-dbd6c9b5.entry.js → p-3559e7c5.entry.js} +2 -2
  446. package/dist/core/p-3559e7c5.entry.js.map +1 -0
  447. package/dist/core/p-36be8f6e.js.map +1 -1
  448. package/dist/core/{p-fd62778e.entry.js → p-3858e2c8.entry.js} +2 -2
  449. package/dist/core/p-3858e2c8.entry.js.map +1 -0
  450. package/dist/core/p-3b9df792.entry.js +2 -0
  451. package/dist/core/p-3b9df792.entry.js.map +1 -0
  452. package/dist/core/{p-b1ca32cc.entry.js → p-3d720d54.entry.js} +2 -2
  453. package/dist/core/p-3d720d54.entry.js.map +1 -0
  454. package/dist/core/p-3dbf7f49.js.map +1 -1
  455. package/dist/core/{p-40df0e89.entry.js → p-3e5432d7.entry.js} +2 -2
  456. package/dist/core/p-3e5432d7.entry.js.map +1 -0
  457. package/dist/core/p-3f37ddb6.js.map +1 -1
  458. package/dist/core/p-404f469e.js.map +1 -1
  459. package/dist/core/{p-00e21d46.entry.js → p-42cd2cc4.entry.js} +2 -2
  460. package/dist/core/p-42cd2cc4.entry.js.map +1 -0
  461. package/dist/core/{p-3b6d6f6f.entry.js → p-48349167.entry.js} +2 -2
  462. package/dist/core/p-48349167.entry.js.map +1 -0
  463. package/dist/core/{p-d9747cca.entry.js → p-49926f53.entry.js} +2 -2
  464. package/dist/core/p-49926f53.entry.js.map +1 -0
  465. package/dist/core/{p-2b0af68c.entry.js → p-5150efee.entry.js} +2 -2
  466. package/dist/core/p-5150efee.entry.js.map +1 -0
  467. package/dist/core/{p-1c20657a.entry.js → p-5316e768.entry.js} +2 -2
  468. package/dist/core/p-5316e768.entry.js.map +1 -0
  469. package/dist/core/p-55500e5a.js.map +1 -1
  470. package/dist/core/p-561fa17b.js.map +1 -1
  471. package/dist/core/{p-c134863d.entry.js → p-5a855a15.entry.js} +2 -2
  472. package/dist/core/p-5a855a15.entry.js.map +1 -0
  473. package/dist/core/p-5defdc5e.js.map +1 -1
  474. package/dist/core/{p-424fdf22.entry.js → p-5e23a6ba.entry.js} +2 -2
  475. package/dist/core/p-5e23a6ba.entry.js.map +1 -0
  476. package/dist/core/p-6278531b.js.map +1 -1
  477. package/dist/core/p-64ced668.js.map +1 -1
  478. package/dist/core/{p-1e1bd302.entry.js → p-6dacb8d3.entry.js} +2 -2
  479. package/dist/core/p-6dacb8d3.entry.js.map +1 -0
  480. package/dist/core/{p-174d3df0.entry.js → p-6f43bd00.entry.js} +2 -2
  481. package/dist/core/p-6f43bd00.entry.js.map +1 -0
  482. package/dist/core/{p-034c5c8f.entry.js → p-722218fd.entry.js} +2 -2
  483. package/dist/core/p-722218fd.entry.js.map +1 -0
  484. package/dist/core/{p-9a1d5c77.entry.js → p-739dd451.entry.js} +2 -2
  485. package/dist/core/p-739dd451.entry.js.map +1 -0
  486. package/dist/core/{p-51582b94.entry.js → p-7ab82a55.entry.js} +2 -2
  487. package/dist/core/p-7ab82a55.entry.js.map +1 -0
  488. package/dist/core/p-80e30702.js.map +1 -1
  489. package/dist/core/{p-ddffa85e.entry.js → p-88a78167.entry.js} +2 -2
  490. package/dist/core/p-88a78167.entry.js.map +1 -0
  491. package/dist/core/{p-ec8e7f8f.entry.js → p-89921159.entry.js} +2 -2
  492. package/dist/core/p-89921159.entry.js.map +1 -0
  493. package/dist/core/p-9144dde1.js.map +1 -1
  494. package/dist/core/{p-1bfe6f33.entry.js → p-93042b25.entry.js} +2 -2
  495. package/dist/core/p-93042b25.entry.js.map +1 -0
  496. package/dist/core/{p-b2c6a185.entry.js → p-9633e7b5.entry.js} +2 -2
  497. package/dist/core/p-9633e7b5.entry.js.map +1 -0
  498. package/dist/core/{p-82af6719.entry.js → p-9751af2e.entry.js} +2 -2
  499. package/dist/core/p-9751af2e.entry.js.map +1 -0
  500. package/dist/core/{p-6e6a44f0.entry.js → p-9a3e3ace.entry.js} +2 -2
  501. package/dist/core/p-9a3e3ace.entry.js.map +1 -0
  502. package/dist/core/{p-5f23b01d.entry.js → p-9ad54c30.entry.js} +2 -2
  503. package/dist/core/p-9ad54c30.entry.js.map +1 -0
  504. package/dist/core/p-9dab01be.js.map +1 -1
  505. package/dist/core/{p-b9bfca0a.entry.js → p-9e208f40.entry.js} +2 -2
  506. package/dist/core/p-9e208f40.entry.js.map +1 -0
  507. package/dist/core/p-9f541022.entry.js +2 -0
  508. package/dist/core/p-9f541022.entry.js.map +1 -0
  509. package/dist/core/p-a5d69694.js.map +1 -1
  510. package/dist/core/{p-8ee11310.entry.js → p-a68547b1.entry.js} +2 -2
  511. package/dist/core/p-a68547b1.entry.js.map +1 -0
  512. package/dist/core/p-a6d14a47.js.map +1 -1
  513. package/dist/core/{p-d7ee8f40.entry.js → p-a857915f.entry.js} +2 -2
  514. package/dist/core/{p-d7ee8f40.entry.js.map → p-a857915f.entry.js.map} +1 -1
  515. package/dist/core/{p-cbfe47ee.entry.js → p-aa4e716e.entry.js} +2 -2
  516. package/dist/core/p-aa4e716e.entry.js.map +1 -0
  517. package/dist/core/p-ac94d242.entry.js +2 -0
  518. package/dist/core/p-ac94d242.entry.js.map +1 -0
  519. package/dist/core/{p-32c8b7a4.entry.js → p-ae04e58f.entry.js} +2 -2
  520. package/dist/core/p-ae04e58f.entry.js.map +1 -0
  521. package/dist/core/{p-dae9dc31.entry.js → p-af7a89bc.entry.js} +2 -2
  522. package/dist/core/p-af7a89bc.entry.js.map +1 -0
  523. package/dist/core/{p-0b9eed8b.entry.js → p-b5a560d2.entry.js} +2 -2
  524. package/dist/core/p-b5a560d2.entry.js.map +1 -0
  525. package/dist/core/{p-b547d31a.entry.js → p-bbcbe1cc.entry.js} +2 -2
  526. package/dist/core/p-bbcbe1cc.entry.js.map +1 -0
  527. package/dist/core/p-be4aab0e.js.map +1 -1
  528. package/dist/core/{p-902ff1a5.entry.js → p-d2729599.entry.js} +2 -2
  529. package/dist/core/p-d2729599.entry.js.map +1 -0
  530. package/dist/core/{p-52373a5b.entry.js → p-d921bd4b.entry.js} +2 -2
  531. package/dist/core/p-d921bd4b.entry.js.map +1 -0
  532. package/dist/core/{p-8694e397.entry.js → p-da762184.entry.js} +2 -2
  533. package/dist/core/p-da762184.entry.js.map +1 -0
  534. package/dist/core/p-de3dc437.entry.js +2 -0
  535. package/dist/core/p-de3dc437.entry.js.map +1 -0
  536. package/dist/core/p-e0c04c5f.entry.js +2 -0
  537. package/dist/core/p-e0c04c5f.entry.js.map +1 -0
  538. package/dist/core/{p-c862ac0d.entry.js → p-e1b3c361.entry.js} +2 -2
  539. package/dist/core/p-e1b3c361.entry.js.map +1 -0
  540. package/dist/core/{p-2c821d36.entry.js → p-e86db39c.entry.js} +2 -2
  541. package/dist/core/p-e86db39c.entry.js.map +1 -0
  542. package/dist/core/{p-dfe0cb6d.entry.js → p-eda868dc.entry.js} +2 -2
  543. package/dist/core/p-eda868dc.entry.js.map +1 -0
  544. package/dist/core/{p-37599a2d.entry.js → p-f95bca5f.entry.js} +2 -2
  545. package/dist/core/p-f95bca5f.entry.js.map +1 -0
  546. package/dist/core/{p-1a4cb97e.entry.js → p-f969eec7.entry.js} +2 -2
  547. package/dist/core/p-f969eec7.entry.js.map +1 -0
  548. package/dist/core/{p-4b8bf83d.entry.js → p-fa71fb92.entry.js} +2 -2
  549. package/dist/core/p-fa71fb92.entry.js.map +1 -0
  550. package/dist/core/p-ff7365ae.js.map +1 -1
  551. package/dist/core/p-ffb7495c.js.map +1 -1
  552. package/dist/esm/core.js +3 -2
  553. package/dist/esm/core.js.map +1 -1
  554. package/dist/esm/gov-accordion-item.entry.js +1 -1
  555. package/dist/esm/gov-accordion.entry.js +1 -1
  556. package/dist/esm/gov-alert.entry.js +1 -1
  557. package/dist/esm/gov-app.entry.js +1 -1
  558. package/dist/esm/gov-app.entry.js.map +1 -1
  559. package/dist/esm/gov-attachments_3.entry.js +1 -1
  560. package/dist/esm/gov-backdrop.entry.js +1 -1
  561. package/dist/esm/gov-badge.entry.js +1 -1
  562. package/dist/esm/gov-breadcrumbs.entry.js +1 -1
  563. package/dist/esm/gov-button.entry.js +1 -1
  564. package/dist/esm/gov-card.entry.js +1 -1
  565. package/dist/esm/gov-container.entry.js +1 -1
  566. package/dist/esm/gov-control-group.entry.js +1 -1
  567. package/dist/esm/gov-cookiebar.entry.js +1 -1
  568. package/dist/esm/gov-dropdown.entry.js +1 -1
  569. package/dist/esm/gov-empty.entry.js +1 -1
  570. package/dist/esm/gov-error-code.entry.js +1 -1
  571. package/dist/esm/gov-form-autocomplete.entry.js +1 -1
  572. package/dist/esm/gov-form-checkbox.entry.js +1 -1
  573. package/dist/esm/gov-form-control.entry.js +1 -1
  574. package/dist/esm/gov-form-file.entry.js +1 -1
  575. package/dist/esm/gov-form-group.entry.js +1 -1
  576. package/dist/esm/gov-form-input.entry.js +1 -1
  577. package/dist/esm/gov-form-label.entry.js +1 -1
  578. package/dist/esm/gov-form-multi-select.entry.js +1 -1
  579. package/dist/esm/gov-form-password-power.entry.js +1 -1
  580. package/dist/esm/gov-form-radio.entry.js +1 -1
  581. package/dist/esm/gov-form-search.entry.js +1 -1
  582. package/dist/esm/gov-form-select.entry.js +1 -1
  583. package/dist/esm/gov-form-switch.entry.js +1 -1
  584. package/dist/esm/gov-grid-item.entry.js +1 -1
  585. package/dist/esm/gov-grid.entry.js +1 -1
  586. package/dist/esm/gov-icon.entry.js +1 -1
  587. package/dist/esm/gov-layout-column.entry.js +1 -1
  588. package/dist/esm/gov-layout.entry.js +1 -1
  589. package/dist/esm/gov-loading.entry.js +1 -1
  590. package/dist/esm/gov-message.entry.js +1 -1
  591. package/dist/esm/gov-modal.entry.js +1 -1
  592. package/dist/esm/gov-nav-item.entry.js +1 -1
  593. package/dist/esm/gov-nav.entry.js +1 -1
  594. package/dist/esm/gov-pagination.entry.js +1 -1
  595. package/dist/esm/gov-prompt.entry.js +1 -1
  596. package/dist/esm/gov-side-nav-item.entry.js +1 -1
  597. package/dist/esm/gov-side-nav.entry.js +1 -1
  598. package/dist/esm/gov-skeleton.entry.js +1 -1
  599. package/dist/esm/gov-spacer.entry.js +1 -1
  600. package/dist/esm/gov-statsbar-item.entry.js +1 -1
  601. package/dist/esm/gov-statsbar.entry.js +1 -1
  602. package/dist/esm/gov-stepper-item.entry.js +1 -1
  603. package/dist/esm/gov-stepper.entry.js +1 -1
  604. package/dist/esm/gov-tabs-item.entry.js +1 -1
  605. package/dist/esm/gov-tabs.entry.js +1 -1
  606. package/dist/esm/gov-tabs.entry.js.map +1 -1
  607. package/dist/esm/gov-tile.entry.js +1 -1
  608. package/dist/esm/gov-tiles.entry.js +1 -1
  609. package/dist/esm/gov-toast.entry.js +1 -1
  610. package/dist/esm/gov-tooltip-content.entry.js +1 -1
  611. package/dist/esm/gov-tooltip.entry.js +1 -1
  612. package/dist/esm/gov-wizzard-item.entry.js +1 -1
  613. package/dist/esm/gov-wizzard.entry.js +1 -1
  614. package/dist/esm/{index-12c94daf.js → index-ae3c50f1.js} +305 -53
  615. package/dist/esm/index-ae3c50f1.js.map +1 -0
  616. package/dist/esm/loader.js +3 -11
  617. package/dist/esm/loader.js.map +1 -1
  618. package/dist/hydrate/index.d.ts +17 -16
  619. package/dist/hydrate/index.js +199 -166
  620. package/dist/stencil.config.js +5 -11
  621. package/dist/stencil.config.js.map +1 -1
  622. package/dist/types/components/gov-accordion/constants.d.ts +2 -2
  623. package/dist/types/components/gov-alert/constants.d.ts +1 -1
  624. package/dist/types/components/gov-app/gov-app.d.ts +34 -34
  625. package/dist/types/components/gov-badge/constants.d.ts +1 -1
  626. package/dist/types/components/gov-button/default/constants.d.ts +5 -5
  627. package/dist/types/components/gov-button/dropdown/constants.d.ts +1 -1
  628. package/dist/types/components/gov-control-group/constants.d.ts +1 -1
  629. package/dist/types/components/gov-form/autocomplete/constants.d.ts +2 -2
  630. package/dist/types/components/gov-form/checkbox/constants.d.ts +1 -1
  631. package/dist/types/components/gov-form/control/constants.d.ts +1 -1
  632. package/dist/types/components/gov-form/group/constants.d.ts +1 -1
  633. package/dist/types/components/gov-form/input/constants.d.ts +4 -4
  634. package/dist/types/components/gov-form/label/constants.d.ts +1 -1
  635. package/dist/types/components/gov-form/message/constants.d.ts +1 -1
  636. package/dist/types/components/gov-form/multiselect/constants.d.ts +2 -2
  637. package/dist/types/components/gov-form/radio/constants.d.ts +1 -1
  638. package/dist/types/components/gov-form/search/constants.d.ts +1 -1
  639. package/dist/types/components/gov-form/select/constants.d.ts +2 -2
  640. package/dist/types/components/gov-form/switch/constants.d.ts +1 -1
  641. package/dist/types/components/gov-icon/constants.d.ts +1 -1
  642. package/dist/types/components/gov-layout/constants.d.ts +2 -2
  643. package/dist/types/components/gov-loading/skeleton/constants.d.ts +3 -3
  644. package/dist/types/components/gov-message/constants.d.ts +1 -1
  645. package/dist/types/components/gov-pagination/constants.d.ts +3 -3
  646. package/dist/types/components/gov-spacer/constants.d.ts +2 -2
  647. package/dist/types/components/gov-statsbar/constants.d.ts +2 -2
  648. package/dist/types/components/gov-stepper/constants.d.ts +2 -2
  649. package/dist/types/components/gov-tabs/constants.d.ts +3 -3
  650. package/dist/types/components/gov-toast/constants.d.ts +2 -2
  651. package/dist/types/components/gov-tooltip/constants.d.ts +3 -3
  652. package/dist/types/components/gov-wizzard/constants.d.ts +2 -2
  653. package/dist/types/components.d.ts +50 -0
  654. package/dist/types/stencil-public-runtime.d.ts +88 -17
  655. package/dist/types/types/interfaces.d.ts +2 -2
  656. package/dist/types/utils/utils.d.ts +1 -1
  657. package/loader/index.d.ts +10 -1
  658. package/package.json +22 -22
  659. package/dist/cjs/index-7ba43a19.js.map +0 -1
  660. package/dist/components/Fragment.js +0 -5
  661. package/dist/components/Fragment.js.map +0 -1
  662. package/dist/components/constants.js +0 -25
  663. package/dist/components/constants.js.map +0 -1
  664. package/dist/components/constants10.js +0 -19
  665. package/dist/components/constants10.js.map +0 -1
  666. package/dist/components/constants11.js +0 -22
  667. package/dist/components/constants11.js.map +0 -1
  668. package/dist/components/constants12.js +0 -25
  669. package/dist/components/constants12.js.map +0 -1
  670. package/dist/components/constants13.js +0 -29
  671. package/dist/components/constants14.js +0 -23
  672. package/dist/components/constants14.js.map +0 -1
  673. package/dist/components/constants15.js +0 -24
  674. package/dist/components/constants15.js.map +0 -1
  675. package/dist/components/constants2.js +0 -15
  676. package/dist/components/constants2.js.map +0 -1
  677. package/dist/components/constants3.js +0 -33
  678. package/dist/components/constants3.js.map +0 -1
  679. package/dist/components/constants4.js +0 -12
  680. package/dist/components/constants4.js.map +0 -1
  681. package/dist/components/constants5.js +0 -13
  682. package/dist/components/constants5.js.map +0 -1
  683. package/dist/components/constants6.js +0 -10
  684. package/dist/components/constants6.js.map +0 -1
  685. package/dist/components/constants7.js +0 -22
  686. package/dist/components/constants7.js.map +0 -1
  687. package/dist/components/constants8.js +0 -18
  688. package/dist/components/constants8.js.map +0 -1
  689. package/dist/components/constants9.js +0 -12
  690. package/dist/components/constants9.js.map +0 -1
  691. package/dist/components/form.js +0 -152
  692. package/dist/components/form.js.map +0 -1
  693. package/dist/components/gov-attachments-item2.js +0 -70
  694. package/dist/components/gov-attachments-item2.js.map +0 -1
  695. package/dist/components/gov-attachments2.js +0 -57
  696. package/dist/components/gov-attachments2.js.map +0 -1
  697. package/dist/components/gov-backdrop2.js +0 -64
  698. package/dist/components/gov-backdrop2.js.map +0 -1
  699. package/dist/components/gov-badge2.js +0 -108
  700. package/dist/components/gov-badge2.js.map +0 -1
  701. package/dist/components/gov-button2.js +0 -223
  702. package/dist/components/gov-button2.js.map +0 -1
  703. package/dist/components/gov-form-autocomplete2.js +0 -294
  704. package/dist/components/gov-form-autocomplete2.js.map +0 -1
  705. package/dist/components/gov-form-input2.js +0 -235
  706. package/dist/components/gov-form-input2.js.map +0 -1
  707. package/dist/components/gov-form-message2.js +0 -58
  708. package/dist/components/gov-form-message2.js.map +0 -1
  709. package/dist/components/gov-form-select2.js +0 -186
  710. package/dist/components/gov-icon2.js +0 -142
  711. package/dist/components/gov-icon2.js.map +0 -1
  712. package/dist/components/gov.log.js +0 -17
  713. package/dist/components/gov.log.js.map +0 -1
  714. package/dist/components/props.js +0 -14
  715. package/dist/components/props.js.map +0 -1
  716. package/dist/components/sizes.js +0 -18
  717. package/dist/components/sizes.js.map +0 -1
  718. package/dist/components/string.utils.js +0 -20
  719. package/dist/components/string.utils.js.map +0 -1
  720. package/dist/components/template.js +0 -113
  721. package/dist/components/template.js.map +0 -1
  722. package/dist/components/utils.js +0 -35
  723. package/dist/components/utils.js.map +0 -1
  724. package/dist/components/variants.js +0 -18
  725. package/dist/components/variants.js.map +0 -1
  726. package/dist/components/wcag.js +0 -62
  727. package/dist/components/wcag.js.map +0 -1
  728. package/dist/components/win.js +0 -23
  729. package/dist/components/win.js.map +0 -1
  730. package/dist/core/critical.css +0 -1
  731. package/dist/core/p-00e21d46.entry.js.map +0 -1
  732. package/dist/core/p-024fa230.entry.js.map +0 -1
  733. package/dist/core/p-034c5c8f.entry.js.map +0 -1
  734. package/dist/core/p-0b9eed8b.entry.js.map +0 -1
  735. package/dist/core/p-174d3df0.entry.js.map +0 -1
  736. package/dist/core/p-1a4cb97e.entry.js.map +0 -1
  737. package/dist/core/p-1bfe6f33.entry.js.map +0 -1
  738. package/dist/core/p-1c20657a.entry.js.map +0 -1
  739. package/dist/core/p-1d20b5af.entry.js +0 -2
  740. package/dist/core/p-1d20b5af.entry.js.map +0 -1
  741. package/dist/core/p-1e1bd302.entry.js.map +0 -1
  742. package/dist/core/p-1ea41454.entry.js +0 -2
  743. package/dist/core/p-1ea41454.entry.js.map +0 -1
  744. package/dist/core/p-1f883c31.entry.js.map +0 -1
  745. package/dist/core/p-21375e02.entry.js.map +0 -1
  746. package/dist/core/p-24ba5c7b.entry.js.map +0 -1
  747. package/dist/core/p-2713b83e.entry.js.map +0 -1
  748. package/dist/core/p-2b0af68c.entry.js.map +0 -1
  749. package/dist/core/p-2c0e96dd.entry.js +0 -2
  750. package/dist/core/p-2c0e96dd.entry.js.map +0 -1
  751. package/dist/core/p-2c821d36.entry.js.map +0 -1
  752. package/dist/core/p-32c8b7a4.entry.js.map +0 -1
  753. package/dist/core/p-34508063.entry.js.map +0 -1
  754. package/dist/core/p-37599a2d.entry.js.map +0 -1
  755. package/dist/core/p-397b0e73.entry.js +0 -2
  756. package/dist/core/p-397b0e73.entry.js.map +0 -1
  757. package/dist/core/p-3b6d6f6f.entry.js.map +0 -1
  758. package/dist/core/p-40df0e89.entry.js.map +0 -1
  759. package/dist/core/p-424fdf22.entry.js.map +0 -1
  760. package/dist/core/p-439340f9.entry.js.map +0 -1
  761. package/dist/core/p-4b8bf83d.entry.js.map +0 -1
  762. package/dist/core/p-51582b94.entry.js.map +0 -1
  763. package/dist/core/p-52373a5b.entry.js.map +0 -1
  764. package/dist/core/p-5f23b01d.entry.js.map +0 -1
  765. package/dist/core/p-6e6a44f0.entry.js.map +0 -1
  766. package/dist/core/p-7d7dab2e.entry.js.map +0 -1
  767. package/dist/core/p-818bb0f5.entry.js.map +0 -1
  768. package/dist/core/p-82af6719.entry.js.map +0 -1
  769. package/dist/core/p-8694e397.entry.js.map +0 -1
  770. package/dist/core/p-88c10472.entry.js.map +0 -1
  771. package/dist/core/p-8ee11310.entry.js.map +0 -1
  772. package/dist/core/p-902ff1a5.entry.js.map +0 -1
  773. package/dist/core/p-9a1d5c77.entry.js.map +0 -1
  774. package/dist/core/p-a008979f.entry.js.map +0 -1
  775. package/dist/core/p-b1ca32cc.entry.js.map +0 -1
  776. package/dist/core/p-b2c6a185.entry.js.map +0 -1
  777. package/dist/core/p-b547d31a.entry.js.map +0 -1
  778. package/dist/core/p-b9bfca0a.entry.js.map +0 -1
  779. package/dist/core/p-c0c9b349.entry.js.map +0 -1
  780. package/dist/core/p-c134863d.entry.js.map +0 -1
  781. package/dist/core/p-c862ac0d.entry.js.map +0 -1
  782. package/dist/core/p-cbfe47ee.entry.js.map +0 -1
  783. package/dist/core/p-d9747cca.entry.js.map +0 -1
  784. package/dist/core/p-dae9dc31.entry.js.map +0 -1
  785. package/dist/core/p-dbd6c9b5.entry.js.map +0 -1
  786. package/dist/core/p-dd6d9f6d.js +0 -3
  787. package/dist/core/p-dd6d9f6d.js.map +0 -1
  788. package/dist/core/p-ddffa85e.entry.js.map +0 -1
  789. package/dist/core/p-dfe0cb6d.entry.js.map +0 -1
  790. package/dist/core/p-e866befd.entry.js +0 -2
  791. package/dist/core/p-e866befd.entry.js.map +0 -1
  792. package/dist/core/p-ec8e7f8f.entry.js.map +0 -1
  793. package/dist/core/p-f2d22b62.entry.js.map +0 -1
  794. package/dist/core/p-fd62778e.entry.js.map +0 -1
  795. package/dist/custom-elements/index.d.ts +0 -399
  796. package/dist/custom-elements/index.js +0 -2
  797. package/dist/custom-elements/index.js.map +0 -1
  798. package/dist/esm/index-12c94daf.js.map +0 -1
  799. package/dist/esm/polyfills/css-shim.js +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"gov-tabs.js","sourceRoot":"","sources":["../../../../../../src/components/gov-tabs/gov-tabs.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,EAAgB,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAC5G,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAA;AAC3D,OAAO,EAAE,aAAa,EAAE,WAAW,EAAe,MAAM,aAAa,CAAA;AAErE,OAAO,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,4BAA4B,CAAA;AAChE,OAAO,EAAE,iBAAiB,EAAE,gBAAgB,EAAE,MAAM,6BAA6B,CAAA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KAAK,CAAC,YAAY,CAAC,UAAkB;IACpC,IAAI,CAAC,qBAAqB,CAAC,UAAU,CAAC,CAAA;IACtC,IAAI,CAAC,QAAQ,EAAE,CAAA;EAChB,CAAC;EAED;;KAEG;EAEH,KAAK,CAAC,YAAY;IACjB,gBAAgB,CAAC,IAAI,CAAC,eAAe,EAAE,mBAAmB,EAAE,SAAS,CAAC,IAAI,CAAC,CAAA;IAC3E,iBAAiB,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,cAAc,EAAE,SAAS,CAAC,IAAI,CAAC,CAAA;EACvE,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACD","sourcesContent":["import { Component, Element, Host, h, State, Method, Event, EventEmitter, Prop, Watch } from '@stencil/core'\nimport { validateProp } from '../../helpers/Validate/props'\nimport { TabsItemClass, TabVariants, VariantType } from './constants'\nimport { GovTabControllerItem } from './gov-tabs.types'\nimport { govHost, toBoolAttr } from '../../helpers/Dom/template'\nimport { validateWcagLabel, validateWcagProp } from '../../helpers/Validate/wcag'\nimport { TabsClass, TabType, TabTypes, TabOrientationType } from './constants'\nimport { canValidateWcagOnRender } from '../../helpers/Dom/win'\nimport { delay, throttle } from '../../utils/utils'\nimport { createID } from '../../utils/string.utils'\nimport { Nullable } from '../../types/interfaces'\nimport { GovHost } from '../../helpers/Dom/template.types'\n\n@Component({\n\ttag: 'gov-tabs',\n\tstyleUrl: 'gov-tabs.scss',\n})\nexport class GovTabs {\n\tprivate h: GovHost\n\tprivate triggerRefs: { [key: string]: HTMLButtonElement } = {}\n\tprivate tabsRef?: HTMLDivElement\n\n\tprivate readonly formSelectId: string\n\n\tconstructor() {\n\t\tthis.h = govHost(this.host)\n\t\tthis.formSelectId = createID('GovForSelect')\n\t}\n\n\t@Element() host: HTMLGovTabsElement\n\t@State() controller: GovTabControllerItem[] = []\n\t@State() focusIndex = 0\n\t@State() compactControls = false\n\t/**\n\t * Tabs type\n\t */\n\t@Prop() readonly type: TabType = 'text'\n\t/**\n\t * Style variation of the tab badges.\n\t */\n\t@Prop() readonly variant?: VariantType = 'primary'\n\t/**\n\t * Tabs orientation\n\t */\n\t@Prop() readonly orientation: TabOrientationType = 'horizontal'\n\t/**\n\t * Adds accessible label for the tabs that is only shown for screen readers.\n\t */\n\t@Prop({ attribute: 'wcag-label' }) readonly wcagLabel: string\n\t/**\n\t * Adds accessible label for the tabs select\n\t */\n\t@Prop({ attribute: 'wcag-select-label' }) readonly wcagSelectLabel: string\n\t/**\n\t * Indicates the id of a component that labels the tabs.\n\t */\n\t@Prop({ attribute: 'wcag-labelled-by' }) readonly wcagLabelledBy: string\n\t/**\n\t * Emitted when the tab is changed.\n\t */\n\t@Event({ eventName: 'gov-change' }) govChange: EventEmitter<HTMLGovTabsItemElement>\n\n\t@Watch('type')\n\tvalidateType(newValue: string): void {\n\t\tvalidateProp(TabTypes, newValue, TabsClass.root)\n\t}\n\t@Watch('variant')\n\tvalidateVariant(newValue: string): void {\n\t\tvalidateProp(TabVariants, newValue, TabsClass.root)\n\t}\n\n\tcomponentWillLoad() {\n\t\tthis.prepareDataSource()\n\t}\n\n\tasync componentDidRender() {\n\t\tif (canValidateWcagOnRender()) {\n\t\t\tawait delay(500)\n\t\t\tawait this.validateWcag()\n\t\t}\n\n\t\tthis.resizeObserver()\n\t}\n\n\tprivate prepareDataSource(): void {\n\t\tthis.controller = []\n\t\tconst promises: Promise<GovTabControllerItem>[] = []\n\t\tthis.host.querySelectorAll(TabsItemClass.root).forEach((tab: HTMLGovTabsItemElement) => {\n\t\t\tconst controlItem = Promise.all([tab.getIdentifier(), tab.getTriggerIdentifier()]).then(([identifier, triggerIdentifier]) => {\n\t\t\t\tconst isDefault = typeof tab.getAttribute('default') === 'string'\n\t\t\t\treturn {\n\t\t\t\t\tlabel: tab.getAttribute('label'),\n\t\t\t\t\tcontentIdentifier: identifier,\n\t\t\t\t\ttriggerIdentifier: triggerIdentifier,\n\t\t\t\t\telement: tab,\n\t\t\t\t\tactive: false,\n\t\t\t\t\tdefault: isDefault,\n\t\t\t\t}\n\t\t\t})\n\t\t\tpromises.push(controlItem)\n\t\t})\n\t\tPromise.all(promises).then(controllers => {\n\t\t\tlet defaultTab = controllers.findIndex(controller => controller.default)\n\t\t\tif (defaultTab === -1) defaultTab = 0\n\t\t\tthis.focusIndex = defaultTab\n\t\t\tcontrollers[defaultTab].active = true\n\t\t\tthis.controller = [...controllers]\n\t\t\tthis.reRender()\n\t\t})\n\t}\n\n\tprivate setActiveByIdentifier(identifier: string) {\n\t\tconst temp = []\n\t\tthis.controller.map(item => {\n\t\t\titem.active = identifier === item.triggerIdentifier || identifier === item.contentIdentifier\n\t\t\ttemp.push(item)\n\t\t})\n\t\tthis.controller = [...temp]\n\t}\n\n\tprivate reRender() {\n\t\tthis.controller.map(control => {\n\t\t\tcontrol.element.setActiveStatus(control.active)\n\t\t})\n\t}\n\n\t/*\n\tprivate evaluateControls() {\n\t\tthis.compactControls = false\n\t\tlet sumOfWidth = this.tabsRef.querySelector(\"ul\").offsetWidth\n\t\tthis.compactControls = this.tabsRef.offsetWidth < sumOfWidth\n\t}\n\t*/\n\n\tprivate resizeObserver() {\n\t\tconst resizeObserver = new ResizeObserver(\n\t\t\tthrottle(() => {\n\t\t\t\t// this.evaluateControls()\n\t\t\t}, 200)\n\t\t)\n\n\t\tresizeObserver.observe(this.tabsRef)\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<Host\n\t\t\t\tclass={this.h.classes(TabsClass.root)}\n\t\t\t\tvariant={this.variant}\n\t\t\t\ttype={this.type}\n\t\t\t\trole=\"tablist\"\n\t\t\t\tref={el => (this.tabsRef = el as HTMLDivElement)}\n\t\t\t\taria-label={this.wcagLabel}\n\t\t\t\taria-labelledby={this.wcagLabelledBy}\n\t\t\t\tonKeyDown={this.onKeydownHandler.bind(this)}\n\t\t\t>\n\t\t\t\t<div class={TabsClass.tabs} aria-hidden={toBoolAttr(this.compactControls)}>\n\t\t\t\t\t<ul class={TabsClass.list}>\n\t\t\t\t\t\t{this.controller.map((control, index) => (\n\t\t\t\t\t\t\t<li class={TabsClass.item}>\n\t\t\t\t\t\t\t\t{this.type == 'text' ? (\n\t\t\t\t\t\t\t\t\t<button\n\t\t\t\t\t\t\t\t\t\tclass={TabsClass.btn}\n\t\t\t\t\t\t\t\t\t\tid={control.triggerIdentifier}\n\t\t\t\t\t\t\t\t\t\trole=\"tab\"\n\t\t\t\t\t\t\t\t\t\tonClick={() => this.onSelectHandler(control, index)}\n\t\t\t\t\t\t\t\t\t\taria-selected={toBoolAttr(control.active)}\n\t\t\t\t\t\t\t\t\t\taria-controls={control.contentIdentifier}\n\t\t\t\t\t\t\t\t\t\ttabindex={control.active ? -1 : 0}\n\t\t\t\t\t\t\t\t\t\tref={el => (this.triggerRefs[control.triggerIdentifier] = el as HTMLInputElement)}\n\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t{control.label}\n\t\t\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t\t\t) : (\n\t\t\t\t\t\t\t\t\t<gov-badge\n\t\t\t\t\t\t\t\t\t\tvariant={this.variant}\n\t\t\t\t\t\t\t\t\t\ttype={toBoolAttr(control.active) == 'true' ? 'solid' : 'outlined'}\n\t\t\t\t\t\t\t\t\t\ton-gov-click={() => this.onSelectHandler(control, index)}\n\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t{control.label}\n\t\t\t\t\t\t\t\t\t</gov-badge>\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t))}\n\t\t\t\t\t</ul>\n\t\t\t\t</div>\n\n\t\t\t\t<span id={this.formSelectId} hidden>\n\t\t\t\t\t{this.wcagSelectLabel}\n\t\t\t\t</span>\n\t\t\t\t{this.compactControls ? (\n\t\t\t\t\t<gov-form-select wcag-labelled-by={this.formSelectId} onGov-change={this.onChangeHandler.bind(this)}>\n\t\t\t\t\t\t{this.controller.map(control => (\n\t\t\t\t\t\t\t<option value={control.triggerIdentifier} selected={control.active}>\n\t\t\t\t\t\t\t\t{control.label}\n\t\t\t\t\t\t\t</option>\n\t\t\t\t\t\t))}\n\t\t\t\t\t</gov-form-select>\n\t\t\t\t) : null}\n\n\t\t\t\t<slot></slot>\n\t\t\t</Host>\n\t\t)\n\t}\n\n\tprivate getCurrentTab(): GovTabControllerItem | null {\n\t\treturn this.controller.find(control => control.active) || null\n\t}\n\n\tprivate onSelectHandler(control: GovTabControllerItem, index: number) {\n\t\tthis.focusIndex = index\n\t\tthis.setActiveByIdentifier(control.triggerIdentifier)\n\t\tthis.reRender()\n\t\tthis.govChange.emit(this.getCurrentTab().element)\n\t}\n\n\tprivate onChangeHandler(e: CustomEvent) {\n\t\tconst triggerId = (e.target as HTMLSelectElement).value\n\t\te.stopPropagation()\n\t\tthis.setActiveByIdentifier(triggerId)\n\t\tthis.reRender()\n\t\tthis.govChange.emit(this.getCurrentTab().element)\n\t}\n\n\tprivate onKeydownHandler(e: KeyboardEvent) {\n\t\tconst keyCode = e.keyCode\n\t\te.stopPropagation()\n\t\tif (keyCode === 39 || keyCode === 37) {\n\t\t\tif (false === (this.focusIndex >= 0 && this.focusIndex <= this.controller.length - 1)) {\n\t\t\t\treturn\n\t\t\t}\n\t\t\tthis.controller[this.focusIndex].active = false\n\t\t\tif (keyCode === 39) {\n\t\t\t\tthis.focusIndex++\n\t\t\t\tif (this.focusIndex >= this.controller.length) {\n\t\t\t\t\tthis.focusIndex = 0\n\t\t\t\t}\n\t\t\t} else if (keyCode === 37) {\n\t\t\t\tthis.focusIndex--\n\t\t\t\tif (this.focusIndex < 0) {\n\t\t\t\t\tthis.focusIndex = this.controller.length - 1\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (this.focusIndex >= 0 && this.focusIndex <= this.controller.length - 1) {\n\t\t\t\tconst current = this.controller[this.focusIndex]\n\t\t\t\tcurrent.active = true\n\t\t\t\tthis.triggerRefs[current.triggerIdentifier].focus()\n\t\t\t\tthis.controller = [...this.controller]\n\t\t\t\tthis.reRender()\n\t\t\t\tthis.govChange.emit(this.getCurrentTab().element)\n\t\t\t}\n\t\t}\n\t}\n\n\t/**\n\t * Regenerate tabs controllers\n\t */\n\t@Method()\n\tasync refresh(): Promise<void> {\n\t\tthis.prepareDataSource()\n\t}\n\n\t/**\n\t * Returns the currently selected tabs-item\n\t */\n\t@Method()\n\tasync currentTab(): Promise<Nullable<HTMLGovTabsItemElement>> {\n\t\treturn this.getCurrentTab().element || null\n\t}\n\n\t/**\n\t * Regenerate tabs controllers\n\t */\n\t@Method()\n\tasync setActiveTab(identifier: string): Promise<void> {\n\t\tthis.setActiveByIdentifier(identifier)\n\t\tthis.reRender()\n\t}\n\n\t/**\n\t * Validate the WCAG attributes of the component\n\t */\n\t@Method()\n\tasync validateWcag(): Promise<void> {\n\t\tvalidateWcagProp(this.wcagSelectLabel, 'wcag-select-label', TabsClass.root)\n\t\tvalidateWcagLabel(this.wcagLabel, this.wcagLabelledBy, TabsClass.root)\n\t}\n}\n"]}
1
+ {"version":3,"file":"gov-tabs.js","sourceRoot":"","sources":["../../../../../../src/components/gov-tabs/gov-tabs.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC,EAAE,KAAK,EAAE,MAAM,EAAE,KAAK,EAAgB,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAC5G,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAA;AAC3D,OAAO,EAAE,aAAa,EAAE,WAAW,EAAe,MAAM,aAAa,CAAA;AAErE,O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;EAEH,KAAK,CAAC,UAAU;IACf,OAAO,IAAI,CAAC,aAAa,EAAE,CAAC,OAAO,IAAI,IAAI,CAAA;EAC5C,CAAC;EAED;;KAEG;EAEH,KAAK,CAAC,YAAY,CAAC,UAAkB;IACpC,IAAI,CAAC,qBAAqB,CAAC,UAAU,CAAC,CAAA;IACtC,IAAI,CAAC,QAAQ,EAAE,CAAA;EAChB,CAAC;EAED;;KAEG;EAEH,KAAK,CAAC,YAAY;IACjB,gBAAgB,CAAC,IAAI,CAAC,eAAe,EAAE,mBAAmB,EAAE,SAAS,CAAC,IAAI,CAAC,CAAA;IAC3E,iBAAiB,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,cAAc,EAAE,SAAS,CAAC,IAAI,CAAC,CAAA;EACvE,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACD","sourcesContent":["import { Component, Element, Host, h, State, Method, Event, EventEmitter, Prop, Watch } from '@stencil/core'\nimport { validateProp } from '../../helpers/Validate/props'\nimport { TabsItemClass, TabVariants, VariantType } from './constants'\nimport { GovTabControllerItem } from './gov-tabs.types'\nimport { govHost, toBoolAttr } from '../../helpers/Dom/template'\nimport { validateWcagLabel, validateWcagProp } from '../../helpers/Validate/wcag'\nimport { TabsClass, TabType, TabTypes, TabOrientationType } from './constants'\nimport { canValidateWcagOnRender } from '../../helpers/Dom/win'\nimport { delay, throttle } from '../../utils/utils'\nimport { createID } from '../../utils/string.utils'\nimport { Nullable } from '../../types/interfaces'\nimport { GovHost } from '../../helpers/Dom/template.types'\n\n@Component({\n\ttag: 'gov-tabs',\n\tstyleUrl: 'gov-tabs.scss',\n})\nexport class GovTabs {\n\tprivate h: GovHost\n\tprivate triggerRefs: { [key: string]: HTMLButtonElement } = {}\n\tprivate tabsRef?: HTMLDivElement\n\n\tprivate readonly formSelectId: string\n\n\tconstructor() {\n\t\tthis.h = govHost(this.host)\n\t\tthis.formSelectId = createID('GovForSelect')\n\t}\n\n\t@Element() host: HTMLGovTabsElement\n\t@State() controller: GovTabControllerItem[] = []\n\t@State() focusIndex = 0\n\t@State() compactControls = false\n\t/**\n\t * Tabs type\n\t */\n\t@Prop() readonly type: TabType = 'text'\n\t/**\n\t * Style variation of the tab badges.\n\t */\n\t@Prop() readonly variant?: VariantType = 'primary'\n\t/**\n\t * Tabs orientation\n\t */\n\t@Prop() readonly orientation: TabOrientationType = 'horizontal'\n\t/**\n\t * Adds accessible label for the tabs that is only shown for screen readers.\n\t */\n\t@Prop({ attribute: 'wcag-label' }) readonly wcagLabel: string\n\t/**\n\t * Adds accessible label for the tabs select\n\t */\n\t@Prop({ attribute: 'wcag-select-label' }) readonly wcagSelectLabel: string\n\t/**\n\t * Indicates the id of a component that labels the tabs.\n\t */\n\t@Prop({ attribute: 'wcag-labelled-by' }) readonly wcagLabelledBy: string\n\t/**\n\t * Emitted when the tab is changed.\n\t */\n\t@Event({ eventName: 'gov-change' }) govChange: EventEmitter<HTMLGovTabsItemElement>\n\n\t@Watch('type')\n\tvalidateType(newValue: string): void {\n\t\tvalidateProp(TabTypes, newValue, TabsClass.root)\n\t}\n\t@Watch('variant')\n\tvalidateVariant(newValue: string): void {\n\t\tvalidateProp(TabVariants, newValue, TabsClass.root)\n\t}\n\n\tcomponentWillLoad() {\n\t\tthis.prepareDataSource()\n\t}\n\n\tasync componentDidRender() {\n\t\tif (canValidateWcagOnRender()) {\n\t\t\tawait delay(500)\n\t\t\tawait this.validateWcag()\n\t\t}\n\n\t\tthis.resizeObserver()\n\t}\n\n\tprivate prepareDataSource(): void {\n\t\tthis.controller = []\n\t\tconst promises: Promise<GovTabControllerItem>[] = []\n\t\tthis.host.querySelectorAll(TabsItemClass.root).forEach((tab: HTMLGovTabsItemElement) => {\n\t\t\tconst controlItem = Promise.all([tab.getIdentifier(), tab.getTriggerIdentifier()]).then(([identifier, triggerIdentifier]) => {\n\t\t\t\tconst isDefault = typeof tab.getAttribute('default') === 'string'\n\t\t\t\treturn {\n\t\t\t\t\tlabel: tab.getAttribute('label'),\n\t\t\t\t\tcontentIdentifier: identifier,\n\t\t\t\t\ttriggerIdentifier: triggerIdentifier,\n\t\t\t\t\telement: tab,\n\t\t\t\t\tactive: false,\n\t\t\t\t\tdefault: isDefault,\n\t\t\t\t}\n\t\t\t})\n\t\t\tpromises.push(controlItem)\n\t\t})\n\t\tPromise.all(promises).then(controllers => {\n\t\t\tlet defaultTab = controllers.findIndex(controller => controller.default)\n\t\t\tif (defaultTab === -1) defaultTab = 0\n\t\t\tthis.focusIndex = defaultTab\n\t\t\tcontrollers[defaultTab].active = true\n\t\t\tthis.controller = [...controllers]\n\t\t\tthis.reRender()\n\t\t})\n\t}\n\n\tprivate setActiveByIdentifier(identifier: string) {\n\t\tconst temp = []\n\t\tthis.controller.map(item => {\n\t\t\titem.active = identifier === item.triggerIdentifier || identifier === item.contentIdentifier\n\t\t\ttemp.push(item)\n\t\t})\n\t\tthis.controller = [...temp]\n\t}\n\n\tprivate reRender() {\n\t\tthis.controller.map(control => {\n\t\t\tcontrol.element.setActiveStatus(control.active)\n\t\t})\n\t}\n\n\t/*\n\tprivate evaluateControls() {\n\t\tthis.compactControls = false\n\t\tlet sumOfWidth = this.tabsRef.querySelector(\"ul\").offsetWidth\n\t\tthis.compactControls = this.tabsRef.offsetWidth < sumOfWidth\n\t}\n\t*/\n\n\tprivate resizeObserver() {\n\t\tconst resizeObserver = new ResizeObserver(\n\t\t\tthrottle(() => {\n\t\t\t\t// this.evaluateControls()\n\t\t\t}, 200)\n\t\t)\n\n\t\tresizeObserver.observe(this.tabsRef)\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<Host\n\t\t\t\tclass={this.h.classes(TabsClass.root)}\n\t\t\t\tvariant={this.variant}\n\t\t\t\ttype={this.type}\n\t\t\t\trole=\"tablist\"\n\t\t\t\tref={el => (this.tabsRef = el as HTMLDivElement)}\n\t\t\t\taria-label={this.wcagLabel}\n\t\t\t\taria-labelledby={this.wcagLabelledBy}\n\t\t\t\tonKeyDown={this.onKeydownHandler.bind(this)}\n\t\t\t>\n\t\t\t\t<div class={TabsClass.tabs} aria-hidden={toBoolAttr(this.compactControls)}>\n\t\t\t\t\t<ul class={TabsClass.list}>\n\t\t\t\t\t\t{this.controller.map((control, index) => (\n\t\t\t\t\t\t\t<li class={TabsClass.item}>\n\t\t\t\t\t\t\t\t{this.type == 'text' ? (\n\t\t\t\t\t\t\t\t\t<button\n\t\t\t\t\t\t\t\t\t\tclass={TabsClass.btn}\n\t\t\t\t\t\t\t\t\t\tid={control.triggerIdentifier}\n\t\t\t\t\t\t\t\t\t\trole=\"tab\"\n\t\t\t\t\t\t\t\t\t\tonClick={() => this.onSelectHandler(control, index)}\n\t\t\t\t\t\t\t\t\t\taria-selected={toBoolAttr(control.active)}\n\t\t\t\t\t\t\t\t\t\taria-controls={control.contentIdentifier}\n\t\t\t\t\t\t\t\t\t\ttabindex={control.active ? -1 : 0}\n\t\t\t\t\t\t\t\t\t\tref={el => (this.triggerRefs[control.triggerIdentifier] = el as HTMLButtonElement)}\n\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t{control.label}\n\t\t\t\t\t\t\t\t\t</button>\n\t\t\t\t\t\t\t\t) : (\n\t\t\t\t\t\t\t\t\t<gov-badge\n\t\t\t\t\t\t\t\t\t\tvariant={this.variant}\n\t\t\t\t\t\t\t\t\t\ttype={toBoolAttr(control.active) == 'true' ? 'solid' : 'outlined'}\n\t\t\t\t\t\t\t\t\t\ton-gov-click={() => this.onSelectHandler(control, index)}\n\t\t\t\t\t\t\t\t\t>\n\t\t\t\t\t\t\t\t\t\t{control.label}\n\t\t\t\t\t\t\t\t\t</gov-badge>\n\t\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t</li>\n\t\t\t\t\t\t))}\n\t\t\t\t\t</ul>\n\t\t\t\t</div>\n\n\t\t\t\t<span id={this.formSelectId} hidden>\n\t\t\t\t\t{this.wcagSelectLabel}\n\t\t\t\t</span>\n\t\t\t\t{this.compactControls ? (\n\t\t\t\t\t<gov-form-select wcag-labelled-by={this.formSelectId} onGov-change={this.onChangeHandler.bind(this)}>\n\t\t\t\t\t\t{this.controller.map(control => (\n\t\t\t\t\t\t\t<option value={control.triggerIdentifier} selected={control.active}>\n\t\t\t\t\t\t\t\t{control.label}\n\t\t\t\t\t\t\t</option>\n\t\t\t\t\t\t))}\n\t\t\t\t\t</gov-form-select>\n\t\t\t\t) : null}\n\n\t\t\t\t<slot></slot>\n\t\t\t</Host>\n\t\t)\n\t}\n\n\tprivate getCurrentTab(): GovTabControllerItem | null {\n\t\treturn this.controller.find(control => control.active) || null\n\t}\n\n\tprivate onSelectHandler(control: GovTabControllerItem, index: number) {\n\t\tthis.focusIndex = index\n\t\tthis.setActiveByIdentifier(control.triggerIdentifier)\n\t\tthis.reRender()\n\t\tthis.govChange.emit(this.getCurrentTab().element)\n\t}\n\n\tprivate onChangeHandler(e: CustomEvent) {\n\t\tconst triggerId = (e.target as HTMLSelectElement).value\n\t\te.stopPropagation()\n\t\tthis.setActiveByIdentifier(triggerId)\n\t\tthis.reRender()\n\t\tthis.govChange.emit(this.getCurrentTab().element)\n\t}\n\n\tprivate onKeydownHandler(e: KeyboardEvent) {\n\t\tconst keyCode = e.keyCode\n\t\te.stopPropagation()\n\t\tif (keyCode === 39 || keyCode === 37) {\n\t\t\tif (false === (this.focusIndex >= 0 && this.focusIndex <= this.controller.length - 1)) {\n\t\t\t\treturn\n\t\t\t}\n\t\t\tthis.controller[this.focusIndex].active = false\n\t\t\tif (keyCode === 39) {\n\t\t\t\tthis.focusIndex++\n\t\t\t\tif (this.focusIndex >= this.controller.length) {\n\t\t\t\t\tthis.focusIndex = 0\n\t\t\t\t}\n\t\t\t} else if (keyCode === 37) {\n\t\t\t\tthis.focusIndex--\n\t\t\t\tif (this.focusIndex < 0) {\n\t\t\t\t\tthis.focusIndex = this.controller.length - 1\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (this.focusIndex >= 0 && this.focusIndex <= this.controller.length - 1) {\n\t\t\t\tconst current = this.controller[this.focusIndex]\n\t\t\t\tcurrent.active = true\n\t\t\t\tthis.triggerRefs[current.triggerIdentifier].focus()\n\t\t\t\tthis.controller = [...this.controller]\n\t\t\t\tthis.reRender()\n\t\t\t\tthis.govChange.emit(this.getCurrentTab().element)\n\t\t\t}\n\t\t}\n\t}\n\n\t/**\n\t * Regenerate tabs controllers\n\t */\n\t@Method()\n\tasync refresh(): Promise<void> {\n\t\tthis.prepareDataSource()\n\t}\n\n\t/**\n\t * Returns the currently selected tabs-item\n\t */\n\t@Method()\n\tasync currentTab(): Promise<Nullable<HTMLGovTabsItemElement>> {\n\t\treturn this.getCurrentTab().element || null\n\t}\n\n\t/**\n\t * Regenerate tabs controllers\n\t */\n\t@Method()\n\tasync setActiveTab(identifier: string): Promise<void> {\n\t\tthis.setActiveByIdentifier(identifier)\n\t\tthis.reRender()\n\t}\n\n\t/**\n\t * Validate the WCAG attributes of the component\n\t */\n\t@Method()\n\tasync validateWcag(): Promise<void> {\n\t\tvalidateWcagProp(this.wcagSelectLabel, 'wcag-select-label', TabsClass.root)\n\t\tvalidateWcagLabel(this.wcagLabel, this.wcagLabelledBy, TabsClass.root)\n\t}\n}\n"]}
@@ -1,7 +1,7 @@
1
- import { h, Host } from '@stencil/core';
2
- import { TilesClass } from './constants';
3
- import { prepareClasses } from '../../../helpers/Dom/template';
4
- import { govHost } from '../../../helpers/Dom/template';
1
+ import { h, Host } from "@stencil/core";
2
+ import { TilesClass } from "./constants";
3
+ import { prepareClasses } from "../../../helpers/Dom/template";
4
+ import { govHost } from "../../../helpers/Dom/template";
5
5
  export class GovTiles {
6
6
  constructor() {
7
7
  this.columns = 3;
@@ -102,13 +102,16 @@ export class GovTile {
102
102
  "parameters": [],
103
103
  "references": {
104
104
  "Promise": {
105
- "location": "global"
105
+ "location": "global",
106
+ "id": "global::Promise"
106
107
  },
107
108
  "HTMLLinkElement": {
108
- "location": "global"
109
+ "location": "global",
110
+ "id": "global::HTMLLinkElement"
109
111
  },
110
112
  "HTMLSpanElement": {
111
- "location": "global"
113
+ "location": "global",
114
+ "id": "global::HTMLSpanElement"
112
115
  }
113
116
  },
114
117
  "return": "Promise<HTMLLinkElement | HTMLSpanElement>"
@@ -1 +1 @@
1
- {"version":3,"file":"gov-tile.js","sourceRoot":"","sources":["../../../../../../src/components/gov-tile/gov-tile.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAChF,OAAO,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAA;AACvD,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAA;AACvC,OAAO,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAA;AAOpD,MAAM,OAAO,OAAO;EAInB;qBAQsC,KAAK;;;IAP1C,IAAI,CAAC,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,CAAA;GAC3B;EAiBD,YAAY,CAAC,QAAgB;IAC5B,IAAI,CAAC,QAAQ,EAAE;MACd,WAAW,CAAC,IAAI,SAAS,CAAC,IAAI,iCAAiC,CAAC,CAAA;KAChE;EACF,CAAC;EAED,iBAAiB;IAChB,IAAI,CAAC,YAAY,CAAC,IAAI,CAAC,IAAI,CAAC,CAAA;EAC7B,CAAC;EAED,MAAM;IACL,WAAW;IACX,OAAO,CACN,EAAC,IAAI,IAAC,KAAK,EAAE,IAAI,CAAC,CAAC,CAAC,OAAO,CAAC,SAAS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ent":["import { Component, Element, h, Host, Method, Prop, Watch } from \"@stencil/core\"\nimport { govErrorLog } from \"../../helpers/Log/gov.log\"\nimport { TileClass } from \"./constants\"\nimport { govHost } from \"../../helpers/Dom/template\"\nimport { GovHost } from \"../../helpers/Dom/template.types\"\n\n@Component({\n\ttag: \"gov-tile\",\n\tstyleUrl: \"gov-tile.scss\",\n})\nexport class GovTile {\n\tprivate triggerRef?: HTMLLinkElement | HTMLSpanElement\n\tprivate h: GovHost\n\n\tconstructor() {\n\t\tthis.h = govHost(this.host)\n\t}\n\n\t@Element() host: HTMLGovTileElement\n\t/**\n\t * Style variation of the card.\n\t */\n\t@Prop() readonly promotion: boolean = false\n\t/**\n\t * Link on whole tile\n\t */\n\t@Prop() readonly href: string\n\t/**\n\t * Item name\n\t */\n\t@Prop() readonly name: string\n\n\t@Watch(\"name\")\n\tvalidateName(newValue: string): void {\n\t\tif (!newValue) {\n\t\t\tgovErrorLog(`[${TileClass.root}]: Parameter title is required.`)\n\t\t}\n\t}\n\n\tcomponentWillLoad(): void {\n\t\tthis.validateName(this.name)\n\t}\n\n\trender() {\n\t\t// tag type\n\t\treturn (\n\t\t\t<Host class={this.h.classes(TileClass.root)} promotion={this.promotion}>\n\t\t\t\t{this.href ? (\n\t\t\t\t\t<a href={this.href} class={TileClass.link} ref={el => (this.triggerRef = el as HTMLLinkElement | HTMLSpanElement)}>\n\t\t\t\t\t\t{this.h.hasSlot(\"icon\") && (\n\t\t\t\t\t\t\t<div class={TileClass.icon}>\n\t\t\t\t\t\t\t\t<slot name=\"icon\" />\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t)}\n\t\t\t\t\t\t<h3 class={TileClass.title}>\n\t\t\t\t\t\t\t<span class={TileClass.heading}>\n\t\t\t\t\t\t\t\t{this.name}\n\t\t\t\t\t\t\t\t<gov-icon class={TileClass.arrow} name=\"chevron-right\"></gov-icon>\n\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t</h3>\n\t\t\t\t\t\t<div class={TileClass.content}>\n\t\t\t\t\t\t\t<slot />\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</a>\n\t\t\t\t) : (\n\t\t\t\t\t<span>\n\t\t\t\t\t\t{this.h.hasSlot(\"icon\") && (\n\t\t\t\t\t\t\t<div class={TileClass.icon}>\n\t\t\t\t\t\t\t\t<slot name=\"icon\" />\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t)}\n\t\t\t\t\t\t<h3 class={TileClass.title}>\n\t\t\t\t\t\t\t\t<span>{this.name}</span>\n\t\t\t\t\t\t</h3>\n\t\t\t\t\t\t<div class={TileClass.content}>\n\t\t\t\t\t\t\t<slot />\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</span>\n\t\t\t\t)}\n\n\t\t\t</Host>\n\t\t)\n\t}\n\n\t/**\n\t * Returns a clickable element instance\n\t */\n\t@Method()\n\tasync getTriggerRef() {\n\t\treturn this.triggerRef\n\t}\n}\n"]}
1
+ {"version":3,"file":"gov-tile.js","sourceRoot":"","sources":["../../../../../../src/components/gov-tile/gov-tile.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAChF,OAAO,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAA;AACvD,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAA;AACvC,OAAO,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAA;AAOpD,MAAM,OAAO,OAAO;EAInB;qBAQsC,KAAK;;;IAP1C,IAAI,CAAC,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,CAAA;GAC3B;EAiBD,YAAY,CAAC,QAAgB;IAC5B,IAAI,CAAC,QAAQ,EAAE;MACd,WAAW,CAAC,IAAI,SAAS,CAAC,IAAI,iCAAiC,CAAC,CAAA;KAChE;EACF,CAAC;EAED,iBAAiB;IAChB,IAA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AAa;IAClB,OAAO,IAAI,CAAC,UAAU,CAAA;EACvB,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACD","sourcesContent":["import { Component, Element, h, Host, Method, Prop, Watch } from \"@stencil/core\"\nimport { govErrorLog } from \"../../helpers/Log/gov.log\"\nimport { TileClass } from \"./constants\"\nimport { govHost } from \"../../helpers/Dom/template\"\nimport { GovHost } from \"../../helpers/Dom/template.types\"\n\n@Component({\n\ttag: \"gov-tile\",\n\tstyleUrl: \"gov-tile.scss\",\n})\nexport class GovTile {\n\tprivate triggerRef?: HTMLLinkElement | HTMLSpanElement\n\tprivate h: GovHost\n\n\tconstructor() {\n\t\tthis.h = govHost(this.host)\n\t}\n\n\t@Element() host: HTMLGovTileElement\n\t/**\n\t * Style variation of the card.\n\t */\n\t@Prop() readonly promotion: boolean = false\n\t/**\n\t * Link on whole tile\n\t */\n\t@Prop() readonly href: string\n\t/**\n\t * Item name\n\t */\n\t@Prop() readonly name: string\n\n\t@Watch(\"name\")\n\tvalidateName(newValue: string): void {\n\t\tif (!newValue) {\n\t\t\tgovErrorLog(`[${TileClass.root}]: Parameter title is required.`)\n\t\t}\n\t}\n\n\tcomponentWillLoad(): void {\n\t\tthis.validateName(this.name)\n\t}\n\n\trender() {\n\t\t// tag type\n\t\treturn (\n\t\t\t<Host class={this.h.classes(TileClass.root)} promotion={this.promotion}>\n\t\t\t\t{this.href ? (\n\t\t\t\t\t<a href={this.href} class={TileClass.link} ref={el => (this.triggerRef = el as HTMLLinkElement | HTMLSpanElement)}>\n\t\t\t\t\t\t{this.h.hasSlot(\"icon\") && (\n\t\t\t\t\t\t\t<div class={TileClass.icon}>\n\t\t\t\t\t\t\t\t<slot name=\"icon\" />\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t)}\n\t\t\t\t\t\t<h3 class={TileClass.title}>\n\t\t\t\t\t\t\t<span class={TileClass.heading}>\n\t\t\t\t\t\t\t\t{this.name}\n\t\t\t\t\t\t\t\t<gov-icon class={TileClass.arrow} name=\"chevron-right\"></gov-icon>\n\t\t\t\t\t\t\t</span>\n\t\t\t\t\t\t</h3>\n\t\t\t\t\t\t<div class={TileClass.content}>\n\t\t\t\t\t\t\t<slot />\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</a>\n\t\t\t\t) : (\n\t\t\t\t\t<span>\n\t\t\t\t\t\t{this.h.hasSlot(\"icon\") && (\n\t\t\t\t\t\t\t<div class={TileClass.icon}>\n\t\t\t\t\t\t\t\t<slot name=\"icon\" />\n\t\t\t\t\t\t\t</div>\n\t\t\t\t\t\t)}\n\t\t\t\t\t\t<h3 class={TileClass.title}>\n\t\t\t\t\t\t\t\t<span>{this.name}</span>\n\t\t\t\t\t\t</h3>\n\t\t\t\t\t\t<div class={TileClass.content}>\n\t\t\t\t\t\t\t<slot />\n\t\t\t\t\t\t</div>\n\t\t\t\t\t</span>\n\t\t\t\t)}\n\n\t\t\t</Host>\n\t\t)\n\t}\n\n\t/**\n\t * Returns a clickable element instance\n\t */\n\t@Method()\n\tasync getTriggerRef() {\n\t\treturn this.triggerRef\n\t}\n}\n"]}
@@ -1,5 +1,5 @@
1
- import { Variants, Types } from '../../core/constants/variants';
2
- import { pick } from '../../utils/utils';
1
+ import { Variants, Types } from "../../core/constants/variants";
2
+ import { pick } from "../../utils/utils";
3
3
  export const ToastVariants = pick(Variants, ['SUCCESS', 'WARNING', 'ERROR', 'SECONDARY', 'PRIMARY']);
4
4
  export const ToastTypes = pick(Types, ['CLASSIC', 'SOLID']);
5
5
  export const ToastClass = {
@@ -1,8 +1,8 @@
1
- import { h, Host } from '@stencil/core';
2
- import { validateProp } from '../../helpers/Validate/props';
3
- import { ToastClass, ToastVariants } from './constants';
4
- import { govHost } from '../../helpers/Dom/template';
5
- import { createID } from '../../utils/string.utils';
1
+ import { h, Host } from "@stencil/core";
2
+ import { validateProp } from "../../helpers/Validate/props";
3
+ import { ToastClass, ToastVariants } from "./constants";
4
+ import { govHost } from "../../helpers/Dom/template";
5
+ import { createID } from "../../utils/string.utils";
6
6
  export class GovToast {
7
7
  constructor() {
8
8
  this.variant = 'primary';
@@ -91,7 +91,8 @@ export class GovToast {
91
91
  "references": {
92
92
  "ToastVariantType": {
93
93
  "location": "import",
94
- "path": "./constants"
94
+ "path": "./constants",
95
+ "id": "../../../packages/core/src/components/gov-toast/constants.ts::ToastVariantType"
95
96
  }
96
97
  }
97
98
  },
@@ -150,7 +151,8 @@ export class GovToast {
150
151
  "references": {
151
152
  "ToastTypesType": {
152
153
  "location": "import",
153
- "path": "./constants"
154
+ "path": "./constants",
155
+ "id": "../../../packages/core/src/components/gov-toast/constants.ts::ToastTypesType"
154
156
  }
155
157
  }
156
158
  },
@@ -244,7 +246,8 @@ export class GovToast {
244
246
  "parameters": [],
245
247
  "references": {
246
248
  "Promise": {
247
- "location": "global"
249
+ "location": "global",
250
+ "id": "global::Promise"
248
251
  }
249
252
  },
250
253
  "return": "Promise<void>"
@@ -1 +1 @@
1
- {"version":3,"file":"gov-toast.js","sourceRoot":"","sources":["../../../../../../src/components/gov-toast/gov-toast.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;AACrG,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAA;AAC3D,OAAO,EAAE,UAAU,EAAkB,aAAa,EAAE,MAAM,aAAa,CAAA;AACvE,OAAO,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAA;AAGpD,OAAO,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAA;AAMnD,MAAM,OAAO,QAAQ;EAKpB;mBAS8C,SAAS;mBAKV,KAAK;oBAIO,OAAO;gBAIvB,SAAS;gBAIlB,CAAC;;;IAzBhC,IAAI,CAA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ACZ,IAAI,CAAC,GAAG,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;OAC5C,KAAK,EAAE,CAAA;EACV,CAAC;EAED,IAAI,OAAO;IACV,OAAO,IAAI,CAAC,IAAI,KAAK,OAAO,CAAA;EAC7B,CAAC;EAED,IAAI,OAAO;IACV,OAAO,MAAM,CAAC,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,IAAI,CAAC,IAAI,GAAG,CAAC,CAAA;EACpD,CAAC;EAED;;KAEG;EAEH,KAAK,CAAC,OAAO;IACZ,YAAY,CAAC,IAAI,CAAC,OAAO,CAAC,CAAA;IAC1B,MAAM,KAAK,GAAG,QAAQ,CAAC,aAAa,CAAC,mBAAmB,IAAI,CAAC,OAAO,IAAI,CAAC,CAAA;IACzE,IAAI,KAAK,EAAE;MACV,KAAK,CAAC,SAAS,CAAC,GAAG,CAAC,UAAU,CAAC,MAAM,CAAC,CAAA;MACtC,IAAI,OAAO,KAAK,CAAC,MAAM,KAAK,UAAU,EAAE;QACvC,KAAK,CAAC,MAAM,EAAE,CAAA;OACd;KACD;EACF,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACD","sourcesContent":["import { Component, Element, Event, EventEmitter, h, Host, Prop, Watch, Method } from '@stencil/core'\nimport { validateProp } from '../../helpers/Validate/props'\nimport { ToastClass, ToastTypesType, ToastVariants } from './constants'\nimport { govHost } from '../../helpers/Dom/template'\nimport { GovHost } from '../../helpers/Dom/template.types'\nimport { ToastVariantType } from './constants'\nimport { createID } from '../../utils/string.utils'\n\n@Component({\n\ttag: 'gov-toast',\n\tstyleUrl: 'gov-toast.scss',\n})\nexport class GovToast {\n\tprivate h: GovHost\n\tprivate timeout\n\tprivate readonly toastId: string\n\n\tconstructor() {\n\t\tthis.h = govHost(this.host)\n\t\tthis.toastId = createID('GovToast')\n\t}\n\n\t@Element() host: HTMLGovToastElement\n\t/**\n\t * Style variation of the toast message.\n\t */\n\t@Prop() readonly variant?: ToastVariantType = 'primary'\n\n\t/**\n\t * Toast’s gravity\n\t */\n\t@Prop() readonly gravity: 'top' | 'bottom' = 'top'\n\t/**\n\t * Toast’s position\n\t */\n\t@Prop() readonly position: 'left' | 'center' | 'right' = 'right'\n\t/**\n\t * Toast type\n\t */\n\t@Prop() readonly type?: ToastTypesType = 'classic'\n\t/**\n\t * Number of milliseconds to wait before Toast disappear\n\t */\n\t@Prop() readonly time: number = 0\n\t/**\n\t * Closing button texting instead of icons\n\t */\n\t@Prop({ attribute: 'close-label' }) readonly closeLabel: string\n\t/**\n\t * Aria label for the closing button. It is mandatory if the alert is closable\n\t */\n\t@Prop({ attribute: 'wcag-close-label' }) readonly wcagCloseLabel: string\n\t/**\n\t * Called when the close button is clicked\n\t */\n\t@Event({ eventName: 'gov-close' }) govClose: EventEmitter<string>\n\n\t@Watch('variant')\n\tvalidateVariant(newValue: string): void {\n\t\tvalidateProp(ToastVariants, newValue, ToastClass.root)\n\t}\n\n\tcomponentWillLoad(): void {\n\t\tthis.validateVariant(this.variant)\n\t\tthis.runTimer()\n\t}\n\n\tcomponentDidLoad() {\n\t\tconst existedToasts = document.querySelectorAll(`gov-toast[gravity=\"${this.gravity}\"][position=\"${this.position}\"]:not([data-toast-id=\"${this.toastId}\"])`)\n\t\tif (existedToasts.length > 0) {\n\t\t\tArray.from(existedToasts).map((toast: HTMLGovToastElement) => toast.destroy().then())\n\t\t}\n\t}\n\n\tdisconnectedCallback() {\n\t\tclearTimeout(this.timeout)\n\t}\n\n\tprivate runTimer() {\n\t\tif (this.isSolid) {\n\t\t\tthis.host.classList.add('is-initialized')\n\t\t}\n\t\tif (this.isTimer) {\n\t\t\tthis.timeout = setTimeout(() => {\n\t\t\t\tthis.host.classList.add(ToastClass.hidden)\n\t\t\t\tsetTimeout(this.destroy.bind(this), 600)\n\t\t\t}, this.time)\n\t\t}\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<Host\n\t\t\t\tclass={this.h.classes([ToastClass.root, 'gov-box-shadow--m'])}\n\t\t\t\tdata-toast-id={this.toastId}\n\t\t\t\tgravity={this.gravity}\n\t\t\t\tposition={this.position}\n\t\t\t\tvariant={this.variant}\n\t\t\t\ttype={this.type}\n\t\t\t\tstyle={{ '--toast-duration': this.time + 'ms' }}\n\t\t\t>\n\t\t\t\t{this.h.hasSlot('icon') && (\n\t\t\t\t\t<span class={ToastClass.icon}>\n\t\t\t\t\t\t<slot name=\"icon\" />\n\t\t\t\t\t</span>\n\t\t\t\t)}\n\n\t\t\t\t<div class={ToastClass.content} aria-live=\"polite\" role=\"status\">\n\t\t\t\t\t<slot />\n\t\t\t\t</div>\n\n\t\t\t\t<div class={ToastClass.close}>\n\t\t\t\t\t<gov-button\n\t\t\t\t\t\tsize=\"s\"\n\t\t\t\t\t\twcag-label={this.wcagCloseLabel}\n\t\t\t\t\t\tvariant={this.isSolid ? this.variant : 'secondary'}\n\t\t\t\t\t\tinverse={this.isSolid}\n\t\t\t\t\t\ttype=\"base\"\n\t\t\t\t\t\ton-gov-click={this.onCloseHandler.bind(this)}\n\t\t\t\t\t>\n\t\t\t\t\t\t{this.closeLabel ? this.closeLabel : <gov-icon name=\"x-lg\"></gov-icon>}\n\t\t\t\t\t</gov-button>\n\t\t\t\t</div>\n\n\t\t\t\t<div class={ToastClass.timer}></div>\n\t\t\t</Host>\n\t\t)\n\t}\n\n\tprivate onCloseHandler(): void {\n\t\tthis.destroy()\n\t\t\t.then(() => this.govClose.emit(this.toastId))\n\t\t\t.catch()\n\t}\n\n\tget isSolid(): boolean {\n\t\treturn this.type === 'solid'\n\t}\n\n\tget isTimer(): boolean {\n\t\treturn Number.isInteger(this.time) && this.time > 0\n\t}\n\n\t/**\n\t * Remove toast from dom\n\t */\n\t@Method()\n\tasync destroy(): Promise<void> {\n\t\tclearTimeout(this.timeout)\n\t\tconst toast = document.querySelector(`[data-toast-id=\"${this.toastId}\"]`)\n\t\tif (toast) {\n\t\t\ttoast.classList.add(ToastClass.hidden)\n\t\t\tif (typeof toast.remove === 'function') {\n\t\t\t\ttoast.remove()\n\t\t\t}\n\t\t}\n\t}\n}\n"]}
1
+ {"version":3,"file":"gov-toast.js","sourceRoot":"","sources":["../../../../../../src/components/gov-toast/gov-toast.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,CAAC,EAAE,IAAI,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;AACrG,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAA;AAC3D,OAAO,EAAE,UAAU,EAAkB,aAAa,EAAE,MAAM,aAAa,CAAA;AACvE,OAAO,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAA;AAGpD,OAAO,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAA;AAMnD,MAAM,OAAO,QAAQ;EAKpB;mBAS8C,SAAS;mBAKV,KAAK;oBAIO,OAAO;gBAIvB,SAAS;gBAIlB,CAAC;;;IAzBhC,IAAI,CAAC,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,CAAA;IAC3B,IAAI,CAAC,OAAO,GAAG,QAAQ,CAAC,UAAU,CAAC,CAAA;GACnC;EAsCD,eAAe,CAAC,QAAgB;IAC/B,YAAY,CAAC,aAAa,EAAE,QAAQ,EAAE,UAAU,CAAC,IAAI,CAAC,CAAA;EACvD,CAAC;EAED,iBAAiB;IAChB,IAAI,CAAC,eAAe,CAAC,IAAI,CAAC,OAAO,CAAC,CAAA;IAClC,IAAI,CAAC,QAAQ,EAAE,CAAA;EAChB,CAAC;EAED,gBAAgB;IACf,MAAM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Z,YAAY,CAAC,IAAI,CAAC,OAAO,CAAC,CAAA;IAC1B,MAAM,KAAK,GAAG,QAAQ,CAAC,aAAa,CAAC,mBAAmB,IAAI,CAAC,OAAO,IAAI,CAAC,CAAA;IACzE,IAAI,KAAK,EAAE;MACV,KAAK,CAAC,SAAS,CAAC,GAAG,CAAC,UAAU,CAAC,MAAM,CAAC,CAAA;MACtC,IAAI,OAAO,KAAK,CAAC,MAAM,KAAK,UAAU,EAAE;QACvC,KAAK,CAAC,MAAM,EAAE,CAAA;OACd;KACD;EACF,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACD","sourcesContent":["import { Component, Element, Event, EventEmitter, h, Host, Prop, Watch, Method } from '@stencil/core'\nimport { validateProp } from '../../helpers/Validate/props'\nimport { ToastClass, ToastTypesType, ToastVariants } from './constants'\nimport { govHost } from '../../helpers/Dom/template'\nimport { GovHost } from '../../helpers/Dom/template.types'\nimport { ToastVariantType } from './constants'\nimport { createID } from '../../utils/string.utils'\n\n@Component({\n\ttag: 'gov-toast',\n\tstyleUrl: 'gov-toast.scss',\n})\nexport class GovToast {\n\tprivate h: GovHost\n\tprivate timeout\n\tprivate readonly toastId: string\n\n\tconstructor() {\n\t\tthis.h = govHost(this.host)\n\t\tthis.toastId = createID('GovToast')\n\t}\n\n\t@Element() host: HTMLGovToastElement\n\t/**\n\t * Style variation of the toast message.\n\t */\n\t@Prop() readonly variant?: ToastVariantType = 'primary'\n\n\t/**\n\t * Toast’s gravity\n\t */\n\t@Prop() readonly gravity: 'top' | 'bottom' = 'top'\n\t/**\n\t * Toast’s position\n\t */\n\t@Prop() readonly position: 'left' | 'center' | 'right' = 'right'\n\t/**\n\t * Toast type\n\t */\n\t@Prop() readonly type?: ToastTypesType = 'classic'\n\t/**\n\t * Number of milliseconds to wait before Toast disappear\n\t */\n\t@Prop() readonly time: number = 0\n\t/**\n\t * Closing button texting instead of icons\n\t */\n\t@Prop({ attribute: 'close-label' }) readonly closeLabel: string\n\t/**\n\t * Aria label for the closing button. It is mandatory if the alert is closable\n\t */\n\t@Prop({ attribute: 'wcag-close-label' }) readonly wcagCloseLabel: string\n\t/**\n\t * Called when the close button is clicked\n\t */\n\t@Event({ eventName: 'gov-close' }) govClose: EventEmitter<string>\n\n\t@Watch('variant')\n\tvalidateVariant(newValue: string): void {\n\t\tvalidateProp(ToastVariants, newValue, ToastClass.root)\n\t}\n\n\tcomponentWillLoad(): void {\n\t\tthis.validateVariant(this.variant)\n\t\tthis.runTimer()\n\t}\n\n\tcomponentDidLoad() {\n\t\tconst existedToasts = document.querySelectorAll(`gov-toast[gravity=\"${this.gravity}\"][position=\"${this.position}\"]:not([data-toast-id=\"${this.toastId}\"])`)\n\t\tif (existedToasts.length > 0) {\n\t\t\tArray.from(existedToasts).map((toast: HTMLGovToastElement) => toast.destroy().then())\n\t\t}\n\t}\n\n\tdisconnectedCallback() {\n\t\tclearTimeout(this.timeout)\n\t}\n\n\tprivate runTimer() {\n\t\tif (this.isSolid) {\n\t\t\tthis.host.classList.add('is-initialized')\n\t\t}\n\t\tif (this.isTimer) {\n\t\t\tthis.timeout = setTimeout(() => {\n\t\t\t\tthis.host.classList.add(ToastClass.hidden)\n\t\t\t\tsetTimeout(this.destroy.bind(this), 600)\n\t\t\t}, this.time)\n\t\t}\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<Host\n\t\t\t\tclass={this.h.classes([ToastClass.root, 'gov-box-shadow--m'])}\n\t\t\t\tdata-toast-id={this.toastId}\n\t\t\t\tgravity={this.gravity}\n\t\t\t\tposition={this.position}\n\t\t\t\tvariant={this.variant}\n\t\t\t\ttype={this.type}\n\t\t\t\tstyle={{ '--toast-duration': this.time + 'ms' }}\n\t\t\t>\n\t\t\t\t{this.h.hasSlot('icon') && (\n\t\t\t\t\t<span class={ToastClass.icon}>\n\t\t\t\t\t\t<slot name=\"icon\" />\n\t\t\t\t\t</span>\n\t\t\t\t)}\n\n\t\t\t\t<div class={ToastClass.content} aria-live=\"polite\" role=\"status\">\n\t\t\t\t\t<slot />\n\t\t\t\t</div>\n\n\t\t\t\t<div class={ToastClass.close}>\n\t\t\t\t\t<gov-button\n\t\t\t\t\t\tsize=\"s\"\n\t\t\t\t\t\twcag-label={this.wcagCloseLabel}\n\t\t\t\t\t\tvariant={this.isSolid ? this.variant : 'secondary'}\n\t\t\t\t\t\tinverse={this.isSolid}\n\t\t\t\t\t\ttype=\"base\"\n\t\t\t\t\t\ton-gov-click={this.onCloseHandler.bind(this)}\n\t\t\t\t\t>\n\t\t\t\t\t\t{this.closeLabel ? this.closeLabel : <gov-icon name=\"x-lg\"></gov-icon>}\n\t\t\t\t\t</gov-button>\n\t\t\t\t</div>\n\n\t\t\t\t<div class={ToastClass.timer}></div>\n\t\t\t</Host>\n\t\t)\n\t}\n\n\tprivate onCloseHandler(): void {\n\t\tthis.destroy()\n\t\t\t.then(() => this.govClose.emit(this.toastId))\n\t\t\t.catch()\n\t}\n\n\tget isSolid(): boolean {\n\t\treturn this.type === 'solid'\n\t}\n\n\tget isTimer(): boolean {\n\t\treturn Number.isInteger(this.time) && this.time > 0\n\t}\n\n\t/**\n\t * Remove toast from dom\n\t */\n\t@Method()\n\tasync destroy(): Promise<void> {\n\t\tclearTimeout(this.timeout)\n\t\tconst toast = document.querySelector(`[data-toast-id=\"${this.toastId}\"]`)\n\t\tif (toast) {\n\t\t\ttoast.classList.add(ToastClass.hidden)\n\t\t\tif (typeof toast.remove === 'function') {\n\t\t\t\ttoast.remove()\n\t\t\t}\n\t\t}\n\t}\n}\n"]}
@@ -1,6 +1,6 @@
1
- import { Variants } from '../../core/constants/variants';
2
- import { Sizes } from '../../core/constants/sizes';
3
- import { pick } from '../../utils/utils';
1
+ import { Variants } from "../../core/constants/variants";
2
+ import { Sizes } from "../../core/constants/sizes";
3
+ import { pick } from "../../utils/utils";
4
4
  export const TooltipVariant = pick(Variants, ['PRIMARY', 'SECONDARY']);
5
5
  export const TooltipSize = pick(Sizes, ['_S', '_M', '_L']);
6
6
  export var TooltipPosition;
@@ -1,6 +1,6 @@
1
- import { h, Host } from '@stencil/core';
2
- import { TooltipContentClass } from './constants';
3
- import { toBoolAttr } from '../../helpers/Dom/template';
1
+ import { h, Host } from "@stencil/core";
2
+ import { TooltipContentClass } from "./constants";
3
+ import { toBoolAttr } from "../../helpers/Dom/template";
4
4
  export class GovTooltipContent {
5
5
  constructor() {
6
6
  this.isVisible = false;
@@ -1,8 +1,8 @@
1
- import { h, Host } from '@stencil/core';
2
- import { validateProp } from '../../helpers/Validate/props';
3
- import { TooltipPosition, TooltipSize, TooltipClass, TooltipContentClass, TooltipVariant, } from './constants';
4
- import { createID } from '../../utils/string.utils';
5
- import { govHost } from '../../helpers/Dom/template';
1
+ import { h, Host } from "@stencil/core";
2
+ import { validateProp } from "../../helpers/Validate/props";
3
+ import { TooltipPosition, TooltipSize, TooltipClass, TooltipContentClass, TooltipVariant, } from "./constants";
4
+ import { createID } from "../../utils/string.utils";
5
+ import { govHost } from "../../helpers/Dom/template";
6
6
  export class GovTooltip {
7
7
  constructor() {
8
8
  this.variant = 'primary';
@@ -154,7 +154,8 @@ export class GovTooltip {
154
154
  "references": {
155
155
  "TooltipVariantType": {
156
156
  "location": "import",
157
- "path": "./constants"
157
+ "path": "./constants",
158
+ "id": "../../../packages/core/src/components/gov-tooltip/constants.tsx::TooltipVariantType"
158
159
  }
159
160
  }
160
161
  },
@@ -177,7 +178,8 @@ export class GovTooltip {
177
178
  "references": {
178
179
  "TooltipSizeType": {
179
180
  "location": "import",
180
- "path": "./constants"
181
+ "path": "./constants",
182
+ "id": "../../../packages/core/src/components/gov-tooltip/constants.tsx::TooltipSizeType"
181
183
  }
182
184
  }
183
185
  },
@@ -200,7 +202,8 @@ export class GovTooltip {
200
202
  "references": {
201
203
  "TooltipPositionType": {
202
204
  "location": "import",
203
- "path": "./constants"
205
+ "path": "./constants",
206
+ "id": "../../../packages/core/src/components/gov-tooltip/constants.tsx::TooltipPositionType"
204
207
  }
205
208
  }
206
209
  },
@@ -277,7 +280,8 @@ export class GovTooltip {
277
280
  "parameters": [],
278
281
  "references": {
279
282
  "Promise": {
280
- "location": "global"
283
+ "location": "global",
284
+ "id": "global::Promise"
281
285
  }
282
286
  },
283
287
  "return": "Promise<void>"
@@ -293,7 +297,8 @@ export class GovTooltip {
293
297
  "parameters": [],
294
298
  "references": {
295
299
  "Promise": {
296
- "location": "global"
300
+ "location": "global",
301
+ "id": "global::Promise"
297
302
  }
298
303
  },
299
304
  "return": "Promise<void>"
@@ -1 +1 @@
1
- {"version":3,"file":"gov-tooltip.js","sourceRoot":"","sources":["../../../../../../src/components/gov-tooltip/gov-tooltip.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAChF,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAA;AAC3D,OAAO,EACN,eAAe,EAEf,WAAW,EAEX,YAAY,EACZ,mBAAmB,EACnB,cAAc,GAEd,MAAM,aAAa,CAAA;AACpB,OAAO,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAA;AACnD,OAAO,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAA;AAOpD,MAAM,OAAO,UAAU;EAKtB;mBASgD,SAAS;gBAIf,GAAG;oBAIL,OAAO;mBAIZ,SAAS;;gBAQU,SAAS;IA5B9D,IAAI,CAAC,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,CAAA;IAC3B,IAAI,CAAC,SAAS,GAAG,QAAQ,CAAC,YAAY,CAAC,CAAA;GACvC;EA6BD,eAAe,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I;IACT,IAAI,CAAC,WAAW,EAAE,CAAA;EACnB,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACD","sourcesContent":["import { Component, Element, h, Host, Method, Prop, Watch } from '@stencil/core'\nimport { validateProp } from '../../helpers/Validate/props'\nimport {\n\tTooltipPosition,\n\tTooltipPositionType,\n\tTooltipSize,\n\tTooltipSizeType,\n\tTooltipClass,\n\tTooltipContentClass,\n\tTooltipVariant,\n\tTooltipVariantType,\n} from './constants'\nimport { createID } from '../../utils/string.utils'\nimport { govHost } from '../../helpers/Dom/template'\nimport { GovHost } from '../../helpers/Dom/template.types'\n\n@Component({\n\ttag: 'gov-tooltip',\n\tstyleUrl: 'gov-tooltip.scss',\n})\nexport class GovTooltip {\n\tprivate h: GovHost\n\tprivate content: HTMLGovTooltipContentElement\n\tprivate readonly tooltipId\n\n\tconstructor() {\n\t\tthis.h = govHost(this.host)\n\t\tthis.tooltipId = createID('GovTooltip')\n\t}\n\n\t@Element() host: HTMLGovTooltipElement\n\t/**\n\t * Style variation of the tooltip\n\t */\n\t@Prop() readonly variant?: TooltipVariantType = 'primary'\n\t/**\n\t * Tooltip’s size.\n\t */\n\t@Prop() readonly size?: TooltipSizeType = 'm'\n\t/**\n\t * Tooltip display position\n\t */\n\t@Prop() position: TooltipPositionType = 'right'\n\t/**\n\t * Information contained in the tolltip\n\t */\n\t@Prop() readonly message: string = undefined\n\t/**\n\t * Custom tooltip identifier.\n\t */\n\t@Prop({ attribute: 'identifier' }) readonly identifier: string\n\t/**\n\t * Trigger is just an icon\n\t */\n\t@Prop({ attribute: 'icon' }) readonly icon: boolean = undefined\n\n\t@Watch('variant')\n\tvalidateVariant(newValue: string): void {\n\t\tvalidateProp(TooltipVariant, newValue, TooltipClass.root)\n\t}\n\n\t@Watch('size')\n\tvalidateSize(newValue: string): void {\n\t\tvalidateProp(TooltipSize, newValue, TooltipClass.root)\n\t}\n\n\t@Watch('position')\n\tvalidatePosition(newValue: string): void {\n\t\tvalidateProp(TooltipPosition, newValue, TooltipClass.root)\n\t}\n\n\tcomponentWillLoad(): void {\n\t\tthis.validateVariant(this.variant)\n\t\tthis.validateSize(this.size)\n\t\tthis.validatePosition(this.position)\n\n\t\tthis.createContentWrapper()\n\t\tthis.registerListeners()\n\t}\n\n\tprivate createContentWrapper() {\n\t\tconst hasContentInside = this.host.querySelector(TooltipContentClass.root) as HTMLGovTooltipContentElement\n\t\tif (hasContentInside) {\n\t\t\tthis.content = hasContentInside\n\t\t} else {\n\t\t\tthis.content = document.createElement(TooltipContentClass.root) as HTMLGovTooltipContentElement\n\t\t\tthis.content.innerHTML = this.message\n\t\t\tthis.host.appendChild(this.content)\n\t\t}\n\n\t\tthis.content.setAttribute('id', this.identifier ?? this.tooltipId)\n\t}\n\n\tprivate registerListeners() {\n\t\tthis.host.addEventListener('focus', e => {\n\t\t\te.preventDefault()\n\t\t\tthis.showTooltip()\n\t\t})\n\t\tthis.host.addEventListener('blur', e => {\n\t\t\te.preventDefault()\n\t\t\tthis.hideTooltip()\n\t\t})\n\t\tthis.host.addEventListener('mouseenter', e => {\n\t\t\te.preventDefault()\n\t\t\tthis.showTooltip()\n\t\t})\n\t\tthis.host.addEventListener('mouseleave', e => {\n\t\t\te.preventDefault()\n\t\t\tthis.hideTooltip()\n\t\t})\n\t}\n\n\tprivate verifyPositionSpace() {\n\t\t// @TODO Improve positioning of broken lines\n\t\tconst offset = 12\n\t\tconst windowWidth = window.innerWidth\n\t\tconst trigger = this.host.getBoundingClientRect()\n\t\tconst trgWidth = this.host.offsetWidth\n\t\tconst triggerPos = {\n\t\t\tleft: trigger.left + document.documentElement.scrollLeft,\n\t\t\ttop: trigger.top + document.documentElement.scrollTop,\n\t\t}\n\t\tconst tltWidth = this.content.offsetWidth\n\t\tif (this.position === TooltipPosition.LEFT) {\n\t\t\tif (offset + triggerPos.left < tltWidth) {\n\t\t\t\tthis.position = TooltipPosition.TOP\n\t\t\t\tthis.content.style.left = '0px'\n\t\t\t\tthis.content.style.width = window.innerWidth - triggerPos.left - offset + 'px'\n\t\t\t\tthis.content.style.transform = 'none'\n\t\t\t}\n\t\t} else if (this.position === TooltipPosition.RIGHT) {\n\t\t\tif (windowWidth - (triggerPos.left + trgWidth) < tltWidth) {\n\t\t\t\tthis.position = TooltipPosition.TOP\n\t\t\t\tthis.content.style.right = '0px'\n\t\t\t\tthis.content.style.left = 'auto'\n\t\t\t\tthis.content.style.width = trgWidth + triggerPos.left + offset + 'px'\n\t\t\t\tthis.content.style.transform = 'none'\n\t\t\t}\n\t\t} else {\n\t\t\t// doesn't fit from the left\n\t\t\tif (tltWidth / 2 > triggerPos.left) {\n\t\t\t\tthis.content.style.left = '0px'\n\t\t\t\tthis.content.style.width = window.innerWidth - triggerPos.left - offset + 'px'\n\t\t\t\tthis.content.style.transform = 'none'\n\t\t\t}\n\t\t\t// doesn't fit from the right\n\t\t\telse if (tltWidth / 2 > windowWidth - (triggerPos.left + tltWidth)) {\n\t\t\t\tthis.content.style.right = '0px'\n\t\t\t\tthis.content.style.left = 'auto'\n\t\t\t\tthis.content.style.width = trgWidth + triggerPos.left + offset + 'px'\n\t\t\t\tthis.content.style.transform = 'none'\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate showTooltip() {\n\t\tif (this.content) {\n\t\t\tthis.verifyPositionSpace()\n\t\t\tthis.content.setAttribute('is-visible', 'true')\n\t\t}\n\t}\n\n\tprivate hideTooltip() {\n\t\tif (this.content) {\n\t\t\tthis.content.setAttribute('is-visible', 'false')\n\t\t}\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<Host\n\t\t\t\tclass={this.h.classes(TooltipClass.root)}\n\t\t\t\tposition={this.position}\n\t\t\t\tsize={this.size}\n\t\t\t\ttabindex={0}\n\t\t\t\taria-describedby={this.identifier ?? this.tooltipId}\n\t\t\t\tvariant={this.variant}\n\t\t\t>\n\t\t\t\t<slot />\n\t\t\t</Host>\n\t\t)\n\t}\n\n\t/**\n\t * Showing the modal\n\t */\n\t@Method()\n\tasync show(): Promise<void> {\n\t\tthis.showTooltip()\n\t}\n\n\t/**\n\t * Hidding the modal\n\t */\n\t@Method()\n\tasync hide(): Promise<void> {\n\t\tthis.hideTooltip()\n\t}\n}\n"]}
1
+ {"version":3,"file":"gov-tooltip.js","sourceRoot":"","sources":["../../../../../../src/components/gov-tooltip/gov-tooltip.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAChF,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAA;AAC3D,OAAO,EACN,eAAe,EAEf,WAAW,EAEX,YAAY,EACZ,mBAAmB,EACnB,cAAc,GAEd,MAAM,aAAa,CAAA;AACpB,OAAO,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAA;AACnD,OAAO,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAA;AAOpD,MAAM,OAAO,UAAU;EAKtB;mBASgD,SAAS;gBAIf,GAAG;oBAIL,OAAO;mBAIZ,SAAS;;gBAQU,SAAS;IA5B9D,IAAI,CAAC,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,IAAI,CAAC,CAAA;IAC3B,IAAI,CAAC,SAAS,GAAG,QAAQ,CAAC,YAAY,CAAC,CAAA;GACvC;EA6BD,eAAe,CAAC,QAAgB;IAC/B,YAAY,CAAC,cAAc,EAAE,QAAQ,EAAE,YAAY,CAAC,IAAI,CAAC,CAAA;EAC1D,CAAC;EAGD,YAAY,CAAC,QAAgB;IAC5B,YAAY,CAAC,WAAW,EAAE,QAAQ,EAAE,YAAY,CAAC,IAAI,CAAC,CAA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACD","sourcesContent":["import { Component, Element, h, Host, Method, Prop, Watch } from '@stencil/core'\nimport { validateProp } from '../../helpers/Validate/props'\nimport {\n\tTooltipPosition,\n\tTooltipPositionType,\n\tTooltipSize,\n\tTooltipSizeType,\n\tTooltipClass,\n\tTooltipContentClass,\n\tTooltipVariant,\n\tTooltipVariantType,\n} from './constants'\nimport { createID } from '../../utils/string.utils'\nimport { govHost } from '../../helpers/Dom/template'\nimport { GovHost } from '../../helpers/Dom/template.types'\n\n@Component({\n\ttag: 'gov-tooltip',\n\tstyleUrl: 'gov-tooltip.scss',\n})\nexport class GovTooltip {\n\tprivate h: GovHost\n\tprivate content: HTMLGovTooltipContentElement\n\tprivate readonly tooltipId\n\n\tconstructor() {\n\t\tthis.h = govHost(this.host)\n\t\tthis.tooltipId = createID('GovTooltip')\n\t}\n\n\t@Element() host: HTMLGovTooltipElement\n\t/**\n\t * Style variation of the tooltip\n\t */\n\t@Prop() readonly variant?: TooltipVariantType = 'primary'\n\t/**\n\t * Tooltip’s size.\n\t */\n\t@Prop() readonly size?: TooltipSizeType = 'm'\n\t/**\n\t * Tooltip display position\n\t */\n\t@Prop() position: TooltipPositionType = 'right'\n\t/**\n\t * Information contained in the tolltip\n\t */\n\t@Prop() readonly message: string = undefined\n\t/**\n\t * Custom tooltip identifier.\n\t */\n\t@Prop({ attribute: 'identifier' }) readonly identifier: string\n\t/**\n\t * Trigger is just an icon\n\t */\n\t@Prop({ attribute: 'icon' }) readonly icon: boolean = undefined\n\n\t@Watch('variant')\n\tvalidateVariant(newValue: string): void {\n\t\tvalidateProp(TooltipVariant, newValue, TooltipClass.root)\n\t}\n\n\t@Watch('size')\n\tvalidateSize(newValue: string): void {\n\t\tvalidateProp(TooltipSize, newValue, TooltipClass.root)\n\t}\n\n\t@Watch('position')\n\tvalidatePosition(newValue: string): void {\n\t\tvalidateProp(TooltipPosition, newValue, TooltipClass.root)\n\t}\n\n\tcomponentWillLoad(): void {\n\t\tthis.validateVariant(this.variant)\n\t\tthis.validateSize(this.size)\n\t\tthis.validatePosition(this.position)\n\n\t\tthis.createContentWrapper()\n\t\tthis.registerListeners()\n\t}\n\n\tprivate createContentWrapper() {\n\t\tconst hasContentInside = this.host.querySelector(TooltipContentClass.root) as HTMLGovTooltipContentElement\n\t\tif (hasContentInside) {\n\t\t\tthis.content = hasContentInside\n\t\t} else {\n\t\t\tthis.content = document.createElement(TooltipContentClass.root) as HTMLGovTooltipContentElement\n\t\t\tthis.content.innerHTML = this.message\n\t\t\tthis.host.appendChild(this.content)\n\t\t}\n\n\t\tthis.content.setAttribute('id', this.identifier ?? this.tooltipId)\n\t}\n\n\tprivate registerListeners() {\n\t\tthis.host.addEventListener('focus', e => {\n\t\t\te.preventDefault()\n\t\t\tthis.showTooltip()\n\t\t})\n\t\tthis.host.addEventListener('blur', e => {\n\t\t\te.preventDefault()\n\t\t\tthis.hideTooltip()\n\t\t})\n\t\tthis.host.addEventListener('mouseenter', e => {\n\t\t\te.preventDefault()\n\t\t\tthis.showTooltip()\n\t\t})\n\t\tthis.host.addEventListener('mouseleave', e => {\n\t\t\te.preventDefault()\n\t\t\tthis.hideTooltip()\n\t\t})\n\t}\n\n\tprivate verifyPositionSpace() {\n\t\t// @TODO Improve positioning of broken lines\n\t\tconst offset = 12\n\t\tconst windowWidth = window.innerWidth\n\t\tconst trigger = this.host.getBoundingClientRect()\n\t\tconst trgWidth = this.host.offsetWidth\n\t\tconst triggerPos = {\n\t\t\tleft: trigger.left + document.documentElement.scrollLeft,\n\t\t\ttop: trigger.top + document.documentElement.scrollTop,\n\t\t}\n\t\tconst tltWidth = this.content.offsetWidth\n\t\tif (this.position === TooltipPosition.LEFT) {\n\t\t\tif (offset + triggerPos.left < tltWidth) {\n\t\t\t\tthis.position = TooltipPosition.TOP\n\t\t\t\tthis.content.style.left = '0px'\n\t\t\t\tthis.content.style.width = window.innerWidth - triggerPos.left - offset + 'px'\n\t\t\t\tthis.content.style.transform = 'none'\n\t\t\t}\n\t\t} else if (this.position === TooltipPosition.RIGHT) {\n\t\t\tif (windowWidth - (triggerPos.left + trgWidth) < tltWidth) {\n\t\t\t\tthis.position = TooltipPosition.TOP\n\t\t\t\tthis.content.style.right = '0px'\n\t\t\t\tthis.content.style.left = 'auto'\n\t\t\t\tthis.content.style.width = trgWidth + triggerPos.left + offset + 'px'\n\t\t\t\tthis.content.style.transform = 'none'\n\t\t\t}\n\t\t} else {\n\t\t\t// doesn't fit from the left\n\t\t\tif (tltWidth / 2 > triggerPos.left) {\n\t\t\t\tthis.content.style.left = '0px'\n\t\t\t\tthis.content.style.width = window.innerWidth - triggerPos.left - offset + 'px'\n\t\t\t\tthis.content.style.transform = 'none'\n\t\t\t}\n\t\t\t// doesn't fit from the right\n\t\t\telse if (tltWidth / 2 > windowWidth - (triggerPos.left + tltWidth)) {\n\t\t\t\tthis.content.style.right = '0px'\n\t\t\t\tthis.content.style.left = 'auto'\n\t\t\t\tthis.content.style.width = trgWidth + triggerPos.left + offset + 'px'\n\t\t\t\tthis.content.style.transform = 'none'\n\t\t\t}\n\t\t}\n\t}\n\n\tprivate showTooltip() {\n\t\tif (this.content) {\n\t\t\tthis.verifyPositionSpace()\n\t\t\tthis.content.setAttribute('is-visible', 'true')\n\t\t}\n\t}\n\n\tprivate hideTooltip() {\n\t\tif (this.content) {\n\t\t\tthis.content.setAttribute('is-visible', 'false')\n\t\t}\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<Host\n\t\t\t\tclass={this.h.classes(TooltipClass.root)}\n\t\t\t\tposition={this.position}\n\t\t\t\tsize={this.size}\n\t\t\t\ttabindex={0}\n\t\t\t\taria-describedby={this.identifier ?? this.tooltipId}\n\t\t\t\tvariant={this.variant}\n\t\t\t>\n\t\t\t\t<slot />\n\t\t\t</Host>\n\t\t)\n\t}\n\n\t/**\n\t * Showing the modal\n\t */\n\t@Method()\n\tasync show(): Promise<void> {\n\t\tthis.showTooltip()\n\t}\n\n\t/**\n\t * Hidding the modal\n\t */\n\t@Method()\n\tasync hide(): Promise<void> {\n\t\tthis.hideTooltip()\n\t}\n}\n"]}
@@ -1,6 +1,6 @@
1
- import { Variants } from '../../core/constants/variants';
2
- import { Sizes } from '../../core/constants/sizes';
3
- import { pick } from '../../utils/utils';
1
+ import { Variants } from "../../core/constants/variants";
2
+ import { Sizes } from "../../core/constants/sizes";
3
+ import { pick } from "../../utils/utils";
4
4
  export const WizardVariants = pick(Variants, ['PRIMARY', 'SECONDARY', 'WARNING', 'ERROR', 'SUCCESS']);
5
5
  export const WizardSizes = pick(Sizes, ['_XS', '_S', '_M']);
6
6
  export const WizzardClass = {
@@ -110,7 +110,8 @@ export class GovWizzardItem {
110
110
  "references": {
111
111
  "WizardVariantsType": {
112
112
  "location": "import",
113
- "path": "./constants"
113
+ "path": "./constants",
114
+ "id": "../../../packages/core/src/components/gov-wizzard/constants.ts::WizardVariantsType"
114
115
  }
115
116
  }
116
117
  },
@@ -133,7 +134,8 @@ export class GovWizzardItem {
133
134
  "references": {
134
135
  "WizardSizesType": {
135
136
  "location": "import",
136
- "path": "./constants"
137
+ "path": "./constants",
138
+ "id": "../../../packages/core/src/components/gov-wizzard/constants.ts::WizardSizesType"
137
139
  }
138
140
  }
139
141
  },
@@ -289,7 +291,8 @@ export class GovWizzardItem {
289
291
  "references": {
290
292
  "WizzardItemEvent": {
291
293
  "location": "import",
292
- "path": "./gov-wizzard-item.types"
294
+ "path": "./gov-wizzard-item.types",
295
+ "id": "../../../packages/core/src/components/gov-wizzard/gov-wizzard-item.types.ts::WizzardItemEvent"
293
296
  }
294
297
  }
295
298
  }
@@ -303,7 +306,8 @@ export class GovWizzardItem {
303
306
  "parameters": [],
304
307
  "references": {
305
308
  "Promise": {
306
- "location": "global"
309
+ "location": "global",
310
+ "id": "global::Promise"
307
311
  }
308
312
  },
309
313
  "return": "Promise<void>"
@@ -319,7 +323,8 @@ export class GovWizzardItem {
319
323
  "parameters": [],
320
324
  "references": {
321
325
  "Promise": {
322
- "location": "global"
326
+ "location": "global",
327
+ "id": "global::Promise"
323
328
  }
324
329
  },
325
330
  "return": "Promise<void>"
@@ -335,7 +340,8 @@ export class GovWizzardItem {
335
340
  "parameters": [],
336
341
  "references": {
337
342
  "Promise": {
338
- "location": "global"
343
+ "location": "global",
344
+ "id": "global::Promise"
339
345
  }
340
346
  },
341
347
  "return": "Promise<void>"
@@ -351,7 +357,8 @@ export class GovWizzardItem {
351
357
  "parameters": [],
352
358
  "references": {
353
359
  "Promise": {
354
- "location": "global"
360
+ "location": "global",
361
+ "id": "global::Promise"
355
362
  }
356
363
  },
357
364
  "return": "Promise<boolean>"
@@ -1 +1 @@
1
- {"version":3,"file":"gov-wizzard-item.js","sourceRoot":"","sources":["../../../../../../src/components/gov-wizzard/gov-wizzard-item.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AACrG,OAAO,EAAE,WAAW,EAAE,MAAM,2BAA2B,CAAA;AACvD,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAA;AAC3D,OAAO,EAAmB,cAAc,EAAsB,gBAAgB,EAAE,MAAM,aAAa,CAAA;AACnG,OAAO,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAA;AACnD,OAAO,EAAE,aAAa,EAAE,OAAO,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAA;AAGxF,OAAO,QAAQ,MAAM,wBAAwB,CAAA;AAE7C,IAAK,IAGJ;AAHD,WAAK,IAAI;EACR,mBAAW,CAAA;EACX,yBAAiB,CAAA;AAClB,CAAC,EAHI,IAAI,KAAJ,IAAI,QAGR;AAMD,MAAM,OAAO,cAAc;EAK1B;mBAUgD,SAAS;gBAIf,GAAG;;uBAQL,KAAK;;;oBAYR,KAAK;sBAIsB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B,CAAC;EAED;;KAEG;EAEI,KAAK,CAAC,MAAM;IAClB,IAAI,CAAC,UAAU,GAAG,CAAC,IAAI,CAAC,UAAU,CAAA;IAClC,IAAI,CAAC,WAAW,EAAE,CAAA;EACnB,CAAC;EAED;;KAEG;EAEI,KAAK,CAAC,YAAY;IACxB,OAAO,IAAI,CAAC,UAAU,CAAA;EACvB,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACD","sourcesContent":["import { Component, Element, Event, EventEmitter, h, Host, Method, Prop, Watch } from \"@stencil/core\"\nimport { govErrorLog } from \"../../helpers/Log/gov.log\"\nimport { validateProp } from \"../../helpers/Validate/props\"\nimport { WizardSizesType, WizardVariants, WizardVariantsType, WizzardItemClass } from \"./constants\"\nimport { createID } from \"../../utils/string.utils\"\nimport { booleanString, govHost, toBoolAttrIfDefined } from \"../../helpers/Dom/template\"\nimport { GovHost } from \"../../helpers/Dom/template.types\"\nimport { WizzardItemEvent } from \"./gov-wizzard-item.types\"\nimport Fragment from \"../../helpers/Fragment\"\n\nenum Tags {\n\tDIV = \"div\",\n\tBUTTON = \"button\",\n}\n\n@Component({\n\ttag: \"gov-wizzard-item\",\n\tstyleUrl: \"gov-wizzard-item.scss\",\n})\nexport class GovWizzardItem {\n\tprivate h: GovHost\n\tprivate readonly triggerId: string\n\tprivate readonly contentId: string\n\n\tconstructor() {\n\t\tthis.h = govHost(this.host)\n\t\tthis.triggerId = createID(\"GovWizzardItem\")\n\t\tthis.contentId = createID(\"GovWizzardContent\")\n\t}\n\n\t@Element() readonly host: HTMLGovWizzardItemElement\n\t/**\n\t * Style variation of the button.\n\t */\n\t@Prop() readonly variant?: WizardVariantsType = \"primary\"\n\t/**\n\t * Size of wizzard\n\t */\n\t@Prop() readonly size?: WizardSizesType = \"m\"\n\t/**\n\t * Custom wizzard item identifier. Otherwise, it will be generated\n\t */\n\t@Prop() readonly identifier: string\n\t/**\n\t * Defines weather the wizzard item can be collapsible\n\t */\n\t@Prop() readonly collapsible: boolean = false\n\t/**\n\t * Item annotation of the wizzard\n\t */\n\t@Prop() readonly annotation: string\n\t/**\n\t * Item label of the wizzard\n\t */\n\t@Prop() readonly label: string\n\t/**\n\t * Makes the wizzard component disabled.\n\t */\n\t@Prop() readonly disabled: boolean = false\n\t/**\n\t * Defines whether the accordion is open or closed by default\n\t */\n\t@Prop({ attribute: \"is-expanded\", mutable: true }) isExpanded = false\n\t/**\n\t * Used to change the HTML tag in the accordion trigger for correct semantic structure\n\t */\n\t@Prop({ attribute: \"label-tag\" }) readonly labelTag: string = \"h3\"\n\t/**\n\t * Called when the accordion state changes\n\t */\n\t@Event({ eventName: \"gov-change\" }) govChange: EventEmitter<WizzardItemEvent>\n\n\t@Watch(\"label\")\n\tprivate validateLabel(newValue: string): void {\n\t\tif (!newValue) {\n\t\t\tgovErrorLog(`[${WizzardItemClass.root}]: Parameter label is required.`)\n\t\t}\n\t}\n\n\t@Watch(\"labelTag\")\n\tprivate validateTriggerTag(newValue: string): void {\n\t\tconst validTags = [\"h1\", \"h2\", \"h3\", \"h4\", \"h5\", \"h6\", \"span\"]\n\t\tif (newValue) {\n\t\t\tif (!validTags.includes(newValue)) {\n\t\t\t\tgovErrorLog(`[${WizzardItemClass.root}]: Tag ${newValue} is not allowed.`)\n\t\t\t}\n\t\t}\n\t}\n\n\t@Watch(\"variant\")\n\tprivate validateVariant(newValue: string): void {\n\t\tvalidateProp(WizardVariants, newValue, WizzardItemClass.root)\n\t}\n\n\tprivate emmitChange(): void {\n\t\tthis.govChange.emit({ expanded: this.isExpanded, component: WizzardItemClass.root })\n\t}\n\n\tcomponentWillLoad(): void {\n\t\tthis.validateLabel(this.label)\n\t\tthis.validateVariant(this.variant)\n\t\tthis.validateTriggerTag(this.labelTag)\n\t}\n\n\trender() {\n\t\tconst triggerId = this.identifier || this.triggerId\n\t\tconst LabelTag = this.labelTag\n\t\tconst Tag = this.collapsible ? Tags.BUTTON : Tags.DIV\n\t\tconst prefixSlot = this.h.hasSlot(\"prefix\") && (<span class={WizzardItemClass.prefix}><slot name=\"prefix\" /></span>)\n\n\t\tconst label = (\n\t\t\t<LabelTag class={WizzardItemClass.title}>\n\t\t\t\t<span class={WizzardItemClass.name}>\n\t\t\t\t\t<span class={WizzardItemClass.label}>\n\t\t\t\t\t\t<span>{this.label}</span>\n\t\t\t\t\t\t{this.collapsible && <gov-icon class={WizzardItemClass.arrow} name=\"chevron-down\"></gov-icon>}\n\t\t\t\t\t</span>\n\n\t\t\t\t\t{this.annotation && <span class={WizzardItemClass.annot}>{this.annotation}</span>}\n\t\t\t\t</span>\n\t\t\t</LabelTag>\n\t\t)\n\n\t\treturn (\n\t\t\t<Host class={this.h.classes(WizzardItemClass.root)} is-expanded={this.isExpanded} variant={this.variant} size={this.size} role=\"listitem\" collapsible={this.collapsible}>\n\t\t\t\t{this.collapsible ? (\n\t\t\t\t\t<Fragment>\n\t\t\t\t\t\t{prefixSlot}\n\t\t\t\t\t\t<Tag\n\t\t\t\t\t\t\tid={triggerId}\n\t\t\t\t\t\t\tclass={WizzardItemClass.header}\n\t\t\t\t\t\t\taria-expanded={booleanString(this.isExpanded)}\n\t\t\t\t\t\t\taria-controls={this.contentId}\n\t\t\t\t\t\t\tdisabled={this.disabled}\n\t\t\t\t\t\t\taria-disabled={toBoolAttrIfDefined(this.disabled)}\n\t\t\t\t\t\t\tonClick={(e) => {\n\t\t\t\t\t\t\t\te.preventDefault()\n\t\t\t\t\t\t\t\te.stopPropagation()\n\t\t\t\t\t\t\t\tthis.collapsible ? this.toggle() : false\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{label}\n\t\t\t\t\t\t</Tag>\n\t\t\t\t\t</Fragment>\n\t\t\t\t) : (\n\t\t\t\t\t<Fragment>\n\t\t\t\t\t\t{prefixSlot}\n\t\t\t\t\t\t<div class={WizzardItemClass.header}>{label}</div>\n\t\t\t\t\t</Fragment>\n\t\t\t\t)}\n\t\t\t\t{this.collapsible ? (\n\t\t\t\t\t<div\n\t\t\t\t\t\tclass={WizzardItemClass.content}\n\t\t\t\t\t\tid={this.contentId}\n\t\t\t\t\t\taria-hidden={booleanString(!this.isExpanded)}\n\t\t\t\t\t\thidden={!this.isExpanded}\n\t\t\t\t\t\taria-labelledby={triggerId}\n\t\t\t\t\t>\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</div>\n\t\t\t\t) : (\n\t\t\t\t\t<div class={WizzardItemClass.content} aria-hidden={booleanString(!this.isExpanded)} hidden={!this.isExpanded}>\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</div>\n\t\t\t\t)}\n\t\t\t</Host>\n\t\t)\n\t}\n\n\t/**\n\t * Opening the Wizzard\n\t */\n\t@Method()\n\tasync open(): Promise<void> {\n\t\tthis.isExpanded = true\n\t\tthis.emmitChange()\n\t}\n\n\t/**\n\t * Closing the Wizzard\n\t */\n\t@Method()\n\tpublic async close(): Promise<void> {\n\t\tthis.isExpanded = false\n\t\tthis.emmitChange()\n\t}\n\n\t/**\n\t * Wizzard switch\n\t */\n\t@Method()\n\tpublic async toggle(): Promise<void> {\n\t\tthis.isExpanded = !this.isExpanded\n\t\tthis.emmitChange()\n\t}\n\n\t/**\n\t * Returns the current state of the component\n\t */\n\t@Method()\n\tpublic async currentState(): Promise<boolean> {\n\t\treturn this.isExpanded\n\t}\n}\n"]}
1
+ {"version":3,"file":"gov-wizzard-item.js","sourceRoot":"","sources":["../../../../../../src/components/gov-wizzard/gov-wizzard-item.tsx"],"names":[],"mappings":"AAAA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;;;;;;;;;;;;;;;;;;;;;;CACD","sourcesContent":["import { Component, Element, Event, EventEmitter, h, Host, Method, Prop, Watch } from \"@stencil/core\"\nimport { govErrorLog } from \"../../helpers/Log/gov.log\"\nimport { validateProp } from \"../../helpers/Validate/props\"\nimport { WizardSizesType, WizardVariants, WizardVariantsType, WizzardItemClass } from \"./constants\"\nimport { createID } from \"../../utils/string.utils\"\nimport { booleanString, govHost, toBoolAttrIfDefined } from \"../../helpers/Dom/template\"\nimport { GovHost } from \"../../helpers/Dom/template.types\"\nimport { WizzardItemEvent } from \"./gov-wizzard-item.types\"\nimport Fragment from \"../../helpers/Fragment\"\n\nenum Tags {\n\tDIV = \"div\",\n\tBUTTON = \"button\",\n}\n\n@Component({\n\ttag: \"gov-wizzard-item\",\n\tstyleUrl: \"gov-wizzard-item.scss\",\n})\nexport class GovWizzardItem {\n\tprivate h: GovHost\n\tprivate readonly triggerId: string\n\tprivate readonly contentId: string\n\n\tconstructor() {\n\t\tthis.h = govHost(this.host)\n\t\tthis.triggerId = createID(\"GovWizzardItem\")\n\t\tthis.contentId = createID(\"GovWizzardContent\")\n\t}\n\n\t@Element() readonly host: HTMLGovWizzardItemElement\n\t/**\n\t * Style variation of the button.\n\t */\n\t@Prop() readonly variant?: WizardVariantsType = \"primary\"\n\t/**\n\t * Size of wizzard\n\t */\n\t@Prop() readonly size?: WizardSizesType = \"m\"\n\t/**\n\t * Custom wizzard item identifier. Otherwise, it will be generated\n\t */\n\t@Prop() readonly identifier: string\n\t/**\n\t * Defines weather the wizzard item can be collapsible\n\t */\n\t@Prop() readonly collapsible: boolean = false\n\t/**\n\t * Item annotation of the wizzard\n\t */\n\t@Prop() readonly annotation: string\n\t/**\n\t * Item label of the wizzard\n\t */\n\t@Prop() readonly label: string\n\t/**\n\t * Makes the wizzard component disabled.\n\t */\n\t@Prop() readonly disabled: boolean = false\n\t/**\n\t * Defines whether the accordion is open or closed by default\n\t */\n\t@Prop({ attribute: \"is-expanded\", mutable: true }) isExpanded = false\n\t/**\n\t * Used to change the HTML tag in the accordion trigger for correct semantic structure\n\t */\n\t@Prop({ attribute: \"label-tag\" }) readonly labelTag: string = \"h3\"\n\t/**\n\t * Called when the accordion state changes\n\t */\n\t@Event({ eventName: \"gov-change\" }) govChange: EventEmitter<WizzardItemEvent>\n\n\t@Watch(\"label\")\n\tprivate validateLabel(newValue: string): void {\n\t\tif (!newValue) {\n\t\t\tgovErrorLog(`[${WizzardItemClass.root}]: Parameter label is required.`)\n\t\t}\n\t}\n\n\t@Watch(\"labelTag\")\n\tprivate validateTriggerTag(newValue: string): void {\n\t\tconst validTags = [\"h1\", \"h2\", \"h3\", \"h4\", \"h5\", \"h6\", \"span\"]\n\t\tif (newValue) {\n\t\t\tif (!validTags.includes(newValue)) {\n\t\t\t\tgovErrorLog(`[${WizzardItemClass.root}]: Tag ${newValue} is not allowed.`)\n\t\t\t}\n\t\t}\n\t}\n\n\t@Watch(\"variant\")\n\tprivate validateVariant(newValue: string): void {\n\t\tvalidateProp(WizardVariants, newValue, WizzardItemClass.root)\n\t}\n\n\tprivate emmitChange(): void {\n\t\tthis.govChange.emit({ expanded: this.isExpanded, component: WizzardItemClass.root })\n\t}\n\n\tcomponentWillLoad(): void {\n\t\tthis.validateLabel(this.label)\n\t\tthis.validateVariant(this.variant)\n\t\tthis.validateTriggerTag(this.labelTag)\n\t}\n\n\trender() {\n\t\tconst triggerId = this.identifier || this.triggerId\n\t\tconst LabelTag = this.labelTag\n\t\tconst Tag = this.collapsible ? Tags.BUTTON : Tags.DIV\n\t\tconst prefixSlot = this.h.hasSlot(\"prefix\") && (<span class={WizzardItemClass.prefix}><slot name=\"prefix\" /></span>)\n\n\t\tconst label = (\n\t\t\t<LabelTag class={WizzardItemClass.title}>\n\t\t\t\t<span class={WizzardItemClass.name}>\n\t\t\t\t\t<span class={WizzardItemClass.label}>\n\t\t\t\t\t\t<span>{this.label}</span>\n\t\t\t\t\t\t{this.collapsible && <gov-icon class={WizzardItemClass.arrow} name=\"chevron-down\"></gov-icon>}\n\t\t\t\t\t</span>\n\n\t\t\t\t\t{this.annotation && <span class={WizzardItemClass.annot}>{this.annotation}</span>}\n\t\t\t\t</span>\n\t\t\t</LabelTag>\n\t\t)\n\n\t\treturn (\n\t\t\t<Host class={this.h.classes(WizzardItemClass.root)} is-expanded={this.isExpanded} variant={this.variant} size={this.size} role=\"listitem\" collapsible={this.collapsible}>\n\t\t\t\t{this.collapsible ? (\n\t\t\t\t\t<Fragment>\n\t\t\t\t\t\t{prefixSlot}\n\t\t\t\t\t\t<Tag\n\t\t\t\t\t\t\tid={triggerId}\n\t\t\t\t\t\t\tclass={WizzardItemClass.header}\n\t\t\t\t\t\t\taria-expanded={booleanString(this.isExpanded)}\n\t\t\t\t\t\t\taria-controls={this.contentId}\n\t\t\t\t\t\t\tdisabled={this.disabled}\n\t\t\t\t\t\t\taria-disabled={toBoolAttrIfDefined(this.disabled)}\n\t\t\t\t\t\t\tonClick={(e) => {\n\t\t\t\t\t\t\t\te.preventDefault()\n\t\t\t\t\t\t\t\te.stopPropagation()\n\t\t\t\t\t\t\t\tthis.collapsible ? this.toggle() : false\n\t\t\t\t\t\t\t}}\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t{label}\n\t\t\t\t\t\t</Tag>\n\t\t\t\t\t</Fragment>\n\t\t\t\t) : (\n\t\t\t\t\t<Fragment>\n\t\t\t\t\t\t{prefixSlot}\n\t\t\t\t\t\t<div class={WizzardItemClass.header}>{label}</div>\n\t\t\t\t\t</Fragment>\n\t\t\t\t)}\n\t\t\t\t{this.collapsible ? (\n\t\t\t\t\t<div\n\t\t\t\t\t\tclass={WizzardItemClass.content}\n\t\t\t\t\t\tid={this.contentId}\n\t\t\t\t\t\taria-hidden={booleanString(!this.isExpanded)}\n\t\t\t\t\t\thidden={!this.isExpanded}\n\t\t\t\t\t\taria-labelledby={triggerId}\n\t\t\t\t\t>\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</div>\n\t\t\t\t) : (\n\t\t\t\t\t<div class={WizzardItemClass.content} aria-hidden={booleanString(!this.isExpanded)} hidden={!this.isExpanded}>\n\t\t\t\t\t\t<slot />\n\t\t\t\t\t</div>\n\t\t\t\t)}\n\t\t\t</Host>\n\t\t)\n\t}\n\n\t/**\n\t * Opening the Wizzard\n\t */\n\t@Method()\n\tasync open(): Promise<void> {\n\t\tthis.isExpanded = true\n\t\tthis.emmitChange()\n\t}\n\n\t/**\n\t * Closing the Wizzard\n\t */\n\t@Method()\n\tpublic async close(): Promise<void> {\n\t\tthis.isExpanded = false\n\t\tthis.emmitChange()\n\t}\n\n\t/**\n\t * Wizzard switch\n\t */\n\t@Method()\n\tpublic async toggle(): Promise<void> {\n\t\tthis.isExpanded = !this.isExpanded\n\t\tthis.emmitChange()\n\t}\n\n\t/**\n\t * Returns the current state of the component\n\t */\n\t@Method()\n\tpublic async currentState(): Promise<boolean> {\n\t\treturn this.isExpanded\n\t}\n}\n"]}
@@ -66,7 +66,8 @@ export class GovWizzard {
66
66
  "references": {
67
67
  "WizardSizesType": {
68
68
  "location": "import",
69
- "path": "./constants"
69
+ "path": "./constants",
70
+ "id": "../../../packages/core/src/components/gov-wizzard/constants.ts::WizardSizesType"
70
71
  }
71
72
  }
72
73
  },
@@ -133,7 +134,8 @@ export class GovWizzard {
133
134
  "references": {
134
135
  "GovWizzardItemChangeEvent": {
135
136
  "location": "import",
136
- "path": "./gov-wizzard-item.d"
137
+ "path": "./gov-wizzard-item.d",
138
+ "id": "../../../packages/core/src/components/gov-wizzard/gov-wizzard-item.d.tsx::GovWizzardItemChangeEvent"
137
139
  }
138
140
  }
139
141
  }
@@ -147,7 +149,8 @@ export class GovWizzard {
147
149
  "parameters": [],
148
150
  "references": {
149
151
  "Promise": {
150
- "location": "global"
152
+ "location": "global",
153
+ "id": "global::Promise"
151
154
  }
152
155
  },
153
156
  "return": "Promise<void>"
@@ -1 +1 @@
1
- {"version":3,"file":"gov-wizzard.js","sourceRoot":"","sources":["../../../../../../src/components/gov-w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B;EACF,CAAC;EAED,MAAM;IACL,OAAO,CACN,EAAC,IAAI,IAAC,KAAK,EAAE,IAAI,CAAC,CAAC,CAAC,OAAO,CAAC,YAAY,CAAC,IAAI,CAAC,EAAE,IAAI,EAAC,MAAM,EAAC,IAAI,EAAE,IAAI,CAAC,IAAI;MAC1E,eAAQ,CACF,CACP,CAAA;EACF,CAAC;EAED;;KAEG;EAEI,KAAK,CAAC,YAAY;IACxB,iBAAiB,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,cAAc,EAAE,YAAY,CAAC,IAAI,CAAC,CAAA;EAC1E,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACD","sourcesContent":["import { Component, Element, Event, EventEmitter, h, Host, Method, Prop, Watch } from \"@stencil/core\"\nimport { validateProp } from \"../../helpers/Validate/props\"\nimport { WizardSizes, WizardSizesType, WizzardClass, WizzardItemClass } from \"./constants\"\nimport { GovWizzardItemChangeEvent } from \"./gov-wizzard-item.d\"\nimport { govHost } from \"../../helpers/Dom/template\"\nimport { GovHost } from \"../../helpers/Dom/template.types\"\nimport { validateWcagLabel } from \"../../helpers/Validate/wcag\"\nimport { canValidateWcagOnRender } from \"../../helpers/Dom/win\"\nimport { delay } from \"../../utils/utils\"\n\n@Component({\n\ttag: \"gov-wizzard\",\n\tstyleUrl: \"gov-wizzard.scss\",\n})\nexport class GovWizzard {\n\tprivate h: GovHost\n\n\t@Element() readonly host: HTMLGovWizzardElement\n\n\tconstructor() {\n\t\tthis.h = govHost(this.host)\n\t}\n\n\t/**\n\t * Size of wizzard\n\t */\n\t@Prop() readonly size?: WizardSizesType = \"m\"\n\t/**\n\t * Adds accessible label for the wizzard that is only shown for screen readers.\n\t */\n\t@Prop({ attribute: \"wcag-label\" }) readonly wcagLabel: string\n\t/**\n\t * String of id's that indicate alternative labels elements\n\t */\n\t@Prop({ attribute: \"wcag-labelled-by\" }) readonly wcagLabelledBy: string\n\t/**\n\t * Called when the wizzard children state changes\n\t */\n\t@Event({ eventName: \"gov-change\" }) govChange: EventEmitter<GovWizzardItemChangeEvent>\n\n\t@Watch(\"size\")\n\tprivate validateSize(newValue: string): void {\n\t\tvalidateProp(WizardSizes, newValue, WizzardClass.root)\n\t}\n\n\tcomponentWillLoad(): void {\n\t\tthis.validateSize(this.size)\n\t}\n\n\tcomponentDidLoad() {\n\t\tthis.host.querySelectorAll(WizzardItemClass.root).forEach((child: HTMLGovWizzardItemElement) => {\n\t\t\tchild.setAttribute(\"size\", this.size)\n\t\t\t/*\n\t\t\tchild.addEventListener('gov-change', (e: GovWizzardItemCustomEvent<GovWizzardItemChangeEvent>) => {\n\t\t\t\te.stopPropagation()\n\t\t\t\tthis.govChange.emit(e.detail)\n\t\t\t})\n\t\t\t*/\n\t\t})\n\t}\n\n\tasync componentDidRender() {\n\t\tif (canValidateWcagOnRender()) {\n\t\t\tawait delay(500)\n\t\t\tawait this.validateWcag()\n\t\t}\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<Host class={this.h.classes(WizzardClass.root)} role=\"list\" size={this.size}>\n\t\t\t\t<slot />\n\t\t\t</Host>\n\t\t)\n\t}\n\n\t/**\n\t * Validate the WCAG attributes of the component\n\t */\n\t@Method()\n\tpublic async validateWcag(): Promise<void> {\n\t\tvalidateWcagLabel(this.wcagLabel, this.wcagLabelledBy, WizzardClass.root)\n\t}\n}\n"]}
1
+ {"version":3,"file":"gov-wizzard.js","sourceRoot":"","sources":["../../../../../../src/components/gov-wizzard/gov-wizzard.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,OAAO,EAAE,KAAK,EAAgB,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AACrG,OAAO,EAAE,YAAY,EAAE,MAAM,8BAA8B,CAAA;AAC3D,O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AAC;EAED;;KAEG;EAEI,KAAK,CAAC,YAAY;IACxB,iBAAiB,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,cAAc,EAAE,YAAY,CAAC,IAAI,CAAC,CAAA;EAC1E,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CACD","sourcesContent":["import { Component, Element, Event, EventEmitter, h, Host, Method, Prop, Watch } from \"@stencil/core\"\nimport { validateProp } from \"../../helpers/Validate/props\"\nimport { WizardSizes, WizardSizesType, WizzardClass, WizzardItemClass } from \"./constants\"\nimport { GovWizzardItemChangeEvent } from \"./gov-wizzard-item.d\"\nimport { govHost } from \"../../helpers/Dom/template\"\nimport { GovHost } from \"../../helpers/Dom/template.types\"\nimport { validateWcagLabel } from \"../../helpers/Validate/wcag\"\nimport { canValidateWcagOnRender } from \"../../helpers/Dom/win\"\nimport { delay } from \"../../utils/utils\"\n\n@Component({\n\ttag: \"gov-wizzard\",\n\tstyleUrl: \"gov-wizzard.scss\",\n})\nexport class GovWizzard {\n\tprivate h: GovHost\n\n\t@Element() readonly host: HTMLGovWizzardElement\n\n\tconstructor() {\n\t\tthis.h = govHost(this.host)\n\t}\n\n\t/**\n\t * Size of wizzard\n\t */\n\t@Prop() readonly size?: WizardSizesType = \"m\"\n\t/**\n\t * Adds accessible label for the wizzard that is only shown for screen readers.\n\t */\n\t@Prop({ attribute: \"wcag-label\" }) readonly wcagLabel: string\n\t/**\n\t * String of id's that indicate alternative labels elements\n\t */\n\t@Prop({ attribute: \"wcag-labelled-by\" }) readonly wcagLabelledBy: string\n\t/**\n\t * Called when the wizzard children state changes\n\t */\n\t@Event({ eventName: \"gov-change\" }) govChange: EventEmitter<GovWizzardItemChangeEvent>\n\n\t@Watch(\"size\")\n\tprivate validateSize(newValue: string): void {\n\t\tvalidateProp(WizardSizes, newValue, WizzardClass.root)\n\t}\n\n\tcomponentWillLoad(): void {\n\t\tthis.validateSize(this.size)\n\t}\n\n\tcomponentDidLoad() {\n\t\tthis.host.querySelectorAll(WizzardItemClass.root).forEach((child: HTMLGovWizzardItemElement) => {\n\t\t\tchild.setAttribute(\"size\", this.size)\n\t\t\t/*\n\t\t\tchild.addEventListener('gov-change', (e: GovWizzardItemCustomEvent<GovWizzardItemChangeEvent>) => {\n\t\t\t\te.stopPropagation()\n\t\t\t\tthis.govChange.emit(e.detail)\n\t\t\t})\n\t\t\t*/\n\t\t})\n\t}\n\n\tasync componentDidRender() {\n\t\tif (canValidateWcagOnRender()) {\n\t\t\tawait delay(500)\n\t\t\tawait this.validateWcag()\n\t\t}\n\t}\n\n\trender() {\n\t\treturn (\n\t\t\t<Host class={this.h.classes(WizzardClass.root)} role=\"list\" size={this.size}>\n\t\t\t\t<slot />\n\t\t\t</Host>\n\t\t)\n\t}\n\n\t/**\n\t * Validate the WCAG attributes of the component\n\t */\n\t@Method()\n\tpublic async validateWcag(): Promise<void> {\n\t\tvalidateWcagLabel(this.wcagLabel, this.wcagLabelledBy, WizzardClass.root)\n\t}\n}\n"]}
@@ -1,12 +1,12 @@
1
- import { FormControlClass } from '../../components/gov-form/control/constants';
2
- import { FormInputClass } from '../../components/gov-form/input/constants';
3
- import { FormSelectClass } from '../../components/gov-form/select/constants';
4
- import { FormMultiSelectClass } from '../../components/gov-form/multiselect/constants';
5
- import { FormSwitchClass } from '../../components/gov-form/switch/constants';
6
- import { FormCheckboxClass } from '../../components/gov-form/checkbox/constants';
7
- import { FormRadioClass } from '../../components/gov-form/radio/constants';
8
- import { FormMessageClass } from '../../components/gov-form/message/constants';
9
- import { FormAutocompleteClass } from '../../components/gov-form/autocomplete/constants';
1
+ import { FormControlClass } from "../../components/gov-form/control/constants";
2
+ import { FormInputClass } from "../../components/gov-form/input/constants";
3
+ import { FormSelectClass } from "../../components/gov-form/select/constants";
4
+ import { FormMultiSelectClass } from "../../components/gov-form/multiselect/constants";
5
+ import { FormSwitchClass } from "../../components/gov-form/switch/constants";
6
+ import { FormCheckboxClass } from "../../components/gov-form/checkbox/constants";
7
+ import { FormRadioClass } from "../../components/gov-form/radio/constants";
8
+ import { FormMessageClass } from "../../components/gov-form/message/constants";
9
+ import { FormAutocompleteClass } from "../../components/gov-form/autocomplete/constants";
10
10
  import { FormLabelClass } from "../../components/gov-form/label/constants";
11
11
  export const govForm = (govHost) => {
12
12
  return {
@@ -1,4 +1,4 @@
1
- import { property } from '../../utils/utils';
1
+ import { property } from "../../utils/utils";
2
2
  export const isWindow = typeof window !== "undefined";
3
3
  const getWindowProperty = (name) => isWindow && window && property(name, window);
4
4
  const config = () => {