primereact 9.4.0 → 9.6.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 (886) hide show
  1. package/accordion/accordion.cjs.js +2 -1
  2. package/accordion/accordion.cjs.min.js +1 -1
  3. package/accordion/accordion.esm.js +3 -2
  4. package/accordion/accordion.esm.min.js +1 -1
  5. package/accordion/accordion.js +2 -1
  6. package/accordion/accordion.min.js +1 -1
  7. package/api/api.cjs.js +215 -3
  8. package/api/api.cjs.min.js +1 -1
  9. package/api/api.d.ts +882 -8
  10. package/api/api.esm.js +210 -4
  11. package/api/api.esm.min.js +1 -1
  12. package/api/api.js +216 -5
  13. package/api/api.min.js +1 -1
  14. package/autocomplete/autocomplete.cjs.js +148 -89
  15. package/autocomplete/autocomplete.cjs.min.js +1 -1
  16. package/autocomplete/autocomplete.d.ts +138 -2
  17. package/autocomplete/autocomplete.esm.js +150 -91
  18. package/autocomplete/autocomplete.esm.min.js +1 -1
  19. package/autocomplete/autocomplete.js +149 -91
  20. package/autocomplete/autocomplete.min.css +1 -1
  21. package/autocomplete/autocomplete.min.js +1 -1
  22. package/avatar/avatar.cjs.js +3 -1
  23. package/avatar/avatar.cjs.min.js +1 -1
  24. package/avatar/avatar.d.ts +1 -1
  25. package/avatar/avatar.esm.js +3 -1
  26. package/avatar/avatar.esm.min.js +1 -1
  27. package/avatar/avatar.js +4 -3
  28. package/avatar/avatar.min.js +1 -1
  29. package/avatargroup/avatargroup.cjs.js +3 -1
  30. package/avatargroup/avatargroup.cjs.min.js +1 -1
  31. package/avatargroup/avatargroup.esm.js +3 -1
  32. package/avatargroup/avatargroup.esm.min.js +1 -1
  33. package/avatargroup/avatargroup.js +4 -3
  34. package/avatargroup/avatargroup.min.js +1 -1
  35. package/badge/badge.cjs.js +3 -1
  36. package/badge/badge.cjs.min.js +1 -1
  37. package/badge/badge.esm.js +3 -1
  38. package/badge/badge.esm.min.js +1 -1
  39. package/badge/badge.js +4 -3
  40. package/badge/badge.min.js +1 -1
  41. package/blockui/blockui.cjs.js +4 -3
  42. package/blockui/blockui.cjs.min.js +1 -1
  43. package/blockui/blockui.esm.js +4 -3
  44. package/blockui/blockui.esm.min.js +1 -1
  45. package/blockui/blockui.js +5 -4
  46. package/blockui/blockui.min.js +1 -1
  47. package/breadcrumb/breadcrumb.cjs.js +97 -52
  48. package/breadcrumb/breadcrumb.cjs.min.js +1 -1
  49. package/breadcrumb/breadcrumb.d.ts +53 -1
  50. package/breadcrumb/breadcrumb.esm.js +97 -52
  51. package/breadcrumb/breadcrumb.esm.min.js +1 -1
  52. package/breadcrumb/breadcrumb.js +96 -53
  53. package/breadcrumb/breadcrumb.min.css +1 -1
  54. package/breadcrumb/breadcrumb.min.js +1 -1
  55. package/button/button.cjs.js +6 -2
  56. package/button/button.cjs.min.js +1 -1
  57. package/button/button.d.ts +6 -0
  58. package/button/button.esm.js +6 -2
  59. package/button/button.esm.min.js +1 -1
  60. package/button/button.js +7 -4
  61. package/button/button.min.js +1 -1
  62. package/calendar/calendar.cjs.js +322 -223
  63. package/calendar/calendar.cjs.min.js +1 -1
  64. package/calendar/calendar.d.ts +272 -3
  65. package/calendar/calendar.esm.js +324 -225
  66. package/calendar/calendar.esm.min.js +1 -1
  67. package/calendar/calendar.js +323 -225
  68. package/calendar/calendar.min.js +1 -1
  69. package/card/card.cjs.js +3 -1
  70. package/card/card.cjs.min.js +1 -1
  71. package/card/card.d.ts +5 -11
  72. package/card/card.esm.js +3 -1
  73. package/card/card.esm.min.js +1 -1
  74. package/card/card.js +4 -3
  75. package/card/card.min.js +1 -1
  76. package/carousel/carousel.cjs.js +154 -92
  77. package/carousel/carousel.cjs.min.js +1 -1
  78. package/carousel/carousel.d.ts +121 -1
  79. package/carousel/carousel.esm.js +156 -94
  80. package/carousel/carousel.esm.min.js +1 -1
  81. package/carousel/carousel.js +155 -94
  82. package/carousel/carousel.min.js +1 -1
  83. package/cascadeselect/cascadeselect.cjs.js +181 -108
  84. package/cascadeselect/cascadeselect.cjs.min.js +1 -1
  85. package/cascadeselect/cascadeselect.d.ts +100 -1
  86. package/cascadeselect/cascadeselect.esm.js +183 -110
  87. package/cascadeselect/cascadeselect.esm.min.js +1 -1
  88. package/cascadeselect/cascadeselect.js +180 -108
  89. package/cascadeselect/cascadeselect.min.js +1 -1
  90. package/chart/chart.cjs.js +31 -44
  91. package/chart/chart.cjs.min.js +1 -1
  92. package/chart/chart.d.ts +30 -0
  93. package/chart/chart.esm.js +18 -31
  94. package/chart/chart.esm.min.js +1 -1
  95. package/chart/chart.js +141 -156
  96. package/chart/chart.min.js +1 -1
  97. package/checkbox/checkbox.cjs.js +113 -48
  98. package/checkbox/checkbox.cjs.min.js +1 -1
  99. package/checkbox/checkbox.d.ts +65 -1
  100. package/checkbox/checkbox.esm.js +115 -50
  101. package/checkbox/checkbox.esm.min.js +1 -1
  102. package/checkbox/checkbox.js +113 -50
  103. package/checkbox/checkbox.min.js +1 -1
  104. package/chip/chip.cjs.js +3 -1
  105. package/chip/chip.cjs.min.js +1 -1
  106. package/chip/chip.d.ts +1 -1
  107. package/chip/chip.esm.js +3 -1
  108. package/chip/chip.esm.min.js +1 -1
  109. package/chip/chip.js +4 -3
  110. package/chip/chip.min.js +1 -1
  111. package/chips/chips.cjs.js +84 -55
  112. package/chips/chips.cjs.min.js +1 -1
  113. package/chips/chips.d.ts +78 -6
  114. package/chips/chips.esm.js +85 -56
  115. package/chips/chips.esm.min.js +1 -1
  116. package/chips/chips.js +83 -57
  117. package/chips/chips.min.js +1 -1
  118. package/colorpicker/colorpicker.cjs.js +123 -49
  119. package/colorpicker/colorpicker.cjs.min.js +1 -1
  120. package/colorpicker/colorpicker.d.ts +81 -0
  121. package/colorpicker/colorpicker.esm.js +125 -51
  122. package/colorpicker/colorpicker.esm.min.js +1 -1
  123. package/colorpicker/colorpicker.js +124 -51
  124. package/colorpicker/colorpicker.min.js +1 -1
  125. package/column/column.cjs.js +2 -0
  126. package/column/column.d.ts +298 -1
  127. package/column/column.esm.js +2 -0
  128. package/column/column.js +2 -0
  129. package/columngroup/columngroup.d.ts +28 -0
  130. package/componentbase/componentbase.cjs.js +29 -5
  131. package/componentbase/componentbase.cjs.min.js +1 -1
  132. package/componentbase/componentbase.esm.js +25 -5
  133. package/componentbase/componentbase.esm.min.js +1 -1
  134. package/componentbase/componentbase.js +30 -7
  135. package/componentbase/componentbase.min.js +1 -1
  136. package/confirmdialog/confirmdialog.cjs.js +4 -3
  137. package/confirmdialog/confirmdialog.cjs.min.js +1 -1
  138. package/confirmdialog/confirmdialog.esm.js +5 -4
  139. package/confirmdialog/confirmdialog.esm.min.js +1 -1
  140. package/confirmdialog/confirmdialog.js +4 -3
  141. package/confirmdialog/confirmdialog.min.js +1 -1
  142. package/confirmpopup/confirmpopup.cjs.js +5 -4
  143. package/confirmpopup/confirmpopup.cjs.min.js +1 -1
  144. package/confirmpopup/confirmpopup.esm.js +6 -5
  145. package/confirmpopup/confirmpopup.esm.min.js +1 -1
  146. package/confirmpopup/confirmpopup.js +5 -4
  147. package/confirmpopup/confirmpopup.min.js +1 -1
  148. package/contextmenu/contextmenu.cjs.js +121 -69
  149. package/contextmenu/contextmenu.cjs.min.js +1 -1
  150. package/contextmenu/contextmenu.d.ts +92 -1
  151. package/contextmenu/contextmenu.esm.js +123 -71
  152. package/contextmenu/contextmenu.esm.min.js +1 -1
  153. package/contextmenu/contextmenu.js +122 -71
  154. package/contextmenu/contextmenu.min.js +1 -1
  155. package/core/core.js +14005 -2381
  156. package/core/core.min.js +47 -47
  157. package/csstransition/csstransition.cjs.js +3 -2
  158. package/csstransition/csstransition.cjs.min.js +1 -1
  159. package/csstransition/csstransition.esm.js +3 -2
  160. package/csstransition/csstransition.esm.min.js +1 -1
  161. package/csstransition/csstransition.js +4 -3
  162. package/csstransition/csstransition.min.js +1 -1
  163. package/datascroller/datascroller.cjs.js +34 -43
  164. package/datascroller/datascroller.cjs.min.js +1 -1
  165. package/datascroller/datascroller.d.ts +51 -1
  166. package/datascroller/datascroller.esm.js +36 -45
  167. package/datascroller/datascroller.esm.min.js +1 -1
  168. package/datascroller/datascroller.js +35 -45
  169. package/datascroller/datascroller.min.js +1 -1
  170. package/datatable/datatable.cjs.js +1089 -649
  171. package/datatable/datatable.cjs.min.js +1 -1
  172. package/datatable/datatable.d.ts +191 -3
  173. package/datatable/datatable.esm.js +1091 -651
  174. package/datatable/datatable.esm.min.js +1 -1
  175. package/datatable/datatable.js +1090 -651
  176. package/datatable/datatable.min.js +1 -1
  177. package/dataview/dataview.cjs.js +125 -109
  178. package/dataview/dataview.cjs.min.js +1 -1
  179. package/dataview/dataview.d.ts +105 -2
  180. package/dataview/dataview.esm.js +127 -111
  181. package/dataview/dataview.esm.min.js +1 -1
  182. package/dataview/dataview.js +123 -108
  183. package/dataview/dataview.min.js +1 -1
  184. package/deferredcontent/deferredcontent.cjs.js +3 -1
  185. package/deferredcontent/deferredcontent.cjs.min.js +1 -1
  186. package/deferredcontent/deferredcontent.esm.js +3 -1
  187. package/deferredcontent/deferredcontent.esm.min.js +1 -1
  188. package/deferredcontent/deferredcontent.js +4 -3
  189. package/deferredcontent/deferredcontent.min.js +1 -1
  190. package/dialog/dialog.cjs.js +6 -5
  191. package/dialog/dialog.cjs.min.js +1 -1
  192. package/dialog/dialog.esm.js +7 -6
  193. package/dialog/dialog.esm.min.js +1 -1
  194. package/dialog/dialog.js +6 -5
  195. package/dialog/dialog.min.js +1 -1
  196. package/divider/divider.cjs.js +3 -1
  197. package/divider/divider.cjs.min.js +1 -1
  198. package/divider/divider.esm.js +3 -1
  199. package/divider/divider.esm.min.js +1 -1
  200. package/divider/divider.js +4 -3
  201. package/divider/divider.min.js +1 -1
  202. package/dock/dock.cjs.js +85 -46
  203. package/dock/dock.cjs.min.js +1 -1
  204. package/dock/dock.d.ts +66 -0
  205. package/dock/dock.esm.js +86 -47
  206. package/dock/dock.esm.min.js +1 -1
  207. package/dock/dock.js +85 -48
  208. package/dock/dock.min.js +1 -1
  209. package/dropdown/dropdown.cjs.js +170 -120
  210. package/dropdown/dropdown.cjs.min.js +1 -1
  211. package/dropdown/dropdown.d.ts +154 -2
  212. package/dropdown/dropdown.esm.js +172 -122
  213. package/dropdown/dropdown.esm.min.js +1 -1
  214. package/dropdown/dropdown.js +170 -121
  215. package/dropdown/dropdown.min.js +1 -1
  216. package/editor/editor.cjs.js +95 -116
  217. package/editor/editor.cjs.min.js +1 -1
  218. package/editor/editor.d.ts +50 -0
  219. package/editor/editor.esm.js +96 -117
  220. package/editor/editor.esm.min.js +1 -1
  221. package/editor/editor.js +95 -118
  222. package/editor/editor.min.js +1 -1
  223. package/fieldset/fieldset.cjs.js +3 -1
  224. package/fieldset/fieldset.cjs.min.js +1 -1
  225. package/fieldset/fieldset.esm.js +3 -1
  226. package/fieldset/fieldset.esm.min.js +1 -1
  227. package/fieldset/fieldset.js +4 -3
  228. package/fieldset/fieldset.min.js +1 -1
  229. package/fileupload/fileupload.cjs.js +234 -191
  230. package/fileupload/fileupload.cjs.min.js +1 -1
  231. package/fileupload/fileupload.d.ts +160 -1
  232. package/fileupload/fileupload.esm.js +235 -192
  233. package/fileupload/fileupload.esm.min.js +1 -1
  234. package/fileupload/fileupload.js +231 -188
  235. package/fileupload/fileupload.min.js +1 -1
  236. package/galleria/galleria.cjs.js +139 -124
  237. package/galleria/galleria.cjs.min.js +1 -1
  238. package/galleria/galleria.d.ts +156 -2
  239. package/galleria/galleria.esm.js +141 -126
  240. package/galleria/galleria.esm.min.js +1 -1
  241. package/galleria/galleria.js +138 -124
  242. package/galleria/galleria.min.js +1 -1
  243. package/hooks/hooks.cjs.js +10 -3
  244. package/hooks/hooks.cjs.min.js +1 -1
  245. package/hooks/hooks.esm.js +7 -3
  246. package/hooks/hooks.esm.min.js +1 -1
  247. package/hooks/hooks.js +11 -5
  248. package/hooks/hooks.min.js +1 -1
  249. package/icons/arrowdown/index.cjs.js +415 -2
  250. package/icons/arrowdown/index.cjs.min.js +1 -1
  251. package/icons/arrowdown/index.esm.js +415 -2
  252. package/icons/arrowdown/index.esm.min.js +1 -1
  253. package/icons/arrowdown/index.js +415 -2
  254. package/icons/arrowdown/index.min.js +1 -1
  255. package/icons/arrowup/index.cjs.js +415 -2
  256. package/icons/arrowup/index.cjs.min.js +1 -1
  257. package/icons/arrowup/index.esm.js +415 -2
  258. package/icons/arrowup/index.esm.min.js +1 -1
  259. package/icons/arrowup/index.js +415 -2
  260. package/icons/arrowup/index.min.js +1 -1
  261. package/icons/ban/index.cjs.js +415 -2
  262. package/icons/ban/index.cjs.min.js +1 -1
  263. package/icons/ban/index.esm.js +415 -2
  264. package/icons/ban/index.esm.min.js +1 -1
  265. package/icons/ban/index.js +415 -2
  266. package/icons/ban/index.min.js +1 -1
  267. package/icons/download/index.cjs.js +415 -2
  268. package/icons/download/index.cjs.min.js +1 -1
  269. package/icons/download/index.esm.js +415 -2
  270. package/icons/download/index.esm.min.js +1 -1
  271. package/icons/download/index.js +415 -2
  272. package/icons/download/index.min.js +1 -1
  273. package/icons/exclamationtriangle/index.cjs.js +415 -2
  274. package/icons/exclamationtriangle/index.cjs.min.js +1 -1
  275. package/icons/exclamationtriangle/index.esm.js +415 -2
  276. package/icons/exclamationtriangle/index.esm.min.js +1 -1
  277. package/icons/exclamationtriangle/index.js +415 -2
  278. package/icons/exclamationtriangle/index.min.js +1 -1
  279. package/icons/eyeslash/index.cjs.js +415 -2
  280. package/icons/eyeslash/index.cjs.min.js +1 -1
  281. package/icons/eyeslash/index.esm.js +415 -2
  282. package/icons/eyeslash/index.esm.min.js +1 -1
  283. package/icons/eyeslash/index.js +415 -2
  284. package/icons/eyeslash/index.min.js +1 -1
  285. package/icons/filter/index.cjs.js +415 -2
  286. package/icons/filter/index.cjs.min.js +1 -1
  287. package/icons/filter/index.esm.js +415 -2
  288. package/icons/filter/index.esm.min.js +1 -1
  289. package/icons/filter/index.js +415 -2
  290. package/icons/filter/index.min.js +1 -1
  291. package/icons/filterslash/index.cjs.js +415 -2
  292. package/icons/filterslash/index.cjs.min.js +1 -1
  293. package/icons/filterslash/index.esm.js +415 -2
  294. package/icons/filterslash/index.esm.min.js +1 -1
  295. package/icons/filterslash/index.js +415 -2
  296. package/icons/filterslash/index.min.js +1 -1
  297. package/icons/infocircle/index.cjs.js +415 -2
  298. package/icons/infocircle/index.cjs.min.js +1 -1
  299. package/icons/infocircle/index.esm.js +415 -2
  300. package/icons/infocircle/index.esm.min.js +1 -1
  301. package/icons/infocircle/index.js +415 -2
  302. package/icons/infocircle/index.min.js +1 -1
  303. package/icons/pencil/index.cjs.js +415 -2
  304. package/icons/pencil/index.cjs.min.js +1 -1
  305. package/icons/pencil/index.esm.js +415 -2
  306. package/icons/pencil/index.esm.min.js +1 -1
  307. package/icons/pencil/index.js +415 -2
  308. package/icons/pencil/index.min.js +1 -1
  309. package/icons/plus/index.cjs.js +415 -2
  310. package/icons/plus/index.cjs.min.js +1 -1
  311. package/icons/plus/index.esm.js +415 -2
  312. package/icons/plus/index.esm.min.js +1 -1
  313. package/icons/plus/index.js +415 -2
  314. package/icons/plus/index.min.js +1 -1
  315. package/icons/refresh/index.cjs.js +415 -2
  316. package/icons/refresh/index.cjs.min.js +1 -1
  317. package/icons/refresh/index.esm.js +415 -2
  318. package/icons/refresh/index.esm.min.js +1 -1
  319. package/icons/refresh/index.js +415 -2
  320. package/icons/refresh/index.min.js +1 -1
  321. package/icons/search/index.cjs.js +415 -2
  322. package/icons/search/index.cjs.min.js +1 -1
  323. package/icons/search/index.esm.js +415 -2
  324. package/icons/search/index.esm.min.js +1 -1
  325. package/icons/search/index.js +415 -2
  326. package/icons/search/index.min.js +1 -1
  327. package/icons/searchminus/index.cjs.js +415 -2
  328. package/icons/searchminus/index.cjs.min.js +1 -1
  329. package/icons/searchminus/index.esm.js +415 -2
  330. package/icons/searchminus/index.esm.min.js +1 -1
  331. package/icons/searchminus/index.js +415 -2
  332. package/icons/searchminus/index.min.js +1 -1
  333. package/icons/searchplus/index.cjs.js +415 -2
  334. package/icons/searchplus/index.cjs.min.js +1 -1
  335. package/icons/searchplus/index.esm.js +415 -2
  336. package/icons/searchplus/index.esm.min.js +1 -1
  337. package/icons/searchplus/index.js +415 -2
  338. package/icons/searchplus/index.min.js +1 -1
  339. package/icons/sortalt/index.cjs.js +415 -2
  340. package/icons/sortalt/index.cjs.min.js +1 -1
  341. package/icons/sortalt/index.esm.js +415 -2
  342. package/icons/sortalt/index.esm.min.js +1 -1
  343. package/icons/sortalt/index.js +415 -2
  344. package/icons/sortalt/index.min.js +1 -1
  345. package/icons/sortamountdown/index.cjs.js +415 -2
  346. package/icons/sortamountdown/index.cjs.min.js +1 -1
  347. package/icons/sortamountdown/index.esm.js +415 -2
  348. package/icons/sortamountdown/index.esm.min.js +1 -1
  349. package/icons/sortamountdown/index.js +415 -2
  350. package/icons/sortamountdown/index.min.js +1 -1
  351. package/icons/sortamountupalt/index.cjs.js +415 -2
  352. package/icons/sortamountupalt/index.cjs.min.js +1 -1
  353. package/icons/sortamountupalt/index.esm.js +415 -2
  354. package/icons/sortamountupalt/index.esm.min.js +1 -1
  355. package/icons/sortamountupalt/index.js +415 -2
  356. package/icons/sortamountupalt/index.min.js +1 -1
  357. package/icons/spinner/index.cjs.js +415 -2
  358. package/icons/spinner/index.cjs.min.js +1 -1
  359. package/icons/spinner/index.esm.js +415 -2
  360. package/icons/spinner/index.esm.min.js +1 -1
  361. package/icons/spinner/index.js +415 -2
  362. package/icons/spinner/index.min.js +1 -1
  363. package/icons/star/index.cjs.js +415 -2
  364. package/icons/star/index.cjs.min.js +1 -1
  365. package/icons/star/index.esm.js +415 -2
  366. package/icons/star/index.esm.min.js +1 -1
  367. package/icons/star/index.js +415 -2
  368. package/icons/star/index.min.js +1 -1
  369. package/icons/starfill/index.cjs.js +415 -2
  370. package/icons/starfill/index.cjs.min.js +1 -1
  371. package/icons/starfill/index.esm.js +415 -2
  372. package/icons/starfill/index.esm.min.js +1 -1
  373. package/icons/starfill/index.js +415 -2
  374. package/icons/starfill/index.min.js +1 -1
  375. package/icons/thlarge/index.cjs.js +415 -2
  376. package/icons/thlarge/index.cjs.min.js +1 -1
  377. package/icons/thlarge/index.esm.js +415 -2
  378. package/icons/thlarge/index.esm.min.js +1 -1
  379. package/icons/thlarge/index.js +415 -2
  380. package/icons/thlarge/index.min.js +1 -1
  381. package/icons/timescircle/index.cjs.js +415 -2
  382. package/icons/timescircle/index.cjs.min.js +1 -1
  383. package/icons/timescircle/index.esm.js +415 -2
  384. package/icons/timescircle/index.esm.min.js +1 -1
  385. package/icons/timescircle/index.js +415 -2
  386. package/icons/timescircle/index.min.js +1 -1
  387. package/icons/trash/index.cjs.js +415 -2
  388. package/icons/trash/index.cjs.min.js +1 -1
  389. package/icons/trash/index.esm.js +415 -2
  390. package/icons/trash/index.esm.min.js +1 -1
  391. package/icons/trash/index.js +415 -2
  392. package/icons/trash/index.min.js +1 -1
  393. package/icons/undo/index.cjs.js +415 -2
  394. package/icons/undo/index.cjs.min.js +1 -1
  395. package/icons/undo/index.esm.js +415 -2
  396. package/icons/undo/index.esm.min.js +1 -1
  397. package/icons/undo/index.js +415 -2
  398. package/icons/undo/index.min.js +1 -1
  399. package/icons/upload/index.cjs.js +415 -2
  400. package/icons/upload/index.cjs.min.js +1 -1
  401. package/icons/upload/index.esm.js +415 -2
  402. package/icons/upload/index.esm.min.js +1 -1
  403. package/icons/upload/index.js +415 -2
  404. package/icons/upload/index.min.js +1 -1
  405. package/icons/windowmaximize/index.cjs.js +415 -2
  406. package/icons/windowmaximize/index.cjs.min.js +1 -1
  407. package/icons/windowmaximize/index.esm.js +415 -2
  408. package/icons/windowmaximize/index.esm.min.js +1 -1
  409. package/icons/windowmaximize/index.js +415 -2
  410. package/icons/windowmaximize/index.min.js +1 -1
  411. package/icons/windowminimize/index.cjs.js +415 -2
  412. package/icons/windowminimize/index.cjs.min.js +1 -1
  413. package/icons/windowminimize/index.esm.js +415 -2
  414. package/icons/windowminimize/index.esm.min.js +1 -1
  415. package/icons/windowminimize/index.js +415 -2
  416. package/icons/windowminimize/index.min.js +1 -1
  417. package/image/image.cjs.js +480 -80
  418. package/image/image.cjs.min.js +1 -1
  419. package/image/image.d.ts +130 -3
  420. package/image/image.esm.js +483 -83
  421. package/image/image.esm.min.js +1 -1
  422. package/image/image.js +481 -82
  423. package/image/image.min.css +1 -1
  424. package/image/image.min.js +1 -1
  425. package/inplace/inplace.cjs.js +2 -1
  426. package/inplace/inplace.cjs.min.js +1 -1
  427. package/inplace/inplace.esm.js +3 -2
  428. package/inplace/inplace.esm.min.js +1 -1
  429. package/inplace/inplace.js +2 -1
  430. package/inplace/inplace.min.js +1 -1
  431. package/inputmask/inputmask.cjs.js +26 -26
  432. package/inputmask/inputmask.cjs.min.js +1 -1
  433. package/inputmask/inputmask.d.ts +7 -2
  434. package/inputmask/inputmask.esm.js +27 -27
  435. package/inputmask/inputmask.esm.min.js +1 -1
  436. package/inputmask/inputmask.js +26 -28
  437. package/inputmask/inputmask.min.js +1 -1
  438. package/inputnumber/inputnumber.cjs.js +68 -48
  439. package/inputnumber/inputnumber.cjs.min.js +1 -1
  440. package/inputnumber/inputnumber.d.ts +62 -1
  441. package/inputnumber/inputnumber.esm.js +66 -49
  442. package/inputnumber/inputnumber.esm.min.js +1 -1
  443. package/inputnumber/inputnumber.js +68 -50
  444. package/inputnumber/inputnumber.min.js +1 -1
  445. package/inputswitch/inputswitch.cjs.js +84 -25
  446. package/inputswitch/inputswitch.cjs.min.js +1 -1
  447. package/inputswitch/inputswitch.d.ts +61 -0
  448. package/inputswitch/inputswitch.esm.js +85 -26
  449. package/inputswitch/inputswitch.esm.min.js +1 -1
  450. package/inputswitch/inputswitch.js +83 -27
  451. package/inputswitch/inputswitch.min.js +1 -1
  452. package/inputtext/inputtext.cjs.js +25 -15
  453. package/inputtext/inputtext.cjs.min.js +1 -1
  454. package/inputtext/inputtext.d.ts +32 -0
  455. package/inputtext/inputtext.esm.js +26 -16
  456. package/inputtext/inputtext.esm.min.js +1 -1
  457. package/inputtext/inputtext.js +25 -17
  458. package/inputtext/inputtext.min.js +1 -1
  459. package/inputtextarea/inputtextarea.cjs.js +25 -15
  460. package/inputtextarea/inputtextarea.cjs.min.js +1 -1
  461. package/inputtextarea/inputtextarea.d.ts +33 -1
  462. package/inputtextarea/inputtextarea.esm.js +26 -16
  463. package/inputtextarea/inputtextarea.esm.min.js +1 -1
  464. package/inputtextarea/inputtextarea.js +25 -17
  465. package/inputtextarea/inputtextarea.min.js +1 -1
  466. package/keyfilter/keyfilter.cjs.js +25 -9
  467. package/keyfilter/keyfilter.cjs.min.js +1 -1
  468. package/keyfilter/keyfilter.esm.js +25 -9
  469. package/keyfilter/keyfilter.esm.min.js +1 -1
  470. package/keyfilter/keyfilter.js +25 -11
  471. package/keyfilter/keyfilter.min.js +1 -1
  472. package/knob/knob.cjs.js +44 -43
  473. package/knob/knob.cjs.min.js +1 -1
  474. package/knob/knob.d.ts +42 -0
  475. package/knob/knob.esm.js +45 -44
  476. package/knob/knob.esm.min.js +1 -1
  477. package/knob/knob.js +44 -45
  478. package/knob/knob.min.js +1 -1
  479. package/listbox/listbox.cjs.js +86 -56
  480. package/listbox/listbox.cjs.min.js +1 -1
  481. package/listbox/listbox.d.ts +103 -3
  482. package/listbox/listbox.esm.js +88 -58
  483. package/listbox/listbox.esm.min.js +1 -1
  484. package/listbox/listbox.js +86 -57
  485. package/listbox/listbox.min.js +1 -1
  486. package/megamenu/megamenu.cjs.js +151 -99
  487. package/megamenu/megamenu.cjs.min.js +1 -1
  488. package/megamenu/megamenu.d.ts +142 -2
  489. package/megamenu/megamenu.esm.js +152 -100
  490. package/megamenu/megamenu.esm.min.js +1 -1
  491. package/megamenu/megamenu.js +149 -98
  492. package/megamenu/megamenu.min.js +1 -1
  493. package/mention/mention.cjs.js +87 -61
  494. package/mention/mention.cjs.min.js +1 -1
  495. package/mention/mention.d.ts +80 -1
  496. package/mention/mention.esm.js +89 -63
  497. package/mention/mention.esm.min.js +1 -1
  498. package/mention/mention.js +88 -63
  499. package/mention/mention.min.js +1 -1
  500. package/menu/menu.cjs.js +99 -59
  501. package/menu/menu.cjs.min.js +1 -1
  502. package/menu/menu.d.ts +71 -0
  503. package/menu/menu.esm.js +101 -61
  504. package/menu/menu.esm.min.js +1 -1
  505. package/menu/menu.js +100 -61
  506. package/menu/menu.min.js +1 -1
  507. package/menubar/menubar.cjs.js +122 -114
  508. package/menubar/menubar.cjs.min.js +1 -1
  509. package/menubar/menubar.d.ts +94 -1
  510. package/menubar/menubar.esm.js +124 -116
  511. package/menubar/menubar.esm.min.js +1 -1
  512. package/menubar/menubar.js +122 -115
  513. package/menubar/menubar.min.js +1 -1
  514. package/message/message.cjs.js +69 -47
  515. package/message/message.cjs.min.js +1 -1
  516. package/message/message.d.ts +35 -2
  517. package/message/message.esm.js +70 -48
  518. package/message/message.esm.min.js +1 -1
  519. package/message/message.js +69 -49
  520. package/message/message.min.js +1 -1
  521. package/messages/messages.cjs.js +65 -63
  522. package/messages/messages.cjs.min.js +1 -1
  523. package/messages/messages.d.ts +51 -2
  524. package/messages/messages.esm.js +66 -64
  525. package/messages/messages.esm.min.js +1 -1
  526. package/messages/messages.js +65 -64
  527. package/messages/messages.min.js +1 -1
  528. package/multiselect/multiselect.cjs.js +249 -193
  529. package/multiselect/multiselect.cjs.min.js +1 -1
  530. package/multiselect/multiselect.d.ts +185 -3
  531. package/multiselect/multiselect.esm.js +252 -196
  532. package/multiselect/multiselect.esm.min.js +1 -1
  533. package/multiselect/multiselect.js +249 -194
  534. package/multiselect/multiselect.min.js +1 -1
  535. package/multistatecheckbox/multistatecheckbox.cjs.js +47 -33
  536. package/multistatecheckbox/multistatecheckbox.cjs.min.js +1 -1
  537. package/multistatecheckbox/multistatecheckbox.d.ts +61 -2
  538. package/multistatecheckbox/multistatecheckbox.esm.js +49 -35
  539. package/multistatecheckbox/multistatecheckbox.esm.min.js +1 -1
  540. package/multistatecheckbox/multistatecheckbox.js +48 -35
  541. package/multistatecheckbox/multistatecheckbox.min.js +1 -1
  542. package/orderlist/orderlist.cjs.js +188 -110
  543. package/orderlist/orderlist.cjs.min.js +1 -1
  544. package/orderlist/orderlist.d.ts +118 -2
  545. package/orderlist/orderlist.esm.js +190 -112
  546. package/orderlist/orderlist.esm.min.js +1 -1
  547. package/orderlist/orderlist.js +186 -109
  548. package/orderlist/orderlist.min.js +1 -1
  549. package/organizationchart/organizationchart.cjs.js +139 -73
  550. package/organizationchart/organizationchart.cjs.min.js +1 -1
  551. package/organizationchart/organizationchart.d.ts +89 -2
  552. package/organizationchart/organizationchart.esm.js +140 -74
  553. package/organizationchart/organizationchart.esm.min.js +1 -1
  554. package/organizationchart/organizationchart.js +139 -75
  555. package/organizationchart/organizationchart.min.js +1 -1
  556. package/overlaypanel/overlaypanel.cjs.js +7 -6
  557. package/overlaypanel/overlaypanel.cjs.min.js +1 -1
  558. package/overlaypanel/overlaypanel.d.ts +5 -0
  559. package/overlaypanel/overlaypanel.esm.js +8 -7
  560. package/overlaypanel/overlaypanel.esm.min.js +1 -1
  561. package/overlaypanel/overlaypanel.js +8 -7
  562. package/overlaypanel/overlaypanel.min.js +1 -1
  563. package/package.json +1 -1
  564. package/paginator/paginator.cjs.js +172 -166
  565. package/paginator/paginator.cjs.min.js +1 -1
  566. package/paginator/paginator.d.ts +111 -5
  567. package/paginator/paginator.esm.js +174 -168
  568. package/paginator/paginator.esm.min.js +1 -1
  569. package/paginator/paginator.js +172 -167
  570. package/paginator/paginator.min.js +1 -1
  571. package/panel/panel.cjs.js +3 -1
  572. package/panel/panel.cjs.min.js +1 -1
  573. package/panel/panel.esm.js +3 -1
  574. package/panel/panel.esm.min.js +1 -1
  575. package/panel/panel.js +4 -3
  576. package/panel/panel.min.js +1 -1
  577. package/panelmenu/panelmenu.cjs.js +148 -84
  578. package/panelmenu/panelmenu.cjs.min.js +1 -1
  579. package/panelmenu/panelmenu.d.ts +124 -2
  580. package/panelmenu/panelmenu.esm.js +148 -84
  581. package/panelmenu/panelmenu.esm.min.js +1 -1
  582. package/panelmenu/panelmenu.js +146 -84
  583. package/panelmenu/panelmenu.min.js +1 -1
  584. package/password/password.cjs.js +89 -46
  585. package/password/password.cjs.min.js +1 -1
  586. package/password/password.d.ts +98 -2
  587. package/password/password.esm.js +91 -48
  588. package/password/password.esm.min.js +1 -1
  589. package/password/password.js +88 -46
  590. package/password/password.min.js +1 -1
  591. package/picklist/picklist.cjs.js +146 -82
  592. package/picklist/picklist.cjs.min.js +1 -1
  593. package/picklist/picklist.d.ts +133 -1
  594. package/picklist/picklist.esm.js +148 -84
  595. package/picklist/picklist.esm.min.js +1 -1
  596. package/picklist/picklist.js +143 -80
  597. package/picklist/picklist.min.js +1 -1
  598. package/portal/portal.cjs.js +3 -2
  599. package/portal/portal.cjs.min.js +1 -1
  600. package/portal/portal.esm.js +3 -2
  601. package/portal/portal.esm.min.js +1 -1
  602. package/portal/portal.js +4 -3
  603. package/portal/portal.min.js +1 -1
  604. package/primereact.all.cjs.js +6656 -4389
  605. package/primereact.all.cjs.min.js +1 -1
  606. package/primereact.all.esm.js +6655 -4390
  607. package/primereact.all.esm.min.js +1 -1
  608. package/primereact.all.js +6656 -4389
  609. package/primereact.all.min.js +1 -1
  610. package/progressbar/progressbar.cjs.js +3 -1
  611. package/progressbar/progressbar.cjs.min.js +1 -1
  612. package/progressbar/progressbar.esm.js +3 -1
  613. package/progressbar/progressbar.esm.min.js +1 -1
  614. package/progressbar/progressbar.js +4 -3
  615. package/progressbar/progressbar.min.js +1 -1
  616. package/progressspinner/progressspinner.cjs.js +3 -1
  617. package/progressspinner/progressspinner.cjs.min.js +1 -1
  618. package/progressspinner/progressspinner.esm.js +3 -1
  619. package/progressspinner/progressspinner.esm.min.js +1 -1
  620. package/progressspinner/progressspinner.js +4 -3
  621. package/progressspinner/progressspinner.min.js +1 -1
  622. package/radiobutton/radiobutton.cjs.js +90 -30
  623. package/radiobutton/radiobutton.cjs.min.js +1 -1
  624. package/radiobutton/radiobutton.d.ts +66 -1
  625. package/radiobutton/radiobutton.esm.js +91 -31
  626. package/radiobutton/radiobutton.esm.min.js +1 -1
  627. package/radiobutton/radiobutton.js +89 -32
  628. package/radiobutton/radiobutton.min.js +1 -1
  629. package/rating/rating.cjs.js +47 -36
  630. package/rating/rating.cjs.min.js +1 -1
  631. package/rating/rating.d.ts +64 -1
  632. package/rating/rating.esm.js +48 -37
  633. package/rating/rating.esm.min.js +1 -1
  634. package/rating/rating.js +47 -38
  635. package/rating/rating.min.js +1 -1
  636. package/resources/primereact.css +475 -465
  637. package/resources/primereact.min.css +1 -1
  638. package/resources/themes/arya-blue/theme.css +33 -8
  639. package/resources/themes/arya-green/theme.css +33 -8
  640. package/resources/themes/arya-orange/theme.css +33 -8
  641. package/resources/themes/arya-purple/theme.css +33 -8
  642. package/resources/themes/bootstrap4-dark-blue/theme.css +33 -8
  643. package/resources/themes/bootstrap4-dark-purple/theme.css +33 -8
  644. package/resources/themes/bootstrap4-light-blue/theme.css +33 -8
  645. package/resources/themes/bootstrap4-light-purple/theme.css +33 -8
  646. package/resources/themes/fluent-light/theme.css +33 -8
  647. package/resources/themes/lara-dark-blue/theme.css +33 -8
  648. package/resources/themes/lara-dark-indigo/theme.css +33 -8
  649. package/resources/themes/lara-dark-purple/theme.css +33 -8
  650. package/resources/themes/lara-dark-teal/theme.css +33 -8
  651. package/resources/themes/lara-light-blue/theme.css +33 -8
  652. package/resources/themes/lara-light-indigo/theme.css +33 -8
  653. package/resources/themes/lara-light-purple/theme.css +33 -8
  654. package/resources/themes/lara-light-teal/theme.css +33 -8
  655. package/resources/themes/luna-amber/theme.css +33 -8
  656. package/resources/themes/luna-blue/theme.css +33 -8
  657. package/resources/themes/luna-green/theme.css +33 -8
  658. package/resources/themes/luna-pink/theme.css +33 -8
  659. package/resources/themes/md-dark-deeppurple/theme.css +33 -8
  660. package/resources/themes/md-dark-indigo/theme.css +33 -8
  661. package/resources/themes/md-light-deeppurple/theme.css +33 -8
  662. package/resources/themes/md-light-indigo/theme.css +33 -8
  663. package/resources/themes/mdc-dark-deeppurple/theme.css +33 -8
  664. package/resources/themes/mdc-dark-indigo/theme.css +33 -8
  665. package/resources/themes/mdc-light-deeppurple/theme.css +33 -8
  666. package/resources/themes/mdc-light-indigo/theme.css +33 -8
  667. package/resources/themes/mira/theme.css +33 -8
  668. package/resources/themes/nano/theme.css +33 -8
  669. package/resources/themes/nova/theme.css +33 -8
  670. package/resources/themes/nova-accent/theme.css +33 -8
  671. package/resources/themes/nova-alt/theme.css +33 -8
  672. package/resources/themes/rhea/theme.css +33 -8
  673. package/resources/themes/saga-blue/theme.css +33 -8
  674. package/resources/themes/saga-green/theme.css +33 -8
  675. package/resources/themes/saga-orange/theme.css +33 -8
  676. package/resources/themes/saga-purple/theme.css +33 -8
  677. package/resources/themes/soho-dark/theme.css +33 -8
  678. package/resources/themes/soho-light/theme.css +33 -8
  679. package/resources/themes/tailwind-light/theme.css +45 -20
  680. package/resources/themes/vela-blue/theme.css +33 -8
  681. package/resources/themes/vela-green/theme.css +33 -8
  682. package/resources/themes/vela-orange/theme.css +33 -8
  683. package/resources/themes/vela-purple/theme.css +33 -8
  684. package/resources/themes/viva-dark/theme.css +33 -8
  685. package/resources/themes/viva-light/theme.css +33 -8
  686. package/ripple/ripple.cjs.js +3 -2
  687. package/ripple/ripple.cjs.min.js +1 -1
  688. package/ripple/ripple.esm.js +3 -2
  689. package/ripple/ripple.esm.min.js +1 -1
  690. package/ripple/ripple.js +4 -3
  691. package/ripple/ripple.min.js +1 -1
  692. package/row/row.cjs.js +28 -41
  693. package/row/row.cjs.min.js +1 -1
  694. package/row/row.d.ts +28 -0
  695. package/row/row.esm.js +15 -28
  696. package/row/row.esm.min.js +1 -1
  697. package/row/row.js +49 -64
  698. package/row/row.min.js +1 -1
  699. package/scrollpanel/scrollpanel.cjs.js +3 -1
  700. package/scrollpanel/scrollpanel.cjs.min.js +1 -1
  701. package/scrollpanel/scrollpanel.esm.js +3 -1
  702. package/scrollpanel/scrollpanel.esm.min.js +1 -1
  703. package/scrollpanel/scrollpanel.js +4 -3
  704. package/scrollpanel/scrollpanel.min.js +1 -1
  705. package/scrolltop/scrolltop.cjs.js +9 -7
  706. package/scrolltop/scrolltop.cjs.min.js +1 -1
  707. package/scrolltop/scrolltop.esm.js +11 -9
  708. package/scrolltop/scrolltop.esm.min.js +1 -1
  709. package/scrolltop/scrolltop.js +10 -8
  710. package/scrolltop/scrolltop.min.js +1 -1
  711. package/selectbutton/selectbutton.cjs.js +37 -25
  712. package/selectbutton/selectbutton.cjs.min.js +1 -1
  713. package/selectbutton/selectbutton.d.ts +52 -1
  714. package/selectbutton/selectbutton.esm.js +38 -26
  715. package/selectbutton/selectbutton.esm.min.js +1 -1
  716. package/selectbutton/selectbutton.js +37 -27
  717. package/selectbutton/selectbutton.min.js +1 -1
  718. package/sidebar/sidebar.cjs.js +7 -6
  719. package/sidebar/sidebar.cjs.min.js +1 -1
  720. package/sidebar/sidebar.esm.js +8 -7
  721. package/sidebar/sidebar.esm.min.js +1 -1
  722. package/sidebar/sidebar.js +8 -7
  723. package/sidebar/sidebar.min.js +1 -1
  724. package/skeleton/skeleton.cjs.js +4 -3
  725. package/skeleton/skeleton.cjs.min.js +1 -1
  726. package/skeleton/skeleton.esm.js +4 -3
  727. package/skeleton/skeleton.esm.min.js +1 -1
  728. package/skeleton/skeleton.js +5 -5
  729. package/skeleton/skeleton.min.js +1 -1
  730. package/slidemenu/slidemenu.cjs.js +125 -114
  731. package/slidemenu/slidemenu.cjs.min.js +1 -1
  732. package/slidemenu/slidemenu.d.ts +103 -1
  733. package/slidemenu/slidemenu.esm.js +127 -116
  734. package/slidemenu/slidemenu.esm.min.js +1 -1
  735. package/slidemenu/slidemenu.js +125 -115
  736. package/slidemenu/slidemenu.min.js +1 -1
  737. package/slider/slider.cjs.js +71 -39
  738. package/slider/slider.cjs.min.js +1 -1
  739. package/slider/slider.d.ts +34 -1
  740. package/slider/slider.esm.js +72 -40
  741. package/slider/slider.esm.min.js +1 -1
  742. package/slider/slider.js +71 -41
  743. package/slider/slider.min.js +1 -1
  744. package/speeddial/speeddial.cjs.js +3 -1
  745. package/speeddial/speeddial.cjs.min.js +1 -1
  746. package/speeddial/speeddial.esm.js +3 -1
  747. package/speeddial/speeddial.esm.min.js +1 -1
  748. package/speeddial/speeddial.js +4 -3
  749. package/speeddial/speeddial.min.js +1 -1
  750. package/splitbutton/splitbutton.cjs.js +74 -63
  751. package/splitbutton/splitbutton.cjs.min.js +1 -1
  752. package/splitbutton/splitbutton.d.ts +39 -11
  753. package/splitbutton/splitbutton.esm.js +76 -65
  754. package/splitbutton/splitbutton.esm.min.js +1 -1
  755. package/splitbutton/splitbutton.js +74 -63
  756. package/splitbutton/splitbutton.min.js +1 -1
  757. package/splitter/splitter.cjs.js +3 -1
  758. package/splitter/splitter.cjs.min.js +1 -1
  759. package/splitter/splitter.d.ts +10 -0
  760. package/splitter/splitter.esm.js +3 -1
  761. package/splitter/splitter.esm.min.js +1 -1
  762. package/splitter/splitter.js +4 -3
  763. package/splitter/splitter.min.js +1 -1
  764. package/steps/steps.cjs.js +81 -46
  765. package/steps/steps.cjs.min.js +1 -1
  766. package/steps/steps.d.ts +50 -0
  767. package/steps/steps.esm.js +82 -47
  768. package/steps/steps.esm.min.js +1 -1
  769. package/steps/steps.js +81 -48
  770. package/steps/steps.min.js +1 -1
  771. package/styleclass/styleclass.cjs.js +3 -1
  772. package/styleclass/styleclass.cjs.min.js +1 -1
  773. package/styleclass/styleclass.esm.js +3 -1
  774. package/styleclass/styleclass.esm.min.js +1 -1
  775. package/styleclass/styleclass.js +4 -3
  776. package/styleclass/styleclass.min.js +1 -1
  777. package/tabmenu/tabmenu.cjs.js +86 -48
  778. package/tabmenu/tabmenu.cjs.min.js +1 -1
  779. package/tabmenu/tabmenu.d.ts +62 -0
  780. package/tabmenu/tabmenu.esm.js +87 -49
  781. package/tabmenu/tabmenu.esm.min.js +1 -1
  782. package/tabmenu/tabmenu.js +86 -50
  783. package/tabmenu/tabmenu.min.js +1 -1
  784. package/tabview/tabview.cjs.js +8 -5
  785. package/tabview/tabview.cjs.min.js +1 -1
  786. package/tabview/tabview.esm.js +9 -6
  787. package/tabview/tabview.esm.min.js +1 -1
  788. package/tabview/tabview.js +7 -4
  789. package/tabview/tabview.min.js +1 -1
  790. package/tag/tag.cjs.js +3 -1
  791. package/tag/tag.cjs.min.js +1 -1
  792. package/tag/tag.esm.js +3 -1
  793. package/tag/tag.esm.min.js +1 -1
  794. package/tag/tag.js +4 -3
  795. package/tag/tag.min.js +1 -1
  796. package/terminal/terminal.cjs.js +3 -1
  797. package/terminal/terminal.cjs.min.js +1 -1
  798. package/terminal/terminal.esm.js +3 -1
  799. package/terminal/terminal.esm.min.js +1 -1
  800. package/terminal/terminal.js +4 -3
  801. package/terminal/terminal.min.js +1 -1
  802. package/tieredmenu/tieredmenu.cjs.js +110 -64
  803. package/tieredmenu/tieredmenu.cjs.min.js +1 -1
  804. package/tieredmenu/tieredmenu.d.ts +83 -2
  805. package/tieredmenu/tieredmenu.esm.js +112 -66
  806. package/tieredmenu/tieredmenu.esm.min.js +1 -1
  807. package/tieredmenu/tieredmenu.js +111 -66
  808. package/tieredmenu/tieredmenu.min.js +1 -1
  809. package/timeline/timeline.cjs.js +51 -43
  810. package/timeline/timeline.cjs.min.js +1 -1
  811. package/timeline/timeline.d.ts +51 -1
  812. package/timeline/timeline.esm.js +52 -44
  813. package/timeline/timeline.esm.min.js +1 -1
  814. package/timeline/timeline.js +51 -45
  815. package/timeline/timeline.min.js +1 -1
  816. package/toast/toast.cjs.js +118 -75
  817. package/toast/toast.cjs.min.js +1 -1
  818. package/toast/toast.d.ts +122 -4
  819. package/toast/toast.esm.js +120 -77
  820. package/toast/toast.esm.min.js +1 -1
  821. package/toast/toast.js +116 -74
  822. package/toast/toast.min.js +1 -1
  823. package/togglebutton/togglebutton.cjs.js +74 -21
  824. package/togglebutton/togglebutton.cjs.min.js +1 -1
  825. package/togglebutton/togglebutton.d.ts +40 -2
  826. package/togglebutton/togglebutton.esm.js +75 -22
  827. package/togglebutton/togglebutton.esm.min.js +1 -1
  828. package/togglebutton/togglebutton.js +73 -23
  829. package/togglebutton/togglebutton.min.js +1 -1
  830. package/toolbar/toolbar.cjs.js +3 -1
  831. package/toolbar/toolbar.cjs.min.js +1 -1
  832. package/toolbar/toolbar.d.ts +5 -11
  833. package/toolbar/toolbar.esm.js +3 -1
  834. package/toolbar/toolbar.esm.min.js +1 -1
  835. package/toolbar/toolbar.js +4 -3
  836. package/toolbar/toolbar.min.js +1 -1
  837. package/tooltip/tooltip.cjs.js +3 -2
  838. package/tooltip/tooltip.cjs.min.js +1 -1
  839. package/tooltip/tooltip.d.ts +7 -7
  840. package/tooltip/tooltip.esm.js +4 -3
  841. package/tooltip/tooltip.esm.min.js +1 -1
  842. package/tooltip/tooltip.js +3 -2
  843. package/tooltip/tooltip.min.js +1 -1
  844. package/tree/tree.cjs.js +118 -88
  845. package/tree/tree.cjs.min.js +1 -1
  846. package/tree/tree.d.ts +139 -1
  847. package/tree/tree.esm.js +120 -90
  848. package/tree/tree.esm.min.js +1 -1
  849. package/tree/tree.js +116 -87
  850. package/tree/tree.min.js +1 -1
  851. package/treeselect/treeselect.cjs.js +135 -102
  852. package/treeselect/treeselect.cjs.min.js +1 -1
  853. package/treeselect/treeselect.d.ts +143 -2
  854. package/treeselect/treeselect.esm.js +137 -104
  855. package/treeselect/treeselect.esm.min.js +1 -1
  856. package/treeselect/treeselect.js +136 -104
  857. package/treeselect/treeselect.min.js +1 -1
  858. package/treetable/treetable.cjs.js +385 -198
  859. package/treetable/treetable.cjs.min.js +1 -1
  860. package/treetable/treetable.d.ts +305 -2
  861. package/treetable/treetable.esm.js +387 -200
  862. package/treetable/treetable.esm.min.js +1 -1
  863. package/treetable/treetable.js +383 -197
  864. package/treetable/treetable.min.js +1 -1
  865. package/tristatecheckbox/tristatecheckbox.cjs.js +97 -40
  866. package/tristatecheckbox/tristatecheckbox.cjs.min.js +1 -1
  867. package/tristatecheckbox/tristatecheckbox.d.ts +64 -1
  868. package/tristatecheckbox/tristatecheckbox.esm.js +99 -42
  869. package/tristatecheckbox/tristatecheckbox.esm.min.js +1 -1
  870. package/tristatecheckbox/tristatecheckbox.js +97 -42
  871. package/tristatecheckbox/tristatecheckbox.min.js +1 -1
  872. package/utils/utils.cjs.js +31 -5
  873. package/utils/utils.cjs.min.js +1 -1
  874. package/utils/utils.d.ts +1 -1
  875. package/utils/utils.esm.js +28 -5
  876. package/utils/utils.esm.min.js +1 -1
  877. package/utils/utils.js +32 -7
  878. package/utils/utils.min.js +1 -1
  879. package/virtualscroller/virtualscroller.cjs.js +43 -29
  880. package/virtualscroller/virtualscroller.cjs.min.js +1 -1
  881. package/virtualscroller/virtualscroller.d.ts +78 -1
  882. package/virtualscroller/virtualscroller.esm.js +44 -30
  883. package/virtualscroller/virtualscroller.esm.min.js +1 -1
  884. package/virtualscroller/virtualscroller.js +43 -31
  885. package/virtualscroller/virtualscroller.min.js +1 -1
  886. package/web-types.json +1 -1
@@ -5,11 +5,12 @@ Object.defineProperty(exports, '__esModule', { value: true });
5
5
  var React = require('react');
6
6
  var PrimeReact = require('primereact/api');
7
7
  var hooks = require('primereact/hooks');
8
- var ripple = require('primereact/ripple');
9
- var utils = require('primereact/utils');
10
- var angleright = require('primereact/icons/angleright');
11
8
  var angledown = require('primereact/icons/angledown');
9
+ var angleright = require('primereact/icons/angleright');
12
10
  var bars = require('primereact/icons/bars');
11
+ var ripple = require('primereact/ripple');
12
+ var utils = require('primereact/utils');
13
+ var componentbase = require('primereact/componentbase');
13
14
 
14
15
  function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
15
16
 
@@ -34,19 +35,45 @@ function _interopNamespace(e) {
34
35
  var React__namespace = /*#__PURE__*/_interopNamespace(React);
35
36
  var PrimeReact__default = /*#__PURE__*/_interopDefaultLegacy(PrimeReact);
36
37
 
37
- function _extends() {
38
- _extends = Object.assign ? Object.assign.bind() : function (target) {
39
- for (var i = 1; i < arguments.length; i++) {
40
- var source = arguments[i];
41
- for (var key in source) {
42
- if (Object.prototype.hasOwnProperty.call(source, key)) {
43
- target[key] = source[key];
44
- }
45
- }
46
- }
47
- return target;
48
- };
49
- return _extends.apply(this, arguments);
38
+ function _typeof(obj) {
39
+ "@babel/helpers - typeof";
40
+
41
+ return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
42
+ return typeof obj;
43
+ } : function (obj) {
44
+ return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
45
+ }, _typeof(obj);
46
+ }
47
+
48
+ function _toPrimitive(input, hint) {
49
+ if (_typeof(input) !== "object" || input === null) return input;
50
+ var prim = input[Symbol.toPrimitive];
51
+ if (prim !== undefined) {
52
+ var res = prim.call(input, hint || "default");
53
+ if (_typeof(res) !== "object") return res;
54
+ throw new TypeError("@@toPrimitive must return a primitive value.");
55
+ }
56
+ return (hint === "string" ? String : Number)(input);
57
+ }
58
+
59
+ function _toPropertyKey(arg) {
60
+ var key = _toPrimitive(arg, "string");
61
+ return _typeof(key) === "symbol" ? key : String(key);
62
+ }
63
+
64
+ function _defineProperty(obj, key, value) {
65
+ key = _toPropertyKey(key);
66
+ if (key in obj) {
67
+ Object.defineProperty(obj, key, {
68
+ value: value,
69
+ enumerable: true,
70
+ configurable: true,
71
+ writable: true
72
+ });
73
+ } else {
74
+ obj[key] = value;
75
+ }
76
+ return obj;
50
77
  }
51
78
 
52
79
  function _arrayWithHoles(arr) {
@@ -104,7 +131,7 @@ function _slicedToArray(arr, i) {
104
131
  return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();
105
132
  }
106
133
 
107
- var MegaMenuBase = {
134
+ var MegaMenuBase = componentbase.ComponentBase.extend({
108
135
  defaultProps: {
109
136
  __TYPE: 'MegaMenu',
110
137
  id: null,
@@ -119,17 +146,14 @@ var MegaMenuBase = {
119
146
  menuIcon: null,
120
147
  end: null,
121
148
  children: undefined
122
- },
123
- getProps: function getProps(props) {
124
- return utils.ObjectUtils.getMergedProps(props, MegaMenuBase.defaultProps);
125
- },
126
- getOtherProps: function getOtherProps(props) {
127
- return utils.ObjectUtils.getDiffProps(props, MegaMenuBase.defaultProps);
128
149
  }
129
- };
150
+ });
130
151
 
152
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
153
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
131
154
  var MegaMenu = /*#__PURE__*/React__namespace.memo( /*#__PURE__*/React__namespace.forwardRef(function (inProps, ref) {
132
- var props = MegaMenuBase.getProps(inProps);
155
+ var context = React__namespace.useContext(PrimeReact.PrimeReactContext);
156
+ var props = MegaMenuBase.getProps(inProps, context);
133
157
  var _React$useState = React__namespace.useState(null),
134
158
  _React$useState2 = _slicedToArray(_React$useState, 2),
135
159
  activeItemState = _React$useState2[0],
@@ -148,6 +172,22 @@ var MegaMenu = /*#__PURE__*/React__namespace.memo( /*#__PURE__*/React__namespace
148
172
  var horizontal = props.orientation === 'horizontal';
149
173
  var vertical = props.orientation === 'vertical';
150
174
  var isMobileMode = hooks.useMatchMedia("screen and (max-width: ".concat(props.breakpoint, ")"), !!props.breakpoint);
175
+ var _MegaMenuBase$setMeta = MegaMenuBase.setMetaData({
176
+ props: props,
177
+ state: {
178
+ activeItem: activeItemState,
179
+ attributeSelector: attributeSelectorState,
180
+ mobileActive: mobileActiveState
181
+ }
182
+ }),
183
+ ptm = _MegaMenuBase$setMeta.ptm;
184
+ var getPTOptions = function getPTOptions(item, key) {
185
+ return ptm(key, {
186
+ context: {
187
+ active: activeItemState === item
188
+ }
189
+ });
190
+ };
151
191
  var _useEventListener = hooks.useEventListener({
152
192
  type: 'click',
153
193
  listener: function listener(event) {
@@ -316,7 +356,7 @@ var MegaMenu = /*#__PURE__*/React__namespace.memo( /*#__PURE__*/React__namespace
316
356
  hooks.useUpdateEffect(function () {
317
357
  var currentPanel = utils.DomHandler.findSingle(elementRef.current, '.p-menuitem-active > .p-megamenu-panel');
318
358
  if (activeItemState && !isMobileMode) {
319
- utils.ZIndexUtils.set('menu', currentPanel, PrimeReact__default["default"].autoZIndex, PrimeReact__default["default"].zIndex['menu']);
359
+ utils.ZIndexUtils.set('menu', currentPanel, context && context.autoZIndex || PrimeReact__default["default"].autoZIndex, context && context.zIndex['menu'] || PrimeReact__default["default"].zIndex['menu']);
320
360
  }
321
361
  if (isMobileMode) {
322
362
  currentPanel && currentPanel.previousElementSibling.scrollIntoView({
@@ -330,23 +370,21 @@ var MegaMenu = /*#__PURE__*/React__namespace.memo( /*#__PURE__*/React__namespace
330
370
  }, [activeItemState]);
331
371
  var createSeparator = function createSeparator(index) {
332
372
  var key = 'separator_' + index;
333
- return /*#__PURE__*/React__namespace.createElement("li", {
373
+ var separatorProps = utils.mergeProps({
334
374
  key: key,
335
- className: "p-menu-separator",
336
- role: "separator"
337
- });
375
+ className: 'p-menu-separator',
376
+ role: 'separator'
377
+ }, ptm('separator'));
378
+ return /*#__PURE__*/React__namespace.createElement("li", separatorProps);
338
379
  };
339
380
  var createSubmenuIcon = function createSubmenuIcon(item) {
340
381
  if (item.items) {
341
382
  var iconClassName = 'p-submenu-icon';
342
- var icon = vertical ? props.submenuIcon || /*#__PURE__*/React__namespace.createElement(angleright.AngleRightIcon, {
343
- className: iconClassName
344
- }) : props.submenuIcon || /*#__PURE__*/React__namespace.createElement(angledown.AngleDownIcon, {
345
- className: iconClassName
346
- });
347
- var submenuIcon = utils.IconUtils.getJSXIcon(icon, {
383
+ var submenuIconProps = utils.mergeProps({
348
384
  className: iconClassName
349
- }, {
385
+ }, ptm('submenuIcon'));
386
+ var icon = vertical ? props.submenuIcon || /*#__PURE__*/React__namespace.createElement(angleright.AngleRightIcon, submenuIconProps) : props.submenuIcon || /*#__PURE__*/React__namespace.createElement(angledown.AngleDownIcon, submenuIconProps);
387
+ var submenuIcon = utils.IconUtils.getJSXIcon(icon, _objectSpread({}, submenuIconProps), {
350
388
  props: props
351
389
  });
352
390
  return submenuIcon;
@@ -374,16 +412,24 @@ var MegaMenu = /*#__PURE__*/React__namespace.memo( /*#__PURE__*/React__namespace
374
412
  var label = item.label && /*#__PURE__*/React__namespace.createElement("span", {
375
413
  className: "p-menuitem-text"
376
414
  }, item.label);
377
- var content = /*#__PURE__*/React__namespace.createElement("a", {
415
+ var actionProps = utils.mergeProps({
378
416
  href: item.url || '#',
379
417
  className: linkClassName,
380
418
  target: item.target,
381
419
  onClick: function onClick(event) {
382
420
  return onLeafClick(event, item);
383
421
  },
384
- role: "menuitem",
385
- "aria-disabled": item.disabled
386
- }, icon, label, /*#__PURE__*/React__namespace.createElement(ripple.Ripple, null));
422
+ role: 'menuitem',
423
+ 'aria-disabled': item.disabled
424
+ }, getPTOptions(item, 'action'));
425
+ var submenuItemProps = utils.mergeProps({
426
+ key: key,
427
+ id: item.id,
428
+ className: _className,
429
+ style: item.style,
430
+ role: 'none'
431
+ }, getPTOptions(item, 'submenuItem'));
432
+ var content = /*#__PURE__*/React__namespace.createElement("a", actionProps, icon, label, /*#__PURE__*/React__namespace.createElement(ripple.Ripple, null));
387
433
  if (item.template) {
388
434
  var defaultContentOptions = {
389
435
  onClick: function onClick(event) {
@@ -397,13 +443,7 @@ var MegaMenu = /*#__PURE__*/React__namespace.memo( /*#__PURE__*/React__namespace
397
443
  };
398
444
  content = utils.ObjectUtils.getJSXElement(item.template, item, defaultContentOptions);
399
445
  }
400
- return /*#__PURE__*/React__namespace.createElement("li", {
401
- key: key,
402
- id: item.id,
403
- className: _className,
404
- style: item.style,
405
- role: "none"
406
- }, content);
446
+ return /*#__PURE__*/React__namespace.createElement("li", submenuItemProps, content);
407
447
  }
408
448
  };
409
449
  var createSubmenu = function createSubmenu(submenu) {
@@ -414,14 +454,15 @@ var MegaMenu = /*#__PURE__*/React__namespace.memo( /*#__PURE__*/React__namespace
414
454
  'p-disabled': submenu.disabled
415
455
  }, submenu.className);
416
456
  var items = submenu.items.map(createSubmenuItem);
417
- return /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, {
418
- key: submenu.label
419
- }, /*#__PURE__*/React__namespace.createElement("li", {
457
+ var submenuHeaderProps = utils.mergeProps({
420
458
  id: submenu.id,
421
459
  className: className,
422
460
  style: submenu.style,
423
- role: "presentation"
424
- }, submenu.label), items);
461
+ role: 'presentation'
462
+ }, ptm('submenuHeader'));
463
+ return /*#__PURE__*/React__namespace.createElement(React__namespace.Fragment, {
464
+ key: submenu.label
465
+ }, /*#__PURE__*/React__namespace.createElement("li", submenuHeaderProps, submenu.label), items);
425
466
  };
426
467
  var createSubmenus = function createSubmenus(column) {
427
468
  return column.map(createSubmenu);
@@ -429,13 +470,15 @@ var MegaMenu = /*#__PURE__*/React__namespace.memo( /*#__PURE__*/React__namespace
429
470
  var createColumn = function createColumn(category, column, index, columnClassName) {
430
471
  var key = category.label + '_column_' + index;
431
472
  var submenus = createSubmenus(column);
432
- return /*#__PURE__*/React__namespace.createElement("div", {
473
+ var columnProps = utils.mergeProps({
433
474
  key: key,
434
475
  className: columnClassName
435
- }, /*#__PURE__*/React__namespace.createElement("ul", {
436
- className: "p-megamenu-submenu",
437
- role: "menu"
438
- }, submenus));
476
+ }, ptm('column'));
477
+ var submenuProps = utils.mergeProps({
478
+ className: 'p-megamenu-submenu',
479
+ role: 'menu'
480
+ }, ptm('submenu'));
481
+ return /*#__PURE__*/React__namespace.createElement("div", columnProps, /*#__PURE__*/React__namespace.createElement("ul", submenuProps, submenus));
439
482
  };
440
483
  var createColumns = function createColumns(category) {
441
484
  if (category.items) {
@@ -449,17 +492,19 @@ var MegaMenu = /*#__PURE__*/React__namespace.memo( /*#__PURE__*/React__namespace
449
492
  var createCategoryPanel = function createCategoryPanel(category) {
450
493
  if (category.items) {
451
494
  var columns = createColumns(category);
452
- return /*#__PURE__*/React__namespace.createElement("div", {
453
- className: "p-megamenu-panel"
454
- }, /*#__PURE__*/React__namespace.createElement("div", {
455
- className: "p-megamenu-grid"
456
- }, columns));
495
+ var panelProps = utils.mergeProps({
496
+ className: 'p-megamenu-panel'
497
+ }, ptm('panel'));
498
+ var gridProps = utils.mergeProps({
499
+ className: 'p-megamenu-grid'
500
+ }, ptm('grid'));
501
+ return /*#__PURE__*/React__namespace.createElement("div", panelProps, /*#__PURE__*/React__namespace.createElement("div", gridProps, columns));
457
502
  }
458
503
  return null;
459
504
  };
460
505
  var createStyle = function createStyle() {
461
506
  if (!styleElementRef.current) {
462
- styleElementRef.current = utils.DomHandler.createInlineStyle(PrimeReact__default["default"].nonce);
507
+ styleElementRef.current = utils.DomHandler.createInlineStyle(context && context.nonce || PrimeReact__default["default"].nonce);
463
508
  var selector = "".concat(attributeSelectorState);
464
509
  var innerHTML = "\n@media screen and (max-width: ".concat(props.breakpoint, ") {\n .p-megamenu[").concat(selector, "] > .p-megamenu-root-list .p-menuitem-active .p-megamenu-panel {\n position: relative;\n left: 0 !important;\n box-shadow: none;\n border-radius: 0;\n background: inherit;\n }\n\n .p-megamenu[").concat(selector, "] .p-menuitem-active > .p-menuitem-link > .p-submenu-icon {\n transform: rotate(-180deg);\n }\n\n .p-megamenu[").concat(selector, "] .p-megamenu-grid {\n flex-wrap: wrap;\n }\n\n ").concat(horizontal ? "\n.p-megamenu[".concat(selector, "] .p-megamenu-button {\n display: flex;\n}\n\n.p-megamenu[").concat(selector, "].p-megamenu-horizontal {\n position: relative;\n}\n\n.p-megamenu[").concat(selector, "].p-megamenu-horizontal .p-megamenu-root-list {\n display: none;\n}\n\n.p-megamenu-horizontal[").concat(selector, "] div[class*=\"p-megamenu-col-\"] {\n width: auto;\n flex: 1;\n padding: 0;\n}\n\n.p-megamenu[").concat(selector, "].p-megamenu-mobile-active .p-megamenu-root-list {\n display: flex;\n flex-direction: column;\n position: absolute;\n width: 100%;\n top: 100%;\n left: 0;\n z-index: 1;\n}\n ") : '', "\n\n ").concat(vertical ? "\n.p-megamenu-vertical[".concat(selector, "] {\n width: 100%;\n}\n\n.p-megamenu-vertical[").concat(selector, "] .p-megamenu-root-list {\n max-height: ").concat(props.scrollHeight, ";\n overflow: ").concat(props.scrollHeight ? 'auto' : '', ";\n}\n.p-megamenu-vertical[").concat(selector, "] div[class*=\"p-megamenu-col-\"] {\n width: 100%;\n padding: 0;\n}\n\n.p-megamenu-vertical[").concat(selector, "] .p-megamenu-submenu {\n width: 100%;\n}\n\n.p-megamenu-vertical[").concat(selector, "] div[class*=\"p-megamenu-col-\"] .p-megamenu-submenu-header {\n background: inherit;\n}\n\n.p-megamenu-vertical[").concat(selector, "] .p-submenu-icon:before {\n content: \"\\e930\";\n}\n ") : '', "\n}\n");
465
510
  styleElementRef.current.innerHTML = innerHTML;
@@ -484,27 +529,20 @@ var MegaMenu = /*#__PURE__*/React__namespace.memo( /*#__PURE__*/React__namespace
484
529
  var linkClassName = utils.classNames('p-menuitem-link', {
485
530
  'p-disabled': category.disabled
486
531
  });
487
- var icon = utils.IconUtils.getJSXIcon(category.icon, {
532
+ var iconProps = utils.mergeProps({
488
533
  className: 'p-menuitem-icon'
489
- }, {
534
+ }, getPTOptions(category, 'icon'));
535
+ var icon = utils.IconUtils.getJSXIcon(category.icon, _objectSpread({}, iconProps), {
490
536
  props: props
491
537
  });
492
- var label = category.label && /*#__PURE__*/React__namespace.createElement("span", {
493
- className: "p-menuitem-text"
494
- }, category.label);
538
+ var labelProps = utils.mergeProps({
539
+ className: 'p-menuitem-text'
540
+ }, getPTOptions(category, 'label'));
541
+ var label = category.label && /*#__PURE__*/React__namespace.createElement("span", labelProps, category.label);
495
542
  var itemContent = category.template ? utils.ObjectUtils.getJSXElement(category.template, category) : null;
496
543
  var submenuIcon = createSubmenuIcon(category);
497
544
  var panel = createCategoryPanel(category);
498
- return /*#__PURE__*/React__namespace.createElement("li", {
499
- key: category.label + '_' + index,
500
- id: category.id,
501
- className: className,
502
- style: category.style,
503
- onMouseEnter: function onMouseEnter(e) {
504
- return onCategoryMouseEnter(e, category);
505
- },
506
- role: "none"
507
- }, /*#__PURE__*/React__namespace.createElement("a", {
545
+ var headerActionProps = utils.mergeProps({
508
546
  href: category.url || '#',
509
547
  className: linkClassName,
510
548
  target: category.target,
@@ -514,36 +552,50 @@ var MegaMenu = /*#__PURE__*/React__namespace.memo( /*#__PURE__*/React__namespace
514
552
  onKeyDown: function onKeyDown(e) {
515
553
  return onCategoryKeyDown(e, category);
516
554
  },
517
- role: "menuitem",
518
- "aria-haspopup": category.items != null
519
- }, icon, label, itemContent, submenuIcon, /*#__PURE__*/React__namespace.createElement(ripple.Ripple, null)), panel);
555
+ role: 'menuitem',
556
+ 'aria-haspopup': category.items != null
557
+ }, getPTOptions(category, 'headerAction'));
558
+ var menuItemProps = utils.mergeProps({
559
+ key: category.label + '_' + index,
560
+ id: category.id,
561
+ className: className,
562
+ style: category.style,
563
+ onMouseEnter: function onMouseEnter(e) {
564
+ return onCategoryMouseEnter(e, category);
565
+ },
566
+ role: 'none'
567
+ }, getPTOptions(category, 'menuitem'));
568
+ return /*#__PURE__*/React__namespace.createElement("li", menuItemProps, /*#__PURE__*/React__namespace.createElement("a", headerActionProps, icon, label, itemContent, submenuIcon, /*#__PURE__*/React__namespace.createElement(ripple.Ripple, null)), panel);
520
569
  };
521
570
  var createMenu = function createMenu() {
571
+ var menuProps = utils.mergeProps({
572
+ className: 'p-megamenu-root-list',
573
+ role: 'menubar'
574
+ }, ptm('menu'));
522
575
  if (props.model) {
523
- return /*#__PURE__*/React__namespace.createElement("ul", {
524
- className: "p-megamenu-root-list",
525
- role: "menubar"
526
- }, props.model.map(function (item, index) {
576
+ return /*#__PURE__*/React__namespace.createElement("ul", menuProps, props.model.map(function (item, index) {
527
577
  return createCategory(item, index);
528
578
  }));
529
579
  }
530
580
  return null;
531
581
  };
532
582
  var createStartContent = function createStartContent() {
583
+ var startProps = utils.mergeProps({
584
+ className: 'p-megamenu-start'
585
+ }, ptm('start'));
533
586
  if (props.start) {
534
587
  var _start = utils.ObjectUtils.getJSXElement(props.start, props);
535
- return /*#__PURE__*/React__namespace.createElement("div", {
536
- className: "p-megamenu-start"
537
- }, _start);
588
+ return /*#__PURE__*/React__namespace.createElement("div", startProps, _start);
538
589
  }
539
590
  return null;
540
591
  };
541
592
  var createEndContent = function createEndContent() {
593
+ var endProps = utils.mergeProps({
594
+ className: 'p-megamenu-end'
595
+ }, ptm('end'));
542
596
  if (props.end) {
543
597
  var _end = utils.ObjectUtils.getJSXElement(props.end, props);
544
- return /*#__PURE__*/React__namespace.createElement("div", {
545
- className: "p-megamenu-end"
546
- }, _end);
598
+ return /*#__PURE__*/React__namespace.createElement("div", endProps, _end);
547
599
  }
548
600
  return null;
549
601
  };
@@ -568,22 +620,22 @@ var MegaMenu = /*#__PURE__*/React__namespace.memo( /*#__PURE__*/React__namespace
568
620
 
569
621
  return button;
570
622
  };
571
- var otherProps = MegaMenuBase.getOtherProps(props);
572
623
  var className = utils.classNames('p-megamenu p-component', {
573
624
  'p-megamenu-horizontal': props.orientation === 'horizontal',
574
625
  'p-megamenu-vertical': props.orientation === 'vertical',
575
626
  'p-megamenu-mobile-active': mobileActiveState
576
627
  }, props.className);
577
- var menu = createMenu();
578
- var start = createStartContent();
579
- var end = createEndContent();
580
- var menuButton = createMenuButton();
581
- return /*#__PURE__*/React__namespace.createElement("div", _extends({
628
+ var rootProps = utils.mergeProps({
582
629
  ref: elementRef,
583
630
  id: props.id,
584
631
  className: className,
585
632
  style: props.style
586
- }, otherProps), start, menuButton, menu, end);
633
+ }, MegaMenuBase.getOtherProps(props), ptm('root'));
634
+ var menu = createMenu();
635
+ var start = createStartContent();
636
+ var end = createEndContent();
637
+ var menuButton = createMenuButton();
638
+ return /*#__PURE__*/React__namespace.createElement("div", rootProps, start, menuButton, menu, end);
587
639
  }));
588
640
  MegaMenu.displayName = 'MegaMenu';
589
641
 
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),n=require("primereact/api"),t=require("primereact/hooks"),r=require("primereact/ripple"),a=require("primereact/utils"),l=require("primereact/icons/angleright"),i=require("primereact/icons/angledown"),u=require("primereact/icons/bars");function o(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function c(e){if(e&&e.__esModule)return e;var n=Object.create(null);return e&&Object.keys(e).forEach((function(t){if("default"!==t){var r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(n,t,r.get?r:{enumerable:!0,get:function(){return e[t]}})}})),n.default=e,Object.freeze(n)}var m=c(e),s=o(n);function p(){return p=Object.assign?Object.assign.bind():function(e){for(var n=1;n<arguments.length;n++){var t=arguments[n];for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])}return e},p.apply(this,arguments)}function f(e){if(Array.isArray(e))return e}function d(e,n){var t=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=t){var r,a,l,i,u=[],o=!0,c=!1;try{if(l=(t=t.call(e)).next,0===n){if(Object(t)!==t)return;o=!1}else for(;!(o=(r=l.call(t)).done)&&(u.push(r.value),u.length!==n);o=!0);}catch(e){c=!0,a=e}finally{try{if(!o&&null!=t.return&&(i=t.return(),Object(i)!==i))return}finally{if(c)throw a}}return u}}function g(e,n){(null==n||n>e.length)&&(n=e.length);for(var t=0,r=new Array(n);t<n;t++)r[t]=e[t];return r}function b(e,n){if(e){if("string"==typeof e)return g(e,n);var t=Object.prototype.toString.call(e).slice(8,-1);return"Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t?Array.from(e):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?g(e,n):void 0}}function v(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function h(e,n){return f(e)||d(e,n)||b(e,n)||v()}var y={defaultProps:{__TYPE:"MegaMenu",id:null,model:null,style:null,className:null,orientation:"horizontal",breakpoint:void 0,scrollHeight:"400px",start:null,submenuIcon:null,menuIcon:null,end:null,children:void 0},getProps:function(e){return a.ObjectUtils.getMergedProps(e,y.defaultProps)},getOtherProps:function(e){return a.ObjectUtils.getDiffProps(e,y.defaultProps)}},E=m.memo(m.forwardRef((function(e,n){var o=y.getProps(e),c=h(m.useState(null),2),f=c[0],d=c[1],g=h(m.useState(null),2),b=g[0],v=g[1],E=h(m.useState(!1),2),N=E[0],k=E[1],I=m.useRef(null),w=m.useRef(null),x=m.useRef(null),O="horizontal"===o.orientation,S="vertical"===o.orientation,j=t.useMatchMedia("screen and (max-width: ".concat(o.breakpoint,")"),!!o.breakpoint),D=h(t.useEventListener({type:"click",listener:function(e){j&&!N||!R(e)||(d(null),k(!1))}}),1)[0],U=h(t.useResizeListener({listener:function(){j&&!N||(d(null),k(!1))}}),1)[0],M=function(e,n){n.disabled?e.preventDefault():(n.url||e.preventDefault(),n.command&&n.command({originalEvent:e,item:n}),d(null),k(!1))},P=function(e,n){var t=e.currentTarget.parentElement;switch(e.which){case 40:O?C(n):A(t),e.preventDefault();break;case 38:S?J(t):n.items&&n===f&&H(),e.preventDefault();break;case 39:O?A(t):C(n),e.preventDefault();break;case 37:O?J(t):n.items&&n===f&&H(),e.preventDefault()}},C=function(e){e.items&&d(e)},H=function(e){d(null)},z=function(e){e.preventDefault(),k((function(e){return!e})),d(null)},_=function e(n){var t=n.nextElementSibling;return t?a.DomHandler.hasClass(t,"p-disabled")||!a.DomHandler.hasClass(t,"p-menuitem")?e(t):t:null},q=function e(n){var t=n.previousElementSibling;return t?a.DomHandler.hasClass(t,"p-disabled")||!a.DomHandler.hasClass(t,"p-menuitem")?e(t):t:null},A=function(e){var n=_(e);n&&n.children[0].focus()},J=function(e){var n=q(e);n&&n.children[0].focus()},R=function(e){return I.current&&!(I.current.isSameNode(e.target)||I.current.contains(e.target)||x.current&&x.current.contains(e.target))},X=function(e){var n;switch(e.items?e.items.length:0){case 2:n="p-megamenu-col-6";break;case 3:n="p-megamenu-col-4";break;case 4:n="p-megamenu-col-3";break;case 6:n="p-megamenu-col-2";break;default:n="p-megamenu-col-12"}return n};m.useImperativeHandle(n,(function(){return{props:o,getElement:function(){return I.current}}})),t.useMountEffect((function(){o.breakpoint&&!b&&v(a.UniqueComponentId()),D(),U()})),t.useUpdateEffect((function(){var e=a.DomHandler.findSingle(I.current,".p-menuitem-active > .p-megamenu-panel");return f&&!j&&a.ZIndexUtils.set("menu",e,s.default.autoZIndex,s.default.zIndex.menu),j&&e&&e.previousElementSibling.scrollIntoView({block:"nearest",inline:"nearest"}),function(){a.ZIndexUtils.clear(e)}}),[f]);var T=function(e){return m.createElement("li",{key:"separator_"+e,className:"p-menu-separator",role:"separator"})},L=function(e){if(e.items){var n="p-submenu-icon";return a.IconUtils.getJSXIcon(S?o.submenuIcon||m.createElement(l.AngleRightIcon,{className:n}):o.submenuIcon||m.createElement(i.AngleDownIcon,{className:n}),{className:n},{props:o})}return null},Z=function(e,n){if(!1===e.visible)return null;if(e.separator)return T(n);var t=e.label+"_"+n,l=a.classNames("p-menuitem",e.className),i=a.classNames("p-menuitem-link",{"p-disabled":e.disabled}),u=a.classNames(e.icon,"p-menuitem-icon"),c=a.IconUtils.getJSXIcon(e.icon,{className:"p-menuitem-icon"},{props:o}),s=m.createElement("a",{href:e.url||"#",className:i,target:e.target,onClick:function(n){return M(n,e)},role:"menuitem","aria-disabled":e.disabled},c,e.label&&m.createElement("span",{className:"p-menuitem-text"},e.label),m.createElement(r.Ripple,null));return e.template&&(s=a.ObjectUtils.getJSXElement(e.template,e,{onClick:function(n){return M(n,e)},className:i,labelClassName:"p-menuitem-text",iconClassName:u,element:s,props:o})),m.createElement("li",{key:t,id:e.id,className:l,style:e.style,role:"none"},s)},B=function(e){if(!1===e.visible)return null;var n=a.classNames("p-megamenu-submenu-header",{"p-disabled":e.disabled},e.className),t=e.items.map(Z);return m.createElement(m.Fragment,{key:e.label},m.createElement("li",{id:e.id,className:n,style:e.style,role:"presentation"},e.label),t)},F=function(e){return e.map(B)},K=function(e,n,t,r){var a=e.label+"_column_"+t,l=F(n);return m.createElement("div",{key:a,className:r},m.createElement("ul",{className:"p-megamenu-submenu",role:"menu"},l))},V=function(e){if(e.items){var n=X(e);return e.items.map((function(t,r){return K(e,t,r,n)}))}return null},Y=function(e){if(e.items){var n=V(e);return m.createElement("div",{className:"p-megamenu-panel"},m.createElement("div",{className:"p-megamenu-grid"},n))}return null},$=function(){if(!w.current){w.current=a.DomHandler.createInlineStyle(s.default.nonce);var e="".concat(b),n="\n@media screen and (max-width: ".concat(o.breakpoint,") {\n .p-megamenu[").concat(e,"] > .p-megamenu-root-list .p-menuitem-active .p-megamenu-panel {\n position: relative;\n left: 0 !important;\n box-shadow: none;\n border-radius: 0;\n background: inherit;\n }\n\n .p-megamenu[").concat(e,"] .p-menuitem-active > .p-menuitem-link > .p-submenu-icon {\n transform: rotate(-180deg);\n }\n\n .p-megamenu[").concat(e,"] .p-megamenu-grid {\n flex-wrap: wrap;\n }\n\n ").concat(O?"\n.p-megamenu[".concat(e,"] .p-megamenu-button {\n display: flex;\n}\n\n.p-megamenu[").concat(e,"].p-megamenu-horizontal {\n position: relative;\n}\n\n.p-megamenu[").concat(e,"].p-megamenu-horizontal .p-megamenu-root-list {\n display: none;\n}\n\n.p-megamenu-horizontal[").concat(e,'] div[class*="p-megamenu-col-"] {\n width: auto;\n flex: 1;\n padding: 0;\n}\n\n.p-megamenu[').concat(e,"].p-megamenu-mobile-active .p-megamenu-root-list {\n display: flex;\n flex-direction: column;\n position: absolute;\n width: 100%;\n top: 100%;\n left: 0;\n z-index: 1;\n}\n "):"","\n\n ").concat(S?"\n.p-megamenu-vertical[".concat(e,"] {\n width: 100%;\n}\n\n.p-megamenu-vertical[").concat(e,"] .p-megamenu-root-list {\n max-height: ").concat(o.scrollHeight,";\n overflow: ").concat(o.scrollHeight?"auto":"",";\n}\n.p-megamenu-vertical[").concat(e,'] div[class*="p-megamenu-col-"] {\n width: 100%;\n padding: 0;\n}\n\n.p-megamenu-vertical[').concat(e,"] .p-megamenu-submenu {\n width: 100%;\n}\n\n.p-megamenu-vertical[").concat(e,'] div[class*="p-megamenu-col-"] .p-megamenu-submenu-header {\n background: inherit;\n}\n\n.p-megamenu-vertical[').concat(e,'] .p-submenu-icon:before {\n content: "\\e930";\n}\n '):"","\n}\n");w.current.innerHTML=n}};t.useUpdateEffect((function(){return b&&I.current&&(I.current.setAttribute(b,""),$()),function(){w.current=a.DomHandler.removeInlineStyle(w.current)}}),[b,o.breakpoint]);var G=function(e,n){var t=a.classNames("p-menuitem",{"p-menuitem-active":e===f},e.className),l=a.classNames("p-menuitem-link",{"p-disabled":e.disabled}),i=a.IconUtils.getJSXIcon(e.icon,{className:"p-menuitem-icon"},{props:o}),u=e.label&&m.createElement("span",{className:"p-menuitem-text"},e.label),c=e.template?a.ObjectUtils.getJSXElement(e.template,e):null,s=L(e),p=Y(e);return m.createElement("li",{key:e.label+"_"+n,id:e.id,className:t,style:e.style,onMouseEnter:function(n){return t=n,void((r=e).disabled||j?t.preventDefault():f&&d(r));var t,r},role:"none"},m.createElement("a",{href:e.url||"#",className:l,target:e.target,onClick:function(n){return t=n,(r=e).disabled||(r.url||t.preventDefault(),r.command&&r.command({originalEvent:t,item:o.item}),r.items&&d(f&&f===r?null:r)),void t.preventDefault();var t,r},onKeyDown:function(n){return P(n,e)},role:"menuitem","aria-haspopup":null!=e.items},i,u,c,s,m.createElement(r.Ripple,null)),p)},Q=y.getOtherProps(o),W=a.classNames("p-megamenu p-component",{"p-megamenu-horizontal":"horizontal"===o.orientation,"p-megamenu-vertical":"vertical"===o.orientation,"p-megamenu-mobile-active":N},o.className),ee=o.model?m.createElement("ul",{className:"p-megamenu-root-list",role:"menubar"},o.model.map((function(e,n){return G(e,n)}))):null,ne=function(){if(o.start){var e=a.ObjectUtils.getJSXElement(o.start,o);return m.createElement("div",{className:"p-megamenu-start"},e)}return null}(),te=function(){if(o.end){var e=a.ObjectUtils.getJSXElement(o.end,o);return m.createElement("div",{className:"p-megamenu-end"},e)}return null}(),re=function(){if("vertical"===o.orientation||o.model&&o.model.length<1)return null;var e=a.IconUtils.getJSXIcon(o.menuIcon||m.createElement(u.BarsIcon,null),void 0,{props:o});return m.createElement("a",{ref:x,href:"#",role:"button",tabIndex:0,className:"p-megamenu-button",onClick:z},e)}();return m.createElement("div",p({ref:I,id:o.id,className:W,style:o.style},Q),ne,re,ee,te)})));E.displayName="MegaMenu",exports.MegaMenu=E;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),n=require("primereact/api"),t=require("primereact/hooks"),r=require("primereact/icons/angledown"),a=require("primereact/icons/angleright"),l=require("primereact/icons/bars"),i=require("primereact/ripple"),o=require("primereact/utils"),u=require("primereact/componentbase");function c(e){return e&&"object"==typeof e&&"default"in e?e:{default:e}}function m(e){if(e&&e.__esModule)return e;var n=Object.create(null);return e&&Object.keys(e).forEach((function(t){if("default"!==t){var r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(n,t,r.get?r:{enumerable:!0,get:function(){return e[t]}})}})),n.default=e,Object.freeze(n)}var s=m(e),p=c(n);function f(e){return f="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},f(e)}function d(e,n){if("object"!==f(e)||null===e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,n||"default");if("object"!==f(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===n?String:Number)(e)}function g(e){var n=d(e,"string");return"symbol"===f(n)?n:String(n)}function b(e,n,t){return(n=g(n))in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function v(e){if(Array.isArray(e))return e}function y(e,n){var t=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=t){var r,a,l,i,o=[],u=!0,c=!1;try{if(l=(t=t.call(e)).next,0===n){if(Object(t)!==t)return;u=!1}else for(;!(u=(r=l.call(t)).done)&&(o.push(r.value),o.length!==n);u=!0);}catch(e){c=!0,a=e}finally{try{if(!u&&null!=t.return&&(i=t.return(),Object(i)!==i))return}finally{if(c)throw a}}return o}}function h(e,n){(null==n||n>e.length)&&(n=e.length);for(var t=0,r=new Array(n);t<n;t++)r[t]=e[t];return r}function E(e,n){if(e){if("string"==typeof e)return h(e,n);var t=Object.prototype.toString.call(e).slice(8,-1);return"Object"===t&&e.constructor&&(t=e.constructor.name),"Map"===t||"Set"===t?Array.from(e):"Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t)?h(e,n):void 0}}function N(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}function P(e,n){return v(e)||y(e,n)||E(e,n)||N()}var I=u.ComponentBase.extend({defaultProps:{__TYPE:"MegaMenu",id:null,model:null,style:null,className:null,orientation:"horizontal",breakpoint:void 0,scrollHeight:"400px",start:null,submenuIcon:null,menuIcon:null,end:null,children:void 0}});function O(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function S(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?O(Object(t),!0).forEach((function(n){b(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):O(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}var w=s.memo(s.forwardRef((function(e,u){var c=s.useContext(n.PrimeReactContext),m=I.getProps(e,c),f=P(s.useState(null),2),d=f[0],g=f[1],b=P(s.useState(null),2),v=b[0],y=b[1],h=P(s.useState(!1),2),E=h[0],N=h[1],O=s.useRef(null),w=s.useRef(null),k=s.useRef(null),j="horizontal"===m.orientation,x="vertical"===m.orientation,D=t.useMatchMedia("screen and (max-width: ".concat(m.breakpoint,")"),!!m.breakpoint),C=I.setMetaData({props:m,state:{activeItem:d,attributeSelector:v,mobileActive:E}}).ptm,M=function(e,n){return C(n,{context:{active:d===e}})},U=P(t.useEventListener({type:"click",listener:function(e){D&&!E||!L(e)||(g(null),N(!1))}}),1)[0],H=P(t.useResizeListener({listener:function(){D&&!E||(g(null),N(!1))}}),1)[0],z=function(e,n){n.disabled?e.preventDefault():(n.url||e.preventDefault(),n.command&&n.command({originalEvent:e,item:n}),g(null),N(!1))},A=function(e,n){var t=e.currentTarget.parentElement;switch(e.which){case 40:j?_(n):T(t),e.preventDefault();break;case 38:x?Z(t):n.items&&n===d&&q(),e.preventDefault();break;case 39:j?T(t):_(n),e.preventDefault();break;case 37:j?Z(t):n.items&&n===d&&q(),e.preventDefault()}},_=function(e){e.items&&g(e)},q=function(e){g(null)},R=function(e){e.preventDefault(),N((function(e){return!e})),g(null)},J=function e(n){var t=n.nextElementSibling;return t?o.DomHandler.hasClass(t,"p-disabled")||!o.DomHandler.hasClass(t,"p-menuitem")?e(t):t:null},X=function e(n){var t=n.previousElementSibling;return t?o.DomHandler.hasClass(t,"p-disabled")||!o.DomHandler.hasClass(t,"p-menuitem")?e(t):t:null},T=function(e){var n=J(e);n&&n.children[0].focus()},Z=function(e){var n=X(e);n&&n.children[0].focus()},L=function(e){return O.current&&!(O.current.isSameNode(e.target)||O.current.contains(e.target)||k.current&&k.current.contains(e.target))},B=function(e){var n;switch(e.items?e.items.length:0){case 2:n="p-megamenu-col-6";break;case 3:n="p-megamenu-col-4";break;case 4:n="p-megamenu-col-3";break;case 6:n="p-megamenu-col-2";break;default:n="p-megamenu-col-12"}return n};s.useImperativeHandle(u,(function(){return{props:m,getElement:function(){return O.current}}})),t.useMountEffect((function(){m.breakpoint&&!v&&y(o.UniqueComponentId()),U(),H()})),t.useUpdateEffect((function(){var e=o.DomHandler.findSingle(O.current,".p-menuitem-active > .p-megamenu-panel");return d&&!D&&o.ZIndexUtils.set("menu",e,c&&c.autoZIndex||p.default.autoZIndex,c&&c.zIndex.menu||p.default.zIndex.menu),D&&e&&e.previousElementSibling.scrollIntoView({block:"nearest",inline:"nearest"}),function(){o.ZIndexUtils.clear(e)}}),[d]);var F=function(e){var n=o.mergeProps({key:"separator_"+e,className:"p-menu-separator",role:"separator"},C("separator"));return s.createElement("li",n)},K=function(e){if(e.items){var n=o.mergeProps({className:"p-submenu-icon"},C("submenuIcon"));return o.IconUtils.getJSXIcon(x?m.submenuIcon||s.createElement(a.AngleRightIcon,n):m.submenuIcon||s.createElement(r.AngleDownIcon,n),S({},n),{props:m})}return null},V=function(e,n){if(!1===e.visible)return null;if(e.separator)return F(n);var t=e.label+"_"+n,r=o.classNames("p-menuitem",e.className),a=o.classNames("p-menuitem-link",{"p-disabled":e.disabled}),l=o.classNames(e.icon,"p-menuitem-icon"),u=o.IconUtils.getJSXIcon(e.icon,{className:"p-menuitem-icon"},{props:m}),c=e.label&&s.createElement("span",{className:"p-menuitem-text"},e.label),p=o.mergeProps({href:e.url||"#",className:a,target:e.target,onClick:function(n){return z(n,e)},role:"menuitem","aria-disabled":e.disabled},M(e,"action")),f=o.mergeProps({key:t,id:e.id,className:r,style:e.style,role:"none"},M(e,"submenuItem")),d=s.createElement("a",p,u,c,s.createElement(i.Ripple,null));return e.template&&(d=o.ObjectUtils.getJSXElement(e.template,e,{onClick:function(n){return z(n,e)},className:a,labelClassName:"p-menuitem-text",iconClassName:l,element:d,props:m})),s.createElement("li",f,d)},Y=function(e){if(!1===e.visible)return null;var n=o.classNames("p-megamenu-submenu-header",{"p-disabled":e.disabled},e.className),t=e.items.map(V),r=o.mergeProps({id:e.id,className:n,style:e.style,role:"presentation"},C("submenuHeader"));return s.createElement(s.Fragment,{key:e.label},s.createElement("li",r,e.label),t)},$=function(e){return e.map(Y)},G=function(e,n,t,r){var a=e.label+"_column_"+t,l=$(n),i=o.mergeProps({key:a,className:r},C("column")),u=o.mergeProps({className:"p-megamenu-submenu",role:"menu"},C("submenu"));return s.createElement("div",i,s.createElement("ul",u,l))},Q=function(e){if(e.items){var n=B(e);return e.items.map((function(t,r){return G(e,t,r,n)}))}return null},W=function(e){if(e.items){var n=Q(e),t=o.mergeProps({className:"p-megamenu-panel"},C("panel")),r=o.mergeProps({className:"p-megamenu-grid"},C("grid"));return s.createElement("div",t,s.createElement("div",r,n))}return null},ee=function(){if(!w.current){w.current=o.DomHandler.createInlineStyle(c&&c.nonce||p.default.nonce);var e="".concat(v),n="\n@media screen and (max-width: ".concat(m.breakpoint,") {\n .p-megamenu[").concat(e,"] > .p-megamenu-root-list .p-menuitem-active .p-megamenu-panel {\n position: relative;\n left: 0 !important;\n box-shadow: none;\n border-radius: 0;\n background: inherit;\n }\n\n .p-megamenu[").concat(e,"] .p-menuitem-active > .p-menuitem-link > .p-submenu-icon {\n transform: rotate(-180deg);\n }\n\n .p-megamenu[").concat(e,"] .p-megamenu-grid {\n flex-wrap: wrap;\n }\n\n ").concat(j?"\n.p-megamenu[".concat(e,"] .p-megamenu-button {\n display: flex;\n}\n\n.p-megamenu[").concat(e,"].p-megamenu-horizontal {\n position: relative;\n}\n\n.p-megamenu[").concat(e,"].p-megamenu-horizontal .p-megamenu-root-list {\n display: none;\n}\n\n.p-megamenu-horizontal[").concat(e,'] div[class*="p-megamenu-col-"] {\n width: auto;\n flex: 1;\n padding: 0;\n}\n\n.p-megamenu[').concat(e,"].p-megamenu-mobile-active .p-megamenu-root-list {\n display: flex;\n flex-direction: column;\n position: absolute;\n width: 100%;\n top: 100%;\n left: 0;\n z-index: 1;\n}\n "):"","\n\n ").concat(x?"\n.p-megamenu-vertical[".concat(e,"] {\n width: 100%;\n}\n\n.p-megamenu-vertical[").concat(e,"] .p-megamenu-root-list {\n max-height: ").concat(m.scrollHeight,";\n overflow: ").concat(m.scrollHeight?"auto":"",";\n}\n.p-megamenu-vertical[").concat(e,'] div[class*="p-megamenu-col-"] {\n width: 100%;\n padding: 0;\n}\n\n.p-megamenu-vertical[').concat(e,"] .p-megamenu-submenu {\n width: 100%;\n}\n\n.p-megamenu-vertical[").concat(e,'] div[class*="p-megamenu-col-"] .p-megamenu-submenu-header {\n background: inherit;\n}\n\n.p-megamenu-vertical[').concat(e,'] .p-submenu-icon:before {\n content: "\\e930";\n}\n '):"","\n}\n");w.current.innerHTML=n}};t.useUpdateEffect((function(){return v&&O.current&&(O.current.setAttribute(v,""),ee()),function(){w.current=o.DomHandler.removeInlineStyle(w.current)}}),[v,m.breakpoint]);var ne,te=function(e,n){var t=o.classNames("p-menuitem",{"p-menuitem-active":e===d},e.className),r=o.classNames("p-menuitem-link",{"p-disabled":e.disabled}),a=o.mergeProps({className:"p-menuitem-icon"},M(e,"icon")),l=o.IconUtils.getJSXIcon(e.icon,S({},a),{props:m}),u=o.mergeProps({className:"p-menuitem-text"},M(e,"label")),c=e.label&&s.createElement("span",u,e.label),p=e.template?o.ObjectUtils.getJSXElement(e.template,e):null,f=K(e),b=W(e),v=o.mergeProps({href:e.url||"#",className:r,target:e.target,onClick:function(n){return t=n,(r=e).disabled||(r.url||t.preventDefault(),r.command&&r.command({originalEvent:t,item:m.item}),r.items&&g(d&&d===r?null:r)),void t.preventDefault();var t,r},onKeyDown:function(n){return A(n,e)},role:"menuitem","aria-haspopup":null!=e.items},M(e,"headerAction")),y=o.mergeProps({key:e.label+"_"+n,id:e.id,className:t,style:e.style,onMouseEnter:function(n){return t=n,void((r=e).disabled||D?t.preventDefault():d&&g(r));var t,r},role:"none"},M(e,"menuitem"));return s.createElement("li",y,s.createElement("a",v,l,c,p,f,s.createElement(i.Ripple,null)),b)},re=o.classNames("p-megamenu p-component",{"p-megamenu-horizontal":"horizontal"===m.orientation,"p-megamenu-vertical":"vertical"===m.orientation,"p-megamenu-mobile-active":E},m.className),ae=o.mergeProps({ref:O,id:m.id,className:re,style:m.style},I.getOtherProps(m),C("root")),le=(ne=o.mergeProps({className:"p-megamenu-root-list",role:"menubar"},C("menu")),m.model?s.createElement("ul",ne,m.model.map((function(e,n){return te(e,n)}))):null),ie=function(){var e=o.mergeProps({className:"p-megamenu-start"},C("start"));if(m.start){var n=o.ObjectUtils.getJSXElement(m.start,m);return s.createElement("div",e,n)}return null}(),oe=function(){var e=o.mergeProps({className:"p-megamenu-end"},C("end"));if(m.end){var n=o.ObjectUtils.getJSXElement(m.end,m);return s.createElement("div",e,n)}return null}(),ue=function(){if("vertical"===m.orientation||m.model&&m.model.length<1)return null;var e=o.IconUtils.getJSXIcon(m.menuIcon||s.createElement(l.BarsIcon,null),void 0,{props:m});return s.createElement("a",{ref:k,href:"#",role:"button",tabIndex:0,className:"p-megamenu-button",onClick:R},e)}();return s.createElement("div",ae,ie,ue,le,oe)})));w.displayName="MegaMenu",exports.MegaMenu=w;
@@ -9,13 +9,148 @@
9
9
  */
10
10
  import * as React from 'react';
11
11
  import { MenuItem } from '../menuitem';
12
- import { IconType } from '../utils/utils';
12
+ import { IconType, PassThroughType } from '../utils/utils';
13
+
14
+ export declare type MegaMenuPassThroughType<T> = PassThroughType<T, MegaMenuPassThroughMethodOptions>;
15
+
16
+ /**
17
+ * Custom passthrough(pt) option method.
18
+ */
19
+ export interface MegaMenuPassThroughMethodOptions {
20
+ props: MegaMenuProps;
21
+ state: MegaMenuState;
22
+ context: MegaMenuContext;
23
+ }
24
+
25
+ /**
26
+ * Custom passthrough(pt) options.
27
+ * @see {@link MegaMenuProps.pt}
28
+ */
29
+ export interface MegaMenuPassThroughOptions {
30
+ /**
31
+ * Uses to pass attributes to the root's DOM element.
32
+ */
33
+ root?: MegaMenuPassThroughType<React.HTMLAttributes<HTMLDivElement>>;
34
+ /**
35
+ * Uses to pass attributes to the list's DOM element.
36
+ */
37
+ menu?: MegaMenuPassThroughType<React.HTMLAttributes<HTMLUListElement>>;
38
+ /**
39
+ * Uses to pass attributes to the list item's DOM element.
40
+ */
41
+ menuitem?: MegaMenuPassThroughType<React.HTMLAttributes<HTMLLIElement>>;
42
+ /**
43
+ * Uses to pass attributes to the header action's DOM element.
44
+ */
45
+ headerAction?: MegaMenuPassThroughType<React.HTMLAttributes<HTMLAnchorElement>>;
46
+ /**
47
+ * Uses to pass attributes to the action's DOM element.
48
+ */
49
+ action?: MegaMenuPassThroughType<React.HTMLAttributes<HTMLAnchorElement>>;
50
+ /**
51
+ * Uses to pass attributes to the icon's DOM element.
52
+ */
53
+ icon?: MegaMenuPassThroughType<React.SVGProps<SVGSVGElement> | React.HTMLAttributes<HTMLSpanElement>>;
54
+ /**
55
+ * Uses to pass attributes to the label's DOM element.
56
+ */
57
+ label?: MegaMenuPassThroughType<React.HTMLAttributes<HTMLSpanElement>>;
58
+ /**
59
+ * Uses to pass attributes to the submenu icon's DOM element.
60
+ */
61
+ submenuIcon?: MegaMenuPassThroughType<React.SVGProps<SVGSVGElement> | React.HTMLAttributes<HTMLSpanElement>>;
62
+ /**
63
+ * Uses to pass attributes to the panel's DOM element.
64
+ */
65
+ panel?: MegaMenuPassThroughType<React.HTMLAttributes<HTMLDivElement>>;
66
+ /**
67
+ * Uses to pass attributes to the grid's DOM element.
68
+ */
69
+ grid?: MegaMenuPassThroughType<React.HTMLAttributes<HTMLDivElement>>;
70
+ /**
71
+ * Uses to pass attributes to the column's DOM element.
72
+ */
73
+ column?: MegaMenuPassThroughType<React.HTMLAttributes<HTMLDivElement>>;
74
+ /**
75
+ * Uses to pass attributes to the submenu's DOM element.
76
+ */
77
+ submenu?: MegaMenuPassThroughType<React.HTMLAttributes<HTMLUListElement>>;
78
+ /**
79
+ * Uses to pass attributes to the submenu items's DOM element.
80
+ */
81
+ submenuItem?: MegaMenuPassThroughType<React.HTMLAttributes<HTMLLIElement>>;
82
+ /**
83
+ * Uses to pass attributes to the submenu header's DOM element.
84
+ */
85
+ submenuHeader?: MegaMenuPassThroughType<React.HTMLAttributes<HTMLLIElement>>;
86
+ /**
87
+ * Uses to pass attributes to the separator's DOM element.
88
+ */
89
+ separator?: MegaMenuPassThroughType<React.HTMLAttributes<HTMLLIElement>>;
90
+ /**
91
+ * Uses to pass attributes to the start of the component.
92
+ */
93
+ start?: MegaMenuPassThroughType<React.HTMLAttributes<HTMLDivElement>>;
94
+ /**
95
+ * Uses to pass attributes to the end of the component.
96
+ */
97
+ end?: MegaMenuPassThroughType<React.HTMLAttributes<HTMLDivElement>>;
98
+ }
99
+
100
+ /**
101
+ * Defines focused item info
102
+ */
103
+ export interface MegaMenuFocusedItemInfo {
104
+ /**
105
+ * Active item index
106
+ */
107
+ index: number;
108
+ /**
109
+ * Active item level
110
+ */
111
+ level: number;
112
+ /**
113
+ * Parent key info
114
+ */
115
+ parentKey: string;
116
+ }
117
+
118
+ /**
119
+ * Defines current inline state in MegaMenu component.
120
+ */
121
+ export interface MegaMenuState {
122
+ /**
123
+ * Current mobileActive state as a boolean.
124
+ * @defaultValue false
125
+ */
126
+ mobileActive: boolean;
127
+ /**
128
+ * Current attributeSelector visible state as a string.
129
+ */
130
+ attributeSelector: boolean;
131
+ /**
132
+ * Active item path.
133
+ * @type {MenuItem}
134
+ */
135
+ activeItem: MenuItem;
136
+ }
137
+
138
+ /**
139
+ * Defines current options in MegaMenu component.
140
+ */
141
+ export interface MegaMenuContext {
142
+ /**
143
+ * Current active state of menuitem as a boolean.
144
+ * @defaultValue false
145
+ */
146
+ active: boolean;
147
+ }
13
148
 
14
149
  /**
15
150
  * Defines valid properties in MegaMenu component. In addition to these, all properties of HTMLDivElement can be used in this component.
16
151
  * @group Properties
17
152
  */
18
- export interface MegaMenuProps extends Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, 'ref'> {
153
+ export interface MegaMenuProps extends Omit<React.DetailedHTMLProps<React.HTMLAttributes<HTMLDivElement>, HTMLDivElement>, 'ref' | 'pt'> {
19
154
  /**
20
155
  * An array of menuitems.
21
156
  */
@@ -55,6 +190,11 @@ export interface MegaMenuProps extends Omit<React.DetailedHTMLProps<React.HTMLAt
55
190
  * @readonly
56
191
  */
57
192
  children?: React.ReactNode | undefined;
193
+ /**
194
+ * Uses to pass attributes to DOM elements inside the component.
195
+ * @type {MegaMenuPassThroughOptions}
196
+ */
197
+ pt?: MegaMenuPassThroughOptions;
58
198
  }
59
199
 
60
200
  /**