@ibiz-template/vue3-util 0.7.41-alpha.111 → 0.7.41-alpha.113
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/index.min.css +1 -1
- package/dist/index.system.min.js +1 -1
- package/es/control/panel/view-layout-panel/view-layout-panel.d.ts.map +1 -1
- package/es/control/panel/view-layout-panel/view-layout-panel.mjs +8 -3
- package/es/panel-component/auth-wxmp-qrcode/auth-wxmp-qrcode.css +1 -1
- package/es/panel-component/auth-wxmp-qrcode/auth-wxmp-qrcode.d.ts +2 -0
- package/es/panel-component/auth-wxmp-qrcode/auth-wxmp-qrcode.d.ts.map +1 -1
- package/es/panel-component/auth-wxmp-qrcode/auth-wxmp-qrcode.mjs +16 -5
- package/es/panel-component/auth-wxmp-qrcode/index.d.ts +2 -0
- package/es/panel-component/auth-wxmp-qrcode/index.d.ts.map +1 -1
- package/es/panel-component/grid-container/grid-container.d.ts +2 -0
- package/es/panel-component/grid-container/grid-container.d.ts.map +1 -1
- package/es/panel-component/grid-container/grid-container.mjs +12 -2
- package/es/panel-component/grid-container/index.d.ts +2 -0
- package/es/panel-component/grid-container/index.d.ts.map +1 -1
- package/es/panel-component/multi-data-container/index.d.ts +2 -0
- package/es/panel-component/multi-data-container/index.d.ts.map +1 -1
- package/es/panel-component/multi-data-container/multi-data-container.d.ts +2 -0
- package/es/panel-component/multi-data-container/multi-data-container.d.ts.map +1 -1
- package/es/panel-component/multi-data-container/multi-data-container.mjs +16 -3
- package/es/panel-component/multi-data-container-raw/index.d.ts +2 -0
- package/es/panel-component/multi-data-container-raw/index.d.ts.map +1 -1
- package/es/panel-component/multi-data-container-raw/multi-data-container-raw.d.ts +2 -0
- package/es/panel-component/multi-data-container-raw/multi-data-container-raw.d.ts.map +1 -1
- package/es/panel-component/multi-data-container-raw/multi-data-container-raw.mjs +19 -4
- package/es/panel-component/nav-pos/index.d.ts +2 -0
- package/es/panel-component/nav-pos/index.d.ts.map +1 -1
- package/es/panel-component/nav-pos/nav-pos.d.ts +2 -0
- package/es/panel-component/nav-pos/nav-pos.d.ts.map +1 -1
- package/es/panel-component/nav-pos/nav-pos.mjs +18 -3
- package/es/panel-component/panel-container/index.d.ts +2 -0
- package/es/panel-component/panel-container/index.d.ts.map +1 -1
- package/es/panel-component/panel-container/panel-container.d.ts +2 -0
- package/es/panel-component/panel-container/panel-container.d.ts.map +1 -1
- package/es/panel-component/panel-container/panel-container.mjs +23 -5
- package/es/panel-component/panel-container-image/index.d.ts +2 -0
- package/es/panel-component/panel-container-image/index.d.ts.map +1 -1
- package/es/panel-component/panel-container-image/panel-container-image.d.ts +2 -0
- package/es/panel-component/panel-container-image/panel-container-image.d.ts.map +1 -1
- package/es/panel-component/panel-container-image/panel-container-image.mjs +19 -4
- package/es/panel-component/panel-ctrl-pos/index.d.ts +2 -0
- package/es/panel-component/panel-ctrl-pos/index.d.ts.map +1 -1
- package/es/panel-component/panel-ctrl-pos/panel-ctrl-pos.d.ts +2 -0
- package/es/panel-component/panel-ctrl-pos/panel-ctrl-pos.d.ts.map +1 -1
- package/es/panel-component/panel-ctrl-pos/panel-ctrl-pos.mjs +16 -4
- package/es/panel-component/panel-ctrl-view-page-caption/index.d.ts +2 -0
- package/es/panel-component/panel-ctrl-view-page-caption/index.d.ts.map +1 -1
- package/es/panel-component/panel-ctrl-view-page-caption/panel-ctrl-view-page-caption.d.ts +2 -0
- package/es/panel-component/panel-ctrl-view-page-caption/panel-ctrl-view-page-caption.d.ts.map +1 -1
- package/es/panel-component/panel-ctrl-view-page-caption/panel-ctrl-view-page-caption.mjs +12 -3
- package/es/panel-component/panel-field/index.d.ts +2 -0
- package/es/panel-component/panel-field/index.d.ts.map +1 -1
- package/es/panel-component/panel-field/panel-field.d.ts +2 -0
- package/es/panel-component/panel-field/panel-field.d.ts.map +1 -1
- package/es/panel-component/panel-field/panel-field.mjs +14 -5
- package/es/panel-component/panel-item-render/index.d.ts +2 -0
- package/es/panel-component/panel-item-render/index.d.ts.map +1 -1
- package/es/panel-component/panel-item-render/panel-item-render.d.ts +2 -0
- package/es/panel-component/panel-item-render/panel-item-render.d.ts.map +1 -1
- package/es/panel-component/panel-item-render/panel-item-render.mjs +10 -2
- package/es/panel-component/panel-rawitem/index.d.ts +2 -0
- package/es/panel-component/panel-rawitem/index.d.ts.map +1 -1
- package/es/panel-component/panel-rawitem/panel-rawitem.d.ts +2 -0
- package/es/panel-component/panel-rawitem/panel-rawitem.d.ts.map +1 -1
- package/es/panel-component/panel-rawitem/panel-rawitem.mjs +12 -4
- package/es/panel-component/panel-tab-page/index.d.ts +2 -0
- package/es/panel-component/panel-tab-page/index.d.ts.map +1 -1
- package/es/panel-component/panel-tab-page/panel-tab-page.d.ts +2 -0
- package/es/panel-component/panel-tab-page/panel-tab-page.d.ts.map +1 -1
- package/es/panel-component/panel-tab-page/panel-tab-page.mjs +16 -2
- package/es/panel-component/scroll-container/index.d.ts +2 -0
- package/es/panel-component/scroll-container/index.d.ts.map +1 -1
- package/es/panel-component/scroll-container/scroll-container/scroll-container.d.ts +2 -0
- package/es/panel-component/scroll-container/scroll-container/scroll-container.d.ts.map +1 -1
- package/es/panel-component/scroll-container/scroll-container/scroll-container.mjs +22 -12
- package/es/panel-component/scroll-container/scroll-container-item/scroll-container-item.d.ts +2 -0
- package/es/panel-component/scroll-container/scroll-container-item/scroll-container-item.d.ts.map +1 -1
- package/es/panel-component/scroll-container/scroll-container-item/scroll-container-item.mjs +16 -2
- package/es/panel-component/single-data-container/index.d.ts +2 -0
- package/es/panel-component/single-data-container/index.d.ts.map +1 -1
- package/es/panel-component/single-data-container/single-data-container.d.ts +2 -0
- package/es/panel-component/single-data-container/single-data-container.d.ts.map +1 -1
- package/es/panel-component/single-data-container/single-data-container.mjs +18 -3
- package/es/panel-component/teleport-placeholder/index.d.ts +2 -0
- package/es/panel-component/teleport-placeholder/index.d.ts.map +1 -1
- package/es/panel-component/teleport-placeholder/teleport-placeholder.d.ts +2 -0
- package/es/panel-component/teleport-placeholder/teleport-placeholder.d.ts.map +1 -1
- package/es/panel-component/teleport-placeholder/teleport-placeholder.mjs +10 -3
- package/es/use/use-semantic-node/use-semantic-node.d.ts +2 -2
- package/es/use/use-semantic-node/use-semantic-node.d.ts.map +1 -1
- package/es/use/use-semantic-node/use-semantic-node.mjs +12 -2
- package/lib/control/panel/view-layout-panel/view-layout-panel.cjs +8 -3
- package/lib/panel-component/auth-wxmp-qrcode/auth-wxmp-qrcode.cjs +16 -5
- package/lib/panel-component/auth-wxmp-qrcode/auth-wxmp-qrcode.css +1 -1
- package/lib/panel-component/grid-container/grid-container.cjs +12 -2
- package/lib/panel-component/multi-data-container/multi-data-container.cjs +16 -3
- package/lib/panel-component/multi-data-container-raw/multi-data-container-raw.cjs +19 -4
- package/lib/panel-component/nav-pos/nav-pos.cjs +18 -3
- package/lib/panel-component/panel-container/panel-container.cjs +23 -5
- package/lib/panel-component/panel-container-image/panel-container-image.cjs +19 -4
- package/lib/panel-component/panel-ctrl-pos/panel-ctrl-pos.cjs +16 -4
- package/lib/panel-component/panel-ctrl-view-page-caption/panel-ctrl-view-page-caption.cjs +12 -3
- package/lib/panel-component/panel-field/panel-field.cjs +14 -5
- package/lib/panel-component/panel-item-render/panel-item-render.cjs +10 -2
- package/lib/panel-component/panel-rawitem/panel-rawitem.cjs +12 -4
- package/lib/panel-component/panel-tab-page/panel-tab-page.cjs +16 -2
- package/lib/panel-component/scroll-container/scroll-container/scroll-container.cjs +22 -12
- package/lib/panel-component/scroll-container/scroll-container-item/scroll-container-item.cjs +16 -2
- package/lib/panel-component/single-data-container/single-data-container.cjs +18 -3
- package/lib/panel-component/teleport-placeholder/teleport-placeholder.cjs +10 -3
- package/lib/use/use-semantic-node/use-semantic-node.cjs +12 -2
- package/package.json +6 -6
- package/src/control/panel/view-layout-panel/view-layout-panel.tsx +8 -2
- package/src/panel-component/auth-wxmp-qrcode/auth-wxmp-qrcode.scss +2 -0
- package/src/panel-component/auth-wxmp-qrcode/auth-wxmp-qrcode.tsx +19 -6
- package/src/panel-component/grid-container/grid-container.tsx +8 -2
- package/src/panel-component/multi-data-container/multi-data-container.tsx +13 -4
- package/src/panel-component/multi-data-container-raw/multi-data-container-raw.tsx +12 -4
- package/src/panel-component/nav-pos/nav-pos.tsx +16 -3
- package/src/panel-component/panel-container/panel-container.tsx +20 -6
- package/src/panel-component/panel-container-image/panel-container-image.tsx +13 -5
- package/src/panel-component/panel-ctrl-pos/panel-ctrl-pos.tsx +11 -4
- package/src/panel-component/panel-ctrl-view-page-caption/panel-ctrl-view-page-caption.tsx +10 -3
- package/src/panel-component/panel-field/panel-field.tsx +26 -5
- package/src/panel-component/panel-item-render/panel-item-render.tsx +5 -3
- package/src/panel-component/panel-rawitem/panel-rawitem.tsx +25 -4
- package/src/panel-component/panel-tab-page/panel-tab-page.tsx +18 -3
- package/src/panel-component/scroll-container/scroll-container/scroll-container.tsx +37 -9
- package/src/panel-component/scroll-container/scroll-container-item/scroll-container-item.tsx +7 -3
- package/src/panel-component/single-data-container/single-data-container.tsx +12 -4
- package/src/panel-component/teleport-placeholder/teleport-placeholder.tsx +5 -4
- package/src/use/use-semantic-node/use-semantic-node.ts +20 -6
- package/src/view/common/view.scss +3 -2
|
@@ -5,6 +5,7 @@ require('../../use/index.cjs');
|
|
|
5
5
|
var singleDataContainer_controller = require('./single-data-container.controller.cjs');
|
|
6
6
|
require('./single-data-container.css');
|
|
7
7
|
var namespace = require('../../use/namespace/namespace.cjs');
|
|
8
|
+
var useSemanticNode = require('../../use/use-semantic-node/use-semantic-node.cjs');
|
|
8
9
|
|
|
9
10
|
"use strict";
|
|
10
11
|
function _isSlot(s) {
|
|
@@ -33,6 +34,10 @@ const SingleDataContainer = /* @__PURE__ */ vue.defineComponent({
|
|
|
33
34
|
const {
|
|
34
35
|
id
|
|
35
36
|
} = props.modelData;
|
|
37
|
+
const {
|
|
38
|
+
semanticClass,
|
|
39
|
+
semanticStyle
|
|
40
|
+
} = useSemanticNode.useSemanticNode(props.controller);
|
|
36
41
|
const keys = Object.keys(props.controller.panelItems);
|
|
37
42
|
keys.forEach((key) => {
|
|
38
43
|
const panelItem = props.controller.panelItems[key];
|
|
@@ -46,7 +51,9 @@ const SingleDataContainer = /* @__PURE__ */ vue.defineComponent({
|
|
|
46
51
|
return {
|
|
47
52
|
ns,
|
|
48
53
|
classArr,
|
|
49
|
-
renderPanelItem
|
|
54
|
+
renderPanelItem,
|
|
55
|
+
semanticClass,
|
|
56
|
+
semanticStyle
|
|
50
57
|
};
|
|
51
58
|
},
|
|
52
59
|
render() {
|
|
@@ -55,7 +62,8 @@ const SingleDataContainer = /* @__PURE__ */ vue.defineComponent({
|
|
|
55
62
|
content = this.$slots.default();
|
|
56
63
|
} else {
|
|
57
64
|
content = vue.createVNode(vue.resolveComponent("iBizRow"), {
|
|
58
|
-
"class": this.ns.b("content"),
|
|
65
|
+
"class": [this.ns.b("content"), this.semanticClass("content")],
|
|
66
|
+
"style": this.semanticStyle("content"),
|
|
59
67
|
"layout": this.modelData.layout
|
|
60
68
|
}, {
|
|
61
69
|
default: () => {
|
|
@@ -64,6 +72,12 @@ const SingleDataContainer = /* @__PURE__ */ vue.defineComponent({
|
|
|
64
72
|
let _slot;
|
|
65
73
|
const childController = this.controller.panelItems[panelItem.id];
|
|
66
74
|
return vue.createVNode(vue.resolveComponent("iBizCol"), {
|
|
75
|
+
"class": this.semanticClass("item", {
|
|
76
|
+
item: childController
|
|
77
|
+
}),
|
|
78
|
+
"style": this.semanticStyle("item", {
|
|
79
|
+
item: childController
|
|
80
|
+
}),
|
|
67
81
|
"layoutPos": panelItem.layoutPos,
|
|
68
82
|
"state": childController.state
|
|
69
83
|
}, _isSlot(_slot = this.renderPanelItem(panelItem, {
|
|
@@ -77,7 +91,8 @@ const SingleDataContainer = /* @__PURE__ */ vue.defineComponent({
|
|
|
77
91
|
});
|
|
78
92
|
}
|
|
79
93
|
return vue.withDirectives(vue.createVNode("div", {
|
|
80
|
-
"class": this.classArr,
|
|
94
|
+
"class": [this.classArr, this.semanticClass("root")],
|
|
95
|
+
"style": this.semanticStyle("root"),
|
|
81
96
|
"element-loading-text": this.controller.state.loadingText
|
|
82
97
|
}, [content]), [[vue.resolveDirective("loading"), this.controller.state.loading]]);
|
|
83
98
|
}
|
|
@@ -4,6 +4,7 @@ var vue = require('vue');
|
|
|
4
4
|
require('../../use/index.cjs');
|
|
5
5
|
require('./teleport-placeholder.css');
|
|
6
6
|
var namespace = require('../../use/namespace/namespace.cjs');
|
|
7
|
+
var useSemanticNode = require('../../use/use-semantic-node/use-semantic-node.cjs');
|
|
7
8
|
|
|
8
9
|
"use strict";
|
|
9
10
|
const TeleportPlaceholder = /* @__PURE__ */ vue.defineComponent({
|
|
@@ -27,6 +28,10 @@ const TeleportPlaceholder = /* @__PURE__ */ vue.defineComponent({
|
|
|
27
28
|
setup(props) {
|
|
28
29
|
const ns = namespace.useNamespace("teleport-placeholder");
|
|
29
30
|
const tempStyle = vue.ref("");
|
|
31
|
+
const {
|
|
32
|
+
semanticClass,
|
|
33
|
+
semanticStyle
|
|
34
|
+
} = useSemanticNode.useSemanticNode(props.controller);
|
|
30
35
|
const {
|
|
31
36
|
rawItem
|
|
32
37
|
} = props.modelData;
|
|
@@ -44,7 +49,9 @@ const TeleportPlaceholder = /* @__PURE__ */ vue.defineComponent({
|
|
|
44
49
|
return {
|
|
45
50
|
ns,
|
|
46
51
|
classArr,
|
|
47
|
-
tempStyle
|
|
52
|
+
tempStyle,
|
|
53
|
+
semanticClass,
|
|
54
|
+
semanticStyle
|
|
48
55
|
};
|
|
49
56
|
},
|
|
50
57
|
render() {
|
|
@@ -53,8 +60,8 @@ const TeleportPlaceholder = /* @__PURE__ */ vue.defineComponent({
|
|
|
53
60
|
}
|
|
54
61
|
return vue.createVNode("div", {
|
|
55
62
|
"id": this.controller.state.teleportTag,
|
|
56
|
-
"class": this.classArr,
|
|
57
|
-
"style": this.tempStyle
|
|
63
|
+
"class": [this.classArr, this.semanticClass("content")],
|
|
64
|
+
"style": [this.tempStyle, this.semanticStyle("content")]
|
|
58
65
|
}, null);
|
|
59
66
|
}
|
|
60
67
|
});
|
|
@@ -6,16 +6,22 @@ var vue = require('vue');
|
|
|
6
6
|
"use strict";
|
|
7
7
|
function useSemanticNode(controller) {
|
|
8
8
|
var _a, _b;
|
|
9
|
+
const controlType = controller.model.controlType;
|
|
10
|
+
const editorType = controller.model.editorType;
|
|
9
11
|
let classItems = {};
|
|
10
12
|
const classNameAttr = (_a = controller.model.controlAttributes) == null ? void 0 : _a.find(
|
|
11
13
|
(item) => item.attrName === runtime.PredefinedAttributes.CLASSNAMES
|
|
12
14
|
);
|
|
13
15
|
if (classNameAttr && classNameAttr.attrValue) {
|
|
14
|
-
const { controlType } = controller.model;
|
|
15
16
|
if (controlType) {
|
|
16
17
|
classItems = runtime.ScriptFactory.execSingleLine(classNameAttr.attrValue, {
|
|
17
18
|
...controller.getEventArgs()
|
|
18
19
|
});
|
|
20
|
+
} else if (editorType) {
|
|
21
|
+
const editor = controller;
|
|
22
|
+
classItems = runtime.ScriptFactory.execSingleLine(classNameAttr.attrValue, {
|
|
23
|
+
...editor.ctrl.getEventArgs()
|
|
24
|
+
});
|
|
19
25
|
} else {
|
|
20
26
|
const panelItem = controller;
|
|
21
27
|
classItems = runtime.ScriptFactory.execSingleLine(classNameAttr.attrValue, {
|
|
@@ -46,11 +52,15 @@ function useSemanticNode(controller) {
|
|
|
46
52
|
(item) => item.attrName === runtime.PredefinedAttributes.STYLES
|
|
47
53
|
);
|
|
48
54
|
if (styleAttr && styleAttr.attrValue) {
|
|
49
|
-
const { controlType } = controller.model;
|
|
50
55
|
if (controlType) {
|
|
51
56
|
styleItems = runtime.ScriptFactory.execSingleLine(styleAttr.attrValue, {
|
|
52
57
|
...controller.getEventArgs()
|
|
53
58
|
});
|
|
59
|
+
} else if (editorType) {
|
|
60
|
+
const editor = controller;
|
|
61
|
+
styleItems = runtime.ScriptFactory.execSingleLine(styleAttr.attrValue, {
|
|
62
|
+
...editor.ctrl.getEventArgs()
|
|
63
|
+
});
|
|
54
64
|
} else {
|
|
55
65
|
const panelItem = controller;
|
|
56
66
|
styleItems = runtime.ScriptFactory.execSingleLine(styleAttr.attrValue, {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ibiz-template/vue3-util",
|
|
3
|
-
"version": "0.7.41-alpha.
|
|
3
|
+
"version": "0.7.41-alpha.113",
|
|
4
4
|
"description": "通用组件库(vue3)",
|
|
5
5
|
"main": "lib/index.cjs",
|
|
6
6
|
"types": "es/index.d.ts",
|
|
@@ -38,10 +38,10 @@
|
|
|
38
38
|
"license": "MIT",
|
|
39
39
|
"devDependencies": {
|
|
40
40
|
"@ibiz-template/cli": "^0.3.23",
|
|
41
|
-
"@ibiz-template/core": "^0.7.41-alpha.
|
|
42
|
-
"@ibiz-template/runtime": "^0.7.41-alpha.
|
|
41
|
+
"@ibiz-template/core": "^0.7.41-alpha.113",
|
|
42
|
+
"@ibiz-template/runtime": "^0.7.41-alpha.113",
|
|
43
43
|
"@ibiz-template/theme": "^0.7.39",
|
|
44
|
-
"@ibiz/model-core": "^0.1.
|
|
44
|
+
"@ibiz/model-core": "^0.1.88",
|
|
45
45
|
"@types/path-browserify": "^1.0.2",
|
|
46
46
|
"@types/qs": "^6.9.11",
|
|
47
47
|
"@types/systemjs": "^6.13.5",
|
|
@@ -58,7 +58,7 @@
|
|
|
58
58
|
"peerDependencies": {
|
|
59
59
|
"@ibiz-template/core": "^0.6.0",
|
|
60
60
|
"@ibiz-template/runtime": "^0.6.0",
|
|
61
|
-
"@ibiz/model-core": "^0.1.
|
|
61
|
+
"@ibiz/model-core": "^0.1.88",
|
|
62
62
|
"dayjs": "^1.11.10",
|
|
63
63
|
"path-browserify": "^1.0.1",
|
|
64
64
|
"pinia": "^2.1.7",
|
|
@@ -68,5 +68,5 @@
|
|
|
68
68
|
"vue": "^3.3.8",
|
|
69
69
|
"vue-router": "^4.2.4"
|
|
70
70
|
},
|
|
71
|
-
"gitHead": "
|
|
71
|
+
"gitHead": "74e0e6c2da67e6310ccca411945b5cf172a77955"
|
|
72
72
|
}
|
|
@@ -169,14 +169,20 @@ export const ViewLayoutPanelControl = defineComponent({
|
|
|
169
169
|
panelItemC.parent &&
|
|
170
170
|
isSimpleDataContainer(panelItemC.parent.model)
|
|
171
171
|
) {
|
|
172
|
-
children = () => {
|
|
172
|
+
children = (event: IData = {}) => {
|
|
173
173
|
return slots[panelItem.id!]!({
|
|
174
174
|
isSimple: true,
|
|
175
175
|
data: panelItemC.data,
|
|
176
|
+
class: event.class,
|
|
177
|
+
style: event.style,
|
|
176
178
|
});
|
|
177
179
|
};
|
|
178
180
|
} else {
|
|
179
|
-
children = () =>
|
|
181
|
+
children = (event: IData = {}) =>
|
|
182
|
+
slots[panelItem.id!]!({
|
|
183
|
+
class: event.class,
|
|
184
|
+
style: event.style,
|
|
185
|
+
});
|
|
180
186
|
}
|
|
181
187
|
} else if (
|
|
182
188
|
panelItem.itemType === 'TABPANEL' &&
|
|
@@ -2,7 +2,7 @@ import { watch, PropType, onUnmounted, defineComponent } from 'vue';
|
|
|
2
2
|
import { useRoute } from 'vue-router';
|
|
3
3
|
import { IPanelRawItem } from '@ibiz/model-core';
|
|
4
4
|
import { AuthWxmpQrcodeController } from './auth-wxmp-qrcode.controller';
|
|
5
|
-
import { useNamespace } from '../../use';
|
|
5
|
+
import { useNamespace, useSemanticNode } from '../../use';
|
|
6
6
|
import './auth-wxmp-qrcode.scss';
|
|
7
7
|
|
|
8
8
|
/**
|
|
@@ -36,6 +36,7 @@ export const AuthWxmpQrcode = defineComponent({
|
|
|
36
36
|
const { state } = props.controller;
|
|
37
37
|
const route = useRoute();
|
|
38
38
|
props.controller.setRouter(route);
|
|
39
|
+
const { semanticClass, semanticStyle } = useSemanticNode(props.controller);
|
|
39
40
|
|
|
40
41
|
/**
|
|
41
42
|
* 加载二维码
|
|
@@ -66,20 +67,27 @@ export const AuthWxmpQrcode = defineComponent({
|
|
|
66
67
|
props.controller.destroy();
|
|
67
68
|
});
|
|
68
69
|
|
|
69
|
-
return { ns, loadQrcode };
|
|
70
|
+
return { ns, loadQrcode, semanticClass, semanticStyle };
|
|
70
71
|
},
|
|
71
72
|
render() {
|
|
72
73
|
return (
|
|
73
|
-
<div
|
|
74
|
+
<div
|
|
75
|
+
class={[this.ns.b(), this.semanticClass('root')]}
|
|
76
|
+
style={this.semanticStyle('root')}
|
|
77
|
+
>
|
|
74
78
|
<div class={this.ns.e('content')}>
|
|
75
79
|
{this.controller.state.qrcode && (
|
|
76
80
|
<img
|
|
77
|
-
class={this.ns.e('qrcode')}
|
|
81
|
+
class={[this.ns.e('qrcode'), this.semanticClass('content')]}
|
|
82
|
+
style={this.semanticStyle('content')}
|
|
78
83
|
src={this.controller.state.qrcode?.url}
|
|
79
84
|
></img>
|
|
80
85
|
)}
|
|
81
86
|
{!this.controller.state.qrcode?.expirein && (
|
|
82
|
-
<div
|
|
87
|
+
<div
|
|
88
|
+
class={[this.ns.e('mask'), this.semanticClass('mask')]}
|
|
89
|
+
style={this.semanticStyle('mask')}
|
|
90
|
+
>
|
|
83
91
|
<ion-icon
|
|
84
92
|
title={ibiz.i18n.t('vue3Util.panelComponent.refresh')}
|
|
85
93
|
name='reload-outline'
|
|
@@ -89,7 +97,12 @@ export const AuthWxmpQrcode = defineComponent({
|
|
|
89
97
|
</div>
|
|
90
98
|
)}
|
|
91
99
|
</div>
|
|
92
|
-
<div
|
|
100
|
+
<div
|
|
101
|
+
class={[this.ns.e('caption'), this.semanticClass('caption')]}
|
|
102
|
+
style={this.semanticStyle('caption')}
|
|
103
|
+
>
|
|
104
|
+
{this.controller.state.tips}
|
|
105
|
+
</div>
|
|
93
106
|
</div>
|
|
94
107
|
);
|
|
95
108
|
},
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { IFlexLayoutPos, IPanelContainer } from '@ibiz/model-core';
|
|
2
2
|
import { computed, defineComponent, PropType, ref, Ref, VNode } from 'vue';
|
|
3
|
-
import { useNamespace } from '../../use';
|
|
3
|
+
import { useNamespace, useSemanticNode } from '../../use';
|
|
4
4
|
import { GridContainerController } from './grid-container.controller';
|
|
5
5
|
import './grid-container.scss';
|
|
6
6
|
|
|
@@ -30,6 +30,7 @@ export const GridContainer = defineComponent({
|
|
|
30
30
|
setup(props) {
|
|
31
31
|
const ns = useNamespace('grid-container');
|
|
32
32
|
const { id } = props.modelData;
|
|
33
|
+
const { semanticClass, semanticStyle } = useSemanticNode(props.controller);
|
|
33
34
|
|
|
34
35
|
// 类名控制
|
|
35
36
|
const classArr = computed(() => {
|
|
@@ -74,6 +75,8 @@ export const GridContainer = defineComponent({
|
|
|
74
75
|
convertLayoutPos,
|
|
75
76
|
adaptGrow,
|
|
76
77
|
adaptCols,
|
|
78
|
+
semanticClass,
|
|
79
|
+
semanticStyle,
|
|
77
80
|
};
|
|
78
81
|
},
|
|
79
82
|
render() {
|
|
@@ -106,7 +109,8 @@ export const GridContainer = defineComponent({
|
|
|
106
109
|
|
|
107
110
|
return (
|
|
108
111
|
<iBizRow
|
|
109
|
-
class={this.classArr}
|
|
112
|
+
class={[this.classArr, this.semanticClass('root')]}
|
|
113
|
+
style={this.semanticStyle('root')}
|
|
110
114
|
layout={this.layoutModel}
|
|
111
115
|
v-loading={this.controller.state.loading}
|
|
112
116
|
element-loading-text={this.controller.state.loadingText}
|
|
@@ -119,6 +123,8 @@ export const GridContainer = defineComponent({
|
|
|
119
123
|
|
|
120
124
|
return (
|
|
121
125
|
<iBizCol
|
|
126
|
+
class={this.semanticClass('item')}
|
|
127
|
+
style={this.semanticStyle('item')}
|
|
122
128
|
layoutPos={this.convertLayoutPos(
|
|
123
129
|
props.modelData.layoutPos,
|
|
124
130
|
this.adaptGrow,
|
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
VNode,
|
|
13
13
|
watch,
|
|
14
14
|
} from 'vue';
|
|
15
|
-
import { useNamespace } from '../../use';
|
|
15
|
+
import { useNamespace, useSemanticNode } from '../../use';
|
|
16
16
|
import { MultiDataContainerController } from './multi-data-container.controller';
|
|
17
17
|
import './multi-data-container.scss';
|
|
18
18
|
|
|
@@ -42,6 +42,7 @@ export const MultiDataContainer = defineComponent({
|
|
|
42
42
|
setup(props) {
|
|
43
43
|
const ns = useNamespace('multi-data-container');
|
|
44
44
|
const { id } = props.modelData;
|
|
45
|
+
const { semanticClass, semanticStyle } = useSemanticNode(props.controller);
|
|
45
46
|
|
|
46
47
|
// 面板成员state响应式
|
|
47
48
|
watch(
|
|
@@ -85,7 +86,7 @@ export const MultiDataContainer = defineComponent({
|
|
|
85
86
|
return result;
|
|
86
87
|
});
|
|
87
88
|
|
|
88
|
-
return { ns, classArr, renderPanelItem };
|
|
89
|
+
return { ns, classArr, renderPanelItem, semanticClass, semanticStyle };
|
|
89
90
|
},
|
|
90
91
|
render() {
|
|
91
92
|
let content: VNode | VNode[];
|
|
@@ -96,7 +97,14 @@ export const MultiDataContainer = defineComponent({
|
|
|
96
97
|
content = this.controller.state.items.map((_item, index) => {
|
|
97
98
|
const itemController = this.controller.dataItems[index];
|
|
98
99
|
return (
|
|
99
|
-
<iBizRow
|
|
100
|
+
<iBizRow
|
|
101
|
+
class={[
|
|
102
|
+
this.ns.b('content'),
|
|
103
|
+
this.semanticClass('item', { data: _item }),
|
|
104
|
+
]}
|
|
105
|
+
style={this.semanticStyle('item', { data: _item })}
|
|
106
|
+
layout={this.modelData.layout}
|
|
107
|
+
>
|
|
100
108
|
{this.modelData.panelItems?.map(panelItem => {
|
|
101
109
|
const childController = itemController.panelItems[panelItem.id!];
|
|
102
110
|
return (
|
|
@@ -117,7 +125,8 @@ export const MultiDataContainer = defineComponent({
|
|
|
117
125
|
}
|
|
118
126
|
return (
|
|
119
127
|
<div
|
|
120
|
-
class={this.classArr}
|
|
128
|
+
class={[this.classArr, this.semanticClass('root')]}
|
|
129
|
+
style={this.semanticStyle('root')}
|
|
121
130
|
v-loading={this.controller.state.loading}
|
|
122
131
|
element-loading-text={this.controller.state.loadingText}
|
|
123
132
|
>
|
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
VNode,
|
|
13
13
|
watch,
|
|
14
14
|
} from 'vue';
|
|
15
|
-
import { useNamespace } from '../../use';
|
|
15
|
+
import { useNamespace, useSemanticNode } from '../../use';
|
|
16
16
|
import { MultiDataContainerRawController } from './multi-data-container-raw.controller';
|
|
17
17
|
import './multi-data-container-raw.scss';
|
|
18
18
|
|
|
@@ -42,6 +42,7 @@ export const MultiDataContainerRaw = defineComponent({
|
|
|
42
42
|
setup(props) {
|
|
43
43
|
const ns = useNamespace('multi-data-container-raw');
|
|
44
44
|
const { id } = props.modelData;
|
|
45
|
+
const { semanticClass, semanticStyle } = useSemanticNode(props.controller);
|
|
45
46
|
|
|
46
47
|
// 面板成员state响应式
|
|
47
48
|
watch(
|
|
@@ -81,7 +82,7 @@ export const MultiDataContainerRaw = defineComponent({
|
|
|
81
82
|
return result;
|
|
82
83
|
});
|
|
83
84
|
|
|
84
|
-
return { ns, classArr, renderPanelItem };
|
|
85
|
+
return { ns, classArr, renderPanelItem, semanticClass, semanticStyle };
|
|
85
86
|
},
|
|
86
87
|
render() {
|
|
87
88
|
let content: VNode | VNode[];
|
|
@@ -90,13 +91,19 @@ export const MultiDataContainerRaw = defineComponent({
|
|
|
90
91
|
} else {
|
|
91
92
|
// 内容区默认插槽处理,封装app-col
|
|
92
93
|
content = (
|
|
93
|
-
<iBizRow
|
|
94
|
+
<iBizRow
|
|
95
|
+
class={[this.ns.b('content'), this.semanticClass('content')]}
|
|
96
|
+
style={this.semanticStyle('content')}
|
|
97
|
+
layout={this.modelData.layout}
|
|
98
|
+
>
|
|
94
99
|
{this.modelData.panelItems?.map(panelItem => {
|
|
95
100
|
const childController = this.controller.panelItems[panelItem.id!];
|
|
96
101
|
return (
|
|
97
102
|
<iBizCol
|
|
98
103
|
layoutPos={panelItem.layoutPos}
|
|
99
104
|
state={childController.state}
|
|
105
|
+
class={this.semanticClass('item', { item: childController })}
|
|
106
|
+
style={this.semanticStyle('item', { item: childController })}
|
|
100
107
|
>
|
|
101
108
|
{this.renderPanelItem(panelItem, {
|
|
102
109
|
providers: this.controller.providers,
|
|
@@ -110,7 +117,8 @@ export const MultiDataContainerRaw = defineComponent({
|
|
|
110
117
|
}
|
|
111
118
|
return (
|
|
112
119
|
<div
|
|
113
|
-
class={this.classArr}
|
|
120
|
+
class={[this.classArr, this.semanticClass('root')]}
|
|
121
|
+
style={this.semanticStyle('root')}
|
|
114
122
|
v-loading={this.controller.state.loading}
|
|
115
123
|
element-loading-text={this.controller.state.loadingText}
|
|
116
124
|
>
|
|
@@ -12,7 +12,7 @@ import { EventBase } from '@ibiz-template/runtime';
|
|
|
12
12
|
import { RouterView, useRoute, useRouter } from 'vue-router';
|
|
13
13
|
import { NavPosController } from './nav-pos.controller';
|
|
14
14
|
import './nav-pos.scss';
|
|
15
|
-
import { useNamespace } from '../../use';
|
|
15
|
+
import { useNamespace, useSemanticNode } from '../../use';
|
|
16
16
|
import { getNestedRoutePath } from '../../util';
|
|
17
17
|
|
|
18
18
|
/**
|
|
@@ -46,6 +46,8 @@ export const NavPos = defineComponent({
|
|
|
46
46
|
setup(props) {
|
|
47
47
|
const c = props.controller;
|
|
48
48
|
const ns = useNamespace('nav-pos');
|
|
49
|
+
const { semanticClass, semanticStyle } = useSemanticNode(props.controller);
|
|
50
|
+
|
|
49
51
|
const onViewCreated = (event: EventBase): void => {
|
|
50
52
|
c.onViewCreated(event);
|
|
51
53
|
};
|
|
@@ -84,7 +86,7 @@ export const NavPos = defineComponent({
|
|
|
84
86
|
);
|
|
85
87
|
}
|
|
86
88
|
|
|
87
|
-
return { ns, c, isPresetView, onViewCreated };
|
|
89
|
+
return { ns, c, isPresetView, onViewCreated, semanticClass, semanticStyle };
|
|
88
90
|
},
|
|
89
91
|
render() {
|
|
90
92
|
const { viewModals, state } = this.c;
|
|
@@ -92,11 +94,18 @@ export const NavPos = defineComponent({
|
|
|
92
94
|
let content: VNode | null = null;
|
|
93
95
|
if (state.routeOpen) {
|
|
94
96
|
if (this.isPresetView) {
|
|
95
|
-
return
|
|
97
|
+
return (
|
|
98
|
+
<RouterView
|
|
99
|
+
class={this.semanticClass('content')}
|
|
100
|
+
style={this.semanticStyle('content')}
|
|
101
|
+
/>
|
|
102
|
+
);
|
|
96
103
|
}
|
|
97
104
|
|
|
98
105
|
content = (
|
|
99
106
|
<iBizRouterView
|
|
107
|
+
class={this.semanticClass('content')}
|
|
108
|
+
style={this.semanticStyle('content')}
|
|
100
109
|
manualKey={currentKey}
|
|
101
110
|
modal={viewModals[currentKey]}
|
|
102
111
|
onCreated={this.onViewCreated}
|
|
@@ -121,6 +130,8 @@ export const NavPos = defineComponent({
|
|
|
121
130
|
const view =
|
|
122
131
|
currentKey && navViewMsgs[currentKey]
|
|
123
132
|
? h(resolveComponent('IBizViewShell'), {
|
|
133
|
+
class: this.semanticClass('content'),
|
|
134
|
+
style: this.semanticStyle('content'),
|
|
124
135
|
context: navViewMsgs[currentKey].context,
|
|
125
136
|
params: navViewMsgs[currentKey].params,
|
|
126
137
|
key: !this.c.ignoreEmbedKey ? currentKey : undefined,
|
|
@@ -142,8 +153,10 @@ export const NavPos = defineComponent({
|
|
|
142
153
|
class={[
|
|
143
154
|
this.ns.b(),
|
|
144
155
|
this.ns.m(this.modelData.id),
|
|
156
|
+
this.semanticClass('root'),
|
|
145
157
|
...this.controller.containerClass,
|
|
146
158
|
]}
|
|
159
|
+
style={this.semanticStyle('root')}
|
|
147
160
|
// v-loading={this.c.state.isLoading}
|
|
148
161
|
>
|
|
149
162
|
{content}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { PanelContainerController } from '@ibiz-template/runtime';
|
|
2
2
|
import { IPanelContainer } from '@ibiz/model-core';
|
|
3
3
|
import { computed, defineComponent, PropType, VNode } from 'vue';
|
|
4
|
-
import { useNamespace } from '../../use';
|
|
4
|
+
import { useNamespace, useSemanticNode } from '../../use';
|
|
5
5
|
import './panel-container.scss';
|
|
6
6
|
|
|
7
7
|
/**
|
|
@@ -27,6 +27,7 @@ export const PanelContainer = defineComponent({
|
|
|
27
27
|
setup(props) {
|
|
28
28
|
const ns = useNamespace('panel-container');
|
|
29
29
|
const { id } = props.modelData;
|
|
30
|
+
const { semanticClass, semanticStyle } = useSemanticNode(props.controller);
|
|
30
31
|
|
|
31
32
|
// 类名控制
|
|
32
33
|
const classArr = computed(() => {
|
|
@@ -39,13 +40,18 @@ export const PanelContainer = defineComponent({
|
|
|
39
40
|
return result;
|
|
40
41
|
});
|
|
41
42
|
|
|
42
|
-
return { ns, classArr };
|
|
43
|
+
return { ns, classArr, semanticClass, semanticStyle };
|
|
43
44
|
},
|
|
44
45
|
render() {
|
|
45
46
|
// 内容区默认插槽处理,封装app-col
|
|
46
47
|
const defaultSlots: VNode[] = this.$slots.default?.() || [];
|
|
47
48
|
const content = (
|
|
48
|
-
<iBizRow
|
|
49
|
+
<iBizRow
|
|
50
|
+
slot='content'
|
|
51
|
+
class={this.semanticClass('content')}
|
|
52
|
+
style={this.semanticStyle('content')}
|
|
53
|
+
layout={this.modelData.layout}
|
|
54
|
+
>
|
|
49
55
|
{defaultSlots.map(slot => {
|
|
50
56
|
const props = slot.props as IData;
|
|
51
57
|
if (!props || !props.controller) {
|
|
@@ -56,6 +62,8 @@ export const PanelContainer = defineComponent({
|
|
|
56
62
|
<iBizCol
|
|
57
63
|
layoutPos={props.modelData.layoutPos}
|
|
58
64
|
state={props.controller.state}
|
|
65
|
+
class={this.semanticClass('item', { props })}
|
|
66
|
+
style={this.semanticStyle('item', { props })}
|
|
59
67
|
>
|
|
60
68
|
{slot}
|
|
61
69
|
</iBizCol>
|
|
@@ -79,7 +87,8 @@ export const PanelContainer = defineComponent({
|
|
|
79
87
|
default: () => {
|
|
80
88
|
return (
|
|
81
89
|
<div
|
|
82
|
-
class={this.classArr}
|
|
90
|
+
class={[this.classArr, this.semanticClass('root')]}
|
|
91
|
+
style={this.semanticStyle('root')}
|
|
83
92
|
onClick={() => {
|
|
84
93
|
this.controller.onClick();
|
|
85
94
|
}}
|
|
@@ -97,7 +106,11 @@ export const PanelContainer = defineComponent({
|
|
|
97
106
|
content: () => {
|
|
98
107
|
return (
|
|
99
108
|
<div
|
|
100
|
-
class={
|
|
109
|
+
class={[
|
|
110
|
+
this.ns.e('dynamic-tooltip-content'),
|
|
111
|
+
this.semanticClass('tooltip'),
|
|
112
|
+
]}
|
|
113
|
+
style={this.semanticStyle('tooltip')}
|
|
101
114
|
v-html={attrs.dynamictooltip.content}
|
|
102
115
|
></div>
|
|
103
116
|
);
|
|
@@ -109,7 +122,8 @@ export const PanelContainer = defineComponent({
|
|
|
109
122
|
|
|
110
123
|
return (
|
|
111
124
|
<div
|
|
112
|
-
class={this.classArr}
|
|
125
|
+
class={[this.classArr, this.semanticClass('root')]}
|
|
126
|
+
style={this.semanticStyle('root')}
|
|
113
127
|
v-loading={this.controller.state.loading}
|
|
114
128
|
element-loading-text={this.controller.state.loadingText}
|
|
115
129
|
onClick={event => this.controller.onClick(event)}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { IPanelContainer } from '@ibiz/model-core';
|
|
2
2
|
import { computed, defineComponent, PropType, VNode } from 'vue';
|
|
3
3
|
import { isSvg } from '@ibiz-template/core';
|
|
4
|
-
import { useNamespace } from '../../use';
|
|
4
|
+
import { useNamespace, useSemanticNode } from '../../use';
|
|
5
5
|
import { PanelContainerImageController } from './panel-container-image.controller';
|
|
6
6
|
import './panel-container-image.scss';
|
|
7
7
|
|
|
@@ -31,6 +31,7 @@ export const PanelContainerImage = defineComponent({
|
|
|
31
31
|
setup(props) {
|
|
32
32
|
const ns = useNamespace('panel-container-image');
|
|
33
33
|
const { id } = props.modelData;
|
|
34
|
+
const { semanticClass, semanticStyle } = useSemanticNode(props.controller);
|
|
34
35
|
|
|
35
36
|
// 类名控制
|
|
36
37
|
const classArr = computed(() => {
|
|
@@ -66,13 +67,18 @@ export const PanelContainerImage = defineComponent({
|
|
|
66
67
|
return styles;
|
|
67
68
|
});
|
|
68
69
|
|
|
69
|
-
return { ns, classArr, backgroundStyle };
|
|
70
|
+
return { ns, classArr, backgroundStyle, semanticClass, semanticStyle };
|
|
70
71
|
},
|
|
71
72
|
render() {
|
|
72
73
|
// 内容区默认插槽处理,封装app-col
|
|
73
74
|
const defaultSlots: VNode[] = this.$slots.default?.() || [];
|
|
74
75
|
const content = (
|
|
75
|
-
<iBizRow
|
|
76
|
+
<iBizRow
|
|
77
|
+
slot='content'
|
|
78
|
+
class={this.semanticClass('content')}
|
|
79
|
+
style={this.semanticStyle('content')}
|
|
80
|
+
layout={this.modelData.layout}
|
|
81
|
+
>
|
|
76
82
|
{defaultSlots.map(slot => {
|
|
77
83
|
const props = slot.props as IData;
|
|
78
84
|
if (!props || !props.controller) {
|
|
@@ -83,6 +89,8 @@ export const PanelContainerImage = defineComponent({
|
|
|
83
89
|
<iBizCol
|
|
84
90
|
layoutPos={props.modelData.layoutPos}
|
|
85
91
|
state={props.controller.state}
|
|
92
|
+
class={this.semanticClass('item', { props })}
|
|
93
|
+
style={this.semanticStyle('item', { props })}
|
|
86
94
|
>
|
|
87
95
|
{slot}
|
|
88
96
|
</iBizCol>
|
|
@@ -92,11 +100,11 @@ export const PanelContainerImage = defineComponent({
|
|
|
92
100
|
);
|
|
93
101
|
return (
|
|
94
102
|
<div
|
|
95
|
-
class={this.classArr}
|
|
103
|
+
class={[this.classArr, this.semanticClass('root')]}
|
|
96
104
|
v-loading={this.controller.state.loading}
|
|
97
105
|
element-loading-text={this.controller.state.loadingText}
|
|
98
106
|
onClick={event => this.controller.onClick(event)}
|
|
99
|
-
style={this.backgroundStyle}
|
|
107
|
+
style={[this.backgroundStyle, this.semanticStyle('root')]}
|
|
100
108
|
>
|
|
101
109
|
{this.controller.model.cssStyle ? (
|
|
102
110
|
<style type='text/css'>{this.controller.model.cssStyle}</style>
|