@nova-design-system/nova-webcomponents 3.0.0 → 3.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (532) hide show
  1. package/dist/cjs/{constants-bcd6b2e2.js → constants-8fb8ccc0.js} +14 -1
  2. package/dist/cjs/constants-8fb8ccc0.js.map +1 -0
  3. package/dist/cjs/{index-9bda5507.js → index-108ddff0.js} +22 -6
  4. package/dist/cjs/index-108ddff0.js.map +1 -0
  5. package/dist/cjs/index.cjs.js +5 -471
  6. package/dist/cjs/index.cjs.js.map +1 -1
  7. package/dist/cjs/loader.cjs.js +2 -2
  8. package/dist/cjs/native.cjs.js +2 -2
  9. package/dist/cjs/nv-alert.cjs.entry.js +6 -6
  10. package/dist/cjs/nv-alert.cjs.entry.js.map +1 -1
  11. package/dist/cjs/nv-avatar.cjs.entry.js +2 -2
  12. package/dist/cjs/nv-badge_2.cjs.entry.js +18 -9
  13. package/dist/cjs/nv-badge_2.cjs.entry.js.map +1 -1
  14. package/dist/cjs/nv-breadcrumb.cjs.entry.js +1 -1
  15. package/dist/cjs/nv-breadcrumbs.cjs.entry.js +1 -1
  16. package/dist/cjs/nv-button.cjs.entry.js +2 -2
  17. package/dist/cjs/nv-calendar.cjs.entry.js +821 -843
  18. package/dist/cjs/nv-calendar.cjs.entry.js.map +1 -1
  19. package/dist/cjs/nv-col.cjs.entry.js +1 -1
  20. package/dist/cjs/nv-datagrid.cjs.entry.js +423 -94
  21. package/dist/cjs/nv-datagrid.cjs.entry.js.map +1 -1
  22. package/dist/cjs/nv-datagridcolumn.cjs.entry.js +2 -2
  23. package/dist/cjs/nv-datagridcolumn.cjs.entry.js.map +1 -1
  24. package/dist/cjs/nv-dialog.cjs.entry.js +19 -13
  25. package/dist/cjs/nv-dialog.cjs.entry.js.map +1 -1
  26. package/dist/cjs/nv-dialogfooter_2.cjs.entry.js +2 -2
  27. package/dist/cjs/nv-fieldcheckbox.cjs.entry.js +1 -1
  28. package/dist/cjs/nv-fielddate.cjs.entry.js +9 -18
  29. package/dist/cjs/nv-fielddate.cjs.entry.js.map +1 -1
  30. package/dist/cjs/nv-fielddaterange.cjs.entry.js +85 -32
  31. package/dist/cjs/nv-fielddaterange.cjs.entry.js.map +1 -1
  32. package/dist/cjs/nv-fielddropdown.cjs.entry.js +88 -57
  33. package/dist/cjs/nv-fielddropdown.cjs.entry.js.map +1 -1
  34. package/dist/cjs/nv-fielddropdownitem.cjs.entry.js +2 -2
  35. package/dist/cjs/nv-fieldmultiselect.cjs.entry.js +122 -104
  36. package/dist/cjs/nv-fieldmultiselect.cjs.entry.js.map +1 -1
  37. package/dist/cjs/nv-fieldnumber.cjs.entry.js +9 -5
  38. package/dist/cjs/nv-fieldnumber.cjs.entry.js.map +1 -1
  39. package/dist/cjs/nv-fieldpassword.cjs.entry.js +9 -5
  40. package/dist/cjs/nv-fieldpassword.cjs.entry.js.map +1 -1
  41. package/dist/cjs/nv-fieldradio.cjs.entry.js +4 -4
  42. package/dist/cjs/nv-fieldselect.cjs.entry.js +11 -7
  43. package/dist/cjs/nv-fieldselect.cjs.entry.js.map +1 -1
  44. package/dist/cjs/nv-fieldslider.cjs.entry.js +663 -0
  45. package/dist/cjs/nv-fieldslider.cjs.entry.js.map +1 -0
  46. package/dist/cjs/nv-fieldtext.cjs.entry.js +9 -5
  47. package/dist/cjs/nv-fieldtext.cjs.entry.js.map +1 -1
  48. package/dist/cjs/nv-fieldtextarea.cjs.entry.js +9 -5
  49. package/dist/cjs/nv-fieldtextarea.cjs.entry.js.map +1 -1
  50. package/dist/cjs/nv-fieldtime.cjs.entry.js +16 -13
  51. package/dist/cjs/nv-fieldtime.cjs.entry.js.map +1 -1
  52. package/dist/cjs/nv-icon.cjs.entry.js +4 -4
  53. package/dist/cjs/nv-icon.cjs.entry.js.map +1 -1
  54. package/dist/cjs/nv-iconbutton_2.cjs.entry.js +3 -3
  55. package/dist/cjs/nv-menu.cjs.entry.js +4 -2
  56. package/dist/cjs/nv-menu.cjs.entry.js.map +1 -1
  57. package/dist/cjs/nv-menuitem.cjs.entry.js +2 -2
  58. package/dist/cjs/nv-popover.cjs.entry.js +2 -2
  59. package/dist/cjs/nv-row.cjs.entry.js +2 -2
  60. package/dist/cjs/nv-stack.cjs.entry.js +2 -2
  61. package/dist/cjs/nv-table.cjs.entry.js +3 -3
  62. package/dist/cjs/nv-table.cjs.entry.js.map +1 -1
  63. package/dist/cjs/nv-tablecolumn.cjs.entry.js +1 -1
  64. package/dist/cjs/nv-toggle.cjs.entry.js +3 -3
  65. package/dist/cjs/nv-tooltip.cjs.entry.js +3 -3
  66. package/dist/cjs/nv-tooltip.cjs.entry.js.map +1 -1
  67. package/dist/collection/collection-manifest.json +1 -0
  68. package/dist/collection/components/nv-alert/nv-alert.css +3 -0
  69. package/dist/collection/components/nv-alert/nv-alert.js +6 -11
  70. package/dist/collection/components/nv-alert/nv-alert.js.map +1 -1
  71. package/dist/collection/components/nv-badge/nv-badge.css +181 -1
  72. package/dist/collection/components/nv-badge/nv-badge.docs.js +20 -1
  73. package/dist/collection/components/nv-badge/nv-badge.docs.js.map +1 -1
  74. package/dist/collection/components/nv-badge/nv-badge.js +39 -15
  75. package/dist/collection/components/nv-badge/nv-badge.js.map +1 -1
  76. package/dist/collection/components/nv-breadcrumbs/nv-breadcrumbs.docs.js +0 -1
  77. package/dist/collection/components/nv-breadcrumbs/nv-breadcrumbs.docs.js.map +1 -1
  78. package/dist/collection/components/nv-calendar/nv-calendar.css +25 -2
  79. package/dist/collection/components/nv-calendar/nv-calendar.docs.js +33 -38
  80. package/dist/collection/components/nv-calendar/nv-calendar.docs.js.map +1 -1
  81. package/dist/collection/components/nv-calendar/nv-calendar.js +659 -897
  82. package/dist/collection/components/nv-calendar/nv-calendar.js.map +1 -1
  83. package/dist/collection/components/nv-calendar/nv-calendar.utils.js +202 -0
  84. package/dist/collection/components/nv-calendar/nv-calendar.utils.js.map +1 -0
  85. package/dist/collection/components/nv-calendar/test/nv-calendar.utils.test.js +667 -0
  86. package/dist/collection/components/nv-calendar/test/nv-calendar.utils.test.js.map +1 -0
  87. package/dist/collection/components/nv-datagrid/nv-datagrid.css +98 -0
  88. package/dist/collection/components/nv-datagrid/nv-datagrid.docs.js +232 -51
  89. package/dist/collection/components/nv-datagrid/nv-datagrid.docs.js.map +1 -1
  90. package/dist/collection/components/nv-datagrid/nv-datagrid.js +437 -160
  91. package/dist/collection/components/nv-datagrid/nv-datagrid.js.map +1 -1
  92. package/dist/collection/components/nv-datagridcolumn/nv-datagridcolumn.js +20 -1
  93. package/dist/collection/components/nv-datagridcolumn/nv-datagridcolumn.js.map +1 -1
  94. package/dist/collection/components/nv-dialog/nv-dialog.css +29 -5
  95. package/dist/collection/components/nv-dialog/nv-dialog.docs.js +0 -1
  96. package/dist/collection/components/nv-dialog/nv-dialog.docs.js.map +1 -1
  97. package/dist/collection/components/nv-dialog/nv-dialog.js +16 -10
  98. package/dist/collection/components/nv-dialog/nv-dialog.js.map +1 -1
  99. package/dist/collection/components/nv-fielddate/nv-fielddate.docs.js +16 -8
  100. package/dist/collection/components/nv-fielddate/nv-fielddate.docs.js.map +1 -1
  101. package/dist/collection/components/nv-fielddate/nv-fielddate.js +48 -39
  102. package/dist/collection/components/nv-fielddate/nv-fielddate.js.map +1 -1
  103. package/dist/collection/components/nv-fielddate/styles/nv-fielddate.css +14 -1
  104. package/dist/collection/components/nv-fielddaterange/nv-fielddaterange.docs.js +12 -15
  105. package/dist/collection/components/nv-fielddaterange/nv-fielddaterange.docs.js.map +1 -1
  106. package/dist/collection/components/nv-fielddaterange/nv-fielddaterange.js +147 -68
  107. package/dist/collection/components/nv-fielddaterange/nv-fielddaterange.js.map +1 -1
  108. package/dist/collection/components/nv-fielddaterange/styles/nv-fielddaterange.css +20 -12
  109. package/dist/collection/components/nv-fielddropdown/nv-fielddropdown.docs.js +16 -0
  110. package/dist/collection/components/nv-fielddropdown/nv-fielddropdown.docs.js.map +1 -1
  111. package/dist/collection/components/nv-fielddropdown/nv-fielddropdown.js +197 -103
  112. package/dist/collection/components/nv-fielddropdown/nv-fielddropdown.js.map +1 -1
  113. package/dist/collection/components/nv-fielddropdown/styles/nv-fielddropdown.css +36 -1
  114. package/dist/collection/components/nv-fielddropdownitem/nv-fielddropdownitem.js +1 -1
  115. package/dist/collection/components/nv-fielddropdownitemcheck/nv-fielddropdownitemcheck.js +1 -1
  116. package/dist/collection/components/nv-fieldmultiselect/nv-fieldmultiselect.docs.js +8 -1
  117. package/dist/collection/components/nv-fieldmultiselect/nv-fieldmultiselect.docs.js.map +1 -1
  118. package/dist/collection/components/nv-fieldmultiselect/nv-fieldmultiselect.js +228 -190
  119. package/dist/collection/components/nv-fieldmultiselect/nv-fieldmultiselect.js.map +1 -1
  120. package/dist/collection/components/nv-fieldmultiselect/{nv-fieldmultiselect.css → styles/nv-fieldmultiselect.css} +36 -1
  121. package/dist/collection/components/nv-fieldnumber/nv-fieldnumber.css +12 -1
  122. package/dist/collection/components/nv-fieldnumber/nv-fieldnumber.docs.js +8 -0
  123. package/dist/collection/components/nv-fieldnumber/nv-fieldnumber.docs.js.map +1 -1
  124. package/dist/collection/components/nv-fieldnumber/nv-fieldnumber.js +27 -3
  125. package/dist/collection/components/nv-fieldnumber/nv-fieldnumber.js.map +1 -1
  126. package/dist/collection/components/nv-fieldpassword/nv-fieldpassword.css +12 -1
  127. package/dist/collection/components/nv-fieldpassword/nv-fieldpassword.docs.js +8 -0
  128. package/dist/collection/components/nv-fieldpassword/nv-fieldpassword.docs.js.map +1 -1
  129. package/dist/collection/components/nv-fieldpassword/nv-fieldpassword.js +27 -3
  130. package/dist/collection/components/nv-fieldpassword/nv-fieldpassword.js.map +1 -1
  131. package/dist/collection/components/nv-fieldradio/nv-fieldradio.js +3 -3
  132. package/dist/collection/components/nv-fieldselect/nv-fieldselect.css +12 -1
  133. package/dist/collection/components/nv-fieldselect/nv-fieldselect.docs.js +8 -0
  134. package/dist/collection/components/nv-fieldselect/nv-fieldselect.docs.js.map +1 -1
  135. package/dist/collection/components/nv-fieldselect/nv-fieldselect.js +29 -5
  136. package/dist/collection/components/nv-fieldselect/nv-fieldselect.js.map +1 -1
  137. package/dist/collection/components/nv-fieldslider/nv-fieldslider.docs.js +264 -0
  138. package/dist/collection/components/nv-fieldslider/nv-fieldslider.docs.js.map +1 -0
  139. package/dist/collection/components/nv-fieldslider/nv-fieldslider.js +1035 -0
  140. package/dist/collection/components/nv-fieldslider/nv-fieldslider.js.map +1 -0
  141. package/dist/collection/components/nv-fieldslider/nv-fieldslider.utils.js +77 -0
  142. package/dist/collection/components/nv-fieldslider/nv-fieldslider.utils.js.map +1 -0
  143. package/dist/collection/components/nv-fieldslider/partials/field-input.js +33 -0
  144. package/dist/collection/components/nv-fieldslider/partials/field-input.js.map +1 -0
  145. package/dist/collection/components/nv-fieldslider/partials/range-thumb.js +34 -0
  146. package/dist/collection/components/nv-fieldslider/partials/range-thumb.js.map +1 -0
  147. package/dist/collection/components/nv-fieldslider/partials/single-thumb.js +18 -0
  148. package/dist/collection/components/nv-fieldslider/partials/single-thumb.js.map +1 -0
  149. package/dist/collection/components/nv-fieldslider/partials/tick-marks.js +18 -0
  150. package/dist/collection/components/nv-fieldslider/partials/tick-marks.js.map +1 -0
  151. package/dist/collection/components/nv-fieldslider/styles/nv-fieldslider.css +267 -0
  152. package/dist/collection/components/nv-fieldslider/test/nv-fieldslider.utils.test.js +159 -0
  153. package/dist/collection/components/nv-fieldslider/test/nv-fieldslider.utils.test.js.map +1 -0
  154. package/dist/collection/components/nv-fieldtext/nv-fieldtext.css +20 -1
  155. package/dist/collection/components/nv-fieldtext/nv-fieldtext.docs.js +17 -1
  156. package/dist/collection/components/nv-fieldtext/nv-fieldtext.docs.js.map +1 -1
  157. package/dist/collection/components/nv-fieldtext/nv-fieldtext.js +28 -3
  158. package/dist/collection/components/nv-fieldtext/nv-fieldtext.js.map +1 -1
  159. package/dist/collection/components/nv-fieldtextarea/nv-fieldtextarea.css +30 -1
  160. package/dist/collection/components/nv-fieldtextarea/nv-fieldtextarea.docs.js +8 -0
  161. package/dist/collection/components/nv-fieldtextarea/nv-fieldtextarea.docs.js.map +1 -1
  162. package/dist/collection/components/nv-fieldtextarea/nv-fieldtextarea.js +27 -3
  163. package/dist/collection/components/nv-fieldtextarea/nv-fieldtextarea.js.map +1 -1
  164. package/dist/collection/components/nv-fieldtime/nv-fieldtime.js +13 -10
  165. package/dist/collection/components/nv-fieldtime/nv-fieldtime.js.map +1 -1
  166. package/dist/collection/components/nv-fieldtime/styles/nv-fieldtime.css +26 -3
  167. package/dist/collection/components/nv-icon/nv-icon.js +1 -1
  168. package/dist/collection/components/nv-icon/nv-icons.js +4 -470
  169. package/dist/collection/components/nv-icon/nv-icons.js.map +1 -1
  170. package/dist/collection/components/nv-iconbutton/nv-iconbutton.js +1 -1
  171. package/dist/collection/components/nv-loader/nv-loader.js +1 -1
  172. package/dist/collection/components/nv-menu/nv-menu.js +3 -1
  173. package/dist/collection/components/nv-menu/nv-menu.js.map +1 -1
  174. package/dist/collection/components/nv-menuitem/nv-menuitem.js +2 -2
  175. package/dist/collection/components/nv-popover/nv-popover.js +1 -1
  176. package/dist/collection/components/nv-row/nv-row.js +1 -1
  177. package/dist/collection/components/nv-stack/nv-stack.js +1 -1
  178. package/dist/collection/components/nv-table/nv-table.js +8 -11
  179. package/dist/collection/components/nv-table/nv-table.js.map +1 -1
  180. package/dist/collection/components/nv-toggle/nv-toggle.js +2 -2
  181. package/dist/collection/components/nv-tooltip/nv-tooltip.css +1 -0
  182. package/dist/collection/components/nv-tooltip/nv-tooltip.js +1 -1
  183. package/dist/collection/index.js.map +1 -1
  184. package/dist/collection/interfaces/Column.js.map +1 -1
  185. package/dist/collection/templates/navigation.docs.js +0 -1
  186. package/dist/collection/templates/navigation.docs.js.map +1 -1
  187. package/dist/collection/utils/constants.js +11 -0
  188. package/dist/collection/utils/constants.js.map +1 -1
  189. package/dist/components/index.js +6 -472
  190. package/dist/components/index.js.map +1 -1
  191. package/dist/components/nv-alert.js +7 -7
  192. package/dist/components/nv-alert.js.map +1 -1
  193. package/dist/components/nv-avatar.js +3 -3
  194. package/dist/components/nv-badge.js +1 -1
  195. package/dist/components/nv-breadcrumb.js +3 -3
  196. package/dist/components/nv-breadcrumbs.js +1 -1
  197. package/dist/components/nv-button.js +1 -1
  198. package/dist/components/nv-calendar.js +1 -1
  199. package/dist/components/nv-col.js +1 -1
  200. package/dist/components/nv-datagrid.js +447 -102
  201. package/dist/components/nv-datagrid.js.map +1 -1
  202. package/dist/components/nv-datagridcolumn.js +4 -3
  203. package/dist/components/nv-datagridcolumn.js.map +1 -1
  204. package/dist/components/nv-dialog.js +24 -18
  205. package/dist/components/nv-dialog.js.map +1 -1
  206. package/dist/components/nv-dialogfooter.js +1 -1
  207. package/dist/components/nv-dialogheader.js +1 -1
  208. package/dist/components/nv-fieldcheckbox.js +1 -1
  209. package/dist/components/nv-fielddate.js +19 -27
  210. package/dist/components/nv-fielddate.js.map +1 -1
  211. package/dist/components/nv-fielddaterange.js +99 -44
  212. package/dist/components/nv-fielddaterange.js.map +1 -1
  213. package/dist/components/nv-fielddropdown.js +103 -69
  214. package/dist/components/nv-fielddropdown.js.map +1 -1
  215. package/dist/components/nv-fielddropdownitem.js +1 -1
  216. package/dist/components/nv-fielddropdownitemcheck.js +1 -1
  217. package/dist/components/nv-fieldmultiselect.js +139 -120
  218. package/dist/components/nv-fieldmultiselect.js.map +1 -1
  219. package/dist/components/nv-fieldnumber.js +14 -9
  220. package/dist/components/nv-fieldnumber.js.map +1 -1
  221. package/dist/components/nv-fieldpassword.js +13 -8
  222. package/dist/components/nv-fieldpassword.js.map +1 -1
  223. package/dist/components/nv-fieldradio.js +4 -4
  224. package/dist/components/nv-fieldselect.js +15 -10
  225. package/dist/components/nv-fieldselect.js.map +1 -1
  226. package/dist/components/nv-fieldslider.d.ts +11 -0
  227. package/dist/components/nv-fieldslider.js +726 -0
  228. package/dist/components/nv-fieldslider.js.map +1 -0
  229. package/dist/components/nv-fieldtext.js +1 -158
  230. package/dist/components/nv-fieldtext.js.map +1 -1
  231. package/dist/components/nv-fieldtextarea.js +11 -6
  232. package/dist/components/nv-fieldtextarea.js.map +1 -1
  233. package/dist/components/nv-fieldtime.js +20 -17
  234. package/dist/components/nv-fieldtime.js.map +1 -1
  235. package/dist/components/nv-icon.js +1 -1
  236. package/dist/components/nv-iconbutton.js +1 -1
  237. package/dist/components/nv-loader.js +1 -1
  238. package/dist/components/nv-menu.js +7 -5
  239. package/dist/components/nv-menu.js.map +1 -1
  240. package/dist/components/nv-menuitem.js +1 -1
  241. package/dist/components/nv-popover.js +1 -1
  242. package/dist/components/nv-row.js +2 -2
  243. package/dist/components/nv-stack.js +2 -2
  244. package/dist/components/nv-table.js +3 -3
  245. package/dist/components/nv-table.js.map +1 -1
  246. package/dist/components/nv-tablecolumn.js +1 -1
  247. package/dist/components/nv-toggle.js +3 -3
  248. package/dist/components/nv-tooltip.js +1 -1
  249. package/dist/components/{p-dc3faba3.js → p-04cb3a6f.js} +5 -5
  250. package/dist/components/{p-dc3faba3.js.map → p-04cb3a6f.js.map} +1 -1
  251. package/dist/components/p-07a89754.js +187 -0
  252. package/dist/components/p-07a89754.js.map +1 -0
  253. package/dist/components/{p-b7b78e64.js → p-0ab80d95.js} +3 -3
  254. package/dist/components/{p-b7b78e64.js.map → p-0ab80d95.js.map} +1 -1
  255. package/dist/components/{p-8348db09.js → p-1f505531.js} +15 -2
  256. package/dist/components/p-1f505531.js.map +1 -0
  257. package/dist/components/{p-02752770.js → p-33e231f4.js} +2 -2
  258. package/dist/components/{p-02752770.js.map → p-33e231f4.js.map} +1 -1
  259. package/dist/components/p-4656efae.js +1111 -0
  260. package/dist/components/p-4656efae.js.map +1 -0
  261. package/dist/components/{p-2012b8ba.js → p-581e67cc.js} +4 -4
  262. package/dist/components/{p-2012b8ba.js.map → p-581e67cc.js.map} +1 -1
  263. package/dist/components/{p-1c45c0f2.js → p-679e0fa9.js} +16 -4
  264. package/dist/components/p-679e0fa9.js.map +1 -0
  265. package/dist/components/p-76a30bf1.js +88 -0
  266. package/dist/components/p-76a30bf1.js.map +1 -0
  267. package/dist/components/{p-150daf68.js → p-83c8873a.js} +3 -3
  268. package/dist/components/{p-150daf68.js.map → p-83c8873a.js.map} +1 -1
  269. package/dist/components/{p-c14f6b8e.js → p-c0a91091.js} +5 -5
  270. package/dist/components/p-c0a91091.js.map +1 -0
  271. package/dist/components/{p-6c364a23.js → p-cbdc2c8b.js} +6 -6
  272. package/dist/components/{p-6c364a23.js.map → p-cbdc2c8b.js.map} +1 -1
  273. package/dist/components/{p-2d9ba7d3.js → p-cbe9521f.js} +4 -4
  274. package/dist/components/{p-2d9ba7d3.js.map → p-cbe9521f.js.map} +1 -1
  275. package/dist/components/{p-a30b55fc.js → p-d19b41d2.js} +2 -2
  276. package/dist/components/{p-a30b55fc.js.map → p-d19b41d2.js.map} +1 -1
  277. package/dist/components/{p-4d3ec142.js → p-d63f1cbe.js} +4 -4
  278. package/dist/components/{p-4d3ec142.js.map → p-d63f1cbe.js.map} +1 -1
  279. package/dist/components/{p-e00cbb8a.js → p-dd2273a3.js} +2 -2
  280. package/dist/components/{p-e00cbb8a.js.map → p-dd2273a3.js.map} +1 -1
  281. package/dist/components/p-f0a5e7e4.js +167 -0
  282. package/dist/components/p-f0a5e7e4.js.map +1 -0
  283. package/dist/components/{p-f4d86795.js → p-f1859ddc.js} +4 -4
  284. package/dist/components/{p-f4d86795.js.map → p-f1859ddc.js.map} +1 -1
  285. package/dist/esm/{constants-98e2dcc2.js → constants-b97e736d.js} +15 -2
  286. package/dist/esm/constants-b97e736d.js.map +1 -0
  287. package/dist/esm/{index-1fb7a9a6.js → index-8f0e5f19.js} +22 -6
  288. package/dist/esm/index-8f0e5f19.js.map +1 -0
  289. package/dist/esm/index.js +5 -471
  290. package/dist/esm/index.js.map +1 -1
  291. package/dist/esm/loader.js +3 -3
  292. package/dist/esm/native.js +3 -3
  293. package/dist/esm/nv-alert.entry.js +6 -6
  294. package/dist/esm/nv-alert.entry.js.map +1 -1
  295. package/dist/esm/nv-avatar.entry.js +2 -2
  296. package/dist/esm/nv-badge_2.entry.js +18 -9
  297. package/dist/esm/nv-badge_2.entry.js.map +1 -1
  298. package/dist/esm/nv-breadcrumb.entry.js +1 -1
  299. package/dist/esm/nv-breadcrumbs.entry.js +1 -1
  300. package/dist/esm/nv-button.entry.js +2 -2
  301. package/dist/esm/nv-calendar.entry.js +821 -843
  302. package/dist/esm/nv-calendar.entry.js.map +1 -1
  303. package/dist/esm/nv-col.entry.js +1 -1
  304. package/dist/esm/nv-datagrid.entry.js +423 -94
  305. package/dist/esm/nv-datagrid.entry.js.map +1 -1
  306. package/dist/esm/nv-datagridcolumn.entry.js +2 -2
  307. package/dist/esm/nv-datagridcolumn.entry.js.map +1 -1
  308. package/dist/esm/nv-dialog.entry.js +19 -13
  309. package/dist/esm/nv-dialog.entry.js.map +1 -1
  310. package/dist/esm/nv-dialogfooter_2.entry.js +2 -2
  311. package/dist/esm/nv-fieldcheckbox.entry.js +1 -1
  312. package/dist/esm/nv-fielddate.entry.js +9 -18
  313. package/dist/esm/nv-fielddate.entry.js.map +1 -1
  314. package/dist/esm/nv-fielddaterange.entry.js +85 -32
  315. package/dist/esm/nv-fielddaterange.entry.js.map +1 -1
  316. package/dist/esm/nv-fielddropdown.entry.js +88 -57
  317. package/dist/esm/nv-fielddropdown.entry.js.map +1 -1
  318. package/dist/esm/nv-fielddropdownitem.entry.js +2 -2
  319. package/dist/esm/nv-fieldmultiselect.entry.js +122 -104
  320. package/dist/esm/nv-fieldmultiselect.entry.js.map +1 -1
  321. package/dist/esm/nv-fieldnumber.entry.js +9 -5
  322. package/dist/esm/nv-fieldnumber.entry.js.map +1 -1
  323. package/dist/esm/nv-fieldpassword.entry.js +9 -5
  324. package/dist/esm/nv-fieldpassword.entry.js.map +1 -1
  325. package/dist/esm/nv-fieldradio.entry.js +4 -4
  326. package/dist/esm/nv-fieldselect.entry.js +11 -7
  327. package/dist/esm/nv-fieldselect.entry.js.map +1 -1
  328. package/dist/esm/nv-fieldslider.entry.js +659 -0
  329. package/dist/esm/nv-fieldslider.entry.js.map +1 -0
  330. package/dist/esm/nv-fieldtext.entry.js +9 -5
  331. package/dist/esm/nv-fieldtext.entry.js.map +1 -1
  332. package/dist/esm/nv-fieldtextarea.entry.js +9 -5
  333. package/dist/esm/nv-fieldtextarea.entry.js.map +1 -1
  334. package/dist/esm/nv-fieldtime.entry.js +16 -13
  335. package/dist/esm/nv-fieldtime.entry.js.map +1 -1
  336. package/dist/esm/nv-icon.entry.js +4 -4
  337. package/dist/esm/nv-icon.entry.js.map +1 -1
  338. package/dist/esm/nv-iconbutton_2.entry.js +3 -3
  339. package/dist/esm/nv-menu.entry.js +4 -2
  340. package/dist/esm/nv-menu.entry.js.map +1 -1
  341. package/dist/esm/nv-menuitem.entry.js +2 -2
  342. package/dist/esm/nv-popover.entry.js +2 -2
  343. package/dist/esm/nv-row.entry.js +2 -2
  344. package/dist/esm/nv-stack.entry.js +2 -2
  345. package/dist/esm/nv-table.entry.js +3 -3
  346. package/dist/esm/nv-table.entry.js.map +1 -1
  347. package/dist/esm/nv-tablecolumn.entry.js +1 -1
  348. package/dist/esm/nv-toggle.entry.js +3 -3
  349. package/dist/esm/nv-tooltip.entry.js +3 -3
  350. package/dist/esm/nv-tooltip.entry.js.map +1 -1
  351. package/dist/native/index.esm.js +1 -1
  352. package/dist/native/index.esm.js.map +1 -1
  353. package/dist/native/native.css +1 -1
  354. package/dist/native/native.esm.js +1 -1
  355. package/dist/native/native.esm.js.map +1 -1
  356. package/dist/native/{p-6b348684.entry.js → p-0323daf6.entry.js} +2 -2
  357. package/dist/native/{p-d5cbf5c8.entry.js → p-05d95d4d.entry.js} +2 -2
  358. package/dist/native/{p-fb5bddba.entry.js → p-0ec1e2e3.entry.js} +2 -2
  359. package/dist/native/{p-c7b201cd.entry.js → p-16a4cdf3.entry.js} +2 -2
  360. package/dist/native/p-19fb0fd0.entry.js +2 -0
  361. package/dist/native/p-19fb0fd0.entry.js.map +1 -0
  362. package/dist/native/p-1e3d3374.entry.js +2 -0
  363. package/dist/native/{p-9135fdf5.entry.js.map → p-1e3d3374.entry.js.map} +1 -1
  364. package/dist/native/p-21e7132f.entry.js +2 -0
  365. package/dist/native/p-21e7132f.entry.js.map +1 -0
  366. package/dist/native/p-221b8f72.entry.js +2 -0
  367. package/dist/native/p-221b8f72.entry.js.map +1 -0
  368. package/dist/native/p-2805f9f2.entry.js +2 -0
  369. package/dist/native/p-2805f9f2.entry.js.map +1 -0
  370. package/dist/native/p-3f2b6a22.entry.js +2 -0
  371. package/dist/native/p-3f2b6a22.entry.js.map +1 -0
  372. package/dist/native/{p-0245863d.entry.js → p-407fc32d.entry.js} +2 -2
  373. package/dist/native/{p-63e6aed3.entry.js → p-4c0d81b0.entry.js} +2 -2
  374. package/dist/native/p-4c0d81b0.entry.js.map +1 -0
  375. package/dist/native/{p-39bb95ff.entry.js → p-519b4819.entry.js} +2 -2
  376. package/dist/native/{p-fa77a591.entry.js → p-5382eab2.entry.js} +2 -2
  377. package/dist/native/p-5ba3fc3c.entry.js +2 -0
  378. package/dist/native/p-5ba3fc3c.entry.js.map +1 -0
  379. package/dist/native/{p-bad11367.entry.js → p-60b204ac.entry.js} +2 -2
  380. package/dist/native/p-60b204ac.entry.js.map +1 -0
  381. package/dist/native/p-7092a675.entry.js +2 -0
  382. package/dist/native/p-711a7778.js +3 -0
  383. package/dist/native/p-711a7778.js.map +1 -0
  384. package/dist/native/p-759c9ce4.entry.js +2 -0
  385. package/dist/native/p-759c9ce4.entry.js.map +1 -0
  386. package/dist/native/{p-d7a76400.entry.js → p-7c676f2c.entry.js} +2 -2
  387. package/dist/native/p-7c6edd1c.entry.js +2 -0
  388. package/dist/native/p-7c6edd1c.entry.js.map +1 -0
  389. package/dist/native/p-987c79d8.entry.js +2 -0
  390. package/dist/native/p-987c79d8.entry.js.map +1 -0
  391. package/dist/native/{p-f85aca27.entry.js → p-9fba8663.entry.js} +2 -2
  392. package/dist/native/{p-b094296d.entry.js → p-a2c0f1a7.entry.js} +2 -2
  393. package/dist/native/p-aa86af25.entry.js +2 -0
  394. package/dist/native/p-aa86af25.entry.js.map +1 -0
  395. package/dist/native/p-adc96c3a.entry.js +2 -0
  396. package/dist/native/p-adc96c3a.entry.js.map +1 -0
  397. package/dist/native/p-b0fc08e7.entry.js +2 -0
  398. package/dist/native/p-b0fc08e7.entry.js.map +1 -0
  399. package/dist/native/{p-6ff228da.entry.js → p-c930adb7.entry.js} +2 -2
  400. package/dist/native/{p-701b5557.entry.js → p-cfe0a6c6.entry.js} +2 -2
  401. package/dist/native/p-d07ab618.entry.js +2 -0
  402. package/dist/native/p-dac0089b.entry.js +2 -0
  403. package/dist/native/p-dac0089b.entry.js.map +1 -0
  404. package/dist/native/p-de2c07a6.entry.js +13 -0
  405. package/dist/native/p-de2c07a6.entry.js.map +1 -0
  406. package/dist/native/p-ed488498.entry.js +7 -0
  407. package/dist/native/p-ed488498.entry.js.map +1 -0
  408. package/dist/native/p-ef76178b.entry.js +2 -0
  409. package/dist/native/p-ef76178b.entry.js.map +1 -0
  410. package/dist/native/{p-e5de64d5.entry.js → p-f0ddf60b.entry.js} +2 -2
  411. package/dist/native/p-f39803d9.entry.js +2 -0
  412. package/dist/native/p-f39803d9.entry.js.map +1 -0
  413. package/dist/native/{p-59768ee5.js → p-f85c08f1.js} +2 -2
  414. package/dist/native/p-f85c08f1.js.map +1 -0
  415. package/dist/native/p-fb897f7d.entry.js +2 -0
  416. package/dist/native/p-fb897f7d.entry.js.map +1 -0
  417. package/dist/native/{p-244f56ac.entry.js → p-fc3bea07.entry.js} +2 -2
  418. package/dist/types/components/nv-alert/nv-alert.d.ts +1 -1
  419. package/dist/types/components/nv-badge/nv-badge.d.ts +11 -3
  420. package/dist/types/components/nv-calendar/nv-calendar.d.ts +70 -112
  421. package/dist/types/components/nv-calendar/nv-calendar.utils.d.ts +60 -0
  422. package/dist/types/components/nv-calendar/test/nv-calendar.utils.test.d.ts +1 -0
  423. package/dist/types/components/nv-datagrid/nv-datagrid.d.ts +47 -26
  424. package/dist/types/components/nv-datagridcolumn/nv-datagridcolumn.d.ts +4 -0
  425. package/dist/types/components/nv-dialog/nv-dialog.d.ts +4 -0
  426. package/dist/types/components/nv-fielddate/nv-fielddate.d.ts +6 -7
  427. package/dist/types/components/nv-fielddaterange/nv-fielddaterange.d.ts +23 -12
  428. package/dist/types/components/nv-fielddropdown/nv-fielddropdown.d.ts +51 -26
  429. package/dist/types/components/nv-fieldmultiselect/nv-fieldmultiselect.d.ts +65 -55
  430. package/dist/types/components/nv-fieldnumber/nv-fieldnumber.d.ts +4 -0
  431. package/dist/types/components/nv-fieldpassword/nv-fieldpassword.d.ts +4 -0
  432. package/dist/types/components/nv-fieldselect/nv-fieldselect.d.ts +4 -0
  433. package/dist/types/components/nv-fieldslider/nv-fieldslider.d.ts +230 -0
  434. package/dist/types/components/nv-fieldslider/nv-fieldslider.docs.d.ts +4 -0
  435. package/dist/types/components/nv-fieldslider/nv-fieldslider.utils.d.ts +46 -0
  436. package/dist/types/components/nv-fieldslider/partials/field-input.d.ts +45 -0
  437. package/dist/types/components/nv-fieldslider/partials/range-thumb.d.ts +37 -0
  438. package/dist/types/components/nv-fieldslider/partials/single-thumb.d.ts +35 -0
  439. package/dist/types/components/nv-fieldslider/partials/tick-marks.d.ts +28 -0
  440. package/dist/types/components/nv-fieldslider/test/nv-fieldslider.utils.test.d.ts +1 -0
  441. package/dist/types/components/nv-fieldtext/nv-fieldtext.d.ts +5 -0
  442. package/dist/types/components/nv-fieldtextarea/nv-fieldtextarea.d.ts +4 -0
  443. package/dist/types/components/nv-icon/nv-icons.d.ts +1 -1
  444. package/dist/types/components/nv-table/nv-table.d.ts +13 -2
  445. package/dist/types/components.d.ts +656 -154
  446. package/dist/types/index.d.ts +0 -2
  447. package/dist/types/interfaces/Column.d.ts +5 -1
  448. package/dist/types/utils/constants.d.ts +9 -0
  449. package/dist/vscode-data.json +292 -1546
  450. package/hydrate/index.js +2715 -1533
  451. package/hydrate/index.mjs +2715 -1533
  452. package/package.json +6 -2
  453. package/dist/cjs/constants-bcd6b2e2.js.map +0 -1
  454. package/dist/cjs/index-9bda5507.js.map +0 -1
  455. package/dist/collection/interfaces/actionEvent.js +0 -2
  456. package/dist/collection/interfaces/actionEvent.js.map +0 -1
  457. package/dist/collection/interfaces/calendarShortcut.js +0 -2
  458. package/dist/collection/interfaces/calendarShortcut.js.map +0 -1
  459. package/dist/collection/interfaces/dateRange.js +0 -2
  460. package/dist/collection/interfaces/dateRange.js.map +0 -1
  461. package/dist/components/p-1c45c0f2.js.map +0 -1
  462. package/dist/components/p-373926aa.js +0 -177
  463. package/dist/components/p-373926aa.js.map +0 -1
  464. package/dist/components/p-591730e7.js +0 -88
  465. package/dist/components/p-591730e7.js.map +0 -1
  466. package/dist/components/p-8348db09.js.map +0 -1
  467. package/dist/components/p-c14f6b8e.js.map +0 -1
  468. package/dist/components/p-f331117c.js +0 -1133
  469. package/dist/components/p-f331117c.js.map +0 -1
  470. package/dist/esm/constants-98e2dcc2.js.map +0 -1
  471. package/dist/esm/index-1fb7a9a6.js.map +0 -1
  472. package/dist/native/p-0ee428d5.entry.js +0 -2
  473. package/dist/native/p-0ee428d5.entry.js.map +0 -1
  474. package/dist/native/p-2691e02d.entry.js +0 -2
  475. package/dist/native/p-37f0210e.entry.js +0 -2
  476. package/dist/native/p-37f0210e.entry.js.map +0 -1
  477. package/dist/native/p-4a440970.entry.js +0 -2
  478. package/dist/native/p-4a440970.entry.js.map +0 -1
  479. package/dist/native/p-4ae26462.entry.js +0 -7
  480. package/dist/native/p-4ae26462.entry.js.map +0 -1
  481. package/dist/native/p-4d9c4618.entry.js +0 -2
  482. package/dist/native/p-4d9c4618.entry.js.map +0 -1
  483. package/dist/native/p-4dc1d036.entry.js +0 -2
  484. package/dist/native/p-59768ee5.js.map +0 -1
  485. package/dist/native/p-59e0bd2b.entry.js +0 -2
  486. package/dist/native/p-59e0bd2b.entry.js.map +0 -1
  487. package/dist/native/p-5c00f092.entry.js +0 -2
  488. package/dist/native/p-5c00f092.entry.js.map +0 -1
  489. package/dist/native/p-63e6aed3.entry.js.map +0 -1
  490. package/dist/native/p-7f5eb2ac.entry.js +0 -2
  491. package/dist/native/p-7f5eb2ac.entry.js.map +0 -1
  492. package/dist/native/p-84a73e2a.entry.js +0 -2
  493. package/dist/native/p-84a73e2a.entry.js.map +0 -1
  494. package/dist/native/p-9135fdf5.entry.js +0 -2
  495. package/dist/native/p-93dc2f47.entry.js +0 -2
  496. package/dist/native/p-93dc2f47.entry.js.map +0 -1
  497. package/dist/native/p-9a267f16.entry.js +0 -13
  498. package/dist/native/p-9a267f16.entry.js.map +0 -1
  499. package/dist/native/p-9d6431c7.entry.js +0 -2
  500. package/dist/native/p-9d6431c7.entry.js.map +0 -1
  501. package/dist/native/p-ab002252.js +0 -3
  502. package/dist/native/p-ab002252.js.map +0 -1
  503. package/dist/native/p-b2ce83ad.entry.js +0 -2
  504. package/dist/native/p-b2ce83ad.entry.js.map +0 -1
  505. package/dist/native/p-bad11367.entry.js.map +0 -1
  506. package/dist/native/p-e1a4f776.entry.js +0 -2
  507. package/dist/native/p-e1a4f776.entry.js.map +0 -1
  508. package/dist/native/p-e49bbd02.entry.js +0 -2
  509. package/dist/native/p-e49bbd02.entry.js.map +0 -1
  510. package/dist/native/p-eee01062.entry.js +0 -2
  511. package/dist/native/p-eee01062.entry.js.map +0 -1
  512. package/dist/native/p-f6bdc270.entry.js +0 -2
  513. package/dist/native/p-f6bdc270.entry.js.map +0 -1
  514. package/dist/types/interfaces/actionEvent.d.ts +0 -13
  515. package/dist/types/interfaces/calendarShortcut.d.ts +0 -17
  516. package/dist/types/interfaces/dateRange.d.ts +0 -13
  517. /package/dist/native/{p-6b348684.entry.js.map → p-0323daf6.entry.js.map} +0 -0
  518. /package/dist/native/{p-d5cbf5c8.entry.js.map → p-05d95d4d.entry.js.map} +0 -0
  519. /package/dist/native/{p-fb5bddba.entry.js.map → p-0ec1e2e3.entry.js.map} +0 -0
  520. /package/dist/native/{p-c7b201cd.entry.js.map → p-16a4cdf3.entry.js.map} +0 -0
  521. /package/dist/native/{p-0245863d.entry.js.map → p-407fc32d.entry.js.map} +0 -0
  522. /package/dist/native/{p-39bb95ff.entry.js.map → p-519b4819.entry.js.map} +0 -0
  523. /package/dist/native/{p-fa77a591.entry.js.map → p-5382eab2.entry.js.map} +0 -0
  524. /package/dist/native/{p-2691e02d.entry.js.map → p-7092a675.entry.js.map} +0 -0
  525. /package/dist/native/{p-d7a76400.entry.js.map → p-7c676f2c.entry.js.map} +0 -0
  526. /package/dist/native/{p-f85aca27.entry.js.map → p-9fba8663.entry.js.map} +0 -0
  527. /package/dist/native/{p-b094296d.entry.js.map → p-a2c0f1a7.entry.js.map} +0 -0
  528. /package/dist/native/{p-6ff228da.entry.js.map → p-c930adb7.entry.js.map} +0 -0
  529. /package/dist/native/{p-701b5557.entry.js.map → p-cfe0a6c6.entry.js.map} +0 -0
  530. /package/dist/native/{p-4dc1d036.entry.js.map → p-d07ab618.entry.js.map} +0 -0
  531. /package/dist/native/{p-e5de64d5.entry.js.map → p-f0ddf60b.entry.js.map} +0 -0
  532. /package/dist/native/{p-244f56ac.entry.js.map → p-fc3bea07.entry.js.map} +0 -0
@@ -0,0 +1,1111 @@
1
+ import { p as proxyCustomElement, H, c as createEvent, h, d as Host } from './p-679e0fa9.js';
2
+ import { C as CUSTOM_DAY_NAMES, b as CUSTOM_MONTH_NAMES, W as WEEK_ABBREVIATIONS } from './p-1f505531.js';
3
+ import { d as defineCustomElement$4 } from './p-cbe9521f.js';
4
+ import { d as defineCustomElement$3 } from './p-76a30bf1.js';
5
+ import { d as defineCustomElement$2 } from './p-04cb3a6f.js';
6
+ import { d as defineCustomElement$1 } from './p-83c8873a.js';
7
+
8
+ var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};
9
+
10
+ function getDefaultExportFromCjs (x) {
11
+ return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
12
+ }
13
+
14
+ var dayjs_min = {exports: {}};
15
+
16
+ (function (module, exports) {
17
+ !function(t,e){module.exports=e();}(commonjsGlobal,(function(){var t=1e3,e=6e4,n=36e5,r="millisecond",i="second",s="minute",u="hour",a="day",o="week",c="month",f="quarter",h="year",d="date",l="Invalid Date",$=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,y=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,M={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(t){var e=["th","st","nd","rd"],n=t%100;return "["+t+(e[(n-20)%10]||e[n]||e[0])+"]"}},m=function(t,e,n){var r=String(t);return !r||r.length>=e?t:""+Array(e+1-r.length).join(n)+t},v={s:m,z:function(t){var e=-t.utcOffset(),n=Math.abs(e),r=Math.floor(n/60),i=n%60;return (e<=0?"+":"-")+m(r,2,"0")+":"+m(i,2,"0")},m:function t(e,n){if(e.date()<n.date())return -t(n,e);var r=12*(n.year()-e.year())+(n.month()-e.month()),i=e.clone().add(r,c),s=n-i<0,u=e.clone().add(r+(s?-1:1),c);return +(-(r+(n-i)/(s?i-u:u-i))||0)},a:function(t){return t<0?Math.ceil(t)||0:Math.floor(t)},p:function(t){return {M:c,y:h,w:o,d:a,D:d,h:u,m:s,s:i,ms:r,Q:f}[t]||String(t||"").toLowerCase().replace(/s$/,"")},u:function(t){return void 0===t}},g="en",D={};D[g]=M;var p="$isDayjsObject",S=function(t){return t instanceof _||!(!t||!t[p])},w=function t(e,n,r){var i;if(!e)return g;if("string"==typeof e){var s=e.toLowerCase();D[s]&&(i=s),n&&(D[s]=n,i=s);var u=e.split("-");if(!i&&u.length>1)return t(u[0])}else {var a=e.name;D[a]=e,i=a;}return !r&&i&&(g=i),i||!r&&g},O=function(t,e){if(S(t))return t.clone();var n="object"==typeof e?e:{};return n.date=t,n.args=arguments,new _(n)},b=v;b.l=w,b.i=S,b.w=function(t,e){return O(t,{locale:e.$L,utc:e.$u,x:e.$x,$offset:e.$offset})};var _=function(){function M(t){this.$L=w(t.locale,null,!0),this.parse(t),this.$x=this.$x||t.x||{},this[p]=!0;}var m=M.prototype;return m.parse=function(t){this.$d=function(t){var e=t.date,n=t.utc;if(null===e)return new Date(NaN);if(b.u(e))return new Date;if(e instanceof Date)return new Date(e);if("string"==typeof e&&!/Z$/i.test(e)){var r=e.match($);if(r){var i=r[2]-1||0,s=(r[7]||"0").substring(0,3);return n?new Date(Date.UTC(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)):new Date(r[1],i,r[3]||1,r[4]||0,r[5]||0,r[6]||0,s)}}return new Date(e)}(t),this.init();},m.init=function(){var t=this.$d;this.$y=t.getFullYear(),this.$M=t.getMonth(),this.$D=t.getDate(),this.$W=t.getDay(),this.$H=t.getHours(),this.$m=t.getMinutes(),this.$s=t.getSeconds(),this.$ms=t.getMilliseconds();},m.$utils=function(){return b},m.isValid=function(){return !(this.$d.toString()===l)},m.isSame=function(t,e){var n=O(t);return this.startOf(e)<=n&&n<=this.endOf(e)},m.isAfter=function(t,e){return O(t)<this.startOf(e)},m.isBefore=function(t,e){return this.endOf(e)<O(t)},m.$g=function(t,e,n){return b.u(t)?this[e]:this.set(n,t)},m.unix=function(){return Math.floor(this.valueOf()/1e3)},m.valueOf=function(){return this.$d.getTime()},m.startOf=function(t,e){var n=this,r=!!b.u(e)||e,f=b.p(t),l=function(t,e){var i=b.w(n.$u?Date.UTC(n.$y,e,t):new Date(n.$y,e,t),n);return r?i:i.endOf(a)},$=function(t,e){return b.w(n.toDate()[t].apply(n.toDate("s"),(r?[0,0,0,0]:[23,59,59,999]).slice(e)),n)},y=this.$W,M=this.$M,m=this.$D,v="set"+(this.$u?"UTC":"");switch(f){case h:return r?l(1,0):l(31,11);case c:return r?l(1,M):l(0,M+1);case o:var g=this.$locale().weekStart||0,D=(y<g?y+7:y)-g;return l(r?m-D:m+(6-D),M);case a:case d:return $(v+"Hours",0);case u:return $(v+"Minutes",1);case s:return $(v+"Seconds",2);case i:return $(v+"Milliseconds",3);default:return this.clone()}},m.endOf=function(t){return this.startOf(t,!1)},m.$set=function(t,e){var n,o=b.p(t),f="set"+(this.$u?"UTC":""),l=(n={},n[a]=f+"Date",n[d]=f+"Date",n[c]=f+"Month",n[h]=f+"FullYear",n[u]=f+"Hours",n[s]=f+"Minutes",n[i]=f+"Seconds",n[r]=f+"Milliseconds",n)[o],$=o===a?this.$D+(e-this.$W):e;if(o===c||o===h){var y=this.clone().set(d,1);y.$d[l]($),y.init(),this.$d=y.set(d,Math.min(this.$D,y.daysInMonth())).$d;}else l&&this.$d[l]($);return this.init(),this},m.set=function(t,e){return this.clone().$set(t,e)},m.get=function(t){return this[b.p(t)]()},m.add=function(r,f){var d,l=this;r=Number(r);var $=b.p(f),y=function(t){var e=O(l);return b.w(e.date(e.date()+Math.round(t*r)),l)};if($===c)return this.set(c,this.$M+r);if($===h)return this.set(h,this.$y+r);if($===a)return y(1);if($===o)return y(7);var M=(d={},d[s]=e,d[u]=n,d[i]=t,d)[$]||1,m=this.$d.getTime()+r*M;return b.w(m,this)},m.subtract=function(t,e){return this.add(-1*t,e)},m.format=function(t){var e=this,n=this.$locale();if(!this.isValid())return n.invalidDate||l;var r=t||"YYYY-MM-DDTHH:mm:ssZ",i=b.z(this),s=this.$H,u=this.$m,a=this.$M,o=n.weekdays,c=n.months,f=n.meridiem,h=function(t,n,i,s){return t&&(t[n]||t(e,r))||i[n].slice(0,s)},d=function(t){return b.s(s%12||12,t,"0")},$=f||function(t,e,n){var r=t<12?"AM":"PM";return n?r.toLowerCase():r};return r.replace(y,(function(t,r){return r||function(t){switch(t){case"YY":return String(e.$y).slice(-2);case"YYYY":return b.s(e.$y,4,"0");case"M":return a+1;case"MM":return b.s(a+1,2,"0");case"MMM":return h(n.monthsShort,a,c,3);case"MMMM":return h(c,a);case"D":return e.$D;case"DD":return b.s(e.$D,2,"0");case"d":return String(e.$W);case"dd":return h(n.weekdaysMin,e.$W,o,2);case"ddd":return h(n.weekdaysShort,e.$W,o,3);case"dddd":return o[e.$W];case"H":return String(s);case"HH":return b.s(s,2,"0");case"h":return d(1);case"hh":return d(2);case"a":return $(s,u,!0);case"A":return $(s,u,!1);case"m":return String(u);case"mm":return b.s(u,2,"0");case"s":return String(e.$s);case"ss":return b.s(e.$s,2,"0");case"SSS":return b.s(e.$ms,3,"0");case"Z":return i}return null}(t)||i.replace(":","")}))},m.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},m.diff=function(r,d,l){var $,y=this,M=b.p(d),m=O(r),v=(m.utcOffset()-this.utcOffset())*e,g=this-m,D=function(){return b.m(y,m)};switch(M){case h:$=D()/12;break;case c:$=D();break;case f:$=D()/3;break;case o:$=(g-v)/6048e5;break;case a:$=(g-v)/864e5;break;case u:$=g/n;break;case s:$=g/e;break;case i:$=g/t;break;default:$=g;}return l?$:b.a($)},m.daysInMonth=function(){return this.endOf(c).$D},m.$locale=function(){return D[this.$L]},m.locale=function(t,e){if(!t)return this.$L;var n=this.clone(),r=w(t,e,!0);return r&&(n.$L=r),n},m.clone=function(){return b.w(this.$d,this)},m.toDate=function(){return new Date(this.valueOf())},m.toJSON=function(){return this.isValid()?this.toISOString():null},m.toISOString=function(){return this.$d.toISOString()},m.toString=function(){return this.$d.toUTCString()},M}(),k=_.prototype;return O.prototype=k,[["$ms",r],["$s",i],["$m",s],["$H",u],["$W",a],["$M",c],["$y",h],["$D",d]].forEach((function(t){k[t[1]]=function(e){return this.$g(e,t[0],t[1])};})),O.extend=function(t,e){return t.$i||(t(e,_,O),t.$i=!0),O},O.locale=w,O.isDayjs=S,O.unix=function(t){return O(1e3*t)},O.en=D[g],O.Ls=D,O.p={},O}));
18
+ }(dayjs_min));
19
+
20
+ const dayjs = dayjs_min.exports;
21
+
22
+ var customParseFormat$1 = {exports: {}};
23
+
24
+ (function (module, exports) {
25
+ !function(e,t){module.exports=t();}(commonjsGlobal,(function(){var e={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},t=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,n=/\d/,r=/\d\d/,i=/\d\d?/,o=/\d*[^-_:/,()\s\d]+/,s={},a=function(e){return (e=+e)+(e>68?1900:2e3)};var f=function(e){return function(t){this[e]=+t;}},h=[/[+-]\d\d:?(\d\d)?|Z/,function(e){(this.zone||(this.zone={})).offset=function(e){if(!e)return 0;if("Z"===e)return 0;var t=e.match(/([+-]|\d\d)/g),n=60*t[1]+(+t[2]||0);return 0===n?0:"+"===t[0]?-n:n}(e);}],u=function(e){var t=s[e];return t&&(t.indexOf?t:t.s.concat(t.f))},d=function(e,t){var n,r=s.meridiem;if(r){for(var i=1;i<=24;i+=1)if(e.indexOf(r(i,0,t))>-1){n=i>12;break}}else n=e===(t?"pm":"PM");return n},c={A:[o,function(e){this.afternoon=d(e,!1);}],a:[o,function(e){this.afternoon=d(e,!0);}],Q:[n,function(e){this.month=3*(e-1)+1;}],S:[n,function(e){this.milliseconds=100*+e;}],SS:[r,function(e){this.milliseconds=10*+e;}],SSS:[/\d{3}/,function(e){this.milliseconds=+e;}],s:[i,f("seconds")],ss:[i,f("seconds")],m:[i,f("minutes")],mm:[i,f("minutes")],H:[i,f("hours")],h:[i,f("hours")],HH:[i,f("hours")],hh:[i,f("hours")],D:[i,f("day")],DD:[r,f("day")],Do:[o,function(e){var t=s.ordinal,n=e.match(/\d+/);if(this.day=n[0],t)for(var r=1;r<=31;r+=1)t(r).replace(/\[|\]/g,"")===e&&(this.day=r);}],w:[i,f("week")],ww:[r,f("week")],M:[i,f("month")],MM:[r,f("month")],MMM:[o,function(e){var t=u("months"),n=(u("monthsShort")||t.map((function(e){return e.slice(0,3)}))).indexOf(e)+1;if(n<1)throw new Error;this.month=n%12||n;}],MMMM:[o,function(e){var t=u("months").indexOf(e)+1;if(t<1)throw new Error;this.month=t%12||t;}],Y:[/[+-]?\d+/,f("year")],YY:[r,function(e){this.year=a(e);}],YYYY:[/\d{4}/,f("year")],Z:h,ZZ:h};function l(n){var r,i;r=n,i=s&&s.formats;for(var o=(n=r.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(t,n,r){var o=r&&r.toUpperCase();return n||i[r]||e[r]||i[o].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(e,t,n){return t||n.slice(1)}))}))).match(t),a=o.length,f=0;f<a;f+=1){var h=o[f],u=c[h],d=u&&u[0],l=u&&u[1];o[f]=l?{regex:d,parser:l}:h.replace(/^\[|\]$/g,"");}return function(e){for(var t={},n=0,r=0;n<a;n+=1){var i=o[n];if("string"==typeof i)r+=i.length;else {var s=i.regex,f=i.parser,h=e.slice(r),u=s.exec(h)[0];f.call(t,u),e=e.replace(u,"");}}return function(e){var t=e.afternoon;if(void 0!==t){var n=e.hours;t?n<12&&(e.hours+=12):12===n&&(e.hours=0),delete e.afternoon;}}(t),t}}return function(e,t,n){n.p.customParseFormat=!0,e&&e.parseTwoDigitYear&&(a=e.parseTwoDigitYear);var r=t.prototype,i=r.parse;r.parse=function(e){var t=e.date,r=e.utc,o=e.args;this.$u=r;var a=o[1];if("string"==typeof a){var f=!0===o[2],h=!0===o[3],u=f||h,d=o[2];h&&(d=o[2]),s=this.$locale(),!f&&d&&(s=n.Ls[d]),this.$d=function(e,t,n,r){try{if(["x","X"].indexOf(t)>-1)return new Date(("X"===t?1e3:1)*e);var i=l(t)(e),o=i.year,s=i.month,a=i.day,f=i.hours,h=i.minutes,u=i.seconds,d=i.milliseconds,c=i.zone,m=i.week,M=new Date,Y=a||(o||s?1:M.getDate()),p=o||M.getFullYear(),v=0;o&&!s||(v=s>0?s-1:M.getMonth());var D,w=f||0,g=h||0,y=u||0,L=d||0;return c?new Date(Date.UTC(p,v,Y,w,g,y,L+60*c.offset*1e3)):n?new Date(Date.UTC(p,v,Y,w,g,y,L)):(D=new Date(p,v,Y,w,g,y,L),m&&(D=r(D).week(m).toDate()),D)}catch(e){return new Date("")}}(t,a,r,n),this.init(),d&&!0!==d&&(this.$L=this.locale(d).$L),u&&t!=this.format(a)&&(this.$d=new Date("")),s={};}else if(a instanceof Array)for(var c=a.length,m=1;m<=c;m+=1){o[1]=a[m-1];var M=n.apply(this,o);if(M.isValid()){this.$d=M.$d,this.$L=M.$L,this.init();break}m===c&&(this.$d=new Date(""));}else i.call(this,e);};}}));
26
+ }(customParseFormat$1));
27
+
28
+ const customParseFormat = customParseFormat$1.exports;
29
+
30
+ var utc$1 = {exports: {}};
31
+
32
+ (function (module, exports) {
33
+ !function(t,i){module.exports=i();}(commonjsGlobal,(function(){var t="minute",i=/[+-]\d\d(?::?\d\d)?/g,e=/([+-]|\d\d)/g;return function(s,f,n){var u=f.prototype;n.utc=function(t){var i={date:t,utc:!0,args:arguments};return new f(i)},u.utc=function(i){var e=n(this.toDate(),{locale:this.$L,utc:!0});return i?e.add(this.utcOffset(),t):e},u.local=function(){return n(this.toDate(),{locale:this.$L,utc:!1})};var o=u.parse;u.parse=function(t){t.utc&&(this.$u=!0),this.$utils().u(t.$offset)||(this.$offset=t.$offset),o.call(this,t);};var r=u.init;u.init=function(){if(this.$u){var t=this.$d;this.$y=t.getUTCFullYear(),this.$M=t.getUTCMonth(),this.$D=t.getUTCDate(),this.$W=t.getUTCDay(),this.$H=t.getUTCHours(),this.$m=t.getUTCMinutes(),this.$s=t.getUTCSeconds(),this.$ms=t.getUTCMilliseconds();}else r.call(this);};var a=u.utcOffset;u.utcOffset=function(s,f){var n=this.$utils().u;if(n(s))return this.$u?0:n(this.$offset)?a.call(this):this.$offset;if("string"==typeof s&&(s=function(t){void 0===t&&(t="");var s=t.match(i);if(!s)return null;var f=(""+s[0]).match(e)||["-",0,0],n=f[0],u=60*+f[1]+ +f[2];return 0===u?0:"+"===n?u:-u}(s),null===s))return this;var u=Math.abs(s)<=16?60*s:s,o=this;if(f)return o.$offset=u,o.$u=0===s,o;if(0!==s){var r=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(o=this.local().add(u+r,t)).$offset=u,o.$x.$localOffset=r;}else o=this.utc();return o};var h=u.format;u.format=function(t){var i=t||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return h.call(this,i)},u.valueOf=function(){var t=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*t},u.isUTC=function(){return !!this.$u},u.toISOString=function(){return this.toDate().toISOString()},u.toString=function(){return this.toDate().toUTCString()};var l=u.toDate;u.toDate=function(t){return "s"===t&&this.$offset?n(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():l.call(this)};var c=u.diff;u.diff=function(t,i,e){if(t&&this.$u===t.$u)return c.call(this,t,i,e);var s=this.local(),f=n(t).local();return c.call(s,f,i,e)};}}));
34
+ }(utc$1));
35
+
36
+ const utc = utc$1.exports;
37
+
38
+ var weekOfYear$1 = {exports: {}};
39
+
40
+ (function (module, exports) {
41
+ !function(e,t){module.exports=t();}(commonjsGlobal,(function(){var e="week",t="year";return function(i,n,r){var f=n.prototype;f.week=function(i){if(void 0===i&&(i=null),null!==i)return this.add(7*(i-this.week()),"day");var n=this.$locale().yearStart||1;if(11===this.month()&&this.date()>25){var f=r(this).startOf(t).add(1,t).date(n),s=r(this).endOf(e);if(f.isBefore(s))return 1}var a=r(this).startOf(t).date(n).startOf(e).subtract(1,"millisecond"),o=this.diff(a,e,!0);return o<0?r(this).startOf("week").week():Math.ceil(o)},f.weeks=function(e){return void 0===e&&(e=null),this.week(e)};}}));
42
+ }(weekOfYear$1));
43
+
44
+ const weekOfYear = weekOfYear$1.exports;
45
+
46
+ dayjs.extend(customParseFormat);
47
+ dayjs.extend(utc);
48
+ dayjs.extend(weekOfYear);
49
+ /**
50
+ * Formats a date to a string according to the format
51
+ * @param {Date} date - Date to format
52
+ * @returns {string} Formatted date
53
+ * @param {Object} options - Additional options
54
+ * @param {string} options.dateFormat - Date format (ex: 'YYYY-MM-DD', 'DD-MM-YYYY', etc.)
55
+ */
56
+ function formatDate(date, options) {
57
+ if (!date)
58
+ return '';
59
+ const isUTCMode = options.dateFormat.includes('Z');
60
+ const isISO8601Format = options.dateFormat === 'YYYY-MM-DD[T]HH:mm:ss[Z]';
61
+ // Special case for ISO 8601
62
+ if (isISO8601Format) {
63
+ // For the ISO 8601 format, use directly toISOString() which is standard
64
+ return date.toISOString();
65
+ }
66
+ // If the format is "Ticks", convert the time to C# ticks
67
+ if (options.dateFormat === 'Ticks') {
68
+ const ticks = date.getTime() * 10000 + 621355968000000000;
69
+ return ticks.toString();
70
+ }
71
+ // If the format is "X" (Unix Seconds)
72
+ if (options.dateFormat === 'X') {
73
+ return dayjs(date).unix().toString();
74
+ }
75
+ // If the format is "x" (Unix Milliseconds)
76
+ if (options.dateFormat === 'x') {
77
+ return date.getTime().toString();
78
+ }
79
+ // Otherwise, format according to the mode (UTC or local)
80
+ return isUTCMode
81
+ ? dayjs(date).utc().format(options.dateFormat)
82
+ : dayjs(date).format(options.dateFormat);
83
+ }
84
+ /**
85
+ * Checks if two dates are identical
86
+ * @param {Date | null} date - First date
87
+ * @param {Date | null} compareDate - Second date
88
+ * @param {Object} options - Additional options
89
+ * @param {boolean} options.isUTCMode - Whether the dates are in UTC mode
90
+ * @returns {boolean} true if the dates are identical
91
+ */
92
+ function isSameDate(date, compareDate, options) {
93
+ if (!date || !compareDate)
94
+ return false;
95
+ if (options.isUTCMode) {
96
+ return (date.getUTCFullYear() === compareDate.getUTCFullYear() &&
97
+ date.getUTCMonth() === compareDate.getUTCMonth() &&
98
+ date.getUTCDate() === compareDate.getUTCDate());
99
+ }
100
+ else {
101
+ return (date.getFullYear() === compareDate.getFullYear() &&
102
+ date.getMonth() === compareDate.getMonth() &&
103
+ date.getDate() === compareDate.getDate());
104
+ }
105
+ }
106
+ /**
107
+ * Checks if a date is identical or before another date
108
+ * @param {Date} date - Date to check
109
+ * @param {Date} compareDate - Reference date
110
+ * @param {Object} options - Additional options
111
+ * @param {boolean} options.isUTCMode - Whether the dates are in UTC mode
112
+ * @returns {boolean} true if `date` <= `compareDate`
113
+ */
114
+ function isSameOrBefore(date, compareDate, options) {
115
+ if (!date || !compareDate)
116
+ return false;
117
+ if (options.isUTCMode) {
118
+ return (date.getUTCFullYear() < compareDate.getUTCFullYear() ||
119
+ (date.getUTCFullYear() === compareDate.getUTCFullYear() &&
120
+ date.getUTCMonth() < compareDate.getUTCMonth()) ||
121
+ (date.getUTCFullYear() === compareDate.getUTCFullYear() &&
122
+ date.getUTCMonth() === compareDate.getUTCMonth() &&
123
+ date.getUTCDate() <= compareDate.getUTCDate()));
124
+ }
125
+ else {
126
+ return (date.getFullYear() < compareDate.getFullYear() ||
127
+ (date.getFullYear() === compareDate.getFullYear() &&
128
+ date.getMonth() < compareDate.getMonth()) ||
129
+ (date.getFullYear() === compareDate.getFullYear() &&
130
+ date.getMonth() === compareDate.getMonth() &&
131
+ date.getDate() <= compareDate.getDate()));
132
+ }
133
+ }
134
+ /**
135
+ * Checks if a date is identical or after another date
136
+ * @param {Date} date - Date to check
137
+ * @param {Date} compareDate - Reference date
138
+ * @param {Object} options - Additional options
139
+ * @param {boolean} options.isUTCMode - Whether the dates are in UTC mode
140
+ * @returns {boolean} true if `date` >= `compareDate`
141
+ */
142
+ function isSameOrAfter(date, compareDate, options) {
143
+ if (!date || !compareDate)
144
+ return false;
145
+ if (options.isUTCMode) {
146
+ return (date.getUTCFullYear() > compareDate.getUTCFullYear() ||
147
+ (date.getUTCFullYear() === compareDate.getUTCFullYear() &&
148
+ date.getUTCMonth() > compareDate.getUTCMonth()) ||
149
+ (date.getUTCFullYear() === compareDate.getUTCFullYear() &&
150
+ date.getUTCMonth() === compareDate.getUTCMonth() &&
151
+ date.getUTCDate() >= compareDate.getUTCDate()));
152
+ }
153
+ else {
154
+ return (date.getFullYear() > compareDate.getFullYear() ||
155
+ (date.getFullYear() === compareDate.getFullYear() &&
156
+ date.getMonth() > compareDate.getMonth()) ||
157
+ (date.getFullYear() === compareDate.getFullYear() &&
158
+ date.getMonth() === compareDate.getMonth() &&
159
+ date.getDate() >= compareDate.getDate()));
160
+ }
161
+ }
162
+ /**
163
+ * Calculates the ISO week number
164
+ * @param {Date} date - Date to calculate
165
+ * @returns {number} Week number
166
+ */
167
+ function getWeekNumber(date) {
168
+ const startOfYear = new Date(date.getFullYear(), 0, 1);
169
+ const pastDaysOfYear = (date.getTime() - startOfYear.getTime()) / 86400000;
170
+ return Math.ceil((pastDaysOfYear + startOfYear.getDay() + 1) / 7);
171
+ }
172
+ /**
173
+ * Convert a date string/Date to a Date without timezone offset
174
+ * @param {string | Date} dateInput - Date under string or Date object form
175
+ * @param {string} dateFormat - Date format (ex: 'YYYY-MM-DD', 'DD-MM-YYYY', etc.)
176
+ * @returns {Date} Date in Date form without timezone offset
177
+ */
178
+ function parseDate(dateInput, dateFormat) {
179
+ if (dateInput instanceof Date)
180
+ return dateInput;
181
+ const isUTCMode = dateFormat.includes('Z');
182
+ // Attempt to automatically detect ISO 8601 format (generated by toISOString())
183
+ // The regex checks the standard ISO format: YYYY-MM-DDTHH:mm:ss.sssZ
184
+ if (typeof dateInput === 'string' &&
185
+ /^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}.\d{3}Z$/.test(dateInput)) {
186
+ try {
187
+ const parsedDate = new Date(dateInput);
188
+ if (!isNaN(parsedDate.getTime())) {
189
+ return parsedDate;
190
+ }
191
+ }
192
+ catch (error) {
193
+ // If it fails, continue with other methods
194
+ console.error('Error parsing ISO date:', error);
195
+ }
196
+ }
197
+ // Handling Unix Seconds ("X") formats
198
+ if (dateFormat === 'X') {
199
+ const unixSeconds = Number(dateInput);
200
+ if (isNaN(unixSeconds))
201
+ return null;
202
+ return isUTCMode
203
+ ? dayjs.unix(unixSeconds).utc().toDate()
204
+ : dayjs.unix(unixSeconds).toDate();
205
+ }
206
+ // Handling Unix Milliseconds ("x") formats
207
+ if (dateFormat === 'x') {
208
+ const unixMilliseconds = Number(dateInput);
209
+ if (isNaN(unixMilliseconds))
210
+ return null;
211
+ return isUTCMode
212
+ ? dayjs(unixMilliseconds).utc().toDate()
213
+ : dayjs(unixMilliseconds).toDate();
214
+ }
215
+ // Handling C# Ticks format
216
+ if (dateFormat === 'Ticks') {
217
+ const ticks = Number(dateInput);
218
+ if (isNaN(ticks))
219
+ return null;
220
+ // Conversion of .NET ticks to milliseconds since Unix epoch
221
+ const unixMilliseconds = (ticks - 621355968000000000) / 10000;
222
+ return isUTCMode
223
+ ? dayjs(unixMilliseconds).utc().toDate()
224
+ : dayjs(unixMilliseconds).toDate();
225
+ }
226
+ // For all other formats, use customParseFormat in strict mode
227
+ let parsed;
228
+ if (isUTCMode) {
229
+ parsed = dayjs.utc(dateInput, dateFormat, true);
230
+ }
231
+ else {
232
+ parsed = dayjs(dateInput, dateFormat, true);
233
+ }
234
+ if (!parsed.isValid()) {
235
+ console.error(`Parsing error:`, {
236
+ dateInput,
237
+ dateFormat: dateFormat,
238
+ });
239
+ return null;
240
+ }
241
+ return parsed.toDate();
242
+ }
243
+
244
+ const nvCalendarCss = "nv-calendar{display:block}.datepicker-root{display:flex;justify-content:center;align-items:flex-start;width:auto}.datepicker-container{font-family:system-ui, sans-serif;display:flex;flex-direction:column;align-items:stretch;background:var(--components-calendar-background);border-radius:var(--calendar-radius);padding:var(--calendar-padding);box-shadow:0px var(--shadow-y-axis-md-1) var(--shadow-blur-md-1) var(--shadow-spread-md, 0) var(--shadow-color-opacity-0), 0px var(--shadow-y-axis-md-2) var(--shadow-blur-md-2) var(--shadow-spread-md, 0) var(--shadow-color-opacity-2);border:1px solid var(--components-calendar-border);width:auto;max-width:100%}.datepicker-container-single{max-width:300px}.datepicker-container-single .datepicker-wrapper:has(.shortcuts-placement-left),.datepicker-container-single .datepicker-wrapper:has(.shortcuts-placement-right){max-width:410px !important}.datepicker-container-single:has(.shortcuts-placement-left),.datepicker-container-single:has(.shortcuts-placement-right){max-width:410px !important}.datepicker-wrapper{display:flex;justify-content:center;align-items:flex-start;gap:var(--calendar-gap-x);width:auto;overflow-x:hidden}.datepicker-wrapper::-webkit-scrollbar{width:6px;height:6px}.datepicker-wrapper::-webkit-scrollbar-track{background-color:var(--color-level-10-background);border-radius:9999px}.datepicker-wrapper::-webkit-scrollbar-thumb{background-color:var(--color-gray-200);border-radius:9999px}.datepicker-wrapper.single{justify-content:center}.calendar-container{display:flex;flex-direction:column;align-items:center;padding:var(--calendar-padding);width:auto;position:relative}.calendar-separator{width:1px;background:var(--components-calendar-border);height:auto;min-height:100%;margin:0 10px}.header{display:flex;justify-content:start;align-items:center;margin-bottom:var(--calendar-header-margin-bottom);width:100%}.header nv-iconbutton{width:var(--calendar-header-button-size);height:var(--calendar-header-button-size)}.nav-buttons{display:flex;gap:var(--spacing-0);margin-left:auto}.nav-left{order:-1}.date-controls{display:flex;gap:var(--spacing-1);align-items:center;min-height:34px;justify-content:center}.datepicker-container-single .date-controls{justify-content:flex-start}.datepicker-container:not(.datepicker-container-single) .date-controls{justify-content:start;flex-grow:1}.date-controls .month-select,.date-controls .year-input{background:transparent !important}.calendar-wrapper:nth-child(n+2) .datepicker-container{margin-left:42px}.calendar-grid{display:grid;grid-template-columns:auto 1fr;column-gap:var(--calendar-weeks-calendar-gap-x);position:relative}.calendar-grid.slide-left{animation:slideLeft 0.3s ease-out}.calendar-grid.slide-right{animation:slideRight 0.3s ease-out}.week-numbers{display:grid;grid-template-rows:var(--calendar-cell-size) repeat(6, var(--calendar-cell-size));background:var(--components-calendar-weeks-background);color:var(--components-calendar-weeks-text);border-radius:var(--calendar-weeks-radius);width:var(--calendar-weeks-size);row-gap:var(--calendar-grid-gap-y)}.week-numbers .clickable{cursor:pointer}.week-numbers .clickable:hover{background-color:var(--components-calendar-weeks-background-hover);color:var(--components-calendar-weeks-text-hover);border-radius:var(--calendar-radius)}.week-header,.week-number{display:grid;place-items:center;font-size:var(--calendar-cell-font-size)}.week-header{font-weight:700;color:var(--components-calendar-weeks-text)}.week-number{color:var(--components-calendar-cell-text)}.days-container{display:grid;grid-template-rows:auto 1fr;row-gap:var(--calendar-grid-gap-y)}.days-header{display:grid;grid-template-columns:repeat(7, var(--calendar-cell-size));height:var(--calendar-cell-size)}.day-header{display:grid;place-items:center;font-size:var(--calendar-cell-font-size);color:var(--components-calendar-cell-text)}.days-grid{display:grid;grid-template-columns:repeat(7, var(--calendar-cell-size));grid-template-rows:repeat(6, var(--calendar-cell-size));animation:fadeIn 0.2s ease-in;row-gap:var(--calendar-grid-gap-y);z-index:0}.day{display:grid;place-items:center;width:var(--calendar-cell-size);height:var(--calendar-cell-size);font-size:var(--calendar-cell-font-size);border-radius:var(--calendar-cell-radius);cursor:pointer;border:none;background:transparent;transition:all 0.2s ease;text-align:center;animation:scaleIn 0.2s ease-out}.day:hover:not(.disabled,.empty,.selected){background:var(--components-calendar-cell-background-hover);color:var(--components-calendar-cell-text-hover)}.day.selected,.day.selected:hover .day.is-today.selected,.day.is-today.selected:hover{background:var(--components-calendar-cell-background-selected);color:var(--components-calendar-cell-text-selected) !important}.day.disabled{opacity:var(--opacity-disabled);cursor:not-allowed}.day.outside-month{color:var(--components-calendar-cell-text);opacity:var(--opacity-disabled)}.day.outside-month.selected{opacity:1 !important;color:var(--components-calendar-cell-text-selected)}.day.outside-month.in-range{opacity:0.5 !important;background-color:var(--components-calendar-cell-background-in-range);color:var(--components-calendar-cell-text-in-range)}.day.outside-month.in-range:hover{opacity:0.7 !important;background-color:var(--components-calendar-cell-background-in-range)}.day.in-range{background:var(--components-calendar-cell-background-in-range);color:var(--components-calendar-cell-text-in-range);border-radius:0;position:relative}.day.range-start,.day.range-start:focus,.day.range-start:hover,.day.range-end,.day.range-end:focus,.day.range-end:hover{background-color:var(--components-calendar-cell-background-selected) !important;color:var(--components-calendar-cell-text-selected) !important}.day.range-start,.day.range-end,.day.range-start.is-today,.day.range-end.is-today{background:var(--components-calendar-cell-background-selected);color:var(--components-calendar-cell-text-selected);position:relative;border-radius:var(--radius-rounded-full)}.day.range-start:hover,.day.range-end:hover,.day.range-start.is-today:hover,.day.range-end.is-today:hover{color:var(--components-calendar-cell-text-today)}.day.range-start:before,.day.range-end:before,.day.range-start.is-today:before,.day.range-end.is-today:before{content:\"\";position:absolute;bottom:0;left:0;right:0;top:0;z-index:-1;background-color:var(--components-calendar-cell-background-in-range);border-radius:var(--radius-rounded-full);width:auto;height:auto}.day.range-start:has(~.range-end):before,.day.range-start:has(+.in-range):before{border-top-right-radius:0;border-bottom-right-radius:0}.day.range-end:before{border-top-left-radius:0 !important;border-bottom-left-radius:0 !important}.day.outside-month.range-start,.day.outside-month.range-end{opacity:1 !important;background:var(--components-calendar-cell-background-selected) !important;color:var(--components-calendar-cell-text-selected)}.day.is-today{font-weight:700;position:relative;color:var(--components-calendar-cell-text-today)}.day.is-today.range-start,.day.is-today.range-end{color:var(--components-calendar-cell-text-selected)}.day.is-today.range-start:hover,.day.is-today.range-end:hover{color:var(--components-calendar-cell-text-today)}.day.is-today::after{content:\"\";position:absolute;bottom:var(--spacing-1);left:50%;transform:translateX(-50%);width:var(--calendar-cell-dot-size);height:var(--calendar-cell-dot-size);background-color:currentColor;border-radius:50%}.day.is-today.selected::after{color:var(--components-calendar-cell-text-selected)}.day.is-today.selected::after::after{background-color:var(--components-calendar-cell-dot-selected)}.calendar-footer{display:flex;gap:var(--spacing-1);justify-content:flex-start;width:100%;flex-wrap:wrap}.footer-placement-left{justify-content:flex-start}.footer-placement-right{justify-content:flex-end}.footer-placement-center{justify-content:center}.datepicker-controls{display:flex;flex-direction:column;border-top:1px solid var(--components-calendar-border);padding:var(--calendar-controls-padding-top) var(--calendar-padding) var(--calendar-padding);gap:var(--calendar-grid-gap-y);margin-top:var(--calendar-controls-margin-top)}.datepicker-actions{display:flex;justify-content:flex-end;gap:var(--spacing-1);width:100%}.datepicker-actions slot-fb{display:contents !important}.calendar-footer+.datepicker-actions{margin-top:0}.shortcuts-placement-left,.shortcuts-placement-right{display:flex;flex-direction:column;gap:var(--spacing-1);margin-top:var(--spacing-4)}.shortcuts-placement-left{align-items:flex-end}.shortcuts-placement-right{align-items:flex-start}@keyframes slideLeft{from{opacity:0;transform:translateX(20px)}to{opacity:1;transform:translateX(0)}}@keyframes slideRight{from{opacity:0;transform:translateX(-20px)}to{opacity:1;transform:translateX(0)}}@keyframes fadeIn{from{opacity:0;transform:translateY(10px)}to{opacity:1;transform:translateY(0)}}@keyframes scaleIn{from{opacity:0;transform:scale(0.9)}to{opacity:1;transform:scale(1)}}";
245
+ const NvCalendarStyle0 = nvCalendarCss;
246
+
247
+ const NvCalendar = /*@__PURE__*/ proxyCustomElement(class NvCalendar extends H {
248
+ constructor() {
249
+ super();
250
+ this.__registerHost();
251
+ this.singleDateChange = createEvent(this, "singleDateChange", 7);
252
+ this.rangeDateChange = createEvent(this, "rangeDateChange", 7);
253
+ /****************************************************************************/
254
+ //#region PROPERTIES
255
+ /**
256
+ * First day of the week (0 = Sunday, 1 = Monday, etc.)
257
+ * @default 0
258
+ */
259
+ this.firstDayOfWeek = 0;
260
+ /**
261
+ * Number of calendars to display
262
+ * @default 1
263
+ */
264
+ this.numberOfCalendars = 1;
265
+ /**
266
+ * Locale for date formatting
267
+ * @default 'en-BE'
268
+ */
269
+ this.locale = 'en-BE';
270
+ /**
271
+ * Date format (ex: 'YYYY-MM-DD', 'DD-MM-YYYY', etc.)
272
+ * @default 'YYYY-MM-DD'
273
+ * @note If the date format is in UTC mode, the date will be displayed in UTC time.
274
+ * @note If the date format is not in UTC mode, the date will be displayed in the local time.
275
+ */
276
+ this.dateFormat = 'YYYY-MM-DD';
277
+ /**
278
+ * Footer placement
279
+ * @default 'bottom'
280
+ */
281
+ this.shortcutsPlacement = 'bottom';
282
+ /**
283
+ * Selection type (single date or date range)
284
+ * @default 'single'
285
+ */
286
+ this.selectionType = 'single';
287
+ /**
288
+ * Show action buttons
289
+ */
290
+ this.showActions = false;
291
+ /** Cache for parsed disabled dates */
292
+ this.parsedDisabledDates = [];
293
+ //#endregion PROPERTIES
294
+ /****************************************************************************/
295
+ //#region STATE
296
+ this.currentDate = null;
297
+ this.selectedDate = null;
298
+ this.startDate = null;
299
+ this.endDate = null;
300
+ /** List of formatted months for the selector */
301
+ this.months = [];
302
+ /**
303
+ * Change the displayed month
304
+ * @param {number} offset - Month offset (-1 for previous, 1 for next)
305
+ */
306
+ this.changeMonth = (offset) => {
307
+ const newDate = new Date(this.currentDate);
308
+ // Ensure we only move by one month at a time
309
+ newDate.setUTCMonth(newDate.getUTCMonth() + offset);
310
+ // Add the appropriate animation class
311
+ const containers = this.el.querySelectorAll('.calendar-grid');
312
+ containers.forEach(container => {
313
+ // Remove existing animation classes
314
+ container.classList.remove('slide-left', 'slide-right');
315
+ // Add the new animation class
316
+ const animationClass = offset > 0 ? 'slide-left' : 'slide-right';
317
+ container.classList.add(animationClass);
318
+ // Remove the class after the animation
319
+ setTimeout(() => {
320
+ container.classList.remove(animationClass);
321
+ }, 300); // 300ms corresponds to $slide-duration in the SCSS
322
+ });
323
+ this.currentDate = newDate;
324
+ };
325
+ /**
326
+ * Handles date selection based on the mode
327
+ * @param {Date} date - Selected date
328
+ */
329
+ this.handleDateSelection = (date) => {
330
+ if (this.isDateDisabled(date)) {
331
+ return;
332
+ }
333
+ if (this.selectionType === 'single') {
334
+ this.handleSingleSelection(date);
335
+ }
336
+ else {
337
+ this.handleRangeSelection(date);
338
+ }
339
+ };
340
+ /**
341
+ * Handles single date selection
342
+ * @param {Date} date - Selected date
343
+ */
344
+ this.handleSingleSelection = (date) => {
345
+ if (!date)
346
+ return;
347
+ const formattedDate = formatDate(date, { dateFormat: this.dateFormat });
348
+ this.selectedDate = date;
349
+ this.singleDateChange.emit(formattedDate);
350
+ };
351
+ /**
352
+ * Handles range date selection
353
+ * @param {Date} date - Selected date
354
+ */
355
+ this.handleRangeSelection = (date) => {
356
+ if (!this.startDate || (this.startDate && this.endDate)) {
357
+ this.startDate = date;
358
+ this.endDate = null;
359
+ }
360
+ else {
361
+ this.endDate = date;
362
+ if (this.startDate > this.endDate) {
363
+ [this.startDate, this.endDate] = [this.endDate, this.startDate];
364
+ }
365
+ this.rangeDateChange.emit({
366
+ start: formatDate(this.startDate, { dateFormat: this.dateFormat }),
367
+ end: formatDate(this.endDate, { dateFormat: this.dateFormat }),
368
+ });
369
+ }
370
+ };
371
+ /**
372
+ * Checks if a date is disabled.
373
+ * Disabled if:
374
+ * - The date is before min (if defined)
375
+ * - The date is after max (if defined)
376
+ * - The date is in the disabledDates array
377
+ * @param {Date} date - Date to check
378
+ * @returns {boolean} true if the date is disabled
379
+ */
380
+ this.isDateDisabled = (date) => {
381
+ if (!date)
382
+ return true;
383
+ // Minimum bound check
384
+ if (this.min) {
385
+ const minDate = parseDate(this.min, this.dateFormat);
386
+ if (minDate && date < minDate) {
387
+ return true;
388
+ }
389
+ }
390
+ // Maximum bound check
391
+ if (this.max) {
392
+ const maxDate = parseDate(this.max, this.dateFormat);
393
+ if (maxDate && date > maxDate) {
394
+ return true;
395
+ }
396
+ }
397
+ // Check disabled dates
398
+ return this.parsedDisabledDates.some(disabledDate => isSameDate(date, disabledDate, { isUTCMode: this.isUTCMode }));
399
+ };
400
+ /**
401
+ * Checks if a date is in the selected range
402
+ * @param {Date} date - Date to check
403
+ * @returns {boolean} true if the date is in the range
404
+ */
405
+ this.isDateInRange = (date) => {
406
+ if (!date || !this.startDate || !this.endDate)
407
+ return false;
408
+ const checkDate = parseDate(date, this.dateFormat);
409
+ const startDate = parseDate(this.startDate, this.dateFormat);
410
+ const endDate = parseDate(this.endDate, this.dateFormat);
411
+ // Verify if startDate and endDate are valid
412
+ if (isNaN(startDate.getTime()) || isNaN(endDate.getTime())) {
413
+ return false;
414
+ }
415
+ // Verify that startDate is before endDate (additional security)
416
+ if (startDate > endDate)
417
+ return false;
418
+ // Comparison based only on the date (year, month, day)
419
+ return (isSameOrAfter(checkDate, startDate, { isUTCMode: this.isUTCMode }) &&
420
+ isSameOrBefore(checkDate, endDate, { isUTCMode: this.isUTCMode }));
421
+ };
422
+ /**
423
+ * Retrieves the localized day names
424
+ * @returns {string[]} Array of short day names
425
+ */
426
+ this.getDayNames = () => {
427
+ // If we have custom day names for this locale
428
+ if (CUSTOM_DAY_NAMES[this.locale]) {
429
+ const days = [...CUSTOM_DAY_NAMES[this.locale]];
430
+ // Reorganize the days based on the first day of the week
431
+ const firstDays = days.slice(0, this.firstDayOfWeek);
432
+ const remainingDays = days.slice(this.firstDayOfWeek);
433
+ return [...remainingDays, ...firstDays];
434
+ }
435
+ // Otherwise, use the default behavior
436
+ const formatter = new Intl.DateTimeFormat(this.locale, {
437
+ weekday: 'short',
438
+ });
439
+ const days = [...Array(7)].map((_, i) => formatter.format(new Date(2023, 0, i + 1)).toUpperCase());
440
+ // Reorganize the days based on the first day of the week
441
+ const firstDays = days.slice(0, this.firstDayOfWeek);
442
+ const remainingDays = days.slice(this.firstDayOfWeek);
443
+ return [...remainingDays, ...firstDays];
444
+ };
445
+ /**
446
+ * Generates the days of the current month
447
+ * @param {number} offset - Month offset (0 by default)
448
+ * @param {number} totalCalendars - Number of calendars to display (1 by default)
449
+ * @returns {Array<{ dayOfMonth: number | null, date: Date | null, isSelected: boolean, isDisabled: boolean }>} Array of formatted days
450
+ */
451
+ this.getDaysInMonth = (offset = 0, totalCalendars = 1) => {
452
+ const year = this.currentDate.getUTCFullYear();
453
+ const month = this.currentDate.getUTCMonth() + offset;
454
+ const firstDay = new Date(Date.UTC(year, month, 1));
455
+ const lastDay = new Date(Date.UTC(year, month + 1, 0));
456
+ const days = [];
457
+ // Correct calculation of offset for previous month days
458
+ // Use getUTCDay to stay consistent with UTC timezone
459
+ const dayOfWeekIndex = firstDay.getUTCDay(); // 0 = Sunday, 1 = Monday, etc.
460
+ // Adjust based on firstDayOfWeek (if week starts on Monday, offset is different)
461
+ const offsetDays = (dayOfWeekIndex - this.firstDayOfWeek + 7) % 7;
462
+ // Add the days of the previous month for the first calendar
463
+ if (offset === 0 && offsetDays > 0) {
464
+ const prevMonthLastDay = new Date(Date.UTC(year, month, 0)).getUTCDate();
465
+ for (let i = offsetDays; i > 0; i--) {
466
+ const date = new Date(Date.UTC(year, month - 1, prevMonthLastDay - i + 1));
467
+ days.push({
468
+ dayOfMonth: date.getUTCDate(),
469
+ date,
470
+ isCurrentMonth: false,
471
+ isDisabled: this.isDateDisabled(date),
472
+ });
473
+ }
474
+ }
475
+ // Add the days of the current month
476
+ for (let i = 1; i <= lastDay.getUTCDate(); i++) {
477
+ const date = new Date(Date.UTC(year, month, i));
478
+ days.push({
479
+ dayOfMonth: i,
480
+ date,
481
+ isCurrentMonth: true,
482
+ isDisabled: this.isDateDisabled(date),
483
+ });
484
+ }
485
+ // Add the days of the next month only for the last calendar
486
+ if (offset === totalCalendars - 1) {
487
+ const nextMonthDaysNeeded = 7 - (days.length % 7 || 7);
488
+ for (let i = 1; i <= nextMonthDaysNeeded; i++) {
489
+ const date = new Date(Date.UTC(year, month + 1, i));
490
+ days.push({
491
+ dayOfMonth: i,
492
+ date,
493
+ isCurrentMonth: false,
494
+ isDisabled: this.isDateDisabled(date),
495
+ });
496
+ }
497
+ }
498
+ return days;
499
+ };
500
+ /** Initializes the list of formatted months according to the locale */
501
+ this.initializeMonths = () => {
502
+ // If we have custom month names for this locale
503
+ if (CUSTOM_MONTH_NAMES[this.locale]) {
504
+ this.months = CUSTOM_MONTH_NAMES[this.locale].map((label, value) => ({
505
+ value,
506
+ label,
507
+ }));
508
+ return;
509
+ }
510
+ // Otherwise, use the default behavior
511
+ const formatter = new Intl.DateTimeFormat(this.locale, { month: 'short' });
512
+ this.months = Array.from({ length: 12 }, (_, i) => ({
513
+ value: i,
514
+ label: formatter.format(new Date(2000, i, 1)).toUpperCase(),
515
+ }));
516
+ };
517
+ /**
518
+ * Retrieves the localized abbreviation for "week"
519
+ * @returns {string} Localized abbreviation for "week"
520
+ */
521
+ this.getLocalizedWeekText = () => {
522
+ return WEEK_ABBREVIATIONS[this.locale] || 'W';
523
+ };
524
+ /**
525
+ * Handles month change in the selector
526
+ * @param {Event} event - Month change event
527
+ * @param {number} calendarOffset - Calendar offset (0 by default)
528
+ */
529
+ this.handleMonthChange = (event, calendarOffset = 0) => {
530
+ const select = event.target;
531
+ const selectedMonth = parseInt(select.value, 10);
532
+ const currentMonth = this.currentDate.getUTCMonth();
533
+ // Calculate the difference considering the calendar offset
534
+ const monthDiff = selectedMonth - ((currentMonth + calendarOffset) % 12);
535
+ const newDate = new Date(this.currentDate);
536
+ newDate.setUTCMonth(newDate.getUTCMonth() + monthDiff);
537
+ this.currentDate = newDate;
538
+ };
539
+ /**
540
+ * Handles year change in the numeric entry
541
+ * @param {Event} event - Year change event
542
+ * @param {number} calendarOffset - Calendar offset (0 by default)
543
+ */
544
+ this.handleYearChange = (event, calendarOffset = 0) => {
545
+ const input = event.target;
546
+ const year = parseInt(input.value, 10);
547
+ if (!isNaN(year) && year >= 1900 && year <= 2100) {
548
+ const newDate = new Date(this.currentDate);
549
+ newDate.setUTCFullYear(year);
550
+ newDate.setUTCMonth(newDate.getUTCMonth() + calendarOffset);
551
+ this.currentDate = newDate;
552
+ }
553
+ };
554
+ /**
555
+ * Handles week selection
556
+ * @param {Date[]} weekDays - Selected week days
557
+ * @param {number} calendarIndex - Calendar index from which the selection is made
558
+ */
559
+ this.handleWeekSelection = (weekDays, calendarIndex) => {
560
+ if (this.selectionType !== 'range')
561
+ return;
562
+ const allDays = this.getDaysInMonth(calendarIndex, this.numberOfCalendars);
563
+ const weekStart = weekDays[0];
564
+ const weekEnd = weekDays[weekDays.length - 1];
565
+ if (!weekStart || !weekEnd)
566
+ return;
567
+ const selectedWeekDays = allDays.filter(day => day.date && day.date >= weekStart && day.date <= weekEnd);
568
+ const validDays = selectedWeekDays.filter(day => !this.isDateDisabled(day.date));
569
+ if (validDays.length > 0) {
570
+ this.startDate = validDays[0].date;
571
+ this.endDate = validDays[validDays.length - 1].date;
572
+ this.rangeDateChange.emit({
573
+ start: formatDate(this.startDate, { dateFormat: this.dateFormat }),
574
+ end: formatDate(this.endDate, { dateFormat: this.dateFormat }),
575
+ });
576
+ }
577
+ };
578
+ /**
579
+ * Checks if a date corresponds to today
580
+ * @param {Date} date - Date to check
581
+ * @returns {boolean} true if the date is today
582
+ */
583
+ this.isToday = (date) => {
584
+ const today = new Date();
585
+ return (date.getDate() === today.getDate() &&
586
+ date.getMonth() === today.getMonth() &&
587
+ date.getFullYear() === today.getFullYear());
588
+ };
589
+ /**
590
+ * Parse and cache the disabled dates
591
+ * @description Parse and cache the disabled dates
592
+ */
593
+ this.parseDisabledDates = () => {
594
+ if (!this.disabledDates) {
595
+ this.parsedDisabledDates = [];
596
+ return;
597
+ }
598
+ try {
599
+ this.parsedDisabledDates = this.disabledDates
600
+ .map(date => parseDate(date, this.dateFormat))
601
+ .filter(date => date !== null);
602
+ }
603
+ catch (error) {
604
+ console.error('Error parsing disabled dates:', error);
605
+ this.parsedDisabledDates = [];
606
+ }
607
+ };
608
+ /**
609
+ * Applies a shortcut selection
610
+ * @param {Object} shortcut - Shortcut to apply
611
+ * @param {string | Date} shortcut.singleValue - Selected date value
612
+ * @param {Object} shortcut.rangeValue - Start and end date values
613
+ * @param {string | Date} shortcut.rangeValue.start - Start date value
614
+ * @param {string | Date} shortcut.rangeValue.end - End date value
615
+ * @param {string} shortcut.label - Label
616
+ */
617
+ this.applyShortcut = (shortcut) => {
618
+ this.selectedDate = null;
619
+ this.startDate = null;
620
+ this.endDate = null;
621
+ if (shortcut.singleValue) {
622
+ const newDate = parseDate(shortcut.singleValue, this.dateFormat);
623
+ this.selectedDate = newDate;
624
+ this.singleDateChange.emit(formatDate(newDate, { dateFormat: this.dateFormat }));
625
+ this.singleValue = formatDate(newDate, { dateFormat: this.dateFormat });
626
+ if (!this.showActions) {
627
+ const event = new CustomEvent('closePopover', {
628
+ bubbles: true,
629
+ composed: true,
630
+ });
631
+ this.el.dispatchEvent(event);
632
+ }
633
+ this.forceCalendarUpdate(newDate);
634
+ }
635
+ else {
636
+ const start = parseDate(shortcut.rangeValue.start, this.dateFormat);
637
+ const end = parseDate(shortcut.rangeValue.end, this.dateFormat);
638
+ this.startDate = start;
639
+ this.endDate = end;
640
+ this.rangeDateChange.emit({
641
+ start: formatDate(start, { dateFormat: this.dateFormat }),
642
+ end: formatDate(end, { dateFormat: this.dateFormat }),
643
+ });
644
+ this.rangeValue = {
645
+ start: formatDate(start, { dateFormat: this.dateFormat }),
646
+ end: formatDate(end, { dateFormat: this.dateFormat }),
647
+ };
648
+ if (!this.showActions) {
649
+ const event = new CustomEvent('closePopover', {
650
+ bubbles: true,
651
+ composed: true,
652
+ });
653
+ this.el.dispatchEvent(event);
654
+ }
655
+ this.currentDate = start;
656
+ }
657
+ };
658
+ /**
659
+ * Method to force the complete calendar update
660
+ * @param {Date} newDate - Date to force
661
+ */
662
+ this.forceCalendarUpdate = newDate => {
663
+ this.currentDate = new Date(newDate);
664
+ };
665
+ /**
666
+ * Handles month change with an offset
667
+ * @param {number} direction - Direction (-1 for previous, 1 for next)
668
+ * @returns {Function} Change month handler
669
+ */
670
+ this.getChangeMonthHandler = (direction) => {
671
+ return () => this.changeMonth(direction);
672
+ };
673
+ /**
674
+ * Handles month change from an event (ex: dropdown)
675
+ * @param {number} offset - Month offset (0 by default)
676
+ * @returns {Function} Change month handler
677
+ */
678
+ this.getHandleMonthChange = (offset) => {
679
+ return (event) => this.handleMonthChange(event, offset);
680
+ };
681
+ /**
682
+ * Handles year change from an event (ex: dropdown)
683
+ * @param {number} offset - Year offset (0 by default)
684
+ * @returns {Function} Change year handler
685
+ */
686
+ this.getHandleYearChange = (offset) => {
687
+ return (event) => this.handleYearChange(event, offset);
688
+ };
689
+ /**
690
+ * Handles day click
691
+ * @param {Date} date - Date to handle
692
+ * @param {boolean} isDisabled - Whether the date is disabled
693
+ * @returns {Function} Day click handler
694
+ */
695
+ this.getDayClickHandler = (date, isDisabled) => {
696
+ return isDisabled ? undefined : () => this.handleDateSelection(date);
697
+ };
698
+ /**
699
+ * Handles shortcut selection
700
+ * @param {Object} shortcut - Shortcut to handle
701
+ * @param {string | Date} shortcut.singleValue - Selected date value
702
+ * @param {Object} shortcut.rangeValue - Start and end date values
703
+ * @param {string | Date} shortcut.rangeValue.start - Start date value
704
+ * @param {string | Date} shortcut.rangeValue.end - End date value
705
+ * @param {string} shortcut.label - Label
706
+ * @returns {Function} Shortcut selection handler
707
+ */
708
+ this.getShortcutHandler = (shortcut) => {
709
+ return () => this.applyShortcut(shortcut);
710
+ };
711
+ /**
712
+ * Handles week selection
713
+ * @param {Date[]} dates - Dates to handle
714
+ * @param {number} index - Calendar index
715
+ * @returns {Function} Week selection handler
716
+ */
717
+ this.getWeekSelectionHandler = (dates, index) => {
718
+ return () => {
719
+ if (this.selectionType === 'range') {
720
+ this.handleWeekSelection(dates, index);
721
+ }
722
+ };
723
+ };
724
+ /**
725
+ * Resets the current selection
726
+ */
727
+ this.resetSelection = () => {
728
+ if (this.selectionType === 'single') {
729
+ this.selectedDate = null;
730
+ this.singleValue = null;
731
+ this.singleDateChange.emit('');
732
+ }
733
+ else {
734
+ this.startDate = null;
735
+ this.endDate = null;
736
+ this.rangeValue = null;
737
+ this.rangeDateChange.emit({ start: '', end: '' });
738
+ }
739
+ };
740
+ /**
741
+ * Confirms the current selection
742
+ */
743
+ this.confirmSelection = () => {
744
+ if (this.selectionType === 'single' && this.selectedDate) {
745
+ const dateStr = formatDate(this.selectedDate, {
746
+ dateFormat: this.dateFormat,
747
+ });
748
+ this.singleDateChange.emit(dateStr);
749
+ this.singleValue = dateStr;
750
+ const event = new CustomEvent('closePopover', {
751
+ bubbles: true,
752
+ composed: true,
753
+ });
754
+ this.el.dispatchEvent(event);
755
+ }
756
+ else if (this.selectionType === 'range' &&
757
+ this.startDate &&
758
+ this.endDate) {
759
+ this.rangeDateChange.emit({
760
+ start: formatDate(this.startDate, { dateFormat: this.dateFormat }),
761
+ end: formatDate(this.endDate, { dateFormat: this.dateFormat }),
762
+ });
763
+ this.rangeValue = {
764
+ start: formatDate(this.startDate, { dateFormat: this.dateFormat }),
765
+ end: formatDate(this.endDate, { dateFormat: this.dateFormat }),
766
+ };
767
+ const event = new CustomEvent('closePopover', {
768
+ bubbles: true,
769
+ composed: true,
770
+ });
771
+ this.el.dispatchEvent(event);
772
+ }
773
+ };
774
+ //#endregion METHODS
775
+ /****************************************************************************/
776
+ //#region RENDER
777
+ /**
778
+ * Renders the header
779
+ * @param {number} offset - Month offset
780
+ * @param {number} index - Calendar index
781
+ * @returns {JSX.Element} Header
782
+ * @description Renders the header of the calendar
783
+ */
784
+ this.renderHeader = (offset, index) => {
785
+ return (h("div", { class: "header" }, this.numberOfCalendars > 1 && index === 0 && (h("nv-iconbutton", { class: "nav-left", emphasis: "lower", name: "chevron-left", onClick: this.getChangeMonthHandler(-1) })), h("div", { class: "date-controls" }, h("select", { class: "month-select mr-4", onChange: this.getHandleMonthChange(offset) }, this.months.map(month => (h("option", { key: month.value, value: month.value, selected: month.value === (this.currentDate.getUTCMonth() + offset) % 12 }, month.label)))), h("input", { type: "number", class: "year-input", min: "1950", max: "2100", value: this.currentDate.getUTCFullYear() +
786
+ Math.floor((this.currentDate.getUTCMonth() + offset) / 12), onChange: this.getHandleYearChange(offset) })), this.numberOfCalendars === 1 && (h("div", { class: "nav-buttons" }, h("nv-iconbutton", { emphasis: "lower", name: "chevron-left", onClick: this.getChangeMonthHandler(-1) }), h("nv-iconbutton", { emphasis: "lower", name: "chevron-right", onClick: this.getChangeMonthHandler(1) }))), this.numberOfCalendars > 1 && index === this.numberOfCalendars - 1 && (h("nv-iconbutton", { emphasis: "lower", name: "chevron-right", onClick: this.getChangeMonthHandler(1), class: "nav-right" }))));
787
+ };
788
+ /**
789
+ * Renders the week numbers
790
+ * @param {Array<{date: Date}>} weeks - Weeks to render
791
+ * @param {number} index - Calendar index
792
+ * @returns {JSX.Element} Week numbers
793
+ * @description Renders the week numbers of the calendar
794
+ */
795
+ this.renderWeekNumbers = (
796
+ /** Weeks to render */
797
+ weeks,
798
+ /** Calendar index */
799
+ index) => {
800
+ return (h("div", { class: "week-numbers" }, h("div", { class: "week-header" }, this.getLocalizedWeekText()), weeks.map((week, weekIndex) => {
801
+ var _a;
802
+ const dates = week.map(d => d.date);
803
+ return (h("div", { class: `week-number ${this.selectionType === 'range' ? 'clickable' : ''}`, onClick: this.getWeekSelectionHandler(dates, index), key: `week-${weekIndex}` }, getWeekNumber(((_a = week.find(d => d.date)) === null || _a === void 0 ? void 0 : _a.date) || new Date())));
804
+ })));
805
+ };
806
+ this.renderDaysGrid = (
807
+ /** Days to render */
808
+ days) => {
809
+ return (h("div", { class: "days-grid" }, days.map(day => {
810
+ const date = day.date;
811
+ if (!date)
812
+ return null;
813
+ const isSelected = this.selectionType === 'single' &&
814
+ isSameDate(date, this.selectedDate, { isUTCMode: this.isUTCMode });
815
+ const isInRange = this.isDateInRange(date);
816
+ const isStart = isSameDate(date, this.startDate, {
817
+ isUTCMode: this.isUTCMode,
818
+ });
819
+ const isEnd = isSameDate(date, this.endDate, {
820
+ isUTCMode: this.isUTCMode,
821
+ });
822
+ const isToday = this.isToday(date);
823
+ const isOutsideMonth = !day.isCurrentMonth;
824
+ const dayClasses = [
825
+ 'day',
826
+ isSelected ? 'selected' : '',
827
+ isStart ? 'range-start' : '',
828
+ isEnd ? 'range-end' : '',
829
+ isInRange ? 'in-range' : '',
830
+ day.isDisabled ? 'disabled' : '',
831
+ isOutsideMonth ? 'outside-month' : '',
832
+ isToday ? 'is-today' : '',
833
+ ];
834
+ return (h("div", { class: dayClasses.filter(Boolean).join(' '), onClick: this.getDayClickHandler(date, day.isDisabled), "aria-disabled": day.isDisabled, key: `day-${date.toISOString()}` }, day.dayOfMonth));
835
+ })));
836
+ };
837
+ /**
838
+ * Renders the calendar
839
+ * @param {number} index - Calendar index
840
+ * @param {number} offset - Month offset
841
+ * @returns {JSX.Element} Calendar
842
+ * @description Renders the calendar of the calendar
843
+ */
844
+ this.renderCalendar = (
845
+ /** Calendar index */
846
+ index,
847
+ /** Month offset */
848
+ offset) => {
849
+ const days = this.getDaysInMonth(offset, this.numberOfCalendars);
850
+ const weeks = [];
851
+ for (let i = 0; i < days.length; i += 7) {
852
+ weeks.push(days.slice(i, i + 7));
853
+ }
854
+ return (h("div", { class: "calendar-wrapper" }, h("div", { class: "calendar-container", key: `calendar-${index}` }, this.renderHeader(offset, index), h("div", { class: "calendar-grid" }, this.showWeekNumbers && this.renderWeekNumbers(weeks, index), h("div", { class: "days-container" }, h("div", { class: "days-header" }, this.getDayNames().map(day => (h("div", { class: "day-header" }, day)))), this.renderDaysGrid(days)))), index < this.numberOfCalendars - 1 && (h("div", { class: "calendar-separator" }))));
855
+ };
856
+ /**
857
+ * Renders the shortcuts
858
+ * @returns {JSX.Element} Shortcuts
859
+ * @description Renders the shortcuts of the calendar
860
+ */
861
+ this.renderShortcuts = () => {
862
+ if (!this.hasShortcuts) {
863
+ return null;
864
+ }
865
+ return (h("div", { class: `shortcuts-container shortcuts-placement-${this.shortcutsPlacement}` }, this.shortcuts.map(shortcut => (h("nv-button", { emphasis: "lower", size: "xs", "aria-label": shortcut.label, onClick: this.getShortcutHandler(shortcut) }, shortcut.label)))));
866
+ };
867
+ /**
868
+ * Renders the actions
869
+ * @returns {JSX.Element} Actions
870
+ * @description Renders the actions of the calendar
871
+ * @slot actions - Child content of the component.
872
+ */
873
+ this.renderActions = () => {
874
+ return (h("div", { class: "datepicker-actions" }, h("slot", { name: "actions" }, h("nv-button", { emphasis: "low", size: "xs", onClick: this.resetSelection }, "Cancel"), h("nv-button", { size: "xs", onClick: this.confirmSelection }, "OK"))));
875
+ };
876
+ }
877
+ //#endregion EVENTS
878
+ /****************************************************************************/
879
+ //#region WATCHERS
880
+ /**
881
+ * Watches the changes of the number of calendars
882
+ * @param {number} newValue - New number of calendars
883
+ */
884
+ validateNumberOfCalendars(newValue) {
885
+ if (newValue < 1 || newValue > 4) {
886
+ console.warn('numberOfCalendars must be between 1 and 4. Defaulting to 1.');
887
+ this.numberOfCalendars = 1;
888
+ }
889
+ }
890
+ /**
891
+ * Watches the changes of the selected date range
892
+ * @param {Object} newValue - New rangeValue value
893
+ * @param {string} newValue.start - Start date
894
+ * @param {string} newValue.end - End date
895
+ */
896
+ onRangeValueChange(newValue) {
897
+ if (newValue && newValue.start && newValue.end) {
898
+ try {
899
+ const { startDate, endDate } = this.validateDateRange(newValue.start, newValue.end);
900
+ this.startDate = startDate;
901
+ this.endDate = endDate;
902
+ // Do not navigate to the start date if data-prevent-navigation attribute is present
903
+ const preventNavigation = this.el.getAttribute('data-prevent-navigation') === 'true';
904
+ if (!preventNavigation) {
905
+ this.currentDate = startDate;
906
+ }
907
+ }
908
+ catch (error) {
909
+ console.error('Invalid rangeValue:', error);
910
+ }
911
+ }
912
+ }
913
+ /**
914
+ * Watches the changes of the disabled dates
915
+ * @description Watches the changes of the disabled dates
916
+ */
917
+ handleDisabledDatesChange() {
918
+ this.parseDisabledDates();
919
+ }
920
+ /**
921
+ * Watches the changes of the single value
922
+ * @param {string} newValue - New single value
923
+ * @param {string} oldValue - Old single value
924
+ */
925
+ onSingleValueChange(newValue, oldValue) {
926
+ if (this.selectionType === 'single' && newValue !== oldValue && newValue) {
927
+ const parsedDate = parseDate(newValue, this.dateFormat);
928
+ if (parsedDate) {
929
+ this.selectedDate = parsedDate;
930
+ // Do not navigate to the selected date if data-prevent-navigation attribute is present
931
+ const preventNavigation = this.el.getAttribute('data-prevent-navigation') === 'true';
932
+ if (!preventNavigation) {
933
+ this.currentDate = parsedDate;
934
+ }
935
+ }
936
+ }
937
+ }
938
+ //#endregion WATCHERS
939
+ /****************************************************************************/
940
+ //#region LIFECYCLE
941
+ componentWillLoad() {
942
+ this.parseDisabledDates();
943
+ if (this.selectionType === 'single' && this.singleValue) {
944
+ this.selectedDate = parseDate(this.singleValue, this.dateFormat);
945
+ this.currentDate = this.selectedDate;
946
+ }
947
+ else if (this.selectionType === 'range' && this.rangeValue) {
948
+ try {
949
+ if (this.rangeValue.start && this.rangeValue.end) {
950
+ const { startDate, endDate, swapped } = this.validateDateRange(this.rangeValue.start, this.rangeValue.end);
951
+ this.startDate = startDate;
952
+ this.endDate = endDate;
953
+ this.currentDate = startDate;
954
+ if (swapped) {
955
+ // If dates were swapped, update the rangeValue property
956
+ this.rangeValue = {
957
+ start: formatDate(startDate, { dateFormat: this.dateFormat }),
958
+ end: formatDate(endDate, { dateFormat: this.dateFormat }),
959
+ };
960
+ }
961
+ }
962
+ }
963
+ catch (error) {
964
+ console.error('Invalid rangeValue:', error);
965
+ }
966
+ }
967
+ else {
968
+ this.currentDate = new Date();
969
+ }
970
+ this.initializeMonths();
971
+ }
972
+ //#endregion LIFECYCLE
973
+ /****************************************************************************/
974
+ //#region METHODS
975
+ /**
976
+ * Checks if shortcuts are visible
977
+ * @returns {boolean} true if shortcuts are visible
978
+ */
979
+ get hasShortcuts() {
980
+ return Boolean(this.shortcutsPlacement && this.shortcuts);
981
+ }
982
+ /**
983
+ * Checks if actions are visible
984
+ * @returns {boolean} true if actions are visible
985
+ */
986
+ get hasActions() {
987
+ return this.showActions;
988
+ }
989
+ /**
990
+ * Checks if the date format is in UTC mode
991
+ * @returns {boolean} true if the date format is in UTC mode
992
+ */
993
+ get isUTCMode() {
994
+ return this.dateFormat.includes('Z');
995
+ }
996
+ /**
997
+ * Validates and processes a date range, warning if start is after end
998
+ * @param {string} startDateStr - Start date in ISO string format
999
+ * @param {string} endDateStr - End date in ISO string format
1000
+ * @returns {object} Object containing the validated start and end dates
1001
+ */
1002
+ validateDateRange(startDateStr, endDateStr) {
1003
+ try {
1004
+ const startDate = parseDate(startDateStr, this.dateFormat);
1005
+ const endDate = parseDate(endDateStr, this.dateFormat);
1006
+ if (startDate && endDate && startDate > endDate) {
1007
+ console.warn(`Warning: startDate (${formatDate(startDate, {
1008
+ dateFormat: this.dateFormat,
1009
+ })}) is after endDate (${formatDate(endDate, {
1010
+ dateFormat: this.dateFormat,
1011
+ })})`);
1012
+ // Return dates in correct order, with swapped flag
1013
+ return {
1014
+ startDate: endDate,
1015
+ endDate: startDate,
1016
+ swapped: true,
1017
+ };
1018
+ }
1019
+ return {
1020
+ startDate,
1021
+ endDate,
1022
+ swapped: false,
1023
+ };
1024
+ }
1025
+ catch (error) {
1026
+ console.error('Invalid date range:', error);
1027
+ throw error; // Re-throw to let the caller handle it
1028
+ }
1029
+ }
1030
+ /**
1031
+ * Renders the datepicker
1032
+ * @returns {JSX.Element} Datepicker
1033
+ * @description Renders the datepicker of the calendar
1034
+ * @slot default - Child content of the component.
1035
+ */
1036
+ render() {
1037
+ return (h(Host, { key: '9804c486acf32e12f2d88f932a54ca6260365887' }, h("div", { key: '8503f585401191b904f2de248ed0c24b1fed1505', class: "datepicker-root" }, h("div", { key: '9da71618bd2031b44f5a3fd889d40b2580fcca58', class: `datepicker-container ${this.numberOfCalendars === 1 ? 'datepicker-container-single' : ''}` }, h("div", { key: 'fbf71a34b520ca48f1440d8caeec442773b1e57a', class: `datepicker-wrapper ${this.numberOfCalendars === 1 ? 'single' : ''}` }, this.shortcutsPlacement === 'left' && this.renderShortcuts(), Array.from({ length: this.numberOfCalendars }, (_, index) => this.renderCalendar(index, index)), this.shortcutsPlacement === 'right' && this.renderShortcuts()), ((this.hasShortcuts && this.shortcutsPlacement === 'bottom') ||
1038
+ this.hasActions) && (h("div", { key: '4431e3f1221e9d47807d58af380dcaa91bf05c48', class: "datepicker-controls" }, this.shortcutsPlacement === 'bottom' && this.renderShortcuts(), this.hasActions && this.renderActions())))), h("slot", { key: '30386356bda72f4f12a28351084ab498ec95f5b9' })));
1039
+ }
1040
+ get el() { return this; }
1041
+ static get watchers() { return {
1042
+ "numberOfCalendars": ["validateNumberOfCalendars"],
1043
+ "rangeValue": ["onRangeValueChange"],
1044
+ "disabledDates": ["handleDisabledDatesChange"],
1045
+ "singleValue": ["onSingleValueChange"]
1046
+ }; }
1047
+ static get style() { return NvCalendarStyle0; }
1048
+ }, [4, "nv-calendar", {
1049
+ "firstDayOfWeek": [514, "first-day-of-week"],
1050
+ "numberOfCalendars": [1538, "number-of-calendars"],
1051
+ "singleValue": [1537, "single-value"],
1052
+ "rangeValue": [1040],
1053
+ "min": [513],
1054
+ "max": [513],
1055
+ "disabledDates": [16],
1056
+ "locale": [513],
1057
+ "dateFormat": [513, "date-format"],
1058
+ "shortcutsPlacement": [513, "shortcuts-placement"],
1059
+ "selectionType": [513, "selection-type"],
1060
+ "showActions": [516, "show-actions"],
1061
+ "shortcuts": [16],
1062
+ "showWeekNumbers": [516, "show-week-numbers"],
1063
+ "currentDate": [32],
1064
+ "selectedDate": [32],
1065
+ "startDate": [32],
1066
+ "endDate": [32],
1067
+ "months": [32]
1068
+ }, undefined, {
1069
+ "numberOfCalendars": ["validateNumberOfCalendars"],
1070
+ "rangeValue": ["onRangeValueChange"],
1071
+ "disabledDates": ["handleDisabledDatesChange"],
1072
+ "singleValue": ["onSingleValueChange"]
1073
+ }]);
1074
+ function defineCustomElement() {
1075
+ if (typeof customElements === "undefined") {
1076
+ return;
1077
+ }
1078
+ const components = ["nv-calendar", "nv-button", "nv-icon", "nv-iconbutton", "nv-loader"];
1079
+ components.forEach(tagName => { switch (tagName) {
1080
+ case "nv-calendar":
1081
+ if (!customElements.get(tagName)) {
1082
+ customElements.define(tagName, NvCalendar);
1083
+ }
1084
+ break;
1085
+ case "nv-button":
1086
+ if (!customElements.get(tagName)) {
1087
+ defineCustomElement$4();
1088
+ }
1089
+ break;
1090
+ case "nv-icon":
1091
+ if (!customElements.get(tagName)) {
1092
+ defineCustomElement$3();
1093
+ }
1094
+ break;
1095
+ case "nv-iconbutton":
1096
+ if (!customElements.get(tagName)) {
1097
+ defineCustomElement$2();
1098
+ }
1099
+ break;
1100
+ case "nv-loader":
1101
+ if (!customElements.get(tagName)) {
1102
+ defineCustomElement$1();
1103
+ }
1104
+ break;
1105
+ } });
1106
+ }
1107
+ defineCustomElement();
1108
+
1109
+ export { NvCalendar as N, commonjsGlobal as c, defineCustomElement as d, getDefaultExportFromCjs as g };
1110
+
1111
+ //# sourceMappingURL=p-4656efae.js.map