@govbr-ds/webcomponents 2.1.0 → 2.1.2

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 (866) hide show
  1. package/README.md +0 -11
  2. package/cem/custom-elements.json +272 -71
  3. package/dist/cjs/app-globals-DcqHuMBv.js +9 -0
  4. package/dist/cjs/br-avatar.cjs.entry.js +248 -0
  5. package/dist/cjs/br-breadcrumb-item.cjs.entry.js +45 -0
  6. package/dist/cjs/br-breadcrumb.cjs.entry.js +443 -0
  7. package/dist/cjs/br-button_2.cjs.entry.js +280 -0
  8. package/dist/cjs/br-card.cjs.entry.js +111 -0
  9. package/dist/cjs/br-carousel-page.cjs.entry.js +80 -0
  10. package/dist/cjs/br-carousel.cjs.entry.js +565 -0
  11. package/dist/cjs/br-checkbox-group.cjs.entry.js +118 -0
  12. package/dist/cjs/br-checkbox.cjs.entry.js +288 -0
  13. package/dist/cjs/br-checkgroup.cjs.entry.js +20 -0
  14. package/dist/cjs/br-collapse_2.cjs.entry.js +683 -0
  15. package/dist/cjs/br-cookiebar-cookie.cjs.entry.js +83 -0
  16. package/dist/cjs/br-cookiebar-group.cjs.entry.js +309 -0
  17. package/dist/cjs/br-cookiebar-header.cjs.entry.js +39 -0
  18. package/dist/cjs/br-cookiebar-link.cjs.entry.js +55 -0
  19. package/dist/cjs/br-cookiebar-note-group.cjs.entry.js +70 -0
  20. package/dist/cjs/br-cookiebar-note.cjs.entry.js +25 -0
  21. package/dist/cjs/br-cookiebar.cjs.entry.js +758 -0
  22. package/dist/cjs/br-crumb.cjs.entry.js +51 -0
  23. package/dist/cjs/br-date-picker_3.cjs.entry.js +2447 -0
  24. package/dist/cjs/br-datetime-picker.cjs.entry.js +1886 -0
  25. package/dist/cjs/br-divider.cjs.entry.js +225 -0
  26. package/dist/cjs/br-dropdown_2.cjs.entry.js +2000 -0
  27. package/dist/cjs/br-footer-category.cjs.entry.js +102 -0
  28. package/dist/cjs/br-footer-item.cjs.entry.js +52 -0
  29. package/dist/cjs/br-footer-legal.cjs.entry.js +41 -0
  30. package/dist/cjs/br-footer-logo.cjs.entry.js +104 -0
  31. package/dist/cjs/br-footer-social.cjs.entry.js +71 -0
  32. package/dist/cjs/br-footer.cjs.entry.js +92 -0
  33. package/dist/cjs/br-header-function.cjs.entry.js +142 -0
  34. package/dist/cjs/br-header-link.cjs.entry.js +60 -0
  35. package/dist/cjs/br-header-list.cjs.entry.js +279 -0
  36. package/dist/cjs/br-header-logo.cjs.entry.js +178 -0
  37. package/dist/cjs/br-header.cjs.entry.js +642 -0
  38. package/dist/cjs/br-icon.cjs.entry.js +485 -0
  39. package/dist/cjs/br-input.cjs.entry.js +599 -0
  40. package/dist/cjs/br-item.cjs.entry.js +367 -0
  41. package/dist/cjs/br-link.cjs.entry.js +133 -0
  42. package/dist/cjs/br-loading.cjs.entry.js +505 -0
  43. package/dist/cjs/br-magic-button.cjs.entry.js +93 -0
  44. package/dist/cjs/br-menu-group.cjs.entry.js +23 -0
  45. package/dist/cjs/br-menu-header.cjs.entry.js +47 -0
  46. package/dist/cjs/br-menu-info.cjs.entry.js +38 -0
  47. package/dist/cjs/br-menu-item.cjs.entry.js +79 -0
  48. package/dist/cjs/br-menu-link.cjs.entry.js +56 -0
  49. package/dist/cjs/br-menu-list.cjs.entry.js +149 -0
  50. package/dist/cjs/br-menu-logo.cjs.entry.js +75 -0
  51. package/dist/cjs/br-menu-social.cjs.entry.js +65 -0
  52. package/dist/cjs/br-menu.cjs.entry.js +993 -0
  53. package/dist/cjs/br-modal.cjs.entry.js +496 -0
  54. package/dist/cjs/br-notification-body.cjs.entry.js +71 -0
  55. package/dist/cjs/br-notification-header.cjs.entry.js +48 -0
  56. package/dist/cjs/br-notification-item.cjs.entry.js +110 -0
  57. package/dist/cjs/br-notification.cjs.entry.js +334 -0
  58. package/dist/cjs/br-pagination.cjs.entry.js +884 -0
  59. package/dist/cjs/br-radio-group.cjs.entry.js +428 -0
  60. package/dist/cjs/br-radio.cjs.entry.js +357 -0
  61. package/dist/cjs/br-scrim.cjs.entry.js +1336 -0
  62. package/dist/cjs/br-select-input_3.cjs.entry.js +988 -0
  63. package/dist/cjs/br-sign-in.cjs.entry.js +126 -0
  64. package/dist/cjs/br-skip-link-item.cjs.entry.js +20 -0
  65. package/dist/cjs/br-skip-link.cjs.entry.js +362 -0
  66. package/dist/cjs/br-skiplink-item.cjs.entry.js +192 -0
  67. package/dist/cjs/br-slider.cjs.entry.js +687 -0
  68. package/dist/cjs/br-step_2.cjs.entry.js +628 -0
  69. package/dist/cjs/br-switch.cjs.entry.js +245 -0
  70. package/dist/cjs/br-tab-item.cjs.entry.js +185 -0
  71. package/dist/cjs/br-tab.cjs.entry.js +397 -0
  72. package/dist/cjs/br-table-body.cjs.entry.js +37 -0
  73. package/dist/cjs/br-table-cell.cjs.entry.js +184 -0
  74. package/dist/cjs/br-table-header-cell.cjs.entry.js +173 -0
  75. package/dist/cjs/br-table-header.cjs.entry.js +37 -0
  76. package/dist/cjs/br-table-row.cjs.entry.js +81 -0
  77. package/dist/cjs/br-table.cjs.entry.js +680 -0
  78. package/dist/cjs/br-tag.cjs.entry.js +493 -0
  79. package/dist/cjs/br-textarea.cjs.entry.js +306 -0
  80. package/dist/cjs/br-tooltip.cjs.entry.js +627 -0
  81. package/dist/cjs/br-upload.cjs.entry.js +581 -0
  82. package/dist/cjs/br-wizard-panel.cjs.entry.js +54 -0
  83. package/dist/cjs/br-wizard.cjs.entry.js +708 -0
  84. package/dist/cjs/breakpoint-observer-P8veqXg7.js +144 -0
  85. package/dist/cjs/clamp-Co_hWptd.js +25 -0
  86. package/dist/cjs/cookiebar.utils-CB1gQwZ4.js +18 -0
  87. package/dist/cjs/datetime-picker-constants-B5pWeOn1.js +3827 -0
  88. package/dist/cjs/event-CmVdNHxl.js +56 -0
  89. package/dist/cjs/floating-surface-dismiss-ccdiD0KF.js +63 -0
  90. package/dist/cjs/floating-ui-MBI1osio.js +136 -0
  91. package/dist/cjs/floating-ui.dom-BUSTaaxR.js +1715 -0
  92. package/dist/cjs/focus-DuywwJPR.js +30 -0
  93. package/dist/cjs/getNextElement-R9l3JtM9.js +31 -0
  94. package/dist/cjs/iconify-icon-DfODV9bf.js +2307 -0
  95. package/dist/cjs/id-CjRFMzf6.js +20 -0
  96. package/dist/cjs/index-C92n55ch.js +678 -0
  97. package/dist/cjs/index-CRdcutym.js +3287 -0
  98. package/dist/cjs/index.cjs.js +12 -0
  99. package/dist/cjs/isNil-DO5zWc3l.js +19 -0
  100. package/dist/cjs/isValid-Fu3kaWNn.js +3694 -0
  101. package/dist/cjs/loader.cjs.js +17 -0
  102. package/dist/cjs/native-dialog--Ewqm4w0.js +49 -0
  103. package/dist/cjs/navigation-AbzwcRCU.js +25 -0
  104. package/dist/cjs/parts-D5K3ae2C.js +19 -0
  105. package/dist/cjs/props-CScmBvKd.js +24 -0
  106. package/dist/cjs/raf-batcher-yc87a4dS.js +55 -0
  107. package/dist/cjs/slot-DAllytTj.js +48 -0
  108. package/dist/cjs/swipe-BU8_XE9f.js +345 -0
  109. package/dist/cjs/table-constants-BOPSay0B.js +183 -0
  110. package/dist/cjs/validator-CTCajtT9.js +123 -0
  111. package/dist/cjs/webcomponents.cjs.js +50 -0
  112. package/dist/collection/assets/icon-search.svg +6 -0
  113. package/dist/collection/assets/logo-negative.svg +1 -0
  114. package/dist/collection/assets/logo-positive.svg +1 -0
  115. package/dist/collection/assets/wc.svg +1 -0
  116. package/dist/collection/collection-manifest.json +113 -0
  117. package/dist/collection/components/avatar/avatar.css +1 -0
  118. package/dist/collection/components/avatar/avatar.js +589 -0
  119. package/dist/collection/components/avatar/avatar.types.js +1 -0
  120. package/dist/collection/components/breadcrumb/breadcrumb-item/breadcrumb-item.js +166 -0
  121. package/dist/collection/components/breadcrumb/breadcrumb.css +1 -0
  122. package/dist/collection/components/breadcrumb/breadcrumb.js +619 -0
  123. package/dist/collection/components/breadcrumb/breadcrumb.types.js +1 -0
  124. package/dist/collection/components/breadcrumb/crumb/crumb.js +175 -0
  125. package/dist/collection/components/button/button.css +1 -0
  126. package/dist/collection/components/button/button.js +546 -0
  127. package/dist/collection/components/button/button.types.js +1 -0
  128. package/dist/collection/components/card/card.css +1 -0
  129. package/dist/collection/components/card/card.js +225 -0
  130. package/dist/collection/components/carousel/carousel-page/carousel-page.css +1 -0
  131. package/dist/collection/components/carousel/carousel-page/carousel-page.js +195 -0
  132. package/dist/collection/components/carousel/carousel.css +1 -0
  133. package/dist/collection/components/carousel/carousel.js +1217 -0
  134. package/dist/collection/components/carousel/carousel.types.js +1 -0
  135. package/dist/collection/components/checkbox/checkbox.css +1 -0
  136. package/dist/collection/components/checkbox/checkbox.js +823 -0
  137. package/dist/collection/components/checkbox/checkbox.types.js +1 -0
  138. package/dist/collection/components/checkbox-group/checkbox-group.css +1 -0
  139. package/dist/collection/components/checkbox-group/checkbox-group.js +268 -0
  140. package/dist/collection/components/checkgroup/checkgroup.js +166 -0
  141. package/dist/collection/components/collapse/collapse.css +1 -0
  142. package/dist/collection/components/collapse/collapse.js +642 -0
  143. package/dist/collection/components/collapse/collapse.types.js +1 -0
  144. package/dist/collection/components/cookiebar/cookiebar-cookie/cookiebar-cookie.css +1 -0
  145. package/dist/collection/components/cookiebar/cookiebar-cookie/cookiebar-cookie.js +529 -0
  146. package/dist/collection/components/cookiebar/cookiebar-group/cookiebar-group.css +1 -0
  147. package/dist/collection/components/cookiebar/cookiebar-group/cookiebar-group.js +628 -0
  148. package/dist/collection/components/cookiebar/cookiebar-header/cookiebar-header.css +1 -0
  149. package/dist/collection/components/cookiebar/cookiebar-header/cookiebar-header.js +165 -0
  150. package/dist/collection/components/cookiebar/cookiebar-link/cookiebar-link.css +1 -0
  151. package/dist/collection/components/cookiebar/cookiebar-link/cookiebar-link.js +201 -0
  152. package/dist/collection/components/cookiebar/cookiebar-note/cookiebar-note.css +1 -0
  153. package/dist/collection/components/cookiebar/cookiebar-note/cookiebar-note.js +100 -0
  154. package/dist/collection/components/cookiebar/cookiebar-note-group/cookiebar-note-group.css +1 -0
  155. package/dist/collection/components/cookiebar/cookiebar-note-group/cookiebar-note-group.js +172 -0
  156. package/dist/collection/components/cookiebar/cookiebar.css +1 -0
  157. package/dist/collection/components/cookiebar/cookiebar.js +1419 -0
  158. package/dist/collection/components/cookiebar/cookiebar.types.js +1 -0
  159. package/dist/collection/components/cookiebar/cookiebar.utils.js +14 -0
  160. package/dist/collection/components/datetime-picker/date-picker/date-picker-locale.js +94 -0
  161. package/dist/collection/components/datetime-picker/date-picker/date-picker-props-validation.js +57 -0
  162. package/dist/collection/components/datetime-picker/date-picker/date-picker.css +1 -0
  163. package/dist/collection/components/datetime-picker/date-picker/date-picker.js +913 -0
  164. package/dist/collection/components/datetime-picker/datetime-input/datetime-input-props-validation.js +65 -0
  165. package/dist/collection/components/datetime-picker/datetime-input/datetime-input.css +1 -0
  166. package/dist/collection/components/datetime-picker/datetime-input/datetime-input.js +826 -0
  167. package/dist/collection/components/datetime-picker/datetime-picker-constants.js +36 -0
  168. package/dist/collection/components/datetime-picker/datetime-picker-form-associated.js +112 -0
  169. package/dist/collection/components/datetime-picker/datetime-picker-props-validation.js +202 -0
  170. package/dist/collection/components/datetime-picker/datetime-picker.css +1 -0
  171. package/dist/collection/components/datetime-picker/datetime-picker.js +1924 -0
  172. package/dist/collection/components/datetime-picker/datetime-picker.types.js +1 -0
  173. package/dist/collection/components/datetime-picker/datetime-picker.utils.js +250 -0
  174. package/dist/collection/components/datetime-picker/time-picker/time-picker-constants.js +13 -0
  175. package/dist/collection/components/datetime-picker/time-picker/time-picker.css +1 -0
  176. package/dist/collection/components/datetime-picker/time-picker/time-picker.js +456 -0
  177. package/dist/collection/components/divider/divider.css +1 -0
  178. package/dist/collection/components/divider/divider.js +537 -0
  179. package/dist/collection/components/divider/divider.types.js +1 -0
  180. package/dist/collection/components/dropdown/dropdown.css +1 -0
  181. package/dist/collection/components/dropdown/dropdown.js +939 -0
  182. package/dist/collection/components/dropdown/dropdown.types.js +1 -0
  183. package/dist/collection/components/footer/footer-category/footer-category.css +1 -0
  184. package/dist/collection/components/footer/footer-category/footer-category.js +160 -0
  185. package/dist/collection/components/footer/footer-item/footer-item.css +1 -0
  186. package/dist/collection/components/footer/footer-item/footer-item.js +154 -0
  187. package/dist/collection/components/footer/footer-legal/footer-legal.css +1 -0
  188. package/dist/collection/components/footer/footer-legal/footer-legal.js +75 -0
  189. package/dist/collection/components/footer/footer-logo/footer-logo.css +1 -0
  190. package/dist/collection/components/footer/footer-logo/footer-logo.js +342 -0
  191. package/dist/collection/components/footer/footer-logo/footer-logo.types.js +1 -0
  192. package/dist/collection/components/footer/footer-social/footer-social.css +1 -0
  193. package/dist/collection/components/footer/footer-social/footer-social.js +239 -0
  194. package/dist/collection/components/footer/footer.css +1 -0
  195. package/dist/collection/components/footer/footer.js +245 -0
  196. package/dist/collection/components/footer/footer.types.js +1 -0
  197. package/dist/collection/components/global.types.js +1 -0
  198. package/dist/collection/components/header/header-function/header-function.css +1 -0
  199. package/dist/collection/components/header/header-function/header-function.js +311 -0
  200. package/dist/collection/components/header/header-link/header-link.css +1 -0
  201. package/dist/collection/components/header/header-link/header-link.js +189 -0
  202. package/dist/collection/components/header/header-list/header-list.css +1 -0
  203. package/dist/collection/components/header/header-list/header-list.js +452 -0
  204. package/dist/collection/components/header/header-logo/header-logo.css +1 -0
  205. package/dist/collection/components/header/header-logo/header-logo.js +421 -0
  206. package/dist/collection/components/header/header.css +1 -0
  207. package/dist/collection/components/header/header.js +1131 -0
  208. package/dist/collection/components/header/header.types.js +1 -0
  209. package/dist/collection/components/icon/default-icons-cache.js +233 -0
  210. package/dist/collection/components/icon/icon.css +1 -0
  211. package/dist/collection/components/icon/icon.js +598 -0
  212. package/dist/collection/components/icon/icon.types.js +1 -0
  213. package/dist/collection/components/icon/icon.utils.js +33 -0
  214. package/dist/collection/components/input/input.css +1 -0
  215. package/dist/collection/components/input/input.js +1642 -0
  216. package/dist/collection/components/input/input.types.js +1 -0
  217. package/dist/collection/components/item/item.css +1 -0
  218. package/dist/collection/components/item/item.js +917 -0
  219. package/dist/collection/components/item/item.types.js +1 -0
  220. package/dist/collection/components/link/link.css +1 -0
  221. package/dist/collection/components/link/link.js +699 -0
  222. package/dist/collection/components/list/list.css +1 -0
  223. package/dist/collection/components/list/list.js +728 -0
  224. package/dist/collection/components/loading/loading.css +1 -0
  225. package/dist/collection/components/loading/loading.js +1169 -0
  226. package/dist/collection/components/loading/loading.types.js +1 -0
  227. package/dist/collection/components/magic-button/magic-button.css +1 -0
  228. package/dist/collection/components/magic-button/magic-button.js +238 -0
  229. package/dist/collection/components/menu/menu-group/menu-group.css +1 -0
  230. package/dist/collection/components/menu/menu-group/menu-group.js +77 -0
  231. package/dist/collection/components/menu/menu-header/menu-header.css +1 -0
  232. package/dist/collection/components/menu/menu-header/menu-header.js +161 -0
  233. package/dist/collection/components/menu/menu-info/menu-info.css +1 -0
  234. package/dist/collection/components/menu/menu-info/menu-info.js +94 -0
  235. package/dist/collection/components/menu/menu-item/menu-item.css +1 -0
  236. package/dist/collection/components/menu/menu-item/menu-item.js +306 -0
  237. package/dist/collection/components/menu/menu-item/menu-item.types.js +1 -0
  238. package/dist/collection/components/menu/menu-link/menu-link.css +1 -0
  239. package/dist/collection/components/menu/menu-link/menu-link.js +260 -0
  240. package/dist/collection/components/menu/menu-list/menu-list.css +1 -0
  241. package/dist/collection/components/menu/menu-list/menu-list.js +311 -0
  242. package/dist/collection/components/menu/menu-logo/menu-logo.css +1 -0
  243. package/dist/collection/components/menu/menu-logo/menu-logo.js +230 -0
  244. package/dist/collection/components/menu/menu-social/menu-social.css +1 -0
  245. package/dist/collection/components/menu/menu-social/menu-social.js +263 -0
  246. package/dist/collection/components/menu/menu.css +1 -0
  247. package/dist/collection/components/menu/menu.js +1372 -0
  248. package/dist/collection/components/menu/menu.types.js +1 -0
  249. package/dist/collection/components/menu/menu.utils.js +279 -0
  250. package/dist/collection/components/message/message.css +1 -0
  251. package/dist/collection/components/message/message.js +508 -0
  252. package/dist/collection/components/modal/modal.css +1 -0
  253. package/dist/collection/components/modal/modal.js +842 -0
  254. package/dist/collection/components/modal/modal.types.js +1 -0
  255. package/dist/collection/components/notification/notification-body/notification-body.css +1 -0
  256. package/dist/collection/components/notification/notification-body/notification-body.js +153 -0
  257. package/dist/collection/components/notification/notification-header/notification-header.css +1 -0
  258. package/dist/collection/components/notification/notification-header/notification-header.js +181 -0
  259. package/dist/collection/components/notification/notification-item/notification-item.css +1 -0
  260. package/dist/collection/components/notification/notification-item/notification-item.js +351 -0
  261. package/dist/collection/components/notification/notification-item/notification-item.types.js +1 -0
  262. package/dist/collection/components/notification/notification.css +1 -0
  263. package/dist/collection/components/notification/notification.js +838 -0
  264. package/dist/collection/components/notification/notification.types.js +1 -0
  265. package/dist/collection/components/pagination/pagination.css +1 -0
  266. package/dist/collection/components/pagination/pagination.js +1470 -0
  267. package/dist/collection/components/pagination/pagination.types.js +1 -0
  268. package/dist/collection/components/radio/radio.css +1 -0
  269. package/dist/collection/components/radio/radio.js +847 -0
  270. package/dist/collection/components/radio/radio.types.js +1 -0
  271. package/dist/collection/components/radio-group/radio-group.css +1 -0
  272. package/dist/collection/components/radio-group/radio-group.js +862 -0
  273. package/dist/collection/components/radio-group/radio-group.types.js +1 -0
  274. package/dist/collection/components/scrim/scrim.css +1 -0
  275. package/dist/collection/components/scrim/scrim.js +1825 -0
  276. package/dist/collection/components/scrim/scrim.types.js +1 -0
  277. package/dist/collection/components/scrim/scrim.utils.js +132 -0
  278. package/dist/collection/components/select/select-input/select-input.css +1 -0
  279. package/dist/collection/components/select/select-input/select-input.js +586 -0
  280. package/dist/collection/components/select/select-list/select-list.css +1 -0
  281. package/dist/collection/components/select/select-list/select-list.js +1159 -0
  282. package/dist/collection/components/select/select-option/select-option.css +1 -0
  283. package/dist/collection/components/select/select-option/select-option.js +564 -0
  284. package/dist/collection/components/select/select.constants.js +6 -0
  285. package/dist/collection/components/select/select.css +1 -0
  286. package/dist/collection/components/select/select.js +2692 -0
  287. package/dist/collection/components/select/select.types.js +1 -0
  288. package/dist/collection/components/select/select.utils.js +34 -0
  289. package/dist/collection/components/sign-in/sign-in.css +1 -0
  290. package/dist/collection/components/sign-in/sign-in.js +401 -0
  291. package/dist/collection/components/sign-in/sign-in.types.js +1 -0
  292. package/dist/collection/components/skip-link/skip-link-item/skip-link-item-alias.js +103 -0
  293. package/dist/collection/components/skip-link/skip-link-item/skip-link-item.css +1 -0
  294. package/dist/collection/components/skip-link/skip-link-item/skip-link-item.js +450 -0
  295. package/dist/collection/components/skip-link/skip-link.css +1 -0
  296. package/dist/collection/components/skip-link/skip-link.js +699 -0
  297. package/dist/collection/components/skip-link/skip-link.types.js +1 -0
  298. package/dist/collection/components/slider/slider.css +1 -0
  299. package/dist/collection/components/slider/slider.js +1324 -0
  300. package/dist/collection/components/slider/slider.types.js +1 -0
  301. package/dist/collection/components/step/step-item/step-item.css +1 -0
  302. package/dist/collection/components/step/step-item/step-item.js +604 -0
  303. package/dist/collection/components/step/step-item/step-item.types.js +1 -0
  304. package/dist/collection/components/step/step.css +1 -0
  305. package/dist/collection/components/step/step.js +896 -0
  306. package/dist/collection/components/step/step.types.js +1 -0
  307. package/dist/collection/components/switch/switch.css +1 -0
  308. package/dist/collection/components/switch/switch.js +715 -0
  309. package/dist/collection/components/switch/switch.types.js +1 -0
  310. package/dist/collection/components/tab/tab-item/tab-item.css +1 -0
  311. package/dist/collection/components/tab/tab-item/tab-item.js +425 -0
  312. package/dist/collection/components/tab/tab.css +1 -0
  313. package/dist/collection/components/tab/tab.js +724 -0
  314. package/dist/collection/components/tab/tab.types.js +1 -0
  315. package/dist/collection/components/table/table-body/table-body.css +1 -0
  316. package/dist/collection/components/table/table-body/table-body.js +51 -0
  317. package/dist/collection/components/table/table-cell/table-cell.css +1 -0
  318. package/dist/collection/components/table/table-cell/table-cell.js +373 -0
  319. package/dist/collection/components/table/table-constants.js +171 -0
  320. package/dist/collection/components/table/table-header/table-header.css +1 -0
  321. package/dist/collection/components/table/table-header/table-header.js +51 -0
  322. package/dist/collection/components/table/table-header-cell/table-header-cell.css +1 -0
  323. package/dist/collection/components/table/table-header-cell/table-header-cell.js +402 -0
  324. package/dist/collection/components/table/table-row/table-row.css +1 -0
  325. package/dist/collection/components/table/table-row/table-row.js +261 -0
  326. package/dist/collection/components/table/table-tokens.js +50 -0
  327. package/dist/collection/components/table/table-types.js +1 -0
  328. package/dist/collection/components/table/table-utils.js +44 -0
  329. package/dist/collection/components/table/table.css +1 -0
  330. package/dist/collection/components/table/table.js +1030 -0
  331. package/dist/collection/components/tag/tag.css +1 -0
  332. package/dist/collection/components/tag/tag.js +1152 -0
  333. package/dist/collection/components/tag/tag.types.js +1 -0
  334. package/dist/collection/components/textarea/textarea.css +1 -0
  335. package/dist/collection/components/textarea/textarea.js +985 -0
  336. package/dist/collection/components/textarea/textarea.types.js +1 -0
  337. package/dist/collection/components/tooltip/tooltip.css +1 -0
  338. package/dist/collection/components/tooltip/tooltip.js +1024 -0
  339. package/dist/collection/components/tooltip/tooltip.types.js +1 -0
  340. package/dist/collection/components/upload/upload.css +1 -0
  341. package/dist/collection/components/upload/upload.js +1314 -0
  342. package/dist/collection/components/upload/upload.types.js +1 -0
  343. package/dist/collection/components/wizard/wizard-panel/wizard-panel.css +1 -0
  344. package/dist/collection/components/wizard/wizard-panel/wizard-panel.js +167 -0
  345. package/dist/collection/components/wizard/wizard.css +1 -0
  346. package/dist/collection/components/wizard/wizard.js +1228 -0
  347. package/dist/collection/index.js +14 -0
  348. package/dist/collection/pages/components/cookiebar/index.js +26 -0
  349. package/dist/collection/pages/components/link/index.js +29 -0
  350. package/dist/collection/pages/components/pagination/index.js +12 -0
  351. package/dist/collection/pages/components/slider/index.js +18 -0
  352. package/dist/collection/pages/scripts/code-editor.js +101 -0
  353. package/dist/collection/pages/scripts/component-controls.js +600 -0
  354. package/dist/collection/pages/scripts/dev-event-console.js +47 -0
  355. package/dist/collection/pages/scripts/menu.js +192 -0
  356. package/dist/collection/pages/scripts/pageLoader.js +1422 -0
  357. package/dist/collection/shared/utils/assetsPath.js +75 -0
  358. package/dist/collection/shared/utils/breakpoint-observer.js +139 -0
  359. package/dist/collection/shared/utils/clamp.js +21 -0
  360. package/dist/collection/shared/utils/css-variables.js +12 -0
  361. package/dist/collection/shared/utils/cssVariables.js +37 -0
  362. package/dist/collection/shared/utils/date.js +405 -0
  363. package/dist/collection/shared/utils/debounce.js +39 -0
  364. package/dist/collection/shared/utils/event.js +55 -0
  365. package/dist/collection/shared/utils/floating-surface-dismiss.js +59 -0
  366. package/dist/collection/shared/utils/floating-ui.js +131 -0
  367. package/dist/collection/shared/utils/focus.js +24 -0
  368. package/dist/collection/shared/utils/form.js +82 -0
  369. package/dist/collection/shared/utils/format-bytes.js +20 -0
  370. package/dist/collection/shared/utils/getNextElement.js +30 -0
  371. package/dist/collection/shared/utils/getRandom.js +27 -0
  372. package/dist/collection/shared/utils/helpers.js +31 -0
  373. package/dist/collection/shared/utils/id.js +16 -0
  374. package/dist/collection/shared/utils/index.js +60 -0
  375. package/dist/collection/shared/utils/interfaces.js +1 -0
  376. package/dist/collection/shared/utils/isClient.js +14 -0
  377. package/dist/collection/shared/utils/isDefined.js +19 -0
  378. package/dist/collection/shared/utils/isEmpty.js +30 -0
  379. package/dist/collection/shared/utils/isHTMLElement.js +16 -0
  380. package/dist/collection/shared/utils/isNil.js +15 -0
  381. package/dist/collection/shared/utils/isString.js +20 -0
  382. package/dist/collection/shared/utils/native-dialog.js +44 -0
  383. package/dist/collection/shared/utils/navigation.js +21 -0
  384. package/dist/collection/shared/utils/parts.js +15 -0
  385. package/dist/collection/shared/utils/prop-warning.js +7 -0
  386. package/dist/collection/shared/utils/props.js +37 -0
  387. package/dist/collection/shared/utils/raf-batcher.js +51 -0
  388. package/dist/collection/shared/utils/scrollLock.js +141 -0
  389. package/dist/collection/shared/utils/setRafTimeout.js +38 -0
  390. package/dist/collection/shared/utils/slot.js +113 -0
  391. package/dist/collection/shared/utils/ssr-date.js +33 -0
  392. package/dist/collection/shared/utils/stringToArray.js +29 -0
  393. package/dist/collection/shared/utils/swipe.js +342 -0
  394. package/dist/collection/shared/utils/transition.js +127 -0
  395. package/dist/collection/shared/utils/types.js +1 -0
  396. package/dist/collection/shared/utils/validator.js +51 -0
  397. package/dist/collection/value-accessors/angular-value-accessor-config.js +41 -0
  398. package/dist/collection/value-accessors/index.js +6 -0
  399. package/dist/collection/value-accessors/vue-model-config.js +43 -0
  400. package/dist/components/br-avatar.d.ts +11 -0
  401. package/dist/components/br-avatar.js +5 -0
  402. package/dist/components/br-breadcrumb-item.d.ts +11 -0
  403. package/dist/components/br-breadcrumb-item.js +5 -0
  404. package/dist/components/br-breadcrumb.d.ts +11 -0
  405. package/dist/components/br-breadcrumb.js +5 -0
  406. package/dist/components/br-button.d.ts +11 -0
  407. package/dist/components/br-button.js +5 -0
  408. package/dist/components/br-card.d.ts +11 -0
  409. package/dist/components/br-card.js +5 -0
  410. package/dist/components/br-carousel-page.d.ts +11 -0
  411. package/dist/components/br-carousel-page.js +5 -0
  412. package/dist/components/br-carousel.d.ts +11 -0
  413. package/dist/components/br-carousel.js +5 -0
  414. package/dist/components/br-checkbox-group.d.ts +11 -0
  415. package/dist/components/br-checkbox-group.js +5 -0
  416. package/dist/components/br-checkbox.d.ts +11 -0
  417. package/dist/components/br-checkbox.js +5 -0
  418. package/dist/components/br-checkgroup.d.ts +11 -0
  419. package/dist/components/br-checkgroup.js +5 -0
  420. package/dist/components/br-collapse.d.ts +11 -0
  421. package/dist/components/br-collapse.js +5 -0
  422. package/dist/components/br-cookiebar-cookie.d.ts +11 -0
  423. package/dist/components/br-cookiebar-cookie.js +5 -0
  424. package/dist/components/br-cookiebar-group.d.ts +11 -0
  425. package/dist/components/br-cookiebar-group.js +5 -0
  426. package/dist/components/br-cookiebar-header.d.ts +11 -0
  427. package/dist/components/br-cookiebar-header.js +5 -0
  428. package/dist/components/br-cookiebar-link.d.ts +11 -0
  429. package/dist/components/br-cookiebar-link.js +5 -0
  430. package/dist/components/br-cookiebar-note-group.d.ts +11 -0
  431. package/dist/components/br-cookiebar-note-group.js +5 -0
  432. package/dist/components/br-cookiebar-note.d.ts +11 -0
  433. package/dist/components/br-cookiebar-note.js +5 -0
  434. package/dist/components/br-cookiebar.d.ts +11 -0
  435. package/dist/components/br-cookiebar.js +5 -0
  436. package/dist/components/br-crumb.d.ts +11 -0
  437. package/dist/components/br-crumb.js +5 -0
  438. package/dist/components/br-date-picker.d.ts +11 -0
  439. package/dist/components/br-date-picker.js +5 -0
  440. package/dist/components/br-datetime-input.d.ts +11 -0
  441. package/dist/components/br-datetime-input.js +5 -0
  442. package/dist/components/br-datetime-picker.d.ts +11 -0
  443. package/dist/components/br-datetime-picker.js +5 -0
  444. package/dist/components/br-divider.d.ts +11 -0
  445. package/dist/components/br-divider.js +5 -0
  446. package/dist/components/br-dropdown.d.ts +11 -0
  447. package/dist/components/br-dropdown.js +5 -0
  448. package/dist/components/br-footer-category.d.ts +11 -0
  449. package/dist/components/br-footer-category.js +5 -0
  450. package/dist/components/br-footer-item.d.ts +11 -0
  451. package/dist/components/br-footer-item.js +5 -0
  452. package/dist/components/br-footer-legal.d.ts +11 -0
  453. package/dist/components/br-footer-legal.js +5 -0
  454. package/dist/components/br-footer-logo.d.ts +11 -0
  455. package/dist/components/br-footer-logo.js +5 -0
  456. package/dist/components/br-footer-social.d.ts +11 -0
  457. package/dist/components/br-footer-social.js +5 -0
  458. package/dist/components/br-footer.d.ts +11 -0
  459. package/dist/components/br-footer.js +5 -0
  460. package/dist/components/br-header-function.d.ts +11 -0
  461. package/dist/components/br-header-function.js +5 -0
  462. package/dist/components/br-header-link.d.ts +11 -0
  463. package/dist/components/br-header-link.js +5 -0
  464. package/dist/components/br-header-list.d.ts +11 -0
  465. package/dist/components/br-header-list.js +5 -0
  466. package/dist/components/br-header-logo.d.ts +11 -0
  467. package/dist/components/br-header-logo.js +5 -0
  468. package/dist/components/br-header.d.ts +11 -0
  469. package/dist/components/br-header.js +5 -0
  470. package/dist/components/br-icon.d.ts +11 -0
  471. package/dist/components/br-icon.js +5 -0
  472. package/dist/components/br-input.d.ts +11 -0
  473. package/dist/components/br-input.js +5 -0
  474. package/dist/components/br-item.d.ts +11 -0
  475. package/dist/components/br-item.js +5 -0
  476. package/dist/components/br-link.d.ts +11 -0
  477. package/dist/components/br-link.js +5 -0
  478. package/dist/components/br-list.d.ts +11 -0
  479. package/dist/components/br-list.js +5 -0
  480. package/dist/components/br-loading.d.ts +11 -0
  481. package/dist/components/br-loading.js +5 -0
  482. package/dist/components/br-magic-button.d.ts +11 -0
  483. package/dist/components/br-magic-button.js +5 -0
  484. package/dist/components/br-menu-group.d.ts +11 -0
  485. package/dist/components/br-menu-group.js +5 -0
  486. package/dist/components/br-menu-header.d.ts +11 -0
  487. package/dist/components/br-menu-header.js +5 -0
  488. package/dist/components/br-menu-info.d.ts +11 -0
  489. package/dist/components/br-menu-info.js +5 -0
  490. package/dist/components/br-menu-item.d.ts +11 -0
  491. package/dist/components/br-menu-item.js +5 -0
  492. package/dist/components/br-menu-link.d.ts +11 -0
  493. package/dist/components/br-menu-link.js +5 -0
  494. package/dist/components/br-menu-list.d.ts +11 -0
  495. package/dist/components/br-menu-list.js +5 -0
  496. package/dist/components/br-menu-logo.d.ts +11 -0
  497. package/dist/components/br-menu-logo.js +5 -0
  498. package/dist/components/br-menu-social.d.ts +11 -0
  499. package/dist/components/br-menu-social.js +5 -0
  500. package/dist/components/br-menu.d.ts +11 -0
  501. package/dist/components/br-menu.js +5 -0
  502. package/dist/components/br-message.d.ts +11 -0
  503. package/dist/components/br-message.js +5 -0
  504. package/dist/components/br-modal.d.ts +11 -0
  505. package/dist/components/br-modal.js +5 -0
  506. package/dist/components/br-notification-body.d.ts +11 -0
  507. package/dist/components/br-notification-body.js +5 -0
  508. package/dist/components/br-notification-header.d.ts +11 -0
  509. package/dist/components/br-notification-header.js +5 -0
  510. package/dist/components/br-notification-item.d.ts +11 -0
  511. package/dist/components/br-notification-item.js +5 -0
  512. package/dist/components/br-notification.d.ts +11 -0
  513. package/dist/components/br-notification.js +5 -0
  514. package/dist/components/br-pagination.d.ts +11 -0
  515. package/dist/components/br-pagination.js +5 -0
  516. package/dist/components/br-radio-group.d.ts +11 -0
  517. package/dist/components/br-radio-group.js +5 -0
  518. package/dist/components/br-radio.d.ts +11 -0
  519. package/dist/components/br-radio.js +5 -0
  520. package/dist/components/br-scrim.d.ts +11 -0
  521. package/dist/components/br-scrim.js +5 -0
  522. package/dist/components/br-select-input.d.ts +11 -0
  523. package/dist/components/br-select-input.js +5 -0
  524. package/dist/components/br-select-list.d.ts +11 -0
  525. package/dist/components/br-select-list.js +5 -0
  526. package/dist/components/br-select-option.d.ts +11 -0
  527. package/dist/components/br-select-option.js +5 -0
  528. package/dist/components/br-select.d.ts +11 -0
  529. package/dist/components/br-select.js +5 -0
  530. package/dist/components/br-sign-in.d.ts +11 -0
  531. package/dist/components/br-sign-in.js +5 -0
  532. package/dist/components/br-skip-link-item.d.ts +11 -0
  533. package/dist/components/br-skip-link-item.js +5 -0
  534. package/dist/components/br-skip-link.d.ts +11 -0
  535. package/dist/components/br-skip-link.js +5 -0
  536. package/dist/components/br-skiplink-item.d.ts +11 -0
  537. package/dist/components/br-skiplink-item.js +5 -0
  538. package/dist/components/br-slider.d.ts +11 -0
  539. package/dist/components/br-slider.js +5 -0
  540. package/dist/components/br-step-item.d.ts +11 -0
  541. package/dist/components/br-step-item.js +5 -0
  542. package/dist/components/br-step.d.ts +11 -0
  543. package/dist/components/br-step.js +5 -0
  544. package/dist/components/br-switch.d.ts +11 -0
  545. package/dist/components/br-switch.js +5 -0
  546. package/dist/components/br-tab-item.d.ts +11 -0
  547. package/dist/components/br-tab-item.js +5 -0
  548. package/dist/components/br-tab.d.ts +11 -0
  549. package/dist/components/br-tab.js +5 -0
  550. package/dist/components/br-table-body.d.ts +11 -0
  551. package/dist/components/br-table-body.js +5 -0
  552. package/dist/components/br-table-cell.d.ts +11 -0
  553. package/dist/components/br-table-cell.js +5 -0
  554. package/dist/components/br-table-header-cell.d.ts +11 -0
  555. package/dist/components/br-table-header-cell.js +5 -0
  556. package/dist/components/br-table-header.d.ts +11 -0
  557. package/dist/components/br-table-header.js +5 -0
  558. package/dist/components/br-table-row.d.ts +11 -0
  559. package/dist/components/br-table-row.js +5 -0
  560. package/dist/components/br-table.d.ts +11 -0
  561. package/dist/components/br-table.js +5 -0
  562. package/dist/components/br-tag.d.ts +11 -0
  563. package/dist/components/br-tag.js +5 -0
  564. package/dist/components/br-textarea.d.ts +11 -0
  565. package/dist/components/br-textarea.js +5 -0
  566. package/dist/components/br-time-picker.d.ts +11 -0
  567. package/dist/components/br-time-picker.js +5 -0
  568. package/dist/components/br-tooltip.d.ts +11 -0
  569. package/dist/components/br-tooltip.js +5 -0
  570. package/dist/components/br-upload.d.ts +11 -0
  571. package/dist/components/br-upload.js +5 -0
  572. package/dist/components/br-wizard-panel.d.ts +11 -0
  573. package/dist/components/br-wizard-panel.js +5 -0
  574. package/dist/components/br-wizard.d.ts +11 -0
  575. package/dist/components/br-wizard.js +5 -0
  576. package/dist/components/index.d.ts +213 -0
  577. package/dist/components/index.js +5 -0
  578. package/dist/components/p-34Jfn-U-.js +5 -0
  579. package/dist/components/p-5z6jgH1D.js +5 -0
  580. package/dist/components/p-6OdfnwnK.js +5 -0
  581. package/dist/components/p-9S9bgUT0.js +5 -0
  582. package/dist/components/p-B-qLmYZC.js +5 -0
  583. package/dist/components/p-B55qsau4.js +5 -0
  584. package/dist/components/p-B7Amgxkp.js +5 -0
  585. package/dist/components/p-BC7f6MK8.js +5 -0
  586. package/dist/components/p-BKuMQJrQ.js +5 -0
  587. package/dist/components/p-BPJpHGOW.js +5 -0
  588. package/dist/components/p-BWXfdbQH.js +5 -0
  589. package/dist/components/p-Bb-nLtTG.js +5 -0
  590. package/dist/components/p-BeE7R9nu.js +5 -0
  591. package/dist/components/p-BkS6ujyf.js +5 -0
  592. package/dist/components/p-Bo0QYHJO.js +5 -0
  593. package/dist/components/p-C1yRmdso.js +5 -0
  594. package/dist/components/p-C2i2c_io.js +5 -0
  595. package/dist/components/p-C7v0lVlX.js +5 -0
  596. package/dist/components/p-CMBsvswx.js +5 -0
  597. package/dist/components/p-CRrimdz6.js +5 -0
  598. package/dist/components/p-CWORw84-.js +5 -0
  599. package/dist/components/p-CXMwM9m4.js +5 -0
  600. package/dist/components/p-CdDwqbBv.js +5 -0
  601. package/dist/components/p-CvUMXJCl.js +5 -0
  602. package/dist/components/p-D3usVJE2.js +16 -0
  603. package/dist/components/p-D6zroLx5.js +5 -0
  604. package/dist/components/p-DA5GS53D.js +5 -0
  605. package/dist/components/p-DBP6K_aq.js +5 -0
  606. package/dist/components/p-DBmwzG9E.js +5 -0
  607. package/dist/components/p-DCrVo-8T.js +5 -0
  608. package/dist/components/p-DFUKDNck.js +5 -0
  609. package/dist/components/p-DHicj0By.js +5 -0
  610. package/dist/components/p-DIK54tTj.js +5 -0
  611. package/dist/components/p-DQRSHR-D.js +5 -0
  612. package/dist/components/p-DRVMm1Py.js +5 -0
  613. package/dist/components/p-DWPmUV72.js +5 -0
  614. package/dist/components/p-DXjQyH6s.js +5 -0
  615. package/dist/components/p-DYA74R1r.js +5 -0
  616. package/dist/components/p-DmCxdB9P.js +5 -0
  617. package/dist/components/p-Dmfk7eEe.js +5 -0
  618. package/dist/components/p-Dp0xy_3n.js +5 -0
  619. package/dist/components/p-DxZJrIyL.js +5 -0
  620. package/dist/components/p-JAkkThgf.js +5 -0
  621. package/dist/components/p-Ud-WB0hx.js +5 -0
  622. package/dist/components/p-bhULC15U.js +5 -0
  623. package/dist/components/p-cF3ia5e9.js +5 -0
  624. package/dist/components/p-fpMNttbg.js +5 -0
  625. package/dist/components/p-gvnfuTjd.js +5 -0
  626. package/dist/components/p-qYONSNcf.js +5 -0
  627. package/dist/components/p-qhhHGJY1.js +5 -0
  628. package/dist/components/p-ttI0nvv_.js +5 -0
  629. package/dist/components/p-ukNmfGNP.js +5 -0
  630. package/dist/components/p-xa8e1kSW.js +5 -0
  631. package/dist/esm/app-globals-DVjNHTTs.js +7 -0
  632. package/dist/esm/br-avatar.entry.js +246 -0
  633. package/dist/esm/br-breadcrumb-item.entry.js +43 -0
  634. package/dist/esm/br-breadcrumb.entry.js +441 -0
  635. package/dist/esm/br-button_2.entry.js +277 -0
  636. package/dist/esm/br-card.entry.js +109 -0
  637. package/dist/esm/br-carousel-page.entry.js +78 -0
  638. package/dist/esm/br-carousel.entry.js +563 -0
  639. package/dist/esm/br-checkbox-group.entry.js +116 -0
  640. package/dist/esm/br-checkbox.entry.js +286 -0
  641. package/dist/esm/br-checkgroup.entry.js +18 -0
  642. package/dist/esm/br-collapse_2.entry.js +680 -0
  643. package/dist/esm/br-cookiebar-cookie.entry.js +81 -0
  644. package/dist/esm/br-cookiebar-group.entry.js +307 -0
  645. package/dist/esm/br-cookiebar-header.entry.js +37 -0
  646. package/dist/esm/br-cookiebar-link.entry.js +53 -0
  647. package/dist/esm/br-cookiebar-note-group.entry.js +68 -0
  648. package/dist/esm/br-cookiebar-note.entry.js +23 -0
  649. package/dist/esm/br-cookiebar.entry.js +756 -0
  650. package/dist/esm/br-crumb.entry.js +49 -0
  651. package/dist/esm/br-date-picker_3.entry.js +2443 -0
  652. package/dist/esm/br-datetime-picker.entry.js +1884 -0
  653. package/dist/esm/br-divider.entry.js +223 -0
  654. package/dist/esm/br-dropdown_2.entry.js +1997 -0
  655. package/dist/esm/br-footer-category.entry.js +100 -0
  656. package/dist/esm/br-footer-item.entry.js +50 -0
  657. package/dist/esm/br-footer-legal.entry.js +39 -0
  658. package/dist/esm/br-footer-logo.entry.js +102 -0
  659. package/dist/esm/br-footer-social.entry.js +69 -0
  660. package/dist/esm/br-footer.entry.js +90 -0
  661. package/dist/esm/br-header-function.entry.js +140 -0
  662. package/dist/esm/br-header-link.entry.js +58 -0
  663. package/dist/esm/br-header-list.entry.js +277 -0
  664. package/dist/esm/br-header-logo.entry.js +176 -0
  665. package/dist/esm/br-header.entry.js +640 -0
  666. package/dist/esm/br-icon.entry.js +483 -0
  667. package/dist/esm/br-input.entry.js +597 -0
  668. package/dist/esm/br-item.entry.js +365 -0
  669. package/dist/esm/br-link.entry.js +131 -0
  670. package/dist/esm/br-loading.entry.js +503 -0
  671. package/dist/esm/br-magic-button.entry.js +91 -0
  672. package/dist/esm/br-menu-group.entry.js +21 -0
  673. package/dist/esm/br-menu-header.entry.js +45 -0
  674. package/dist/esm/br-menu-info.entry.js +36 -0
  675. package/dist/esm/br-menu-item.entry.js +77 -0
  676. package/dist/esm/br-menu-link.entry.js +54 -0
  677. package/dist/esm/br-menu-list.entry.js +147 -0
  678. package/dist/esm/br-menu-logo.entry.js +73 -0
  679. package/dist/esm/br-menu-social.entry.js +63 -0
  680. package/dist/esm/br-menu.entry.js +991 -0
  681. package/dist/esm/br-modal.entry.js +494 -0
  682. package/dist/esm/br-notification-body.entry.js +69 -0
  683. package/dist/esm/br-notification-header.entry.js +46 -0
  684. package/dist/esm/br-notification-item.entry.js +108 -0
  685. package/dist/esm/br-notification.entry.js +332 -0
  686. package/dist/esm/br-pagination.entry.js +882 -0
  687. package/dist/esm/br-radio-group.entry.js +426 -0
  688. package/dist/esm/br-radio.entry.js +355 -0
  689. package/dist/esm/br-scrim.entry.js +1334 -0
  690. package/dist/esm/br-select-input_3.entry.js +984 -0
  691. package/dist/esm/br-sign-in.entry.js +124 -0
  692. package/dist/esm/br-skip-link-item.entry.js +18 -0
  693. package/dist/esm/br-skip-link.entry.js +360 -0
  694. package/dist/esm/br-skiplink-item.entry.js +190 -0
  695. package/dist/esm/br-slider.entry.js +685 -0
  696. package/dist/esm/br-step_2.entry.js +625 -0
  697. package/dist/esm/br-switch.entry.js +243 -0
  698. package/dist/esm/br-tab-item.entry.js +183 -0
  699. package/dist/esm/br-tab.entry.js +395 -0
  700. package/dist/esm/br-table-body.entry.js +35 -0
  701. package/dist/esm/br-table-cell.entry.js +182 -0
  702. package/dist/esm/br-table-header-cell.entry.js +171 -0
  703. package/dist/esm/br-table-header.entry.js +35 -0
  704. package/dist/esm/br-table-row.entry.js +79 -0
  705. package/dist/esm/br-table.entry.js +678 -0
  706. package/dist/esm/br-tag.entry.js +491 -0
  707. package/dist/esm/br-textarea.entry.js +304 -0
  708. package/dist/esm/br-tooltip.entry.js +625 -0
  709. package/dist/esm/br-upload.entry.js +579 -0
  710. package/dist/esm/br-wizard-panel.entry.js +52 -0
  711. package/dist/esm/br-wizard.entry.js +706 -0
  712. package/dist/esm/breakpoint-observer-DBmwzG9E.js +141 -0
  713. package/dist/esm/clamp-gvnfuTjd.js +23 -0
  714. package/dist/esm/cookiebar.utils-DYA74R1r.js +16 -0
  715. package/dist/esm/datetime-picker-constants-Bfm58jO6.js +3798 -0
  716. package/dist/esm/event-DFN_so7I.js +48 -0
  717. package/dist/esm/floating-surface-dismiss-BWXfdbQH.js +61 -0
  718. package/dist/esm/floating-ui-BavFwMnx.js +134 -0
  719. package/dist/esm/floating-ui.dom-DIK54tTj.js +1707 -0
  720. package/dist/esm/focus-DxZJrIyL.js +26 -0
  721. package/dist/esm/getNextElement-9S9bgUT0.js +28 -0
  722. package/dist/esm/iconify-icon-D3usVJE2.js +2303 -0
  723. package/dist/esm/id-BkS6ujyf.js +18 -0
  724. package/dist/esm/index-Bo-2igoO.js +671 -0
  725. package/dist/esm/index-C2RBydfd.js +3258 -0
  726. package/dist/esm/index.js +6 -0
  727. package/dist/esm/isNil-B-qLmYZC.js +17 -0
  728. package/dist/esm/isValid-DIUZX1qS.js +3684 -0
  729. package/dist/esm/loader.js +15 -0
  730. package/dist/esm/native-dialog-B55qsau4.js +46 -0
  731. package/dist/esm/navigation-bhULC15U.js +23 -0
  732. package/dist/esm/parts-Bb5vVlCC.js +17 -0
  733. package/dist/esm/props-DRVMm1Py.js +22 -0
  734. package/dist/esm/raf-batcher-cF3ia5e9.js +53 -0
  735. package/dist/esm/slot-BIG-yees.js +44 -0
  736. package/dist/esm/swipe-Dmfk7eEe.js +343 -0
  737. package/dist/esm/table-constants-CXMwM9m4.js +170 -0
  738. package/dist/esm/validator-D3tVP32U.js +113 -0
  739. package/dist/esm/webcomponents.js +46 -0
  740. package/dist/hydrate/index.d.ts +287 -0
  741. package/dist/hydrate/index.js +67516 -0
  742. package/dist/hydrate/index.mjs +67506 -0
  743. package/dist/hydrate/package.json +12 -0
  744. package/dist/index.cjs.js +1 -0
  745. package/dist/index.js +1 -0
  746. package/dist/loader/cdn.js +5 -0
  747. package/dist/loader/index.cjs.js +5 -0
  748. package/dist/loader/index.d.ts +24 -0
  749. package/dist/loader/index.es2017.js +5 -0
  750. package/dist/loader/index.js +6 -0
  751. package/dist/types/components/item/item.d.ts +1 -0
  752. package/dist/types/components/select/select-list/select-list.d.ts +1 -0
  753. package/dist/types/components/select/select-option/select-option.d.ts +1 -0
  754. package/dist/types/components/select/select.d.ts +14 -0
  755. package/dist/types/components/select/select.types.d.ts +2 -0
  756. package/dist/types/components/select/select.utils.d.ts +13 -0
  757. package/dist/webcomponents/index.esm.js +5 -0
  758. package/dist/webcomponents/p-0196804a.entry.js +5 -0
  759. package/dist/webcomponents/p-0410186a.entry.js +5 -0
  760. package/dist/webcomponents/p-0415ef22.entry.js +5 -0
  761. package/dist/webcomponents/p-0777c7b1.entry.js +5 -0
  762. package/dist/webcomponents/p-0caa4d12.entry.js +5 -0
  763. package/dist/webcomponents/p-0d4f718d.entry.js +5 -0
  764. package/dist/webcomponents/p-0e84c9e8.entry.js +5 -0
  765. package/dist/webcomponents/p-12286e73.entry.js +5 -0
  766. package/dist/webcomponents/p-147ac8d3.entry.js +5 -0
  767. package/dist/webcomponents/p-1580beee.entry.js +5 -0
  768. package/dist/webcomponents/p-18ee6175.entry.js +5 -0
  769. package/dist/webcomponents/p-1bca4499.entry.js +5 -0
  770. package/dist/webcomponents/p-1c303a4e.entry.js +5 -0
  771. package/dist/webcomponents/p-1d6b0b6f.entry.js +5 -0
  772. package/dist/webcomponents/p-1d8cb8fd.entry.js +5 -0
  773. package/dist/webcomponents/p-224daaac.entry.js +5 -0
  774. package/dist/webcomponents/p-28426d2a.entry.js +5 -0
  775. package/dist/webcomponents/p-2abd2da0.entry.js +5 -0
  776. package/dist/webcomponents/p-2fdc51ae.entry.js +5 -0
  777. package/dist/webcomponents/p-30c428b6.entry.js +5 -0
  778. package/dist/webcomponents/p-36bbea4e.entry.js +5 -0
  779. package/dist/webcomponents/p-3907ebfa.entry.js +5 -0
  780. package/dist/webcomponents/p-39a16f9d.entry.js +5 -0
  781. package/dist/webcomponents/p-3ebbd2f5.entry.js +5 -0
  782. package/dist/webcomponents/p-3ef7eac8.entry.js +5 -0
  783. package/dist/webcomponents/p-45356e9a.entry.js +5 -0
  784. package/dist/webcomponents/p-46513db4.entry.js +5 -0
  785. package/dist/webcomponents/p-4c13221a.entry.js +5 -0
  786. package/dist/webcomponents/p-51ce2c31.entry.js +5 -0
  787. package/dist/webcomponents/p-52df61cb.entry.js +5 -0
  788. package/dist/webcomponents/p-569134cf.entry.js +5 -0
  789. package/dist/webcomponents/p-5ce7db4a.entry.js +5 -0
  790. package/dist/webcomponents/p-5f373708.entry.js +5 -0
  791. package/dist/webcomponents/p-5f6afb79.entry.js +5 -0
  792. package/dist/webcomponents/p-5fc7ba4c.entry.js +5 -0
  793. package/dist/webcomponents/p-66006312.entry.js +5 -0
  794. package/dist/webcomponents/p-66b13fd9.entry.js +5 -0
  795. package/dist/webcomponents/p-6OdfnwnK.js +5 -0
  796. package/dist/webcomponents/p-750799b7.entry.js +5 -0
  797. package/dist/webcomponents/p-756ff2ad.entry.js +5 -0
  798. package/dist/webcomponents/p-765bfe27.entry.js +5 -0
  799. package/dist/webcomponents/p-7ab96c11.entry.js +5 -0
  800. package/dist/webcomponents/p-7c2ff8b4.entry.js +5 -0
  801. package/dist/webcomponents/p-7f7506f0.entry.js +5 -0
  802. package/dist/webcomponents/p-7fb03a49.entry.js +5 -0
  803. package/dist/webcomponents/p-82200563.entry.js +5 -0
  804. package/dist/webcomponents/p-83ff4579.entry.js +5 -0
  805. package/dist/webcomponents/p-85f8063b.entry.js +5 -0
  806. package/dist/webcomponents/p-8b558233.entry.js +5 -0
  807. package/dist/webcomponents/p-8e6c2767.entry.js +5 -0
  808. package/dist/webcomponents/p-8e819355.entry.js +5 -0
  809. package/dist/webcomponents/p-92a9b9c4.entry.js +5 -0
  810. package/dist/webcomponents/p-966ad32f.entry.js +5 -0
  811. package/dist/webcomponents/p-9679d230.entry.js +5 -0
  812. package/dist/webcomponents/p-96dd663b.entry.js +5 -0
  813. package/dist/webcomponents/p-98843fa3.entry.js +5 -0
  814. package/dist/webcomponents/p-9S9bgUT0.js +5 -0
  815. package/dist/webcomponents/p-9a375eff.entry.js +5 -0
  816. package/dist/webcomponents/p-9b358cff.entry.js +5 -0
  817. package/dist/webcomponents/p-9f7558c7.entry.js +5 -0
  818. package/dist/webcomponents/p-B-qLmYZC.js +5 -0
  819. package/dist/webcomponents/p-B55qsau4.js +5 -0
  820. package/dist/webcomponents/p-BIG-yees.js +5 -0
  821. package/dist/webcomponents/p-BWXfdbQH.js +5 -0
  822. package/dist/webcomponents/p-Bb5vVlCC.js +5 -0
  823. package/dist/webcomponents/p-Bfm58jO6.js +5 -0
  824. package/dist/webcomponents/p-BhMVJQ4-.js +5 -0
  825. package/dist/webcomponents/p-BkS6ujyf.js +5 -0
  826. package/dist/webcomponents/p-C2RBydfd.js +6 -0
  827. package/dist/webcomponents/p-CO5cOQQU.js +5 -0
  828. package/dist/webcomponents/p-CXMwM9m4.js +5 -0
  829. package/dist/webcomponents/p-D3tVP32U.js +5 -0
  830. package/dist/webcomponents/p-D3usVJE2.js +16 -0
  831. package/dist/webcomponents/p-DBmwzG9E.js +5 -0
  832. package/dist/webcomponents/p-DFN_so7I.js +5 -0
  833. package/dist/webcomponents/p-DIK54tTj.js +5 -0
  834. package/dist/webcomponents/p-DRVMm1Py.js +5 -0
  835. package/dist/webcomponents/p-DVjNHTTs.js +5 -0
  836. package/dist/webcomponents/p-DYA74R1r.js +5 -0
  837. package/dist/webcomponents/p-Dmfk7eEe.js +5 -0
  838. package/dist/webcomponents/p-DxZJrIyL.js +5 -0
  839. package/dist/webcomponents/p-a382e115.entry.js +5 -0
  840. package/dist/webcomponents/p-a4ae72e3.entry.js +5 -0
  841. package/dist/webcomponents/p-a994c190.entry.js +5 -0
  842. package/dist/webcomponents/p-a9ff7c25.entry.js +5 -0
  843. package/dist/webcomponents/p-bhULC15U.js +5 -0
  844. package/dist/webcomponents/p-c0b0f531.entry.js +5 -0
  845. package/dist/webcomponents/p-c211af17.entry.js +5 -0
  846. package/dist/webcomponents/p-c492d926.entry.js +5 -0
  847. package/dist/webcomponents/p-c4cfe599.entry.js +5 -0
  848. package/dist/webcomponents/p-c846e784.entry.js +5 -0
  849. package/dist/webcomponents/p-c949d993.entry.js +5 -0
  850. package/dist/webcomponents/p-cF3ia5e9.js +5 -0
  851. package/dist/webcomponents/p-d1e899cd.entry.js +5 -0
  852. package/dist/webcomponents/p-d38d82cc.entry.js +5 -0
  853. package/dist/webcomponents/p-e0ce536a.entry.js +5 -0
  854. package/dist/webcomponents/p-e1331288.entry.js +5 -0
  855. package/dist/webcomponents/p-e360a463.entry.js +5 -0
  856. package/dist/webcomponents/p-f078f972.entry.js +5 -0
  857. package/dist/webcomponents/p-f26038e2.entry.js +5 -0
  858. package/dist/webcomponents/p-f303f6b3.entry.js +5 -0
  859. package/dist/webcomponents/p-f6318e94.entry.js +5 -0
  860. package/dist/webcomponents/p-f85ee01c.entry.js +5 -0
  861. package/dist/webcomponents/p-fcd4ae48.entry.js +5 -0
  862. package/dist/webcomponents/p-ffe0241e.entry.js +5 -0
  863. package/dist/webcomponents/p-gvnfuTjd.js +5 -0
  864. package/dist/webcomponents/webcomponents.esm.js +5 -0
  865. package/package.json +3 -7
  866. package/cem/.gitkeep +0 -0
@@ -0,0 +1,1884 @@
1
+ /*!
2
+ * Construído por SERPRO
3
+ * © https://serpro.gov.br/ - MIT License.
4
+ */
5
+ import { r as registerInstance, c as createEvent, h, F as Fragment, H as Host, g as getElement } from './index-C2RBydfd.js';
6
+ import { r as requireParse, p as parseExports, i as isValidExports, t as toDateExports, w as warnInvalidPropValue, a as resolveSsrLocalDate, s as setExports, e as eachDayOfIntervalExports, b as isSameDayExports } from './isValid-DIUZX1qS.js';
7
+ import { d as dispatchNativeFormEvent } from './event-DFN_so7I.js';
8
+ import { r as resolveFormValidator, a as runFormValidator, g as getFormValidationState, c as setFormValidity, i as isFormControlDisabled } from './validator-D3tVP32U.js';
9
+ import { a as hasAssignedSlotContent } from './slot-BIG-yees.js';
10
+ import { r as requireIsValid, a as requireConstructFrom, b as requireToDate, c as requireConstants, D as DATETIME_PICKER_MODE, f as formatExports, d as DATETIME_PICKER_LOCALE } from './datetime-picker-constants-Bfm58jO6.js';
11
+
12
+ var isMatch = {};
13
+
14
+ var hasRequiredIsMatch;
15
+
16
+ function requireIsMatch () {
17
+ if (hasRequiredIsMatch) return isMatch;
18
+ hasRequiredIsMatch = 1;
19
+ isMatch.isMatch = isMatch$1;
20
+ var _index = /*@__PURE__*/ requireIsValid();
21
+ var _index2 = /*@__PURE__*/ requireParse();
22
+
23
+ /**
24
+ * The {@link isMatch} function options.
25
+ */
26
+
27
+ /**
28
+ * @name isMatch
29
+ * @category Common Helpers
30
+ * @summary validates the date string against given formats
31
+ *
32
+ * @description
33
+ * Return the true if given date is string correct against the given format else
34
+ * will return false.
35
+ *
36
+ * > ⚠️ Please note that the `format` tokens differ from Moment.js and other libraries.
37
+ * > See: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md
38
+ *
39
+ * The characters in the format string wrapped between two single quotes characters (') are escaped.
40
+ * Two single quotes in a row, whether inside or outside a quoted sequence, represent a 'real' single quote.
41
+ *
42
+ * Format of the format string is based on Unicode Technical Standard #35:
43
+ * https://www.unicode.org/reports/tr35/tr35-dates.html#Date_Field_Symbol_Table
44
+ * with a few additions (see note 5 below the table).
45
+ *
46
+ * Not all tokens are compatible. Combinations that don't make sense or could lead to bugs are prohibited
47
+ * and will throw `RangeError`. For example usage of 24-hour format token with AM/PM token will throw an exception:
48
+ *
49
+ * ```javascript
50
+ * isMatch('23 AM', 'HH a')
51
+ * //=> RangeError: The format string mustn't contain `HH` and `a` at the same time
52
+ * ```
53
+ *
54
+ * See the compatibility table: https://docs.google.com/spreadsheets/d/e/2PACX-1vQOPU3xUhplll6dyoMmVUXHKl_8CRDs6_ueLmex3SoqwhuolkuN3O05l4rqx5h1dKX8eb46Ul-CCSrq/pubhtml?gid=0&single=true
55
+ *
56
+ * Accepted format string patterns:
57
+ * | Unit |Prior| Pattern | Result examples | Notes |
58
+ * |---------------------------------|-----|---------|-----------------------------------|-------|
59
+ * | Era | 140 | G..GGG | AD, BC | |
60
+ * | | | GGGG | Anno Domini, Before Christ | 2 |
61
+ * | | | GGGGG | A, B | |
62
+ * | Calendar year | 130 | y | 44, 1, 1900, 2017, 9999 | 4 |
63
+ * | | | yo | 44th, 1st, 1900th, 9999999th | 4,5 |
64
+ * | | | yy | 44, 01, 00, 17 | 4 |
65
+ * | | | yyy | 044, 001, 123, 999 | 4 |
66
+ * | | | yyyy | 0044, 0001, 1900, 2017 | 4 |
67
+ * | | | yyyyy | ... | 2,4 |
68
+ * | Local week-numbering year | 130 | Y | 44, 1, 1900, 2017, 9000 | 4 |
69
+ * | | | Yo | 44th, 1st, 1900th, 9999999th | 4,5 |
70
+ * | | | YY | 44, 01, 00, 17 | 4,6 |
71
+ * | | | YYY | 044, 001, 123, 999 | 4 |
72
+ * | | | YYYY | 0044, 0001, 1900, 2017 | 4,6 |
73
+ * | | | YYYYY | ... | 2,4 |
74
+ * | ISO week-numbering year | 130 | R | -43, 1, 1900, 2017, 9999, -9999 | 4,5 |
75
+ * | | | RR | -43, 01, 00, 17 | 4,5 |
76
+ * | | | RRR | -043, 001, 123, 999, -999 | 4,5 |
77
+ * | | | RRRR | -0043, 0001, 2017, 9999, -9999 | 4,5 |
78
+ * | | | RRRRR | ... | 2,4,5 |
79
+ * | Extended year | 130 | u | -43, 1, 1900, 2017, 9999, -999 | 4 |
80
+ * | | | uu | -43, 01, 99, -99 | 4 |
81
+ * | | | uuu | -043, 001, 123, 999, -999 | 4 |
82
+ * | | | uuuu | -0043, 0001, 2017, 9999, -9999 | 4 |
83
+ * | | | uuuuu | ... | 2,4 |
84
+ * | Quarter (formatting) | 120 | Q | 1, 2, 3, 4 | |
85
+ * | | | Qo | 1st, 2nd, 3rd, 4th | 5 |
86
+ * | | | QQ | 01, 02, 03, 04 | |
87
+ * | | | QQQ | Q1, Q2, Q3, Q4 | |
88
+ * | | | QQQQ | 1st quarter, 2nd quarter, ... | 2 |
89
+ * | | | QQQQQ | 1, 2, 3, 4 | 4 |
90
+ * | Quarter (stand-alone) | 120 | q | 1, 2, 3, 4 | |
91
+ * | | | qo | 1st, 2nd, 3rd, 4th | 5 |
92
+ * | | | qq | 01, 02, 03, 04 | |
93
+ * | | | qqq | Q1, Q2, Q3, Q4 | |
94
+ * | | | qqqq | 1st quarter, 2nd quarter, ... | 2 |
95
+ * | | | qqqqq | 1, 2, 3, 4 | 3 |
96
+ * | Month (formatting) | 110 | M | 1, 2, ..., 12 | |
97
+ * | | | Mo | 1st, 2nd, ..., 12th | 5 |
98
+ * | | | MM | 01, 02, ..., 12 | |
99
+ * | | | MMM | Jan, Feb, ..., Dec | |
100
+ * | | | MMMM | January, February, ..., December | 2 |
101
+ * | | | MMMMM | J, F, ..., D | |
102
+ * | Month (stand-alone) | 110 | L | 1, 2, ..., 12 | |
103
+ * | | | Lo | 1st, 2nd, ..., 12th | 5 |
104
+ * | | | LL | 01, 02, ..., 12 | |
105
+ * | | | LLL | Jan, Feb, ..., Dec | |
106
+ * | | | LLLL | January, February, ..., December | 2 |
107
+ * | | | LLLLL | J, F, ..., D | |
108
+ * | Local week of year | 100 | w | 1, 2, ..., 53 | |
109
+ * | | | wo | 1st, 2nd, ..., 53th | 5 |
110
+ * | | | ww | 01, 02, ..., 53 | |
111
+ * | ISO week of year | 100 | I | 1, 2, ..., 53 | 5 |
112
+ * | | | Io | 1st, 2nd, ..., 53th | 5 |
113
+ * | | | II | 01, 02, ..., 53 | 5 |
114
+ * | Day of month | 90 | d | 1, 2, ..., 31 | |
115
+ * | | | do | 1st, 2nd, ..., 31st | 5 |
116
+ * | | | dd | 01, 02, ..., 31 | |
117
+ * | Day of year | 90 | D | 1, 2, ..., 365, 366 | 7 |
118
+ * | | | Do | 1st, 2nd, ..., 365th, 366th | 5 |
119
+ * | | | DD | 01, 02, ..., 365, 366 | 7 |
120
+ * | | | DDD | 001, 002, ..., 365, 366 | |
121
+ * | | | DDDD | ... | 2 |
122
+ * | Day of week (formatting) | 90 | E..EEE | Mon, Tue, Wed, ..., Su | |
123
+ * | | | EEEE | Monday, Tuesday, ..., Sunday | 2 |
124
+ * | | | EEEEE | M, T, W, T, F, S, S | |
125
+ * | | | EEEEEE | Mo, Tu, We, Th, Fr, Sa, Su | |
126
+ * | ISO day of week (formatting) | 90 | i | 1, 2, 3, ..., 7 | 5 |
127
+ * | | | io | 1st, 2nd, ..., 7th | 5 |
128
+ * | | | ii | 01, 02, ..., 07 | 5 |
129
+ * | | | iii | Mon, Tue, Wed, ..., Su | 5 |
130
+ * | | | iiii | Monday, Tuesday, ..., Sunday | 2,5 |
131
+ * | | | iiiii | M, T, W, T, F, S, S | 5 |
132
+ * | | | iiiiii | Mo, Tu, We, Th, Fr, Sa, Su | 5 |
133
+ * | Local day of week (formatting) | 90 | e | 2, 3, 4, ..., 1 | |
134
+ * | | | eo | 2nd, 3rd, ..., 1st | 5 |
135
+ * | | | ee | 02, 03, ..., 01 | |
136
+ * | | | eee | Mon, Tue, Wed, ..., Su | |
137
+ * | | | eeee | Monday, Tuesday, ..., Sunday | 2 |
138
+ * | | | eeeee | M, T, W, T, F, S, S | |
139
+ * | | | eeeeee | Mo, Tu, We, Th, Fr, Sa, Su | |
140
+ * | Local day of week (stand-alone) | 90 | c | 2, 3, 4, ..., 1 | |
141
+ * | | | co | 2nd, 3rd, ..., 1st | 5 |
142
+ * | | | cc | 02, 03, ..., 01 | |
143
+ * | | | ccc | Mon, Tue, Wed, ..., Su | |
144
+ * | | | cccc | Monday, Tuesday, ..., Sunday | 2 |
145
+ * | | | ccccc | M, T, W, T, F, S, S | |
146
+ * | | | cccccc | Mo, Tu, We, Th, Fr, Sa, Su | |
147
+ * | AM, PM | 80 | a..aaa | AM, PM | |
148
+ * | | | aaaa | a.m., p.m. | 2 |
149
+ * | | | aaaaa | a, p | |
150
+ * | AM, PM, noon, midnight | 80 | b..bbb | AM, PM, noon, midnight | |
151
+ * | | | bbbb | a.m., p.m., noon, midnight | 2 |
152
+ * | | | bbbbb | a, p, n, mi | |
153
+ * | Flexible day period | 80 | B..BBB | at night, in the morning, ... | |
154
+ * | | | BBBB | at night, in the morning, ... | 2 |
155
+ * | | | BBBBB | at night, in the morning, ... | |
156
+ * | Hour [1-12] | 70 | h | 1, 2, ..., 11, 12 | |
157
+ * | | | ho | 1st, 2nd, ..., 11th, 12th | 5 |
158
+ * | | | hh | 01, 02, ..., 11, 12 | |
159
+ * | Hour [0-23] | 70 | H | 0, 1, 2, ..., 23 | |
160
+ * | | | Ho | 0th, 1st, 2nd, ..., 23rd | 5 |
161
+ * | | | HH | 00, 01, 02, ..., 23 | |
162
+ * | Hour [0-11] | 70 | K | 1, 2, ..., 11, 0 | |
163
+ * | | | Ko | 1st, 2nd, ..., 11th, 0th | 5 |
164
+ * | | | KK | 01, 02, ..., 11, 00 | |
165
+ * | Hour [1-24] | 70 | k | 24, 1, 2, ..., 23 | |
166
+ * | | | ko | 24th, 1st, 2nd, ..., 23rd | 5 |
167
+ * | | | kk | 24, 01, 02, ..., 23 | |
168
+ * | Minute | 60 | m | 0, 1, ..., 59 | |
169
+ * | | | mo | 0th, 1st, ..., 59th | 5 |
170
+ * | | | mm | 00, 01, ..., 59 | |
171
+ * | Second | 50 | s | 0, 1, ..., 59 | |
172
+ * | | | so | 0th, 1st, ..., 59th | 5 |
173
+ * | | | ss | 00, 01, ..., 59 | |
174
+ * | Seconds timestamp | 40 | t | 512969520 | |
175
+ * | | | tt | ... | 2 |
176
+ * | Fraction of second | 30 | S | 0, 1, ..., 9 | |
177
+ * | | | SS | 00, 01, ..., 99 | |
178
+ * | | | SSS | 000, 001, ..., 999 | |
179
+ * | | | SSSS | ... | 2 |
180
+ * | Milliseconds timestamp | 20 | T | 512969520900 | |
181
+ * | | | TT | ... | 2 |
182
+ * | Timezone (ISO-8601 w/ Z) | 10 | X | -08, +0530, Z | |
183
+ * | | | XX | -0800, +0530, Z | |
184
+ * | | | XXX | -08:00, +05:30, Z | |
185
+ * | | | XXXX | -0800, +0530, Z, +123456 | 2 |
186
+ * | | | XXXXX | -08:00, +05:30, Z, +12:34:56 | |
187
+ * | Timezone (ISO-8601 w/o Z) | 10 | x | -08, +0530, +00 | |
188
+ * | | | xx | -0800, +0530, +0000 | |
189
+ * | | | xxx | -08:00, +05:30, +00:00 | 2 |
190
+ * | | | xxxx | -0800, +0530, +0000, +123456 | |
191
+ * | | | xxxxx | -08:00, +05:30, +00:00, +12:34:56 | |
192
+ * | Long localized date | NA | P | 05/29/1453 | 5,8 |
193
+ * | | | PP | May 29, 1453 | |
194
+ * | | | PPP | May 29th, 1453 | |
195
+ * | | | PPPP | Sunday, May 29th, 1453 | 2,5,8 |
196
+ * | Long localized time | NA | p | 12:00 AM | 5,8 |
197
+ * | | | pp | 12:00:00 AM | |
198
+ * | Combination of date and time | NA | Pp | 05/29/1453, 12:00 AM | |
199
+ * | | | PPpp | May 29, 1453, 12:00:00 AM | |
200
+ * | | | PPPpp | May 29th, 1453 at ... | |
201
+ * | | | PPPPpp | Sunday, May 29th, 1453 at ... | 2,5,8 |
202
+ * Notes:
203
+ * 1. "Formatting" units (e.g. formatting quarter) in the default en-US locale
204
+ * are the same as "stand-alone" units, but are different in some languages.
205
+ * "Formatting" units are declined according to the rules of the language
206
+ * in the context of a date. "Stand-alone" units are always nominative singular.
207
+ * In `format` function, they will produce different result:
208
+ *
209
+ * `format(new Date(2017, 10, 6), 'do LLLL', {locale: cs}) //=> '6. listopad'`
210
+ *
211
+ * `format(new Date(2017, 10, 6), 'do MMMM', {locale: cs}) //=> '6. listopadu'`
212
+ *
213
+ * `isMatch` will try to match both formatting and stand-alone units interchangeably.
214
+ *
215
+ * 2. Any sequence of the identical letters is a pattern, unless it is escaped by
216
+ * the single quote characters (see below).
217
+ * If the sequence is longer than listed in table:
218
+ * - for numerical units (`yyyyyyyy`) `isMatch` will try to match a number
219
+ * as wide as the sequence
220
+ * - for text units (`MMMMMMMM`) `isMatch` will try to match the widest variation of the unit.
221
+ * These variations are marked with "2" in the last column of the table.
222
+ *
223
+ * 3. `QQQQQ` and `qqqqq` could be not strictly numerical in some locales.
224
+ * These tokens represent the shortest form of the quarter.
225
+ *
226
+ * 4. The main difference between `y` and `u` patterns are B.C. years:
227
+ *
228
+ * | Year | `y` | `u` |
229
+ * |------|-----|-----|
230
+ * | AC 1 | 1 | 1 |
231
+ * | BC 1 | 1 | 0 |
232
+ * | BC 2 | 2 | -1 |
233
+ *
234
+ * Also `yy` will try to guess the century of two digit year by proximity with `referenceDate`:
235
+ *
236
+ * `isMatch('50', 'yy') //=> true`
237
+ *
238
+ * `isMatch('75', 'yy') //=> true`
239
+ *
240
+ * while `uu` will use the year as is:
241
+ *
242
+ * `isMatch('50', 'uu') //=> true`
243
+ *
244
+ * `isMatch('75', 'uu') //=> true`
245
+ *
246
+ * The same difference is true for local and ISO week-numbering years (`Y` and `R`),
247
+ * except local week-numbering years are dependent on `options.weekStartsOn`
248
+ * and `options.firstWeekContainsDate` (compare [setISOWeekYear](https://date-fns.org/docs/setISOWeekYear)
249
+ * and [setWeekYear](https://date-fns.org/docs/setWeekYear)).
250
+ *
251
+ * 5. These patterns are not in the Unicode Technical Standard #35:
252
+ * - `i`: ISO day of week
253
+ * - `I`: ISO week of year
254
+ * - `R`: ISO week-numbering year
255
+ * - `o`: ordinal number modifier
256
+ * - `P`: long localized date
257
+ * - `p`: long localized time
258
+ *
259
+ * 6. `YY` and `YYYY` tokens represent week-numbering years but they are often confused with years.
260
+ * You should enable `options.useAdditionalWeekYearTokens` to use them. See: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md
261
+ *
262
+ * 7. `D` and `DD` tokens represent days of the year but they are often confused with days of the month.
263
+ * You should enable `options.useAdditionalDayOfYearTokens` to use them. See: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md
264
+ *
265
+ * 8. `P+` tokens do not have a defined priority since they are merely aliases to other tokens based
266
+ * on the given locale.
267
+ *
268
+ * using `en-US` locale: `P` => `MM/dd/yyyy`
269
+ * using `en-US` locale: `p` => `hh:mm a`
270
+ * using `pt-BR` locale: `P` => `dd/MM/yyyy`
271
+ * using `pt-BR` locale: `p` => `HH:mm`
272
+ *
273
+ * Values will be checked in the descending order of its unit's priority.
274
+ * Units of an equal priority overwrite each other in the order of appearance.
275
+ *
276
+ * If no values of higher priority are matched (e.g. when matching string 'January 1st' without a year),
277
+ * the values will be taken from today's using `new Date()` date which works as a context of parsing.
278
+ *
279
+ * The result may vary by locale.
280
+ *
281
+ * If `formatString` matches with `dateString` but does not provides tokens, `referenceDate` will be returned.
282
+ *
283
+ * @param dateStr - The date string to verify
284
+ * @param format - The string of tokens
285
+ * @param options - An object with options.
286
+ * see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md
287
+ * see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md
288
+ *
289
+ * @returns Is format string a match for date string?
290
+ *
291
+ * @throws `options.locale` must contain `match` property
292
+ * @throws use `yyyy` instead of `YYYY` for formatting years; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md
293
+ * @throws use `yy` instead of `YY` for formatting years; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md
294
+ * @throws use `d` instead of `D` for formatting days of the month; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md
295
+ * @throws use `dd` instead of `DD` for formatting days of the month; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md
296
+ * @throws format string contains an unescaped latin alphabet character
297
+ *
298
+ * @example
299
+ * // Match 11 February 2014 from middle-endian format:
300
+ * const result = isMatch('02/11/2014', 'MM/dd/yyyy')
301
+ * //=> true
302
+ *
303
+ * @example
304
+ * // Match 28th of February in Esperanto locale in the context of 2010 year:
305
+ * import eo from 'date-fns/locale/eo'
306
+ * const result = isMatch('28-a de februaro', "do 'de' MMMM", {
307
+ * locale: eo
308
+ * })
309
+ * //=> true
310
+ */
311
+ function isMatch$1(dateStr, formatStr, options) {
312
+ return (0, _index.isValid)(
313
+ (0, _index2.parse)(dateStr, formatStr, new Date(), options),
314
+ );
315
+ }
316
+ return isMatch;
317
+ }
318
+
319
+ var isMatchExports = /*@__PURE__*/ requireIsMatch();
320
+
321
+ var parseISO = {};
322
+
323
+ var hasRequiredParseISO;
324
+
325
+ function requireParseISO () {
326
+ if (hasRequiredParseISO) return parseISO;
327
+ hasRequiredParseISO = 1;
328
+ parseISO.parseISO = parseISO$1;
329
+ var _index = /*@__PURE__*/ requireConstants();
330
+
331
+ var _index2 = /*@__PURE__*/ requireConstructFrom();
332
+ var _index3 = /*@__PURE__*/ requireToDate();
333
+
334
+ /**
335
+ * The {@link parseISO} function options.
336
+ */
337
+
338
+ /**
339
+ * @name parseISO
340
+ * @category Common Helpers
341
+ * @summary Parse ISO string
342
+ *
343
+ * @description
344
+ * Parse the given string in ISO 8601 format and return an instance of Date.
345
+ *
346
+ * Function accepts complete ISO 8601 formats as well as partial implementations.
347
+ * ISO 8601: http://en.wikipedia.org/wiki/ISO_8601
348
+ *
349
+ * If the argument isn't a string, the function cannot parse the string or
350
+ * the values are invalid, it returns Invalid Date.
351
+ *
352
+ * @typeParam DateType - The `Date` type, the function operates on. Gets inferred from passed arguments. Allows to use extensions like [`UTCDate`](https://github.com/date-fns/utc).
353
+ * @typeParam ResultDate - The result `Date` type, it is the type returned from the context function if it is passed, or inferred from the arguments.
354
+ *
355
+ * @param argument - The value to convert
356
+ * @param options - An object with options
357
+ *
358
+ * @returns The parsed date in the local time zone
359
+ *
360
+ * @example
361
+ * // Convert string '2014-02-11T11:30:30' to date:
362
+ * const result = parseISO('2014-02-11T11:30:30')
363
+ * //=> Tue Feb 11 2014 11:30:30
364
+ *
365
+ * @example
366
+ * // Convert string '+02014101' to date,
367
+ * // if the additional number of digits in the extended year format is 1:
368
+ * const result = parseISO('+02014101', { additionalDigits: 1 })
369
+ * //=> Fri Apr 11 2014 00:00:00
370
+ */
371
+ function parseISO$1(argument, options) {
372
+ const invalidDate = () => (0, _index2.constructFrom)(options?.in, NaN);
373
+
374
+ const additionalDigits = options?.additionalDigits ?? 2;
375
+ const dateStrings = splitDateString(argument);
376
+
377
+ let date;
378
+ if (dateStrings.date) {
379
+ const parseYearResult = parseYear(dateStrings.date, additionalDigits);
380
+ date = parseDate(parseYearResult.restDateString, parseYearResult.year);
381
+ }
382
+
383
+ if (!date || isNaN(+date)) return invalidDate();
384
+
385
+ const timestamp = +date;
386
+ let time = 0;
387
+ let offset;
388
+
389
+ if (dateStrings.time) {
390
+ time = parseTime(dateStrings.time);
391
+ if (isNaN(time)) return invalidDate();
392
+ }
393
+
394
+ if (dateStrings.timezone) {
395
+ offset = parseTimezone(dateStrings.timezone);
396
+ if (isNaN(offset)) return invalidDate();
397
+ } else {
398
+ const tmpDate = new Date(timestamp + time);
399
+ const result = (0, _index3.toDate)(0, options?.in);
400
+ result.setFullYear(
401
+ tmpDate.getUTCFullYear(),
402
+ tmpDate.getUTCMonth(),
403
+ tmpDate.getUTCDate(),
404
+ );
405
+ result.setHours(
406
+ tmpDate.getUTCHours(),
407
+ tmpDate.getUTCMinutes(),
408
+ tmpDate.getUTCSeconds(),
409
+ tmpDate.getUTCMilliseconds(),
410
+ );
411
+ return result;
412
+ }
413
+
414
+ return (0, _index3.toDate)(timestamp + time + offset, options?.in);
415
+ }
416
+
417
+ const patterns = {
418
+ dateTimeDelimiter: /[T ]/,
419
+ timeZoneDelimiter: /[Z ]/i,
420
+ timezone: /([Z+-].*)$/,
421
+ };
422
+
423
+ const dateRegex =
424
+ /^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/;
425
+ const timeRegex =
426
+ /^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/;
427
+ const timezoneRegex = /^([+-])(\d{2})(?::?(\d{2}))?$/;
428
+
429
+ function splitDateString(dateString) {
430
+ const dateStrings = {};
431
+ const array = dateString.split(patterns.dateTimeDelimiter);
432
+ let timeString;
433
+
434
+ // The regex match should only return at maximum two array elements.
435
+ // [date], [time], or [date, time].
436
+ if (array.length > 2) {
437
+ return dateStrings;
438
+ }
439
+
440
+ if (/:/.test(array[0])) {
441
+ timeString = array[0];
442
+ } else {
443
+ dateStrings.date = array[0];
444
+ timeString = array[1];
445
+ if (patterns.timeZoneDelimiter.test(dateStrings.date)) {
446
+ dateStrings.date = dateString.split(patterns.timeZoneDelimiter)[0];
447
+ timeString = dateString.substr(
448
+ dateStrings.date.length,
449
+ dateString.length,
450
+ );
451
+ }
452
+ }
453
+
454
+ if (timeString) {
455
+ const token = patterns.timezone.exec(timeString);
456
+ if (token) {
457
+ dateStrings.time = timeString.replace(token[1], "");
458
+ dateStrings.timezone = token[1];
459
+ } else {
460
+ dateStrings.time = timeString;
461
+ }
462
+ }
463
+
464
+ return dateStrings;
465
+ }
466
+
467
+ function parseYear(dateString, additionalDigits) {
468
+ const regex = new RegExp(
469
+ "^(?:(\\d{4}|[+-]\\d{" +
470
+ (4 + additionalDigits) +
471
+ "})|(\\d{2}|[+-]\\d{" +
472
+ (2 + additionalDigits) +
473
+ "})$)",
474
+ );
475
+
476
+ const captures = dateString.match(regex);
477
+ // Invalid ISO-formatted year
478
+ if (!captures) return { year: NaN, restDateString: "" };
479
+
480
+ const year = captures[1] ? parseInt(captures[1]) : null;
481
+ const century = captures[2] ? parseInt(captures[2]) : null;
482
+
483
+ // either year or century is null, not both
484
+ return {
485
+ year: century === null ? year : century * 100,
486
+ restDateString: dateString.slice((captures[1] || captures[2]).length),
487
+ };
488
+ }
489
+
490
+ function parseDate(dateString, year) {
491
+ // Invalid ISO-formatted year
492
+ if (year === null) return new Date(NaN);
493
+
494
+ const captures = dateString.match(dateRegex);
495
+ // Invalid ISO-formatted string
496
+ if (!captures) return new Date(NaN);
497
+
498
+ const isWeekDate = !!captures[4];
499
+ const dayOfYear = parseDateUnit(captures[1]);
500
+ const month = parseDateUnit(captures[2]) - 1;
501
+ const day = parseDateUnit(captures[3]);
502
+ const week = parseDateUnit(captures[4]);
503
+ const dayOfWeek = parseDateUnit(captures[5]) - 1;
504
+
505
+ if (isWeekDate) {
506
+ if (!validateWeekDate(year, week, dayOfWeek)) {
507
+ return new Date(NaN);
508
+ }
509
+ return dayOfISOWeekYear(year, week, dayOfWeek);
510
+ } else {
511
+ const date = new Date(0);
512
+ if (
513
+ !validateDate(year, month, day) ||
514
+ !validateDayOfYearDate(year, dayOfYear)
515
+ ) {
516
+ return new Date(NaN);
517
+ }
518
+ date.setUTCFullYear(year, month, Math.max(dayOfYear, day));
519
+ return date;
520
+ }
521
+ }
522
+
523
+ function parseDateUnit(value) {
524
+ return value ? parseInt(value) : 1;
525
+ }
526
+
527
+ function parseTime(timeString) {
528
+ const captures = timeString.match(timeRegex);
529
+ if (!captures) return NaN; // Invalid ISO-formatted time
530
+
531
+ const hours = parseTimeUnit(captures[1]);
532
+ const minutes = parseTimeUnit(captures[2]);
533
+ const seconds = parseTimeUnit(captures[3]);
534
+
535
+ if (!validateTime(hours, minutes, seconds)) {
536
+ return NaN;
537
+ }
538
+
539
+ return (
540
+ hours * _index.millisecondsInHour +
541
+ minutes * _index.millisecondsInMinute +
542
+ seconds * 1000
543
+ );
544
+ }
545
+
546
+ function parseTimeUnit(value) {
547
+ return (value && parseFloat(value.replace(",", "."))) || 0;
548
+ }
549
+
550
+ function parseTimezone(timezoneString) {
551
+ if (timezoneString === "Z") return 0;
552
+
553
+ const captures = timezoneString.match(timezoneRegex);
554
+ if (!captures) return 0;
555
+
556
+ const sign = captures[1] === "+" ? -1 : 1;
557
+ const hours = parseInt(captures[2]);
558
+ const minutes = (captures[3] && parseInt(captures[3])) || 0;
559
+
560
+ if (!validateTimezone(hours, minutes)) {
561
+ return NaN;
562
+ }
563
+
564
+ return (
565
+ sign *
566
+ (hours * _index.millisecondsInHour + minutes * _index.millisecondsInMinute)
567
+ );
568
+ }
569
+
570
+ function dayOfISOWeekYear(isoWeekYear, week, day) {
571
+ const date = new Date(0);
572
+ date.setUTCFullYear(isoWeekYear, 0, 4);
573
+ const fourthOfJanuaryDay = date.getUTCDay() || 7;
574
+ const diff = (week - 1) * 7 + day + 1 - fourthOfJanuaryDay;
575
+ date.setUTCDate(date.getUTCDate() + diff);
576
+ return date;
577
+ }
578
+
579
+ // Validation functions
580
+
581
+ // February is null to handle the leap year (using ||)
582
+ const daysInMonths = [31, null, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];
583
+
584
+ function isLeapYearIndex(year) {
585
+ return year % 400 === 0 || (year % 4 === 0 && year % 100 !== 0);
586
+ }
587
+
588
+ function validateDate(year, month, date) {
589
+ return (
590
+ month >= 0 &&
591
+ month <= 11 &&
592
+ date >= 1 &&
593
+ date <= (daysInMonths[month] || (isLeapYearIndex(year) ? 29 : 28))
594
+ );
595
+ }
596
+
597
+ function validateDayOfYearDate(year, dayOfYear) {
598
+ return dayOfYear >= 1 && dayOfYear <= (isLeapYearIndex(year) ? 366 : 365);
599
+ }
600
+
601
+ function validateWeekDate(_year, week, day) {
602
+ return week >= 1 && week <= 53 && day >= 0 && day <= 6;
603
+ }
604
+
605
+ function validateTime(hours, minutes, seconds) {
606
+ if (hours === 24) {
607
+ return minutes === 0 && seconds === 0;
608
+ }
609
+
610
+ return (
611
+ seconds >= 0 &&
612
+ seconds < 60 &&
613
+ minutes >= 0 &&
614
+ minutes < 60 &&
615
+ hours >= 0 &&
616
+ hours < 25
617
+ );
618
+ }
619
+
620
+ function validateTimezone(_hours, minutes) {
621
+ return minutes >= 0 && minutes <= 59;
622
+ }
623
+ return parseISO;
624
+ }
625
+
626
+ var parseISOExports = /*@__PURE__*/ requireParseISO();
627
+
628
+ /** Serializa o valor atual para envio em FormData conforme o modo ativo. */
629
+ function serializeDatetimePickerFormValue(value, context) {
630
+ if (isDateRangeMode(context)) {
631
+ return serializeRangeFormValue(context.rangeStart, context.rangeEnd);
632
+ }
633
+ if (value === null) {
634
+ return null;
635
+ }
636
+ switch (context.mode) {
637
+ case DATETIME_PICKER_MODE.DATE:
638
+ return serializeDate(value);
639
+ case DATETIME_PICKER_MODE.TIME:
640
+ return formatExports.format(value, 'HH:mm');
641
+ default:
642
+ // Para submissão em formulários, no modo datetime retornamos a ISO completa
643
+ // incluindo o deslocamento de fuso local em vez de UTC (Z).
644
+ return formatExports.format(value, "yyyy-MM-dd'T'HH:mm:ssXXX");
645
+ }
646
+ }
647
+ /** Analisa um valor serializado de formulário para Date respeitando o modo atual. */
648
+ function parseDatetimePickerSerializedValue(value, mode, referenceDate) {
649
+ if (isBlankValue(value)) {
650
+ return null;
651
+ }
652
+ switch (mode) {
653
+ case DATETIME_PICKER_MODE.DATE:
654
+ return parseDate(value);
655
+ case DATETIME_PICKER_MODE.TIME:
656
+ return parseTimeValue(value, referenceDate);
657
+ default:
658
+ return parseIsoDate(value);
659
+ }
660
+ }
661
+ /** Analisa intervalo serializado no formato YYYY-MM-DD/YYYY-MM-DD. */
662
+ function parseDatetimePickerSerializedRange(value) {
663
+ const [startRaw, endRaw] = value.split('/');
664
+ if (startRaw === undefined || endRaw === undefined) {
665
+ return null;
666
+ }
667
+ const start = parseDate(startRaw);
668
+ const end = parseDate(endRaw);
669
+ if (start === null || end === null) {
670
+ return null;
671
+ }
672
+ return { start, end };
673
+ }
674
+ /** Informa se o componente deve sinalizar valueMissing na validação nativa. */
675
+ function hasDatetimePickerMissingValue(context) {
676
+ const { required, disabled, value } = context;
677
+ if (!required || disabled) {
678
+ return false;
679
+ }
680
+ const isRangeIncomplete = isDateRangeMode(context) && (context.rangeStart === null || context.rangeEnd === null);
681
+ return value === null || isRangeIncomplete;
682
+ }
683
+ function isBlankValue(value) {
684
+ return value.trim() === '';
685
+ }
686
+ function isDateRangeMode(context) {
687
+ return context.selectionMode === 'range' && context.mode === DATETIME_PICKER_MODE.DATE;
688
+ }
689
+ function serializeRangeFormValue(rangeStart, rangeEnd) {
690
+ if (rangeStart === null || rangeEnd === null) {
691
+ return null;
692
+ }
693
+ return `${serializeDate(rangeStart)}/${serializeDate(rangeEnd)}`;
694
+ }
695
+ function parseTimeValue(value, referenceDate) {
696
+ if (!isMatchExports.isMatch(value, 'HH:mm')) {
697
+ return null;
698
+ }
699
+ const parsedTime = parseExports.parse(value, 'HH:mm', new Date());
700
+ if (!isValidExports.isValid(parsedTime)) {
701
+ return null;
702
+ }
703
+ const baseDate = toDateExports.toDate(referenceDate);
704
+ baseDate.setHours(parsedTime.getHours(), parsedTime.getMinutes(), 0, 0);
705
+ return baseDate;
706
+ }
707
+ function parseIsoDate(value) {
708
+ const parsedDate = parseISOExports.parseISO(value);
709
+ return isValidExports.isValid(parsedDate) ? parsedDate : null;
710
+ }
711
+ function parseDate(value) {
712
+ if (!isMatchExports.isMatch(value, 'yyyy-MM-dd')) {
713
+ return null;
714
+ }
715
+ const parsedDate = parseExports.parse(value, 'yyyy-MM-dd', new Date());
716
+ if (!isValidExports.isValid(parsedDate)) {
717
+ return null;
718
+ }
719
+ // Garante aderência estrita ao formato/calendário evitando rollover silencioso.
720
+ if (formatExports.format(parsedDate, 'yyyy-MM-dd') !== value) {
721
+ return null;
722
+ }
723
+ parsedDate.setHours(0, 0, 0, 0);
724
+ return parsedDate;
725
+ }
726
+ function serializeDate(value) {
727
+ return formatExports.format(value, 'yyyy-MM-dd');
728
+ }
729
+
730
+ const VALID_WEEK_START_DAYS = [0, 1, 2, 3, 4, 5, 6];
731
+ const INITIAL_MOMENT_DATE_FORMATS = ['dd/MM/yyyy HH:mm', 'dd/MM/yyyy', 'yyyy-MM-dd HH:mm', 'yyyy-MM-dd'];
732
+ function parseInitialMomentString(value) {
733
+ const trimmedValue = value.trim();
734
+ if (trimmedValue === '') {
735
+ return null;
736
+ }
737
+ const isoDate = parseISOExports.parseISO(trimmedValue);
738
+ if (isValidExports.isValid(isoDate)) {
739
+ return isoDate;
740
+ }
741
+ for (const formatPattern of INITIAL_MOMENT_DATE_FORMATS) {
742
+ const parsedDate = parseExports.parse(trimmedValue, formatPattern, new Date());
743
+ if (isValidExports.isValid(parsedDate)) {
744
+ return parsedDate;
745
+ }
746
+ }
747
+ return null;
748
+ }
749
+ function normalizeDateCandidate(value) {
750
+ if (value instanceof Date) {
751
+ if (!Number.isNaN(value.getTime())) {
752
+ return new Date(value);
753
+ }
754
+ return null;
755
+ }
756
+ if (typeof value === 'string') {
757
+ return parseInitialMomentString(value);
758
+ }
759
+ return null;
760
+ }
761
+ function tokenizeDisabledDatesString(value) {
762
+ return value
763
+ .trim()
764
+ .split(/\s+/)
765
+ .filter((token) => token.length > 0);
766
+ }
767
+ /**
768
+ * Verifica se o valor informado corresponde a um modo suportado pelo componente.
769
+ *
770
+ * @param value - Valor recebido via prop ou atributo.
771
+ * @returns `true` quando o valor pertence ao conjunto aceito de modos.
772
+ */
773
+ function isValidDatetimePickerMode(value) {
774
+ return Object.values(DATETIME_PICKER_MODE).includes(value);
775
+ }
776
+ /**
777
+ * Normaliza o modo informado e aplica o valor padrão quando necessário.
778
+ *
779
+ * @param value - Valor bruto recebido do consumidor do componente.
780
+ * @returns O modo válido correspondente, ou o valor padrão quando o input for inválido.
781
+ */
782
+ function normalizeDatetimePickerMode(value) {
783
+ if (isValidDatetimePickerMode(value))
784
+ return value;
785
+ warnInvalidPropValue('br-datetime-picker', 'mode', value, DATETIME_PICKER_MODE.DEFAULT);
786
+ return DATETIME_PICKER_MODE.DEFAULT;
787
+ }
788
+ /**
789
+ * Verifica se o valor representa um modo de seleção suportado.
790
+ *
791
+ * @param value - Valor bruto recebido via prop.
792
+ * @returns `true` quando o valor é `'single'` ou `'range'`.
793
+ */
794
+ function isValidDatetimePickerSelectionMode(value) {
795
+ return value === 'single' || value === 'range';
796
+ }
797
+ /**
798
+ * Normaliza o modo de seleção informado e aplica o valor padrão quando necessário.
799
+ *
800
+ * @param value - Valor bruto recebido do consumidor do componente.
801
+ * @returns O modo de seleção válido correspondente, ou `'single'` quando o input for inválido.
802
+ */
803
+ function normalizeDatetimePickerSelectionMode(value) {
804
+ if (isValidDatetimePickerSelectionMode(value))
805
+ return value;
806
+ warnInvalidPropValue('br-datetime-picker', 'selectionMode', value, 'single');
807
+ return 'single';
808
+ }
809
+ /**
810
+ * Normaliza a seleção inicial para um valor aplicável pelo componente.
811
+ *
812
+ * @param value - Valor bruto recebido via prop.
813
+ * @returns `'now'`, `Date` normalizada ou `null` quando inválido.
814
+ */
815
+ function normalizeDatetimePickerInitialMoment(value) {
816
+ if (value === null)
817
+ return null;
818
+ if (value === 'now')
819
+ return 'now';
820
+ const normalizedDate = normalizeDateCandidate(value);
821
+ if (normalizedDate !== null) {
822
+ return normalizedDate;
823
+ }
824
+ warnInvalidPropValue('br-datetime-picker', 'initialMoment', value, 'null');
825
+ return null;
826
+ }
827
+ /**
828
+ * Normaliza a lista de datas desabilitadas para uma coleção de `Date` válidas.
829
+ *
830
+ * @param value - Valor bruto recebido via prop.
831
+ * @returns Lista normalizada de datas; retorna array vazio quando inválido.
832
+ */
833
+ function normalizeDatetimePickerDisabledDates(value) {
834
+ if (value === null) {
835
+ return [];
836
+ }
837
+ if (typeof value === 'string') {
838
+ const tokens = tokenizeDisabledDatesString(value);
839
+ if (tokens.length === 0) {
840
+ warnInvalidPropValue('br-datetime-picker', 'disabledDates', value, '[]');
841
+ return [];
842
+ }
843
+ const normalizedDates = tokens
844
+ .map((dateCandidate) => normalizeDateCandidate(dateCandidate))
845
+ .filter((dateCandidate) => dateCandidate !== null);
846
+ if (normalizedDates.length !== tokens.length) {
847
+ warnInvalidPropValue('br-datetime-picker', 'disabledDates', value, '[]');
848
+ }
849
+ return normalizedDates;
850
+ }
851
+ if (!Array.isArray(value)) {
852
+ warnInvalidPropValue('br-datetime-picker', 'disabledDates', value, '[]');
853
+ return [];
854
+ }
855
+ const normalizedDates = value
856
+ .map((dateCandidate) => normalizeDateCandidate(dateCandidate))
857
+ .filter((dateCandidate) => dateCandidate !== null);
858
+ if (normalizedDates.length !== value.length) {
859
+ warnInvalidPropValue('br-datetime-picker', 'disabledDates', value, '[]');
860
+ }
861
+ return normalizedDates;
862
+ }
863
+ /**
864
+ * Verifica se o valor informado representa um índice válido de início da semana.
865
+ *
866
+ * @param value - Valor bruto recebido via prop.
867
+ * @returns `true` quando o valor está entre `0` e `6`.
868
+ */
869
+ function isValidDatetimePickerWeekStartsOn(value) {
870
+ return VALID_WEEK_START_DAYS.includes(value);
871
+ }
872
+ /**
873
+ * Normaliza o índice de início da semana e aplica `0` quando o valor é inválido.
874
+ *
875
+ * @param value - Valor bruto recebido do consumidor do componente.
876
+ * @returns Índice normalizado para o primeiro dia da semana.
877
+ */
878
+ function normalizeDatetimePickerWeekStartsOn(value) {
879
+ const numericValue = typeof value === 'string' ? Number(value) : value;
880
+ if (typeof numericValue === 'number' &&
881
+ Number.isInteger(numericValue) &&
882
+ isValidDatetimePickerWeekStartsOn(numericValue)) {
883
+ return numericValue;
884
+ }
885
+ warnInvalidPropValue('br-datetime-picker', 'weekStartsOn', String(value), '0');
886
+ return 0;
887
+ }
888
+
889
+ const datetimePickerCss = () => `*,*::before,*::after{box-sizing:border-box}:host{line-height:var(--font-line-height-medium);-webkit-text-size-adjust:100%;-moz-text-size-adjust:100%;text-size-adjust:100%}main{display:block}hr{box-sizing:content-box;height:0;overflow:visible}a{background-color:rgba(0,0,0,0)}b,strong{font-weight:bolder}code{font-family:monospace;font-size:1em}small{font-size:80%}img{border-style:none}button,input,select,textarea{font-family:inherit;font-size:100%;line-height:var(--font-line-height-medium);margin:0}button,input{overflow:visible}button,select{text-transform:none}button,[type=button],[type=reset],[type=submit]{appearance:button}button::-moz-focus-inner,[type=button]::-moz-focus-inner,[type=reset]::-moz-focus-inner,[type=submit]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type=button]:-moz-focusring,[type=reset]:-moz-focusring,[type=submit]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:.35em .75em .625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}progress{vertical-align:baseline}textarea{overflow:auto}[type=checkbox],[type=radio]{box-sizing:border-box;padding:0}[type=number]::-webkit-inner-spin-button,[type=number]::-webkit-outer-spin-button{height:auto}[type=search]{appearance:textfield;outline-offset:-2px}[type=search]::-webkit-search-decoration{appearance:none}::-webkit-file-upload-button{appearance:button;font:inherit}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}.d-none{display:none !important}@media (min-width: 576px){.d-sm-block{display:block !important}.d-sm-flex{display:flex !important}}[data-toggle=dropdown]+*{position:absolute}.dropdown{position:relative}.dropdown [data-toggle=dropdown]+*{box-shadow:var(--surface-shadow-sm);left:0;position:absolute;top:100%}.dropdown>.br-notification{left:auto;right:0}.dropdown .br-item{--color:var(--color-light);--color-rgb:var(--color-light-rgb);--text-color:var(--color-light);--interactive:var(--interactive-light);--interactive-rgb:var(--color-rgb);--visited:var(--visited-light);--hover:var(--hover-light);--pressed:var(--pressed-light);--focus-color:var(--focus-color-light);--focus:var(--focus-color-light);--item-padding-y:var(--spacing-scale-2x);background-color:var(--background-light);color:var(--color)}.dropdown .br-item:not(:last-child){border-bottom:1px solid var(--border-color)}.dropdown .br-item.selected{--color:var(--color-dark);--color-rgb:var(--color-dark-rgb);--text-color:var(--color-dark);--interactive:var(--interactive-dark);--interactive-rgb:var(--interactive-dark-rgb);--visited:var(--visited-dark);--hover:var(--hover-dark);--pressed:var(--pressed-dark);--focus-color:var(--focus-color-dark);--focus:var(--focus-color-dark)}.justify-content-start{justify-content:flex-start !important}.justify-content-end{justify-content:flex-end !important}.justify-content-center{justify-content:center !important}.align-items-center{align-items:center !important}.col,[class*=col-]{padding-left:calc(var(--grid-gutter)*.5);padding-right:calc(var(--grid-gutter)*.5);width:100%}.col{flex:1 0 0%;min-width:8.3333333333%}.col-auto{flex:0 0 auto;width:auto}.col-2{flex-basis:16.6666666667%;max-width:16.6666666667%}.container,.container-fluid,.container-lg{--grid-margin:var(--grid-portrait-margin);--grid-maxwidth:var(--grid-portrait-maxwidth);margin-left:auto;margin-right:auto;max-width:var(--grid-maxwidth);padding-left:var(--grid-margin);padding-right:var(--grid-margin);width:100%}.row{--grid-gutter:var(--grid-portrait-gutter);display:flex;flex-wrap:wrap;margin-left:calc(var(--grid-gutter)*-0.5);margin-right:calc(var(--grid-gutter)*-0.5)}@media (min-width: 576px){.container,.container-lg,.container-fluid{--grid-margin:var(--grid-tablet-margin)}.row{--grid-gutter:var(--grid-tablet-gutter)}.container{--grid-maxwidth:calc(var(--grid-breakpoint-sm) - var(--grid-tablet-margin))}}@media (min-width: 992px){.container,.container-lg,.container-fluid{--grid-margin:var(--grid-tablet-margin)}.row{--grid-gutter:var(--grid-tablet-gutter)}.container{--grid-maxwidth:calc(var(--grid-breakpoint-md) - var(--grid-tablet-margin))}}@media (min-width: 1280px){.container,.container-lg,.container-fluid{--grid-margin:var(--grid-desktop-margin)}.row{--grid-gutter:var(--grid-desktop-gutter)}.container,.container-lg{--grid-maxwidth:calc(var(--grid-breakpoint-lg) - var(--grid-desktop-margin))}}@media (min-width: 1600px){.container,.container-lg,.container-fluid{--grid-margin:var(--grid-tv-margin)}.row{--grid-gutter:var(--grid-tv-gutter)}.container,.container-lg{--grid-maxwidth:calc(var(--grid-breakpoint-xl) - var(--grid-tv-margin))}}.ease{animation-timing-function:cubic-bezier(0.25, 0.1, 0.25, 1)}.ease-in-out{animation-timing-function:cubic-bezier(0.42, 0, 0.58, 1)}.mt-1{margin-top:var(--spacing-scale-half) !important}.mr-1{margin-right:var(--spacing-scale-half) !important}.mb-1{margin-bottom:var(--spacing-scale-half) !important}.ml-1{margin-left:var(--spacing-scale-half) !important}.mx-3{margin-left:var(--spacing-scale-2x) !important;margin-right:var(--spacing-scale-2x) !important}.mb-4{margin-bottom:var(--spacing-scale-3x) !important}.ml-auto{margin-left:auto !important}.pt-half{padding-top:var(--spacing-scale-half) !important}@media (min-width: 576px){.ml-sm-0{margin-left:var(--spacing-scale-default) !important}}.highlight{background:var(--status-highlight-background) linear-gradient(var(--status-highlight-overlay), var(--status-highlight-overlay));color:var(--status-highlight-text);padding:0 var(--spacing-scale-half)}[disabled],.disabled{cursor:not-allowed;opacity:var(--disabled)}[disabled] *,.disabled *{pointer-events:none}.text-center{text-align:center !important}.text-right{text-align:right !important}.text-nowrap{white-space:nowrap !important}.text-uppercase{text-transform:uppercase !important}.text-bold{font-weight:700 !important}.text-base{font-size:var(--font-size-scale-base) !important}.text-down-01{font-size:var(--font-size-scale-down-01) !important}@media (min-width: 576px){.text-sm-center{text-align:center !important}.text-sm-left{text-align:left !important}.text-sm-right{text-align:right !important}}p{color:var(--color);font-size:var(--font-size-scale-base);font-weight:var(--font-weight-regular);line-height:var(--font-line-height-medium);margin-bottom:var(--spacing-scale-2x);margin-top:0}p a{text-decoration:underline}@media (min-width: 576px){p{font-size:var(--font-size-scale-up-01)}}a{--focus-offset:var(--spacing-scale-half)}a:focus{outline:none}a.focus-visible,a:focus-visible{outline-color:var(--focus);outline-offset:var(--focus-offset);outline-style:var(--focus-style);outline-width:var(--focus-width)}a:not(:disabled):hover{background-image:linear-gradient(rgba(var(--interactive-rgb), var(--hover)), rgba(var(--interactive-rgb), var(--hover)))}a:not(:disabled):active{background-image:linear-gradient(rgba(var(--interactive-rgb), var(--pressed)), rgba(var(--interactive-rgb), var(--pressed)))}a{color:var(--interactive);text-decoration:none}.main-content a{text-decoration:underline}button{cursor:pointer}img{max-width:100%;vertical-align:middle}h2,.h2{color:var(--color);font-size:var(--font-size-scale-up-03);font-weight:var(--font-weight-semi-bold);line-height:var(--font-line-height-low);margin-bottom:var(--spacing-scale-2xh);margin-top:var(--spacing-scale-3xh);padding-bottom:var(--spacing-scale-2xh)}@media (min-width: 576px){.h2,h2{font-size:var(--font-size-scale-up-05);font-weight:var(--font-weight-regular)}}ul,ol{margin-bottom:var(--spacing-scale-2x);margin-top:0;padding:0 0 0 var(--spacing-scale-5x)}table{--table-background:var(--background);--table-color:var(--color);--table-border-color:var(--gray-20);--table-border-style:solid;--table-border-width:1px;--table-hover:var(--color-rgb);--table-padding:var(--spacing-scale-3x);--table-font-weight:var(--font-weight-medium);--table-th-background:var(--background-alternative);--table-th-font-weight:var(--font-weight-semi-bold);--table-row-size:var(--spacing-scale-2x);border-collapse:collapse;width:100%}tr.selected,tr.is-selected{--color:var(--color-dark);--color-rgb:var(--color-dark-rgb);--text-color:var(--color-dark);--interactive:var(--interactive-dark);--interactive-rgb:var(--interactive-dark-rgb);--visited:var(--visited-dark);--hover:var(--hover-dark);--pressed:var(--pressed-dark);--focus-color:var(--focus-color-dark);--focus:var(--focus-color-dark)}label,.label{color:var(--color);font-size:var(--font-size-scale-base);font-weight:var(--font-weight-semi-bold);line-height:var(--font-line-height-medium);margin-bottom:var(--spacing-scale-half)}fieldset,.fieldset{border:var(--surface-width-none);margin-bottom:var(--spacing-scale-5x);margin-top:0;padding:0}legend,.legend{color:var(--color);font-size:var(--font-size-scale-up-01);font-weight:var(--font-weight-semi-bold);line-height:var(--font-line-height-low);margin-bottom:var(--spacing-scale-2x);margin-top:var(--spacing-scale-2x)}::placeholder,.placeholder{color:var(--color-light);font-size:var(--font-size-scale-base);font-style:italic;font-weight:var(--font-weight-regular);line-height:var(--font-line-height-medium);margin-bottom:var(--spacing-scale-half);margin-top:var(--spacing-scale-half);opacity:1}input,textarea,.input{color:var(--color-light);font-size:var(--font-size-scale-up-01);font-weight:var(--font-weight-medium);line-height:var(--font-line-height-low);margin-bottom:var(--spacing-scale-half)}.help{font-size:var(--font-size-scale-base)}code,.code{background:var(--gray-5);border-radius:4px;color:var(--gray-80);display:inline-block;font-family:monospace;font-size:var(--font-size-scale-base);font-weight:var(--font-weight-medium);line-height:var(--font-line-height-low);padding:var(--spacing-scale-half)}*[data-toggle=collapse]:not(:disabled):hover{background-image:linear-gradient(rgba(var(--interactive-rgb), var(--hover)), rgba(var(--interactive-rgb), var(--hover)))}*[data-toggle=collapse]:focus{outline:none}*[data-toggle=collapse].focus-visible,*[data-toggle=collapse]:focus-visible{outline-color:var(--focus);outline-offset:var(--focus-offset);outline-style:var(--focus-style);outline-width:var(--focus-width)}:host{display:inline-block;margin-bottom:var(--spacing-scale-base);position:relative;width:var(--br-datetime-picker-width, 304px)}:host([mode=time]){width:var(--br-datetime-picker-time-width, 144px)}:host([mode=date]){width:var(--br-datetime-picker-date-width, 304px)}:host([mode=datetime]){width:var(--br-datetime-picker-datetime-width, 304px)}.br-datetime-picker{width:100%}.br-datetime-picker br-datetime-input,.br-datetime-picker br-card{display:block;width:100%}.br-datetime-picker br-card{font-size:var(--font-size-scale-base)}`;
890
+
891
+ const DatetimePicker = class {
892
+ constructor(hostRef) {
893
+ registerInstance(this, hostRef);
894
+ this.dateStateChange = createEvent(this, "dateStateChange", 7);
895
+ this.valueChange = createEvent(this, "valueChange", 7);
896
+ this.brDatetimePickerValidationChange = createEvent(this, "brDatetimePickerValidationChange", 7);
897
+ if (hostRef.$hostElement$["s-ei"]) {
898
+ this.elementInternals = hostRef.$hostElement$["s-ei"];
899
+ }
900
+ else {
901
+ this.elementInternals = hostRef.$hostElement$.attachInternals();
902
+ hostRef.$hostElement$["s-ei"] = this.elementInternals;
903
+ }
904
+ /**
905
+ * Controla se o conteúdo do picker está visível.
906
+ */
907
+ this.isPickerOpen = false;
908
+ this.formDisabled = false;
909
+ this.hasFeedbackSlot = false;
910
+ this.customValidationMessage = '';
911
+ this.validatorMessage = null;
912
+ this.isValidating = false;
913
+ this.feedbackId = `br-datetime-picker-feedback-${datetimePickerId++}`;
914
+ /** Lista normalizada de datas indisponíveis para seleção. */
915
+ this.normalizedDisabledDates = [];
916
+ /** Data final selecionada no modo de intervalo. */
917
+ this.rangeEnd = null;
918
+ /** Data inicial selecionada no modo de intervalo. */
919
+ this.rangeStart = null;
920
+ /**
921
+ * Mantém a data de referência que orienta a navegação visual do calendário.
922
+ */
923
+ this.referenceDate = new Date();
924
+ /**
925
+ * Define o modo de seleção exibido pelo componente: data, horário ou ambos.
926
+ *
927
+ * Valores aceitos: `date`, `time` ou `datetime`.
928
+ * Valores inválidos são corrigidos automaticamente para o valor padrão,
929
+ * mantendo o atributo refletido sempre consistente com o modo exibido.
930
+ *
931
+ * @default 'datetime'
932
+ */
933
+ this.mode = DATETIME_PICKER_MODE.DEFAULT;
934
+ /**
935
+ * Define o locale usado pelos subcomponentes para formatar datas e rótulos.
936
+ *
937
+ * @default 'pt-BR'
938
+ */
939
+ this.locale = DATETIME_PICKER_LOCALE.DEFAULT;
940
+ /**
941
+ * Define o placeholder exibido no campo de entrada do datetime picker.
942
+ *
943
+ * @default ''
944
+ */
945
+ this.placeholder = '';
946
+ /** Nome do campo para submissão em formulários nativos. */
947
+ this.name = '';
948
+ /** Indica se o campo deve ter valor antes do envio do formulário. */
949
+ this.required = false;
950
+ /** Menor data/horário aceito, interpretado conforme `mode`. */
951
+ this.min = null;
952
+ /** Maior data/horário aceito, interpretado conforme `mode`. */
953
+ this.max = null;
954
+ /**
955
+ * Define o tipo de seleção de datas para o calendário: única ou intervalo.
956
+ *
957
+ * `range` só funciona em conjunto com `mode="date"`.
958
+ * Se `selectionMode="range"` for informado, o componente ajusta automaticamente
959
+ * `mode` para `date`. Se `mode` mudar para `time` ou `datetime`, o componente
960
+ * normaliza `selectionMode` para `single` quando necessário.
961
+ */
962
+ this.selectionMode = 'single';
963
+ /**
964
+ * Define o dia inicial da semana exibida no calendário.
965
+ *
966
+ * Valores suportados: 0 (domingo) a 6 (sábado).
967
+ *
968
+ * @default 0
969
+ */
970
+ this.weekStartsOn = 0;
971
+ /**
972
+ * Define a seleção inicial do componente.
973
+ *
974
+ * Aceita:
975
+ * - `'now'`: seleciona o momento atual.
976
+ * - `Date` ou `string`: seleciona uma data arbitrária.
977
+ * - `null`: inicia sem seleção.
978
+ *
979
+ * Reativo em runtime: mudanças na prop atualizam estado e subcomponentes.
980
+ *
981
+ * @default null
982
+ */
983
+ this.initialMoment = null;
984
+ /**
985
+ * Valor selecionado pelo usuário. Pode ser controlado externamente e é atualizado
986
+ * pelo evento `valueChange`.
987
+ */
988
+ this.value = null;
989
+ /**
990
+ * Desabilita toda a interação do componente.
991
+ *
992
+ * Quando `true`, impede abrir o picker, alterar valores e navegar entre datas/horários.
993
+ *
994
+ * @default false
995
+ */
996
+ this.disabled = false;
997
+ /**
998
+ * Define um conjunto de datas indisponíveis para seleção.
999
+ *
1000
+ * Aceita uma lista de `Date` e/ou strings analisáveis, ou uma string com datas
1001
+ * separadas por espaço em branco. Datas inválidas são ignoradas com warning.
1002
+ * A comparação considera apenas o dia (ano/mês/dia), ignorando hora.
1003
+ *
1004
+ * @default null
1005
+ */
1006
+ this.disabledDates = null;
1007
+ /**
1008
+ * Define se o calendário deve manter um número fixo de linhas (6 semanas = 42 dias)
1009
+ * ou variar conforme o mês.
1010
+ *
1011
+ * Quando `true`, o calendário sempre exibe 6 semanas completas.
1012
+ * Quando `false`, o calendário adapta-se ao mês, exibindo apenas as semanas necessárias.
1013
+ *
1014
+ * @default false
1015
+ */
1016
+ this.fixedRowCount = false;
1017
+ /** Snapshot da seleção inicial usada para restaurar em reset de formulário. */
1018
+ this.initialFormValue = null;
1019
+ this.validationRunId = 0;
1020
+ this.isInitialized = false;
1021
+ this.syncingCanonicalValues = false;
1022
+ /** Mapeia cada modo para a função responsável por renderizar seu conteúdo. */
1023
+ this.modeRendererMap = {
1024
+ [DATETIME_PICKER_MODE.DATE]: () => this.renderDatePicker(),
1025
+ [DATETIME_PICKER_MODE.TIME]: () => this.renderTimePicker(),
1026
+ [DATETIME_PICKER_MODE.DATETIME]: () => this.renderDateTimePicker(),
1027
+ };
1028
+ /**
1029
+ * Sincroniza o estado local com a emissão dos subcomponentes de data e horário.
1030
+ *
1031
+ * @param event - Evento com a data de referência e o valor selecionado.
1032
+ */
1033
+ this.handleDateStateChange = (event) => {
1034
+ // Evita que o evento interno dos subcomponentes vaze para fora do host.
1035
+ event.stopPropagation();
1036
+ if (this.isDisabled()) {
1037
+ return;
1038
+ }
1039
+ const { referenceDate, value, range } = event.detail;
1040
+ const selectedDate = this.resolveSelectedDateFromEvent(range, value);
1041
+ if (selectedDate !== null && this.isDateDisabled(selectedDate)) {
1042
+ return;
1043
+ }
1044
+ this.referenceDate = toDateExports.toDate(referenceDate);
1045
+ const shouldEmitPublicEvent = this.resolvePublicEventEmissionForRange(range);
1046
+ this.setComponentValue(value === null ? null : toDateExports.toDate(value), shouldEmitPublicEvent && this.isInitialized);
1047
+ };
1048
+ /**
1049
+ * Alterna visibilidade do picker quando o input solicita.
1050
+ */
1051
+ this.handleTogglePicker = (event) => {
1052
+ if (this.isDisabled()) {
1053
+ return;
1054
+ }
1055
+ event.stopPropagation();
1056
+ const willOpen = !this.isPickerOpen;
1057
+ if (willOpen) {
1058
+ this.referenceDate = this.value === null ? toDateExports.toDate(new Date()) : toDateExports.toDate(this.value);
1059
+ }
1060
+ this.isPickerOpen = willOpen;
1061
+ };
1062
+ /**
1063
+ * Fecha o picker quando o clique acontece fora do host.
1064
+ */
1065
+ this.handleOutsideClick = (event) => {
1066
+ const eventPath = event.composedPath();
1067
+ if (eventPath.includes(this.el)) {
1068
+ return;
1069
+ }
1070
+ this.isPickerOpen = false;
1071
+ };
1072
+ this.outsideClickListenerAttached = false;
1073
+ /**
1074
+ * Fecha o picker ao pressionar Escape, devolvendo o foco ao input interno.
1075
+ *
1076
+ * @param event - Evento de teclado disparado em qualquer descendente do componente.
1077
+ */
1078
+ this.handlePickerKeydown = (event) => {
1079
+ if (event.key !== 'Escape' || !this.isPickerOpen)
1080
+ return;
1081
+ event.stopPropagation();
1082
+ this.isPickerOpen = false;
1083
+ this.getNativeInputElement()?.focus();
1084
+ };
1085
+ }
1086
+ formDisabledCallback(disabled) {
1087
+ this.formDisabled = disabled;
1088
+ }
1089
+ /** API nativa de reset de form-associated custom elements. */
1090
+ formResetCallback() {
1091
+ this.customValidationMessage = '';
1092
+ this.validatorMessage = null;
1093
+ this.validationRunId++;
1094
+ this.restoreSelection(this.initialFormValue);
1095
+ }
1096
+ /** API nativa de restauração de estado (histórico/autofill) do formulário. */
1097
+ formStateRestoreCallback(state) {
1098
+ if (typeof state !== 'string') {
1099
+ this.restoreSelection(null);
1100
+ return;
1101
+ }
1102
+ if (this.isRangeRestoreMode()) {
1103
+ this.restoreRangeStateFromSerialized(state);
1104
+ return;
1105
+ }
1106
+ this.restoreSingleStateFromSerialized(state);
1107
+ }
1108
+ /**
1109
+ * Revalida o modo sempre que a prop mudar.
1110
+ *
1111
+ * @param newValue - Valor recebido via atributo/prop.
1112
+ */
1113
+ handleModeChange(newValue) {
1114
+ this.ensureValidMode(newValue);
1115
+ if (this.selectionMode === 'range' && this.mode !== DATETIME_PICKER_MODE.DATE) {
1116
+ this.selectionMode = 'single';
1117
+ return;
1118
+ }
1119
+ this.updateFormInternals();
1120
+ }
1121
+ /** Revalida o estado do formulário quando required mudar. */
1122
+ handleRequiredChange() {
1123
+ this.updateFormInternals();
1124
+ }
1125
+ handleConstraintChange() {
1126
+ this.updateFormInternals();
1127
+ }
1128
+ /** Exclui o valor do FormData enquanto o componente estiver desabilitado. */
1129
+ handleDisabledChange() {
1130
+ this.updateFormInternals();
1131
+ }
1132
+ /** Reage a mudanças no modo de seleção e limpa intervalo quando necessário. */
1133
+ handleSelectionModeChange(newValue) {
1134
+ this.ensureValidSelectionMode(newValue);
1135
+ if (this.selectionMode === 'range' && this.mode !== DATETIME_PICKER_MODE.DATE) {
1136
+ this.mode = DATETIME_PICKER_MODE.DATE;
1137
+ return;
1138
+ }
1139
+ if (this.selectionMode === 'single') {
1140
+ this.clearRangeState();
1141
+ return;
1142
+ }
1143
+ this.updateFormInternals();
1144
+ }
1145
+ /** Revalida o dia inicial da semana sempre que a prop mudar. */
1146
+ handleWeekStartsOnChange(newValue) {
1147
+ this.ensureValidWeekStartsOn(newValue);
1148
+ }
1149
+ /**
1150
+ * Aplica ou limpa a seleção da data atual conforme o novo valor da prop.
1151
+ *
1152
+ * @param newValue - Novo estado da prop.
1153
+ */
1154
+ handleInitialMomentChange(newValue) {
1155
+ this.applyInitialMoment(newValue, this.isInitialized);
1156
+ this.initialFormValue = this.cloneDate(this.value);
1157
+ }
1158
+ /** Sincroniza alterações externas do valor com o estado visual e o formulário nativo. */
1159
+ handleValueChange(newValue) {
1160
+ const normalizedValue = newValue instanceof Date && !Number.isNaN(newValue.getTime()) ? toDateExports.toDate(newValue) : null;
1161
+ if (newValue !== null && normalizedValue === null) {
1162
+ this.value = null;
1163
+ return;
1164
+ }
1165
+ if (normalizedValue !== null) {
1166
+ this.referenceDate = normalizedValue;
1167
+ }
1168
+ this.syncCanonicalValues();
1169
+ this.updateFormInternals();
1170
+ }
1171
+ /** Converte alterações externas no valor serializado sem mudar o tipo da prop legada `value`. */
1172
+ handleSerializedValueChange(newValue) {
1173
+ if (this.syncingCanonicalValues || newValue === undefined)
1174
+ return;
1175
+ this.restoreSerializedValue(newValue);
1176
+ }
1177
+ /** Mantém `valueAsDate` e a prop legada `value` apontando para o mesmo estado observável. */
1178
+ handleValueAsDateChange(newValue) {
1179
+ if (this.syncingCanonicalValues || newValue === undefined)
1180
+ return;
1181
+ const normalizedValue = newValue instanceof Date && !Number.isNaN(newValue.getTime()) ? toDateExports.toDate(newValue) : null;
1182
+ if (this.sameDate(this.value, normalizedValue))
1183
+ return;
1184
+ this.value = normalizedValue;
1185
+ }
1186
+ handlePickerOpenChange(isOpen) {
1187
+ if (isOpen) {
1188
+ this.attachOutsideClickListener();
1189
+ }
1190
+ else {
1191
+ this.detachOutsideClickListener();
1192
+ }
1193
+ }
1194
+ /**
1195
+ * Recalcula a lista de datas desabilitadas quando a prop mudar.
1196
+ *
1197
+ * @param newValue - Nova configuração recebida via prop.
1198
+ */
1199
+ handleDisabledDatesChange(newValue) {
1200
+ this.syncDisabledDates(newValue);
1201
+ }
1202
+ handleRangeValueChange(newValue) {
1203
+ if (!newValue || this.selectionMode !== 'range')
1204
+ return;
1205
+ this.rangeStart = this.cloneDate(newValue.start);
1206
+ this.rangeEnd = this.cloneDate(newValue.end);
1207
+ const nextValue = newValue.end ?? newValue.start;
1208
+ this.referenceDate = nextValue ? toDateExports.toDate(nextValue) : this.referenceDate;
1209
+ this.setComponentValue(nextValue);
1210
+ }
1211
+ /** Registra o listener global somente enquanto o picker está aberto. */
1212
+ connectedCallback() {
1213
+ if (this.isPickerOpen)
1214
+ this.attachOutsideClickListener();
1215
+ }
1216
+ /** Remove o listener global para evitar vazamento de eventos ao desmontar. */
1217
+ disconnectedCallback() {
1218
+ this.detachOutsideClickListener();
1219
+ }
1220
+ /**
1221
+ * Normaliza o modo antes da primeira renderização e aplica a data atual quando solicitado.
1222
+ */
1223
+ componentWillLoad() {
1224
+ this.referenceDate = resolveSsrLocalDate(this.el, this.referenceDate);
1225
+ this.initializeMode();
1226
+ this.initializeSelectionMode();
1227
+ this.initializeWeekStartsOn();
1228
+ this.initializeDisabledDates();
1229
+ this.initializeDefaultValue();
1230
+ if (this.serializedValue !== undefined) {
1231
+ this.restoreSerializedValue(this.serializedValue);
1232
+ }
1233
+ else if (this.valueAsDate !== undefined) {
1234
+ this.handleValueAsDateChange(this.valueAsDate);
1235
+ }
1236
+ this.initialFormValue = this.cloneDate(this.value);
1237
+ this.syncCanonicalValues();
1238
+ this.updateFormInternals();
1239
+ }
1240
+ componentDidLoad() {
1241
+ this.isInitialized = true;
1242
+ this.hasFeedbackSlot = this.el.querySelector('[slot="feedback"]') !== null;
1243
+ }
1244
+ /**
1245
+ * Define programaticamente as datas desabilitadas por meio de array.
1246
+ *
1247
+ * Útil quando o componente é usado via HTML e o consumidor precisa enviar
1248
+ * uma lista tipada em runtime.
1249
+ *
1250
+ * @param dates - Lista de datas (Date|string) a bloquear.
1251
+ */
1252
+ async setDisabledDates(dates) {
1253
+ this.syncDisabledDates(dates);
1254
+ }
1255
+ /** Define o valor atual de forma imperativa aceitando Date, string serializada ou null. */
1256
+ async setValue(value) {
1257
+ if (this.isDisabled()) {
1258
+ return;
1259
+ }
1260
+ const nextValue = this.parseMethodValue(value, this.mode);
1261
+ if (nextValue !== null && this.isDateDisabled(nextValue)) {
1262
+ this.setComponentValue(null);
1263
+ return;
1264
+ }
1265
+ if (this.selectionMode === 'single') {
1266
+ this.rangeStart = null;
1267
+ this.rangeEnd = null;
1268
+ }
1269
+ this.referenceDate = nextValue === null ? toDateExports.toDate(new Date()) : toDateExports.toDate(nextValue);
1270
+ this.setComponentValue(nextValue);
1271
+ }
1272
+ /** Retorna uma cópia do valor selecionado atualmente. */
1273
+ async getValue() {
1274
+ return this.cloneDate(this.value);
1275
+ }
1276
+ /** Limpa valor e intervalo selecionados. */
1277
+ async clear() {
1278
+ this.rangeStart = null;
1279
+ this.rangeEnd = null;
1280
+ this.referenceDate = toDateExports.toDate(new Date());
1281
+ this.setComponentValue(null);
1282
+ }
1283
+ /** Abre o picker quando o componente estiver habilitado. */
1284
+ async open() {
1285
+ if (this.isDisabled()) {
1286
+ return;
1287
+ }
1288
+ this.referenceDate = this.value === null ? toDateExports.toDate(new Date()) : toDateExports.toDate(this.value);
1289
+ this.isPickerOpen = true;
1290
+ }
1291
+ /** Fecha o picker. */
1292
+ async close() {
1293
+ this.isPickerOpen = false;
1294
+ }
1295
+ /** Alterna o estado de abertura do picker. */
1296
+ async toggle() {
1297
+ if (this.isPickerOpen) {
1298
+ await this.close();
1299
+ return;
1300
+ }
1301
+ await this.open();
1302
+ }
1303
+ /** Move o foco para o input nativo interno. */
1304
+ async focusInput() {
1305
+ this.getNativeInputElement()?.focus();
1306
+ }
1307
+ /** Define intervalo de datas de forma imperativa, forçando modo date e selectionMode range. */
1308
+ async setRange(start, end) {
1309
+ if (this.isDisabled()) {
1310
+ return;
1311
+ }
1312
+ this.selectionMode = 'range';
1313
+ this.mode = DATETIME_PICKER_MODE.DATE;
1314
+ const normalizedStart = this.parseMethodValue(start, DATETIME_PICKER_MODE.DATE);
1315
+ const normalizedEnd = this.parseMethodValue(end, DATETIME_PICKER_MODE.DATE);
1316
+ if ((normalizedStart !== null && this.isDateDisabled(normalizedStart)) ||
1317
+ (normalizedEnd !== null && this.isDateDisabled(normalizedEnd))) {
1318
+ this.clearRangeState();
1319
+ return;
1320
+ }
1321
+ this.rangeStart = this.cloneDate(normalizedStart);
1322
+ this.rangeEnd = this.cloneDate(normalizedEnd);
1323
+ const nextValue = normalizedEnd ?? normalizedStart;
1324
+ this.referenceDate = nextValue === null ? toDateExports.toDate(new Date()) : toDateExports.toDate(nextValue);
1325
+ this.setComponentValue(nextValue);
1326
+ }
1327
+ /**
1328
+ * Retorna o intervalo de datas selecionado quando em modo `selectionMode="range"`.
1329
+ *
1330
+ * @returns Objeto com datas `start` e `end`, ou `null` se não estiver em modo range.
1331
+ */
1332
+ async getRange() {
1333
+ if (this.selectionMode !== 'range' || this.mode !== DATETIME_PICKER_MODE.DATE) {
1334
+ return null;
1335
+ }
1336
+ return {
1337
+ start: this.cloneDate(this.rangeStart),
1338
+ end: this.cloneDate(this.rangeEnd),
1339
+ };
1340
+ }
1341
+ /**
1342
+ * Consulta se o picker está atualmente aberto.
1343
+ *
1344
+ * @returns `true` se o picker está visível, `false` caso contrário.
1345
+ */
1346
+ async isOpen() {
1347
+ return this.isPickerOpen;
1348
+ }
1349
+ /** Restaura o estado inicial atualmente registrado para reset. */
1350
+ async resetToInitial() {
1351
+ this.restoreSelection(this.initialFormValue);
1352
+ }
1353
+ /** Permite que consumidores acionem validação nativa do formulário via host. */
1354
+ async checkValidity() {
1355
+ return this.elementInternals.checkValidity();
1356
+ }
1357
+ /** Permite exibir mensagens nativas de validação no host. */
1358
+ async reportValidity() {
1359
+ return this.elementInternals.reportValidity();
1360
+ }
1361
+ /** Define ou limpa uma mensagem de validade customizada. */
1362
+ async setCustomValidity(message) {
1363
+ this.customValidationMessage = message;
1364
+ this.syncFormValidity();
1365
+ }
1366
+ /** Executa o validator do picker e retorna se a seleção atual é válida. */
1367
+ async validate() {
1368
+ const validator = resolveFormValidator(this.validator);
1369
+ if (!validator || this.isDisabled())
1370
+ return this.checkValidity();
1371
+ const runId = ++this.validationRunId;
1372
+ this.isValidating = true;
1373
+ this.validatorMessage = null;
1374
+ this.syncFormValidity();
1375
+ this.brDatetimePickerValidationChange.emit({ validating: true, valid: null, message: null });
1376
+ const value = this.selectionMode === 'range'
1377
+ ? { start: this.cloneDate(this.rangeStart), end: this.cloneDate(this.rangeEnd) }
1378
+ : this.cloneDate(this.value);
1379
+ const message = await runFormValidator(validator, value);
1380
+ if (runId !== this.validationRunId)
1381
+ return false;
1382
+ this.validatorMessage = message;
1383
+ this.isValidating = false;
1384
+ this.syncFormValidity();
1385
+ const valid = message === null && (await this.checkValidity());
1386
+ this.brDatetimePickerValidationChange.emit({ validating: false, valid, message });
1387
+ return valid;
1388
+ }
1389
+ /** Retorna um snapshot serializável da Constraint Validation API. */
1390
+ async getValidationState() {
1391
+ return getFormValidationState(this.elementInternals);
1392
+ }
1393
+ /**
1394
+ * Valida o modo de seleção e corrige para padrão se inválido.
1395
+ *
1396
+ * @param value - Modo informado pelo consumidor do componente.
1397
+ */
1398
+ ensureValidSelectionMode(value) {
1399
+ this.selectionMode = normalizeDatetimePickerSelectionMode(value);
1400
+ }
1401
+ /**
1402
+ * Normaliza o modo de seleção logo na inicialização.
1403
+ */
1404
+ initializeSelectionMode() {
1405
+ this.handleSelectionModeChange(this.selectionMode);
1406
+ }
1407
+ /** Normaliza o dia inicial da semana logo na inicialização. */
1408
+ initializeWeekStartsOn() {
1409
+ this.handleWeekStartsOnChange(this.weekStartsOn);
1410
+ }
1411
+ /** Valida o dia inicial da semana e corrige para padrão quando necessário. */
1412
+ ensureValidWeekStartsOn(value) {
1413
+ this.weekStartsOn = normalizeDatetimePickerWeekStartsOn(value);
1414
+ }
1415
+ /**
1416
+ * Limpa o estado do intervalo de datas ao mudar para modo single.
1417
+ */
1418
+ clearRangeState() {
1419
+ this.rangeStart = null;
1420
+ this.rangeEnd = null;
1421
+ this.updateFormInternals();
1422
+ }
1423
+ /** Indica quando o componente está operando em seleção de intervalo por data. */
1424
+ isRangeDateSelectionMode() {
1425
+ return this.selectionMode === 'range' && this.mode === DATETIME_PICKER_MODE.DATE;
1426
+ }
1427
+ /**
1428
+ * Resolve se o evento público deve ser emitido após um update vindo dos subcomponentes.
1429
+ *
1430
+ * No modo range, o evento externo só é emitido no clique final (quando `end` é definido).
1431
+ */
1432
+ resolvePublicEventEmissionForRange(range) {
1433
+ if (!this.isRangeDateSelectionMode()) {
1434
+ return true;
1435
+ }
1436
+ if (range === undefined) {
1437
+ return false;
1438
+ }
1439
+ const isFinalRangeClick = this.rangeEnd === null && range.end !== null;
1440
+ this.setRangeState(range);
1441
+ return isFinalRangeClick;
1442
+ }
1443
+ /** Resolve a data efetivamente selecionada no evento para validar bloqueio em single/range. */
1444
+ resolveSelectedDateFromEvent(range, value) {
1445
+ if (!this.isRangeDateSelectionMode() || range === undefined) {
1446
+ return value;
1447
+ }
1448
+ return range.end ?? range.start ?? value;
1449
+ }
1450
+ attachOutsideClickListener() {
1451
+ if (this.outsideClickListenerAttached)
1452
+ return;
1453
+ document.addEventListener('click', this.handleOutsideClick);
1454
+ this.outsideClickListenerAttached = true;
1455
+ }
1456
+ detachOutsideClickListener() {
1457
+ if (!this.outsideClickListenerAttached)
1458
+ return;
1459
+ document.removeEventListener('click', this.handleOutsideClick);
1460
+ this.outsideClickListenerAttached = false;
1461
+ }
1462
+ /**
1463
+ * Garante que o componente inicie com um modo suportado.
1464
+ */
1465
+ initializeMode() {
1466
+ this.ensureValidMode(this.mode);
1467
+ }
1468
+ /**
1469
+ * Normaliza a coleção de datas desabilitadas na inicialização.
1470
+ */
1471
+ initializeDisabledDates() {
1472
+ this.syncDisabledDates(this.disabledDates);
1473
+ }
1474
+ /**
1475
+ * Normaliza e aplica as datas desabilitadas, limpando valor atual quando necessário.
1476
+ *
1477
+ * @param value - Valor bruto recebido por prop/atributo ou método público.
1478
+ */
1479
+ syncDisabledDates(value) {
1480
+ this.normalizedDisabledDates = normalizeDatetimePickerDisabledDates(value);
1481
+ if (this.rangeStart !== null && this.isDateDisabled(this.rangeStart)) {
1482
+ this.rangeStart = null;
1483
+ }
1484
+ if (this.rangeEnd !== null && this.isDateDisabled(this.rangeEnd)) {
1485
+ this.rangeEnd = null;
1486
+ }
1487
+ if (this.value !== null && this.isDateDisabled(this.value)) {
1488
+ this.setComponentValue(null);
1489
+ }
1490
+ }
1491
+ /**
1492
+ * Aplica a seleção inicial configurada na prop.
1493
+ */
1494
+ initializeDefaultValue() {
1495
+ if (this.value instanceof Date && !Number.isNaN(this.value.getTime())) {
1496
+ this.referenceDate = toDateExports.toDate(this.value);
1497
+ return;
1498
+ }
1499
+ this.value = null;
1500
+ this.applyInitialMoment(this.initialMoment, false);
1501
+ }
1502
+ /**
1503
+ * Aplica a seleção inicial recebida, com normalização de valores inválidos.
1504
+ *
1505
+ * @param selection - Configuração de seleção inicial.
1506
+ */
1507
+ applyInitialMoment(selection, shouldEmitEvents = true) {
1508
+ if (this.isDisabled()) {
1509
+ return;
1510
+ }
1511
+ const normalizedSelection = normalizeDatetimePickerInitialMoment(selection);
1512
+ if (normalizedSelection === 'now') {
1513
+ const now = toDateExports.toDate(new Date());
1514
+ this.referenceDate = now;
1515
+ this.setComponentValue(now, shouldEmitEvents);
1516
+ return;
1517
+ }
1518
+ if (normalizedSelection === null) {
1519
+ this.rangeStart = null;
1520
+ this.rangeEnd = null;
1521
+ this.setComponentValue(null, shouldEmitEvents);
1522
+ return;
1523
+ }
1524
+ const selectedDate = toDateExports.toDate(normalizedSelection);
1525
+ if (this.isDateDisabled(selectedDate)) {
1526
+ this.setComponentValue(null, shouldEmitEvents);
1527
+ return;
1528
+ }
1529
+ this.referenceDate = selectedDate;
1530
+ this.rangeStart = null;
1531
+ this.rangeEnd = null;
1532
+ this.setComponentValue(selectedDate, shouldEmitEvents);
1533
+ }
1534
+ /** Indica se o estado serializado deve ser interpretado como intervalo. */
1535
+ isRangeRestoreMode() {
1536
+ return this.selectionMode === 'range' && this.mode === DATETIME_PICKER_MODE.DATE;
1537
+ }
1538
+ /** Restaura estado de intervalo a partir do valor serializado do formulário. */
1539
+ restoreRangeStateFromSerialized(serializedState) {
1540
+ const restoredRange = parseDatetimePickerSerializedRange(serializedState);
1541
+ if (restoredRange === null) {
1542
+ this.restoreSelection(null);
1543
+ return;
1544
+ }
1545
+ const { start, end } = restoredRange;
1546
+ this.rangeStart = start;
1547
+ this.rangeEnd = end;
1548
+ this.restoreSelection(end);
1549
+ }
1550
+ /** Restaura estado de seleção única a partir do valor serializado do formulário. */
1551
+ restoreSingleStateFromSerialized(serializedState) {
1552
+ const restoredValue = parseDatetimePickerSerializedValue(serializedState, this.mode, this.referenceDate);
1553
+ if (restoredValue !== null && this.isDateDisabled(restoredValue)) {
1554
+ this.restoreSelection(null);
1555
+ return;
1556
+ }
1557
+ this.restoreSelection(restoredValue);
1558
+ }
1559
+ /** Resolve Date|null a partir de valores aceitos pelos métodos públicos. */
1560
+ parseMethodValue(value, mode) {
1561
+ if (value === null) {
1562
+ return null;
1563
+ }
1564
+ if (value instanceof Date) {
1565
+ return Number.isNaN(value.getTime()) ? null : toDateExports.toDate(value);
1566
+ }
1567
+ return parseDatetimePickerSerializedValue(value, mode, this.referenceDate);
1568
+ }
1569
+ /** Aplica a ponte serializada usando os mesmos parsers já usados por restore de formulário. */
1570
+ restoreSerializedValue(serializedValue) {
1571
+ if (this.isRangeRestoreMode()) {
1572
+ this.restoreRangeStateFromSerialized(serializedValue);
1573
+ return;
1574
+ }
1575
+ this.restoreSingleStateFromSerialized(serializedValue);
1576
+ }
1577
+ /** Atualiza os nomes canônicos sem emitir eventos adicionais ou criar ciclos de watchers. */
1578
+ syncCanonicalValues() {
1579
+ const nextSerializedValue = this.getSerializedValue();
1580
+ const nextValueAsDate = this.cloneDate(this.value);
1581
+ if (this.serializedValue === nextSerializedValue && this.sameDate(this.valueAsDate ?? null, nextValueAsDate))
1582
+ return;
1583
+ this.syncingCanonicalValues = true;
1584
+ this.serializedValue = nextSerializedValue;
1585
+ this.valueAsDate = nextValueAsDate;
1586
+ this.syncingCanonicalValues = false;
1587
+ }
1588
+ /** Retorna o mesmo valor que será submetido pelo ElementInternals. */
1589
+ getSerializedValue() {
1590
+ const zero = (date) => (date === null ? null : setExports.set(date, { seconds: 0, milliseconds: 0 }));
1591
+ return (serializeDatetimePickerFormValue(this.value === null ? null : zero(this.value), {
1592
+ mode: this.mode,
1593
+ selectionMode: this.selectionMode,
1594
+ rangeStart: zero(this.rangeStart),
1595
+ rangeEnd: zero(this.rangeEnd),
1596
+ referenceDate: zero(this.referenceDate) ?? this.referenceDate,
1597
+ }) ?? '');
1598
+ }
1599
+ sameDate(left, right) {
1600
+ return left === right || (left !== null && right !== null && left.getTime() === right.getTime());
1601
+ }
1602
+ /** Busca o input nativo interno para ações imperativas de foco. */
1603
+ getNativeInputElement() {
1604
+ return this.el.shadowRoot
1605
+ ?.querySelector('br-datetime-input')
1606
+ ?.shadowRoot?.querySelector('br-input')
1607
+ ?.shadowRoot?.querySelector('input');
1608
+ }
1609
+ /** Atualiza estado interno, FormData e validação com uma única chamada. */
1610
+ setComponentValue(nextValue, shouldEmitPublicEvent = true) {
1611
+ this.value = this.cloneDate(nextValue);
1612
+ this.syncCanonicalValues();
1613
+ if (shouldEmitPublicEvent && this.isInitialized) {
1614
+ this.emitDateStateChange();
1615
+ void this.validate();
1616
+ }
1617
+ this.updateFormInternals();
1618
+ }
1619
+ /** Propaga o estado atual consolidado para consumidores externos do componente raiz. */
1620
+ emitDateStateChange() {
1621
+ const range = this.selectionMode === 'range' && this.mode === DATETIME_PICKER_MODE.DATE
1622
+ ? {
1623
+ start: this.cloneDate(this.rangeStart),
1624
+ end: this.cloneDate(this.rangeEnd),
1625
+ }
1626
+ : undefined;
1627
+ const rangeDates = range !== undefined && range.start !== null && range.end !== null
1628
+ ? this.buildRangeDatesState(range.start, range.end)
1629
+ : undefined;
1630
+ this.dateStateChange.emit({
1631
+ referenceDate: this.cloneDate(this.referenceDate),
1632
+ value: this.cloneDate(this.value),
1633
+ range,
1634
+ rangeDates,
1635
+ });
1636
+ if (range)
1637
+ this.rangeValue = range;
1638
+ this.valueChange.emit(this.cloneDate(this.value));
1639
+ dispatchNativeFormEvent(this.el, 'input');
1640
+ dispatchNativeFormEvent(this.el, 'change');
1641
+ }
1642
+ /** Expande o intervalo completo e marca quais dias estão desabilitados. */
1643
+ buildRangeDatesState(start, end) {
1644
+ const intervalStart = start.getTime() <= end.getTime() ? start : end;
1645
+ const intervalEnd = start.getTime() <= end.getTime() ? end : start;
1646
+ return eachDayOfIntervalExports.eachDayOfInterval({
1647
+ start: intervalStart,
1648
+ end: intervalEnd,
1649
+ }).map((date) => ({
1650
+ date: toDateExports.toDate(date),
1651
+ disabled: this.isDateDisabled(date),
1652
+ }));
1653
+ }
1654
+ /** Restaura seleção e data de referência a partir de uma data já validada. */
1655
+ restoreSelection(nextValue) {
1656
+ this.value = this.cloneDate(nextValue);
1657
+ if (this.selectionMode === 'single') {
1658
+ this.rangeStart = null;
1659
+ this.rangeEnd = null;
1660
+ }
1661
+ this.referenceDate = nextValue === null ? toDateExports.toDate(new Date()) : toDateExports.toDate(nextValue);
1662
+ this.syncCanonicalValues();
1663
+ this.updateFormInternals();
1664
+ }
1665
+ /** Atualiza o estado local de intervalo a partir do evento do calendário. */
1666
+ setRangeState(nextRange) {
1667
+ this.rangeStart = this.cloneDate(nextRange?.start ?? null);
1668
+ this.rangeEnd = this.cloneDate(nextRange?.end ?? null);
1669
+ }
1670
+ /** Mantém ElementInternals sincronizado com estado e regras do componente. */
1671
+ updateFormInternals() {
1672
+ this.syncFormValue();
1673
+ this.syncFormValidity();
1674
+ }
1675
+ /** Atualiza o valor submetido no FormData do form-associated custom element. */
1676
+ syncFormValue() {
1677
+ try {
1678
+ const zero = (d) => (d === null ? null : setExports.set(d, { seconds: 0, milliseconds: 0 }));
1679
+ const nextValue = this.isDisabled()
1680
+ ? null
1681
+ : serializeDatetimePickerFormValue(this.value === null ? null : zero(this.value), {
1682
+ mode: this.mode,
1683
+ selectionMode: this.selectionMode,
1684
+ rangeStart: zero(this.rangeStart),
1685
+ rangeEnd: zero(this.rangeEnd),
1686
+ referenceDate: zero(this.referenceDate) ?? this.referenceDate,
1687
+ });
1688
+ this.elementInternals.setFormValue(nextValue);
1689
+ }
1690
+ catch {
1691
+ // Ambientes de teste podem esconder attachInternals parcialmente.
1692
+ }
1693
+ }
1694
+ /** Espelha a regra de required no mecanismo nativo de validade. */
1695
+ // biome-ignore lint/complexity/noExcessiveCognitiveComplexity: consolida flags nativos relacionados sem esconder a precedência das mensagens.
1696
+ syncFormValidity() {
1697
+ try {
1698
+ const missing = hasDatetimePickerMissingValue({
1699
+ required: this.required,
1700
+ disabled: this.isDisabled(),
1701
+ value: this.value,
1702
+ mode: this.mode,
1703
+ selectionMode: this.selectionMode,
1704
+ rangeStart: this.rangeStart,
1705
+ rangeEnd: this.rangeEnd});
1706
+ const min = this.parseConstraintValue(this.min);
1707
+ const max = this.parseConstraintValue(this.max);
1708
+ const values = this.selectionMode === 'range' ? [this.rangeStart, this.rangeEnd] : [this.value];
1709
+ const rangeUnderflow = min !== null && values.some((value) => value !== null && value.getTime() < min.getTime());
1710
+ const rangeOverflow = max !== null && values.some((value) => value !== null && value.getTime() > max.getTime());
1711
+ const invalidRange = this.selectionMode === 'range' &&
1712
+ this.rangeStart !== null &&
1713
+ this.rangeEnd !== null &&
1714
+ this.rangeStart.getTime() > this.rangeEnd.getTime();
1715
+ const flags = {
1716
+ customError: this.customValidationMessage !== '' || Boolean(this.validatorMessage) || invalidRange,
1717
+ rangeOverflow,
1718
+ rangeUnderflow,
1719
+ valueMissing: missing,
1720
+ };
1721
+ const message = this.customValidationMessage ||
1722
+ this.validatorMessage ||
1723
+ (missing
1724
+ ? 'Preencha este campo.'
1725
+ : invalidRange
1726
+ ? 'A data inicial deve anteceder a data final.'
1727
+ : rangeUnderflow
1728
+ ? 'Selecione uma data igual ou posterior ao mínimo.'
1729
+ : rangeOverflow
1730
+ ? 'Selecione uma data igual ou anterior ao máximo.'
1731
+ : '');
1732
+ setFormValidity(this.elementInternals, flags, message, this.getNativeInputElement());
1733
+ }
1734
+ catch {
1735
+ // Ambientes sem ElementInternals completo não devem falhar.
1736
+ }
1737
+ }
1738
+ parseConstraintValue(value) {
1739
+ return value === null ? null : this.parseMethodValue(value, this.mode);
1740
+ }
1741
+ isDisabled() {
1742
+ return isFormControlDisabled(this.disabled, this.formDisabled);
1743
+ }
1744
+ /** Duplica datas para evitar compartilhamento de referência mutável. */
1745
+ cloneDate(value) {
1746
+ return value === null ? null : toDateExports.toDate(value);
1747
+ }
1748
+ /**
1749
+ * Verifica se a data pertence ao conjunto de dias bloqueados.
1750
+ *
1751
+ * @param date - Data candidata à seleção.
1752
+ * @returns `true` quando o dia estiver desabilitado.
1753
+ */
1754
+ isDateDisabled(date) {
1755
+ return this.normalizedDisabledDates.some((disabledDate) => isSameDayExports.isSameDay(disabledDate, date));
1756
+ }
1757
+ /**
1758
+ * Corrige valores inválidos para o modo padrão, preservando a consistência do estado refletido.
1759
+ *
1760
+ * @param value - Modo informado pelo consumidor do componente.
1761
+ */
1762
+ ensureValidMode(value) {
1763
+ const normalizedMode = normalizeDatetimePickerMode(value);
1764
+ if (normalizedMode !== value) {
1765
+ this.mode = normalizedMode;
1766
+ }
1767
+ }
1768
+ /**
1769
+ * Resolve a função de renderização associada ao modo atual.
1770
+ *
1771
+ * @returns Função que renderiza o conteúdo interno do picker.
1772
+ */
1773
+ getModeRenderer() {
1774
+ return this.modeRendererMap[this.mode];
1775
+ }
1776
+ /** Retorna o conjunto de classes base aplicadas ao container do componente. */
1777
+ getCssClassMap() {
1778
+ return {
1779
+ 'br-datetime-picker': true,
1780
+ };
1781
+ }
1782
+ /**
1783
+ * Agrupa os bindings compartilhados para evitar divergência entre data e horário.
1784
+ */
1785
+ getSharedDateStateBindings() {
1786
+ return {
1787
+ referenceDate: this.referenceDate,
1788
+ value: this.value,
1789
+ selectionMode: this.selectionMode,
1790
+ rangeStart: this.rangeStart,
1791
+ rangeEnd: this.rangeEnd,
1792
+ onDateStateChange: this.handleDateStateChange,
1793
+ };
1794
+ }
1795
+ /** Renderiza o campo de entrada responsável por abrir e sincronizar o picker. */
1796
+ renderInputField() {
1797
+ return (h("br-datetime-input", { referenceDate: this.referenceDate, value: this.value, selectionMode: this.selectionMode, rangeStart: this.rangeStart, rangeEnd: this.rangeEnd, placeholder: this.placeholder, mode: this.mode, disabled: this.isDisabled(), onDateStateChange: this.handleDateStateChange, onTogglePicker: this.handleTogglePicker, exportparts: "container: input-container, input: input-field, icon: input-icon" }));
1798
+ }
1799
+ /** Renderiza apenas o seletor de data. */
1800
+ renderDatePicker() {
1801
+ const effectiveSelectionMode = this.mode === DATETIME_PICKER_MODE.DATE ? this.selectionMode : 'single';
1802
+ return (h("br-date-picker", { ...this.getSharedDateStateBindings(), selectionMode: effectiveSelectionMode, weekStartsOn: this.weekStartsOn, locale: this.locale, disabled: this.isDisabled(), disabledDates: this.normalizedDisabledDates, fixedRowCount: this.fixedRowCount }));
1803
+ }
1804
+ /** Renderiza apenas o seletor de hora. */
1805
+ renderTimePicker() {
1806
+ return h("br-time-picker", { ...this.getSharedDateStateBindings(), disabled: this.isDisabled() });
1807
+ }
1808
+ /**
1809
+ * Renderiza a combinação de data e horário no modo `datetime`.
1810
+ */
1811
+ renderDateTimePicker() {
1812
+ return (h(Fragment, null, this.renderDatePicker(), this.renderDivider(), this.renderTimePicker()));
1813
+ }
1814
+ /** Renderiza o separador visual entre data e hora no modo combinado. */
1815
+ renderDivider() {
1816
+ return h("br-divider", { thickness: "medium", color: "#e6e6e6", "margin-top": "10px", "margin-bottom": "10px" });
1817
+ }
1818
+ /**
1819
+ * Resolve o conteúdo interno conforme o modo atual do componente.
1820
+ */
1821
+ renderPickerContent() {
1822
+ if (!this.isPickerOpen) {
1823
+ return null;
1824
+ }
1825
+ const renderContent = this.getModeRenderer();
1826
+ return h("br-card", { part: "panel" }, renderContent());
1827
+ }
1828
+ /**
1829
+ * Renderização principal do componente.
1830
+ */
1831
+ render() {
1832
+ return (h(Host, { key: '906849439dfc93b18952963b95e35da332e5018b', onKeyDown: this.handlePickerKeydown, "aria-busy": this.isValidating ? 'true' : null, "aria-describedby": this.hasFeedbackSlot || this.customValidationMessage || this.validatorMessage ? this.feedbackId : null, "aria-errormessage": this.customValidationMessage || this.validatorMessage || this.hasFeedbackSlot ? this.feedbackId : null }, h("div", { key: '8a77432dc84c6897d7ffb2e403f72d42e333230a', class: this.getCssClassMap(), part: "container" }, this.renderInputField(), this.renderPickerContent()), h("div", { key: '1e3f4df6f301fbb54d76eea49848ec7910bc3f33', id: this.feedbackId, part: "feedback", hidden: !this.hasFeedbackSlot && !this.customValidationMessage && !this.validatorMessage }, h("slot", { key: '7000d3c447c5bfa1f674c78024a1e58ca69652a3', name: "feedback", onSlotchange: (event) => (this.hasFeedbackSlot = hasAssignedSlotContent(event.currentTarget)) }), !this.hasFeedbackSlot && (this.customValidationMessage || this.validatorMessage) ? (h("br-message", { state: "danger", message: this.customValidationMessage || this.validatorMessage })) : null)));
1833
+ }
1834
+ static get formAssociated() { return true; }
1835
+ get el() { return getElement(this); }
1836
+ static get watchers() { return {
1837
+ "mode": [{
1838
+ "handleModeChange": 0
1839
+ }],
1840
+ "required": [{
1841
+ "handleRequiredChange": 0
1842
+ }],
1843
+ "min": [{
1844
+ "handleConstraintChange": 0
1845
+ }],
1846
+ "max": [{
1847
+ "handleConstraintChange": 0
1848
+ }],
1849
+ "disabled": [{
1850
+ "handleDisabledChange": 0
1851
+ }],
1852
+ "selectionMode": [{
1853
+ "handleSelectionModeChange": 0
1854
+ }],
1855
+ "weekStartsOn": [{
1856
+ "handleWeekStartsOnChange": 0
1857
+ }],
1858
+ "initialMoment": [{
1859
+ "handleInitialMomentChange": 0
1860
+ }],
1861
+ "value": [{
1862
+ "handleValueChange": 0
1863
+ }],
1864
+ "serializedValue": [{
1865
+ "handleSerializedValueChange": 0
1866
+ }],
1867
+ "valueAsDate": [{
1868
+ "handleValueAsDateChange": 0
1869
+ }],
1870
+ "isPickerOpen": [{
1871
+ "handlePickerOpenChange": 0
1872
+ }],
1873
+ "disabledDates": [{
1874
+ "handleDisabledDatesChange": 0
1875
+ }],
1876
+ "rangeValue": [{
1877
+ "handleRangeValueChange": 0
1878
+ }]
1879
+ }; }
1880
+ };
1881
+ let datetimePickerId = 0;
1882
+ DatetimePicker.style = datetimePickerCss();
1883
+
1884
+ export { DatetimePicker as br_datetime_picker };