@refinedev/antd 5.37.4 → 5.37.6

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 (647) hide show
  1. package/CHANGELOG.md +1793 -1778
  2. package/README.md +109 -17
  3. package/dist/components/autoSaveIndicator/index.d.cts +4 -0
  4. package/dist/components/autoSaveIndicator/index.d.cts.map +1 -0
  5. package/dist/components/autoSaveIndicator/index.d.mts +4 -0
  6. package/dist/components/autoSaveIndicator/index.d.mts.map +1 -0
  7. package/dist/components/autoSaveIndicator/index.d.ts.map +1 -1
  8. package/dist/components/breadcrumb/index.d.cts +6 -0
  9. package/dist/components/breadcrumb/index.d.cts.map +1 -0
  10. package/dist/components/breadcrumb/index.d.mts +6 -0
  11. package/dist/components/breadcrumb/index.d.mts.map +1 -0
  12. package/dist/components/breadcrumb/index.d.ts +1 -1
  13. package/dist/components/breadcrumb/index.d.ts.map +1 -1
  14. package/dist/components/buttons/clone/index.d.cts +11 -0
  15. package/dist/components/buttons/clone/index.d.cts.map +1 -0
  16. package/dist/components/buttons/clone/index.d.mts +11 -0
  17. package/dist/components/buttons/clone/index.d.mts.map +1 -0
  18. package/dist/components/buttons/clone/index.d.ts +1 -1
  19. package/dist/components/buttons/clone/index.d.ts.map +1 -1
  20. package/dist/components/buttons/create/index.d.cts +11 -0
  21. package/dist/components/buttons/create/index.d.cts.map +1 -0
  22. package/dist/components/buttons/create/index.d.mts +11 -0
  23. package/dist/components/buttons/create/index.d.mts.map +1 -0
  24. package/dist/components/buttons/create/index.d.ts +1 -1
  25. package/dist/components/buttons/create/index.d.ts.map +1 -1
  26. package/dist/components/buttons/delete/index.d.cts +10 -0
  27. package/dist/components/buttons/delete/index.d.cts.map +1 -0
  28. package/dist/components/buttons/delete/index.d.mts +10 -0
  29. package/dist/components/buttons/delete/index.d.mts.map +1 -0
  30. package/dist/components/buttons/delete/index.d.ts +1 -1
  31. package/dist/components/buttons/delete/index.d.ts.map +1 -1
  32. package/dist/components/buttons/edit/index.d.cts +11 -0
  33. package/dist/components/buttons/edit/index.d.cts.map +1 -0
  34. package/dist/components/buttons/edit/index.d.mts +11 -0
  35. package/dist/components/buttons/edit/index.d.mts.map +1 -0
  36. package/dist/components/buttons/edit/index.d.ts.map +1 -1
  37. package/dist/components/buttons/export/index.d.cts +10 -0
  38. package/dist/components/buttons/export/index.d.cts.map +1 -0
  39. package/dist/components/buttons/export/index.d.mts +10 -0
  40. package/dist/components/buttons/export/index.d.mts.map +1 -0
  41. package/dist/components/buttons/import/index.d.cts +11 -0
  42. package/dist/components/buttons/import/index.d.cts.map +1 -0
  43. package/dist/components/buttons/import/index.d.mts +11 -0
  44. package/dist/components/buttons/import/index.d.mts.map +1 -0
  45. package/dist/components/buttons/import/index.d.ts.map +1 -1
  46. package/dist/components/buttons/index.d.cts +12 -0
  47. package/dist/components/buttons/index.d.cts.map +1 -0
  48. package/dist/components/buttons/index.d.mts +12 -0
  49. package/dist/components/buttons/index.d.mts.map +1 -0
  50. package/dist/components/buttons/list/index.d.cts +11 -0
  51. package/dist/components/buttons/list/index.d.cts.map +1 -0
  52. package/dist/components/buttons/list/index.d.mts +11 -0
  53. package/dist/components/buttons/list/index.d.mts.map +1 -0
  54. package/dist/components/buttons/list/index.d.ts.map +1 -1
  55. package/dist/components/buttons/refresh/index.d.cts +10 -0
  56. package/dist/components/buttons/refresh/index.d.cts.map +1 -0
  57. package/dist/components/buttons/refresh/index.d.mts +10 -0
  58. package/dist/components/buttons/refresh/index.d.mts.map +1 -0
  59. package/dist/components/buttons/refresh/index.d.ts.map +1 -1
  60. package/dist/components/buttons/save/index.d.cts +10 -0
  61. package/dist/components/buttons/save/index.d.cts.map +1 -0
  62. package/dist/components/buttons/save/index.d.mts +10 -0
  63. package/dist/components/buttons/save/index.d.mts.map +1 -0
  64. package/dist/components/buttons/show/index.d.cts +11 -0
  65. package/dist/components/buttons/show/index.d.cts.map +1 -0
  66. package/dist/components/buttons/show/index.d.mts +11 -0
  67. package/dist/components/buttons/show/index.d.mts.map +1 -0
  68. package/dist/components/buttons/show/index.d.ts.map +1 -1
  69. package/dist/components/buttons/types.d.cts +24 -0
  70. package/dist/components/buttons/types.d.cts.map +1 -0
  71. package/dist/components/buttons/types.d.mts +24 -0
  72. package/dist/components/buttons/types.d.mts.map +1 -0
  73. package/dist/components/buttons/types.d.ts +10 -10
  74. package/dist/components/buttons/types.d.ts.map +1 -1
  75. package/dist/components/crud/create/index.d.cts +10 -0
  76. package/dist/components/crud/create/index.d.cts.map +1 -0
  77. package/dist/components/crud/create/index.d.mts +10 -0
  78. package/dist/components/crud/create/index.d.mts.map +1 -0
  79. package/dist/components/crud/edit/index.d.cts +10 -0
  80. package/dist/components/crud/edit/index.d.cts.map +1 -0
  81. package/dist/components/crud/edit/index.d.mts +10 -0
  82. package/dist/components/crud/edit/index.d.mts.map +1 -0
  83. package/dist/components/crud/edit/index.d.ts.map +1 -1
  84. package/dist/components/crud/index.d.cts +6 -0
  85. package/dist/components/crud/index.d.cts.map +1 -0
  86. package/dist/components/crud/index.d.mts +6 -0
  87. package/dist/components/crud/index.d.mts.map +1 -0
  88. package/dist/components/crud/list/index.d.cts +10 -0
  89. package/dist/components/crud/list/index.d.cts.map +1 -0
  90. package/dist/components/crud/list/index.d.mts +10 -0
  91. package/dist/components/crud/list/index.d.mts.map +1 -0
  92. package/dist/components/crud/list/index.d.ts.map +1 -1
  93. package/dist/components/crud/show/index.d.cts +10 -0
  94. package/dist/components/crud/show/index.d.cts.map +1 -0
  95. package/dist/components/crud/show/index.d.mts +10 -0
  96. package/dist/components/crud/show/index.d.mts.map +1 -0
  97. package/dist/components/crud/show/index.d.ts.map +1 -1
  98. package/dist/components/crud/types.d.cts +10 -0
  99. package/dist/components/crud/types.d.cts.map +1 -0
  100. package/dist/components/crud/types.d.mts +10 -0
  101. package/dist/components/crud/types.d.mts.map +1 -0
  102. package/dist/components/crud/types.d.ts +4 -4
  103. package/dist/components/crud/types.d.ts.map +1 -1
  104. package/dist/components/fields/boolean/index.d.cts +9 -0
  105. package/dist/components/fields/boolean/index.d.cts.map +1 -0
  106. package/dist/components/fields/boolean/index.d.mts +9 -0
  107. package/dist/components/fields/boolean/index.d.mts.map +1 -0
  108. package/dist/components/fields/date/index.d.cts +9 -0
  109. package/dist/components/fields/date/index.d.cts.map +1 -0
  110. package/dist/components/fields/date/index.d.mts +9 -0
  111. package/dist/components/fields/date/index.d.mts.map +1 -0
  112. package/dist/components/fields/email/index.d.cts +10 -0
  113. package/dist/components/fields/email/index.d.cts.map +1 -0
  114. package/dist/components/fields/email/index.d.mts +10 -0
  115. package/dist/components/fields/email/index.d.mts.map +1 -0
  116. package/dist/components/fields/file/index.d.cts +9 -0
  117. package/dist/components/fields/file/index.d.cts.map +1 -0
  118. package/dist/components/fields/file/index.d.mts +9 -0
  119. package/dist/components/fields/file/index.d.mts.map +1 -0
  120. package/dist/components/fields/image/index.d.cts +9 -0
  121. package/dist/components/fields/image/index.d.cts.map +1 -0
  122. package/dist/components/fields/image/index.d.mts +9 -0
  123. package/dist/components/fields/image/index.d.mts.map +1 -0
  124. package/dist/components/fields/index.d.cts +12 -0
  125. package/dist/components/fields/index.d.cts.map +1 -0
  126. package/dist/components/fields/index.d.mts +12 -0
  127. package/dist/components/fields/index.d.mts.map +1 -0
  128. package/dist/components/fields/markdown/index.d.cts +9 -0
  129. package/dist/components/fields/markdown/index.d.cts.map +1 -0
  130. package/dist/components/fields/markdown/index.d.mts +9 -0
  131. package/dist/components/fields/markdown/index.d.mts.map +1 -0
  132. package/dist/components/fields/number/index.d.cts +9 -0
  133. package/dist/components/fields/number/index.d.cts.map +1 -0
  134. package/dist/components/fields/number/index.d.mts +9 -0
  135. package/dist/components/fields/number/index.d.mts.map +1 -0
  136. package/dist/components/fields/tag/index.d.cts +9 -0
  137. package/dist/components/fields/tag/index.d.cts.map +1 -0
  138. package/dist/components/fields/tag/index.d.mts +9 -0
  139. package/dist/components/fields/tag/index.d.mts.map +1 -0
  140. package/dist/components/fields/text/index.d.cts +9 -0
  141. package/dist/components/fields/text/index.d.cts.map +1 -0
  142. package/dist/components/fields/text/index.d.mts +9 -0
  143. package/dist/components/fields/text/index.d.mts.map +1 -0
  144. package/dist/components/fields/types.d.cts +20 -0
  145. package/dist/components/fields/types.d.cts.map +1 -0
  146. package/dist/components/fields/types.d.mts +20 -0
  147. package/dist/components/fields/types.d.mts.map +1 -0
  148. package/dist/components/fields/types.d.ts +10 -10
  149. package/dist/components/fields/types.d.ts.map +1 -1
  150. package/dist/components/fields/url/index.d.cts +10 -0
  151. package/dist/components/fields/url/index.d.cts.map +1 -0
  152. package/dist/components/fields/url/index.d.mts +10 -0
  153. package/dist/components/fields/url/index.d.mts.map +1 -0
  154. package/dist/components/index.d.cts +24 -0
  155. package/dist/components/index.d.cts.map +1 -0
  156. package/dist/components/index.d.mts +24 -0
  157. package/dist/components/index.d.mts.map +1 -0
  158. package/dist/components/layout/header/index.d.cts +4 -0
  159. package/dist/components/layout/header/index.d.cts.map +1 -0
  160. package/dist/components/layout/header/index.d.mts +4 -0
  161. package/dist/components/layout/header/index.d.mts.map +1 -0
  162. package/dist/components/layout/index.d.cts +8 -0
  163. package/dist/components/layout/index.d.cts.map +1 -0
  164. package/dist/components/layout/index.d.mts +8 -0
  165. package/dist/components/layout/index.d.mts.map +1 -0
  166. package/dist/components/layout/sider/index.d.cts +4 -0
  167. package/dist/components/layout/sider/index.d.cts.map +1 -0
  168. package/dist/components/layout/sider/index.d.mts +4 -0
  169. package/dist/components/layout/sider/index.d.mts.map +1 -0
  170. package/dist/components/layout/sider/index.d.ts.map +1 -1
  171. package/dist/components/layout/sider/styles.d.cts +3 -0
  172. package/dist/components/layout/sider/styles.d.cts.map +1 -0
  173. package/dist/components/layout/sider/styles.d.mts +3 -0
  174. package/dist/components/layout/sider/styles.d.mts.map +1 -0
  175. package/dist/components/layout/title/index.d.cts +4 -0
  176. package/dist/components/layout/title/index.d.cts.map +1 -0
  177. package/dist/components/layout/title/index.d.mts +4 -0
  178. package/dist/components/layout/title/index.d.mts.map +1 -0
  179. package/dist/components/layout/title/index.d.ts.map +1 -1
  180. package/dist/components/layout/types.d.cts +3 -0
  181. package/dist/components/layout/types.d.cts.map +1 -0
  182. package/dist/components/layout/types.d.mts +3 -0
  183. package/dist/components/layout/types.d.mts.map +1 -0
  184. package/dist/components/layout/types.d.ts.map +1 -1
  185. package/dist/components/pageHeader/index.d.cts +5 -0
  186. package/dist/components/pageHeader/index.d.cts.map +1 -0
  187. package/dist/components/pageHeader/index.d.mts +5 -0
  188. package/dist/components/pageHeader/index.d.mts.map +1 -0
  189. package/dist/components/pageHeader/index.d.ts +1 -1
  190. package/dist/components/pageHeader/index.d.ts.map +1 -1
  191. package/dist/components/pages/auth/components/forgotPassword/index.d.cts +12 -0
  192. package/dist/components/pages/auth/components/forgotPassword/index.d.cts.map +1 -0
  193. package/dist/components/pages/auth/components/forgotPassword/index.d.mts +12 -0
  194. package/dist/components/pages/auth/components/forgotPassword/index.d.mts.map +1 -0
  195. package/dist/components/pages/auth/components/forgotPassword/index.d.ts +1 -1
  196. package/dist/components/pages/auth/components/forgotPassword/index.d.ts.map +1 -1
  197. package/dist/components/pages/auth/components/index.d.cts +5 -0
  198. package/dist/components/pages/auth/components/index.d.cts.map +1 -0
  199. package/dist/components/pages/auth/components/index.d.mts +5 -0
  200. package/dist/components/pages/auth/components/index.d.mts.map +1 -0
  201. package/dist/components/pages/auth/components/login/index.d.cts +12 -0
  202. package/dist/components/pages/auth/components/login/index.d.cts.map +1 -0
  203. package/dist/components/pages/auth/components/login/index.d.mts +12 -0
  204. package/dist/components/pages/auth/components/login/index.d.mts.map +1 -0
  205. package/dist/components/pages/auth/components/login/index.d.ts +1 -1
  206. package/dist/components/pages/auth/components/login/index.d.ts.map +1 -1
  207. package/dist/components/pages/auth/components/register/index.d.cts +12 -0
  208. package/dist/components/pages/auth/components/register/index.d.cts.map +1 -0
  209. package/dist/components/pages/auth/components/register/index.d.mts +12 -0
  210. package/dist/components/pages/auth/components/register/index.d.mts.map +1 -0
  211. package/dist/components/pages/auth/components/register/index.d.ts +1 -1
  212. package/dist/components/pages/auth/components/register/index.d.ts.map +1 -1
  213. package/dist/components/pages/auth/components/styles.d.cts +7 -0
  214. package/dist/components/pages/auth/components/styles.d.cts.map +1 -0
  215. package/dist/components/pages/auth/components/styles.d.mts +7 -0
  216. package/dist/components/pages/auth/components/styles.d.mts.map +1 -0
  217. package/dist/components/pages/auth/components/updatePassword/index.d.cts +12 -0
  218. package/dist/components/pages/auth/components/updatePassword/index.d.cts.map +1 -0
  219. package/dist/components/pages/auth/components/updatePassword/index.d.mts +12 -0
  220. package/dist/components/pages/auth/components/updatePassword/index.d.mts.map +1 -0
  221. package/dist/components/pages/auth/components/updatePassword/index.d.ts +1 -1
  222. package/dist/components/pages/auth/components/updatePassword/index.d.ts.map +1 -1
  223. package/dist/components/pages/auth/index.d.cts +14 -0
  224. package/dist/components/pages/auth/index.d.cts.map +1 -0
  225. package/dist/components/pages/auth/index.d.mts +14 -0
  226. package/dist/components/pages/auth/index.d.mts.map +1 -0
  227. package/dist/components/pages/auth/index.d.ts +1 -1
  228. package/dist/components/pages/auth/index.d.ts.map +1 -1
  229. package/dist/components/pages/error/index.d.cts +10 -0
  230. package/dist/components/pages/error/index.d.cts.map +1 -0
  231. package/dist/components/pages/error/index.d.mts +10 -0
  232. package/dist/components/pages/error/index.d.mts.map +1 -0
  233. package/dist/components/pages/index.d.cts +7 -0
  234. package/dist/components/pages/index.d.cts.map +1 -0
  235. package/dist/components/pages/index.d.mts +7 -0
  236. package/dist/components/pages/index.d.mts.map +1 -0
  237. package/dist/components/pages/login/index.d.cts +15 -0
  238. package/dist/components/pages/login/index.d.cts.map +1 -0
  239. package/dist/components/pages/login/index.d.mts +15 -0
  240. package/dist/components/pages/login/index.d.mts.map +1 -0
  241. package/dist/components/pages/login/index.d.ts.map +1 -1
  242. package/dist/components/pages/login/styles.d.cts +6 -0
  243. package/dist/components/pages/login/styles.d.cts.map +1 -0
  244. package/dist/components/pages/login/styles.d.mts +6 -0
  245. package/dist/components/pages/login/styles.d.mts.map +1 -0
  246. package/dist/components/pages/ready/index.d.cts +9 -0
  247. package/dist/components/pages/ready/index.d.cts.map +1 -0
  248. package/dist/components/pages/ready/index.d.mts +9 -0
  249. package/dist/components/pages/ready/index.d.mts.map +1 -0
  250. package/dist/components/pages/ready/index.d.ts.map +1 -1
  251. package/dist/components/pages/welcome/index.d.cts +7 -0
  252. package/dist/components/pages/welcome/index.d.cts.map +1 -0
  253. package/dist/components/pages/welcome/index.d.mts +7 -0
  254. package/dist/components/pages/welcome/index.d.mts.map +1 -0
  255. package/dist/components/table/components/filterDropdown/index.d.cts +13 -0
  256. package/dist/components/table/components/filterDropdown/index.d.cts.map +1 -0
  257. package/dist/components/table/components/filterDropdown/index.d.mts +13 -0
  258. package/dist/components/table/components/filterDropdown/index.d.mts.map +1 -0
  259. package/dist/components/table/components/filterDropdown/index.d.ts +2 -2
  260. package/dist/components/table/components/filterDropdown/index.d.ts.map +1 -1
  261. package/dist/components/table/components/index.d.cts +2 -0
  262. package/dist/components/table/components/index.d.cts.map +1 -0
  263. package/dist/components/table/components/index.d.mts +2 -0
  264. package/dist/components/table/components/index.d.mts.map +1 -0
  265. package/dist/components/table/index.d.cts +2 -0
  266. package/dist/components/table/index.d.cts.map +1 -0
  267. package/dist/components/table/index.d.mts +2 -0
  268. package/dist/components/table/index.d.mts.map +1 -0
  269. package/dist/components/themedLayout/header/index.d.cts +7 -0
  270. package/dist/components/themedLayout/header/index.d.cts.map +1 -0
  271. package/dist/components/themedLayout/header/index.d.mts +7 -0
  272. package/dist/components/themedLayout/header/index.d.mts.map +1 -0
  273. package/dist/components/themedLayout/header/index.d.ts.map +1 -1
  274. package/dist/components/themedLayout/index.d.cts +7 -0
  275. package/dist/components/themedLayout/index.d.cts.map +1 -0
  276. package/dist/components/themedLayout/index.d.mts +7 -0
  277. package/dist/components/themedLayout/index.d.mts.map +1 -0
  278. package/dist/components/themedLayout/sider/index.d.cts +7 -0
  279. package/dist/components/themedLayout/sider/index.d.cts.map +1 -0
  280. package/dist/components/themedLayout/sider/index.d.mts +7 -0
  281. package/dist/components/themedLayout/sider/index.d.mts.map +1 -0
  282. package/dist/components/themedLayout/sider/styles.d.cts +3 -0
  283. package/dist/components/themedLayout/sider/styles.d.cts.map +1 -0
  284. package/dist/components/themedLayout/sider/styles.d.mts +3 -0
  285. package/dist/components/themedLayout/sider/styles.d.mts.map +1 -0
  286. package/dist/components/themedLayout/title/index.d.cts +7 -0
  287. package/dist/components/themedLayout/title/index.d.cts.map +1 -0
  288. package/dist/components/themedLayout/title/index.d.mts +7 -0
  289. package/dist/components/themedLayout/title/index.d.mts.map +1 -0
  290. package/dist/components/themedLayout/types.d.cts +3 -0
  291. package/dist/components/themedLayout/types.d.cts.map +1 -0
  292. package/dist/components/themedLayout/types.d.mts +3 -0
  293. package/dist/components/themedLayout/types.d.mts.map +1 -0
  294. package/dist/components/themedLayout/types.d.ts.map +1 -1
  295. package/dist/components/themedLayoutV2/header/index.d.cts +4 -0
  296. package/dist/components/themedLayoutV2/header/index.d.cts.map +1 -0
  297. package/dist/components/themedLayoutV2/header/index.d.mts +4 -0
  298. package/dist/components/themedLayoutV2/header/index.d.mts.map +1 -0
  299. package/dist/components/themedLayoutV2/header/index.d.ts.map +1 -1
  300. package/dist/components/themedLayoutV2/index.d.cts +4 -0
  301. package/dist/components/themedLayoutV2/index.d.cts.map +1 -0
  302. package/dist/components/themedLayoutV2/index.d.mts +4 -0
  303. package/dist/components/themedLayoutV2/index.d.mts.map +1 -0
  304. package/dist/components/themedLayoutV2/index.d.ts.map +1 -1
  305. package/dist/components/themedLayoutV2/sider/index.d.cts +4 -0
  306. package/dist/components/themedLayoutV2/sider/index.d.cts.map +1 -0
  307. package/dist/components/themedLayoutV2/sider/index.d.mts +4 -0
  308. package/dist/components/themedLayoutV2/sider/index.d.mts.map +1 -0
  309. package/dist/components/themedLayoutV2/sider/index.d.ts.map +1 -1
  310. package/dist/components/themedLayoutV2/sider/styles.d.cts +3 -0
  311. package/dist/components/themedLayoutV2/sider/styles.d.cts.map +1 -0
  312. package/dist/components/themedLayoutV2/sider/styles.d.mts +3 -0
  313. package/dist/components/themedLayoutV2/sider/styles.d.mts.map +1 -0
  314. package/dist/components/themedLayoutV2/title/index.d.cts +4 -0
  315. package/dist/components/themedLayoutV2/title/index.d.cts.map +1 -0
  316. package/dist/components/themedLayoutV2/title/index.d.mts +4 -0
  317. package/dist/components/themedLayoutV2/title/index.d.mts.map +1 -0
  318. package/dist/components/themedLayoutV2/types.d.cts +6 -0
  319. package/dist/components/themedLayoutV2/types.d.cts.map +1 -0
  320. package/dist/components/themedLayoutV2/types.d.mts +6 -0
  321. package/dist/components/themedLayoutV2/types.d.mts.map +1 -0
  322. package/dist/components/themedLayoutV2/types.d.ts +1 -1
  323. package/dist/components/themedLayoutV2/types.d.ts.map +1 -1
  324. package/dist/components/undoableNotification/index.d.cts +10 -0
  325. package/dist/components/undoableNotification/index.d.cts.map +1 -0
  326. package/dist/components/undoableNotification/index.d.mts +10 -0
  327. package/dist/components/undoableNotification/index.d.mts.map +1 -0
  328. package/dist/components/undoableNotification/index.d.ts +1 -1
  329. package/dist/components/undoableNotification/index.d.ts.map +1 -1
  330. package/dist/contexts/index.d.cts +2 -0
  331. package/dist/contexts/index.d.cts.map +1 -0
  332. package/dist/contexts/index.d.mts +2 -0
  333. package/dist/contexts/index.d.mts.map +1 -0
  334. package/dist/contexts/index.d.ts.map +1 -1
  335. package/dist/contexts/themedLayoutContext/IThemedLayoutContext.d.cts +7 -0
  336. package/dist/contexts/themedLayoutContext/IThemedLayoutContext.d.cts.map +1 -0
  337. package/dist/contexts/themedLayoutContext/IThemedLayoutContext.d.mts +7 -0
  338. package/dist/contexts/themedLayoutContext/IThemedLayoutContext.d.mts.map +1 -0
  339. package/dist/contexts/themedLayoutContext/IThemedLayoutContext.d.ts.map +1 -1
  340. package/dist/contexts/themedLayoutContext/index.d.cts +8 -0
  341. package/dist/contexts/themedLayoutContext/index.d.cts.map +1 -0
  342. package/dist/contexts/themedLayoutContext/index.d.mts +8 -0
  343. package/dist/contexts/themedLayoutContext/index.d.mts.map +1 -0
  344. package/dist/contexts/themedLayoutContext/index.d.ts.map +1 -1
  345. package/dist/definitions/index.d.cts +4 -0
  346. package/dist/definitions/index.d.cts.map +1 -0
  347. package/dist/definitions/index.d.mts +4 -0
  348. package/dist/definitions/index.d.mts.map +1 -0
  349. package/dist/definitions/table/index.d.cts +13 -0
  350. package/dist/definitions/table/index.d.cts.map +1 -0
  351. package/dist/definitions/table/index.d.mts +13 -0
  352. package/dist/definitions/table/index.d.mts.map +1 -0
  353. package/dist/definitions/table/index.d.ts +6 -3
  354. package/dist/definitions/table/index.d.ts.map +1 -1
  355. package/dist/definitions/themes/index.d.cts +6 -0
  356. package/dist/definitions/themes/index.d.cts.map +1 -0
  357. package/dist/definitions/themes/index.d.mts +6 -0
  358. package/dist/definitions/themes/index.d.mts.map +1 -0
  359. package/dist/definitions/themes/index.d.ts +2 -2
  360. package/dist/definitions/themes/index.d.ts.map +1 -1
  361. package/dist/definitions/upload/index.d.cts +4 -0
  362. package/dist/definitions/upload/index.d.cts.map +1 -0
  363. package/dist/definitions/upload/index.d.mts +4 -0
  364. package/dist/definitions/upload/index.d.mts.map +1 -0
  365. package/dist/hooks/fields/index.d.cts +4 -0
  366. package/dist/hooks/fields/index.d.cts.map +1 -0
  367. package/dist/hooks/fields/index.d.mts +4 -0
  368. package/dist/hooks/fields/index.d.mts.map +1 -0
  369. package/dist/hooks/fields/useCheckboxGroup/index.d.cts +29 -0
  370. package/dist/hooks/fields/useCheckboxGroup/index.d.cts.map +1 -0
  371. package/dist/hooks/fields/useCheckboxGroup/index.d.mts +29 -0
  372. package/dist/hooks/fields/useCheckboxGroup/index.d.mts.map +1 -0
  373. package/dist/hooks/fields/useCheckboxGroup/index.d.ts +2 -2
  374. package/dist/hooks/fields/useCheckboxGroup/index.d.ts.map +1 -1
  375. package/dist/hooks/fields/useRadioGroup/index.d.cts +29 -0
  376. package/dist/hooks/fields/useRadioGroup/index.d.cts.map +1 -0
  377. package/dist/hooks/fields/useRadioGroup/index.d.mts +29 -0
  378. package/dist/hooks/fields/useRadioGroup/index.d.mts.map +1 -0
  379. package/dist/hooks/fields/useRadioGroup/index.d.ts +2 -2
  380. package/dist/hooks/fields/useRadioGroup/index.d.ts.map +1 -1
  381. package/dist/hooks/fields/useSelect/index.d.cts +20 -0
  382. package/dist/hooks/fields/useSelect/index.d.cts.map +1 -0
  383. package/dist/hooks/fields/useSelect/index.d.mts +20 -0
  384. package/dist/hooks/fields/useSelect/index.d.mts.map +1 -0
  385. package/dist/hooks/fields/useSelect/index.d.ts +1 -1
  386. package/dist/hooks/fields/useSelect/index.d.ts.map +1 -1
  387. package/dist/hooks/form/index.d.cts +5 -0
  388. package/dist/hooks/form/index.d.cts.map +1 -0
  389. package/dist/hooks/form/index.d.mts +5 -0
  390. package/dist/hooks/form/index.d.mts.map +1 -0
  391. package/dist/hooks/form/index.d.ts.map +1 -1
  392. package/dist/hooks/form/useDrawerForm/index.d.cts +2 -0
  393. package/dist/hooks/form/useDrawerForm/index.d.cts.map +1 -0
  394. package/dist/hooks/form/useDrawerForm/index.d.mts +2 -0
  395. package/dist/hooks/form/useDrawerForm/index.d.mts.map +1 -0
  396. package/dist/hooks/form/useDrawerForm/index.d.ts.map +1 -1
  397. package/dist/hooks/form/useDrawerForm/useDrawerForm.d.cts +37 -0
  398. package/dist/hooks/form/useDrawerForm/useDrawerForm.d.cts.map +1 -0
  399. package/dist/hooks/form/useDrawerForm/useDrawerForm.d.mts +37 -0
  400. package/dist/hooks/form/useDrawerForm/useDrawerForm.d.mts.map +1 -0
  401. package/dist/hooks/form/useDrawerForm/useDrawerForm.d.ts +2 -2
  402. package/dist/hooks/form/useDrawerForm/useDrawerForm.d.ts.map +1 -1
  403. package/dist/hooks/form/useForm.d.cts +40 -0
  404. package/dist/hooks/form/useForm.d.cts.map +1 -0
  405. package/dist/hooks/form/useForm.d.mts +40 -0
  406. package/dist/hooks/form/useForm.d.mts.map +1 -0
  407. package/dist/hooks/form/useForm.d.ts +2 -2
  408. package/dist/hooks/form/useForm.d.ts.map +1 -1
  409. package/dist/hooks/form/useModalForm/index.d.cts +2 -0
  410. package/dist/hooks/form/useModalForm/index.d.cts.map +1 -0
  411. package/dist/hooks/form/useModalForm/index.d.mts +2 -0
  412. package/dist/hooks/form/useModalForm/index.d.mts.map +1 -0
  413. package/dist/hooks/form/useModalForm/index.d.ts.map +1 -1
  414. package/dist/hooks/form/useModalForm/useModalForm.d.cts +42 -0
  415. package/dist/hooks/form/useModalForm/useModalForm.d.cts.map +1 -0
  416. package/dist/hooks/form/useModalForm/useModalForm.d.mts +42 -0
  417. package/dist/hooks/form/useModalForm/useModalForm.d.mts.map +1 -0
  418. package/dist/hooks/form/useModalForm/useModalForm.d.ts +4 -4
  419. package/dist/hooks/form/useModalForm/useModalForm.d.ts.map +1 -1
  420. package/dist/hooks/form/useStepsForm/index.d.cts +2 -0
  421. package/dist/hooks/form/useStepsForm/index.d.cts.map +1 -0
  422. package/dist/hooks/form/useStepsForm/index.d.mts +2 -0
  423. package/dist/hooks/form/useStepsForm/index.d.mts.map +1 -0
  424. package/dist/hooks/form/useStepsForm/index.d.ts.map +1 -1
  425. package/dist/hooks/form/useStepsForm/useStepsForm.d.cts +35 -0
  426. package/dist/hooks/form/useStepsForm/useStepsForm.d.cts.map +1 -0
  427. package/dist/hooks/form/useStepsForm/useStepsForm.d.mts +35 -0
  428. package/dist/hooks/form/useStepsForm/useStepsForm.d.mts.map +1 -0
  429. package/dist/hooks/form/useStepsForm/useStepsForm.d.ts +3 -3
  430. package/dist/hooks/form/useStepsForm/useStepsForm.d.ts.map +1 -1
  431. package/dist/hooks/import/index.d.cts +18 -0
  432. package/dist/hooks/import/index.d.cts.map +1 -0
  433. package/dist/hooks/import/index.d.mts +18 -0
  434. package/dist/hooks/import/index.d.mts.map +1 -0
  435. package/dist/hooks/import/index.d.ts.map +1 -1
  436. package/dist/hooks/index.d.cts +10 -0
  437. package/dist/hooks/index.d.cts.map +1 -0
  438. package/dist/hooks/index.d.mts +10 -0
  439. package/dist/hooks/index.d.mts.map +1 -0
  440. package/dist/hooks/list/index.d.cts +2 -0
  441. package/dist/hooks/list/index.d.cts.map +1 -0
  442. package/dist/hooks/list/index.d.mts +2 -0
  443. package/dist/hooks/list/index.d.mts.map +1 -0
  444. package/dist/hooks/list/useSimpleList/index.d.cts +2 -0
  445. package/dist/hooks/list/useSimpleList/index.d.cts.map +1 -0
  446. package/dist/hooks/list/useSimpleList/index.d.mts +2 -0
  447. package/dist/hooks/list/useSimpleList/index.d.mts.map +1 -0
  448. package/dist/hooks/list/useSimpleList/useSimpleList.d.cts +24 -0
  449. package/dist/hooks/list/useSimpleList/useSimpleList.d.cts.map +1 -0
  450. package/dist/hooks/list/useSimpleList/useSimpleList.d.mts +24 -0
  451. package/dist/hooks/list/useSimpleList/useSimpleList.d.mts.map +1 -0
  452. package/dist/hooks/list/useSimpleList/useSimpleList.d.ts +3 -3
  453. package/dist/hooks/list/useSimpleList/useSimpleList.d.ts.map +1 -1
  454. package/dist/hooks/modal/index.d.cts +2 -0
  455. package/dist/hooks/modal/index.d.cts.map +1 -0
  456. package/dist/hooks/modal/index.d.mts +2 -0
  457. package/dist/hooks/modal/index.d.mts.map +1 -0
  458. package/dist/hooks/modal/useModal/index.d.cts +18 -0
  459. package/dist/hooks/modal/useModal/index.d.cts.map +1 -0
  460. package/dist/hooks/modal/useModal/index.d.mts +18 -0
  461. package/dist/hooks/modal/useModal/index.d.mts.map +1 -0
  462. package/dist/hooks/modal/useModal/index.d.ts +2 -2
  463. package/dist/hooks/modal/useModal/index.d.ts.map +1 -1
  464. package/dist/hooks/table/index.d.cts +3 -0
  465. package/dist/hooks/table/index.d.cts.map +1 -0
  466. package/dist/hooks/table/index.d.mts +3 -0
  467. package/dist/hooks/table/index.d.mts.map +1 -0
  468. package/dist/hooks/table/useEditableTable/index.d.cts +2 -0
  469. package/dist/hooks/table/useEditableTable/index.d.cts.map +1 -0
  470. package/dist/hooks/table/useEditableTable/index.d.mts +2 -0
  471. package/dist/hooks/table/useEditableTable/index.d.mts.map +1 -0
  472. package/dist/hooks/table/useEditableTable/useEditableTable.d.cts +40 -0
  473. package/dist/hooks/table/useEditableTable/useEditableTable.d.cts.map +1 -0
  474. package/dist/hooks/table/useEditableTable/useEditableTable.d.mts +40 -0
  475. package/dist/hooks/table/useEditableTable/useEditableTable.d.mts.map +1 -0
  476. package/dist/hooks/table/useEditableTable/useEditableTable.d.ts +2 -2
  477. package/dist/hooks/table/useEditableTable/useEditableTable.d.ts.map +1 -1
  478. package/dist/hooks/table/useTable/index.d.cts +2 -0
  479. package/dist/hooks/table/useTable/index.d.cts.map +1 -0
  480. package/dist/hooks/table/useTable/index.d.mts +2 -0
  481. package/dist/hooks/table/useTable/index.d.mts.map +1 -0
  482. package/dist/hooks/table/useTable/paginationLink.d.cts +8 -0
  483. package/dist/hooks/table/useTable/paginationLink.d.cts.map +1 -0
  484. package/dist/hooks/table/useTable/paginationLink.d.mts +8 -0
  485. package/dist/hooks/table/useTable/paginationLink.d.mts.map +1 -0
  486. package/dist/hooks/table/useTable/paginationLink.d.ts.map +1 -1
  487. package/dist/hooks/table/useTable/useTable.d.cts +24 -0
  488. package/dist/hooks/table/useTable/useTable.d.cts.map +1 -0
  489. package/dist/hooks/table/useTable/useTable.d.mts +24 -0
  490. package/dist/hooks/table/useTable/useTable.d.mts.map +1 -0
  491. package/dist/hooks/table/useTable/useTable.d.ts +2 -2
  492. package/dist/hooks/table/useTable/useTable.d.ts.map +1 -1
  493. package/dist/hooks/useFileUploadState/index.d.cts +7 -0
  494. package/dist/hooks/useFileUploadState/index.d.cts.map +1 -0
  495. package/dist/hooks/useFileUploadState/index.d.mts +7 -0
  496. package/dist/hooks/useFileUploadState/index.d.mts.map +1 -0
  497. package/dist/hooks/useFileUploadState/index.d.ts +1 -1
  498. package/dist/hooks/useFileUploadState/index.d.ts.map +1 -1
  499. package/dist/hooks/useSiderVisible/index.d.cts +11 -0
  500. package/dist/hooks/useSiderVisible/index.d.cts.map +1 -0
  501. package/dist/hooks/useSiderVisible/index.d.mts +11 -0
  502. package/dist/hooks/useSiderVisible/index.d.mts.map +1 -0
  503. package/dist/hooks/useSiderVisible/index.d.ts +1 -1
  504. package/dist/hooks/useSiderVisible/index.d.ts.map +1 -1
  505. package/dist/hooks/useThemedLayoutContext/index.d.cts +4 -0
  506. package/dist/hooks/useThemedLayoutContext/index.d.cts.map +1 -0
  507. package/dist/hooks/useThemedLayoutContext/index.d.mts +4 -0
  508. package/dist/hooks/useThemedLayoutContext/index.d.mts.map +1 -0
  509. package/dist/hooks/useThemedLayoutContext/index.d.ts +1 -1
  510. package/dist/hooks/useThemedLayoutContext/index.d.ts.map +1 -1
  511. package/dist/index.cjs +3 -0
  512. package/dist/index.cjs.map +1 -0
  513. package/dist/index.d.cts +8 -0
  514. package/dist/index.d.cts.map +1 -0
  515. package/dist/index.d.mts +8 -0
  516. package/dist/index.d.mts.map +1 -0
  517. package/dist/index.d.ts.map +1 -1
  518. package/dist/index.mjs +3 -0
  519. package/dist/index.mjs.map +1 -0
  520. package/dist/interfaces/field.d.cts +4 -0
  521. package/dist/interfaces/field.d.cts.map +1 -0
  522. package/dist/interfaces/field.d.mts +4 -0
  523. package/dist/interfaces/field.d.mts.map +1 -0
  524. package/dist/interfaces/field.d.ts +1 -1
  525. package/dist/interfaces/field.d.ts.map +1 -1
  526. package/dist/interfaces/index.d.cts +19 -0
  527. package/dist/interfaces/index.d.cts.map +1 -0
  528. package/dist/interfaces/index.d.mts +19 -0
  529. package/dist/interfaces/index.d.mts.map +1 -0
  530. package/dist/interfaces/index.d.ts +3 -3
  531. package/dist/interfaces/index.d.ts.map +1 -1
  532. package/dist/interfaces/upload.d.cts +10 -0
  533. package/dist/interfaces/upload.d.cts.map +1 -0
  534. package/dist/interfaces/upload.d.mts +10 -0
  535. package/dist/interfaces/upload.d.mts.map +1 -0
  536. package/dist/interfaces/upload.d.ts.map +1 -1
  537. package/dist/providers/index.d.cts +2 -0
  538. package/dist/providers/index.d.cts.map +1 -0
  539. package/dist/providers/index.d.mts +2 -0
  540. package/dist/providers/index.d.mts.map +1 -0
  541. package/dist/providers/notificationProvider/index.d.cts +8 -0
  542. package/dist/providers/notificationProvider/index.d.cts.map +1 -0
  543. package/dist/providers/notificationProvider/index.d.mts +8 -0
  544. package/dist/providers/notificationProvider/index.d.mts.map +1 -0
  545. package/package.json +54 -37
  546. package/refine.config.js +497 -524
  547. package/src/components/autoSaveIndicator/index.tsx +69 -69
  548. package/src/components/breadcrumb/index.tsx +63 -65
  549. package/src/components/buttons/clone/index.tsx +47 -98
  550. package/src/components/buttons/create/index.tsx +49 -99
  551. package/src/components/buttons/delete/index.tsx +70 -130
  552. package/src/components/buttons/edit/index.tsx +47 -99
  553. package/src/components/buttons/export/index.tsx +18 -18
  554. package/src/components/buttons/import/index.tsx +22 -21
  555. package/src/components/buttons/list/index.tsx +44 -116
  556. package/src/components/buttons/refresh/index.tsx +29 -59
  557. package/src/components/buttons/save/index.tsx +18 -18
  558. package/src/components/buttons/show/index.tsx +46 -97
  559. package/src/components/buttons/types.ts +20 -20
  560. package/src/components/crud/create/index.tsx +120 -120
  561. package/src/components/crud/edit/index.tsx +205 -207
  562. package/src/components/crud/list/index.tsx +88 -90
  563. package/src/components/crud/show/index.tsx +175 -185
  564. package/src/components/crud/types.ts +41 -56
  565. package/src/components/fields/boolean/index.tsx +11 -11
  566. package/src/components/fields/date/index.tsx +13 -13
  567. package/src/components/fields/email/index.tsx +5 -5
  568. package/src/components/fields/file/index.tsx +8 -8
  569. package/src/components/fields/image/index.tsx +4 -4
  570. package/src/components/fields/markdown/index.tsx +9 -9
  571. package/src/components/fields/number/index.tsx +17 -17
  572. package/src/components/fields/tag/index.tsx +1 -1
  573. package/src/components/fields/text/index.tsx +1 -1
  574. package/src/components/fields/types.ts +18 -18
  575. package/src/components/fields/url/index.tsx +8 -8
  576. package/src/components/layout/header/index.tsx +25 -25
  577. package/src/components/layout/index.tsx +30 -30
  578. package/src/components/layout/sider/index.tsx +238 -246
  579. package/src/components/layout/sider/styles.ts +5 -5
  580. package/src/components/layout/title/index.tsx +40 -40
  581. package/src/components/layout/types.ts +6 -6
  582. package/src/components/pageHeader/index.tsx +44 -44
  583. package/src/components/pages/auth/components/forgotPassword/index.tsx +177 -180
  584. package/src/components/pages/auth/components/login/index.tsx +258 -271
  585. package/src/components/pages/auth/components/register/index.tsx +247 -263
  586. package/src/components/pages/auth/components/styles.ts +16 -16
  587. package/src/components/pages/auth/components/updatePassword/index.tsx +160 -174
  588. package/src/components/pages/auth/index.tsx +23 -23
  589. package/src/components/pages/error/index.tsx +57 -57
  590. package/src/components/pages/login/index.tsx +120 -146
  591. package/src/components/pages/login/styles.ts +12 -12
  592. package/src/components/pages/ready/index.tsx +72 -80
  593. package/src/components/pages/welcome/index.tsx +1 -1
  594. package/src/components/table/components/filterDropdown/index.tsx +90 -93
  595. package/src/components/themedLayout/header/index.tsx +28 -32
  596. package/src/components/themedLayout/index.tsx +30 -30
  597. package/src/components/themedLayout/sider/index.tsx +279 -279
  598. package/src/components/themedLayout/sider/styles.ts +5 -5
  599. package/src/components/themedLayout/title/index.tsx +66 -66
  600. package/src/components/themedLayout/types.ts +8 -8
  601. package/src/components/themedLayoutV2/header/index.tsx +37 -41
  602. package/src/components/themedLayoutV2/index.tsx +34 -36
  603. package/src/components/themedLayoutV2/sider/index.tsx +309 -313
  604. package/src/components/themedLayoutV2/sider/styles.ts +5 -5
  605. package/src/components/themedLayoutV2/title/index.tsx +66 -66
  606. package/src/components/themedLayoutV2/types.ts +9 -9
  607. package/src/components/undoableNotification/index.tsx +31 -31
  608. package/src/contexts/index.ts +2 -2
  609. package/src/contexts/themedLayoutContext/IThemedLayoutContext.ts +4 -4
  610. package/src/contexts/themedLayoutContext/index.tsx +22 -22
  611. package/src/definitions/table/index.ts +94 -83
  612. package/src/definitions/themes/index.ts +35 -35
  613. package/src/definitions/upload/index.ts +17 -17
  614. package/src/hooks/fields/useCheckboxGroup/index.ts +64 -64
  615. package/src/hooks/fields/useRadioGroup/index.ts +60 -63
  616. package/src/hooks/fields/useSelect/index.ts +30 -30
  617. package/src/hooks/form/index.ts +10 -10
  618. package/src/hooks/form/useDrawerForm/index.ts +4 -4
  619. package/src/hooks/form/useDrawerForm/useDrawerForm.ts +257 -261
  620. package/src/hooks/form/useForm.ts +258 -259
  621. package/src/hooks/form/useModalForm/index.ts +3 -3
  622. package/src/hooks/form/useModalForm/useModalForm.ts +289 -295
  623. package/src/hooks/form/useStepsForm/index.ts +3 -3
  624. package/src/hooks/form/useStepsForm/useStepsForm.ts +96 -96
  625. package/src/hooks/import/index.tsx +104 -106
  626. package/src/hooks/list/useSimpleList/useSimpleList.ts +179 -185
  627. package/src/hooks/modal/useModal/index.tsx +24 -24
  628. package/src/hooks/table/useEditableTable/useEditableTable.ts +85 -85
  629. package/src/hooks/table/useTable/paginationLink.tsx +17 -17
  630. package/src/hooks/table/useTable/useTable.ts +197 -207
  631. package/src/hooks/useFileUploadState/index.ts +20 -20
  632. package/src/hooks/useSiderVisible/index.ts +16 -16
  633. package/src/hooks/useThemedLayoutContext/index.ts +12 -12
  634. package/src/index.tsx +4 -4
  635. package/src/interfaces/field.ts +1 -1
  636. package/src/interfaces/index.ts +7 -8
  637. package/src/interfaces/upload.ts +7 -7
  638. package/src/providers/notificationProvider/index.tsx +78 -78
  639. package/src/types/index.d.ts +2 -2
  640. package/src/types/sunflower.d.ts +68 -68
  641. package/tsconfig.json +30 -26
  642. package/dist/esm/index.js +0 -3
  643. package/dist/esm/index.js.map +0 -1
  644. package/dist/iife/index.js +0 -72
  645. package/dist/iife/index.js.map +0 -1
  646. package/dist/index.js +0 -3
  647. package/dist/index.js.map +0 -1
@@ -2,26 +2,26 @@ import { useLink, useRouterContext, useRouterType } from "@refinedev/core";
2
2
  import React, { ReactNode } from "react";
3
3
 
4
4
  interface PaginationLinkProps {
5
- to: string;
6
- element: ReactNode;
5
+ to: string;
6
+ element: ReactNode;
7
7
  }
8
8
 
9
9
  export const PaginationLink = ({ to, element }: PaginationLinkProps) => {
10
- const { Link: LegacyLink } = useRouterContext();
11
- const routerType = useRouterType();
12
- const Link = useLink();
10
+ const { Link: LegacyLink } = useRouterContext();
11
+ const routerType = useRouterType();
12
+ const Link = useLink();
13
13
 
14
- const ActiveLink = routerType === "legacy" ? LegacyLink : Link;
14
+ const ActiveLink = routerType === "legacy" ? LegacyLink : Link;
15
15
 
16
- return (
17
- <ActiveLink
18
- to={to}
19
- replace={false}
20
- onClick={(e: React.PointerEvent<HTMLButtonElement>) => {
21
- e.preventDefault();
22
- }}
23
- >
24
- {element}
25
- </ActiveLink>
26
- );
16
+ return (
17
+ <ActiveLink
18
+ to={to}
19
+ replace={false}
20
+ onClick={(e: React.PointerEvent<HTMLButtonElement>) => {
21
+ e.preventDefault();
22
+ }}
23
+ >
24
+ {element}
25
+ </ActiveLink>
26
+ );
27
27
  };
@@ -2,39 +2,36 @@ import React, { Children, createElement, Fragment } from "react";
2
2
  import { Grid, FormProps, Form, TablePaginationConfig, TableProps } from "antd";
3
3
  import { useForm as useFormSF } from "sunflower-antd";
4
4
 
5
- import { SorterResult } from "antd/lib/table/interface";
6
-
7
5
  import {
8
- useLiveMode,
9
- BaseRecord,
10
- CrudFilters,
11
- HttpError,
12
- useTable as useTableCore,
13
- useTableProps as useTablePropsCore,
14
- useTableReturnType as useTableCoreReturnType,
15
- pickNotDeprecated,
6
+ useLiveMode,
7
+ BaseRecord,
8
+ CrudFilters,
9
+ HttpError,
10
+ useTable as useTableCore,
11
+ useTableProps as useTablePropsCore,
12
+ useTableReturnType as useTableCoreReturnType,
13
+ pickNotDeprecated,
16
14
  } from "@refinedev/core";
17
15
 
18
16
  import {
19
- mapAntdSorterToCrudSorting,
20
- mapAntdFilterToCrudFilter,
17
+ mapAntdSorterToCrudSorting,
18
+ mapAntdFilterToCrudFilter,
21
19
  } from "@definitions/table";
22
20
  import { PaginationLink } from "./paginationLink";
21
+ import { FilterValue, SorterResult } from "../../../definitions/table";
23
22
 
24
23
  export type useTableProps<TQueryFnData, TError, TSearchVariables, TData> =
25
- useTablePropsCore<TQueryFnData, TError, TData> & {
26
- onSearch?: (
27
- data: TSearchVariables,
28
- ) => CrudFilters | Promise<CrudFilters>;
29
- };
24
+ useTablePropsCore<TQueryFnData, TError, TData> & {
25
+ onSearch?: (data: TSearchVariables) => CrudFilters | Promise<CrudFilters>;
26
+ };
30
27
 
31
28
  export type useTableReturnType<
32
- TData extends BaseRecord = BaseRecord,
33
- TError extends HttpError = HttpError,
34
- TSearchVariables = unknown,
29
+ TData extends BaseRecord = BaseRecord,
30
+ TError extends HttpError = HttpError,
31
+ TSearchVariables = unknown,
35
32
  > = useTableCoreReturnType<TData, TError> & {
36
- searchFormProps: FormProps<TSearchVariables>;
37
- tableProps: TableProps<TData>;
33
+ searchFormProps: FormProps<TSearchVariables>;
34
+ tableProps: TableProps<TData>;
38
35
  };
39
36
 
40
37
  /**
@@ -52,219 +49,212 @@ export type useTableReturnType<
52
49
  */
53
50
 
54
51
  export const useTable = <
55
- TQueryFnData extends BaseRecord = BaseRecord,
56
- TError extends HttpError = HttpError,
57
- TSearchVariables = unknown,
58
- TData extends BaseRecord = TQueryFnData,
52
+ TQueryFnData extends BaseRecord = BaseRecord,
53
+ TError extends HttpError = HttpError,
54
+ TSearchVariables = unknown,
55
+ TData extends BaseRecord = TQueryFnData,
59
56
  >({
60
- onSearch,
57
+ onSearch,
58
+ initialCurrent,
59
+ initialPageSize,
60
+ hasPagination = true,
61
+ pagination,
62
+ initialSorter,
63
+ permanentSorter,
64
+ initialFilter,
65
+ permanentFilter,
66
+ defaultSetFilterBehavior,
67
+ filters: filtersFromProp,
68
+ sorters: sortersFromProp,
69
+ syncWithLocation,
70
+ resource,
71
+ successNotification,
72
+ errorNotification,
73
+ queryOptions,
74
+ liveMode: liveModeFromProp,
75
+ onLiveEvent,
76
+ liveParams,
77
+ meta,
78
+ metaData,
79
+ dataProviderName,
80
+ }: useTableProps<
81
+ TQueryFnData,
82
+ TError,
83
+ TSearchVariables,
84
+ TData
85
+ > = {}): useTableReturnType<TData, TError, TSearchVariables> => {
86
+ const {
87
+ tableQueryResult,
88
+ current,
89
+ setCurrent,
90
+ pageSize,
91
+ setPageSize,
92
+ filters,
93
+ setFilters,
94
+ sorters,
95
+ setSorters,
96
+ sorter,
97
+ setSorter,
98
+ createLinkForSyncWithLocation,
99
+ pageCount,
100
+ overtime,
101
+ } = useTableCore<TQueryFnData, TError, TData>({
102
+ permanentSorter,
103
+ permanentFilter,
61
104
  initialCurrent,
62
105
  initialPageSize,
63
- hasPagination = true,
64
106
  pagination,
65
- initialSorter,
66
- permanentSorter,
67
- initialFilter,
68
- permanentFilter,
69
- defaultSetFilterBehavior,
107
+ hasPagination,
70
108
  filters: filtersFromProp,
71
109
  sorters: sortersFromProp,
110
+ initialSorter,
111
+ initialFilter,
72
112
  syncWithLocation,
73
113
  resource,
114
+ defaultSetFilterBehavior,
74
115
  successNotification,
75
116
  errorNotification,
76
117
  queryOptions,
77
118
  liveMode: liveModeFromProp,
78
119
  onLiveEvent,
79
120
  liveParams,
80
- meta,
81
- metaData,
121
+ meta: pickNotDeprecated(meta, metaData),
122
+ metaData: pickNotDeprecated(meta, metaData),
82
123
  dataProviderName,
83
- }: useTableProps<
84
- TQueryFnData,
85
- TError,
86
- TSearchVariables,
87
- TData
88
- > = {}): useTableReturnType<TData, TError, TSearchVariables> => {
89
- const {
90
- tableQueryResult,
91
- current,
92
- setCurrent,
93
- pageSize,
94
- setPageSize,
95
- filters,
96
- setFilters,
97
- sorters,
98
- setSorters,
99
- sorter,
100
- setSorter,
101
- createLinkForSyncWithLocation,
102
- pageCount,
103
- overtime,
104
- } = useTableCore<TQueryFnData, TError, TData>({
105
- permanentSorter,
106
- permanentFilter,
107
- initialCurrent,
108
- initialPageSize,
109
- pagination,
110
- hasPagination,
111
- filters: filtersFromProp,
112
- sorters: sortersFromProp,
113
- initialSorter,
114
- initialFilter,
115
- syncWithLocation,
116
- resource,
117
- defaultSetFilterBehavior,
118
- successNotification,
119
- errorNotification,
120
- queryOptions,
121
- liveMode: liveModeFromProp,
122
- onLiveEvent,
123
- liveParams,
124
- meta: pickNotDeprecated(meta, metaData),
125
- metaData: pickNotDeprecated(meta, metaData),
126
- dataProviderName,
127
- });
128
- const breakpoint = Grid.useBreakpoint();
129
- const [form] = Form.useForm<TSearchVariables>();
130
- const formSF = useFormSF<any, TSearchVariables>({
131
- form: form,
132
- });
133
- const liveMode = useLiveMode(liveModeFromProp);
124
+ });
125
+ const breakpoint = Grid.useBreakpoint();
126
+ const [form] = Form.useForm<TSearchVariables>();
127
+ const formSF = useFormSF<any, TSearchVariables>({
128
+ form: form,
129
+ });
130
+ const liveMode = useLiveMode(liveModeFromProp);
134
131
 
135
- const hasPaginationString = hasPagination === false ? "off" : "server";
136
- const isPaginationEnabled =
137
- (pagination?.mode ?? hasPaginationString) !== "off";
132
+ const hasPaginationString = hasPagination === false ? "off" : "server";
133
+ const isPaginationEnabled =
134
+ (pagination?.mode ?? hasPaginationString) !== "off";
138
135
 
139
- const preferredInitialFilters = pickNotDeprecated(
140
- filtersFromProp?.initial,
141
- initialFilter,
142
- );
143
-
144
- const { data, isFetched, isLoading } = tableQueryResult;
145
-
146
- const onChange = (
147
- paginationState: TablePaginationConfig,
148
- tableFilters: Record<
149
- string,
150
- (string | number | boolean) | (string | number | boolean)[] | null
151
- >,
152
- sorter: SorterResult<any> | SorterResult<any>[],
153
- ) => {
154
- if (tableFilters && Object.keys(tableFilters).length > 0) {
155
- // Map Antd:Filter -> refine:CrudFilter
156
- const crudFilters = mapAntdFilterToCrudFilter(
157
- tableFilters,
158
- filters,
159
- preferredInitialFilters,
160
- );
161
- setFilters(crudFilters);
162
- }
136
+ const preferredInitialFilters = pickNotDeprecated(
137
+ filtersFromProp?.initial,
138
+ initialFilter,
139
+ );
163
140
 
164
- if (sorter && Object.keys(sorter).length > 0) {
165
- // Map Antd:Sorter -> refine:CrudSorting
166
- const crudSorting = mapAntdSorterToCrudSorting(sorter);
167
- setSorters(crudSorting);
168
- }
141
+ const { data, isFetched, isLoading } = tableQueryResult;
169
142
 
170
- if (isPaginationEnabled) {
171
- setCurrent?.(paginationState.current || 1);
172
- setPageSize?.(paginationState.pageSize || 10);
173
- }
174
- };
143
+ const onChange = (
144
+ paginationState: TablePaginationConfig,
145
+ tableFilters: Record<string, FilterValue | null>,
146
+ sorter: SorterResult | SorterResult[],
147
+ ) => {
148
+ if (tableFilters && Object.keys(tableFilters).length > 0) {
149
+ // Map Antd:Filter -> refine:CrudFilter
150
+ const crudFilters = mapAntdFilterToCrudFilter(
151
+ tableFilters,
152
+ filters,
153
+ preferredInitialFilters,
154
+ );
155
+ setFilters(crudFilters);
156
+ }
175
157
 
176
- const onFinish = async (value: TSearchVariables) => {
177
- if (onSearch) {
178
- const searchFilters = await onSearch(value);
179
- setFilters(searchFilters);
158
+ if (sorter && Object.keys(sorter).length > 0) {
159
+ // Map Antd:Sorter -> refine:CrudSorting
160
+ const crudSorting = mapAntdSorterToCrudSorting(sorter);
161
+ setSorters(crudSorting);
162
+ }
180
163
 
181
- if (isPaginationEnabled) {
182
- setCurrent?.(1);
183
- }
184
- }
185
- };
164
+ if (isPaginationEnabled) {
165
+ setCurrent?.(paginationState.current || 1);
166
+ setPageSize?.(paginationState.pageSize || 10);
167
+ }
168
+ };
186
169
 
187
- const antdPagination = (): false | TablePaginationConfig => {
188
- if (isPaginationEnabled) {
189
- return {
190
- itemRender: (page, type, element) => {
191
- const link = createLinkForSyncWithLocation({
192
- pagination: {
193
- pageSize,
194
- current: page,
195
- },
196
- sorters,
197
- filters,
198
- });
170
+ const onFinish = async (value: TSearchVariables) => {
171
+ if (onSearch) {
172
+ const searchFilters = await onSearch(value);
173
+ setFilters(searchFilters);
199
174
 
200
- if (type === "page") {
201
- return createElement(PaginationLink, {
202
- to: link,
203
- element: `${page}`,
204
- });
205
- }
206
- if (type === "next" || type === "prev") {
207
- return createElement(PaginationLink, {
208
- to: link,
209
- element: element,
210
- });
211
- }
175
+ if (isPaginationEnabled) {
176
+ setCurrent?.(1);
177
+ }
178
+ }
179
+ };
212
180
 
213
- if (type === "jump-next" || type === "jump-prev") {
214
- const elementChildren = (element as React.ReactElement)
215
- ?.props?.children;
181
+ const antdPagination = (): false | TablePaginationConfig => {
182
+ if (isPaginationEnabled) {
183
+ return {
184
+ itemRender: (page, type, element) => {
185
+ const link = createLinkForSyncWithLocation({
186
+ pagination: {
187
+ pageSize,
188
+ current: page,
189
+ },
190
+ sorters,
191
+ filters,
192
+ });
216
193
 
217
- return createElement(PaginationLink, {
218
- to: link,
219
- element:
220
- Children.count(elementChildren) > 1
221
- ? createElement(
222
- Fragment,
223
- {},
224
- elementChildren,
225
- )
226
- : elementChildren,
227
- });
228
- }
194
+ if (type === "page") {
195
+ return createElement(PaginationLink, {
196
+ to: link,
197
+ element: `${page}`,
198
+ });
199
+ }
200
+ if (type === "next" || type === "prev") {
201
+ return createElement(PaginationLink, {
202
+ to: link,
203
+ element: element,
204
+ });
205
+ }
229
206
 
230
- return element;
231
- },
232
- pageSize,
233
- current,
234
- simple: !breakpoint.sm,
235
- position: !breakpoint.sm ? ["bottomCenter"] : ["bottomRight"],
236
- total: data?.total,
237
- };
238
- }
207
+ if (type === "jump-next" || type === "jump-prev") {
208
+ const elementChildren = (element as React.ReactElement)?.props
209
+ ?.children;
239
210
 
240
- return false;
241
- };
211
+ return createElement(PaginationLink, {
212
+ to: link,
213
+ element:
214
+ Children.count(elementChildren) > 1
215
+ ? createElement(Fragment, {}, elementChildren)
216
+ : elementChildren,
217
+ });
218
+ }
242
219
 
243
- return {
244
- searchFormProps: {
245
- ...formSF.formProps,
246
- onFinish,
247
- },
248
- tableProps: {
249
- dataSource: data?.data,
250
- loading: liveMode === "auto" ? isLoading : !isFetched,
251
- onChange,
252
- pagination: antdPagination(),
253
- scroll: { x: true },
220
+ return element;
254
221
  },
255
- tableQueryResult,
256
- sorters,
257
- sorter,
258
- filters,
259
- setSorters,
260
- setSorter,
261
- setFilters,
262
- current,
263
- setCurrent,
264
222
  pageSize,
265
- setPageSize,
266
- pageCount,
267
- createLinkForSyncWithLocation,
268
- overtime,
269
- };
223
+ current,
224
+ simple: !breakpoint.sm,
225
+ position: !breakpoint.sm ? ["bottomCenter"] : ["bottomRight"],
226
+ total: data?.total,
227
+ };
228
+ }
229
+
230
+ return false;
231
+ };
232
+
233
+ return {
234
+ searchFormProps: {
235
+ ...formSF.formProps,
236
+ onFinish,
237
+ },
238
+ tableProps: {
239
+ dataSource: data?.data,
240
+ loading: liveMode === "auto" ? isLoading : !isFetched,
241
+ onChange,
242
+ pagination: antdPagination(),
243
+ scroll: { x: true },
244
+ },
245
+ tableQueryResult,
246
+ sorters,
247
+ sorter,
248
+ filters,
249
+ setSorters,
250
+ setSorter,
251
+ setFilters,
252
+ current,
253
+ setCurrent,
254
+ pageSize,
255
+ setPageSize,
256
+ pageCount,
257
+ createLinkForSyncWithLocation,
258
+ overtime,
259
+ };
270
260
  };
@@ -2,33 +2,33 @@ import { useCallback, useMemo, useState } from "react";
2
2
  import { UploadChangeParam } from "antd/lib/upload";
3
3
 
4
4
  export type UseFileUploadStateType = () => {
5
- isLoading: boolean;
6
- onChange: (info: UploadChangeParam) => void;
5
+ isLoading: boolean;
6
+ onChange: (info: UploadChangeParam) => void;
7
7
  };
8
8
 
9
9
  export const useFileUploadState: UseFileUploadStateType = () => {
10
- const [isLoading, setIsloading] = useState(false);
10
+ const [isLoading, setIsloading] = useState(false);
11
11
 
12
- const onChange = useCallback((info: UploadChangeParam) => {
13
- const fileListLoadings = mapStatusToLoading(info.fileList);
12
+ const onChange = useCallback((info: UploadChangeParam) => {
13
+ const fileListLoadings = mapStatusToLoading(info.fileList);
14
14
 
15
- if (fileListLoadings.includes(true)) {
16
- setIsloading(true);
17
- } else {
18
- setIsloading(false);
19
- }
20
- }, []);
15
+ if (fileListLoadings.includes(true)) {
16
+ setIsloading(true);
17
+ } else {
18
+ setIsloading(false);
19
+ }
20
+ }, []);
21
21
 
22
- return useMemo(() => ({ isLoading, onChange }), [isLoading]);
22
+ return useMemo(() => ({ isLoading, onChange }), [isLoading]);
23
23
  };
24
24
 
25
25
  const mapStatusToLoading = (files: UploadChangeParam["fileList"]) => {
26
- return files.map((file) => {
27
- switch (file.status) {
28
- case "uploading":
29
- return true;
30
- default:
31
- return false;
32
- }
33
- });
26
+ return files.map((file) => {
27
+ switch (file.status) {
28
+ case "uploading":
29
+ return true;
30
+ default:
31
+ return false;
32
+ }
33
+ });
34
34
  };
@@ -3,27 +3,27 @@ import { useContext } from "react";
3
3
  import { ThemedLayoutContext } from "@contexts";
4
4
 
5
5
  export type UseSiderVisibleType = {
6
- siderVisible: boolean;
7
- drawerSiderVisible: boolean;
8
- setSiderVisible: (visible: boolean) => void;
9
- setDrawerSiderVisible: (visible: boolean) => void;
6
+ siderVisible: boolean;
7
+ drawerSiderVisible: boolean;
8
+ setSiderVisible: (visible: boolean) => void;
9
+ setDrawerSiderVisible: (visible: boolean) => void;
10
10
  };
11
11
 
12
12
  /**
13
13
  * @deprecated Please use `useThemedLayoutContext` instead.
14
14
  */
15
15
  export const useSiderVisible = (): UseSiderVisibleType => {
16
- const {
17
- mobileSiderOpen,
18
- siderCollapsed,
19
- setMobileSiderOpen,
20
- setSiderCollapsed,
21
- } = useContext(ThemedLayoutContext);
16
+ const {
17
+ mobileSiderOpen,
18
+ siderCollapsed,
19
+ setMobileSiderOpen,
20
+ setSiderCollapsed,
21
+ } = useContext(ThemedLayoutContext);
22
22
 
23
- return {
24
- siderVisible: mobileSiderOpen,
25
- setSiderVisible: setMobileSiderOpen,
26
- drawerSiderVisible: siderCollapsed,
27
- setDrawerSiderVisible: setSiderCollapsed,
28
- };
23
+ return {
24
+ siderVisible: mobileSiderOpen,
25
+ setSiderVisible: setMobileSiderOpen,
26
+ drawerSiderVisible: siderCollapsed,
27
+ setDrawerSiderVisible: setSiderCollapsed,
28
+ };
29
29
  };
@@ -6,17 +6,17 @@ import { IThemedLayoutContext } from "@contexts/themedLayoutContext/IThemedLayou
6
6
  export type UseThemedLayoutContextType = IThemedLayoutContext;
7
7
 
8
8
  export const useThemedLayoutContext = (): UseThemedLayoutContextType => {
9
- const {
10
- mobileSiderOpen,
11
- siderCollapsed,
12
- setMobileSiderOpen,
13
- setSiderCollapsed,
14
- } = useContext(ThemedLayoutContext);
9
+ const {
10
+ mobileSiderOpen,
11
+ siderCollapsed,
12
+ setMobileSiderOpen,
13
+ setSiderCollapsed,
14
+ } = useContext(ThemedLayoutContext);
15
15
 
16
- return {
17
- mobileSiderOpen,
18
- siderCollapsed,
19
- setMobileSiderOpen,
20
- setSiderCollapsed,
21
- };
16
+ return {
17
+ mobileSiderOpen,
18
+ siderCollapsed,
19
+ setMobileSiderOpen,
20
+ setSiderCollapsed,
21
+ };
22
22
  };
package/src/index.tsx CHANGED
@@ -4,10 +4,10 @@ export * from "./components";
4
4
  export * from "./contexts";
5
5
 
6
6
  export {
7
- getDefaultSortOrder,
8
- getDefaultFilter,
9
- mapAntdSorterToCrudSorting,
10
- mapAntdFilterToCrudFilter,
7
+ getDefaultSortOrder,
8
+ getDefaultFilter,
9
+ mapAntdSorterToCrudSorting,
10
+ mapAntdFilterToCrudFilter,
11
11
  } from "./definitions/table";
12
12
  export { getValueFromEvent } from "./definitions/upload";
13
13
 
@@ -1,3 +1,3 @@
1
1
  export type FieldProps<T> = {
2
- value: T;
2
+ value: T;
3
3
  };
@@ -1,22 +1,21 @@
1
1
  import { IResourceItem } from "@refinedev/core";
2
2
 
3
3
  export type BaseRecord = {
4
- id?: string;
5
- // eslint-disable-next-line @typescript-eslint/no-explicit-any
6
- [key: string]: any;
4
+ id?: string;
5
+ [key: string]: any;
7
6
  };
8
7
  export interface Option {
9
- label: string;
10
- value: string;
8
+ label: string;
9
+ value: string;
11
10
  }
12
11
 
13
12
  export type ITreeMenu = IMenuItem & {
14
- children: ITreeMenu[];
13
+ children: ITreeMenu[];
15
14
  };
16
15
 
17
16
  export type IMenuItem = IResourceItem & {
18
- key: string;
19
- route: string;
17
+ key: string;
18
+ route: string;
20
19
  };
21
20
 
22
21
  export * from "./field";