@go-wind/admin-vben 0.1.0 → 0.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@go-wind/admin-vben",
3
- "version": "0.1.0",
3
+ "version": "0.1.2",
4
4
  "description": "Vben 5 derived admin shell framework (Vue 3 + Ant Design Vue + tailwind), deep-customized and version-pinned by go-wind-admin. Consumed as a SOURCE package: hosts resolve subpaths into src/ via their own tsconfig paths / bundler, keeping full component types without a build step.",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -18,6 +18,7 @@
18
18
  "peerDependencies": {
19
19
  "@iconify/vue": ">=4.0.0",
20
20
  "@tanstack/vue-query": ">=5.0.0",
21
+ "@tanstack/vue-store": ">=0.6.0",
21
22
  "ant-design-vue": ">=4.2.0",
22
23
  "pinia": ">=2.2.0",
23
24
  "pinia-plugin-persistedstate": ">=4.0.0",
@@ -26,16 +27,40 @@
26
27
  "vue-router": ">=4.4.0"
27
28
  },
28
29
  "dependencies": {
29
- "@tanstack/vue-store": "0.11.2",
30
+ "@ctrl/tinycolor": "^4.1.0",
30
31
  "@intlify/core-base": "^10.0.0",
32
+ "@tanstack/vue-store": "0.6.0",
33
+ "@vee-validate/zod": "^4.15.0",
31
34
  "@vueuse/core": "^11.3.0",
32
- "axios": "^1.16.1",
35
+ "@vueuse/integrations": "^11.3.0",
36
+ "class-variance-authority": "^0.7.1",
37
+ "clsx": "^2.1.1",
38
+ "dayjs": "^1.11.13",
39
+ "defu": "6.1.4",
40
+ "json-bigint": "^1.0.0",
41
+ "lodash.clonedeep": "^4.5.0",
42
+ "lodash.get": "^4.4.2",
43
+ "lodash.isequal": "^4.5.0",
44
+ "lucide-vue-next": "^0.507.0",
45
+ "nprogress": "^0.2.0",
33
46
  "radix-vue": "^1.9.0",
47
+ "sortablejs": "^1.15.6",
48
+ "tailwind-merge": "^2.5.5",
49
+ "theme-colors": "^0.1.0",
34
50
  "vee-validate": "^4.13.0",
51
+ "vue-json-viewer": "^3.0.4",
52
+ "watermark-js-plus": "^1.5.7",
35
53
  "zod": "^3.23.0"
36
54
  },
37
55
  "publishConfig": {
38
56
  "access": "public",
39
57
  "registry": "https://registry.npmjs.org/"
58
+ },
59
+ "devDependencies": {
60
+ "vue": "3.5.13",
61
+ "vue-router": "5.4.0",
62
+ "pinia": "2.2.2",
63
+ "@vueuse/core": "11.3.0",
64
+ "@tanstack/vue-query": "5.105.0"
40
65
  }
41
66
  }
@@ -16,8 +16,19 @@ import VueJsonViewer from 'vue-json-viewer';
16
16
  import { $t } from '../../../../locales';
17
17
  import { isBoolean } from '../../../../base/shared/utils';
18
18
 
19
- // @ts-ignore
20
- import JsonBigint from 'json-bigint';
19
+ /**
20
+ * 大数安全解析:把 JSON 里 16 位以上的裸数字加引号后交给 JSON.parse
21
+ * 后其 import 无法被预构建重写,浏览器直取 raw 会因缺 default 导出而崩。
22
+ * 预处理只匹配「: 或 , 或 [ 之后紧跟的裸数字字面量」,不会误伤字符串内容
23
+ * 中带引号的同名片段(那些片段前一个字符是引号,不满足负向断言会被跳过)。
24
+ */
25
+ function parseWithBigintAsString(text: string): Record<string, any> {
26
+ const safe = text.replace(/([{,]\s*)"?(true|false)"?/g, '$1$2').replace(
27
+ /(:\s*|\[\s*)(-?\d{15,}(?:\.\d+)?)(\s*[,\]}])/g,
28
+ '$1"$2"$3',
29
+ );
30
+ return JSON.parse(safe);
31
+ }
21
32
 
22
33
  defineOptions({ name: 'JsonViewer' });
23
34
 
@@ -76,7 +87,7 @@ const jsonData = computed<Record<string, any>>(() => {
76
87
  }
77
88
 
78
89
  try {
79
- return JsonBigint({ storeAsString: true }).parse(props.value);
90
+ return parseWithBigintAsString(props.value);
80
91
  } catch (error) {
81
92
  console.error('JSON parse error:', error);
82
93
  return {};