wt-customize
Version:
This template should help get you started developing with Vue 3 in Vite. The template uses Vue 3 `<script setup>` SFCs, check out the [script setup docs](https://v3.vuejs.org/api/sfc-script-setup.html#sfc-script-setup) to learn more.
2,462 lines • 103 kB
JavaScript
import { defineComponent, reactive, openBlock, createElementBlock, createElementVNode, Fragment, renderList, toDisplayString, pushScopeId, popScopeId, resolveComponent, createVNode, withCtx, createBlock, createCommentVNode, createTextVNode, ref, withDirectives, vShow, h, normalizeClass } from "vue";
var asideLeft_vue_vue_type_style_index_0_scoped_true_lang = "";
var _export_sfc = (sfc, props) => {
for (const [key, val] of props) {
sfc[key] = val;
}
return sfc;
};
const _sfc_main$f = defineComponent({
setup(props, context) {
const list = reactive([
{ label: "\u591A\u9009\u6846", value: "checkbox" },
{ label: "\u5355\u9009\u6846", value: "radio" },
{ label: "\u6587\u672C\u6846", value: "input" },
{ label: "\u591A\u884C\u6587\u672C\u6846", value: "input", type: "textarea" },
{ label: "\u8BA1\u6570\u5668", value: "input-number" },
{ label: "\u9009\u62E9\u5668", value: "select" },
{ label: "\u5F00\u5173", value: "switch" },
{ label: "\u8BC4\u5206", value: "rate" },
{ label: "\u65E5\u671F\u9009\u62E9", value: "date-picker" },
{ label: "\u65F6\u95F4\u9009\u62E9", value: "time-picker" },
{ label: "\u65F6\u95F4\u9009\u62E9\u5668", value: "time-select" }
]);
const onClick = (l) => {
context.emit("onSelect", l);
};
return { list, onClick };
}
});
const _withScopeId$5 = (n) => (pushScopeId("data-v-546508d4"), n = n(), popScopeId(), n);
const _hoisted_1$g = { class: "aside-left" };
const _hoisted_2$f = /* @__PURE__ */ _withScopeId$5(() => /* @__PURE__ */ createElementVNode("div", { class: "aside-title" }, "\u8868\u5355\u9879", -1));
const _hoisted_3$c = { class: "items-wrap" };
const _hoisted_4$b = { class: "items" };
const _hoisted_5$7 = ["onClick"];
const _hoisted_6$6 = { class: "label" };
function _sfc_render$d(_ctx, _cache, $props, $setup, $data, $options) {
return openBlock(), createElementBlock("div", _hoisted_1$g, [
_hoisted_2$f,
createElementVNode("div", _hoisted_3$c, [
createElementVNode("div", _hoisted_4$b, [
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.list, (l, i) => {
return openBlock(), createElementBlock("div", {
class: "item",
key: i,
onClick: ($event) => _ctx.onClick(l)
}, [
createElementVNode("div", _hoisted_6$6, toDisplayString(l.label), 1)
], 8, _hoisted_5$7);
}), 128))
])
])
]);
}
var asideLeft = /* @__PURE__ */ _export_sfc(_sfc_main$f, [["render", _sfc_render$d], ["__scopeId", "data-v-546508d4"]]);
var selectEdit_vue_vue_type_style_index_0_scoped_true_lang = "";
const _sfc_main$e = defineComponent({
props: { value: { type: Object, default: {} } },
setup(props, context) {
const multipleSelect = (value) => {
if (value) {
props.value.configs.value = [];
} else {
props.value.configs.value = "";
}
};
const append = () => {
props.value.configs.list.push({ label: "", value: "" });
};
const remove = (i) => {
props.value.configs.list.splice(i, 1);
};
return { multipleSelect, append, remove };
}
});
const _withScopeId$4 = (n) => (pushScopeId("data-v-2e9f561a"), n = n(), popScopeId(), n);
const _hoisted_1$f = { class: "item-option" };
const _hoisted_2$e = { class: "list-item" };
const _hoisted_3$b = { class: "item-option" };
const _hoisted_4$a = /* @__PURE__ */ _withScopeId$4(() => /* @__PURE__ */ createElementVNode("span", null, "label:", -1));
const _hoisted_5$6 = { class: "item-option" };
const _hoisted_6$5 = /* @__PURE__ */ _withScopeId$4(() => /* @__PURE__ */ createElementVNode("span", null, "value:", -1));
const _hoisted_7$4 = { class: "item-option" };
const _hoisted_8$3 = ["onClick"];
const _hoisted_9$2 = { class: "list-item" };
const _hoisted_10$2 = { class: "item-option" };
const _hoisted_11$2 = /* @__PURE__ */ _withScopeId$4(() => /* @__PURE__ */ createElementVNode("span", null, "label:", -1));
const _hoisted_12$2 = { class: "item-option" };
const _hoisted_13$2 = /* @__PURE__ */ _withScopeId$4(() => /* @__PURE__ */ createElementVNode("span", null, "value:", -1));
const _hoisted_14$2 = { class: "item-option" };
const _hoisted_15 = ["onClick"];
const _hoisted_16 = { class: "item-option" };
const _hoisted_17 = /* @__PURE__ */ createTextVNode(" \u6DFB\u52A0 ");
const _hoisted_18 = /* @__PURE__ */ _withScopeId$4(() => /* @__PURE__ */ createElementVNode("i", { class: "el-icon-circle-plus-outline el-icon--right" }, null, -1));
const _hoisted_19 = { key: 0 };
const _hoisted_20 = /* @__PURE__ */ createTextVNode("\u5931\u53BB\u7126\u70B9");
const _hoisted_21 = /* @__PURE__ */ createTextVNode("\u9009\u9879\u6539\u53D8");
function _sfc_render$c(_ctx, _cache, $props, $setup, $data, $options) {
const _component_el_input = resolveComponent("el-input");
const _component_el_form_item = resolveComponent("el-form-item");
const _component_el_radio = resolveComponent("el-radio");
const _component_el_radio_group = resolveComponent("el-radio-group");
const _component_el_checkbox = resolveComponent("el-checkbox");
const _component_el_checkbox_group = resolveComponent("el-checkbox-group");
const _component_el_button = resolveComponent("el-button");
const _component_el_form = resolveComponent("el-form");
return openBlock(), createElementBlock("div", _hoisted_1$f, [
createVNode(_component_el_form, {
size: "mini",
"label-width": "100px"
}, {
default: withCtx(() => [
createVNode(_component_el_form_item, { label: "\u540D\u79F0" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.label,
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.value.configs.label = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u63D0\u793A" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.placeholder,
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.value.configs.placeholder = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u9009\u9879" }, {
default: withCtx(() => [
!_ctx.value.configs.multiple ? (openBlock(), createBlock(_component_el_radio_group, {
key: 0,
modelValue: _ctx.value.configs.value,
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => _ctx.value.configs.value = $event)
}, {
default: withCtx(() => [
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.value.configs.list, (l, i) => {
return openBlock(), createBlock(_component_el_radio, {
label: l.value,
key: i
}, {
default: withCtx(() => [
createElementVNode("div", _hoisted_2$e, [
createElementVNode("div", _hoisted_3$b, [
_hoisted_4$a,
createVNode(_component_el_input, {
size: "mini",
modelValue: l.label,
"onUpdate:modelValue": ($event) => l.label = $event
}, null, 8, ["modelValue", "onUpdate:modelValue"])
]),
createElementVNode("div", _hoisted_5$6, [
_hoisted_6$5,
createVNode(_component_el_input, {
size: "mini",
modelValue: l.value,
"onUpdate:modelValue": ($event) => l.value = $event
}, null, 8, ["modelValue", "onUpdate:modelValue"])
]),
createElementVNode("div", _hoisted_7$4, [
createElementVNode("i", {
class: "el-icon-remove-outline remove icon",
onClick: ($event) => _ctx.remove(i)
}, null, 8, _hoisted_8$3)
])
])
]),
_: 2
}, 1032, ["label"]);
}), 128))
]),
_: 1
}, 8, ["modelValue"])) : (openBlock(), createBlock(_component_el_checkbox_group, {
key: 1,
modelValue: _ctx.value.configs.value,
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => _ctx.value.configs.value = $event)
}, {
default: withCtx(() => [
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.value.configs.list, (l, i) => {
return openBlock(), createBlock(_component_el_checkbox, {
label: l.value,
key: i
}, {
default: withCtx(() => [
createElementVNode("div", _hoisted_9$2, [
createElementVNode("div", _hoisted_10$2, [
_hoisted_11$2,
createVNode(_component_el_input, {
size: "mini",
modelValue: l.label,
"onUpdate:modelValue": ($event) => l.label = $event
}, null, 8, ["modelValue", "onUpdate:modelValue"])
]),
createElementVNode("div", _hoisted_12$2, [
_hoisted_13$2,
createVNode(_component_el_input, {
size: "mini",
modelValue: l.value,
"onUpdate:modelValue": ($event) => l.value = $event
}, null, 8, ["modelValue", "onUpdate:modelValue"])
]),
createElementVNode("div", _hoisted_14$2, [
createElementVNode("i", {
class: "el-icon-remove-outline remove icon",
onClick: ($event) => _ctx.remove(i)
}, null, 8, _hoisted_15)
])
])
]),
_: 2
}, 1032, ["label"]);
}), 128))
]),
_: 1
}, 8, ["modelValue"])),
createElementVNode("div", _hoisted_16, [
createVNode(_component_el_button, {
size: "mini",
type: "primary",
onClick: _ctx.append
}, {
default: withCtx(() => [
_hoisted_17,
_hoisted_18
]),
_: 1
}, 8, ["onClick"])
])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u591A\u9009" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.multiple,
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => _ctx.value.configs.multiple = $event),
onChange: _ctx.multipleSelect
}, null, 8, ["modelValue", "onChange"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u7981\u7528" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.disabled,
"onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => _ctx.value.configs.disabled = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u5FC5\u586B" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.rules.required,
"onUpdate:modelValue": _cache[6] || (_cache[6] = ($event) => _ctx.value.configs.rules.required = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
_ctx.value.configs.rules.required ? (openBlock(), createElementBlock("div", _hoisted_19, [
createVNode(_component_el_form_item, { label: "\u63D0\u793A\u8BED" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.rules.message,
"onUpdate:modelValue": _cache[7] || (_cache[7] = ($event) => _ctx.value.configs.rules.message = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u89E6\u53D1" }, {
default: withCtx(() => [
createVNode(_component_el_radio_group, {
modelValue: _ctx.value.configs.rules.trigger,
"onUpdate:modelValue": _cache[8] || (_cache[8] = ($event) => _ctx.value.configs.rules.trigger = $event)
}, {
default: withCtx(() => [
createVNode(_component_el_radio, { label: "blur" }, {
default: withCtx(() => [
_hoisted_20
]),
_: 1
}),
createVNode(_component_el_radio, { label: "change" }, {
default: withCtx(() => [
_hoisted_21
]),
_: 1
})
]),
_: 1
}, 8, ["modelValue"])
]),
_: 1
})
])) : createCommentVNode("", true),
createVNode(_component_el_form_item, { label: "\u641C\u7D22" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.filterable,
"onUpdate:modelValue": _cache[9] || (_cache[9] = ($event) => _ctx.value.configs.filterable = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u6E05\u7A7A" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.clearable,
"onUpdate:modelValue": _cache[10] || (_cache[10] = ($event) => _ctx.value.configs.clearable = $event)
}, null, 8, ["modelValue"])
]),
_: 1
})
]),
_: 1
})
]);
}
var selectEdit = /* @__PURE__ */ _export_sfc(_sfc_main$e, [["render", _sfc_render$c], ["__scopeId", "data-v-2e9f561a"]]);
var checkboxEdit_vue_vue_type_style_index_0_scoped_true_lang = "";
const _sfc_main$d = defineComponent({
props: { value: { type: Object, default: {} } },
setup(props, context) {
const multipleSelect = (value) => {
if (value) {
props.value.configs.value = [];
} else {
props.value.configs.value = "";
}
};
const append = () => {
props.value.configs.list.push({ label: "", value: "" });
};
const remove = (i) => {
props.value.configs.list.splice(i, 1);
};
return { multipleSelect, append, remove };
}
});
const _withScopeId$3 = (n) => (pushScopeId("data-v-2b0e5fae"), n = n(), popScopeId(), n);
const _hoisted_1$e = { class: "item-option" };
const _hoisted_2$d = { class: "list-item" };
const _hoisted_3$a = { class: "item-option" };
const _hoisted_4$9 = /* @__PURE__ */ _withScopeId$3(() => /* @__PURE__ */ createElementVNode("span", null, "label:", -1));
const _hoisted_5$5 = { class: "item-option" };
const _hoisted_6$4 = /* @__PURE__ */ _withScopeId$3(() => /* @__PURE__ */ createElementVNode("span", null, "value:", -1));
const _hoisted_7$3 = { class: "item-option" };
const _hoisted_8$2 = ["onClick"];
const _hoisted_9$1 = { class: "item-option" };
const _hoisted_10$1 = /* @__PURE__ */ createTextVNode(" \u6DFB\u52A0 ");
const _hoisted_11$1 = /* @__PURE__ */ _withScopeId$3(() => /* @__PURE__ */ createElementVNode("i", { class: "el-icon-circle-plus-outline el-icon--right" }, null, -1));
const _hoisted_12$1 = { key: 0 };
const _hoisted_13$1 = /* @__PURE__ */ createTextVNode("\u5931\u53BB\u7126\u70B9");
const _hoisted_14$1 = /* @__PURE__ */ createTextVNode("\u9009\u9879\u6539\u53D8");
function _sfc_render$b(_ctx, _cache, $props, $setup, $data, $options) {
const _component_el_input = resolveComponent("el-input");
const _component_el_form_item = resolveComponent("el-form-item");
const _component_el_checkbox = resolveComponent("el-checkbox");
const _component_el_checkbox_group = resolveComponent("el-checkbox-group");
const _component_el_button = resolveComponent("el-button");
const _component_el_radio = resolveComponent("el-radio");
const _component_el_radio_group = resolveComponent("el-radio-group");
const _component_el_form = resolveComponent("el-form");
return openBlock(), createElementBlock("div", _hoisted_1$e, [
createVNode(_component_el_form, {
size: "mini",
"label-width": "100px"
}, {
default: withCtx(() => [
createVNode(_component_el_form_item, { label: "\u540D\u79F0" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.label,
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.value.configs.label = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u9009\u9879" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox_group, {
modelValue: _ctx.value.configs.value,
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.value.configs.value = $event)
}, {
default: withCtx(() => [
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.value.configs.list, (l, i) => {
return openBlock(), createBlock(_component_el_checkbox, {
label: l.label,
key: i
}, {
default: withCtx(() => [
createElementVNode("div", _hoisted_2$d, [
createElementVNode("div", _hoisted_3$a, [
_hoisted_4$9,
createVNode(_component_el_input, {
size: "mini",
modelValue: l.label,
"onUpdate:modelValue": ($event) => l.label = $event
}, null, 8, ["modelValue", "onUpdate:modelValue"])
]),
createElementVNode("div", _hoisted_5$5, [
_hoisted_6$4,
createVNode(_component_el_input, {
size: "mini",
modelValue: l.value,
"onUpdate:modelValue": ($event) => l.value = $event
}, null, 8, ["modelValue", "onUpdate:modelValue"])
]),
createElementVNode("div", _hoisted_7$3, [
createElementVNode("i", {
class: "el-icon-remove-outline remove icon",
onClick: ($event) => _ctx.remove(i)
}, null, 8, _hoisted_8$2)
])
])
]),
_: 2
}, 1032, ["label"]);
}), 128))
]),
_: 1
}, 8, ["modelValue"]),
createElementVNode("div", _hoisted_9$1, [
createVNode(_component_el_button, {
size: "mini",
type: "primary",
onClick: _ctx.append
}, {
default: withCtx(() => [
_hoisted_10$1,
_hoisted_11$1
]),
_: 1
}, 8, ["onClick"])
])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u7981\u7528" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.disabled,
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => _ctx.value.configs.disabled = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u5FC5\u586B" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.rules.required,
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => _ctx.value.configs.rules.required = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
_ctx.value.configs.rules.required ? (openBlock(), createElementBlock("div", _hoisted_12$1, [
createVNode(_component_el_form_item, { label: "\u63D0\u793A\u8BED" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.rules.message,
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => _ctx.value.configs.rules.message = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u89E6\u53D1" }, {
default: withCtx(() => [
createVNode(_component_el_radio_group, {
modelValue: _ctx.value.configs.rules.trigger,
"onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => _ctx.value.configs.rules.trigger = $event)
}, {
default: withCtx(() => [
createVNode(_component_el_radio, { label: "blur" }, {
default: withCtx(() => [
_hoisted_13$1
]),
_: 1
}),
createVNode(_component_el_radio, { label: "change" }, {
default: withCtx(() => [
_hoisted_14$1
]),
_: 1
})
]),
_: 1
}, 8, ["modelValue"])
]),
_: 1
})
])) : createCommentVNode("", true)
]),
_: 1
})
]);
}
var checkboxEdit = /* @__PURE__ */ _export_sfc(_sfc_main$d, [["render", _sfc_render$b], ["__scopeId", "data-v-2b0e5fae"]]);
var radioEdit_vue_vue_type_style_index_0_scoped_true_lang = "";
const _sfc_main$c = defineComponent({
props: { value: { type: Object, default: {} } },
setup(props, context) {
const multipleSelect = (value) => {
if (value) {
props.value.configs.value = [];
} else {
props.value.configs.value = "";
}
};
const append = () => {
props.value.configs.list.push({ label: "", value: "" });
};
const remove = (i) => {
props.value.configs.list.splice(i, 1);
};
return { multipleSelect, append, remove };
}
});
const _withScopeId$2 = (n) => (pushScopeId("data-v-a13db016"), n = n(), popScopeId(), n);
const _hoisted_1$d = { class: "item-option" };
const _hoisted_2$c = { class: "list-item" };
const _hoisted_3$9 = { class: "item-option" };
const _hoisted_4$8 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("span", null, "label:", -1));
const _hoisted_5$4 = { class: "item-option" };
const _hoisted_6$3 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("span", null, "value:", -1));
const _hoisted_7$2 = { class: "item-option" };
const _hoisted_8$1 = ["onClick"];
const _hoisted_9 = { class: "item-option" };
const _hoisted_10 = /* @__PURE__ */ createTextVNode(" \u6DFB\u52A0 ");
const _hoisted_11 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("i", { class: "el-icon-circle-plus-outline el-icon--right" }, null, -1));
const _hoisted_12 = { key: 0 };
const _hoisted_13 = /* @__PURE__ */ createTextVNode("\u5931\u53BB\u7126\u70B9");
const _hoisted_14 = /* @__PURE__ */ createTextVNode("\u9009\u9879\u6539\u53D8");
function _sfc_render$a(_ctx, _cache, $props, $setup, $data, $options) {
const _component_el_input = resolveComponent("el-input");
const _component_el_form_item = resolveComponent("el-form-item");
const _component_el_radio = resolveComponent("el-radio");
const _component_el_radio_group = resolveComponent("el-radio-group");
const _component_el_button = resolveComponent("el-button");
const _component_el_checkbox = resolveComponent("el-checkbox");
const _component_el_form = resolveComponent("el-form");
return openBlock(), createElementBlock("div", _hoisted_1$d, [
createVNode(_component_el_form, {
size: "mini",
"label-width": "100px"
}, {
default: withCtx(() => [
createVNode(_component_el_form_item, { label: "\u540D\u79F0" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.label,
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.value.configs.label = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u9009\u9879" }, {
default: withCtx(() => [
createVNode(_component_el_radio_group, {
modelValue: _ctx.value.configs.value,
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.value.configs.value = $event)
}, {
default: withCtx(() => [
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.value.configs.list, (l, i) => {
return openBlock(), createBlock(_component_el_radio, {
label: l.value,
key: i
}, {
default: withCtx(() => [
createElementVNode("div", _hoisted_2$c, [
createElementVNode("div", _hoisted_3$9, [
_hoisted_4$8,
createVNode(_component_el_input, {
size: "mini",
modelValue: l.label,
"onUpdate:modelValue": ($event) => l.label = $event
}, null, 8, ["modelValue", "onUpdate:modelValue"])
]),
createElementVNode("div", _hoisted_5$4, [
_hoisted_6$3,
createVNode(_component_el_input, {
size: "mini",
modelValue: l.value,
"onUpdate:modelValue": ($event) => l.value = $event
}, null, 8, ["modelValue", "onUpdate:modelValue"])
]),
createElementVNode("div", _hoisted_7$2, [
createElementVNode("i", {
class: "el-icon-remove-outline remove icon",
onClick: ($event) => _ctx.remove(i)
}, null, 8, _hoisted_8$1)
])
])
]),
_: 2
}, 1032, ["label"]);
}), 128))
]),
_: 1
}, 8, ["modelValue"]),
createElementVNode("div", _hoisted_9, [
createVNode(_component_el_button, {
size: "mini",
type: "primary",
onClick: _ctx.append
}, {
default: withCtx(() => [
_hoisted_10,
_hoisted_11
]),
_: 1
}, 8, ["onClick"])
])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u7981\u7528" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.disabled,
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => _ctx.value.configs.disabled = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u5FC5\u586B" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.rules.required,
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => _ctx.value.configs.rules.required = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
_ctx.value.configs.rules.required ? (openBlock(), createElementBlock("div", _hoisted_12, [
createVNode(_component_el_form_item, { label: "\u63D0\u793A\u8BED" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.rules.message,
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => _ctx.value.configs.rules.message = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u89E6\u53D1" }, {
default: withCtx(() => [
createVNode(_component_el_radio_group, {
modelValue: _ctx.value.configs.rules.trigger,
"onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => _ctx.value.configs.rules.trigger = $event)
}, {
default: withCtx(() => [
createVNode(_component_el_radio, { label: "blur" }, {
default: withCtx(() => [
_hoisted_13
]),
_: 1
}),
createVNode(_component_el_radio, { label: "change" }, {
default: withCtx(() => [
_hoisted_14
]),
_: 1
})
]),
_: 1
}, 8, ["modelValue"])
]),
_: 1
})
])) : createCommentVNode("", true)
]),
_: 1
})
]);
}
var radioEdit = /* @__PURE__ */ _export_sfc(_sfc_main$c, [["render", _sfc_render$a], ["__scopeId", "data-v-a13db016"]]);
const _sfc_main$b = defineComponent({
props: { value: { type: Object, default: {} } },
setup(props, context) {
}
});
const _hoisted_1$c = { class: "item-option" };
const _hoisted_2$b = { key: 0 };
const _hoisted_3$8 = /* @__PURE__ */ createTextVNode("\u5931\u53BB\u7126\u70B9");
const _hoisted_4$7 = /* @__PURE__ */ createTextVNode("\u9009\u9879\u6539\u53D8");
function _sfc_render$9(_ctx, _cache, $props, $setup, $data, $options) {
const _component_el_input = resolveComponent("el-input");
const _component_el_form_item = resolveComponent("el-form-item");
const _component_el_checkbox = resolveComponent("el-checkbox");
const _component_el_radio = resolveComponent("el-radio");
const _component_el_radio_group = resolveComponent("el-radio-group");
const _component_el_form = resolveComponent("el-form");
return openBlock(), createElementBlock("div", _hoisted_1$c, [
createVNode(_component_el_form, {
size: "mini",
"label-width": "100px"
}, {
default: withCtx(() => [
createVNode(_component_el_form_item, { label: "\u540D\u79F0" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.label,
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.value.configs.label = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u63D0\u793A" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.placeholder,
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.value.configs.placeholder = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u7981\u7528" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.disabled,
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => _ctx.value.configs.disabled = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u5FC5\u586B" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.rules.required,
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => _ctx.value.configs.rules.required = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
_ctx.value.configs.rules.required ? (openBlock(), createElementBlock("div", _hoisted_2$b, [
createVNode(_component_el_form_item, { label: "\u63D0\u793A\u8BED" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.rules.message,
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => _ctx.value.configs.rules.message = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u89E6\u53D1" }, {
default: withCtx(() => [
createVNode(_component_el_radio_group, {
modelValue: _ctx.value.configs.rules.trigger,
"onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => _ctx.value.configs.rules.trigger = $event)
}, {
default: withCtx(() => [
createVNode(_component_el_radio, { label: "blur" }, {
default: withCtx(() => [
_hoisted_3$8
]),
_: 1
}),
createVNode(_component_el_radio, { label: "change" }, {
default: withCtx(() => [
_hoisted_4$7
]),
_: 1
})
]),
_: 1
}, 8, ["modelValue"])
]),
_: 1
})
])) : createCommentVNode("", true),
createVNode(_component_el_form_item, { label: "\u6E05\u7A7A" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.clearable,
"onUpdate:modelValue": _cache[6] || (_cache[6] = ($event) => _ctx.value.configs.clearable = $event)
}, null, 8, ["modelValue"])
]),
_: 1
})
]),
_: 1
})
]);
}
var inputEdit = /* @__PURE__ */ _export_sfc(_sfc_main$b, [["render", _sfc_render$9]]);
const _sfc_main$a = defineComponent({
props: { value: { type: Object, default: {} } },
setup(props, context) {
}
});
const _hoisted_1$b = { class: "item-option" };
const _hoisted_2$a = { key: 0 };
const _hoisted_3$7 = /* @__PURE__ */ createTextVNode("\u5931\u53BB\u7126\u70B9");
const _hoisted_4$6 = /* @__PURE__ */ createTextVNode("\u9009\u9879\u6539\u53D8");
function _sfc_render$8(_ctx, _cache, $props, $setup, $data, $options) {
const _component_el_input = resolveComponent("el-input");
const _component_el_form_item = resolveComponent("el-form-item");
const _component_el_input_number = resolveComponent("el-input-number");
const _component_el_checkbox = resolveComponent("el-checkbox");
const _component_el_radio = resolveComponent("el-radio");
const _component_el_radio_group = resolveComponent("el-radio-group");
const _component_el_form = resolveComponent("el-form");
return openBlock(), createElementBlock("div", _hoisted_1$b, [
createVNode(_component_el_form, {
size: "mini",
"label-width": "100px"
}, {
default: withCtx(() => [
createVNode(_component_el_form_item, { label: "\u540D\u79F0" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.label,
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.value.configs.label = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u63D0\u793A" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.placeholder,
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.value.configs.placeholder = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u884C\u6570" }, {
default: withCtx(() => [
createVNode(_component_el_input_number, {
modelValue: _ctx.value.configs.rows,
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => _ctx.value.configs.rows = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u7981\u7528" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.disabled,
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => _ctx.value.configs.disabled = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u5FC5\u586B" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.rules.required,
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => _ctx.value.configs.rules.required = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u81EA\u9002\u5E94" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.autosize,
"onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => _ctx.value.configs.autosize = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
_ctx.value.configs.rules.required ? (openBlock(), createElementBlock("div", _hoisted_2$a, [
createVNode(_component_el_form_item, { label: "\u63D0\u793A\u8BED" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.rules.message,
"onUpdate:modelValue": _cache[6] || (_cache[6] = ($event) => _ctx.value.configs.rules.message = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u89E6\u53D1" }, {
default: withCtx(() => [
createVNode(_component_el_radio_group, {
modelValue: _ctx.value.configs.rules.trigger,
"onUpdate:modelValue": _cache[7] || (_cache[7] = ($event) => _ctx.value.configs.rules.trigger = $event)
}, {
default: withCtx(() => [
createVNode(_component_el_radio, { label: "blur" }, {
default: withCtx(() => [
_hoisted_3$7
]),
_: 1
}),
createVNode(_component_el_radio, { label: "change" }, {
default: withCtx(() => [
_hoisted_4$6
]),
_: 1
})
]),
_: 1
}, 8, ["modelValue"])
]),
_: 1
})
])) : createCommentVNode("", true),
createVNode(_component_el_form_item, { label: "\u6E05\u7A7A" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.clearable,
"onUpdate:modelValue": _cache[8] || (_cache[8] = ($event) => _ctx.value.configs.clearable = $event)
}, null, 8, ["modelValue"])
]),
_: 1
})
]),
_: 1
})
]);
}
var inputTextareaEdit = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["render", _sfc_render$8]]);
const _sfc_main$9 = defineComponent({
props: { value: { type: Object, default: {} } },
setup(props, context) {
const minChange = (value) => {
if (value >= props.value.configs.max) {
props.value.configs.max += props.value.configs.step;
}
if (value > props.value.configs.value)
props.value.configs.value = value;
};
return { minChange };
}
});
const _hoisted_1$a = { class: "item-option" };
const _hoisted_2$9 = { key: 0 };
const _hoisted_3$6 = /* @__PURE__ */ createTextVNode("\u5931\u53BB\u7126\u70B9");
const _hoisted_4$5 = /* @__PURE__ */ createTextVNode("\u9009\u9879\u6539\u53D8");
function _sfc_render$7(_ctx, _cache, $props, $setup, $data, $options) {
const _component_el_input = resolveComponent("el-input");
const _component_el_form_item = resolveComponent("el-form-item");
const _component_el_input_number = resolveComponent("el-input-number");
const _component_el_checkbox = resolveComponent("el-checkbox");
const _component_el_radio = resolveComponent("el-radio");
const _component_el_radio_group = resolveComponent("el-radio-group");
const _component_el_form = resolveComponent("el-form");
return openBlock(), createElementBlock("div", _hoisted_1$a, [
createVNode(_component_el_form, {
size: "mini",
"label-width": "100px"
}, {
default: withCtx(() => [
createVNode(_component_el_form_item, { label: "\u540D\u79F0" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.label,
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.value.configs.label = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u6B65\u6570" }, {
default: withCtx(() => [
createVNode(_component_el_input_number, {
modelValue: _ctx.value.configs.step,
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.value.configs.step = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u6700\u5927\u503C" }, {
default: withCtx(() => [
createVNode(_component_el_input_number, {
modelValue: _ctx.value.configs.max,
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => _ctx.value.configs.max = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u6700\u5C0F\u503C" }, {
default: withCtx(() => [
createVNode(_component_el_input_number, {
modelValue: _ctx.value.configs.min,
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => _ctx.value.configs.min = $event),
onChange: _ctx.minChange
}, null, 8, ["modelValue", "onChange"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u7981\u7528" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.disabled,
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => _ctx.value.configs.disabled = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u5FC5\u586B" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.rules.required,
"onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => _ctx.value.configs.rules.required = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
_ctx.value.configs.rules.required ? (openBlock(), createElementBlock("div", _hoisted_2$9, [
createVNode(_component_el_form_item, { label: "\u63D0\u793A\u8BED" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.rules.message,
"onUpdate:modelValue": _cache[6] || (_cache[6] = ($event) => _ctx.value.configs.rules.message = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u89E6\u53D1" }, {
default: withCtx(() => [
createVNode(_component_el_radio_group, {
modelValue: _ctx.value.configs.rules.trigger,
"onUpdate:modelValue": _cache[7] || (_cache[7] = ($event) => _ctx.value.configs.rules.trigger = $event)
}, {
default: withCtx(() => [
createVNode(_component_el_radio, { label: "blur" }, {
default: withCtx(() => [
_hoisted_3$6
]),
_: 1
}),
createVNode(_component_el_radio, { label: "change" }, {
default: withCtx(() => [
_hoisted_4$5
]),
_: 1
})
]),
_: 1
}, 8, ["modelValue"])
]),
_: 1
})
])) : createCommentVNode("", true)
]),
_: 1
})
]);
}
var inputNumberEdit = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["render", _sfc_render$7]]);
const _sfc_main$8 = defineComponent({
props: { value: { type: Object, default: {} } },
setup(props, context) {
}
});
const _hoisted_1$9 = { class: "item-option" };
function _sfc_render$6(_ctx, _cache, $props, $setup, $data, $options) {
const _component_el_input = resolveComponent("el-input");
const _component_el_form_item = resolveComponent("el-form-item");
const _component_el_checkbox = resolveComponent("el-checkbox");
const _component_el_form = resolveComponent("el-form");
return openBlock(), createElementBlock("div", _hoisted_1$9, [
createVNode(_component_el_form, {
size: "mini",
"label-width": "100px"
}, {
default: withCtx(() => [
createVNode(_component_el_form_item, { label: "\u540D\u79F0" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.label,
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.value.configs.label = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u6587\u5B57\uFF08\u5F00\uFF09" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.activeText,
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.value.configs.activeText = $event),
placeholder: "\u5F00\u5173\u5F00\u542F\u6587\u672C"
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u6587\u5B57\uFF08\u5173\uFF09" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.inactiveText,
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => _ctx.value.configs.inactiveText = $event),
placeholder: "\u5F00\u5173\u5173\u95ED\u6587\u672C"
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u7981\u7528" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.disabled,
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => _ctx.value.configs.disabled = $event)
}, null, 8, ["modelValue"])
]),
_: 1
})
]),
_: 1
})
]);
}
var switchEdit = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["render", _sfc_render$6]]);
var rateEdit_vue_vue_type_style_index_0_scoped_true_lang = "";
const _sfc_main$7 = defineComponent({
props: { value: { type: Object, default: {} } },
setup(props, context) {
}
});
const _hoisted_1$8 = { class: "item-option" };
const _hoisted_2$8 = {
key: 0,
class: "show-text"
};
const _hoisted_3$5 = { key: 0 };
const _hoisted_4$4 = /* @__PURE__ */ createTextVNode("\u5931\u53BB\u7126\u70B9");
const _hoisted_5$3 = /* @__PURE__ */ createTextVNode("\u9009\u9879\u6539\u53D8");
function _sfc_render$5(_ctx, _cache, $props, $setup, $data, $options) {
const _component_el_input = resolveComponent("el-input");
const _component_el_form_item = resolveComponent("el-form-item");
const _component_el_checkbox = resolveComponent("el-checkbox");
const _component_el_radio = resolveComponent("el-radio");
const _component_el_radio_group = resolveComponent("el-radio-group");
const _component_el_form = resolveComponent("el-form");
return openBlock(), createElementBlock("div", _hoisted_1$8, [
createVNode(_component_el_form, {
size: "mini",
"label-width": "100px"
}, {
default: withCtx(() => [
createVNode(_component_el_form_item, { label: "\u540D\u79F0" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.label,
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.value.configs.label = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u8F85\u52A9\u6587\u5B57" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.showText,
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.value.configs.showText = $event)
}, null, 8, ["modelValue"]),
_ctx.value.configs.showText ? (openBlock(), createElementBlock("div", _hoisted_2$8, [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.texts[0],
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => _ctx.value.configs.texts[0] = $event)
}, null, 8, ["modelValue"]),
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.texts[1],
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => _ctx.value.configs.texts[1] = $event)
}, null, 8, ["modelValue"]),
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.texts[2],
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => _ctx.value.configs.texts[2] = $event)
}, null, 8, ["modelValue"]),
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.texts[3],
"onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => _ctx.value.configs.texts[3] = $event)
}, null, 8, ["modelValue"]),
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.texts[4],
"onUpdate:modelValue": _cache[6] || (_cache[6] = ($event) => _ctx.value.configs.texts[4] = $event)
}, null, 8, ["modelValue"])
])) : createCommentVNode("", true)
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u7981\u7528" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.disabled,
"onUpdate:modelValue": _cache[7] || (_cache[7] = ($event) => _ctx.value.configs.disabled = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u534A\u9009" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.allowHalf,
"onUpdate:modelValue": _cache[8] || (_cache[8] = ($event) => _ctx.value.configs.allowHalf = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u5206\u503C" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.showScore,
"onUpdate:modelValue": _cache[9] || (_cache[9] = ($event) => _ctx.value.configs.showScore = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u5FC5\u586B" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.rules.required,
"onUpdate:modelValue": _cache[10] || (_cache[10] = ($event) => _ctx.value.configs.rules.required = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
_ctx.value.configs.rules.required ? (openBlock(), createElementBlock("div", _hoisted_3$5, [
createVNode(_component_el_form_item, { label: "\u63D0\u793A\u8BED" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.rules.message,
"onUpdate:modelValue": _cache[11] || (_cache[11] = ($event) => _ctx.value.configs.rules.message = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u89E6\u53D1" }, {
default: withCtx(() => [
createVNode(_component_el_radio_group, {
modelValue: _ctx.value.configs.rules.trigger,
"onUpdate:modelValue": _cache[12] || (_cache[12] = ($event) => _ctx.value.configs.rules.trigger = $event)
}, {
default: withCtx(() => [
createVNode(_component_el_radio, { label: "blur" }, {
default: withCtx(() => [
_hoisted_4$4
]),
_: 1
}),
createVNode(_component_el_radio, { label: "change" }, {
default: withCtx(() => [
_hoisted_5$3
]),
_: 1
})
]),
_: 1
}, 8, ["modelValue"])
]),
_: 1
})
])) : createCommentVNode("", true)
]),
_: 1
})
]);
}
var rateEdit = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["render", _sfc_render$5], ["__scopeId", "data-v-32971d34"]]);
var datePickerEdit_vue_vue_type_style_index_0_scoped_true_lang = "";
const _sfc_main$6 = defineComponent({
props: { value: { type: Object, default: {} } },
setup(props, context) {
const onDisChange = () => {
props.value.configs.value = "";
};
const onDisMinChange = () => {
props.value.configs.value = "";
props.value.configs.disabledMax = "";
};
const typeChange = (value) => {
props.value.configs.disType = value.replace("range", "");
props.value.configs.value = "";
props.value.configs.format = "YYYY-MM-DD HH:mm:ss";
};
const disabledDate = (time) => {
return time.getTime() < new Date(props.value.configs.disabledMin).getTime();
};
return { onDisChange, typeChange, disabledDate, onDisMinChange };
}
});
const _withScopeId$1 = (n) => (pushScopeId("data-v-18d52653"), n = n(), popScopeId(), n);
const _hoisted_1$7 = { class: "item-option" };
const _hoisted_2$7 = /* @__PURE__ */ _withScopeId$1(() => /* @__PURE__ */ createElementVNode("div", { class: "label" }, "\u8D77\u59CB", -1));
const _hoisted_3$4 = /* @__PURE__ */ _withScopeId$1(() => /* @__PURE__ */ createElementVNode("div", { class: "label" }, "\u7ED3\u675F", -1));
const _hoisted_4$3 = { key: 2 };
const _hoisted_5$2 = /* @__PURE__ */ createTextVNode("\u5931\u53BB\u7126\u70B9");
const _hoisted_6$2 = /* @__PURE__ */ createTextVNode("\u9009\u9879\u6539\u53D8");
function _sfc_render$4(_ctx, _cache, $props, $setup, $data, $options) {
const _component_el_input = resolveComponent("el-input");
const _component_el_form_item = resolveComponent("el-form-item");
const _component_el_option = resolveComponent("el-option");
const _component_el_select = resolveComponent("el-select");
const _component_el_date_picker = resolveComponent("el-date-picker");
const _component_el_checkbox = resolveComponent("el-checkbox");
const _component_el_radio = resolveComponent("el-radio");
const _component_el_radio_group = resolveComponent("el-radio-group");
const _component_el_form = resolveComponent("el-form");
return openBlock(), createElementBlock("div", _hoisted_1$7, [
createVNode(_component_el_form, {
size: "mini",
"label-width": "100px"
}, {
default: withCtx(() => [
createVNode(_component_el_form_item, { label: "\u540D\u79F0" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.label,
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.value.configs.label = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u7C7B\u578B" }, {
default: withCtx(() => [
createVNode(_component_el_select, {
modelValue: _ctx.value.configs.type,
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.value.configs.type = $event),
onChange: _ctx.typeChange
}, {
default: withCtx(() => [
createVNode(_component_el_option, {
value: "date",
label: "\u65E5\u671F"
}),
createVNode(_component_el_option, {
value: "month",
label: "\u6708\u4EFD"
}),
createVNode(_component_el_option, {
value: "year",
label: "\u5E74\u4EFD"
}),
createVNode(_component_el_option, {
value: "datetime",
label: "\u65E5\u671F\u65F6\u95F4"
}),
createVNode(_component_el_option, {
value: "daterange",
label: "\u65E5\u671F\u8303\u56F4"
}),
createVNode(_component_el_option, {
value: "monthrange",
label: "\u6708\u4EFD\u8303\u56F4"
})
]),
_: 1
}, 8, ["modelValue", "onChange"])
]),
_: 1
}),
_ctx.value.configs.type != "datetime" ? (openBlock(), createBlock(_component_el_form_item, {
key: 0,
label: "\u65E5\u671F\u683C\u5F0F"
}, {
default: withCtx(() => [
createVNode(_component_el_select, {
modelValue: _ctx.value.configs.format,
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => _ctx.value.configs.format = $event)
}, {
default: withCtx(() => [
createVNode(_component_el_option, { value: "YYYY/MM/DD" }),
createVNode(_component_el_option, { value: "YYYY/M/D" }),
createVNode(_component_el_option, { value: "YYYY-MM-DD" }),
createVNode(_component_el_option, { value: "YYYY-M-D" })
]),
_: 1
}, 8, ["modelValue"])
]),
_: 1
})) : (openBlock(), createBlock(_component_el_form_item, {
key: 1,
label: "\u65E5\u671F\u683C\u5F0F"
}, {
default: withCtx(() => [
createVNode(_component_el_select, {
modelValue: _ctx.value.configs.format,
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => _ctx.value.configs.format = $event)
}, {
default: withCtx(() => [
createVNode(_component_el_option, { value: "YYYY/MM/DD HH:mm:ss" }),
createVNode(_component_el_option, { value: "YYYY/M/D H:m:s" }),
createVNode(_component_el_option, { value: "YYYY-MM-DD HH:mm:ss" }),
createVNode(_component_el_option, { value: "YYYY-M-D H:m:s" })
]),
_: 1
}, 8, ["modelValue"])
]),
_: 1
})),
createVNode(_component_el_form_item, { label: "\u7ED1\u5B9A\u683C\u5F0F" }, {
default: withCtx(() => [
createVNode(_component_el_select, {
modelValue: _ctx.value.configs.valueFormat,
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => _ctx.value.configs.valueFormat = $event)
}, {
default: withCtx(() => [
createVNode(_component_el_option, {
value: "",
label: "\u9ED8\u8BA4"
}),
createVNode(_component_el_option, {
value: "x",
label: "\u65F6\u95F4\u6233"
}),
createVNode(_component_el_option, {
value: "YYYY-MM-DD",
label: "\u65E5\u671F"
})
]),
_: 1
}, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u7981\u7528\u65E5\u671F" }, {
default: withCtx(() => [
createElementVNode("div", null, [
_hoisted_2$7,
createVNode(_component_el_date_picker, {
modelValue: _ctx.value.configs.disabledMin,
"onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => _ctx.value.configs.disabledMin = $event),
type: _ctx.value.configs.disType,
placeholder: "\u9009\u62E9\u7981\u7528\u5F00\u59CB\u65E5\u671F",
onChange: _ctx.onDisMinChange
}, null, 8, ["modelValue", "type", "onChange"])
]),
createElementVNode("div", null, [
_hoisted_3$4,
createVNode(_component_el_date_picker, {
modelValue: _ctx.value.configs.disabledMax,
"onUpdate:modelValue": _cache[6] || (_cache[6] = ($event) => _ctx.value.configs.disabledMax = $event),
type: _ctx.value.configs.disType,
placeholder: "\u9009\u62E9\u7981\u7528\u7ED3\u675F\u65E5\u671F",
onChange: _ctx.onDisChange,
"disabled-date": _ctx.disabledDate
}, null, 8, ["modelValue", "type", "onChange", "disabled-date"])
])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u63D0\u793A" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.placeholder,
"onUpdate:modelValue": _cache[7] || (_cache[7] = ($event) => _ctx.value.configs.placeholder = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u7981\u7528" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.disabled,
"onUpdate:modelValue": _cache[8] || (_cache[8] = ($event) => _ctx.value.configs.disabled = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u5FC5\u586B" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.rules.required,
"onUpdate:modelValue": _cache[9] || (_cache[9] = ($event) => _ctx.value.configs.rules.required = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
_ctx.value.configs.rules.required ? (openBlock(), createElementBlock("div", _hoisted_4$3, [
createVNode(_component_el_form_item, { label: "\u63D0\u793A\u8BED" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.rules.message,
"onUpdate:modelValue": _cache[10] || (_cache[10] = ($event) => _ctx.value.configs.rules.message = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u89E6\u53D1" }, {
default: withCtx(() => [
createVNode(_component_el_radio_group, {
modelValue: _ctx.value.configs.rules.trigger,
"onUpdate:modelValue": _cache[11] || (_cache[11] = ($event) => _ctx.value.configs.rules.trigger = $event)
}, {
default: withCtx(() => [
createVNode(_component_el_radio, { label: "blur" }, {
default: withCtx(() => [
_hoisted_5$2
]),
_: 1
}),
createVNode(_component_el_radio, { label: "change" }, {
default: withCtx(() => [
_hoisted_6$2
]),
_: 1
})
]),
_: 1
}, 8, ["modelValue"])
]),
_: 1
})
])) : createCommentVNode("", true),
createVNode(_component_el_form_item, { label: "\u6E05\u7A7A" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.clearable,
"onUpdate:modelValue": _cache[12] || (_cache[12] = ($event) => _ctx.value.configs.clearable = $event)
}, null, 8, ["modelValue"])
]),
_: 1
})
]),
_: 1
})
]);
}
var datePickerEdit = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["render", _sfc_render$4], ["__scopeId", "data-v-18d52653"]]);
var timePickerEdit_vue_vue_type_style_index_0_scoped_true_lang = "";
const _sfc_main$5 = defineComponent({
props: { value: { type: Object, default: {} } },
setup(props, context) {
}
});
const _hoisted_1$6 = { class: "item-option" };
const _hoisted_2$6 = { key: 0 };
const _hoisted_3$3 = /* @__PURE__ */ createTextVNode("\u5931\u53BB\u7126\u70B9");
const _hoisted_4$2 = /* @__PURE__ */ createTextVNode("\u9009\u9879\u6539\u53D8");
function _sfc_render$3(_ctx, _cache, $props, $setup, $data, $options) {
const _component_el_input = resolveComponent("el-input");
const _component_el_form_item = resolveComponent("el-form-item");
const _component_el_checkbox = resolveComponent("el-checkbox");
const _component_el_radio = resolveComponent("el-radio");
const _component_el_radio_group = resolveComponent("el-radio-group");
const _component_el_form = resolveComponent("el-form");
return openBlock(), createElementBlock("div", _hoisted_1$6, [
createVNode(_component_el_form, {
size: "mini",
"label-width": "100px"
}, {
default: withCtx(() => [
createVNode(_component_el_form_item, { label: "\u540D\u79F0" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.label,
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.value.configs.label = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u63D0\u793A" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.placeholder,
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.value.configs.placeholder = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u7981\u7528" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.disabled,
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => _ctx.value.configs.disabled = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u65F6\u95F4\u8303\u56F4" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.isRange,
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => _ctx.value.configs.isRange = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u5FC5\u586B" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.rules.required,
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => _ctx.value.configs.rules.required = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
_ctx.value.configs.rules.required ? (openBlock(), createElementBlock("div", _hoisted_2$6, [
createVNode(_component_el_form_item, { label: "\u63D0\u793A\u8BED" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.rules.message,
"onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => _ctx.value.configs.rules.message = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u89E6\u53D1" }, {
default: withCtx(() => [
createVNode(_component_el_radio_group, {
modelValue: _ctx.value.configs.rules.trigger,
"onUpdate:modelValue": _cache[6] || (_cache[6] = ($event) => _ctx.value.configs.rules.trigger = $event)
}, {
default: withCtx(() => [
createVNode(_component_el_radio, { label: "blur" }, {
default: withCtx(() => [
_hoisted_3$3
]),
_: 1
}),
createVNode(_component_el_radio, { label: "change" }, {
default: withCtx(() => [
_hoisted_4$2
]),
_: 1
})
]),
_: 1
}, 8, ["modelValue"])
]),
_: 1
})
])) : createCommentVNode("", true),
createVNode(_component_el_form_item, { label: "\u6E05\u7A7A" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.clearable,
"onUpdate:modelValue": _cache[7] || (_cache[7] = ($event) => _ctx.value.configs.clearable = $event)
}, null, 8, ["modelValue"])
]),
_: 1
})
]),
_: 1
})
]);
}
var timePickerEdit = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["render", _sfc_render$3], ["__scopeId", "data-v-5c5d0268"]]);
var timeSelectEdit_vue_vue_type_style_index_0_scoped_true_lang = "";
const _sfc_main$4 = defineComponent({
props: { value: { type: Object, default: {} } },
setup(props, context) {
const max = ref("");
const maxChange = (value) => {
let steps = props.value.configs.step.split(":");
let step = Number(steps[0]) * 60 + Number(steps[1]);
let maxs = value.split(":");
let count = Number(maxs[0]) * 60 + Number(maxs[1]);
let h2 = Math.floor((count - step) / 60);
let m = (count - step) % 60;
max.value = `${h2 < 10 ? "0" + h2 : h2}:${m < 10 ? "0" + m : m}`;
};
const onChange = () => {
props.value.configs.min = "";
props.value.configs.max = "";
max.value = "";
};
return { max, maxChange, onChange };
}
});
const _withScopeId = (n) => (pushScopeId("data-v-71690bb9"), n = n(), popScopeId(), n);
const _hoisted_1$5 = { class: "item-option" };
const _hoisted_2$5 = /* @__PURE__ */ _withScopeId(() => /* @__PURE__ */ createElementVNode("div", { class: "label" }, "\u5F00\u59CB", -1));
const _hoisted_3$2 = { style: { "margin-top": "12px" } };
const _hoisted_4$1 = /* @__PURE__ */ _withScopeId(() => /* @__PURE__ */ createElementVNode("div", { class: "label" }, "\u7ED3\u675F", -1));
const _hoisted_5$1 = { key: 0 };
const _hoisted_6$1 = /* @__PURE__ */ createTextVNode("\u5931\u53BB\u7126\u70B9");
const _hoisted_7$1 = /* @__PURE__ */ createTextVNode("\u9009\u9879\u6539\u53D8");
function _sfc_render$2(_ctx, _cache, $props, $setup, $data, $options) {
const _component_el_input = resolveComponent("el-input");
const _component_el_form_item = resolveComponent("el-form-item");
const _component_el_time_select = resolveComponent("el-time-select");
const _component_el_checkbox = resolveComponent("el-checkbox");
const _component_el_radio = resolveComponent("el-radio");
const _component_el_radio_group = resolveComponent("el-radio-group");
const _component_el_form = resolveComponent("el-form");
return openBlock(), createElementBlock("div", _hoisted_1$5, [
createVNode(_component_el_form, {
size: "mini",
"label-width": "100px"
}, {
default: withCtx(() => [
createVNode(_component_el_form_item, { label: "\u540D\u79F0" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.label,
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.value.configs.label = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u5F00\u59CB" }, {
default: withCtx(() => [
createVNode(_component_el_time_select, {
modelValue: _ctx.value.configs.start,
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.value.configs.start = $event),
placeholder: "\u5F00\u59CB\u65F6\u95F4",
start: "00:00",
end: "23:59",
step: _ctx.value.configs.step,
onChange: _ctx.onChange,
"max-time": _ctx.value.configs.end
}, null, 8, ["modelValue", "step", "onChange", "max-time"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u7ED3\u675F" }, {
default: withCtx(() => [
createVNode(_component_el_time_select, {
modelValue: _ctx.value.configs.end,
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => _ctx.value.configs.end = $event),
placeholder: "\u7ED3\u675F\u65F6\u95F4",
start: "00:00",
end: "23:59",
step: _ctx.value.configs.step,
onChange: _ctx.onChange,
"min-time": _ctx.value.configs.start
}, null, 8, ["modelValue", "step", "onChange", "min-time"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u7981\u6B62\u65F6\u95F4" }, {
default: withCtx(() => [
createElementVNode("div", null, [
_hoisted_2$5,
createVNode(_component_el_time_select, {
modelValue: _ctx.value.configs.min,
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => _ctx.value.configs.min = $event),
placeholder: "\u5F00\u59CB\u65F6\u95F4",
start: _ctx.value.configs.start,
end: _ctx.value.configs.end,
step: _ctx.value.configs.step,
"max-time": _ctx.max
}, null, 8, ["modelValue", "start", "end", "step", "max-time"])
]),
createElementVNode("div", _hoisted_3$2, [
_hoisted_4$1,
createVNode(_component_el_time_select, {
modelValue: _ctx.value.configs.max,
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => _ctx.value.configs.max = $event),
placeholder: "\u7ED3\u675F\u65F6\u95F4",
start: _ctx.value.configs.start,
end: _ctx.value.configs.end,
step: _ctx.value.configs.step,
onChange: _ctx.maxChange,
"min-time": _ctx.value.configs.min
}, null, 8, ["modelValue", "start", "end", "step", "onChange", "min-time"])
])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u63D0\u793A" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.placeholder,
"onUpdate:modelValue": _cache[5] || (_cache[5] = ($event) => _ctx.value.configs.placeholder = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u7981\u7528" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.disabled,
"onUpdate:modelValue": _cache[6] || (_cache[6] = ($event) => _ctx.value.configs.disabled = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u65F6\u95F4\u8303\u56F4" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.isRange,
"onUpdate:modelValue": _cache[7] || (_cache[7] = ($event) => _ctx.value.configs.isRange = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u5FC5\u586B" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.rules.required,
"onUpdate:modelValue": _cache[8] || (_cache[8] = ($event) => _ctx.value.configs.rules.required = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
_ctx.value.configs.rules.required ? (openBlock(), createElementBlock("div", _hoisted_5$1, [
createVNode(_component_el_form_item, { label: "\u63D0\u793A\u8BED" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.configs.rules.message,
"onUpdate:modelValue": _cache[9] || (_cache[9] = ($event) => _ctx.value.configs.rules.message = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u89E6\u53D1" }, {
default: withCtx(() => [
createVNode(_component_el_radio_group, {
modelValue: _ctx.value.configs.rules.trigger,
"onUpdate:modelValue": _cache[10] || (_cache[10] = ($event) => _ctx.value.configs.rules.trigger = $event)
}, {
default: withCtx(() => [
createVNode(_component_el_radio, { label: "blur" }, {
default: withCtx(() => [
_hoisted_6$1
]),
_: 1
}),
createVNode(_component_el_radio, { label: "change" }, {
default: withCtx(() => [
_hoisted_7$1
]),
_: 1
})
]),
_: 1
}, 8, ["modelValue"])
]),
_: 1
})
])) : createCommentVNode("", true),
createVNode(_component_el_form_item, { label: "\u6E05\u7A7A" }, {
default: withCtx(() => [
createVNode(_component_el_checkbox, {
modelValue: _ctx.value.configs.clearable,
"onUpdate:modelValue": _cache[11] || (_cache[11] = ($event) => _ctx.value.configs.clearable = $event)
}, null, 8, ["modelValue"])
]),
_: 1
})
]),
_: 1
})
]);
}
var timeSelectEdit = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["render", _sfc_render$2], ["__scopeId", "data-v-71690bb9"]]);
var script$2 = defineComponent({
name: "ArrowDownBold"
});
const _hoisted_1$4 = {
xmlns: "http://www.w3.org/2000/svg",
viewBox: "0 0 1024 1024"
};
const _hoisted_2$4 = /* @__PURE__ */ createVNode("path", {
fill: "currentColor",
d: "M104.704 338.752a64 64 0 0 1 90.496 0l316.8 316.8 316.8-316.8a64 64 0 0 1 90.496 90.496L557.248 791.296a64 64 0 0 1-90.496 0L104.704 429.248a64 64 0 0 1 0-90.496z"
}, null, -1);
function render$2(_ctx, _cache, $props, $setup, $data, $options) {
return openBlock(), createBlock("svg", _hoisted_1$4, [
_hoisted_2$4
]);
}
script$2.render = render$2;
script$2.__file = "packages/components/ArrowDownBold.vue";
var ArrowDownBold = script$2;
var script$1 = defineComponent({
name: "ArrowUpBold"
});
const _hoisted_1$3 = {
xmlns: "http://www.w3.org/2000/svg",
viewBox: "0 0 1024 1024"
};
const _hoisted_2$3 = /* @__PURE__ */ createVNode("path", {
fill: "currentColor",
d: "M104.704 685.248a64 64 0 0 0 90.496 0l316.8-316.8 316.8 316.8a64 64 0 0 0 90.496-90.496L557.248 232.704a64 64 0 0 0-90.496 0L104.704 594.752a64 64 0 0 0 0 90.496z"
}, null, -1);
function render$1(_ctx, _cache, $props, $setup, $data, $options) {
return openBlock(), createBlock("svg", _hoisted_1$3, [
_hoisted_2$3
]);
}
script$1.render = render$1;
script$1.__file = "packages/components/ArrowUpBold.vue";
var ArrowUpBold = script$1;
var script = defineComponent({
name: "Delete"
});
const _hoisted_1$2 = {
xmlns: "http://www.w3.org/2000/svg",
viewBox: "0 0 1024 1024"
};
const _hoisted_2$2 = /* @__PURE__ */ createVNode("path", {
fill: "currentColor",
d: "M160 256H96a32 32 0 0 1 0-64h256V95.936a32 32 0 0 1 32-32h256a32 32 0 0 1 32 32V192h256a32 32 0 1 1 0 64h-64v672a32 32 0 0 1-32 32H192a32 32 0 0 1-32-32V256zm448-64v-64H416v64h192zM224 896h576V256H224v640zm192-128a32 32 0 0 1-32-32V416a32 32 0 0 1 64 0v320a32 32 0 0 1-32 32zm192 0a32 32 0 0 1-32-32V416a32 32 0 0 1 64 0v320a32 32 0 0 1-32 32z"
}, null, -1);
function render(_ctx, _cache, $props, $setup, $data, $options) {
return openBlock(), createBlock("svg", _hoisted_1$2, [
_hoisted_2$2
]);
}
script.render = render;
script.__file = "packages/components/Delete.vue";
var Delete = script;
var formEdit_vue_vue_type_style_index_0_scoped_true_lang = "";
const _sfc_main$3 = defineComponent({
components: { ArrowUpBold, ArrowDownBold },
props: { value: { type: Object, default: {} } },
setup() {
const visible = ref(false);
const toggle = () => {
visible.value = !visible.value;
};
return { visible, toggle };
}
});
const _hoisted_1$1 = { class: "aside-title" };
const _hoisted_2$1 = /* @__PURE__ */ createTextVNode(" \u8868\u5355\u914D\u7F6E ");
const _hoisted_3$1 = /* @__PURE__ */ createTextVNode("\u6700\u5C0F");
const _hoisted_4 = /* @__PURE__ */ createTextVNode("\u4E2D\u7B49");
const _hoisted_5 = /* @__PURE__ */ createTextVNode("\u6700\u5927");
const _hoisted_6 = /* @__PURE__ */ createTextVNode("\u53F3\u5BF9\u9F50");
const _hoisted_7 = /* @__PURE__ */ createTextVNode("\u5DE6\u5BF9\u9F50");
const _hoisted_8 = /* @__PURE__ */ createTextVNode("\u4E0A\u5BF9\u9F50");
function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
const _component_arrow_up_bold = resolveComponent("arrow-up-bold");
const _component_el_icon = resolveComponent("el-icon");
const _component_arrow_down_bold = resolveComponent("arrow-down-bold");
const _component_el_input = resolveComponent("el-input");
const _component_el_form_item = resolveComponent("el-form-item");
const _component_el_radio = resolveComponent("el-radio");
const _component_el_radio_group = resolveComponent("el-radio-group");
const _component_el_input_number = resolveComponent("el-input-number");
const _component_el_form = resolveComponent("el-form");
return openBlock(), createElementBlock("div", null, [
createElementVNode("div", _hoisted_1$1, [
_hoisted_2$1,
_ctx.visible ? (openBlock(), createBlock(_component_el_icon, {
key: 0,
class: "icon",
onClick: _ctx.toggle
}, {
default: withCtx(() => [
createVNode(_component_arrow_up_bold, { size: 20 })
]),
_: 1
}, 8, ["onClick"])) : (openBlock(), createBlock(_component_el_icon, {
key: 1,
class: "icon",
size: 16,
onClick: _ctx.toggle
}, {
default: withCtx(() => [
createVNode(_component_arrow_down_bold)
]),
_: 1
}, 8, ["onClick"]))
]),
withDirectives(createVNode(_component_el_form, {
modelValue: _ctx.value,
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => _ctx.value = $event),
size: "mini",
"label-width": "100px"
}, {
default: withCtx(() => [
createVNode(_component_el_form_item, { label: "\u540D\u79F0" }, {
default: withCtx(() => [
createVNode(_component_el_input, {
modelValue: _ctx.value.name,
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.value.name = $event)
}, null, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u5C3A\u5BF8" }, {
default: withCtx(() => [
createVNode(_component_el_radio_group, {
modelValue: _ctx.value.size,
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => _ctx.value.size = $event)
}, {
default: withCtx(() => [
createVNode(_component_el_radio, { label: "mini" }, {
default: withCtx(() => [
_hoisted_3$1
]),
_: 1
}),
createVNode(_component_el_radio, { label: "small" }, {
default: withCtx(() => [
_hoisted_4
]),
_: 1
}),
createVNode(_component_el_radio, { label: "medium" }, {
default: withCtx(() => [
_hoisted_5
]),
_: 1
})
]),
_: 1
}, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u5BF9\u9F50" }, {
default: withCtx(() => [
createVNode(_component_el_radio_group, {
modelValue: _ctx.value.position,
"onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => _ctx.value.position = $event)
}, {
default: withCtx(() => [
createVNode(_component_el_radio, { label: "right" }, {
default: withCtx(() => [
_hoisted_6
]),
_: 1
}),
createVNode(_component_el_radio, { label: "left" }, {
default: withCtx(() => [
_hoisted_7
]),
_: 1
}),
createVNode(_component_el_radio, { label: "top" }, {
default: withCtx(() => [
_hoisted_8
]),
_: 1
})
]),
_: 1
}, 8, ["modelValue"])
]),
_: 1
}),
createVNode(_component_el_form_item, { label: "\u5BBD\u5EA6" }, {
default: withCtx(() => [
createVNode(_component_el_input_number, {
modelValue: _ctx.value.labelWidth,
"onUpdate:modelValue": _cache[3] || (_cache[3] = ($event) => _ctx.value.labelWidth = $event),
min: 100
}, null, 8, ["modelValue"])
]),
_: 1
})
]),
_: 1
}, 8, ["modelValue"]), [
[vShow, _ctx.visible]
])
]);
}
var formEdit = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["render", _sfc_render$1], ["__scopeId", "data-v-1758dc2a"]]);
var _sfc_main$2 = defineComponent({
components: {
selectEdit,
formEdit,
checkboxEdit,
switchEdit,
rateEdit,
datePickerEdit,
timePickerEdit,
timeSelectEdit,
radioEdit,
inputEdit,
inputTextareaEdit,
inputNumberEdit
},
props: {
value: {
type: Object,
default: {}
},
form: {
type: Object,
default: {}
}
},
setup(props, context) {
console.log(props.form);
let element = props.value.element + "-edit";
return () => createVNode("div", {
"class": "aside-right"
}, [h(resolveComponent("form-edit"), {
value: props.form
}), createVNode("div", {
"class": "aside-title"
}, [createTextVNode("\u8868\u5355\u9879\u914D\u7F6E")]), h(resolveComponent(element), {
value: props.value,
"onUpdate:value": (data) => {
}
})]);
}
});
var asideRight_vue_vue_type_style_index_0_scoped_true_lang = "";
var asideRight = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["__scopeId", "data-v-1db7147a"]]);
var _sfc_main$1 = defineComponent({
props: {
options: {
type: Object,
default: {}
}
},
setup(props) {
props.options;
let element = "wt-" + props.options.element;
return () => h(resolveComponent(element), {
configs: props.options.configs
});
}
});
const formConfigs = {
checkbox: {
element: "checkbox",
name: "\u591A\u9009\u6846",
configs: {
label: "\u591A\u9009\u6846",
disabled: false,
value: [],
rules: {
required: false,
trigger: "blur",
message: "\u8BE5\u9879\u4E3A\u5FC5\u586B\u9879"
},
list: [
{ label: "\u9009\u98791", value: "\u9009\u98791" },
{ label: "\u9009\u98792", value: "\u9009\u98792" },
{ label: "\u9009\u98793", value: "\u9009\u98793" }
]
}
},
radio: {
element: "radio",
name: "\u5355\u9009\u6846",
configs: {
label: "\u5355\u9009\u6846",
disabled: false,
value: "",
rules: {
required: false,
trigger: "blur",
message: "\u8BE5\u9879\u4E3A\u5FC5\u586B\u9879"
},
list: [
{ label: "\u9009\u98791", value: "\u9009\u98791" },
{ label: "\u9009\u98792", value: "\u9009\u98792" },
{ label: "\u9009\u98793", value: "\u9009\u98793" }
]
}
},
input: {
element: "input",
name: "\u6587\u672C\u6846",
configs: {
label: "\u6587\u672C\u6846",
disabled: false,
value: "",
placeholder: "",
clearable: false,
rules: {
required: false,
trigger: "blur",
message: "\u8BE5\u9879\u4E3A\u5FC5\u586B\u9879"
},
placeholder: "\u8BF7\u8F93\u5165"
}
},
"input-textarea": {
element: "inputTextarea",
name: "\u591A\u884C\u6587\u672C\u6846",
configs: {
label: "\u591A\u884C\u6587\u672C\u6846",
disabled: false,
rows: 2,
autosize: false,
value: "",
placeholder: "",
clearable: false,
rules: {
required: false,
trigger: "blur",
message: "\u8BE5\u9879\u4E3A\u5FC5\u586B\u9879"
},
placeholder: "\u8BF7\u8F93\u5165"
}
},
"input-number": {
element: "input-number",
name: "\u8BA1\u6570\u5668",
configs: {
label: "\u8BA1\u6570\u5668",
disabled: false,
value: 0,
max: 100,
min: 0,
step: 1,
"controls-position": "right",
rules: {
required: false,
trigger: "blur",
message: "\u8BE5\u9879\u4E3A\u5FC5\u586B\u9879"
}
}
},
select: {
element: "select",
name: "\u9009\u62E9\u5668",
configs: {
label: "\u9009\u62E9\u5668",
disabled: false,
value: "",
multiple: false,
clearable: true,
filterable: false,
rules: {
required: false,
trigger: "blur",
message: "\u8BE5\u9879\u4E3A\u5FC5\u586B\u9879"
},
list: [
{ label: "\u9009\u98791", value: "\u9009\u98791" },
{ label: "\u9009\u98792", value: "\u9009\u98792" },
{ label: "\u9009\u98793", value: "\u9009\u98793" }
],
placeholder: "\u8BF7\u9009\u62E9"
}
},
switch: {
element: "switch",
name: "\u5F00\u5173",
configs: {
label: "\u5F00\u5173",
disabled: false,
value: false,
activeText: "",
inactiveText: ""
}
},
rate: {
element: "rate",
name: "\u8BC4\u5206",
configs: {
label: "\u8BC4\u5206",
disabled: false,
value: 0,
allowHalf: false,
showText: false,
texts: ["1\u661F", "2\u661F", "3\u661F", "4\u661F", "5\u661F"],
rules: {
required: false,
trigger: "blur",
message: "\u8BE5\u9879\u4E3A\u5FC5\u586B\u9879"
}
}
},
"date-picker": {
element: "date-picker",
name: "\u65E5\u671F\u9009\u62E9",
configs: {
label: "\u65E5\u671F\u9009\u62E9",
type: "date",
label: "\u65E5\u671F\u9009\u62E9",
disabled: false,
value: "",
placeholder: "\u8BF7\u9009\u62E9",
format: "YYYY-MM-DD",
valueFormat: "",
disabledMin: "",
disabledMax: "",
disType: "date",
rules: {
required: false,
trigger: "blur",
message: "\u8BE5\u9879\u4E3A\u5FC5\u586B\u9879"
}
}
},
"time-picker": {
element: "time-picker",
name: "\u65F6\u95F4\u9009\u62E9",
configs: {
label: "\u65F6\u95F4\u9009\u62E9",
disabled: false,
value: "",
placeholder: "\u8BF7\u9009\u62E9",
isRange: false,
rules: {
required: false,
trigger: "blur",
message: "\u8BE5\u9879\u4E3A\u5FC5\u586B\u9879"
}
}
},
"time-select": {
element: "time-select",
name: "\u65F6\u95F4\u9009\u62E9\u5668",
configs: {
label: "\u65F6\u95F4\u9009\u62E9\u5668",
disabled: false,
value: "",
placeholder: "\u8BF7\u9009\u62E9",
start: "00:00",
end: "23:59",
step: "00:15",
min: "",
max: "",
rules: {
required: false,
trigger: "blur",
message: "\u8BE5\u9879\u4E3A\u5FC5\u586B\u9879"
}
}
}
};
var index_vue_vue_type_style_index_0_scoped_true_lang = "";
const _sfc_main = defineComponent({
components: {
asideLeft,
asideRight,
formItem: _sfc_main$1,
Delete
},
setup(props, context) {
const list = reactive([]);
const editIndex = ref(null);
const form = reactive({
name: "\u8868\u5355",
size: "mini",
position: "right",
labelWidth: 100
});
const onSelect = (l) => {
let el = l.type ? l.value + "-" + l.type : l.value;
let item = JSON.parse(JSON.stringify(formConfigs[el]));
item.id = "l-" + new Date().getTime();
list.push(item);
editIndex.value = list.length - 1;
};
const onDelete = (i) => {
list.splice(i, 1);
if (i != editIndex.value)
return;
if (list[i]) {
editIndex.value = i;
} else {
if (list[i - 1])
editIndex.value = i - 1;
}
if (!list.length)
editIndex.value = null;
};
const pos = reactive({
moveIndex: null,
targetIndex: null
});
const onDrag = (e) => {
e.preventDefault();
};
const onDragstart = (e, l, i) => {
e.dataTransfer.effectAllowed = "copy";
pos.moveIndex = i;
};
const onDragend = (e) => {
let moveItem = list.splice(pos.moveIndex, 1)[0];
list.splice(pos.targetIndex, 0, moveItem);
editIndex.value = pos.targetIndex;
setTimeout(() => {
moveItem.id = "l-" + new Date().getTime();
pos.moveIndex = null;
pos.targetIndex = null;
}, 20);
};
const allowDrag = (e) => {
e.preventDefault();
};
const onDragenter = (e) => {
pos.targetIndex = Number(e.target.getAttribute("data-index"));
};
const editItem = (l, i) => {
editIndex.value = i;
};
return {
onSelect,
list,
editIndex,
form,
onDelete,
onDrag,
onDragstart,
onDragend,
allowDrag,
pos,
onDragenter,
editItem
};
}
});
const _hoisted_1 = { class: "custom-form" };
const _hoisted_2 = { class: "title" };
const _hoisted_3 = ["onDragstart", "data-index", "onClick"];
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
const _component_aside_left = resolveComponent("aside-left");
const _component_el_empty = resolveComponent("el-empty");
const _component_form_item = resolveComponent("form-item");
const _component_Delete = resolveComponent("Delete");
const _component_el_icon = resolveComponent("el-icon");
const _component_el_form_item = resolveComponent("el-form-item");
const _component_el_form = resolveComponent("el-form");
const _component_aside_right = resolveComponent("aside-right");
return openBlock(), createElementBlock("div", _hoisted_1, [
createVNode(_component_aside_left, { onOnSelect: _ctx.onSelect }, null, 8, ["onOnSelect"]),
createElementVNode("main", {
class: normalizeClass({ pdf: _ctx.editIndex == null })
}, [
createElementVNode("div", _hoisted_2, toDisplayString(_ctx.form.name), 1),
createVNode(_component_el_form, {
model: {},
size: _ctx.form.size,
"label-width": _ctx.form.labelWidth + "px",
"label-position": _ctx.form.position,
class: "form-edit"
}, {
default: withCtx(() => [
!_ctx.list.length ? (openBlock(), createBlock(_component_el_empty, {
key: 0,
description: "\u6682\u65E0\u8868\u5355\u9879\uFF0C\u70B9\u51FB\u5DE6\u4FA7\u63A7\u4EF6\u5B8C\u5584\u8868\u5355"
})) : createCommentVNode("", true),
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.list, (l, i) => {
return openBlock(), createElementBlock("div", {
class: normalizeClass(["item-wrap", { isTarget: _ctx.pos.targetIndex === i, isCurrent: _ctx.editIndex == i }]),
key: l.id,
draggable: "true",
onDrag: _cache[0] || (_cache[0] = (...args) => _ctx.onDrag && _ctx.onDrag(...args)),
onDragstart: ($event) => _ctx.onDragstart($event, l, i),
onDragend: _cache[1] || (_cache[1] = (...args) => _ctx.onDragend && _ctx.onDragend(...args)),
onDragover: _cache[2] || (_cache[2] = (...args) => _ctx.allowDrag && _ctx.allowDrag(...args)),
onDragenter: _cache[3] || (_cache[3] = (...args) => _ctx.onDragenter && _ctx.onDragenter(...args)),
"data-index": i,
onClick: ($event) => _ctx.editItem(l, i)
}, [
createVNode(_component_el_form_item, {
class: "item",
"data-index": i,
label: l.configs.label,
prop: l.id,
rules: l.configs.rules
}, {
default: withCtx(() => [
createVNode(_component_form_item, { options: l }, null, 8, ["options"]),
createVNode(_component_el_icon, {
class: "flow-icon",
onClick: ($event) => _ctx.onDelete(i)
}, {
default: withCtx(() => [
createVNode(_component_Delete)
]),
_: 2
}, 1032, ["onClick"])
]),
_: 2
}, 1032, ["data-index", "label", "prop", "rules"])
], 42, _hoisted_3);
}), 128))
]),
_: 1
}, 8, ["size", "label-width", "label-position"])
], 2),
_ctx.editIndex != null ? (openBlock(), createBlock(_component_aside_right, {
key: _ctx.list[_ctx.editIndex] ? _ctx.list[_ctx.editIndex].id : "aside-right",
form: _ctx.form,
"onUpdate:form": _cache[4] || (_cache[4] = ($event) => _ctx.form = $event),
value: _ctx.list[_ctx.editIndex],
"onUpdate:value": _cache[5] || (_cache[5] = ($event) => _ctx.list[_ctx.editIndex] = $event)
}, null, 8, ["form", "value"])) : createCommentVNode("", true)
]);
}
var formTemplate = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-08ba28a0"]]);
var index = { formTemplate };
export { index as default };