@tmagic/form 1.3.0-alpha.2 → 1.3.0-alpha.3

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 (71) hide show
  1. package/dist/tmagic-form.js +889 -903
  2. package/dist/tmagic-form.js.map +1 -1
  3. package/dist/tmagic-form.umd.cjs +887 -901
  4. package/dist/tmagic-form.umd.cjs.map +1 -1
  5. package/package.json +10 -11
  6. package/src/Form.vue +5 -1
  7. package/src/FormDialog.vue +5 -1
  8. package/src/containers/Col.vue +5 -1
  9. package/src/containers/Container.vue +5 -1
  10. package/src/containers/Fieldset.vue +5 -1
  11. package/src/containers/GroupList.vue +5 -1
  12. package/src/containers/GroupListItem.vue +5 -1
  13. package/src/containers/Panel.vue +5 -1
  14. package/src/containers/Row.vue +5 -1
  15. package/src/containers/Step.vue +5 -1
  16. package/src/containers/Table.vue +5 -1
  17. package/src/containers/Tabs.vue +14 -8
  18. package/src/fields/Cascader.vue +5 -1
  19. package/src/fields/Checkbox.vue +5 -1
  20. package/src/fields/CheckboxGroup.vue +6 -2
  21. package/src/fields/ColorPicker.vue +5 -1
  22. package/src/fields/Date.vue +5 -1
  23. package/src/fields/DateTime.vue +5 -1
  24. package/src/fields/Daterange.vue +5 -1
  25. package/src/fields/Display.vue +5 -1
  26. package/src/fields/DynamicField.vue +5 -1
  27. package/src/fields/Hidden.vue +5 -1
  28. package/src/fields/Link.vue +5 -1
  29. package/src/fields/Number.vue +5 -1
  30. package/src/fields/RadioGroup.vue +5 -1
  31. package/src/fields/Select.vue +9 -9
  32. package/src/fields/SelectOptionGroups.vue +7 -3
  33. package/src/fields/SelectOptions.vue +5 -1
  34. package/src/fields/Switch.vue +5 -1
  35. package/src/fields/Text.vue +5 -1
  36. package/src/fields/Textarea.vue +5 -1
  37. package/src/fields/Time.vue +5 -1
  38. package/src/index.ts +39 -37
  39. package/types/Form.vue.d.ts +7 -4
  40. package/types/FormDialog.vue.d.ts +76 -121
  41. package/types/containers/Col.vue.d.ts +1 -1
  42. package/types/containers/Container.vue.d.ts +6 -3
  43. package/types/containers/Fieldset.vue.d.ts +6 -3
  44. package/types/containers/GroupList.vue.d.ts +1 -1
  45. package/types/containers/GroupListItem.vue.d.ts +1 -1
  46. package/types/containers/Panel.vue.d.ts +3 -3
  47. package/types/containers/Row.vue.d.ts +1 -1
  48. package/types/containers/Step.vue.d.ts +6 -3
  49. package/types/containers/Table.vue.d.ts +9 -6
  50. package/types/containers/Tabs.vue.d.ts +6 -3
  51. package/types/fields/Cascader.vue.d.ts +1 -1
  52. package/types/fields/Checkbox.vue.d.ts +1 -1
  53. package/types/fields/CheckboxGroup.vue.d.ts +1 -1
  54. package/types/fields/ColorPicker.vue.d.ts +1 -1
  55. package/types/fields/Date.vue.d.ts +1 -1
  56. package/types/fields/DateTime.vue.d.ts +1 -1
  57. package/types/fields/Daterange.vue.d.ts +1 -1
  58. package/types/fields/Display.vue.d.ts +2 -2
  59. package/types/fields/DynamicField.vue.d.ts +1 -10
  60. package/types/fields/Hidden.vue.d.ts +2 -2
  61. package/types/fields/Link.vue.d.ts +1 -1
  62. package/types/fields/Number.vue.d.ts +1 -1
  63. package/types/fields/RadioGroup.vue.d.ts +1 -1
  64. package/types/fields/Select.vue.d.ts +1 -1
  65. package/types/fields/SelectOptionGroups.vue.d.ts +2 -2
  66. package/types/fields/SelectOptions.vue.d.ts +2 -2
  67. package/types/fields/Switch.vue.d.ts +1 -1
  68. package/types/fields/Text.vue.d.ts +1 -1
  69. package/types/fields/Textarea.vue.d.ts +1 -1
  70. package/types/fields/Time.vue.d.ts +1 -1
  71. package/types/index.d.ts +4 -1
@@ -1,9 +1,9 @@
1
- import { toRaw, defineComponent, inject, ref, computed, resolveComponent, watchEffect, watch, openBlock, createElementBlock, normalizeStyle, normalizeClass, unref, createBlock, resolveDynamicComponent, Fragment, createVNode, withCtx, createElementVNode, createCommentVNode, renderList, createTextVNode, toDisplayString, withDirectives, vShow, renderSlot, onMounted, toRefs, mergeProps, getCurrentInstance, reactive, onBeforeUnmount, vModelText, provide, onBeforeMount, resolveDirective, createSlots, withModifiers } from 'vue';
1
+ import { toRaw, defineComponent, inject, ref, computed, resolveComponent, watchEffect, watch, openBlock, createElementBlock, normalizeStyle, normalizeClass, createBlock, resolveDynamicComponent, Fragment, createVNode, unref, withCtx, createElementVNode, createCommentVNode, renderList, createTextVNode, toDisplayString, withDirectives, vShow, renderSlot, onMounted, toRefs, mergeProps, getCurrentInstance, reactive, onBeforeUnmount, vModelText, provide, onBeforeMount, resolveDirective, createSlots, withModifiers } from 'vue';
2
2
  import { WarningFilled, CaretBottom, CaretRight, Delete, CaretTop, Grid, ArrowUp, ArrowDown, FullScreen } from '@element-plus/icons-vue';
3
3
  import { cloneDeep, isEqual, isEmpty } from 'lodash-es';
4
4
  import { TMagicFormItem, TMagicTooltip, TMagicIcon, TMagicButton, TMagicCheckbox, TMagicCard, TMagicCol, TMagicRow, TMagicSteps, TMagicStep, TMagicTable, TMagicTableColumn, TMagicUpload, TMagicPagination, tMagicMessage, getConfig as getConfig$1, TMagicBadge, TMagicCascader, TMagicCheckboxGroup, TMagicColorPicker, TMagicDatePicker, TMagicForm, TMagicInput, TMagicDialog, TMagicInputNumber, TMagicRadioGroup, TMagicRadio, TMagicOptionGroup, TMagicOption, TMagicSelect, TMagicSwitch, TMagicTimePicker } from '@tmagic/design';
5
5
  import Sortable from 'sortablejs';
6
- import { asyncLoadJs, sleep, datetimeFormatter, isNumber } from '@tmagic/utils';
6
+ import { asyncLoadJs, sleep, datetimeFormatter, getValueByKeyPath, isNumber } from '@tmagic/utils';
7
7
  import cloneDeep$1 from 'lodash-es/cloneDeep';
8
8
 
9
9
  const isTableSelect = (type) => typeof type === "string" && ["table-select", "tableSelect"].includes(type);
@@ -167,35 +167,35 @@ const initValue = async (mForm, { initValues, config }) => {
167
167
  };
168
168
 
169
169
  const _hoisted_1$b = ["innerHTML"];
170
- const _hoisted_2$7 = ["innerHTML"];
171
- const _hoisted_3$7 = ["innerHTML"];
172
- const _hoisted_4$6 = ["innerHTML"];
173
- const _hoisted_5$4 = ["innerHTML"];
174
- const _hoisted_6$3 = ["innerHTML"];
175
- const _hoisted_7$3 = ["innerHTML"];
176
- const _hoisted_8$2 = ["innerHTML"];
177
- const _hoisted_9$1 = ["innerHTML"];
178
- const _hoisted_10$1 = ["innerHTML"];
170
+ const _hoisted_2$6 = ["innerHTML"];
171
+ const _hoisted_3$4 = ["innerHTML"];
172
+ const _hoisted_4$4 = ["innerHTML"];
173
+ const _hoisted_5$3 = ["innerHTML"];
174
+ const _hoisted_6$1 = ["innerHTML"];
175
+ const _hoisted_7$1 = ["innerHTML"];
176
+ const _hoisted_8$1 = ["innerHTML"];
177
+ const _hoisted_9 = ["innerHTML"];
178
+ const _hoisted_10 = ["innerHTML"];
179
179
  const _hoisted_11 = ["innerHTML"];
180
180
  const _hoisted_12 = ["innerHTML"];
181
181
  const _hoisted_13 = {
182
182
  key: 5,
183
183
  style: { "text-align": "center" }
184
184
  };
185
- const __default__$v = defineComponent({
186
- name: "MFormContainer"
187
- });
188
185
  const _sfc_main$v = /* @__PURE__ */ defineComponent({
189
- ...__default__$v,
186
+ ...{
187
+ name: "MFormContainer"
188
+ },
189
+ __name: "Container",
190
190
  props: {
191
- model: null,
191
+ model: {},
192
192
  lastValues: { default: () => ({}) },
193
- config: null,
193
+ config: {},
194
194
  prop: { default: "" },
195
195
  disabled: { type: Boolean },
196
- labelWidth: null,
196
+ labelWidth: {},
197
197
  expandMore: { type: Boolean, default: false },
198
- stepActive: null,
198
+ stepActive: {},
199
199
  size: { default: "small" },
200
200
  isCompare: { type: Boolean, default: false }
201
201
  },
@@ -327,94 +327,94 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
327
327
  return (_ctx, _cache) => {
328
328
  const _component_m_fields_hidden = resolveComponent("m-fields-hidden");
329
329
  const _component_Container = resolveComponent("Container", true);
330
- return __props.config ? (openBlock(), createElementBlock("div", {
330
+ return _ctx.config ? (openBlock(), createElementBlock("div", {
331
331
  key: 0,
332
- style: normalizeStyle(__props.config.tip ? "display: flex;align-items: baseline;" : ""),
333
- class: normalizeClass([__props.config.className, "m-form-container"])
332
+ style: normalizeStyle(_ctx.config.tip ? "display: flex;align-items: baseline;" : ""),
333
+ class: normalizeClass([_ctx.config.className, "m-form-container"])
334
334
  }, [
335
- unref(type) === "hidden" ? (openBlock(), createBlock(_component_m_fields_hidden, {
335
+ type.value === "hidden" ? (openBlock(), createBlock(_component_m_fields_hidden, {
336
336
  key: 0,
337
- model: __props.model,
338
- config: __props.config,
339
- name: __props.config.name,
340
- disabled: unref(disabled),
341
- prop: unref(itemProp)
342
- }, null, 8, ["model", "config", "name", "disabled", "prop"])) : unref(items) && !__props.config.text && unref(type) && unref(display$1) ? (openBlock(), createBlock(resolveDynamicComponent(unref(tagName)), {
343
- key: key(__props.config),
344
- size: __props.size,
345
- model: __props.model,
346
- "last-values": __props.lastValues,
347
- "is-compare": __props.isCompare,
348
- config: __props.config,
349
- disabled: unref(disabled),
350
- name: unref(name),
351
- prop: unref(itemProp),
352
- "step-active": __props.stepActive,
337
+ model: _ctx.model,
338
+ config: _ctx.config,
339
+ name: _ctx.config.name,
340
+ disabled: disabled.value,
341
+ prop: itemProp.value
342
+ }, null, 8, ["model", "config", "name", "disabled", "prop"])) : items.value && !_ctx.config.text && type.value && display$1.value ? (openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
343
+ key: key(_ctx.config),
344
+ size: _ctx.size,
345
+ model: _ctx.model,
346
+ "last-values": _ctx.lastValues,
347
+ "is-compare": _ctx.isCompare,
348
+ config: _ctx.config,
349
+ disabled: disabled.value,
350
+ name: name.value,
351
+ prop: itemProp.value,
352
+ "step-active": _ctx.stepActive,
353
353
  "expand-more": expand.value,
354
- "label-width": unref(itemLabelWidth),
354
+ "label-width": itemLabelWidth.value,
355
355
  onChange: onChangeHandler,
356
356
  onAddDiffCount
357
- }, null, 40, ["size", "model", "last-values", "is-compare", "config", "disabled", "name", "prop", "step-active", "expand-more", "label-width"])) : unref(type) && unref(display$1) && !unref(showDiff) ? (openBlock(), createElementBlock(Fragment, { key: 2 }, [
357
+ }, null, 40, ["size", "model", "last-values", "is-compare", "config", "disabled", "name", "prop", "step-active", "expand-more", "label-width"])) : type.value && display$1.value && !showDiff.value ? (openBlock(), createElementBlock(Fragment, { key: 2 }, [
358
358
  createVNode(unref(TMagicFormItem), {
359
- style: normalizeStyle(__props.config.tip ? "flex: 1" : ""),
360
- class: normalizeClass({ hidden: `${unref(itemLabelWidth)}` === "0" || !__props.config.text }),
361
- prop: unref(itemProp),
362
- "label-width": unref(itemLabelWidth),
363
- rules: unref(rule)
359
+ style: normalizeStyle(_ctx.config.tip ? "flex: 1" : ""),
360
+ class: normalizeClass({ hidden: `${itemLabelWidth.value}` === "0" || !_ctx.config.text }),
361
+ prop: itemProp.value,
362
+ "label-width": itemLabelWidth.value,
363
+ rules: rule.value
364
364
  }, {
365
365
  label: withCtx(() => [
366
366
  createElementVNode("span", {
367
- innerHTML: unref(type) === "checkbox" ? "" : __props.config.text
367
+ innerHTML: type.value === "checkbox" ? "" : _ctx.config.text
368
368
  }, null, 8, _hoisted_1$b)
369
369
  ]),
370
370
  default: withCtx(() => [
371
- unref(tooltip) ? (openBlock(), createBlock(unref(TMagicTooltip), { key: 0 }, {
371
+ tooltip.value ? (openBlock(), createBlock(unref(TMagicTooltip), { key: 0 }, {
372
372
  content: withCtx(() => [
373
- createElementVNode("div", { innerHTML: unref(tooltip) }, null, 8, _hoisted_2$7)
373
+ createElementVNode("div", { innerHTML: tooltip.value }, null, 8, _hoisted_2$6)
374
374
  ]),
375
375
  default: withCtx(() => [
376
- (openBlock(), createBlock(resolveDynamicComponent(unref(tagName)), {
377
- key: key(__props.config),
378
- size: __props.size,
379
- model: __props.model,
380
- "last-values": __props.lastValues,
381
- config: __props.config,
382
- name: unref(name),
383
- disabled: unref(disabled),
384
- prop: unref(itemProp),
376
+ (openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
377
+ key: key(_ctx.config),
378
+ size: _ctx.size,
379
+ model: _ctx.model,
380
+ "last-values": _ctx.lastValues,
381
+ config: _ctx.config,
382
+ name: name.value,
383
+ disabled: disabled.value,
384
+ prop: itemProp.value,
385
385
  onChange: onChangeHandler,
386
386
  onAddDiffCount
387
387
  }, null, 40, ["size", "model", "last-values", "config", "name", "disabled", "prop"]))
388
388
  ]),
389
389
  _: 1
390
- })) : (openBlock(), createBlock(resolveDynamicComponent(unref(tagName)), {
391
- key: key(__props.config),
392
- size: __props.size,
393
- model: __props.model,
394
- "last-values": __props.lastValues,
395
- config: __props.config,
396
- name: unref(name),
397
- disabled: unref(disabled),
398
- prop: unref(itemProp),
390
+ })) : (openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
391
+ key: key(_ctx.config),
392
+ size: _ctx.size,
393
+ model: _ctx.model,
394
+ "last-values": _ctx.lastValues,
395
+ config: _ctx.config,
396
+ name: name.value,
397
+ disabled: disabled.value,
398
+ prop: itemProp.value,
399
399
  onChange: onChangeHandler,
400
400
  onAddDiffCount
401
401
  }, null, 40, ["size", "model", "last-values", "config", "name", "disabled", "prop"])),
402
- unref(extra) && unref(type) !== "table" ? (openBlock(), createElementBlock("div", {
402
+ extra.value && type.value !== "table" ? (openBlock(), createElementBlock("div", {
403
403
  key: 2,
404
- innerHTML: unref(extra),
404
+ innerHTML: extra.value,
405
405
  class: "m-form-tip"
406
- }, null, 8, _hoisted_3$7)) : createCommentVNode("", true)
406
+ }, null, 8, _hoisted_3$4)) : createCommentVNode("", true)
407
407
  ]),
408
408
  _: 1
409
409
  }, 8, ["style", "class", "prop", "label-width", "rules"]),
410
- __props.config.tip ? (openBlock(), createBlock(unref(TMagicTooltip), {
410
+ _ctx.config.tip ? (openBlock(), createBlock(unref(TMagicTooltip), {
411
411
  key: 0,
412
412
  placement: "left"
413
413
  }, {
414
414
  content: withCtx(() => [
415
415
  createElementVNode("div", {
416
- innerHTML: __props.config.tip
417
- }, null, 8, _hoisted_4$6)
416
+ innerHTML: _ctx.config.tip
417
+ }, null, 8, _hoisted_4$4)
418
418
  ]),
419
419
  default: withCtx(() => [
420
420
  createVNode(unref(TMagicIcon), { style: { "line-height": "40px", "margin-left": "5px" } }, {
@@ -426,63 +426,63 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
426
426
  ]),
427
427
  _: 1
428
428
  })) : createCommentVNode("", true)
429
- ], 64)) : unref(type) && unref(display$1) && unref(showDiff) ? (openBlock(), createElementBlock(Fragment, { key: 3 }, [
429
+ ], 64)) : type.value && display$1.value && showDiff.value ? (openBlock(), createElementBlock(Fragment, { key: 3 }, [
430
430
  createVNode(unref(TMagicFormItem), {
431
- style: normalizeStyle([__props.config.tip ? "flex: 1" : "", { "background": "#f7dadd" }]),
432
- class: normalizeClass({ hidden: `${unref(itemLabelWidth)}` === "0" || !__props.config.text }),
433
- prop: unref(itemProp),
434
- "label-width": unref(itemLabelWidth),
435
- rules: unref(rule)
431
+ style: normalizeStyle([_ctx.config.tip ? "flex: 1" : "", { "background": "#f7dadd" }]),
432
+ class: normalizeClass({ hidden: `${itemLabelWidth.value}` === "0" || !_ctx.config.text }),
433
+ prop: itemProp.value,
434
+ "label-width": itemLabelWidth.value,
435
+ rules: rule.value
436
436
  }, {
437
437
  label: withCtx(() => [
438
438
  createElementVNode("span", {
439
- innerHTML: unref(type) === "checkbox" ? "" : __props.config.text
440
- }, null, 8, _hoisted_5$4)
439
+ innerHTML: type.value === "checkbox" ? "" : _ctx.config.text
440
+ }, null, 8, _hoisted_5$3)
441
441
  ]),
442
442
  default: withCtx(() => [
443
- unref(tooltip) ? (openBlock(), createBlock(unref(TMagicTooltip), { key: 0 }, {
443
+ tooltip.value ? (openBlock(), createBlock(unref(TMagicTooltip), { key: 0 }, {
444
444
  content: withCtx(() => [
445
- createElementVNode("div", { innerHTML: unref(tooltip) }, null, 8, _hoisted_6$3)
445
+ createElementVNode("div", { innerHTML: tooltip.value }, null, 8, _hoisted_6$1)
446
446
  ]),
447
447
  default: withCtx(() => [
448
- (openBlock(), createBlock(resolveDynamicComponent(unref(tagName)), {
449
- key: key(__props.config),
450
- size: __props.size,
451
- model: __props.lastValues,
452
- config: __props.config,
453
- name: unref(name),
454
- disabled: unref(disabled),
455
- prop: unref(itemProp),
448
+ (openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
449
+ key: key(_ctx.config),
450
+ size: _ctx.size,
451
+ model: _ctx.lastValues,
452
+ config: _ctx.config,
453
+ name: name.value,
454
+ disabled: disabled.value,
455
+ prop: itemProp.value,
456
456
  onChange: onChangeHandler
457
457
  }, null, 40, ["size", "model", "config", "name", "disabled", "prop"]))
458
458
  ]),
459
459
  _: 1
460
- })) : (openBlock(), createBlock(resolveDynamicComponent(unref(tagName)), {
461
- key: key(__props.config),
462
- size: __props.size,
463
- model: __props.lastValues,
464
- config: __props.config,
465
- name: unref(name),
466
- disabled: unref(disabled),
467
- prop: unref(itemProp),
460
+ })) : (openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
461
+ key: key(_ctx.config),
462
+ size: _ctx.size,
463
+ model: _ctx.lastValues,
464
+ config: _ctx.config,
465
+ name: name.value,
466
+ disabled: disabled.value,
467
+ prop: itemProp.value,
468
468
  onChange: onChangeHandler
469
469
  }, null, 40, ["size", "model", "config", "name", "disabled", "prop"])),
470
- unref(extra) ? (openBlock(), createElementBlock("div", {
470
+ extra.value ? (openBlock(), createElementBlock("div", {
471
471
  key: 2,
472
- innerHTML: unref(extra),
472
+ innerHTML: extra.value,
473
473
  class: "m-form-tip"
474
- }, null, 8, _hoisted_7$3)) : createCommentVNode("", true)
474
+ }, null, 8, _hoisted_7$1)) : createCommentVNode("", true)
475
475
  ]),
476
476
  _: 1
477
477
  }, 8, ["style", "class", "prop", "label-width", "rules"]),
478
- __props.config.tip ? (openBlock(), createBlock(unref(TMagicTooltip), {
478
+ _ctx.config.tip ? (openBlock(), createBlock(unref(TMagicTooltip), {
479
479
  key: 0,
480
480
  placement: "left"
481
481
  }, {
482
482
  content: withCtx(() => [
483
483
  createElementVNode("div", {
484
- innerHTML: __props.config.tip
485
- }, null, 8, _hoisted_8$2)
484
+ innerHTML: _ctx.config.tip
485
+ }, null, 8, _hoisted_8$1)
486
486
  ]),
487
487
  default: withCtx(() => [
488
488
  createVNode(unref(TMagicIcon), { style: { "line-height": "40px", "margin-left": "5px" } }, {
@@ -495,60 +495,60 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
495
495
  _: 1
496
496
  })) : createCommentVNode("", true),
497
497
  createVNode(unref(TMagicFormItem), {
498
- style: normalizeStyle([__props.config.tip ? "flex: 1" : "", { "background": "#def7da" }]),
499
- class: normalizeClass({ hidden: `${unref(itemLabelWidth)}` === "0" || !__props.config.text }),
500
- prop: unref(itemProp),
501
- "label-width": unref(itemLabelWidth),
502
- rules: unref(rule)
498
+ style: normalizeStyle([_ctx.config.tip ? "flex: 1" : "", { "background": "#def7da" }]),
499
+ class: normalizeClass({ hidden: `${itemLabelWidth.value}` === "0" || !_ctx.config.text }),
500
+ prop: itemProp.value,
501
+ "label-width": itemLabelWidth.value,
502
+ rules: rule.value
503
503
  }, {
504
504
  label: withCtx(() => [
505
505
  createElementVNode("span", {
506
- innerHTML: unref(type) === "checkbox" ? "" : __props.config.text
507
- }, null, 8, _hoisted_9$1)
506
+ innerHTML: type.value === "checkbox" ? "" : _ctx.config.text
507
+ }, null, 8, _hoisted_9)
508
508
  ]),
509
509
  default: withCtx(() => [
510
- unref(tooltip) ? (openBlock(), createBlock(unref(TMagicTooltip), { key: 0 }, {
510
+ tooltip.value ? (openBlock(), createBlock(unref(TMagicTooltip), { key: 0 }, {
511
511
  content: withCtx(() => [
512
- createElementVNode("div", { innerHTML: unref(tooltip) }, null, 8, _hoisted_10$1)
512
+ createElementVNode("div", { innerHTML: tooltip.value }, null, 8, _hoisted_10)
513
513
  ]),
514
514
  default: withCtx(() => [
515
- (openBlock(), createBlock(resolveDynamicComponent(unref(tagName)), {
516
- key: key(__props.config),
517
- size: __props.size,
518
- model: __props.model,
519
- config: __props.config,
520
- name: unref(name),
521
- disabled: unref(disabled),
522
- prop: unref(itemProp),
515
+ (openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
516
+ key: key(_ctx.config),
517
+ size: _ctx.size,
518
+ model: _ctx.model,
519
+ config: _ctx.config,
520
+ name: name.value,
521
+ disabled: disabled.value,
522
+ prop: itemProp.value,
523
523
  onChange: onChangeHandler
524
524
  }, null, 40, ["size", "model", "config", "name", "disabled", "prop"]))
525
525
  ]),
526
526
  _: 1
527
- })) : (openBlock(), createBlock(resolveDynamicComponent(unref(tagName)), {
528
- key: key(__props.config),
529
- size: __props.size,
530
- model: __props.model,
531
- config: __props.config,
532
- name: unref(name),
533
- disabled: unref(disabled),
534
- prop: unref(itemProp),
527
+ })) : (openBlock(), createBlock(resolveDynamicComponent(tagName.value), {
528
+ key: key(_ctx.config),
529
+ size: _ctx.size,
530
+ model: _ctx.model,
531
+ config: _ctx.config,
532
+ name: name.value,
533
+ disabled: disabled.value,
534
+ prop: itemProp.value,
535
535
  onChange: onChangeHandler
536
536
  }, null, 40, ["size", "model", "config", "name", "disabled", "prop"])),
537
- unref(extra) ? (openBlock(), createElementBlock("div", {
537
+ extra.value ? (openBlock(), createElementBlock("div", {
538
538
  key: 2,
539
- innerHTML: unref(extra),
539
+ innerHTML: extra.value,
540
540
  class: "m-form-tip"
541
541
  }, null, 8, _hoisted_11)) : createCommentVNode("", true)
542
542
  ]),
543
543
  _: 1
544
544
  }, 8, ["style", "class", "prop", "label-width", "rules"]),
545
- __props.config.tip ? (openBlock(), createBlock(unref(TMagicTooltip), {
545
+ _ctx.config.tip ? (openBlock(), createBlock(unref(TMagicTooltip), {
546
546
  key: 1,
547
547
  placement: "left"
548
548
  }, {
549
549
  content: withCtx(() => [
550
550
  createElementVNode("div", {
551
- innerHTML: __props.config.tip
551
+ innerHTML: _ctx.config.tip
552
552
  }, null, 8, _hoisted_12)
553
553
  ]),
554
554
  default: withCtx(() => [
@@ -561,26 +561,26 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
561
561
  ]),
562
562
  _: 1
563
563
  })) : createCommentVNode("", true)
564
- ], 64)) : unref(items) && unref(display$1) ? (openBlock(), createElementBlock(Fragment, { key: 4 }, [
565
- (unref(name) || unref(name) === 0 ? __props.model[unref(name)] : __props.model) ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(unref(items), (item) => {
564
+ ], 64)) : items.value && display$1.value ? (openBlock(), createElementBlock(Fragment, { key: 4 }, [
565
+ (name.value || name.value === 0 ? _ctx.model[name.value] : _ctx.model) ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(items.value, (item) => {
566
566
  return openBlock(), createBlock(_component_Container, {
567
567
  key: key(item),
568
- model: unref(name) || unref(name) === 0 ? __props.model[unref(name)] : __props.model,
569
- "last-values": unref(name) || unref(name) === 0 ? __props.lastValues[unref(name)] || {} : __props.lastValues,
570
- "is-compare": __props.isCompare,
568
+ model: name.value || name.value === 0 ? _ctx.model[name.value] : _ctx.model,
569
+ "last-values": name.value || name.value === 0 ? _ctx.lastValues[name.value] || {} : _ctx.lastValues,
570
+ "is-compare": _ctx.isCompare,
571
571
  config: item,
572
- size: __props.size,
573
- disabled: unref(disabled),
574
- "step-active": __props.stepActive,
572
+ size: _ctx.size,
573
+ disabled: disabled.value,
574
+ "step-active": _ctx.stepActive,
575
575
  "expand-more": expand.value,
576
- "label-width": unref(itemLabelWidth),
577
- prop: unref(itemProp),
576
+ "label-width": itemLabelWidth.value,
577
+ prop: itemProp.value,
578
578
  onChange: onChangeHandler,
579
579
  onAddDiffCount
580
580
  }, null, 8, ["model", "last-values", "is-compare", "config", "size", "disabled", "step-active", "expand-more", "label-width", "prop"]);
581
581
  }), 128)) : createCommentVNode("", true)
582
582
  ], 64)) : createCommentVNode("", true),
583
- __props.config.expand && unref(type) !== "fieldset" ? (openBlock(), createElementBlock("div", _hoisted_13, [
583
+ _ctx.config.expand && type.value !== "fieldset" ? (openBlock(), createElementBlock("div", _hoisted_13, [
584
584
  createVNode(unref(TMagicButton), {
585
585
  type: "primary",
586
586
  size: "small",
@@ -600,29 +600,29 @@ const _sfc_main$v = /* @__PURE__ */ defineComponent({
600
600
  });
601
601
 
602
602
  const _hoisted_1$a = ["innerHTML"];
603
- const _hoisted_2$6 = ["innerHTML"];
604
- const _hoisted_3$6 = { key: 1 };
605
- const _hoisted_4$5 = ["innerHTML"];
606
- const _hoisted_5$3 = ["innerHTML"];
607
- const _hoisted_6$2 = {
603
+ const _hoisted_2$5 = ["innerHTML"];
604
+ const _hoisted_3$3 = { key: 1 };
605
+ const _hoisted_4$3 = ["innerHTML"];
606
+ const _hoisted_5$2 = ["innerHTML"];
607
+ const _hoisted_6 = {
608
608
  key: 2,
609
609
  style: { "display": "flex" }
610
610
  };
611
- const _hoisted_7$2 = { style: { "flex": "1" } };
612
- const _hoisted_8$1 = ["src"];
613
- const __default__$u = defineComponent({
614
- name: "MFormFieldset"
615
- });
611
+ const _hoisted_7 = { style: { "flex": "1" } };
612
+ const _hoisted_8 = ["src"];
616
613
  const _sfc_main$u = /* @__PURE__ */ defineComponent({
617
- ...__default__$u,
614
+ ...{
615
+ name: "MFormFieldset"
616
+ },
617
+ __name: "Fieldset",
618
618
  props: {
619
- labelWidth: null,
619
+ labelWidth: {},
620
620
  prop: { default: "" },
621
- size: null,
622
- model: null,
621
+ size: {},
622
+ model: {},
623
623
  lastValues: { default: () => ({}) },
624
624
  isCompare: { type: Boolean, default: false },
625
- config: null,
625
+ config: {},
626
626
  rules: { default: {} },
627
627
  disabled: { type: Boolean }
628
628
  },
@@ -649,61 +649,61 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
649
649
  const key = (item, index) => item[mForm?.keyProp || "__key"] ?? index;
650
650
  const onAddDiffCount = () => emit("addDiffCount");
651
651
  return (_ctx, _cache) => {
652
- return (unref(name) ? __props.model[unref(name)] : __props.model) ? (openBlock(), createElementBlock("fieldset", {
652
+ return (name.value ? _ctx.model[name.value] : _ctx.model) ? (openBlock(), createElementBlock("fieldset", {
653
653
  key: 0,
654
654
  class: "m-fieldset",
655
- style: normalizeStyle(unref(show) ? "padding: 15px 15px 0 5px;" : "border: 0")
655
+ style: normalizeStyle(show.value ? "padding: 15px 15px 0 5px;" : "border: 0")
656
656
  }, [
657
- unref(name) && __props.config.checkbox ? (openBlock(), createBlock(resolveDynamicComponent(!unref(show) ? "div" : "legend"), { key: 0 }, {
657
+ name.value && _ctx.config.checkbox ? (openBlock(), createBlock(resolveDynamicComponent(!show.value ? "div" : "legend"), { key: 0 }, {
658
658
  default: withCtx(() => [
659
659
  createVNode(unref(TMagicCheckbox), {
660
- modelValue: __props.model[unref(name)].value,
660
+ modelValue: _ctx.model[name.value].value,
661
661
  "onUpdate:modelValue": [
662
- _cache[0] || (_cache[0] = ($event) => __props.model[unref(name)].value = $event),
662
+ _cache[0] || (_cache[0] = ($event) => _ctx.model[name.value].value = $event),
663
663
  change
664
664
  ],
665
- prop: `${__props.prop}${__props.prop ? "." : ""}${__props.config.name}.value`,
665
+ prop: `${_ctx.prop}${_ctx.prop ? "." : ""}${_ctx.config.name}.value`,
666
666
  "true-label": 1,
667
667
  "false-label": 0
668
668
  }, {
669
669
  default: withCtx(() => [
670
670
  createElementVNode("span", {
671
- innerHTML: __props.config.legend
671
+ innerHTML: _ctx.config.legend
672
672
  }, null, 8, _hoisted_1$a),
673
- __props.config.extra ? (openBlock(), createElementBlock("span", {
673
+ _ctx.config.extra ? (openBlock(), createElementBlock("span", {
674
674
  key: 0,
675
- innerHTML: __props.config.extra,
675
+ innerHTML: _ctx.config.extra,
676
676
  class: "m-form-tip"
677
- }, null, 8, _hoisted_2$6)) : createCommentVNode("", true)
677
+ }, null, 8, _hoisted_2$5)) : createCommentVNode("", true)
678
678
  ]),
679
679
  _: 1
680
680
  }, 8, ["modelValue", "prop"])
681
681
  ]),
682
682
  _: 1
683
- })) : (openBlock(), createElementBlock("legend", _hoisted_3$6, [
683
+ })) : (openBlock(), createElementBlock("legend", _hoisted_3$3, [
684
684
  createElementVNode("span", {
685
- innerHTML: __props.config.legend
686
- }, null, 8, _hoisted_4$5),
687
- __props.config.extra ? (openBlock(), createElementBlock("span", {
685
+ innerHTML: _ctx.config.legend
686
+ }, null, 8, _hoisted_4$3),
687
+ _ctx.config.extra ? (openBlock(), createElementBlock("span", {
688
688
  key: 0,
689
- innerHTML: __props.config.extra,
689
+ innerHTML: _ctx.config.extra,
690
690
  class: "m-form-tip"
691
- }, null, 8, _hoisted_5$3)) : createCommentVNode("", true)
691
+ }, null, 8, _hoisted_5$2)) : createCommentVNode("", true)
692
692
  ])),
693
- __props.config.schematic && unref(show) ? (openBlock(), createElementBlock("div", _hoisted_6$2, [
694
- createElementVNode("div", _hoisted_7$2, [
695
- (openBlock(true), createElementBlock(Fragment, null, renderList(__props.config.items, (item, index) => {
693
+ _ctx.config.schematic && show.value ? (openBlock(), createElementBlock("div", _hoisted_6, [
694
+ createElementVNode("div", _hoisted_7, [
695
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.config.items, (item, index) => {
696
696
  return openBlock(), createBlock(_sfc_main$v, {
697
697
  key: key(item, index),
698
- model: unref(name) ? __props.model[unref(name)] : __props.model,
699
- lastValues: unref(name) ? __props.lastValues[unref(name)] : __props.lastValues,
700
- "is-compare": __props.isCompare,
701
- rules: unref(name) ? __props.rules[unref(name)] : [],
698
+ model: name.value ? _ctx.model[name.value] : _ctx.model,
699
+ lastValues: name.value ? _ctx.lastValues[name.value] : _ctx.lastValues,
700
+ "is-compare": _ctx.isCompare,
701
+ rules: name.value ? _ctx.rules[name.value] : [],
702
702
  config: item,
703
- prop: __props.prop,
704
- disabled: __props.disabled,
705
- labelWidth: unref(lWidth),
706
- size: __props.size,
703
+ prop: _ctx.prop,
704
+ disabled: _ctx.disabled,
705
+ labelWidth: lWidth.value,
706
+ size: _ctx.size,
707
707
  onChange: change,
708
708
  onAddDiffCount: _cache[1] || (_cache[1] = ($event) => onAddDiffCount())
709
709
  }, null, 8, ["model", "lastValues", "is-compare", "rules", "config", "prop", "disabled", "labelWidth", "size"]);
@@ -711,20 +711,20 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
711
711
  ]),
712
712
  createElementVNode("img", {
713
713
  class: "m-form-schematic",
714
- src: __props.config.schematic
715
- }, null, 8, _hoisted_8$1)
716
- ])) : unref(show) ? (openBlock(true), createElementBlock(Fragment, { key: 3 }, renderList(__props.config.items, (item, index) => {
714
+ src: _ctx.config.schematic
715
+ }, null, 8, _hoisted_8)
716
+ ])) : show.value ? (openBlock(true), createElementBlock(Fragment, { key: 3 }, renderList(_ctx.config.items, (item, index) => {
717
717
  return openBlock(), createBlock(_sfc_main$v, {
718
718
  key: key(item, index),
719
- model: unref(name) ? __props.model[unref(name)] : __props.model,
720
- lastValues: unref(name) ? __props.lastValues[unref(name)] : __props.lastValues,
721
- "is-compare": __props.isCompare,
722
- rules: unref(name) ? __props.rules[unref(name)] : [],
719
+ model: name.value ? _ctx.model[name.value] : _ctx.model,
720
+ lastValues: name.value ? _ctx.lastValues[name.value] : _ctx.lastValues,
721
+ "is-compare": _ctx.isCompare,
722
+ rules: name.value ? _ctx.rules[name.value] : [],
723
723
  config: item,
724
- prop: __props.prop,
725
- labelWidth: unref(lWidth),
726
- size: __props.size,
727
- disabled: __props.disabled,
724
+ prop: _ctx.prop,
725
+ labelWidth: lWidth.value,
726
+ size: _ctx.size,
727
+ disabled: _ctx.disabled,
728
728
  onChange: change,
729
729
  onAddDiffCount: _cache[2] || (_cache[2] = ($event) => onAddDiffCount())
730
730
  }, null, 8, ["model", "lastValues", "is-compare", "rules", "config", "prop", "labelWidth", "size", "disabled"]);
@@ -735,24 +735,22 @@ const _sfc_main$u = /* @__PURE__ */ defineComponent({
735
735
  });
736
736
 
737
737
  const _hoisted_1$9 = { class: "m-fields-group-list-item" };
738
- const _hoisted_2$5 = /* @__PURE__ */ createTextVNode("上移");
739
- const _hoisted_3$5 = /* @__PURE__ */ createTextVNode("下移");
740
- const _hoisted_4$4 = ["innerHTML"];
741
- const __default__$t = defineComponent({
742
- name: "MFormGroupListItem"
743
- });
738
+ const _hoisted_2$4 = ["innerHTML"];
744
739
  const _sfc_main$t = /* @__PURE__ */ defineComponent({
745
- ...__default__$t,
740
+ ...{
741
+ name: "MFormGroupListItem"
742
+ },
743
+ __name: "GroupListItem",
746
744
  props: {
747
- model: null,
748
- lastValues: null,
745
+ model: {},
746
+ lastValues: {},
749
747
  isCompare: { type: Boolean },
750
- groupModel: null,
751
- config: null,
752
- labelWidth: null,
753
- prop: null,
754
- size: null,
755
- index: null,
748
+ groupModel: {},
749
+ config: {},
750
+ labelWidth: {},
751
+ prop: {},
752
+ size: {},
753
+ index: {},
756
754
  disabled: { type: Boolean }
757
755
  },
758
756
  emits: ["swap-item", "remove-item", "change", "addDiffCount"],
@@ -806,12 +804,12 @@ const _sfc_main$t = /* @__PURE__ */ defineComponent({
806
804
  createElementVNode("div", null, [
807
805
  createVNode(unref(TMagicButton), {
808
806
  text: "",
809
- disabled: __props.disabled,
807
+ disabled: _ctx.disabled,
810
808
  icon: expand.value ? unref(CaretBottom) : unref(CaretRight),
811
809
  onClick: expandHandler
812
810
  }, {
813
811
  default: withCtx(() => [
814
- createTextVNode(toDisplayString(unref(title)), 1)
812
+ createTextVNode(toDisplayString(title.value), 1)
815
813
  ]),
816
814
  _: 1
817
815
  }, 8, ["disabled", "icon"]),
@@ -819,20 +817,20 @@ const _sfc_main$t = /* @__PURE__ */ defineComponent({
819
817
  style: { "color": "#f56c6c" },
820
818
  text: "",
821
819
  icon: unref(Delete),
822
- disabled: __props.disabled,
820
+ disabled: _ctx.disabled,
823
821
  onClick: removeHandler
824
822
  }, null, 8, ["icon", "disabled"]), [
825
- [vShow, showDelete(parseInt(String(__props.index)))]
823
+ [vShow, showDelete(parseInt(String(_ctx.index)))]
826
824
  ]),
827
825
  movable() ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
828
826
  withDirectives(createVNode(unref(TMagicButton), {
829
827
  text: "",
830
- disabled: __props.disabled,
828
+ disabled: _ctx.disabled,
831
829
  size: "small",
832
830
  onClick: _cache[0] || (_cache[0] = ($event) => changeOrder(-1))
833
831
  }, {
834
832
  default: withCtx(() => [
835
- _hoisted_2$5,
833
+ createTextVNode("上移"),
836
834
  createVNode(unref(TMagicIcon), null, {
837
835
  default: withCtx(() => [
838
836
  createVNode(unref(CaretTop))
@@ -842,16 +840,16 @@ const _sfc_main$t = /* @__PURE__ */ defineComponent({
842
840
  ]),
843
841
  _: 1
844
842
  }, 8, ["disabled"]), [
845
- [vShow, __props.index !== 0]
843
+ [vShow, _ctx.index !== 0]
846
844
  ]),
847
845
  withDirectives(createVNode(unref(TMagicButton), {
848
- disabled: __props.disabled,
846
+ disabled: _ctx.disabled,
849
847
  text: "",
850
848
  size: "small",
851
849
  onClick: _cache[1] || (_cache[1] = ($event) => changeOrder(1))
852
850
  }, {
853
851
  default: withCtx(() => [
854
- _hoisted_3$5,
852
+ createTextVNode("下移"),
855
853
  createVNode(unref(TMagicIcon), null, {
856
854
  default: withCtx(() => [
857
855
  createVNode(unref(CaretBottom))
@@ -861,25 +859,25 @@ const _sfc_main$t = /* @__PURE__ */ defineComponent({
861
859
  ]),
862
860
  _: 1
863
861
  }, 8, ["disabled"]), [
864
- [vShow, __props.index !== unref(length) - 1]
862
+ [vShow, _ctx.index !== length.value - 1]
865
863
  ])
866
864
  ], 64)) : createCommentVNode("", true),
867
- unref(itemExtra) ? (openBlock(), createElementBlock("span", {
865
+ itemExtra.value ? (openBlock(), createElementBlock("span", {
868
866
  key: 1,
869
- innerHTML: unref(itemExtra),
867
+ innerHTML: itemExtra.value,
870
868
  class: "m-form-tip"
871
- }, null, 8, _hoisted_4$4)) : createCommentVNode("", true)
869
+ }, null, 8, _hoisted_2$4)) : createCommentVNode("", true)
872
870
  ]),
873
871
  expand.value ? (openBlock(), createBlock(_sfc_main$v, {
874
872
  key: 0,
875
- config: unref(rowConfig),
876
- model: __props.model,
877
- lastValues: __props.lastValues,
878
- "is-compare": __props.isCompare,
879
- labelWidth: __props.labelWidth,
880
- prop: `${__props.prop}${__props.prop ? "." : ""}${String(__props.index)}`,
881
- size: __props.size,
882
- disabled: __props.disabled,
873
+ config: rowConfig.value,
874
+ model: _ctx.model,
875
+ lastValues: _ctx.lastValues,
876
+ "is-compare": _ctx.isCompare,
877
+ labelWidth: _ctx.labelWidth,
878
+ prop: `${_ctx.prop}${_ctx.prop ? "." : ""}${String(_ctx.index)}`,
879
+ size: _ctx.size,
880
+ disabled: _ctx.disabled,
883
881
  onChange: changeHandler,
884
882
  onAddDiffCount: _cache[2] || (_cache[2] = ($event) => onAddDiffCount())
885
883
  }, null, 8, ["config", "model", "lastValues", "is-compare", "labelWidth", "prop", "size", "disabled"])) : createCommentVNode("", true)
@@ -889,31 +887,29 @@ const _sfc_main$t = /* @__PURE__ */ defineComponent({
889
887
  });
890
888
 
891
889
  const _hoisted_1$8 = { class: "m-fields-group-list" };
892
- const _hoisted_2$4 = ["innerHTML"];
893
- const _hoisted_3$4 = {
890
+ const _hoisted_2$3 = ["innerHTML"];
891
+ const _hoisted_3$2 = {
894
892
  key: 1,
895
893
  class: "el-table__empty-block"
896
894
  };
897
- const _hoisted_4$3 = /* @__PURE__ */ createElementVNode("span", { class: "el-table__empty-text" }, "暂无数据", -1);
898
- const _hoisted_5$2 = [
899
- _hoisted_4$3
895
+ const _hoisted_4$2 = /* @__PURE__ */ createElementVNode("span", { class: "el-table__empty-text" }, "暂无数据", -1);
896
+ const _hoisted_5$1 = [
897
+ _hoisted_4$2
900
898
  ];
901
- const _hoisted_6$1 = /* @__PURE__ */ createTextVNode("添加组");
902
- const _hoisted_7$1 = /* @__PURE__ */ createTextVNode("切换为表格");
903
- const __default__$s = defineComponent({
904
- name: "MFormGroupList"
905
- });
906
899
  const _sfc_main$s = /* @__PURE__ */ defineComponent({
907
- ...__default__$s,
900
+ ...{
901
+ name: "MFormGroupList"
902
+ },
903
+ __name: "GroupList",
908
904
  props: {
909
- model: null,
910
- lastValues: null,
905
+ model: {},
906
+ lastValues: {},
911
907
  isCompare: { type: Boolean },
912
- config: null,
913
- name: null,
914
- labelWidth: null,
915
- prop: null,
916
- size: null,
908
+ config: {},
909
+ name: {},
910
+ labelWidth: {},
911
+ prop: {},
912
+ size: {},
917
913
  disabled: { type: Boolean }
918
914
  },
919
915
  emits: ["change", "addDiffCount"],
@@ -984,49 +980,49 @@ const _sfc_main$s = /* @__PURE__ */ defineComponent({
984
980
  const getLastValues = (item, index) => item?.[index] || {};
985
981
  return (_ctx, _cache) => {
986
982
  return openBlock(), createElementBlock("div", _hoisted_1$8, [
987
- __props.config.extra ? (openBlock(), createElementBlock("div", {
983
+ _ctx.config.extra ? (openBlock(), createElementBlock("div", {
988
984
  key: 0,
989
- innerHTML: __props.config.extra,
985
+ innerHTML: _ctx.config.extra,
990
986
  style: { "color": "rgba(0, 0, 0, 0.45)" }
991
- }, null, 8, _hoisted_2$4)) : createCommentVNode("", true),
992
- !__props.model[__props.name] || !__props.model[__props.name].length ? (openBlock(), createElementBlock("div", _hoisted_3$4, _hoisted_5$2)) : (openBlock(true), createElementBlock(Fragment, { key: 2 }, renderList(__props.model[__props.name], (item, index) => {
987
+ }, null, 8, _hoisted_2$3)) : createCommentVNode("", true),
988
+ !_ctx.model[_ctx.name] || !_ctx.model[_ctx.name].length ? (openBlock(), createElementBlock("div", _hoisted_3$2, _hoisted_5$1)) : (openBlock(true), createElementBlock(Fragment, { key: 2 }, renderList(_ctx.model[_ctx.name], (item, index) => {
993
989
  return openBlock(), createBlock(_sfc_main$t, {
994
990
  key: index,
995
991
  model: item,
996
- lastValues: getLastValues(__props.lastValues[__props.name], index),
997
- "is-compare": __props.isCompare,
998
- config: __props.config,
999
- prop: __props.prop,
992
+ lastValues: getLastValues(_ctx.lastValues[_ctx.name], index),
993
+ "is-compare": _ctx.isCompare,
994
+ config: _ctx.config,
995
+ prop: _ctx.prop,
1000
996
  index,
1001
- "label-width": __props.labelWidth,
1002
- size: __props.size,
1003
- disabled: __props.disabled,
1004
- "group-model": __props.model[__props.name],
997
+ "label-width": _ctx.labelWidth,
998
+ size: _ctx.size,
999
+ disabled: _ctx.disabled,
1000
+ "group-model": _ctx.model[_ctx.name],
1005
1001
  onRemoveItem: removeHandler,
1006
1002
  onSwapItem: swapHandler,
1007
1003
  onChange: changeHandler,
1008
1004
  onAddDiffCount: _cache[0] || (_cache[0] = ($event) => onAddDiffCount())
1009
1005
  }, null, 8, ["model", "lastValues", "is-compare", "config", "prop", "index", "label-width", "size", "disabled", "group-model"]);
1010
1006
  }), 128)),
1011
- unref(addable) ? (openBlock(), createBlock(unref(TMagicButton), {
1007
+ addable.value ? (openBlock(), createBlock(unref(TMagicButton), {
1012
1008
  key: 3,
1013
1009
  onClick: addHandler,
1014
1010
  size: "small",
1015
- disabled: __props.disabled
1011
+ disabled: _ctx.disabled
1016
1012
  }, {
1017
1013
  default: withCtx(() => [
1018
- _hoisted_6$1
1014
+ createTextVNode("添加组")
1019
1015
  ]),
1020
1016
  _: 1
1021
1017
  }, 8, ["disabled"])) : createCommentVNode("", true),
1022
- __props.config.enableToggleMode ? (openBlock(), createBlock(unref(TMagicButton), {
1018
+ _ctx.config.enableToggleMode ? (openBlock(), createBlock(unref(TMagicButton), {
1023
1019
  key: 4,
1024
1020
  icon: unref(Grid),
1025
1021
  size: "small",
1026
1022
  onClick: toggleMode
1027
1023
  }, {
1028
1024
  default: withCtx(() => [
1029
- _hoisted_7$1
1025
+ createTextVNode("切换为表格")
1030
1026
  ]),
1031
1027
  _: 1
1032
1028
  }, 8, ["icon"])) : createCommentVNode("", true)
@@ -1036,27 +1032,27 @@ const _sfc_main$s = /* @__PURE__ */ defineComponent({
1036
1032
  });
1037
1033
 
1038
1034
  const _hoisted_1$7 = { style: { "width": "100%", "display": "flex", "align-items": "center" } };
1039
- const _hoisted_2$3 = ["innerHTML"];
1040
- const _hoisted_3$3 = {
1035
+ const _hoisted_2$2 = ["innerHTML"];
1036
+ const _hoisted_3$1 = {
1041
1037
  key: 0,
1042
1038
  style: { "display": "flex" }
1043
1039
  };
1044
- const _hoisted_4$2 = { style: { "flex": "1" } };
1045
- const _hoisted_5$1 = ["src"];
1046
- const __default__$r = defineComponent({
1047
- name: "MFormPanel"
1048
- });
1040
+ const _hoisted_4$1 = { style: { "flex": "1" } };
1041
+ const _hoisted_5 = ["src"];
1049
1042
  const _sfc_main$r = /* @__PURE__ */ defineComponent({
1050
- ...__default__$r,
1043
+ ...{
1044
+ name: "MFormPanel"
1045
+ },
1046
+ __name: "Panel",
1051
1047
  props: {
1052
- model: null,
1053
- lastValues: null,
1048
+ model: {},
1049
+ lastValues: {},
1054
1050
  isCompare: { type: Boolean },
1055
- config: null,
1056
- name: null,
1057
- labelWidth: null,
1058
- prop: null,
1059
- size: null,
1051
+ config: {},
1052
+ name: {},
1053
+ labelWidth: {},
1054
+ prop: {},
1055
+ size: {},
1060
1056
  disabled: { type: Boolean }
1061
1057
  },
1062
1058
  emits: ["change", "addDiffCount"],
@@ -1069,7 +1065,7 @@ const _sfc_main$r = /* @__PURE__ */ defineComponent({
1069
1065
  const changeHandler = () => emit("change", props.model);
1070
1066
  const onAddDiffCount = () => emit("addDiffCount");
1071
1067
  return (_ctx, _cache) => {
1072
- return unref(items) && unref(items).length ? (openBlock(), createBlock(unref(TMagicCard), {
1068
+ return items.value && items.value.length ? (openBlock(), createBlock(unref(TMagicCard), {
1073
1069
  key: 0,
1074
1070
  class: "box-card m-form-panel",
1075
1071
  "body-style": { display: expand.value ? "block" : "none" }
@@ -1082,32 +1078,32 @@ const _sfc_main$r = /* @__PURE__ */ defineComponent({
1082
1078
  icon: expand.value ? unref(CaretBottom) : unref(CaretRight),
1083
1079
  onClick: _cache[0] || (_cache[0] = ($event) => expand.value = !expand.value)
1084
1080
  }, null, 8, ["icon"]),
1085
- __props.config && __props.config.extra ? (openBlock(), createElementBlock("span", {
1081
+ _ctx.config && _ctx.config.extra ? (openBlock(), createElementBlock("span", {
1086
1082
  key: 0,
1087
- innerHTML: __props.config.extra,
1083
+ innerHTML: _ctx.config.extra,
1088
1084
  class: "m-form-tip"
1089
- }, null, 8, _hoisted_2$3)) : createCommentVNode("", true),
1085
+ }, null, 8, _hoisted_2$2)) : createCommentVNode("", true),
1090
1086
  renderSlot(_ctx.$slots, "header", {}, () => [
1091
- createTextVNode(toDisplayString(filter(__props.config.title)), 1)
1087
+ createTextVNode(toDisplayString(filter(_ctx.config.title)), 1)
1092
1088
  ])
1093
1089
  ])
1094
1090
  ]),
1095
1091
  default: withCtx(() => [
1096
1092
  createElementVNode("div", null, [
1097
1093
  renderSlot(_ctx.$slots, "default"),
1098
- __props.config.schematic ? (openBlock(), createElementBlock("div", _hoisted_3$3, [
1099
- createElementVNode("div", _hoisted_4$2, [
1100
- (openBlock(true), createElementBlock(Fragment, null, renderList(unref(items), (item, index) => {
1094
+ _ctx.config.schematic ? (openBlock(), createElementBlock("div", _hoisted_3$1, [
1095
+ createElementVNode("div", _hoisted_4$1, [
1096
+ (openBlock(true), createElementBlock(Fragment, null, renderList(items.value, (item, index) => {
1101
1097
  return openBlock(), createBlock(_sfc_main$v, {
1102
1098
  key: item[unref(mForm)?.keyProp || "__key"] ?? index,
1103
1099
  config: item,
1104
- model: __props.name ? __props.model[__props.name] : __props.model,
1105
- lastValues: __props.name ? __props.lastValues[__props.name] : __props.lastValues,
1106
- "is-compare": __props.isCompare,
1107
- prop: __props.prop,
1108
- size: __props.size,
1109
- disabled: __props.disabled,
1110
- "label-width": __props.config.labelWidth || __props.labelWidth,
1100
+ model: _ctx.name ? _ctx.model[_ctx.name] : _ctx.model,
1101
+ lastValues: _ctx.name ? _ctx.lastValues[_ctx.name] : _ctx.lastValues,
1102
+ "is-compare": _ctx.isCompare,
1103
+ prop: _ctx.prop,
1104
+ size: _ctx.size,
1105
+ disabled: _ctx.disabled,
1106
+ "label-width": _ctx.config.labelWidth || _ctx.labelWidth,
1111
1107
  onChange: changeHandler,
1112
1108
  onAddDiffCount: _cache[1] || (_cache[1] = ($event) => onAddDiffCount())
1113
1109
  }, null, 8, ["config", "model", "lastValues", "is-compare", "prop", "size", "disabled", "label-width"]);
@@ -1115,19 +1111,19 @@ const _sfc_main$r = /* @__PURE__ */ defineComponent({
1115
1111
  ]),
1116
1112
  createElementVNode("img", {
1117
1113
  class: "m-form-schematic",
1118
- src: __props.config.schematic
1119
- }, null, 8, _hoisted_5$1)
1120
- ])) : (openBlock(true), createElementBlock(Fragment, { key: 1 }, renderList(unref(items), (item, index) => {
1114
+ src: _ctx.config.schematic
1115
+ }, null, 8, _hoisted_5)
1116
+ ])) : (openBlock(true), createElementBlock(Fragment, { key: 1 }, renderList(items.value, (item, index) => {
1121
1117
  return openBlock(), createBlock(_sfc_main$v, {
1122
1118
  key: item[unref(mForm)?.keyProp || "__key"] ?? index,
1123
1119
  config: item,
1124
- model: __props.name ? __props.model[__props.name] : __props.model,
1125
- lastValues: __props.name ? __props.lastValues[__props.name] : __props.lastValues,
1126
- "is-compare": __props.isCompare,
1127
- prop: __props.prop,
1128
- size: __props.size,
1129
- disabled: __props.disabled,
1130
- "label-width": __props.config.labelWidth || __props.labelWidth,
1120
+ model: _ctx.name ? _ctx.model[_ctx.name] : _ctx.model,
1121
+ lastValues: _ctx.name ? _ctx.lastValues[_ctx.name] : _ctx.lastValues,
1122
+ "is-compare": _ctx.isCompare,
1123
+ prop: _ctx.prop,
1124
+ size: _ctx.size,
1125
+ disabled: _ctx.disabled,
1126
+ "label-width": _ctx.config.labelWidth || _ctx.labelWidth,
1131
1127
  onChange: changeHandler,
1132
1128
  onAddDiffCount: _cache[2] || (_cache[2] = ($event) => onAddDiffCount())
1133
1129
  }, null, 8, ["config", "model", "lastValues", "is-compare", "prop", "size", "disabled", "label-width"]);
@@ -1140,21 +1136,21 @@ const _sfc_main$r = /* @__PURE__ */ defineComponent({
1140
1136
  }
1141
1137
  });
1142
1138
 
1143
- const __default__$q = defineComponent({
1144
- name: "MFormCol"
1145
- });
1146
1139
  const _sfc_main$q = /* @__PURE__ */ defineComponent({
1147
- ...__default__$q,
1140
+ ...{
1141
+ name: "MFormCol"
1142
+ },
1143
+ __name: "Col",
1148
1144
  props: {
1149
- model: null,
1150
- lastValues: null,
1145
+ model: {},
1146
+ lastValues: {},
1151
1147
  isCompare: { type: Boolean },
1152
- config: null,
1153
- labelWidth: null,
1148
+ config: {},
1149
+ labelWidth: {},
1154
1150
  expandMore: { type: Boolean },
1155
- span: null,
1156
- size: null,
1157
- prop: null,
1151
+ span: {},
1152
+ size: {},
1153
+ prop: {},
1158
1154
  disabled: { type: Boolean }
1159
1155
  },
1160
1156
  emits: ["change", "addDiffCount"],
@@ -1165,44 +1161,44 @@ const _sfc_main$q = /* @__PURE__ */ defineComponent({
1165
1161
  const changeHandler = () => emit("change", props.model);
1166
1162
  const onAddDiffCount = () => emit("addDiffCount");
1167
1163
  return (_ctx, _cache) => {
1168
- return withDirectives((openBlock(), createBlock(unref(TMagicCol), { span: __props.span }, {
1164
+ return withDirectives((openBlock(), createBlock(unref(TMagicCol), { span: _ctx.span }, {
1169
1165
  default: withCtx(() => [
1170
1166
  createVNode(_sfc_main$v, {
1171
- model: __props.model,
1172
- lastValues: __props.lastValues,
1173
- "is-compare": __props.isCompare,
1174
- config: __props.config,
1175
- prop: __props.prop,
1176
- "label-width": __props.config.labelWidth || __props.labelWidth,
1177
- "expand-more": __props.expandMore,
1178
- size: __props.size,
1179
- disabled: __props.disabled,
1167
+ model: _ctx.model,
1168
+ lastValues: _ctx.lastValues,
1169
+ "is-compare": _ctx.isCompare,
1170
+ config: _ctx.config,
1171
+ prop: _ctx.prop,
1172
+ "label-width": _ctx.config.labelWidth || _ctx.labelWidth,
1173
+ "expand-more": _ctx.expandMore,
1174
+ size: _ctx.size,
1175
+ disabled: _ctx.disabled,
1180
1176
  onChange: changeHandler,
1181
1177
  onAddDiffCount
1182
1178
  }, null, 8, ["model", "lastValues", "is-compare", "config", "prop", "label-width", "expand-more", "size", "disabled"])
1183
1179
  ]),
1184
1180
  _: 1
1185
1181
  }, 8, ["span"])), [
1186
- [vShow, unref(display$1) && __props.config.type !== "hidden"]
1182
+ [vShow, display$1.value && _ctx.config.type !== "hidden"]
1187
1183
  ]);
1188
1184
  };
1189
1185
  }
1190
1186
  });
1191
1187
 
1192
- const __default__$p = defineComponent({
1193
- name: "MFormRow"
1194
- });
1195
1188
  const _sfc_main$p = /* @__PURE__ */ defineComponent({
1196
- ...__default__$p,
1189
+ ...{
1190
+ name: "MFormRow"
1191
+ },
1192
+ __name: "Row",
1197
1193
  props: {
1198
- model: null,
1199
- lastValues: null,
1194
+ model: {},
1195
+ lastValues: {},
1200
1196
  isCompare: { type: Boolean },
1201
- config: null,
1202
- name: null,
1203
- labelWidth: null,
1204
- prop: null,
1205
- size: null,
1197
+ config: {},
1198
+ name: {},
1199
+ labelWidth: {},
1200
+ prop: {},
1201
+ size: {},
1206
1202
  expandMore: { type: Boolean },
1207
1203
  disabled: { type: Boolean }
1208
1204
  },
@@ -1215,19 +1211,19 @@ const _sfc_main$p = /* @__PURE__ */ defineComponent({
1215
1211
  return (_ctx, _cache) => {
1216
1212
  return openBlock(), createBlock(unref(TMagicRow), { gutter: 10 }, {
1217
1213
  default: withCtx(() => [
1218
- (openBlock(true), createElementBlock(Fragment, null, renderList(__props.config.items, (col, index) => {
1214
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.config.items, (col, index) => {
1219
1215
  return openBlock(), createBlock(_sfc_main$q, {
1220
1216
  key: col[unref(mForm)?.keyProp || "__key"] ?? index,
1221
- span: col.span || __props.config.span || 24 / __props.config.items.length,
1217
+ span: col.span || _ctx.config.span || 24 / _ctx.config.items.length,
1222
1218
  config: col,
1223
- labelWidth: __props.config.labelWidth || __props.labelWidth,
1224
- expandMore: __props.expandMore,
1225
- model: __props.name ? __props.model[__props.name] : __props.model,
1226
- lastValues: __props.name ? __props.lastValues[__props.name] : __props.lastValues,
1227
- "is-compare": __props.isCompare,
1228
- prop: __props.prop,
1229
- size: __props.size,
1230
- disabled: __props.disabled,
1219
+ labelWidth: _ctx.config.labelWidth || _ctx.labelWidth,
1220
+ expandMore: _ctx.expandMore,
1221
+ model: _ctx.name ? _ctx.model[_ctx.name] : _ctx.model,
1222
+ lastValues: _ctx.name ? _ctx.lastValues[_ctx.name] : _ctx.lastValues,
1223
+ "is-compare": _ctx.isCompare,
1224
+ prop: _ctx.prop,
1225
+ size: _ctx.size,
1226
+ disabled: _ctx.disabled,
1231
1227
  onChange: changeHandler,
1232
1228
  onAddDiffCount
1233
1229
  }, null, 8, ["span", "config", "labelWidth", "expandMore", "model", "lastValues", "is-compare", "prop", "size", "disabled"]);
@@ -1239,19 +1235,19 @@ const _sfc_main$p = /* @__PURE__ */ defineComponent({
1239
1235
  }
1240
1236
  });
1241
1237
 
1242
- const __default__$o = defineComponent({
1243
- name: "MFormStep"
1244
- });
1245
1238
  const _sfc_main$o = /* @__PURE__ */ defineComponent({
1246
- ...__default__$o,
1239
+ ...{
1240
+ name: "MFormStep"
1241
+ },
1242
+ __name: "Step",
1247
1243
  props: {
1248
- model: null,
1249
- lastValues: null,
1244
+ model: {},
1245
+ lastValues: {},
1250
1246
  isCompare: { type: Boolean },
1251
- config: null,
1247
+ config: {},
1252
1248
  stepActive: { default: 1 },
1253
- labelWidth: null,
1254
- size: null,
1249
+ labelWidth: {},
1250
+ size: {},
1255
1251
  disabled: { type: Boolean }
1256
1252
  },
1257
1253
  emits: ["change", "addDiffCount"],
@@ -1275,10 +1271,10 @@ const _sfc_main$o = /* @__PURE__ */ defineComponent({
1275
1271
  createVNode(unref(TMagicSteps), {
1276
1272
  active: active.value,
1277
1273
  "align-center": "",
1278
- space: __props.config.space
1274
+ space: _ctx.config.space
1279
1275
  }, {
1280
1276
  default: withCtx(() => [
1281
- (openBlock(true), createElementBlock(Fragment, null, renderList(__props.config.items, (item, index) => {
1277
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.config.items, (item, index) => {
1282
1278
  return openBlock(), createBlock(unref(TMagicStep), {
1283
1279
  key: item.__key,
1284
1280
  title: item.title,
@@ -1289,20 +1285,20 @@ const _sfc_main$o = /* @__PURE__ */ defineComponent({
1289
1285
  ]),
1290
1286
  _: 1
1291
1287
  }, 8, ["active", "space"]),
1292
- (openBlock(true), createElementBlock(Fragment, null, renderList(__props.config.items, (step, index) => {
1288
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.config.items, (step, index) => {
1293
1289
  return openBlock(), createElementBlock(Fragment, null, [
1294
1290
  (openBlock(true), createElementBlock(Fragment, null, renderList(step.items, (item) => {
1295
1291
  return openBlock(), createElementBlock(Fragment, null, [
1296
1292
  item ? withDirectives((openBlock(), createBlock(_sfc_main$v, {
1297
1293
  key: item[unref(mForm)?.keyProp || "__key"],
1298
1294
  config: item,
1299
- model: step.name ? __props.model[step.name] : __props.model,
1300
- lastValues: step.name ? __props.lastValues[step.name] : __props.lastValues,
1301
- "is-compare": __props.isCompare,
1295
+ model: step.name ? _ctx.model[step.name] : _ctx.model,
1296
+ lastValues: step.name ? _ctx.lastValues[step.name] : _ctx.lastValues,
1297
+ "is-compare": _ctx.isCompare,
1302
1298
  prop: `${step.name}`,
1303
- size: __props.size,
1304
- disabled: __props.disabled,
1305
- "label-width": __props.config.labelWidth || __props.labelWidth,
1299
+ size: _ctx.size,
1300
+ disabled: _ctx.disabled,
1301
+ "label-width": _ctx.config.labelWidth || _ctx.labelWidth,
1306
1302
  onChange: changeHandler,
1307
1303
  onAddDiffCount: _cache[0] || (_cache[0] = ($event) => onAddDiffCount())
1308
1304
  }, null, 8, ["config", "model", "lastValues", "is-compare", "prop", "size", "disabled", "label-width"])), [
@@ -1318,42 +1314,36 @@ const _sfc_main$o = /* @__PURE__ */ defineComponent({
1318
1314
  });
1319
1315
 
1320
1316
  const _hoisted_1$6 = ["innerHTML"];
1321
- const _hoisted_2$2 = { class: "el-form-item__content" };
1322
- const _hoisted_3$2 = ["innerHTML"];
1323
- const _hoisted_4$1 = /* @__PURE__ */ createTextVNode("添加");
1324
- const _hoisted_5 = /* @__PURE__ */ createTextVNode("   ");
1325
- const _hoisted_6 = /* @__PURE__ */ createTextVNode("展开配置");
1326
- const _hoisted_7 = /* @__PURE__ */ createTextVNode("导入EXCEL");
1327
- const _hoisted_8 = /* @__PURE__ */ createTextVNode("  ");
1328
- const _hoisted_9 = /* @__PURE__ */ createTextVNode("清空");
1329
- const _hoisted_10 = {
1317
+ const _hoisted_2$1 = { class: "el-form-item__content" };
1318
+ const _hoisted_3 = ["innerHTML"];
1319
+ const _hoisted_4 = {
1330
1320
  key: 1,
1331
1321
  class: "bottom",
1332
1322
  style: { "text-align": "right" }
1333
1323
  };
1334
- const __default__$n = defineComponent({
1335
- name: "MFormTable"
1336
- });
1337
1324
  const _sfc_main$n = /* @__PURE__ */ defineComponent({
1338
- ...__default__$n,
1325
+ ...{
1326
+ name: "MFormTable"
1327
+ },
1328
+ __name: "Table",
1339
1329
  props: {
1340
- model: null,
1330
+ model: {},
1341
1331
  lastValues: { default: () => ({}) },
1342
1332
  isCompare: { type: Boolean, default: false },
1343
- config: null,
1344
- name: null,
1333
+ config: {},
1334
+ name: {},
1345
1335
  prop: { default: "" },
1346
- labelWidth: null,
1336
+ labelWidth: {},
1347
1337
  sort: { type: Boolean },
1348
1338
  disabled: { type: Boolean },
1349
1339
  sortKey: { default: "" },
1350
- text: null,
1351
- size: null,
1340
+ text: {},
1341
+ size: {},
1352
1342
  enableToggleMode: { type: Boolean, default: true },
1353
1343
  showIndex: { type: Boolean, default: true }
1354
1344
  },
1355
1345
  emits: ["change", "select", "addDiffCount"],
1356
- setup(__props, { expose, emit }) {
1346
+ setup(__props, { expose: __expose, emit }) {
1357
1347
  const props = __props;
1358
1348
  let timer = null;
1359
1349
  const mForm = inject("mForm");
@@ -1673,43 +1663,43 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
1673
1663
  return `${prop.value}${prop.value ? "." : ""}${index + 1 + pagecontext.value * pagesize.value - 1}`;
1674
1664
  };
1675
1665
  const onAddDiffCount = () => emit("addDiffCount");
1676
- expose({
1666
+ __expose({
1677
1667
  toggleRowSelection
1678
1668
  });
1679
1669
  return (_ctx, _cache) => {
1680
1670
  return openBlock(), createElementBlock("div", {
1681
1671
  ref_key: "mTable",
1682
1672
  ref: mTable,
1683
- class: normalizeClass(["m-fields-table", { "m-fields-table-item-extra": __props.config.itemExtra }])
1673
+ class: normalizeClass(["m-fields-table", { "m-fields-table-item-extra": _ctx.config.itemExtra }])
1684
1674
  }, [
1685
- __props.config.extra ? (openBlock(), createElementBlock("span", {
1675
+ _ctx.config.extra ? (openBlock(), createElementBlock("span", {
1686
1676
  key: 0,
1687
1677
  style: { "color": "rgba(0, 0, 0, 0.45)" },
1688
- innerHTML: __props.config.extra
1678
+ innerHTML: _ctx.config.extra
1689
1679
  }, null, 8, _hoisted_1$6)) : createCommentVNode("", true),
1690
- createElementVNode("div", _hoisted_2$2, [
1680
+ createElementVNode("div", _hoisted_2$1, [
1691
1681
  createVNode(unref(TMagicTooltip), {
1692
1682
  content: "拖拽可排序",
1693
1683
  placement: "left-start",
1694
- disabled: __props.config.dropSort !== true
1684
+ disabled: _ctx.config.dropSort !== true
1695
1685
  }, {
1696
1686
  default: withCtx(() => [
1697
- __props.model[unref(modelName)] ? (openBlock(), createBlock(unref(TMagicTable), {
1687
+ _ctx.model[modelName.value] ? (openBlock(), createBlock(unref(TMagicTable), {
1698
1688
  ref_key: "tMagicTable",
1699
1689
  ref: tMagicTable,
1700
1690
  style: { "width": "100%" },
1701
- "row-key": __props.config.rowKey || "id",
1702
- data: unref(data),
1703
- lastData: unref(lastData),
1704
- border: __props.config.border,
1705
- "max-height": __props.config.maxHeight,
1691
+ "row-key": _ctx.config.rowKey || "id",
1692
+ data: data.value,
1693
+ lastData: lastData.value,
1694
+ border: _ctx.config.border,
1695
+ "max-height": _ctx.config.maxHeight,
1706
1696
  "default-expand-all": true,
1707
1697
  key: updateKey.value,
1708
1698
  onSelect: selectHandle,
1709
1699
  onSortChange: sortChange
1710
1700
  }, {
1711
1701
  default: withCtx(() => [
1712
- __props.config.itemExtra ? (openBlock(), createBlock(unref(TMagicTableColumn), {
1702
+ _ctx.config.itemExtra ? (openBlock(), createBlock(unref(TMagicTableColumn), {
1713
1703
  key: 0,
1714
1704
  fixed: "left",
1715
1705
  width: "30",
@@ -1717,17 +1707,17 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
1717
1707
  }, {
1718
1708
  default: withCtx((scope) => [
1719
1709
  createElementVNode("span", {
1720
- innerHTML: itemExtra(__props.config.itemExtra, scope.$index),
1710
+ innerHTML: itemExtra(_ctx.config.itemExtra, scope.$index),
1721
1711
  class: "m-form-tip"
1722
- }, null, 8, _hoisted_3$2)
1712
+ }, null, 8, _hoisted_3)
1723
1713
  ]),
1724
1714
  _: 1
1725
1715
  })) : createCommentVNode("", true),
1726
1716
  createVNode(unref(TMagicTableColumn), {
1727
1717
  label: "操作",
1728
- width: __props.config.operateColWidth || 55,
1718
+ width: _ctx.config.operateColWidth || 55,
1729
1719
  align: "center",
1730
- fixed: __props.config.fixed === false ? void 0 : "left"
1720
+ fixed: _ctx.config.fixed === false ? void 0 : "left"
1731
1721
  }, {
1732
1722
  default: withCtx((scope) => [
1733
1723
  renderSlot(_ctx.$slots, "operateCol", { scope }),
@@ -1745,7 +1735,7 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
1745
1735
  ]),
1746
1736
  _: 3
1747
1737
  }, 8, ["width", "fixed"]),
1748
- __props.sort && __props.model[unref(modelName)] && __props.model[unref(modelName)].length > 1 ? (openBlock(), createBlock(unref(TMagicTableColumn), {
1738
+ _ctx.sort && _ctx.model[modelName.value] && _ctx.model[modelName.value].length > 1 ? (openBlock(), createBlock(unref(TMagicTableColumn), {
1749
1739
  key: 1,
1750
1740
  label: "排序",
1751
1741
  width: "60"
@@ -1762,7 +1752,7 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
1762
1752
  size: "small",
1763
1753
  type: "primary",
1764
1754
  icon: unref(ArrowUp),
1765
- disabled: __props.disabled,
1755
+ disabled: _ctx.disabled,
1766
1756
  text: "",
1767
1757
  onClick: ($event) => upHandler(scope.$index + 1 + pagecontext.value * pagesize.value - 1),
1768
1758
  onDblclick: ($event) => topHandler(scope.$index + 1 + pagecontext.value * pagesize.value - 1)
@@ -1770,7 +1760,7 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
1770
1760
  ]),
1771
1761
  _: 2
1772
1762
  }, 1024)) : createCommentVNode("", true),
1773
- scope.$index + 1 + pagecontext.value * pagesize.value - 1 !== __props.model[unref(modelName)].length - 1 ? (openBlock(), createBlock(unref(TMagicTooltip), {
1763
+ scope.$index + 1 + pagecontext.value * pagesize.value - 1 !== _ctx.model[modelName.value].length - 1 ? (openBlock(), createBlock(unref(TMagicTooltip), {
1774
1764
  key: 1,
1775
1765
  content: "点击下移,双击置底",
1776
1766
  placement: "top"
@@ -1781,7 +1771,7 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
1781
1771
  size: "small",
1782
1772
  type: "primary",
1783
1773
  icon: unref(ArrowDown),
1784
- disabled: __props.disabled,
1774
+ disabled: _ctx.disabled,
1785
1775
  text: "",
1786
1776
  onClick: ($event) => downHandler(scope.$index + 1 + pagecontext.value * pagesize.value - 1),
1787
1777
  onDblclick: ($event) => bottomHandler(scope.$index + 1 + pagecontext.value * pagesize.value - 1)
@@ -1792,14 +1782,14 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
1792
1782
  ]),
1793
1783
  _: 1
1794
1784
  })) : createCommentVNode("", true),
1795
- unref(selection) ? (openBlock(), createBlock(unref(TMagicTableColumn), {
1785
+ selection.value ? (openBlock(), createBlock(unref(TMagicTableColumn), {
1796
1786
  key: 2,
1797
1787
  align: "center",
1798
1788
  "header-align": "center",
1799
1789
  type: "selection",
1800
1790
  width: "45"
1801
1791
  })) : createCommentVNode("", true),
1802
- __props.showIndex && __props.config.showIndex ? (openBlock(), createBlock(unref(TMagicTableColumn), {
1792
+ _ctx.showIndex && _ctx.config.showIndex ? (openBlock(), createBlock(unref(TMagicTableColumn), {
1803
1793
  key: 3,
1804
1794
  width: "60",
1805
1795
  label: "序号"
@@ -1809,7 +1799,7 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
1809
1799
  ]),
1810
1800
  _: 1
1811
1801
  })) : createCommentVNode("", true),
1812
- (openBlock(true), createElementBlock(Fragment, null, renderList(__props.config.items, (column, index) => {
1802
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.config.items, (column, index) => {
1813
1803
  return openBlock(), createElementBlock(Fragment, null, [
1814
1804
  column.type !== "hidden" && display$1(column.display) ? (openBlock(), createBlock(unref(TMagicTableColumn), {
1815
1805
  prop: column.name,
@@ -1818,21 +1808,21 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
1818
1808
  sortable: column.sortable,
1819
1809
  "sort-orders": ["ascending", "descending"],
1820
1810
  key: column[unref(mForm)?.keyProp || "__key"] ?? index,
1821
- "class-name": __props.config.dropSort === true ? "el-table__column--dropable" : ""
1811
+ "class-name": _ctx.config.dropSort === true ? "el-table__column--dropable" : ""
1822
1812
  }, {
1823
1813
  default: withCtx((scope) => [
1824
1814
  scope.$index > -1 ? (openBlock(), createBlock(_sfc_main$v, {
1825
1815
  key: 0,
1826
1816
  labelWidth: "0",
1827
- disabled: __props.disabled,
1817
+ disabled: _ctx.disabled,
1828
1818
  prop: getProp(scope.$index),
1829
1819
  rules: column.rules,
1830
1820
  config: makeConfig(column, scope.row),
1831
1821
  model: scope.row,
1832
- lastValues: unref(lastData)[scope.$index],
1833
- "is-compare": __props.isCompare,
1834
- size: __props.size,
1835
- onChange: _cache[0] || (_cache[0] = ($event) => _ctx.$emit("change", __props.model[unref(modelName)])),
1822
+ lastValues: lastData.value[scope.$index],
1823
+ "is-compare": _ctx.isCompare,
1824
+ size: _ctx.size,
1825
+ onChange: _cache[0] || (_cache[0] = ($event) => _ctx.$emit("change", _ctx.model[modelName.value])),
1836
1826
  onAddDiffCount: _cache[1] || (_cache[1] = ($event) => onAddDiffCount())
1837
1827
  }, null, 8, ["disabled", "prop", "rules", "config", "model", "lastValues", "is-compare", "size"])) : createCommentVNode("", true)
1838
1828
  ]),
@@ -1847,21 +1837,21 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
1847
1837
  _: 3
1848
1838
  }, 8, ["disabled"]),
1849
1839
  renderSlot(_ctx.$slots, "default"),
1850
- unref(addable) ? (openBlock(), createBlock(unref(TMagicButton), {
1840
+ addable.value ? (openBlock(), createBlock(unref(TMagicButton), {
1851
1841
  key: 0,
1852
1842
  size: "small",
1853
1843
  type: "primary",
1854
- disabled: __props.disabled,
1844
+ disabled: _ctx.disabled,
1855
1845
  plain: "",
1856
1846
  onClick: _cache[2] || (_cache[2] = ($event) => newHandler())
1857
1847
  }, {
1858
1848
  default: withCtx(() => [
1859
- _hoisted_4$1
1849
+ createTextVNode("添加")
1860
1850
  ]),
1861
1851
  _: 1
1862
1852
  }, 8, ["disabled"])) : createCommentVNode("", true),
1863
- _hoisted_5,
1864
- __props.enableToggleMode && !isFullscreen.value ? (openBlock(), createBlock(unref(TMagicButton), {
1853
+ createTextVNode("   "),
1854
+ _ctx.enableToggleMode && !isFullscreen.value ? (openBlock(), createBlock(unref(TMagicButton), {
1865
1855
  key: 1,
1866
1856
  icon: unref(Grid),
1867
1857
  size: "small",
@@ -1869,11 +1859,11 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
1869
1859
  onClick: toggleMode
1870
1860
  }, {
1871
1861
  default: withCtx(() => [
1872
- _hoisted_6
1862
+ createTextVNode("展开配置")
1873
1863
  ]),
1874
1864
  _: 1
1875
1865
  }, 8, ["icon"])) : createCommentVNode("", true),
1876
- __props.config.enableFullscreen !== false ? (openBlock(), createBlock(unref(TMagicButton), {
1866
+ _ctx.config.enableFullscreen !== false ? (openBlock(), createBlock(unref(TMagicButton), {
1877
1867
  key: 2,
1878
1868
  icon: unref(FullScreen),
1879
1869
  size: "small",
@@ -1885,13 +1875,13 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
1885
1875
  ]),
1886
1876
  _: 1
1887
1877
  }, 8, ["icon"])) : createCommentVNode("", true),
1888
- unref(importable) ? (openBlock(), createBlock(unref(TMagicUpload), {
1878
+ importable.value ? (openBlock(), createBlock(unref(TMagicUpload), {
1889
1879
  key: 3,
1890
1880
  style: { "display": "inline-block" },
1891
1881
  ref_key: "excelBtn",
1892
1882
  ref: excelBtn,
1893
1883
  action: "/noop",
1894
- disabled: __props.disabled,
1884
+ disabled: _ctx.disabled,
1895
1885
  "on-change": excelHandler,
1896
1886
  "auto-upload": false
1897
1887
  }, {
@@ -1899,40 +1889,40 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
1899
1889
  createVNode(unref(TMagicButton), {
1900
1890
  size: "small",
1901
1891
  type: "success",
1902
- disabled: __props.disabled,
1892
+ disabled: _ctx.disabled,
1903
1893
  plain: ""
1904
1894
  }, {
1905
1895
  default: withCtx(() => [
1906
- _hoisted_7
1896
+ createTextVNode("导入EXCEL")
1907
1897
  ]),
1908
1898
  _: 1
1909
1899
  }, 8, ["disabled"])
1910
1900
  ]),
1911
1901
  _: 1
1912
1902
  }, 8, ["disabled"])) : createCommentVNode("", true),
1913
- _hoisted_8,
1914
- unref(importable) ? (openBlock(), createBlock(unref(TMagicButton), {
1903
+ createTextVNode("  "),
1904
+ importable.value ? (openBlock(), createBlock(unref(TMagicButton), {
1915
1905
  key: 4,
1916
1906
  size: "small",
1917
1907
  type: "warning",
1918
- disabled: __props.disabled,
1908
+ disabled: _ctx.disabled,
1919
1909
  plain: "",
1920
1910
  onClick: _cache[3] || (_cache[3] = ($event) => clearHandler())
1921
1911
  }, {
1922
1912
  default: withCtx(() => [
1923
- _hoisted_9
1913
+ createTextVNode("清空")
1924
1914
  ]),
1925
1915
  _: 1
1926
1916
  }, 8, ["disabled"])) : createCommentVNode("", true)
1927
1917
  ]),
1928
- __props.config.pagination ? (openBlock(), createElementBlock("div", _hoisted_10, [
1918
+ _ctx.config.pagination ? (openBlock(), createElementBlock("div", _hoisted_4, [
1929
1919
  createVNode(unref(TMagicPagination), {
1930
1920
  layout: "total, sizes, prev, pager, next, jumper",
1931
- "hide-on-single-page": __props.model[unref(modelName)].length < pagesize.value,
1921
+ "hide-on-single-page": _ctx.model[modelName.value].length < pagesize.value,
1932
1922
  "current-page": pagecontext.value + 1,
1933
1923
  "page-sizes": [pagesize.value, 60, 120, 300],
1934
1924
  "page-size": pagesize.value,
1935
- total: __props.model[unref(modelName)].length,
1925
+ total: _ctx.model[modelName.value].length,
1936
1926
  onSizeChange: handleSizeChange,
1937
1927
  onCurrentChange: handleCurrentChange
1938
1928
  }, null, 8, ["hide-on-single-page", "current-page", "page-sizes", "page-size", "total"])
@@ -1942,28 +1932,28 @@ const _sfc_main$n = /* @__PURE__ */ defineComponent({
1942
1932
  }
1943
1933
  });
1944
1934
 
1945
- const __default__$m = defineComponent({
1946
- name: "MFormTabs"
1947
- });
1948
1935
  const _sfc_main$m = /* @__PURE__ */ defineComponent({
1949
- ...__default__$m,
1936
+ ...{
1937
+ name: "MFormTabs"
1938
+ },
1939
+ __name: "Tabs",
1950
1940
  props: {
1951
- model: null,
1941
+ model: {},
1952
1942
  lastValues: { default: () => ({}) },
1953
1943
  isCompare: { type: Boolean, default: false },
1954
- config: null,
1955
- name: null,
1956
- size: null,
1957
- labelWidth: null,
1958
- prop: null,
1944
+ config: {},
1945
+ name: {},
1946
+ size: {},
1947
+ labelWidth: {},
1948
+ prop: {},
1959
1949
  expandMore: { type: Boolean },
1960
1950
  disabled: { type: Boolean }
1961
1951
  },
1962
1952
  emits: ["change", "addDiffCount"],
1963
1953
  setup(__props, { emit }) {
1964
1954
  const props = __props;
1965
- const tabPaneComponent = getConfig$1("components").tabPane;
1966
- const tabsComponent = getConfig$1("components").tabs;
1955
+ const tabPaneComponent = getConfig$1("components")?.tabPane;
1956
+ const tabsComponent = getConfig$1("components")?.tabs;
1967
1957
  const getActive = (mForm2, props2, activeTabName2) => {
1968
1958
  const { config, model, prop } = props2;
1969
1959
  const { active } = config;
@@ -2059,28 +2049,31 @@ const _sfc_main$m = /* @__PURE__ */ defineComponent({
2059
2049
  emit("addDiffCount");
2060
2050
  };
2061
2051
  return (_ctx, _cache) => {
2062
- return openBlock(), createBlock(resolveDynamicComponent(unref(tabsComponent).component), mergeProps(
2052
+ return openBlock(), createBlock(resolveDynamicComponent(unref(tabsComponent)?.component || "el-tabs"), mergeProps(
2063
2053
  {
2064
2054
  modelValue: activeTabName.value,
2065
2055
  "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => activeTabName.value = $event)
2066
2056
  },
2067
- unref(tabsComponent).props({
2068
- type: __props.config.tabType,
2069
- editable: __props.config.editable || false,
2070
- tabPosition: __props.config.tabPosition || "top"
2071
- }),
2057
+ unref(tabsComponent)?.props({
2058
+ type: _ctx.config.tabType,
2059
+ editable: _ctx.config.editable || false,
2060
+ tabPosition: _ctx.config.tabPosition || "top"
2061
+ }) || {},
2072
2062
  {
2073
- class: `tmagic-design-tabs ${__props.config.dynamic ? "magic-form-dynamic-tab" : "magic-form-tab"}`,
2063
+ class: `tmagic-design-tabs ${_ctx.config.dynamic ? "magic-form-dynamic-tab" : "magic-form-tab"}`,
2074
2064
  onTabClick: tabClickHandler,
2075
2065
  onTabAdd,
2076
2066
  onTabRemove
2077
2067
  }
2078
2068
  ), {
2079
2069
  default: withCtx(() => [
2080
- (openBlock(true), createElementBlock(Fragment, null, renderList(unref(tabs), (tab, tabIndex) => {
2081
- return openBlock(), createBlock(resolveDynamicComponent(unref(tabPaneComponent).component), mergeProps({
2082
- key: tab[unref(mForm)?.keyProp || "__key"] ?? tabIndex
2083
- }, unref(tabPaneComponent).props({ name: filter(tab.status) || tabIndex.toString(), lazy: tab.lazy || false })), {
2070
+ (openBlock(true), createElementBlock(Fragment, null, renderList(tabs.value, (tab, tabIndex) => {
2071
+ return openBlock(), createBlock(resolveDynamicComponent(unref(tabPaneComponent)?.component || "el-tab-pane"), mergeProps(
2072
+ {
2073
+ key: tab[unref(mForm)?.keyProp || "__key"] ?? tabIndex
2074
+ },
2075
+ unref(tabPaneComponent)?.props({ name: filter(tab.status) || tabIndex.toString(), lazy: tab.lazy || false }) || {}
2076
+ ), {
2084
2077
  label: withCtx(() => [
2085
2078
  createElementVNode("span", null, [
2086
2079
  createTextVNode(toDisplayString(filter(tab.title)), 1),
@@ -2096,14 +2089,14 @@ const _sfc_main$m = /* @__PURE__ */ defineComponent({
2096
2089
  return openBlock(), createBlock(_sfc_main$v, {
2097
2090
  key: item[unref(mForm)?.keyProp || "__key"],
2098
2091
  config: item,
2099
- disabled: __props.disabled,
2100
- model: __props.config.dynamic ? (__props.name ? __props.model[__props.name] : __props.model)[tabIndex] : tab.name ? (__props.name ? __props.model[__props.name] : __props.model)[tab.name] : __props.name ? __props.model[__props.name] : __props.model,
2101
- "last-values": unref(isEmpty)(__props.lastValues) ? {} : __props.config.dynamic ? (__props.name ? __props.lastValues[__props.name] : __props.lastValues)[tabIndex] : tab.name ? (__props.name ? __props.lastValues[__props.name] : __props.lastValues)[tab.name] : __props.name ? __props.lastValues[__props.name] : __props.lastValues,
2102
- "is-compare": __props.isCompare,
2103
- prop: __props.config.dynamic ? `${__props.prop}${__props.prop ? "." : ""}${String(tabIndex)}` : __props.prop,
2104
- size: __props.size,
2105
- "label-width": tab.labelWidth || __props.labelWidth,
2106
- "expand-more": __props.expandMore,
2092
+ disabled: _ctx.disabled,
2093
+ model: _ctx.config.dynamic ? (_ctx.name ? _ctx.model[_ctx.name] : _ctx.model)[tabIndex] : tab.name ? (_ctx.name ? _ctx.model[_ctx.name] : _ctx.model)[tab.name] : _ctx.name ? _ctx.model[_ctx.name] : _ctx.model,
2094
+ "last-values": unref(isEmpty)(_ctx.lastValues) ? {} : _ctx.config.dynamic ? (_ctx.name ? _ctx.lastValues[_ctx.name] : _ctx.lastValues)[tabIndex] : tab.name ? (_ctx.name ? _ctx.lastValues[_ctx.name] : _ctx.lastValues)[tab.name] : _ctx.name ? _ctx.lastValues[_ctx.name] : _ctx.lastValues,
2095
+ "is-compare": _ctx.isCompare,
2096
+ prop: _ctx.config.dynamic ? `${_ctx.prop}${_ctx.prop ? "." : ""}${String(tabIndex)}` : _ctx.prop,
2097
+ size: _ctx.size,
2098
+ "label-width": tab.labelWidth || _ctx.labelWidth,
2099
+ "expand-more": _ctx.expandMore,
2107
2100
  onChange: changeHandler,
2108
2101
  onAddDiffCount: ($event) => onAddDiffCount(tabIndex)
2109
2102
  }, null, 8, ["config", "disabled", "model", "last-values", "is-compare", "prop", "size", "label-width", "expand-more", "onAddDiffCount"]);
@@ -2145,21 +2138,21 @@ const useAddField = (prop) => {
2145
2138
  );
2146
2139
  };
2147
2140
 
2148
- const __default__$l = defineComponent({
2149
- name: "MFormCascader"
2150
- });
2151
2141
  const _sfc_main$l = /* @__PURE__ */ defineComponent({
2152
- ...__default__$l,
2142
+ ...{
2143
+ name: "MFormCascader"
2144
+ },
2145
+ __name: "Cascader",
2153
2146
  props: {
2154
- config: null,
2155
- model: null,
2156
- initValues: null,
2157
- values: null,
2158
- name: null,
2159
- prop: null,
2147
+ config: {},
2148
+ model: {},
2149
+ initValues: {},
2150
+ values: {},
2151
+ name: {},
2152
+ prop: {},
2160
2153
  disabled: { type: Boolean },
2161
- size: null,
2162
- lastValues: null
2154
+ size: {},
2155
+ lastValues: {}
2163
2156
  },
2164
2157
  emits: ["change"],
2165
2158
  setup(__props, { emit }) {
@@ -2215,39 +2208,39 @@ const _sfc_main$l = /* @__PURE__ */ defineComponent({
2215
2208
  };
2216
2209
  return (_ctx, _cache) => {
2217
2210
  return openBlock(), createBlock(unref(TMagicCascader), {
2218
- modelValue: __props.model[__props.name],
2219
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => __props.model[__props.name] = $event),
2211
+ modelValue: _ctx.model[_ctx.name],
2212
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.model[_ctx.name] = $event),
2220
2213
  ref_key: "tMagicCascader",
2221
2214
  ref: tMagicCascader,
2222
2215
  style: { "width": "100%" },
2223
2216
  clearable: "",
2224
2217
  filterable: "",
2225
- size: __props.size,
2226
- placeholder: __props.config.placeholder,
2227
- disabled: __props.disabled,
2218
+ size: _ctx.size,
2219
+ placeholder: _ctx.config.placeholder,
2220
+ disabled: _ctx.disabled,
2228
2221
  options: unref(options),
2229
- props: { multiple: __props.config.multiple },
2222
+ props: { multiple: _ctx.config.multiple },
2230
2223
  onChange: changeHandler
2231
2224
  }, null, 8, ["modelValue", "size", "placeholder", "disabled", "options", "props"]);
2232
2225
  };
2233
2226
  }
2234
2227
  });
2235
2228
 
2236
- const __default__$k = defineComponent({
2237
- name: "MFormCheckbox"
2238
- });
2239
2229
  const _sfc_main$k = /* @__PURE__ */ defineComponent({
2240
- ...__default__$k,
2230
+ ...{
2231
+ name: "MFormCheckbox"
2232
+ },
2233
+ __name: "Checkbox",
2241
2234
  props: {
2242
- config: null,
2243
- model: null,
2244
- initValues: null,
2245
- values: null,
2246
- name: null,
2247
- prop: null,
2235
+ config: {},
2236
+ model: {},
2237
+ initValues: {},
2238
+ values: {},
2239
+ name: {},
2240
+ prop: {},
2248
2241
  disabled: { type: Boolean },
2249
- size: null,
2250
- lastValues: null
2242
+ size: {},
2243
+ lastValues: {}
2251
2244
  },
2252
2245
  emits: ["change"],
2253
2246
  setup(__props, { emit }) {
@@ -2278,16 +2271,16 @@ const _sfc_main$k = /* @__PURE__ */ defineComponent({
2278
2271
  };
2279
2272
  return (_ctx, _cache) => {
2280
2273
  return openBlock(), createBlock(unref(TMagicCheckbox), {
2281
- modelValue: __props.model[__props.name],
2282
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => __props.model[__props.name] = $event),
2283
- size: __props.size,
2284
- trueLabel: unref(activeValue),
2285
- falseLabel: unref(inactiveValue),
2286
- disabled: __props.disabled,
2274
+ modelValue: _ctx.model[_ctx.name],
2275
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.model[_ctx.name] = $event),
2276
+ size: _ctx.size,
2277
+ trueLabel: activeValue.value,
2278
+ falseLabel: inactiveValue.value,
2279
+ disabled: _ctx.disabled,
2287
2280
  onChange: changeHandler
2288
2281
  }, {
2289
2282
  default: withCtx(() => [
2290
- createTextVNode(toDisplayString(__props.config.text), 1)
2283
+ createTextVNode(toDisplayString(_ctx.config.text), 1)
2291
2284
  ]),
2292
2285
  _: 1
2293
2286
  }, 8, ["modelValue", "size", "trueLabel", "falseLabel", "disabled"]);
@@ -2295,21 +2288,21 @@ const _sfc_main$k = /* @__PURE__ */ defineComponent({
2295
2288
  }
2296
2289
  });
2297
2290
 
2298
- const __default__$j = defineComponent({
2299
- name: "MFormCheckGroup"
2300
- });
2301
2291
  const _sfc_main$j = /* @__PURE__ */ defineComponent({
2302
- ...__default__$j,
2292
+ ...{
2293
+ name: "MFormCheckGroup"
2294
+ },
2295
+ __name: "CheckboxGroup",
2303
2296
  props: {
2304
- config: null,
2305
- model: null,
2306
- initValues: null,
2307
- values: null,
2308
- name: null,
2309
- prop: null,
2297
+ config: {},
2298
+ model: {},
2299
+ initValues: {},
2300
+ values: {},
2301
+ name: {},
2302
+ prop: {},
2310
2303
  disabled: { type: Boolean },
2311
- size: null,
2312
- lastValues: null
2304
+ size: {},
2305
+ lastValues: {}
2313
2306
  },
2314
2307
  emits: ["change"],
2315
2308
  setup(__props, { emit }) {
@@ -2331,14 +2324,14 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
2331
2324
  });
2332
2325
  return (_ctx, _cache) => {
2333
2326
  return openBlock(), createBlock(unref(TMagicCheckboxGroup), {
2334
- modelValue: __props.model[__props.name],
2335
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => __props.model[__props.name] = $event),
2336
- size: __props.size,
2337
- disabled: __props.disabled,
2327
+ modelValue: _ctx.model[_ctx.name],
2328
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.model[_ctx.name] = $event),
2329
+ size: _ctx.size,
2330
+ disabled: _ctx.disabled,
2338
2331
  onChange: changeHandler
2339
2332
  }, {
2340
2333
  default: withCtx(() => [
2341
- (openBlock(true), createElementBlock(Fragment, null, renderList(unref(options), (option) => {
2334
+ (openBlock(true), createElementBlock(Fragment, null, renderList(options.value, (option) => {
2342
2335
  return openBlock(), createBlock(unref(TMagicCheckbox), {
2343
2336
  label: option.value,
2344
2337
  value: option.value,
@@ -2358,21 +2351,21 @@ const _sfc_main$j = /* @__PURE__ */ defineComponent({
2358
2351
  }
2359
2352
  });
2360
2353
 
2361
- const __default__$i = defineComponent({
2362
- name: "MFormColorPicker"
2363
- });
2364
2354
  const _sfc_main$i = /* @__PURE__ */ defineComponent({
2365
- ...__default__$i,
2355
+ ...{
2356
+ name: "MFormColorPicker"
2357
+ },
2358
+ __name: "ColorPicker",
2366
2359
  props: {
2367
- config: null,
2368
- model: null,
2369
- initValues: null,
2370
- values: null,
2371
- name: null,
2372
- prop: null,
2360
+ config: {},
2361
+ model: {},
2362
+ initValues: {},
2363
+ values: {},
2364
+ name: {},
2365
+ prop: {},
2373
2366
  disabled: { type: Boolean },
2374
- size: null,
2375
- lastValues: null
2367
+ size: {},
2368
+ lastValues: {}
2376
2369
  },
2377
2370
  emits: ["change"],
2378
2371
  setup(__props, { emit }) {
@@ -2381,10 +2374,10 @@ const _sfc_main$i = /* @__PURE__ */ defineComponent({
2381
2374
  const changeHandler = (value) => emit("change", value);
2382
2375
  return (_ctx, _cache) => {
2383
2376
  return openBlock(), createBlock(unref(TMagicColorPicker), {
2384
- modelValue: __props.model[__props.name],
2385
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => __props.model[__props.name] = $event),
2386
- size: __props.size,
2387
- disabled: __props.disabled,
2377
+ modelValue: _ctx.model[_ctx.name],
2378
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.model[_ctx.name] = $event),
2379
+ size: _ctx.size,
2380
+ disabled: _ctx.disabled,
2388
2381
  showAlpha: true,
2389
2382
  onChange: changeHandler
2390
2383
  }, null, 8, ["modelValue", "size", "disabled"]);
@@ -2392,21 +2385,21 @@ const _sfc_main$i = /* @__PURE__ */ defineComponent({
2392
2385
  }
2393
2386
  });
2394
2387
 
2395
- const __default__$h = defineComponent({
2396
- name: "MFormDate"
2397
- });
2398
2388
  const _sfc_main$h = /* @__PURE__ */ defineComponent({
2399
- ...__default__$h,
2389
+ ...{
2390
+ name: "MFormDate"
2391
+ },
2392
+ __name: "Date",
2400
2393
  props: {
2401
- config: null,
2402
- model: null,
2403
- initValues: null,
2404
- values: null,
2405
- name: null,
2406
- prop: null,
2394
+ config: {},
2395
+ model: {},
2396
+ initValues: {},
2397
+ values: {},
2398
+ name: {},
2399
+ prop: {},
2407
2400
  disabled: { type: Boolean },
2408
- size: null,
2409
- lastValues: null
2401
+ size: {},
2402
+ lastValues: {}
2410
2403
  },
2411
2404
  emits: ["change"],
2412
2405
  setup(__props, { emit }) {
@@ -2418,35 +2411,35 @@ const _sfc_main$h = /* @__PURE__ */ defineComponent({
2418
2411
  };
2419
2412
  return (_ctx, _cache) => {
2420
2413
  return openBlock(), createBlock(unref(TMagicDatePicker), {
2421
- modelValue: __props.model[__props.name],
2422
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => __props.model[__props.name] = $event),
2414
+ modelValue: _ctx.model[_ctx.name],
2415
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.model[_ctx.name] = $event),
2423
2416
  type: "date",
2424
- size: __props.size,
2425
- placeholder: __props.config.placeholder,
2426
- disabled: __props.disabled,
2427
- format: __props.config.format,
2428
- "value-format": __props.config.valueFormat || "YYYY-MM-DD HH:mm:ss",
2417
+ size: _ctx.size,
2418
+ placeholder: _ctx.config.placeholder,
2419
+ disabled: _ctx.disabled,
2420
+ format: _ctx.config.format,
2421
+ "value-format": _ctx.config.valueFormat || "YYYY-MM-DD HH:mm:ss",
2429
2422
  onChange: changeHandler
2430
2423
  }, null, 8, ["modelValue", "size", "placeholder", "disabled", "format", "value-format"]);
2431
2424
  };
2432
2425
  }
2433
2426
  });
2434
2427
 
2435
- const __default__$g = defineComponent({
2436
- name: "MFormDateRange"
2437
- });
2438
2428
  const _sfc_main$g = /* @__PURE__ */ defineComponent({
2439
- ...__default__$g,
2429
+ ...{
2430
+ name: "MFormDateRange"
2431
+ },
2432
+ __name: "Daterange",
2440
2433
  props: {
2441
- config: null,
2442
- model: null,
2443
- initValues: null,
2444
- values: null,
2445
- name: null,
2446
- prop: null,
2434
+ config: {},
2435
+ model: {},
2436
+ initValues: {},
2437
+ values: {},
2438
+ name: {},
2439
+ prop: {},
2447
2440
  disabled: { type: Boolean },
2448
- size: null,
2449
- lastValues: null
2441
+ size: {},
2442
+ lastValues: {}
2450
2443
  },
2451
2444
  emits: ["change"],
2452
2445
  setup(__props, { emit }) {
@@ -2524,31 +2517,31 @@ const _sfc_main$g = /* @__PURE__ */ defineComponent({
2524
2517
  "range-separator": "-",
2525
2518
  "start-placeholder": "开始日期",
2526
2519
  "end-placeholder": "结束日期",
2527
- size: __props.size,
2520
+ size: _ctx.size,
2528
2521
  "unlink-panels": true,
2529
- disabled: __props.disabled,
2530
- "default-time": __props.config.defaultTime,
2522
+ disabled: _ctx.disabled,
2523
+ "default-time": _ctx.config.defaultTime,
2531
2524
  onChange: changeHandler
2532
2525
  }, null, 8, ["modelValue", "size", "disabled", "default-time"]);
2533
2526
  };
2534
2527
  }
2535
2528
  });
2536
2529
 
2537
- const __default__$f = defineComponent({
2538
- name: "MFormDateTime"
2539
- });
2540
2530
  const _sfc_main$f = /* @__PURE__ */ defineComponent({
2541
- ...__default__$f,
2531
+ ...{
2532
+ name: "MFormDateTime"
2533
+ },
2534
+ __name: "DateTime",
2542
2535
  props: {
2543
- config: null,
2544
- model: null,
2545
- initValues: null,
2546
- values: null,
2547
- name: null,
2548
- prop: null,
2536
+ config: {},
2537
+ model: {},
2538
+ initValues: {},
2539
+ values: {},
2540
+ name: {},
2541
+ prop: {},
2549
2542
  disabled: { type: Boolean },
2550
- size: null,
2551
- lastValues: null
2543
+ size: {},
2544
+ lastValues: {}
2552
2545
  },
2553
2546
  emits: ["change"],
2554
2547
  setup(__props, { emit }) {
@@ -2567,16 +2560,16 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent({
2567
2560
  };
2568
2561
  return (_ctx, _cache) => {
2569
2562
  return openBlock(), createBlock(unref(TMagicDatePicker), {
2570
- modelValue: __props.model[__props.name],
2571
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => __props.model[__props.name] = $event),
2563
+ modelValue: _ctx.model[_ctx.name],
2564
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.model[_ctx.name] = $event),
2572
2565
  "popper-class": "magic-datetime-picker-popper",
2573
2566
  type: "datetime",
2574
- size: __props.size,
2575
- placeholder: __props.config.placeholder,
2576
- disabled: __props.disabled,
2577
- format: __props.config.format || "YYYY-MM-DD HH:mm:ss",
2578
- "value-format": __props.config.valueFormat || "YYYY-MM-DD HH:mm:ss",
2579
- "default-time": __props.config.defaultTime,
2567
+ size: _ctx.size,
2568
+ placeholder: _ctx.config.placeholder,
2569
+ disabled: _ctx.disabled,
2570
+ format: _ctx.config.format || "YYYY-MM-DD HH:mm:ss",
2571
+ "value-format": _ctx.config.valueFormat || "YYYY-MM-DD HH:mm:ss",
2572
+ "default-time": _ctx.config.defaultTime,
2580
2573
  onChange: changeHandler
2581
2574
  }, null, 8, ["modelValue", "size", "placeholder", "disabled", "format", "value-format", "default-time"]);
2582
2575
  };
@@ -2584,19 +2577,19 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent({
2584
2577
  });
2585
2578
 
2586
2579
  const _hoisted_1$5 = { key: 0 };
2587
- const __default__$e = defineComponent({
2588
- name: "MFormDisplay"
2589
- });
2590
2580
  const _sfc_main$e = /* @__PURE__ */ defineComponent({
2591
- ...__default__$e,
2581
+ ...{
2582
+ name: "MFormDisplay"
2583
+ },
2584
+ __name: "Display",
2592
2585
  props: {
2593
- config: null,
2594
- model: null,
2595
- initValues: null,
2596
- values: null,
2597
- name: null,
2598
- prop: null,
2599
- lastValues: null
2586
+ config: {},
2587
+ model: {},
2588
+ initValues: {},
2589
+ values: {},
2590
+ name: {},
2591
+ prop: {},
2592
+ lastValues: {}
2600
2593
  },
2601
2594
  setup(__props) {
2602
2595
  const props = __props;
@@ -2605,27 +2598,27 @@ const _sfc_main$e = /* @__PURE__ */ defineComponent({
2605
2598
  }
2606
2599
  useAddField(props.prop);
2607
2600
  return (_ctx, _cache) => {
2608
- return __props.model ? (openBlock(), createElementBlock("span", _hoisted_1$5, toDisplayString(__props.model[__props.name]), 1)) : createCommentVNode("", true);
2601
+ return _ctx.model ? (openBlock(), createElementBlock("span", _hoisted_1$5, toDisplayString(_ctx.model[_ctx.name]), 1)) : createCommentVNode("", true);
2609
2602
  };
2610
2603
  }
2611
2604
  });
2612
2605
 
2613
2606
  const _hoisted_1$4 = { class: "m-fields-dynamic-field" };
2614
- const __default__$d = defineComponent({
2615
- name: "MFormDynamicField"
2616
- });
2617
2607
  const _sfc_main$d = /* @__PURE__ */ defineComponent({
2618
- ...__default__$d,
2608
+ ...{
2609
+ name: "MFormDynamicField"
2610
+ },
2611
+ __name: "DynamicField",
2619
2612
  props: {
2620
- config: null,
2621
- model: null,
2622
- initValues: null,
2623
- values: null,
2624
- name: null,
2625
- prop: null,
2613
+ config: {},
2614
+ model: {},
2615
+ initValues: {},
2616
+ values: {},
2617
+ name: {},
2618
+ prop: {},
2626
2619
  disabled: { type: Boolean },
2627
- size: null,
2628
- lastValues: null
2620
+ size: {},
2621
+ lastValues: {}
2629
2622
  },
2630
2623
  emits: ["change"],
2631
2624
  setup(__props, { emit }) {
@@ -2703,40 +2696,40 @@ const _sfc_main$d = /* @__PURE__ */ defineComponent({
2703
2696
  }
2704
2697
  });
2705
2698
 
2706
- const __default__$c = defineComponent({
2707
- name: "MFormHidden"
2708
- });
2709
2699
  const _sfc_main$c = /* @__PURE__ */ defineComponent({
2710
- ...__default__$c,
2700
+ ...{
2701
+ name: "MFormHidden"
2702
+ },
2703
+ __name: "Hidden",
2711
2704
  props: {
2712
- config: null,
2713
- model: null,
2714
- initValues: null,
2715
- values: null,
2716
- name: null,
2717
- prop: null,
2718
- lastValues: null
2705
+ config: {},
2706
+ model: {},
2707
+ initValues: {},
2708
+ values: {},
2709
+ name: {},
2710
+ prop: {},
2711
+ lastValues: {}
2719
2712
  },
2720
2713
  setup(__props) {
2721
2714
  const props = __props;
2722
2715
  useAddField(props.prop);
2723
2716
  return (_ctx, _cache) => {
2724
- return __props.model ? withDirectives((openBlock(), createElementBlock("input", {
2717
+ return _ctx.model ? withDirectives((openBlock(), createElementBlock("input", {
2725
2718
  key: 0,
2726
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => __props.model[__props.name] = $event),
2719
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.model[_ctx.name] = $event),
2727
2720
  type: "hidden"
2728
2721
  }, null, 512)), [
2729
- [vModelText, __props.model[__props.name]]
2722
+ [vModelText, _ctx.model[_ctx.name]]
2730
2723
  ]) : createCommentVNode("", true);
2731
2724
  };
2732
2725
  }
2733
2726
  });
2734
2727
 
2735
- const __default__$b = defineComponent({
2736
- name: "MForm"
2737
- });
2738
2728
  const _sfc_main$b = /* @__PURE__ */ defineComponent({
2739
- ...__default__$b,
2729
+ ...{
2730
+ name: "MForm"
2731
+ },
2732
+ __name: "Form",
2740
2733
  props: {
2741
2734
  config: { default: () => [] },
2742
2735
  initValues: { default: () => ({}) },
@@ -2747,14 +2740,14 @@ const _sfc_main$b = /* @__PURE__ */ defineComponent({
2747
2740
  disabled: { type: Boolean, default: false },
2748
2741
  height: { default: "auto" },
2749
2742
  stepActive: { default: 1 },
2750
- size: null,
2743
+ size: {},
2751
2744
  inline: { type: Boolean, default: false },
2752
2745
  labelPosition: { default: "right" },
2753
2746
  keyProp: { default: "__key" },
2754
- popperClass: null
2747
+ popperClass: {}
2755
2748
  },
2756
2749
  emits: ["change", "field-input", "field-change"],
2757
- setup(__props, { expose, emit }) {
2750
+ setup(__props, { expose: __expose, emit }) {
2758
2751
  const props = __props;
2759
2752
  const tMagicForm = ref();
2760
2753
  const initialized = ref(false);
@@ -2824,7 +2817,7 @@ const _sfc_main$b = /* @__PURE__ */ defineComponent({
2824
2817
  const changeHandler = () => {
2825
2818
  emit("change", values.value);
2826
2819
  };
2827
- expose({
2820
+ __expose({
2828
2821
  values,
2829
2822
  lastValuesProcessed,
2830
2823
  formState,
@@ -2857,23 +2850,23 @@ const _sfc_main$b = /* @__PURE__ */ defineComponent({
2857
2850
  ref_key: "tMagicForm",
2858
2851
  ref: tMagicForm,
2859
2852
  model: values.value,
2860
- "label-width": __props.labelWidth,
2861
- style: normalizeStyle(`height: ${__props.height}`),
2862
- inline: __props.inline,
2863
- "label-position": __props.labelPosition
2853
+ "label-width": _ctx.labelWidth,
2854
+ style: normalizeStyle(`height: ${_ctx.height}`),
2855
+ inline: _ctx.inline,
2856
+ "label-position": _ctx.labelPosition
2864
2857
  }, {
2865
2858
  default: withCtx(() => [
2866
- initialized.value && Array.isArray(__props.config) ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(__props.config, (item, index) => {
2859
+ initialized.value && Array.isArray(_ctx.config) ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(_ctx.config, (item, index) => {
2867
2860
  return openBlock(), createBlock(_sfc_main$v, {
2868
- disabled: __props.disabled,
2869
- key: item[__props.keyProp] ?? index,
2861
+ disabled: _ctx.disabled,
2862
+ key: item[_ctx.keyProp] ?? index,
2870
2863
  config: item,
2871
2864
  model: values.value,
2872
2865
  "last-values": lastValuesProcessed.value,
2873
- "is-compare": __props.isCompare,
2874
- "label-width": item.labelWidth || __props.labelWidth,
2875
- "step-active": __props.stepActive,
2876
- size: __props.size,
2866
+ "is-compare": _ctx.isCompare,
2867
+ "label-width": item.labelWidth || _ctx.labelWidth,
2868
+ "step-active": _ctx.stepActive,
2869
+ size: _ctx.size,
2877
2870
  onChange: changeHandler
2878
2871
  }, null, 8, ["disabled", "config", "model", "last-values", "is-compare", "label-width", "step-active", "size"]);
2879
2872
  }), 128)) : createCommentVNode("", true)
@@ -2885,29 +2878,26 @@ const _sfc_main$b = /* @__PURE__ */ defineComponent({
2885
2878
  });
2886
2879
 
2887
2880
  const _hoisted_1$3 = { style: { "min-height": "1px" } };
2888
- const _hoisted_2$1 = /* @__PURE__ */ createTextVNode("取 消");
2889
- const _hoisted_3$1 = /* @__PURE__ */ createTextVNode("上一步");
2890
- const _hoisted_4 = /* @__PURE__ */ createTextVNode("下一步");
2891
- const __default__$a = defineComponent({
2892
- name: "MFormDialog"
2893
- });
2894
2881
  const _sfc_main$a = /* @__PURE__ */ defineComponent({
2895
- ...__default__$a,
2882
+ ...{
2883
+ name: "MFormDialog"
2884
+ },
2885
+ __name: "FormDialog",
2896
2886
  props: {
2897
2887
  config: { default: () => [] },
2898
2888
  values: { default: () => ({}) },
2899
- parentValues: null,
2900
- width: null,
2901
- labelWidth: null,
2889
+ parentValues: {},
2890
+ width: {},
2891
+ labelWidth: {},
2902
2892
  fullscreen: { type: Boolean },
2903
2893
  disabled: { type: Boolean },
2904
- title: null,
2905
- zIndex: null,
2906
- size: null,
2894
+ title: {},
2895
+ zIndex: {},
2896
+ size: {},
2907
2897
  confirmText: { default: "确定" }
2908
2898
  },
2909
2899
  emits: ["close", "submit", "error", "change"],
2910
- setup(__props, { expose, emit }) {
2900
+ setup(__props, { expose: __expose, emit }) {
2911
2901
  const props = __props;
2912
2902
  const form = ref();
2913
2903
  const dialogVisible = ref(false);
@@ -2956,7 +2946,7 @@ const _sfc_main$a = /* @__PURE__ */ defineComponent({
2956
2946
  const changeHandler = (value) => {
2957
2947
  emit("change", value);
2958
2948
  };
2959
- expose({
2949
+ __expose({
2960
2950
  form,
2961
2951
  saveFetch,
2962
2952
  dialogVisible,
@@ -2970,10 +2960,10 @@ const _sfc_main$a = /* @__PURE__ */ defineComponent({
2970
2960
  class: "m-form-dialog",
2971
2961
  top: "20px",
2972
2962
  "append-to-body": "",
2973
- title: __props.title,
2974
- width: __props.width,
2975
- zIndex: __props.zIndex,
2976
- fullscreen: __props.fullscreen,
2963
+ title: _ctx.title,
2964
+ width: _ctx.width,
2965
+ zIndex: _ctx.zIndex,
2966
+ fullscreen: _ctx.fullscreen,
2977
2967
  "close-on-click-modal": false,
2978
2968
  onClose: closeHandler
2979
2969
  }, {
@@ -2999,29 +2989,29 @@ const _sfc_main$a = /* @__PURE__ */ defineComponent({
2999
2989
  size: "small"
3000
2990
  }, {
3001
2991
  default: withCtx(() => [
3002
- _hoisted_2$1
2992
+ createTextVNode("取 消")
3003
2993
  ]),
3004
2994
  _: 1
3005
2995
  }),
3006
- unref(hasStep) && stepActive.value > 1 ? (openBlock(), createBlock(unref(TMagicButton), {
2996
+ hasStep.value && stepActive.value > 1 ? (openBlock(), createBlock(unref(TMagicButton), {
3007
2997
  key: 0,
3008
2998
  type: "info",
3009
2999
  size: "small",
3010
3000
  onClick: preStep
3011
3001
  }, {
3012
3002
  default: withCtx(() => [
3013
- _hoisted_3$1
3003
+ createTextVNode("上一步")
3014
3004
  ]),
3015
3005
  _: 1
3016
3006
  })) : createCommentVNode("", true),
3017
- unref(hasStep) && unref(stepCount) > stepActive.value ? (openBlock(), createBlock(unref(TMagicButton), {
3007
+ hasStep.value && stepCount.value > stepActive.value ? (openBlock(), createBlock(unref(TMagicButton), {
3018
3008
  key: 1,
3019
3009
  type: "info",
3020
3010
  size: "small",
3021
3011
  onClick: nextStep
3022
3012
  }, {
3023
3013
  default: withCtx(() => [
3024
- _hoisted_4
3014
+ createTextVNode("下一步")
3025
3015
  ]),
3026
3016
  _: 1
3027
3017
  })) : (openBlock(), createBlock(unref(TMagicButton), {
@@ -3032,7 +3022,7 @@ const _sfc_main$a = /* @__PURE__ */ defineComponent({
3032
3022
  onClick: save
3033
3023
  }, {
3034
3024
  default: withCtx(() => [
3035
- createTextVNode(toDisplayString(__props.confirmText), 1)
3025
+ createTextVNode(toDisplayString(_ctx.confirmText), 1)
3036
3026
  ]),
3037
3027
  _: 1
3038
3028
  }, 8, ["loading"]))
@@ -3055,12 +3045,12 @@ const _sfc_main$a = /* @__PURE__ */ defineComponent({
3055
3045
  "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => stepActive.value = $event),
3056
3046
  ref_key: "form",
3057
3047
  ref: form,
3058
- size: __props.size,
3059
- disabled: __props.disabled,
3060
- config: __props.config,
3061
- "init-values": __props.values,
3062
- "parent-values": __props.parentValues,
3063
- "label-width": __props.labelWidth,
3048
+ size: _ctx.size,
3049
+ disabled: _ctx.disabled,
3050
+ config: _ctx.config,
3051
+ "init-values": _ctx.values,
3052
+ "parent-values": _ctx.parentValues,
3053
+ "label-width": _ctx.labelWidth,
3064
3054
  onChange: changeHandler
3065
3055
  }, null, 8, ["modelValue", "size", "disabled", "config", "init-values", "parent-values", "label-width"]),
3066
3056
  renderSlot(_ctx.$slots, "default")
@@ -3077,22 +3067,21 @@ const _hoisted_2 = {
3077
3067
  key: 2,
3078
3068
  class: "m-fields-link"
3079
3069
  };
3080
- const _hoisted_3 = /* @__PURE__ */ createTextVNode("点击编辑");
3081
- const __default__$9 = defineComponent({
3082
- name: "MFormLink"
3083
- });
3084
3070
  const _sfc_main$9 = /* @__PURE__ */ defineComponent({
3085
- ...__default__$9,
3071
+ ...{
3072
+ name: "MFormLink"
3073
+ },
3074
+ __name: "Link",
3086
3075
  props: {
3087
- config: null,
3088
- model: null,
3089
- initValues: null,
3090
- values: null,
3091
- name: null,
3092
- prop: null,
3076
+ config: {},
3077
+ model: {},
3078
+ initValues: {},
3079
+ values: {},
3080
+ name: {},
3081
+ prop: {},
3093
3082
  disabled: { type: Boolean },
3094
- size: null,
3095
- lastValues: null
3083
+ size: {},
3084
+ lastValues: {}
3096
3085
  },
3097
3086
  emits: ["change"],
3098
3087
  setup(__props, { emit }) {
@@ -3141,34 +3130,34 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
3141
3130
  editor.value && (editor.value.dialogVisible = false);
3142
3131
  };
3143
3132
  return (_ctx, _cache) => {
3144
- return __props.config.href && !__props.disabled ? (openBlock(), createElementBlock("a", {
3133
+ return _ctx.config.href && !_ctx.disabled ? (openBlock(), createElementBlock("a", {
3145
3134
  key: 0,
3146
3135
  target: "_blank",
3147
- href: unref(href),
3148
- style: normalizeStyle(__props.config.css || {})
3149
- }, toDisplayString(unref(displayText)), 13, _hoisted_1$2)) : __props.config.href && __props.disabled ? (openBlock(), createElementBlock("span", {
3136
+ href: href.value,
3137
+ style: normalizeStyle(_ctx.config.css || {})
3138
+ }, toDisplayString(displayText.value), 13, _hoisted_1$2)) : _ctx.config.href && _ctx.disabled ? (openBlock(), createElementBlock("span", {
3150
3139
  key: 1,
3151
- style: normalizeStyle(__props.config.disabledCss || {})
3152
- }, toDisplayString(unref(displayText)), 5)) : (openBlock(), createElementBlock("div", _hoisted_2, [
3140
+ style: normalizeStyle(_ctx.config.disabledCss || {})
3141
+ }, toDisplayString(displayText.value), 5)) : (openBlock(), createElementBlock("div", _hoisted_2, [
3153
3142
  createVNode(unref(TMagicButton), {
3154
3143
  text: true,
3155
3144
  type: "primary",
3156
3145
  onClick: editHandler
3157
3146
  }, {
3158
3147
  default: withCtx(() => [
3159
- _hoisted_3
3148
+ createTextVNode("点击编辑")
3160
3149
  ]),
3161
3150
  _: 1
3162
3151
  }),
3163
3152
  createVNode(_sfc_main$a, {
3164
3153
  ref_key: "editor",
3165
3154
  ref: editor,
3166
- title: __props.config.formTitle || "编辑扩展配置",
3167
- width: __props.config.formWidth,
3155
+ title: _ctx.config.formTitle || "编辑扩展配置",
3156
+ width: _ctx.config.formWidth,
3168
3157
  values: formValue.value,
3169
- config: unref(formConfig),
3170
- parentValues: __props.values,
3171
- fullscreen: __props.config.fullscreen,
3158
+ config: formConfig.value,
3159
+ parentValues: _ctx.values,
3160
+ fullscreen: _ctx.config.fullscreen,
3172
3161
  onSubmit: action
3173
3162
  }, null, 8, ["title", "width", "values", "config", "parentValues", "fullscreen"])
3174
3163
  ]));
@@ -3176,21 +3165,21 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
3176
3165
  }
3177
3166
  });
3178
3167
 
3179
- const __default__$8 = defineComponent({
3180
- name: "MFormNumber"
3181
- });
3182
3168
  const _sfc_main$8 = /* @__PURE__ */ defineComponent({
3183
- ...__default__$8,
3169
+ ...{
3170
+ name: "MFormNumber"
3171
+ },
3172
+ __name: "Number",
3184
3173
  props: {
3185
- config: null,
3186
- model: null,
3187
- initValues: null,
3188
- values: null,
3189
- name: null,
3190
- prop: null,
3174
+ config: {},
3175
+ model: {},
3176
+ initValues: {},
3177
+ values: {},
3178
+ name: {},
3179
+ prop: {},
3191
3180
  disabled: { type: Boolean },
3192
- size: null,
3193
- lastValues: null
3181
+ size: {},
3182
+ lastValues: {}
3194
3183
  },
3195
3184
  emits: ["change", "input"],
3196
3185
  setup(__props, { emit }) {
@@ -3205,18 +3194,18 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
3205
3194
  mForm?.$emit("field-input", props.prop, v);
3206
3195
  };
3207
3196
  return (_ctx, _cache) => {
3208
- return __props.model ? (openBlock(), createBlock(unref(TMagicInputNumber), {
3197
+ return _ctx.model ? (openBlock(), createBlock(unref(TMagicInputNumber), {
3209
3198
  key: 0,
3210
- modelValue: __props.model[__props.name],
3211
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => __props.model[__props.name] = $event),
3199
+ modelValue: _ctx.model[_ctx.name],
3200
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.model[_ctx.name] = $event),
3212
3201
  clearable: "",
3213
3202
  "controls-position": "right",
3214
- size: __props.size,
3215
- max: __props.config.max,
3216
- min: __props.config.min,
3217
- step: __props.config.step,
3218
- placeholder: __props.config.placeholder,
3219
- disabled: __props.disabled,
3203
+ size: _ctx.size,
3204
+ max: _ctx.config.max,
3205
+ min: _ctx.config.min,
3206
+ step: _ctx.config.step,
3207
+ placeholder: _ctx.config.placeholder,
3208
+ disabled: _ctx.disabled,
3220
3209
  onChange: changeHandler,
3221
3210
  onInput: inputHandler
3222
3211
  }, null, 8, ["modelValue", "size", "max", "min", "step", "placeholder", "disabled"])) : createCommentVNode("", true);
@@ -3224,21 +3213,21 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent({
3224
3213
  }
3225
3214
  });
3226
3215
 
3227
- const __default__$7 = defineComponent({
3228
- name: "MFormRadioGroup"
3229
- });
3230
3216
  const _sfc_main$7 = /* @__PURE__ */ defineComponent({
3231
- ...__default__$7,
3217
+ ...{
3218
+ name: "MFormRadioGroup"
3219
+ },
3220
+ __name: "RadioGroup",
3232
3221
  props: {
3233
- config: null,
3234
- model: null,
3235
- initValues: null,
3236
- values: null,
3237
- name: null,
3238
- prop: null,
3222
+ config: {},
3223
+ model: {},
3224
+ initValues: {},
3225
+ values: {},
3226
+ name: {},
3227
+ prop: {},
3239
3228
  disabled: { type: Boolean },
3240
- size: null,
3241
- lastValues: null
3229
+ size: {},
3230
+ lastValues: {}
3242
3231
  },
3243
3232
  emits: ["change"],
3244
3233
  setup(__props, { emit }) {
@@ -3248,16 +3237,16 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
3248
3237
  };
3249
3238
  useAddField(props.prop);
3250
3239
  return (_ctx, _cache) => {
3251
- return __props.model ? (openBlock(), createBlock(unref(TMagicRadioGroup), {
3240
+ return _ctx.model ? (openBlock(), createBlock(unref(TMagicRadioGroup), {
3252
3241
  key: 0,
3253
- modelValue: __props.model[__props.name],
3254
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => __props.model[__props.name] = $event),
3255
- size: __props.size,
3256
- disabled: __props.disabled,
3242
+ modelValue: _ctx.model[_ctx.name],
3243
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.model[_ctx.name] = $event),
3244
+ size: _ctx.size,
3245
+ disabled: _ctx.disabled,
3257
3246
  onChange: changeHandler
3258
3247
  }, {
3259
3248
  default: withCtx(() => [
3260
- (openBlock(true), createElementBlock(Fragment, null, renderList(__props.config.options, (option) => {
3249
+ (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.config.options, (option) => {
3261
3250
  return openBlock(), createBlock(unref(TMagicRadio), {
3262
3251
  label: option.value,
3263
3252
  value: option.value,
@@ -3276,18 +3265,18 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
3276
3265
  }
3277
3266
  });
3278
3267
 
3279
- const __default__$6 = defineComponent({
3280
- name: "MFormSelectOptionGroups"
3281
- });
3282
3268
  const _sfc_main$6 = /* @__PURE__ */ defineComponent({
3283
- ...__default__$6,
3269
+ ...{
3270
+ name: "MFormSelectOptionGroups"
3271
+ },
3272
+ __name: "SelectOptionGroups",
3284
3273
  props: {
3285
- options: null
3274
+ options: {}
3286
3275
  },
3287
3276
  setup(__props) {
3288
- const uiComponent = getConfig$1("components").option;
3277
+ const uiComponent = getConfig$1("components")?.option.component || "el-option";
3289
3278
  return (_ctx, _cache) => {
3290
- return openBlock(true), createElementBlock(Fragment, null, renderList(__props.options, (group, index) => {
3279
+ return openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.options, (group, index) => {
3291
3280
  return openBlock(), createBlock(unref(TMagicOptionGroup), {
3292
3281
  key: index,
3293
3282
  label: group.label,
@@ -3295,7 +3284,7 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
3295
3284
  }, {
3296
3285
  default: withCtx(() => [
3297
3286
  (openBlock(true), createElementBlock(Fragment, null, renderList(group.options, (item, index2) => {
3298
- return openBlock(), createBlock(resolveDynamicComponent(unref(uiComponent).component), {
3287
+ return openBlock(), createBlock(resolveDynamicComponent(unref(uiComponent)), {
3299
3288
  key: index2,
3300
3289
  label: item.label || item.text,
3301
3290
  value: item.value,
@@ -3310,22 +3299,22 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
3310
3299
  }
3311
3300
  });
3312
3301
 
3313
- const __default__$5 = defineComponent({
3314
- name: "MFormSelectOptions"
3315
- });
3316
3302
  const _sfc_main$5 = /* @__PURE__ */ defineComponent({
3317
- ...__default__$5,
3303
+ ...{
3304
+ name: "MFormSelectOptions"
3305
+ },
3306
+ __name: "SelectOptions",
3318
3307
  props: {
3319
- options: null,
3320
- valueKey: null
3308
+ options: {},
3309
+ valueKey: {}
3321
3310
  },
3322
3311
  setup(__props) {
3323
3312
  return (_ctx, _cache) => {
3324
- return openBlock(true), createElementBlock(Fragment, null, renderList(__props.options, (option) => {
3313
+ return openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.options, (option) => {
3325
3314
  return openBlock(), createBlock(unref(TMagicOption), {
3326
3315
  label: option.text,
3327
3316
  value: option.value,
3328
- key: __props.valueKey ? option.value[__props.valueKey] : option.value,
3317
+ key: _ctx.valueKey ? option.value[_ctx.valueKey] : option.value,
3329
3318
  disabled: option.disabled
3330
3319
  }, null, 8, ["label", "value", "disabled"]);
3331
3320
  }), 128);
@@ -3334,21 +3323,21 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
3334
3323
  });
3335
3324
 
3336
3325
  const _hoisted_1$1 = { key: 2 };
3337
- const __default__$4 = defineComponent({
3338
- name: "MFormSelect"
3339
- });
3340
3326
  const _sfc_main$4 = /* @__PURE__ */ defineComponent({
3341
- ...__default__$4,
3327
+ ...{
3328
+ name: "MFormSelect"
3329
+ },
3330
+ __name: "Select",
3342
3331
  props: {
3343
- config: null,
3344
- model: null,
3345
- initValues: null,
3346
- values: null,
3347
- name: null,
3348
- prop: null,
3332
+ config: {},
3333
+ model: {},
3334
+ initValues: {},
3335
+ values: {},
3336
+ name: {},
3337
+ prop: {},
3349
3338
  disabled: { type: Boolean },
3350
- size: null,
3351
- lastValues: null
3339
+ size: {},
3340
+ lastValues: {}
3352
3341
  },
3353
3342
  emits: ["change"],
3354
3343
  setup(__props, { emit }) {
@@ -3440,11 +3429,8 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
3440
3429
  postOptions
3441
3430
  });
3442
3431
  }
3443
- const optionsData = root.split(".").reduce((accumulator, currentValue) => accumulator[currentValue], res);
3444
- const resTotal = globalThis.parseInt(
3445
- totalKey.split(".").reduce((accumulator, currentValue) => accumulator[currentValue], res),
3446
- 10
3447
- );
3432
+ const optionsData = getValueByKeyPath(root, res);
3433
+ const resTotal = globalThis.parseInt(getValueByKeyPath(totalKey, res), 10);
3448
3434
  if (resTotal > 0) {
3449
3435
  total.value = resTotal;
3450
3436
  }
@@ -3544,7 +3530,7 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
3544
3530
  postOptions
3545
3531
  });
3546
3532
  }
3547
- let initData = (initRoot || root).split(".").reduce((accumulator, currentValue) => accumulator[currentValue], res);
3533
+ let initData = getValueByKeyPath(initRoot || root, res);
3548
3534
  if (initData) {
3549
3535
  if (!Array.isArray(initData)) {
3550
3536
  initData = [initData];
@@ -3649,29 +3635,29 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
3649
3635
  const groupOptions = options;
3650
3636
  return (_ctx, _cache) => {
3651
3637
  const _directive_loading = resolveDirective("loading");
3652
- return __props.model ? withDirectives((openBlock(), createBlock(unref(TMagicSelect), {
3638
+ return _ctx.model ? withDirectives((openBlock(), createBlock(unref(TMagicSelect), {
3653
3639
  key: 0,
3654
- modelValue: __props.model[__props.name],
3655
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => __props.model[__props.name] = $event),
3640
+ modelValue: _ctx.model[_ctx.name],
3641
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.model[_ctx.name] = $event),
3656
3642
  class: "m-select",
3657
3643
  ref_key: "tMagicSelect",
3658
3644
  ref: tMagicSelect,
3659
- clearable: typeof __props.config.clearable !== "undefined" ? __props.config.clearable : true,
3660
- filterable: typeof __props.config.filterable !== "undefined" ? __props.config.filterable : true,
3645
+ clearable: typeof _ctx.config.clearable !== "undefined" ? _ctx.config.clearable : true,
3646
+ filterable: typeof _ctx.config.filterable !== "undefined" ? _ctx.config.filterable : true,
3661
3647
  "popper-class": `m-select-popper ${unref(popperClass)}`,
3662
- size: __props.size,
3648
+ size: _ctx.size,
3663
3649
  remote: remote.value,
3664
- placeholder: __props.config.placeholder,
3665
- multiple: __props.config.multiple,
3666
- "value-key": __props.config.valueKey || "value",
3667
- "allow-create": __props.config.allowCreate,
3668
- disabled: __props.disabled,
3669
- "remote-method": __props.config.remote && remoteMethod,
3650
+ placeholder: _ctx.config.placeholder,
3651
+ multiple: _ctx.config.multiple,
3652
+ "value-key": _ctx.config.valueKey || "value",
3653
+ "allow-create": _ctx.config.allowCreate,
3654
+ disabled: _ctx.disabled,
3655
+ "remote-method": _ctx.config.remote && remoteMethod,
3670
3656
  onChange: changeHandler,
3671
3657
  onVisibleChange: visibleHandler
3672
3658
  }, {
3673
3659
  default: withCtx(() => [
3674
- __props.config.group ? (openBlock(), createBlock(_sfc_main$6, {
3660
+ _ctx.config.group ? (openBlock(), createBlock(_sfc_main$6, {
3675
3661
  key: 0,
3676
3662
  options: unref(groupOptions)
3677
3663
  }, null, 8, ["options"])) : (openBlock(), createBlock(_sfc_main$5, {
@@ -3690,21 +3676,21 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
3690
3676
  }
3691
3677
  });
3692
3678
 
3693
- const __default__$3 = defineComponent({
3694
- name: "MFormSwitch"
3695
- });
3696
3679
  const _sfc_main$3 = /* @__PURE__ */ defineComponent({
3697
- ...__default__$3,
3680
+ ...{
3681
+ name: "MFormSwitch"
3682
+ },
3683
+ __name: "Switch",
3698
3684
  props: {
3699
- config: null,
3700
- model: null,
3701
- initValues: null,
3702
- values: null,
3703
- name: null,
3704
- prop: null,
3685
+ config: {},
3686
+ model: {},
3687
+ initValues: {},
3688
+ values: {},
3689
+ name: {},
3690
+ prop: {},
3705
3691
  disabled: { type: Boolean },
3706
- size: null,
3707
- lastValues: null
3692
+ size: {},
3693
+ lastValues: {}
3708
3694
  },
3709
3695
  emits: ["change"],
3710
3696
  setup(__props, { emit }) {
@@ -3735,12 +3721,12 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
3735
3721
  });
3736
3722
  return (_ctx, _cache) => {
3737
3723
  return openBlock(), createBlock(unref(TMagicSwitch), {
3738
- modelValue: __props.model[__props.name],
3739
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => __props.model[__props.name] = $event),
3740
- size: __props.size,
3741
- activeValue: unref(activeValue),
3742
- inactiveValue: unref(inactiveValue),
3743
- disabled: __props.disabled,
3724
+ modelValue: _ctx.model[_ctx.name],
3725
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.model[_ctx.name] = $event),
3726
+ size: _ctx.size,
3727
+ activeValue: activeValue.value,
3728
+ inactiveValue: inactiveValue.value,
3729
+ disabled: _ctx.disabled,
3744
3730
  onChange: changeHandler
3745
3731
  }, null, 8, ["modelValue", "size", "activeValue", "inactiveValue", "disabled"]);
3746
3732
  };
@@ -3748,21 +3734,21 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
3748
3734
  });
3749
3735
 
3750
3736
  const _hoisted_1 = { key: 0 };
3751
- const __default__$2 = defineComponent({
3752
- name: "MFormText"
3753
- });
3754
3737
  const _sfc_main$2 = /* @__PURE__ */ defineComponent({
3755
- ...__default__$2,
3738
+ ...{
3739
+ name: "MFormText"
3740
+ },
3741
+ __name: "Text",
3756
3742
  props: {
3757
- config: null,
3758
- model: null,
3759
- initValues: null,
3760
- values: null,
3761
- name: null,
3762
- prop: null,
3743
+ config: {},
3744
+ model: {},
3745
+ initValues: {},
3746
+ values: {},
3747
+ name: {},
3748
+ prop: {},
3763
3749
  disabled: { type: Boolean },
3764
- size: null,
3765
- lastValues: null
3750
+ size: {},
3751
+ lastValues: {}
3766
3752
  },
3767
3753
  emits: ["change", "input"],
3768
3754
  setup(__props, { emit }) {
@@ -3839,53 +3825,54 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
3839
3825
  };
3840
3826
  return (_ctx, _cache) => {
3841
3827
  return openBlock(), createBlock(unref(TMagicInput), {
3842
- modelValue: __props.model[__props.name],
3843
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => __props.model[__props.name] = $event),
3828
+ modelValue: _ctx.model[_ctx.name],
3829
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.model[_ctx.name] = $event),
3844
3830
  clearable: "",
3845
- size: __props.size,
3846
- placeholder: __props.config.placeholder,
3847
- disabled: __props.disabled,
3831
+ size: _ctx.size,
3832
+ placeholder: _ctx.config.placeholder,
3833
+ disabled: _ctx.disabled,
3848
3834
  onChange: changeHandler,
3849
3835
  onInput: inputHandler,
3850
3836
  onKeyup: _cache[1] || (_cache[1] = ($event) => keyUpHandler($event))
3851
3837
  }, createSlots({ _: 2 }, [
3852
- __props.config.append ? {
3838
+ _ctx.config.append ? {
3853
3839
  name: "append",
3854
3840
  fn: withCtx(() => [
3855
- typeof __props.config.append === "string" ? (openBlock(), createElementBlock("span", _hoisted_1, toDisplayString(__props.config.append), 1)) : createCommentVNode("", true),
3856
- typeof __props.config.append === "object" && __props.config.append.type === "button" ? (openBlock(), createBlock(unref(TMagicButton), {
3841
+ typeof _ctx.config.append === "string" ? (openBlock(), createElementBlock("span", _hoisted_1, toDisplayString(_ctx.config.append), 1)) : createCommentVNode("", true),
3842
+ typeof _ctx.config.append === "object" && _ctx.config.append.type === "button" ? (openBlock(), createBlock(unref(TMagicButton), {
3857
3843
  key: 1,
3858
3844
  style: { "color": "#409eff" },
3859
- size: __props.size,
3845
+ size: _ctx.size,
3860
3846
  onClick: withModifiers(buttonClickHandler, ["prevent"])
3861
3847
  }, {
3862
3848
  default: withCtx(() => [
3863
- createTextVNode(toDisplayString(__props.config.append.text), 1)
3849
+ createTextVNode(toDisplayString(_ctx.config.append.text), 1)
3864
3850
  ]),
3865
3851
  _: 1
3866
3852
  }, 8, ["size", "onClick"])) : createCommentVNode("", true)
3867
- ])
3853
+ ]),
3854
+ key: "0"
3868
3855
  } : void 0
3869
3856
  ]), 1032, ["modelValue", "size", "placeholder", "disabled"]);
3870
3857
  };
3871
3858
  }
3872
3859
  });
3873
3860
 
3874
- const __default__$1 = defineComponent({
3875
- name: "MFormTextarea"
3876
- });
3877
3861
  const _sfc_main$1 = /* @__PURE__ */ defineComponent({
3878
- ...__default__$1,
3862
+ ...{
3863
+ name: "MFormTextarea"
3864
+ },
3865
+ __name: "Textarea",
3879
3866
  props: {
3880
- config: null,
3881
- model: null,
3882
- initValues: null,
3883
- values: null,
3884
- name: null,
3885
- prop: null,
3867
+ config: {},
3868
+ model: {},
3869
+ initValues: {},
3870
+ values: {},
3871
+ name: {},
3872
+ prop: {},
3886
3873
  disabled: { type: Boolean },
3887
- size: null,
3888
- lastValues: null
3874
+ size: {},
3875
+ lastValues: {}
3889
3876
  },
3890
3877
  emits: ["change", "input"],
3891
3878
  setup(__props, { emit }) {
@@ -3901,13 +3888,13 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
3901
3888
  };
3902
3889
  return (_ctx, _cache) => {
3903
3890
  return openBlock(), createBlock(unref(TMagicInput), {
3904
- modelValue: __props.model[__props.name],
3905
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => __props.model[__props.name] = $event),
3891
+ modelValue: _ctx.model[_ctx.name],
3892
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.model[_ctx.name] = $event),
3906
3893
  type: "textarea",
3907
- size: __props.size,
3894
+ size: _ctx.size,
3908
3895
  clearable: "",
3909
- placeholder: __props.config.placeholder,
3910
- disabled: __props.disabled,
3896
+ placeholder: _ctx.config.placeholder,
3897
+ disabled: _ctx.disabled,
3911
3898
  onChange: changeHandler,
3912
3899
  onInput: inputHandler
3913
3900
  }, null, 8, ["modelValue", "size", "placeholder", "disabled"]);
@@ -3915,21 +3902,21 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
3915
3902
  }
3916
3903
  });
3917
3904
 
3918
- const __default__ = defineComponent({
3919
- name: "MFormTime"
3920
- });
3921
3905
  const _sfc_main = /* @__PURE__ */ defineComponent({
3922
- ...__default__,
3906
+ ...{
3907
+ name: "MFormTime"
3908
+ },
3909
+ __name: "Time",
3923
3910
  props: {
3924
- config: null,
3925
- model: null,
3926
- initValues: null,
3927
- values: null,
3928
- name: null,
3929
- prop: null,
3911
+ config: {},
3912
+ model: {},
3913
+ initValues: {},
3914
+ values: {},
3915
+ name: {},
3916
+ prop: {},
3930
3917
  disabled: { type: Boolean },
3931
- size: null,
3932
- lastValues: null
3918
+ size: {},
3919
+ lastValues: {}
3933
3920
  },
3934
3921
  emits: ["change"],
3935
3922
  setup(__props, { emit }) {
@@ -3940,13 +3927,13 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
3940
3927
  };
3941
3928
  return (_ctx, _cache) => {
3942
3929
  return openBlock(), createBlock(unref(TMagicTimePicker), {
3943
- modelValue: __props.model[__props.name],
3944
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => __props.model[__props.name] = $event),
3945
- "value-format": __props.config.valueFormat || "HH:mm:ss",
3946
- format: __props.config.format || "HH:mm:ss",
3947
- size: __props.size,
3948
- placeholder: __props.config.placeholder,
3949
- disabled: __props.disabled,
3930
+ modelValue: _ctx.model[_ctx.name],
3931
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.model[_ctx.name] = $event),
3932
+ "value-format": _ctx.config.valueFormat || "HH:mm:ss",
3933
+ format: _ctx.config.format || "HH:mm:ss",
3934
+ size: _ctx.size,
3935
+ placeholder: _ctx.config.placeholder,
3936
+ disabled: _ctx.disabled,
3950
3937
  onChange: changeHandler
3951
3938
  }, null, 8, ["modelValue", "value-format", "format", "size", "placeholder", "disabled"]);
3952
3939
  };
@@ -3956,41 +3943,40 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
3956
3943
  const index$1 = '';
3957
3944
 
3958
3945
  const defaultInstallOpt = {};
3959
- const install = (app, opt) => {
3960
- const option = Object.assign(defaultInstallOpt, opt);
3961
- app.config.globalProperties.$MAGIC_FORM = option;
3962
- setConfig(option);
3963
- app.component("m-form", _sfc_main$b);
3964
- app.component("m-form-dialog", _sfc_main$a);
3965
- app.component("m-form-container", _sfc_main$v);
3966
- app.component("m-form-fieldset", _sfc_main$u);
3967
- app.component("m-form-group-list", _sfc_main$s);
3968
- app.component("m-form-panel", _sfc_main$r);
3969
- app.component("m-form-row", _sfc_main$p);
3970
- app.component("m-form-step", _sfc_main$o);
3971
- app.component("m-form-table", _sfc_main$n);
3972
- app.component("m-form-tab", _sfc_main$m);
3973
- app.component("m-fields-text", _sfc_main$2);
3974
- app.component("m-fields-number", _sfc_main$8);
3975
- app.component("m-fields-textarea", _sfc_main$1);
3976
- app.component("m-fields-hidden", _sfc_main$c);
3977
- app.component("m-fields-date", _sfc_main$h);
3978
- app.component("m-fields-datetime", _sfc_main$f);
3979
- app.component("m-fields-daterange", _sfc_main$g);
3980
- app.component("m-fields-time", _sfc_main);
3981
- app.component("m-fields-checkbox", _sfc_main$k);
3982
- app.component("m-fields-switch", _sfc_main$3);
3983
- app.component("m-fields-color-picker", _sfc_main$i);
3984
- app.component("m-fields-checkbox-group", _sfc_main$j);
3985
- app.component("m-fields-radio-group", _sfc_main$7);
3986
- app.component("m-fields-display", _sfc_main$e);
3987
- app.component("m-fields-link", _sfc_main$9);
3988
- app.component("m-fields-select", _sfc_main$4);
3989
- app.component("m-fields-cascader", _sfc_main$l);
3990
- app.component("m-fields-dynamic-field", _sfc_main$d);
3991
- };
3992
3946
  const index = {
3993
- install
3947
+ install(app, opt = {}) {
3948
+ const option = Object.assign(defaultInstallOpt, opt);
3949
+ app.config.globalProperties.$MAGIC_FORM = option;
3950
+ setConfig(option);
3951
+ app.component("m-form", _sfc_main$b);
3952
+ app.component("m-form-dialog", _sfc_main$a);
3953
+ app.component("m-form-container", _sfc_main$v);
3954
+ app.component("m-form-fieldset", _sfc_main$u);
3955
+ app.component("m-form-group-list", _sfc_main$s);
3956
+ app.component("m-form-panel", _sfc_main$r);
3957
+ app.component("m-form-row", _sfc_main$p);
3958
+ app.component("m-form-step", _sfc_main$o);
3959
+ app.component("m-form-table", _sfc_main$n);
3960
+ app.component("m-form-tab", _sfc_main$m);
3961
+ app.component("m-fields-text", _sfc_main$2);
3962
+ app.component("m-fields-number", _sfc_main$8);
3963
+ app.component("m-fields-textarea", _sfc_main$1);
3964
+ app.component("m-fields-hidden", _sfc_main$c);
3965
+ app.component("m-fields-date", _sfc_main$h);
3966
+ app.component("m-fields-datetime", _sfc_main$f);
3967
+ app.component("m-fields-daterange", _sfc_main$g);
3968
+ app.component("m-fields-time", _sfc_main);
3969
+ app.component("m-fields-checkbox", _sfc_main$k);
3970
+ app.component("m-fields-switch", _sfc_main$3);
3971
+ app.component("m-fields-color-picker", _sfc_main$i);
3972
+ app.component("m-fields-checkbox-group", _sfc_main$j);
3973
+ app.component("m-fields-radio-group", _sfc_main$7);
3974
+ app.component("m-fields-display", _sfc_main$e);
3975
+ app.component("m-fields-link", _sfc_main$9);
3976
+ app.component("m-fields-select", _sfc_main$4);
3977
+ app.component("m-fields-cascader", _sfc_main$l);
3978
+ app.component("m-fields-dynamic-field", _sfc_main$d);
3979
+ }
3994
3980
  };
3995
3981
 
3996
3982
  export { _sfc_main$l as MCascader, _sfc_main$k as MCheckbox, _sfc_main$j as MCheckboxGroup, _sfc_main$i as MColorPicker, _sfc_main$v as MContainer, _sfc_main$h as MDate, _sfc_main$f as MDateTime, _sfc_main$g as MDaterange, _sfc_main$e as MDisplay, _sfc_main$d as MDynamicField, _sfc_main$u as MFieldset, _sfc_main$b as MForm, _sfc_main$a as MFormDialog, _sfc_main$s as MGroupList, _sfc_main$c as MHidden, _sfc_main$9 as MLink, _sfc_main$8 as MNumber, _sfc_main$r as MPanel, _sfc_main$7 as MRadioGroup, _sfc_main$p as MRow, _sfc_main$4 as MSelect, _sfc_main$3 as MSwitch, _sfc_main$n as MTable, _sfc_main$m as MTabs, _sfc_main$2 as MText, _sfc_main$1 as MTextarea, _sfc_main as MTime, createValues, index as default, display, filterFunction, getRules, initValue, useAddField };