starfish-editor-custom 1.0.0

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.
Files changed (108) hide show
  1. package/auto-imports.d.ts +10 -0
  2. package/babel.config.js +8 -0
  3. package/components.d.ts +46 -0
  4. package/dist/ConditionModule.js +892 -0
  5. package/dist/ConditionSelect.js +483 -0
  6. package/dist/CustomDialog.js +105 -0
  7. package/dist/formStyle.js +245 -0
  8. package/dist/globalFormList.js +59 -0
  9. package/dist/jsonCode.js +74 -0
  10. package/dist/jsonEditor.js +71 -0
  11. package/dist/main.js +3319 -0
  12. package/dist/starfish-editor.es.js +30 -0
  13. package/dist/style.css +1 -0
  14. package/dist/types/editor/src/common/ConditionSelect/ConditionGroup.vue.d.ts +61 -0
  15. package/dist/types/editor/src/common/ConditionSelect/ConditionModule.vue.d.ts +43 -0
  16. package/dist/types/editor/src/common/ConditionSelect/ConditionTanc.vue.d.ts +48 -0
  17. package/dist/types/editor/src/common/ConditionSelect.vue.d.ts +72 -0
  18. package/dist/types/editor/src/common/CustomDialog.vue.d.ts +25 -0
  19. package/dist/types/editor/src/common/Loading.vue.d.ts +3 -0
  20. package/dist/types/editor/src/common/formJson.d.ts +80 -0
  21. package/dist/types/editor/src/common/jsonCode.vue.d.ts +110 -0
  22. package/dist/types/editor/src/components/ComponentList.vue.d.ts +32 -0
  23. package/dist/types/editor/src/components/FormPreview.vue.d.ts +25 -0
  24. package/dist/types/editor/src/components/Nav.vue.d.ts +9 -0
  25. package/dist/types/editor/src/components/PropsPanel.vue.d.ts +53 -0
  26. package/dist/types/editor/src/components/Shape.vue.d.ts +40 -0
  27. package/dist/types/editor/src/components/Workspace.vue.d.ts +22 -0
  28. package/dist/types/editor/src/components/globalFormList.vue.d.ts +6 -0
  29. package/dist/types/editor/src/components/jsonEditor.vue.d.ts +6 -0
  30. package/dist/types/editor/src/controller/action.d.ts +18 -0
  31. package/dist/types/editor/src/controller/form.d.ts +24 -0
  32. package/dist/types/editor/src/controller/history.d.ts +12 -0
  33. package/dist/types/editor/src/controller/shortcut.d.ts +20 -0
  34. package/dist/types/editor/src/controller/ui.d.ts +10 -0
  35. package/dist/types/editor/src/layouts/ControlEditSize.vue.d.ts +17 -0
  36. package/dist/types/editor/src/layouts/Framework.vue.d.ts +33 -0
  37. package/dist/types/editor/src/layouts/Resizer.vue.d.ts +13 -0
  38. package/dist/types/editor/src/layouts/ShortcutKey.vue.d.ts +8 -0
  39. package/dist/types/editor/src/main.d.ts +5 -0
  40. package/dist/types/editor/src/shims-vue.d.ts +23 -0
  41. package/dist/types/editor/src/starfish-editor.vue.d.ts +109 -0
  42. package/dist/types/editor/src/type.d.ts +224 -0
  43. package/dist/types/editor/src/utils/_.d.ts +33 -0
  44. package/dist/types/editor/src/utils/formKeycon.d.ts +18 -0
  45. package/dist/types/editor/src/utils/shortcutKey.d.ts +3 -0
  46. package/dist/types/editor/src/utils/vm.d.ts +3 -0
  47. package/dist/types/starfish-editor.d.ts +3 -0
  48. package/package.json +55 -0
  49. package/src/common/ConditionSelect/ConditionGroup.vue +167 -0
  50. package/src/common/ConditionSelect/ConditionModule.vue +118 -0
  51. package/src/common/ConditionSelect/ConditionTanc.vue +319 -0
  52. package/src/common/ConditionSelect.vue +268 -0
  53. package/src/common/CustomDialog.vue +77 -0
  54. package/src/common/Loading.vue +10 -0
  55. package/src/common/formJson.ts +143 -0
  56. package/src/common/formStyle.vue +170 -0
  57. package/src/common/jsonCode.vue +45 -0
  58. package/src/components/ComponentList.vue +156 -0
  59. package/src/components/FormPreview.vue +197 -0
  60. package/src/components/Nav.vue +128 -0
  61. package/src/components/NavList.vue +560 -0
  62. package/src/components/PropsPanel.vue +376 -0
  63. package/src/components/Shape.vue +178 -0
  64. package/src/components/Workspace.vue +258 -0
  65. package/src/components/globalFormList.vue +30 -0
  66. package/src/components/jsonEditor.vue +41 -0
  67. package/src/controller/action.ts +37 -0
  68. package/src/controller/form.ts +207 -0
  69. package/src/controller/history.ts +57 -0
  70. package/src/controller/shortcut.ts +81 -0
  71. package/src/controller/ui.ts +91 -0
  72. package/src/layouts/ControlEditSize.vue +52 -0
  73. package/src/layouts/Framework.vue +76 -0
  74. package/src/layouts/Resizer.vue +54 -0
  75. package/src/layouts/ShortcutKey.vue +61 -0
  76. package/src/main.ts +56 -0
  77. package/src/shims-vue.d.ts +23 -0
  78. package/src/starfish-editor.vue +176 -0
  79. package/src/styles/common/normalize.css +455 -0
  80. package/src/styles/component-list.scss +64 -0
  81. package/src/styles/condition-select.scss +176 -0
  82. package/src/styles/control_edit_size.scss +36 -0
  83. package/src/styles/custom-dialog.scss +110 -0
  84. package/src/styles/form-preview.scss +47 -0
  85. package/src/styles/framework.scss +150 -0
  86. package/src/styles/iconfont/iconfont.css +247 -0
  87. package/src/styles/iconfont/iconfont.js +1 -0
  88. package/src/styles/iconfont/iconfont.json +415 -0
  89. package/src/styles/iconfont/iconfont.ttf +0 -0
  90. package/src/styles/iconfont/iconfont.woff +0 -0
  91. package/src/styles/iconfont/iconfont.woff2 +0 -0
  92. package/src/styles/index.scss +18 -0
  93. package/src/styles/nav-list.scss +59 -0
  94. package/src/styles/nav.scss +46 -0
  95. package/src/styles/props-panel.scss +115 -0
  96. package/src/styles/resizer.scss +15 -0
  97. package/src/styles/shape.scss +101 -0
  98. package/src/styles/shortcutkey.scss +44 -0
  99. package/src/styles/variables.scss +36 -0
  100. package/src/styles/work-space.scss +126 -0
  101. package/src/type.ts +240 -0
  102. package/src/utils/_.ts +349 -0
  103. package/src/utils/formKeycon.ts +42 -0
  104. package/src/utils/shortcutKey.ts +46 -0
  105. package/src/utils/vm.ts +3 -0
  106. package/stats.html +4949 -0
  107. package/tsconfig.json +19 -0
  108. package/vite.config.ts +111 -0
@@ -0,0 +1,483 @@
1
+ import { ElOption, ElSelect, ElTableColumn, ElInput, ElFormItem, ElForm, ElSwitch, ElButton, ElTable, ElMain, ElFooter, ElContainer } from "element-plus/es";
2
+ import "element-plus/es/components/base/style/css";
3
+ import "element-plus/es/components/container/style/css";
4
+ import "element-plus/es/components/footer/style/css";
5
+ import "element-plus/es/components/main/style/css";
6
+ import "element-plus/es/components/table/style/css";
7
+ import "element-plus/es/components/button/style/css";
8
+ import "element-plus/es/components/switch/style/css";
9
+ import "element-plus/es/components/form/style/css";
10
+ import "element-plus/es/components/form-item/style/css";
11
+ import "element-plus/es/components/input/style/css";
12
+ import "element-plus/es/components/table-column/style/css";
13
+ import "element-plus/es/components/select/style/css";
14
+ import "element-plus/es/components/option/style/css";
15
+ import { defineComponent, ref, reactive, toRefs, toRaw, resolveComponent, openBlock, createBlock, Teleport, createVNode, withCtx, createElementVNode, createElementBlock, Fragment, renderList, createCommentVNode, withModifiers, createTextVNode } from "vue";
16
+ import { _ as _export_sfc, f as formStore } from "./main.js";
17
+ import "element-plus/dist/index.css";
18
+ import "jsoneditor/dist/jsoneditor.min.css";
19
+ import "starfish-form";
20
+ import "mitt";
21
+ import "element-plus";
22
+ import "nanoid";
23
+ import "starfish-form/dist/style.css";
24
+ import "clipboard";
25
+ import "element-plus/es/components/message/style/css";
26
+ import "element-plus/es/components/tabs/style/css";
27
+ import "element-plus/es/components/tab-pane/style/css";
28
+ import "element-plus/es/components/scrollbar/style/css";
29
+ import "element-plus/es/components/empty/style/css";
30
+ import "element-plus/es/components/loading/style/css";
31
+ import "element-plus/es/components/notification/style/css";
32
+ import "element-plus/es/components/upload/style/css";
33
+ import "element-plus/es/components/drawer/style/css";
34
+ import "element-plus/es/components/tree/style/css";
35
+ import "element-plus/es/components/tooltip/style/css";
36
+ import "gesto";
37
+ import "keycon";
38
+ const _sfc_main = defineComponent({
39
+ props: {
40
+ data: {
41
+ type: Object,
42
+ default() {
43
+ return {};
44
+ }
45
+ },
46
+ item: {
47
+ type: Object,
48
+ default() {
49
+ return {};
50
+ }
51
+ }
52
+ },
53
+ emits: ["change"],
54
+ setup(props, { emit }) {
55
+ const maxJsonDialog = ref();
56
+ const formList = ref();
57
+ const fieldList = ref();
58
+ function initFieldList() {
59
+ var _a, _b;
60
+ const allFormList = (_a = formStore) == null ? void 0 : _a.get("allFormList");
61
+ const fieldResult = [];
62
+ (_b = toRaw(allFormList)) == null ? void 0 : _b.forEach((item) => {
63
+ window.VueContext.$Flex.getFormDataList(item, fieldResult, props.data.fieldName);
64
+ });
65
+ fieldList.value = fieldResult;
66
+ }
67
+ const data = reactive({
68
+ andData: [[]],
69
+ logicList: [
70
+ { value: "=", label: "\u7B49\u4E8E" },
71
+ { value: "!=", label: "\u4E0D\u7B49\u4E8E" }
72
+ ],
73
+ typeList: [
74
+ {
75
+ value: "\u5E38\u91CF",
76
+ label: "\u5E38\u91CF"
77
+ }
78
+ ]
79
+ });
80
+ return {
81
+ ...toRefs(data),
82
+ fieldList,
83
+ maxJsonDialog,
84
+ formList,
85
+ handleType(index, tableIndex, type) {
86
+ if (type == "\u5E03\u5C14") {
87
+ data.andData[tableIndex][index].value = true;
88
+ }
89
+ },
90
+ getLogic(index, tableIndex) {
91
+ const item = fieldList.value.find((item2) => {
92
+ if (data.andData[tableIndex][index]) {
93
+ if (item2.value == data.andData[tableIndex][index].field) {
94
+ return item2;
95
+ }
96
+ }
97
+ });
98
+ if (item && item.options && item.multiple) {
99
+ return [
100
+ { value: "in", label: "\u5305\u542B" },
101
+ { value: "not in", label: "\u4E0D\u5305\u542B" }
102
+ ];
103
+ }
104
+ if (item && item.switch) {
105
+ return [
106
+ {
107
+ value: "=",
108
+ label: "\u7B49\u4E8E"
109
+ }
110
+ ];
111
+ }
112
+ return data.logicList;
113
+ },
114
+ getFiled(index, tableIndex) {
115
+ if (!data.andData[tableIndex][index] || !data.andData[tableIndex][index].field)
116
+ return [];
117
+ const item = fieldList.value.find((item2) => {
118
+ if (data.andData[tableIndex][index]) {
119
+ if (item2.value == data.andData[tableIndex][index].field) {
120
+ return item2;
121
+ }
122
+ }
123
+ });
124
+ return item.options || [];
125
+ },
126
+ show() {
127
+ maxJsonDialog.value.init("\u53EF\u7528\u6761\u4EF6", "icon-icon-bianji");
128
+ maxJsonDialog.value.show();
129
+ console.log(props.data);
130
+ if (typeof props.data.showRule != "string" && Array.isArray(props.data.showRule)) {
131
+ data.andData = props.data.showRule;
132
+ } else {
133
+ data.andData = [[]];
134
+ }
135
+ initFieldList();
136
+ },
137
+ getMultiple(index, tableIndex) {
138
+ const item = fieldList.value.find((item2) => {
139
+ if (data.andData[tableIndex][index]) {
140
+ if (item2.value == data.andData[tableIndex][index].field) {
141
+ return item2;
142
+ }
143
+ }
144
+ });
145
+ return !!item.multiple;
146
+ },
147
+ getNewTypeList(index, tableIndex) {
148
+ const item = fieldList.value.find((item2) => {
149
+ if (data.andData[tableIndex][index]) {
150
+ if (item2.value == data.andData[tableIndex][index].field) {
151
+ return item2;
152
+ }
153
+ }
154
+ });
155
+ if (item && item.options) {
156
+ return [
157
+ {
158
+ rule: [],
159
+ value: "\u9009\u9879",
160
+ label: "\u9009\u9879"
161
+ }
162
+ ];
163
+ }
164
+ if (item && item.switch) {
165
+ return [
166
+ {
167
+ value: "\u5E03\u5C14",
168
+ label: "\u5E03\u5C14"
169
+ }
170
+ ];
171
+ }
172
+ return data.typeList;
173
+ },
174
+ deleteRow(index, tableIndex) {
175
+ data.andData[tableIndex].splice(index, 1);
176
+ },
177
+ getTypeIsChange(index, tableIndex) {
178
+ const nowRow = data.andData[tableIndex][index];
179
+ return !!nowRow.type;
180
+ },
181
+ getRules(value) {
182
+ var _a;
183
+ return {
184
+ value: (_a = data.typeList.find((item) => {
185
+ return item.value == value;
186
+ })) == null ? void 0 : _a.rule
187
+ };
188
+ },
189
+ async onAddItem(index) {
190
+ data.andData[index].push({
191
+ field: "",
192
+ logic: "",
193
+ type: "",
194
+ value: ""
195
+ });
196
+ },
197
+ onOrItem() {
198
+ data.andData.push([]);
199
+ },
200
+ closeDialog() {
201
+ maxJsonDialog.value.close();
202
+ },
203
+ saveJson() {
204
+ const andData = toRaw(data.andData).filter((item) => {
205
+ if (item.length > 0) {
206
+ return item;
207
+ }
208
+ }).map((tabData) => {
209
+ const newTabData = tabData.filter((item) => {
210
+ if (item.field) {
211
+ return item;
212
+ }
213
+ });
214
+ if (newTabData.length > 0) {
215
+ return newTabData;
216
+ }
217
+ }).filter((item) => {
218
+ return !!item;
219
+ });
220
+ emit("change", andData);
221
+ maxJsonDialog.value.close();
222
+ }
223
+ };
224
+ }
225
+ });
226
+ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
227
+ const _component_el_option = ElOption;
228
+ const _component_el_select = ElSelect;
229
+ const _component_el_table_column = ElTableColumn;
230
+ const _component_el_input = ElInput;
231
+ const _component_el_form_item = ElFormItem;
232
+ const _component_el_form = ElForm;
233
+ const _component_el_switch = ElSwitch;
234
+ const _component_el_button = ElButton;
235
+ const _component_el_table = ElTable;
236
+ const _component_el_main = ElMain;
237
+ const _component_el_footer = ElFooter;
238
+ const _component_el_container = ElContainer;
239
+ const _component_CustomDialog = resolveComponent("CustomDialog");
240
+ return openBlock(), createBlock(Teleport, { to: "body" }, [
241
+ createVNode(_component_CustomDialog, {
242
+ ref: "maxJsonDialog",
243
+ dialogclass: "conditionSelectNormal"
244
+ }, {
245
+ default: withCtx(() => [
246
+ createVNode(_component_el_main, { style: { "padding": "0" } }, {
247
+ default: withCtx(() => [
248
+ createVNode(_component_el_container, { style: { "height": "100%" } }, {
249
+ default: withCtx(() => [
250
+ createVNode(_component_el_main, { class: "my-pageMain" }, {
251
+ default: withCtx(() => [
252
+ _cache[3] || (_cache[3] = createElementVNode("div", { class: "tipContent" }, "\u6EE1\u8DB3\u4EE5\u4E0B\u6240\u6709\u6761\u4EF6\u65F6,\u6B64\u7EC4\u4EF6\u53EF\u7528", -1)),
253
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.andData, (table, index) => {
254
+ return openBlock(), createElementBlock("div", {
255
+ class: "tableContainer",
256
+ key: index
257
+ }, [
258
+ createVNode(_component_el_table, {
259
+ data: table,
260
+ style: { "width": "100%" },
261
+ border: ""
262
+ }, {
263
+ default: withCtx(() => [
264
+ createVNode(_component_el_table_column, {
265
+ prop: "field",
266
+ label: "\u5B57\u6BB5"
267
+ }, {
268
+ default: withCtx((scope) => [
269
+ createVNode(_component_el_select, {
270
+ modelValue: scope.row.field,
271
+ "onUpdate:modelValue": ($event) => scope.row.field = $event,
272
+ placeholder: "\u8BF7\u9009\u62E9"
273
+ }, {
274
+ default: withCtx(() => [
275
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.fieldList, (item) => {
276
+ return openBlock(), createBlock(_component_el_option, {
277
+ key: item.value,
278
+ label: item.label,
279
+ value: item.value
280
+ }, null, 8, ["label", "value"]);
281
+ }), 128))
282
+ ]),
283
+ _: 2
284
+ }, 1032, ["modelValue", "onUpdate:modelValue"])
285
+ ]),
286
+ _: 1
287
+ }),
288
+ createVNode(_component_el_table_column, {
289
+ prop: "logic",
290
+ label: "\u903B\u8F91"
291
+ }, {
292
+ default: withCtx((scope) => [
293
+ createVNode(_component_el_select, {
294
+ modelValue: scope.row.logic,
295
+ "onUpdate:modelValue": ($event) => scope.row.logic = $event,
296
+ placeholder: "\u8BF7\u9009\u62E9"
297
+ }, {
298
+ default: withCtx(() => [
299
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.getLogic(scope.$index, index), (item) => {
300
+ return openBlock(), createBlock(_component_el_option, {
301
+ key: item.value,
302
+ label: item.label,
303
+ value: item.value
304
+ }, null, 8, ["label", "value"]);
305
+ }), 128))
306
+ ]),
307
+ _: 2
308
+ }, 1032, ["modelValue", "onUpdate:modelValue"])
309
+ ]),
310
+ _: 2
311
+ }, 1024),
312
+ createVNode(_component_el_table_column, {
313
+ prop: "type",
314
+ label: "\u503C\u7C7B\u578B"
315
+ }, {
316
+ default: withCtx((scope) => [
317
+ createVNode(_component_el_select, {
318
+ modelValue: scope.row.type,
319
+ "onUpdate:modelValue": ($event) => scope.row.type = $event,
320
+ placeholder: "\u8BF7\u9009\u62E9",
321
+ onChange: ($event) => _ctx.handleType(scope.$index, index, scope.row.type)
322
+ }, {
323
+ default: withCtx(() => [
324
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.getNewTypeList(scope.$index, index), (item) => {
325
+ return openBlock(), createBlock(_component_el_option, {
326
+ key: item.value,
327
+ label: item.label,
328
+ value: item.value
329
+ }, null, 8, ["label", "value"]);
330
+ }), 128))
331
+ ]),
332
+ _: 2
333
+ }, 1032, ["modelValue", "onUpdate:modelValue", "onChange"])
334
+ ]),
335
+ _: 2
336
+ }, 1024),
337
+ createVNode(_component_el_table_column, {
338
+ prop: "value",
339
+ label: "\u503C"
340
+ }, {
341
+ default: withCtx((scope) => [
342
+ _ctx.getTypeIsChange(scope.$index, index) && scope.row.type == "\u5E38\u91CF" ? (openBlock(), createBlock(_component_el_form, {
343
+ key: 0,
344
+ model: scope.row,
345
+ rules: _ctx.getRules(scope.row.type),
346
+ ref_for: true,
347
+ ref: "formList"
348
+ }, {
349
+ default: withCtx(() => [
350
+ createVNode(_component_el_form_item, { prop: "value" }, {
351
+ default: withCtx(() => [
352
+ createVNode(_component_el_input, {
353
+ text: "",
354
+ modelValue: scope.row.value,
355
+ "onUpdate:modelValue": ($event) => scope.row.value = $event
356
+ }, null, 8, ["modelValue", "onUpdate:modelValue"])
357
+ ]),
358
+ _: 2
359
+ }, 1024)
360
+ ]),
361
+ _: 2
362
+ }, 1032, ["model", "rules"])) : createCommentVNode("", true),
363
+ scope.row.type == "\u9009\u9879" ? (openBlock(), createBlock(_component_el_select, {
364
+ key: 1,
365
+ modelValue: scope.row.value,
366
+ "onUpdate:modelValue": ($event) => scope.row.value = $event,
367
+ filterable: "",
368
+ placeholder: "\u8BF7\u9009\u62E9",
369
+ multiple: _ctx.getMultiple(scope.$index, index)
370
+ }, {
371
+ default: withCtx(() => [
372
+ createVNode(_component_el_option, {
373
+ label: "\u672A\u9009\u62E9",
374
+ value: ""
375
+ }),
376
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.getFiled(scope.$index, index), (item, rightIndex) => {
377
+ return openBlock(), createBlock(_component_el_option, {
378
+ key: rightIndex,
379
+ label: item.label,
380
+ value: item.value
381
+ }, null, 8, ["label", "value"]);
382
+ }), 128))
383
+ ]),
384
+ _: 2
385
+ }, 1032, ["modelValue", "onUpdate:modelValue", "multiple"])) : createCommentVNode("", true),
386
+ scope.row.type == "\u5E03\u5C14" ? (openBlock(), createBlock(_component_el_switch, {
387
+ key: 2,
388
+ modelValue: scope.row.value,
389
+ "onUpdate:modelValue": ($event) => scope.row.value = $event
390
+ }, null, 8, ["modelValue", "onUpdate:modelValue"])) : createCommentVNode("", true)
391
+ ]),
392
+ _: 2
393
+ }, 1024),
394
+ createVNode(_component_el_table_column, {
395
+ fixed: "right",
396
+ label: "\u64CD\u4F5C",
397
+ width: "100"
398
+ }, {
399
+ default: withCtx((scope) => [
400
+ createVNode(_component_el_button, {
401
+ size: "small",
402
+ type: "danger",
403
+ onClick: withModifiers(($event) => _ctx.deleteRow(scope.$index, index), ["prevent"])
404
+ }, {
405
+ default: withCtx(() => _cache[0] || (_cache[0] = [
406
+ createTextVNode(" \u5220\u9664 ", -1)
407
+ ])),
408
+ _: 2,
409
+ __: [0]
410
+ }, 1032, ["onClick"])
411
+ ]),
412
+ _: 2
413
+ }, 1024)
414
+ ]),
415
+ _: 2
416
+ }, 1032, ["data"]),
417
+ createVNode(_component_el_button, {
418
+ class: "mt-4",
419
+ style: { "width": "100%" },
420
+ text: "",
421
+ onClick: ($event) => _ctx.onAddItem(index)
422
+ }, {
423
+ default: withCtx(() => _cache[1] || (_cache[1] = [
424
+ createTextVNode("+\u5E76\u6761\u4EF6", -1)
425
+ ])),
426
+ _: 2,
427
+ __: [1]
428
+ }, 1032, ["onClick"])
429
+ ]);
430
+ }), 128)),
431
+ createVNode(_component_el_button, {
432
+ class: "mt-4",
433
+ text: "",
434
+ onClick: _ctx.onOrItem
435
+ }, {
436
+ default: withCtx(() => _cache[2] || (_cache[2] = [
437
+ createTextVNode("+\u6216\u6761\u4EF6", -1)
438
+ ])),
439
+ _: 1,
440
+ __: [2]
441
+ }, 8, ["onClick"])
442
+ ]),
443
+ _: 1,
444
+ __: [3]
445
+ }),
446
+ createVNode(_component_el_footer, {
447
+ class: "my-Footer",
448
+ style: { "height": "60px", "padding-top": "10px", "text-align": "right" }
449
+ }, {
450
+ default: withCtx(() => [
451
+ createVNode(_component_el_button, {
452
+ type: "primary",
453
+ onClick: _ctx.saveJson
454
+ }, {
455
+ default: withCtx(() => _cache[4] || (_cache[4] = [
456
+ createTextVNode("\u4FDD\u5B58", -1)
457
+ ])),
458
+ _: 1,
459
+ __: [4]
460
+ }, 8, ["onClick"]),
461
+ createVNode(_component_el_button, { onClick: _ctx.closeDialog }, {
462
+ default: withCtx(() => _cache[5] || (_cache[5] = [
463
+ createTextVNode("\u5173\u95ED", -1)
464
+ ])),
465
+ _: 1,
466
+ __: [5]
467
+ }, 8, ["onClick"])
468
+ ]),
469
+ _: 1
470
+ })
471
+ ]),
472
+ _: 1
473
+ })
474
+ ]),
475
+ _: 1
476
+ })
477
+ ]),
478
+ _: 1
479
+ }, 512)
480
+ ]);
481
+ }
482
+ var ConditionSelect = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
483
+ export { ConditionSelect as default };
@@ -0,0 +1,105 @@
1
+ import { ElDialog } from "element-plus/es";
2
+ import "element-plus/es/components/base/style/css";
3
+ import "element-plus/es/components/dialog/style/css";
4
+ import { defineComponent, ref, computed, openBlock, createBlock, withCtx, createElementVNode, normalizeClass, toDisplayString, renderSlot } from "vue";
5
+ import { _ as _export_sfc } from "./main.js";
6
+ import "element-plus/dist/index.css";
7
+ import "jsoneditor/dist/jsoneditor.min.css";
8
+ import "starfish-form";
9
+ import "mitt";
10
+ import "element-plus";
11
+ import "nanoid";
12
+ import "starfish-form/dist/style.css";
13
+ import "element-plus/es/components/footer/style/css";
14
+ import "element-plus/es/components/button/style/css";
15
+ import "clipboard";
16
+ import "element-plus/es/components/message/style/css";
17
+ import "element-plus/es/components/tabs/style/css";
18
+ import "element-plus/es/components/tab-pane/style/css";
19
+ import "element-plus/es/components/scrollbar/style/css";
20
+ import "element-plus/es/components/empty/style/css";
21
+ import "element-plus/es/components/form/style/css";
22
+ import "element-plus/es/components/form-item/style/css";
23
+ import "element-plus/es/components/loading/style/css";
24
+ import "element-plus/es/components/notification/style/css";
25
+ import "element-plus/es/components/input/style/css";
26
+ import "element-plus/es/components/upload/style/css";
27
+ import "element-plus/es/components/drawer/style/css";
28
+ import "element-plus/es/components/tree/style/css";
29
+ import "element-plus/es/components/tooltip/style/css";
30
+ import "gesto";
31
+ import "keycon";
32
+ var CustomDialog_vue_vue_type_style_index_0_scoped_true_lang = "";
33
+ const _sfc_main = defineComponent({
34
+ props: {
35
+ dialogclass: String,
36
+ showDialog: Boolean,
37
+ width: Number
38
+ },
39
+ emits: ["open", "close"],
40
+ setup(props, { emit }) {
41
+ const isshow = ref(false);
42
+ const title = ref("");
43
+ const icon = ref("");
44
+ const isFullScreen = ref(false);
45
+ const newWidth = computed(() => {
46
+ if (typeof props.width == "number") {
47
+ return props.width + "px";
48
+ } else {
49
+ return props.width || "50%";
50
+ }
51
+ });
52
+ return {
53
+ isshow,
54
+ title,
55
+ icon,
56
+ isFullScreen,
57
+ newWidth,
58
+ init(titles, icons) {
59
+ title.value = titles;
60
+ icon.value = icons;
61
+ },
62
+ show() {
63
+ isshow.value = true;
64
+ emit("open");
65
+ },
66
+ close() {
67
+ isshow.value = false;
68
+ emit("close");
69
+ }
70
+ };
71
+ }
72
+ });
73
+ const _hoisted_1 = { class: "my-pageHeader" };
74
+ const _hoisted_2 = { class: "my-icon" };
75
+ const _hoisted_3 = { class: "my-title" };
76
+ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
77
+ const _component_el_dialog = ElDialog;
78
+ return openBlock(), createBlock(_component_el_dialog, {
79
+ modelValue: _ctx.isshow,
80
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.isshow = $event),
81
+ "custom-class": ["MyDialogBody", _ctx.dialogclass, { fullscreen: _ctx.isFullScreen }],
82
+ width: _ctx.newWidth,
83
+ "append-to-body": true,
84
+ "close-on-click-modal": false,
85
+ "destroy-on-close": true,
86
+ onClose: _ctx.close
87
+ }, {
88
+ title: withCtx(() => [
89
+ createElementVNode("div", _hoisted_1, [
90
+ createElementVNode("div", _hoisted_2, [
91
+ createElementVNode("em", {
92
+ class: normalizeClass(["iconfontui", _ctx.icon])
93
+ }, null, 2)
94
+ ]),
95
+ createElementVNode("div", _hoisted_3, toDisplayString(_ctx.title), 1)
96
+ ])
97
+ ]),
98
+ default: withCtx(() => [
99
+ renderSlot(_ctx.$slots, "default", {}, void 0, true)
100
+ ]),
101
+ _: 3
102
+ }, 8, ["modelValue", "custom-class", "width", "onClose"]);
103
+ }
104
+ var CustomDialog = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-81022734"]]);
105
+ export { CustomDialog as default };