@dt-frames/ui 2.0.2 → 2.0.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 (54) hide show
  1. package/es/components/container/index.d.ts +4 -3
  2. package/es/components/container/index.js +24 -22
  3. package/es/components/container/src/slot-container.d.ts +5 -3
  4. package/es/components/curd/index.js +304 -282
  5. package/es/components/curd/src/components/Curd.d.ts +126 -331
  6. package/es/components/curd/src/props.d.ts +14 -15
  7. package/es/components/drawer/index.d.ts +2 -4
  8. package/es/components/drawer/index.js +64 -63
  9. package/es/components/drawer/src/components/DrawerHeader.d.ts +1 -3
  10. package/es/components/drawer/src/index.d.ts +2 -4
  11. package/es/components/form/index.d.ts +196 -344
  12. package/es/components/form/index.js +140 -139
  13. package/es/components/form/src/components/FormButtons.d.ts +3 -3
  14. package/es/components/form/src/components/FormItem.d.ts +156 -304
  15. package/es/components/form/src/components/formIcon.d.ts +10 -10
  16. package/es/components/form/src/components/formInputUseDialog.d.ts +5 -5
  17. package/es/components/form/src/index.d.ts +186 -334
  18. package/es/components/form/src/props.d.ts +7 -7
  19. package/es/components/form/src/types/form.type.d.ts +1 -1
  20. package/es/components/icons/index.d.ts +496 -2
  21. package/es/components/icons/src/pick-icon.d.ts +5 -5
  22. package/es/components/modal/index.js +87 -86
  23. package/es/components/modal/src/components/Modal.d.ts +108 -215
  24. package/es/components/modal/src/index.d.ts +107 -214
  25. package/es/components/source/index.js +1 -0
  26. package/es/components/table/index.js +357 -788
  27. package/es/components/table/index.less +9 -0
  28. package/es/components/table/src/components/TableAction.d.ts +1 -1
  29. package/es/components/table/src/components/TableHeader.d.ts +109 -216
  30. package/es/components/table/src/components/TableRender.d.ts +13 -9
  31. package/es/components/table/src/components/tableSetting/Download.d.ts +107 -214
  32. package/es/components/table/src/components/tableSetting/DownloadCtrl.d.ts +107 -214
  33. package/es/components/table/src/components/tableSetting/index.d.ts +107 -214
  34. package/es/components/table/src/hooks/useDataSource.d.ts +1 -2
  35. package/es/components/table/src/hooks/usePagination.d.ts +3 -118
  36. package/es/components/table/src/index.d.ts +79 -425
  37. package/es/components/table/src/props.d.ts +11 -70
  38. package/es/components/table/src/types/actions.type.d.ts +1 -2
  39. package/es/components/table/src/types/table.type.d.ts +9 -3
  40. package/es/index.d.ts +1 -1
  41. package/es/index.js +2 -3240
  42. package/es/theme/index.js +406 -393
  43. package/es/theme/src/components/header/components/logo.d.ts +0 -1
  44. package/es/theme/src/components/header/components/notify.d.ts +4 -3
  45. package/es/theme/src/components/header/components/setting-theme.d.ts +2 -1
  46. package/es/theme/src/components/header/components/size.d.ts +5 -5
  47. package/es/theme/src/components/header/components/user-info.d.ts +4 -3
  48. package/es/theme/src/components/header/index.d.ts +13 -12
  49. package/es/theme/src/components/header/multiple-header.d.ts +26 -28
  50. package/es/theme/src/hooks/useMenu.d.ts +1 -1
  51. package/es/theme/src/index.d.ts +27 -28
  52. package/es/theme/src/types/theme.type.d.ts +1 -1
  53. package/package.json +3 -2
  54. package/vite.config.ts +0 -27
@@ -1,7 +1,7 @@
1
- import { toRaw as toRaw$1, unref as unref$1, computed as computed$1, getCurrentInstance as getCurrentInstance$1, reactive as reactive$1, readonly, watchEffect as watchEffect$1, nextTick as nextTick$1, defineComponent as defineComponent$1, openBlock, createBlock, mergeProps, isRef, withCtx, createElementBlock, Fragment, renderList, createTextVNode, toDisplayString, useAttrs as useAttrs$1, createElementVNode, createVNode, normalizeProps, guardReactiveProps, createCommentVNode, isVNode, resolveDirective, normalizeStyle, withDirectives, normalizeClass, withKeys, createSlots, renderSlot, ref as ref$1, inject, onUnmounted as onUnmounted$1, h as h$1, resolveDynamicComponent } from "vue";
1
+ import { toRaw as toRaw$1, unref as unref$1, computed, getCurrentInstance as getCurrentInstance$1, reactive, readonly, watchEffect, nextTick as nextTick$1, defineComponent, useAttrs, openBlock, createBlock, mergeProps, isRef, withCtx, createElementBlock, Fragment, renderList, createTextVNode, toDisplayString, createElementVNode, createVNode, normalizeProps, guardReactiveProps, createCommentVNode, toRefs, isVNode, ref as ref$1, watch, resolveDirective, normalizeStyle, withDirectives, normalizeClass, onMounted as onMounted$1, withKeys, createSlots, renderSlot, onUnmounted, inject, h, provide, onBeforeUnmount, resolveDynamicComponent } from "vue";
2
2
  import { RadioButton, RadioGroup, Button, FormItem as FormItem$1, Col as Col$1, Row, Form as Form$1, Tooltip as Tooltip$1, Spin } from "ant-design-vue/es";
3
3
  import "ant-design-vue/es/form/style";
4
- import { DtCache, CacheKey, deepMerge, Pages, useGo, useRedo, Language, useAppStore, isNumber, useI18n, isString, isFunction, error, useSlots, isArray, isBoolean, isNull, dispatchResize, isObject, isNullAndUnDef, useTimeoutFn, useApp, off, on, windowResizeFn, useMessage } from "@dt-frames/core";
4
+ import { DtCache, CacheKey, deepMerge, Pages, useGo, useRedo, Language, useAppStore, isNumber, useI18n, isString, isFunction, error, useSlots, isArray, isBoolean, isNull, dispatchResize, isObject, isNullAndUnDef, isEmpty, useTimeoutFn, useApp, off, on, windowResizeFn, useMessage } from "@dt-frames/core";
5
5
  import { isEqual, omit, cloneDeep, upperFirst, uniqBy, set } from "lodash-es";
6
6
  import { Input, Select, TreeSelect, Radio, Checkbox, AutoComplete, Cascader, DatePicker, InputNumber, Switch, TimePicker, Slider, Rate, Divider, Col, Tooltip, Form, FormItem, Modal as Modal$1 } from "ant-design-vue";
7
7
  import { defineStore } from "pinia";
@@ -258,39 +258,39 @@ defineStore({
258
258
  });
259
259
  function useMenu() {
260
260
  const { getMenuConf, setThemeConf } = useThemeStore();
261
- const getCollapsedShowTitle = computed$1(() => getMenuConf.collapsedShowTitle);
262
- const getIsSidebarType = computed$1(() => getMenuConf.type === MenuType.SIDE);
263
- const getMenuFixed = computed$1(() => getMenuConf.fixed);
264
- const getShowMenu = computed$1(() => getMenuConf.show);
265
- const getShowSidebar = computed$1(() => {
261
+ const getCollapsedShowTitle = computed(() => getMenuConf.collapsedShowTitle);
262
+ const getIsSidebarType = computed(() => getMenuConf.type === MenuType.SIDE);
263
+ const getMenuFixed = computed(() => getMenuConf.fixed);
264
+ const getShowMenu = computed(() => getMenuConf.show);
265
+ const getShowSidebar = computed(() => {
266
266
  return unref$1(getSplit) || unref$1(getShowMenu) && unref$1(getMenuMode) !== MenuMode.HORIZONTAL;
267
267
  });
268
- const getMenuHidden = computed$1(() => getMenuConf.hidden);
269
- const getMenuTheme = computed$1(() => getMenuConf.theme);
270
- const getTrigger = computed$1(() => getMenuConf.trigger);
271
- const getCanDrag = computed$1(() => getMenuConf.canDrag);
272
- const getIsMixMode = computed$1(() => {
268
+ const getMenuHidden = computed(() => getMenuConf.hidden);
269
+ const getMenuTheme = computed(() => getMenuConf.theme);
270
+ const getTrigger = computed(() => getMenuConf.trigger);
271
+ const getCanDrag = computed(() => getMenuConf.canDrag);
272
+ const getIsMixMode = computed(() => {
273
273
  return unref$1(getMenuMode) === MenuMode.INLINE && unref$1(getMenuType) === MenuType.MIX;
274
274
  });
275
- const getMenuWidth = computed$1(() => unref$1(getIsMixMode) ? Number(getMenuConf.menuWidth) - 40 : getMenuConf.menuWidth);
276
- const getLogoWidth = computed$1(() => getMenuConf.menuWidth);
277
- const getMenuType = computed$1(() => getMenuConf.type);
278
- const getIsTopMenu = computed$1(() => unref$1(getMenuType) === MenuType.TOP_MENU);
279
- const getMenuMode = computed$1(() => getMenuConf.mode);
280
- const getSplit = computed$1(() => getMenuConf.split);
281
- const getCollapsed = computed$1(() => getMenuConf.collapsed);
282
- const getIsHorizontal = computed$1(() => unref$1(getMenuMode) === MenuMode.HORIZONTAL);
275
+ const getMenuWidth = computed(() => unref$1(getIsMixMode) ? Number(getMenuConf.menuWidth) - 40 : getMenuConf.menuWidth);
276
+ const getLogoWidth = computed(() => getMenuConf.menuWidth);
277
+ const getMenuType = computed(() => getMenuConf.type);
278
+ const getIsTopMenu = computed(() => unref$1(getMenuType) === MenuType.TOP_MENU);
279
+ const getMenuMode = computed(() => getMenuConf.mode);
280
+ const getSplit = computed(() => getMenuConf.split);
281
+ const getCollapsed = computed(() => getMenuConf.collapsed);
282
+ const getIsHorizontal = computed(() => unref$1(getMenuMode) === MenuMode.HORIZONTAL);
283
283
  const setThemeStore = (conf = {}) => setThemeConf(conf);
284
284
  const toggleCollapsed = () => setThemeStore({
285
285
  menuOptions: {
286
286
  collapsed: !unref$1(getCollapsed)
287
287
  }
288
288
  });
289
- const getMiniWidthNumber = computed$1(() => getMenuConf.collapsedShowTitle ? 80 : 48);
290
- const getRealWidth = computed$1(() => {
289
+ const getMiniWidthNumber = computed(() => getMenuConf.collapsedShowTitle ? 80 : 48);
290
+ const getRealWidth = computed(() => {
291
291
  return unref$1(getCollapsed) ? unref$1(getMiniWidthNumber) : unref$1(getMenuWidth);
292
292
  });
293
- const getCalcContentWidth = computed$1(() => {
293
+ const getCalcContentWidth = computed(() => {
294
294
  const width = unref$1(getIsTopMenu) || !unref$1(getShowMenu) || unref$1(getSplit) && unref$1(getMenuHidden) ? 0 : unref$1(getRealWidth);
295
295
  return `calc(100% - ${unref$1(width)}px)`;
296
296
  });
@@ -351,29 +351,29 @@ function useHeader() {
351
351
  getIsMixMode
352
352
  } = useMenu();
353
353
  const { getShowMultipleTab } = useMultipleTab();
354
- const getHeaderTheme = computed$1(() => getHeaderConf.theme);
355
- const getFixed = computed$1(() => getHeaderConf.fixed);
356
- const getShowHeaderLogo = computed$1(() => unref$1(getShowLogo) && !unref$1(getIsSidebarType));
357
- const getShowSearch = computed$1(() => getHeaderConf.showSearch);
358
- const getShowHeaderTrigger = computed$1(() => {
354
+ const getHeaderTheme = computed(() => getHeaderConf.theme);
355
+ const getFixed = computed(() => getHeaderConf.fixed);
356
+ const getShowHeaderLogo = computed(() => unref$1(getShowLogo) && !unref$1(getIsSidebarType));
357
+ const getShowSearch = computed(() => getHeaderConf.showSearch);
358
+ const getShowHeaderTrigger = computed(() => {
359
359
  if (unref$1(getMenuType) === MenuType.TOP_MENU || !unref$1(getShowMenu) || unref$1(getMenuHidden)) {
360
360
  return false;
361
361
  }
362
362
  return unref$1(getTrigger);
363
363
  });
364
- const getShowBreadCrumb = computed$1(() => getHeaderConf.showBreadCrumb);
365
- const getShowBread = computed$1(
364
+ const getShowBreadCrumb = computed(() => getHeaderConf.showBreadCrumb);
365
+ const getShowBread = computed(
366
366
  () => unref$1(getMenuMode) !== MenuMode.HORIZONTAL && !unref$1(getSplit) && unref$1(getShowBreadCrumb)
367
367
  );
368
- const getShowTopMenu = computed$1(() => unref$1(getMenuMode) === MenuMode.HORIZONTAL || unref$1(getSplit));
369
- const getShowNotice = computed$1(() => getHeaderConf.showNotice);
370
- const getShowFullScreen = computed$1(() => getHeaderConf.showFullScreen);
371
- const getShowLocale = computed$1(() => getHeaderConf.showLocaleSwitch);
372
- const getShowSettingTheme = computed$1(() => getHeaderConf.showSettingTheme);
373
- const getShowFullHeaderRef = computed$1(() => {
368
+ const getShowTopMenu = computed(() => unref$1(getMenuMode) === MenuMode.HORIZONTAL || unref$1(getSplit));
369
+ const getShowNotice = computed(() => getHeaderConf.showNotice);
370
+ const getShowFullScreen = computed(() => getHeaderConf.showFullScreen);
371
+ const getShowLocale = computed(() => getHeaderConf.showLocaleSwitch);
372
+ const getShowSettingTheme = computed(() => getHeaderConf.showSettingTheme);
373
+ const getShowFullHeaderRef = computed(() => {
374
374
  return !unref$1(getIsSidebarType) && !unref$1(getIsTopMenu);
375
375
  });
376
- const getHeaderHeight = computed$1(() => {
376
+ const getHeaderHeight = computed(() => {
377
377
  let height = 0;
378
378
  height += HEADER_HEIGHT;
379
379
  if (unref$1(getShowMultipleTab) && !unref$1(getSplit)) {
@@ -381,21 +381,21 @@ function useHeader() {
381
381
  }
382
382
  return height;
383
383
  });
384
- const getTabsHeight = computed$1(() => TABS_HEIGHT);
385
- const getShowInsetHeaderRef = computed$1(() => {
384
+ const getTabsHeight = computed(() => TABS_HEIGHT);
385
+ const getShowInsetHeaderRef = computed(() => {
386
386
  return unref$1(getIsSidebarType) || unref$1(getIsTopMenu);
387
387
  });
388
- const getShowBackToTop = computed$1(() => getHeaderConf.showBackToTop);
389
- const getIsZH = computed$1(() => {
388
+ const getShowBackToTop = computed(() => getHeaderConf.showBackToTop);
389
+ const getIsZH = computed(() => {
390
390
  let local = DtCache.getLocal(CacheKey.LOCALE);
391
391
  if (!local)
392
392
  return true;
393
393
  return local === Language.ZH;
394
394
  });
395
- const getUiSize = computed$1(() => getHeaderConf?.size ?? UiSize.SMALL);
396
- const getShowUiSize = computed$1(() => getHeaderConf?.showSize);
397
- const getShowLogo = computed$1(() => getHeaderConf.showLogo);
398
- const getShowLoginOut = computed$1(() => getHeaderConf.showLoginOut);
395
+ const getUiSize = computed(() => getHeaderConf?.size ?? UiSize.SMALL);
396
+ const getShowUiSize = computed(() => getHeaderConf?.showSize);
397
+ const getShowLogo = computed(() => getHeaderConf.showLogo);
398
+ const getShowLoginOut = computed(() => getHeaderConf.showLoginOut);
399
399
  const loginOutClick = getHeaderConf.logoutClick;
400
400
  return {
401
401
  getHeaderTheme,
@@ -426,15 +426,15 @@ function useLabelWidth(schemaItemRef, propsRef) {
426
426
  const { getIsZH } = useHeader();
427
427
  const { appConf } = useAppStore();
428
428
  return computed(() => {
429
- const { labelWidth, enLabelWidth, labelCol = {}, wrapperCol = {} } = unref(schemaItemRef);
429
+ const { labelWidth, enLabelWidth, labelCol = {}, wrapperCol = {} } = unref$1(schemaItemRef);
430
430
  const {
431
431
  labelWidth: gLabelWidth,
432
432
  enLabelWidth: gEnLabelWidth,
433
433
  labelCol: glabelCol = {},
434
434
  wrapperCol: gwrapperCol = {},
435
435
  layout = appConf.ui.form.layout
436
- } = unref(propsRef);
437
- let width = (unref(getIsZH) ? labelWidth ?? gLabelWidth : enLabelWidth ?? gEnLabelWidth) ?? labelWidth ?? gLabelWidth ?? 0;
436
+ } = unref$1(propsRef);
437
+ let width = (unref$1(getIsZH) ? labelWidth ?? gLabelWidth : enLabelWidth ?? gEnLabelWidth) ?? labelWidth ?? gLabelWidth ?? 0;
438
438
  const labelcol = { ...glabelCol, ...labelCol };
439
439
  const wrapcol = { ...gwrapperCol, ...wrapperCol };
440
440
  width = isNumber(width) ? `${width}px` : width;
@@ -492,7 +492,7 @@ const index$2 = "";
492
492
  function useFormValue(props, key = "value", changeEvent = "change", emitData) {
493
493
  const instance = getCurrentInstance$1();
494
494
  const emit = instance?.emit;
495
- const innerState = reactive$1({
495
+ const innerState = reactive({
496
496
  value: props[key]
497
497
  });
498
498
  const defaultState = readonly(innerState);
@@ -502,10 +502,10 @@ function useFormValue(props, key = "value", changeEvent = "change", emitData) {
502
502
  emit?.(changeEvent, val, ...toRaw$1(unref$1(emitData)) || []);
503
503
  });
504
504
  };
505
- watchEffect$1(() => {
505
+ watchEffect(() => {
506
506
  innerState.value = props[key];
507
507
  });
508
- const state = computed$1({
508
+ const state = computed({
509
509
  get() {
510
510
  return innerState.value;
511
511
  },
@@ -520,7 +520,7 @@ function useFormValue(props, key = "value", changeEvent = "change", emitData) {
520
520
  });
521
521
  return [state, setState, defaultState];
522
522
  }
523
- const _sfc_main$c = /* @__PURE__ */ defineComponent$1({
523
+ const _sfc_main$d = /* @__PURE__ */ defineComponent({
524
524
  __name: "radioButton",
525
525
  props: {
526
526
  value: {
@@ -535,7 +535,7 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent$1({
535
535
  const props = __props;
536
536
  const attrs = useAttrs();
537
537
  const [state] = useFormValue(props);
538
- const getOptions = computed$1(() => {
538
+ const getOptions = computed(() => {
539
539
  const { options } = props;
540
540
  if (!options || options?.length === 0)
541
541
  return [];
@@ -571,13 +571,21 @@ const _sfc_main$c = /* @__PURE__ */ defineComponent$1({
571
571
  };
572
572
  }
573
573
  });
574
+ const _export_sfc = (sfc, props) => {
575
+ const target = sfc.__vccOpts || sfc;
576
+ for (const [key, val] of props) {
577
+ target[key] = val;
578
+ }
579
+ return target;
580
+ };
581
+ const RadioButtonGroup = /* @__PURE__ */ _export_sfc(_sfc_main$d, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/form/src/components/radioButton.vue"]]);
574
582
  const _hoisted_1$2 = { class: "input-with-dialog" };
575
- const _sfc_main$b = /* @__PURE__ */ defineComponent$1({
583
+ const _sfc_main$c = /* @__PURE__ */ defineComponent({
576
584
  __name: "formInputUseDialog",
577
585
  setup(__props) {
578
586
  const { t } = useI18n("UI");
579
- const attrs = useAttrs$1();
580
- const bindProps = computed$1(() => {
587
+ const attrs = useAttrs();
588
+ const bindProps = computed(() => {
581
589
  return {
582
590
  ...omit(attrs, [
583
591
  "formValues"
@@ -606,14 +614,15 @@ const _sfc_main$b = /* @__PURE__ */ defineComponent$1({
606
614
  key: 0,
607
615
  class: "i mdi:close-circle",
608
616
  onClick: clearProps
609
- })) : createCommentVNode("", true)
617
+ })) : createCommentVNode("v-if", true)
610
618
  ]);
611
619
  };
612
620
  }
613
621
  });
622
+ const DtFormInputDialog = /* @__PURE__ */ _export_sfc(_sfc_main$c, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/form/src/components/formInputUseDialog.vue"]]);
614
623
  const components = {
615
624
  Input,
616
- InputWithDialog: _sfc_main$b,
625
+ InputWithDialog: DtFormInputDialog,
617
626
  InputTextArea: Input.TextArea,
618
627
  InputSearch: Input.Search,
619
628
  InputGroup: Input.Group,
@@ -622,7 +631,7 @@ const components = {
622
631
  TreeSelect,
623
632
  Radio,
624
633
  RadioGroup: Radio.Group,
625
- RadioButtonGroup: _sfc_main$c,
634
+ RadioButtonGroup,
626
635
  Checkbox,
627
636
  CheckboxGroup: Checkbox.Group,
628
637
  AutoComplete,
@@ -645,7 +654,7 @@ for (let item in components) {
645
654
  function _isSlot$1(s) {
646
655
  return typeof s === "function" || Object.prototype.toString.call(s) === "[object Object]" && !isVNode(s);
647
656
  }
648
- const _sfc_main$a = defineComponent({
657
+ const _sfc_main$b = {
649
658
  name: "FormItem",
650
659
  inheritAttrs: false,
651
660
  props: {
@@ -718,7 +727,7 @@ const _sfc_main$a = defineComponent({
718
727
  return false;
719
728
  }
720
729
  if (isFunction(show)) {
721
- return show(unref(getValues).model);
730
+ return show(unref$1(getValues).model);
722
731
  }
723
732
  return show;
724
733
  });
@@ -730,7 +739,7 @@ const _sfc_main$a = defineComponent({
730
739
  props: cProps = {}
731
740
  } = schema2;
732
741
  if (isFunction(cProps)) {
733
- cProps = cProps(unref(getValues).model) ?? {};
742
+ cProps = cProps(unref$1(getValues).model) ?? {};
734
743
  }
735
744
  if (schema2.component === "Divider") {
736
745
  cProps = Object.assign({
@@ -754,9 +763,9 @@ const _sfc_main$a = defineComponent({
754
763
  const {
755
764
  labelCol,
756
765
  wrapperCol
757
- } = unref(useLabelWidth(schema, formProps));
766
+ } = unref$1(useLabelWidth(schema, formProps));
758
767
  const getContent = () => {
759
- const value = unref(getValues);
768
+ const value = unref$1(getValues);
760
769
  let _con = slot ? getSlot(slots, slot, value.model) : render ? render(value.model) : renderFormItem();
761
770
  return component === "InputGroup" || component === "Icon" ? createVNode(FormItem, {
762
771
  "class": "m-0"
@@ -765,15 +774,15 @@ const _sfc_main$a = defineComponent({
765
774
  }) : _con;
766
775
  };
767
776
  const getSuffix = () => {
768
- return isFunction(suffix) ? suffix(unref(getValues).model) : suffix;
777
+ return isFunction(suffix) ? suffix(unref$1(getValues).model) : suffix;
769
778
  };
770
779
  const getPrefix = () => {
771
- return isFunction(prefix) ? prefix(unref(getValues).model) : prefix;
780
+ return isFunction(prefix) ? prefix(unref$1(getValues).model) : prefix;
772
781
  };
773
782
  return createVNode(Form.Item, {
774
783
  "name": isArray(name) ? name.join("-") : name,
775
784
  "colon": colon,
776
- "class": [unref(getUiSize), {
785
+ "class": [unref$1(getUiSize), {
777
786
  "suffix-item": !!suffix
778
787
  }],
779
788
  "label": renderLabel(),
@@ -802,7 +811,7 @@ const _sfc_main$a = defineComponent({
802
811
  const renderLabel2 = subLabel ? createVNode("span", null, [createTextVNode(" "), label, createTextVNode(" "), createVNode("span", {
803
812
  "class": "text-secondary opacity-50"
804
813
  }, [createTextVNode("("), subLabel, createTextVNode(")")])]) : label;
805
- const _toolTip = isFunction(toolTip) ? toolTip(unref(getValues).model) : toolTip;
814
+ const _toolTip = isFunction(toolTip) ? toolTip(unref$1(getValues).model) : toolTip;
806
815
  const _toolTipProps = {
807
816
  title: renderLabel2,
808
817
  autoAdjustOverflow: true,
@@ -860,19 +869,19 @@ const _sfc_main$a = defineComponent({
860
869
  } = props.schema;
861
870
  const {
862
871
  disabled: itemDisabled = false
863
- } = unref(getComponentProps);
872
+ } = unref$1(getComponentProps);
864
873
  let _disabled = !!gDisabled || itemDisabled;
865
874
  if (isBoolean(disabled))
866
875
  _disabled = disabled;
867
876
  if (isFunction(disabled))
868
- _disabled = disabled(unref(getValues).model);
877
+ _disabled = disabled(unref$1(getValues).model);
869
878
  return _disabled;
870
879
  });
871
880
  const itemProps = {
872
881
  allowClear: _sProps?.allowClear ?? appConf.ui.form.allowClear,
873
- size: unref(getUiSize) === UiSize.MIDDLE ? "default" : unref(getUiSize),
874
- ...unref(getComponentProps),
875
- disabled: unref(getDisable)
882
+ size: unref$1(getUiSize) === UiSize.MIDDLE ? "default" : unref$1(getUiSize),
883
+ ...unref$1(getComponentProps),
884
+ disabled: unref$1(getDisable)
876
885
  };
877
886
  if (component === "Select") {
878
887
  {
@@ -881,15 +890,15 @@ const _sfc_main$a = defineComponent({
881
890
  }
882
891
  }
883
892
  if (!itemProps.disabled && component !== "RangePicker") {
884
- itemProps.placeholder = unref(getComponentProps)?.placeholder || createPlaceholder(component);
893
+ itemProps.placeholder = unref$1(getComponentProps)?.placeholder || createPlaceholder(component);
885
894
  }
886
895
  if (["DatePicker", "MonthPicker", "RangePicker"].includes(component)) {
887
896
  itemProps.defaultValue = props.formModel[name];
888
897
  }
889
898
  itemProps.codeName = name;
890
- itemProps.formValues = unref(getValues);
899
+ itemProps.formValues = unref$1(getValues);
891
900
  if (["Select", "DatePicker", "MonthPicker", "WeekPicker", "RangePicker"].includes(component)) {
892
- itemProps.dropdownClassName += ` ${unref(getUiSize)}`;
901
+ itemProps.dropdownClassName += ` ${unref$1(getUiSize)}`;
893
902
  }
894
903
  const bindValue = {
895
904
  [valueField || (isCheck ? "checked" : "value")]: props.formModel[name]
@@ -904,7 +913,7 @@ const _sfc_main$a = defineComponent({
904
913
  return createVNode(Comp, compAttr, null);
905
914
  }
906
915
  const compSlot = isFunction(renderComponent) ? {
907
- ...renderComponent(unref(getValues))
916
+ ...renderComponent(unref$1(getValues))
908
917
  } : {
909
918
  default: () => renderComponent
910
919
  };
@@ -923,11 +932,11 @@ const _sfc_main$a = defineComponent({
923
932
  if (!component)
924
933
  return [];
925
934
  if (isFunction(dynamicRules)) {
926
- return dynamicRules(unref(getValues).model);
935
+ return dynamicRules(unref$1(getValues).model);
927
936
  }
928
937
  const defaultMsg = createPlaceholder(component) + label;
929
938
  let rules = cloneDeep(defaultRules);
930
- const getRequired = isFunction(required) ? required(unref(getValues).model) : required;
939
+ const getRequired = isFunction(required) ? required(unref$1(getValues).model) : required;
931
940
  function validator(rule, value) {
932
941
  const msg = rule.message || defaultMsg;
933
942
  if (value === void 0 || isNull(value) || Array.isArray(value) && value.length === 0 || typeof value === "string" && value.trim() === "" || typeof value === "object" && Reflect.has(value, "checked") && Reflect.has(value, "halfChecked") && Array.isArray(value.checked) && Array.isArray(value.halfChecked) && value.checked.length === 0 && value.halfChecked.length === 0) {
@@ -936,7 +945,7 @@ const _sfc_main$a = defineComponent({
936
945
  return Promise.resolve();
937
946
  }
938
947
  if (!rules || !rules.length) {
939
- let _required = isBoolean(getRequired) ? getRequired : unref(getRequired);
948
+ let _required = isBoolean(getRequired) ? getRequired : unref$1(getRequired);
940
949
  rules = _required ? [{
941
950
  required: _required,
942
951
  validator
@@ -945,7 +954,7 @@ const _sfc_main$a = defineComponent({
945
954
  const requiredIndex = rules.findIndex((rule) => Reflect.has(rule, "required") && !Reflect.has(rule, "validator"));
946
955
  if (requiredIndex !== -1) {
947
956
  const rule = rules[requiredIndex];
948
- if (!unref(getShow)) {
957
+ if (!unref$1(getShow)) {
949
958
  rule.required = false;
950
959
  }
951
960
  if (!Reflect.has(rule, "type")) {
@@ -955,7 +964,7 @@ const _sfc_main$a = defineComponent({
955
964
  if (component.includes("Input") || component.includes("Textarea")) {
956
965
  rule.whitespace = true;
957
966
  }
958
- const valueFormat = unref(getComponentProps)?.valueFormat;
967
+ const valueFormat = unref$1(getComponentProps)?.valueFormat;
959
968
  setComponentRuleType(rule, component, valueFormat);
960
969
  }
961
970
  const maxIndex = rules.findIndex((val) => val.max);
@@ -979,7 +988,7 @@ const _sfc_main$a = defineComponent({
979
988
  mode
980
989
  } = props.formProps;
981
990
  let _colProps = colProps || gColProps || (mode === "search" ? appConf.ui.form.searchColspan : appConf.ui.form.dialogColspan);
982
- const values = unref(getValues);
991
+ const values = unref$1(getValues);
983
992
  if (!component) {
984
993
  if (!render && !renderCol && !slot) {
985
994
  error(t("NEED_RENDER"));
@@ -988,7 +997,7 @@ const _sfc_main$a = defineComponent({
988
997
  }
989
998
  if (component === "Divider") {
990
999
  let _slot;
991
- let cprops = unref(getComponentProps);
1000
+ let cprops = unref$1(getComponentProps);
992
1001
  const span = cprops?.span ?? 24;
993
1002
  return createVNode(Col, {
994
1003
  "span": span
@@ -1001,12 +1010,13 @@ const _sfc_main$a = defineComponent({
1001
1010
  const getContent = () => {
1002
1011
  return colSlot ? getSlot(slots, colSlot, values) : renderCol ? renderCol(values) : renderItem();
1003
1012
  };
1004
- return unref(getShow) && createVNode(Col, _colProps, _isSlot$1(_slot2 = getContent()) ? _slot2 : {
1013
+ return unref$1(getShow) && createVNode(Col, _colProps, _isSlot$1(_slot2 = getContent()) ? _slot2 : {
1005
1014
  default: () => [_slot2]
1006
1015
  });
1007
1016
  };
1008
1017
  }
1009
- });
1018
+ };
1019
+ const DtFormItem = /* @__PURE__ */ _export_sfc(_sfc_main$b, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/form/src/components/FormItem.vue"]]);
1010
1020
  const _hoisted_1$1 = {
1011
1021
  key: 0,
1012
1022
  className: "preIcon pr-1"
@@ -1020,7 +1030,7 @@ const _hoisted_4 = /* @__PURE__ */ createElementVNode("i", { class: "text-2xl i
1020
1030
  const _hoisted_5 = [
1021
1031
  _hoisted_4
1022
1032
  ];
1023
- const _sfc_main$9 = /* @__PURE__ */ defineComponent$1({
1033
+ const _sfc_main$a = /* @__PURE__ */ defineComponent({
1024
1034
  __name: "FormButtons",
1025
1035
  props: {
1026
1036
  mode: {
@@ -1052,7 +1062,7 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent$1({
1052
1062
  setup(__props, { emit: emits }) {
1053
1063
  const props = __props;
1054
1064
  const { t } = useI18n();
1055
- const advancedRef = ref(props.isAdvanced);
1065
+ const advancedRef = ref$1(props.isAdvanced);
1056
1066
  let key = 0;
1057
1067
  const showAdvanceRef = computed(() => {
1058
1068
  return props.mode === "search" ? props.showAdvancedButton : false;
@@ -1088,7 +1098,7 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent$1({
1088
1098
  }
1089
1099
  watch(() => props.isAdvanced, (v) => {
1090
1100
  if (v) {
1091
- nextTick(() => toggleAdvanced());
1101
+ nextTick$1(() => toggleAdvanced());
1092
1102
  }
1093
1103
  }, {
1094
1104
  immediate: true
@@ -1121,7 +1131,7 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent$1({
1121
1131
  (button.show === void 0 ? true : button.show) ? withDirectives((openBlock(), createBlock(_component_AButton, {
1122
1132
  type: button.type,
1123
1133
  class: normalizeClass(button.class),
1124
- loading: button.loading,
1134
+ loading: button.loading?.value,
1125
1135
  disabled: button.disabled,
1126
1136
  key: unref$1(key),
1127
1137
  onClick: ($event) => handleBtnClick(button)
@@ -1129,18 +1139,18 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent$1({
1129
1139
  icon: withCtx(() => [
1130
1140
  button.preIcon ? withDirectives((openBlock(), createElementBlock("span", _hoisted_1$1, null, 512)), [
1131
1141
  [_directive_icon, button.preIcon]
1132
- ]) : createCommentVNode("", true)
1142
+ ]) : createCommentVNode("v-if", true)
1133
1143
  ]),
1134
1144
  default: withCtx(() => [
1135
1145
  createTextVNode(" " + toDisplayString(unref$1(t)(button.name)) + " ", 1),
1136
1146
  button.postIcon ? withDirectives((openBlock(), createElementBlock("span", _hoisted_2, null, 512)), [
1137
1147
  [_directive_icon, button.postIcon]
1138
- ]) : createCommentVNode("", true)
1148
+ ]) : createCommentVNode("v-if", true)
1139
1149
  ]),
1140
1150
  _: 2
1141
1151
  }, 1032, ["type", "class", "loading", "disabled", "onClick"])), [
1142
1152
  [_directive_auth, button.auth]
1143
- ]) : createCommentVNode("", true)
1153
+ ]) : createCommentVNode("v-if", true)
1144
1154
  ], 64);
1145
1155
  }), 256)),
1146
1156
  unref$1(showAdvanceRef) ? (openBlock(), createBlock(_component_AButton, {
@@ -1150,22 +1160,24 @@ const _sfc_main$9 = /* @__PURE__ */ defineComponent$1({
1150
1160
  onClick: toggleAdvanced
1151
1161
  }, {
1152
1162
  default: withCtx(() => [
1153
- createElementVNode("span", _hoisted_3, toDisplayString(unref$1(advancedRef) ? unref$1(t)("UI.ADVANCED") : unref$1(t)("UI.EXPAND")), 1),
1163
+ createCommentVNode(" \u6536\u8D77 | \u5C55\u5F00 "),
1164
+ createElementVNode("span", _hoisted_3, toDisplayString(advancedRef.value ? unref$1(t)("UI.ADVANCED") : unref$1(t)("UI.EXPAND")), 1),
1154
1165
  createElementVNode("span", {
1155
1166
  class: normalizeClass(unref$1(getAdvanceClass))
1156
1167
  }, _hoisted_5, 2)
1157
1168
  ]),
1158
1169
  _: 1
1159
- })) : createCommentVNode("", true)
1170
+ })) : createCommentVNode("v-if", true)
1160
1171
  ]),
1161
1172
  _: 1
1162
1173
  }, 8, ["style"])
1163
1174
  ]),
1164
1175
  _: 1
1165
- }, 16)) : createCommentVNode("", true);
1176
+ }, 16)) : createCommentVNode("v-if", true);
1166
1177
  };
1167
1178
  }
1168
1179
  });
1180
+ const DtFormButtons = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/form/src/components/FormButtons.vue"]]);
1169
1181
  const SEARCH_BTN_NAME = "UI.SEARCH";
1170
1182
  const RESET_BTN_NAME = "UI.RESET";
1171
1183
  const SEARCH_BTNS = [
@@ -1183,10 +1195,10 @@ function useFormEvents({
1183
1195
  handleFormValues
1184
1196
  }) {
1185
1197
  function getFormValues() {
1186
- const formEl = unref(formElRef);
1198
+ const formEl = unref$1(formElRef);
1187
1199
  if (!formEl)
1188
1200
  return {};
1189
- return handleFormValues(toRaw(unref(formModel)));
1201
+ return handleFormValues(toRaw$1(unref$1(formModel)));
1190
1202
  }
1191
1203
  function updateSchema(data) {
1192
1204
  let updateItems = [];
@@ -1197,7 +1209,7 @@ function useFormEvents({
1197
1209
  }
1198
1210
  const schema = [];
1199
1211
  updateItems.forEach((it) => {
1200
- unref(getSchema).forEach((val) => {
1212
+ unref$1(getSchema).forEach((val) => {
1201
1213
  if (val.name === it.name) {
1202
1214
  const newSchema = deepMerge(val, it);
1203
1215
  schema.push(newSchema);
@@ -1224,7 +1236,7 @@ function useFormEvents({
1224
1236
  obj[name] = null;
1225
1237
  if (!isNullAndUnDef(it.defaultValue))
1226
1238
  return obj[name] = it.defaultValue;
1227
- let props = isFunction(it.props) ? it.props(toRaw(unref(formModel))) : it.props;
1239
+ let props = isFunction(it.props) ? it.props(toRaw$1(unref$1(formModel))) : it.props;
1228
1240
  if (!isNullAndUnDef(props?.defaultValue))
1229
1241
  obj[name] = props.defaultValue;
1230
1242
  });
@@ -1240,25 +1252,25 @@ function useFormEvents({
1240
1252
  setFormValues(obj);
1241
1253
  }
1242
1254
  async function clearValidate(name) {
1243
- await unref(formElRef)?.clearValidate(name);
1255
+ await unref$1(formElRef)?.clearValidate(name);
1244
1256
  }
1245
1257
  function resetForms() {
1246
- const { resetFunc } = unref(getProps);
1258
+ const { resetFunc } = unref$1(getProps);
1247
1259
  resetFunc && isFunction(resetFunc) && resetFunc();
1248
- if (!unref(formElRef))
1260
+ if (!unref$1(formElRef))
1249
1261
  return;
1250
1262
  Object.keys(formModel).forEach((key) => {
1251
- const schema = unref(getSchema).find((item) => item.name === key);
1263
+ const schema = unref$1(getSchema).find((item) => item.name === key);
1252
1264
  const isInput = schema?.component && ["Input", "InputPassword", "InputSearch", "InputTextArea"].includes(schema.component);
1253
1265
  formModel[key] = isInput ? defaultValue.value[key] || "" : defaultValue.value[key];
1254
1266
  });
1255
- nextTick(() => clearValidate());
1256
- emits("reset", toRaw(formModel));
1267
+ nextTick$1(() => clearValidate());
1268
+ emits("reset", toRaw$1(formModel));
1257
1269
  }
1258
1270
  function removeFormByName(names) {
1259
1271
  if (!names)
1260
1272
  return;
1261
- const schemaList = cloneDeep(unref(getSchema));
1273
+ const schemaList = cloneDeep(unref$1(getSchema));
1262
1274
  const nameList = isString(names) ? [names] : names;
1263
1275
  for (const name of nameList) {
1264
1276
  _removeSchemaByName(name, schemaList);
@@ -1273,7 +1285,7 @@ function useFormEvents({
1273
1285
  }
1274
1286
  }
1275
1287
  function appendFormItems(schema, prefixName, first = false) {
1276
- const schemaList = cloneDeep(unref(getSchema));
1288
+ const schemaList = cloneDeep(unref$1(getSchema));
1277
1289
  const index2 = schemaList.findIndex((schema2) => schema2.name === prefixName);
1278
1290
  if (!prefixName || index2 === -1 || first) {
1279
1291
  first ? schemaList.unshift(...schema) : schemaList.push(...schema);
@@ -1286,12 +1298,12 @@ function useFormEvents({
1286
1298
  schemaRef.value = schemaList;
1287
1299
  }
1288
1300
  function itemIsDateType(key) {
1289
- return unref(getSchema).some((item) => {
1301
+ return unref$1(getSchema).some((item) => {
1290
1302
  return item.name === key ? ["DatePicker", "MonthPicker", "WeekPicker", "TimePicker", "RangePicker"].includes(item.component) : false;
1291
1303
  });
1292
1304
  }
1293
1305
  async function validateFields(nameList) {
1294
- return unref(formElRef)?.validateFields(nameList);
1306
+ return unref$1(formElRef)?.validateFields(nameList);
1295
1307
  }
1296
1308
  function setFormValues(values) {
1297
1309
  if (!values || !Object.keys(values).length) {
@@ -1299,10 +1311,10 @@ function useFormEvents({
1299
1311
  formModel[it] = Array.isArray(formModel[it]) ? [] : null;
1300
1312
  return;
1301
1313
  }
1302
- const names = unref(getSchema).map((item) => item.name).filter(Boolean);
1314
+ const names = unref$1(getSchema).map((item) => item.name).filter(Boolean);
1303
1315
  const validKeys = [];
1304
1316
  Object.keys(values).forEach((key) => {
1305
- const schema = unref(getSchema).find((item) => item.name === key);
1317
+ const schema = unref$1(getSchema).find((item) => item.name === key);
1306
1318
  let value = values[key];
1307
1319
  const hasKey = Reflect.has(values, key);
1308
1320
  value = handleInputNumberValue(schema?.component, value);
@@ -1333,7 +1345,7 @@ function useFormEvents({
1333
1345
  return validateFields(validKeys);
1334
1346
  }
1335
1347
  async function validate(nameList) {
1336
- return await unref(formElRef)?.validate(nameList);
1348
+ return await unref$1(formElRef)?.validate(nameList);
1337
1349
  }
1338
1350
  return {
1339
1351
  getFormValues,
@@ -1456,7 +1468,7 @@ function useFormActions(opt) {
1456
1468
  const { getProps, defaultValue, updateSchema, getFormValues, setFormValues } = opt;
1457
1469
  const { appConf } = useAppStore();
1458
1470
  function handleAdvanced(isAdvanced) {
1459
- const { schemas, minShowColumn = appConf.ui.form?.minShowColumn || 2 } = unref(getProps);
1471
+ const { schemas, minShowColumn = appConf.ui.form?.minShowColumn || 2 } = unref$1(getProps);
1460
1472
  let schema = schemas.reduce((t, it, index2) => {
1461
1473
  if (index2 > minShowColumn - 1)
1462
1474
  it.isAdvanced = isAdvanced;
@@ -1466,7 +1478,7 @@ function useFormActions(opt) {
1466
1478
  updateSchema(schema);
1467
1479
  }
1468
1480
  function handleMethod(params) {
1469
- const { onSearch, onReset } = unref(getProps);
1481
+ const { onSearch, onReset } = unref$1(getProps);
1470
1482
  if (isBoolean(params)) {
1471
1483
  handleAdvanced(params);
1472
1484
  } else if (params.name === SEARCH_BTN_NAME) {
@@ -1492,7 +1504,7 @@ const BasicProps = {
1492
1504
  },
1493
1505
  model: {
1494
1506
  type: Object,
1495
- default: {}
1507
+ default: () => ({})
1496
1508
  },
1497
1509
  layout: {
1498
1510
  type: String,
@@ -1512,23 +1524,19 @@ const BasicProps = {
1512
1524
  },
1513
1525
  labelCol: {
1514
1526
  type: Object,
1515
- default: () => {
1516
- }
1527
+ default: () => ({})
1517
1528
  },
1518
1529
  wrapperCol: {
1519
1530
  type: Object,
1520
- default: () => {
1521
- }
1531
+ default: () => ({})
1522
1532
  },
1523
1533
  rowProps: {
1524
1534
  type: Object,
1525
- default: () => {
1526
- }
1535
+ default: () => ({})
1527
1536
  },
1528
1537
  colProps: {
1529
1538
  type: Object,
1530
- default: () => {
1531
- }
1539
+ default: () => ({})
1532
1540
  },
1533
1541
  size: {
1534
1542
  type: String,
@@ -1578,8 +1586,8 @@ const BasicProps = {
1578
1586
  type: Object,
1579
1587
  default: () => {
1580
1588
  return {
1581
- onSearch: ref(false),
1582
- onReset: ref(false)
1589
+ onSearch: ref$1(false),
1590
+ onReset: ref$1(false)
1583
1591
  };
1584
1592
  }
1585
1593
  },
@@ -1604,7 +1612,7 @@ const BasicProps = {
1604
1612
  type: Function
1605
1613
  }
1606
1614
  };
1607
- const _sfc_main$8 = /* @__PURE__ */ defineComponent$1({
1615
+ const _sfc_main$9 = /* @__PURE__ */ defineComponent({
1608
1616
  __name: "index",
1609
1617
  props: BasicProps,
1610
1618
  emits: ["register"],
@@ -1612,29 +1620,34 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent$1({
1612
1620
  const props = __props;
1613
1621
  const { getAppConf } = useAppStore();
1614
1622
  const attrs = useAttrs();
1615
- const formElRef = ref(null);
1623
+ const formElRef = ref$1(null);
1616
1624
  const formModel = reactive({});
1617
- const defaultValue = ref({});
1618
- const propsRef = ref();
1619
- const schemaRef = ref(null);
1625
+ const defaultValue = ref$1({});
1626
+ const propsRef = ref$1();
1627
+ const schemaRef = ref$1(null);
1620
1628
  const getProps = computed(() => {
1629
+ let colProps = props.colProps;
1630
+ if (isEmpty(props.colProps)) {
1631
+ colProps = props.mode === "search" ? getAppConf.ui.form.searchColspan || { span: 8 } : getAppConf.ui.form.dialogColspan || { span: 12 };
1632
+ }
1621
1633
  return {
1622
1634
  ...props,
1623
1635
  ...getAppConf.ui.form,
1624
- ...unref(propsRef)
1636
+ colProps,
1637
+ ...unref$1(propsRef)
1625
1638
  };
1626
1639
  });
1627
1640
  const getBindValue = computed(() => {
1628
1641
  return {
1629
1642
  ...attrs,
1630
- ...unref(getProps)
1643
+ ...unref$1(getProps)
1631
1644
  };
1632
1645
  });
1633
1646
  const getSchema = computed(() => {
1634
- return unref(schemaRef) || unref(getProps).schemas;
1647
+ return unref$1(schemaRef) || unref$1(getProps).schemas;
1635
1648
  });
1636
1649
  const getFormClass = computed(() => {
1637
- const { compact, mode } = unref(getProps);
1650
+ const { compact, mode } = unref$1(getProps);
1638
1651
  const getCompact = compact === null ? mode === "dialog" ? false : true : compact;
1639
1652
  return [
1640
1653
  "basic-form",
@@ -1645,12 +1658,12 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent$1({
1645
1658
  ];
1646
1659
  });
1647
1660
  function setProps(formProps) {
1648
- propsRef.value = deepMerge(unref(propsRef) || {}, formProps);
1661
+ propsRef.value = deepMerge(unref$1(propsRef) || {}, formProps);
1649
1662
  return null;
1650
1663
  }
1651
1664
  function setFormModel(key, value) {
1652
1665
  formModel[key] = value;
1653
- const { validateTrigger } = unref(getBindValue);
1666
+ const { validateTrigger } = unref$1(getBindValue);
1654
1667
  if (!validateTrigger || validateTrigger === "change") {
1655
1668
  validateFields([key]);
1656
1669
  }
@@ -1704,7 +1717,7 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent$1({
1704
1717
  showAdvancedButton: advanced,
1705
1718
  loading,
1706
1719
  buttons
1707
- } = unref(getProps);
1720
+ } = unref$1(getProps);
1708
1721
  let showAdvancedButton = mode === "search" ? true : false;
1709
1722
  if (advanced !== void 0) {
1710
1723
  showAdvancedButton = advanced;
@@ -1737,16 +1750,16 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent$1({
1737
1750
  getFormValues,
1738
1751
  setFormValues
1739
1752
  });
1740
- onMounted(() => {
1753
+ onMounted$1(() => {
1741
1754
  setFormValues(null);
1742
1755
  emits("register", formActionMethods);
1743
1756
  initDefault();
1744
1757
  });
1745
1758
  watch(
1746
- () => unref(getProps).onSearch,
1759
+ () => unref$1(getProps).onSearch,
1747
1760
  () => {
1748
1761
  useTimeoutFn(() => {
1749
- const { onSearch, autoFetch } = unref(getProps);
1762
+ const { onSearch, autoFetch } = unref$1(getProps);
1750
1763
  if (autoFetch && onSearch && isFunction(onSearch)) {
1751
1764
  onSearch(toRaw(defaultValue.value));
1752
1765
  }
@@ -1754,9 +1767,9 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent$1({
1754
1767
  }
1755
1768
  );
1756
1769
  watch(
1757
- () => unref(getProps).model,
1770
+ () => unref$1(getProps).model,
1758
1771
  (v) => {
1759
- const { model } = unref(getProps);
1772
+ const { model } = unref$1(getProps);
1760
1773
  if (!model || !Object.keys(model).length)
1761
1774
  return;
1762
1775
  setFormValues(model);
@@ -1773,7 +1786,7 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent$1({
1773
1786
  ref_key: "formElRef",
1774
1787
  ref: formElRef,
1775
1788
  class: unref$1(getFormClass),
1776
- model: unref$1(formModel),
1789
+ model: formModel,
1777
1790
  layout: unref$1(getProps).layout,
1778
1791
  onKeypress: withKeys(handleEnterPress, ["enter"])
1779
1792
  }), {
@@ -1783,12 +1796,12 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent$1({
1783
1796
  } }), {
1784
1797
  default: withCtx(() => [
1785
1798
  (openBlock(true), createElementBlock(Fragment, null, renderList(unref$1(getSchema), (schema) => {
1786
- return openBlock(), createBlock(unref$1(_sfc_main$a), {
1799
+ return openBlock(), createBlock(unref$1(DtFormItem), {
1787
1800
  key: schema.name,
1788
1801
  schema,
1789
1802
  formProps: unref$1(getProps),
1790
- formModel: unref$1(formModel),
1791
- defaultValues: unref$1(defaultValue),
1803
+ formModel,
1804
+ defaultValues: defaultValue.value,
1792
1805
  setFormModel,
1793
1806
  formActionType: formActionMethods
1794
1807
  }, createSlots({ _: 2 }, [
@@ -1802,7 +1815,7 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent$1({
1802
1815
  })
1803
1816
  ]), 1032, ["schema", "formProps", "formModel", "defaultValues"]);
1804
1817
  }), 128)),
1805
- unref$1(getActionsProps).buttonList?.length ? (openBlock(), createBlock(unref$1(_sfc_main$9), mergeProps({ key: 0 }, unref$1(getActionsProps), { onHandleMethod: unref$1(handleMethod) }), null, 16, ["onHandleMethod"])) : createCommentVNode("", true)
1818
+ unref$1(getActionsProps).buttonList?.length ? (openBlock(), createBlock(unref$1(DtFormButtons), mergeProps({ key: 0 }, unref$1(getActionsProps), { onHandleMethod: unref$1(handleMethod) }), null, 16, ["onHandleMethod"])) : createCommentVNode("v-if", true)
1806
1819
  ]),
1807
1820
  _: 3
1808
1821
  }, 16)
@@ -1812,11 +1825,12 @@ const _sfc_main$8 = /* @__PURE__ */ defineComponent$1({
1812
1825
  };
1813
1826
  }
1814
1827
  });
1828
+ const Forms = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/form/src/index.vue"]]);
1815
1829
  function useForm(props) {
1816
- const formRef = ref(null);
1817
- const loadedRef = ref(false);
1830
+ const formRef = ref$1(null);
1831
+ const loadedRef = ref$1(false);
1818
1832
  function register(instance) {
1819
- if (unref(loadedRef) && instance === unref(formRef))
1833
+ if (unref$1(loadedRef) && instance === unref$1(formRef))
1820
1834
  return;
1821
1835
  formRef.value = instance;
1822
1836
  loadedRef.value = true;
@@ -1830,10 +1844,10 @@ function useForm(props) {
1830
1844
  );
1831
1845
  }
1832
1846
  async function getForm() {
1833
- const form = unref(formRef);
1847
+ const form = unref$1(formRef);
1834
1848
  if (!form)
1835
1849
  console.error("\u8868\u5355\u672A\u7533\u660E!");
1836
- await nextTick();
1850
+ await nextTick$1();
1837
1851
  return form;
1838
1852
  }
1839
1853
  const methods = {
@@ -1858,7 +1872,7 @@ function useForm(props) {
1858
1872
  form.resetForms();
1859
1873
  },
1860
1874
  removeFormByName: async (name) => {
1861
- unref(formRef)?.removeFormByName(name);
1875
+ unref$1(formRef)?.removeFormByName(name);
1862
1876
  },
1863
1877
  setFormValues: async (values) => {
1864
1878
  const form = await getForm();
@@ -1877,7 +1891,7 @@ function useForm(props) {
1877
1891
  return form.validateFields(nameList);
1878
1892
  },
1879
1893
  getFormValues: () => {
1880
- return unref(formRef)?.getFormValues();
1894
+ return unref$1(formRef)?.getFormValues();
1881
1895
  }
1882
1896
  };
1883
1897
  return [register, methods];
@@ -1888,14 +1902,14 @@ const withInstall = (comp) => {
1888
1902
  };
1889
1903
  return comp;
1890
1904
  };
1891
- const DtForm = withInstall(_sfc_main$8);
1905
+ const DtForm = withInstall(Forms);
1892
1906
  const orgDialogProp = reactive({});
1893
1907
  const cbTransfer = reactive({});
1894
1908
  const dataTransfer = reactive({});
1895
1909
  function useModalOut() {
1896
- const modal = ref(null);
1897
- const loaded = ref(true);
1898
- const uid = ref(null);
1910
+ const modal = ref$1(null);
1911
+ const loaded = ref$1(true);
1912
+ const uid = ref$1(null);
1899
1913
  const { isProd } = useApp();
1900
1914
  function register(modalMethod, uuid) {
1901
1915
  if (!getCurrentInstance()) {
@@ -1903,22 +1917,22 @@ function useModalOut() {
1903
1917
  }
1904
1918
  uid.value = uuid;
1905
1919
  onUnmounted(() => {
1906
- if (unref(isProd)) {
1920
+ if (unref$1(isProd)) {
1907
1921
  modal.value = null;
1908
1922
  loaded.value = false;
1909
- dataTransfer[unref(uid)] = null;
1910
- orgDialogProp[unref(uid)] = null;
1911
- cbTransfer[unref(uid)] = (res) => {
1923
+ dataTransfer[unref$1(uid)] = null;
1924
+ orgDialogProp[unref$1(uid)] = null;
1925
+ cbTransfer[unref$1(uid)] = (res) => {
1912
1926
  };
1913
1927
  }
1914
1928
  });
1915
- if (unref(loaded) && modalMethod === unref(modal))
1929
+ if (unref$1(loaded) && modalMethod === unref$1(modal))
1916
1930
  return;
1917
1931
  modal.value = modalMethod;
1918
1932
  loaded.value = true;
1919
1933
  }
1920
1934
  const getInstance = () => {
1921
- const instance = unref(modal);
1935
+ const instance = unref$1(modal);
1922
1936
  if (!instance) {
1923
1937
  error("useModalOut \u5B9E\u4F8B\u672A\u5B9A\u4E49");
1924
1938
  }
@@ -1932,7 +1946,7 @@ function useModalOut() {
1932
1946
  getInstance()?.redoModalHeight?.();
1933
1947
  },
1934
1948
  openModal: (params, afterClose) => {
1935
- const id = unref(uid);
1949
+ const id = unref$1(uid);
1936
1950
  dataTransfer[id] = isObject(params) ? { ...toRaw(params) } : params;
1937
1951
  getInstance()?.setModalProps({
1938
1952
  footer: [],
@@ -1953,19 +1967,19 @@ function useModalOut() {
1953
1967
  return [register, methods];
1954
1968
  }
1955
1969
  function useModal(props, setModalData) {
1956
- const modalInstanceRef = ref(null);
1970
+ const modalInstanceRef = ref$1(null);
1957
1971
  const currentInstance = getCurrentInstance();
1958
- const uidRef = ref(null);
1972
+ const uidRef = ref$1(null);
1959
1973
  const { isProd } = useApp();
1960
1974
  const getInstance = () => {
1961
- const instance = unref(modalInstanceRef);
1975
+ const instance = unref$1(modalInstanceRef);
1962
1976
  if (!instance) {
1963
1977
  error("useModal \u5B9E\u4F8B\u672A\u5B9A\u4E49");
1964
1978
  }
1965
1979
  return instance;
1966
1980
  };
1967
1981
  const register = (modalInstance, uuid) => {
1968
- if (unref(isProd)) {
1982
+ if (unref$1(isProd)) {
1969
1983
  modalInstanceRef.value = null;
1970
1984
  }
1971
1985
  uidRef.value = uuid;
@@ -1975,12 +1989,12 @@ function useModal(props, setModalData) {
1975
1989
  modalInstance.setModalProps(props);
1976
1990
  };
1977
1991
  watchEffect(() => {
1978
- const data = dataTransfer[unref(uidRef)];
1992
+ const data = dataTransfer[unref$1(uidRef)];
1979
1993
  if (!data)
1980
1994
  return;
1981
1995
  if (!setModalData || !isFunction(setModalData))
1982
1996
  return;
1983
- nextTick(() => {
1997
+ nextTick$1(() => {
1984
1998
  setModalData(data);
1985
1999
  });
1986
2000
  });
@@ -1989,8 +2003,8 @@ function useModal(props, setModalData) {
1989
2003
  getInstance()?.setModalProps({ loading });
1990
2004
  },
1991
2005
  closeModal: (rsp) => {
1992
- if (cbTransfer[unref(uidRef)])
1993
- cbTransfer[unref(uidRef)](rsp);
2006
+ if (cbTransfer[unref$1(uidRef)])
2007
+ cbTransfer[unref$1(uidRef)](rsp);
1994
2008
  getInstance()?.setModalProps({ visible: false });
1995
2009
  },
1996
2010
  setModalProps: (props2) => {
@@ -2082,10 +2096,10 @@ function useDragMove(context) {
2082
2096
  const drag = (wrap) => {
2083
2097
  if (!wrap)
2084
2098
  return;
2085
- wrap.setAttribute("data-drag", unref(context.draggable));
2099
+ wrap.setAttribute("data-drag", unref$1(context.draggable));
2086
2100
  const dialogHeaderEl = wrap.querySelector(".ant-modal-header");
2087
2101
  const dragDom = wrap.querySelector(".ant-modal");
2088
- if (!dialogHeaderEl || !dragDom || !unref(context.draggable))
2102
+ if (!dialogHeaderEl || !dragDom || !unref$1(context.draggable))
2089
2103
  return;
2090
2104
  dialogHeaderEl.style.cursor = "move";
2091
2105
  dialogHeaderEl.onmousedown = (e) => {
@@ -2142,14 +2156,14 @@ function useDragMove(context) {
2142
2156
  const display = getStyle(wrap, "display");
2143
2157
  const draggable = wrap.getAttribute("data-drag");
2144
2158
  if (display !== "none") {
2145
- if (draggable === null || unref(context.destroyOnClose)) {
2159
+ if (draggable === null || unref$1(context.destroyOnClose)) {
2146
2160
  drag(wrap);
2147
2161
  }
2148
2162
  }
2149
2163
  }
2150
2164
  };
2151
2165
  watchEffect(() => {
2152
- if (!unref(context.visible) || !unref(context.draggable)) {
2166
+ if (!unref$1(context.visible) || !unref$1(context.draggable)) {
2153
2167
  return;
2154
2168
  }
2155
2169
  useTimeoutFn(() => {
@@ -2160,7 +2174,7 @@ function useDragMove(context) {
2160
2174
  function _isSlot(s) {
2161
2175
  return typeof s === "function" || Object.prototype.toString.call(s) === "[object Object]" && !isVNode(s);
2162
2176
  }
2163
- const Modal = defineComponent({
2177
+ const _sfc_main$8 = {
2164
2178
  name: "Modal",
2165
2179
  inheritAttrs: false,
2166
2180
  props: basicProps$1,
@@ -2187,7 +2201,7 @@ const Modal = defineComponent({
2187
2201
  return () => {
2188
2202
  let _slot;
2189
2203
  const propsData = {
2190
- ...unref(attrs),
2204
+ ...unref$1(attrs),
2191
2205
  ...props,
2192
2206
  destroyOnClose: true,
2193
2207
  onCancel
@@ -2199,9 +2213,10 @@ const Modal = defineComponent({
2199
2213
  });
2200
2214
  };
2201
2215
  }
2202
- });
2216
+ };
2217
+ const Modal = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/modal/src/components/Modal.vue"]]);
2203
2218
  const index = "";
2204
- const _sfc_main$7 = /* @__PURE__ */ defineComponent$1({
2219
+ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
2205
2220
  __name: "CloseIcon",
2206
2221
  props: {
2207
2222
  canFullscreen: { type: Boolean, default: true },
@@ -2259,7 +2274,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent$1({
2259
2274
  ]),
2260
2275
  _: 1
2261
2276
  }, 8, ["title"]))
2262
- ], 64)) : createCommentVNode("", true),
2277
+ ], 64)) : createCommentVNode("v-if", true),
2263
2278
  createElementVNode("i", {
2264
2279
  class: "i mdi:close h-14 w-10 pr-4",
2265
2280
  onClick: handleCancel
@@ -2268,6 +2283,7 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent$1({
2268
2283
  };
2269
2284
  }
2270
2285
  });
2286
+ const CloseIcon = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/modal/src/components/CloseIcon.vue"]]);
2271
2287
  const isServer = typeof window === "undefined";
2272
2288
  const BAR_MAP = {
2273
2289
  vertical: {
@@ -2328,7 +2344,7 @@ function removeResizeListener(element, fn) {
2328
2344
  element.__ro__.disconnect();
2329
2345
  }
2330
2346
  }
2331
- const Bar = defineComponent$1({
2347
+ const Bar = defineComponent({
2332
2348
  name: "Bar",
2333
2349
  props: {
2334
2350
  vertical: Boolean,
@@ -2339,7 +2355,7 @@ const Bar = defineComponent$1({
2339
2355
  const instance = getCurrentInstance$1();
2340
2356
  const thumb = ref$1();
2341
2357
  const wrap = inject("scroll-bar-wrap", {});
2342
- const bar = computed$1(() => {
2358
+ const bar = computed(() => {
2343
2359
  return BAR_MAP[props.vertical ? "vertical" : "horizontal"];
2344
2360
  });
2345
2361
  const barStore = ref$1({});
@@ -2384,16 +2400,16 @@ const Bar = defineComponent$1({
2384
2400
  off(document, "mousemove", mouseMoveDocumentHandler);
2385
2401
  document.onselectstart = null;
2386
2402
  }
2387
- onUnmounted$1(() => {
2403
+ onUnmounted(() => {
2388
2404
  off(document, "mouseup", mouseUpDocumentHandler);
2389
2405
  });
2390
- return () => h$1(
2406
+ return () => h(
2391
2407
  "div",
2392
2408
  {
2393
2409
  class: ["scrollbar__bar", "is-" + bar.value.key],
2394
2410
  onMousedown: clickTrackHandler
2395
2411
  },
2396
- h$1("div", {
2412
+ h("div", {
2397
2413
  ref: thumb,
2398
2414
  class: "scrollbar__thumb",
2399
2415
  onMousedown: clickThumbHandler,
@@ -2407,7 +2423,7 @@ const Bar = defineComponent$1({
2407
2423
  }
2408
2424
  });
2409
2425
  const _hoisted_1 = { class: "scrollbar relative h-full overflow-hidden" };
2410
- const _sfc_main$6 = /* @__PURE__ */ defineComponent$1({
2426
+ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
2411
2427
  __name: "scroll-bar",
2412
2428
  props: {
2413
2429
  wrapClass: {
@@ -2431,12 +2447,12 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent$1({
2431
2447
  },
2432
2448
  setup(__props) {
2433
2449
  const props = __props;
2434
- const sizeWidth = ref("0");
2435
- const sizeHeight = ref("0");
2436
- const moveX = ref(0);
2437
- const moveY = ref(0);
2438
- const wrap = ref();
2439
- const resize = ref();
2450
+ const sizeWidth = ref$1("0");
2451
+ const sizeHeight = ref$1("0");
2452
+ const moveX = ref$1(0);
2453
+ const moveY = ref$1(0);
2454
+ const wrap = ref$1();
2455
+ const resize = ref$1();
2440
2456
  provide("scroll-bar-wrap", wrap);
2441
2457
  const style = computed(() => {
2442
2458
  let rsStyle = {};
@@ -2449,29 +2465,29 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent$1({
2449
2465
  return rsStyle;
2450
2466
  });
2451
2467
  const handleScroll = () => {
2452
- moveY.value = unref(wrap).scrollTop * 100 / unref(wrap).clientHeight;
2453
- moveX.value = unref(wrap).scrollLeft * 100 / unref(wrap).clientWidth;
2468
+ moveY.value = unref$1(wrap).scrollTop * 100 / unref$1(wrap).clientHeight;
2469
+ moveX.value = unref$1(wrap).scrollLeft * 100 / unref$1(wrap).clientWidth;
2454
2470
  };
2455
2471
  const update = () => {
2456
- if (!unref(wrap))
2472
+ if (!unref$1(wrap))
2457
2473
  return;
2458
- const heightPercentage = unref(wrap).clientHeight * 100 / unref(wrap).scrollHeight;
2459
- const widthPercentage = unref(wrap).clientWidth * 100 / unref(wrap).scrollWidth;
2474
+ const heightPercentage = unref$1(wrap).clientHeight * 100 / unref$1(wrap).scrollHeight;
2475
+ const widthPercentage = unref$1(wrap).clientWidth * 100 / unref$1(wrap).scrollWidth;
2460
2476
  sizeHeight.value = heightPercentage < 100 ? heightPercentage + "%" : "";
2461
2477
  sizeWidth.value = widthPercentage < 100 ? widthPercentage + "%" : "";
2462
2478
  };
2463
- onMounted(() => {
2464
- nextTick(update);
2479
+ onMounted$1(() => {
2480
+ nextTick$1(update);
2465
2481
  if (!props.noresize) {
2466
- addResizeListener(unref(resize), update);
2467
- addResizeListener(unref(wrap), update);
2482
+ addResizeListener(unref$1(resize), update);
2483
+ addResizeListener(unref$1(wrap), update);
2468
2484
  addEventListener("resize", update);
2469
2485
  }
2470
2486
  });
2471
2487
  onBeforeUnmount(() => {
2472
2488
  if (!props.noresize) {
2473
- removeResizeListener(unref(resize), update);
2474
- removeResizeListener(unref(wrap), update);
2489
+ removeResizeListener(unref$1(resize), update);
2490
+ removeResizeListener(unref$1(wrap), update);
2475
2491
  removeEventListener("resize", update);
2476
2492
  }
2477
2493
  });
@@ -2497,24 +2513,25 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent$1({
2497
2513
  }, 8, ["class", "style"]))
2498
2514
  ], 38),
2499
2515
  createVNode(unref$1(Bar), {
2500
- move: unref$1(moveX),
2501
- size: unref$1(sizeWidth)
2516
+ move: moveX.value,
2517
+ size: sizeWidth.value
2502
2518
  }, null, 8, ["move", "size"]),
2503
2519
  createVNode(unref$1(Bar), {
2504
2520
  vertical: "",
2505
- move: unref$1(moveY),
2506
- size: unref$1(sizeHeight)
2521
+ move: moveY.value,
2522
+ size: sizeHeight.value
2507
2523
  }, null, 8, ["move", "size"])
2508
2524
  ]);
2509
2525
  };
2510
2526
  }
2511
2527
  });
2512
- const _sfc_main$5 = /* @__PURE__ */ defineComponent$1({
2528
+ const ScrollBar = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/container/src/components/scroll-bar.vue"]]);
2529
+ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
2513
2530
  __name: "scroll-container",
2514
2531
  setup(__props) {
2515
- const scrollbarRef = ref(null);
2532
+ const scrollbarRef = ref$1(null);
2516
2533
  return (_ctx, _cache) => {
2517
- return openBlock(), createBlock(_sfc_main$6, mergeProps({
2534
+ return openBlock(), createBlock(ScrollBar, mergeProps({
2518
2535
  ref_key: "scrollbarRef",
2519
2536
  ref: scrollbarRef
2520
2537
  }, _ctx.$attrs, { class: "w-full h-full" }), {
@@ -2526,8 +2543,9 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent$1({
2526
2543
  };
2527
2544
  }
2528
2545
  });
2529
- const _sfc_main$4 = defineComponent({
2530
- name: "slot-container",
2546
+ const ScrollContainer = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/container/src/scroll-container.vue"]]);
2547
+ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
2548
+ __name: "slot-container",
2531
2549
  props: {
2532
2550
  template: {
2533
2551
  type: Function
@@ -2536,15 +2554,18 @@ const _sfc_main$4 = defineComponent({
2536
2554
  type: Object
2537
2555
  }
2538
2556
  },
2539
- setup(props) {
2540
- return () => {
2541
- return h("div", [props.template(props.data)]);
2557
+ setup(__props) {
2558
+ const props = __props;
2559
+ const Container = h("div", [props.template(props.data)]);
2560
+ return (_ctx, _cache) => {
2561
+ return openBlock(), createBlock(unref$1(Container));
2542
2562
  };
2543
2563
  }
2544
2564
  });
2545
- const DtScrollContainer = withInstall(_sfc_main$5);
2546
- withInstall(_sfc_main$4);
2547
- const _sfc_main$3 = /* @__PURE__ */ defineComponent$1({
2565
+ const SlotContainer = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/container/src/slot-container.vue"]]);
2566
+ const DtScrollContainer = withInstall(ScrollContainer);
2567
+ withInstall(SlotContainer);
2568
+ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
2548
2569
  __name: "ModalWrap",
2549
2570
  props: {
2550
2571
  useWrapper: { type: Boolean, default: true },
@@ -2558,15 +2579,15 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent$1({
2558
2579
  emits: ["ext-height", "height-change"],
2559
2580
  setup(__props, { emit: emits }) {
2560
2581
  const props = __props;
2561
- const wrapperRef = ref(null);
2562
- const wrapRef = ref(null);
2563
- const realHeightRef = ref(0);
2564
- const minRealHeightRef = ref(0);
2582
+ const wrapperRef = ref$1(null);
2583
+ const wrapRef = ref$1(null);
2584
+ const realHeightRef = ref$1(0);
2585
+ const minRealHeightRef = ref$1(0);
2565
2586
  let realHeight = 0;
2566
2587
  const wrapStyle = computed(() => {
2567
2588
  return {
2568
2589
  minHeight: `${props.minHeight}px`,
2569
- [props.fullScreen ? "height" : "maxHeight"]: `${unref(realHeightRef)}px`
2590
+ [props.fullScreen ? "height" : "maxHeight"]: `${unref$1(realHeightRef)}px`
2570
2591
  };
2571
2592
  });
2572
2593
  onMounted(() => {
@@ -2574,14 +2595,14 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent$1({
2574
2595
  emits("ext-height", modalHeaderHeight + modalFooterHeight);
2575
2596
  });
2576
2597
  async function getModalDom() {
2577
- const wrapperRefDom = unref(wrapperRef);
2598
+ const wrapperRefDom = unref$1(wrapperRef);
2578
2599
  if (!wrapperRefDom)
2579
2600
  return;
2580
2601
  const bodyDom = wrapperRefDom.$el.parentElement;
2581
2602
  if (!bodyDom)
2582
2603
  return;
2583
2604
  bodyDom.style.padding = "0";
2584
- await nextTick();
2605
+ await nextTick$1();
2585
2606
  const modalDom = bodyDom.parentElement && bodyDom.parentElement.parentElement;
2586
2607
  return modalDom;
2587
2608
  }
@@ -2598,18 +2619,18 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent$1({
2598
2619
  if (modalTop < 40) {
2599
2620
  maxHeight -= 26;
2600
2621
  }
2601
- await nextTick();
2602
- const warpEl = unref(wrapRef);
2622
+ await nextTick$1();
2623
+ const warpEl = unref$1(wrapRef);
2603
2624
  if (!warpEl)
2604
2625
  return;
2605
- await nextTick();
2626
+ await nextTick$1();
2606
2627
  realHeight = warpEl.scrollHeight;
2607
2628
  if (props.fullScreen) {
2608
2629
  realHeightRef.value = window.innerHeight - props.modalFooterHeight - props.modalHeaderHeight;
2609
2630
  } else {
2610
2631
  realHeightRef.value = props.height ? props.height : realHeight > maxHeight ? maxHeight : realHeight;
2611
2632
  }
2612
- emits("height-change", unref(realHeightRef));
2633
+ emits("height-change", unref$1(realHeightRef));
2613
2634
  const _modalDom = await getModalDom();
2614
2635
  _modalDom.style.top = (window.innerHeight - _modalDom.offsetHeight) / 2 + "px";
2615
2636
  } catch (error2) {
@@ -2650,7 +2671,8 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent$1({
2650
2671
  };
2651
2672
  }
2652
2673
  });
2653
- const _sfc_main$2 = /* @__PURE__ */ defineComponent$1({
2674
+ const ModalWrapper = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/modal/src/components/ModalWrap.vue"]]);
2675
+ const _sfc_main$2 = /* @__PURE__ */ defineComponent({
2654
2676
  __name: "ModalFooter",
2655
2677
  props: {
2656
2678
  buttons: Object,
@@ -2666,7 +2688,7 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent$1({
2666
2688
  setup(__props, { emit: emits }) {
2667
2689
  const props = __props;
2668
2690
  const { t } = useI18n("UI");
2669
- const buttonList = computed$1(() => {
2691
+ const buttonList = computed(() => {
2670
2692
  if (props.buttons && props.buttons.length)
2671
2693
  return props.buttons;
2672
2694
  let buttonActions = [
@@ -2692,7 +2714,7 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent$1({
2692
2714
  return (_ctx, _cache) => {
2693
2715
  return openBlock(), createElementBlock(Fragment, null, [
2694
2716
  renderSlot(_ctx.$slots, "appendFooter"),
2695
- createVNode(_sfc_main$9, {
2717
+ createVNode(DtFormButtons, {
2696
2718
  mode: "dialog",
2697
2719
  buttonList: unref$1(buttonList),
2698
2720
  onHandleMethod: _cache[0] || (_cache[0] = ($event) => handleMethod($event))
@@ -2701,16 +2723,17 @@ const _sfc_main$2 = /* @__PURE__ */ defineComponent$1({
2701
2723
  };
2702
2724
  }
2703
2725
  });
2726
+ const ModalFooter = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/modal/src/components/ModalFooter.vue"]]);
2704
2727
  function useFullScreen(wrapClassName) {
2705
- const fullScreenRef = ref(false);
2728
+ const fullScreenRef = ref$1(false);
2706
2729
  const getWrapClassName = computed(() => {
2707
- const clsName = unref(wrapClassName) || "";
2708
- const cls = unref(fullScreenRef) ? `fullscreen-modal ${clsName} ` : unref(clsName);
2730
+ const clsName = unref$1(wrapClassName) || "";
2731
+ const cls = unref$1(fullScreenRef) ? `fullscreen-modal ${clsName} ` : unref$1(clsName);
2709
2732
  return `dt-modal ${cls}`;
2710
2733
  });
2711
2734
  function toggleFullScreen(e) {
2712
2735
  e && e.stopPropagation();
2713
- fullScreenRef.value = !unref(fullScreenRef);
2736
+ fullScreenRef.value = !unref$1(fullScreenRef);
2714
2737
  dispatchResize();
2715
2738
  }
2716
2739
  return {
@@ -2719,52 +2742,52 @@ function useFullScreen(wrapClassName) {
2719
2742
  toggleFullScreen
2720
2743
  };
2721
2744
  }
2722
- const _sfc_main$1 = /* @__PURE__ */ defineComponent$1({
2745
+ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
2723
2746
  __name: "index",
2724
2747
  props: basicProps$1,
2725
2748
  emits: ["visible-change", "height-change", "cancel", "save", "register", "update:visible"],
2726
2749
  setup(__props, { emit: emits }) {
2727
2750
  const props = __props;
2728
- const visibleRef = ref(false);
2729
- const propsRef = ref();
2730
- const modalWrapperRef = ref(null);
2731
- const { getWrapClassName, toggleFullScreen, fullScreenRef } = useFullScreen(computed(() => unref(propsRef)?.wrapClassName));
2751
+ const visibleRef = ref$1(false);
2752
+ const propsRef = ref$1();
2753
+ const modalWrapperRef = ref$1(null);
2754
+ const { getWrapClassName, toggleFullScreen, fullScreenRef } = useFullScreen(computed(() => unref$1(propsRef)?.wrapClassName));
2732
2755
  const getMergeProps = computed(() => {
2733
2756
  return {
2734
2757
  ...props,
2735
- ...unref(propsRef)
2758
+ ...unref$1(propsRef)
2736
2759
  };
2737
2760
  });
2738
2761
  const getBindValue = computed(() => {
2739
2762
  const bindValue = {
2740
- ...unref(getMergeProps),
2741
- ...unref(propsRef),
2742
- visible: unref(visibleRef),
2743
- wrapClassName: unref(getWrapClassName)
2763
+ ...unref$1(getMergeProps),
2764
+ ...unref$1(propsRef),
2765
+ visible: unref$1(visibleRef),
2766
+ wrapClassName: unref$1(getWrapClassName)
2744
2767
  };
2745
- let omitArr = unref(fullScreenRef) ? ["height", "title"] : ["title"];
2746
- if (isArray(unref(propsRef)?.footer)) {
2768
+ let omitArr = unref$1(fullScreenRef) ? ["height", "title"] : ["title"];
2769
+ if (isArray(unref$1(propsRef)?.footer)) {
2747
2770
  omitArr.push("footer");
2748
2771
  }
2749
2772
  return omit(bindValue, omitArr);
2750
2773
  });
2751
2774
  const getWrapperHeight = computed(() => {
2752
- if (unref(fullScreenRef))
2775
+ if (unref$1(fullScreenRef))
2753
2776
  return void 0;
2754
- return unref(getBindValue).height;
2777
+ return unref$1(getBindValue).height;
2755
2778
  });
2756
2779
  const modalFooterHeight = computed(() => {
2757
2780
  if (isArray(props.footer)) {
2758
- return (unref(propsRef)?.footer).length ? 0 : void 0;
2781
+ return (unref$1(propsRef)?.footer).length ? 0 : void 0;
2759
2782
  }
2760
2783
  return props?.footer !== void 0 && !props.footer ? 0 : void 0;
2761
2784
  });
2762
2785
  const modalMethods = {
2763
2786
  setModalProps,
2764
2787
  redoModalHeight: () => {
2765
- nextTick(() => {
2766
- if (unref(modalWrapperRef)) {
2767
- unref(modalWrapperRef).setModalHeight();
2788
+ nextTick$1(() => {
2789
+ if (unref$1(modalWrapperRef)) {
2790
+ unref$1(modalWrapperRef).setModalHeight();
2768
2791
  }
2769
2792
  });
2770
2793
  }
@@ -2777,7 +2800,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent$1({
2777
2800
  emits("height-change", height);
2778
2801
  }
2779
2802
  function setModalProps(props2) {
2780
- propsRef.value = deepMerge(unref(propsRef) || {}, props2);
2803
+ propsRef.value = deepMerge(unref$1(propsRef) || {}, props2);
2781
2804
  if (Reflect.has(props2, "visible")) {
2782
2805
  visibleRef.value = !!props2.visible;
2783
2806
  }
@@ -2799,19 +2822,19 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent$1({
2799
2822
  return;
2800
2823
  }
2801
2824
  }
2802
- const { afterClose } = unref(getBindValue);
2825
+ const { afterClose } = unref$1(getBindValue);
2803
2826
  if (afterClose && isFunction(afterClose)) {
2804
2827
  afterClose();
2805
2828
  }
2806
2829
  visibleRef.value = false;
2807
2830
  emits("cancel", e);
2808
2831
  }
2809
- watch(() => unref(visibleRef), (v) => {
2832
+ watch(() => unref$1(visibleRef), (v) => {
2810
2833
  emits("visible-change", v);
2811
2834
  emits("update:visible", v);
2812
- nextTick(() => {
2813
- if (props.scrollTop && v && unref(modalWrapperRef)) {
2814
- unref(modalWrapperRef).$el.scrollTop = 0;
2835
+ nextTick$1(() => {
2836
+ if (props.scrollTop && v && unref$1(modalWrapperRef)) {
2837
+ unref$1(modalWrapperRef).$el.scrollTop = 0;
2815
2838
  }
2816
2839
  });
2817
2840
  }, {
@@ -2819,21 +2842,21 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent$1({
2819
2842
  });
2820
2843
  return (_ctx, _cache) => {
2821
2844
  const _component_ASpin = Spin;
2822
- return openBlock(), createBlock(unref$1(Modal), mergeProps(unref$1(getBindValue), { onCancel: handleCancel }), createSlots({
2845
+ return openBlock(), createBlock(Modal, mergeProps(unref$1(getBindValue), { onCancel: handleCancel }), createSlots({
2823
2846
  default: withCtx(() => [
2824
2847
  createVNode(_component_ASpin, {
2825
2848
  spinning: unref$1(getBindValue).loading,
2826
2849
  tip: unref$1(getBindValue).loadingTip
2827
2850
  }, {
2828
2851
  default: withCtx(() => [
2829
- createVNode(_sfc_main$3, mergeProps({
2852
+ createVNode(ModalWrapper, mergeProps({
2830
2853
  useWrapper: unref$1(getBindValue).useWrapper,
2831
2854
  fullScreen: unref$1(fullScreenRef),
2832
2855
  ref_key: "modalWrapperRef",
2833
2856
  ref: modalWrapperRef,
2834
2857
  minHeight: unref$1(getBindValue).minHeight,
2835
2858
  height: unref$1(getWrapperHeight),
2836
- visible: unref$1(visibleRef),
2859
+ visible: visibleRef.value,
2837
2860
  modalFooterHeight: unref$1(modalFooterHeight)
2838
2861
  }, unref$1(omit)(unref$1(getBindValue).wrapperProps, "visible", "height", "modalFooterHeight"), { onHeightChange: handleHeightChange }), {
2839
2862
  default: withCtx(() => [
@@ -2850,7 +2873,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent$1({
2850
2873
  !_ctx.$slots.closeIcon ? {
2851
2874
  name: "closeIcon",
2852
2875
  fn: withCtx(() => [
2853
- createVNode(_sfc_main$7, {
2876
+ createVNode(CloseIcon, {
2854
2877
  canFullscreen: unref$1(getBindValue).canFullscreen,
2855
2878
  fullScreen: unref$1(fullScreenRef),
2856
2879
  onCancel: handleCancel,
@@ -2869,8 +2892,8 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent$1({
2869
2892
  !_ctx.$slots.footer ? {
2870
2893
  name: "footer",
2871
2894
  fn: withCtx(() => [
2872
- createVNode(_sfc_main$2, {
2873
- buttons: unref$1(propsRef)?.footer,
2895
+ createVNode(ModalFooter, {
2896
+ buttons: propsRef.value?.footer,
2874
2897
  showSave: unref$1(getBindValue).showOkBtn,
2875
2898
  showCancel: unref$1(getBindValue).showCancelBtn,
2876
2899
  okText: unref$1(getBindValue).okText,
@@ -2902,6 +2925,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent$1({
2902
2925
  };
2903
2926
  }
2904
2927
  });
2928
+ const DtModal$1 = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/modal/src/index.vue"]]);
2905
2929
  const basicProps = {
2906
2930
  title: {
2907
2931
  type: Object
@@ -2912,7 +2936,7 @@ const basicProps = {
2912
2936
  },
2913
2937
  schemas: {
2914
2938
  type: Array,
2915
- default: []
2939
+ default: () => []
2916
2940
  },
2917
2941
  footer: {
2918
2942
  type: Array,
@@ -2939,33 +2963,30 @@ const basicProps = {
2939
2963
  },
2940
2964
  onSave: {
2941
2965
  type: Function,
2942
- default: () => {
2943
- }
2966
+ default: () => ({})
2944
2967
  },
2945
2968
  onDeletes: {
2946
2969
  type: Function,
2947
- default: (keys) => {
2948
- }
2970
+ default: (keys) => ({})
2949
2971
  },
2950
2972
  onQueryById: {
2951
2973
  type: Function,
2952
- default: (id) => {
2953
- }
2974
+ default: (id) => ({})
2954
2975
  },
2955
2976
  onRegister: {
2956
- type: Object
2977
+ type: Function
2957
2978
  },
2958
2979
  registerInstance: {
2959
2980
  type: Function
2960
2981
  }
2961
2982
  };
2962
- const _sfc_main = /* @__PURE__ */ defineComponent$1({
2983
+ const _sfc_main = /* @__PURE__ */ defineComponent({
2963
2984
  __name: "Curd",
2964
2985
  props: basicProps,
2965
2986
  setup(__props) {
2966
2987
  const props = __props;
2967
- const [registerDialog, { setModalProps }] = useModal({
2968
- ...omit(toRaw(props), [
2988
+ const [registerDialog] = useModal({
2989
+ ...omit(toRaw$1(props), [
2969
2990
  "curd",
2970
2991
  "formProps",
2971
2992
  "schemas"
@@ -2976,7 +2997,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent$1({
2976
2997
  props?.onSave();
2977
2998
  }
2978
2999
  return (_ctx, _cache) => {
2979
- return openBlock(), createBlock(unref$1(_sfc_main$1), {
3000
+ return openBlock(), createBlock(unref$1(DtModal$1), {
2980
3001
  onRegister: unref$1(registerDialog),
2981
3002
  onSave: _cache[0] || (_cache[0] = ($event) => handleSave())
2982
3003
  }, {
@@ -2988,6 +3009,7 @@ const _sfc_main = /* @__PURE__ */ defineComponent$1({
2988
3009
  };
2989
3010
  }
2990
3011
  });
3012
+ const DtModal = /* @__PURE__ */ _export_sfc(_sfc_main, [["__file", "D:/dt/dt-frame-front/dt-frames/frames/packages/ui/src/components/curd/src/components/Curd.vue"]]);
2991
3013
  function useCurd(curdOpt) {
2992
3014
  const [register, {
2993
3015
  openModal,
@@ -3015,7 +3037,7 @@ function useCurd(curdOpt) {
3015
3037
  const DtCurdModal = () => {
3016
3038
  return h(createVNode("div", {
3017
3039
  "class": "dt-curd-modal"
3018
- }, [createVNode(_sfc_main, mergeProps(curdOpt, {
3040
+ }, [createVNode(DtModal, mergeProps(curdOpt, {
3019
3041
  "title": title,
3020
3042
  "onRegister": register
3021
3043
  }), {