primevue 3.16.2 → 3.17.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 (797) hide show
  1. package/README.md +2 -1
  2. package/accordion/Accordion.d.ts +23 -5
  3. package/accordion/Accordion.vue +194 -77
  4. package/accordion/accordion.cjs.js +202 -96
  5. package/accordion/accordion.cjs.min.js +1 -1
  6. package/accordion/accordion.esm.js +200 -98
  7. package/accordion/accordion.esm.min.js +1 -1
  8. package/accordion/accordion.js +203 -98
  9. package/accordion/accordion.min.js +1 -1
  10. package/accordiontab/AccordionTab.d.ts +33 -5
  11. package/accordiontab/AccordionTab.vue +8 -1
  12. package/accordiontab/accordiontab.cjs.js +7 -0
  13. package/accordiontab/accordiontab.cjs.min.js +1 -1
  14. package/accordiontab/accordiontab.esm.js +7 -0
  15. package/accordiontab/accordiontab.esm.min.js +1 -1
  16. package/accordiontab/accordiontab.js +7 -0
  17. package/accordiontab/accordiontab.min.js +1 -1
  18. package/api/Api.d.ts +1 -1
  19. package/api/api.cjs.js +299 -313
  20. package/api/api.esm.js +299 -313
  21. package/api/api.js +299 -313
  22. package/autocomplete/AutoComplete.d.ts +22 -17
  23. package/autocomplete/AutoComplete.vue +239 -126
  24. package/autocomplete/autocomplete.cjs.js +145 -108
  25. package/autocomplete/autocomplete.cjs.min.js +1 -1
  26. package/autocomplete/autocomplete.esm.js +146 -109
  27. package/autocomplete/autocomplete.esm.min.js +1 -1
  28. package/autocomplete/autocomplete.js +145 -108
  29. package/autocomplete/autocomplete.min.js +1 -1
  30. package/avatar/Avatar.d.ts +4 -4
  31. package/avatar/Avatar.vue +15 -11
  32. package/avatar/avatar.cjs.js +11 -7
  33. package/avatar/avatar.cjs.min.js +1 -1
  34. package/avatar/avatar.esm.js +11 -7
  35. package/avatar/avatar.esm.min.js +1 -1
  36. package/avatar/avatar.js +11 -7
  37. package/avatar/avatar.min.js +1 -1
  38. package/avatargroup/AvatarGroup.d.ts +6 -9
  39. package/avatargroup/AvatarGroup.vue +1 -1
  40. package/badge/Badge.d.ts +4 -5
  41. package/badge/Badge.vue +16 -13
  42. package/badge/badge.cjs.js +14 -11
  43. package/badge/badge.esm.js +14 -11
  44. package/badge/badge.js +14 -11
  45. package/badgedirective/badgedirective.cjs.js +8 -10
  46. package/badgedirective/badgedirective.esm.js +8 -10
  47. package/badgedirective/badgedirective.js +8 -10
  48. package/blockui/BlockUI.d.ts +6 -6
  49. package/blockui/BlockUI.vue +13 -15
  50. package/blockui/blockui.cjs.js +11 -13
  51. package/blockui/blockui.cjs.min.js +1 -1
  52. package/blockui/blockui.esm.js +11 -13
  53. package/blockui/blockui.esm.min.js +1 -1
  54. package/blockui/blockui.js +11 -13
  55. package/blockui/blockui.min.js +1 -1
  56. package/breadcrumb/Breadcrumb.d.ts +5 -6
  57. package/breadcrumb/Breadcrumb.vue +2 -2
  58. package/breadcrumb/BreadcrumbItem.vue +18 -15
  59. package/breadcrumb/breadcrumb.cjs.js +15 -12
  60. package/breadcrumb/breadcrumb.esm.js +15 -12
  61. package/breadcrumb/breadcrumb.js +15 -12
  62. package/button/Button.d.ts +10 -7
  63. package/button/Button.vue +22 -14
  64. package/button/button.cjs.js +19 -11
  65. package/button/button.cjs.min.js +1 -1
  66. package/button/button.esm.js +19 -11
  67. package/button/button.esm.min.js +1 -1
  68. package/button/button.js +19 -11
  69. package/button/button.min.js +1 -1
  70. package/calendar/Calendar.d.ts +14 -14
  71. package/calendar/Calendar.vue +793 -583
  72. package/calendar/calendar.cjs.js +581 -526
  73. package/calendar/calendar.cjs.min.js +1 -1
  74. package/calendar/calendar.esm.js +581 -526
  75. package/calendar/calendar.esm.min.js +1 -1
  76. package/calendar/calendar.js +581 -526
  77. package/calendar/calendar.min.js +1 -1
  78. package/card/Card.d.ts +5 -7
  79. package/card/Card.vue +5 -5
  80. package/carousel/Carousel.d.ts +29 -19
  81. package/carousel/Carousel.vue +537 -528
  82. package/carousel/carousel.cjs.js +496 -493
  83. package/carousel/carousel.cjs.min.js +1 -1
  84. package/carousel/carousel.esm.js +496 -493
  85. package/carousel/carousel.esm.min.js +1 -1
  86. package/carousel/carousel.js +645 -642
  87. package/carousel/carousel.min.js +1 -1
  88. package/cascadeselect/CascadeSelect.d.ts +19 -14
  89. package/cascadeselect/CascadeSelect.vue +186 -100
  90. package/cascadeselect/CascadeSelectSub.vue +44 -14
  91. package/cascadeselect/cascadeselect.cjs.js +156 -95
  92. package/cascadeselect/cascadeselect.cjs.min.js +1 -1
  93. package/cascadeselect/cascadeselect.esm.js +157 -96
  94. package/cascadeselect/cascadeselect.esm.min.js +1 -1
  95. package/cascadeselect/cascadeselect.js +156 -95
  96. package/cascadeselect/cascadeselect.min.js +1 -1
  97. package/chart/Chart.d.ts +6 -7
  98. package/chart/Chart.vue +12 -12
  99. package/chart/chart.cjs.js +11 -11
  100. package/chart/chart.cjs.min.js +1 -1
  101. package/chart/chart.esm.js +11 -11
  102. package/chart/chart.esm.min.js +1 -1
  103. package/chart/chart.js +11 -11
  104. package/chart/chart.min.js +1 -1
  105. package/checkbox/Checkbox.d.ts +12 -12
  106. package/checkbox/Checkbox.vue +48 -20
  107. package/checkbox/checkbox.cjs.js +28 -17
  108. package/checkbox/checkbox.cjs.min.js +1 -1
  109. package/checkbox/checkbox.esm.js +28 -17
  110. package/checkbox/checkbox.esm.min.js +1 -1
  111. package/checkbox/checkbox.js +28 -17
  112. package/checkbox/checkbox.min.js +1 -1
  113. package/chip/Chip.d.ts +5 -5
  114. package/chip/Chip.vue +13 -11
  115. package/chip/chip.cjs.js +7 -4
  116. package/chip/chip.esm.js +7 -4
  117. package/chip/chip.js +7 -4
  118. package/chips/Chips.d.ts +9 -9
  119. package/chips/Chips.vue +89 -33
  120. package/chips/chips.cjs.js +48 -26
  121. package/chips/chips.cjs.min.js +1 -1
  122. package/chips/chips.esm.js +48 -26
  123. package/chips/chips.esm.min.js +1 -1
  124. package/chips/chips.js +48 -26
  125. package/chips/chips.min.js +1 -1
  126. package/colorpicker/ColorPicker.d.ts +11 -12
  127. package/colorpicker/ColorPicker.vue +146 -110
  128. package/colorpicker/colorpicker.cjs.js +113 -74
  129. package/colorpicker/colorpicker.cjs.min.js +1 -1
  130. package/colorpicker/colorpicker.esm.js +113 -74
  131. package/colorpicker/colorpicker.esm.min.js +1 -1
  132. package/colorpicker/colorpicker.js +113 -74
  133. package/colorpicker/colorpicker.min.js +1 -1
  134. package/column/Column.d.ts +5 -6
  135. package/column/Column.vue +1 -1
  136. package/columngroup/ColumnGroup.d.ts +5 -7
  137. package/columngroup/ColumnGroup.vue +1 -1
  138. package/config/PrimeVue.d.ts +4 -2
  139. package/config/config.cjs.js +14 -29
  140. package/config/config.cjs.min.js +1 -1
  141. package/config/config.esm.js +14 -29
  142. package/config/config.esm.min.js +1 -1
  143. package/config/config.js +14 -29
  144. package/config/config.min.js +1 -1
  145. package/confirmationoptions/ConfirmationOptions.d.ts +4 -0
  146. package/confirmationservice/confirmationservice.cjs.js +1 -0
  147. package/confirmationservice/confirmationservice.esm.js +1 -0
  148. package/confirmationservice/confirmationservice.js +1 -0
  149. package/confirmdialog/ConfirmDialog.d.ts +11 -5
  150. package/confirmdialog/ConfirmDialog.vue +25 -15
  151. package/confirmdialog/confirmdialog.cjs.js +34 -16
  152. package/confirmdialog/confirmdialog.cjs.min.js +1 -1
  153. package/confirmdialog/confirmdialog.esm.js +34 -16
  154. package/confirmdialog/confirmdialog.esm.min.js +1 -1
  155. package/confirmdialog/confirmdialog.js +35 -17
  156. package/confirmdialog/confirmdialog.min.js +1 -1
  157. package/confirmpopup/ConfirmPopup.d.ts +5 -8
  158. package/confirmpopup/ConfirmPopup.vue +44 -32
  159. package/confirmpopup/confirmpopup.cjs.js +24 -14
  160. package/confirmpopup/confirmpopup.cjs.min.js +1 -1
  161. package/confirmpopup/confirmpopup.esm.js +24 -14
  162. package/confirmpopup/confirmpopup.esm.min.js +1 -1
  163. package/confirmpopup/confirmpopup.js +24 -14
  164. package/confirmpopup/confirmpopup.min.js +1 -1
  165. package/contextmenu/ContextMenu.d.ts +4 -5
  166. package/contextmenu/ContextMenu.vue +23 -19
  167. package/contextmenu/ContextMenuSub.vue +54 -42
  168. package/contextmenu/contextmenu.cjs.js +52 -44
  169. package/contextmenu/contextmenu.cjs.min.js +1 -1
  170. package/contextmenu/contextmenu.esm.js +52 -44
  171. package/contextmenu/contextmenu.esm.min.js +1 -1
  172. package/contextmenu/contextmenu.js +52 -44
  173. package/contextmenu/contextmenu.min.js +1 -1
  174. package/core/core.js +1918 -1744
  175. package/core/core.min.js +14 -14
  176. package/datatable/BodyCell.vue +93 -75
  177. package/datatable/ColumnFilter.vue +137 -86
  178. package/datatable/DataTable.d.ts +24 -24
  179. package/datatable/DataTable.vue +470 -296
  180. package/datatable/FooterCell.vue +20 -13
  181. package/datatable/HeaderCell.vue +108 -51
  182. package/datatable/HeaderCheckbox.vue +12 -5
  183. package/datatable/RowCheckbox.vue +14 -6
  184. package/datatable/RowRadioButton.vue +4 -4
  185. package/datatable/TableBody.vue +135 -83
  186. package/datatable/TableFooter.vue +17 -20
  187. package/datatable/TableHeader.vue +132 -52
  188. package/datatable/TableLoadingBody.vue +3 -3
  189. package/datatable/datatable.cjs.js +696 -559
  190. package/datatable/datatable.cjs.min.js +1 -1
  191. package/datatable/datatable.esm.js +696 -559
  192. package/datatable/datatable.esm.min.js +1 -1
  193. package/datatable/datatable.js +696 -559
  194. package/datatable/datatable.min.js +1 -1
  195. package/dataview/DataView.d.ts +8 -8
  196. package/dataview/DataView.vue +80 -66
  197. package/dataview/dataview.cjs.js +31 -35
  198. package/dataview/dataview.cjs.min.js +1 -1
  199. package/dataview/dataview.esm.js +31 -35
  200. package/dataview/dataview.esm.min.js +1 -1
  201. package/dataview/dataview.js +31 -35
  202. package/dataview/dataview.min.js +1 -1
  203. package/dataviewlayoutoptions/DataViewLayoutOptions.d.ts +5 -6
  204. package/dataviewlayoutoptions/DataViewLayoutOptions.vue +28 -34
  205. package/dataviewlayoutoptions/dataviewlayoutoptions.cjs.js +19 -25
  206. package/dataviewlayoutoptions/dataviewlayoutoptions.cjs.min.js +1 -1
  207. package/dataviewlayoutoptions/dataviewlayoutoptions.esm.js +19 -25
  208. package/dataviewlayoutoptions/dataviewlayoutoptions.esm.min.js +1 -1
  209. package/dataviewlayoutoptions/dataviewlayoutoptions.js +46 -52
  210. package/dataviewlayoutoptions/dataviewlayoutoptions.min.js +1 -1
  211. package/deferredcontent/DeferredContent.d.ts +6 -7
  212. package/deferredcontent/DeferredContent.vue +6 -9
  213. package/deferredcontent/deferredcontent.cjs.js +5 -8
  214. package/deferredcontent/deferredcontent.esm.js +5 -8
  215. package/deferredcontent/deferredcontent.js +5 -8
  216. package/dialog/Dialog.d.ts +10 -10
  217. package/dialog/Dialog.vue +64 -60
  218. package/dialog/dialog.cjs.js +50 -46
  219. package/dialog/dialog.cjs.min.js +1 -1
  220. package/dialog/dialog.esm.js +50 -46
  221. package/dialog/dialog.esm.min.js +1 -1
  222. package/dialog/dialog.js +50 -46
  223. package/dialog/dialog.min.js +1 -1
  224. package/divider/Divider.d.ts +4 -5
  225. package/divider/Divider.vue +15 -12
  226. package/divider/divider.cjs.js +17 -12
  227. package/divider/divider.cjs.min.js +1 -1
  228. package/divider/divider.esm.js +17 -12
  229. package/divider/divider.esm.min.js +1 -1
  230. package/divider/divider.js +17 -12
  231. package/divider/divider.min.js +1 -1
  232. package/dock/Dock.d.ts +5 -6
  233. package/dock/Dock.vue +3 -3
  234. package/dock/DockSub.vue +46 -25
  235. package/dock/dock.cjs.js +30 -23
  236. package/dock/dock.cjs.min.js +1 -1
  237. package/dock/dock.esm.js +30 -23
  238. package/dock/dock.esm.min.js +1 -1
  239. package/dock/dock.js +30 -23
  240. package/dock/dock.min.js +1 -1
  241. package/dropdown/Dropdown.d.ts +31 -17
  242. package/dropdown/Dropdown.vue +255 -125
  243. package/dropdown/dropdown.cjs.js +177 -109
  244. package/dropdown/dropdown.cjs.min.js +1 -1
  245. package/dropdown/dropdown.esm.js +178 -110
  246. package/dropdown/dropdown.esm.min.js +1 -1
  247. package/dropdown/dropdown.js +177 -109
  248. package/dropdown/dropdown.min.js +1 -1
  249. package/dynamicdialog/DynamicDialog.d.ts +4 -4
  250. package/dynamicdialog/DynamicDialog.vue +10 -10
  251. package/dynamicdialog/dynamicdialog.cjs.js +11 -9
  252. package/dynamicdialog/dynamicdialog.cjs.min.js +1 -1
  253. package/dynamicdialog/dynamicdialog.esm.js +11 -9
  254. package/dynamicdialog/dynamicdialog.esm.min.js +1 -1
  255. package/dynamicdialog/dynamicdialog.js +11 -9
  256. package/dynamicdialog/dynamicdialog.min.js +1 -1
  257. package/editor/Editor.d.ts +20 -4
  258. package/editor/Editor.vue +506 -466
  259. package/editor/editor.cjs.js +99 -45
  260. package/editor/editor.cjs.min.js +1 -1
  261. package/editor/editor.esm.js +82 -42
  262. package/editor/editor.esm.min.js +1 -1
  263. package/editor/editor.js +83 -47
  264. package/editor/editor.min.js +1 -1
  265. package/fieldset/Fieldset.d.ts +9 -5
  266. package/fieldset/Fieldset.vue +28 -20
  267. package/fieldset/fieldset.cjs.js +31 -19
  268. package/fieldset/fieldset.cjs.min.js +1 -1
  269. package/fieldset/fieldset.esm.js +32 -20
  270. package/fieldset/fieldset.esm.min.js +1 -1
  271. package/fieldset/fieldset.js +31 -19
  272. package/fieldset/fieldset.min.js +1 -1
  273. package/fileupload/FileUpload.d.ts +11 -11
  274. package/fileupload/FileUpload.vue +75 -69
  275. package/fileupload/fileupload.cjs.js +56 -50
  276. package/fileupload/fileupload.cjs.min.js +1 -1
  277. package/fileupload/fileupload.esm.js +56 -50
  278. package/fileupload/fileupload.esm.min.js +1 -1
  279. package/fileupload/fileupload.js +56 -50
  280. package/fileupload/fileupload.min.js +1 -1
  281. package/fullcalendar/FullCalendar.d.ts +5 -7
  282. package/fullcalendar/FullCalendar.vue +6 -6
  283. package/fullcalendar/fullcalendar.cjs.js +3 -2
  284. package/fullcalendar/fullcalendar.esm.js +3 -2
  285. package/fullcalendar/fullcalendar.js +3 -2
  286. package/galleria/Galleria.d.ts +4 -4
  287. package/galleria/Galleria.vue +39 -34
  288. package/galleria/GalleriaContent.vue +58 -31
  289. package/galleria/GalleriaItem.vue +44 -36
  290. package/galleria/GalleriaItemSlot.vue +2 -1
  291. package/galleria/GalleriaThumbnails.vue +107 -91
  292. package/galleria/galleria.cjs.js +180 -152
  293. package/galleria/galleria.cjs.min.js +1 -1
  294. package/galleria/galleria.esm.js +180 -152
  295. package/galleria/galleria.esm.min.js +1 -1
  296. package/galleria/galleria.js +180 -152
  297. package/galleria/galleria.min.js +1 -1
  298. package/image/Image.d.ts +4 -5
  299. package/image/Image.vue +19 -15
  300. package/image/image.cjs.js +11 -7
  301. package/image/image.cjs.min.js +1 -1
  302. package/image/image.esm.js +11 -7
  303. package/image/image.esm.min.js +1 -1
  304. package/image/image.js +11 -7
  305. package/image/image.min.js +1 -1
  306. package/inlinemessage/InlineMessage.d.ts +4 -5
  307. package/inlinemessage/InlineMessage.vue +12 -9
  308. package/inlinemessage/inlinemessage.cjs.js +11 -8
  309. package/inlinemessage/inlinemessage.esm.js +11 -8
  310. package/inlinemessage/inlinemessage.js +11 -8
  311. package/inplace/Inplace.d.ts +6 -6
  312. package/inplace/Inplace.vue +11 -11
  313. package/inplace/inplace.cjs.js +9 -9
  314. package/inplace/inplace.cjs.min.js +1 -1
  315. package/inplace/inplace.esm.js +9 -9
  316. package/inplace/inplace.esm.min.js +1 -1
  317. package/inplace/inplace.js +9 -9
  318. package/inplace/inplace.min.js +1 -1
  319. package/inputmask/InputMask.d.ts +11 -12
  320. package/inputmask/InputMask.vue +119 -92
  321. package/inputmask/inputmask.cjs.js +116 -89
  322. package/inputmask/inputmask.cjs.min.js +1 -1
  323. package/inputmask/inputmask.esm.js +116 -89
  324. package/inputmask/inputmask.esm.min.js +1 -1
  325. package/inputmask/inputmask.js +116 -89
  326. package/inputmask/inputmask.min.js +1 -1
  327. package/inputnumber/InputNumber.d.ts +17 -17
  328. package/inputnumber/InputNumber.vue +237 -177
  329. package/inputnumber/inputnumber.cjs.js +208 -171
  330. package/inputnumber/inputnumber.cjs.min.js +1 -1
  331. package/inputnumber/inputnumber.esm.js +208 -171
  332. package/inputnumber/inputnumber.esm.min.js +1 -1
  333. package/inputnumber/inputnumber.js +208 -171
  334. package/inputnumber/inputnumber.min.js +1 -1
  335. package/inputswitch/InputSwitch.d.ts +10 -10
  336. package/inputswitch/InputSwitch.vue +39 -11
  337. package/inputswitch/inputswitch.cjs.js +23 -9
  338. package/inputswitch/inputswitch.cjs.min.js +1 -1
  339. package/inputswitch/inputswitch.esm.js +23 -9
  340. package/inputswitch/inputswitch.esm.min.js +1 -1
  341. package/inputswitch/inputswitch.js +23 -9
  342. package/inputswitch/inputswitch.min.js +1 -1
  343. package/inputtext/InputText.d.ts +5 -6
  344. package/inputtext/InputText.vue +3 -3
  345. package/inputtext/inputtext.cjs.js +2 -2
  346. package/inputtext/inputtext.esm.js +2 -2
  347. package/inputtext/inputtext.js +2 -2
  348. package/knob/Knob.d.ts +10 -11
  349. package/knob/Knob.vue +47 -29
  350. package/knob/knob.cjs.js +27 -25
  351. package/knob/knob.cjs.min.js +1 -1
  352. package/knob/knob.esm.js +27 -25
  353. package/knob/knob.esm.min.js +1 -1
  354. package/knob/knob.js +27 -25
  355. package/knob/knob.min.js +1 -1
  356. package/listbox/Listbox.d.ts +17 -13
  357. package/listbox/Listbox.vue +144 -97
  358. package/listbox/listbox.cjs.js +96 -86
  359. package/listbox/listbox.cjs.min.js +1 -1
  360. package/listbox/listbox.esm.js +97 -87
  361. package/listbox/listbox.esm.min.js +1 -1
  362. package/listbox/listbox.js +96 -86
  363. package/listbox/listbox.min.js +1 -1
  364. package/megamenu/MegaMenu.d.ts +5 -6
  365. package/megamenu/MegaMenu.vue +108 -94
  366. package/megamenu/megamenu.cjs.js +77 -72
  367. package/megamenu/megamenu.cjs.min.js +1 -1
  368. package/megamenu/megamenu.esm.js +77 -72
  369. package/megamenu/megamenu.esm.min.js +1 -1
  370. package/megamenu/megamenu.js +77 -72
  371. package/megamenu/megamenu.min.js +1 -1
  372. package/menu/Menu.d.ts +5 -8
  373. package/menu/Menu.vue +29 -23
  374. package/menu/Menuitem.vue +21 -18
  375. package/menu/menu.cjs.js +38 -29
  376. package/menu/menu.cjs.min.js +1 -1
  377. package/menu/menu.esm.js +38 -29
  378. package/menu/menu.esm.min.js +1 -1
  379. package/menu/menu.js +38 -29
  380. package/menu/menu.min.js +1 -1
  381. package/menubar/Menubar.d.ts +5 -6
  382. package/menubar/Menubar.vue +14 -15
  383. package/menubar/MenubarSub.vue +79 -62
  384. package/menubar/menubar.cjs.js +56 -58
  385. package/menubar/menubar.cjs.min.js +1 -1
  386. package/menubar/menubar.esm.js +56 -58
  387. package/menubar/menubar.esm.min.js +1 -1
  388. package/menubar/menubar.js +56 -58
  389. package/menubar/menubar.min.js +1 -1
  390. package/menuitem/MenuItem.d.ts +2 -2
  391. package/message/Message.d.ts +5 -5
  392. package/message/Message.vue +19 -14
  393. package/message/message.cjs.js +15 -10
  394. package/message/message.cjs.min.js +1 -1
  395. package/message/message.esm.js +15 -10
  396. package/message/message.esm.min.js +1 -1
  397. package/message/message.js +15 -10
  398. package/message/message.min.js +1 -1
  399. package/multiselect/MultiSelect.d.ts +21 -16
  400. package/multiselect/MultiSelect.vue +240 -150
  401. package/multiselect/multiselect.cjs.js +184 -133
  402. package/multiselect/multiselect.cjs.min.js +1 -1
  403. package/multiselect/multiselect.esm.js +185 -134
  404. package/multiselect/multiselect.esm.min.js +1 -1
  405. package/multiselect/multiselect.js +184 -133
  406. package/multiselect/multiselect.min.js +1 -1
  407. package/orderlist/OrderList.d.ts +5 -5
  408. package/orderlist/OrderList.vue +65 -60
  409. package/orderlist/orderlist.cjs.js +51 -53
  410. package/orderlist/orderlist.esm.js +51 -53
  411. package/orderlist/orderlist.js +51 -53
  412. package/organizationchart/OrganizationChart.d.ts +4 -4
  413. package/organizationchart/OrganizationChart.vue +13 -17
  414. package/organizationchart/OrganizationChartNode.vue +20 -12
  415. package/organizationchart/organizationchart.cjs.js +14 -16
  416. package/organizationchart/organizationchart.cjs.min.js +1 -1
  417. package/organizationchart/organizationchart.esm.js +14 -16
  418. package/organizationchart/organizationchart.esm.min.js +1 -1
  419. package/organizationchart/organizationchart.js +14 -16
  420. package/organizationchart/organizationchart.min.js +1 -1
  421. package/overlaypanel/OverlayPanel.d.ts +5 -5
  422. package/overlaypanel/OverlayPanel.vue +60 -50
  423. package/overlaypanel/overlaypanel.cjs.js +40 -32
  424. package/overlaypanel/overlaypanel.cjs.min.js +1 -1
  425. package/overlaypanel/overlaypanel.esm.js +40 -32
  426. package/overlaypanel/overlaypanel.esm.min.js +1 -1
  427. package/overlaypanel/overlaypanel.js +40 -32
  428. package/overlaypanel/overlaypanel.min.js +1 -1
  429. package/package.json +1 -1
  430. package/paginator/CurrentPageReport.vue +47 -47
  431. package/paginator/FirstPageLink.vue +11 -8
  432. package/paginator/JumpToPageDropdown.vue +7 -6
  433. package/paginator/JumpToPageInput.vue +3 -3
  434. package/paginator/LastPageLink.vue +11 -8
  435. package/paginator/NextPageLink.vue +11 -8
  436. package/paginator/PageLinks.vue +3 -4
  437. package/paginator/Paginator.d.ts +5 -5
  438. package/paginator/Paginator.vue +39 -39
  439. package/paginator/PrevPageLink.vue +11 -8
  440. package/paginator/RowsPerPageDropdown.vue +7 -6
  441. package/paginator/paginator.cjs.js +110 -91
  442. package/paginator/paginator.cjs.min.js +1 -1
  443. package/paginator/paginator.esm.js +110 -91
  444. package/paginator/paginator.esm.min.js +1 -1
  445. package/paginator/paginator.js +633 -614
  446. package/paginator/paginator.min.js +1 -1
  447. package/panel/Panel.d.ts +9 -5
  448. package/panel/Panel.vue +29 -11
  449. package/panel/panel.cjs.js +24 -14
  450. package/panel/panel.cjs.min.js +1 -1
  451. package/panel/panel.esm.js +24 -14
  452. package/panel/panel.esm.min.js +1 -1
  453. package/panel/panel.js +24 -14
  454. package/panel/panel.min.js +1 -1
  455. package/panelmenu/PanelMenu.d.ts +5 -5
  456. package/panelmenu/PanelMenu.vue +46 -38
  457. package/panelmenu/PanelMenuSub.vue +40 -29
  458. package/panelmenu/panelmenu.cjs.js +56 -52
  459. package/panelmenu/panelmenu.cjs.min.js +1 -1
  460. package/panelmenu/panelmenu.esm.js +56 -52
  461. package/panelmenu/panelmenu.esm.min.js +1 -1
  462. package/panelmenu/panelmenu.js +56 -52
  463. package/panelmenu/panelmenu.min.js +1 -1
  464. package/password/Password.d.ts +12 -7
  465. package/password/Password.vue +156 -79
  466. package/password/password.cjs.js +135 -74
  467. package/password/password.cjs.min.js +1 -1
  468. package/password/password.esm.js +135 -74
  469. package/password/password.esm.min.js +1 -1
  470. package/password/password.js +135 -74
  471. package/password/password.min.js +1 -1
  472. package/picklist/PickList.d.ts +9 -9
  473. package/picklist/PickList.vue +99 -78
  474. package/picklist/picklist.cjs.js +71 -66
  475. package/picklist/picklist.cjs.min.js +1 -1
  476. package/picklist/picklist.esm.js +71 -66
  477. package/picklist/picklist.esm.min.js +1 -1
  478. package/picklist/picklist.js +71 -66
  479. package/picklist/picklist.min.js +1 -1
  480. package/portal/Portal.d.ts +3 -3
  481. package/portal/Portal.vue +2 -2
  482. package/portal/portal.cjs.js +1 -1
  483. package/portal/portal.esm.js +1 -1
  484. package/portal/portal.js +1 -1
  485. package/progressbar/ProgressBar.d.ts +4 -5
  486. package/progressbar/ProgressBar.vue +63 -51
  487. package/progressbar/progressbar.cjs.js +2 -2
  488. package/progressbar/progressbar.cjs.min.js +1 -1
  489. package/progressbar/progressbar.esm.js +2 -2
  490. package/progressbar/progressbar.esm.min.js +1 -1
  491. package/progressbar/progressbar.js +2 -2
  492. package/progressbar/progressbar.min.js +1 -1
  493. package/progressspinner/ProgressSpinner.d.ts +5 -7
  494. package/progressspinner/ProgressSpinner.vue +1 -1
  495. package/radiobutton/RadioButton.d.ts +9 -9
  496. package/radiobutton/RadioButton.vue +41 -13
  497. package/radiobutton/radiobutton.cjs.js +24 -10
  498. package/radiobutton/radiobutton.cjs.min.js +1 -1
  499. package/radiobutton/radiobutton.esm.js +24 -10
  500. package/radiobutton/radiobutton.esm.min.js +1 -1
  501. package/radiobutton/radiobutton.js +24 -10
  502. package/radiobutton/radiobutton.min.js +1 -1
  503. package/rating/Rating.d.ts +54 -5
  504. package/rating/Rating.vue +88 -62
  505. package/rating/rating.cjs.js +105 -84
  506. package/rating/rating.cjs.min.js +1 -1
  507. package/rating/rating.esm.js +106 -85
  508. package/rating/rating.esm.min.js +1 -1
  509. package/rating/rating.js +106 -86
  510. package/rating/rating.min.js +1 -1
  511. package/resources/themes/arya-blue/theme.css +23 -12
  512. package/resources/themes/arya-green/theme.css +23 -12
  513. package/resources/themes/arya-orange/theme.css +23 -12
  514. package/resources/themes/arya-purple/theme.css +23 -12
  515. package/resources/themes/bootstrap4-dark-blue/theme.css +24 -13
  516. package/resources/themes/bootstrap4-dark-purple/theme.css +24 -13
  517. package/resources/themes/bootstrap4-light-blue/theme.css +24 -13
  518. package/resources/themes/bootstrap4-light-purple/theme.css +24 -13
  519. package/resources/themes/fluent-light/theme.css +23 -12
  520. package/resources/themes/lara-dark-blue/theme.css +23 -12
  521. package/resources/themes/lara-dark-indigo/theme.css +23 -12
  522. package/resources/themes/lara-dark-purple/theme.css +23 -12
  523. package/resources/themes/lara-dark-teal/theme.css +23 -12
  524. package/resources/themes/lara-light-blue/theme.css +23 -12
  525. package/resources/themes/lara-light-indigo/theme.css +23 -12
  526. package/resources/themes/lara-light-purple/theme.css +23 -12
  527. package/resources/themes/lara-light-teal/theme.css +23 -12
  528. package/resources/themes/luna-amber/theme.css +24 -13
  529. package/resources/themes/luna-blue/theme.css +24 -13
  530. package/resources/themes/luna-green/theme.css +24 -13
  531. package/resources/themes/luna-pink/theme.css +24 -13
  532. package/resources/themes/md-dark-deeppurple/theme.css +46 -20
  533. package/resources/themes/md-dark-indigo/theme.css +46 -20
  534. package/resources/themes/md-light-deeppurple/theme.css +46 -20
  535. package/resources/themes/md-light-indigo/theme.css +46 -20
  536. package/resources/themes/mdc-dark-deeppurple/theme.css +46 -20
  537. package/resources/themes/mdc-dark-indigo/theme.css +46 -20
  538. package/resources/themes/mdc-light-deeppurple/theme.css +46 -20
  539. package/resources/themes/mdc-light-indigo/theme.css +46 -20
  540. package/resources/themes/nova/theme.css +24 -13
  541. package/resources/themes/nova-accent/theme.css +23 -12
  542. package/resources/themes/nova-alt/theme.css +24 -13
  543. package/resources/themes/nova-vue/theme.css +24 -13
  544. package/resources/themes/rhea/theme.css +23 -12
  545. package/resources/themes/saga-blue/theme.css +23 -12
  546. package/resources/themes/saga-green/theme.css +23 -12
  547. package/resources/themes/saga-orange/theme.css +23 -12
  548. package/resources/themes/saga-purple/theme.css +23 -12
  549. package/resources/themes/tailwind-light/theme.css +23 -12
  550. package/resources/themes/vela-blue/theme.css +23 -12
  551. package/resources/themes/vela-green/theme.css +23 -12
  552. package/resources/themes/vela-orange/theme.css +23 -12
  553. package/resources/themes/vela-purple/theme.css +23 -12
  554. package/ripple/ripple.cjs.js +7 -1
  555. package/ripple/ripple.esm.js +7 -1
  556. package/ripple/ripple.js +7 -1
  557. package/row/Row.d.ts +6 -9
  558. package/row/Row.vue +1 -1
  559. package/scrollpanel/ScrollPanel.d.ts +9 -5
  560. package/scrollpanel/ScrollPanel.vue +194 -56
  561. package/scrollpanel/scrollpanel.cjs.js +180 -56
  562. package/scrollpanel/scrollpanel.cjs.min.js +1 -1
  563. package/scrollpanel/scrollpanel.esm.js +181 -57
  564. package/scrollpanel/scrollpanel.esm.min.js +1 -1
  565. package/scrollpanel/scrollpanel.js +180 -56
  566. package/scrollpanel/scrollpanel.min.js +1 -1
  567. package/scrolltop/ScrollTop.d.ts +5 -7
  568. package/scrolltop/ScrollTop.vue +18 -23
  569. package/scrolltop/scrolltop.cjs.js +14 -19
  570. package/scrolltop/scrolltop.cjs.min.js +1 -1
  571. package/scrolltop/scrolltop.esm.js +14 -19
  572. package/scrolltop/scrolltop.esm.min.js +1 -1
  573. package/scrolltop/scrolltop.js +14 -19
  574. package/scrolltop/scrolltop.min.js +1 -1
  575. package/selectbutton/SelectButton.d.ts +11 -11
  576. package/selectbutton/SelectButton.vue +50 -32
  577. package/selectbutton/selectbutton.cjs.js +30 -25
  578. package/selectbutton/selectbutton.esm.js +30 -25
  579. package/selectbutton/selectbutton.js +30 -25
  580. package/sidebar/Sidebar.d.ts +6 -6
  581. package/sidebar/Sidebar.vue +24 -14
  582. package/sidebar/sidebar.cjs.js +20 -10
  583. package/sidebar/sidebar.cjs.min.js +1 -1
  584. package/sidebar/sidebar.esm.js +20 -10
  585. package/sidebar/sidebar.esm.min.js +1 -1
  586. package/sidebar/sidebar.js +20 -10
  587. package/sidebar/sidebar.min.js +1 -1
  588. package/skeleton/Skeleton.d.ts +5 -7
  589. package/skeleton/Skeleton.vue +12 -11
  590. package/skeleton/skeleton.cjs.js +10 -9
  591. package/skeleton/skeleton.cjs.min.js +1 -1
  592. package/skeleton/skeleton.esm.js +10 -9
  593. package/skeleton/skeleton.esm.min.js +1 -1
  594. package/skeleton/skeleton.js +10 -9
  595. package/skeleton/skeleton.min.js +1 -1
  596. package/slider/Slider.d.ts +7 -8
  597. package/slider/Slider.vue +162 -141
  598. package/slider/slider.cjs.js +100 -127
  599. package/slider/slider.cjs.min.js +1 -1
  600. package/slider/slider.esm.js +100 -127
  601. package/slider/slider.esm.min.js +1 -1
  602. package/slider/slider.js +100 -127
  603. package/slider/slider.min.js +1 -1
  604. package/speeddial/SpeedDial.d.ts +8 -8
  605. package/speeddial/SpeedDial.vue +54 -39
  606. package/speeddial/speeddial.cjs.js +44 -36
  607. package/speeddial/speeddial.esm.js +44 -36
  608. package/speeddial/speeddial.js +44 -36
  609. package/splitbutton/SplitButton.d.ts +6 -6
  610. package/splitbutton/SplitButton.vue +9 -11
  611. package/splitbutton/splitbutton.cjs.js +7 -7
  612. package/splitbutton/splitbutton.cjs.min.js +1 -1
  613. package/splitbutton/splitbutton.esm.js +7 -7
  614. package/splitbutton/splitbutton.esm.min.js +1 -1
  615. package/splitbutton/splitbutton.js +7 -7
  616. package/splitbutton/splitbutton.min.js +1 -1
  617. package/splitter/Splitter.d.ts +10 -5
  618. package/splitter/Splitter.vue +158 -53
  619. package/splitter/splitter.cjs.js +156 -52
  620. package/splitter/splitter.cjs.min.js +1 -1
  621. package/splitter/splitter.esm.js +157 -53
  622. package/splitter/splitter.esm.min.js +1 -1
  623. package/splitter/splitter.js +156 -52
  624. package/splitter/splitter.min.js +1 -1
  625. package/splitterpanel/SplitterPanel.d.ts +4 -5
  626. package/splitterpanel/SplitterPanel.vue +3 -3
  627. package/splitterpanel/splitterpanel.cjs.js +2 -2
  628. package/splitterpanel/splitterpanel.esm.js +2 -2
  629. package/splitterpanel/splitterpanel.js +2 -2
  630. package/steps/Steps.d.ts +4 -5
  631. package/steps/Steps.vue +31 -23
  632. package/steps/steps.cjs.js +24 -16
  633. package/steps/steps.esm.js +24 -16
  634. package/steps/steps.js +24 -16
  635. package/styleclass/styleclass.cjs.js +19 -21
  636. package/styleclass/styleclass.esm.js +19 -21
  637. package/styleclass/styleclass.js +19 -21
  638. package/tabmenu/TabMenu.d.ts +4 -4
  639. package/tabmenu/TabMenu.vue +45 -34
  640. package/tabmenu/tabmenu.cjs.js +36 -25
  641. package/tabmenu/tabmenu.cjs.min.js +1 -1
  642. package/tabmenu/tabmenu.esm.js +36 -25
  643. package/tabmenu/tabmenu.esm.min.js +1 -1
  644. package/tabmenu/tabmenu.js +36 -25
  645. package/tabmenu/tabmenu.min.js +1 -1
  646. package/tabpanel/TabPanel.d.ts +33 -6
  647. package/tabpanel/TabPanel.vue +8 -1
  648. package/tabpanel/tabpanel.cjs.js +7 -0
  649. package/tabpanel/tabpanel.cjs.min.js +1 -1
  650. package/tabpanel/tabpanel.esm.js +7 -0
  651. package/tabpanel/tabpanel.esm.min.js +1 -1
  652. package/tabpanel/tabpanel.js +7 -0
  653. package/tabpanel/tabpanel.min.js +1 -1
  654. package/tabview/TabView.d.ts +22 -6
  655. package/tabview/TabView.vue +280 -96
  656. package/tabview/tabview.cjs.js +294 -131
  657. package/tabview/tabview.cjs.min.js +1 -1
  658. package/tabview/tabview.esm.js +296 -133
  659. package/tabview/tabview.esm.min.js +1 -1
  660. package/tabview/tabview.js +294 -131
  661. package/tabview/tabview.min.js +1 -1
  662. package/tag/Tag.d.ts +4 -5
  663. package/tag/Tag.vue +13 -10
  664. package/tag/tag.cjs.js +10 -7
  665. package/tag/tag.esm.js +10 -7
  666. package/tag/tag.js +10 -7
  667. package/terminal/Terminal.d.ts +5 -7
  668. package/terminal/Terminal.vue +10 -10
  669. package/terminal/terminal.cjs.js +3 -3
  670. package/terminal/terminal.cjs.min.js +1 -1
  671. package/terminal/terminal.esm.js +3 -3
  672. package/terminal/terminal.esm.min.js +1 -1
  673. package/terminal/terminal.js +3 -3
  674. package/terminal/terminal.min.js +1 -1
  675. package/textarea/Textarea.d.ts +5 -6
  676. package/textarea/Textarea.vue +7 -7
  677. package/textarea/textarea.cjs.js +6 -6
  678. package/textarea/textarea.esm.js +6 -6
  679. package/textarea/textarea.js +6 -6
  680. package/tieredmenu/TieredMenu.d.ts +4 -5
  681. package/tieredmenu/TieredMenu.vue +23 -15
  682. package/tieredmenu/TieredMenuSub.vue +62 -51
  683. package/tieredmenu/tieredmenu.cjs.js +60 -50
  684. package/tieredmenu/tieredmenu.cjs.min.js +1 -1
  685. package/tieredmenu/tieredmenu.esm.js +60 -50
  686. package/tieredmenu/tieredmenu.esm.min.js +1 -1
  687. package/tieredmenu/tieredmenu.js +60 -50
  688. package/tieredmenu/tieredmenu.min.js +1 -1
  689. package/timeline/Timeline.d.ts +4 -5
  690. package/timeline/Timeline.vue +6 -10
  691. package/timeline/timeline.cjs.js +3 -7
  692. package/timeline/timeline.cjs.min.js +1 -1
  693. package/timeline/timeline.esm.js +3 -7
  694. package/timeline/timeline.esm.min.js +1 -1
  695. package/timeline/timeline.js +3 -7
  696. package/timeline/timeline.min.js +1 -1
  697. package/toast/Toast.d.ts +10 -13
  698. package/toast/Toast.vue +36 -29
  699. package/toast/ToastMessage.vue +25 -18
  700. package/toast/toast.cjs.js +37 -23
  701. package/toast/toast.cjs.min.js +1 -1
  702. package/toast/toast.esm.js +37 -23
  703. package/toast/toast.esm.min.js +1 -1
  704. package/toast/toast.js +37 -23
  705. package/toast/toast.min.js +1 -1
  706. package/toastservice/toastservice.cjs.js +1 -0
  707. package/toastservice/toastservice.esm.js +1 -0
  708. package/toastservice/toastservice.js +1 -0
  709. package/togglebutton/ToggleButton.d.ts +10 -10
  710. package/togglebutton/ToggleButton.vue +42 -18
  711. package/togglebutton/togglebutton.cjs.js +25 -13
  712. package/togglebutton/togglebutton.cjs.min.js +1 -1
  713. package/togglebutton/togglebutton.esm.js +25 -13
  714. package/togglebutton/togglebutton.esm.min.js +1 -1
  715. package/togglebutton/togglebutton.js +25 -13
  716. package/togglebutton/togglebutton.min.js +1 -1
  717. package/toolbar/Toolbar.d.ts +8 -5
  718. package/toolbar/Toolbar.vue +9 -3
  719. package/toolbar/toolbar.cjs.js +14 -7
  720. package/toolbar/toolbar.cjs.min.js +1 -1
  721. package/toolbar/toolbar.esm.js +14 -7
  722. package/toolbar/toolbar.esm.min.js +1 -1
  723. package/toolbar/toolbar.js +14 -7
  724. package/toolbar/toolbar.min.js +1 -1
  725. package/tooltip/tooltip.cjs.js +36 -24
  726. package/tooltip/tooltip.cjs.min.js +1 -1
  727. package/tooltip/tooltip.esm.js +37 -25
  728. package/tooltip/tooltip.esm.min.js +1 -1
  729. package/tooltip/tooltip.js +36 -24
  730. package/tooltip/tooltip.min.js +1 -1
  731. package/tree/Tree.d.ts +7 -7
  732. package/tree/Tree.vue +66 -56
  733. package/tree/TreeNode.vue +70 -66
  734. package/tree/tree.cjs.js +99 -102
  735. package/tree/tree.cjs.min.js +1 -1
  736. package/tree/tree.esm.js +99 -102
  737. package/tree/tree.esm.min.js +1 -1
  738. package/tree/tree.js +99 -102
  739. package/tree/tree.min.js +1 -1
  740. package/treeselect/TreeSelect.d.ts +9 -9
  741. package/treeselect/TreeSelect.vue +130 -72
  742. package/treeselect/treeselect.cjs.js +89 -59
  743. package/treeselect/treeselect.cjs.min.js +1 -1
  744. package/treeselect/treeselect.esm.js +89 -59
  745. package/treeselect/treeselect.esm.min.js +1 -1
  746. package/treeselect/treeselect.js +89 -59
  747. package/treeselect/treeselect.min.js +1 -1
  748. package/treetable/BodyCell.vue +29 -19
  749. package/treetable/FooterCell.vue +19 -11
  750. package/treetable/HeaderCell.vue +44 -36
  751. package/treetable/TreeTable.d.ts +8 -8
  752. package/treetable/TreeTable.vue +229 -178
  753. package/treetable/TreeTableRow.vue +74 -58
  754. package/treetable/treetable.cjs.js +287 -253
  755. package/treetable/treetable.cjs.min.js +1 -1
  756. package/treetable/treetable.esm.js +287 -253
  757. package/treetable/treetable.esm.min.js +1 -1
  758. package/treetable/treetable.js +287 -253
  759. package/treetable/treetable.min.js +1 -1
  760. package/tristatecheckbox/TriStateCheckbox.d.ts +9 -9
  761. package/tristatecheckbox/TriStateCheckbox.vue +39 -18
  762. package/tristatecheckbox/tristatecheckbox.cjs.js +24 -15
  763. package/tristatecheckbox/tristatecheckbox.cjs.min.js +1 -1
  764. package/tristatecheckbox/tristatecheckbox.esm.js +24 -15
  765. package/tristatecheckbox/tristatecheckbox.esm.min.js +1 -1
  766. package/tristatecheckbox/tristatecheckbox.js +24 -15
  767. package/tristatecheckbox/tristatecheckbox.min.js +1 -1
  768. package/ts-helpers.d.ts +16 -10
  769. package/useconfirm/UseConfirm.d.ts +1 -1
  770. package/useconfirm/useconfirm.cjs.js +2 -1
  771. package/useconfirm/useconfirm.esm.js +2 -1
  772. package/useconfirm/useconfirm.js +2 -1
  773. package/usedialog/UseDialog.d.ts +1 -1
  774. package/usedialog/usedialog.cjs.js +2 -1
  775. package/usedialog/usedialog.esm.js +2 -1
  776. package/usedialog/usedialog.js +2 -1
  777. package/usetoast/usetoast.cjs.js +2 -1
  778. package/usetoast/usetoast.esm.js +2 -1
  779. package/usetoast/usetoast.js +2 -1
  780. package/utils/Utils.d.ts +7 -5
  781. package/utils/utils.cjs.js +183 -156
  782. package/utils/utils.cjs.min.js +1 -1
  783. package/utils/utils.esm.js +183 -156
  784. package/utils/utils.esm.min.js +1 -1
  785. package/utils/utils.js +183 -156
  786. package/utils/utils.min.js +1 -1
  787. package/vetur-attributes.json +160 -0
  788. package/vetur-tags.json +58 -8
  789. package/virtualscroller/VirtualScroller.d.ts +9 -9
  790. package/virtualscroller/VirtualScroller.vue +108 -96
  791. package/virtualscroller/virtualscroller.cjs.js +87 -89
  792. package/virtualscroller/virtualscroller.cjs.min.js +1 -1
  793. package/virtualscroller/virtualscroller.esm.js +87 -89
  794. package/virtualscroller/virtualscroller.esm.min.js +1 -1
  795. package/virtualscroller/virtualscroller.js +87 -89
  796. package/virtualscroller/virtualscroller.min.js +1 -1
  797. package/web-types.json +488 -2
@@ -167,17 +167,41 @@ var script = {
167
167
  type: String,
168
168
  default: null
169
169
  },
170
- id: null,
171
- inputId: null,
172
- inputClass: null,
173
- inputStyle: null,
174
- inputProps: null,
175
- panelClass: null,
176
- panelStyle: null,
177
- panelProps: null,
170
+ id: {
171
+ type: String,
172
+ default: null
173
+ },
174
+ inputId: {
175
+ type: String,
176
+ default: null
177
+ },
178
+ inputClass: {
179
+ type: String,
180
+ default: null
181
+ },
182
+ inputStyle: {
183
+ type: null,
184
+ default: null
185
+ },
186
+ inputProps: {
187
+ type: null,
188
+ default: null
189
+ },
190
+ panelClass: {
191
+ type: String,
192
+ default: null
193
+ },
194
+ panelStyle: {
195
+ type: null,
196
+ default: null
197
+ },
198
+ panelProps: {
199
+ type: null,
200
+ default: null
201
+ },
178
202
  'aria-labelledby': {
179
203
  type: String,
180
- default: null
204
+ default: null
181
205
  },
182
206
  'aria-label': {
183
207
  type: String,
@@ -196,6 +220,55 @@ var script = {
196
220
  timePickerTimer: null,
197
221
  preventFocus: false,
198
222
  typeUpdate: false,
223
+ data() {
224
+ return {
225
+ currentMonth: null,
226
+ currentYear: null,
227
+ currentHour: null,
228
+ currentMinute: null,
229
+ currentSecond: null,
230
+ pm: null,
231
+ focused: false,
232
+ overlayVisible: false,
233
+ currentView: this.view
234
+ };
235
+ },
236
+ watch: {
237
+ modelValue(newValue) {
238
+ this.updateCurrentMetaData();
239
+
240
+ if (!this.typeUpdate && !this.inline && this.input) {
241
+ this.input.value = this.formatValue(newValue);
242
+ }
243
+
244
+ this.typeUpdate = false;
245
+ },
246
+ showTime() {
247
+ this.updateCurrentMetaData();
248
+ },
249
+ months() {
250
+ if (this.overlay) {
251
+ if (!this.focused) {
252
+ if (this.inline) {
253
+ this.preventFocus = true;
254
+ }
255
+
256
+ setTimeout(this.updateFocus, 0);
257
+ }
258
+ }
259
+ },
260
+ numberOfMonths() {
261
+ this.destroyResponsiveStyleElement();
262
+ this.createResponsiveStyle();
263
+ },
264
+ responsiveOptions() {
265
+ this.destroyResponsiveStyleElement();
266
+ this.createResponsiveStyle();
267
+ },
268
+ currentView() {
269
+ Promise.resolve(null).then(() => this.alignOverlay());
270
+ }
271
+ },
199
272
  created() {
200
273
  this.updateCurrentMetaData();
201
274
  },
@@ -213,8 +286,7 @@ var script = {
213
286
  this.overlay.style.width = DomHandler.getOuterWidth(this.$el) + 'px';
214
287
  }
215
288
  }
216
- }
217
- else {
289
+ } else {
218
290
  this.input.value = this.formatValue(this.modelValue);
219
291
  }
220
292
  },
@@ -239,6 +311,7 @@ var script = {
239
311
  if (this.mask) {
240
312
  this.destroyMask();
241
313
  }
314
+
242
315
  this.destroyResponsiveStyleElement();
243
316
 
244
317
  this.unbindOutsideClickListener();
@@ -252,51 +325,9 @@ var script = {
252
325
  if (this.overlay && this.autoZIndex) {
253
326
  ZIndexUtils.clear(this.overlay);
254
327
  }
328
+
255
329
  this.overlay = null;
256
330
  },
257
- data() {
258
- return {
259
- currentMonth: null,
260
- currentYear: null,
261
- currentHour: null,
262
- currentMinute: null,
263
- currentSecond: null,
264
- pm: null,
265
- focused: false,
266
- overlayVisible: false,
267
- currentView: this.view
268
- }
269
- },
270
- watch: {
271
- modelValue(newValue) {
272
- this.updateCurrentMetaData();
273
- if (!this.typeUpdate && !this.inline && this.input) {
274
- this.input.value = this.formatValue(newValue);
275
- }
276
- this.typeUpdate = false;
277
- },
278
- showTime() {
279
- this.updateCurrentMetaData();
280
- },
281
- months() {
282
- if (this.overlay) {
283
- if (!this.focused) {
284
- setTimeout(this.updateFocus, 0);
285
- }
286
- }
287
- },
288
- numberOfMonths() {
289
- this.destroyResponsiveStyleElement();
290
- this.createResponsiveStyle();
291
- },
292
- responsiveOptions() {
293
- this.destroyResponsiveStyleElement();
294
- this.createResponsiveStyle();
295
- },
296
- currentView() {
297
- Promise.resolve(null).then(() => this.alignOverlay());
298
- }
299
- },
300
331
  methods: {
301
332
  isComparable() {
302
333
  return this.modelValue != null && typeof this.modelValue !== 'string';
@@ -309,25 +340,23 @@ var script = {
309
340
  if (this.modelValue) {
310
341
  if (this.isSingleSelection()) {
311
342
  return this.isDateEquals(this.modelValue, dateMeta);
312
- }
313
- else if (this.isMultipleSelection()) {
343
+ } else if (this.isMultipleSelection()) {
314
344
  let selected = false;
345
+
315
346
  for (let date of this.modelValue) {
316
347
  selected = this.isDateEquals(date, dateMeta);
348
+
317
349
  if (selected) {
318
350
  break;
319
351
  }
320
352
  }
321
353
 
322
354
  return selected;
323
- }
324
- else if (this.isRangeSelection()) {
325
- if (this.modelValue[1])
326
- return this.isDateEquals(this.modelValue[0], dateMeta) || this.isDateEquals(this.modelValue[1], dateMeta) || this.isDateBetween(this.modelValue[0], this.modelValue[1], dateMeta);
355
+ } else if (this.isRangeSelection()) {
356
+ if (this.modelValue[1]) return this.isDateEquals(this.modelValue[0], dateMeta) || this.isDateEquals(this.modelValue[1], dateMeta) || this.isDateBetween(this.modelValue[0], this.modelValue[1], dateMeta);
327
357
  else {
328
358
  return this.isDateEquals(this.modelValue[0], dateMeta);
329
359
  }
330
-
331
360
  }
332
361
  }
333
362
 
@@ -337,7 +366,7 @@ var script = {
337
366
  if (this.isComparable()) {
338
367
  let value = this.isRangeSelection() ? this.modelValue[0] : this.modelValue;
339
368
 
340
- return !this.isMultipleSelection() ? (value.getMonth() === month && value.getFullYear() === this.currentYear) : false;
369
+ return !this.isMultipleSelection() ? value.getMonth() === month && value.getFullYear() === this.currentYear : false;
341
370
  }
342
371
 
343
372
  return false;
@@ -346,21 +375,21 @@ var script = {
346
375
  if (this.isComparable()) {
347
376
  let value = this.isRangeSelection() ? this.modelValue[0] : this.modelValue;
348
377
 
349
- return !this.isMultipleSelection() && this.isComparable() ? (value.getFullYear() === year) : false;
378
+ return !this.isMultipleSelection() && this.isComparable() ? value.getFullYear() === year : false;
350
379
  }
351
380
 
352
381
  return false;
353
382
  },
354
383
  isDateEquals(value, dateMeta) {
355
- if (value)
356
- return value.getDate() === dateMeta.day && value.getMonth() === dateMeta.month && value.getFullYear() === dateMeta.year;
357
- else
358
- return false;
384
+ if (value) return value.getDate() === dateMeta.day && value.getMonth() === dateMeta.month && value.getFullYear() === dateMeta.year;
385
+ else return false;
359
386
  },
360
387
  isDateBetween(start, end, dateMeta) {
361
388
  let between = false;
389
+
362
390
  if (start && end) {
363
391
  let date = new Date(dateMeta.year, dateMeta.month, dateMeta.day);
392
+
364
393
  return start.getTime() <= date.getTime() && end.getTime() >= date.getTime();
365
394
  }
366
395
 
@@ -368,11 +397,13 @@ var script = {
368
397
  },
369
398
  getFirstDayOfMonthIndex(month, year) {
370
399
  let day = new Date();
400
+
371
401
  day.setDate(1);
372
402
  day.setMonth(month);
373
403
  day.setFullYear(year);
374
404
 
375
405
  let dayIndex = day.getDay() + this.sundayIndex;
406
+
376
407
  return dayIndex >= 7 ? dayIndex - 7 : dayIndex;
377
408
  },
378
409
  getDaysCountInMonth(month, year) {
@@ -380,6 +411,7 @@ var script = {
380
411
  },
381
412
  getDaysCountInPrevMonth(month, year) {
382
413
  let prev = this.getPreviousMonthAndYear(month, year);
414
+
383
415
  return this.getDaysCountInMonth(prev.month, prev.year);
384
416
  },
385
417
  getPreviousMonthAndYear(month, year) {
@@ -388,13 +420,12 @@ var script = {
388
420
  if (month === 0) {
389
421
  m = 11;
390
422
  y = year - 1;
391
- }
392
- else {
423
+ } else {
393
424
  m = month - 1;
394
425
  y = year;
395
426
  }
396
427
 
397
- return {'month':m, 'year': y};
428
+ return { month: m, year: y };
398
429
  },
399
430
  getNextMonthAndYear(month, year) {
400
431
  let m, y;
@@ -402,13 +433,12 @@ var script = {
402
433
  if (month === 11) {
403
434
  m = 0;
404
435
  y = year + 1;
405
- }
406
- else {
436
+ } else {
407
437
  m = month + 1;
408
438
  y = year;
409
439
  }
410
440
 
411
- return {'month':m,'year':y};
441
+ return { month: m, year: y };
412
442
  },
413
443
  daylightSavingAdjust(date) {
414
444
  if (!date) {
@@ -435,12 +465,10 @@ var script = {
435
465
  if (this.minDate) {
436
466
  if (this.minDate.getFullYear() > year) {
437
467
  validMin = false;
438
- }
439
- else if (this.minDate.getFullYear() === year) {
468
+ } else if (this.minDate.getFullYear() === year) {
440
469
  if (this.minDate.getMonth() > month) {
441
470
  validMin = false;
442
- }
443
- else if (this.minDate.getMonth() === month) {
471
+ } else if (this.minDate.getMonth() === month) {
444
472
  if (this.minDate.getDate() > day) {
445
473
  validMin = false;
446
474
  }
@@ -451,12 +479,10 @@ var script = {
451
479
  if (this.maxDate) {
452
480
  if (this.maxDate.getFullYear() < year) {
453
481
  validMax = false;
454
- }
455
- else if (this.maxDate.getFullYear() === year) {
482
+ } else if (this.maxDate.getFullYear() === year) {
456
483
  if (this.maxDate.getMonth() < month) {
457
484
  validMax = false;
458
- }
459
- else if (this.maxDate.getMonth() === month) {
485
+ } else if (this.maxDate.getMonth() === month) {
460
486
  if (this.maxDate.getDate() < day) {
461
487
  validMax = false;
462
488
  }
@@ -465,11 +491,11 @@ var script = {
465
491
  }
466
492
 
467
493
  if (this.disabledDates) {
468
- validDate = !this.isDateDisabled(day,month,year);
494
+ validDate = !this.isDateDisabled(day, month, year);
469
495
  }
470
496
 
471
497
  if (this.disabledDays) {
472
- validDay = !this.isDayDisabled(day,month,year);
498
+ validDay = !this.isDayDisabled(day, month, year);
473
499
  }
474
500
 
475
501
  return validMin && validMax && validDate && validDay;
@@ -478,10 +504,8 @@ var script = {
478
504
  el.setAttribute(this.attributeSelector, '');
479
505
 
480
506
  if (this.autoZIndex) {
481
- if (this.touchUI)
482
- ZIndexUtils.set('modal', el, this.baseZIndex || this.$primevue.config.zIndex.modal);
483
- else
484
- ZIndexUtils.set('overlay', el, this.baseZIndex || this.$primevue.config.zIndex.overlay);
507
+ if (this.touchUI) ZIndexUtils.set('modal', el, this.baseZIndex || this.$primevue.config.zIndex.modal);
508
+ else ZIndexUtils.set('overlay', el, this.baseZIndex || this.$primevue.config.zIndex.overlay);
485
509
  }
486
510
 
487
511
  this.alignOverlay();
@@ -511,14 +535,14 @@ var script = {
511
535
  this.overlay = null;
512
536
  },
513
537
  onPrevButtonClick(event) {
514
- if(this.showOtherMonths) {
515
- this.navigationState = {backward: true, button: true};
538
+ if (this.showOtherMonths) {
539
+ this.navigationState = { backward: true, button: true };
516
540
  this.navBackward(event);
517
541
  }
518
542
  },
519
543
  onNextButtonClick(event) {
520
- if(this.showOtherMonths) {
521
- this.navigationState = {backward: false, button: true};
544
+ if (this.showOtherMonths) {
545
+ this.navigationState = { backward: false, button: true };
522
546
  this.navForward(event);
523
547
  }
524
548
  },
@@ -531,24 +555,20 @@ var script = {
531
555
 
532
556
  if (this.currentView === 'month') {
533
557
  this.decrementYear();
534
- }
535
- else if (this.currentView === 'year') {
558
+ } else if (this.currentView === 'year') {
536
559
  this.decrementDecade();
537
- }
538
- else {
560
+ } else {
539
561
  if (event.shiftKey) {
540
562
  this.decrementYear();
541
- }
542
- else {
563
+ } else {
543
564
  if (this.currentMonth === 0) {
544
565
  this.currentMonth = 11;
545
566
  this.decrementYear();
546
- }
547
- else {
567
+ } else {
548
568
  this.currentMonth--;
549
569
  }
550
570
 
551
- this.$emit('month-change', {month: this.currentMonth + 1, year: this.currentYear});
571
+ this.$emit('month-change', { month: this.currentMonth + 1, year: this.currentYear });
552
572
  }
553
573
  }
554
574
  },
@@ -561,24 +581,20 @@ var script = {
561
581
 
562
582
  if (this.currentView === 'month') {
563
583
  this.incrementYear();
564
- }
565
- else if (this.currentView === 'year') {
584
+ } else if (this.currentView === 'year') {
566
585
  this.incrementDecade();
567
- }
568
- else {
586
+ } else {
569
587
  if (event.shiftKey) {
570
588
  this.incrementYear();
571
- }
572
- else {
589
+ } else {
573
590
  if (this.currentMonth === 11) {
574
591
  this.currentMonth = 0;
575
592
  this.incrementYear();
576
- }
577
- else {
593
+ } else {
578
594
  this.currentMonth++;
579
595
  }
580
596
 
581
- this.$emit('month-change', {month: this.currentMonth + 1, year: this.currentYear});
597
+ this.$emit('month-change', { month: this.currentMonth + 1, year: this.currentYear });
582
598
  }
583
599
  }
584
600
  },
@@ -613,10 +629,8 @@ var script = {
613
629
  if (this.hourFormat === '12') {
614
630
  this.pm = currentHour > 11;
615
631
 
616
- if (currentHour >= 12)
617
- currentHour = (currentHour == 12) ? 12 : currentHour - 12;
618
- else
619
- currentHour = (currentHour == 0) ? 12 : currentHour;
632
+ if (currentHour >= 12) currentHour = currentHour == 12 ? 12 : currentHour - 12;
633
+ else currentHour = currentHour == 0 ? 12 : currentHour;
620
634
  }
621
635
 
622
636
  this.currentHour = Math.floor(currentHour / this.stepHour) * this.stepHour;
@@ -630,6 +644,7 @@ var script = {
630
644
  this.overlayVisible = false;
631
645
  }
632
646
  };
647
+
633
648
  document.addEventListener('mousedown', this.outsideClickListener);
634
649
  }
635
650
  },
@@ -662,6 +677,7 @@ var script = {
662
677
  this.overlayVisible = false;
663
678
  }
664
679
  };
680
+
665
681
  window.addEventListener('resize', this.resizeListener);
666
682
  }
667
683
  },
@@ -672,27 +688,27 @@ var script = {
672
688
  }
673
689
  },
674
690
  isOutsideClicked(event) {
675
- return !(this.$el.isSameNode(event.target) || this.isNavIconClicked(event) ||
676
- this.$el.contains(event.target) || (this.overlay && this.overlay.contains(event.target)));
691
+ return !(this.$el.isSameNode(event.target) || this.isNavIconClicked(event) || this.$el.contains(event.target) || (this.overlay && this.overlay.contains(event.target)));
677
692
  },
678
693
  isNavIconClicked(event) {
679
- return (DomHandler.hasClass(event.target, 'p-datepicker-prev') || DomHandler.hasClass(event.target, 'p-datepicker-prev-icon')
680
- || DomHandler.hasClass(event.target, 'p-datepicker-next') || DomHandler.hasClass(event.target, 'p-datepicker-next-icon'));
694
+ return (
695
+ DomHandler.hasClass(event.target, 'p-datepicker-prev') ||
696
+ DomHandler.hasClass(event.target, 'p-datepicker-prev-icon') ||
697
+ DomHandler.hasClass(event.target, 'p-datepicker-next') ||
698
+ DomHandler.hasClass(event.target, 'p-datepicker-next-icon')
699
+ );
681
700
  },
682
701
  alignOverlay() {
683
702
  if (this.touchUI) {
684
703
  this.enableModality();
685
- }
686
- else if (this.overlay) {
704
+ } else if (this.overlay) {
687
705
  if (this.appendTo === 'self' || this.inline) {
688
706
  DomHandler.relativePosition(this.overlay, this.$el);
689
- }
690
- else {
707
+ } else {
691
708
  if (this.view === 'date') {
692
709
  this.overlay.style.width = DomHandler.getOuterWidth(this.overlay) + 'px';
693
710
  this.overlay.style.minWidth = DomHandler.getOuterWidth(this.$el) + 'px';
694
- }
695
- else {
711
+ } else {
696
712
  this.overlay.style.width = DomHandler.getOuterWidth(this.$el) + 'px';
697
713
  }
698
714
 
@@ -705,8 +721,7 @@ var script = {
705
721
  if (!this.overlayVisible) {
706
722
  this.input.focus();
707
723
  this.overlayVisible = true;
708
- }
709
- else {
724
+ } else {
710
725
  this.overlayVisible = false;
711
726
  }
712
727
  }
@@ -726,41 +741,42 @@ var script = {
726
741
  if (this.disabledDays) {
727
742
  let weekday = new Date(year, month, day);
728
743
  let weekdayNumber = weekday.getDay();
744
+
729
745
  return this.disabledDays.indexOf(weekdayNumber) !== -1;
730
746
  }
747
+
731
748
  return false;
732
749
  },
733
750
  onMonthDropdownChange(value) {
734
751
  this.currentMonth = parseInt(value);
735
- this.$emit('month-change', {month: this.currentMonth + 1, year: this.currentYear});
752
+ this.$emit('month-change', { month: this.currentMonth + 1, year: this.currentYear });
736
753
  },
737
754
  onYearDropdownChange(value) {
738
755
  this.currentYear = parseInt(value);
739
- this.$emit('year-change', {month: this.currentMonth + 1, year: this.currentYear});
756
+ this.$emit('year-change', { month: this.currentMonth + 1, year: this.currentYear });
740
757
  },
741
758
  onDateSelect(event, dateMeta) {
742
759
  if (this.disabled || !dateMeta.selectable) {
743
760
  return;
744
761
  }
745
762
 
746
- DomHandler.find(this.overlay, '.p-datepicker-calendar td span:not(.p-disabled)').forEach(cell => cell.tabIndex = -1);
763
+ DomHandler.find(this.overlay, '.p-datepicker-calendar td span:not(.p-disabled)').forEach((cell) => (cell.tabIndex = -1));
747
764
 
748
765
  if (event) {
749
766
  event.currentTarget.focus();
750
767
  }
751
768
 
752
769
  if (this.isMultipleSelection() && this.isSelected(dateMeta)) {
753
- let newValue = this.modelValue.filter(date => !this.isDateEquals(date, dateMeta));
770
+ let newValue = this.modelValue.filter((date) => !this.isDateEquals(date, dateMeta));
771
+
754
772
  this.updateModel(newValue);
755
- }
756
- else {
773
+ } else {
757
774
  if (this.shouldSelectDate(dateMeta)) {
758
775
  if (dateMeta.otherMonth) {
759
776
  this.currentMonth = dateMeta.month;
760
777
  this.currentYear = dateMeta.year;
761
778
  this.selectDate(dateMeta);
762
- }
763
- else {
779
+ } else {
764
780
  this.selectDate(dateMeta);
765
781
  }
766
782
  }
@@ -777,10 +793,8 @@ var script = {
777
793
  let date = new Date(dateMeta.year, dateMeta.month, dateMeta.day);
778
794
 
779
795
  if (this.showTime) {
780
- if (this.hourFormat === '12' && this.pm && this.currentHour != 12)
781
- date.setHours(this.currentHour + 12);
782
- else
783
- date.setHours(this.currentHour);
796
+ if (this.hourFormat === '12' && this.pm && this.currentHour != 12) date.setHours(this.currentHour + 12);
797
+ else date.setHours(this.currentHour);
784
798
 
785
799
  date.setMinutes(this.currentMinute);
786
800
  date.setSeconds(this.currentSecond);
@@ -804,25 +818,22 @@ var script = {
804
818
 
805
819
  if (this.isSingleSelection()) {
806
820
  modelVal = date;
807
- }
808
- else if (this.isMultipleSelection()) {
821
+ } else if (this.isMultipleSelection()) {
809
822
  modelVal = this.modelValue ? [...this.modelValue, date] : [date];
810
- }
811
- else if (this.isRangeSelection()) {
823
+ } else if (this.isRangeSelection()) {
812
824
  if (this.modelValue && this.modelValue.length) {
813
825
  let startDate = this.modelValue[0];
814
826
  let endDate = this.modelValue[1];
815
827
 
816
828
  if (!endDate && date.getTime() >= startDate.getTime()) {
817
829
  endDate = date;
818
- }
819
- else {
830
+ } else {
820
831
  startDate = date;
821
832
  endDate = null;
822
833
  }
834
+
823
835
  modelVal = [startDate, endDate];
824
- }
825
- else {
836
+ } else {
826
837
  modelVal = [date, null];
827
838
  }
828
839
  }
@@ -836,16 +847,15 @@ var script = {
836
847
  this.overlayVisible = false;
837
848
  }, 150);
838
849
  }
850
+
839
851
  this.$emit('date-select', date);
840
852
  },
841
853
  updateModel(value) {
842
854
  this.$emit('update:modelValue', value);
843
855
  },
844
856
  shouldSelectDate() {
845
- if (this.isMultipleSelection())
846
- return this.maxDateCount != null ? this.maxDateCount > (this.modelValue ? this.modelValue.length : 0) : true;
847
- else
848
- return true;
857
+ if (this.isMultipleSelection()) return this.maxDateCount != null ? this.maxDateCount > (this.modelValue ? this.modelValue.length : 0) : true;
858
+ else return true;
849
859
  },
850
860
  isSingleSelection() {
851
861
  return this.selectionMode === 'single';
@@ -862,33 +872,34 @@ var script = {
862
872
  }
863
873
 
864
874
  let formattedValue = '';
875
+
865
876
  if (value) {
866
877
  try {
867
878
  if (this.isSingleSelection()) {
868
879
  formattedValue = this.formatDateTime(value);
869
- }
870
- else if (this.isMultipleSelection()) {
871
- for(let i = 0; i < value.length; i++) {
880
+ } else if (this.isMultipleSelection()) {
881
+ for (let i = 0; i < value.length; i++) {
872
882
  let dateAsString = this.formatDateTime(value[i]);
883
+
873
884
  formattedValue += dateAsString;
874
- if(i !== (value.length - 1)) {
885
+
886
+ if (i !== value.length - 1) {
875
887
  formattedValue += ', ';
876
888
  }
877
889
  }
878
- }
879
- else if (this.isRangeSelection()) {
890
+ } else if (this.isRangeSelection()) {
880
891
  if (value && value.length) {
881
892
  let startDate = value[0];
882
893
  let endDate = value[1];
883
894
 
884
895
  formattedValue = this.formatDateTime(startDate);
896
+
885
897
  if (endDate) {
886
898
  formattedValue += ' - ' + this.formatDateTime(endDate);
887
899
  }
888
900
  }
889
901
  }
890
- }
891
- catch(err) {
902
+ } catch (err) {
892
903
  formattedValue = value;
893
904
  }
894
905
  }
@@ -897,13 +908,14 @@ var script = {
897
908
  },
898
909
  formatDateTime(date) {
899
910
  let formattedValue = null;
911
+
900
912
  if (date) {
901
- if(this.timeOnly) {
913
+ if (this.timeOnly) {
902
914
  formattedValue = this.formatTime(date);
903
- }
904
- else {
915
+ } else {
905
916
  formattedValue = this.formatDate(date, this.datePattern);
906
- if(this.showTime) {
917
+
918
+ if (this.showTime) {
907
919
  formattedValue += ' ' + this.formatTime(date);
908
920
  }
909
921
  }
@@ -917,32 +929,38 @@ var script = {
917
929
  }
918
930
 
919
931
  let iFormat;
932
+
920
933
  const lookAhead = (match) => {
921
- const matches = (iFormat + 1 < format.length && format.charAt(iFormat + 1) === match);
922
- if (matches) {
923
- iFormat++;
924
- }
925
- return matches;
926
- },
934
+ const matches = iFormat + 1 < format.length && format.charAt(iFormat + 1) === match;
935
+
936
+ if (matches) {
937
+ iFormat++;
938
+ }
939
+
940
+ return matches;
941
+ },
927
942
  formatNumber = (match, value, len) => {
928
943
  let num = '' + value;
944
+
929
945
  if (lookAhead(match)) {
930
946
  while (num.length < len) {
931
947
  num = '0' + num;
932
948
  }
933
949
  }
950
+
934
951
  return num;
935
952
  },
936
953
  formatName = (match, value, shortNames, longNames) => {
937
- return (lookAhead(match) ? longNames[value] : shortNames[value]);
954
+ return lookAhead(match) ? longNames[value] : shortNames[value];
938
955
  };
956
+
939
957
  let output = '';
940
958
  let literal = false;
941
959
 
942
960
  if (date) {
943
961
  for (iFormat = 0; iFormat < format.length; iFormat++) {
944
962
  if (literal) {
945
- if (format.charAt(iFormat) === '\'' && !lookAhead('\'')) {
963
+ if (format.charAt(iFormat) === "'" && !lookAhead("'")) {
946
964
  literal = false;
947
965
  } else {
948
966
  output += format.charAt(iFormat);
@@ -956,16 +974,13 @@ var script = {
956
974
  output += formatName('D', date.getDay(), this.$primevue.config.locale.dayNamesShort, this.$primevue.config.locale.dayNames);
957
975
  break;
958
976
  case 'o':
959
- output += formatNumber('o',
960
- Math.round((
961
- new Date(date.getFullYear(), date.getMonth(), date.getDate()).getTime() -
962
- new Date(date.getFullYear(), 0, 0).getTime()) / 86400000), 3);
977
+ output += formatNumber('o', Math.round((new Date(date.getFullYear(), date.getMonth(), date.getDate()).getTime() - new Date(date.getFullYear(), 0, 0).getTime()) / 86400000), 3);
963
978
  break;
964
979
  case 'm':
965
980
  output += formatNumber('m', date.getMonth() + 1, 2);
966
981
  break;
967
982
  case 'M':
968
- output += formatName('M',date.getMonth(), this.$primevue.config.locale.monthNamesShort, this.$primevue.config.locale.monthNames);
983
+ output += formatName('M', date.getMonth(), this.$primevue.config.locale.monthNamesShort, this.$primevue.config.locale.monthNames);
969
984
  break;
970
985
  case 'y':
971
986
  output += lookAhead('y') ? date.getFullYear() : (date.getFullYear() % 100 < 10 ? '0' : '') + (date.getFullYear() % 100);
@@ -976,12 +991,13 @@ var script = {
976
991
  case '!':
977
992
  output += date.getTime() * 10000 + this.ticksTo1970;
978
993
  break;
979
- case '\'':
980
- if (lookAhead('\'')) {
981
- output += '\'';
994
+ case "'":
995
+ if (lookAhead("'")) {
996
+ output += "'";
982
997
  } else {
983
998
  literal = true;
984
999
  }
1000
+
985
1001
  break;
986
1002
  default:
987
1003
  output += format.charAt(iFormat);
@@ -989,6 +1005,7 @@ var script = {
989
1005
  }
990
1006
  }
991
1007
  }
1008
+
992
1009
  return output;
993
1010
  },
994
1011
  formatTime(date) {
@@ -1006,17 +1023,17 @@ var script = {
1006
1023
  }
1007
1024
 
1008
1025
  if (this.hourFormat === '12') {
1009
- output += hours === 0 ? 12 : (hours < 10) ? '0' + hours : hours;
1010
- }
1011
- else {
1012
- output += (hours < 10) ? '0' + hours : hours;
1026
+ output += hours === 0 ? 12 : hours < 10 ? '0' + hours : hours;
1027
+ } else {
1028
+ output += hours < 10 ? '0' + hours : hours;
1013
1029
  }
1030
+
1014
1031
  output += ':';
1015
- output += (minutes < 10) ? '0' + minutes : minutes;
1032
+ output += minutes < 10 ? '0' + minutes : minutes;
1016
1033
 
1017
1034
  if (this.showSeconds) {
1018
1035
  output += ':';
1019
- output += (seconds < 10) ? '0' + seconds : seconds;
1036
+ output += seconds < 10 ? '0' + seconds : seconds;
1020
1037
  }
1021
1038
 
1022
1039
  if (this.hourFormat === '12') {
@@ -1063,44 +1080,39 @@ var script = {
1063
1080
  this.clearTimePickerTimer();
1064
1081
  },
1065
1082
  repeat(event, interval, type, direction) {
1066
- let i = interval||500;
1083
+ let i = interval || 500;
1067
1084
 
1068
1085
  this.clearTimePickerTimer();
1069
1086
  this.timePickerTimer = setTimeout(() => {
1070
1087
  this.repeat(event, 100, type, direction);
1071
1088
  }, i);
1072
1089
 
1073
- switch(type) {
1090
+ switch (type) {
1074
1091
  case 0:
1075
- if (direction === 1)
1076
- this.incrementHour(event);
1077
- else
1078
- this.decrementHour(event);
1079
- break;
1092
+ if (direction === 1) this.incrementHour(event);
1093
+ else this.decrementHour(event);
1094
+ break;
1080
1095
 
1081
1096
  case 1:
1082
- if (direction === 1)
1083
- this.incrementMinute(event);
1084
- else
1085
- this.decrementMinute(event);
1086
- break;
1097
+ if (direction === 1) this.incrementMinute(event);
1098
+ else this.decrementMinute(event);
1099
+ break;
1087
1100
 
1088
1101
  case 2:
1089
- if (direction === 1)
1090
- this.incrementSecond(event);
1091
- else
1092
- this.decrementSecond(event);
1093
- break;
1102
+ if (direction === 1) this.incrementSecond(event);
1103
+ else this.decrementSecond(event);
1104
+ break;
1094
1105
  }
1095
1106
  },
1096
1107
  convertTo24Hour(hours, pm) {
1097
1108
  if (this.hourFormat == '12') {
1098
1109
  if (hours === 12) {
1099
- return (pm ? 12 : 0);
1110
+ return pm ? 12 : 0;
1100
1111
  } else {
1101
- return (pm ? hours + 12 : hours);
1112
+ return pm ? hours + 12 : hours;
1102
1113
  }
1103
1114
  }
1115
+
1104
1116
  return hours;
1105
1117
  },
1106
1118
  validateTime(hour, minute, second, pm) {
@@ -1110,18 +1122,23 @@ var script = {
1110
1122
  if (this.isRangeSelection()) {
1111
1123
  value = this.modelValue[1] || this.modelValue[0];
1112
1124
  }
1125
+
1113
1126
  if (this.isMultipleSelection()) {
1114
1127
  value = this.modelValue[this.modelValue.length - 1];
1115
1128
  }
1129
+
1116
1130
  const valueDateString = value ? value.toDateString() : null;
1131
+
1117
1132
  if (this.minDate && valueDateString && this.minDate.toDateString() === valueDateString) {
1118
1133
  if (this.minDate.getHours() > convertedHour) {
1119
1134
  return false;
1120
1135
  }
1136
+
1121
1137
  if (this.minDate.getHours() === convertedHour) {
1122
1138
  if (this.minDate.getMinutes() > minute) {
1123
1139
  return false;
1124
1140
  }
1141
+
1125
1142
  if (this.minDate.getMinutes() === minute) {
1126
1143
  if (this.minDate.getSeconds() > second) {
1127
1144
  return false;
@@ -1134,10 +1151,12 @@ var script = {
1134
1151
  if (this.maxDate.getHours() < convertedHour) {
1135
1152
  return false;
1136
1153
  }
1154
+
1137
1155
  if (this.maxDate.getHours() === convertedHour) {
1138
1156
  if (this.maxDate.getMinutes() < minute) {
1139
1157
  return false;
1140
1158
  }
1159
+
1141
1160
  if (this.maxDate.getMinutes() === minute) {
1142
1161
  if (this.maxDate.getSeconds() < second) {
1143
1162
  return false;
@@ -1145,6 +1164,7 @@ var script = {
1145
1164
  }
1146
1165
  }
1147
1166
  }
1167
+
1148
1168
  return true;
1149
1169
  },
1150
1170
  incrementHour(event) {
@@ -1152,51 +1172,58 @@ var script = {
1152
1172
  let newHour = this.currentHour + this.stepHour;
1153
1173
  let newPM = this.pm;
1154
1174
 
1155
- if (this.hourFormat == '24')
1156
- newHour = (newHour >= 24) ? (newHour - 24) : newHour;
1175
+ if (this.hourFormat == '24') newHour = newHour >= 24 ? newHour - 24 : newHour;
1157
1176
  else if (this.hourFormat == '12') {
1158
1177
  // Before the AM/PM break, now after
1159
1178
  if (prevHour < 12 && newHour > 11) {
1160
- newPM= !this.pm;
1179
+ newPM = !this.pm;
1161
1180
  }
1162
- newHour = (newHour >= 13) ? (newHour - 12) : newHour;
1181
+
1182
+ newHour = newHour >= 13 ? newHour - 12 : newHour;
1163
1183
  }
1164
1184
 
1165
1185
  if (this.validateTime(newHour, this.currentMinute, this.currentSecond, newPM)) {
1166
1186
  this.currentHour = newHour;
1167
1187
  this.pm = newPM;
1168
1188
  }
1189
+
1169
1190
  event.preventDefault();
1170
1191
  },
1171
1192
  decrementHour(event) {
1172
1193
  let newHour = this.currentHour - this.stepHour;
1173
1194
  let newPM = this.pm;
1174
1195
 
1175
- if (this.hourFormat == '24')
1176
- newHour = (newHour < 0) ? (24 + newHour) : newHour;
1196
+ if (this.hourFormat == '24') newHour = newHour < 0 ? 24 + newHour : newHour;
1177
1197
  else if (this.hourFormat == '12') {
1178
1198
  // If we were at noon/midnight, then switch
1179
1199
  if (this.currentHour === 12) {
1180
1200
  newPM = !this.pm;
1181
1201
  }
1182
- newHour = (newHour <= 0) ? (12 + newHour) : newHour;
1202
+
1203
+ newHour = newHour <= 0 ? 12 + newHour : newHour;
1183
1204
  }
1205
+
1184
1206
  if (this.validateTime(newHour, this.currentMinute, this.currentSecond, newPM)) {
1185
1207
  this.currentHour = newHour;
1186
1208
  this.pm = newPM;
1187
1209
  }
1210
+
1188
1211
  event.preventDefault();
1189
1212
  },
1190
1213
  incrementMinute(event) {
1191
1214
  let newMinute = this.currentMinute + this.stepMinute;
1215
+
1192
1216
  if (this.validateTime(this.currentHour, newMinute, this.currentSecond, true)) {
1193
- this.currentMinute = (newMinute > 59) ? newMinute - 60 : newMinute;
1217
+ this.currentMinute = newMinute > 59 ? newMinute - 60 : newMinute;
1194
1218
  }
1219
+
1195
1220
  event.preventDefault();
1196
1221
  },
1197
1222
  decrementMinute(event) {
1198
1223
  let newMinute = this.currentMinute - this.stepMinute;
1199
- newMinute = (newMinute < 0) ? 60 + newMinute : newMinute;
1224
+
1225
+ newMinute = newMinute < 0 ? 60 + newMinute : newMinute;
1226
+
1200
1227
  if (this.validateTime(this.currentHour, newMinute, this.currentSecond, true)) {
1201
1228
  this.currentMinute = newMinute;
1202
1229
  }
@@ -1205,15 +1232,18 @@ var script = {
1205
1232
  },
1206
1233
  incrementSecond(event) {
1207
1234
  let newSecond = this.currentSecond + this.stepSecond;
1235
+
1208
1236
  if (this.validateTime(this.currentHour, this.currentMinute, newSecond, true)) {
1209
- this.currentSecond = (newSecond > 59) ? newSecond - 60 : newSecond;
1237
+ this.currentSecond = newSecond > 59 ? newSecond - 60 : newSecond;
1210
1238
  }
1211
1239
 
1212
1240
  event.preventDefault();
1213
1241
  },
1214
1242
  decrementSecond(event) {
1215
1243
  let newSecond = this.currentSecond - this.stepSecond;
1216
- newSecond = (newSecond < 0) ? 60 + newSecond : newSecond;
1244
+
1245
+ newSecond = newSecond < 0 ? 60 + newSecond : newSecond;
1246
+
1217
1247
  if (this.validateTime(this.currentHour, this.currentMinute, newSecond, true)) {
1218
1248
  this.currentSecond = newSecond;
1219
1249
  }
@@ -1227,18 +1257,17 @@ var script = {
1227
1257
  if (this.isRangeSelection()) {
1228
1258
  value = this.modelValue[1] || this.modelValue[0];
1229
1259
  }
1260
+
1230
1261
  if (this.isMultipleSelection()) {
1231
1262
  value = this.modelValue[this.modelValue.length - 1];
1232
1263
  }
1264
+
1233
1265
  value = value ? new Date(value.getTime()) : new Date();
1234
1266
 
1235
1267
  if (this.hourFormat == '12') {
1236
- if (this.currentHour === 12)
1237
- value.setHours(this.pm ? 12 : 0);
1238
- else
1239
- value.setHours(this.pm ? this.currentHour + 12 : this.currentHour);
1240
- }
1241
- else {
1268
+ if (this.currentHour === 12) value.setHours(this.pm ? 12 : 0);
1269
+ else value.setHours(this.pm ? this.currentHour + 12 : this.currentHour);
1270
+ } else {
1242
1271
  value.setHours(this.currentHour);
1243
1272
  }
1244
1273
 
@@ -1246,19 +1275,17 @@ var script = {
1246
1275
  value.setSeconds(this.currentSecond);
1247
1276
 
1248
1277
  if (this.isRangeSelection()) {
1249
- if (this.modelValue[1])
1250
- value = [this.modelValue[0], value];
1251
- else
1252
- value = [value, null];
1278
+ if (this.modelValue[1]) value = [this.modelValue[0], value];
1279
+ else value = [value, null];
1253
1280
  }
1254
1281
 
1255
- if (this.isMultipleSelection()){
1282
+ if (this.isMultipleSelection()) {
1256
1283
  value = [...this.modelValue.slice(0, -1), value];
1257
1284
  }
1258
1285
 
1259
1286
  this.updateModel(value);
1260
1287
  this.$emit('date-select', value);
1261
- setTimeout(() => this.timePickerChange = false, 0);
1288
+ setTimeout(() => (this.timePickerChange = false), 0);
1262
1289
  },
1263
1290
  toggleAMPM(event) {
1264
1291
  this.pm = !this.pm;
@@ -1272,24 +1299,22 @@ var script = {
1272
1299
  },
1273
1300
  onMonthSelect(event, index) {
1274
1301
  if (this.view === 'month') {
1275
- this.onDateSelect(event, {year: this.currentYear, month: index, day: 1, selectable: true});
1276
- }
1277
- else {
1302
+ this.onDateSelect(event, { year: this.currentYear, month: index, day: 1, selectable: true });
1303
+ } else {
1278
1304
  this.currentMonth = index;
1279
1305
  this.currentView = 'date';
1280
- this.$emit('month-change', {month: this.currentMonth + 1, year: this.currentYear});
1306
+ this.$emit('month-change', { month: this.currentMonth + 1, year: this.currentYear });
1281
1307
  }
1282
1308
 
1283
1309
  setTimeout(this.updateFocus, 0);
1284
1310
  },
1285
1311
  onYearSelect(event, year) {
1286
1312
  if (this.view === 'year') {
1287
- this.onDateSelect(event, {year: year, month: 0, day: 1, selectable: true});
1288
- }
1289
- else {
1313
+ this.onDateSelect(event, { year: year, month: 0, day: 1, selectable: true });
1314
+ } else {
1290
1315
  this.currentYear = year;
1291
1316
  this.currentView = 'month';
1292
- this.$emit('year-change', {month: this.currentMonth + 1, year: this.currentYear});
1317
+ this.$emit('year-change', { month: this.currentMonth + 1, year: this.currentYear });
1293
1318
  }
1294
1319
 
1295
1320
  setTimeout(this.updateFocus, 0);
@@ -1303,6 +1328,7 @@ var script = {
1303
1328
  this.maskClickListener = () => {
1304
1329
  this.overlayVisible = false;
1305
1330
  };
1331
+
1306
1332
  this.mask.addEventListener('click', this.maskClickListener);
1307
1333
 
1308
1334
  document.body.appendChild(this.mask);
@@ -1325,9 +1351,11 @@ var script = {
1325
1351
 
1326
1352
  let bodyChildren = document.body.children;
1327
1353
  let hasBlockerMasks;
1354
+
1328
1355
  for (let i = 0; i < bodyChildren.length; i++) {
1329
1356
  let bodyChild = bodyChildren[i];
1330
- if(DomHandler.hasClass(bodyChild, 'p-datepicker-mask-scrollblocker')) {
1357
+
1358
+ if (DomHandler.hasClass(bodyChild, 'p-datepicker-mask-scrollblocker')) {
1331
1359
  hasBlockerMasks = true;
1332
1360
  break;
1333
1361
  }
@@ -1339,6 +1367,7 @@ var script = {
1339
1367
  },
1340
1368
  updateCurrentMetaData() {
1341
1369
  const viewDate = this.viewDate;
1370
+
1342
1371
  this.currentMonth = viewDate.getMonth();
1343
1372
  this.currentYear = viewDate.getFullYear();
1344
1373
 
@@ -1352,15 +1381,17 @@ var script = {
1352
1381
  }
1353
1382
 
1354
1383
  let isValid = true;
1384
+
1355
1385
  if (this.isSingleSelection()) {
1356
1386
  if (!this.isSelectable(value.getDate(), value.getMonth(), value.getFullYear(), false)) {
1357
1387
  isValid = false;
1358
1388
  }
1359
- } else if (value.every(v => this.isSelectable(v.getDate(), v.getMonth(), v.getFullYear(), false))) {
1389
+ } else if (value.every((v) => this.isSelectable(v.getDate(), v.getMonth(), v.getFullYear(), false))) {
1360
1390
  if (this.isRangeSelection()) {
1361
1391
  isValid = value.length > 1 && value[1] > value[0] ? true : false;
1362
1392
  }
1363
1393
  }
1394
+
1364
1395
  return isValid;
1365
1396
  },
1366
1397
  parseValue(text) {
@@ -1372,17 +1403,19 @@ var script = {
1372
1403
 
1373
1404
  if (this.isSingleSelection()) {
1374
1405
  value = this.parseDateTime(text);
1375
- }
1376
- else if (this.isMultipleSelection()) {
1406
+ } else if (this.isMultipleSelection()) {
1377
1407
  let tokens = text.split(',');
1408
+
1378
1409
  value = [];
1410
+
1379
1411
  for (let token of tokens) {
1380
1412
  value.push(this.parseDateTime(token.trim()));
1381
1413
  }
1382
- }
1383
- else if (this.isRangeSelection()) {
1414
+ } else if (this.isRangeSelection()) {
1384
1415
  let tokens = text.split(' - ');
1416
+
1385
1417
  value = [];
1418
+
1386
1419
  for (let i = 0; i < tokens.length; i++) {
1387
1420
  value[i] = this.parseDateTime(tokens[i].trim());
1388
1421
  }
@@ -1397,14 +1430,13 @@ var script = {
1397
1430
  if (this.timeOnly) {
1398
1431
  date = new Date();
1399
1432
  this.populateTime(date, parts[0], parts[1]);
1400
- }
1401
- else {
1433
+ } else {
1402
1434
  const dateFormat = this.datePattern;
1435
+
1403
1436
  if (this.showTime) {
1404
1437
  date = this.parseDate(parts[0], dateFormat);
1405
1438
  this.populateTime(date, parts[1], parts[2]);
1406
- }
1407
- else {
1439
+ } else {
1408
1440
  date = this.parseDate(text, dateFormat);
1409
1441
  }
1410
1442
  }
@@ -1416,8 +1448,9 @@ var script = {
1416
1448
  throw 'Invalid Time';
1417
1449
  }
1418
1450
 
1419
- this.pm = (ampm === 'PM' || ampm === 'pm');
1451
+ this.pm = ampm === 'PM' || ampm === 'pm';
1420
1452
  let time = this.parseTime(timeString);
1453
+
1421
1454
  value.setHours(time.hour);
1422
1455
  value.setMinutes(time.minute);
1423
1456
  value.setSeconds(time.second);
@@ -1425,10 +1458,10 @@ var script = {
1425
1458
  parseTime(value) {
1426
1459
  let tokens = value.split(':');
1427
1460
  let validTokenLength = this.showSeconds ? 3 : 2;
1428
- let regex = (/^[0-9][0-9]$/);
1461
+ let regex = /^[0-9][0-9]$/;
1429
1462
 
1430
1463
  if (tokens.length !== validTokenLength || !tokens[0].match(regex) || !tokens[1].match(regex) || (this.showSeconds && !tokens[2].match(regex))) {
1431
- throw "Invalid time";
1464
+ throw 'Invalid time';
1432
1465
  }
1433
1466
 
1434
1467
  let h = parseInt(tokens[0]);
@@ -1436,88 +1469,97 @@ var script = {
1436
1469
  let s = this.showSeconds ? parseInt(tokens[2]) : null;
1437
1470
 
1438
1471
  if (isNaN(h) || isNaN(m) || h > 23 || m > 59 || (this.hourFormat == '12' && h > 12) || (this.showSeconds && (isNaN(s) || s > 59))) {
1439
- throw "Invalid time";
1440
- }
1441
- else {
1472
+ throw 'Invalid time';
1473
+ } else {
1442
1474
  if (this.hourFormat == '12' && h !== 12 && this.pm) {
1443
- h+= 12;
1475
+ h += 12;
1444
1476
  }
1445
1477
 
1446
- return {hour: h, minute: m, second: s};
1478
+ return { hour: h, minute: m, second: s };
1447
1479
  }
1448
1480
  },
1449
1481
  parseDate(value, format) {
1450
1482
  if (format == null || value == null) {
1451
- throw "Invalid arguments";
1483
+ throw 'Invalid arguments';
1452
1484
  }
1453
1485
 
1454
- value = (typeof value === "object" ? value.toString() : value + "");
1455
- if (value === "") {
1486
+ value = typeof value === 'object' ? value.toString() : value + '';
1487
+
1488
+ if (value === '') {
1456
1489
  return null;
1457
1490
  }
1458
1491
 
1459
- let iFormat, dim, extra,
1460
- iValue = 0,
1461
- shortYearCutoff = (typeof this.shortYearCutoff !== "string" ? this.shortYearCutoff : new Date().getFullYear() % 100 + parseInt(this.shortYearCutoff, 10)),
1462
- year = -1,
1463
- month = -1,
1464
- day = -1,
1465
- doy = -1,
1466
- literal = false,
1467
- date,
1468
- lookAhead = (match) => {
1469
- let matches = (iFormat + 1 < format.length && format.charAt(iFormat + 1) === match);
1470
- if (matches) {
1471
- iFormat++;
1472
- }
1473
- return matches;
1474
- },
1475
- getNumber = (match) => {
1476
- let isDoubled = lookAhead(match),
1477
- size = (match === "@" ? 14 : (match === "!" ? 20 :
1478
- (match === "y" && isDoubled ? 4 : (match === "o" ? 3 : 2)))),
1479
- minSize = (match === "y" ? size : 1),
1480
- digits = new RegExp("^\\d{" + minSize + "," + size + "}"),
1481
- num = value.substring(iValue).match(digits);
1482
- if (!num) {
1483
- throw "Missing number at position " + iValue;
1484
- }
1485
- iValue += num[ 0 ].length;
1486
- return parseInt(num[ 0 ], 10);
1487
- },
1488
- getName = (match, shortNames, longNames) => {
1489
- let index = -1;
1490
- let arr = lookAhead(match) ? longNames : shortNames;
1491
- let names = [];
1492
-
1493
- for (let i = 0; i < arr.length; i++) {
1494
- names.push([i,arr[i]]);
1495
- }
1496
- names.sort((a,b) => {
1497
- return -(a[ 1 ].length - b[ 1 ].length);
1498
- });
1492
+ let iFormat,
1493
+ dim,
1494
+ extra,
1495
+ iValue = 0,
1496
+ shortYearCutoff = typeof this.shortYearCutoff !== 'string' ? this.shortYearCutoff : (new Date().getFullYear() % 100) + parseInt(this.shortYearCutoff, 10),
1497
+ year = -1,
1498
+ month = -1,
1499
+ day = -1,
1500
+ doy = -1,
1501
+ literal = false,
1502
+ date,
1503
+ lookAhead = (match) => {
1504
+ let matches = iFormat + 1 < format.length && format.charAt(iFormat + 1) === match;
1499
1505
 
1500
- for (let i = 0; i < names.length; i++) {
1501
- let name = names[i][1];
1502
- if (value.substr(iValue, name.length).toLowerCase() === name.toLowerCase()) {
1503
- index = names[i][0];
1504
- iValue += name.length;
1505
- break;
1506
+ if (matches) {
1507
+ iFormat++;
1506
1508
  }
1507
- }
1508
1509
 
1509
- if (index !== -1) {
1510
- return index + 1;
1511
- } else {
1512
- throw "Unknown name at position " + iValue;
1513
- }
1514
- },
1515
- checkLiteral = () => {
1516
- if (value.charAt(iValue) !== format.charAt(iFormat)) {
1517
- throw "Unexpected literal at position " + iValue;
1518
- }
1519
- iValue++;
1520
- };
1510
+ return matches;
1511
+ },
1512
+ getNumber = (match) => {
1513
+ let isDoubled = lookAhead(match),
1514
+ size = match === '@' ? 14 : match === '!' ? 20 : match === 'y' && isDoubled ? 4 : match === 'o' ? 3 : 2,
1515
+ minSize = match === 'y' ? size : 1,
1516
+ digits = new RegExp('^\\d{' + minSize + ',' + size + '}'),
1517
+ num = value.substring(iValue).match(digits);
1518
+
1519
+ if (!num) {
1520
+ throw 'Missing number at position ' + iValue;
1521
+ }
1522
+
1523
+ iValue += num[0].length;
1524
+
1525
+ return parseInt(num[0], 10);
1526
+ },
1527
+ getName = (match, shortNames, longNames) => {
1528
+ let index = -1;
1529
+ let arr = lookAhead(match) ? longNames : shortNames;
1530
+ let names = [];
1531
+
1532
+ for (let i = 0; i < arr.length; i++) {
1533
+ names.push([i, arr[i]]);
1534
+ }
1535
+
1536
+ names.sort((a, b) => {
1537
+ return -(a[1].length - b[1].length);
1538
+ });
1539
+
1540
+ for (let i = 0; i < names.length; i++) {
1541
+ let name = names[i][1];
1542
+
1543
+ if (value.substr(iValue, name.length).toLowerCase() === name.toLowerCase()) {
1544
+ index = names[i][0];
1545
+ iValue += name.length;
1546
+ break;
1547
+ }
1548
+ }
1549
+
1550
+ if (index !== -1) {
1551
+ return index + 1;
1552
+ } else {
1553
+ throw 'Unknown name at position ' + iValue;
1554
+ }
1555
+ },
1556
+ checkLiteral = () => {
1557
+ if (value.charAt(iValue) !== format.charAt(iFormat)) {
1558
+ throw 'Unexpected literal at position ' + iValue;
1559
+ }
1560
+
1561
+ iValue++;
1562
+ };
1521
1563
 
1522
1564
  if (this.currentView === 'month') {
1523
1565
  day = 1;
@@ -1532,32 +1574,32 @@ var script = {
1532
1574
  }
1533
1575
  } else {
1534
1576
  switch (format.charAt(iFormat)) {
1535
- case "d":
1536
- day = getNumber("d");
1577
+ case 'd':
1578
+ day = getNumber('d');
1537
1579
  break;
1538
- case "D":
1539
- getName("D", this.$primevue.config.locale.dayNamesShort, this.$primevue.config.locale.dayNames);
1580
+ case 'D':
1581
+ getName('D', this.$primevue.config.locale.dayNamesShort, this.$primevue.config.locale.dayNames);
1540
1582
  break;
1541
- case "o":
1542
- doy = getNumber("o");
1583
+ case 'o':
1584
+ doy = getNumber('o');
1543
1585
  break;
1544
- case "m":
1545
- month = getNumber("m");
1586
+ case 'm':
1587
+ month = getNumber('m');
1546
1588
  break;
1547
- case "M":
1548
- month = getName("M", this.$primevue.config.locale.monthNamesShort, this.$primevue.config.locale.monthNames);
1589
+ case 'M':
1590
+ month = getName('M', this.$primevue.config.locale.monthNamesShort, this.$primevue.config.locale.monthNames);
1549
1591
  break;
1550
- case "y":
1551
- year = getNumber("y");
1592
+ case 'y':
1593
+ year = getNumber('y');
1552
1594
  break;
1553
- case "@":
1554
- date = new Date(getNumber("@"));
1595
+ case '@':
1596
+ date = new Date(getNumber('@'));
1555
1597
  year = date.getFullYear();
1556
1598
  month = date.getMonth() + 1;
1557
1599
  day = date.getDate();
1558
1600
  break;
1559
- case "!":
1560
- date = new Date((getNumber("!") - this.ticksTo1970) / 10000);
1601
+ case '!':
1602
+ date = new Date((getNumber('!') - this.ticksTo1970) / 10000);
1561
1603
  year = date.getFullYear();
1562
1604
  month = date.getMonth() + 1;
1563
1605
  day = date.getDate();
@@ -1568,6 +1610,7 @@ var script = {
1568
1610
  } else {
1569
1611
  literal = true;
1570
1612
  }
1613
+
1571
1614
  break;
1572
1615
  default:
1573
1616
  checkLiteral();
@@ -1577,47 +1620,53 @@ var script = {
1577
1620
 
1578
1621
  if (iValue < value.length) {
1579
1622
  extra = value.substr(iValue);
1623
+
1580
1624
  if (!/^\s+/.test(extra)) {
1581
- throw "Extra/unparsed characters found in date: " + extra;
1625
+ throw 'Extra/unparsed characters found in date: ' + extra;
1582
1626
  }
1583
1627
  }
1584
1628
 
1585
1629
  if (year === -1) {
1586
1630
  year = new Date().getFullYear();
1587
1631
  } else if (year < 100) {
1588
- year += new Date().getFullYear() - new Date().getFullYear() % 100 +
1589
- (year <= shortYearCutoff ? 0 : -100);
1632
+ year += new Date().getFullYear() - (new Date().getFullYear() % 100) + (year <= shortYearCutoff ? 0 : -100);
1590
1633
  }
1591
1634
 
1592
1635
  if (doy > -1) {
1593
1636
  month = 1;
1594
1637
  day = doy;
1638
+
1595
1639
  do {
1596
1640
  dim = this.getDaysCountInMonth(year, month - 1);
1641
+
1597
1642
  if (day <= dim) {
1598
1643
  break;
1599
1644
  }
1645
+
1600
1646
  month++;
1601
1647
  day -= dim;
1602
- // eslint-disable-next-line
1648
+ // eslint-disable-next-line
1603
1649
  } while (true);
1604
1650
  }
1605
1651
 
1606
1652
  date = this.daylightSavingAdjust(new Date(year, month - 1, day));
1607
1653
 
1608
1654
  if (date.getFullYear() !== year || date.getMonth() + 1 !== month || date.getDate() !== day) {
1609
- throw "Invalid date"; // E.g. 31/02/00
1655
+ throw 'Invalid date'; // E.g. 31/02/00
1610
1656
  }
1611
1657
 
1612
1658
  return date;
1613
1659
  },
1614
1660
  getWeekNumber(date) {
1615
1661
  let checkDate = new Date(date.getTime());
1616
- checkDate.setDate(checkDate.getDate() + 4 - ( checkDate.getDay() || 7 ));
1662
+
1663
+ checkDate.setDate(checkDate.getDate() + 4 - (checkDate.getDay() || 7));
1617
1664
  let time = checkDate.getTime();
1618
- checkDate.setMonth( 0 );
1619
- checkDate.setDate( 1 );
1620
- return Math.floor( Math.round((time - checkDate.getTime()) / 86400000 ) / 7 ) + 1;
1665
+
1666
+ checkDate.setMonth(0);
1667
+ checkDate.setDate(1);
1668
+
1669
+ return Math.floor(Math.round((time - checkDate.getTime()) / 86400000) / 7) + 1;
1621
1670
  },
1622
1671
  onDateCellKeydown(event, date, groupIndex) {
1623
1672
  const cellContent = event.currentTarget;
@@ -1628,21 +1677,22 @@ var script = {
1628
1677
  cellContent.tabIndex = '-1';
1629
1678
  let cellIndex = DomHandler.index(cell);
1630
1679
  let nextRow = cell.parentElement.nextElementSibling;
1680
+
1631
1681
  if (nextRow) {
1632
1682
  let focusCell = nextRow.children[cellIndex].children[0];
1683
+
1633
1684
  if (DomHandler.hasClass(focusCell, 'p-disabled')) {
1634
- this.navigationState = {backward: false};
1685
+ this.navigationState = { backward: false };
1635
1686
  this.navForward(event);
1636
- }
1637
- else {
1687
+ } else {
1638
1688
  nextRow.children[cellIndex].children[0].tabIndex = '0';
1639
1689
  nextRow.children[cellIndex].children[0].focus();
1640
1690
  }
1641
- }
1642
- else {
1643
- this.navigationState = {backward: false};
1691
+ } else {
1692
+ this.navigationState = { backward: false };
1644
1693
  this.navForward(event);
1645
1694
  }
1695
+
1646
1696
  event.preventDefault();
1647
1697
  break;
1648
1698
  }
@@ -1651,21 +1701,22 @@ var script = {
1651
1701
  cellContent.tabIndex = '-1';
1652
1702
  let cellIndex = DomHandler.index(cell);
1653
1703
  let prevRow = cell.parentElement.previousElementSibling;
1704
+
1654
1705
  if (prevRow) {
1655
1706
  let focusCell = prevRow.children[cellIndex].children[0];
1707
+
1656
1708
  if (DomHandler.hasClass(focusCell, 'p-disabled')) {
1657
- this.navigationState = {backward: true};
1709
+ this.navigationState = { backward: true };
1658
1710
  this.navBackward(event);
1659
- }
1660
- else {
1711
+ } else {
1661
1712
  focusCell.tabIndex = '0';
1662
1713
  focusCell.focus();
1663
1714
  }
1664
- }
1665
- else {
1666
- this.navigationState = {backward: true};
1715
+ } else {
1716
+ this.navigationState = { backward: true };
1667
1717
  this.navBackward(event);
1668
1718
  }
1719
+
1669
1720
  event.preventDefault();
1670
1721
  break;
1671
1722
  }
@@ -1673,19 +1724,20 @@ var script = {
1673
1724
  case 'ArrowLeft': {
1674
1725
  cellContent.tabIndex = '-1';
1675
1726
  let prevCell = cell.previousElementSibling;
1727
+
1676
1728
  if (prevCell) {
1677
1729
  let focusCell = prevCell.children[0];
1730
+
1678
1731
  if (DomHandler.hasClass(focusCell, 'p-disabled')) {
1679
1732
  this.navigateToMonth(event, true, groupIndex);
1680
- }
1681
- else {
1733
+ } else {
1682
1734
  focusCell.tabIndex = '0';
1683
1735
  focusCell.focus();
1684
1736
  }
1685
- }
1686
- else {
1737
+ } else {
1687
1738
  this.navigateToMonth(event, true, groupIndex);
1688
1739
  }
1740
+
1689
1741
  event.preventDefault();
1690
1742
  break;
1691
1743
  }
@@ -1693,24 +1745,26 @@ var script = {
1693
1745
  case 'ArrowRight': {
1694
1746
  cellContent.tabIndex = '-1';
1695
1747
  let nextCell = cell.nextElementSibling;
1748
+
1696
1749
  if (nextCell) {
1697
1750
  let focusCell = nextCell.children[0];
1751
+
1698
1752
  if (DomHandler.hasClass(focusCell, 'p-disabled')) {
1699
1753
  this.navigateToMonth(event, false, groupIndex);
1700
- }
1701
- else {
1754
+ } else {
1702
1755
  focusCell.tabIndex = '0';
1703
1756
  focusCell.focus();
1704
1757
  }
1705
- }
1706
- else {
1758
+ } else {
1707
1759
  this.navigateToMonth(event, false, groupIndex);
1708
1760
  }
1761
+
1709
1762
  event.preventDefault();
1710
1763
  break;
1711
1764
  }
1712
1765
 
1713
1766
  case 'Enter':
1767
+
1714
1768
  case 'Space': {
1715
1769
  this.onDateSelect(event, date);
1716
1770
  event.preventDefault();
@@ -1727,6 +1781,7 @@ var script = {
1727
1781
  if (!this.inline) {
1728
1782
  this.trapFocus(event);
1729
1783
  }
1784
+
1730
1785
  break;
1731
1786
  }
1732
1787
 
@@ -1734,10 +1789,10 @@ var script = {
1734
1789
  cellContent.tabIndex = '-1';
1735
1790
  let currentRow = cell.parentElement;
1736
1791
  let focusCell = currentRow.children[0].children[0];
1792
+
1737
1793
  if (DomHandler.hasClass(focusCell, 'p-disabled')) {
1738
1794
  this.navigateToMonth(event, true, groupIndex);
1739
- }
1740
- else {
1795
+ } else {
1741
1796
  focusCell.tabIndex = '0';
1742
1797
  focusCell.focus();
1743
1798
  }
@@ -1749,11 +1804,11 @@ var script = {
1749
1804
  case 'End': {
1750
1805
  cellContent.tabIndex = '-1';
1751
1806
  let currentRow = cell.parentElement;
1752
- let focusCell = currentRow.children[currentRow.children.length -1].children[0];
1807
+ let focusCell = currentRow.children[currentRow.children.length - 1].children[0];
1808
+
1753
1809
  if (DomHandler.hasClass(focusCell, 'p-disabled')) {
1754
1810
  this.navigateToMonth(event, false, groupIndex);
1755
- }
1756
- else {
1811
+ } else {
1757
1812
  focusCell.tabIndex = '0';
1758
1813
  focusCell.focus();
1759
1814
  }
@@ -1765,10 +1820,9 @@ var script = {
1765
1820
  case 'PageUp': {
1766
1821
  cellContent.tabIndex = '-1';
1767
1822
  if (event.shiftKey) {
1768
- this.navigationState = {backward: true};
1823
+ this.navigationState = { backward: true };
1769
1824
  this.navBackward(event);
1770
- }
1771
- else this.navigateToMonth(event, true, groupIndex);
1825
+ } else this.navigateToMonth(event, true, groupIndex);
1772
1826
 
1773
1827
  event.preventDefault();
1774
1828
  break;
@@ -1777,10 +1831,9 @@ var script = {
1777
1831
  case 'PageDown': {
1778
1832
  cellContent.tabIndex = '-1';
1779
1833
  if (event.shiftKey) {
1780
- this.navigationState = {backward: false};
1834
+ this.navigationState = { backward: false };
1781
1835
  this.navForward(event);
1782
- }
1783
- else this.navigateToMonth(event, false, groupIndex);
1836
+ } else this.navigateToMonth(event, false, groupIndex);
1784
1837
 
1785
1838
  event.preventDefault();
1786
1839
  break;
@@ -1789,26 +1842,25 @@ var script = {
1789
1842
  },
1790
1843
  navigateToMonth(event, prev, groupIndex) {
1791
1844
  if (prev) {
1792
- if (this.numberOfMonths === 1 || (groupIndex === 0)) {
1793
- this.navigationState = {backward: true};
1845
+ if (this.numberOfMonths === 1 || groupIndex === 0) {
1846
+ this.navigationState = { backward: true };
1794
1847
  this.navBackward(event);
1795
- }
1796
- else {
1848
+ } else {
1797
1849
  let prevMonthContainer = this.overlay.children[groupIndex - 1];
1798
1850
  let cells = DomHandler.find(prevMonthContainer, '.p-datepicker-calendar td span:not(.p-disabled):not(.p-ink)');
1799
1851
  let focusCell = cells[cells.length - 1];
1852
+
1800
1853
  focusCell.tabIndex = '0';
1801
1854
  focusCell.focus();
1802
1855
  }
1803
- }
1804
- else {
1805
- if (this.numberOfMonths === 1 || (groupIndex === this.numberOfMonths - 1)) {
1806
- this.navigationState = {backward: false};
1856
+ } else {
1857
+ if (this.numberOfMonths === 1 || groupIndex === this.numberOfMonths - 1) {
1858
+ this.navigationState = { backward: false };
1807
1859
  this.navForward(event);
1808
- }
1809
- else {
1860
+ } else {
1810
1861
  let nextMonthContainer = this.overlay.children[groupIndex + 1];
1811
1862
  let focusCell = DomHandler.findSingle(nextMonthContainer, '.p-datepicker-calendar td span:not(.p-disabled):not(.p-ink)');
1863
+
1812
1864
  focusCell.tabIndex = '0';
1813
1865
  focusCell.focus();
1814
1866
  }
@@ -1819,15 +1871,18 @@ var script = {
1819
1871
 
1820
1872
  switch (event.code) {
1821
1873
  case 'ArrowUp':
1874
+
1822
1875
  case 'ArrowDown': {
1823
1876
  cell.tabIndex = '-1';
1824
1877
  var cells = cell.parentElement.children;
1825
1878
  var cellIndex = DomHandler.index(cell);
1826
- let nextCell = cells[event.code === 'ArrowDown' ? cellIndex + 3 : cellIndex -3];
1879
+ let nextCell = cells[event.code === 'ArrowDown' ? cellIndex + 3 : cellIndex - 3];
1880
+
1827
1881
  if (nextCell) {
1828
1882
  nextCell.tabIndex = '0';
1829
1883
  nextCell.focus();
1830
1884
  }
1885
+
1831
1886
  event.preventDefault();
1832
1887
  break;
1833
1888
  }
@@ -1835,14 +1890,15 @@ var script = {
1835
1890
  case 'ArrowLeft': {
1836
1891
  cell.tabIndex = '-1';
1837
1892
  let prevCell = cell.previousElementSibling;
1893
+
1838
1894
  if (prevCell) {
1839
1895
  prevCell.tabIndex = '0';
1840
1896
  prevCell.focus();
1841
- }
1842
- else {
1843
- this.navigationState = {backward: true};
1897
+ } else {
1898
+ this.navigationState = { backward: true };
1844
1899
  this.navBackward(event);
1845
1900
  }
1901
+
1846
1902
  event.preventDefault();
1847
1903
  break;
1848
1904
  }
@@ -1850,21 +1906,22 @@ var script = {
1850
1906
  case 'ArrowRight': {
1851
1907
  cell.tabIndex = '-1';
1852
1908
  let nextCell = cell.nextElementSibling;
1909
+
1853
1910
  if (nextCell) {
1854
1911
  nextCell.tabIndex = '0';
1855
1912
  nextCell.focus();
1856
- }
1857
- else {
1858
- this.navigationState = {backward: false};
1913
+ } else {
1914
+ this.navigationState = { backward: false };
1859
1915
  this.navForward(event);
1860
1916
  }
1917
+
1861
1918
  event.preventDefault();
1862
1919
  break;
1863
1920
  }
1864
1921
 
1865
1922
  case 'PageUp': {
1866
1923
  if (event.shiftKey) return;
1867
- this.navigationState = {backward: true};
1924
+ this.navigationState = { backward: true };
1868
1925
  this.navBackward(event);
1869
1926
 
1870
1927
  break;
@@ -1872,13 +1929,14 @@ var script = {
1872
1929
 
1873
1930
  case 'PageDown': {
1874
1931
  if (event.shiftKey) return;
1875
- this.navigationState = {backward: false};
1932
+ this.navigationState = { backward: false };
1876
1933
  this.navForward(event);
1877
1934
 
1878
1935
  break;
1879
1936
  }
1880
1937
 
1881
1938
  case 'Enter':
1939
+
1882
1940
  case 'Space': {
1883
1941
  this.onMonthSelect(event, index);
1884
1942
  event.preventDefault();
@@ -1902,15 +1960,18 @@ var script = {
1902
1960
 
1903
1961
  switch (event.code) {
1904
1962
  case 'ArrowUp':
1905
- case 'ArrowDown': {
1963
+
1964
+ case 'ArrowDown': {
1906
1965
  cell.tabIndex = '-1';
1907
1966
  var cells = cell.parentElement.children;
1908
1967
  var cellIndex = DomHandler.index(cell);
1909
1968
  let nextCell = cells[event.code === 'ArrowDown' ? cellIndex + 2 : cellIndex - 2];
1969
+
1910
1970
  if (nextCell) {
1911
1971
  nextCell.tabIndex = '0';
1912
1972
  nextCell.focus();
1913
1973
  }
1974
+
1914
1975
  event.preventDefault();
1915
1976
  break;
1916
1977
  }
@@ -1918,14 +1979,15 @@ var script = {
1918
1979
  case 'ArrowLeft': {
1919
1980
  cell.tabIndex = '-1';
1920
1981
  let prevCell = cell.previousElementSibling;
1982
+
1921
1983
  if (prevCell) {
1922
1984
  prevCell.tabIndex = '0';
1923
1985
  prevCell.focus();
1924
- }
1925
- else {
1926
- this.navigationState = {backward: true};
1986
+ } else {
1987
+ this.navigationState = { backward: true };
1927
1988
  this.navBackward(event);
1928
1989
  }
1990
+
1929
1991
  event.preventDefault();
1930
1992
  break;
1931
1993
  }
@@ -1933,21 +1995,22 @@ var script = {
1933
1995
  case 'ArrowRight': {
1934
1996
  cell.tabIndex = '-1';
1935
1997
  let nextCell = cell.nextElementSibling;
1998
+
1936
1999
  if (nextCell) {
1937
2000
  nextCell.tabIndex = '0';
1938
2001
  nextCell.focus();
1939
- }
1940
- else {
1941
- this.navigationState = {backward: false};
2002
+ } else {
2003
+ this.navigationState = { backward: false };
1942
2004
  this.navForward(event);
1943
2005
  }
2006
+
1944
2007
  event.preventDefault();
1945
2008
  break;
1946
2009
  }
1947
2010
 
1948
2011
  case 'PageUp': {
1949
2012
  if (event.shiftKey) return;
1950
- this.navigationState = {backward: true};
2013
+ this.navigationState = { backward: true };
1951
2014
  this.navBackward(event);
1952
2015
 
1953
2016
  break;
@@ -1955,13 +2018,14 @@ var script = {
1955
2018
 
1956
2019
  case 'PageDown': {
1957
2020
  if (event.shiftKey) return;
1958
- this.navigationState = {backward: false};
2021
+ this.navigationState = { backward: false };
1959
2022
  this.navForward(event);
1960
2023
 
1961
2024
  break;
1962
2025
  }
1963
2026
 
1964
2027
  case 'Enter':
2028
+
1965
2029
  case 'Space': {
1966
2030
  this.onYearSelect(event, index);
1967
2031
  event.preventDefault();
@@ -1987,37 +2051,29 @@ var script = {
1987
2051
  if (this.navigationState.button) {
1988
2052
  this.initFocusableCell();
1989
2053
 
1990
- if (this.navigationState.backward)
1991
- DomHandler.findSingle(this.overlay, '.p-datepicker-prev').focus();
1992
- else
1993
- DomHandler.findSingle(this.overlay, '.p-datepicker-next').focus();
1994
- }
1995
- else {
2054
+ if (this.navigationState.backward) DomHandler.findSingle(this.overlay, '.p-datepicker-prev').focus();
2055
+ else DomHandler.findSingle(this.overlay, '.p-datepicker-next').focus();
2056
+ } else {
1996
2057
  if (this.navigationState.backward) {
1997
2058
  let cells;
1998
2059
 
1999
2060
  if (this.currentView === 'month') {
2000
2061
  cells = DomHandler.find(this.overlay, '.p-monthpicker .p-monthpicker-month:not(.p-disabled)');
2001
- }
2002
- else if (this.currentView === 'year') {
2062
+ } else if (this.currentView === 'year') {
2003
2063
  cells = DomHandler.find(this.overlay, '.p-yearpicker .p-yearpicker-year:not(.p-disabled)');
2004
- }
2005
- else {
2064
+ } else {
2006
2065
  cells = DomHandler.find(this.overlay, '.p-datepicker-calendar td span:not(.p-disabled):not(.p-ink)');
2007
2066
  }
2008
2067
 
2009
2068
  if (cells && cells.length > 0) {
2010
2069
  cell = cells[cells.length - 1];
2011
2070
  }
2012
- }
2013
- else {
2071
+ } else {
2014
2072
  if (this.currentView === 'month') {
2015
2073
  cell = DomHandler.findSingle(this.overlay, '.p-monthpicker .p-monthpicker-month:not(.p-disabled)');
2016
- }
2017
- else if (this.currentView === 'year') {
2074
+ } else if (this.currentView === 'year') {
2018
2075
  cell = DomHandler.findSingle(this.overlay, '.p-yearpicker .p-yearpicker-year:not(.p-disabled)');
2019
- }
2020
- else {
2076
+ } else {
2021
2077
  cell = DomHandler.findSingle(this.overlay, '.p-datepicker-calendar td span:not(.p-disabled):not(.p-ink)');
2022
2078
  }
2023
2079
  }
@@ -2029,8 +2085,7 @@ var script = {
2029
2085
  }
2030
2086
 
2031
2087
  this.navigationState = null;
2032
- }
2033
- else {
2088
+ } else {
2034
2089
  this.initFocusableCell();
2035
2090
  }
2036
2091
  },
@@ -2039,24 +2094,24 @@ var script = {
2039
2094
 
2040
2095
  if (this.currentView === 'month') {
2041
2096
  let cells = DomHandler.find(this.overlay, '.p-monthpicker .p-monthpicker-month');
2042
- let selectedCell= DomHandler.findSingle(this.overlay, '.p-monthpicker .p-monthpicker-month.p-highlight');
2043
- cells.forEach(cell => cell.tabIndex = -1);
2097
+ let selectedCell = DomHandler.findSingle(this.overlay, '.p-monthpicker .p-monthpicker-month.p-highlight');
2098
+
2099
+ cells.forEach((cell) => (cell.tabIndex = -1));
2044
2100
  cell = selectedCell || cells[0];
2045
- }
2046
- else if (this.currentView === 'year') {
2101
+ } else if (this.currentView === 'year') {
2047
2102
  let cells = DomHandler.find(this.overlay, '.p-yearpicker .p-yearpicker-year');
2048
- let selectedCell= DomHandler.findSingle(this.overlay, '.p-yearpicker .p-yearpicker-year.p-highlight');
2049
- cells.forEach(cell => cell.tabIndex = -1);
2103
+ let selectedCell = DomHandler.findSingle(this.overlay, '.p-yearpicker .p-yearpicker-year.p-highlight');
2104
+
2105
+ cells.forEach((cell) => (cell.tabIndex = -1));
2050
2106
  cell = selectedCell || cells[0];
2051
- }
2052
- else {
2107
+ } else {
2053
2108
  cell = DomHandler.findSingle(this.overlay, 'span.p-highlight');
2109
+
2054
2110
  if (!cell) {
2055
2111
  let todayCell = DomHandler.findSingle(this.overlay, 'td.p-datepicker-today span:not(.p-disabled):not(.p-ink');
2056
- if (todayCell)
2057
- cell = todayCell;
2058
- else
2059
- cell = DomHandler.findSingle(this.overlay, '.p-datepicker-calendar td span:not(.p-disabled):not(.p-ink');
2112
+
2113
+ if (todayCell) cell = todayCell;
2114
+ else cell = DomHandler.findSingle(this.overlay, '.p-datepicker-calendar td span:not(.p-disabled):not(.p-ink');
2060
2115
  }
2061
2116
  }
2062
2117
 
@@ -2077,34 +2132,27 @@ var script = {
2077
2132
  if (focusableElements && focusableElements.length > 0) {
2078
2133
  if (!document.activeElement) {
2079
2134
  focusableElements[0].focus();
2080
- }
2081
- else {
2135
+ } else {
2082
2136
  let focusedIndex = focusableElements.indexOf(document.activeElement);
2083
2137
 
2084
2138
  if (event.shiftKey) {
2085
- if (focusedIndex === -1 || focusedIndex === 0)
2086
- focusableElements[focusableElements.length - 1].focus();
2087
- else
2088
- focusableElements[focusedIndex - 1].focus();
2089
- }
2090
- else {
2139
+ if (focusedIndex === -1 || focusedIndex === 0) focusableElements[focusableElements.length - 1].focus();
2140
+ else focusableElements[focusedIndex - 1].focus();
2141
+ } else {
2091
2142
  if (focusedIndex === -1) {
2092
2143
  if (this.timeOnly) {
2093
2144
  focusableElements[0].focus();
2094
- }
2095
- else {
2145
+ } else {
2096
2146
  let spanIndex = null;
2097
- for (let i = 0; i < focusableElements.length; i++){
2098
- if (focusableElements[i].tagName === 'SPAN')
2099
- spanIndex = i;
2147
+
2148
+ for (let i = 0; i < focusableElements.length; i++) {
2149
+ if (focusableElements[i].tagName === 'SPAN') spanIndex = i;
2100
2150
  }
2151
+
2101
2152
  focusableElements[spanIndex].focus();
2102
2153
  }
2103
- }
2104
- else if (focusedIndex === (focusableElements.length - 1))
2105
- focusableElements[0].focus();
2106
- else
2107
- focusableElements[focusedIndex + 1].focus();
2154
+ } else if (focusedIndex === focusableElements.length - 1) focusableElements[0].focus();
2155
+ else focusableElements[focusedIndex + 1].focus();
2108
2156
  }
2109
2157
  }
2110
2158
  }
@@ -2113,12 +2161,12 @@ var script = {
2113
2161
  switch (event.code) {
2114
2162
  case 'Tab':
2115
2163
  this.trapFocus(event);
2116
- break;
2164
+ break;
2117
2165
 
2118
2166
  case 'Escape':
2119
2167
  this.overlayVisible = false;
2120
2168
  event.preventDefault();
2121
- break;
2169
+ break;
2122
2170
  }
2123
2171
 
2124
2172
  this.$emit('keydown', event);
@@ -2129,12 +2177,12 @@ var script = {
2129
2177
  this.selectionEnd = this.input.selectionEnd;
2130
2178
 
2131
2179
  let value = this.parseValue(event.target.value);
2180
+
2132
2181
  if (this.isValidSelection(value)) {
2133
2182
  this.typeUpdate = true;
2134
2183
  this.updateModel(value);
2135
2184
  }
2136
- }
2137
- catch(err) {
2185
+ } catch (err) {
2138
2186
  /* NoOp */
2139
2187
  }
2140
2188
 
@@ -2144,11 +2192,12 @@ var script = {
2144
2192
  if (this.showOnFocus && this.isEnabled()) {
2145
2193
  this.overlayVisible = true;
2146
2194
  }
2195
+
2147
2196
  this.focused = true;
2148
2197
  this.$emit('focus', event);
2149
2198
  },
2150
2199
  onBlur(event) {
2151
- this.$emit('blur', {originalEvent: event, value: event.target.value});
2200
+ this.$emit('blur', { originalEvent: event, value: event.target.value });
2152
2201
 
2153
2202
  this.focused = false;
2154
2203
  event.target.value = this.formatValue(this.modelValue);
@@ -2156,19 +2205,16 @@ var script = {
2156
2205
  onKeyDown(event) {
2157
2206
  if (event.code === 'ArrowDown' && this.overlay) {
2158
2207
  this.trapFocus(event);
2159
- }
2160
- else if (event.code === 'ArrowDown' && !this.overlay) {
2208
+ } else if (event.code === 'ArrowDown' && !this.overlay) {
2161
2209
  this.overlayVisible = true;
2162
- }
2163
- else if (event.code === 'Escape') {
2210
+ } else if (event.code === 'Escape') {
2164
2211
  if (this.overlayVisible) {
2165
2212
  this.overlayVisible = false;
2166
2213
  event.preventDefault();
2167
2214
  }
2168
- }
2169
- else if (event.code === 'Tab') {
2215
+ } else if (event.code === 'Tab') {
2170
2216
  if (this.overlay) {
2171
- DomHandler.getFocusableElements(this.overlay).forEach(el => el.tabIndex = '-1');
2217
+ DomHandler.getFocusableElements(this.overlay).forEach((el) => (el.tabIndex = '-1'));
2172
2218
  }
2173
2219
 
2174
2220
  if (this.overlayVisible) {
@@ -2216,10 +2262,9 @@ var script = {
2216
2262
  }
2217
2263
 
2218
2264
  let innerHTML = '';
2265
+
2219
2266
  if (this.responsiveOptions) {
2220
- let responsiveOptions = [...this.responsiveOptions]
2221
- .filter(o => !!(o.breakpoint && o.numMonths))
2222
- .sort((o1, o2) => -1 * o1.breakpoint.localeCompare(o2.breakpoint, undefined, { numeric: true }));
2267
+ let responsiveOptions = [...this.responsiveOptions].filter((o) => !!(o.breakpoint && o.numMonths)).sort((o1, o2) => -1 * o1.breakpoint.localeCompare(o2.breakpoint, undefined, { numeric: true }));
2223
2268
 
2224
2269
  for (let i = 0; i < responsiveOptions.length; i++) {
2225
2270
  let { breakpoint, numMonths } = responsiveOptions[i];
@@ -2247,7 +2292,7 @@ var script = {
2247
2292
 
2248
2293
  this.responsiveStyleElement.innerHTML = innerHTML;
2249
2294
  }
2250
- },
2295
+ },
2251
2296
  destroyResponsiveStyleElement() {
2252
2297
  if (this.responsiveStyleElement) {
2253
2298
  this.responsiveStyleElement.remove();
@@ -2258,19 +2303,18 @@ var script = {
2258
2303
  computed: {
2259
2304
  viewDate() {
2260
2305
  let propValue = this.modelValue;
2306
+
2261
2307
  if (propValue && Array.isArray(propValue)) {
2262
2308
  if (this.isRangeSelection()) {
2263
2309
  propValue = propValue[1] || propValue[0];
2264
- }
2265
- else if (this.isMultipleSelection()) {
2310
+ } else if (this.isMultipleSelection()) {
2266
2311
  propValue = propValue[propValue.length - 1];
2267
2312
  }
2268
2313
  }
2269
2314
 
2270
2315
  if (propValue && typeof propValue !== 'string') {
2271
2316
  return propValue;
2272
- }
2273
- else {
2317
+ } else {
2274
2318
  let today = new Date();
2275
2319
 
2276
2320
  if (this.maxDate && this.maxDate < today) {
@@ -2300,25 +2344,31 @@ var script = {
2300
2344
  ];
2301
2345
  },
2302
2346
  panelStyleClass() {
2303
- return ['p-datepicker p-component', this.panelClass, {
2304
- 'p-datepicker-inline': this.inline,
2305
- 'p-disabled': this.disabled,
2306
- 'p-datepicker-timeonly': this.timeOnly,
2307
- 'p-datepicker-multiple-month': this.numberOfMonths > 1,
2308
- 'p-datepicker-monthpicker': (this.currentView === 'month'),
2309
- 'p-datepicker-yearpicker': (this.currentView === 'year'),
2310
- 'p-datepicker-touch-ui': this.touchUI,
2311
- 'p-input-filled': this.$primevue.config.inputStyle === 'filled',
2312
- 'p-ripple-disabled': this.$primevue.config.ripple === false
2313
- }];
2347
+ return [
2348
+ 'p-datepicker p-component',
2349
+ this.panelClass,
2350
+ {
2351
+ 'p-datepicker-inline': this.inline,
2352
+ 'p-disabled': this.disabled,
2353
+ 'p-datepicker-timeonly': this.timeOnly,
2354
+ 'p-datepicker-multiple-month': this.numberOfMonths > 1,
2355
+ 'p-datepicker-monthpicker': this.currentView === 'month',
2356
+ 'p-datepicker-yearpicker': this.currentView === 'year',
2357
+ 'p-datepicker-touch-ui': this.touchUI,
2358
+ 'p-input-filled': this.$primevue.config.inputStyle === 'filled',
2359
+ 'p-ripple-disabled': this.$primevue.config.ripple === false
2360
+ }
2361
+ ];
2314
2362
  },
2315
2363
  months() {
2316
2364
  let months = [];
2317
- for (let i = 0 ; i < this.numberOfMonths; i++) {
2365
+
2366
+ for (let i = 0; i < this.numberOfMonths; i++) {
2318
2367
  let month = this.currentMonth + i;
2319
2368
  let year = this.currentYear;
2369
+
2320
2370
  if (month > 11) {
2321
- month = month % 11 - 1;
2371
+ month = (month % 11) - 1;
2322
2372
  year = year + 1;
2323
2373
  }
2324
2374
 
@@ -2335,30 +2385,33 @@ var script = {
2335
2385
  let week = [];
2336
2386
 
2337
2387
  if (i == 0) {
2338
- for (let j = (prevMonthDaysLength - firstDay + 1); j <= prevMonthDaysLength; j++) {
2388
+ for (let j = prevMonthDaysLength - firstDay + 1; j <= prevMonthDaysLength; j++) {
2339
2389
  let prev = this.getPreviousMonthAndYear(month, year);
2340
- week.push({day: j, month: prev.month, year: prev.year, otherMonth: true,
2341
- today: this.isToday(today, j, prev.month, prev.year), selectable: this.isSelectable(j, prev.month, prev.year, true)});
2390
+
2391
+ week.push({ day: j, month: prev.month, year: prev.year, otherMonth: true, today: this.isToday(today, j, prev.month, prev.year), selectable: this.isSelectable(j, prev.month, prev.year, true) });
2342
2392
  }
2343
2393
 
2344
2394
  let remainingDaysLength = 7 - week.length;
2395
+
2345
2396
  for (let j = 0; j < remainingDaysLength; j++) {
2346
- week.push({day: dayNo, month: month, year: year, today: this.isToday(today, dayNo, month, year),
2347
- selectable: this.isSelectable(dayNo, month, year, false)});
2397
+ week.push({ day: dayNo, month: month, year: year, today: this.isToday(today, dayNo, month, year), selectable: this.isSelectable(dayNo, month, year, false) });
2348
2398
  dayNo++;
2349
2399
  }
2350
- }
2351
- else {
2400
+ } else {
2352
2401
  for (let j = 0; j < 7; j++) {
2353
2402
  if (dayNo > daysLength) {
2354
2403
  let next = this.getNextMonthAndYear(month, year);
2355
- week.push({day: dayNo - daysLength, month: next.month, year: next.year, otherMonth: true,
2356
- today: this.isToday(today, dayNo - daysLength, next.month, next.year),
2357
- selectable: this.isSelectable((dayNo - daysLength), next.month, next.year, true)});
2358
- }
2359
- else {
2360
- week.push({day: dayNo, month: month, year: year, today: this.isToday(today, dayNo, month, year),
2361
- selectable: this.isSelectable(dayNo, month, year, false)});
2404
+
2405
+ week.push({
2406
+ day: dayNo - daysLength,
2407
+ month: next.month,
2408
+ year: next.year,
2409
+ otherMonth: true,
2410
+ today: this.isToday(today, dayNo - daysLength, next.month, next.year),
2411
+ selectable: this.isSelectable(dayNo - daysLength, next.month, next.year, true)
2412
+ });
2413
+ } else {
2414
+ week.push({ day: dayNo, month: month, year: year, today: this.isToday(today, dayNo, month, year), selectable: this.isSelectable(dayNo, month, year, false) });
2362
2415
  }
2363
2416
 
2364
2417
  dayNo++;
@@ -2385,15 +2438,16 @@ var script = {
2385
2438
  weekDays() {
2386
2439
  let weekDays = [];
2387
2440
  let dayIndex = this.$primevue.config.locale.firstDayOfWeek;
2441
+
2388
2442
  for (let i = 0; i < 7; i++) {
2389
2443
  weekDays.push(this.$primevue.config.locale.dayNamesMin[dayIndex]);
2390
- dayIndex = (dayIndex == 6) ? 0 : ++dayIndex;
2444
+ dayIndex = dayIndex == 6 ? 0 : ++dayIndex;
2391
2445
  }
2392
2446
 
2393
2447
  return weekDays;
2394
2448
  },
2395
2449
  ticksTo1970() {
2396
- return (((1970 - 1) * 365 + Math.floor(1970 / 4) - Math.floor(1970 / 100) + Math.floor(1970 / 400)) * 24 * 60 * 60 * 10000000);
2450
+ return ((1970 - 1) * 365 + Math.floor(1970 / 4) - Math.floor(1970 / 100) + Math.floor(1970 / 400)) * 24 * 60 * 60 * 10000000;
2397
2451
  },
2398
2452
  sundayIndex() {
2399
2453
  return this.$primevue.config.locale.firstDayOfWeek > 0 ? 7 - this.$primevue.config.locale.firstDayOfWeek : 0;
@@ -2411,8 +2465,7 @@ var script = {
2411
2465
 
2412
2466
  if (this.currentYear < yearStart) {
2413
2467
  $vm.currentYear = yearEnd;
2414
- }
2415
- else if (this.currentYear > yearEnd) {
2468
+ } else if (this.currentYear > yearEnd) {
2416
2469
  $vm.currentYear = yearStart;
2417
2470
  }
2418
2471
 
@@ -2421,13 +2474,13 @@ var script = {
2421
2474
  }
2422
2475
 
2423
2476
  return yearOptions;
2424
- }
2425
- else {
2477
+ } else {
2426
2478
  return null;
2427
2479
  }
2428
2480
  },
2429
2481
  monthPickerValues() {
2430
2482
  let monthPickerValues = [];
2483
+
2431
2484
  for (let i = 0; i <= 11; i++) {
2432
2485
  monthPickerValues.push(this.$primevue.config.locale.monthNamesShort[i]);
2433
2486
  }
@@ -2436,7 +2489,8 @@ var script = {
2436
2489
  },
2437
2490
  yearPickerValues() {
2438
2491
  let yearPickerValues = [];
2439
- let base = this.currentYear - (this.currentYear % 10);
2492
+ let base = this.currentYear - (this.currentYear % 10);
2493
+
2440
2494
  for (let i = 0; i < 10; i++) {
2441
2495
  yearPickerValues.push(base + i);
2442
2496
  }
@@ -2475,16 +2529,16 @@ var script = {
2475
2529
  }
2476
2530
  },
2477
2531
  components: {
2478
- 'CalendarButton': Button,
2479
- 'Portal': Portal
2532
+ CalendarButton: Button,
2533
+ Portal: Portal
2480
2534
  },
2481
2535
  directives: {
2482
- 'ripple': Ripple
2536
+ ripple: Ripple
2483
2537
  }
2484
2538
  };
2485
2539
 
2486
2540
  const _hoisted_1 = ["id"];
2487
- const _hoisted_2 = ["id", "placeholder", "aria-expanded", "aria-controls", "aria-labelledby", "aria-label", "readonly"];
2541
+ const _hoisted_2 = ["id", "placeholder", "aria-expanded", "aria-controls", "aria-labelledby", "aria-label", "disabled", "readonly"];
2488
2542
  const _hoisted_3 = ["id", "role", "aria-modal", "aria-label"];
2489
2543
  const _hoisted_4 = { class: "p-datepicker-group-container" };
2490
2544
  const _hoisted_5 = { class: "p-datepicker-header" };
@@ -2637,9 +2691,9 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
2637
2691
  ? (openBlock(), createElementBlock("input", mergeProps({
2638
2692
  key: 0,
2639
2693
  ref: $options.inputRef,
2694
+ id: $props.inputId,
2640
2695
  type: "text",
2641
2696
  role: "combobox",
2642
- id: $props.inputId,
2643
2697
  class: ['p-inputtext p-component', $props.inputClass],
2644
2698
  style: $props.inputStyle,
2645
2699
  placeholder: $props.placeholder,
@@ -2650,12 +2704,13 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
2650
2704
  "aria-labelledby": _ctx.ariaLabelledby,
2651
2705
  "aria-label": _ctx.ariaLabel,
2652
2706
  inputmode: "none",
2707
+ disabled: $props.disabled,
2708
+ readonly: !$props.manualInput,
2709
+ tabindex: 0,
2653
2710
  onInput: _cache[0] || (_cache[0] = (...args) => ($options.onInput && $options.onInput(...args))),
2654
2711
  onFocus: _cache[1] || (_cache[1] = (...args) => ($options.onFocus && $options.onFocus(...args))),
2655
2712
  onBlur: _cache[2] || (_cache[2] = (...args) => ($options.onBlur && $options.onBlur(...args))),
2656
- onKeydown: _cache[3] || (_cache[3] = (...args) => ($options.onKeyDown && $options.onKeyDown(...args))),
2657
- readonly: !$props.manualInput,
2658
- tabindex: 0
2713
+ onKeydown: _cache[3] || (_cache[3] = (...args) => ($options.onKeyDown && $options.onKeyDown(...args)))
2659
2714
  }, $props.inputProps), null, 16, _hoisted_2))
2660
2715
  : createCommentVNode("", true),
2661
2716
  ($props.showIcon)
@@ -2704,8 +2759,8 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
2704
2759
  createElementVNode("div", _hoisted_4, [
2705
2760
  (openBlock(true), createElementBlock(Fragment, null, renderList($options.months, (month, groupIndex) => {
2706
2761
  return (openBlock(), createElementBlock("div", {
2707
- class: "p-datepicker-group",
2708
- key: month.month + month.year
2762
+ key: month.month + month.year,
2763
+ class: "p-datepicker-group"
2709
2764
  }, [
2710
2765
  createElementVNode("div", _hoisted_5, [
2711
2766
  renderSlot(_ctx.$slots, "header"),
@@ -2715,7 +2770,7 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
2715
2770
  type: "button",
2716
2771
  onKeydown: _cache[5] || (_cache[5] = (...args) => ($options.onContainerButtonKeydown && $options.onContainerButtonKeydown(...args))),
2717
2772
  disabled: $props.disabled,
2718
- "aria-label": $data.currentView === 'year' ? _ctx.$primevue.config.locale.prevDecade: $data.currentView === 'month' ? _ctx.$primevue.config.locale.prevYear : _ctx.$primevue.config.locale.prevMonth
2773
+ "aria-label": $data.currentView === 'year' ? _ctx.$primevue.config.locale.prevDecade : $data.currentView === 'month' ? _ctx.$primevue.config.locale.prevYear : _ctx.$primevue.config.locale.prevMonth
2719
2774
  }, _hoisted_8, 40, _hoisted_6)), [
2720
2775
  [vShow, $props.showOtherMonths ? groupIndex === 0 : false],
2721
2776
  [_directive_ripple]
@@ -2757,13 +2812,13 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
2757
2812
  type: "button",
2758
2813
  onKeydown: _cache[11] || (_cache[11] = (...args) => ($options.onContainerButtonKeydown && $options.onContainerButtonKeydown(...args))),
2759
2814
  disabled: $props.disabled,
2760
- "aria-label": $data.currentView === 'year' ? _ctx.$primevue.config.locale.nextDecade : $data.currentView === 'month' ? _ctx.$primevue.config.locale.nextYear : _ctx.$primevue.config.locale.nextMonth
2815
+ "aria-label": $data.currentView === 'year' ? _ctx.$primevue.config.locale.nextDecade : $data.currentView === 'month' ? _ctx.$primevue.config.locale.nextYear : _ctx.$primevue.config.locale.nextMonth
2761
2816
  }, _hoisted_15, 40, _hoisted_13)), [
2762
- [vShow, $props.showOtherMonths ? $props.numberOfMonths === 1 ? true : (groupIndex === $props.numberOfMonths - 1) : false],
2817
+ [vShow, $props.showOtherMonths ? ($props.numberOfMonths === 1 ? true : groupIndex === $props.numberOfMonths - 1) : false],
2763
2818
  [_directive_ripple]
2764
2819
  ])
2765
2820
  ]),
2766
- ($data.currentView ==='date')
2821
+ ($data.currentView === 'date')
2767
2822
  ? (openBlock(), createElementBlock("div", _hoisted_16, [
2768
2823
  createElementVNode("table", _hoisted_17, [
2769
2824
  createElementVNode("thead", null, [
@@ -2775,8 +2830,8 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
2775
2830
  : createCommentVNode("", true),
2776
2831
  (openBlock(true), createElementBlock(Fragment, null, renderList($options.weekDays, (weekDay) => {
2777
2832
  return (openBlock(), createElementBlock("th", {
2778
- scope: "col",
2779
2833
  key: weekDay,
2834
+ scope: "col",
2780
2835
  abbr: weekDay
2781
2836
  }, [
2782
2837
  createElementVNode("span", null, toDisplayString(weekDay), 1)
@@ -2801,15 +2856,15 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
2801
2856
  : createCommentVNode("", true),
2802
2857
  (openBlock(true), createElementBlock(Fragment, null, renderList(week, (date) => {
2803
2858
  return (openBlock(), createElementBlock("td", {
2804
- "aria-label": date.day,
2805
2859
  key: date.day + '' + date.month,
2806
- class: normalizeClass({'p-datepicker-other-month': date.otherMonth, 'p-datepicker-today': date.today})
2860
+ "aria-label": date.day,
2861
+ class: normalizeClass({ 'p-datepicker-other-month': date.otherMonth, 'p-datepicker-today': date.today })
2807
2862
  }, [
2808
2863
  withDirectives((openBlock(), createElementBlock("span", {
2809
- class: normalizeClass({'p-highlight': $options.isSelected(date), 'p-disabled': !date.selectable}),
2864
+ class: normalizeClass({ 'p-highlight': $options.isSelected(date), 'p-disabled': !date.selectable }),
2810
2865
  onClick: $event => ($options.onDateSelect($event, date)),
2811
2866
  draggable: "false",
2812
- onKeydown: $event => ($options.onDateCellKeydown($event,date,groupIndex)),
2867
+ onKeydown: $event => ($options.onDateCellKeydown($event, date, groupIndex)),
2813
2868
  "aria-selected": $options.isSelected(date)
2814
2869
  }, [
2815
2870
  renderSlot(_ctx.$slots, "date", { date: date }, () => [
@@ -2838,8 +2893,8 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
2838
2893
  return withDirectives((openBlock(), createElementBlock("span", {
2839
2894
  key: m,
2840
2895
  onClick: $event => ($options.onMonthSelect($event, i)),
2841
- onKeydown: $event => ($options.onMonthCellKeydown($event,i)),
2842
- class: normalizeClass(["p-monthpicker-month", {'p-highlight': $options.isMonthSelected(i)}])
2896
+ onKeydown: $event => ($options.onMonthCellKeydown($event, i)),
2897
+ class: normalizeClass(["p-monthpicker-month", { 'p-highlight': $options.isMonthSelected(i) }])
2843
2898
  }, [
2844
2899
  createTextVNode(toDisplayString(m) + " ", 1),
2845
2900
  ($options.isMonthSelected(i))
@@ -2857,8 +2912,8 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
2857
2912
  return withDirectives((openBlock(), createElementBlock("span", {
2858
2913
  key: y,
2859
2914
  onClick: $event => ($options.onYearSelect($event, y)),
2860
- onKeydown: $event => ($options.onYearCellKeydown($event,y)),
2861
- class: normalizeClass(["p-yearpicker-year", {'p-highlight': $options.isYearSelected(y)}])
2915
+ onKeydown: $event => ($options.onYearCellKeydown($event, y)),
2916
+ class: normalizeClass(["p-yearpicker-year", { 'p-highlight': $options.isYearSelected(y) }])
2862
2917
  }, [
2863
2918
  createTextVNode(toDisplayString(y) + " ", 1),
2864
2919
  ($options.isYearSelected(y))
@@ -2872,7 +2927,7 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
2872
2927
  : createCommentVNode("", true)
2873
2928
  ], 64))
2874
2929
  : createCommentVNode("", true),
2875
- (($props.showTime||$props.timeOnly) && $data.currentView === 'date')
2930
+ (($props.showTime || $props.timeOnly) && $data.currentView === 'date')
2876
2931
  ? (openBlock(), createElementBlock("div", _hoisted_32, [
2877
2932
  createElementVNode("div", _hoisted_33, [
2878
2933
  withDirectives((openBlock(), createElementBlock("button", {
@@ -3011,12 +3066,12 @@ function render(_ctx, _cache, $props, $setup, $data, $options) {
3011
3066
  ])
3012
3067
  ]))
3013
3068
  : createCommentVNode("", true),
3014
- ($props.hourFormat=='12')
3069
+ ($props.hourFormat == '12')
3015
3070
  ? (openBlock(), createElementBlock("div", _hoisted_56, [
3016
3071
  createElementVNode("span", null, toDisplayString($props.timeSeparator), 1)
3017
3072
  ]))
3018
3073
  : createCommentVNode("", true),
3019
- ($props.hourFormat=='12')
3074
+ ($props.hourFormat == '12')
3020
3075
  ? (openBlock(), createElementBlock("div", _hoisted_57, [
3021
3076
  withDirectives((openBlock(), createElementBlock("button", {
3022
3077
  class: "p-link",
@@ -3098,7 +3153,7 @@ function styleInject(css, ref) {
3098
3153
  }
3099
3154
  }
3100
3155
 
3101
- var css_248z = "\n.p-calendar {\n position: relative;\n display: -webkit-inline-box;\n display: -ms-inline-flexbox;\n display: inline-flex;\n max-width: 100%;\n}\n.p-calendar .p-inputtext {\n -webkit-box-flex: 1;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n width: 1%;\n}\n.p-calendar-w-btn .p-inputtext {\n border-top-right-radius: 0;\n border-bottom-right-radius: 0;\n}\n.p-calendar-w-btn .p-datepicker-trigger {\n border-top-left-radius: 0;\n border-bottom-left-radius: 0;\n}\n\n/* Fluid */\n.p-fluid .p-calendar {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n}\n.p-fluid .p-calendar .p-inputtext {\n width: 1%;\n}\n\n/* Datepicker */\n.p-calendar .p-datepicker {\n min-width: 100%;\n}\n.p-datepicker {\n\twidth: auto;\n position: absolute;\n top: 0;\n left: 0;\n}\n.p-datepicker-inline {\n display: inline-block;\n position: static;\n overflow-x: auto;\n}\n\n/* Header */\n.p-datepicker-header {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: justify;\n -ms-flex-pack: justify;\n justify-content: space-between;\n}\n.p-datepicker-header .p-datepicker-title {\n margin: 0 auto;\n}\n.p-datepicker-prev,\n.p-datepicker-next {\n cursor: pointer;\n display: -webkit-inline-box;\n display: -ms-inline-flexbox;\n display: inline-flex;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n overflow: hidden;\n position: relative;\n}\n\n/* Multiple Month DatePicker */\n.p-datepicker-multiple-month .p-datepicker-group-container {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n}\n.p-datepicker-multiple-month .p-datepicker-group-container .p-datepicker-group {\n -webkit-box-flex: 1;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n}\n\n/* DatePicker Table */\n.p-datepicker table {\n\twidth: 100%;\n\tborder-collapse: collapse;\n}\n.p-datepicker td > span {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n cursor: pointer;\n margin: 0 auto;\n overflow: hidden;\n position: relative;\n}\n\n/* Month Picker */\n.p-monthpicker-month {\n width: 33.3%;\n display: -webkit-inline-box;\n display: -ms-inline-flexbox;\n display: inline-flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n cursor: pointer;\n overflow: hidden;\n position: relative;\n}\n\n/* Year Picker */\n.p-yearpicker-year {\n width: 50%;\n display: -webkit-inline-box;\n display: -ms-inline-flexbox;\n display: inline-flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n cursor: pointer;\n overflow: hidden;\n position: relative;\n}\n\n/* Button Bar */\n.p-datepicker-buttonbar {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: justify;\n -ms-flex-pack: justify;\n justify-content: space-between;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n/* Time Picker */\n.p-timepicker {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n}\n.p-timepicker button {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n cursor: pointer;\n overflow: hidden;\n position: relative;\n}\n.p-timepicker > div {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n\n/* Touch UI */\n.p-datepicker-touch-ui,\n.p-calendar .p-datepicker-touch-ui {\n position: fixed;\n top: 50%;\n left: 50%;\n min-width: 80vw;\n -webkit-transform: translate(-50%, -50%);\n transform: translate(-50%, -50%);\n}\n";
3156
+ var css_248z = "\n.p-calendar {\n position: relative;\n display: -webkit-inline-box;\n display: -ms-inline-flexbox;\n display: inline-flex;\n max-width: 100%;\n}\n.p-calendar .p-inputtext {\n -webkit-box-flex: 1;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n width: 1%;\n}\n.p-calendar-w-btn .p-inputtext {\n border-top-right-radius: 0;\n border-bottom-right-radius: 0;\n}\n.p-calendar-w-btn .p-datepicker-trigger {\n border-top-left-radius: 0;\n border-bottom-left-radius: 0;\n}\n\n/* Fluid */\n.p-fluid .p-calendar {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n}\n.p-fluid .p-calendar .p-inputtext {\n width: 1%;\n}\n\n/* Datepicker */\n.p-calendar .p-datepicker {\n min-width: 100%;\n}\n.p-datepicker {\n width: auto;\n position: absolute;\n top: 0;\n left: 0;\n}\n.p-datepicker-inline {\n display: inline-block;\n position: static;\n overflow-x: auto;\n}\n\n/* Header */\n.p-datepicker-header {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: justify;\n -ms-flex-pack: justify;\n justify-content: space-between;\n}\n.p-datepicker-header .p-datepicker-title {\n margin: 0 auto;\n}\n.p-datepicker-prev,\n.p-datepicker-next {\n cursor: pointer;\n display: -webkit-inline-box;\n display: -ms-inline-flexbox;\n display: inline-flex;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n overflow: hidden;\n position: relative;\n}\n\n/* Multiple Month DatePicker */\n.p-datepicker-multiple-month .p-datepicker-group-container {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n}\n.p-datepicker-multiple-month .p-datepicker-group-container .p-datepicker-group {\n -webkit-box-flex: 1;\n -ms-flex: 1 1 auto;\n flex: 1 1 auto;\n}\n\n/* DatePicker Table */\n.p-datepicker table {\n width: 100%;\n border-collapse: collapse;\n}\n.p-datepicker td > span {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n cursor: pointer;\n margin: 0 auto;\n overflow: hidden;\n position: relative;\n}\n\n/* Month Picker */\n.p-monthpicker-month {\n width: 33.3%;\n display: -webkit-inline-box;\n display: -ms-inline-flexbox;\n display: inline-flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n cursor: pointer;\n overflow: hidden;\n position: relative;\n}\n\n/* Year Picker */\n.p-yearpicker-year {\n width: 50%;\n display: -webkit-inline-box;\n display: -ms-inline-flexbox;\n display: inline-flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n cursor: pointer;\n overflow: hidden;\n position: relative;\n}\n\n/* Button Bar */\n.p-datepicker-buttonbar {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: justify;\n -ms-flex-pack: justify;\n justify-content: space-between;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n}\n\n/* Time Picker */\n.p-timepicker {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n}\n.p-timepicker button {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n cursor: pointer;\n overflow: hidden;\n position: relative;\n}\n.p-timepicker > div {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n\n/* Touch UI */\n.p-datepicker-touch-ui,\n.p-calendar .p-datepicker-touch-ui {\n position: fixed;\n top: 50%;\n left: 50%;\n min-width: 80vw;\n -webkit-transform: translate(-50%, -50%);\n transform: translate(-50%, -50%);\n}\n";
3102
3157
  styleInject(css_248z);
3103
3158
 
3104
3159
  script.render = render;