@gct-paas/core-components 0.1.5-dev.4
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/CHANGELOG.md +14 -0
- package/LICENSE +21 -0
- package/README.md +1 -0
- package/dist/IconNext-Cz0XmLgr.js +1 -0
- package/dist/index.min.css +2 -0
- package/dist/loader.esm.min.js +1 -0
- package/dist/types-Ct3W9C4R.js +1 -0
- package/es/_virtual/_plugin-vue_export-helper.mjs +8 -0
- package/es/assets-svg-icon/assets-svg-icon.css +188 -0
- package/es/assets-svg-icon/assets-svg-icon.d.ts +134 -0
- package/es/assets-svg-icon/assets-svg-icon.mjs +167 -0
- package/es/assets-svg-icon/request.d.ts +2 -0
- package/es/assets-svg-icon/request.mjs +68 -0
- package/es/assets-svg-icon/utils.d.ts +9 -0
- package/es/assets-svg-icon/utils.mjs +23 -0
- package/es/assets-svg-icon/validate.d.ts +4 -0
- package/es/assets-svg-icon/validate.mjs +29 -0
- package/es/icon-next/data/icons.data.d.ts +5 -0
- package/es/icon-next/hooks/useIconAsset.d.ts +16 -0
- package/es/icon-next/hooks/useIconAsset.mjs +36 -0
- package/es/icon-next/hooks/useIconPark.d.ts +16 -0
- package/es/icon-next/hooks/useIconPark.mjs +52 -0
- package/es/icon-next/hooks/useIconPlatform.d.ts +8 -0
- package/es/icon-next/hooks/useIconPlatform.mjs +43 -0
- package/es/icon-next/index.d.ts +43 -0
- package/es/icon-next/index.mjs +10 -0
- package/es/icon-next/src/IconNext.vue.d.ts +40 -0
- package/es/icon-next/src/IconNext.vue.mjs +7 -0
- package/es/icon-next/src/IconNext.vue_vue_type_script_setup_true_name_IconNext_lang.mjs +113 -0
- package/es/icon-next/src/IconNext.vue_vue_type_style_index_0_scoped_0940cc40_lang.css +18 -0
- package/es/icon-next/types/index.d.ts +17 -0
- package/es/icon-next/types/index.mjs +11 -0
- package/es/index.d.ts +10 -0
- package/es/index.mjs +17 -0
- package/es/loader.d.ts +2 -0
- package/es/svg-icon/svg-icon.vue.d.ts +40 -0
- package/es/svg-icon/svg-icon.vue.mjs +6 -0
- package/es/svg-icon/svg-icon.vue_vue_type_script_setup_true_name_SvgIcon_lang.mjs +52 -0
- package/es/svg-icon/svg-icon.vue_vue_type_style_index_0_lang.css +73 -0
- package/es/types/index.d.ts +1 -0
- package/es/wujie-container/wujie-container.css +74 -0
- package/es/wujie-container/wujie-container.d.ts +11 -0
- package/es/wujie-container/wujie-container.mjs +61 -0
- package/package.json +68 -0
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
@charset "UTF-8";
|
|
2
|
+
/* stylelint-disable scss/no-global-function-names */
|
|
3
|
+
/* bem('block', 'element', 'modifier') => 'ibiz-block__element--modifier' */
|
|
4
|
+
/**
|
|
5
|
+
* 定义 Block 块
|
|
6
|
+
* @param {String} $block - Block 块名称
|
|
7
|
+
* @example
|
|
8
|
+
* @include b('button') {
|
|
9
|
+
* padding: 10px;
|
|
10
|
+
* }
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* 定义 Element 元素
|
|
14
|
+
* @param {String|List} $element - Element 元素名称,支持单个或多个
|
|
15
|
+
* @example
|
|
16
|
+
* @include b('button') {
|
|
17
|
+
* @include e('text') {
|
|
18
|
+
* color: #000;
|
|
19
|
+
* }
|
|
20
|
+
* }
|
|
21
|
+
* // 或传入多个元素
|
|
22
|
+
* @include b('button') {
|
|
23
|
+
* @include e(('text', 'icon')) {
|
|
24
|
+
* margin: 5px;
|
|
25
|
+
* }
|
|
26
|
+
* }
|
|
27
|
+
*/
|
|
28
|
+
/**
|
|
29
|
+
* 定义 Modifier 修饰符
|
|
30
|
+
* @param {String|List} $modifier - Modifier 修饰符名称,支持单个或多个
|
|
31
|
+
* @example
|
|
32
|
+
* @include b('button') {
|
|
33
|
+
* @include m('primary') {
|
|
34
|
+
* background: blue;
|
|
35
|
+
* }
|
|
36
|
+
* }
|
|
37
|
+
* // 或传入多个修饰符
|
|
38
|
+
* @include b('button') {
|
|
39
|
+
* @include m(('primary', 'large')) {
|
|
40
|
+
* background: blue;
|
|
41
|
+
* font-size: 16px;
|
|
42
|
+
* }
|
|
43
|
+
* }
|
|
44
|
+
*/
|
|
45
|
+
/**
|
|
46
|
+
* 定义状态选择器
|
|
47
|
+
* @param {String} $state - 状态名称
|
|
48
|
+
* @example
|
|
49
|
+
* @include b('button') {
|
|
50
|
+
* @include when('disabled') {
|
|
51
|
+
* opacity: 0.5;
|
|
52
|
+
* }
|
|
53
|
+
* }
|
|
54
|
+
*/
|
|
55
|
+
/**
|
|
56
|
+
* 深色主题样式
|
|
57
|
+
* @param {String} $block - Block 块名称
|
|
58
|
+
* @example
|
|
59
|
+
* @include dark('button') {
|
|
60
|
+
* background: #333;
|
|
61
|
+
* color: #fff;
|
|
62
|
+
* }
|
|
63
|
+
*/
|
|
64
|
+
/* stylelint-disable scss/no-global-function-names */
|
|
65
|
+
.gct-svg-icon {
|
|
66
|
+
display: inline-block;
|
|
67
|
+
overflow: hidden;
|
|
68
|
+
fill: currentcolor;
|
|
69
|
+
vertical-align: -0.15em;
|
|
70
|
+
}
|
|
71
|
+
.gct-svg-icon--spin {
|
|
72
|
+
animation: loadingCircle 1s infinite linear;
|
|
73
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import '@gct-paas/core/types';
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
@charset "UTF-8";
|
|
2
|
+
/* stylelint-disable scss/no-global-function-names */
|
|
3
|
+
/* bem('block', 'element', 'modifier') => 'ibiz-block__element--modifier' */
|
|
4
|
+
/**
|
|
5
|
+
* 定义 Block 块
|
|
6
|
+
* @param {String} $block - Block 块名称
|
|
7
|
+
* @example
|
|
8
|
+
* @include b('button') {
|
|
9
|
+
* padding: 10px;
|
|
10
|
+
* }
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
* 定义 Element 元素
|
|
14
|
+
* @param {String|List} $element - Element 元素名称,支持单个或多个
|
|
15
|
+
* @example
|
|
16
|
+
* @include b('button') {
|
|
17
|
+
* @include e('text') {
|
|
18
|
+
* color: #000;
|
|
19
|
+
* }
|
|
20
|
+
* }
|
|
21
|
+
* // 或传入多个元素
|
|
22
|
+
* @include b('button') {
|
|
23
|
+
* @include e(('text', 'icon')) {
|
|
24
|
+
* margin: 5px;
|
|
25
|
+
* }
|
|
26
|
+
* }
|
|
27
|
+
*/
|
|
28
|
+
/**
|
|
29
|
+
* 定义 Modifier 修饰符
|
|
30
|
+
* @param {String|List} $modifier - Modifier 修饰符名称,支持单个或多个
|
|
31
|
+
* @example
|
|
32
|
+
* @include b('button') {
|
|
33
|
+
* @include m('primary') {
|
|
34
|
+
* background: blue;
|
|
35
|
+
* }
|
|
36
|
+
* }
|
|
37
|
+
* // 或传入多个修饰符
|
|
38
|
+
* @include b('button') {
|
|
39
|
+
* @include m(('primary', 'large')) {
|
|
40
|
+
* background: blue;
|
|
41
|
+
* font-size: 16px;
|
|
42
|
+
* }
|
|
43
|
+
* }
|
|
44
|
+
*/
|
|
45
|
+
/**
|
|
46
|
+
* 定义状态选择器
|
|
47
|
+
* @param {String} $state - 状态名称
|
|
48
|
+
* @example
|
|
49
|
+
* @include b('button') {
|
|
50
|
+
* @include when('disabled') {
|
|
51
|
+
* opacity: 0.5;
|
|
52
|
+
* }
|
|
53
|
+
* }
|
|
54
|
+
*/
|
|
55
|
+
/**
|
|
56
|
+
* 深色主题样式
|
|
57
|
+
* @param {String} $block - Block 块名称
|
|
58
|
+
* @example
|
|
59
|
+
* @include dark('button') {
|
|
60
|
+
* background: #333;
|
|
61
|
+
* color: #fff;
|
|
62
|
+
* }
|
|
63
|
+
*/
|
|
64
|
+
/* stylelint-disable scss/no-global-function-names */
|
|
65
|
+
.gct-wujie-container {
|
|
66
|
+
width: 100%;
|
|
67
|
+
height: 100%;
|
|
68
|
+
}
|
|
69
|
+
.gct-wujie-container .__vue-devtools-container__ {
|
|
70
|
+
display: none;
|
|
71
|
+
}
|
|
72
|
+
.gct-wujie-container iframe {
|
|
73
|
+
border: 0;
|
|
74
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export declare const WuJieContainer: import('vue').DefineComponent<import('vue').ExtractPropTypes<{
|
|
2
|
+
wuJieName: {
|
|
3
|
+
type: StringConstructor;
|
|
4
|
+
required: true;
|
|
5
|
+
};
|
|
6
|
+
}>, () => import("vue/jsx-runtime").JSX.Element, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
|
|
7
|
+
wuJieName: {
|
|
8
|
+
type: StringConstructor;
|
|
9
|
+
required: true;
|
|
10
|
+
};
|
|
11
|
+
}>> & Readonly<{}>, {}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import './wujie-container.css';/* empty css */
|
|
2
|
+
import { computed, createVNode, defineComponent, mergeProps, onUnmounted, resolveComponent, useAttrs } from "vue";
|
|
3
|
+
import { getToken, useNamespace, useUserStore } from "@gct-paas/core";
|
|
4
|
+
import WujieVue3 from "wujie-vue3";
|
|
5
|
+
//#region src/wujie-container/wujie-container.tsx
|
|
6
|
+
var { destroyApp } = WujieVue3;
|
|
7
|
+
var WuJieContainer = /* @__PURE__ */ defineComponent({
|
|
8
|
+
name: "WuJieContainer",
|
|
9
|
+
props: { wuJieName: {
|
|
10
|
+
type: String,
|
|
11
|
+
required: true
|
|
12
|
+
} },
|
|
13
|
+
setup(props) {
|
|
14
|
+
const ns = useNamespace("wujie-container");
|
|
15
|
+
const attr = useAttrs();
|
|
16
|
+
function beforeLoad(win) {
|
|
17
|
+
Object.defineProperty(win, "pSystem", { get: () => {
|
|
18
|
+
return window.System;
|
|
19
|
+
} });
|
|
20
|
+
Object.defineProperty(win, "_gct", { get: () => {
|
|
21
|
+
return window._gct;
|
|
22
|
+
} });
|
|
23
|
+
Object.defineProperty(win, "_api", { get: () => {
|
|
24
|
+
return window._api;
|
|
25
|
+
} });
|
|
26
|
+
}
|
|
27
|
+
function beforeMount(win) {
|
|
28
|
+
console.debug("beforeMount System", win.System);
|
|
29
|
+
console.debug("beforeMount _gct", win._gct);
|
|
30
|
+
console.debug("beforeMount _api", win._api);
|
|
31
|
+
}
|
|
32
|
+
function loadError(win) {
|
|
33
|
+
console.debug("loadError", win.System);
|
|
34
|
+
}
|
|
35
|
+
const { userInfo } = useUserStore();
|
|
36
|
+
const token = getToken();
|
|
37
|
+
const _props = computed(() => {
|
|
38
|
+
return {
|
|
39
|
+
appInfo: _gct.store.appInfo,
|
|
40
|
+
userInfo,
|
|
41
|
+
token,
|
|
42
|
+
...attr.props ?? {}
|
|
43
|
+
};
|
|
44
|
+
});
|
|
45
|
+
onUnmounted(() => {
|
|
46
|
+
if (attr.alive === true) return;
|
|
47
|
+
destroyApp(props.wuJieName);
|
|
48
|
+
});
|
|
49
|
+
return () => {
|
|
50
|
+
return createVNode(resolveComponent("wujieVue"), mergeProps({
|
|
51
|
+
"class": ns.b(),
|
|
52
|
+
"name": props.wuJieName,
|
|
53
|
+
"beforeLoad": beforeLoad,
|
|
54
|
+
"beforeMount": beforeMount,
|
|
55
|
+
"loadError": loadError
|
|
56
|
+
}, attr, { "props": _props.value }), null);
|
|
57
|
+
};
|
|
58
|
+
}
|
|
59
|
+
});
|
|
60
|
+
//#endregion
|
|
61
|
+
export { WuJieContainer };
|
package/package.json
ADDED
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@gct-paas/core-components",
|
|
3
|
+
"version": "0.1.5-dev.4",
|
|
4
|
+
"type": "module",
|
|
5
|
+
"description": "paas 平台核心组件包,不区分Web、Mobile、Pad等平台,包含一些基础组件",
|
|
6
|
+
"loader": "dist/loader.esm.min.js",
|
|
7
|
+
"types": "es/index.d.ts",
|
|
8
|
+
"exports": {
|
|
9
|
+
".": {
|
|
10
|
+
"types": "./es/index.d.ts",
|
|
11
|
+
"import": "./es/index.mjs"
|
|
12
|
+
},
|
|
13
|
+
"./types": {
|
|
14
|
+
"types": "./es/types/index.d.ts"
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
"files": [
|
|
18
|
+
"dist",
|
|
19
|
+
"es",
|
|
20
|
+
"CHANGELOG.md",
|
|
21
|
+
"README.md"
|
|
22
|
+
],
|
|
23
|
+
"keywords": [
|
|
24
|
+
"paas",
|
|
25
|
+
"gct"
|
|
26
|
+
],
|
|
27
|
+
"repository": {
|
|
28
|
+
"type": "git",
|
|
29
|
+
"url": "https://git.gct-china.com/paas/frontend/paas-package.git"
|
|
30
|
+
},
|
|
31
|
+
"license": "MIT",
|
|
32
|
+
"author": "gct",
|
|
33
|
+
"scripts": {
|
|
34
|
+
"dev": "cross-env NODE_ENV=development vite build --watch --config vite.dev.config.ts",
|
|
35
|
+
"es:build": "vite build --config vite.dev.config.ts",
|
|
36
|
+
"build": "npm run lint && vue-tsc --noEmit && vite build --config vite.dev.config.ts && vite build --config vite.config.ts",
|
|
37
|
+
"lint": "eslint src/",
|
|
38
|
+
"publish:next": "npm run build && npm publish --access public --tag=next --registry=https://registry.npmjs.org/",
|
|
39
|
+
"publish:dev": "npm run build && npm publish --access public --tag=dev --registry=https://registry.npmjs.org/",
|
|
40
|
+
"publish:alpha": "npm run build && npm publish --access public --tag=alpha --registry=https://registry.npmjs.org/",
|
|
41
|
+
"publish:beta": "npm run build && npm publish --access public --tag=beta --registry=https://registry.npmjs.org/",
|
|
42
|
+
"publish:npm": "npm run build && npm publish --access public --registry=https://registry.npmjs.org/",
|
|
43
|
+
"gen-api": "npm run gen-api:apaas && npm run gen-api:platform",
|
|
44
|
+
"gen-api:apaas": "gct-paas gen-api --url=http://paas.paasdev.gct-paas.com --tag=apaas -t ../cli/hbs-temp -o ./src/service/gct-apaas && prettier './src/service/gct-apaas' --write",
|
|
45
|
+
"gen-api:platform": "gct-paas gen-api --url=http://paas.paasdev.gct-paas.com --tag=platform -t ../cli/hbs-temp -o ./src/service/gct-platform && prettier './src/service/gct-platform' --write"
|
|
46
|
+
},
|
|
47
|
+
"dependencies": {
|
|
48
|
+
"@ant-design/icons-vue": "^6.1.0",
|
|
49
|
+
"@gct-paas/api": "catalog:",
|
|
50
|
+
"@gct-paas/core": "workspace:*",
|
|
51
|
+
"@gct-paas/platform-icons": "^0.0.2",
|
|
52
|
+
"@gct-paas/scss": "workspace:*",
|
|
53
|
+
"@icon-park/vue-next": "^1.4.2",
|
|
54
|
+
"@vueuse/core": "^14.1.0",
|
|
55
|
+
"dayjs": "^1.11.19",
|
|
56
|
+
"lodash-es": "^4.17.23",
|
|
57
|
+
"vue": "^3.5.30",
|
|
58
|
+
"wujie": "^1.0.29",
|
|
59
|
+
"wujie-vue3": "^1.0.29"
|
|
60
|
+
},
|
|
61
|
+
"peerDependencies": {
|
|
62
|
+
"@gct-paas/api": "catalog:",
|
|
63
|
+
"@gct-paas/core": "workspace:*",
|
|
64
|
+
"@gct-paas/scss": "workspace:*",
|
|
65
|
+
"vant": ">=4",
|
|
66
|
+
"vue": ">=3"
|
|
67
|
+
}
|
|
68
|
+
}
|