@vef-framework/starter 2.0.4 → 2.0.5

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 (337) hide show
  1. package/dist/cjs/components/access-denied/access-denied-icon.cjs +1 -210
  2. package/dist/cjs/components/access-denied/index.cjs +1 -47
  3. package/dist/cjs/components/app/index.cjs +1 -47
  4. package/dist/cjs/components/app/props.cjs +1 -3
  5. package/dist/cjs/components/base-layout/index.cjs +1 -45
  6. package/dist/cjs/components/base-layout/props.cjs +1 -3
  7. package/dist/cjs/components/base-layout/styles.cjs +1 -57
  8. package/dist/cjs/components/base-layout/use-base-layout.cjs +1 -41
  9. package/dist/cjs/components/crud/components/action-button-group.cjs +1 -20
  10. package/dist/cjs/components/crud/components/index.cjs +1 -20
  11. package/dist/cjs/components/crud/components/main.cjs +1 -57
  12. package/dist/cjs/components/crud/components/mutation-holder.cjs +1 -40
  13. package/dist/cjs/components/crud/components/operation-button-group.cjs +1 -22
  14. package/dist/cjs/components/crud/components/scene-form.cjs +1 -84
  15. package/dist/cjs/components/crud/components/selection-indicator.cjs +1 -83
  16. package/dist/cjs/components/crud/components/toolbar-actions.cjs +1 -19
  17. package/dist/cjs/components/crud/components/toolbar.cjs +1 -38
  18. package/dist/cjs/components/crud/event.cjs +1 -12
  19. package/dist/cjs/components/crud/helpers.cjs +1 -26
  20. package/dist/cjs/components/crud/hooks/index.cjs +1 -14
  21. package/dist/cjs/components/crud/hooks/use-query-observer.cjs +1 -37
  22. package/dist/cjs/components/crud/hooks/use-search-values.cjs +1 -12
  23. package/dist/cjs/components/crud/hooks/use-selected-rows.cjs +1 -12
  24. package/dist/cjs/components/crud/index.cjs +1 -46
  25. package/dist/cjs/components/crud/props.cjs +1 -3
  26. package/dist/cjs/components/crud/store.cjs +1 -93
  27. package/dist/cjs/components/crud/styles.cjs +1 -34
  28. package/dist/cjs/components/crud-page/index.cjs +1 -19
  29. package/dist/cjs/components/crud-page/props.cjs +1 -3
  30. package/dist/cjs/components/error/error-icon.cjs +1 -179
  31. package/dist/cjs/components/error/index.cjs +1 -69
  32. package/dist/cjs/components/flex-card/index.cjs +1 -18
  33. package/dist/cjs/components/flex-card/props.cjs +1 -3
  34. package/dist/cjs/components/flex-card/styles.cjs +1 -26
  35. package/dist/cjs/components/form-drawer/components/form-actions.cjs +1 -38
  36. package/dist/cjs/components/form-drawer/components/index.cjs +1 -10
  37. package/dist/cjs/components/form-drawer/index.cjs +1 -112
  38. package/dist/cjs/components/form-modal/components/form-actions.cjs +1 -38
  39. package/dist/cjs/components/form-modal/components/index.cjs +1 -10
  40. package/dist/cjs/components/form-modal/index.cjs +1 -88
  41. package/dist/cjs/components/index.cjs +1 -45
  42. package/dist/cjs/components/layout/components/footer.cjs +1 -27
  43. package/dist/cjs/components/layout/components/header/boy-icon.cjs +1 -20
  44. package/dist/cjs/components/layout/components/header/breadcrumb-navigation.cjs +1 -90
  45. package/dist/cjs/components/layout/components/header/color-scheme.cjs +1 -40
  46. package/dist/cjs/components/layout/components/header/fullscreen.cjs +1 -23
  47. package/dist/cjs/components/layout/components/header/girl-icon.cjs +1 -21
  48. package/dist/cjs/components/layout/components/header/index.cjs +1 -88
  49. package/dist/cjs/components/layout/components/header/menu-burger.cjs +1 -24
  50. package/dist/cjs/components/layout/components/header/menu-fold-left-icon.cjs +1 -20
  51. package/dist/cjs/components/layout/components/header/menu-unfold-left-icon.cjs +1 -20
  52. package/dist/cjs/components/layout/components/header/search.cjs +1 -22
  53. package/dist/cjs/components/layout/components/header/theme-config.cjs +1 -23
  54. package/dist/cjs/components/layout/components/header/user-avatar.cjs +1 -86
  55. package/dist/cjs/components/layout/components/honeycomb-pattern.cjs +1 -39
  56. package/dist/cjs/components/layout/components/index.cjs +1 -20
  57. package/dist/cjs/components/layout/components/logo.cjs +1 -60
  58. package/dist/cjs/components/layout/components/menu.cjs +1 -95
  59. package/dist/cjs/components/layout/components/search/index.cjs +1 -79
  60. package/dist/cjs/components/layout/components/search/keyboard-arrow-down-icon.cjs +1 -15
  61. package/dist/cjs/components/layout/components/search/keyboard-arrow-up-icon.cjs +1 -15
  62. package/dist/cjs/components/layout/components/search/keyboard-control-icon.cjs +1 -15
  63. package/dist/cjs/components/layout/components/search/keyboard-esc-icon.cjs +1 -15
  64. package/dist/cjs/components/layout/components/search/keyboard-help.cjs +1 -46
  65. package/dist/cjs/components/layout/components/search/keyboard-return-icon.cjs +1 -15
  66. package/dist/cjs/components/layout/components/search/keyboard-shift-icon.cjs +1 -15
  67. package/dist/cjs/components/layout/components/search/keyboard.cjs +1 -32
  68. package/dist/cjs/components/layout/components/search/letter-s-icon.cjs +1 -15
  69. package/dist/cjs/components/layout/components/search/search-result-item.cjs +1 -69
  70. package/dist/cjs/components/layout/components/search/search-result.cjs +1 -135
  71. package/dist/cjs/components/layout/components/sidebar.cjs +1 -54
  72. package/dist/cjs/components/layout/components/tabs/context-menu.cjs +1 -96
  73. package/dist/cjs/components/layout/components/tabs/index.cjs +1 -40
  74. package/dist/cjs/components/layout/components/tabs/main-content-maximum.cjs +1 -23
  75. package/dist/cjs/components/layout/components/tabs/reload.cjs +1 -21
  76. package/dist/cjs/components/layout/components/tabs/tab-item.cjs +1 -84
  77. package/dist/cjs/components/layout/components/tabs/tab-list.cjs +1 -91
  78. package/dist/cjs/components/layout/components/tabs/tabs-container.cjs +1 -85
  79. package/dist/cjs/components/layout/components/theme-config/color-scheme-switcher.cjs +1 -49
  80. package/dist/cjs/components/layout/components/theme-config/color-scheme.cjs +1 -57
  81. package/dist/cjs/components/layout/components/theme-config/config-item.cjs +1 -27
  82. package/dist/cjs/components/layout/components/theme-config/index.cjs +1 -59
  83. package/dist/cjs/components/layout/components/theme-config/menu-layout-card.cjs +1 -75
  84. package/dist/cjs/components/layout/components/theme-config/menu-layout.cjs +1 -33
  85. package/dist/cjs/components/layout/components/theme-config/operations.cjs +1 -22
  86. package/dist/cjs/components/layout/components/theme-config/theme-color-picker.cjs +1 -33
  87. package/dist/cjs/components/layout/components/theme-config/theme-colors.cjs +1 -29
  88. package/dist/cjs/components/layout/hooks/index.cjs +1 -14
  89. package/dist/cjs/components/layout/hooks/use-color-scheme-updater.cjs +1 -72
  90. package/dist/cjs/components/layout/hooks/use-menu-navigate.cjs +1 -29
  91. package/dist/cjs/components/layout/hooks/use-tab-navigate.cjs +1 -39
  92. package/dist/cjs/components/layout/index.cjs +1 -81
  93. package/dist/cjs/components/layout/props.cjs +1 -3
  94. package/dist/cjs/components/layout/store.cjs +1 -23
  95. package/dist/cjs/components/layout/styles.cjs +1 -16
  96. package/dist/cjs/components/login/icon-login.cjs +1 -149
  97. package/dist/cjs/components/login/index.cjs +1 -162
  98. package/dist/cjs/components/login/payload.cjs +1 -3
  99. package/dist/cjs/components/login/props.cjs +1 -3
  100. package/dist/cjs/components/login/styles.cjs +1 -97
  101. package/dist/cjs/components/login/welcome-messages.cjs +1 -135
  102. package/dist/cjs/components/logo-icon/index.cjs +1 -22
  103. package/dist/cjs/components/logo-icon/props.cjs +1 -3
  104. package/dist/cjs/components/n-progress/components/bar.cjs +9 -51
  105. package/dist/cjs/components/n-progress/components/container.cjs +1 -25
  106. package/dist/cjs/components/n-progress/components/index.cjs +1 -12
  107. package/dist/cjs/components/n-progress/event.cjs +1 -10
  108. package/dist/cjs/components/n-progress/index.cjs +1 -34
  109. package/dist/cjs/components/not-found/index.cjs +1 -47
  110. package/dist/cjs/components/not-found/not-found-icon.cjs +1 -205
  111. package/dist/cjs/components/page/index.cjs +1 -58
  112. package/dist/cjs/components/page/props.cjs +1 -3
  113. package/dist/cjs/components/page/scroll-content.cjs +1 -65
  114. package/dist/cjs/components/page/styles.cjs +1 -86
  115. package/dist/cjs/components/page/use-page-key.cjs +1 -22
  116. package/dist/cjs/components/page/viewport-context.cjs +1 -19
  117. package/dist/cjs/components/pro-search/components/advanced-search-toggler.cjs +1 -23
  118. package/dist/cjs/components/pro-search/components/advanced-search.cjs +1 -30
  119. package/dist/cjs/components/pro-search/components/index.cjs +1 -14
  120. package/dist/cjs/components/pro-search/components/search-actions.cjs +1 -36
  121. package/dist/cjs/components/pro-search/index.cjs +1 -70
  122. package/dist/cjs/components/pro-search/styles.cjs +1 -65
  123. package/dist/cjs/components/pro-table/components/index.cjs +1 -17
  124. package/dist/cjs/components/pro-table/components/operation-button-group.cjs +1 -22
  125. package/dist/cjs/components/pro-table/components/ref.cjs +1 -24
  126. package/dist/cjs/components/pro-table/components/table-subscriber.cjs +1 -25
  127. package/dist/cjs/components/pro-table/components/table-summary.cjs +1 -15
  128. package/dist/cjs/components/pro-table/components/table-title.cjs +1 -15
  129. package/dist/cjs/components/pro-table/components/table.cjs +1 -132
  130. package/dist/cjs/components/pro-table/context.cjs +1 -15
  131. package/dist/cjs/components/pro-table/event.cjs +1 -12
  132. package/dist/cjs/components/pro-table/hooks/index.cjs +1 -12
  133. package/dist/cjs/components/pro-table/hooks/use-row-selection.cjs +1 -43
  134. package/dist/cjs/components/pro-table/hooks/use-table-columns.cjs +1 -60
  135. package/dist/cjs/components/pro-table/index.cjs +1 -53
  136. package/dist/cjs/components/pro-table/store.cjs +1 -40
  137. package/dist/cjs/components/router-provider/context.cjs +1 -15
  138. package/dist/cjs/components/router-provider/index.cjs +1 -29
  139. package/dist/cjs/components/router-provider/props.cjs +1 -3
  140. package/dist/cjs/components/theme-config-provider/global-style.cjs +65 -16
  141. package/dist/cjs/components/theme-config-provider/index.cjs +1 -19
  142. package/dist/cjs/components/theme-config-provider/use-color-mode-effect.cjs +1 -35
  143. package/dist/cjs/components/theme-config-provider/use-theme-config.cjs +1 -73
  144. package/dist/cjs/constants/event.cjs +1 -8
  145. package/dist/cjs/constants/index.cjs +1 -23
  146. package/dist/cjs/constants/router.cjs +1 -18
  147. package/dist/cjs/constants/storage.cjs +1 -10
  148. package/dist/cjs/constants/symbols.cjs +1 -10
  149. package/dist/cjs/helpers/api.cjs +1 -50
  150. package/dist/cjs/helpers/app-version.cjs +1 -227
  151. package/dist/cjs/helpers/app.cjs +1 -37
  152. package/dist/cjs/helpers/auth.cjs +1 -24
  153. package/dist/cjs/helpers/event.cjs +1 -24
  154. package/dist/cjs/helpers/index.cjs +1 -25
  155. package/dist/cjs/helpers/query.cjs +1 -27
  156. package/dist/cjs/helpers/router.cjs +1 -110
  157. package/dist/cjs/hooks/index.cjs +1 -10
  158. package/dist/cjs/hooks/use-route-full-path.cjs +1 -32
  159. package/dist/cjs/index.cjs +1 -83
  160. package/dist/cjs/routes/access-denied.cjs +1 -31
  161. package/dist/cjs/routes/index.cjs +1 -16
  162. package/dist/cjs/routes/layout.cjs +1 -140
  163. package/dist/cjs/routes/login.cjs +1 -41
  164. package/dist/cjs/routes/root.cjs +1 -35
  165. package/dist/cjs/stores/app.cjs +1 -25
  166. package/dist/cjs/stores/index.cjs +1 -14
  167. package/dist/cjs/stores/tab.cjs +1 -101
  168. package/dist/cjs/stores/theme.cjs +1 -32
  169. package/dist/es/components/access-denied/access-denied-icon.js +201 -202
  170. package/dist/es/components/access-denied/index.js +23 -25
  171. package/dist/es/components/app/index.js +31 -38
  172. package/dist/es/components/app/props.js +1 -1
  173. package/dist/es/components/base-layout/index.js +31 -38
  174. package/dist/es/components/base-layout/props.js +1 -1
  175. package/dist/es/components/base-layout/styles.js +22 -24
  176. package/dist/es/components/base-layout/use-base-layout.js +28 -33
  177. package/dist/es/components/crud/components/action-button-group.js +13 -14
  178. package/dist/es/components/crud/components/index.js +14 -7
  179. package/dist/es/components/crud/components/main.js +40 -46
  180. package/dist/es/components/crud/components/mutation-holder.js +28 -32
  181. package/dist/es/components/crud/components/operation-button-group.js +15 -16
  182. package/dist/es/components/crud/components/scene-form.js +62 -71
  183. package/dist/es/components/crud/components/selection-indicator.js +38 -53
  184. package/dist/es/components/crud/components/toolbar-actions.js +11 -12
  185. package/dist/es/components/crud/components/toolbar.js +26 -27
  186. package/dist/es/components/crud/event.js +6 -7
  187. package/dist/es/components/crud/helpers.js +16 -17
  188. package/dist/es/components/crud/hooks/index.js +8 -4
  189. package/dist/es/components/crud/hooks/use-query-observer.js +20 -25
  190. package/dist/es/components/crud/hooks/use-search-values.js +6 -7
  191. package/dist/es/components/crud/hooks/use-selected-rows.js +6 -7
  192. package/dist/es/components/crud/index.js +36 -36
  193. package/dist/es/components/crud/props.js +1 -1
  194. package/dist/es/components/crud/store.js +68 -77
  195. package/dist/es/components/crud/styles.js +18 -19
  196. package/dist/es/components/crud-page/index.js +12 -13
  197. package/dist/es/components/crud-page/props.js +1 -1
  198. package/dist/es/components/error/error-icon.js +170 -171
  199. package/dist/es/components/error/index.js +31 -37
  200. package/dist/es/components/flex-card/index.js +11 -12
  201. package/dist/es/components/flex-card/props.js +1 -1
  202. package/dist/es/components/flex-card/styles.js +8 -9
  203. package/dist/es/components/form-drawer/components/form-actions.js +23 -27
  204. package/dist/es/components/form-drawer/components/index.js +4 -2
  205. package/dist/es/components/form-drawer/index.js +64 -92
  206. package/dist/es/components/form-modal/components/form-actions.js +23 -27
  207. package/dist/es/components/form-modal/components/index.js +4 -2
  208. package/dist/es/components/form-modal/index.js +53 -76
  209. package/dist/es/components/index.js +39 -20
  210. package/dist/es/components/layout/components/footer.js +10 -11
  211. package/dist/es/components/layout/components/header/boy-icon.js +13 -14
  212. package/dist/es/components/layout/components/header/breadcrumb-navigation.js +56 -79
  213. package/dist/es/components/layout/components/header/color-scheme.js +26 -29
  214. package/dist/es/components/layout/components/header/fullscreen.js +14 -16
  215. package/dist/es/components/layout/components/header/girl-icon.js +14 -15
  216. package/dist/es/components/layout/components/header/index.js +45 -51
  217. package/dist/es/components/layout/components/header/menu-burger.js +16 -17
  218. package/dist/es/components/layout/components/header/menu-fold-left-icon.js +12 -13
  219. package/dist/es/components/layout/components/header/menu-unfold-left-icon.js +12 -13
  220. package/dist/es/components/layout/components/header/search.js +14 -16
  221. package/dist/es/components/layout/components/header/theme-config.js +15 -16
  222. package/dist/es/components/layout/components/header/user-avatar.js +50 -61
  223. package/dist/es/components/layout/components/honeycomb-pattern.js +17 -19
  224. package/dist/es/components/layout/components/index.js +14 -7
  225. package/dist/es/components/layout/components/logo.js +30 -33
  226. package/dist/es/components/layout/components/menu.js +48 -77
  227. package/dist/es/components/layout/components/search/index.js +39 -49
  228. package/dist/es/components/layout/components/search/keyboard-arrow-down-icon.js +8 -9
  229. package/dist/es/components/layout/components/search/keyboard-arrow-up-icon.js +8 -9
  230. package/dist/es/components/layout/components/search/keyboard-control-icon.js +8 -9
  231. package/dist/es/components/layout/components/search/keyboard-esc-icon.js +8 -9
  232. package/dist/es/components/layout/components/search/keyboard-help.js +30 -32
  233. package/dist/es/components/layout/components/search/keyboard-return-icon.js +8 -9
  234. package/dist/es/components/layout/components/search/keyboard-shift-icon.js +8 -9
  235. package/dist/es/components/layout/components/search/keyboard.js +16 -22
  236. package/dist/es/components/layout/components/search/letter-s-icon.js +8 -9
  237. package/dist/es/components/layout/components/search/search-result-item.js +38 -44
  238. package/dist/es/components/layout/components/search/search-result.js +73 -93
  239. package/dist/es/components/layout/components/sidebar.js +26 -29
  240. package/dist/es/components/layout/components/tabs/context-menu.js +66 -71
  241. package/dist/es/components/layout/components/tabs/index.js +21 -23
  242. package/dist/es/components/layout/components/tabs/main-content-maximum.js +15 -16
  243. package/dist/es/components/layout/components/tabs/reload.js +14 -15
  244. package/dist/es/components/layout/components/tabs/tab-item.js +47 -51
  245. package/dist/es/components/layout/components/tabs/tab-list.js +45 -57
  246. package/dist/es/components/layout/components/tabs/tabs-container.js +39 -49
  247. package/dist/es/components/layout/components/theme-config/color-scheme-switcher.js +28 -32
  248. package/dist/es/components/layout/components/theme-config/color-scheme.js +36 -37
  249. package/dist/es/components/layout/components/theme-config/config-item.js +15 -16
  250. package/dist/es/components/layout/components/theme-config/index.js +37 -41
  251. package/dist/es/components/layout/components/theme-config/menu-layout-card.js +31 -33
  252. package/dist/es/components/layout/components/theme-config/menu-layout.js +20 -21
  253. package/dist/es/components/layout/components/theme-config/operations.js +14 -16
  254. package/dist/es/components/layout/components/theme-config/theme-color-picker.js +22 -24
  255. package/dist/es/components/layout/components/theme-config/theme-colors.js +14 -16
  256. package/dist/es/components/layout/hooks/index.js +8 -4
  257. package/dist/es/components/layout/hooks/use-color-scheme-updater.js +39 -47
  258. package/dist/es/components/layout/hooks/use-menu-navigate.js +20 -21
  259. package/dist/es/components/layout/hooks/use-tab-navigate.js +24 -32
  260. package/dist/es/components/layout/index.js +52 -66
  261. package/dist/es/components/layout/props.js +1 -1
  262. package/dist/es/components/layout/store.js +15 -17
  263. package/dist/es/components/layout/styles.js +7 -8
  264. package/dist/es/components/login/icon-login.js +138 -139
  265. package/dist/es/components/login/index.js +87 -100
  266. package/dist/es/components/login/payload.js +1 -1
  267. package/dist/es/components/login/props.js +1 -1
  268. package/dist/es/components/login/styles.js +34 -35
  269. package/dist/es/components/login/welcome-messages.js +8 -7
  270. package/dist/es/components/logo-icon/index.js +14 -15
  271. package/dist/es/components/logo-icon/props.js +1 -1
  272. package/dist/es/components/n-progress/components/bar.js +22 -24
  273. package/dist/es/components/n-progress/components/container.js +15 -16
  274. package/dist/es/components/n-progress/components/index.js +6 -3
  275. package/dist/es/components/n-progress/event.js +5 -6
  276. package/dist/es/components/n-progress/index.js +24 -27
  277. package/dist/es/components/not-found/index.js +23 -25
  278. package/dist/es/components/not-found/not-found-icon.js +196 -197
  279. package/dist/es/components/page/index.js +37 -39
  280. package/dist/es/components/page/props.js +1 -1
  281. package/dist/es/components/page/scroll-content.js +31 -34
  282. package/dist/es/components/page/styles.js +37 -38
  283. package/dist/es/components/page/use-page-key.js +13 -16
  284. package/dist/es/components/page/viewport-context.js +11 -12
  285. package/dist/es/components/pro-search/components/advanced-search-toggler.js +16 -17
  286. package/dist/es/components/pro-search/components/advanced-search.js +12 -15
  287. package/dist/es/components/pro-search/components/index.js +8 -4
  288. package/dist/es/components/pro-search/components/search-actions.js +21 -24
  289. package/dist/es/components/pro-search/index.js +48 -58
  290. package/dist/es/components/pro-search/styles.js +21 -22
  291. package/dist/es/components/pro-table/components/index.js +11 -5
  292. package/dist/es/components/pro-table/components/operation-button-group.js +15 -16
  293. package/dist/es/components/pro-table/components/ref.js +13 -18
  294. package/dist/es/components/pro-table/components/table-subscriber.js +17 -19
  295. package/dist/es/components/pro-table/components/table-summary.js +10 -11
  296. package/dist/es/components/pro-table/components/table-title.js +10 -11
  297. package/dist/es/components/pro-table/components/table.js +92 -115
  298. package/dist/es/components/pro-table/context.js +8 -9
  299. package/dist/es/components/pro-table/event.js +6 -7
  300. package/dist/es/components/pro-table/hooks/index.js +6 -3
  301. package/dist/es/components/pro-table/hooks/use-row-selection.js +25 -31
  302. package/dist/es/components/pro-table/hooks/use-table-columns.js +30 -44
  303. package/dist/es/components/pro-table/index.js +38 -40
  304. package/dist/es/components/pro-table/store.js +32 -33
  305. package/dist/es/components/router-provider/context.js +9 -9
  306. package/dist/es/components/router-provider/index.js +18 -21
  307. package/dist/es/components/router-provider/props.js +1 -1
  308. package/dist/es/components/theme-config-provider/global-style.js +77 -10
  309. package/dist/es/components/theme-config-provider/index.js +11 -13
  310. package/dist/es/components/theme-config-provider/use-color-mode-effect.js +15 -26
  311. package/dist/es/components/theme-config-provider/use-theme-config.js +35 -64
  312. package/dist/es/constants/event.js +4 -4
  313. package/dist/es/constants/index.js +17 -5
  314. package/dist/es/constants/router.js +9 -9
  315. package/dist/es/constants/storage.js +5 -5
  316. package/dist/es/constants/symbols.js +5 -5
  317. package/dist/es/helpers/api.js +28 -30
  318. package/dist/es/helpers/app-version.js +111 -177
  319. package/dist/es/helpers/app.js +17 -24
  320. package/dist/es/helpers/auth.js +15 -18
  321. package/dist/es/helpers/event.js +16 -16
  322. package/dist/es/helpers/index.js +19 -8
  323. package/dist/es/helpers/query.js +16 -16
  324. package/dist/es/helpers/router.js +65 -79
  325. package/dist/es/hooks/index.js +4 -2
  326. package/dist/es/hooks/use-route-full-path.js +18 -26
  327. package/dist/es/index.js +77 -36
  328. package/dist/es/routes/access-denied.js +14 -21
  329. package/dist/es/routes/index.js +10 -5
  330. package/dist/es/routes/layout.js +88 -106
  331. package/dist/es/routes/login.js +25 -26
  332. package/dist/es/routes/root.js +20 -26
  333. package/dist/es/stores/app.js +11 -14
  334. package/dist/es/stores/index.js +8 -4
  335. package/dist/es/stores/tab.js +72 -90
  336. package/dist/es/stores/theme.js +23 -26
  337. package/package.json +6 -6
@@ -1,37 +1 @@
1
- /*! @vef-framework/starter v2.0.2 made with ❤️ by Venus | 2025-11-25T15:03:22.856Z */
2
- 'use strict';
3
-
4
- Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
5
-
6
- const jsxRuntime = require('@emotion/react/jsx-runtime');
7
- const react = require('react');
8
- const client = require('react-dom/client');
9
- require('../components/index.cjs');
10
- const index = require('../components/app/index.cjs');
11
- const context = require('../components/router-provider/context.cjs');
12
-
13
- function createApp({
14
- strictMode = true,
15
- useRouterContext
16
- } = {}) {
17
- const root = client.createRoot(document.querySelector("#root"), {
18
- identifierPrefix: "vef-"
19
- });
20
- return {
21
- render(props) {
22
- let app = /* @__PURE__ */ jsxRuntime.jsx(index.App, { ...props });
23
- if (useRouterContext) {
24
- app = /* @__PURE__ */ jsxRuntime.jsx(context.RouterContextHookProvider, { value: useRouterContext, children: app });
25
- }
26
- if (strictMode) {
27
- app = /* @__PURE__ */ jsxRuntime.jsx(react.StrictMode, { children: app });
28
- }
29
- root.render(app);
30
- },
31
- unmount() {
32
- root.unmount();
33
- }
34
- };
35
- }
36
-
37
- exports.createApp = createApp;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("@emotion/react/jsx-runtime"),c=require("react"),u=require("react-dom/client");require("../components/index.cjs");const d=require("../components/app/index.cjs"),s=require("../components/router-provider/context.cjs");function l({strictMode:n=!0,useRouterContext:t}={}){const o=u.createRoot(document.querySelector("#root"),{identifierPrefix:"vef-"});return{render(i){let e=r.jsx(d.App,{...i});t&&(e=r.jsx(s.RouterContextHookProvider,{value:t,children:e})),n&&(e=r.jsx(c.StrictMode,{children:e})),o.render(e)},unmount(){o.unmount()}}}exports.createApp=l;
@@ -1,24 +1 @@
1
- /*! @vef-framework/starter v2.0.2 made with ❤️ by Venus | 2025-11-25T15:03:22.856Z */
2
- 'use strict';
3
-
4
- Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
5
-
6
- require('../constants/index.cjs');
7
- require('../stores/index.cjs');
8
- const app = require('../stores/app.cjs');
9
- const router = require('../constants/router.cjs');
10
-
11
- async function handleClientLogout(router$1) {
12
- app.useAppStore.setState({
13
- isAuthenticated: false
14
- }, true);
15
- await router$1.navigate({
16
- to: router.LOGIN_ROUTE_PATH
17
- });
18
- router$1.invalidate({
19
- sync: true,
20
- forcePending: true
21
- });
22
- }
23
-
24
- exports.handleClientLogout = handleClientLogout;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("../constants/index.cjs");require("../stores/index.cjs");const t=require("../stores/app.cjs"),i=require("../constants/router.cjs");async function n(e){t.useAppStore.setState({isAuthenticated:!1},!0),await e.navigate({to:i.LOGIN_ROUTE_PATH}),e.invalidate({sync:!0,forcePending:!0})}exports.handleClientLogout=n;
@@ -1,24 +1 @@
1
- /*! @vef-framework/starter v2.0.2 made with ❤️ by Venus | 2025-11-25T15:03:22.856Z */
2
- 'use strict';
3
-
4
- Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
5
-
6
- const shared = require('@vef-framework/shared');
7
- require('../constants/index.cjs');
8
- const event = require('../constants/event.cjs');
9
-
10
- const eventEmitter = shared.createEventEmitter();
11
- function dispatchCustomEvent(type, options) {
12
- if (typeof document === "undefined") {
13
- return false;
14
- }
15
- const event = new CustomEvent(type, options);
16
- return document.dispatchEvent(event);
17
- }
18
- function reloadPage(key) {
19
- eventEmitter.emit(event.RELOAD_PAGE_EVENT, key);
20
- }
21
-
22
- exports.dispatchCustomEvent = dispatchCustomEvent;
23
- exports.eventEmitter = eventEmitter;
24
- exports.reloadPage = reloadPage;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("@vef-framework/shared");require("../constants/index.cjs");const i=require("../constants/event.cjs"),t=o.createEventEmitter();function u(e,n){if(typeof document>"u")return!1;const r=new CustomEvent(e,n);return document.dispatchEvent(r)}function c(e){t.emit(i.RELOAD_PAGE_EVENT,e)}exports.dispatchCustomEvent=u;exports.eventEmitter=t;exports.reloadPage=c;
@@ -1,25 +1 @@
1
- /*! @vef-framework/starter v2.0.2 made with ❤️ by Venus | 2025-11-25T15:03:22.856Z */
2
- 'use strict';
3
-
4
- Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
5
-
6
- const api = require('./api.cjs');
7
- const app = require('./app.cjs');
8
- const appVersion = require('./app-version.cjs');
9
- const auth = require('./auth.cjs');
10
- const event = require('./event.cjs');
11
- const query = require('./query.cjs');
12
- const router = require('./router.cjs');
13
-
14
-
15
-
16
- exports.createApiClient = api.createApiClient;
17
- exports.createApp = app.createApp;
18
- exports.setupAppVersionNotification = appVersion.setupAppVersionNotification;
19
- exports.handleClientLogout = auth.handleClientLogout;
20
- exports.dispatchCustomEvent = event.dispatchCustomEvent;
21
- exports.eventEmitter = event.eventEmitter;
22
- exports.reloadPage = event.reloadPage;
23
- exports.extractQueryParams = query.extractQueryParams;
24
- exports.noopMutationFn = query.noopMutationFn;
25
- exports.createRouter = router.createRouter;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./api.cjs"),o=require("./app.cjs"),i=require("./app-version.cjs"),n=require("./auth.cjs"),e=require("./event.cjs"),t=require("./query.cjs"),a=require("./router.cjs");exports.createApiClient=r.createApiClient;exports.createApp=o.createApp;exports.setupAppVersionNotification=i.setupAppVersionNotification;exports.handleClientLogout=n.handleClientLogout;exports.dispatchCustomEvent=e.dispatchCustomEvent;exports.eventEmitter=e.eventEmitter;exports.reloadPage=e.reloadPage;exports.extractQueryParams=t.extractQueryParams;exports.noopMutationFn=t.noopMutationFn;exports.createRouter=a.createRouter;
@@ -1,27 +1 @@
1
- /*! @vef-framework/starter v2.0.2 made with ❤️ by Venus | 2025-11-25T15:03:22.856Z */
2
- 'use strict';
3
-
4
- Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
5
-
6
- require('../constants/index.cjs');
7
- const symbols = require('../constants/symbols.cjs');
8
-
9
- function noopMutationFn(..._args) {
10
- return Promise.resolve(void 0);
11
- }
12
- noopMutationFn.key = "__noop_mutation_fn";
13
- function extractQueryParams(queryParams) {
14
- const {
15
- [symbols.SYMBOL_PAGINATION]: pagination,
16
- [symbols.SYMBOL_SORT]: sort,
17
- ...params
18
- } = queryParams;
19
- return {
20
- params,
21
- pagination,
22
- sort
23
- };
24
- }
25
-
26
- exports.extractQueryParams = extractQueryParams;
27
- exports.noopMutationFn = noopMutationFn;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("../constants/index.cjs");const o=require("../constants/symbols.cjs");function r(...t){return Promise.resolve(void 0)}r.key="__noop_mutation_fn";function i(t){const{[o.SYMBOL_PAGINATION]:e,[o.SYMBOL_SORT]:n,...a}=t;return{params:a,pagination:e,sort:n}}exports.extractQueryParams=i;exports.noopMutationFn=r;
@@ -1,110 +1 @@
1
- /*! @vef-framework/starter v2.0.2 made with ❤️ by Venus | 2025-11-25T15:03:22.856Z */
2
- 'use strict';
3
-
4
- Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
5
-
6
- const jsxRuntime = require('@emotion/react/jsx-runtime');
7
- const reactRouter = require('@tanstack/react-router');
8
- const components = require('@vef-framework/components');
9
- const shared = require('@vef-framework/shared');
10
- require('../components/index.cjs');
11
- require('../stores/index.cjs');
12
- const index = require('../components/not-found/index.cjs');
13
- const index$1 = require('../components/error/index.cjs');
14
- const event = require('../components/n-progress/event.cjs');
15
- const app = require('../stores/app.cjs');
16
- const tab = require('../stores/tab.cjs');
17
-
18
- function _EMOTION_STRINGIFIED_CSS_ERROR__() {
19
- return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop).";
20
- }
21
- const defaultGcTime = 10 * 60 * 1e3;
22
- var _ref = process.env.NODE_ENV === "production" ? {
23
- name: "1089mxj",
24
- styles: "white-space:pre-wrap"
25
- } : {
26
- name: "1089mxj",
27
- styles: "white-space:pre-wrap/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi9Vc2Vycy92ZW51cy9WRUYvdmVmLWZyYW1ld29yay1yZWFjdC9wYWNrYWdlcy9zdGFydGVyL3NyYy9oZWxwZXJzL3JvdXRlci50c3giXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBOEVlIiwiZmlsZSI6Ii9Vc2Vycy92ZW51cy9WRUYvdmVmLWZyYW1ld29yay1yZWFjdC9wYWNrYWdlcy9zdGFydGVyL3NyYy9oZWxwZXJzL3JvdXRlci50c3giLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgdHlwZSB7IEFueVJvdXRlV2l0aENvbnRleHQgfSBmcm9tIFwiQHRhbnN0YWNrL3JlYWN0LXJvdXRlclwiO1xuXG5pbXBvcnQgdHlwZSB7IFJvdXRlckNvbnRleHQgfSBmcm9tIFwiLi4vdHlwZXNcIjtcblxuaW1wb3J0IHsgY3JlYXRlQnJvd3Nlckhpc3RvcnksIGNyZWF0ZUhhc2hIaXN0b3J5LCBjcmVhdGVSb3V0ZXIgYXMgY3JlYXRlUm91dGVySW50ZXJuYWwgfSBmcm9tIFwiQHRhbnN0YWNrL3JlYWN0LXJvdXRlclwiO1xuaW1wb3J0IHsgTG9hZGVyLCBzaG93RXJyb3JOb3RpZmljYXRpb24gfSBmcm9tIFwiQHZlZi1mcmFtZXdvcmsvY29tcG9uZW50c1wiO1xuaW1wb3J0IHsgZ2V0U2FuaXRpemVkRXJyb3JTdGFjaywgaGFzaEtleSB9IGZyb20gXCJAdmVmLWZyYW1ld29yay9zaGFyZWRcIjtcblxuaW1wb3J0IHsgRXJyb3I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XJjaCxcbiAgICAgICAge1xuICAgICAgICAgIHByZWxvYWQ6IGZhbHNlLFxuICAgICAgICAgIHRocm93T25FcnJvcjogZmFsc2VcbiAgICAgICAgfVxuICAgICAgKVxuICAgICAgLmF0KC0xKSE7XG5cbiAgICBjb25zdCB7IHVzZXJNZW51TWFwIH0gPSB1c2VBcHBTdG9yZS5nZXRTdGF0ZSgpO1xuICAgIGNvbnN0IHsgYWRkVGFiLCBzZXRBY3RpdmVUYWJJZCB9ID0gdXNlVGFiU3RvcmUuZ2V0U3RhdGUoKTtcblxuICAgIGNvbnN0IGlkID0gYCR7ZnVsbFBhdGh9fCR7aGFzaEtleShzZWFyY2gpfXwke2hhc2hLZXkocGFyYW1zKX1gO1xuICAgIGNvbnN0IHVzZXJNZW51ID0gdXNlck1lbnVNYXA/LmdldChmdWxsUGF0aCk7XG5cbiAgICBpZiAodXNlck1lbnUpIHtcbiAgICAgIGFkZFRhYih7XG4gICAgICAgIGlkLFxuICAgICAgICBmdWxsUGF0aCxcbiAgICAgICAgcGFyYW1zLFxuICAgICAgICBzZWFyY2gsXG4gICAgICAgIGxhYmVsOiBjb250ZXh0LnRpdGxlIHx8IHVzZXJNZW51Lm5hbWVcbiAgICAgIH0pO1xuICAgICAgc2V0QWN0aXZlVGFiSWQoaWQpO1xuICAgIH1cbiAgfSk7XG5cbiAgcmV0dXJuIHJvdXRlcjtcbn1cbiJdfQ== */",
28
- toString: _EMOTION_STRINGIFIED_CSS_ERROR__
29
- };
30
- function createRouter({
31
- history,
32
- routeTree,
33
- context
34
- }) {
35
- const router = reactRouter.createRouter({
36
- routeTree,
37
- context,
38
- trailingSlash: "never",
39
- caseSensitive: true,
40
- history: history === "hash" ? reactRouter.createHashHistory() : reactRouter.createBrowserHistory(),
41
- search: {
42
- strict: true
43
- },
44
- notFoundMode: "root",
45
- defaultPendingComponent: () => /* @__PURE__ */ jsxRuntime.jsx(components.Loader, { description: "玩命加载中, 请稍安勿躁...", descriptionSize: 18, size: 48 }),
46
- defaultErrorComponent: index$1.Error,
47
- defaultNotFoundComponent: index.NotFound,
48
- defaultPendingMs: 500,
49
- defaultPendingMinMs: 300,
50
- defaultStructuralSharing: true,
51
- defaultHashScrollIntoView: {
52
- behavior: "smooth",
53
- block: "start",
54
- inline: "center"
55
- },
56
- defaultPreload: "intent",
57
- defaultPreloadDelay: 50,
58
- defaultPreloadGcTime: defaultGcTime,
59
- defaultGcTime,
60
- defaultViewTransition: false,
61
- async defaultOnCatch(error) {
62
- const stack = await shared.getSanitizedErrorStack(error);
63
- components.showErrorNotification(/* @__PURE__ */ jsxRuntime.jsx("pre", { css: _ref, children: stack }), {
64
- title: error.message || error.name
65
- });
66
- }
67
- });
68
- router.subscribe("onBeforeLoad", ({
69
- pathChanged
70
- }) => {
71
- if (pathChanged) {
72
- event.nProgressEventEmitter.emit("start");
73
- }
74
- });
75
- router.subscribe("onLoad", () => event.nProgressEventEmitter.emit("complete"));
76
- router.subscribe("onLoad", (event) => {
77
- const location = event.toLocation;
78
- const {
79
- fullPath,
80
- params,
81
- search,
82
- context: context2
83
- } = router.matchRoutes(location.pathname, location.search, {
84
- preload: false,
85
- throwOnError: false
86
- }).at(-1);
87
- const {
88
- userMenuMap
89
- } = app.useAppStore.getState();
90
- const {
91
- addTab,
92
- setActiveTabId
93
- } = tab.useTabStore.getState();
94
- const id = `${fullPath}|${shared.hashKey(search)}|${shared.hashKey(params)}`;
95
- const userMenu = userMenuMap?.get(fullPath);
96
- if (userMenu) {
97
- addTab({
98
- id,
99
- fullPath,
100
- params,
101
- search,
102
- label: context2.title || userMenu.name
103
- });
104
- setActiveTabId(id);
105
- }
106
- });
107
- return router;
108
- }
109
-
110
- exports.createRouter = createRouter;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("@emotion/react/jsx-runtime"),t=require("@tanstack/react-router"),A=require("@vef-framework/components"),C=require("@vef-framework/shared");require("../components/index.cjs");require("../stores/index.cjs");const V=require("../components/not-found/index.cjs"),y=require("../components/error/index.cjs"),G=require("../components/n-progress/event.cjs"),W=require("../stores/app.cjs"),R=require("../stores/tab.cjs");function F(){return"You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop)."}const a=600*1e3;var h=process.env.NODE_ENV==="production"?{name:"1089mxj",styles:"white-space:pre-wrap"}:{name:"1089mxj",styles:"white-space:pre-wrap/*# sourceMappingURL=data:application/json;charset=utf-8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi9Vc2Vycy92ZW51cy9WRUYvdmVmLWZyYW1ld29yay1yZWFjdC9wYWNrYWdlcy9zdGFydGVyL3NyYy9oZWxwZXJzL3JvdXRlci50c3giXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBOEVlIiwiZmlsZSI6Ii9Vc2Vycy92ZW51cy9WRUYvdmVmLWZyYW1ld29yay1yZWFjdC9wYWNrYWdlcy9zdGFydGVyL3NyYy9oZWxwZXJzL3JvdXRlci50c3giLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgdHlwZSB7IEFueVJvdXRlV2l0aENvbnRleHQgfSBmcm9tIFwiQHRhbnN0YWNrL3JlYWN0LXJvdXRlclwiO1xuXG5pbXBvcnQgdHlwZSB7IFJvdXRlckNvbnRleHQgfSBmcm9tIFwiLi4vdHlwZXNcIjtcblxuaW1wb3J0IHsgY3JlYXRlQnJvd3Nlckhpc3RvcnksIGNyZWF0ZUhhc2hIaXN0b3J5LCBjcmVhdGVSb3V0ZXIgYXMgY3JlYXRlUm91dGVySW50ZXJuYWwgfSBmcm9tIFwiQHRhbnN0YWNrL3JlYWN0LXJvdXRlclwiO1xuaW1wb3J0IHsgTG9hZGVyLCBzaG93RXJyb3JOb3RpZmljYXRpb24gfSBmcm9tIFwiQHZlZi1mcmFtZXdvcmsvY29tcG9uZW50c1wiO1xuaW1wb3J0IHsgZ2V0U2FuaXRpemVkRXJyb3JTdGFjaywgaGFz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JvdXRlcyhcbiAgICAgICAgbG9jYXRpb24ucGF0aG5hbWUsXG4gICAgICAgIGxvY2F0aW9uLnNlYXJjaCxcbiAgICAgICAge1xuICAgICAgICAgIHByZWxvYWQ6IGZhbHNlLFxuICAgICAgICAgIHRocm93T25FcnJvcjogZmFsc2VcbiAgICAgICAgfVxuICAgICAgKVxuICAgICAgLmF0KC0xKSE7XG5cbiAgICBjb25zdCB7IHVzZXJNZW51TWFwIH0gPSB1c2VBcHBTdG9yZS5nZXRTdGF0ZSgpO1xuICAgIGNvbnN0IHsgYWRkVGFiLCBzZXRBY3RpdmVUYWJJZCB9ID0gdXNlVGFiU3RvcmUuZ2V0U3RhdGUoKTtcblxuICAgIGNvbnN0IGlkID0gYCR7ZnVsbFBhdGh9fCR7aGFzaEtleShzZWFyY2gpfXwke2hhc2hLZXkocGFyYW1zKX1gO1xuICAgIGNvbnN0IHVzZXJNZW51ID0gdXNlck1lbnVNYXA/LmdldChmdWxsUGF0aCk7XG5cbiAgICBpZiAodXNlck1lbnUpIHtcbiAgICAgIGFkZFRhYih7XG4gICAgICAgIGlkLFxuICAgICAgICBmdWxsUGF0aCxcbiAgICAgICAgcGFyYW1zLFxuICAgICAgICBzZWFyY2gsXG4gICAgICAgIGxhYmVsOiBjb250ZXh0LnRpdGxlIHx8IHVzZXJNZW51Lm5hbWVcbiAgICAgIH0pO1xuICAgICAgc2V0QWN0aXZlVGFiSWQoaWQpO1xuICAgIH1cbiAgfSk7XG5cbiAgcmV0dXJuIHJvdXRlcjtcbn1cbiJdfQ== */",toString:F};function x({history:X,routeTree:Z,context:o}){const g=t.createRouter({routeTree:Z,context:o,trailingSlash:"never",caseSensitive:!0,history:X==="hash"?t.createHashHistory():t.createBrowserHistory(),search:{strict:!0},notFoundMode:"root",defaultPendingComponent:()=>u.jsx(A.Loader,{description:"玩命加载中, 请稍安勿躁...",descriptionSize:18,size:48}),defaultErrorComponent:y.Error,defaultNotFoundComponent:V.NotFound,defaultPendingMs:500,defaultPendingMinMs:300,defaultStructuralSharing:!0,defaultHashScrollIntoView:{behavior:"smooth",block:"start",inline:"center"},defaultPreload:"intent",defaultPreloadDelay:50,defaultPreloadGcTime:a,defaultGcTime:a,defaultViewTransition:!1,async defaultOnCatch(I){const c=await C.getSanitizedErrorStack(I);A.showErrorNotification(u.jsx("pre",{css:h,children:c}),{title:I.message||I.name})}});return g.subscribe("onBeforeLoad",({pathChanged:I})=>{I&&G.nProgressEventEmitter.emit("start")}),g.subscribe("onLoad",()=>G.nProgressEventEmitter.emit("complete")),g.subscribe("onLoad",I=>{const c=I.toLocation,{fullPath:e,params:i,search:d,context:n}=g.matchRoutes(c.pathname,c.search,{preload:!1,throwOnError:!1}).at(-1),{userMenuMap:s}=W.useAppStore.getState(),{addTab:m,setActiveTabId:r}=R.useTabStore.getState(),l=`${e}|${C.hashKey(d)}|${C.hashKey(i)}`,b=s?.get(e);b&&(m({id:l,fullPath:e,params:i,search:d,label:n.title||b.name}),r(l))}),g}exports.createRouter=x;
@@ -1,10 +1 @@
1
- /*! @vef-framework/starter v2.0.2 made with ❤️ by Venus | 2025-11-25T15:03:22.856Z */
2
- 'use strict';
3
-
4
- Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
5
-
6
- const useRouteFullPath = require('./use-route-full-path.cjs');
7
-
8
-
9
-
10
- exports.useRouteFullPath = useRouteFullPath.useRouteFullPath;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./use-route-full-path.cjs");exports.useRouteFullPath=e.useRouteFullPath;
@@ -1,32 +1 @@
1
- /*! @vef-framework/starter v2.0.2 made with ❤️ by Venus | 2025-11-25T15:03:22.856Z */
2
- 'use strict';
3
-
4
- Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
5
-
6
- const reactRouter = require('@tanstack/react-router');
7
- const react = require('react');
8
-
9
- function useRouteFullPath() {
10
- const router = reactRouter.useRouter();
11
- const {
12
- pathname,
13
- search
14
- } = reactRouter.useLocation({
15
- select: (location) => {
16
- return {
17
- pathname: location.pathname,
18
- search: location.search
19
- };
20
- }
21
- });
22
- const fullPath = react.useMemo(() => {
23
- const match = router.matchRoutes(pathname, search, {
24
- preload: false,
25
- throwOnError: false
26
- }).at(-1);
27
- return match.fullPath;
28
- }, [pathname, router, search]);
29
- return fullPath;
30
- }
31
-
32
- exports.useRouteFullPath = useRouteFullPath;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const u=require("@tanstack/react-router"),o=require("react");function s(){const t=u.useRouter(),{pathname:r,search:a}=u.useLocation({select:e=>({pathname:e.pathname,search:e.search})});return o.useMemo(()=>t.matchRoutes(r,a,{preload:!1,throwOnError:!1}).at(-1).fullPath,[r,t,a])}exports.useRouteFullPath=s;
@@ -1,83 +1 @@
1
- /*! @vef-framework/starter v2.0.2 made with ❤️ by Venus | 2025-11-25T15:03:22.856Z */
2
- 'use strict';
3
-
4
- Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
5
-
6
- require('./components/index.cjs');
7
- require('./constants/index.cjs');
8
- require('./helpers/index.cjs');
9
- require('./routes/index.cjs');
10
- require('./stores/index.cjs');
11
- const helpers = require('./components/crud/helpers.cjs');
12
- const index = require('./components/crud/index.cjs');
13
- const index$1 = require('./components/crud-page/index.cjs');
14
- const index$2 = require('./components/flex-card/index.cjs');
15
- const index$3 = require('./components/form-drawer/index.cjs');
16
- const index$4 = require('./components/form-modal/index.cjs');
17
- const operationButtonGroup = require('./components/pro-table/components/operation-button-group.cjs');
18
- const index$5 = require('./components/page/index.cjs');
19
- const index$6 = require('./components/pro-search/index.cjs');
20
- const index$7 = require('./components/pro-table/index.cjs');
21
- const tableSubscriber = require('./components/pro-table/components/table-subscriber.cjs');
22
- const viewportContext = require('./components/page/viewport-context.cjs');
23
- const event = require('./constants/event.cjs');
24
- const router = require('./constants/router.cjs');
25
- const storage = require('./constants/storage.cjs');
26
- const symbols = require('./constants/symbols.cjs');
27
- const api = require('./helpers/api.cjs');
28
- const app = require('./helpers/app.cjs');
29
- const appVersion = require('./helpers/app-version.cjs');
30
- const auth = require('./helpers/auth.cjs');
31
- const event$1 = require('./helpers/event.cjs');
32
- const query = require('./helpers/query.cjs');
33
- const router$1 = require('./helpers/router.cjs');
34
- const accessDenied = require('./routes/access-denied.cjs');
35
- const layout = require('./routes/layout.cjs');
36
- const login = require('./routes/login.cjs');
37
- const root = require('./routes/root.cjs');
38
- const app$1 = require('./stores/app.cjs');
39
- const tab = require('./stores/tab.cjs');
40
- const theme = require('./stores/theme.cjs');
41
-
42
-
43
-
44
- exports.createCrudKit = helpers.createCrudKit;
45
- exports.Crud = index.Crud;
46
- exports.CrudPage = index$1.CrudPage;
47
- exports.FlexCard = index$2.FlexCard;
48
- exports.FormDrawer = index$3.FormDrawer;
49
- exports.FormModal = index$4.FormModal;
50
- exports.OperationButtonGroup = operationButtonGroup.OperationButtonGroup;
51
- exports.Page = index$5.Page;
52
- exports.ProSearch = index$6.ProSearch;
53
- exports.ProTable = index$7.ProTable;
54
- exports.ProTableSubscriber = tableSubscriber.TableSubscriber;
55
- exports.useViewportHeight = viewportContext.useViewportHeight;
56
- exports.RELOAD_PAGE_EVENT = event.RELOAD_PAGE_EVENT;
57
- exports.ACCESS_DENIED_ROUTE_ID = router.ACCESS_DENIED_ROUTE_ID;
58
- exports.ACCESS_DENIED_ROUTE_PATH = router.ACCESS_DENIED_ROUTE_PATH;
59
- exports.INDEX_ROUTE_ID = router.INDEX_ROUTE_ID;
60
- exports.INDEX_ROUTE_PATH = router.INDEX_ROUTE_PATH;
61
- exports.LOGIN_ROUTE_ID = router.LOGIN_ROUTE_ID;
62
- exports.LOGIN_ROUTE_PATH = router.LOGIN_ROUTE_PATH;
63
- exports.STORAGE_KEY_PREFIX_STORE = storage.STORAGE_KEY_PREFIX_STORE;
64
- exports.STORAGE_KEY_SUFFIX_STORE = storage.STORAGE_KEY_SUFFIX_STORE;
65
- exports.SYMBOL_PAGINATION = symbols.SYMBOL_PAGINATION;
66
- exports.SYMBOL_SORT = symbols.SYMBOL_SORT;
67
- exports.createApiClient = api.createApiClient;
68
- exports.createApp = app.createApp;
69
- exports.setupAppVersionNotification = appVersion.setupAppVersionNotification;
70
- exports.handleClientLogout = auth.handleClientLogout;
71
- exports.dispatchCustomEvent = event$1.dispatchCustomEvent;
72
- exports.eventEmitter = event$1.eventEmitter;
73
- exports.reloadPage = event$1.reloadPage;
74
- exports.extractQueryParams = query.extractQueryParams;
75
- exports.noopMutationFn = query.noopMutationFn;
76
- exports.createRouter = router$1.createRouter;
77
- exports.createAccessDeniedRouteOptions = accessDenied.createAccessDeniedRouteOptions;
78
- exports.createLayoutRouteOptions = layout.createLayoutRouteOptions;
79
- exports.createLoginRouteOptions = login.createLoginRouteOptions;
80
- exports.createRootRouteOptions = root.createRootRouteOptions;
81
- exports.useAppStore = app$1.useAppStore;
82
- exports.useTabStore = tab.useTabStore;
83
- exports.useThemeStore = theme.useThemeStore;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("./components/index.cjs");require("./constants/index.cjs");require("./helpers/index.cjs");require("./routes/index.cjs");require("./stores/index.cjs");const u=require("./components/crud/helpers.cjs"),n=require("./components/crud/index.cjs"),s=require("./components/crud-page/index.cjs"),a=require("./components/flex-card/index.cjs"),c=require("./components/form-drawer/index.cjs"),E=require("./components/form-modal/index.cjs"),_=require("./components/pro-table/components/operation-button-group.cjs"),p=require("./components/page/index.cjs"),O=require("./components/pro-search/index.cjs"),T=require("./components/pro-table/index.cjs"),R=require("./components/pro-table/components/table-subscriber.cjs"),S=require("./components/page/viewport-context.cjs"),q=require("./constants/event.cjs"),e=require("./constants/router.cjs"),t=require("./constants/storage.cjs"),o=require("./constants/symbols.cjs"),A=require("./helpers/api.cjs"),d=require("./helpers/app.cjs"),I=require("./helpers/app-version.cjs"),P=require("./helpers/auth.cjs"),r=require("./helpers/event.cjs"),i=require("./helpers/query.cjs"),D=require("./helpers/router.cjs"),l=require("./routes/access-denied.cjs"),C=require("./routes/layout.cjs"),N=require("./routes/login.cjs"),b=require("./routes/root.cjs"),g=require("./stores/app.cjs"),L=require("./stores/tab.cjs"),m=require("./stores/theme.cjs");exports.createCrudKit=u.createCrudKit;exports.Crud=n.Crud;exports.CrudPage=s.CrudPage;exports.FlexCard=a.FlexCard;exports.FormDrawer=c.FormDrawer;exports.FormModal=E.FormModal;exports.OperationButtonGroup=_.OperationButtonGroup;exports.Page=p.Page;exports.ProSearch=O.ProSearch;exports.ProTable=T.ProTable;exports.ProTableSubscriber=R.TableSubscriber;exports.useViewportHeight=S.useViewportHeight;exports.RELOAD_PAGE_EVENT=q.RELOAD_PAGE_EVENT;exports.ACCESS_DENIED_ROUTE_ID=e.ACCESS_DENIED_ROUTE_ID;exports.ACCESS_DENIED_ROUTE_PATH=e.ACCESS_DENIED_ROUTE_PATH;exports.INDEX_ROUTE_ID=e.INDEX_ROUTE_ID;exports.INDEX_ROUTE_PATH=e.INDEX_ROUTE_PATH;exports.LOGIN_ROUTE_ID=e.LOGIN_ROUTE_ID;exports.LOGIN_ROUTE_PATH=e.LOGIN_ROUTE_PATH;exports.STORAGE_KEY_PREFIX_STORE=t.STORAGE_KEY_PREFIX_STORE;exports.STORAGE_KEY_SUFFIX_STORE=t.STORAGE_KEY_SUFFIX_STORE;exports.SYMBOL_PAGINATION=o.SYMBOL_PAGINATION;exports.SYMBOL_SORT=o.SYMBOL_SORT;exports.createApiClient=A.createApiClient;exports.createApp=d.createApp;exports.setupAppVersionNotification=I.setupAppVersionNotification;exports.handleClientLogout=P.handleClientLogout;exports.dispatchCustomEvent=r.dispatchCustomEvent;exports.eventEmitter=r.eventEmitter;exports.reloadPage=r.reloadPage;exports.extractQueryParams=i.extractQueryParams;exports.noopMutationFn=i.noopMutationFn;exports.createRouter=D.createRouter;exports.createAccessDeniedRouteOptions=l.createAccessDeniedRouteOptions;exports.createLayoutRouteOptions=C.createLayoutRouteOptions;exports.createLoginRouteOptions=N.createLoginRouteOptions;exports.createRootRouteOptions=b.createRootRouteOptions;exports.useAppStore=g.useAppStore;exports.useTabStore=L.useTabStore;exports.useThemeStore=m.useThemeStore;
@@ -1,31 +1 @@
1
- /*! @vef-framework/starter v2.0.2 made with ❤️ by Venus | 2025-11-25T15:03:22.856Z */
2
- 'use strict';
3
-
4
- Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
5
-
6
- require('../components/index.cjs');
7
- require('../constants/index.cjs');
8
- const index = require('../components/access-denied/index.cjs');
9
- const router = require('../constants/router.cjs');
10
-
11
- function createAccessDeniedRouteOptions(getRouter) {
12
- return {
13
- component: index.AccessDenied,
14
- beforeLoad({
15
- location
16
- }) {
17
- const router$1 = getRouter();
18
- if (!router$1.state.resolvedLocation) {
19
- if (location.state.__TSR_index === 0) {
20
- router$1.navigate({
21
- to: router.INDEX_ROUTE_PATH
22
- });
23
- } else {
24
- router$1.history.back();
25
- }
26
- }
27
- }
28
- };
29
- }
30
-
31
- exports.createAccessDeniedRouteOptions = createAccessDeniedRouteOptions;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});require("../components/index.cjs");require("../constants/index.cjs");const r=require("../components/access-denied/index.cjs"),i=require("../constants/router.cjs");function n(t){return{component:r.AccessDenied,beforeLoad({location:o}){const e=t();e.state.resolvedLocation||(o.state.__TSR_index===0?e.navigate({to:i.INDEX_ROUTE_PATH}):e.history.back())}}}exports.createAccessDeniedRouteOptions=n;
@@ -1,16 +1 @@
1
- /*! @vef-framework/starter v2.0.2 made with ❤️ by Venus | 2025-11-25T15:03:22.856Z */
2
- 'use strict';
3
-
4
- Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
5
-
6
- const accessDenied = require('./access-denied.cjs');
7
- const layout = require('./layout.cjs');
8
- const login = require('./login.cjs');
9
- const root = require('./root.cjs');
10
-
11
-
12
-
13
- exports.createAccessDeniedRouteOptions = accessDenied.createAccessDeniedRouteOptions;
14
- exports.createLayoutRouteOptions = layout.createLayoutRouteOptions;
15
- exports.createLoginRouteOptions = login.createLoginRouteOptions;
16
- exports.createRootRouteOptions = root.createRootRouteOptions;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./access-denied.cjs"),t=require("./layout.cjs"),o=require("./login.cjs"),i=require("./root.cjs");exports.createAccessDeniedRouteOptions=e.createAccessDeniedRouteOptions;exports.createLayoutRouteOptions=t.createLayoutRouteOptions;exports.createLoginRouteOptions=o.createLoginRouteOptions;exports.createRootRouteOptions=i.createRootRouteOptions;
@@ -1,140 +1 @@
1
- /*! @vef-framework/starter v2.0.2 made with ❤️ by Venus | 2025-11-25T15:03:22.856Z */
2
- 'use strict';
3
-
4
- Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
5
-
6
- const jsxRuntime = require('@emotion/react/jsx-runtime');
7
- const reactRouter = require('@tanstack/react-router');
8
- const components = require('@vef-framework/components');
9
- require('../components/index.cjs');
10
- require('../constants/index.cjs');
11
- require('../stores/index.cjs');
12
- const index = require('../components/layout/index.cjs');
13
- const index$1 = require('../components/not-found/index.cjs');
14
- const index$2 = require('../components/error/index.cjs');
15
- const app = require('../stores/app.cjs');
16
- const router = require('../constants/router.cjs');
17
-
18
- function createLayoutRouteOptions({
19
- fetchUserInfo,
20
- ...layoutProps
21
- }) {
22
- function LayoutComponent() {
23
- return /* @__PURE__ */ jsxRuntime.jsx(index.Layout, { ...layoutProps, children: /* @__PURE__ */ jsxRuntime.jsx(reactRouter.Outlet, {}) });
24
- }
25
- return {
26
- beforeLoad: ({
27
- location
28
- }) => {
29
- const {
30
- isAuthenticated,
31
- userMenuMap
32
- } = app.useAppStore.getState();
33
- if (!isAuthenticated) {
34
- throw reactRouter.redirect({
35
- to: router.LOGIN_ROUTE_PATH,
36
- search: {
37
- redirect: location.href
38
- }
39
- });
40
- }
41
- if (userMenuMap && !userMenuMap.has(location.pathname)) {
42
- throw reactRouter.redirect({
43
- to: router.ACCESS_DENIED_ROUTE_PATH,
44
- replace: true
45
- });
46
- }
47
- },
48
- loader: async ({
49
- location
50
- }) => {
51
- const {
52
- permTokens,
53
- ...userInfo
54
- } = await fetchUserInfo();
55
- const {
56
- menus
57
- } = userInfo;
58
- const userMenuMap = Object.freeze(buildUserMenuMap(menus));
59
- const menuPathMap = Object.freeze(buildMenuPathMap(menus));
60
- const menuItems = Object.freeze(buildMenuItems(menus));
61
- app.useAppStore.setState({
62
- ...app.useAppStore.getState(),
63
- userInfo: Object.freeze(userInfo),
64
- userMenuMap,
65
- menuPathMap,
66
- menuItems,
67
- permTokens: Object.freeze(new Set(permTokens))
68
- });
69
- if (!userMenuMap.has(location.pathname)) {
70
- throw reactRouter.redirect({
71
- to: router.ACCESS_DENIED_ROUTE_PATH,
72
- replace: true
73
- });
74
- }
75
- },
76
- pendingComponent: () => /* @__PURE__ */ jsxRuntime.jsx(components.Loader, { description: "页面玩命加载中, 请稍后...", descriptionSize: 18, size: 48 }),
77
- errorComponent: index$2.Error,
78
- notFoundComponent: index$1.NotFound,
79
- component: LayoutComponent,
80
- staleTime: Infinity,
81
- shouldReload: false
82
- };
83
- }
84
- function buildUserMenuMap(menus, menuMap = /* @__PURE__ */ new Map()) {
85
- for (const menu of menus) {
86
- const {
87
- children,
88
- path
89
- } = menu;
90
- if (children) {
91
- buildUserMenuMap(children, menuMap);
92
- }
93
- menuMap.set(path, menu);
94
- }
95
- return menuMap;
96
- }
97
- function buildMenuPathMap(menus, parentPath = [], menuPathMap = /* @__PURE__ */ new Map()) {
98
- for (const menu of menus) {
99
- const {
100
- path
101
- } = menu;
102
- menuPathMap.set(path, [...parentPath, path]);
103
- if (menu.children) {
104
- buildMenuPathMap(menu.children, [...parentPath, path], menuPathMap);
105
- }
106
- }
107
- return menuPathMap;
108
- }
109
- function buildMenuItems(menus) {
110
- return menus.filter((menu) => menu.type !== "page").map((menu) => Object.freeze(buildMenuItem(menu)));
111
- }
112
- function buildMenuItem(menu) {
113
- const {
114
- path,
115
- type,
116
- name,
117
- icon
118
- } = menu;
119
- if (type === "directory") {
120
- return {
121
- type: "submenu",
122
- key: path,
123
- label: name,
124
- ...icon ? {
125
- icon: /* @__PURE__ */ jsxRuntime.jsx(components.DynamicIcon, { name: icon })
126
- } : {},
127
- children: menu.children ? buildMenuItems(menu.children) : []
128
- };
129
- }
130
- return {
131
- type: "item",
132
- key: path,
133
- label: name,
134
- ...icon ? {
135
- icon: /* @__PURE__ */ jsxRuntime.jsx(components.DynamicIcon, { name: icon })
136
- } : {}
137
- };
138
- }
139
-
140
- exports.createLayoutRouteOptions = createLayoutRouteOptions;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const c=require("@emotion/react/jsx-runtime"),u=require("@tanstack/react-router"),d=require("@vef-framework/components");require("../components/index.cjs");require("../constants/index.cjs");require("../stores/index.cjs");const O=require("../components/layout/index.cjs"),S=require("../components/not-found/index.cjs"),j=require("../components/error/index.cjs"),a=require("../stores/app.cjs"),p=require("../constants/router.cjs");function q({fetchUserInfo:n,...e}){function o(){return c.jsx(O.Layout,{...e,children:c.jsx(u.Outlet,{})})}return{beforeLoad:({location:t})=>{const{isAuthenticated:r,userMenuMap:i}=a.useAppStore.getState();if(!r)throw u.redirect({to:p.LOGIN_ROUTE_PATH,search:{redirect:t.href}});if(i&&!i.has(t.pathname))throw u.redirect({to:p.ACCESS_DENIED_ROUTE_PATH,replace:!0})},loader:async({location:t})=>{const{permTokens:r,...i}=await n(),{menus:s}=i,f=Object.freeze(l(s)),y=Object.freeze(m(s)),b=Object.freeze(h(s));if(a.useAppStore.setState({...a.useAppStore.getState(),userInfo:Object.freeze(i),userMenuMap:f,menuPathMap:y,menuItems:b,permTokens:Object.freeze(new Set(r))}),!f.has(t.pathname))throw u.redirect({to:p.ACCESS_DENIED_ROUTE_PATH,replace:!0})},pendingComponent:()=>c.jsx(d.Loader,{description:"页面玩命加载中, 请稍后...",descriptionSize:18,size:48}),errorComponent:j.Error,notFoundComponent:S.NotFound,component:o,staleTime:1/0,shouldReload:!1}}function l(n,e=new Map){for(const o of n){const{children:t,path:r}=o;t&&l(t,e),e.set(r,o)}return e}function m(n,e=[],o=new Map){for(const t of n){const{path:r}=t;o.set(r,[...e,r]),t.children&&m(t.children,[...e,r],o)}return o}function h(n){return n.filter(e=>e.type!=="page").map(e=>Object.freeze(I(e)))}function I(n){const{path:e,type:o,name:t,icon:r}=n;return o==="directory"?{type:"submenu",key:e,label:t,...r?{icon:c.jsx(d.DynamicIcon,{name:r})}:{},children:n.children?h(n.children):[]}:{type:"item",key:e,label:t,...r?{icon:c.jsx(d.DynamicIcon,{name:r})}:{}}}exports.createLayoutRouteOptions=q;