qmw-form-design 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -0
- package/lib/cascaderWidget-C4dPsqu5.js +35 -0
- package/lib/cascaderWidget-CZXbv3tO.cjs +1 -0
- package/lib/checkboxWidget-BaFz4odQ.cjs +1 -0
- package/lib/checkboxWidget-CU0seXqA.js +39 -0
- package/lib/datetimeWidget-BRI1k9lz.cjs +1 -0
- package/lib/datetimeWidget-DXuUUSdH.js +32 -0
- package/lib/dyTableWidget-B9g29K4R.cjs +1 -0
- package/lib/dyTableWidget-gQzE59m3.js +66 -0
- package/lib/formDesign-B7SQJxxh.cjs +157750 -0
- package/lib/formDesign-DTFgobCL.js +273574 -0
- package/lib/groupWidget-VmZtc9Bs.js +74 -0
- package/lib/groupWidget-y9fvpsYp.cjs +1 -0
- package/lib/labelWidget-S3O3hW-n.js +28 -0
- package/lib/labelWidget-mp6MkWZ4.cjs +1 -0
- package/lib/numberWidget-C3bkkH0P.js +32 -0
- package/lib/numberWidget-ok9nP1sB.cjs +1 -0
- package/lib/qmw-form-design.cjs +1 -0
- package/lib/qmw-form-design.css +1 -0
- package/lib/qmw-form-design.js +4 -0
- package/lib/radioWidget-Bj9O6GMx.js +39 -0
- package/lib/radioWidget-ClJWGKCx.cjs +1 -0
- package/lib/richEditorWidget-CW_rXEl7.js +20878 -0
- package/lib/richEditorWidget-D4LHcpPx.cjs +186 -0
- package/lib/rowColWidget-B3c6NEpV.cjs +1 -0
- package/lib/rowColWidget-DpxxCDFU.js +85 -0
- package/lib/selectWidget-2a60eLQg.cjs +1 -0
- package/lib/selectWidget-BbLn1CnV.js +35 -0
- package/lib/switchWidget-Dq8pR_eI.js +31 -0
- package/lib/switchWidget-H424ausN.cjs +1 -0
- package/lib/tableWidget-CdLLoEqJ.cjs +1 -0
- package/lib/tableWidget-QyvH8FlO.js +100 -0
- package/lib/textWidget-BYYSe1Ad.cjs +1 -0
- package/lib/textWidget-CGDnbqCG.js +31 -0
- package/lib/textareaWidget-BU6qvVd6.js +31 -0
- package/lib/textareaWidget-CwWBNrZR.cjs +1 -0
- package/lib/treeWidget-D4GFodhm.cjs +1 -0
- package/lib/treeWidget-MJEuA8BS.js +35 -0
- package/lib/uploadWidget-B18wnHTt.js +31 -0
- package/lib/uploadWidget-D_4p14VX.cjs +1 -0
- package/lib/vite.svg +1 -0
- package/package.json +31 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),l=require("./formDesign-B7SQJxxh.cjs"),u=["onClick"],g=["onClick"],m={__name:"rowColWidget",props:e.mergeModels({style:{type:Object,default:()=>({})}},{widgetList:{},widgetListModifiers:{},pWidget:{},pWidgetModifiers:{}}),emits:["update:widgetList","update:pWidget"],setup(d){const o=e.useModel(d,"widgetList"),r=e.useModel(d,"pWidget"),n=window.$formDesignerStore;return e.onMounted(()=>{}),(p,y)=>(e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle(d.style),class:"row-widget"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.value,(i,s)=>(e.openBlock(),e.createElementBlock("div",{key:i.id,style:e.normalizeStyle(i.style),class:e.normalizeClass(["col-widget",e.unref(n).setAreaClass(i)]),onClick:e.withModifiers(t=>{e.unref(n).onClickFormWidget(t,i)},["stop"])},[e.createVNode(l._sfc_main,{widget:i},null,8,["widget"]),e.createVNode(l._sfc_main$1,{widget:i,widgetList:o.value,widgetIndex:s,pWidget:r.value},null,8,["widget","widgetList","widgetIndex","pWidget"]),e.createVNode(e.unref(l.lo),{modelValue:i.children,"onUpdate:modelValue":t=>i.children=t,animation:"150",group:"formContainer",onAdd:t=>{e.unref(n).addWidget(t,i.children,i)},onEnd:e.unref(n).saveHistoryStep,style:{"min-height":"30px"}},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(i.children,(t,a)=>(e.openBlock(),e.createElementBlock("div",{key:t.type,onClick:e.withModifiers(c=>{e.unref(n).onClickFormWidget(c,t)},["stop"]),class:e.normalizeClass(["widget-div",e.unref(n).setAreaClass(t)])},[e.createVNode(l._sfc_main,{widget:t},null,8,["widget"]),e.createVNode(l._sfc_main$1,{widget:t,widgetList:i.children,widgetIndex:a,pWidget:t},null,8,["widget","widgetList","widgetIndex","pWidget"]),t.pType=="formWidget"?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.widgetType),{key:0,widget:t,style:e.normalizeStyle(t.style)},null,8,["widget","style"])):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.widgetType),{key:1,widgetList:t.children,style:e.normalizeStyle(t.style),pWidget:t},null,8,["widgetList","style","pWidget"]))],10,g))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","onAdd","onEnd"])],14,u))),128))],4))}};exports.default=m;
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
import { mergeModels as _, useModel as g, onMounted as v, createElementBlock as s, openBlock as i, normalizeStyle as o, Fragment as u, renderList as p, withModifiers as m, normalizeClass as c, unref as d, createVNode as l, withCtx as x, createBlock as y, resolveDynamicComponent as w } from "vue";
|
|
2
|
+
import { _ as f, a as W, l as M } from "./formDesign-DTFgobCL.js";
|
|
3
|
+
const V = ["onClick"], A = ["onClick"], E = {
|
|
4
|
+
__name: "rowColWidget",
|
|
5
|
+
props: /* @__PURE__ */ _({
|
|
6
|
+
style: {
|
|
7
|
+
type: Object,
|
|
8
|
+
default: () => ({})
|
|
9
|
+
}
|
|
10
|
+
}, {
|
|
11
|
+
widgetList: {},
|
|
12
|
+
widgetListModifiers: {},
|
|
13
|
+
pWidget: {},
|
|
14
|
+
pWidgetModifiers: {}
|
|
15
|
+
}),
|
|
16
|
+
emits: ["update:widgetList", "update:pWidget"],
|
|
17
|
+
setup(r) {
|
|
18
|
+
const a = g(r, "widgetList"), h = g(r, "pWidget"), n = window.$formDesignerStore;
|
|
19
|
+
return v(() => {
|
|
20
|
+
}), (I, S) => (i(), s("div", {
|
|
21
|
+
style: o(r.style),
|
|
22
|
+
class: "row-widget"
|
|
23
|
+
}, [
|
|
24
|
+
(i(!0), s(u, null, p(a.value, (t, k) => (i(), s("div", {
|
|
25
|
+
key: t.id,
|
|
26
|
+
style: o(t.style),
|
|
27
|
+
class: c(["col-widget", d(n).setAreaClass(t)]),
|
|
28
|
+
onClick: m((e) => {
|
|
29
|
+
d(n).onClickFormWidget(e, t);
|
|
30
|
+
}, ["stop"])
|
|
31
|
+
}, [
|
|
32
|
+
l(f, { widget: t }, null, 8, ["widget"]),
|
|
33
|
+
l(W, {
|
|
34
|
+
widget: t,
|
|
35
|
+
widgetList: a.value,
|
|
36
|
+
widgetIndex: k,
|
|
37
|
+
pWidget: h.value
|
|
38
|
+
}, null, 8, ["widget", "widgetList", "widgetIndex", "pWidget"]),
|
|
39
|
+
l(d(M), {
|
|
40
|
+
modelValue: t.children,
|
|
41
|
+
"onUpdate:modelValue": (e) => t.children = e,
|
|
42
|
+
animation: "150",
|
|
43
|
+
group: "formContainer",
|
|
44
|
+
onAdd: (e) => {
|
|
45
|
+
d(n).addWidget(e, t.children, t);
|
|
46
|
+
},
|
|
47
|
+
onEnd: d(n).saveHistoryStep,
|
|
48
|
+
style: { "min-height": "30px" }
|
|
49
|
+
}, {
|
|
50
|
+
default: x(() => [
|
|
51
|
+
(i(!0), s(u, null, p(t.children, (e, C) => (i(), s("div", {
|
|
52
|
+
key: e.type,
|
|
53
|
+
onClick: m((L) => {
|
|
54
|
+
d(n).onClickFormWidget(L, e);
|
|
55
|
+
}, ["stop"]),
|
|
56
|
+
class: c(["widget-div", d(n).setAreaClass(e)])
|
|
57
|
+
}, [
|
|
58
|
+
l(f, { widget: e }, null, 8, ["widget"]),
|
|
59
|
+
l(W, {
|
|
60
|
+
widget: e,
|
|
61
|
+
widgetList: t.children,
|
|
62
|
+
widgetIndex: C,
|
|
63
|
+
pWidget: e
|
|
64
|
+
}, null, 8, ["widget", "widgetList", "widgetIndex", "pWidget"]),
|
|
65
|
+
e.pType == "formWidget" ? (i(), y(w(e.widgetType), {
|
|
66
|
+
key: 0,
|
|
67
|
+
widget: e,
|
|
68
|
+
style: o(e.style)
|
|
69
|
+
}, null, 8, ["widget", "style"])) : (i(), y(w(e.widgetType), {
|
|
70
|
+
key: 1,
|
|
71
|
+
widgetList: e.children,
|
|
72
|
+
style: o(e.style),
|
|
73
|
+
pWidget: e
|
|
74
|
+
}, null, 8, ["widgetList", "style", "pWidget"]))
|
|
75
|
+
], 10, A))), 128))
|
|
76
|
+
]),
|
|
77
|
+
_: 2
|
|
78
|
+
}, 1032, ["modelValue", "onUpdate:modelValue", "onAdd", "onEnd"])
|
|
79
|
+
], 14, V))), 128))
|
|
80
|
+
], 4));
|
|
81
|
+
}
|
|
82
|
+
};
|
|
83
|
+
export {
|
|
84
|
+
E as default
|
|
85
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),c={__name:"selectWidget",props:{widget:{type:Object,default:()=>({})},style:{type:Object,default:()=>({})}},setup(l){const t=l,s=e.computed(()=>{let n={...t.style};return t.style&&t.style.width&&t.style.width!=""||(n.width="100px"),n});return e.onMounted(()=>{}),(n,a)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("label",{style:e.normalizeStyle(l.widget.labelStyle),class:"widget-label"},e.toDisplayString(l.widget.config.label),5),e.createElementVNode("select",{style:e.normalizeStyle(s.value),disabled:""},null,4)],64))}};exports.default=c;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { computed as n, onMounted as d, createElementBlock as i, openBlock as o, Fragment as r, createElementVNode as s, normalizeStyle as a, toDisplayString as y } from "vue";
|
|
2
|
+
const p = {
|
|
3
|
+
__name: "selectWidget",
|
|
4
|
+
props: {
|
|
5
|
+
//组件对象
|
|
6
|
+
widget: {
|
|
7
|
+
type: Object,
|
|
8
|
+
default: () => ({})
|
|
9
|
+
},
|
|
10
|
+
style: {
|
|
11
|
+
type: Object,
|
|
12
|
+
default: () => ({})
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
setup(t) {
|
|
16
|
+
const e = t, c = n(() => {
|
|
17
|
+
let l = { ...e.style };
|
|
18
|
+
return e.style && e.style.width && e.style.width != "" || (l.width = "100px"), l;
|
|
19
|
+
});
|
|
20
|
+
return d(() => {
|
|
21
|
+
}), (l, u) => (o(), i(r, null, [
|
|
22
|
+
s("label", {
|
|
23
|
+
style: a(t.widget.labelStyle),
|
|
24
|
+
class: "widget-label"
|
|
25
|
+
}, y(t.widget.config.label), 5),
|
|
26
|
+
s("select", {
|
|
27
|
+
style: a(c.value),
|
|
28
|
+
disabled: ""
|
|
29
|
+
}, null, 4)
|
|
30
|
+
], 64));
|
|
31
|
+
}
|
|
32
|
+
};
|
|
33
|
+
export {
|
|
34
|
+
p as default
|
|
35
|
+
};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { onMounted as n, createElementBlock as o, openBlock as a, Fragment as i, createElementVNode as l, normalizeStyle as s, toDisplayString as c } from "vue";
|
|
2
|
+
const m = {
|
|
3
|
+
__name: "switchWidget",
|
|
4
|
+
props: {
|
|
5
|
+
//组件对象
|
|
6
|
+
widget: {
|
|
7
|
+
type: Object,
|
|
8
|
+
default: () => ({})
|
|
9
|
+
},
|
|
10
|
+
style: {
|
|
11
|
+
type: Object,
|
|
12
|
+
default: () => ({})
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
setup(e) {
|
|
16
|
+
return n(() => {
|
|
17
|
+
}), (r, t) => (a(), o(i, null, [
|
|
18
|
+
l("label", {
|
|
19
|
+
style: s(e.widget.labelStyle),
|
|
20
|
+
class: "widget-label"
|
|
21
|
+
}, c(e.widget.config.label), 5),
|
|
22
|
+
t[0] || (t[0] = l("span", {
|
|
23
|
+
class: "icomoon icon-switch",
|
|
24
|
+
style: { "font-size": "21px" }
|
|
25
|
+
}, null, -1))
|
|
26
|
+
], 64));
|
|
27
|
+
}
|
|
28
|
+
};
|
|
29
|
+
export {
|
|
30
|
+
m as default
|
|
31
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),n={__name:"switchWidget",props:{widget:{type:Object,default:()=>({})},style:{type:Object,default:()=>({})}},setup(t){return e.onMounted(()=>{}),(o,l)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("label",{style:e.normalizeStyle(t.widget.labelStyle),class:"widget-label"},e.toDisplayString(t.widget.config.label),5),l[0]||(l[0]=e.createElementVNode("span",{class:"icomoon icon-switch",style:{"font-size":"21px"}},null,-1))],64))}};exports.default=n;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),i=require("./formDesign-B7SQJxxh.cjs"),g=["id"],p=["onClick","colspan","rowspan"],y=["onClick"],k={__name:"tableWidget",props:e.mergeModels({style:{type:Object,default:()=>({})}},{widgetList:{},widgetListModifiers:{},pWidget:{},pWidgetModifiers:{}}),emits:["update:widgetList","update:pWidget"],setup(r){const s=e.useModel(r,"widgetList"),a=e.useModel(r,"pWidget"),n=window.$formDesignerStore;return e.onMounted(()=>{}),(f,w)=>(e.openBlock(),e.createElementBlock("table",{style:e.normalizeStyle(r.style)},[e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(o,c)=>(e.openBlock(),e.createElementBlock("tr",{key:o.id,style:e.normalizeStyle(o.style),class:e.normalizeClass(e.unref(n).setAreaClass(o)),id:o.id},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(o.children,(l,d)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:l.id},[!l.cMerge&&!l.rMerge?(e.openBlock(),e.createElementBlock("td",{key:0,style:e.normalizeStyle(l.style),onClick:e.withModifiers(t=>{e.unref(n).onClickFormWidget(t,l)},["stop"]),class:e.normalizeClass(e.unref(n).setAreaClass(l)),colspan:l.colspan,rowspan:l.rowspan},[e.createVNode(i._sfc_main,{widget:l},null,8,["widget"]),e.createVNode(i._sfc_main$1,{widget:l,widgetList:s.value,widgetIndex:d,trIndex:c,pWidget:a.value},null,8,["widget","widgetList","widgetIndex","trIndex","pWidget"]),e.createVNode(e.unref(i.lo),{modelValue:l.children,"onUpdate:modelValue":t=>l.children=t,animation:"150",group:"formContainer",style:e.normalizeStyle(l.style&&l.style.minHeight?"min-height:"+l.style.minHeight:""),onAdd:t=>{e.unref(n).addWidget(t,l.children,l)},onEnd:e.unref(n).saveHistoryStep},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.children,(t,m)=>(e.openBlock(),e.createElementBlock("div",{key:t.type,onClick:e.withModifiers(u=>{e.unref(n).onClickFormWidget(u,t)},["stop"]),class:e.normalizeClass(["widget-div",e.unref(n).setAreaClass(t)])},[e.createVNode(i._sfc_main,{widget:t},null,8,["widget"]),e.createVNode(i._sfc_main$1,{widget:t,widgetList:l.children,widgetIndex:m,pWidget:t},null,8,["widget","widgetList","widgetIndex","pWidget"]),t.pType=="formWidget"?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.widgetType),{key:0,widget:t,style:e.normalizeStyle(t.style)},null,8,["widget","style"])):(e.openBlock(),e.createBlock(e.resolveDynamicComponent(t.widgetType),{key:1,widgetList:t.children,style:e.normalizeStyle(t.style),pWidget:t},null,8,["widgetList","style","pWidget"]))],10,y))),128))]),_:2},1032,["modelValue","onUpdate:modelValue","style","onAdd","onEnd"])],14,p)):e.createCommentVNode("",!0)],64))),128))],14,g))),128))])],4))}};exports.default=k;
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
import { mergeModels as M, useModel as m, onMounted as v, createElementBlock as l, openBlock as i, normalizeStyle as o, createElementVNode as V, Fragment as a, renderList as g, normalizeClass as u, unref as n, createCommentVNode as I, withModifiers as y, createVNode as r, withCtx as A, createBlock as w, resolveDynamicComponent as h } from "vue";
|
|
2
|
+
import { _ as f, a as W, l as b } from "./formDesign-DTFgobCL.js";
|
|
3
|
+
const E = ["id"], S = ["onClick", "colspan", "rowspan"], B = ["onClick"], T = {
|
|
4
|
+
__name: "tableWidget",
|
|
5
|
+
props: /* @__PURE__ */ M({
|
|
6
|
+
style: {
|
|
7
|
+
type: Object,
|
|
8
|
+
default: () => ({})
|
|
9
|
+
}
|
|
10
|
+
}, {
|
|
11
|
+
widgetList: {},
|
|
12
|
+
widgetListModifiers: {},
|
|
13
|
+
pWidget: {},
|
|
14
|
+
pWidgetModifiers: {}
|
|
15
|
+
}),
|
|
16
|
+
emits: ["update:widgetList", "update:pWidget"],
|
|
17
|
+
setup(c) {
|
|
18
|
+
const p = m(c, "widgetList"), k = m(c, "pWidget"), s = window.$formDesignerStore;
|
|
19
|
+
return v(() => {
|
|
20
|
+
}), (D, F) => (i(), l("table", {
|
|
21
|
+
style: o(c.style)
|
|
22
|
+
}, [
|
|
23
|
+
V("tbody", null, [
|
|
24
|
+
(i(!0), l(a, null, g(p.value, (d, C) => (i(), l("tr", {
|
|
25
|
+
key: d.id,
|
|
26
|
+
style: o(d.style),
|
|
27
|
+
class: u(n(s).setAreaClass(d)),
|
|
28
|
+
id: d.id
|
|
29
|
+
}, [
|
|
30
|
+
(i(!0), l(a, null, g(d.children, (t, _) => (i(), l(a, {
|
|
31
|
+
key: t.id
|
|
32
|
+
}, [
|
|
33
|
+
!t.cMerge && !t.rMerge ? (i(), l("td", {
|
|
34
|
+
key: 0,
|
|
35
|
+
style: o(t.style),
|
|
36
|
+
onClick: y((e) => {
|
|
37
|
+
n(s).onClickFormWidget(e, t);
|
|
38
|
+
}, ["stop"]),
|
|
39
|
+
class: u(n(s).setAreaClass(t)),
|
|
40
|
+
colspan: t.colspan,
|
|
41
|
+
rowspan: t.rowspan
|
|
42
|
+
}, [
|
|
43
|
+
r(f, { widget: t }, null, 8, ["widget"]),
|
|
44
|
+
r(W, {
|
|
45
|
+
widget: t,
|
|
46
|
+
widgetList: p.value,
|
|
47
|
+
widgetIndex: _,
|
|
48
|
+
trIndex: C,
|
|
49
|
+
pWidget: k.value
|
|
50
|
+
}, null, 8, ["widget", "widgetList", "widgetIndex", "trIndex", "pWidget"]),
|
|
51
|
+
r(n(b), {
|
|
52
|
+
modelValue: t.children,
|
|
53
|
+
"onUpdate:modelValue": (e) => t.children = e,
|
|
54
|
+
animation: "150",
|
|
55
|
+
group: "formContainer",
|
|
56
|
+
style: o(t.style && t.style.minHeight ? "min-height:" + t.style.minHeight : ""),
|
|
57
|
+
onAdd: (e) => {
|
|
58
|
+
n(s).addWidget(e, t.children, t);
|
|
59
|
+
},
|
|
60
|
+
onEnd: n(s).saveHistoryStep
|
|
61
|
+
}, {
|
|
62
|
+
default: A(() => [
|
|
63
|
+
(i(!0), l(a, null, g(t.children, (e, L) => (i(), l("div", {
|
|
64
|
+
key: e.type,
|
|
65
|
+
onClick: y((x) => {
|
|
66
|
+
n(s).onClickFormWidget(x, e);
|
|
67
|
+
}, ["stop"]),
|
|
68
|
+
class: u(["widget-div", n(s).setAreaClass(e)])
|
|
69
|
+
}, [
|
|
70
|
+
r(f, { widget: e }, null, 8, ["widget"]),
|
|
71
|
+
r(W, {
|
|
72
|
+
widget: e,
|
|
73
|
+
widgetList: t.children,
|
|
74
|
+
widgetIndex: L,
|
|
75
|
+
pWidget: e
|
|
76
|
+
}, null, 8, ["widget", "widgetList", "widgetIndex", "pWidget"]),
|
|
77
|
+
e.pType == "formWidget" ? (i(), w(h(e.widgetType), {
|
|
78
|
+
key: 0,
|
|
79
|
+
widget: e,
|
|
80
|
+
style: o(e.style)
|
|
81
|
+
}, null, 8, ["widget", "style"])) : (i(), w(h(e.widgetType), {
|
|
82
|
+
key: 1,
|
|
83
|
+
widgetList: e.children,
|
|
84
|
+
style: o(e.style),
|
|
85
|
+
pWidget: e
|
|
86
|
+
}, null, 8, ["widgetList", "style", "pWidget"]))
|
|
87
|
+
], 10, B))), 128))
|
|
88
|
+
]),
|
|
89
|
+
_: 2
|
|
90
|
+
}, 1032, ["modelValue", "onUpdate:modelValue", "style", "onAdd", "onEnd"])
|
|
91
|
+
], 14, S)) : I("", !0)
|
|
92
|
+
], 64))), 128))
|
|
93
|
+
], 14, E))), 128))
|
|
94
|
+
])
|
|
95
|
+
], 4));
|
|
96
|
+
}
|
|
97
|
+
};
|
|
98
|
+
export {
|
|
99
|
+
T as default
|
|
100
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),l={__name:"textWidget",props:{widget:{type:Object,default:()=>({})},style:{type:Object,default:()=>({})}},setup(t){return e.onMounted(()=>{}),(n,a)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("label",{style:e.normalizeStyle(t.widget.labelStyle),class:"widget-label"},e.toDisplayString(t.widget.config.label),5),e.createElementVNode("input",{style:e.normalizeStyle(t.style),disabled:""},null,4)],64))}};exports.default=l;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { onMounted as a, createElementBlock as n, openBlock as c, Fragment as i, createElementVNode as t, normalizeStyle as l, toDisplayString as d } from "vue";
|
|
2
|
+
const u = {
|
|
3
|
+
__name: "textWidget",
|
|
4
|
+
props: {
|
|
5
|
+
//组件对象
|
|
6
|
+
widget: {
|
|
7
|
+
type: Object,
|
|
8
|
+
default: () => ({})
|
|
9
|
+
},
|
|
10
|
+
style: {
|
|
11
|
+
type: Object,
|
|
12
|
+
default: () => ({})
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
setup(e) {
|
|
16
|
+
return a(() => {
|
|
17
|
+
}), (o, r) => (c(), n(i, null, [
|
|
18
|
+
t("label", {
|
|
19
|
+
style: l(e.widget.labelStyle),
|
|
20
|
+
class: "widget-label"
|
|
21
|
+
}, d(e.widget.config.label), 5),
|
|
22
|
+
t("input", {
|
|
23
|
+
style: l(e.style),
|
|
24
|
+
disabled: ""
|
|
25
|
+
}, null, 4)
|
|
26
|
+
], 64));
|
|
27
|
+
}
|
|
28
|
+
};
|
|
29
|
+
export {
|
|
30
|
+
u as default
|
|
31
|
+
};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { onMounted as a, createElementBlock as n, openBlock as c, Fragment as i, createElementVNode as t, normalizeStyle as l, toDisplayString as d } from "vue";
|
|
2
|
+
const u = {
|
|
3
|
+
__name: "textareaWidget",
|
|
4
|
+
props: {
|
|
5
|
+
//组件对象
|
|
6
|
+
widget: {
|
|
7
|
+
type: Object,
|
|
8
|
+
default: () => ({})
|
|
9
|
+
},
|
|
10
|
+
style: {
|
|
11
|
+
type: Object,
|
|
12
|
+
default: () => ({})
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
setup(e) {
|
|
16
|
+
return a(() => {
|
|
17
|
+
}), (o, r) => (c(), n(i, null, [
|
|
18
|
+
t("label", {
|
|
19
|
+
style: l(e.widget.labelStyle),
|
|
20
|
+
class: "widget-label"
|
|
21
|
+
}, d(e.widget.config.label), 5),
|
|
22
|
+
t("input", {
|
|
23
|
+
style: l(e.style),
|
|
24
|
+
disabled: ""
|
|
25
|
+
}, null, 4)
|
|
26
|
+
], 64));
|
|
27
|
+
}
|
|
28
|
+
};
|
|
29
|
+
export {
|
|
30
|
+
u as default
|
|
31
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),l={__name:"textareaWidget",props:{widget:{type:Object,default:()=>({})},style:{type:Object,default:()=>({})}},setup(t){return e.onMounted(()=>{}),(a,n)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("label",{style:e.normalizeStyle(t.widget.labelStyle),class:"widget-label"},e.toDisplayString(t.widget.config.label),5),e.createElementVNode("input",{style:e.normalizeStyle(t.style),disabled:""},null,4)],64))}};exports.default=l;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),a={__name:"treeWidget",props:{widget:{type:Object,default:()=>({})},style:{type:Object,default:()=>({})}},setup(l){const t=l,s=e.computed(()=>{let n={...t.style};return t.style&&t.style.width&&t.style.width!=""||(n.width="100px"),n});return e.onMounted(()=>{}),(n,c)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("label",{style:e.normalizeStyle(l.widget.labelStyle),class:"widget-label"},e.toDisplayString(l.widget.config.label),5),e.createElementVNode("select",{style:e.normalizeStyle(s.value),disabled:""},null,4)],64))}};exports.default=a;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { computed as c, onMounted as d, createElementBlock as i, openBlock as o, Fragment as r, createElementVNode as s, normalizeStyle as a, toDisplayString as y } from "vue";
|
|
2
|
+
const p = {
|
|
3
|
+
__name: "treeWidget",
|
|
4
|
+
props: {
|
|
5
|
+
//组件对象
|
|
6
|
+
widget: {
|
|
7
|
+
type: Object,
|
|
8
|
+
default: () => ({})
|
|
9
|
+
},
|
|
10
|
+
style: {
|
|
11
|
+
type: Object,
|
|
12
|
+
default: () => ({})
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
setup(t) {
|
|
16
|
+
const e = t, n = c(() => {
|
|
17
|
+
let l = { ...e.style };
|
|
18
|
+
return e.style && e.style.width && e.style.width != "" || (l.width = "100px"), l;
|
|
19
|
+
});
|
|
20
|
+
return d(() => {
|
|
21
|
+
}), (l, u) => (o(), i(r, null, [
|
|
22
|
+
s("label", {
|
|
23
|
+
style: a(t.widget.labelStyle),
|
|
24
|
+
class: "widget-label"
|
|
25
|
+
}, y(t.widget.config.label), 5),
|
|
26
|
+
s("select", {
|
|
27
|
+
style: a(n.value),
|
|
28
|
+
disabled: ""
|
|
29
|
+
}, null, 4)
|
|
30
|
+
], 64));
|
|
31
|
+
}
|
|
32
|
+
};
|
|
33
|
+
export {
|
|
34
|
+
p as default
|
|
35
|
+
};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { onMounted as a, createElementBlock as n, openBlock as o, Fragment as c, createElementVNode as t, normalizeStyle as l, toDisplayString as d } from "vue";
|
|
2
|
+
const u = {
|
|
3
|
+
__name: "uploadWidget",
|
|
4
|
+
props: {
|
|
5
|
+
//组件对象
|
|
6
|
+
widget: {
|
|
7
|
+
type: Object,
|
|
8
|
+
default: () => ({})
|
|
9
|
+
},
|
|
10
|
+
style: {
|
|
11
|
+
type: Object,
|
|
12
|
+
default: () => ({})
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
setup(e) {
|
|
16
|
+
return a(() => {
|
|
17
|
+
}), (i, r) => (o(), n(c, null, [
|
|
18
|
+
t("label", {
|
|
19
|
+
style: l(e.widget.labelStyle),
|
|
20
|
+
class: "widget-label"
|
|
21
|
+
}, d(e.widget.config.label), 5),
|
|
22
|
+
t("button", {
|
|
23
|
+
style: l(e.style),
|
|
24
|
+
disabled: ""
|
|
25
|
+
}, "选择文件", 4)
|
|
26
|
+
], 64));
|
|
27
|
+
}
|
|
28
|
+
};
|
|
29
|
+
export {
|
|
30
|
+
u as default
|
|
31
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("vue"),l={__name:"uploadWidget",props:{widget:{type:Object,default:()=>({})},style:{type:Object,default:()=>({})}},setup(t){return e.onMounted(()=>{}),(a,n)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("label",{style:e.normalizeStyle(t.widget.labelStyle),class:"widget-label"},e.toDisplayString(t.widget.config.label),5),e.createElementVNode("button",{style:e.normalizeStyle(t.style),disabled:""},"选择文件",4)],64))}};exports.default=l;
|
package/lib/vite.svg
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" class="iconify iconify--logos" width="31.88" height="32" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 257"><defs><linearGradient id="IconifyId1813088fe1fbc01fb466" x1="-.828%" x2="57.636%" y1="7.652%" y2="78.411%"><stop offset="0%" stop-color="#41D1FF"></stop><stop offset="100%" stop-color="#BD34FE"></stop></linearGradient><linearGradient id="IconifyId1813088fe1fbc01fb467" x1="43.376%" x2="50.316%" y1="2.242%" y2="89.03%"><stop offset="0%" stop-color="#FFEA83"></stop><stop offset="8.333%" stop-color="#FFDD35"></stop><stop offset="100%" stop-color="#FFA800"></stop></linearGradient></defs><path fill="url(#IconifyId1813088fe1fbc01fb466)" d="M255.153 37.938L134.897 252.976c-2.483 4.44-8.862 4.466-11.382.048L.875 37.958c-2.746-4.814 1.371-10.646 6.827-9.67l120.385 21.517a6.537 6.537 0 0 0 2.322-.004l117.867-21.483c5.438-.991 9.574 4.796 6.877 9.62Z"></path><path fill="url(#IconifyId1813088fe1fbc01fb467)" d="M185.432.063L96.44 17.501a3.268 3.268 0 0 0-2.634 3.014l-5.474 92.456a3.268 3.268 0 0 0 3.997 3.378l24.777-5.718c2.318-.535 4.413 1.507 3.936 3.838l-7.361 36.047c-.495 2.426 1.782 4.5 4.151 3.78l15.304-4.649c2.372-.72 4.652 1.36 4.15 3.788l-11.698 56.621c-.732 3.542 3.979 5.473 5.943 2.437l1.313-2.028l72.516-144.72c1.215-2.423-.88-5.186-3.54-4.672l-25.505 4.922c-2.396.462-4.435-1.77-3.759-4.114l16.646-57.705c.677-2.35-1.37-4.583-3.769-4.113Z"></path></svg>
|
package/package.json
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "qmw-form-design",
|
|
3
|
+
"version": "0.0.1",
|
|
4
|
+
"description": "表单设计器",
|
|
5
|
+
"main": "./lib/qmw-form-design.js",
|
|
6
|
+
"keywords": ["qmw", "form-design"],
|
|
7
|
+
"license": "MIT",
|
|
8
|
+
"files": ["package.json","lib"],
|
|
9
|
+
"scripts": {
|
|
10
|
+
"dev": "vite",
|
|
11
|
+
"lib": "vite build --mode lib"
|
|
12
|
+
},
|
|
13
|
+
"dependencies": {
|
|
14
|
+
"@codemirror/lang-javascript": "^6.2.4",
|
|
15
|
+
"@codemirror/lint": "^6.8.5",
|
|
16
|
+
"@codemirror/theme-one-dark": "^6.1.3",
|
|
17
|
+
"@wangeditor/editor": "^5.1.23",
|
|
18
|
+
"@wangeditor/editor-for-vue": "^5.1.12",
|
|
19
|
+
"codemirror": "^6.0.2",
|
|
20
|
+
"less": "^4.3.0",
|
|
21
|
+
"lodash": "^4.17.21",
|
|
22
|
+
"pinia": "^3.0.3",
|
|
23
|
+
"pinyin": "^4.0.0",
|
|
24
|
+
"vue": "^3.5.18",
|
|
25
|
+
"vue-draggable-plus": "^0.6.0"
|
|
26
|
+
},
|
|
27
|
+
"devDependencies": {
|
|
28
|
+
"@vitejs/plugin-vue": "^5.2.4",
|
|
29
|
+
"vite": "^6.3.5"
|
|
30
|
+
}
|
|
31
|
+
}
|