@department-of-veterans-affairs/component-library 49.1.2-rc1 → 49.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (349) hide show
  1. package/dist/1214.app.bundle.js +1 -1
  2. package/dist/1365.app.bundle.js +1 -1
  3. package/dist/1450.app.bundle.js +1 -1
  4. package/dist/196.app.bundle.js +1 -1
  5. package/dist/2222.app.bundle.js +1 -1
  6. package/dist/2387.app.bundle.js +1 -1
  7. package/dist/2654.app.bundle.js +1 -1
  8. package/dist/2664.app.bundle.js +1 -1
  9. package/dist/2801.app.bundle.js +1 -1
  10. package/dist/286.app.bundle.js +1 -1
  11. package/dist/3071.app.bundle.js +1 -1
  12. package/dist/3156.app.bundle.js +1 -1
  13. package/dist/4064.app.bundle.js +1 -1
  14. package/dist/4117.app.bundle.js +1 -1
  15. package/dist/4140.app.bundle.js +1 -1
  16. package/dist/4493.app.bundle.js +1 -1
  17. package/dist/4715.app.bundle.js +1 -1
  18. package/dist/5155.app.bundle.js +1 -1
  19. package/dist/5306.app.bundle.js +1 -1
  20. package/dist/5610.app.bundle.js +1 -1
  21. package/dist/5628.app.bundle.js +1 -1
  22. package/dist/5699.app.bundle.js +1 -1
  23. package/dist/5830.app.bundle.js +1 -1
  24. package/dist/6034.app.bundle.js +1 -1
  25. package/dist/6246.app.bundle.js +1 -1
  26. package/dist/6247.app.bundle.js +1 -1
  27. package/dist/641.app.bundle.js +1 -0
  28. package/dist/6527.app.bundle.js +1 -1
  29. package/dist/712.app.bundle.js +1 -1
  30. package/dist/7367.app.bundle.js +1 -1
  31. package/dist/7531.app.bundle.js +1 -1
  32. package/dist/7663.app.bundle.js +1 -1
  33. package/dist/7821.app.bundle.js +1 -1
  34. package/dist/82.app.bundle.js +1 -1
  35. package/dist/8762.app.bundle.js +1 -1
  36. package/dist/890.app.bundle.js +1 -1
  37. package/dist/9288.app.bundle.js +1 -1
  38. package/dist/9670.app.bundle.js +1 -1
  39. package/dist/9724.app.bundle.js +1 -1
  40. package/dist/9800.app.bundle.js +1 -1
  41. package/dist/app.bundle.js +1 -1
  42. package/dist/components/index.d.ts +2 -0
  43. package/dist/components/index.js +1 -1
  44. package/dist/components/types/components.d.ts +135 -4
  45. package/dist/components/va-accordion.js +1 -1
  46. package/dist/components/va-additional-info.js +1 -1
  47. package/dist/components/va-alert-expandable.js +1 -1
  48. package/dist/components/va-alert-sign-in.js +1 -1
  49. package/dist/components/va-back-to-top.js +1 -1
  50. package/dist/components/va-banner.js +1 -1
  51. package/dist/components/va-button-icon2.js +1 -1
  52. package/dist/components/va-button2.js +1 -1
  53. package/dist/components/va-card2.js +1 -1
  54. package/dist/components/va-checkbox-group.js +1 -1
  55. package/dist/components/va-checkbox2.js +1 -1
  56. package/dist/components/va-combo-box.js +2 -2
  57. package/dist/components/va-crisis-line-modal2.js +1 -1
  58. package/dist/components/va-file-input-multiple.js +1 -1
  59. package/dist/components/va-file-input2.js +1 -1
  60. package/dist/components/va-header-minimal.js +1 -1
  61. package/dist/components/va-icon2.js +1 -1
  62. package/dist/components/va-language-toggle.js +1 -1
  63. package/dist/components/va-link-action.js +1 -1
  64. package/dist/components/va-loading-indicator.js +1 -1
  65. package/dist/components/va-memorable-date.js +1 -1
  66. package/dist/components/va-minimal-footer.js +1 -1
  67. package/dist/components/va-need-help.js +1 -1
  68. package/dist/components/va-official-gov-banner2.js +1 -1
  69. package/dist/components/va-omb-info.js +1 -1
  70. package/dist/components/va-privacy-agreement.js +1 -1
  71. package/dist/components/va-process-list-item.js +1 -1
  72. package/dist/components/va-process-list.js +1 -1
  73. package/dist/components/va-progress-bar.js +1 -1
  74. package/dist/components/va-radio-option.js +1 -1
  75. package/dist/components/va-radio.js +1 -1
  76. package/dist/components/va-search-input.js +1 -1
  77. package/dist/components/va-select2.js +1 -1
  78. package/dist/components/{va-number-input.d.ts → va-service-list-item.d.ts} +4 -4
  79. package/dist/components/va-service-list-item.js +1 -0
  80. package/dist/components/va-statement-of-truth.js +1 -1
  81. package/dist/components/va-summary-box.js +1 -1
  82. package/dist/components/va-table-inner2.js +1 -1
  83. package/dist/components/va-table-row.js +1 -1
  84. package/dist/components/va-table.js +1 -1
  85. package/dist/components/va-telephone2.js +1 -1
  86. package/dist/components/va-text-input2.js +1 -1
  87. package/dist/components/va-textarea.js +1 -1
  88. package/dist/main.css +1 -1
  89. package/dist/react-bindings/index.d.ts +1 -0
  90. package/dist/react-bindings/index.js +1 -1
  91. package/dist/react-bindings/index.js.map +1 -1
  92. package/dist/react-bindings/index.ts +1 -0
  93. package/package.json +4 -4
  94. package/dist/1042.app.bundle.js +0 -1
  95. package/dist/1059.app.bundle.js +0 -1
  96. package/dist/1185.app.bundle.js +0 -2
  97. package/dist/1185.app.bundle.js.LICENSE.txt +0 -5
  98. package/dist/1237.app.bundle.js +0 -2
  99. package/dist/1237.app.bundle.js.LICENSE.txt +0 -5
  100. package/dist/1274.app.bundle.js +0 -1
  101. package/dist/1279.app.bundle.js +0 -1
  102. package/dist/1321.app.bundle.js +0 -2
  103. package/dist/1321.app.bundle.js.LICENSE.txt +0 -5
  104. package/dist/1343.app.bundle.js +0 -1
  105. package/dist/139.app.bundle.js +0 -1
  106. package/dist/1558.app.bundle.js +0 -1
  107. package/dist/1563.app.bundle.js +0 -2
  108. package/dist/1563.app.bundle.js.LICENSE.txt +0 -5
  109. package/dist/1652.app.bundle.js +0 -1
  110. package/dist/1674.app.bundle.js +0 -2
  111. package/dist/1674.app.bundle.js.LICENSE.txt +0 -5
  112. package/dist/1680.app.bundle.js +0 -1
  113. package/dist/2010.app.bundle.js +0 -1
  114. package/dist/2025.app.bundle.js +0 -2
  115. package/dist/2025.app.bundle.js.LICENSE.txt +0 -5
  116. package/dist/2104.app.bundle.js +0 -1
  117. package/dist/2108.app.bundle.js +0 -2
  118. package/dist/2108.app.bundle.js.LICENSE.txt +0 -5
  119. package/dist/2159.app.bundle.js +0 -2
  120. package/dist/2159.app.bundle.js.LICENSE.txt +0 -5
  121. package/dist/2272.app.bundle.js +0 -1
  122. package/dist/2305.app.bundle.js +0 -2
  123. package/dist/2305.app.bundle.js.LICENSE.txt +0 -5
  124. package/dist/2342.app.bundle.js +0 -1
  125. package/dist/2465.app.bundle.js +0 -1
  126. package/dist/265.app.bundle.js +0 -1
  127. package/dist/2715.app.bundle.js +0 -1
  128. package/dist/2783.app.bundle.js +0 -2
  129. package/dist/2783.app.bundle.js.LICENSE.txt +0 -5
  130. package/dist/2843.app.bundle.js +0 -1
  131. package/dist/2963.app.bundle.js +0 -1
  132. package/dist/3002.app.bundle.js +0 -1
  133. package/dist/3270.app.bundle.js +0 -2
  134. package/dist/3270.app.bundle.js.LICENSE.txt +0 -11
  135. package/dist/3389.app.bundle.js +0 -2
  136. package/dist/3389.app.bundle.js.LICENSE.txt +0 -5
  137. package/dist/3476.app.bundle.js +0 -2
  138. package/dist/3476.app.bundle.js.LICENSE.txt +0 -5
  139. package/dist/3499.app.bundle.js +0 -1
  140. package/dist/3510.app.bundle.js +0 -1
  141. package/dist/360.app.bundle.js +0 -2
  142. package/dist/360.app.bundle.js.LICENSE.txt +0 -5
  143. package/dist/3661.app.bundle.js +0 -1
  144. package/dist/3718.app.bundle.js +0 -2
  145. package/dist/3718.app.bundle.js.LICENSE.txt +0 -5
  146. package/dist/3719.app.bundle.js +0 -1
  147. package/dist/383.app.bundle.js +0 -2
  148. package/dist/383.app.bundle.js.LICENSE.txt +0 -5
  149. package/dist/3848.app.bundle.js +0 -1
  150. package/dist/3853.app.bundle.js +0 -2
  151. package/dist/3853.app.bundle.js.LICENSE.txt +0 -5
  152. package/dist/3882.app.bundle.js +0 -2
  153. package/dist/3882.app.bundle.js.LICENSE.txt +0 -5
  154. package/dist/3977.app.bundle.js +0 -1
  155. package/dist/4104.app.bundle.js +0 -1
  156. package/dist/4114.app.bundle.js +0 -1
  157. package/dist/4181.app.bundle.js +0 -2
  158. package/dist/4181.app.bundle.js.LICENSE.txt +0 -5
  159. package/dist/4267.app.bundle.js +0 -2
  160. package/dist/4267.app.bundle.js.LICENSE.txt +0 -5
  161. package/dist/4317.app.bundle.js +0 -2
  162. package/dist/4317.app.bundle.js.LICENSE.txt +0 -5
  163. package/dist/4348.app.bundle.js +0 -1
  164. package/dist/4397.app.bundle.js +0 -2
  165. package/dist/4397.app.bundle.js.LICENSE.txt +0 -5
  166. package/dist/4437.app.bundle.js +0 -1
  167. package/dist/4726.app.bundle.js +0 -2
  168. package/dist/4726.app.bundle.js.LICENSE.txt +0 -5
  169. package/dist/4818.app.bundle.js +0 -2
  170. package/dist/4818.app.bundle.js.LICENSE.txt +0 -5
  171. package/dist/4846.app.bundle.js +0 -1
  172. package/dist/4859.app.bundle.js +0 -1
  173. package/dist/4863.app.bundle.js +0 -2
  174. package/dist/4863.app.bundle.js.LICENSE.txt +0 -5
  175. package/dist/4934.app.bundle.js +0 -1
  176. package/dist/5112.app.bundle.js +0 -2
  177. package/dist/5112.app.bundle.js.LICENSE.txt +0 -17
  178. package/dist/5154.app.bundle.js +0 -1
  179. package/dist/5194.app.bundle.js +0 -2
  180. package/dist/5194.app.bundle.js.LICENSE.txt +0 -5
  181. package/dist/5232.app.bundle.js +0 -1
  182. package/dist/5254.app.bundle.js +0 -1
  183. package/dist/5285.app.bundle.js +0 -2
  184. package/dist/5285.app.bundle.js.LICENSE.txt +0 -5
  185. package/dist/529.app.bundle.js +0 -2
  186. package/dist/529.app.bundle.js.LICENSE.txt +0 -5
  187. package/dist/5431.app.bundle.js +0 -1
  188. package/dist/5434.app.bundle.js +0 -1
  189. package/dist/5585.app.bundle.js +0 -1
  190. package/dist/5669.app.bundle.js +0 -2
  191. package/dist/5669.app.bundle.js.LICENSE.txt +0 -5
  192. package/dist/569.app.bundle.js +0 -2
  193. package/dist/569.app.bundle.js.LICENSE.txt +0 -5
  194. package/dist/5847.app.bundle.js +0 -1
  195. package/dist/5889.app.bundle.js +0 -2
  196. package/dist/5889.app.bundle.js.LICENSE.txt +0 -5
  197. package/dist/5941.app.bundle.js +0 -1
  198. package/dist/6166.app.bundle.js +0 -1
  199. package/dist/6171.app.bundle.js +0 -2
  200. package/dist/6171.app.bundle.js.LICENSE.txt +0 -5
  201. package/dist/6191.app.bundle.js +0 -2
  202. package/dist/6191.app.bundle.js.LICENSE.txt +0 -5
  203. package/dist/6205.app.bundle.js +0 -2
  204. package/dist/6205.app.bundle.js.LICENSE.txt +0 -5
  205. package/dist/6221.app.bundle.js +0 -1
  206. package/dist/6230.app.bundle.js +0 -1
  207. package/dist/6391.app.bundle.js +0 -2
  208. package/dist/6391.app.bundle.js.LICENSE.txt +0 -5
  209. package/dist/646.app.bundle.js +0 -2
  210. package/dist/646.app.bundle.js.LICENSE.txt +0 -5
  211. package/dist/6569.app.bundle.js +0 -2
  212. package/dist/6569.app.bundle.js.LICENSE.txt +0 -5
  213. package/dist/6596.app.bundle.js +0 -2
  214. package/dist/6596.app.bundle.js.LICENSE.txt +0 -5
  215. package/dist/6734.app.bundle.js +0 -1
  216. package/dist/6874.app.bundle.js +0 -1
  217. package/dist/6879.app.bundle.js +0 -1
  218. package/dist/6995.app.bundle.js +0 -2
  219. package/dist/6995.app.bundle.js.LICENSE.txt +0 -5
  220. package/dist/6998.app.bundle.js +0 -2
  221. package/dist/6998.app.bundle.js.LICENSE.txt +0 -5
  222. package/dist/7003.app.bundle.js +0 -1
  223. package/dist/7019.app.bundle.js +0 -1
  224. package/dist/7061.app.bundle.js +0 -1
  225. package/dist/7183.app.bundle.js +0 -2
  226. package/dist/7183.app.bundle.js.LICENSE.txt +0 -5
  227. package/dist/7339.app.bundle.js +0 -2
  228. package/dist/7339.app.bundle.js.LICENSE.txt +0 -5
  229. package/dist/7375.app.bundle.js +0 -1
  230. package/dist/7384.app.bundle.js +0 -2
  231. package/dist/7384.app.bundle.js.LICENSE.txt +0 -5
  232. package/dist/7422.app.bundle.js +0 -1
  233. package/dist/7454.app.bundle.js +0 -2
  234. package/dist/7454.app.bundle.js.LICENSE.txt +0 -5
  235. package/dist/7485.app.bundle.js +0 -2
  236. package/dist/7485.app.bundle.js.LICENSE.txt +0 -5
  237. package/dist/753.app.bundle.js +0 -2
  238. package/dist/753.app.bundle.js.LICENSE.txt +0 -5
  239. package/dist/7568.app.bundle.js +0 -2
  240. package/dist/7568.app.bundle.js.LICENSE.txt +0 -5
  241. package/dist/7576.app.bundle.js +0 -1
  242. package/dist/7609.app.bundle.js +0 -2
  243. package/dist/7609.app.bundle.js.LICENSE.txt +0 -5
  244. package/dist/7705.app.bundle.js +0 -2
  245. package/dist/7705.app.bundle.js.LICENSE.txt +0 -11
  246. package/dist/7760.app.bundle.js +0 -1
  247. package/dist/7785.app.bundle.js +0 -2
  248. package/dist/7785.app.bundle.js.LICENSE.txt +0 -5
  249. package/dist/783.app.bundle.js +0 -1
  250. package/dist/7906.app.bundle.js +0 -2
  251. package/dist/7906.app.bundle.js.LICENSE.txt +0 -5
  252. package/dist/8074.app.bundle.js +0 -2
  253. package/dist/8074.app.bundle.js.LICENSE.txt +0 -5
  254. package/dist/8151.app.bundle.js +0 -2
  255. package/dist/8151.app.bundle.js.LICENSE.txt +0 -5
  256. package/dist/8214.app.bundle.js +0 -1
  257. package/dist/8223.app.bundle.js +0 -1
  258. package/dist/8361.app.bundle.js +0 -2
  259. package/dist/8361.app.bundle.js.LICENSE.txt +0 -5
  260. package/dist/8429.app.bundle.js +0 -2
  261. package/dist/8429.app.bundle.js.LICENSE.txt +0 -5
  262. package/dist/8509.app.bundle.js +0 -2
  263. package/dist/8509.app.bundle.js.LICENSE.txt +0 -5
  264. package/dist/8716.app.bundle.js +0 -2
  265. package/dist/8716.app.bundle.js.LICENSE.txt +0 -5
  266. package/dist/8750.app.bundle.js +0 -2
  267. package/dist/8750.app.bundle.js.LICENSE.txt +0 -5
  268. package/dist/876.app.bundle.js +0 -1
  269. package/dist/8912.app.bundle.js +0 -1
  270. package/dist/8991.app.bundle.js +0 -2
  271. package/dist/8991.app.bundle.js.LICENSE.txt +0 -5
  272. package/dist/9101.app.bundle.js +0 -1
  273. package/dist/916.app.bundle.js +0 -1
  274. package/dist/9200.app.bundle.js +0 -2
  275. package/dist/9200.app.bundle.js.LICENSE.txt +0 -5
  276. package/dist/9262.app.bundle.js +0 -2
  277. package/dist/9262.app.bundle.js.LICENSE.txt +0 -5
  278. package/dist/9275.app.bundle.js +0 -2
  279. package/dist/9275.app.bundle.js.LICENSE.txt +0 -5
  280. package/dist/934.app.bundle.js +0 -2
  281. package/dist/934.app.bundle.js.LICENSE.txt +0 -5
  282. package/dist/9356.app.bundle.js +0 -1
  283. package/dist/9370.app.bundle.js +0 -2
  284. package/dist/9370.app.bundle.js.LICENSE.txt +0 -5
  285. package/dist/9398.app.bundle.js +0 -1
  286. package/dist/9407.app.bundle.js +0 -2
  287. package/dist/9407.app.bundle.js.LICENSE.txt +0 -5
  288. package/dist/9425.app.bundle.js +0 -1
  289. package/dist/9452.app.bundle.js +0 -1
  290. package/dist/9727.app.bundle.js +0 -2
  291. package/dist/9727.app.bundle.js.LICENSE.txt +0 -5
  292. package/dist/9893.app.bundle.js +0 -1
  293. package/dist/9903.app.bundle.js +0 -1
  294. package/dist/9970.app.bundle.js +0 -2
  295. package/dist/9970.app.bundle.js.LICENSE.txt +0 -17
  296. package/dist/assets/minus.svg +0 -2
  297. package/dist/assets/plus.svg +0 -2
  298. package/dist/components/_commonjsHelpers.js +0 -1
  299. package/dist/components/img/sprite.svg +0 -5
  300. package/dist/components/index3.js +0 -2
  301. package/dist/components/index3.js.LICENSE.txt +0 -5
  302. package/dist/components/p-0bd33282.js +0 -1
  303. package/dist/components/p-2bacc556.js +0 -2
  304. package/dist/components/p-2bacc556.js.LICENSE.txt +0 -5
  305. package/dist/components/p-3092f0da.js +0 -1
  306. package/dist/components/p-51fd3760.js +0 -1
  307. package/dist/components/p-57ec7157.js +0 -1
  308. package/dist/components/p-5adc0c0f.js +0 -1
  309. package/dist/components/p-703b9866.js +0 -1
  310. package/dist/components/p-71f3e557.js +0 -1
  311. package/dist/components/p-7bd5360a.js +0 -1
  312. package/dist/components/p-7f18a9c3.js +0 -1
  313. package/dist/components/p-8377f9f7.js +0 -1
  314. package/dist/components/p-85dad1ee.js +0 -1
  315. package/dist/components/p-ad634c1d.js +0 -1
  316. package/dist/components/p-aead3f6c.js +0 -1
  317. package/dist/components/p-b5e86daf.js +0 -1
  318. package/dist/components/p-bbd1634b.js +0 -1
  319. package/dist/components/p-c8624782.js +0 -1
  320. package/dist/components/p-c968eed9.js +0 -1
  321. package/dist/components/p-d1bb9044.js +0 -1
  322. package/dist/components/p-d2716799.js +0 -1
  323. package/dist/components/p-d2a83ae3.js +0 -1
  324. package/dist/components/p-deb595cf.js +0 -1
  325. package/dist/components/p-ecc368bc.js +0 -1
  326. package/dist/components/va-number-input.js +0 -1
  327. package/dist/react-bindings/components.d.ts +0 -259
  328. package/dist/react-bindings/components.js +0 -1
  329. package/dist/react-bindings/components.js.map +0 -1
  330. package/dist/react-bindings/components.ts +0 -685
  331. package/dist/react-bindings/react-component-lib/attachProps.d.ts +0 -16
  332. package/dist/react-bindings/react-component-lib/attachProps.js +0 -2
  333. package/dist/react-bindings/react-component-lib/attachProps.js.LICENSE.txt +0 -4
  334. package/dist/react-bindings/react-component-lib/attachProps.js.map +0 -1
  335. package/dist/react-bindings/react-component-lib/attachProps.ts +0 -125
  336. package/dist/react-bindings/react-component-lib/case.d.ts +0 -2
  337. package/dist/react-bindings/react-component-lib/case.js +0 -1
  338. package/dist/react-bindings/react-component-lib/case.js.map +0 -1
  339. package/dist/react-bindings/react-component-lib/case.ts +0 -7
  340. package/dist/react-bindings/react-component-lib/dev.d.ts +0 -2
  341. package/dist/react-bindings/react-component-lib/dev.js +0 -1
  342. package/dist/react-bindings/react-component-lib/dev.js.map +0 -1
  343. package/dist/react-bindings/react-component-lib/dev.ts +0 -14
  344. package/dist/react-bindings/react-component-lib/index.tsx +0 -50
  345. package/en.js +0 -1
  346. package/es.js +0 -1
  347. package/i18n-setup.js +0 -1
  348. package/language-detector.js +0 -1
  349. package/tl.js +0 -1
@@ -1 +1 @@
1
- import{proxyCustomElement,HTMLElement,createEvent,h,Host}from"@stencil/core/internal/client";var isChromatic=function(t){const e=t||"undefined"!=typeof window&&window;return!(!e||!e.navigator.userAgent.match(/Chromatic/)&&!e.location.href.match(/chromatic=true/))};const vaLoadingIndicatorCss=":host{display:block;font-size:1.06rem;text-align:center}.loading-indicator{display:block;height:4rem;margin-top:1rem}.loading-indicator:after{content:' ';display:inline-block;width:2.1875rem;height:2.1875rem;margin:1px;border-radius:50%;border:8px solid var(--vads-color-primary);border-color:var(--vads-color-primary) transparent var(--vads-color-primary)\n transparent;-webkit-animation:spin 1.5s linear infinite;animation:spin 1.5s linear infinite}.loading-indicator.chromatic:after{-webkit-animation:none;animation:none}.loading-indicator:focus{outline:none}@-webkit-keyframes spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}",VaLoadingIndicatorStyle0=vaLoadingIndicatorCss,VaLoadingIndicator$1=proxyCustomElement(class extends HTMLElement{constructor(){super(),this.__registerHost(),this.__attachShadow(),this.componentLibraryAnalytics=createEvent(this,"component-library-analytics",7),this.loadingStartTime=null,this.observer=null,this.message=void 0,this.label="Loading",this.setFocus=!1,this.enableAnalytics=!1}componentDidLoad(){this.setFocus&&this.spinner&&this.spinner.focus(),this.loadingStartTime=Date.now();const t=this.el.parentNode;this.observer=new MutationObserver((e=>{for(const i of e)if("childList"===i.type){const e=Array.from(i.removedNodes.values()).filter((t=>{var e;return"va-loading-indicator"===(null===(e=null==t?void 0:t.tagName)||void 0===e?void 0:e.toLowerCase())})).length>0;if(this.enableAnalytics&&e){const e=new CustomEvent("component-library-analytics",{bubbles:!0,composed:!0,detail:{componentName:"va-loading-indicator",action:"displayed",details:{displayTime:Date.now()-this.loadingStartTime,message:this.message}}});t.dispatchEvent(e)}}})),this.observer.observe(t,{childList:!0})}render(){const{message:t,label:e}=this;let i="loading-indicator";return isChromatic()&&(i+=" chromatic"),h(Host,{key:"7211c80f7ef96413b2212342bffc0dd91180fbf0","aria-live":"polite"},h("div",{key:"64c3dfc29f24874f7521155098b3a78edb045c83",ref:t=>this.spinner=t,class:i,role:"progressbar","aria-label":e,"aria-valuetext":t,tabindex:"-1"}),t)}get el(){return this}static get style(){return VaLoadingIndicatorStyle0}},[1,"va-loading-indicator",{message:[1],label:[1],setFocus:[4,"set-focus"],enableAnalytics:[4,"enable-analytics"]}]);function defineCustomElement$1(){"undefined"!=typeof customElements&&["va-loading-indicator"].forEach((t=>{"va-loading-indicator"===t&&(customElements.get(t)||customElements.define(t,VaLoadingIndicator$1))}))}const VaLoadingIndicator=VaLoadingIndicator$1,defineCustomElement=defineCustomElement$1;export{VaLoadingIndicator,defineCustomElement};
1
+ import{proxyCustomElement,HTMLElement,createEvent,h,Host}from"@stencil/core/internal/client";var isChromatic=function(t){const e=t||"undefined"!=typeof window&&window;return!(!e||!e.navigator.userAgent.match(/Chromatic/)&&!e.location.href.match(/chromatic=true/))};const vaLoadingIndicatorCss=":host{display:block;font-size:1.06rem;text-align:center}.loading-indicator{display:block;height:4rem;margin-top:1rem}.loading-indicator:after{content:' ';display:inline-block;width:2.1875rem;height:2.1875rem;margin:1px;border-radius:50%;border:8px solid var(--vads-color-primary);border-color:var(--vads-color-primary) transparent var(--vads-color-primary)\n transparent;-webkit-animation:spin 1.5s linear infinite;animation:spin 1.5s linear infinite}.loading-indicator.chromatic:after{-webkit-animation:none;animation:none}.loading-indicator:focus{outline:none}@-webkit-keyframes spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}@keyframes spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(360deg);transform:rotate(360deg)}}",VaLoadingIndicatorStyle0=vaLoadingIndicatorCss,VaLoadingIndicator$1=proxyCustomElement(class extends HTMLElement{constructor(){super(),this.__registerHost(),this.__attachShadow(),this.componentLibraryAnalytics=createEvent(this,"component-library-analytics",7),this.loadingStartTime=null,this.observer=null,this.message=void 0,this.label="Loading",this.setFocus=!1,this.enableAnalytics=!1}componentDidLoad(){this.setFocus&&this.spinner&&this.spinner.focus(),this.loadingStartTime=Date.now();const t=this.el.parentNode;this.observer=new MutationObserver((e=>{for(const a of e)if("childList"===a.type){const e=Array.from(a.removedNodes.values()).filter((t=>{var e;return"va-loading-indicator"===(null===(e=null==t?void 0:t.tagName)||void 0===e?void 0:e.toLowerCase())})).length>0;if(this.enableAnalytics&&e){const e=new CustomEvent("component-library-analytics",{bubbles:!0,composed:!0,detail:{componentName:"va-loading-indicator",action:"displayed",details:{displayTime:Date.now()-this.loadingStartTime,message:this.message}}});t.dispatchEvent(e)}}})),this.observer.observe(t,{childList:!0})}render(){const{message:t,label:e}=this;let a="loading-indicator";return isChromatic()&&(a+=" chromatic"),h(Host,{key:"c8b51511f38b3dae97f1dfc123002ef840c48f9f","aria-live":"polite"},h("div",{key:"78d3cba75e54258a2481c0bd781002a7aad6374d",ref:t=>this.spinner=t,class:a,role:"progressbar","aria-label":e,"aria-valuetext":t,tabindex:"-1"}),t)}get el(){return this}static get style(){return VaLoadingIndicatorStyle0}},[1,"va-loading-indicator",{message:[1],label:[1],setFocus:[4,"set-focus"],enableAnalytics:[4,"enable-analytics"]}]);function defineCustomElement$1(){"undefined"!=typeof customElements&&["va-loading-indicator"].forEach((t=>{"va-loading-indicator"===t&&(customElements.get(t)||customElements.define(t,VaLoadingIndicator$1))}))}const VaLoadingIndicator=VaLoadingIndicator$1,defineCustomElement=defineCustomElement$1;export{VaLoadingIndicator,defineCustomElement};
@@ -1 +1 @@
1
- import{Build,proxyCustomElement,HTMLElement,createEvent,forceUpdate,h,Fragment,Host}from"@stencil/core/internal/client";import{v as validate,z as zeroPadStart,g as getErrorParameters,m as months}from"./date-utils.js";import{a as getHeaderLevel}from"./utils.js";import"./i18n-setup.js";import"./contacts.js";import{c as classnames}from"./index2.js";import{d as defineCustomElement$4}from"./va-icon2.js";import{d as defineCustomElement$3}from"./va-select2.js";import{d as defineCustomElement$2}from"./va-text-input2.js";import{i as instance}from"./i18next.js";const vaMemorableDateCss='button:not([disabled]):focus,select:not([disabled]):focus,a:not([disabled]):focus,h1:focus,input:not([disabled]):focus,textarea:not([disabled]):focus,#form-question [role=\'option\']:focus,*[tabindex]:focus{outline:2px solid var(--vads-color-action-focus-on-light);outline-offset:2px}#error-message{margin-bottom:0.75rem}#error-message,#input-error-message{color:var(--vads-color-secondary-dark);display:block;font-weight:700;font-size:1.06rem}:host([error]:not([error=\'\'])){border-left:0.3rem solid var(--vads-color-secondary-dark);padding-left:1.25rem;position:relative}@media screen and (min-width: 1008px){:host([error]:not([error=\'\'])){margin-left:-1.4375rem;}}h1{margin-top:0}h1,h2,h3,h4,h5,h6{margin-bottom:0;margin-top:0;clear:both}*+h1,*+h2,*+h3,*+h4,*+h5,*+h6{margin-top:1.5em}h1+*,h2+*,h3+*,h4+*,h5+*,h6+*{margin-top:1em}h1{font-family:Merriweather Web, Georgia, Cambria, Times New Roman, Times, serif;font-size:2.44rem;line-height:1.2;font-weight:700}h2{font-family:Merriweather Web, Georgia, Cambria, Times New Roman, Times, serif;font-size:1.95rem;line-height:1.2;font-weight:700}h3{font-family:Merriweather Web, Georgia, Cambria, Times New Roman, Times, serif;font-size:1.34rem;line-height:1.2;font-weight:700}h4{font-family:Merriweather Web, Georgia, Cambria, Times New Roman, Times, serif;font-size:0.98rem;line-height:1.2;font-weight:700}h5{font-family:Merriweather Web, Georgia, Cambria, Times New Roman, Times, serif;font-size:0.91rem;line-height:1.2;font-weight:700}h6{font-family:Source Sans Pro Web, Helvetica Neue, Helvetica, Roboto, Arial, sans-serif;font-size:0.87rem;line-height:1.1;font-weight:normal;letter-spacing:0.025em;text-transform:uppercase}h1,h2,h3,h4,h5{font-family:Bitter, Georgia, Cambria, "Times New Roman", Times, serif;font-weight:700}h6{font-family:"Source Sans Pro Web", "Helvetica Neue", Helvetica, Roboto, Arial, sans-serif;font-weight:700}h1{margin-top:0;font-size:2.5rem}h2{font-size:1.875rem}h3{font-size:1.25rem}h4{font-size:1.0625rem}h5{font-size:0.9375rem}h6{font-size:0.9375rem}@media (max-width: 481px){h1{font-size:30px}h2{font-size:24px}}h6{margin:0.5em 0 0;text-transform:none;font-weight:700}@media (max-width: 481px){h1{font-size:30px}h2{font-size:24px}}h6{margin:0.5em 0 0;text-transform:none;font-weight:700}:host legend :is(h1,h2,h3,h4,h5,h6),:host label :is(h1,h2,h3,h4,h5,h6){display:inline;margin:0px}:host legend :is(h1,h2,h3,h4,h5),:host label :is(h1,h2,h3,h4,h5){font-family:var(--font-serif)}:host h1+*,:host h2+*,:host h3+*,:host h4+*,:host h5+*,:host h6+*{margin-top:unset}:host #form-question{margin-bottom:1rem}.usa-hint,.usa-fieldset{font-family:Source Sans Pro Web, "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans;font-size:1.06rem;line-height:1.3}.usa-sr-only{position:absolute;left:-999em;right:auto}.usa-form{font-family:Source Sans Pro Web, "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans;font-size:1.06rem;line-height:1.3}@media all and (min-width: 30em){.usa-form{max-width:20rem}}.usa-form abbr[title=required]{text-decoration:none}.usa-form .usa-input,.usa-form .usa-range,.usa-form .usa-select,.usa-form .usa-textarea{max-width:none}.usa-form .usa-input--2xs,.usa-form .usa-input-group--2xs{max-width:5ex}.usa-form .usa-input--xs,.usa-form .usa-input-group--xs{max-width:9ex}.usa-form .usa-input--sm,.usa-form .usa-input--small,.usa-form .usa-input-group--sm,.usa-form .usa-input-group--small{max-width:13ex}.usa-form .usa-input--md,.usa-form .usa-input--medium,.usa-form .usa-input-group--md,.usa-form .usa-input-group--medium{max-width:20ex}.usa-form .usa-input--lg,.usa-form .usa-input-group--lg{max-width:30ex}.usa-form .usa-input--xl,.usa-form .usa-input-group--xl{max-width:40ex}.usa-form .usa-input--2xl,.usa-form .usa-input-group--2xl{max-width:50ex}.usa-form .usa-button{margin-top:0.5rem}@media all and (min-width: 30em){.usa-form .usa-button{margin-top:1.5rem}}.usa-form a:where(:not(.usa-button)){color:#005ea2;text-decoration:underline}.usa-form a:where(:not(.usa-button)):visited{color:#54278f}.usa-form a:where(:not(.usa-button)):hover{color:#1a4480}.usa-form a:where(:not(.usa-button)):active{color:#162e51}.usa-form a:where(:not(.usa-button)):focus{outline:0.25rem solid #2491ff;outline-offset:0rem}@media all and (min-width: 30em){.usa-form--large{max-width:30rem}}.usa-show-password{color:#005ea2;text-decoration:underline;background-color:transparent;border:0;border-radius:0;-webkit-box-shadow:none;box-shadow:none;font-weight:normal;-ms-flex-pack:normal;justify-content:normal;text-align:left;margin:0;padding:0;width:auto;cursor:pointer}.usa-show-password:visited{color:#54278f}.usa-show-password:hover{color:#1a4480}.usa-show-password:active{color:#162e51}.usa-show-password:focus{outline:0.25rem solid #2491ff;outline-offset:0rem}.usa-show-password:hover,.usa-show-password.usa-button--hover,.usa-show-password:disabled:hover,.usa-show-password[aria-disabled=true]:hover,.usa-show-password:disabled.usa-button--hover,.usa-show-password[aria-disabled=true].usa-button--hover,.usa-show-password:active,.usa-show-password.usa-button--active,.usa-show-password:disabled:active,.usa-show-password[aria-disabled=true]:active,.usa-show-password:disabled.usa-button--active,.usa-show-password[aria-disabled=true].usa-button--active,.usa-show-password:disabled:focus,.usa-show-password[aria-disabled=true]:focus,.usa-show-password:disabled.usa-focus,.usa-show-password[aria-disabled=true].usa-focus,.usa-show-password:disabled,.usa-show-password[aria-disabled=true],.usa-show-password.usa-button--disabled{background-color:transparent;-webkit-box-shadow:none;box-shadow:none;text-decoration:underline}.usa-show-password.usa-button--hover{color:#1a4480}.usa-show-password.usa-button--active{color:#162e51}.usa-show-password:disabled,.usa-show-password[aria-disabled=true],.usa-show-password:disabled:hover,.usa-show-password[aria-disabled=true]:hover,.usa-show-password[aria-disabled=true]:focus{color:#757575}@media (forced-colors: active){.usa-show-password:disabled,.usa-show-password[aria-disabled=true],.usa-show-password:disabled:hover,.usa-show-password[aria-disabled=true]:hover,.usa-show-password[aria-disabled=true]:focus{color:GrayText}}.usa-form__note,.usa-show-password{font-family:Source Sans Pro Web, "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans;font-size:0.93rem;line-height:1.3;float:right;margin:0.25rem 0 1rem}.usa-fieldset{border:none;margin:0;padding:0}.usa-legend{font-family:Source Sans Pro Web, "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans;font-size:1.06rem;line-height:1.3;display:block;font-weight:normal;margin-top:1.5rem;max-width:30rem}.usa-legend--large{font-size:2.13rem;font-weight:700;margin-top:1rem}.usa-label{font-family:Source Sans Pro Web, "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans;font-size:1.06rem;line-height:1.3;display:block;font-weight:normal;margin-top:1.5rem;max-width:30rem}.usa-label--error{font-weight:700;margin-top:0}.usa-label--required{color:#b50909}.usa-hint{color:#71767a}.usa-hint--required{color:#b50909}.usa-form-group{margin-top:1.5rem}.usa-form-group .usa-label:first-child{margin-top:0}.usa-form-group--error{border-left-width:0.25rem;border-left-color:#b50909;border-left-style:solid;padding-left:1rem;position:relative}@media all and (min-width: 64em){.usa-form-group--error{margin-left:-1.25rem}}.usa-error-message{padding-bottom:0.25rem;padding-top:0.25rem;color:#b50909;display:block;font-weight:700}.usa-memorable-date{display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap}.usa-memorable-date [type=number]{-moz-appearance:textfield}.usa-memorable-date [type=number]::-webkit-inner-spin-button{-webkit-appearance:none;appearance:none}.usa-memorable-date [type=number]::-webkit-contacts-auto-fill-button{visibility:hidden;display:none !important;pointer-events:none;height:0;width:0;margin:0}.usa-memorable-date .usa-form-group{margin-top:1rem}.usa-form-group--day,.usa-form-group--month,.usa-form-group--year{-ms-flex:0 1 auto;flex:0 1 auto;margin-right:1rem;width:-webkit-fit-content;width:-moz-fit-content;width:fit-content}.usa-form-group--day input,.usa-form-group--month input{width:3rem}.usa-form-group--month select{width:15rem}.usa-form-group--year input{width:4.5rem}.usa-error-message{font-size:1.06rem}:host([error]:not([error=""])){border-left:0.25rem solid #b50909;padding-left:1rem;position:relative}:host([error]:not([error=""])[use-forms-pattern=multiple]){border-left:none}:host([error]:not([error=""])[use-forms-pattern=multiple]) .input-wrap{border-left:0.25rem solid #b50909;padding-left:1rem;position:relative}@media screen and (min-width: 1008px){:host([error]:not([error=""])){margin-left:-0.9rem}:host([error]:not([error=""])[use-forms-pattern=multiple]) .input-wrap{margin-left:-0.9rem}}@media screen and (max-width: 1008px){:host([error]:not([error=""])[use-forms-pattern=multiple]){padding-left:0}}:host{display:block;font-family:var(--font-source-sans);margin-top:24px}#error-message{margin-bottom:0}.usa-hint{display:block}slot:not([name])::slotted(*){margin-bottom:0.5rem}va-select::part(label),va-text-input::part(label){margin-top:0;margin-bottom:12px}va-text-input::part(validation){display:none}.usa-memorable-date{margin-top:16px;-ms-flex-wrap:nowrap;flex-wrap:nowrap}.usa-memorable-date .usa-form-group{margin-top:0px}.usa-form-group--month{margin-right:16px}.usa-form-group--month-input{width:48px}.usa-form-group--month-select{width:15rem}.usa-form-group--day-input{width:3rem}.usa-form-group--year-input{width:4.5rem}@media (max-width: 480px){.usa-form-group--month-select{width:100%}.usa-form-group--select{-ms-flex:0 1 50%;flex:0 1 50%;width:50%}}',VaMemorableDateStyle0=vaMemorableDateCss;Build.isTesting&&instance.init({lng:"cimode"});const VaMemorableDate$1=proxyCustomElement(class extends HTMLElement{constructor(){super(),this.__registerHost(),this.__attachShadow(),this.dateChange=createEvent(this,"dateChange",7),this.dateBlur=createEvent(this,"dateBlur",7),this.componentLibraryAnalytics=createEvent(this,"component-library-analytics",7),this.dayTouched=!1,this.monthTouched=!1,this.yearTouched=!1,this.handleDateBlur=e=>{const[a,t,r]=(this.value||"").split("-"),o=Number(a),s=Number(t),i=Number(r);if(validate({component:this,year:o,month:s,day:i,yearTouched:this.yearTouched,monthTouched:this.monthTouched,dayTouched:this.dayTouched,monthSelect:this.monthSelect}),!this.error&&(this.value=a||t||r?`${a}-${t?zeroPadStart(s):""}-${r?zeroPadStart(i):""}`:"",this.dateBlur.emit(e),this.enableAnalytics)){const e={componentName:"va-memorable-date",action:"blur",details:{label:this.label,year:o,month:s,day:i}};this.componentLibraryAnalytics.emit(e)}},this.handleMonthChange=e=>{this.handleDateChange(e)},this.handleDateChange=e=>{const a=e.target;let[t,r,o]=(this.value||"").split("-");(a.classList.contains("input-month")||a.classList.contains("usa-form-group--month-input")||a.classList.contains("usa-form-group--month-select"))&&(r=a.value),(a.classList.contains("input-day")||a.classList.contains("usa-form-group--day-input"))&&(o=a.value),(a.classList.contains("input-year")||a.classList.contains("usa-form-group--year-input"))&&(t=a.value),this.value=t||r||o?`${t}-${r||""}-${o||""}`:"",this.dateChange.emit(e)},this.handleMonthBlur=()=>{this.monthTouched=!0},this.handleDayBlur=()=>{this.dayTouched=!0},this.handleYearBlur=()=>{this.yearTouched=!0},this.required=!1,this.useFormsPattern=void 0,this.formHeadingLevel=3,this.formHeading=void 0,this.monthSelect=!1,this.label=void 0,this.name=void 0,this.hint=void 0,this.error=void 0,this.value=void 0,this.customDayErrorMessage=void 0,this.customMonthErrorMessage=void 0,this.customYearErrorMessage=void 0,this.invalidDay=!1,this.invalidMonth=!1,this.invalidYear=!1,this.enableAnalytics=!1}connectedCallback(){instance.on("languageChanged",(()=>{forceUpdate(this.el)}))}disconnectedCallback(){instance.off("languageChanged")}render(){const{required:e,label:a,name:t,hint:r,error:o,handleDateBlur:s,handleDateChange:i,value:n,monthSelect:l,useFormsPattern:u,formHeadingLevel:m,formHeading:d}=this,[p,f,c]=(n||"").split("-"),g=["dateHint",r?"hint":""].filter(Boolean).join(" "),b=l?instance.t("date-hint-with-select"):instance.t("date-hint"),w=e=>instance.t(e,(e=>{const a=parseInt(p),t=parseInt(f);return getErrorParameters(e,a,t)})(e)),v=`${u&&d?"form-question":""} ${u?"form-description":""} ${u&&a?"input-label":""}`.trim()||null;let y=null;if("single"===u||"multiple"===u){const e=getHeaderLevel(m);y=h(Fragment,null,d&&h(e,{id:"form-question",part:"form-header"},d),h("div",{id:"form-description"},h("slot",{name:"form-description"})))}const x=l?h("div",{class:"usa-form-group usa-form-group--month usa-form-group--select"},h("va-select",{label:instance.t("month"),name:t?`${t}Month`:"Month","aria-describedby":g,"aria-labelledby":v,invalid:this.invalidMonth,onVaSelect:this.handleMonthChange,onBlur:this.handleMonthBlur,class:"usa-form-group--month-select",reflectInputError:"month-range"===o,value:f?String(parseInt(f)):f,error:this.invalidMonth?w(o):null,showError:!1},months&&months.map((e=>h("option",{value:e.value,selected:e.value===parseInt(f)},e.label))))):h("div",{class:"usa-form-group usa-form-group--month"},h("va-text-input",{label:instance.t("month"),name:t?`${t}Month`:"Month",maxlength:2,pattern:"[0-9]*","aria-describedby":g,"aria-labelledby":v,invalid:this.invalidMonth,value:null==f?void 0:f.toString(),onInput:i,onBlur:this.handleMonthBlur,class:"usa-form-group--month-input memorable-date-input",reflectInputError:"month-range"===o,inputmode:"numeric",type:"text",error:this.invalidMonth?w(o):null,"show-input-error":"false"})),M=classnames({"usa-legend":!0,"usa-label--error":o});return h(Host,{onBlur:s},y,h("div",{class:"input-wrap"},h("fieldset",{class:"usa-form usa-fieldset"},h("legend",{class:M,id:"input-label",part:"legend"},a,e&&h("span",{class:"usa-label--required"}," ",instance.t("required")),r&&h("div",{class:"usa-hint",id:"hint"},r),h("span",{class:"usa-hint",id:"dateHint"},b)),h("span",{id:"error-message",role:"alert"},o&&h(Fragment,null,h("span",{class:"usa-sr-only"},instance.t("error")),h("span",{class:"usa-error-message"},(e=>{let a="";return this.invalidDay?a=this.customDayErrorMessage:this.invalidMonth?a=this.customMonthErrorMessage:this.invalidYear&&(a=this.customYearErrorMessage),a||w(e)})(o)))),h("slot",null),h("div",{class:"usa-memorable-date"},x,h("div",{class:"usa-form-group usa-form-group--day"},h("va-text-input",{label:instance.t("day"),name:t?`${t}Day`:"Day",maxlength:2,pattern:"[0-9]*","aria-describedby":g,invalid:this.invalidDay,value:null==c?void 0:c.toString(),onInput:i,onBlur:this.handleDayBlur,class:"usa-form-group--day-input memorable-date-input",reflectInputError:"day-range"===o,inputmode:"numeric",type:"text",error:this.invalidDay?w(o):null,"show-input-error":"false"})),h("div",{class:"usa-form-group usa-form-group--year"},h("va-text-input",{label:instance.t("year"),name:t?`${t}Year`:"Year",maxlength:4,pattern:"[0-9]*","aria-describedby":g,invalid:this.invalidYear,value:null==p?void 0:p.toString(),onInput:i,onBlur:this.handleYearBlur,class:"usa-form-group--year-input memorable-date-input",reflectInputError:"year-range"===o,inputmode:"numeric",type:"text",error:this.invalidYear?w(o):null,"show-input-error":"false"}))))))}get el(){return this}static get style(){return VaMemorableDateStyle0}},[1,"va-memorable-date",{required:[4],useFormsPattern:[1,"use-forms-pattern"],formHeadingLevel:[2,"form-heading-level"],formHeading:[1,"form-heading"],monthSelect:[4,"month-select"],label:[1],name:[1],hint:[1],error:[1537],value:[1537],customDayErrorMessage:[1,"custom-day-error-message"],customMonthErrorMessage:[1,"custom-month-error-message"],customYearErrorMessage:[1,"custom-year-error-message"],invalidDay:[1028,"invalid-day"],invalidMonth:[1028,"invalid-month"],invalidYear:[1028,"invalid-year"],enableAnalytics:[4,"enable-analytics"]}]);function defineCustomElement$1(){"undefined"!=typeof customElements&&["va-memorable-date","va-icon","va-select","va-text-input"].forEach((e=>{switch(e){case"va-memorable-date":customElements.get(e)||customElements.define(e,VaMemorableDate$1);break;case"va-icon":customElements.get(e)||defineCustomElement$4();break;case"va-select":customElements.get(e)||defineCustomElement$3();break;case"va-text-input":customElements.get(e)||defineCustomElement$2()}}))}const VaMemorableDate=VaMemorableDate$1,defineCustomElement=defineCustomElement$1;export{VaMemorableDate,defineCustomElement};
1
+ import{Build,proxyCustomElement,HTMLElement,createEvent,forceUpdate,h,Fragment,Host}from"@stencil/core/internal/client";import{v as validate,z as zeroPadStart,g as getErrorParameters,m as months}from"./date-utils.js";import{a as getHeaderLevel}from"./utils.js";import"./i18n-setup.js";import"./contacts.js";import{c as classnames}from"./index2.js";import{d as defineCustomElement$4}from"./va-icon2.js";import{d as defineCustomElement$3}from"./va-select2.js";import{d as defineCustomElement$2}from"./va-text-input2.js";import{i as instance}from"./i18next.js";const vaMemorableDateCss='button:not([disabled]):focus,select:not([disabled]):focus,a:not([disabled]):focus,h1:focus,input:not([disabled]):focus,textarea:not([disabled]):focus,#form-question [role=\'option\']:focus,*[tabindex]:focus{outline:2px solid var(--vads-color-action-focus-on-light);outline-offset:2px}#error-message{margin-bottom:0.75rem}#error-message,#input-error-message{color:var(--vads-color-secondary-dark);display:block;font-weight:700;font-size:1.06rem}:host([error]:not([error=\'\'])){border-left:0.3rem solid var(--vads-color-secondary-dark);padding-left:1.25rem;position:relative}@media screen and (min-width: 1008px){:host([error]:not([error=\'\'])){margin-left:-1.4375rem;}}h1{margin-top:0}h1,h2,h3,h4,h5,h6{margin-bottom:0;margin-top:0;clear:both}*+h1,*+h2,*+h3,*+h4,*+h5,*+h6{margin-top:1.5em}h1+*,h2+*,h3+*,h4+*,h5+*,h6+*{margin-top:1em}h1{font-family:Merriweather Web, Georgia, Cambria, Times New Roman, Times, serif;font-size:2.44rem;line-height:1.2;font-weight:700}h2{font-family:Merriweather Web, Georgia, Cambria, Times New Roman, Times, serif;font-size:1.95rem;line-height:1.2;font-weight:700}h3{font-family:Merriweather Web, Georgia, Cambria, Times New Roman, Times, serif;font-size:1.34rem;line-height:1.2;font-weight:700}h4{font-family:Merriweather Web, Georgia, Cambria, Times New Roman, Times, serif;font-size:0.98rem;line-height:1.2;font-weight:700}h5{font-family:Merriweather Web, Georgia, Cambria, Times New Roman, Times, serif;font-size:0.91rem;line-height:1.2;font-weight:700}h6{font-family:Source Sans Pro Web, Helvetica Neue, Helvetica, Roboto, Arial, sans-serif;font-size:0.87rem;line-height:1.1;font-weight:normal;letter-spacing:0.025em;text-transform:uppercase}h1,h2,h3,h4,h5{font-family:Bitter, Georgia, Cambria, "Times New Roman", Times, serif;font-weight:700}h6{font-family:"Source Sans Pro Web", "Source Sans Pro", "Helvetica Neue", Helvetica, Roboto, Arial, sans-serif;font-weight:700}h1{margin-top:0;font-size:2.5rem}h2{font-size:1.875rem}h3{font-size:1.25rem}h4{font-size:1.0625rem}h5{font-size:0.9375rem}h6{font-size:0.9375rem}@media (max-width: 481px){h1{font-size:30px}h2{font-size:24px}}h6{margin:0.5em 0 0;text-transform:none;font-weight:700}@media (max-width: 481px){h1{font-size:30px}h2{font-size:24px}}h6{margin:0.5em 0 0;text-transform:none;font-weight:700}:host legend :is(h1,h2,h3,h4,h5,h6),:host label :is(h1,h2,h3,h4,h5,h6){display:inline;margin:0px}:host legend :is(h1,h2,h3,h4,h5),:host label :is(h1,h2,h3,h4,h5){font-family:var(--font-serif)}:host h1+*,:host h2+*,:host h3+*,:host h4+*,:host h5+*,:host h6+*{margin-top:unset}:host #form-question{margin-bottom:1rem}.usa-hint,.usa-fieldset{font-family:Source Sans Pro Web, "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans;font-size:1.06rem;line-height:1.3}.usa-sr-only{position:absolute;left:-999em;right:auto}.usa-form{font-family:Source Sans Pro Web, "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans;font-size:1.06rem;line-height:1.3}@media all and (min-width: 30em){.usa-form{max-width:20rem}}.usa-form abbr[title=required]{text-decoration:none}.usa-form .usa-input,.usa-form .usa-range,.usa-form .usa-select,.usa-form .usa-textarea{max-width:none}.usa-form .usa-input--2xs,.usa-form .usa-input-group--2xs{max-width:5ex}.usa-form .usa-input--xs,.usa-form .usa-input-group--xs{max-width:9ex}.usa-form .usa-input--sm,.usa-form .usa-input--small,.usa-form .usa-input-group--sm,.usa-form .usa-input-group--small{max-width:13ex}.usa-form .usa-input--md,.usa-form .usa-input--medium,.usa-form .usa-input-group--md,.usa-form .usa-input-group--medium{max-width:20ex}.usa-form .usa-input--lg,.usa-form .usa-input-group--lg{max-width:30ex}.usa-form .usa-input--xl,.usa-form .usa-input-group--xl{max-width:40ex}.usa-form .usa-input--2xl,.usa-form .usa-input-group--2xl{max-width:50ex}.usa-form .usa-button{margin-top:0.5rem}@media all and (min-width: 30em){.usa-form .usa-button{margin-top:1.5rem}}.usa-form a:where(:not(.usa-button)){color:#005ea2;text-decoration:underline}.usa-form a:where(:not(.usa-button)):visited{color:#54278f}.usa-form a:where(:not(.usa-button)):hover{color:#1a4480}.usa-form a:where(:not(.usa-button)):active{color:#162e51}.usa-form a:where(:not(.usa-button)):focus{outline:0.25rem solid #2491ff;outline-offset:0rem}@media all and (min-width: 30em){.usa-form--large{max-width:30rem}}.usa-show-password{color:#005ea2;text-decoration:underline;background-color:transparent;border:0;border-radius:0;-webkit-box-shadow:none;box-shadow:none;font-weight:normal;-ms-flex-pack:normal;justify-content:normal;text-align:left;margin:0;padding:0;width:auto;cursor:pointer}.usa-show-password:visited{color:#54278f}.usa-show-password:hover{color:#1a4480}.usa-show-password:active{color:#162e51}.usa-show-password:focus{outline:0.25rem solid #2491ff;outline-offset:0rem}.usa-show-password:hover,.usa-show-password.usa-button--hover,.usa-show-password:disabled:hover,.usa-show-password[aria-disabled=true]:hover,.usa-show-password:disabled.usa-button--hover,.usa-show-password[aria-disabled=true].usa-button--hover,.usa-show-password:active,.usa-show-password.usa-button--active,.usa-show-password:disabled:active,.usa-show-password[aria-disabled=true]:active,.usa-show-password:disabled.usa-button--active,.usa-show-password[aria-disabled=true].usa-button--active,.usa-show-password:disabled:focus,.usa-show-password[aria-disabled=true]:focus,.usa-show-password:disabled.usa-focus,.usa-show-password[aria-disabled=true].usa-focus,.usa-show-password:disabled,.usa-show-password[aria-disabled=true],.usa-show-password.usa-button--disabled{background-color:transparent;-webkit-box-shadow:none;box-shadow:none;text-decoration:underline}.usa-show-password.usa-button--hover{color:#1a4480}.usa-show-password.usa-button--active{color:#162e51}.usa-show-password:disabled,.usa-show-password[aria-disabled=true],.usa-show-password:disabled:hover,.usa-show-password[aria-disabled=true]:hover,.usa-show-password[aria-disabled=true]:focus{color:#757575}@media (forced-colors: active){.usa-show-password:disabled,.usa-show-password[aria-disabled=true],.usa-show-password:disabled:hover,.usa-show-password[aria-disabled=true]:hover,.usa-show-password[aria-disabled=true]:focus{color:GrayText}}.usa-form__note,.usa-show-password{font-family:Source Sans Pro Web, "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans;font-size:0.93rem;line-height:1.3;float:right;margin:0.25rem 0 1rem}.usa-fieldset{border:none;margin:0;padding:0}.usa-legend{font-family:Source Sans Pro Web, "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans;font-size:1.06rem;line-height:1.3;display:block;font-weight:normal;margin-top:1.5rem;max-width:30rem}.usa-legend--large{font-size:2.13rem;font-weight:700;margin-top:1rem}.usa-label{font-family:Source Sans Pro Web, "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans;font-size:1.06rem;line-height:1.3;display:block;font-weight:normal;margin-top:1.5rem;max-width:30rem}.usa-label--error{font-weight:700;margin-top:0}.usa-label--required{color:#b50909}.usa-hint{color:#71767a}.usa-hint--required{color:#b50909}.usa-form-group{margin-top:1.5rem}.usa-form-group .usa-label:first-child{margin-top:0}.usa-form-group--error{border-left-width:0.25rem;border-left-color:#b50909;border-left-style:solid;padding-left:1rem;position:relative}@media all and (min-width: 64em){.usa-form-group--error{margin-left:-1.25rem}}.usa-error-message{padding-bottom:0.25rem;padding-top:0.25rem;color:#b50909;display:block;font-weight:700}.usa-memorable-date{display:-ms-flexbox;display:flex;-ms-flex-wrap:wrap;flex-wrap:wrap}.usa-memorable-date [type=number]{-moz-appearance:textfield}.usa-memorable-date [type=number]::-webkit-inner-spin-button{-webkit-appearance:none;appearance:none}.usa-memorable-date [type=number]::-webkit-contacts-auto-fill-button{visibility:hidden;display:none !important;pointer-events:none;height:0;width:0;margin:0}.usa-memorable-date .usa-form-group{margin-top:1rem}.usa-form-group--day,.usa-form-group--month,.usa-form-group--year{-ms-flex:0 1 auto;flex:0 1 auto;margin-right:1rem;width:-webkit-fit-content;width:-moz-fit-content;width:fit-content}.usa-form-group--day input,.usa-form-group--month input{width:3rem}.usa-form-group--month select{width:15rem}.usa-form-group--year input{width:4.5rem}.usa-error-message{font-size:1.06rem}:host([error]:not([error=""])){border-left:0.25rem solid #b50909;padding-left:1rem;position:relative}:host([error]:not([error=""])[use-forms-pattern=multiple]){border-left:none}:host([error]:not([error=""])[use-forms-pattern=multiple]) .input-wrap{border-left:0.25rem solid #b50909;padding-left:1rem;position:relative}@media screen and (min-width: 1008px){:host([error]:not([error=""])){margin-left:-0.9rem}:host([error]:not([error=""])[use-forms-pattern=multiple]) .input-wrap{margin-left:-0.9rem}}@media screen and (max-width: 1008px){:host([error]:not([error=""])[use-forms-pattern=multiple]){padding-left:0}}:host{display:block;font-family:var(--font-source-sans);margin-top:24px}#error-message{margin-bottom:0}.usa-hint{display:block}slot:not([name])::slotted(*){margin-bottom:0.5rem}va-select::part(label),va-text-input::part(label){margin-top:0;margin-bottom:12px}va-text-input::part(validation){display:none}.usa-memorable-date{margin-top:16px;-ms-flex-wrap:nowrap;flex-wrap:nowrap}.usa-memorable-date .usa-form-group{margin-top:0px}.usa-form-group--month{margin-right:16px}.usa-form-group--month-input{width:48px}.usa-form-group--month-select{width:15rem}.usa-form-group--day-input{width:3rem}.usa-form-group--year-input{width:4.5rem}@media (max-width: 480px){.usa-form-group--month-select{width:100%}.usa-form-group--select{-ms-flex:0 1 50%;flex:0 1 50%;width:50%}}',VaMemorableDateStyle0=vaMemorableDateCss;Build.isTesting&&instance.init({lng:"cimode"});const VaMemorableDate$1=proxyCustomElement(class extends HTMLElement{constructor(){super(),this.__registerHost(),this.__attachShadow(),this.dateChange=createEvent(this,"dateChange",7),this.dateBlur=createEvent(this,"dateBlur",7),this.componentLibraryAnalytics=createEvent(this,"component-library-analytics",7),this.dayTouched=!1,this.monthTouched=!1,this.yearTouched=!1,this.handleDateBlur=e=>{const[a,t,r]=(this.value||"").split("-"),o=Number(a),s=Number(t),i=Number(r);if(validate({component:this,year:o,month:s,day:i,yearTouched:this.yearTouched,monthTouched:this.monthTouched,dayTouched:this.dayTouched,monthSelect:this.monthSelect}),!this.error&&(this.value=a||t||r?`${a}-${t?zeroPadStart(s):""}-${r?zeroPadStart(i):""}`:"",this.dateBlur.emit(e),this.enableAnalytics)){const e={componentName:"va-memorable-date",action:"blur",details:{label:this.label,year:o,month:s,day:i}};this.componentLibraryAnalytics.emit(e)}},this.handleMonthChange=e=>{this.handleDateChange(e)},this.handleDateChange=e=>{const a=e.target;let[t,r,o]=(this.value||"").split("-");(a.classList.contains("input-month")||a.classList.contains("usa-form-group--month-input")||a.classList.contains("usa-form-group--month-select"))&&(r=a.value),(a.classList.contains("input-day")||a.classList.contains("usa-form-group--day-input"))&&(o=a.value),(a.classList.contains("input-year")||a.classList.contains("usa-form-group--year-input"))&&(t=a.value),this.value=t||r||o?`${t}-${r||""}-${o||""}`:"",this.dateChange.emit(e)},this.handleMonthBlur=()=>{this.monthTouched=!0},this.handleDayBlur=()=>{this.dayTouched=!0},this.handleYearBlur=()=>{this.yearTouched=!0},this.required=!1,this.useFormsPattern=void 0,this.formHeadingLevel=3,this.formHeading=void 0,this.monthSelect=!1,this.label=void 0,this.name=void 0,this.hint=void 0,this.error=void 0,this.value=void 0,this.customDayErrorMessage=void 0,this.customMonthErrorMessage=void 0,this.customYearErrorMessage=void 0,this.invalidDay=!1,this.invalidMonth=!1,this.invalidYear=!1,this.enableAnalytics=!1}connectedCallback(){instance.on("languageChanged",(()=>{forceUpdate(this.el)}))}disconnectedCallback(){instance.off("languageChanged")}render(){const{required:e,label:a,name:t,hint:r,error:o,handleDateBlur:s,handleDateChange:i,value:n,monthSelect:l,useFormsPattern:u,formHeadingLevel:m,formHeading:d}=this,[p,f,c]=(n||"").split("-"),g=["dateHint",r?"hint":""].filter(Boolean).join(" "),b=l?instance.t("date-hint-with-select"):instance.t("date-hint"),w=e=>instance.t(e,(e=>{const a=parseInt(p),t=parseInt(f);return getErrorParameters(e,a,t)})(e)),v=`${u&&d?"form-question":""} ${u?"form-description":""} ${u&&a?"input-label":""}`.trim()||null;let y=null;if("single"===u||"multiple"===u){const e=getHeaderLevel(m);y=h(Fragment,null,d&&h(e,{id:"form-question",part:"form-header"},d),h("div",{id:"form-description"},h("slot",{name:"form-description"})))}const x=l?h("div",{class:"usa-form-group usa-form-group--month usa-form-group--select"},h("va-select",{label:instance.t("month"),name:t?`${t}Month`:"Month","aria-describedby":g,"aria-labelledby":v,invalid:this.invalidMonth,onVaSelect:this.handleMonthChange,onBlur:this.handleMonthBlur,class:"usa-form-group--month-select",reflectInputError:"month-range"===o,value:f?String(parseInt(f)):f,error:this.invalidMonth?w(o):null,showError:!1},months&&months.map((e=>h("option",{value:e.value,selected:e.value===parseInt(f)},e.label))))):h("div",{class:"usa-form-group usa-form-group--month"},h("va-text-input",{label:instance.t("month"),name:t?`${t}Month`:"Month",maxlength:2,pattern:"[0-9]*","aria-describedby":g,"aria-labelledby":v,invalid:this.invalidMonth,value:null==f?void 0:f.toString(),onInput:i,onBlur:this.handleMonthBlur,class:"usa-form-group--month-input memorable-date-input",reflectInputError:"month-range"===o,inputmode:"numeric",type:"text",error:this.invalidMonth?w(o):null,"show-input-error":"false"})),M=classnames({"usa-legend":!0,"usa-label--error":o});return h(Host,{onBlur:s},y,h("div",{class:"input-wrap"},h("fieldset",{class:"usa-form usa-fieldset"},h("legend",{class:M,id:"input-label",part:"legend"},a,e&&h("span",{class:"usa-label--required"}," ",instance.t("required")),r&&h("div",{class:"usa-hint",id:"hint"},r),h("span",{class:"usa-hint",id:"dateHint"},b)),h("span",{id:"error-message",role:"alert"},o&&h(Fragment,null,h("span",{class:"usa-sr-only"},instance.t("error")),h("span",{class:"usa-error-message"},(e=>{let a="";return this.invalidDay?a=this.customDayErrorMessage:this.invalidMonth?a=this.customMonthErrorMessage:this.invalidYear&&(a=this.customYearErrorMessage),a||w(e)})(o)))),h("slot",null),h("div",{class:"usa-memorable-date"},x,h("div",{class:"usa-form-group usa-form-group--day"},h("va-text-input",{label:instance.t("day"),name:t?`${t}Day`:"Day",maxlength:2,pattern:"[0-9]*","aria-describedby":g,invalid:this.invalidDay,value:null==c?void 0:c.toString(),onInput:i,onBlur:this.handleDayBlur,class:"usa-form-group--day-input memorable-date-input",reflectInputError:"day-range"===o,inputmode:"numeric",type:"text",error:this.invalidDay?w(o):null,"show-input-error":"false"})),h("div",{class:"usa-form-group usa-form-group--year"},h("va-text-input",{label:instance.t("year"),name:t?`${t}Year`:"Year",maxlength:4,pattern:"[0-9]*","aria-describedby":g,invalid:this.invalidYear,value:null==p?void 0:p.toString(),onInput:i,onBlur:this.handleYearBlur,class:"usa-form-group--year-input memorable-date-input",reflectInputError:"year-range"===o,inputmode:"numeric",type:"text",error:this.invalidYear?w(o):null,"show-input-error":"false"}))))))}get el(){return this}static get style(){return VaMemorableDateStyle0}},[1,"va-memorable-date",{required:[4],useFormsPattern:[1,"use-forms-pattern"],formHeadingLevel:[2,"form-heading-level"],formHeading:[1,"form-heading"],monthSelect:[4,"month-select"],label:[1],name:[1],hint:[1],error:[1537],value:[1537],customDayErrorMessage:[1,"custom-day-error-message"],customMonthErrorMessage:[1,"custom-month-error-message"],customYearErrorMessage:[1,"custom-year-error-message"],invalidDay:[1028,"invalid-day"],invalidMonth:[1028,"invalid-month"],invalidYear:[1028,"invalid-year"],enableAnalytics:[4,"enable-analytics"]}]);function defineCustomElement$1(){"undefined"!=typeof customElements&&["va-memorable-date","va-icon","va-select","va-text-input"].forEach((e=>{switch(e){case"va-memorable-date":customElements.get(e)||customElements.define(e,VaMemorableDate$1);break;case"va-icon":customElements.get(e)||defineCustomElement$4();break;case"va-select":customElements.get(e)||defineCustomElement$3();break;case"va-text-input":customElements.get(e)||defineCustomElement$2()}}))}const VaMemorableDate=VaMemorableDate$1,defineCustomElement=defineCustomElement$1;export{VaMemorableDate,defineCustomElement};