@gct-paas/core-web 0.1.5-dev.4 → 0.1.5-dev.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.
- package/dist/_plugin-vue_export-helper-DySwtVV7.js +1 -0
- package/dist/icon-next-picker-CShmDJI0.js +1 -0
- package/dist/index.min.css +1 -1
- package/dist/loader.esm.min.js +1 -1
- package/dist/monaco-editor-t8SRxaFC.js +1 -0
- package/dist/overlayscrollbars-vue-B2LfyB-V.js +1 -0
- package/es/components/UserPick/src/user-pick.vue_vue_type_script_setup_true_lang.mjs +2 -2
- package/es/components/base-button/base-button.vue.mjs +1 -1
- package/es/components/field-upload/src/components/base-upload.vue.mjs +2 -2
- package/es/components/field-upload/src/components/base-upload.vue_vue_type_script_name_baseUpload_setup_true_lang.mjs +4 -3
- package/es/components/field-upload/src/components/{base-upload.vue_vue_type_style_index_0_scoped_f53b6ac6_lang.css → base-upload.vue_vue_type_style_index_0_scoped_65872e0a_lang.css} +18 -18
- package/es/components/field-upload/src/components/file-list.vue.mjs +2 -2
- package/es/components/field-upload/src/components/file-list.vue_vue_type_script_setup_true_name_fileList_lang.mjs +2 -2
- package/es/components/field-upload/src/components/{file-list.vue_vue_type_style_index_0_scoped_3918aad0_lang.css → file-list.vue_vue_type_style_index_0_scoped_543b5221_lang.css} +25 -25
- package/es/components/field-upload/src/components/upload-design.vue.mjs +2 -2
- package/es/components/field-upload/src/components/upload-design.vue_vue_type_script_name_UploadDesign_setup_true_lang.mjs +4 -3
- package/es/components/field-upload/src/components/{upload-design.vue_vue_type_style_index_0_scoped_1e5189c1_lang.css → upload-design.vue_vue_type_style_index_0_scoped_5fd18cf8_lang.css} +10 -10
- package/es/components/icon-next-picker/icon-next-picker.vue.mjs +6 -0
- package/es/components/{icon-next/src/IconNextPicker.vue_vue_type_script_setup_true_name_IconNextPicker_lang.mjs → icon-next-picker/icon-next-picker.vue_vue_type_script_setup_true_name_IconNextPicker_lang.mjs} +7 -11
- package/es/components/image-upload/index.mjs +1 -1
- package/es/components/index.d.ts +2 -5
- package/es/components/index.mjs +3 -11
- package/es/components/number-range/number-range.vue.d.ts +85 -0
- package/es/components/number-range/number-range.vue.mjs +7 -0
- package/es/components/number-range/number-range.vue_vue_type_script_setup_true_lang.mjs +91 -0
- package/es/components/number-range/number-range.vue_vue_type_style_index_0_scoped_283a5280_lang.css +8 -0
- package/es/create-app-vue.mjs +5 -3
- package/es/index.mjs +37 -39
- package/es/modules/color-picker/src/ColorPicker.vue.mjs +1 -1
- package/es/modules/formula-editor/formula-editor.mjs +1 -2
- package/es/modules/formula-editor/interface/i-formula-editor-options/i-formula-editor-options.d.ts +2 -0
- package/es/modules/gct-table/editor/gct-table-date/gct-table-date.mjs +1 -1
- package/es/modules/gct-table/editor/gct-table-text/gct-table-text.mjs +1 -1
- package/es/setup-app.d.ts +2 -1
- package/es/setup-app.mjs +1 -3
- package/es/utils/index.d.ts +1 -0
- package/es/utils/index.mjs +1 -0
- package/es/utils/model-entity/model-entity.d.ts +28 -0
- package/es/utils/model-entity/model-entity.mjs +47 -0
- package/package.json +7 -5
- package/dist/monaco-editor-BSzX1Bsh.js +0 -1
- package/dist/useMonacoEditor-BCTpu3UR.js +0 -1
- package/es/components/assets-svg-icon/assets-svg-icon.css +0 -188
- package/es/components/assets-svg-icon/assets-svg-icon.d.ts +0 -134
- package/es/components/assets-svg-icon/assets-svg-icon.mjs +0 -167
- package/es/components/assets-svg-icon/request.d.ts +0 -2
- package/es/components/assets-svg-icon/request.mjs +0 -68
- package/es/components/assets-svg-icon/utils.d.ts +0 -9
- package/es/components/assets-svg-icon/utils.mjs +0 -23
- package/es/components/assets-svg-icon/validate.d.ts +0 -4
- package/es/components/assets-svg-icon/validate.mjs +0 -29
- package/es/components/icon-next/data/icons.data.d.ts +0 -5
- package/es/components/icon-next/hooks/useIconAsset.d.ts +0 -16
- package/es/components/icon-next/hooks/useIconAsset.mjs +0 -36
- package/es/components/icon-next/hooks/useIconPark.d.ts +0 -16
- package/es/components/icon-next/hooks/useIconPark.mjs +0 -52
- package/es/components/icon-next/hooks/useIconPlatform.d.ts +0 -8
- package/es/components/icon-next/hooks/useIconPlatform.mjs +0 -43
- package/es/components/icon-next/index.d.ts +0 -3
- package/es/components/icon-next/index.mjs +0 -3
- package/es/components/icon-next/src/IconNext.vue.d.ts +0 -40
- package/es/components/icon-next/src/IconNext.vue.mjs +0 -7
- package/es/components/icon-next/src/IconNext.vue_vue_type_script_setup_true_name_IconNext_lang.mjs +0 -113
- package/es/components/icon-next/src/IconNext.vue_vue_type_style_index_0_scoped_360a87c9_lang.css +0 -18
- package/es/components/icon-next/src/IconNextPicker.vue.mjs +0 -6
- package/es/components/icon-next/types/index.d.ts +0 -17
- package/es/components/icon-next/types/index.mjs +0 -11
- package/es/components/svg-icon/svg-icon.vue.d.ts +0 -40
- package/es/components/svg-icon/svg-icon.vue.mjs +0 -6
- package/es/components/svg-icon/svg-icon.vue_vue_type_script_setup_true_name_SvgIcon_lang.mjs +0 -52
- package/es/components/svg-icon/svg-icon.vue_vue_type_style_index_0_lang.css +0 -73
- package/es/components/wujie-container/wujie-container.css +0 -74
- package/es/components/wujie-container/wujie-container.d.ts +0 -11
- package/es/components/wujie-container/wujie-container.mjs +0 -61
- /package/dist/{cropper-DyP6CFER.js → cropper-DPh9NaIi.js} +0 -0
- /package/dist/{de_DE-DIDpd1gQ.js → de_DE-BY1He8Sf.js} +0 -0
- /package/dist/{en_US-BaP-b1tP.js → en_US-CuX-vrWy.js} +0 -0
- /package/dist/{es_ES-NOVlNQnw.js → es_ES-BqHRjpc9.js} +0 -0
- /package/dist/{fr_FR-Bk_x0L7S.js → fr_FR-C4TFcMTv.js} +0 -0
- /package/dist/{ja_JP-CeseBQS9.js → ja_JP-CgXnA74i.js} +0 -0
- /package/dist/{pt_PT-DFlFmzXZ.js → pt_PT-C0ALlHDr.js} +0 -0
- /package/dist/{ru_RU-C5XPaRfl.js → ru_RU-D39vUeFW.js} +0 -0
- /package/dist/{tr_TR-CODhj5X1.js → tr_TR-Cm3P61iH.js} +0 -0
- /package/dist/{vi_VN-BjwID8XV.js → vi_VN-BZ_iPKuE.js} +0 -0
- /package/dist/{zh_CN-BKmwBYsr.js → zh_CN-DY_wA21D.js} +0 -0
- /package/dist/{zh_TW-BSGEo2Qx.js → zh_TW-A1Y7MG2g.js} +0 -0
- /package/es/components/{icon-next/src/IconNextPicker.vue.d.ts → icon-next-picker/icon-next-picker.vue.d.ts} +0 -0
- /package/es/components/{icon-next/src/IconNextPicker.vue_vue_type_style_index_0_lang.css → icon-next-picker/icon-next-picker.vue_vue_type_style_index_0_lang.css} +0 -0
- /package/es/modules/gct-table/editor/{gct-table-date/gct-table-date.css → gct-table-text/gct-table-text.css} +0 -0
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
import { isEncodedDataUrl, isSvgDataUrl, validateContent } from "./validate.mjs";
|
|
2
|
-
//#region src/components/assets-svg-icon/request.ts
|
|
3
|
-
var ioniconContent = /* @__PURE__ */ new Map();
|
|
4
|
-
var requests = /* @__PURE__ */ new Map();
|
|
5
|
-
var parser;
|
|
6
|
-
/**
|
|
7
|
-
* Safely fallback to an empty svg
|
|
8
|
-
*/
|
|
9
|
-
function safeFallback(url) {
|
|
10
|
-
const svg = "";
|
|
11
|
-
ioniconContent.set(url, svg);
|
|
12
|
-
return svg;
|
|
13
|
-
}
|
|
14
|
-
var getSvgContent = (url, sanitize) => {
|
|
15
|
-
/**
|
|
16
|
-
* See if we already have a request for this url
|
|
17
|
-
*/
|
|
18
|
-
const req = requests.get(url);
|
|
19
|
-
if (req) return req;
|
|
20
|
-
if (typeof fetch !== "undefined" && typeof document !== "undefined") {
|
|
21
|
-
/**
|
|
22
|
-
* If the url is a data url of an svg, then try to parse it
|
|
23
|
-
* with the DOMParser. This works with content security policies enabled.
|
|
24
|
-
*/
|
|
25
|
-
if (isSvgDataUrl(url) && isEncodedDataUrl(url)) return Promise.resolve(getSvgByUrl(url));
|
|
26
|
-
return fetchSvg(url, sanitize);
|
|
27
|
-
}
|
|
28
|
-
return Promise.resolve(safeFallback(url));
|
|
29
|
-
};
|
|
30
|
-
function getSvgByUrl(url) {
|
|
31
|
-
if (!parser)
|
|
32
|
-
/**
|
|
33
|
-
* Create an instance of the DOM parser. This creates a single
|
|
34
|
-
* parser instance for the entire app, which is more efficient.
|
|
35
|
-
*/
|
|
36
|
-
parser = new DOMParser();
|
|
37
|
-
const svg = parser.parseFromString(url, "text/html").querySelector("svg");
|
|
38
|
-
if (svg) {
|
|
39
|
-
ioniconContent.set(url, svg.outerHTML);
|
|
40
|
-
return svg.outerHTML;
|
|
41
|
-
}
|
|
42
|
-
throw new Error(`Could not parse svg from ${url}`);
|
|
43
|
-
}
|
|
44
|
-
function fetchSvg(url, sanitize) {
|
|
45
|
-
/**
|
|
46
|
-
* We don't already have a request
|
|
47
|
-
*/
|
|
48
|
-
const req = fetch(url).then((rsp) => {
|
|
49
|
-
/**
|
|
50
|
-
* When fetching from a file:// URL, some browsers return
|
|
51
|
-
* a 0 status code even when the request succeeds so don't
|
|
52
|
-
* rely on rsp.ok as the only signal of success.
|
|
53
|
-
*/
|
|
54
|
-
return rsp.text().then((svgContent) => {
|
|
55
|
-
if (svgContent && sanitize !== false) svgContent = validateContent(svgContent);
|
|
56
|
-
const svg = svgContent || "";
|
|
57
|
-
ioniconContent.set(url, svg);
|
|
58
|
-
return svg;
|
|
59
|
-
}).catch(() => safeFallback(url));
|
|
60
|
-
}).catch(() => safeFallback(url));
|
|
61
|
-
/**
|
|
62
|
-
* Cache for the same requests
|
|
63
|
-
*/
|
|
64
|
-
requests.set(url, req);
|
|
65
|
-
return req;
|
|
66
|
-
}
|
|
67
|
-
//#endregion
|
|
68
|
-
export { getSvgContent, ioniconContent };
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
export declare const isStr: (val: any) => val is string;
|
|
2
|
-
export declare const isSrc: (str: string) => boolean;
|
|
3
|
-
export declare const getSrc: (src: string | undefined) => string | null;
|
|
4
|
-
/**
|
|
5
|
-
* Returns `true` if the document or host element
|
|
6
|
-
* has a `dir` set to `rtl`. The host value will always
|
|
7
|
-
* take priority over the root document value.
|
|
8
|
-
*/
|
|
9
|
-
export declare const isRTL: (hostEl?: Pick<HTMLElement, "dir">) => boolean;
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
//#region src/components/assets-svg-icon/utils.ts
|
|
2
|
-
var isStr = (val) => typeof val === "string";
|
|
3
|
-
var isSrc = (str) => str.length > 0 && /(\/|\.)/.test(str);
|
|
4
|
-
var getSrc = (src) => {
|
|
5
|
-
if (isStr(src)) {
|
|
6
|
-
src = src.trim();
|
|
7
|
-
if (isSrc(src)) return src;
|
|
8
|
-
}
|
|
9
|
-
return null;
|
|
10
|
-
};
|
|
11
|
-
/**
|
|
12
|
-
* Returns `true` if the document or host element
|
|
13
|
-
* has a `dir` set to `rtl`. The host value will always
|
|
14
|
-
* take priority over the root document value.
|
|
15
|
-
*/
|
|
16
|
-
var isRTL = (hostEl) => {
|
|
17
|
-
if (hostEl) {
|
|
18
|
-
if (hostEl.dir !== "") return hostEl.dir.toLowerCase() === "rtl";
|
|
19
|
-
}
|
|
20
|
-
return document?.dir.toLowerCase() === "rtl";
|
|
21
|
-
};
|
|
22
|
-
//#endregion
|
|
23
|
-
export { getSrc, isRTL, isStr };
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import { isStr } from "./utils.mjs";
|
|
2
|
-
//#region src/components/assets-svg-icon/validate.ts
|
|
3
|
-
var validateContent = (svgContent) => {
|
|
4
|
-
const div = document.createElement("div");
|
|
5
|
-
div.innerHTML = svgContent;
|
|
6
|
-
for (let i = div.childNodes.length - 1; i >= 0; i--) if (div.childNodes[i].nodeName.toLowerCase() !== "svg") div.removeChild(div.childNodes[i]);
|
|
7
|
-
const svgElm = div.firstElementChild;
|
|
8
|
-
if (svgElm && svgElm.nodeName.toLowerCase() === "svg") {
|
|
9
|
-
const svgClass = svgElm.getAttribute("class") || "";
|
|
10
|
-
svgElm.setAttribute("class", (svgClass + " s-ion-icon").trim());
|
|
11
|
-
if (isValid(svgElm)) return div.innerHTML;
|
|
12
|
-
}
|
|
13
|
-
return "";
|
|
14
|
-
};
|
|
15
|
-
var isValid = (elm) => {
|
|
16
|
-
if (elm.nodeType === 1) {
|
|
17
|
-
if (elm.nodeName.toLowerCase() === "script") return false;
|
|
18
|
-
for (let i = 0; i < elm.attributes.length; i++) {
|
|
19
|
-
const name = elm.attributes[i].name;
|
|
20
|
-
if (isStr(name) && name.toLowerCase().indexOf("on") === 0) return false;
|
|
21
|
-
}
|
|
22
|
-
for (let i = 0; i < elm.childNodes.length; i++) if (!isValid(elm.childNodes[i])) return false;
|
|
23
|
-
}
|
|
24
|
-
return true;
|
|
25
|
-
};
|
|
26
|
-
var isSvgDataUrl = (url) => url.startsWith("data:image/svg+xml");
|
|
27
|
-
var isEncodedDataUrl = (url) => url.indexOf(";utf8,") !== -1;
|
|
28
|
-
//#endregion
|
|
29
|
-
export { isEncodedDataUrl, isSvgDataUrl, validateContent };
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
export declare function useIconAsset(): {
|
|
2
|
-
getIconAssetCats: () => Promise<{
|
|
3
|
-
id: string;
|
|
4
|
-
name: string;
|
|
5
|
-
children: {
|
|
6
|
-
id: string;
|
|
7
|
-
name: string;
|
|
8
|
-
icons?: {
|
|
9
|
-
id: string;
|
|
10
|
-
name: string;
|
|
11
|
-
_filter_: string[];
|
|
12
|
-
}[] | undefined;
|
|
13
|
-
children?: /*elided*/ any[] | undefined;
|
|
14
|
-
}[];
|
|
15
|
-
}[]>;
|
|
16
|
-
};
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
import { IconNamespaceEnum } from "../types/index.mjs";
|
|
2
|
-
import { computed, ref } from "vue";
|
|
3
|
-
//#region src/components/icon-next/hooks/useIconAsset.ts
|
|
4
|
-
var iconAssetIcons = ref([]);
|
|
5
|
-
var iconParkCats = computed(() => {
|
|
6
|
-
return [{
|
|
7
|
-
id: "IconAsset",
|
|
8
|
-
name: "资产图标",
|
|
9
|
-
children: iconAssetIcons.value
|
|
10
|
-
}].filter((i) => i.children?.length);
|
|
11
|
-
});
|
|
12
|
-
function useIconAsset() {
|
|
13
|
-
async function getIconAssetCats() {
|
|
14
|
-
if (iconAssetIcons.value.length > 0) return iconParkCats.value;
|
|
15
|
-
const params = { assetsModule: "ICON" };
|
|
16
|
-
iconAssetIcons.value = await Promise.all([_api.platform.category.getList(params), _api.platform.assets.getList(params)]).then(([catRes, iconRes]) => {
|
|
17
|
-
return catRes?.map((c) => {
|
|
18
|
-
return {
|
|
19
|
-
id: `${c.id}`,
|
|
20
|
-
name: c.name,
|
|
21
|
-
icons: iconRes?.filter((i) => i.categoryId === c.id).map((item) => {
|
|
22
|
-
Object.assign(item, {
|
|
23
|
-
id: `${IconNamespaceEnum.Asset}:${item.path}`,
|
|
24
|
-
_filter_: [item.name]
|
|
25
|
-
});
|
|
26
|
-
return item;
|
|
27
|
-
})
|
|
28
|
-
};
|
|
29
|
-
}).filter((i) => i.icons?.length);
|
|
30
|
-
});
|
|
31
|
-
return iconParkCats.value;
|
|
32
|
-
}
|
|
33
|
-
return { getIconAssetCats };
|
|
34
|
-
}
|
|
35
|
-
//#endregion
|
|
36
|
-
export { useIconAsset };
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
export declare function useIconPark(): {
|
|
2
|
-
getIconParkCats: () => {
|
|
3
|
-
id: string;
|
|
4
|
-
name: string;
|
|
5
|
-
children: {
|
|
6
|
-
id: string;
|
|
7
|
-
name: string;
|
|
8
|
-
icons?: {
|
|
9
|
-
id: string;
|
|
10
|
-
name: string;
|
|
11
|
-
_filter_: string[];
|
|
12
|
-
}[] | undefined;
|
|
13
|
-
children?: /*elided*/ any[] | undefined;
|
|
14
|
-
}[];
|
|
15
|
-
}[];
|
|
16
|
-
};
|
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { IconNamespaceEnum } from "../types/index.mjs";
|
|
2
|
-
import { computed, ref } from "vue";
|
|
3
|
-
import IconParkJson from "@icon-park/vue-next/icons.json";
|
|
4
|
-
//#region src/components/icon-next/hooks/useIconPark.ts
|
|
5
|
-
var CategoyEnum = /* @__PURE__ */ function(CategoyEnum) {
|
|
6
|
-
CategoyEnum["Base"] = "Base";
|
|
7
|
-
CategoyEnum["Others"] = "Others";
|
|
8
|
-
return CategoyEnum;
|
|
9
|
-
}(CategoyEnum || {});
|
|
10
|
-
var iconParkIcons = ref([]);
|
|
11
|
-
var iconParkCats = computed(() => {
|
|
12
|
-
return [{
|
|
13
|
-
id: "IconPark",
|
|
14
|
-
name: "IconPark",
|
|
15
|
-
children: iconParkIcons.value
|
|
16
|
-
}];
|
|
17
|
-
});
|
|
18
|
-
function useIconPark() {
|
|
19
|
-
function getIconParkCats() {
|
|
20
|
-
if (iconParkIcons.value.length > 0) return iconParkCats.value;
|
|
21
|
-
const cats = [];
|
|
22
|
-
IconParkJson.forEach((item) => {
|
|
23
|
-
const icon = {
|
|
24
|
-
...item,
|
|
25
|
-
id: `${IconNamespaceEnum.IconPark}:${item.name}`,
|
|
26
|
-
_filter_: [
|
|
27
|
-
...item.tag,
|
|
28
|
-
item.title,
|
|
29
|
-
item.name
|
|
30
|
-
]
|
|
31
|
-
};
|
|
32
|
-
let category = cats.find((c) => c.id === icon.category);
|
|
33
|
-
if (category) category.icons.push(icon);
|
|
34
|
-
else {
|
|
35
|
-
category = {
|
|
36
|
-
id: icon.category,
|
|
37
|
-
name: icon.categoryCN,
|
|
38
|
-
icons: [icon]
|
|
39
|
-
};
|
|
40
|
-
cats.push(category);
|
|
41
|
-
}
|
|
42
|
-
});
|
|
43
|
-
const base = cats.filter((c) => c.id === CategoyEnum.Base);
|
|
44
|
-
const others = cats.filter((c) => c.id === CategoyEnum.Others);
|
|
45
|
-
const middle = cats.filter((c) => ![CategoyEnum.Base, CategoyEnum.Others].includes(c.id));
|
|
46
|
-
iconParkIcons.value = base.concat(middle, others);
|
|
47
|
-
return iconParkCats.value;
|
|
48
|
-
}
|
|
49
|
-
return { getIconParkCats };
|
|
50
|
-
}
|
|
51
|
-
//#endregion
|
|
52
|
-
export { useIconPark };
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import { IconNamespaceEnum } from "../types/index.mjs";
|
|
2
|
-
import { computed } from "vue";
|
|
3
|
-
import { iconsNames } from "@gct-paas/platform-icons";
|
|
4
|
-
//#region src/components/icon-next/hooks/useIconPlatform.ts
|
|
5
|
-
var iconPlatformCats = computed(() => {
|
|
6
|
-
return [{
|
|
7
|
-
id: "medicalCare",
|
|
8
|
-
name: "医疗器械",
|
|
9
|
-
icons: medicalCareIcons.value
|
|
10
|
-
}, {
|
|
11
|
-
id: "IconPlatform",
|
|
12
|
-
name: "平台图标",
|
|
13
|
-
icons: platformIcons.value
|
|
14
|
-
}];
|
|
15
|
-
});
|
|
16
|
-
var platformIcons = computed(() => {
|
|
17
|
-
return iconsNames.filter((e) => /^(icon-platform)/.test(e)).map((e) => {
|
|
18
|
-
const iconName = e.replace(/icon-/g, "");
|
|
19
|
-
return {
|
|
20
|
-
id: `${IconNamespaceEnum.Platform}:${iconName}`,
|
|
21
|
-
name: iconName,
|
|
22
|
-
_filter_: [iconName]
|
|
23
|
-
};
|
|
24
|
-
});
|
|
25
|
-
});
|
|
26
|
-
var medicalCareIcons = computed(() => {
|
|
27
|
-
return iconsNames.filter((e) => /^(icon-medicalCare)/.test(e)).map((e) => {
|
|
28
|
-
const iconName = e.replace(/icon-/g, "");
|
|
29
|
-
return {
|
|
30
|
-
id: `${IconNamespaceEnum.Platform}:${iconName}`,
|
|
31
|
-
name: e.replace(/icon-medicalCare-/g, ""),
|
|
32
|
-
_filter_: [iconName]
|
|
33
|
-
};
|
|
34
|
-
});
|
|
35
|
-
});
|
|
36
|
-
function useIconPlatform() {
|
|
37
|
-
function getIconPlatformCats() {
|
|
38
|
-
return iconPlatformCats.value;
|
|
39
|
-
}
|
|
40
|
-
return { getIconPlatformCats };
|
|
41
|
-
}
|
|
42
|
-
//#endregion
|
|
43
|
-
export { useIconPlatform };
|
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
|
|
2
|
-
value: {
|
|
3
|
-
type: (ObjectConstructor | StringConstructor)[];
|
|
4
|
-
required: true;
|
|
5
|
-
};
|
|
6
|
-
color: {
|
|
7
|
-
type: StringConstructor;
|
|
8
|
-
default: string;
|
|
9
|
-
};
|
|
10
|
-
background: {
|
|
11
|
-
type: StringConstructor;
|
|
12
|
-
default: string;
|
|
13
|
-
};
|
|
14
|
-
size: {
|
|
15
|
-
type: NumberConstructor;
|
|
16
|
-
default: number;
|
|
17
|
-
};
|
|
18
|
-
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
|
|
19
|
-
value: {
|
|
20
|
-
type: (ObjectConstructor | StringConstructor)[];
|
|
21
|
-
required: true;
|
|
22
|
-
};
|
|
23
|
-
color: {
|
|
24
|
-
type: StringConstructor;
|
|
25
|
-
default: string;
|
|
26
|
-
};
|
|
27
|
-
background: {
|
|
28
|
-
type: StringConstructor;
|
|
29
|
-
default: string;
|
|
30
|
-
};
|
|
31
|
-
size: {
|
|
32
|
-
type: NumberConstructor;
|
|
33
|
-
default: number;
|
|
34
|
-
};
|
|
35
|
-
}>> & Readonly<{}>, {
|
|
36
|
-
color: string;
|
|
37
|
-
background: string;
|
|
38
|
-
size: number;
|
|
39
|
-
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
40
|
-
export default _default;
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import _plugin_vue_export_helper_default from "../../../_virtual/_plugin-vue_export-helper.mjs";
|
|
2
|
-
import IconNext_vue_vue_type_script_setup_true_name_IconNext_lang_default from "./IconNext.vue_vue_type_script_setup_true_name_IconNext_lang.mjs";
|
|
3
|
-
import './IconNext.vue_vue_type_style_index_0_scoped_360a87c9_lang.css';/* empty css */
|
|
4
|
-
//#region src/components/icon-next/src/IconNext.vue
|
|
5
|
-
var IconNext_default = /* @__PURE__ */ _plugin_vue_export_helper_default(IconNext_vue_vue_type_script_setup_true_name_IconNext_lang_default, [["__scopeId", "data-v-360a87c9"]]);
|
|
6
|
-
//#endregion
|
|
7
|
-
export { IconNext_default as default };
|
package/es/components/icon-next/src/IconNext.vue_vue_type_script_setup_true_name_IconNext_lang.mjs
DELETED
|
@@ -1,113 +0,0 @@
|
|
|
1
|
-
import svg_icon_default from "../../svg-icon/svg-icon.vue.mjs";
|
|
2
|
-
import { IconNamespaceEnum } from "../types/index.mjs";
|
|
3
|
-
import { computed, createBlock, createElementBlock, defineComponent, normalizeClass, normalizeStyle, openBlock, unref } from "vue";
|
|
4
|
-
import { VITE_MINIO_PATH } from "@gct-paas/core";
|
|
5
|
-
import { IconPark } from "@icon-park/vue-next/es/all";
|
|
6
|
-
//#region src/components/icon-next/src/IconNext.vue?vue&type=script&setup=true&name=IconNext&lang.ts
|
|
7
|
-
var IconNext_vue_vue_type_script_setup_true_name_IconNext_lang_default = /* @__PURE__ */ defineComponent({
|
|
8
|
-
__name: "IconNext",
|
|
9
|
-
props: {
|
|
10
|
-
value: {
|
|
11
|
-
type: [String, Object],
|
|
12
|
-
required: true
|
|
13
|
-
},
|
|
14
|
-
color: {
|
|
15
|
-
type: String,
|
|
16
|
-
default: "#FFFFFF"
|
|
17
|
-
},
|
|
18
|
-
background: {
|
|
19
|
-
type: String,
|
|
20
|
-
default: "transparent"
|
|
21
|
-
},
|
|
22
|
-
size: {
|
|
23
|
-
type: Number,
|
|
24
|
-
default: 24
|
|
25
|
-
}
|
|
26
|
-
},
|
|
27
|
-
setup(__props) {
|
|
28
|
-
function fileUrlParser(url) {
|
|
29
|
-
if (!url) return url;
|
|
30
|
-
return `${VITE_MINIO_PATH}${url.startsWith("/") ? "" : "/"}${url}`;
|
|
31
|
-
}
|
|
32
|
-
const props = __props;
|
|
33
|
-
/**
|
|
34
|
-
* 图标命名空间
|
|
35
|
-
*/
|
|
36
|
-
const namespace = computed(() => {
|
|
37
|
-
const value = props.value;
|
|
38
|
-
if (!value) return void 0;
|
|
39
|
-
if (value.includes(":")) return value.split(":")[0];
|
|
40
|
-
else if (value.startsWith("preset-")) return IconNamespaceEnum.Preset;
|
|
41
|
-
});
|
|
42
|
-
/**
|
|
43
|
-
* 图标实际名称
|
|
44
|
-
*/
|
|
45
|
-
const iconName = computed(() => {
|
|
46
|
-
const value = props.value;
|
|
47
|
-
if (!value) return void 0;
|
|
48
|
-
if (value.includes(":")) return value.split(":")[1];
|
|
49
|
-
return props.value;
|
|
50
|
-
});
|
|
51
|
-
const iconBgImage = computed(() => {
|
|
52
|
-
return `url('${fileUrlParser(iconName.value)}')`;
|
|
53
|
-
});
|
|
54
|
-
return (_ctx, _cache) => {
|
|
55
|
-
return namespace.value === unref(IconNamespaceEnum).IconPark ? (openBlock(), createBlock(unref(IconPark), {
|
|
56
|
-
key: `${iconName.value}-${__props.size}`,
|
|
57
|
-
type: iconName.value,
|
|
58
|
-
style: normalizeStyle({
|
|
59
|
-
"--color": __props.color,
|
|
60
|
-
"--bg-color": __props.background
|
|
61
|
-
}),
|
|
62
|
-
class: "icon-next",
|
|
63
|
-
size: __props.size
|
|
64
|
-
}, null, 8, [
|
|
65
|
-
"type",
|
|
66
|
-
"style",
|
|
67
|
-
"size"
|
|
68
|
-
])) : namespace.value === unref(IconNamespaceEnum).Preset || namespace.value === unref(IconNamespaceEnum).Platform ? (openBlock(), createBlock(svg_icon_default, {
|
|
69
|
-
key: 1,
|
|
70
|
-
name: iconName.value,
|
|
71
|
-
style: normalizeStyle({
|
|
72
|
-
"--color": __props.color,
|
|
73
|
-
"--bg-color": __props.background
|
|
74
|
-
}),
|
|
75
|
-
class: "icon-next",
|
|
76
|
-
size: __props.size
|
|
77
|
-
}, null, 8, [
|
|
78
|
-
"name",
|
|
79
|
-
"style",
|
|
80
|
-
"size"
|
|
81
|
-
])) : namespace.value === unref(IconNamespaceEnum).Asset ? (openBlock(), createElementBlock("i", {
|
|
82
|
-
key: 2,
|
|
83
|
-
class: "icon-next",
|
|
84
|
-
style: normalizeStyle({
|
|
85
|
-
"--size": __props.size + "px",
|
|
86
|
-
"--bg-image": iconBgImage.value
|
|
87
|
-
})
|
|
88
|
-
}, null, 4)) : namespace.value === unref(IconNamespaceEnum).GctIconFont ? (openBlock(), createElementBlock("i", {
|
|
89
|
-
key: 3,
|
|
90
|
-
class: normalizeClass([`gct-iconfont ${iconName.value}`, "icon-next"]),
|
|
91
|
-
style: normalizeStyle({
|
|
92
|
-
fontSize: __props.size + "px",
|
|
93
|
-
lineHeight: 1,
|
|
94
|
-
"--color": __props.color,
|
|
95
|
-
"--bg-color": __props.background,
|
|
96
|
-
"--size": __props.size + "px"
|
|
97
|
-
})
|
|
98
|
-
}, null, 6)) : (openBlock(), createElementBlock("i", {
|
|
99
|
-
key: 4,
|
|
100
|
-
class: normalizeClass([`iconfont ${iconName.value}`, "icon-next"]),
|
|
101
|
-
style: normalizeStyle({
|
|
102
|
-
fontSize: __props.size + "px",
|
|
103
|
-
lineHeight: 1,
|
|
104
|
-
"--color": __props.color,
|
|
105
|
-
"--bg-color": __props.background,
|
|
106
|
-
"--size": __props.size + "px"
|
|
107
|
-
})
|
|
108
|
-
}, null, 6));
|
|
109
|
-
};
|
|
110
|
-
}
|
|
111
|
-
});
|
|
112
|
-
//#endregion
|
|
113
|
-
export { IconNext_vue_vue_type_script_setup_true_name_IconNext_lang_default as default };
|
package/es/components/icon-next/src/IconNext.vue_vue_type_style_index_0_scoped_360a87c9_lang.css
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
.icon-next[data-v-360a87c9] {
|
|
2
|
-
display: inline-flex;
|
|
3
|
-
align-items: center;
|
|
4
|
-
color: var(--color);
|
|
5
|
-
background-color: var(--bg-color);
|
|
6
|
-
transition: all 0.3s;
|
|
7
|
-
}
|
|
8
|
-
.icon-next > svg[data-v-360a87c9] {
|
|
9
|
-
transform: translateY(1px);
|
|
10
|
-
}
|
|
11
|
-
i.icon-next[data-v-360a87c9] {
|
|
12
|
-
height: var(--size);
|
|
13
|
-
width: var(--size);
|
|
14
|
-
background-image: var(--bg-image);
|
|
15
|
-
background-size: contain;
|
|
16
|
-
background-position: center;
|
|
17
|
-
background-repeat: no-repeat;
|
|
18
|
-
}
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import IconNextPicker_vue_vue_type_script_setup_true_name_IconNextPicker_lang_default from "./IconNextPicker.vue_vue_type_script_setup_true_name_IconNextPicker_lang.mjs";
|
|
2
|
-
import './IconNextPicker.vue_vue_type_style_index_0_lang.css';/* empty css */
|
|
3
|
-
//#region src/components/icon-next/src/IconNextPicker.vue
|
|
4
|
-
var IconNextPicker_default = IconNextPicker_vue_vue_type_script_setup_true_name_IconNextPicker_lang_default;
|
|
5
|
-
//#endregion
|
|
6
|
-
export { IconNextPicker_default as default };
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
export interface ICategory {
|
|
2
|
-
id: string;
|
|
3
|
-
name: string;
|
|
4
|
-
icons?: {
|
|
5
|
-
id: string;
|
|
6
|
-
name: string;
|
|
7
|
-
_filter_: string[];
|
|
8
|
-
}[];
|
|
9
|
-
children?: ICategory[];
|
|
10
|
-
}
|
|
11
|
-
export declare enum IconNamespaceEnum {
|
|
12
|
-
Preset = "icon-preset",
|
|
13
|
-
IconPark = "icon-park",
|
|
14
|
-
Asset = "icon-assert",
|
|
15
|
-
Platform = "icon-platform",
|
|
16
|
-
GctIconFont = "gct-iconfont"
|
|
17
|
-
}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
//#region src/components/icon-next/types/index.ts
|
|
2
|
-
var IconNamespaceEnum = /* @__PURE__ */ function(IconNamespaceEnum) {
|
|
3
|
-
IconNamespaceEnum["Preset"] = "icon-preset";
|
|
4
|
-
IconNamespaceEnum["IconPark"] = "icon-park";
|
|
5
|
-
IconNamespaceEnum["Asset"] = "icon-assert";
|
|
6
|
-
IconNamespaceEnum["Platform"] = "icon-platform";
|
|
7
|
-
IconNamespaceEnum["GctIconFont"] = "gct-iconfont";
|
|
8
|
-
return IconNamespaceEnum;
|
|
9
|
-
}({});
|
|
10
|
-
//#endregion
|
|
11
|
-
export { IconNamespaceEnum };
|
|
@@ -1,40 +0,0 @@
|
|
|
1
|
-
declare const _default: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
|
|
2
|
-
prefix: {
|
|
3
|
-
type: StringConstructor;
|
|
4
|
-
default: string;
|
|
5
|
-
};
|
|
6
|
-
name: {
|
|
7
|
-
type: StringConstructor;
|
|
8
|
-
required: true;
|
|
9
|
-
};
|
|
10
|
-
size: {
|
|
11
|
-
type: (NumberConstructor | StringConstructor)[];
|
|
12
|
-
default: number;
|
|
13
|
-
};
|
|
14
|
-
spin: {
|
|
15
|
-
type: BooleanConstructor;
|
|
16
|
-
default: boolean;
|
|
17
|
-
};
|
|
18
|
-
}>, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
|
|
19
|
-
prefix: {
|
|
20
|
-
type: StringConstructor;
|
|
21
|
-
default: string;
|
|
22
|
-
};
|
|
23
|
-
name: {
|
|
24
|
-
type: StringConstructor;
|
|
25
|
-
required: true;
|
|
26
|
-
};
|
|
27
|
-
size: {
|
|
28
|
-
type: (NumberConstructor | StringConstructor)[];
|
|
29
|
-
default: number;
|
|
30
|
-
};
|
|
31
|
-
spin: {
|
|
32
|
-
type: BooleanConstructor;
|
|
33
|
-
default: boolean;
|
|
34
|
-
};
|
|
35
|
-
}>> & Readonly<{}>, {
|
|
36
|
-
prefix: string;
|
|
37
|
-
size: string | number;
|
|
38
|
-
spin: boolean;
|
|
39
|
-
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, SVGSVGElement>;
|
|
40
|
-
export default _default;
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import svg_icon_vue_vue_type_script_setup_true_name_SvgIcon_lang_default from "./svg-icon.vue_vue_type_script_setup_true_name_SvgIcon_lang.mjs";
|
|
2
|
-
import './svg-icon.vue_vue_type_style_index_0_lang.css';/* empty css */
|
|
3
|
-
//#region src/components/svg-icon/svg-icon.vue
|
|
4
|
-
var svg_icon_default = svg_icon_vue_vue_type_script_setup_true_name_SvgIcon_lang_default;
|
|
5
|
-
//#endregion
|
|
6
|
-
export { svg_icon_default as default };
|
package/es/components/svg-icon/svg-icon.vue_vue_type_script_setup_true_name_SvgIcon_lang.mjs
DELETED
|
@@ -1,52 +0,0 @@
|
|
|
1
|
-
import { computed, createElementBlock, createElementVNode, defineComponent, normalizeClass, normalizeStyle, openBlock, unref } from "vue";
|
|
2
|
-
import { useNamespace } from "@gct-paas/core";
|
|
3
|
-
//#region src/components/svg-icon/svg-icon.vue?vue&type=script&setup=true&name=SvgIcon&lang.ts
|
|
4
|
-
var _hoisted_1 = ["xlink:href"];
|
|
5
|
-
var svg_icon_vue_vue_type_script_setup_true_name_SvgIcon_lang_default = /* @__PURE__ */ defineComponent({
|
|
6
|
-
__name: "svg-icon",
|
|
7
|
-
props: {
|
|
8
|
-
prefix: {
|
|
9
|
-
type: String,
|
|
10
|
-
default: "icon"
|
|
11
|
-
},
|
|
12
|
-
name: {
|
|
13
|
-
type: String,
|
|
14
|
-
required: true
|
|
15
|
-
},
|
|
16
|
-
size: {
|
|
17
|
-
type: [Number, String],
|
|
18
|
-
default: 16
|
|
19
|
-
},
|
|
20
|
-
spin: {
|
|
21
|
-
type: Boolean,
|
|
22
|
-
default: false
|
|
23
|
-
}
|
|
24
|
-
},
|
|
25
|
-
setup(__props) {
|
|
26
|
-
const ns = useNamespace("svg-icon");
|
|
27
|
-
const props = __props;
|
|
28
|
-
const symbolId = computed(() => `#${props.prefix}-${props.name}`);
|
|
29
|
-
const getStyle = computed(() => {
|
|
30
|
-
const { size } = props;
|
|
31
|
-
let s = `${size}`;
|
|
32
|
-
s = `${s.replace("px", "")}px`;
|
|
33
|
-
return {
|
|
34
|
-
width: s,
|
|
35
|
-
height: s
|
|
36
|
-
};
|
|
37
|
-
});
|
|
38
|
-
return (_ctx, _cache) => {
|
|
39
|
-
return openBlock(), createElementBlock("svg", {
|
|
40
|
-
class: normalizeClass([
|
|
41
|
-
_ctx.$attrs.class,
|
|
42
|
-
unref(ns).b(),
|
|
43
|
-
__props.spin && unref(ns).m("spin")
|
|
44
|
-
]),
|
|
45
|
-
style: normalizeStyle(getStyle.value),
|
|
46
|
-
"aria-hidden": "true"
|
|
47
|
-
}, [createElementVNode("use", { "xlink:href": symbolId.value }, null, 8, _hoisted_1)], 6);
|
|
48
|
-
};
|
|
49
|
-
}
|
|
50
|
-
});
|
|
51
|
-
//#endregion
|
|
52
|
-
export { svg_icon_vue_vue_type_script_setup_true_name_SvgIcon_lang_default as default };
|