@omnitron-dev/prism 0.3.0 → 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (413) hide show
  1. package/README.md +216 -2
  2. package/THIRD-PARTY-NOTICES.txt +26 -0
  3. package/dist/accessibility/index.js +2 -0
  4. package/dist/accessibility/index.js.map +1 -1
  5. package/dist/auth/index.d.ts +4 -0
  6. package/dist/auth/index.d.ts.map +1 -0
  7. package/dist/auth/index.js +4 -0
  8. package/dist/auth/index.js.map +1 -0
  9. package/dist/blocks/auth-block/guards.d.ts +3 -2
  10. package/dist/blocks/auth-block/guards.d.ts.map +1 -1
  11. package/dist/blocks/dashboard-block/dashboard-block.d.ts.map +1 -1
  12. package/dist/blocks/dashboard-block/types.d.ts +4 -2
  13. package/dist/blocks/dashboard-block/types.d.ts.map +1 -1
  14. package/dist/blocks/dashboard-block/use-dashboard-block.d.ts +2 -2
  15. package/dist/blocks/dashboard-block/use-dashboard-block.d.ts.map +1 -1
  16. package/dist/blocks/data-grid-block/data-grid-block.d.ts.map +1 -1
  17. package/dist/blocks/data-grid-block/types.d.ts +3 -0
  18. package/dist/blocks/data-grid-block/types.d.ts.map +1 -1
  19. package/dist/blocks/index.js +80 -253
  20. package/dist/blocks/index.js.map +1 -1
  21. package/dist/chunk-2AB7VGPW.js +447 -0
  22. package/dist/chunk-2AB7VGPW.js.map +1 -0
  23. package/dist/{chunk-WFD54GQQ.js → chunk-2E67PQ4T.js} +14 -573
  24. package/dist/chunk-2E67PQ4T.js.map +1 -0
  25. package/dist/chunk-2KG2NI73.js +84 -0
  26. package/dist/chunk-2KG2NI73.js.map +1 -0
  27. package/dist/chunk-2UYRW6X3.js +44 -0
  28. package/dist/chunk-2UYRW6X3.js.map +1 -0
  29. package/dist/chunk-36C5H56C.js +208 -0
  30. package/dist/chunk-36C5H56C.js.map +1 -0
  31. package/dist/chunk-36FOXX25.js +73 -0
  32. package/dist/chunk-36FOXX25.js.map +1 -0
  33. package/dist/chunk-3VSM7NZG.js +562 -0
  34. package/dist/chunk-3VSM7NZG.js.map +1 -0
  35. package/dist/chunk-4B2LTPK2.js +826 -0
  36. package/dist/chunk-4B2LTPK2.js.map +1 -0
  37. package/dist/chunk-4HUGZJKU.js +108 -0
  38. package/dist/chunk-4HUGZJKU.js.map +1 -0
  39. package/dist/chunk-4Q5L7LDG.js +74 -0
  40. package/dist/chunk-4Q5L7LDG.js.map +1 -0
  41. package/dist/{chunk-BRDWQVRT.js → chunk-4R7EZ7GQ.js} +3 -2
  42. package/dist/chunk-4R7EZ7GQ.js.map +1 -0
  43. package/dist/chunk-6IANOSMD.js +185 -0
  44. package/dist/chunk-6IANOSMD.js.map +1 -0
  45. package/dist/chunk-7ATBURW2.js +206 -0
  46. package/dist/chunk-7ATBURW2.js.map +1 -0
  47. package/dist/{chunk-6AHI4GSV.js → chunk-AATAOOSF.js} +4 -3
  48. package/dist/chunk-AATAOOSF.js.map +1 -0
  49. package/dist/chunk-AKLRKCYH.js +128 -0
  50. package/dist/chunk-AKLRKCYH.js.map +1 -0
  51. package/dist/chunk-CT46KJOR.js +133 -0
  52. package/dist/chunk-CT46KJOR.js.map +1 -0
  53. package/dist/{chunk-YQW43BDH.js → chunk-D4GFAJAZ.js} +1168 -6354
  54. package/dist/chunk-D4GFAJAZ.js.map +1 -0
  55. package/dist/chunk-D5J3KW6Q.js +106 -0
  56. package/dist/chunk-D5J3KW6Q.js.map +1 -0
  57. package/dist/chunk-DEPJRTVT.js +3 -0
  58. package/dist/{chunk-FU52GL2E.js.map → chunk-DEPJRTVT.js.map} +1 -1
  59. package/dist/{chunk-S6SEGBX6.js → chunk-DHTYHUYI.js} +85 -107
  60. package/dist/chunk-DHTYHUYI.js.map +1 -0
  61. package/dist/chunk-E7WM2RXA.js +249 -0
  62. package/dist/chunk-E7WM2RXA.js.map +1 -0
  63. package/dist/chunk-F6RZ7LW6.js +1271 -0
  64. package/dist/chunk-F6RZ7LW6.js.map +1 -0
  65. package/dist/chunk-FOGY3HA4.js +217 -0
  66. package/dist/chunk-FOGY3HA4.js.map +1 -0
  67. package/dist/chunk-G2GANYMW.js +139 -0
  68. package/dist/chunk-G2GANYMW.js.map +1 -0
  69. package/dist/chunk-I6DILPFE.js +293 -0
  70. package/dist/chunk-I6DILPFE.js.map +1 -0
  71. package/dist/chunk-IRYU3NTG.js +573 -0
  72. package/dist/chunk-IRYU3NTG.js.map +1 -0
  73. package/dist/chunk-JTIUGPW5.js +284 -0
  74. package/dist/chunk-JTIUGPW5.js.map +1 -0
  75. package/dist/{chunk-GUFHFEPZ.js → chunk-JZBSPDED.js} +2 -2
  76. package/dist/{chunk-GUFHFEPZ.js.map → chunk-JZBSPDED.js.map} +1 -1
  77. package/dist/chunk-KPY7TA4D.js +191 -0
  78. package/dist/chunk-KPY7TA4D.js.map +1 -0
  79. package/dist/{chunk-OBJ244BO.js → chunk-LFWKGNCX.js} +50 -656
  80. package/dist/chunk-LFWKGNCX.js.map +1 -0
  81. package/dist/chunk-LH4ZZZYB.js +37 -0
  82. package/dist/chunk-LH4ZZZYB.js.map +1 -0
  83. package/dist/chunk-NFJ7CPG3.js +13 -0
  84. package/dist/chunk-NFJ7CPG3.js.map +1 -0
  85. package/dist/chunk-NFPOIHD4.js +3 -0
  86. package/dist/{chunk-AYYFMTMI.js.map → chunk-NFPOIHD4.js.map} +1 -1
  87. package/dist/{chunk-XIXSSI3B.js → chunk-NJM5AVBM.js} +3 -2
  88. package/dist/chunk-NJM5AVBM.js.map +1 -0
  89. package/dist/{chunk-Z5OSPAOC.js → chunk-NSNM53WI.js} +196 -175
  90. package/dist/chunk-NSNM53WI.js.map +1 -0
  91. package/dist/chunk-NTREGTG7.js +31 -0
  92. package/dist/chunk-NTREGTG7.js.map +1 -0
  93. package/dist/{chunk-ADG4HZEP.js → chunk-OKJA6SJM.js} +4 -4
  94. package/dist/chunk-OKJA6SJM.js.map +1 -0
  95. package/dist/chunk-Q6JDNFSG.js +303 -0
  96. package/dist/chunk-Q6JDNFSG.js.map +1 -0
  97. package/dist/chunk-RPOGINR5.js +115 -0
  98. package/dist/chunk-RPOGINR5.js.map +1 -0
  99. package/dist/{chunk-ZTATTUH7.js → chunk-RSWVYIXK.js} +282 -683
  100. package/dist/chunk-RSWVYIXK.js.map +1 -0
  101. package/dist/chunk-SSEHL5VP.js +110 -0
  102. package/dist/chunk-SSEHL5VP.js.map +1 -0
  103. package/dist/chunk-TEIGUOWN.js +523 -0
  104. package/dist/chunk-TEIGUOWN.js.map +1 -0
  105. package/dist/{chunk-AYYFMTMI.js → chunk-TJ7DHXUX.js} +2 -2
  106. package/dist/chunk-TJ7DHXUX.js.map +1 -0
  107. package/dist/chunk-TZHWYT34.js +590 -0
  108. package/dist/chunk-TZHWYT34.js.map +1 -0
  109. package/dist/chunk-TZWHELY4.js +45 -0
  110. package/dist/chunk-TZWHELY4.js.map +1 -0
  111. package/dist/{chunk-BZOL7GMU.js → chunk-UEINJFLS.js} +7 -7
  112. package/dist/chunk-UEINJFLS.js.map +1 -0
  113. package/dist/chunk-URFQX3I6.js +129 -0
  114. package/dist/chunk-URFQX3I6.js.map +1 -0
  115. package/dist/chunk-VG6FOMOH.js +187 -0
  116. package/dist/chunk-VG6FOMOH.js.map +1 -0
  117. package/dist/chunk-VQVVHMPG.js +106 -0
  118. package/dist/chunk-VQVVHMPG.js.map +1 -0
  119. package/dist/{chunk-DRFNMZLG.js → chunk-VUKOT432.js} +3 -2
  120. package/dist/chunk-VUKOT432.js.map +1 -0
  121. package/dist/chunk-WD4N72DL.js +315 -0
  122. package/dist/chunk-WD4N72DL.js.map +1 -0
  123. package/dist/chunk-XBYMG4QK.js +119 -0
  124. package/dist/chunk-XBYMG4QK.js.map +1 -0
  125. package/dist/chunk-YHM6GIHV.js +3 -0
  126. package/dist/chunk-YHM6GIHV.js.map +1 -0
  127. package/dist/{chunk-SNZK5X6F.js → chunk-Z2AN43YU.js} +4 -2
  128. package/dist/chunk-Z2AN43YU.js.map +1 -0
  129. package/dist/chunk-ZNWHMQRM.js +171 -0
  130. package/dist/chunk-ZNWHMQRM.js.map +1 -0
  131. package/dist/{chunk-YSIG2XYH.js → chunk-ZRJYQN6Y.js} +2 -2
  132. package/dist/{chunk-YSIG2XYH.js.map → chunk-ZRJYQN6Y.js.map} +1 -1
  133. package/dist/{chunk-AD4W7HYC.js → chunk-ZYI3MHLE.js} +3 -2
  134. package/dist/chunk-ZYI3MHLE.js.map +1 -0
  135. package/dist/cli/index.js +66 -423
  136. package/dist/cli/index.js.map +1 -1
  137. package/dist/components/accordion/accordion.d.ts.map +1 -1
  138. package/dist/components/admin-filters/admin-data-table.d.ts +7 -1
  139. package/dist/components/admin-filters/admin-data-table.d.ts.map +1 -1
  140. package/dist/components/admin-filters/filter-toolbar.d.ts.map +1 -1
  141. package/dist/components/admin-filters/index.js +8 -0
  142. package/dist/components/admin-filters/index.js.map +1 -0
  143. package/dist/components/alert/alert.d.ts.map +1 -1
  144. package/dist/components/alert/index.js +5 -0
  145. package/dist/components/alert/index.js.map +1 -0
  146. package/dist/components/animate/index.js +5 -0
  147. package/dist/components/animate/index.js.map +1 -0
  148. package/dist/components/breadcrumbs/breadcrumbs.d.ts.map +1 -1
  149. package/dist/components/breadcrumbs/index.js +4 -0
  150. package/dist/components/breadcrumbs/index.js.map +1 -0
  151. package/dist/components/card/index.js +4 -0
  152. package/dist/components/card/index.js.map +1 -0
  153. package/dist/components/chart/chart.d.ts.map +1 -1
  154. package/dist/components/chart/index.css +52 -0
  155. package/dist/components/chart/index.css.map +1 -0
  156. package/dist/components/chart/index.js +5 -0
  157. package/dist/components/chart/index.js.map +1 -0
  158. package/dist/components/chart/types.d.ts +3 -1
  159. package/dist/components/chart/types.d.ts.map +1 -1
  160. package/dist/components/chart/use-chart.d.ts.map +1 -1
  161. package/dist/components/command-palette/command-palette.d.ts +3 -1
  162. package/dist/components/command-palette/command-palette.d.ts.map +1 -1
  163. package/dist/components/command-palette/index.js +4 -0
  164. package/dist/components/command-palette/index.js.map +1 -0
  165. package/dist/components/confirm-dialog/index.js +4 -0
  166. package/dist/components/confirm-dialog/index.js.map +1 -0
  167. package/dist/components/date-input/date-input.d.ts +28 -0
  168. package/dist/components/date-input/date-input.d.ts.map +1 -0
  169. package/dist/components/date-input/index.d.ts +3 -0
  170. package/dist/components/date-input/index.d.ts.map +1 -0
  171. package/dist/components/date-input/value.d.ts +9 -0
  172. package/dist/components/date-input/value.d.ts.map +1 -0
  173. package/dist/components/doc-layout/doc-sidebar.d.ts +4 -1
  174. package/dist/components/doc-layout/doc-sidebar.d.ts.map +1 -1
  175. package/dist/components/doc-layout/index.js +7 -0
  176. package/dist/components/doc-layout/index.js.map +1 -0
  177. package/dist/components/editor/editor.d.ts.map +1 -1
  178. package/dist/components/editor/icons/index.d.ts +32 -40
  179. package/dist/components/editor/icons/index.d.ts.map +1 -1
  180. package/dist/components/editor/index.js +4 -1
  181. package/dist/components/editor/index.js.map +1 -1
  182. package/dist/components/emoji-picker/index.js +2 -1
  183. package/dist/components/emoji-picker/index.js.map +1 -1
  184. package/dist/components/empty-content/empty-content.d.ts.map +1 -1
  185. package/dist/components/empty-content/index.js +4 -0
  186. package/dist/components/empty-content/index.js.map +1 -0
  187. package/dist/components/error-boundary/error-boundary.d.ts.map +1 -1
  188. package/dist/components/error-boundary/index.js +6 -0
  189. package/dist/components/error-boundary/index.js.map +1 -0
  190. package/dist/components/index.css +17 -10
  191. package/dist/components/index.css.map +1 -1
  192. package/dist/components/index.d.ts +5 -4
  193. package/dist/components/index.d.ts.map +1 -1
  194. package/dist/components/index.js +47 -11
  195. package/dist/components/index.js.map +1 -1
  196. package/dist/components/knowledge-graph/edge-labels.d.ts +14 -0
  197. package/dist/components/knowledge-graph/edge-labels.d.ts.map +1 -0
  198. package/dist/components/knowledge-graph/graph.d.ts +56 -0
  199. package/dist/components/knowledge-graph/graph.d.ts.map +1 -0
  200. package/dist/components/knowledge-graph/index.css +176 -0
  201. package/dist/components/knowledge-graph/index.css.map +1 -0
  202. package/dist/components/knowledge-graph/index.d.ts +3 -0
  203. package/dist/components/knowledge-graph/index.d.ts.map +1 -0
  204. package/dist/components/knowledge-graph/index.js +797 -0
  205. package/dist/components/knowledge-graph/index.js.map +1 -0
  206. package/dist/components/knowledge-graph/label-layout.d.ts +28 -0
  207. package/dist/components/knowledge-graph/label-layout.d.ts.map +1 -0
  208. package/dist/components/knowledge-graph/label-store.d.ts +15 -0
  209. package/dist/components/knowledge-graph/label-store.d.ts.map +1 -0
  210. package/dist/components/knowledge-graph/model.d.ts +92 -0
  211. package/dist/components/knowledge-graph/model.d.ts.map +1 -0
  212. package/dist/components/label/index.js +5 -0
  213. package/dist/components/label/index.js.map +1 -0
  214. package/dist/components/label/label.d.ts.map +1 -1
  215. package/dist/components/lightbox/lightbox.d.ts.map +1 -1
  216. package/dist/components/loading-screen/index.js +4 -0
  217. package/dist/components/loading-screen/index.js.map +1 -0
  218. package/dist/components/map/Map.d.ts +19 -43
  219. package/dist/components/map/Map.d.ts.map +1 -1
  220. package/dist/components/map/MapCoverageLayer.d.ts +1 -1
  221. package/dist/components/map/MapCoverageLayer.d.ts.map +1 -1
  222. package/dist/components/map/MapMarker.d.ts +1 -1
  223. package/dist/components/map/MapMarker.d.ts.map +1 -1
  224. package/dist/components/map/MapPlaceSearch.d.ts +33 -0
  225. package/dist/components/map/MapPlaceSearch.d.ts.map +1 -0
  226. package/dist/components/map/MapPointPicker.d.ts +21 -12
  227. package/dist/components/map/MapPointPicker.d.ts.map +1 -1
  228. package/dist/components/map/coordinates.d.ts +10 -0
  229. package/dist/components/map/coordinates.d.ts.map +1 -0
  230. package/dist/components/map/index.css +4 -0
  231. package/dist/components/map/index.css.map +1 -0
  232. package/dist/components/map/index.d.ts +7 -2
  233. package/dist/components/map/index.d.ts.map +1 -1
  234. package/dist/components/map/index.js +4 -0
  235. package/dist/components/map/index.js.map +1 -0
  236. package/dist/components/nav-card/nav-card.d.ts.map +1 -1
  237. package/dist/components/navigation-progress/index.js +4 -0
  238. package/dist/components/navigation-progress/index.js.map +1 -0
  239. package/dist/components/page-content/index.js +4 -0
  240. package/dist/components/page-content/index.js.map +1 -0
  241. package/dist/components/popover/index.js +4 -0
  242. package/dist/components/popover/index.js.map +1 -0
  243. package/dist/components/rail/rail.d.ts.map +1 -1
  244. package/dist/components/research/diagram-image.d.ts +11 -0
  245. package/dist/components/research/diagram-image.d.ts.map +1 -0
  246. package/dist/components/research/diagram.d.ts +8 -0
  247. package/dist/components/research/diagram.d.ts.map +1 -0
  248. package/dist/components/research/document.d.ts +33 -0
  249. package/dist/components/research/document.d.ts.map +1 -0
  250. package/dist/components/research/frontmatter.d.ts +15 -0
  251. package/dist/components/research/frontmatter.d.ts.map +1 -0
  252. package/dist/components/research/index.css +51 -0
  253. package/dist/components/research/index.css.map +1 -0
  254. package/dist/components/research/index.d.ts +3 -0
  255. package/dist/components/research/index.d.ts.map +1 -0
  256. package/dist/components/research/index.js +8 -0
  257. package/dist/components/research/index.js.map +1 -0
  258. package/dist/components/research/parse.d.ts +29 -0
  259. package/dist/components/research/parse.d.ts.map +1 -0
  260. package/dist/components/research-editor/block-commands.d.ts +20 -0
  261. package/dist/components/research-editor/block-commands.d.ts.map +1 -0
  262. package/dist/components/research-editor/block-controls.d.ts +13 -0
  263. package/dist/components/research-editor/block-controls.d.ts.map +1 -0
  264. package/dist/components/research-editor/editor.d.ts +75 -0
  265. package/dist/components/research-editor/editor.d.ts.map +1 -0
  266. package/dist/components/research-editor/extensions.d.ts +14 -0
  267. package/dist/components/research-editor/extensions.d.ts.map +1 -0
  268. package/dist/components/research-editor/index.css +332 -0
  269. package/dist/components/research-editor/index.css.map +1 -0
  270. package/dist/components/research-editor/index.d.ts +5 -0
  271. package/dist/components/research-editor/index.d.ts.map +1 -0
  272. package/dist/components/research-editor/index.js +1593 -0
  273. package/dist/components/research-editor/index.js.map +1 -0
  274. package/dist/components/research-editor/math-input.d.ts +32 -0
  275. package/dist/components/research-editor/math-input.d.ts.map +1 -0
  276. package/dist/components/research-editor/math-markup.d.ts +4 -0
  277. package/dist/components/research-editor/math-markup.d.ts.map +1 -0
  278. package/dist/components/research-editor/math-navigation.d.ts +6 -0
  279. package/dist/components/research-editor/math-navigation.d.ts.map +1 -0
  280. package/dist/components/research-editor/math-node.d.ts +11 -0
  281. package/dist/components/research-editor/math-node.d.ts.map +1 -0
  282. package/dist/components/research-editor/source.d.ts +19 -0
  283. package/dist/components/research-editor/source.d.ts.map +1 -0
  284. package/dist/components/scroll-to-top/index.js +4 -0
  285. package/dist/components/scroll-to-top/index.js.map +1 -0
  286. package/dist/components/scrollbar/scrollbar.d.ts +4 -2
  287. package/dist/components/scrollbar/scrollbar.d.ts.map +1 -1
  288. package/dist/components/search-input/index.js +7 -0
  289. package/dist/components/search-input/index.js.map +1 -0
  290. package/dist/components/search-input/search-input.d.ts +3 -11
  291. package/dist/components/search-input/search-input.d.ts.map +1 -1
  292. package/dist/components/skeleton/index.js +4 -0
  293. package/dist/components/skeleton/index.js.map +1 -0
  294. package/dist/components/snackbar/index.js +6 -0
  295. package/dist/components/snackbar/index.js.map +1 -0
  296. package/dist/components/stepper/index.js +4 -0
  297. package/dist/components/stepper/index.js.map +1 -0
  298. package/dist/components/table/index.d.ts +1 -0
  299. package/dist/components/table/index.d.ts.map +1 -1
  300. package/dist/components/table/index.js +5 -0
  301. package/dist/components/table/index.js.map +1 -0
  302. package/dist/components/table/table-viewport.d.ts +13 -0
  303. package/dist/components/table/table-viewport.d.ts.map +1 -0
  304. package/dist/components/table/table.d.ts +3 -1
  305. package/dist/components/table/table.d.ts.map +1 -1
  306. package/dist/components/tabs/index.js +6 -0
  307. package/dist/components/tabs/index.js.map +1 -0
  308. package/dist/components/tabs/tabs.d.ts +12 -1
  309. package/dist/components/tabs/tabs.d.ts.map +1 -1
  310. package/dist/components/tiptap-renderer/tiptap-renderer.d.ts +4 -3
  311. package/dist/components/tiptap-renderer/tiptap-renderer.d.ts.map +1 -1
  312. package/dist/core/index.d.ts +1 -1
  313. package/dist/core/index.d.ts.map +1 -1
  314. package/dist/core/index.js +12 -6
  315. package/dist/core/index.js.map +1 -1
  316. package/dist/core/provider.d.ts +7 -2
  317. package/dist/core/provider.d.ts.map +1 -1
  318. package/dist/forms/index.js +2 -0
  319. package/dist/forms/index.js.map +1 -1
  320. package/dist/forms/schema-provider.d.ts +3 -3
  321. package/dist/forms/schema-utils.d.ts +3 -3
  322. package/dist/hooks/index.js +14 -8
  323. package/dist/hooks/index.js.map +1 -1
  324. package/dist/hooks/use-config-from-query.d.ts +2 -0
  325. package/dist/hooks/use-config-from-query.d.ts.map +1 -1
  326. package/dist/hooks/use-image-dimensions.d.ts.map +1 -1
  327. package/dist/hooks/use-keyboard-shortcut.d.ts.map +1 -1
  328. package/dist/hooks/use-scroll-position.d.ts.map +1 -1
  329. package/dist/hooks/use-window-size.d.ts.map +1 -1
  330. package/dist/icons/context.d.ts +17 -0
  331. package/dist/icons/context.d.ts.map +1 -0
  332. package/dist/icons/controls.d.ts +51 -0
  333. package/dist/icons/controls.d.ts.map +1 -0
  334. package/dist/icons/index.d.ts +3 -0
  335. package/dist/icons/index.d.ts.map +1 -0
  336. package/dist/icons/index.js +5 -0
  337. package/dist/icons/index.js.map +1 -0
  338. package/dist/icons/theme.d.ts +4 -0
  339. package/dist/icons/theme.d.ts.map +1 -0
  340. package/dist/index.css +17 -10
  341. package/dist/index.css.map +1 -1
  342. package/dist/index.js +57 -20
  343. package/dist/index.js.map +1 -1
  344. package/dist/internal/research-parser.js +3 -0
  345. package/dist/internal/research-parser.js.map +1 -0
  346. package/dist/layouts/core/header-section.d.ts +1 -0
  347. package/dist/layouts/core/header-section.d.ts.map +1 -1
  348. package/dist/layouts/dashboard/labels.d.ts +12 -0
  349. package/dist/layouts/dashboard/labels.d.ts.map +1 -0
  350. package/dist/layouts/dashboard/layout.d.ts +9 -1
  351. package/dist/layouts/dashboard/layout.d.ts.map +1 -1
  352. package/dist/layouts/dashboard/sidenav.d.ts +7 -3
  353. package/dist/layouts/dashboard/sidenav.d.ts.map +1 -1
  354. package/dist/layouts/index.d.ts +5 -0
  355. package/dist/layouts/index.d.ts.map +1 -1
  356. package/dist/layouts/index.js +9 -3
  357. package/dist/layouts/index.js.map +1 -1
  358. package/dist/layouts/panel-layout.d.ts +35 -0
  359. package/dist/layouts/panel-layout.d.ts.map +1 -0
  360. package/dist/layouts/sidebar-toggle.d.ts +11 -0
  361. package/dist/layouts/sidebar-toggle.d.ts.map +1 -0
  362. package/dist/netron/index.js +2 -1
  363. package/dist/netron/index.js.map +1 -1
  364. package/dist/registry/index.js +1 -1
  365. package/dist/state/create-store.d.ts.map +1 -1
  366. package/dist/state/index.js +3 -2
  367. package/dist/state/index.js.map +1 -1
  368. package/dist/state/settings-version.d.ts.map +1 -1
  369. package/dist/state/stores/auth.d.ts +4 -16
  370. package/dist/state/stores/auth.d.ts.map +1 -1
  371. package/dist/state/stores/ui.d.ts +7 -105
  372. package/dist/state/stores/ui.d.ts.map +1 -1
  373. package/dist/theme/components/Button.d.ts.map +1 -1
  374. package/dist/theme/components/Chip.d.ts.map +1 -1
  375. package/dist/theme/components/Dialog.d.ts.map +1 -1
  376. package/dist/theme/components/FormControls.d.ts +3 -12
  377. package/dist/theme/components/FormControls.d.ts.map +1 -1
  378. package/dist/theme/components/TextField.d.ts.map +1 -1
  379. package/dist/theme/components/index.d.ts.map +1 -1
  380. package/dist/theme/components/theme-utils.d.ts +2 -2
  381. package/dist/theme/components/theme-utils.d.ts.map +1 -1
  382. package/dist/theme/create-theme.d.ts +5 -17
  383. package/dist/theme/create-theme.d.ts.map +1 -1
  384. package/dist/theme/index.js +8 -2
  385. package/dist/theme/index.js.map +1 -1
  386. package/dist/theme/mixins.d.ts +3 -1
  387. package/dist/theme/mixins.d.ts.map +1 -1
  388. package/dist/theme/palette/overrides.d.ts +24 -0
  389. package/dist/theme/palette/overrides.d.ts.map +1 -0
  390. package/dist/theme/semantic-surface.d.ts +8 -0
  391. package/dist/theme/semantic-surface.d.ts.map +1 -0
  392. package/dist/types/index.js +2 -2
  393. package/dist/ui/index.d.ts +18 -0
  394. package/dist/ui/index.d.ts.map +1 -0
  395. package/dist/ui/index.js +149 -0
  396. package/dist/ui/index.js.map +1 -0
  397. package/dist/utils/async-lock.d.ts.map +1 -1
  398. package/package.json +200 -47
  399. package/dist/chunk-6AHI4GSV.js.map +0 -1
  400. package/dist/chunk-AD4W7HYC.js.map +0 -1
  401. package/dist/chunk-ADG4HZEP.js.map +0 -1
  402. package/dist/chunk-BRDWQVRT.js.map +0 -1
  403. package/dist/chunk-BZOL7GMU.js.map +0 -1
  404. package/dist/chunk-DRFNMZLG.js.map +0 -1
  405. package/dist/chunk-FU52GL2E.js +0 -3
  406. package/dist/chunk-OBJ244BO.js.map +0 -1
  407. package/dist/chunk-S6SEGBX6.js.map +0 -1
  408. package/dist/chunk-SNZK5X6F.js.map +0 -1
  409. package/dist/chunk-WFD54GQQ.js.map +0 -1
  410. package/dist/chunk-XIXSSI3B.js.map +0 -1
  411. package/dist/chunk-YQW43BDH.js.map +0 -1
  412. package/dist/chunk-Z5OSPAOC.js.map +0 -1
  413. package/dist/chunk-ZTATTUH7.js.map +0 -1
@@ -1,5 +1,11 @@
1
- import { ErrorBoundary, Field, EmptyContent, SearchInput } from '../chunk-OBJ244BO.js';
2
- import { useBoolean } from '../chunk-BRDWQVRT.js';
1
+ "use client";
2
+ export { AuthGuard, GuestGuard, RoleBasedGuard, createConditionalRender, hasPermission, hasRole } from '../chunk-4HUGZJKU.js';
3
+ import { Field } from '../chunk-LFWKGNCX.js';
4
+ import { EmptyContent } from '../chunk-6IANOSMD.js';
5
+ import { ErrorBoundary } from '../chunk-I6DILPFE.js';
6
+ import { useBoolean } from '../chunk-4R7EZ7GQ.js';
7
+ import { CloseIcon } from '../chunk-VQVVHMPG.js';
8
+ import '../chunk-D5J3KW6Q.js';
3
9
  import { createContext, useContext, useCallback, useMemo, useState, useRef, useEffect } from 'react';
4
10
  import Box2 from '@mui/material/Box';
5
11
  import Paper from '@mui/material/Paper';
@@ -22,8 +28,9 @@ import MenuItem from '@mui/material/MenuItem';
22
28
  import ListItemIcon from '@mui/material/ListItemIcon';
23
29
  import ListItemText from '@mui/material/ListItemText';
24
30
  import Tooltip from '@mui/material/Tooltip';
31
+ import { useEventCallback } from '@mui/material/utils';
25
32
  import LinearProgress from '@mui/material/LinearProgress';
26
- import { DataGrid, GridToolbarContainer, GridToolbarColumnsButton, GridToolbarDensitySelector, GridToolbarExport } from '@mui/x-data-grid';
33
+ import { DataGrid, GridToolbarContainer, QuickFilter, QuickFilterControl, QuickFilterClear, GridToolbarColumnsButton, GridToolbarDensitySelector, GridToolbarExport } from '@mui/x-data-grid';
27
34
 
28
35
  var collapseNoop = () => {
29
36
  };
@@ -63,7 +70,7 @@ var sizeConfig = {
63
70
  }
64
71
  };
65
72
  function DashboardBlockHeader({ title, subtitle, icon, actions, sx }) {
66
- const { collapsed, toggleCollapse, variant, size, labels } = useDashboardBlockContext();
73
+ const { collapsible, collapsed, toggleCollapse, size, labels } = useDashboardBlockContext();
67
74
  const config = sizeConfig[size];
68
75
  return /* @__PURE__ */ jsxs(
69
76
  Box2,
@@ -128,7 +135,7 @@ function DashboardBlockHeader({ title, subtitle, icon, actions, sx }) {
128
135
  ] }),
129
136
  /* @__PURE__ */ jsxs(Box2, { sx: { display: "flex", alignItems: "center", gap: 0.5, flexShrink: 0 }, children: [
130
137
  actions,
131
- collapsed !== void 0 && /* @__PURE__ */ jsx(
138
+ collapsible && /* @__PURE__ */ jsx(
132
139
  IconButton2,
133
140
  {
134
141
  size: "small",
@@ -145,9 +152,9 @@ function DashboardBlockHeader({ title, subtitle, icon, actions, sx }) {
145
152
  );
146
153
  }
147
154
  function DashboardBlockContent({ children, disablePadding = false, sx }) {
148
- const { collapsed, loading, error, size } = useDashboardBlockContext();
155
+ const { size } = useDashboardBlockContext();
149
156
  const config = sizeConfig[size];
150
- return /* @__PURE__ */ jsx(Collapse, { in: !collapsed, timeout: "auto", children: /* @__PURE__ */ jsx(
157
+ return /* @__PURE__ */ jsx(
151
158
  Box2,
152
159
  {
153
160
  "data-testid": "prism-dashboard-block-content",
@@ -162,7 +169,7 @@ function DashboardBlockContent({ children, disablePadding = false, sx }) {
162
169
  ],
163
170
  children
164
171
  }
165
- ) });
172
+ );
166
173
  }
167
174
  function DashboardBlockFooter({ children, divider = true, sx }) {
168
175
  const { collapsed, size } = useDashboardBlockContext();
@@ -251,25 +258,18 @@ function DashboardBlock({
251
258
  const uncontrolledCollapse = useBoolean(defaultCollapsed);
252
259
  const isControlled = controlledCollapsed !== void 0;
253
260
  const collapsed = isControlled ? controlledCollapsed : uncontrolledCollapse.value;
254
- const handleToggleCollapse = useCallback(() => {
255
- if (isControlled) {
256
- onCollapseChange?.(!controlledCollapsed);
257
- } else {
258
- uncontrolledCollapse.onToggle();
259
- }
260
- }, [isControlled, controlledCollapsed, onCollapseChange, uncontrolledCollapse]);
261
261
  const handleSetCollapsed = useCallback(
262
262
  (value) => {
263
- if (isControlled) {
264
- onCollapseChange?.(value);
265
- } else {
266
- uncontrolledCollapse.setValue(value);
267
- }
263
+ if (!collapsible || value === collapsed) return;
264
+ if (!isControlled) uncontrolledCollapse.setValue(value);
265
+ onCollapseChange?.(value);
268
266
  },
269
- [isControlled, onCollapseChange, uncontrolledCollapse]
267
+ [collapsible, collapsed, isControlled, onCollapseChange, uncontrolledCollapse]
270
268
  );
269
+ const handleToggleCollapse = useCallback(() => handleSetCollapsed(!collapsed), [collapsed, handleSetCollapsed]);
271
270
  const contextValue = useMemo(
272
271
  () => ({
272
+ collapsible,
273
273
  collapsed: collapsible ? collapsed : false,
274
274
  toggleCollapse: collapsible ? handleToggleCollapse : collapseNoop,
275
275
  setCollapsed: collapsible ? handleSetCollapsed : collapseNoop,
@@ -312,7 +312,7 @@ function DashboardBlock({
312
312
  }
313
313
  ),
314
314
  title && /* @__PURE__ */ jsx(Divider, {}),
315
- /* @__PURE__ */ jsx(Box2, { "aria-live": "polite", "aria-busy": loading, children: catchErrors ? /* @__PURE__ */ jsx(
315
+ /* @__PURE__ */ jsx(Collapse, { in: !contextValue.collapsed, timeout: "auto", children: /* @__PURE__ */ jsx(Box2, { "aria-live": "polite", "aria-busy": loading, children: catchErrors ? /* @__PURE__ */ jsx(
316
316
  ErrorBoundary,
317
317
  {
318
318
  resetKeys: [loading, error, empty],
@@ -330,7 +330,7 @@ function DashboardBlock({
330
330
  ),
331
331
  children: body
332
332
  }
333
- ) : body }),
333
+ ) : body }) }),
334
334
  footer && !loading && !error && /* @__PURE__ */ jsx(DashboardBlockFooter, { divider: footerDivider, ...slotProps?.footer, children: footer })
335
335
  ]
336
336
  }
@@ -1113,142 +1113,6 @@ var AuthBlock = {
1113
1113
  ResetPassword: ResetPasswordForm,
1114
1114
  VerifyCode: VerifyCodeForm
1115
1115
  };
1116
- function AuthGuard({
1117
- children,
1118
- useAuth,
1119
- loadingComponent = null,
1120
- onUnauthenticated,
1121
- unauthenticatedComponent = null
1122
- }) {
1123
- const { isAuthenticated, isLoading } = useAuth();
1124
- const [checked, setChecked] = useState(false);
1125
- useEffect(() => {
1126
- if (!isLoading) {
1127
- if (!isAuthenticated) {
1128
- onUnauthenticated?.();
1129
- }
1130
- setChecked(true);
1131
- }
1132
- }, [isAuthenticated, isLoading, onUnauthenticated]);
1133
- if (isLoading || !checked) {
1134
- return loadingComponent;
1135
- }
1136
- if (!isAuthenticated) {
1137
- return unauthenticatedComponent;
1138
- }
1139
- return children;
1140
- }
1141
- function GuestGuard({
1142
- children,
1143
- useAuth,
1144
- loadingComponent = null,
1145
- onAuthenticated,
1146
- authenticatedComponent = null
1147
- }) {
1148
- const { isAuthenticated, isLoading } = useAuth();
1149
- const [checked, setChecked] = useState(false);
1150
- useEffect(() => {
1151
- if (!isLoading) {
1152
- if (isAuthenticated) {
1153
- onAuthenticated?.();
1154
- }
1155
- setChecked(true);
1156
- }
1157
- }, [isAuthenticated, isLoading, onAuthenticated]);
1158
- if (isLoading || !checked) {
1159
- return loadingComponent;
1160
- }
1161
- if (isAuthenticated) {
1162
- return authenticatedComponent;
1163
- }
1164
- return children;
1165
- }
1166
- function RoleBasedGuard({
1167
- children,
1168
- useAuth,
1169
- roles = [],
1170
- permissions = [],
1171
- requireEmailVerified = false,
1172
- roleMatchStrategy = "any",
1173
- loadingComponent = null,
1174
- onAccessDenied,
1175
- accessDeniedComponent = null
1176
- }) {
1177
- const { isAuthenticated, isLoading, user } = useAuth();
1178
- const [checked, setChecked] = useState(false);
1179
- const [accessGranted, setAccessGranted] = useState(false);
1180
- useEffect(() => {
1181
- if (!isLoading) {
1182
- if (!isAuthenticated || !user) {
1183
- onAccessDenied?.("not_authenticated");
1184
- setAccessGranted(false);
1185
- setChecked(true);
1186
- return;
1187
- }
1188
- if (requireEmailVerified && !user.emailVerified) {
1189
- onAccessDenied?.("email_not_verified");
1190
- setAccessGranted(false);
1191
- setChecked(true);
1192
- return;
1193
- }
1194
- if (roles.length > 0) {
1195
- const userRoles = user.roles ?? [];
1196
- const hasRequiredRole = roleMatchStrategy === "all" ? roles.every((role) => userRoles.includes(role)) : roles.some((role) => userRoles.includes(role));
1197
- if (!hasRequiredRole) {
1198
- onAccessDenied?.("missing_role");
1199
- setAccessGranted(false);
1200
- setChecked(true);
1201
- return;
1202
- }
1203
- }
1204
- if (permissions.length > 0) {
1205
- const userPermissions = user.permissions ?? [];
1206
- const hasAllPermissions = permissions.every((perm) => userPermissions.includes(perm));
1207
- if (!hasAllPermissions) {
1208
- onAccessDenied?.("missing_permission");
1209
- setAccessGranted(false);
1210
- setChecked(true);
1211
- return;
1212
- }
1213
- }
1214
- setAccessGranted(true);
1215
- setChecked(true);
1216
- }
1217
- }, [isAuthenticated, isLoading, user, roles, permissions, requireEmailVerified, roleMatchStrategy, onAccessDenied]);
1218
- if (isLoading || !checked) {
1219
- return loadingComponent;
1220
- }
1221
- if (!accessGranted) {
1222
- return accessDeniedComponent;
1223
- }
1224
- return children;
1225
- }
1226
- function hasRole(user, role, strategy = "any") {
1227
- if (!user?.roles?.length) return false;
1228
- const roles = Array.isArray(role) ? role : [role];
1229
- if (roles.length === 0) return false;
1230
- return strategy === "all" ? roles.every((r) => user.roles.includes(r)) : roles.some((r) => user.roles.includes(r));
1231
- }
1232
- function hasPermission(user, permission, strategy = "all") {
1233
- if (!user?.permissions?.length) return false;
1234
- const permissions = Array.isArray(permission) ? permission : [permission];
1235
- if (permissions.length === 0) return false;
1236
- return strategy === "all" ? permissions.every((p) => user.permissions.includes(p)) : permissions.some((p) => user.permissions.includes(p));
1237
- }
1238
- function createConditionalRender(user) {
1239
- return {
1240
- canRender: (options) => {
1241
- const { roles = [], permissions = [], roleMatchStrategy = "any" } = options;
1242
- if (roles.length > 0 && !hasRole(user, roles, roleMatchStrategy)) {
1243
- return false;
1244
- }
1245
- if (permissions.length > 0 && !hasPermission(user, permissions, "all")) {
1246
- return false;
1247
- }
1248
- return true;
1249
- }
1250
- };
1251
- }
1252
1116
  var DataGridBlockContext = createContext(null);
1253
1117
  function useDataGridBlockContext() {
1254
1118
  const context = useContext(DataGridBlockContext);
@@ -1302,36 +1166,12 @@ function EmptyIcon() {
1302
1166
  }
1303
1167
  );
1304
1168
  }
1305
- function CustomToolbar({
1306
- quickFilter,
1307
- exportConfig,
1308
- showColumnSelector = true,
1309
- showDensitySelector = true,
1310
- startContent,
1311
- endContent,
1312
- actions,
1313
- onQuickFilterChange
1314
- }) {
1315
- const [searchValue, setSearchValue] = useState("");
1316
- const debounceRef = useRef(null);
1317
- useEffect(
1318
- () => () => {
1319
- if (debounceRef.current) clearTimeout(debounceRef.current);
1320
- },
1321
- []
1322
- );
1323
- const handleSearchChange = useCallback(
1324
- (value) => {
1325
- setSearchValue(value);
1326
- if (debounceRef.current) {
1327
- clearTimeout(debounceRef.current);
1328
- }
1329
- debounceRef.current = setTimeout(() => {
1330
- onQuickFilterChange?.(value);
1331
- }, quickFilter?.debounceMs ?? 300);
1332
- },
1333
- [onQuickFilterChange, quickFilter?.debounceMs]
1334
- );
1169
+ function CustomToolbar() {
1170
+ const { toolbar } = useDataGridBlockContext();
1171
+ const { quickFilter, export: exportConfig, actions, startContent, endContent } = toolbar ?? {};
1172
+ const showColumnSelector = toolbar?.columnVisibility?.enabled !== false;
1173
+ const showDensitySelector = toolbar?.densitySelector !== false;
1174
+ const placeholder = quickFilter?.placeholder ?? "Search...";
1335
1175
  return /* @__PURE__ */ jsxs(
1336
1176
  GridToolbarContainer,
1337
1177
  {
@@ -1343,16 +1183,24 @@ function CustomToolbar({
1343
1183
  },
1344
1184
  children: [
1345
1185
  startContent,
1346
- quickFilter?.enabled !== false && /* @__PURE__ */ jsx(
1347
- SearchInput,
1348
- {
1349
- value: searchValue,
1350
- onChange: handleSearchChange,
1351
- placeholder: quickFilter?.placeholder ?? "Search...",
1352
- fullWidth: false,
1353
- minWidth: 200
1354
- }
1355
- ),
1186
+ quickFilter?.enabled !== false && /* @__PURE__ */ jsxs(QuickFilter, { "data-keyboard-search": true, expanded: true, debounceMs: quickFilter?.debounceMs ?? 300, children: [
1187
+ /* @__PURE__ */ jsx(
1188
+ QuickFilterControl,
1189
+ {
1190
+ placeholder,
1191
+ size: "small",
1192
+ slotProps: { htmlInput: { role: "searchbox", "aria-label": placeholder } }
1193
+ }
1194
+ ),
1195
+ /* @__PURE__ */ jsx(
1196
+ QuickFilterClear,
1197
+ {
1198
+ "aria-label": "Clear search",
1199
+ size: "small",
1200
+ render: (props, state) => state.value ? /* @__PURE__ */ jsx(IconButton2, { ...props, children: /* @__PURE__ */ jsx(CloseIcon, { fontSize: "small" }) }) : /* @__PURE__ */ jsx("span", {})
1201
+ }
1202
+ )
1203
+ ] }),
1356
1204
  /* @__PURE__ */ jsx(Box2, { sx: { flex: 1 } }),
1357
1205
  showColumnSelector && /* @__PURE__ */ jsx(GridToolbarColumnsButton, {}),
1358
1206
  showDensitySelector && /* @__PURE__ */ jsx(GridToolbarDensitySelector, {}),
@@ -1560,7 +1408,6 @@ function DataGridBlock({
1560
1408
  type: "include",
1561
1409
  ids: /* @__PURE__ */ new Set()
1562
1410
  });
1563
- const [quickFilterValue, setQuickFilterValue] = useState("");
1564
1411
  const paginationModel = controlledPaginationModel ?? internalPaginationModel;
1565
1412
  const sortModel = controlledSortModel ?? internalSortModel;
1566
1413
  const filterModel = controlledFilterModel ?? internalFilterModel;
@@ -1623,31 +1470,14 @@ function DataGridBlock({
1623
1470
  error,
1624
1471
  density,
1625
1472
  setDensity,
1473
+ toolbar,
1626
1474
  rowCount: rows.length,
1627
1475
  selectedCount: selectionModelValue.ids.size,
1628
1476
  refresh: onRetry
1629
1477
  }),
1630
- [loading, error, density, rows.length, selectionModelValue, onRetry]
1478
+ [loading, error, density, rows.length, selectionModelValue, onRetry, toolbar]
1631
1479
  );
1632
- const rowCount = pagination?.mode === "server" ? pagination.rowCount ?? 0 : rows.length;
1633
- const toolbarSlot = useMemo(() => {
1634
- if (toolbar?.show === false) {
1635
- return void 0;
1636
- }
1637
- return () => /* @__PURE__ */ jsx(
1638
- CustomToolbar,
1639
- {
1640
- quickFilter: toolbar?.quickFilter,
1641
- exportConfig: toolbar?.export,
1642
- showColumnSelector: toolbar?.columnVisibility?.enabled !== false,
1643
- showDensitySelector: toolbar?.densitySelector !== false,
1644
- startContent: toolbar?.startContent,
1645
- endContent: toolbar?.endContent,
1646
- actions: toolbar?.actions,
1647
- onQuickFilterChange: setQuickFilterValue
1648
- }
1649
- );
1650
- }, [toolbar]);
1480
+ const rowCount = pagination?.mode === "server" ? pagination.rowCount ?? 0 : void 0;
1651
1481
  const noRowsOverlay = useMemo(() => {
1652
1482
  if (error) {
1653
1483
  return () => /* @__PURE__ */ jsx(ErrorState2, { message: errorMessage, onRetry });
@@ -1682,6 +1512,8 @@ function DataGridBlock({
1682
1512
  columns: finalColumns,
1683
1513
  loading,
1684
1514
  density,
1515
+ onDensityChange: setDensity,
1516
+ showToolbar: toolbar?.show !== false,
1685
1517
  autoHeight,
1686
1518
  rowHeight,
1687
1519
  getRowId,
@@ -1698,6 +1530,7 @@ function DataGridBlock({
1698
1530
  filterMode: pagination?.mode === "server" ? "server" : "client",
1699
1531
  filterModel,
1700
1532
  onFilterModelChange: handleFilterChange,
1533
+ rowSelection: selection?.enabled ?? true,
1701
1534
  checkboxSelection: selection?.checkboxSelection ?? false,
1702
1535
  rowSelectionModel: selectionModelValue,
1703
1536
  onRowSelectionModelChange: handleSelectionChange,
@@ -1712,7 +1545,7 @@ function DataGridBlock({
1712
1545
  disableVirtualization,
1713
1546
  hideFooter: hideFooter || pagination?.hide,
1714
1547
  slots: {
1715
- toolbar: toolbarSlot,
1548
+ toolbar: CustomToolbar,
1716
1549
  noRowsOverlay,
1717
1550
  loadingOverlay: () => /* @__PURE__ */ jsx(LinearProgress, { sx: { position: "absolute", top: 0, left: 0, right: 0 } }),
1718
1551
  ...slots
@@ -1723,9 +1556,6 @@ function DataGridBlock({
1723
1556
  "& .MuiDataGrid-columnHeaders": {
1724
1557
  bgcolor: "action.hover"
1725
1558
  },
1726
- "& .MuiDataGrid-cell:focus": {
1727
- outline: "none"
1728
- },
1729
1559
  "& .MuiDataGrid-row:hover": {
1730
1560
  bgcolor: "action.hover"
1731
1561
  }
@@ -1754,37 +1584,35 @@ function useDataGridBlock(options) {
1754
1584
  });
1755
1585
  const [sortModel, setSortModel] = useState(initialSortModel);
1756
1586
  const [filterModel, setFilterModel] = useState(initialFilterModel);
1757
- const isMountedRef = useRef(true);
1758
1587
  const abortControllerRef = useRef(null);
1759
- const fetchData = useCallback(
1760
- async (params) => {
1761
- if (abortControllerRef.current) {
1762
- abortControllerRef.current.abort();
1588
+ const fetchData = useEventCallback(async (params) => {
1589
+ if (abortControllerRef.current) {
1590
+ abortControllerRef.current.abort();
1591
+ }
1592
+ const controller = new AbortController();
1593
+ abortControllerRef.current = controller;
1594
+ setLoading(true);
1595
+ setError(null);
1596
+ try {
1597
+ const result = await fetcher({ ...params, quickFilterValue: params.filterModel.quickFilterValues?.join(" "), signal: controller.signal });
1598
+ if (!controller.signal.aborted) {
1599
+ setRows(result.rows);
1600
+ setTotal(result.total);
1763
1601
  }
1764
- abortControllerRef.current = new AbortController();
1765
- setLoading(true);
1766
- setError(null);
1767
- try {
1768
- const result = await fetcher(params);
1769
- if (isMountedRef.current) {
1770
- setRows(result.rows);
1771
- setTotal(result.total);
1772
- }
1773
- } catch (err) {
1774
- if (isMountedRef.current && err instanceof Error && err.name !== "AbortError") {
1775
- setError(err);
1776
- if (!keepPreviousData) {
1777
- setRows([]);
1778
- }
1779
- }
1780
- } finally {
1781
- if (isMountedRef.current) {
1782
- setLoading(false);
1602
+ } catch (err) {
1603
+ if (!controller.signal.aborted && err instanceof Error && err.name !== "AbortError") {
1604
+ setError(err);
1605
+ if (!keepPreviousData) {
1606
+ setRows([]);
1607
+ setTotal(0);
1783
1608
  }
1784
1609
  }
1785
- },
1786
- [fetcher, keepPreviousData]
1787
- );
1610
+ } finally {
1611
+ if (!controller.signal.aborted) {
1612
+ setLoading(false);
1613
+ }
1614
+ }
1615
+ });
1788
1616
  const refresh = useCallback(() => {
1789
1617
  fetchData({
1790
1618
  page: paginationModel.page,
@@ -1810,7 +1638,6 @@ function useDataGridBlock(options) {
1810
1638
  }, [fetchData, paginationModel, sortModel, filterModel, autoFetch]);
1811
1639
  useEffect(
1812
1640
  () => () => {
1813
- isMountedRef.current = false;
1814
1641
  if (abortControllerRef.current) {
1815
1642
  abortControllerRef.current.abort();
1816
1643
  }
@@ -1844,6 +1671,6 @@ function useDataGridBlock(options) {
1844
1671
  };
1845
1672
  }
1846
1673
 
1847
- export { AuthBlock, AuthGuard, DashboardBlock, DashboardBlockContent, DashboardBlockFooter, DashboardBlockHeader, DataGridBlock, ForgotPasswordForm, GuestGuard, LoginForm, RegisterForm, ResetPasswordForm, RoleBasedGuard, VerifyCodeForm, createConditionalRender, hasPermission, hasRole, useDashboardBlock, useDashboardBlockContext, useDataGridBlock, useDataGridBlockContext };
1674
+ export { AuthBlock, DashboardBlock, DashboardBlockContent, DashboardBlockFooter, DashboardBlockHeader, DataGridBlock, ForgotPasswordForm, LoginForm, RegisterForm, ResetPasswordForm, VerifyCodeForm, useDashboardBlock, useDashboardBlockContext, useDataGridBlock, useDataGridBlockContext };
1848
1675
  //# sourceMappingURL=index.js.map
1849
1676
  //# sourceMappingURL=index.js.map