@pubinfo-pr/core 0.230.1 → 0.231.1
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/dist/{AppSetting-DxV7nNkI.js → AppSetting-ipWat3GI.js} +6 -6
- package/dist/{HCheckList-B-6FpnO9.js → HCheckList-DGq85k9z.js} +1 -1
- package/dist/{HSlideover-B6gEDfA5.js → HSlideover-DqsKvKiI.js} +1 -1
- package/dist/{PreferencesContent-8y4xvxPh.js → PreferencesContent-qg_ZQftO.js} +3 -5
- package/dist/{SettingBreadcrumb-3PoN9Ecz.js → SettingBreadcrumb-GUJWKm3l.js} +1 -4
- package/dist/{SettingMenu-D-TfSLho.js → SettingMenu-CI1VE_2k.js} +1 -4
- package/dist/{SettingTabbar-BDqQAYef.js → SettingTabbar-BsRVzcwN.js} +1 -4
- package/dist/{SettingThemes-DaRKZ2Q3.js → SettingThemes--ObZszDO.js} +1 -3
- package/dist/{SettingTopbar-yoEeNKdr.js → SettingTopbar-rsafB5tv.js} +1 -4
- package/dist/{auth-BVTDpkDr.js → auth-BU3f3mc7.js} +3 -3
- package/dist/{change-organization-BezqpSfp.js → change-organization-BjgmB5xc.js} +4 -5
- package/dist/{change-password-BTb3qYGv.js → change-password-0VLMfQB_.js} +5 -6
- package/dist/{components-BHWiQ3ez.js → components-B6fZinoE.js} +132 -146
- package/dist/{core-Dg8YES9i.js → core--p_FvLxH.js} +6 -7
- package/dist/{form-CGzMvzKZ.js → form-CmNl2b3W.js} +2 -2
- package/dist/index.js +12 -12
- package/dist/{modal-ybprgEqf.js → modal-DXJis9Ay.js} +2 -2
- package/dist/{not-found-CuHR6H_g.js → not-found-BLDgkCMn.js} +1 -3
- package/dist/{not-permission-BcQAkzxI.js → not-permission-DpD0vTVw.js} +1 -3
- package/dist/{profile-Bsc6FIbI.js → profile-Cp1PyI44.js} +14 -15
- package/dist/{tree-select-gPCwtMia.js → tree-select-DS-DUpQw.js} +1660 -1660
- package/dist/{watchDiff-DJP3s9bb.js → watchDiff-Dofh9yLN.js} +4 -4
- package/package.json +8 -8
- package/src/features/components/PubinfoIcon/index.vue +43 -2
- package/dist/features/components/PubinfoIcon/parser.d.ts +0 -6
- package/src/features/components/PubinfoIcon/parser.ts +0 -42
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Gr as e, Jr as t, Kr as n, Wr as r, Yr as i, qr as a } from "./modal-
|
|
1
|
+
import { Gr as e, Jr as t, Kr as n, Wr as r, Yr as i, qr as a } from "./modal-DXJis9Ay.js";
|
|
2
2
|
import { watch as o } from "vue";
|
|
3
3
|
//#region ../../node_modules/.pnpm/lodash-es@4.17.23/node_modules/lodash-es/isObjectLike.js
|
|
4
4
|
function s(e) {
|
|
@@ -323,7 +323,7 @@ function At() {
|
|
|
323
323
|
//#region ../../node_modules/.pnpm/lodash-es@4.17.23/node_modules/lodash-es/_hashDelete.js
|
|
324
324
|
function jt(e) {
|
|
325
325
|
var t = this.has(e) && delete this.__data__[e];
|
|
326
|
-
return this.size -= t
|
|
326
|
+
return this.size -= +!!t, t;
|
|
327
327
|
}
|
|
328
328
|
//#endregion
|
|
329
329
|
//#region ../../node_modules/.pnpm/lodash-es@4.17.23/node_modules/lodash-es/_hashGet.js
|
|
@@ -348,7 +348,7 @@ function It(e) {
|
|
|
348
348
|
var Lt = "__lodash_hash_undefined__";
|
|
349
349
|
function Rt(e, t) {
|
|
350
350
|
var n = this.__data__;
|
|
351
|
-
return this.size += this.has(e)
|
|
351
|
+
return this.size += +!this.has(e), n[e] = F && t === void 0 ? Lt : t, this;
|
|
352
352
|
}
|
|
353
353
|
//#endregion
|
|
354
354
|
//#region ../../node_modules/.pnpm/lodash-es@4.17.23/node_modules/lodash-es/_Hash.js
|
|
@@ -433,7 +433,7 @@ function B(e, t) {
|
|
|
433
433
|
//#region ../../node_modules/.pnpm/lodash-es@4.17.23/node_modules/lodash-es/_mapCacheDelete.js
|
|
434
434
|
function qt(e) {
|
|
435
435
|
var t = B(this, e).delete(e);
|
|
436
|
-
return this.size -= t
|
|
436
|
+
return this.size -= +!!t, t;
|
|
437
437
|
}
|
|
438
438
|
//#endregion
|
|
439
439
|
//#region ../../node_modules/.pnpm/lodash-es@4.17.23/node_modules/lodash-es/_mapCacheGet.js
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@pubinfo-pr/core",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.231.1",
|
|
5
5
|
"exports": {
|
|
6
6
|
".": {
|
|
7
7
|
"types": "./dist/index.d.ts",
|
|
@@ -27,9 +27,9 @@
|
|
|
27
27
|
"node": "^20.19.0 || >=22.12.0"
|
|
28
28
|
},
|
|
29
29
|
"peerDependencies": {
|
|
30
|
-
"@pubinfo-pr/config": "0.
|
|
31
|
-
"@pubinfo-pr/devtools": "0.
|
|
32
|
-
"@pubinfo-pr/vite": "0.
|
|
30
|
+
"@pubinfo-pr/config": "0.231.1",
|
|
31
|
+
"@pubinfo-pr/devtools": "0.231.1",
|
|
32
|
+
"@pubinfo-pr/vite": "0.231.1",
|
|
33
33
|
"alova": "^3.5.0",
|
|
34
34
|
"pinia": "^3.0.4",
|
|
35
35
|
"vue": "^3.5.28",
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
"@headlessui/vue": "^1.7.23",
|
|
43
43
|
"@imengyu/vue3-context-menu": "^1.5.4",
|
|
44
44
|
"@pubinfo/pro-components": "^1.8.2",
|
|
45
|
-
"@pubinfo-pr/shared": "0.
|
|
45
|
+
"@pubinfo-pr/shared": "0.231.1",
|
|
46
46
|
"@unocss/reset": "^66.6.0",
|
|
47
47
|
"@vueuse/core": "^14.2.1",
|
|
48
48
|
"@vueuse/integrations": "^14.2.1",
|
|
@@ -69,10 +69,10 @@
|
|
|
69
69
|
"@alova/mock": "^2.0.18",
|
|
70
70
|
"@iconify/json": "^2.2.437",
|
|
71
71
|
"@iconify/vue": "^5.0.0",
|
|
72
|
-
"@pubinfo-pr/config": "0.
|
|
72
|
+
"@pubinfo-pr/config": "0.231.1",
|
|
73
73
|
"@pubinfo/openapi": "^0.9.1",
|
|
74
74
|
"@pubinfo/preset-openapi": "^0.9.1",
|
|
75
|
-
"@pubinfo-pr/vite": "0.
|
|
75
|
+
"@pubinfo-pr/vite": "0.231.1",
|
|
76
76
|
"@types/lodash-es": "^4.17.12",
|
|
77
77
|
"@types/md5": "^2.3.6",
|
|
78
78
|
"@types/nprogress": "^0.2.3",
|
|
@@ -91,7 +91,7 @@
|
|
|
91
91
|
"unplugin-auto-import": "^21.0.0",
|
|
92
92
|
"unplugin-icons": "^23.0.1",
|
|
93
93
|
"unplugin-vue-components": "^31.0.0",
|
|
94
|
-
"vite": "^8.0.
|
|
94
|
+
"vite": "^8.0.8",
|
|
95
95
|
"vite-plugin-dts": "^4.5.4",
|
|
96
96
|
"vue": "^3.5.28",
|
|
97
97
|
"vue-router": "^5.0.2"
|
|
@@ -5,7 +5,6 @@ import { Icon } from '@iconify/vue';
|
|
|
5
5
|
import { shallowRef, watch } from 'vue';
|
|
6
6
|
import { getCachedIcon, setCachedIcon, setupIcon } from '@/core';
|
|
7
7
|
import { useProvider } from '../PubinfoProvider';
|
|
8
|
-
import { parseCustomIconName } from './parser';
|
|
9
8
|
import PrismBox from './PrismBox.vue';
|
|
10
9
|
import SquareBox from './SquareBox.vue';
|
|
11
10
|
|
|
@@ -75,7 +74,7 @@ const element = computed(() => {
|
|
|
75
74
|
const icon = shallowRef<string | undefined>(undefined);
|
|
76
75
|
|
|
77
76
|
function getIconLookupMeta(rawName: string) {
|
|
78
|
-
const parsed =
|
|
77
|
+
const parsed = parseString(rawName);
|
|
79
78
|
const fileName = `${parsed.name}${parsed.ext || '.svg'}`;
|
|
80
79
|
const moduleId = parsed.prefix || undefined;
|
|
81
80
|
return { fileName, moduleId } as const;
|
|
@@ -160,6 +159,48 @@ watch(
|
|
|
160
159
|
{ immediate: true, flush: 'sync' },
|
|
161
160
|
);
|
|
162
161
|
|
|
162
|
+
interface Parsed {
|
|
163
|
+
prefix: string
|
|
164
|
+
name: string
|
|
165
|
+
ext: string
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
function parseString(str: string): Parsed {
|
|
169
|
+
let prefix = '';
|
|
170
|
+
let name = '';
|
|
171
|
+
let ext = '';
|
|
172
|
+
|
|
173
|
+
// 匹配 RBAC-[org.svg] 或 RBAC-[org]
|
|
174
|
+
const match = str.match(/^([^-\s]+)-\[(.+)\]$/);
|
|
175
|
+
|
|
176
|
+
if (match) {
|
|
177
|
+
prefix = match[1];
|
|
178
|
+
const inner = match[2];
|
|
179
|
+
|
|
180
|
+
const dotIdx = inner.lastIndexOf('.');
|
|
181
|
+
if (dotIdx !== -1) {
|
|
182
|
+
name = inner.slice(0, dotIdx);
|
|
183
|
+
ext = inner.slice(dotIdx);
|
|
184
|
+
}
|
|
185
|
+
else {
|
|
186
|
+
name = inner;
|
|
187
|
+
}
|
|
188
|
+
}
|
|
189
|
+
else {
|
|
190
|
+
// 如果没有前缀格式,就当普通文件处理
|
|
191
|
+
const dotIdx = str.lastIndexOf('.');
|
|
192
|
+
if (dotIdx !== -1) {
|
|
193
|
+
name = str.slice(0, dotIdx);
|
|
194
|
+
ext = str.slice(dotIdx);
|
|
195
|
+
}
|
|
196
|
+
else {
|
|
197
|
+
name = str;
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
return { prefix, name, ext };
|
|
202
|
+
}
|
|
203
|
+
|
|
163
204
|
const style = computed(() => {
|
|
164
205
|
const transform: string[] = [];
|
|
165
206
|
if (props.flip) {
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
export interface ParsedIconName {
|
|
2
|
-
prefix: string
|
|
3
|
-
name: string
|
|
4
|
-
ext: string
|
|
5
|
-
}
|
|
6
|
-
|
|
7
|
-
function splitNameExt(value: string) {
|
|
8
|
-
const dotIdx = value.lastIndexOf('.');
|
|
9
|
-
if (dotIdx !== -1) {
|
|
10
|
-
return {
|
|
11
|
-
name: value.slice(0, dotIdx),
|
|
12
|
-
ext: value.slice(dotIdx),
|
|
13
|
-
};
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
return {
|
|
17
|
-
name: value,
|
|
18
|
-
ext: '',
|
|
19
|
-
};
|
|
20
|
-
}
|
|
21
|
-
|
|
22
|
-
export function parseCustomIconName(str: string): ParsedIconName {
|
|
23
|
-
const markerIdx = str.lastIndexOf('-[');
|
|
24
|
-
const hasScopedSyntax = markerIdx > 0 && str.endsWith(']');
|
|
25
|
-
|
|
26
|
-
if (hasScopedSyntax) {
|
|
27
|
-
const prefix = str.slice(0, markerIdx);
|
|
28
|
-
const inner = str.slice(markerIdx + 2, -1);
|
|
29
|
-
|
|
30
|
-
if (prefix && inner) {
|
|
31
|
-
return {
|
|
32
|
-
prefix,
|
|
33
|
-
...splitNameExt(inner),
|
|
34
|
-
};
|
|
35
|
-
}
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
return {
|
|
39
|
-
prefix: '',
|
|
40
|
-
...splitNameExt(str),
|
|
41
|
-
};
|
|
42
|
-
}
|