@duxweb/dvha-core 0.1.20 → 0.1.21

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 (110) hide show
  1. package/dist/cjs/_virtual/_commonjsHelpers.cjs +1 -0
  2. package/dist/cjs/_virtual/dayjs.min.cjs +1 -0
  3. package/dist/cjs/_virtual/dayjs.min2.cjs +1 -0
  4. package/dist/cjs/components/auth/can.cjs +1 -1
  5. package/dist/cjs/components/loader/iframe.cjs +1 -1
  6. package/dist/cjs/components/loader/loader.cjs +1 -0
  7. package/dist/cjs/components/loader/remote/loader.cjs +1 -0
  8. package/dist/cjs/components/loader/remote/render.cjs +1 -0
  9. package/dist/cjs/components/overlay/overlay.cjs +1 -1
  10. package/dist/cjs/components/status/error.cjs +1 -1
  11. package/dist/cjs/components/status/exception.cjs +1 -0
  12. package/dist/cjs/components/status/notAuthorized.cjs +1 -1
  13. package/dist/cjs/components/status/notFound.cjs +1 -1
  14. package/dist/cjs/directive/permission.cjs +1 -1
  15. package/dist/cjs/hooks/auth.cjs +1 -1
  16. package/dist/cjs/hooks/data.cjs +1 -1
  17. package/dist/cjs/hooks/export.cjs +1 -1
  18. package/dist/cjs/hooks/form.cjs +1 -1
  19. package/dist/cjs/hooks/formExtend.cjs +1 -0
  20. package/dist/cjs/hooks/formValidate.cjs +1 -0
  21. package/dist/cjs/hooks/i18n.cjs +1 -1
  22. package/dist/cjs/hooks/importCsv.cjs +1 -1
  23. package/dist/cjs/hooks/json.cjs +1 -1
  24. package/dist/cjs/hooks/list.cjs +1 -0
  25. package/dist/cjs/hooks/manage.cjs +1 -1
  26. package/dist/cjs/hooks/menu.cjs +1 -1
  27. package/dist/cjs/hooks/overlay.cjs +1 -1
  28. package/dist/cjs/hooks/select.cjs +1 -1
  29. package/dist/cjs/hooks/theme.cjs +2 -2
  30. package/dist/cjs/hooks/upload.cjs +1 -1
  31. package/dist/cjs/index.cjs +1 -1
  32. package/dist/cjs/main.cjs +1 -1
  33. package/dist/cjs/node_modules/dayjs/dayjs.min.cjs +1 -0
  34. package/dist/cjs/node_modules/mitt/dist/mitt.cjs +1 -0
  35. package/dist/cjs/preset/dataProvider.cjs +1 -1
  36. package/dist/cjs/preset/i18nProvider.cjs +1 -1
  37. package/dist/cjs/provider/app.cjs +1 -1
  38. package/dist/cjs/stores/manage.cjs +1 -1
  39. package/dist/cjs/stores/tab.cjs +1 -1
  40. package/dist/cjs/stores/theme.cjs +1 -1
  41. package/dist/cjs/utils/theme.cjs +9 -1
  42. package/dist/esm/_virtual/_commonjsHelpers.js +6 -0
  43. package/dist/esm/_virtual/dayjs.min.js +7 -0
  44. package/dist/esm/_virtual/dayjs.min2.js +4 -0
  45. package/dist/esm/components/auth/can.js +9 -7
  46. package/dist/esm/components/loader/loader.js +47 -0
  47. package/dist/esm/components/loader/remote/loader.js +150 -0
  48. package/dist/esm/components/loader/remote/render.js +19 -0
  49. package/dist/esm/components/overlay/overlay.js +22 -31
  50. package/dist/esm/components/status/error.js +3 -3
  51. package/dist/esm/components/status/exception.js +23 -0
  52. package/dist/esm/components/status/notAuthorized.js +2 -2
  53. package/dist/esm/components/status/notFound.js +4 -4
  54. package/dist/esm/directive/permission.js +5 -3
  55. package/dist/esm/hooks/auth.js +67 -67
  56. package/dist/esm/hooks/data.js +164 -160
  57. package/dist/esm/hooks/export.js +26 -23
  58. package/dist/esm/hooks/form.js +38 -35
  59. package/dist/esm/hooks/formExtend.js +38 -0
  60. package/dist/esm/hooks/formValidate.js +28 -0
  61. package/dist/esm/hooks/i18n.js +16 -8
  62. package/dist/esm/hooks/json.js +57 -57
  63. package/dist/esm/hooks/list.js +179 -0
  64. package/dist/esm/hooks/manage.js +19 -14
  65. package/dist/esm/hooks/overlay.js +6 -4
  66. package/dist/esm/hooks/theme.js +11 -11
  67. package/dist/esm/index.js +129 -113
  68. package/dist/esm/main.js +22 -12
  69. package/dist/esm/node_modules/dayjs/dayjs.min.js +282 -0
  70. package/dist/esm/node_modules/mitt/dist/mitt.js +19 -0
  71. package/dist/esm/preset/i18nProvider.js +17 -18
  72. package/dist/esm/provider/app.js +61 -53
  73. package/dist/esm/stores/manage.js +23 -15
  74. package/dist/esm/stores/tab.js +58 -49
  75. package/dist/esm/utils/theme.js +89 -76
  76. package/dist/types/components/index.d.ts +2 -1
  77. package/dist/types/components/loader/loader.d.ts +2 -0
  78. package/dist/types/components/loader/remote/index.d.ts +2 -0
  79. package/dist/types/components/loader/remote/loader.d.ts +1 -0
  80. package/dist/types/components/loader/remote/render.d.ts +1 -0
  81. package/dist/types/components/status/error.d.ts +1 -2
  82. package/dist/types/components/status/exception.d.ts +3 -0
  83. package/dist/types/components/status/index.d.ts +4 -0
  84. package/dist/types/components/status/notAuthorized.d.ts +1 -2
  85. package/dist/types/components/status/notFound.d.ts +1 -2
  86. package/dist/types/config/index.d.ts +1 -0
  87. package/dist/types/hooks/auth.d.ts +6 -6
  88. package/dist/types/hooks/data.d.ts +30 -30
  89. package/dist/types/hooks/form.d.ts +6 -3
  90. package/dist/types/hooks/formExtend.d.ts +12 -0
  91. package/dist/types/hooks/formValidate.d.ts +14 -0
  92. package/dist/types/hooks/i18n.d.ts +2 -0
  93. package/dist/types/hooks/import.d.ts +1 -2
  94. package/dist/types/hooks/index.d.ts +4 -1
  95. package/dist/types/hooks/json.d.ts +1 -1
  96. package/dist/types/hooks/list.d.ts +66 -0
  97. package/dist/types/hooks/manage.d.ts +1 -0
  98. package/dist/types/index.d.ts +6 -5
  99. package/dist/types/preset/i18nProvider.d.ts +1 -1
  100. package/dist/types/stores/route.d.ts +180 -180
  101. package/dist/types/stores/tab.d.ts +1112 -73
  102. package/dist/types/types/config.d.ts +9 -0
  103. package/dist/types/types/i18n.d.ts +1 -0
  104. package/dist/types/types/manage.d.ts +6 -0
  105. package/dist/types/utils/index.d.ts +1 -1
  106. package/dist/types/utils/theme.d.ts +4 -49
  107. package/package.json +11 -5
  108. /package/dist/cjs/{hooks/themeColor.cjs → config/color.cjs} +0 -0
  109. /package/dist/esm/{hooks/themeColor.js → config/color.js} +0 -0
  110. /package/dist/types/{hooks/themeColor.d.ts → config/color.d.ts} +0 -0
@@ -1,3 +1,4 @@
1
+ import type { Options } from 'vue3-sfc-loader';
1
2
  import type { RouteComponent, RouteRecordRaw } from 'vue-router';
2
3
  import type { IAuthProvider } from './auth';
3
4
  import type { IDataProvider } from './data';
@@ -21,6 +22,11 @@ export interface IConfig {
21
22
  components?: IConfigComponent;
22
23
  routes?: RouteRecordRaw[];
23
24
  theme?: IConfigTheme;
25
+ remote?: {
26
+ packages?: Options;
27
+ apiMethod?: string;
28
+ apiRoutePath?: string | ((path: string) => string);
29
+ };
24
30
  [key: string]: any;
25
31
  }
26
32
  export interface IConfigComponent {
@@ -29,5 +35,8 @@ export interface IConfigComponent {
29
35
  notFound?: RouteComponent;
30
36
  notAuthorized?: RouteComponent;
31
37
  error?: RouteComponent;
38
+ exception?: RouteComponent;
39
+ loading?: RouteComponent;
32
40
  iframe?: RouteComponent;
41
+ remote?: RouteComponent;
33
42
  }
@@ -6,5 +6,6 @@ export interface I18nProvider {
6
6
  t: (key: string, options?: any, defaultMessage?: string) => string;
7
7
  changeLocale: (lang: string, options?: any) => Promise<any>;
8
8
  loadLocale: (lang: string, files: Record<string, unknown>) => Promise<any>;
9
+ mergeLocale: (lang: string, messages: Record<string, unknown>) => void;
9
10
  getLocale: () => string;
10
11
  }
@@ -1,3 +1,4 @@
1
+ import type { Options } from 'vue3-sfc-loader';
1
2
  import type { RouteRecordRaw } from 'vue-router';
2
3
  import type { IAuthProvider } from './auth';
3
4
  import type { IConfigComponent } from './config';
@@ -26,5 +27,10 @@ export interface IManage {
26
27
  menus?: IMenu[];
27
28
  components?: IConfigComponent;
28
29
  theme?: IConfigTheme;
30
+ remote?: {
31
+ packages?: Options;
32
+ apiMethod?: string;
33
+ apiRoutePath?: string | ((path: string) => string);
34
+ };
29
35
  [key: string]: any;
30
36
  }
@@ -1,2 +1,2 @@
1
- export * from './tree';
2
1
  export * from './theme';
2
+ export * from './tree';
@@ -1,52 +1,7 @@
1
1
  export declare function themePreset(themeColor: Record<string, any>): {
2
- colors: Record<string, Record<string, any>>;
3
- classes: {
4
- 'text-default': {
5
- color: string;
6
- };
7
- 'text-dimmed': {
8
- color: string;
9
- };
10
- 'text-muted': {
11
- color: string;
12
- };
13
- 'text-toned': {
14
- color: string;
15
- };
16
- 'text-highlighted': {
17
- color: string;
18
- };
19
- 'text-inverted': {
20
- color: string;
21
- };
22
- 'bg-default': {
23
- 'background-color': string;
24
- };
25
- 'bg-muted': {
26
- 'background-color': string;
27
- };
28
- 'bg-elevated': {
29
- 'background-color': string;
30
- };
31
- 'bg-accented': {
32
- 'background-color': string;
33
- };
34
- 'bg-inverted': {
35
- 'background-color': string;
36
- };
37
- 'border-default': {
38
- 'border-color': string;
39
- };
40
- 'border-muted': {
41
- 'border-color': string;
42
- };
43
- 'border-accented': {
44
- 'border-color': string;
45
- };
46
- 'border-inverted': {
47
- 'border-color': string;
48
- };
2
+ name: string;
3
+ theme: {
4
+ colors: Record<string, Record<string, any>>;
49
5
  };
50
- rules: object[];
51
- utilities: Record<string, Record<string, string>>;
6
+ rules: any[];
52
7
  };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@duxweb/dvha-core",
3
3
  "type": "module",
4
- "version": "0.1.20",
4
+ "version": "0.1.21",
5
5
  "author": "DuxWeb",
6
6
  "license": "MIT",
7
7
  "repository": {
@@ -39,18 +39,24 @@
39
39
  "dependencies": {
40
40
  "@overlastic/vue": "^0.8.1",
41
41
  "@tanstack/vue-query": "^5.76.2",
42
+ "@vee-validate/rules": "^4.15.1",
42
43
  "@vueuse/core": "^13.3.0",
43
44
  "@vueuse/integrations": "^13.3.0",
44
45
  "axios": "^1.9.0",
45
46
  "clsx": "^2.1.1",
46
47
  "colorizr": "^3.0.8",
48
+ "crypto-js": "^4.2.0",
47
49
  "json-2-csv": "^5.5.9",
48
50
  "lodash-es": "^4.17.21",
49
- "petite-vue-i18n": "^11.1.4",
50
- "pinia": "^3.0.0",
51
- "pinia-plugin-persistedstate": "^4.0.0",
51
+ "mathjs": "^14.5.2",
52
+ "mime": "^4.0.7",
53
+ "pinia": "^3.0.3",
54
+ "pinia-plugin-persistedstate": "^4.3.0",
55
+ "vee-validate": "^4.15.1",
52
56
  "vue": "^3.5.0",
53
- "vue-router": "^4.0.0"
57
+ "vue-i18n": "^11.1.4",
58
+ "vue-router": "^4.0.0",
59
+ "vue3-sfc-loader": "^0.9.5"
54
60
  },
55
61
  "devDependencies": {
56
62
  "rimraf": "^6.0.1",