@vipl520/dk-ui 1.0.28 → 1.0.29

Sign up to get free protection for your applications and to get access to all the features.
Files changed (61) hide show
  1. package/README.md +2 -2
  2. package/dist/index.js +698 -412
  3. package/dist/index.min.js +8 -8
  4. package/dist/index.min.js.map +1 -1
  5. package/dist/index.min.mjs +8 -8
  6. package/dist/index.min.mjs.map +1 -1
  7. package/dist/index.mjs +698 -412
  8. package/dist/web-types.json +1 -1
  9. package/es/page-diy/index.d.ts +1 -0
  10. package/es/page-diy/index.mjs +4 -0
  11. package/es/page-diy/index.mjs.map +1 -1
  12. package/es/page-diy/src/components/forms/DkEventCreateInput.vue.d.ts +36 -0
  13. package/es/page-diy/src/components/forms/DkEventCreateInput.vue.mjs +7 -0
  14. package/es/page-diy/src/components/forms/DkEventCreateInput.vue.mjs.map +1 -0
  15. package/es/page-diy/src/components/forms/DkEventCreateInput.vue2.mjs +81 -0
  16. package/es/page-diy/src/components/forms/DkEventCreateInput.vue2.mjs.map +1 -0
  17. package/es/page-diy/src/components/forms/DkEventSelectInput.vue.d.ts +38 -0
  18. package/es/page-diy/src/components/forms/DkEventSelectInput.vue.mjs +163 -0
  19. package/es/page-diy/src/components/forms/DkEventSelectInput.vue.mjs.map +1 -0
  20. package/es/page-diy/src/config/rule/web/common/DkViewDialog.d.ts +14 -0
  21. package/es/page-diy/src/config/rule/web/common/DkViewDialog.mjs +3 -9
  22. package/es/page-diy/src/config/rule/web/common/DkViewDialog.mjs.map +1 -1
  23. package/es/page-diy/src/config/rule/web/common/index.d.ts +28 -0
  24. package/es/page-diy/src/config/rule/web/index.d.ts +28 -0
  25. package/es/page-diy/src/page-diy.vue.d.ts +2 -0
  26. package/es/page-diy/src/page-diy.vue.mjs +3 -0
  27. package/es/page-diy/src/page-diy.vue.mjs.map +1 -1
  28. package/es/page-diy/src/utils/bus.d.ts +2 -0
  29. package/es/page-diy/src/utils/eventData.d.ts +32 -0
  30. package/es/page-diy/src/utils/eventData.mjs +51 -0
  31. package/es/page-diy/src/utils/eventData.mjs.map +1 -0
  32. package/es/page-diy/src/views/web/DkViewDialog.vue.d.ts +9 -0
  33. package/es/page-diy/src/views/web/DkViewDialog.vue.mjs +3 -1
  34. package/es/page-diy/src/views/web/DkViewDialog.vue.mjs.map +1 -1
  35. package/lib/page-diy/index.d.ts +1 -0
  36. package/lib/page-diy/index.js +4 -0
  37. package/lib/page-diy/index.js.map +1 -1
  38. package/lib/page-diy/src/components/forms/DkEventCreateInput.vue.d.ts +36 -0
  39. package/lib/page-diy/src/components/forms/DkEventCreateInput.vue.js +11 -0
  40. package/lib/page-diy/src/components/forms/DkEventCreateInput.vue.js.map +1 -0
  41. package/lib/page-diy/src/components/forms/DkEventCreateInput.vue2.js +85 -0
  42. package/lib/page-diy/src/components/forms/DkEventCreateInput.vue2.js.map +1 -0
  43. package/lib/page-diy/src/components/forms/DkEventSelectInput.vue.d.ts +38 -0
  44. package/lib/page-diy/src/components/forms/DkEventSelectInput.vue.js +167 -0
  45. package/lib/page-diy/src/components/forms/DkEventSelectInput.vue.js.map +1 -0
  46. package/lib/page-diy/src/config/rule/web/common/DkViewDialog.d.ts +14 -0
  47. package/lib/page-diy/src/config/rule/web/common/DkViewDialog.js +3 -9
  48. package/lib/page-diy/src/config/rule/web/common/DkViewDialog.js.map +1 -1
  49. package/lib/page-diy/src/config/rule/web/common/index.d.ts +28 -0
  50. package/lib/page-diy/src/config/rule/web/index.d.ts +28 -0
  51. package/lib/page-diy/src/page-diy.vue.d.ts +2 -0
  52. package/lib/page-diy/src/page-diy.vue.js +3 -0
  53. package/lib/page-diy/src/page-diy.vue.js.map +1 -1
  54. package/lib/page-diy/src/utils/bus.d.ts +2 -0
  55. package/lib/page-diy/src/utils/eventData.d.ts +32 -0
  56. package/lib/page-diy/src/utils/eventData.js +55 -0
  57. package/lib/page-diy/src/utils/eventData.js.map +1 -0
  58. package/lib/page-diy/src/views/web/DkViewDialog.vue.d.ts +9 -0
  59. package/lib/page-diy/src/views/web/DkViewDialog.vue.js +2 -0
  60. package/lib/page-diy/src/views/web/DkViewDialog.vue.js.map +1 -1
  61. package/package.json +3 -2
@@ -2,7 +2,7 @@
2
2
  "$schema": "http://json.schemastore.org/web-types",
3
3
  "framework": "vue",
4
4
  "name": "dk",
5
- "version": "1.0.27",
5
+ "version": "1.0.28",
6
6
  "js-types-syntax": "typescript",
7
7
  "description-markup": "markdown",
8
8
  "contributions": {
@@ -34,6 +34,7 @@ export declare const PageDiy: import("@vipl520/utils").WithInstall<import("vue")
34
34
  }, {
35
35
  countObj: import("vue").ComputedRef<{}>;
36
36
  diyTree: import("vue").ComputedRef<any[]>;
37
+ eventData: import("./src/utils/eventData").default;
37
38
  clear(type?: string): void;
38
39
  get(): {
39
40
  rule: any;
@@ -2,6 +2,8 @@ import { withInstall } from '@vipl520/utils';
2
2
  import _PageDiy from './src/page-diy.vue.mjs';
3
3
  import DragTool from './src/components/DragTool.vue.mjs';
4
4
  import DragBox from './src/components/DragBox.vue.mjs';
5
+ import DkEventCreateInput from './src/components/forms/DkEventCreateInput.vue.mjs';
6
+ import DkEventSelectInput from './src/components/forms/DkEventSelectInput.vue.mjs';
5
7
  import { designerForm, viewForm } from './src/utils/form.mjs';
6
8
  import draggable from 'vuedraggable/src/vuedraggable';
7
9
  import './src/utils/index.mjs';
@@ -15,6 +17,8 @@ const addComponent = (id, component) => {
15
17
  designerForm.component("Draggable", draggable);
16
18
  designerForm.component("DragTool", DragTool);
17
19
  designerForm.component("DragBox", DragBox);
20
+ designerForm.component("DkEventCreateInput", DkEventCreateInput);
21
+ designerForm.component("DkEventSelectInput", DkEventSelectInput);
18
22
  designerForm.register("_fc", {
19
23
  init(fc, rule) {
20
24
  rule._id = uniqueId();
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs","sources":["../../src/page-diy/index.ts"],"sourcesContent":["import { withInstall } from '@vipl520/utils'\nimport _PageDiy from './src/page-diy.vue'\nimport DragTool from './src/components/DragTool.vue'\nimport DragBox from './src/components/DragBox.vue'\nimport formCreate, { designerForm } from './src/utils/form'\nimport draggable from 'vuedraggable/src/vuedraggable'\nimport { uniqueId } from './src/utils'\n// import views from './src/views/web'\n\nconst addComponent = (id: any, component: any) => {\n designerForm.component(id, component)\n formCreate.component(id, component)\n}\n\ndesignerForm.component('Draggable', draggable)\ndesignerForm.component('DragTool', DragTool)\ndesignerForm.component('DragBox', DragBox)\n\n// for (const name in views) {\n// designerForm.component(name, views[name])\n// }\n\ndesignerForm.register('_fc', {\n init(fc: any, rule: any) {\n rule._id = uniqueId()\n if (fc.value) {\n rule.effect._fc = false\n }\n },\n})\n\ndesignerForm.register('_fc_tool', {\n init(_, rule: any) {\n rule.props.unique = uniqueId()\n },\n})\n\n_PageDiy.formCreate = formCreate\n_PageDiy.designerForm = designerForm\n_PageDiy.component = addComponent\nexport const PageDiy = withInstall(_PageDiy)\nexport default PageDiy\n\nexport * from './src/props'\n"],"names":["formCreate"],"mappings":";;;;;;;;;;AASA,MAAM,YAAA,GAAe,CAAC,EAAA,EAAS,SAAmB,KAAA;AAChD,EAAa,YAAA,CAAA,SAAA,CAAU,IAAI,SAAS,CAAA,CAAA;AACpC,EAAWA,QAAA,CAAA,SAAA,CAAU,IAAI,SAAS,CAAA,CAAA;AACpC,CAAA,CAAA;AAEA,YAAa,CAAA,SAAA,CAAU,aAAa,SAAS,CAAA,CAAA;AAC7C,YAAa,CAAA,SAAA,CAAU,YAAY,QAAQ,CAAA,CAAA;AAC3C,YAAa,CAAA,SAAA,CAAU,WAAW,OAAO,CAAA,CAAA;AAMzC,YAAA,CAAa,SAAS,KAAO,EAAA;AAAA,EAC3B,IAAA,CAAK,IAAS,IAAW,EAAA;AACvB,IAAA,IAAA,CAAK,MAAM,QAAS,EAAA,CAAA;AACpB,IAAA,IAAI,GAAG,KAAO,EAAA;AACZ,MAAA,IAAA,CAAK,OAAO,GAAM,GAAA,KAAA,CAAA;AAAA,KACpB;AAAA,GACF;AACF,CAAC,CAAA,CAAA;AAED,YAAA,CAAa,SAAS,UAAY,EAAA;AAAA,EAChC,IAAA,CAAK,GAAG,IAAW,EAAA;AACjB,IAAK,IAAA,CAAA,KAAA,CAAM,SAAS,QAAS,EAAA,CAAA;AAAA,GAC/B;AACF,CAAC,CAAA,CAAA;AAED,QAAA,CAAS,UAAa,GAAAA,QAAA,CAAA;AACtB,QAAA,CAAS,YAAe,GAAA,YAAA,CAAA;AACxB,QAAA,CAAS,SAAY,GAAA,YAAA,CAAA;AACR,MAAA,OAAA,GAAU,YAAY,QAAQ;;;;"}
1
+ {"version":3,"file":"index.mjs","sources":["../../src/page-diy/index.ts"],"sourcesContent":["import { withInstall } from '@vipl520/utils'\nimport _PageDiy from './src/page-diy.vue'\nimport DragTool from './src/components/DragTool.vue'\nimport DragBox from './src/components/DragBox.vue'\nimport DkEventCreateInput from './src/components/forms/DkEventCreateInput.vue'\nimport DkEventSelectInput from './src/components/forms/DkEventSelectInput.vue'\nimport formCreate, { designerForm } from './src/utils/form'\nimport draggable from 'vuedraggable/src/vuedraggable'\nimport { uniqueId } from './src/utils'\n// import views from './src/views/web'\n\nconst addComponent = (id: any, component: any) => {\n designerForm.component(id, component)\n formCreate.component(id, component)\n}\n\ndesignerForm.component('Draggable', draggable)\ndesignerForm.component('DragTool', DragTool)\ndesignerForm.component('DragBox', DragBox)\ndesignerForm.component('DkEventCreateInput', DkEventCreateInput)\ndesignerForm.component('DkEventSelectInput', DkEventSelectInput)\n\n// for (const name in views) {\n// designerForm.component(name, views[name])\n// }\n\ndesignerForm.register('_fc', {\n init(fc: any, rule: any) {\n rule._id = uniqueId()\n if (fc.value) {\n rule.effect._fc = false\n }\n },\n})\n\ndesignerForm.register('_fc_tool', {\n init(_, rule: any) {\n rule.props.unique = uniqueId()\n },\n})\n\n_PageDiy.formCreate = formCreate\n_PageDiy.designerForm = designerForm\n_PageDiy.component = addComponent\nexport const PageDiy = withInstall(_PageDiy)\nexport default PageDiy\n\nexport * from './src/props'\n"],"names":["formCreate"],"mappings":";;;;;;;;;;;;AAWA,MAAM,YAAA,GAAe,CAAC,EAAA,EAAS,SAAmB,KAAA;AAChD,EAAa,YAAA,CAAA,SAAA,CAAU,IAAI,SAAS,CAAA,CAAA;AACpC,EAAWA,QAAA,CAAA,SAAA,CAAU,IAAI,SAAS,CAAA,CAAA;AACpC,CAAA,CAAA;AAEA,YAAa,CAAA,SAAA,CAAU,aAAa,SAAS,CAAA,CAAA;AAC7C,YAAa,CAAA,SAAA,CAAU,YAAY,QAAQ,CAAA,CAAA;AAC3C,YAAa,CAAA,SAAA,CAAU,WAAW,OAAO,CAAA,CAAA;AACzC,YAAa,CAAA,SAAA,CAAU,sBAAsB,kBAAkB,CAAA,CAAA;AAC/D,YAAa,CAAA,SAAA,CAAU,sBAAsB,kBAAkB,CAAA,CAAA;AAM/D,YAAA,CAAa,SAAS,KAAO,EAAA;AAAA,EAC3B,IAAA,CAAK,IAAS,IAAW,EAAA;AACvB,IAAA,IAAA,CAAK,MAAM,QAAS,EAAA,CAAA;AACpB,IAAA,IAAI,GAAG,KAAO,EAAA;AACZ,MAAA,IAAA,CAAK,OAAO,GAAM,GAAA,KAAA,CAAA;AAAA,KACpB;AAAA,GACF;AACF,CAAC,CAAA,CAAA;AAED,YAAA,CAAa,SAAS,UAAY,EAAA;AAAA,EAChC,IAAA,CAAK,GAAG,IAAW,EAAA;AACjB,IAAK,IAAA,CAAA,KAAA,CAAM,SAAS,QAAS,EAAA,CAAA;AAAA,GAC/B;AACF,CAAC,CAAA,CAAA;AAED,QAAA,CAAS,UAAa,GAAAA,QAAA,CAAA;AACtB,QAAA,CAAS,YAAe,GAAA,YAAA,CAAA;AACxB,QAAA,CAAS,SAAY,GAAA,YAAA,CAAA;AACR,MAAA,OAAA,GAAU,YAAY,QAAQ;;;;"}
@@ -0,0 +1,36 @@
1
+ declare const _default: import("vue").DefineComponent<{
2
+ modelValue: {
3
+ default: string;
4
+ type: StringConstructor;
5
+ };
6
+ placeholder: {
7
+ default: string;
8
+ type: StringConstructor;
9
+ };
10
+ label: {
11
+ default: string;
12
+ type: StringConstructor;
13
+ };
14
+ }, {}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("input" | "update:modelValue" | "change")[], "input" | "update:modelValue" | "change", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
15
+ modelValue: {
16
+ default: string;
17
+ type: StringConstructor;
18
+ };
19
+ placeholder: {
20
+ default: string;
21
+ type: StringConstructor;
22
+ };
23
+ label: {
24
+ default: string;
25
+ type: StringConstructor;
26
+ };
27
+ }>> & {
28
+ onInput?: ((...args: any[]) => any) | undefined;
29
+ "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
30
+ onChange?: ((...args: any[]) => any) | undefined;
31
+ }, {
32
+ modelValue: string;
33
+ label: string;
34
+ placeholder: string;
35
+ }, {}>;
36
+ export default _default;
@@ -0,0 +1,7 @@
1
+ import _sfc_main from './DkEventCreateInput.vue2.mjs';
2
+ import _export_sfc from '../../../../_virtual/_plugin-vue_export-helper.mjs';
3
+
4
+ var DkEventCreateInput = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "E:\\project\\monster-admin\\system\\dkgs-ui-back\\packages\\dk-ui\\src\\page-diy\\src\\components\\forms\\DkEventCreateInput.vue"]]);
5
+
6
+ export { DkEventCreateInput as default };
7
+ //# sourceMappingURL=DkEventCreateInput.vue.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DkEventCreateInput.vue.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;"}
@@ -0,0 +1,81 @@
1
+ import { defineComponent, ref, watch, resolveComponent, openBlock, createElementBlock, createVNode, withCtx, createTextVNode } from 'vue';
2
+
3
+ const __default__ = defineComponent({
4
+ name: "DkEventCreateInput"
5
+ });
6
+ var _sfc_main = /* @__PURE__ */ defineComponent({
7
+ ...__default__,
8
+ props: {
9
+ modelValue: {
10
+ default: "",
11
+ type: String
12
+ },
13
+ placeholder: {
14
+ default: "",
15
+ type: String
16
+ },
17
+ label: {
18
+ default: "",
19
+ type: String
20
+ }
21
+ },
22
+ emits: ["input", "update:modelValue", "change"],
23
+ setup(__props, { emit }) {
24
+ const props = __props;
25
+ const data = ref(props.modelValue || "");
26
+ watch(
27
+ () => props.modelValue,
28
+ (val) => {
29
+ data.value = val;
30
+ }
31
+ );
32
+ watch(
33
+ () => data.value,
34
+ (val) => {
35
+ emit("change", val);
36
+ emit("update:modelValue", val);
37
+ emit("input", val);
38
+ }
39
+ );
40
+ const randomString = (e) => {
41
+ e = e || 32;
42
+ const t = "ABCDEFGHJKMNPQRSTWXYZabcdefhijkmnprstwxyz2345678";
43
+ const a = t.length;
44
+ let n = "";
45
+ for (let i = 0; i < e; i++) {
46
+ n += t.charAt(Math.floor(Math.random() * a));
47
+ }
48
+ return n;
49
+ };
50
+ const onClick = () => {
51
+ data.value = randomString(6);
52
+ };
53
+ return (_ctx, _cache) => {
54
+ const _component_el_button = resolveComponent("el-button");
55
+ const _component_el_input = resolveComponent("el-input");
56
+ return openBlock(), createElementBlock("div", null, [
57
+ createVNode(_component_el_input, {
58
+ modelValue: data.value,
59
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => data.value = $event),
60
+ placeholder: __props.placeholder,
61
+ clearable: ""
62
+ }, {
63
+ append: withCtx(() => [
64
+ createVNode(_component_el_button, { onClick }, {
65
+ default: withCtx(() => [
66
+ createTextVNode("\u968F\u673A")
67
+ ]),
68
+ _: 1
69
+ /* STABLE */
70
+ })
71
+ ]),
72
+ _: 1
73
+ /* STABLE */
74
+ }, 8, ["modelValue", "placeholder"])
75
+ ]);
76
+ };
77
+ }
78
+ });
79
+
80
+ export { _sfc_main as default };
81
+ //# sourceMappingURL=DkEventCreateInput.vue2.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DkEventCreateInput.vue2.mjs","sources":["../../../../../src/page-diy/src/components/forms/DkEventCreateInput.vue"],"sourcesContent":["<script lang=\"ts\">\nimport { defineComponent as __MACROS_defineComponent } from \"vue\";\nexport default /*#__PURE__*/ __MACROS_defineComponent({\n name: 'DkEventCreateInput',\n});\n</script>\n<template>\n <div>\n <el-input v-model=\"data\" :placeholder=\"placeholder\" clearable>\n <template #append>\n <el-button @click=\"onClick\">随机</el-button>\n </template>\n </el-input>\n </div>\n</template>\n\n<script lang=\"ts\" setup>\nimport { ref, watch } from 'vue'\n\n\n\nconst props = defineProps({\n modelValue: {\n default: '',\n type: String,\n },\n placeholder: {\n default: '',\n type: String,\n },\n label: {\n default: '',\n type: String,\n },\n})\n\nconst data = ref(props.modelValue || '')\n\nconst emit = defineEmits(['input', 'update:modelValue', 'change'])\nwatch(\n () => props.modelValue,\n (val) => {\n data.value = val\n }\n)\nwatch(\n () => data.value,\n (val) => {\n emit('change', val)\n emit('update:modelValue', val)\n emit('input', val)\n }\n)\n\nconst randomString = (e: any) => {\n e = e || 32\n const t = 'ABCDEFGHJKMNPQRSTWXYZabcdefhijkmnprstwxyz2345678'\n const a = t.length\n let n = ''\n for (let i = 0; i < e; i++) {\n n += t.charAt(Math.floor(Math.random() * a))\n }\n return n\n}\nconst onClick = () => {\n data.value = randomString(6)\n}\n</script>\n\n<style scoped lang=\"scss\"></style>\n"],"names":["__MACROS_defineComponent"],"mappings":";;AAEA,MAA6B,cAAAA,eAAyB,CAAA;AAAA,EACpD,IAAM,EAAA,oBAAA;AACR,CAAC,CAAA,CAAA;;;;;;;;;;;;;;;;;;;;AAgCD,IAAA,MAAM,IAAO,GAAA,GAAA,CAAI,KAAM,CAAA,UAAA,IAAc,EAAE,CAAA,CAAA;AAGvC,IAAA,KAAA;AAAA,MACE,MAAM,KAAM,CAAA,UAAA;AAAA,MACZ,CAAC,GAAQ,KAAA;AACP,QAAA,IAAA,CAAK,KAAQ,GAAA,GAAA,CAAA;AAAA,OACf;AAAA,KACF,CAAA;AACA,IAAA,KAAA;AAAA,MACE,MAAM,IAAK,CAAA,KAAA;AAAA,MACX,CAAC,GAAQ,KAAA;AACP,QAAA,IAAA,CAAK,UAAU,GAAG,CAAA,CAAA;AAClB,QAAA,IAAA,CAAK,qBAAqB,GAAG,CAAA,CAAA;AAC7B,QAAA,IAAA,CAAK,SAAS,GAAG,CAAA,CAAA;AAAA,OACnB;AAAA,KACF,CAAA;AAEA,IAAM,MAAA,YAAA,GAAe,CAAC,CAAW,KAAA;AAC/B,MAAA,CAAA,GAAI,CAAK,IAAA,EAAA,CAAA;AACT,MAAA,MAAM,CAAI,GAAA,kDAAA,CAAA;AACV,MAAA,MAAM,IAAI,CAAE,CAAA,MAAA,CAAA;AACZ,MAAA,IAAI,CAAI,GAAA,EAAA,CAAA;AACR,MAAA,KAAA,IAAS,CAAI,GAAA,CAAA,EAAG,CAAI,GAAA,CAAA,EAAG,CAAK,EAAA,EAAA;AAC1B,QAAK,CAAA,IAAA,CAAA,CAAE,OAAO,IAAK,CAAA,KAAA,CAAM,KAAK,MAAO,EAAA,GAAI,CAAC,CAAC,CAAA,CAAA;AAAA,OAC7C;AACA,MAAO,OAAA,CAAA,CAAA;AAAA,KACT,CAAA;AACA,IAAA,MAAM,UAAU,MAAM;AACpB,MAAK,IAAA,CAAA,KAAA,GAAQ,aAAa,CAAC,CAAA,CAAA;AAAA,KAC7B,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -0,0 +1,38 @@
1
+ declare const _default: import("vue").DefineComponent<{
2
+ modelValue: {
3
+ default: string;
4
+ type: StringConstructor;
5
+ };
6
+ placeholder: {
7
+ default: string;
8
+ type: StringConstructor;
9
+ };
10
+ }, any, {
11
+ data: string;
12
+ loading: boolean;
13
+ eventData: never[];
14
+ }, {
15
+ EventData(): any;
16
+ children(): any;
17
+ }, {
18
+ updateEvent(): void;
19
+ onClick(): void;
20
+ randomString(e: any): string;
21
+ onUpdateEvent(): void;
22
+ findDkEventCreateInput(data: any, propsData: any): any[];
23
+ }, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, "update:modelValue"[], "update:modelValue", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
24
+ modelValue: {
25
+ default: string;
26
+ type: StringConstructor;
27
+ };
28
+ placeholder: {
29
+ default: string;
30
+ type: StringConstructor;
31
+ };
32
+ }>> & {
33
+ "onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
34
+ }, {
35
+ modelValue: string;
36
+ placeholder: string;
37
+ }, {}>;
38
+ export default _default;
@@ -0,0 +1,163 @@
1
+ import { resolveComponent, openBlock, createElementBlock, createVNode, withCtx, Fragment, renderList, createBlock, createElementVNode, toDisplayString, createTextVNode } from 'vue';
2
+ import _export_sfc from '../../../../_virtual/_plugin-vue_export-helper.mjs';
3
+
4
+ const _sfc_main = {
5
+ name: 'DkEventSelectInput',
6
+ inject: ['diy'],
7
+ props: {
8
+ modelValue: {
9
+ default: '',
10
+ type: String,
11
+ },
12
+ placeholder: {
13
+ default: '',
14
+ type: String,
15
+ },
16
+ },
17
+ emits: ['update:modelValue'],
18
+ data() {
19
+ return {
20
+ data: '',
21
+ loading: false,
22
+ eventData: [],
23
+ }
24
+ },
25
+ computed: {
26
+ EventData() {
27
+ return this.diy.proxy.eventData
28
+ },
29
+ children() {
30
+ return this.diy.proxy.children
31
+ },
32
+ },
33
+ watch: {
34
+ data() {
35
+ this.$emit('update:modelValue', this.data);
36
+ },
37
+ },
38
+ mounted() {
39
+ this.data = this.modelValue || '';
40
+ this.updateEvent();
41
+ },
42
+ methods: {
43
+ updateEvent() {
44
+ this.loading = true;
45
+ this.EventData.removeAllEvent();
46
+ this.onUpdateEvent();
47
+ this.loading = false;
48
+ },
49
+ onClick() {
50
+ this.data = this.randomString(10);
51
+ },
52
+ randomString(e) {
53
+ e = e || 32;
54
+ const t = 'ABCDEFGHJKMNPQRSTWXYZabcdefhijkmnprstwxyz2345678';
55
+ const a = t.length;
56
+ let n = '';
57
+ for (let i = 0; i < e; i++) {
58
+ n += t.charAt(Math.floor(Math.random() * a));
59
+ }
60
+ return n
61
+ },
62
+ // 更新事件
63
+ onUpdateEvent() {
64
+ for (let i = 0; i < this.children.length; i++) {
65
+ if (this.children[i].children.length > 0) {
66
+ // 当前节点
67
+ const children = this.children[i].children[0];
68
+ // 当前节点的props数据
69
+ const propsData = children.props;
70
+ // 当前节点的配置数据
71
+ const config = children.config.config;
72
+ const isEvent = config.event || false;
73
+ if (isEvent) {
74
+ // 表单配置数据
75
+ const eventProps = config.props();
76
+ this.findDkEventCreateInput(eventProps, propsData).forEach((item) => {
77
+ const data = {
78
+ id: children._id,
79
+ label: item.props?.label || config.label,
80
+ value: propsData[item.field],
81
+ };
82
+ if (data.value && data.id && data.label) {
83
+ this.EventData.addEvent(data);
84
+ }
85
+ });
86
+ }
87
+ }
88
+ }
89
+ this.eventData = this.EventData.getAllEvents();
90
+ },
91
+ // 寻找事件
92
+ findDkEventCreateInput(data, propsData) {
93
+ const result = [];
94
+ data.forEach((element) => {
95
+ if (element.children) {
96
+ result.push(...this.findDkEventCreateInput(element.children));
97
+ }
98
+ if (element.control && Array.isArray(element.control)) {
99
+ element.control.forEach((control) => {
100
+ if (control.rule.length > 0) {
101
+ result.push(...this.findDkEventCreateInput(control.rule));
102
+ }
103
+ });
104
+ }
105
+ if (element.type === 'DkEventCreateInput') {
106
+ result.push(element);
107
+ }
108
+ });
109
+ return result
110
+ },
111
+ },
112
+ };
113
+
114
+ const _hoisted_1 = { style: {"display":"flex"} };
115
+ const _hoisted_2 = { style: {"float":"left"} };
116
+ const _hoisted_3 = { style: {"float":"right","color":"#8492a6","font-size":"13px"} };
117
+
118
+ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
119
+ const _component_el_option = resolveComponent("el-option");
120
+ const _component_el_select = resolveComponent("el-select");
121
+ const _component_el_button = resolveComponent("el-button");
122
+
123
+ return (openBlock(), createElementBlock("div", _hoisted_1, [
124
+ createVNode(_component_el_select, {
125
+ modelValue: $data.data,
126
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = $event => (($data.data) = $event)),
127
+ placeholder: "请选择要触发事件",
128
+ style: {"width":"100%"},
129
+ "allow-create": "",
130
+ filterable: ""
131
+ }, {
132
+ default: withCtx(() => [
133
+ (openBlock(true), createElementBlock(Fragment, null, renderList($data.eventData, (item) => {
134
+ return (openBlock(), createBlock(_component_el_option, {
135
+ key: item.value,
136
+ label: item.label + '(' + item.value + ')',
137
+ value: item.value
138
+ }, {
139
+ default: withCtx(() => [
140
+ createElementVNode("span", _hoisted_2, toDisplayString(item.label), 1 /* TEXT */),
141
+ createElementVNode("span", _hoisted_3, toDisplayString(item.value), 1 /* TEXT */)
142
+ ]),
143
+ _: 2 /* DYNAMIC */
144
+ }, 1032 /* PROPS, DYNAMIC_SLOTS */, ["label", "value"]))
145
+ }), 128 /* KEYED_FRAGMENT */))
146
+ ]),
147
+ _: 1 /* STABLE */
148
+ }, 8 /* PROPS */, ["modelValue"]),
149
+ createVNode(_component_el_button, {
150
+ loading: $data.loading,
151
+ onClick: $options.updateEvent
152
+ }, {
153
+ default: withCtx(() => [
154
+ createTextVNode("刷新")
155
+ ]),
156
+ _: 1 /* STABLE */
157
+ }, 8 /* PROPS */, ["loading", "onClick"])
158
+ ]))
159
+ }
160
+ var DkEventSelectInput = /*#__PURE__*/_export_sfc(_sfc_main, [['render',_sfc_render],['__file',"E:\\project\\monster-admin\\system\\dkgs-ui-back\\packages\\dk-ui\\src\\page-diy\\src\\components\\forms\\DkEventSelectInput.vue"]]);
161
+
162
+ export { DkEventSelectInput as default };
163
+ //# sourceMappingURL=DkEventSelectInput.vue.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"DkEventSelectInput.vue.mjs","sources":["../../../../../src/page-diy/src/components/forms/DkEventSelectInput.vue"],"sourcesContent":["<template>\n <div style=\"display: flex\">\n <el-select v-model=\"data\" placeholder=\"请选择要触发事件\" style=\"width: 100%\" allow-create filterable>\n <el-option\n v-for=\"item in eventData\"\n :key=\"item.value\"\n :label=\"item.label + '(' + item.value + ')'\"\n :value=\"item.value\"\n >\n <span style=\"float: left\">{{ item.label }}</span>\n <span style=\"float: right; color: #8492a6; font-size: 13px\">{{ item.value }}</span>\n </el-option>\n </el-select>\n <el-button :loading=\"loading\" @click=\"updateEvent\">刷新</el-button>\n </div>\n</template>\n\n<script>\nexport default {\n name: 'DkEventSelectInput',\n inject: ['diy'],\n props: {\n modelValue: {\n default: '',\n type: String,\n },\n placeholder: {\n default: '',\n type: String,\n },\n },\n emits: ['update:modelValue'],\n data() {\n return {\n data: '',\n loading: false,\n eventData: [],\n }\n },\n computed: {\n EventData() {\n return this.diy.proxy.eventData\n },\n children() {\n return this.diy.proxy.children\n },\n },\n watch: {\n data() {\n this.$emit('update:modelValue', this.data)\n },\n },\n mounted() {\n this.data = this.modelValue || ''\n this.updateEvent()\n },\n methods: {\n updateEvent() {\n this.loading = true\n this.EventData.removeAllEvent()\n this.onUpdateEvent()\n this.loading = false\n },\n onClick() {\n this.data = this.randomString(10)\n },\n randomString(e) {\n e = e || 32\n const t = 'ABCDEFGHJKMNPQRSTWXYZabcdefhijkmnprstwxyz2345678'\n const a = t.length\n let n = ''\n for (let i = 0; i < e; i++) {\n n += t.charAt(Math.floor(Math.random() * a))\n }\n return n\n },\n // 更新事件\n onUpdateEvent() {\n for (let i = 0; i < this.children.length; i++) {\n if (this.children[i].children.length > 0) {\n // 当前节点\n const children = this.children[i].children[0]\n // 当前节点的props数据\n const propsData = children.props\n // 当前节点的配置数据\n const config = children.config.config\n const isEvent = config.event || false\n if (isEvent) {\n // 表单配置数据\n const eventProps = config.props()\n this.findDkEventCreateInput(eventProps, propsData).forEach((item) => {\n const data = {\n id: children._id,\n label: item.props?.label || config.label,\n value: propsData[item.field],\n }\n if (data.value && data.id && data.label) {\n this.EventData.addEvent(data)\n }\n })\n }\n }\n }\n this.eventData = this.EventData.getAllEvents()\n },\n // 寻找事件\n findDkEventCreateInput(data, propsData) {\n const result = []\n data.forEach((element) => {\n if (element.children) {\n result.push(...this.findDkEventCreateInput(element.children))\n }\n if (element.control && Array.isArray(element.control)) {\n element.control.forEach((control) => {\n if (control.rule.length > 0) {\n result.push(...this.findDkEventCreateInput(control.rule))\n }\n })\n }\n if (element.type === 'DkEventCreateInput') {\n result.push(element)\n }\n })\n return result\n },\n },\n}\n</script>\n"],"names":["_openBlock","_createElementBlock","_createVNode","_Fragment","_renderList","_createBlock","_createElementVNode","_toDisplayString"],"mappings":";;;AAkBA,MAAK,SAAU,GAAA;EACb,IAAI,EAAE,oBAAoB;AAC1B,EAAA,MAAM,EAAE,CAAC,KAAK,CAAC;AACf,EAAA,KAAK,EAAE;IACL,UAAU,EAAE;MACV,OAAO,EAAE,EAAE;MACX,IAAI,EAAE,MAAM;KACb;IACD,WAAW,EAAE;MACX,OAAO,EAAE,EAAE;MACX,IAAI,EAAE,MAAM;KACb;GACF;EACD,KAAK,EAAE,CAAC,mBAAmB,CAAC;AAC5B,EAAA,IAAI,GAAG;AACL,IAAA,OAAO;AACL,MAAA,IAAI,EAAE,EAAE;MACR,OAAO,EAAE,KAAK;MACd,SAAS,EAAE,EAAE;AACf,KAAA;GACD;AACD,EAAA,QAAQ,EAAE;IACR,SAAS,GAAG;MACV,OAAO,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC,SAAQ;KAC/B;IACD,QAAQ,GAAG;MACT,OAAO,IAAI,CAAC,GAAG,CAAC,KAAK,CAAC,QAAO;KAC9B;GACF;AACD,EAAA,KAAK,EAAE;AACL,IAAA,IAAI,GAAG;AACL,MAAA,IAAI,CAAC,KAAK,CAAC,mBAAmB,EAAE,IAAI,CAAC,IAAI,EAAA;KAC1C;GACF;AACD,EAAA,OAAO,GAAG;IACR,IAAI,CAAC,IAAK,GAAE,IAAI,CAAC,UAAS,IAAK,GAAC;AAChC,IAAA,IAAI,CAAC,WAAW,GAAC;GAClB;AACD,EAAA,OAAO,EAAE;IACP,WAAW,GAAG;AACZ,MAAA,IAAI,CAAC,OAAM,GAAI,KAAG;AAClB,MAAA,IAAI,CAAC,SAAS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MAAnF,EAAA,UAAmF,EAApBC,eAAA,CAAA,IAAI,CAAC,KAAK,CAAA,EAAA,CAAA,YAAA;;;;;;;;IAG7EL,WAAiE,CAAA,oBAAA,EAAA;AAArD,MAAA,OAAO,EAAE,KAAO,CAAA,OAAA;AAAG,MAAA,OAAK,EAAE,QAAW,CAAA,WAAA;;uBAAE,MAAE;wBAAF,IAAE,CAAA;;;;;;;;;;"}
@@ -7,11 +7,24 @@ declare namespace _default {
7
7
  type: string;
8
8
  props: {
9
9
  title: string;
10
+ listen: string;
10
11
  };
11
12
  showStyle: boolean;
12
13
  fixed: boolean;
13
14
  };
14
15
  export function props(): ({
16
+ type: string;
17
+ field: string;
18
+ title: string;
19
+ value: string;
20
+ props: {
21
+ label: string;
22
+ buttonText?: undefined;
23
+ };
24
+ effect?: undefined;
25
+ options?: undefined;
26
+ control?: undefined;
27
+ } | {
15
28
  type: string;
16
29
  field: string;
17
30
  title: string;
@@ -26,6 +39,7 @@ declare namespace _default {
26
39
  title: string;
27
40
  props: {
28
41
  buttonText: string;
42
+ label?: undefined;
29
43
  };
30
44
  value: string;
31
45
  effect?: undefined;
@@ -9,7 +9,8 @@ var DkViewDialog = {
9
9
  return {
10
10
  type: name,
11
11
  props: {
12
- title: "\u901A\u77E5"
12
+ title: "\u901A\u77E5",
13
+ listen: ""
13
14
  },
14
15
  showStyle: true,
15
16
  fixed: true
@@ -17,14 +18,7 @@ var DkViewDialog = {
17
18
  },
18
19
  props() {
19
20
  return [
20
- // TODO 待完善
21
- // {
22
- // type: 'DkEventCreateInput',
23
- // field: 'listen',
24
- // title: '监听事件',
25
- // value: '',
26
- // props: { label: '弹窗组件' },
27
- // },
21
+ { type: "DkEventCreateInput", field: "listen", title: "\u76D1\u542C\u4E8B\u4EF6", value: "", props: { label: "\u5F39\u7A97\u7EC4\u4EF6" } },
28
22
  { type: "input", field: "title", title: "\u5F39\u7A97\u6807\u9898", value: "\u901A\u77E5" },
29
23
  {
30
24
  type: "dk-tiny-editor",
@@ -1 +1 @@
1
- {"version":3,"file":"DkViewDialog.mjs","sources":["../../../../../../../src/page-diy/src/config/rule/web/common/DkViewDialog.js"],"sourcesContent":["const label = '弹窗组件'\nconst name = 'DkViewDialog'\nexport default {\n icon: 'mi:window',\n label,\n name,\n event: true,\n rule() {\n return {\n type: name,\n props: {\n title: '通知',\n },\n showStyle: true,\n fixed: true,\n }\n },\n props() {\n return [\n // TODO 待完善\n // {\n // type: 'DkEventCreateInput',\n // field: 'listen',\n // title: '监听事件',\n // value: '',\n // props: { label: '弹窗组件' },\n // },\n { type: 'input', field: 'title', title: '弹窗标题', value: '通知' },\n {\n type: 'dk-tiny-editor',\n field: 'content',\n title: '弹窗内容',\n props: {\n buttonText: '编辑弹窗内容',\n },\n value: '',\n },\n { type: 'input', field: 'confirmText', title: '按钮文字', value: '确定' },\n {\n type: 'switch',\n field: 'show',\n title: '预览',\n value: false,\n effect: {\n help: '当前为预览按钮,不影响实际显示,点击后在预览窗口点确定即可关闭',\n },\n },\n {\n type: 'radio',\n field: 'copy',\n title: '复制内容',\n value: '0',\n options: [\n { label: '不复制', value: '0' },\n { label: '复制弹窗内容', value: '1' },\n {\n label: '复制自定义内容',\n value: '2',\n },\n ],\n control: [\n {\n value: '2',\n rule: [\n {\n type: 'select',\n field: 'copyType',\n title: '复制类型',\n value: 'text',\n options: [\n { label: '纯文本', value: 'text' },\n { label: '富文本', value: 'html' },\n ],\n control: [\n {\n value: 'text',\n rule: [\n {\n type: 'input',\n field: 'copyText',\n title: '复制内容',\n value: '',\n props: { type: 'textarea' },\n },\n ],\n },\n {\n value: 'html',\n rule: [\n {\n type: 'dk-tiny-editor',\n field: 'copyHtml',\n title: '复制内容',\n value: '',\n },\n ],\n },\n ],\n },\n ],\n },\n {\n handle: function (val) {\n return val !== ''\n },\n rule: [\n {\n type: 'input',\n field: 'copySuccessToast',\n title: '复制提示',\n value: '复制成功',\n effect: { help: '复制成功后的提示,不填则不显示' },\n },\n ],\n },\n ],\n },\n ]\n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A,aACF;AAAA,WACF;AAAA,UACA;AAAA,YACE,MAAA,EAAQ,SAAU,GAAK,EAAA;AACrB,cAAA,OAAO,GAAQ,KAAA,EAAA,CAAA;AAAA,aACjB;AAAA,YACA,IAAM,EAAA;AAAA,cACJ;AAAA,gBACE,IAAM,EAAA,OAAA;AAAA,gBACN,KAAO,EAAA,kBAAA;AAAA,gBACP,KAAO,EAAA,0BAAA;AAAA,gBACP,KAAO,EAAA,0BAAA;AAAA,gBACP,MAAA,EAAQ,EAAE,IAAA,EAAM,uFAAkB,EAAA;AAAA,eACpC;AAAA,aACF;AAAA,WACF;AAAA,SACF;AAAA,OACF;AAAA,KACF,CAAA;AAAA,GACF;AACF,CAAA;;;;"}
1
+ {"version":3,"file":"DkViewDialog.mjs","sources":["../../../../../../../src/page-diy/src/config/rule/web/common/DkViewDialog.js"],"sourcesContent":["const label = '弹窗组件'\nconst name = 'DkViewDialog'\nexport default {\n icon: 'mi:window',\n label,\n name,\n event: true,\n rule() {\n return {\n type: name,\n props: {\n title: '通知',\n listen: '',\n },\n showStyle: true,\n fixed: true,\n }\n },\n props() {\n return [\n { type: 'DkEventCreateInput', field: 'listen', title: '监听事件', value: '', props: { label: '弹窗组件' } },\n { type: 'input', field: 'title', title: '弹窗标题', value: '通知' },\n {\n type: 'dk-tiny-editor',\n field: 'content',\n title: '弹窗内容',\n props: {\n buttonText: '编辑弹窗内容',\n },\n value: '',\n },\n { type: 'input', field: 'confirmText', title: '按钮文字', value: '确定' },\n {\n type: 'switch',\n field: 'show',\n title: '预览',\n value: false,\n effect: {\n help: '当前为预览按钮,不影响实际显示,点击后在预览窗口点确定即可关闭',\n },\n },\n {\n type: 'radio',\n field: 'copy',\n title: '复制内容',\n value: '0',\n options: [\n { label: '不复制', value: '0' },\n { label: '复制弹窗内容', value: '1' },\n {\n label: '复制自定义内容',\n value: '2',\n },\n ],\n control: [\n {\n value: '2',\n rule: [\n {\n type: 'select',\n field: 'copyType',\n title: '复制类型',\n value: 'text',\n options: [\n { label: '纯文本', value: 'text' },\n { label: '富文本', value: 'html' },\n ],\n control: [\n {\n value: 'text',\n rule: [\n {\n type: 'input',\n field: 'copyText',\n title: '复制内容',\n value: '',\n props: { type: 'textarea' },\n },\n ],\n },\n {\n value: 'html',\n rule: [\n {\n type: 'dk-tiny-editor',\n field: 'copyHtml',\n title: '复制内容',\n value: '',\n },\n ],\n },\n ],\n },\n ],\n },\n {\n handle: function (val) {\n return val !== ''\n },\n rule: [\n {\n type: 'input',\n field: 'copySuccessToast',\n title: '复制提示',\n value: '复制成功',\n effect: { help: '复制成功后的提示,不填则不显示' },\n },\n ],\n },\n ],\n },\n ]\n },\n}\n"],"names":[],"mappings":"AAAA,MAAM,KAAQ,GAAA,0BAAA,CAAA;AACd,MAAM,IAAO,GAAA,cAAA,CAAA;AACb,mBAAe;AAAA,EACb,IAAM,EAAA,WAAA;AAAA,EACN,KAAA;AAAA,EACA,IAAA;AAAA,EACA,KAAO,EAAA,IAAA;AAAA,EACP,IAAO,GAAA;AACL,IAAO,OAAA;AAAA,MACL,IAAM,EAAA,IAAA;AAAA,MACN,KAAO,EAAA;AAAA,QACL,KAAO,EAAA,cAAA;AAAA,QACP,MAAQ,EAAA,EAAA;AAAA,OACV;AAAA,MACA,SAAW,EAAA,IAAA;AAAA,MACX,KAAO,EAAA,IAAA;AAAA,KACT,CAAA;AAAA,GACF;AAAA,EACA,KAAQ,GAAA;AACN,IAAO,OAAA;AAAA,MACL,EAAE,IAAA,EAAM,oBAAsB,EAAA,KAAA,EAAO,QAAU,EAAA,KAAA,EAAO,0BAAQ,EAAA,KAAA,EAAO,EAAI,EAAA,KAAA,EAAO,EAAE,KAAA,EAAO,4BAAS,EAAA;AAAA,MAClG,EAAE,MAAM,OAAS,EAAA,KAAA,EAAO,SAAS,KAAO,EAAA,0BAAA,EAAQ,OAAO,cAAK,EAAA;AAAA,MAC5D;AAAA,QACE,IAAM,EAAA,gBAAA;AAAA,QACN,KAAO,EAAA,SAAA;AAAA,QAC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P;AAAA,oBACE,KAAO,EAAA,MAAA;AAAA,oBACP,IAAM,EAAA;AAAA,sBACJ;AAAA,wBACE,IAAM,EAAA,OAAA;AAAA,wBACN,KAAO,EAAA,UAAA;AAAA,wBACP,KAAO,EAAA,0BAAA;AAAA,wBACP,KAAO,EAAA,EAAA;AAAA,wBACP,KAAA,EAAO,EAAE,IAAA,EAAM,UAAW,EAAA;AAAA,uBAC5B;AAAA,qBACF;AAAA,mBACF;AAAA,kBACA;AAAA,oBACE,KAAO,EAAA,MAAA;AAAA,oBACP,IAAM,EAAA;AAAA,sBACJ;AAAA,wBACE,IAAM,EAAA,gBAAA;AAAA,wBACN,KAAO,EAAA,UAAA;AAAA,wBACP,KAAO,EAAA,0BAAA;AAAA,wBACP,KAAO,EAAA,EAAA;AAAA,uBACT;AAAA,qBACF;AAAA,mBACF;AAAA,iBACF;AAAA,eACF;AAAA,aACF;AAAA,WACF;AAAA,UACA;AAAA,YACE,MAAA,EAAQ,SAAU,GAAK,EAAA;AACrB,cAAA,OAAO,GAAQ,KAAA,EAAA,CAAA;AAAA,aACjB;AAAA,YACA,IAAM,EAAA;AAAA,cACJ;AAAA,gBACE,IAAM,EAAA,OAAA;AAAA,gBACN,KAAO,EAAA,kBAAA;AAAA,gBACP,KAAO,EAAA,0BAAA;AAAA,gBACP,KAAO,EAAA,0BAAA;AAAA,gBACP,MAAA,EAAQ,EAAE,IAAA,EAAM,uFAAkB,EAAA;AAAA,eACpC;AAAA,aACF;AAAA,WACF;AAAA,SACF;AAAA,OACF;AAAA,KACF,CAAA;AAAA,GACF;AACF,CAAA;;;;"}
@@ -486,11 +486,24 @@ export const commonMenu: ({
486
486
  type: string;
487
487
  props: {
488
488
  title: string;
489
+ listen: string;
489
490
  };
490
491
  showStyle: boolean;
491
492
  fixed: boolean;
492
493
  };
493
494
  props(): ({
495
+ type: string;
496
+ field: string;
497
+ title: string;
498
+ value: string;
499
+ props: {
500
+ label: string;
501
+ buttonText?: undefined;
502
+ };
503
+ effect?: undefined;
504
+ options?: undefined;
505
+ control?: undefined;
506
+ } | {
494
507
  type: string;
495
508
  field: string;
496
509
  title: string;
@@ -505,6 +518,7 @@ export const commonMenu: ({
505
518
  title: string;
506
519
  props: {
507
520
  buttonText: string;
521
+ label?: undefined;
508
522
  };
509
523
  value: string;
510
524
  effect?: undefined;
@@ -1805,11 +1819,24 @@ export const commonRuleList: {
1805
1819
  type: string;
1806
1820
  props: {
1807
1821
  title: string;
1822
+ listen: string;
1808
1823
  };
1809
1824
  showStyle: boolean;
1810
1825
  fixed: boolean;
1811
1826
  };
1812
1827
  props(): ({
1828
+ type: string;
1829
+ field: string;
1830
+ title: string;
1831
+ value: string;
1832
+ props: {
1833
+ label: string;
1834
+ buttonText?: undefined;
1835
+ };
1836
+ effect?: undefined;
1837
+ options?: undefined;
1838
+ control?: undefined;
1839
+ } | {
1813
1840
  type: string;
1814
1841
  field: string;
1815
1842
  title: string;
@@ -1824,6 +1851,7 @@ export const commonRuleList: {
1824
1851
  title: string;
1825
1852
  props: {
1826
1853
  buttonText: string;
1854
+ label?: undefined;
1827
1855
  };
1828
1856
  value: string;
1829
1857
  effect?: undefined;
@@ -487,11 +487,24 @@ export const webRuleList: {
487
487
  type: string;
488
488
  props: {
489
489
  title: string;
490
+ listen: string;
490
491
  };
491
492
  showStyle: boolean;
492
493
  fixed: boolean;
493
494
  };
494
495
  props(): ({
496
+ type: string;
497
+ field: string;
498
+ title: string;
499
+ value: string;
500
+ props: {
501
+ label: string;
502
+ buttonText?: undefined;
503
+ };
504
+ effect?: undefined;
505
+ options?: undefined;
506
+ control?: undefined;
507
+ } | {
495
508
  type: string;
496
509
  field: string;
497
510
  title: string;
@@ -506,6 +519,7 @@ export const webRuleList: {
506
519
  title: string;
507
520
  props: {
508
521
  buttonText: string;
522
+ label?: undefined;
509
523
  };
510
524
  value: string;
511
525
  effect?: undefined;
@@ -2362,11 +2376,24 @@ export function createWebMenu(): ({
2362
2376
  type: string;
2363
2377
  props: {
2364
2378
  title: string;
2379
+ listen: string;
2365
2380
  };
2366
2381
  showStyle: boolean;
2367
2382
  fixed: boolean;
2368
2383
  };
2369
2384
  props(): ({
2385
+ type: string;
2386
+ field: string;
2387
+ title: string;
2388
+ value: string;
2389
+ props: {
2390
+ label: string;
2391
+ buttonText?: undefined;
2392
+ };
2393
+ effect?: undefined;
2394
+ options?: undefined;
2395
+ control?: undefined;
2396
+ } | {
2370
2397
  type: string;
2371
2398
  field: string;
2372
2399
  title: string;
@@ -2381,6 +2408,7 @@ export function createWebMenu(): ({
2381
2408
  title: string;
2382
2409
  props: {
2383
2410
  buttonText: string;
2411
+ label?: undefined;
2384
2412
  };
2385
2413
  value: string;
2386
2414
  effect?: undefined;
@@ -34,6 +34,7 @@ declare const _default: import("vue").DefineComponent<{
34
34
  }, {
35
35
  countObj: import("vue").ComputedRef<{}>;
36
36
  diyTree: import("vue").ComputedRef<any[]>;
37
+ eventData: EventData;
37
38
  clear(type?: string): void;
38
39
  get(): {
39
40
  rule: any;
@@ -365,3 +366,4 @@ declare const _default: import("vue").DefineComponent<{
365
366
  leftAsideWidth: string;
366
367
  }, {}>;
367
368
  export default _default;
369
+ import EventData from './utils/eventData';