@ibiz-template/vue3-components 0.7.41-alpha.55 → 0.7.41-alpha.57
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-B7VRgnNY.js → index-CGlkTyaF.js} +1 -1
- package/dist/{index-DTdGRmFc.js → index-CkCK0iHH.js} +1 -1
- package/dist/index-QscInrTW.js +11 -0
- package/dist/index.min.css +1 -1
- package/dist/index.system.min.js +1 -1
- package/dist/{wang-editor-dy_UWMYO.js → wang-editor-w-EiarfV.js} +1 -1
- package/dist/{xlsx-util-BAhkwxNf.js → xlsx-util-B-cFlAOU.js} +1 -1
- package/es/control/drtab/drtab-control.util.mjs +1 -1
- package/es/control/form/form-detail/form-item/form-item.mjs +12 -3
- package/es/index.mjs +1 -0
- package/es/locale/en/index.mjs +3 -0
- package/es/locale/zh-CN/index.mjs +3 -0
- package/es/panel-component/user-message/internal-message/common/internal-message-container/internal-message-container.mjs +5 -1
- package/es/panel-component/user-message/internal-message/internal-message-json/internal-message-json.mjs +7 -3
- package/es/panel-component/user-message/internal-message/internal-message-tab/internal-message-tab.mjs +15 -1
- package/es/util/ai-chat-util/ai-chat-util.mjs +42 -2
- package/es/util/fullscreen/fullscreen-util.mjs +1 -1
- package/es/util/index.mjs +1 -0
- package/es/util/print-preview-util/print-preview-markdown/icon/icon.mjs +46 -0
- package/es/util/print-preview-util/print-preview-markdown/print-preview-markdown.css +1 -0
- package/es/util/print-preview-util/print-preview-markdown/print-preview-markdown.mjs +75 -0
- package/es/util/print-preview-util/print-preview-util.mjs +57 -0
- package/es/web-app/main.mjs +2 -0
- package/lib/control/drtab/drtab-control.util.cjs +1 -1
- package/lib/control/form/form-detail/form-item/form-item.cjs +11 -2
- package/lib/index.cjs +2 -0
- package/lib/locale/en/index.cjs +3 -0
- package/lib/locale/zh-CN/index.cjs +3 -0
- package/lib/panel-component/user-message/internal-message/common/internal-message-container/internal-message-container.cjs +5 -1
- package/lib/panel-component/user-message/internal-message/internal-message-json/internal-message-json.cjs +7 -3
- package/lib/panel-component/user-message/internal-message/internal-message-tab/internal-message-tab.cjs +15 -1
- package/lib/util/ai-chat-util/ai-chat-util.cjs +42 -2
- package/lib/util/fullscreen/fullscreen-util.cjs +1 -1
- package/lib/util/index.cjs +2 -0
- package/lib/util/print-preview-util/print-preview-markdown/icon/icon.cjs +52 -0
- package/lib/util/print-preview-util/print-preview-markdown/print-preview-markdown.cjs +77 -0
- package/lib/util/print-preview-util/print-preview-markdown/print-preview-markdown.css +1 -0
- package/lib/util/print-preview-util/print-preview-util.cjs +59 -0
- package/lib/web-app/main.cjs +2 -0
- package/package.json +10 -10
- package/dist/index-BZxlkb5k.js +0 -11
- /package/es/node_modules/.pnpm/{@ibiz-template_core@0.7.41-alpha.53_axios@1.12.2_lodash-es@4.17.21_qs@6.14.0_qx-util@0.4.8_ramda@0.29.1 → @ibiz-template_core@0.7.41-alpha.60_axios@1.12.2_lodash-es@4.17.21_qs@6.14.0_qx-util@0.4.8_ramda@0.29.1}/node_modules/@ibiz-template/core/out/utils/namespace/namespace.mjs +0 -0
- /package/lib/node_modules/.pnpm/{@ibiz-template_core@0.7.41-alpha.53_axios@1.12.2_lodash-es@4.17.21_qs@6.14.0_qx-util@0.4.8_ramda@0.29.1 → @ibiz-template_core@0.7.41-alpha.60_axios@1.12.2_lodash-es@4.17.21_qs@6.14.0_qx-util@0.4.8_ramda@0.29.1}/node_modules/@ibiz-template/core/out/utils/namespace/namespace.cjs +0 -0
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
var vue = require('vue');
|
|
4
4
|
var ElementPlus = require('element-plus');
|
|
5
|
-
var namespace = require('../../node_modules/.pnpm/@ibiz-template_core@0.7.41-alpha.
|
|
5
|
+
var namespace = require('../../node_modules/.pnpm/@ibiz-template_core@0.7.41-alpha.60_axios@1.12.2_lodash-es@4.17.21_qs@6.14.0_qx-util@0.4.8_ramda@0.29.1/node_modules/@ibiz-template/core/out/utils/namespace/namespace.cjs');
|
|
6
6
|
var fullscreenToolbar = require('../../common/fullscreen-toolbar/fullscreen-toolbar.cjs');
|
|
7
7
|
|
|
8
8
|
"use strict";
|
package/lib/util/index.cjs
CHANGED
|
@@ -20,6 +20,7 @@ var inlineAiUtil = require('./inline-ai-util/inline-ai-util.cjs');
|
|
|
20
20
|
var aiChatUtil = require('./ai-chat-util/ai-chat-util.cjs');
|
|
21
21
|
var screenShotUtil = require('./screen-shot-util/screen-shot-util.cjs');
|
|
22
22
|
var userRouteUtil = require('./user-route-util/user-route-util.cjs');
|
|
23
|
+
var printPreviewUtil = require('./print-preview-util/print-preview-util.cjs');
|
|
23
24
|
|
|
24
25
|
"use strict";
|
|
25
26
|
|
|
@@ -45,3 +46,4 @@ exports.AIChatUtil = aiChatUtil.AIChatUtil;
|
|
|
45
46
|
exports.ScreenShotUtil = screenShotUtil.ScreenShotUtil;
|
|
46
47
|
exports.splitPathToSegments = userRouteUtil.splitPathToSegments;
|
|
47
48
|
exports.validateRouteSegments = userRouteUtil.validateRouteSegments;
|
|
49
|
+
exports.PrintPreviewUtil = printPreviewUtil.PrintPreviewUtil;
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var vue = require('vue');
|
|
4
|
+
|
|
5
|
+
"use strict";
|
|
6
|
+
const ArrowLeftBold = () => vue.createVNode("svg", {
|
|
7
|
+
"data-v-9a20e128": "",
|
|
8
|
+
"xmlns": "http://www.w3.org/2000/svg",
|
|
9
|
+
"viewBox": "0 0 1024 1024",
|
|
10
|
+
"width": "1em",
|
|
11
|
+
"height": "1em"
|
|
12
|
+
}, [vue.createVNode("path", {
|
|
13
|
+
"fill": "currentColor",
|
|
14
|
+
"d": "M685.248 104.704a64 64 0 0 1 0 90.496L368.448 512l316.8 316.8a64 64 0 0 1-90.496 90.496L232.704 557.248a64 64 0 0 1 0-90.496l362.048-362.048a64 64 0 0 1 90.496 0z"
|
|
15
|
+
}, null)]);
|
|
16
|
+
const ArrowRightBold = () => vue.createVNode("svg", {
|
|
17
|
+
"data-v-9a20e128": "",
|
|
18
|
+
"xmlns": "http://www.w3.org/2000/svg",
|
|
19
|
+
"viewBox": "0 0 1024 1024",
|
|
20
|
+
"width": "1em",
|
|
21
|
+
"height": "1em"
|
|
22
|
+
}, [vue.createVNode("path", {
|
|
23
|
+
"fill": "currentColor",
|
|
24
|
+
"d": "M338.752 104.704a64 64 0 0 0 0 90.496l316.8 316.8-316.8 316.8a64 64 0 0 0 90.496 90.496l362.048-362.048a64 64 0 0 0 0-90.496L429.248 104.704a64 64 0 0 0-90.496 0z"
|
|
25
|
+
}, null)]);
|
|
26
|
+
const FullScreenSvg = () => vue.createVNode("svg", {
|
|
27
|
+
"viewBox": "0 0 1024 1024",
|
|
28
|
+
"version": "1.1",
|
|
29
|
+
"xmlns": "http://www.w3.org/2000/svg"
|
|
30
|
+
}, [vue.createVNode("path", {
|
|
31
|
+
"d": "M547.4 197.4v46l200.3 0.1L546.1 444l32.4 32.6 201.9-200.7v200.9h46V197.5zM471.4 584.4l-32.6-32.6L243.6 747V547.9h-46v278.7h279v-46H275z"
|
|
32
|
+
}, null)]);
|
|
33
|
+
const CloseFullScreenSvg = () => vue.createVNode("svg", {
|
|
34
|
+
"viewBox": "0 0 1024 1024",
|
|
35
|
+
"version": "1.1",
|
|
36
|
+
"xmlns": "http://www.w3.org/2000/svg"
|
|
37
|
+
}, [vue.createVNode("path", {
|
|
38
|
+
"d": "M544 480V282.944h52.224l0.064 107.968L763.072 224l36.928 36.928-166.976 166.976 108.032-0.128V480H544zM260.928 800l-36.928-36.928 166.912-166.784-107.968-0.064V544H480v197.056h-52.224l0.064-107.968L260.928 800z"
|
|
39
|
+
}, null)]);
|
|
40
|
+
const CloseSvg = () => vue.createVNode("svg", {
|
|
41
|
+
"viewBox": "0 0 1024 1024",
|
|
42
|
+
"version": "1.1",
|
|
43
|
+
"xmlns": "http://www.w3.org/2000/svg"
|
|
44
|
+
}, [vue.createVNode("path", {
|
|
45
|
+
"d": "M843.904 783.573333 783.573333 843.904 512.042667 572.373333 240.512 843.904 180.181333 783.573333 451.712 512.042667 180.181333 240.512 240.512 180.181333 512.042667 451.712 783.573333 180.181333 843.904 240.512 572.373333 512.042667 843.904 783.573333Z"
|
|
46
|
+
}, null)]);
|
|
47
|
+
|
|
48
|
+
exports.ArrowLeftBold = ArrowLeftBold;
|
|
49
|
+
exports.ArrowRightBold = ArrowRightBold;
|
|
50
|
+
exports.CloseFullScreenSvg = CloseFullScreenSvg;
|
|
51
|
+
exports.CloseSvg = CloseSvg;
|
|
52
|
+
exports.FullScreenSvg = FullScreenSvg;
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var vue = require('vue');
|
|
4
|
+
var vue3Util = require('@ibiz-template/vue3-util');
|
|
5
|
+
var icon = require('./icon/icon.cjs');
|
|
6
|
+
require('./print-preview-markdown.css');
|
|
7
|
+
|
|
8
|
+
"use strict";
|
|
9
|
+
const PrintPreviewMarkdown = /* @__PURE__ */ vue.defineComponent({
|
|
10
|
+
name: "PrintPreviewMarkdown",
|
|
11
|
+
props: {
|
|
12
|
+
modal: {
|
|
13
|
+
type: Object,
|
|
14
|
+
required: true
|
|
15
|
+
},
|
|
16
|
+
value: {
|
|
17
|
+
type: String,
|
|
18
|
+
default: ""
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
setup(props) {
|
|
22
|
+
const ns = vue3Util.useNamespace("print-preview-markdown");
|
|
23
|
+
const printPreview = vue.ref();
|
|
24
|
+
const isFull = vue.ref(false);
|
|
25
|
+
const switchFull = () => {
|
|
26
|
+
if (isFull.value) {
|
|
27
|
+
ibiz.fullscreenUtil.closeElementFullscreen();
|
|
28
|
+
} else {
|
|
29
|
+
ibiz.fullscreenUtil.openElementFullscreen(printPreview.value);
|
|
30
|
+
}
|
|
31
|
+
isFull.value = !isFull.value;
|
|
32
|
+
};
|
|
33
|
+
const onClose = () => {
|
|
34
|
+
props.modal.dismiss();
|
|
35
|
+
};
|
|
36
|
+
const renderHeader = () => {
|
|
37
|
+
return vue.createVNode("div", {
|
|
38
|
+
"class": ns.e("header")
|
|
39
|
+
}, [vue.createVNode("div", {
|
|
40
|
+
"class": ns.em("header", "caption")
|
|
41
|
+
}, [ibiz.i18n.t("util.printPreviewUtil.title")]), vue.createVNode("div", {
|
|
42
|
+
"class": ns.em("header", "action")
|
|
43
|
+
}, [vue.createVNode("div", {
|
|
44
|
+
"class": ns.em("header", "full"),
|
|
45
|
+
"onClick": switchFull,
|
|
46
|
+
"title": ibiz.i18n.t(isFull.value ? "app.cancelFullscreen" : "app.fullscreen")
|
|
47
|
+
}, [isFull.value ? vue.createVNode(icon.CloseFullScreenSvg, null, null) : vue.createVNode(icon.FullScreenSvg, null, null)]), isFull.value && vue.createVNode("div", {
|
|
48
|
+
"class": ns.em("header", "close"),
|
|
49
|
+
"onClick": onClose,
|
|
50
|
+
"title": ibiz.i18n.t("app.close")
|
|
51
|
+
}, [vue.createVNode(icon.CloseSvg, null, null)])])]);
|
|
52
|
+
};
|
|
53
|
+
const renderContent = () => {
|
|
54
|
+
const markdown = vue.resolveComponent("IBizMarkDown");
|
|
55
|
+
return vue.createVNode("div", {
|
|
56
|
+
"class": ns.e("content")
|
|
57
|
+
}, [vue.h(markdown, {
|
|
58
|
+
value: props.value,
|
|
59
|
+
readonly: true
|
|
60
|
+
})]);
|
|
61
|
+
};
|
|
62
|
+
return {
|
|
63
|
+
ns,
|
|
64
|
+
printPreview,
|
|
65
|
+
renderHeader,
|
|
66
|
+
renderContent
|
|
67
|
+
};
|
|
68
|
+
},
|
|
69
|
+
render() {
|
|
70
|
+
return vue.createVNode("div", {
|
|
71
|
+
"class": this.ns.b(),
|
|
72
|
+
"ref": "printPreview"
|
|
73
|
+
}, [this.renderHeader(), this.renderContent()]);
|
|
74
|
+
}
|
|
75
|
+
});
|
|
76
|
+
|
|
77
|
+
exports.PrintPreviewMarkdown = PrintPreviewMarkdown;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.ibiz-print-preview-markdown{display:flex;flex-direction:column;width:100%;height:100%;overflow:hidden}.ibiz-print-preview-markdown__header{display:flex;flex-shrink:0;gap:var(--ibiz-spacing-base);align-items:center;justify-content:space-between;padding:var(--ibiz-spacing-base)}.ibiz-print-preview-markdown__header--action{display:flex;flex-shrink:0;gap:var(--ibiz-spacing-base)}.ibiz-print-preview-markdown__header--caption{font-size:var(--ibiz-font-size-header-5)}.ibiz-print-preview-markdown__header--full{cursor:pointer}.ibiz-print-preview-markdown__header--full svg{width:var(--ibiz-spacing-base-loose);height:var(--ibiz-spacing-base-loose)}.ibiz-print-preview-markdown__header--close{cursor:pointer}.ibiz-print-preview-markdown__header--close svg{width:var(--ibiz-spacing-base-loose);height:var(--ibiz-spacing-base-loose)}.ibiz-print-preview-markdown__content{flex:1;padding:16px;overflow:auto;border-top:1px solid var(--ibiz-color-border)}.ibiz-print-preview-markdown__content>.ibiz-markdown{height:100%}.ibiz-print-preview-markdown__content>.ibiz-markdown .ibiz-markdown-cherry .cherry{border:none}.ibiz-print-preview-markdown__content>.ibiz-markdown .ibiz-markdown-cherry .cherry .cherry-previewer{border:none}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var vue = require('vue');
|
|
4
|
+
var printPreviewMarkdown = require('./print-preview-markdown/print-preview-markdown.cjs');
|
|
5
|
+
|
|
6
|
+
"use strict";
|
|
7
|
+
class PrintPreviewUtil {
|
|
8
|
+
/**
|
|
9
|
+
* 执行打印
|
|
10
|
+
* @param context
|
|
11
|
+
* @param params
|
|
12
|
+
* @param data
|
|
13
|
+
* @returns boolean 是否成功执行打印
|
|
14
|
+
*/
|
|
15
|
+
async execPrint(context, params, data) {
|
|
16
|
+
const srfcontenttype = params.srfcontenttype;
|
|
17
|
+
if (srfcontenttype === "MARKDOWN") {
|
|
18
|
+
return this.printMarkDown(data, params);
|
|
19
|
+
}
|
|
20
|
+
if (srfcontenttype === "HTML") {
|
|
21
|
+
return this.printHtml(data);
|
|
22
|
+
}
|
|
23
|
+
return false;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* 打印MarkDown(窗口可以由视图参数srfprintheight和srfprintwidth指定,默认居中50%,绘制时为md预览模式绘制,提供全屏按钮,和关闭按钮。)
|
|
27
|
+
* @param data
|
|
28
|
+
* @returns
|
|
29
|
+
*/
|
|
30
|
+
async printMarkDown(data, params) {
|
|
31
|
+
const text = await data.text();
|
|
32
|
+
const overlay = ibiz.overlay.createModal(
|
|
33
|
+
(modal) => vue.h(printPreviewMarkdown.PrintPreviewMarkdown, {
|
|
34
|
+
value: text,
|
|
35
|
+
modal
|
|
36
|
+
}),
|
|
37
|
+
void 0,
|
|
38
|
+
{
|
|
39
|
+
width: params.srfprintwidth || "50%",
|
|
40
|
+
height: params.srfprintheight || "50%"
|
|
41
|
+
}
|
|
42
|
+
);
|
|
43
|
+
overlay.present();
|
|
44
|
+
await overlay.onWillDismiss();
|
|
45
|
+
return true;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* 打印HTML(原生浏览器预览)
|
|
49
|
+
* @param data
|
|
50
|
+
* @returns
|
|
51
|
+
*/
|
|
52
|
+
async printHtml(data) {
|
|
53
|
+
const link = window.URL.createObjectURL(data);
|
|
54
|
+
window.open(link, "_blank");
|
|
55
|
+
return true;
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
exports.PrintPreviewUtil = PrintPreviewUtil;
|
package/lib/web-app/main.cjs
CHANGED
|
@@ -26,6 +26,7 @@ var overlayController = require('../util/overlay-controller/overlay-controller.c
|
|
|
26
26
|
var inlineAiUtil = require('../util/inline-ai-util/inline-ai-util.cjs');
|
|
27
27
|
var screenShotUtil = require('../util/screen-shot-util/screen-shot-util.cjs');
|
|
28
28
|
var aiChatUtil = require('../util/ai-chat-util/ai-chat-util.cjs');
|
|
29
|
+
var printPreviewUtil = require('../util/print-preview-util/print-preview-util.cjs');
|
|
29
30
|
var fullscreenUtil = require('../util/fullscreen/fullscreen-util.cjs');
|
|
30
31
|
|
|
31
32
|
"use strict";
|
|
@@ -92,6 +93,7 @@ async function runApp(plugins, opts) {
|
|
|
92
93
|
ibiz.util.text.format = (value, code) => {
|
|
93
94
|
return app.config.globalProperties.$textFormat(value, code);
|
|
94
95
|
};
|
|
96
|
+
ibiz.printPreview = new printPreviewUtil.PrintPreviewUtil();
|
|
95
97
|
ibiz.fullscreenUtil = new fullscreenUtil.FullscreenUtil();
|
|
96
98
|
await ibiz.i18n.init();
|
|
97
99
|
app.mount("#app");
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ibiz-template/vue3-components",
|
|
3
|
-
"version": "0.7.41-alpha.
|
|
3
|
+
"version": "0.7.41-alpha.57",
|
|
4
4
|
"description": "web端组件库(vue3)",
|
|
5
5
|
"main": "lib/index.cjs",
|
|
6
6
|
"module": "es/index.mjs",
|
|
@@ -30,16 +30,16 @@
|
|
|
30
30
|
"dependencies": {
|
|
31
31
|
"@amap/amap-jsapi-loader": "^1.0.1",
|
|
32
32
|
"@floating-ui/dom": "^1.5.3",
|
|
33
|
-
"@ibiz-template-plugin/ai-chat": "^0.0.
|
|
33
|
+
"@ibiz-template-plugin/ai-chat": "^0.0.48",
|
|
34
34
|
"@ibiz-template-plugin/gantt": "0.1.8-alpha.378",
|
|
35
35
|
"@ibiz-template-plugin/bi-report": "0.0.32",
|
|
36
36
|
"@ibiz-template-plugin/data-view": "0.0.6",
|
|
37
|
-
"@ibiz-template/core": "0.7.41-alpha.
|
|
37
|
+
"@ibiz-template/core": "0.7.41-alpha.60",
|
|
38
38
|
"@ibiz-template/devtool": "0.0.14",
|
|
39
|
-
"@ibiz-template/model-helper": "0.7.41-alpha.
|
|
40
|
-
"@ibiz-template/runtime": "0.7.41-alpha.
|
|
39
|
+
"@ibiz-template/model-helper": "0.7.41-alpha.60",
|
|
40
|
+
"@ibiz-template/runtime": "0.7.41-alpha.60",
|
|
41
41
|
"@ibiz-template/theme": "0.7.39",
|
|
42
|
-
"@ibiz-template/vue3-util": "0.7.41-alpha.
|
|
42
|
+
"@ibiz-template/vue3-util": "0.7.41-alpha.60",
|
|
43
43
|
"@ibiz-template/web-theme": "3.10.0",
|
|
44
44
|
"@ibiz/model-core": "^0.1.84",
|
|
45
45
|
"@imengyu/vue3-context-menu": "^1.3.5",
|
|
@@ -59,11 +59,11 @@
|
|
|
59
59
|
"pinia": "^2.1.7",
|
|
60
60
|
"pluralize": "^8.0.0",
|
|
61
61
|
"qs": "^6.11.2",
|
|
62
|
-
"axios": "^1.
|
|
62
|
+
"axios": "^1.8.2",
|
|
63
63
|
"qx-util": "^0.4.8",
|
|
64
64
|
"ramda": "^0.29.1",
|
|
65
65
|
"vue": "^3.3.8",
|
|
66
|
-
"vue-i18n": "^9.
|
|
66
|
+
"vue-i18n": "^9.14.3",
|
|
67
67
|
"vue-router": "^4.2.5",
|
|
68
68
|
"vuedraggable": "^4.1.0",
|
|
69
69
|
"sortablejs": "^1.15.6",
|
|
@@ -99,7 +99,7 @@
|
|
|
99
99
|
"stylelint-scss": "5.3.1",
|
|
100
100
|
"typescript": "^5.3.3",
|
|
101
101
|
"vite": "^5.0.12",
|
|
102
|
-
"vitest": "^1.
|
|
102
|
+
"vitest": "^1.6.1",
|
|
103
103
|
"vue-tsc": "^1.8.27"
|
|
104
104
|
},
|
|
105
105
|
"peerDependencies": {
|
|
@@ -126,7 +126,7 @@
|
|
|
126
126
|
"qx-util": "^0.4.8",
|
|
127
127
|
"ramda": "^0.29.0",
|
|
128
128
|
"vue": "^3.3.8",
|
|
129
|
-
"vue-i18n": "^9.
|
|
129
|
+
"vue-i18n": "^9.14.3",
|
|
130
130
|
"vue-router": "^4.2.4",
|
|
131
131
|
"vuedraggable": "^4.1.0"
|
|
132
132
|
},
|