@aplus-frontend/ui 7.13.8 → 7.13.10
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.
- package/es/src/ag-grid/components/body-cell/index.vue2.mjs +7 -7
- package/es/src/ag-grid/components/empty/index.vue2.mjs +10 -10
- package/es/src/ag-grid/components/header-cell/index.vue2.mjs +37 -37
- package/es/src/ag-grid/components/row/index.vue2.mjs +5 -5
- package/es/src/ag-grid/components/tooltip/index.vue2.mjs +12 -12
- package/es/src/ag-grid/editable/form-item.vue.mjs +49 -49
- package/es/src/ag-grid/editable/index.vue.mjs +27 -27
- package/es/src/ag-grid/hooks/use-columns.d.ts +2 -0
- package/es/src/ag-grid/hooks/use-columns.mjs +35 -17
- package/es/src/ag-grid/index.vue.mjs +349 -318
- package/es/src/ap-action/group/index.vue.mjs +15 -15
- package/es/src/ap-action/item/index.vue2.mjs +28 -28
- package/es/src/ap-action/item-dropdown/index.vue.mjs +39 -39
- package/es/src/ap-field/checkbox/index.vue.mjs +19 -19
- package/es/src/ap-field/checkbox/read.vue2.mjs +9 -9
- package/es/src/ap-field/date/index.vue.mjs +50 -50
- package/es/src/ap-field/date/read.vue2.mjs +7 -7
- package/es/src/ap-field/date-range/index.vue.mjs +29 -29
- package/es/src/ap-field/date-range/read.vue2.mjs +22 -22
- package/es/src/ap-field/hooks/use-default-presets.mjs +59 -16
- package/es/src/ap-field/interface.d.ts +46 -1
- package/es/src/ap-field/number/index.vue.mjs +24 -24
- package/es/src/ap-field/radio/index.vue.mjs +24 -24
- package/es/src/ap-field/second/index.vue.mjs +15 -15
- package/es/src/ap-field/second/read.vue2.mjs +7 -7
- package/es/src/ap-field/segmented/index.vue.mjs +24 -24
- package/es/src/ap-field/select/index.vue.d.ts +12 -2
- package/es/src/ap-field/select/index.vue.mjs +127 -124
- package/es/src/ap-field/select/read.vue2.mjs +6 -6
- package/es/src/ap-field/slider/index.vue.mjs +11 -11
- package/es/src/ap-field/style/select.mjs +53 -36
- package/es/src/ap-field/switch/index.vue.mjs +45 -45
- package/es/src/ap-field/text/read-password.vue2.mjs +13 -13
- package/es/src/ap-field/text/read.vue2.mjs +3 -3
- package/es/src/ap-field/text-area/index.vue.mjs +29 -29
- package/es/src/ap-field/text-area/read.vue2.mjs +12 -12
- package/es/src/ap-field/tree-select/index.vue.mjs +31 -31
- package/es/src/ap-form/ap-form.vue2.mjs +46 -46
- package/es/src/ap-form/drawer-form/index.vue.mjs +30 -30
- package/es/src/ap-form/item/index.vue.mjs +75 -75
- package/es/src/ap-form/items/checkbox/index.vue.mjs +10 -10
- package/es/src/ap-form/items/number/index.vue.mjs +17 -17
- package/es/src/ap-form/items/radio/index.vue.mjs +13 -13
- package/es/src/ap-form/items/switch/index.vue.mjs +14 -14
- package/es/src/ap-form/items/text/index.vue2.mjs +26 -26
- package/es/src/ap-form/items/text/password.vue.mjs +19 -19
- package/es/src/ap-form/items/text-area/index.vue.mjs +17 -17
- package/es/src/ap-form/modal-form/index.vue.mjs +34 -34
- package/es/src/ap-form/search-form/components/popover-filter.vue2.mjs +39 -39
- package/es/src/ap-form/search-form/components/popover-sorter/sortable-item.vue2.mjs +7 -7
- package/es/src/ap-grid/editable/form-item.vue.mjs +46 -46
- package/es/src/ap-grid/editable/index.vue.mjs +19 -19
- package/es/src/ap-grid/index.vue.mjs +212 -212
- package/es/src/ap-list/index.vue.mjs +116 -116
- package/es/src/ap-table/ap-table.vue2.mjs +217 -217
- package/es/src/ap-table/components/index/index.vue2.mjs +9 -9
- package/es/src/ap-table/components/setting/modal/index.vue2.mjs +52 -51
- package/es/src/ap-table/components/setting/select-group/index.vue2.mjs +21 -21
- package/es/src/ap-table/components/setting/sortable/index.vue2.mjs +15 -15
- package/es/src/ap-table/components/setting/sortable/item.vue2.mjs +69 -69
- package/es/src/ap-table/components/setting/template/edit-form.vue.d.ts +1 -0
- package/es/src/ap-table/components/setting/template/edit-form.vue2.mjs +31 -30
- package/es/src/ap-table/components/setting/template/index.vue2.mjs +25 -25
- package/es/src/ap-table/components/setting/template/item.vue2.mjs +41 -40
- package/es/src/ap-table/components/setting/tree-select/index.vue2.mjs +14 -14
- package/es/src/ap-table/hooks/use-sorted-filtered.d.ts +18 -2
- package/es/src/ap-table/hooks/use-sorted-filtered.mjs +13 -11
- package/es/src/ap-table/hooks/use-table-paging-ng.d.ts +17 -2
- package/es/src/ap-table/hooks/use-table-paging-ng.mjs +148 -142
- package/es/src/ap-table/style/setting.mjs +2 -2
- package/es/src/business/ag-grid-modal/modal-layout/index.vue2.mjs +54 -54
- package/es/src/business/ag-grid-modal/selected-items/default.vue2.mjs +13 -13
- package/es/src/business/ag-grid-modal/wrapper/index.vue2.mjs +20 -20
- package/es/src/business/ap-descriptions/ap-descriptions.vue.mjs +33 -33
- package/es/src/business/ap-descriptions/help-message/index.vue2.mjs +13 -13
- package/es/src/business/ap-download/ap-download.vue.mjs +24 -24
- package/es/src/business/ap-expand-alert/ApExpandAlert.vue.mjs +77 -77
- package/es/src/business/ap-export-group/ApExportGroup.vue2.mjs +119 -112
- package/es/src/business/ap-export-group/handleExportDownload.d.ts +1 -1
- package/es/src/business/ap-export-group/handleExportDownload.mjs +2 -2
- package/es/src/business/ap-export-group/interface.d.ts +9 -0
- package/es/src/business/ap-radio-group/ap-radio-group.vue2.mjs +33 -33
- package/es/src/business/ap-status/group/ApStatusGroup.vue2.mjs +12 -12
- package/es/src/business/ap-table-modal/table-layout/index.vue2.mjs +43 -43
- package/es/src/business/ap-table-modal/table-modal.vue2.mjs +57 -57
- package/es/src/business/ap-tag/ap-tag-group.vue.mjs +37 -37
- package/es/src/business/ap-tag/ap-tag.vue.mjs +24 -24
- package/es/src/business/ap-title/ApTitle.vue2.mjs +27 -27
- package/es/src/business/ap-value-select-card/index.vue2.mjs +98 -98
- package/es/src/business/ap-view/components/main-button-content.vue.d.ts +1 -1
- package/es/src/business/batch-input-group/form-item.vue.mjs +25 -25
- package/es/src/business/batch-input-group/index.vue.mjs +60 -60
- package/es/src/business/batch-input-group/popover-input/index.vue2.mjs +29 -29
- package/es/src/config-provider/config-provider-props.d.ts +1 -1
- package/es/src/config-provider/config-provider.d.ts +3 -0
- package/es/src/config-provider/hooks/use-global-config.d.ts +1 -0
- package/es/src/config-provider/index.d.ts +6 -0
- package/es/src/editable-table/form-item.vue.mjs +35 -35
- package/es/src/editable-table/index.vue.mjs +19 -19
- package/es/src/full-screen/index.vue.mjs +46 -46
- package/es/src/locale/lang/en.mjs +2 -1
- package/es/src/locale/lang/zh-cn.mjs +2 -1
- package/es/src/mask/index.vue.mjs +48 -48
- package/es/src/portal/index.vue.mjs +5 -5
- package/es/src/scroll-bar/internal.vue.mjs +62 -62
- package/es/src/scroll-view/index.vue.mjs +66 -66
- package/es/src/skeleton/components/desc/index.vue2.mjs +9 -9
- package/es/src/skeleton/components/desc/item-large.vue2.mjs +25 -25
- package/es/src/skeleton/components/desc/item.vue2.mjs +13 -13
- package/es/src/skeleton/components/list/index.vue2.mjs +14 -14
- package/es/src/skeleton/components/list/item.vue2.mjs +12 -12
- package/es/src/skeleton/components/page-header/index.vue2.mjs +8 -8
- package/es/src/skeleton/components/search-form/index.vue2.mjs +35 -35
- package/es/src/skeleton/components/table/index.vue2.mjs +17 -17
- package/es/src/skeleton/components/table/item.vue2.mjs +23 -23
- package/es/src/skeleton/descriptions.vue2.mjs +15 -15
- package/es/src/skeleton/list-page.vue2.mjs +12 -12
- package/es/src/splitter/Panel.vue2.mjs +11 -11
- package/es/src/splitter/SplitBar.vue2.mjs +79 -79
- package/es/src/splitter/Splitter.vue2.mjs +50 -50
- package/es/src/text/group.vue.mjs +8 -8
- package/es/src/text/index.vue.mjs +48 -48
- package/es/src/version.d.ts +1 -1
- package/es/src/version.mjs +1 -1
- package/lib/src/ag-grid/components/body-cell/index.vue2.js +1 -1
- package/lib/src/ag-grid/components/empty/index.vue2.js +1 -1
- package/lib/src/ag-grid/components/header-cell/index.vue2.js +1 -1
- package/lib/src/ag-grid/components/row/index.vue2.js +1 -1
- package/lib/src/ag-grid/components/tooltip/index.vue2.js +1 -1
- package/lib/src/ag-grid/editable/form-item.vue.js +1 -1
- package/lib/src/ag-grid/editable/index.vue.js +1 -1
- package/lib/src/ag-grid/hooks/use-columns.d.ts +2 -0
- package/lib/src/ag-grid/hooks/use-columns.js +1 -1
- package/lib/src/ag-grid/index.vue.js +1 -1
- package/lib/src/ap-action/group/index.vue.js +1 -1
- package/lib/src/ap-action/item/index.vue2.js +1 -1
- package/lib/src/ap-action/item-dropdown/index.vue.js +1 -1
- package/lib/src/ap-field/checkbox/index.vue.js +1 -1
- package/lib/src/ap-field/checkbox/read.vue2.js +1 -1
- package/lib/src/ap-field/date/index.vue.js +1 -1
- package/lib/src/ap-field/date/read.vue2.js +1 -1
- package/lib/src/ap-field/date-range/index.vue.js +1 -1
- package/lib/src/ap-field/date-range/read.vue2.js +1 -1
- package/lib/src/ap-field/hooks/use-default-presets.js +1 -1
- package/lib/src/ap-field/interface.d.ts +46 -1
- package/lib/src/ap-field/number/index.vue.js +1 -1
- package/lib/src/ap-field/radio/index.vue.js +1 -1
- package/lib/src/ap-field/second/index.vue.js +1 -1
- package/lib/src/ap-field/second/read.vue2.js +1 -1
- package/lib/src/ap-field/segmented/index.vue.js +1 -1
- package/lib/src/ap-field/select/index.vue.d.ts +12 -2
- package/lib/src/ap-field/select/index.vue.js +1 -1
- package/lib/src/ap-field/select/read.vue2.js +1 -1
- package/lib/src/ap-field/slider/index.vue.js +1 -1
- package/lib/src/ap-field/style/select.js +1 -1
- package/lib/src/ap-field/switch/index.vue.js +1 -1
- package/lib/src/ap-field/text/read-password.vue2.js +1 -1
- package/lib/src/ap-field/text/read.vue2.js +1 -1
- package/lib/src/ap-field/text-area/index.vue.js +1 -1
- package/lib/src/ap-field/text-area/read.vue2.js +1 -1
- package/lib/src/ap-field/tree-select/index.vue.js +1 -1
- package/lib/src/ap-form/ap-form.vue2.js +1 -1
- package/lib/src/ap-form/drawer-form/index.vue.js +1 -1
- package/lib/src/ap-form/item/index.vue.js +1 -1
- package/lib/src/ap-form/items/checkbox/index.vue.js +1 -1
- package/lib/src/ap-form/items/number/index.vue.js +1 -1
- package/lib/src/ap-form/items/radio/index.vue.js +1 -1
- package/lib/src/ap-form/items/switch/index.vue.js +1 -1
- package/lib/src/ap-form/items/text/index.vue2.js +1 -1
- package/lib/src/ap-form/items/text/password.vue.js +1 -1
- package/lib/src/ap-form/items/text-area/index.vue.js +1 -1
- package/lib/src/ap-form/modal-form/index.vue.js +1 -1
- package/lib/src/ap-form/search-form/components/popover-filter.vue2.js +1 -1
- package/lib/src/ap-form/search-form/components/popover-sorter/sortable-item.vue2.js +1 -1
- package/lib/src/ap-grid/editable/form-item.vue.js +1 -1
- package/lib/src/ap-grid/editable/index.vue.js +1 -1
- package/lib/src/ap-grid/index.vue.js +1 -1
- package/lib/src/ap-list/index.vue.js +1 -1
- package/lib/src/ap-table/ap-table.vue2.js +1 -1
- package/lib/src/ap-table/components/index/index.vue2.js +1 -1
- package/lib/src/ap-table/components/setting/modal/index.vue2.js +1 -1
- package/lib/src/ap-table/components/setting/select-group/index.vue2.js +1 -1
- package/lib/src/ap-table/components/setting/sortable/index.vue2.js +1 -1
- package/lib/src/ap-table/components/setting/sortable/item.vue2.js +1 -1
- package/lib/src/ap-table/components/setting/template/edit-form.vue.d.ts +1 -0
- package/lib/src/ap-table/components/setting/template/edit-form.vue2.js +1 -1
- package/lib/src/ap-table/components/setting/template/index.vue2.js +1 -1
- package/lib/src/ap-table/components/setting/template/item.vue2.js +1 -1
- package/lib/src/ap-table/components/setting/tree-select/index.vue2.js +1 -1
- package/lib/src/ap-table/hooks/use-sorted-filtered.d.ts +18 -2
- package/lib/src/ap-table/hooks/use-sorted-filtered.js +1 -1
- package/lib/src/ap-table/hooks/use-table-paging-ng.d.ts +17 -2
- package/lib/src/ap-table/hooks/use-table-paging-ng.js +1 -1
- package/lib/src/ap-table/style/setting.js +1 -1
- package/lib/src/business/ag-grid-modal/modal-layout/index.vue2.js +1 -1
- package/lib/src/business/ag-grid-modal/selected-items/default.vue2.js +1 -1
- package/lib/src/business/ag-grid-modal/wrapper/index.vue2.js +1 -1
- package/lib/src/business/ap-descriptions/ap-descriptions.vue.js +1 -1
- package/lib/src/business/ap-descriptions/help-message/index.vue2.js +1 -1
- package/lib/src/business/ap-download/ap-download.vue.js +1 -1
- package/lib/src/business/ap-expand-alert/ApExpandAlert.vue.js +1 -1
- package/lib/src/business/ap-export-group/ApExportGroup.vue2.js +1 -1
- package/lib/src/business/ap-export-group/handleExportDownload.d.ts +1 -1
- package/lib/src/business/ap-export-group/handleExportDownload.js +1 -1
- package/lib/src/business/ap-export-group/interface.d.ts +9 -0
- package/lib/src/business/ap-radio-group/ap-radio-group.vue2.js +1 -1
- package/lib/src/business/ap-status/group/ApStatusGroup.vue2.js +1 -1
- package/lib/src/business/ap-table-modal/table-layout/index.vue2.js +1 -1
- package/lib/src/business/ap-table-modal/table-modal.vue2.js +1 -1
- package/lib/src/business/ap-tag/ap-tag-group.vue.js +1 -1
- package/lib/src/business/ap-tag/ap-tag.vue.js +1 -1
- package/lib/src/business/ap-title/ApTitle.vue2.js +1 -1
- package/lib/src/business/ap-value-select-card/index.vue2.js +1 -1
- package/lib/src/business/ap-view/components/main-button-content.vue.d.ts +1 -1
- package/lib/src/business/batch-input-group/form-item.vue.js +1 -1
- package/lib/src/business/batch-input-group/index.vue.js +2 -2
- package/lib/src/business/batch-input-group/popover-input/index.vue2.js +2 -2
- package/lib/src/config-provider/config-provider-props.d.ts +1 -1
- package/lib/src/config-provider/config-provider.d.ts +3 -0
- package/lib/src/config-provider/hooks/use-global-config.d.ts +1 -0
- package/lib/src/config-provider/index.d.ts +6 -0
- package/lib/src/editable-table/form-item.vue.js +1 -1
- package/lib/src/editable-table/index.vue.js +1 -1
- package/lib/src/full-screen/index.vue.js +1 -1
- package/lib/src/locale/lang/en.js +1 -1
- package/lib/src/locale/lang/zh-cn.js +1 -1
- package/lib/src/mask/index.vue.js +1 -1
- package/lib/src/portal/index.vue.js +1 -1
- package/lib/src/scroll-bar/internal.vue.js +1 -1
- package/lib/src/scroll-view/index.vue.js +1 -1
- package/lib/src/skeleton/components/desc/index.vue2.js +1 -1
- package/lib/src/skeleton/components/desc/item-large.vue2.js +1 -1
- package/lib/src/skeleton/components/desc/item.vue2.js +1 -1
- package/lib/src/skeleton/components/list/index.vue2.js +1 -1
- package/lib/src/skeleton/components/list/item.vue2.js +1 -1
- package/lib/src/skeleton/components/page-header/index.vue2.js +1 -1
- package/lib/src/skeleton/components/search-form/index.vue2.js +1 -1
- package/lib/src/skeleton/components/table/index.vue2.js +1 -1
- package/lib/src/skeleton/components/table/item.vue2.js +1 -1
- package/lib/src/skeleton/descriptions.vue2.js +1 -1
- package/lib/src/skeleton/list-page.vue2.js +1 -1
- package/lib/src/splitter/Panel.vue2.js +1 -1
- package/lib/src/splitter/SplitBar.vue2.js +1 -1
- package/lib/src/splitter/Splitter.vue2.js +1 -1
- package/lib/src/text/group.vue.js +1 -1
- package/lib/src/text/index.vue.js +1 -1
- package/lib/src/version.d.ts +1 -1
- package/lib/src/version.js +1 -1
- package/package.json +3 -3
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import { defineComponent as Y, reactive as Z, shallowRef as z, ref as ee, unref as g, nextTick as te, toRaw as U, watch as re, onWatcherCleanup as oe, computed as ne, createBlock as ie, openBlock as le, mergeProps as ae, withCtx as se, renderSlot as ue } from "vue";
|
|
2
|
-
import { Form as
|
|
3
|
-
import { useUrlSearchParams as
|
|
4
|
-
import { isArray as P, cloneDeep as
|
|
5
|
-
import { useDevWarning as
|
|
6
|
-
import { getRouteType as
|
|
2
|
+
import { Form as fe } from "@aplus-frontend/antdv";
|
|
3
|
+
import { useUrlSearchParams as ce } from "@vueuse/core";
|
|
4
|
+
import { isArray as P, cloneDeep as b, isEqual as de, omit as ge } from "lodash-unified";
|
|
5
|
+
import { useDevWarning as pe } from "../utils/warning.mjs";
|
|
6
|
+
import { getRouteType as me } from "../utils/index.mjs";
|
|
7
7
|
import { INTERNAL_FORM_INSTANCE_MARK as E } from "./constant.mjs";
|
|
8
8
|
import { useProvideForm as he } from "./context.mjs";
|
|
9
9
|
import { useInjectFormProvider as Fe } from "./provider/context.mjs";
|
|
10
|
-
import { getModelValue as
|
|
11
|
-
import { genParams as R, setToParams as
|
|
10
|
+
import { getModelValue as x } from "./utils/get.mjs";
|
|
11
|
+
import { genParams as R, setToParams as O } from "./utils/params.mjs";
|
|
12
12
|
import ye from "./utils/set.mjs";
|
|
13
13
|
import { transformValues as h } from "./utils/transform.mjs";
|
|
14
14
|
import { isDef as F } from "../utils/is.mjs";
|
|
15
|
-
const
|
|
15
|
+
const Ee = /* @__PURE__ */ Y({
|
|
16
16
|
name: "ApForm",
|
|
17
17
|
__name: "ap-form",
|
|
18
18
|
props: {
|
|
@@ -44,8 +44,8 @@ const xe = /* @__PURE__ */ Y({
|
|
|
44
44
|
syncToUrl: { type: [Boolean, Function], default: !1 },
|
|
45
45
|
syncToUrlPriority: { type: Boolean }
|
|
46
46
|
},
|
|
47
|
-
setup(
|
|
48
|
-
const r =
|
|
47
|
+
setup(W, { expose: j }) {
|
|
48
|
+
const r = W;
|
|
49
49
|
function y(e, t, o = !0, i) {
|
|
50
50
|
if (P(e)) {
|
|
51
51
|
let l = n;
|
|
@@ -54,20 +54,20 @@ const xe = /* @__PURE__ */ Y({
|
|
|
54
54
|
i ? i(l, e[e.length - 1]) : l[e[e.length - 1]] = t;
|
|
55
55
|
} else
|
|
56
56
|
i ? i(n, e) : n[e] = t;
|
|
57
|
-
let
|
|
57
|
+
let A = P(e) ? e[0] : e;
|
|
58
58
|
if (o) {
|
|
59
|
-
const l = { [
|
|
60
|
-
|
|
59
|
+
const l = { [A]: n[A] };
|
|
60
|
+
p.triggerFormChange(r.name, l), r.onValuesChange?.(l, n, e);
|
|
61
61
|
}
|
|
62
|
-
|
|
62
|
+
m();
|
|
63
63
|
}
|
|
64
|
-
const a = z(), T =
|
|
64
|
+
const a = z(), T = ce(me()), p = Fe(), k = pe("ApForm"), V = ee(
|
|
65
65
|
r.syncToUrl ? R(r.syncToUrl, T, "get") : {}
|
|
66
66
|
);
|
|
67
|
-
let s =
|
|
68
|
-
const n = Z(
|
|
69
|
-
let
|
|
70
|
-
function
|
|
67
|
+
let s = b(M()), u = {};
|
|
68
|
+
const n = Z(M());
|
|
69
|
+
let c = [];
|
|
70
|
+
function M() {
|
|
71
71
|
const e = r.initialValues || {};
|
|
72
72
|
return r.syncToUrlPriority ? {
|
|
73
73
|
...e,
|
|
@@ -81,20 +81,20 @@ const xe = /* @__PURE__ */ Y({
|
|
|
81
81
|
const t = h(
|
|
82
82
|
e,
|
|
83
83
|
u,
|
|
84
|
-
|
|
84
|
+
f
|
|
85
85
|
);
|
|
86
|
-
|
|
86
|
+
p.triggerFormFinish(r.name, e), r.syncToUrl && O(T, R(r.syncToUrl, t, "set")), r.onFinish?.(t);
|
|
87
87
|
}
|
|
88
88
|
const S = async () => {
|
|
89
89
|
a.value?.resetFields(), await te(() => {
|
|
90
|
-
Object.keys(n).forEach((e) => delete n[e]), Object.assign(n,
|
|
90
|
+
Object.keys(n).forEach((e) => delete n[e]), Object.assign(n, b(s)), m(), r.syncToUrl && O(
|
|
91
91
|
T,
|
|
92
92
|
R(
|
|
93
93
|
r.syncToUrl,
|
|
94
94
|
h(
|
|
95
95
|
s,
|
|
96
96
|
u,
|
|
97
|
-
|
|
97
|
+
f
|
|
98
98
|
),
|
|
99
99
|
"set"
|
|
100
100
|
)
|
|
@@ -110,21 +110,21 @@ const xe = /* @__PURE__ */ Y({
|
|
|
110
110
|
return h(
|
|
111
111
|
o,
|
|
112
112
|
u,
|
|
113
|
-
|
|
113
|
+
f
|
|
114
114
|
);
|
|
115
|
-
},
|
|
116
|
-
const t =
|
|
117
|
-
return h(t, u,
|
|
115
|
+
}, f = (e) => e === !0 ? U(n) : a.value?.getFieldsValue(e), L = (e) => {
|
|
116
|
+
const t = f(e);
|
|
117
|
+
return h(t, u, f);
|
|
118
118
|
}, $ = (e, t) => a.value?.validate(e, t), G = (e, t = {}) => {
|
|
119
119
|
a.value?.scrollToField(e, t);
|
|
120
120
|
}, H = (e) => {
|
|
121
|
-
Object.assign(n, e),
|
|
121
|
+
Object.assign(n, e), m();
|
|
122
122
|
}, v = (e, t, o = !0, i) => {
|
|
123
|
-
y(e, t, o, i),
|
|
123
|
+
y(e, t, o, i), m();
|
|
124
124
|
};
|
|
125
125
|
function C(e) {
|
|
126
|
-
return e(U(n)),
|
|
127
|
-
|
|
126
|
+
return e(U(n)), c.push(e), () => {
|
|
127
|
+
c = c.filter((t) => t !== e);
|
|
128
128
|
};
|
|
129
129
|
}
|
|
130
130
|
function I(e, t) {
|
|
@@ -139,10 +139,10 @@ const xe = /* @__PURE__ */ Y({
|
|
|
139
139
|
function J(e, t) {
|
|
140
140
|
if (!F(e) || !F(t))
|
|
141
141
|
return;
|
|
142
|
-
const o =
|
|
142
|
+
const o = x(s, t);
|
|
143
143
|
if (de(o, e))
|
|
144
144
|
return;
|
|
145
|
-
const i =
|
|
145
|
+
const i = x(g(V), t);
|
|
146
146
|
F(i) && r.syncToUrlPriority || (y(t, e, !1), I(t, e));
|
|
147
147
|
}
|
|
148
148
|
function Q(e, t) {
|
|
@@ -153,7 +153,7 @@ const xe = /* @__PURE__ */ Y({
|
|
|
153
153
|
!0
|
|
154
154
|
));
|
|
155
155
|
}
|
|
156
|
-
function
|
|
156
|
+
function B({ initialValue: e, name: t, transform: o }) {
|
|
157
157
|
J(e, t), Q(t, o);
|
|
158
158
|
}
|
|
159
159
|
function _() {
|
|
@@ -166,26 +166,26 @@ const xe = /* @__PURE__ */ Y({
|
|
|
166
166
|
"getInternalInstance should only used at internal"
|
|
167
167
|
), e === E)
|
|
168
168
|
return {
|
|
169
|
-
registerField:
|
|
169
|
+
registerField: B,
|
|
170
170
|
registerWatch: C,
|
|
171
171
|
setFieldValue: v,
|
|
172
172
|
getInitialValues: _,
|
|
173
173
|
updateInitialModel: I
|
|
174
174
|
};
|
|
175
175
|
}
|
|
176
|
-
function
|
|
177
|
-
if (
|
|
176
|
+
function m() {
|
|
177
|
+
if (c.length) {
|
|
178
178
|
const e = U(n);
|
|
179
|
-
|
|
179
|
+
c.forEach((t) => {
|
|
180
180
|
t(e);
|
|
181
181
|
});
|
|
182
182
|
}
|
|
183
183
|
}
|
|
184
|
-
const
|
|
184
|
+
const w = {
|
|
185
185
|
resetFields: S,
|
|
186
186
|
clearValidate: q,
|
|
187
187
|
validateFields: D,
|
|
188
|
-
getFieldsValue:
|
|
188
|
+
getFieldsValue: f,
|
|
189
189
|
validate: $,
|
|
190
190
|
scrollToField: G,
|
|
191
191
|
setFieldsValue: H,
|
|
@@ -198,8 +198,8 @@ const xe = /* @__PURE__ */ Y({
|
|
|
198
198
|
return re(
|
|
199
199
|
() => r.name,
|
|
200
200
|
(e) => {
|
|
201
|
-
e && (
|
|
202
|
-
|
|
201
|
+
e && (p.registerForm(e, w), oe(() => {
|
|
202
|
+
p.unregisterForm(r.name);
|
|
203
203
|
}));
|
|
204
204
|
},
|
|
205
205
|
{
|
|
@@ -210,12 +210,12 @@ const xe = /* @__PURE__ */ Y({
|
|
|
210
210
|
updateModel: y,
|
|
211
211
|
internalInstance: {
|
|
212
212
|
registerWatch: C,
|
|
213
|
-
registerField:
|
|
213
|
+
registerField: B,
|
|
214
214
|
setFieldValue: v,
|
|
215
215
|
getInitialValues: _,
|
|
216
216
|
updateInitialModel: I
|
|
217
217
|
}
|
|
218
|
-
}), j(
|
|
218
|
+
}), j(w), (e, t) => (le(), ie(g(fe), ae(
|
|
219
219
|
{
|
|
220
220
|
ref_key: "formRef",
|
|
221
221
|
ref: a
|
|
@@ -229,7 +229,7 @@ const xe = /* @__PURE__ */ Y({
|
|
|
229
229
|
]),
|
|
230
230
|
{
|
|
231
231
|
model: n,
|
|
232
|
-
"data-form-name":
|
|
232
|
+
"data-form-name": e.name,
|
|
233
233
|
onFinish: N
|
|
234
234
|
}
|
|
235
235
|
), {
|
|
@@ -241,5 +241,5 @@ const xe = /* @__PURE__ */ Y({
|
|
|
241
241
|
}
|
|
242
242
|
});
|
|
243
243
|
export {
|
|
244
|
-
|
|
244
|
+
Ee as default
|
|
245
245
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { isVNode as Q, defineComponent as Y, useSlots as Z, shallowRef as ee, ref as y, computed as w, unref as n, watch as P, cloneVNode as te, createVNode as
|
|
1
|
+
import { isVNode as Q, defineComponent as Y, useSlots as Z, shallowRef as ee, ref as y, computed as w, unref as n, watch as P, cloneVNode as te, createVNode as s, mergeProps as p, createElementBlock as N, openBlock as h, Fragment as ie, createBlock as S, createCommentVNode as M, withCtx as v, renderSlot as _, withModifiers as ne, normalizeClass as oe, resolveDynamicComponent as I, createTextVNode as ae, toDisplayString as se } from "vue";
|
|
2
2
|
import { Button as z, Flex as le, Space as re, Drawer as ue } from "@aplus-frontend/antdv";
|
|
3
3
|
import { isBoolean as de, isUndefined as me, omit as ce } from "lodash-unified";
|
|
4
4
|
import "../../config-provider/index.mjs";
|
|
@@ -11,8 +11,8 @@ import { useControllableValue as ve } from "../../hooks/useControllableValue.mjs
|
|
|
11
11
|
import { useLocale as be } from "../../config-provider/hooks/use-locale.mjs";
|
|
12
12
|
import { useNamespace as ge } from "../../config-provider/hooks/use-namespace.mjs";
|
|
13
13
|
import Fe from "../ap-form.vue2.mjs";
|
|
14
|
-
function
|
|
15
|
-
return typeof
|
|
14
|
+
function L(r) {
|
|
15
|
+
return typeof r == "function" || Object.prototype.toString.call(r) === "[object Object]" && !Q(r);
|
|
16
16
|
}
|
|
17
17
|
const De = /* @__PURE__ */ Y({
|
|
18
18
|
name: "ApFormDrawerForm",
|
|
@@ -97,17 +97,17 @@ const De = /* @__PURE__ */ Y({
|
|
|
97
97
|
}
|
|
98
98
|
},
|
|
99
99
|
emits: ["update:open"],
|
|
100
|
-
setup(
|
|
101
|
-
expose:
|
|
100
|
+
setup(r, {
|
|
101
|
+
expose: U,
|
|
102
102
|
emit: j
|
|
103
103
|
}) {
|
|
104
|
-
const t =
|
|
104
|
+
const t = r, b = Z(), E = j, o = ee(), d = y(), a = y(!1), {
|
|
105
105
|
value: C,
|
|
106
106
|
updateValue: m
|
|
107
107
|
} = ve(t, E, {
|
|
108
108
|
valuePropName: "open",
|
|
109
109
|
defaultValue: !1
|
|
110
|
-
}),
|
|
110
|
+
}), l = w(() => {
|
|
111
111
|
const e = {
|
|
112
112
|
onResize: () => {
|
|
113
113
|
},
|
|
@@ -128,17 +128,17 @@ const De = /* @__PURE__ */ Y({
|
|
|
128
128
|
e: q,
|
|
129
129
|
em: V
|
|
130
130
|
} = ge("ap-form-drawer-form"), A = w(() => [q("resize-bar"), {
|
|
131
|
-
[V("resize-bar", "min-disabled")]: n(u) === n(
|
|
131
|
+
[V("resize-bar", "min-disabled")]: n(u) === n(l).minWidth
|
|
132
132
|
}, {
|
|
133
|
-
[V("resize-bar", "max-disabled")]: n(u) === n(
|
|
133
|
+
[V("resize-bar", "max-disabled")]: n(u) === n(l).maxWidth
|
|
134
134
|
}]);
|
|
135
135
|
P(() => o.value, (e) => {
|
|
136
136
|
e && d.value && (e.setFieldsValue?.(d.value), d.value = void 0);
|
|
137
137
|
}), P(() => n(C), (e) => {
|
|
138
|
-
e && n(
|
|
138
|
+
e && n(l)?.resizeOnOpen && (u.value = T());
|
|
139
139
|
});
|
|
140
140
|
function T() {
|
|
141
|
-
const e = n(
|
|
141
|
+
const e = n(l)?.minWidth;
|
|
142
142
|
return !e || e && e < t.width ? t.width : e;
|
|
143
143
|
}
|
|
144
144
|
const R = pe(b.trigger), W = R ? te(R, {
|
|
@@ -151,20 +151,20 @@ const De = /* @__PURE__ */ Y({
|
|
|
151
151
|
return null;
|
|
152
152
|
if (t.showCancel) {
|
|
153
153
|
let i;
|
|
154
|
-
e.push(
|
|
154
|
+
e.push(s(z, {
|
|
155
155
|
onClick: k,
|
|
156
156
|
disabled: a.value
|
|
157
|
-
},
|
|
157
|
+
}, L(i = g("ap.common.cancelText")) ? i : {
|
|
158
158
|
default: () => [i]
|
|
159
159
|
}));
|
|
160
160
|
}
|
|
161
|
-
return t.submitter?.resetButtonProps !== !1 && e.push(
|
|
161
|
+
return t.submitter?.resetButtonProps !== !1 && e.push(s(z, p(t.submitter?.resetButtonProps || {}, {
|
|
162
162
|
key: "submit",
|
|
163
163
|
disabled: a.value,
|
|
164
164
|
onClick: H
|
|
165
165
|
}), {
|
|
166
166
|
default: () => [t.submitter?.resetText || g("ap.common.resetText")]
|
|
167
|
-
})), t.submitter?.submitButtonProps !== !1 && e.push(
|
|
167
|
+
})), t.submitter?.submitButtonProps !== !1 && e.push(s(z, p({
|
|
168
168
|
type: "primary",
|
|
169
169
|
key: "submit"
|
|
170
170
|
}, t.submitter?.submitButtonProps || {}, {
|
|
@@ -172,24 +172,24 @@ const De = /* @__PURE__ */ Y({
|
|
|
172
172
|
onClick: J
|
|
173
173
|
}), {
|
|
174
174
|
default: () => [t.submitter?.submitText || g("ap.common.okText")]
|
|
175
|
-
})),
|
|
175
|
+
})), s(le, {
|
|
176
176
|
justify: "flex-end"
|
|
177
177
|
}, {
|
|
178
|
-
default: () => [b.submitter ? b.submitter(e) :
|
|
178
|
+
default: () => [b.submitter ? b.submitter(e) : s(re, null, L(e) ? e : {
|
|
179
179
|
default: () => [e]
|
|
180
180
|
})]
|
|
181
181
|
});
|
|
182
182
|
});
|
|
183
183
|
function G() {
|
|
184
|
-
|
|
184
|
+
l.value?.onResize?.(), document.addEventListener("mousemove", B), document.addEventListener("mouseup", x);
|
|
185
185
|
}
|
|
186
|
-
function
|
|
187
|
-
const i = n(
|
|
186
|
+
function B(e) {
|
|
187
|
+
const i = n(l), c = (document.body.offsetWidth || 1e3) - (e.clientX - document.body.offsetLeft), f = i?.minWidth ?? (t.width || 800), O = i?.maxWidth ?? window.innerWidth * 0.8;
|
|
188
188
|
let F = c;
|
|
189
189
|
c < f && (F = f), c > O && (F = O), u.value = F;
|
|
190
190
|
}
|
|
191
|
-
function
|
|
192
|
-
document.removeEventListener("mousemove",
|
|
191
|
+
function x() {
|
|
192
|
+
document.removeEventListener("mousemove", B), document.removeEventListener("mouseup", x);
|
|
193
193
|
}
|
|
194
194
|
function H() {
|
|
195
195
|
t.submitter !== !1 && (o.value?.resetFields(), t.submitter?.onReset?.());
|
|
@@ -217,7 +217,7 @@ const De = /* @__PURE__ */ Y({
|
|
|
217
217
|
function K(e) {
|
|
218
218
|
!e && n(a) || m(e);
|
|
219
219
|
}
|
|
220
|
-
return
|
|
220
|
+
return U({
|
|
221
221
|
resetFields: async () => {
|
|
222
222
|
o.value?.resetFields();
|
|
223
223
|
},
|
|
@@ -243,28 +243,28 @@ const De = /* @__PURE__ */ Y({
|
|
|
243
243
|
getInternalInstance: (e) => o.value?.getInternalInstance(e),
|
|
244
244
|
getFieldsValueTransformed: (e) => o.value?.getFieldsValueTransformed(e),
|
|
245
245
|
validateFieldsReturnTransformed: (e) => o.value?.validateFieldsReturnTransformed(e)
|
|
246
|
-
}), (e, i) => (h(), N(ie, null, [
|
|
246
|
+
}), (e, i) => (h(), N(ie, null, [s(n(ue), p(e.drawerProps, {
|
|
247
247
|
open: n(C),
|
|
248
248
|
width: u.value,
|
|
249
249
|
class: [n($)(), n(D)],
|
|
250
250
|
"onUpdate:open": K,
|
|
251
251
|
onCancel: k
|
|
252
252
|
}), {
|
|
253
|
-
title: v(() => [
|
|
254
|
-
footer: v(() => [(h(), S(
|
|
255
|
-
default: v(() => [
|
|
253
|
+
title: v(() => [_(e.$slots, "title", {}, () => [ae(se(t.title), 1)])]),
|
|
254
|
+
footer: v(() => [(h(), S(I(X.value)))]),
|
|
255
|
+
default: v(() => [s(Fe, p({
|
|
256
256
|
ref_key: "formRef",
|
|
257
257
|
ref: o
|
|
258
258
|
}, n(ce)(t, ["drawerProps", "open", "onUpdate:open", "title", "width", "onFinish", "submitter"])), {
|
|
259
|
-
default: v(() => [
|
|
259
|
+
default: v(() => [_(e.$slots, "default")]),
|
|
260
260
|
_: 3
|
|
261
|
-
}, 16),
|
|
261
|
+
}, 16), e.resize ? (h(), N("div", {
|
|
262
262
|
key: 0,
|
|
263
263
|
class: oe(A.value),
|
|
264
264
|
onMousedown: ne(G, ["stop", "prevent"])
|
|
265
265
|
}, null, 34)) : M("", !0)]),
|
|
266
266
|
_: 3
|
|
267
|
-
}, 16, ["open", "width", "class"]), n(W) ? (h(), S(
|
|
267
|
+
}, 16, ["open", "width", "class"]), n(W) ? (h(), S(I(n(W)), {
|
|
268
268
|
key: 0
|
|
269
269
|
})) : M("", !0)], 64));
|
|
270
270
|
}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { defineComponent as L, useSlots as
|
|
2
|
-
import { QuestionCircleOutlined as
|
|
1
|
+
import { defineComponent as L, useSlots as _, ref as j, shallowRef as E, onMounted as M, computed as O, unref as r, cloneVNode as $, createBlock as y, openBlock as b, mergeProps as q, createSlots as K, withCtx as i, resolveDynamicComponent as Q, renderList as U, createElementVNode as Y, normalizeClass as G, createVNode as f, normalizeStyle as H, renderSlot as J, normalizeProps as W, guardReactiveProps as X } from "vue";
|
|
2
|
+
import { QuestionCircleOutlined as Z } from "@ant-design/icons-vue";
|
|
3
3
|
import { Form as ee, Tooltip as oe, TypographyText as te } from "@aplus-frontend/antdv";
|
|
4
|
-
import { useToken as
|
|
5
|
-
import { isFunction as
|
|
4
|
+
import { useToken as re } from "@aplus-frontend/antdv/es/theme/internal";
|
|
5
|
+
import { isFunction as v, cloneDeep as le, isArray as ae, omit as F } from "lodash-unified";
|
|
6
6
|
import { isPromise as ne } from "../../utils/is.mjs";
|
|
7
7
|
import "../../config-provider/index.mjs";
|
|
8
8
|
import { getValidVNodeList as ie } from "../../utils/slot.mjs";
|
|
@@ -10,7 +10,7 @@ import { apFormItemColPropKeys as se } from "../constant.mjs";
|
|
|
10
10
|
import { useInjectForm as ue } from "../context.mjs";
|
|
11
11
|
import de from "../style/item.mjs";
|
|
12
12
|
import { useNamespace as fe } from "../../config-provider/hooks/use-namespace.mjs";
|
|
13
|
-
const
|
|
13
|
+
const ke = /* @__PURE__ */ L({
|
|
14
14
|
name: "ApFormItem",
|
|
15
15
|
__name: "index",
|
|
16
16
|
props: {
|
|
@@ -57,69 +57,69 @@ const Ce = /* @__PURE__ */ L({
|
|
|
57
57
|
customFilled: {},
|
|
58
58
|
disabled: { type: Boolean }
|
|
59
59
|
},
|
|
60
|
-
setup(
|
|
61
|
-
const
|
|
62
|
-
|
|
63
|
-
let
|
|
64
|
-
ne(
|
|
65
|
-
name:
|
|
66
|
-
initialValue:
|
|
67
|
-
transform:
|
|
60
|
+
setup(V, { expose: h }) {
|
|
61
|
+
const o = V, m = _(), { model: p, updateModel: g, internalInstance: B } = ue(), { m: u, b: C } = fe("ap-form-item"), k = de("ap-form-item"), d = j(!1), n = E(), [, P] = re();
|
|
62
|
+
M(async () => {
|
|
63
|
+
let e = v(o.initialValue) ? o.initialValue() : o.initialValue;
|
|
64
|
+
ne(e) && (e = await e), B?.registerField({
|
|
65
|
+
name: o.name,
|
|
66
|
+
initialValue: le(e),
|
|
67
|
+
transform: o.transform
|
|
68
68
|
});
|
|
69
69
|
});
|
|
70
|
-
const
|
|
71
|
-
function
|
|
72
|
-
const
|
|
73
|
-
return
|
|
74
|
-
|
|
75
|
-
}),
|
|
70
|
+
const c = O(() => o.name ? ae(o.name) ? o.name.reduce((e, t) => e?.[t], r(p)) : p?.value[o.name] : null);
|
|
71
|
+
function x(e, t) {
|
|
72
|
+
const l = Object.keys(t), a = { ...t };
|
|
73
|
+
return l.forEach((s) => {
|
|
74
|
+
s in e || delete a[s];
|
|
75
|
+
}), a;
|
|
76
76
|
}
|
|
77
77
|
function N() {
|
|
78
|
-
const
|
|
79
|
-
if (!
|
|
80
|
-
return
|
|
81
|
-
const t = ie(
|
|
78
|
+
const e = m.default?.() || [];
|
|
79
|
+
if (!o.name)
|
|
80
|
+
return e[0];
|
|
81
|
+
const t = ie(e)[0];
|
|
82
82
|
if (!t)
|
|
83
83
|
return null;
|
|
84
|
-
const
|
|
85
|
-
variant:
|
|
86
|
-
bordered:
|
|
84
|
+
const l = t?.type?.props ?? {}, a = {
|
|
85
|
+
variant: o.bordered ? "borderless" : t?.props?.variant,
|
|
86
|
+
bordered: o.bordered ? !1 : t?.props?.bordered,
|
|
87
87
|
onFocus: S,
|
|
88
88
|
onBlur: T
|
|
89
89
|
};
|
|
90
|
-
return
|
|
91
|
-
...
|
|
92
|
-
[
|
|
93
|
-
[`onUpdate:${
|
|
90
|
+
return $(t, {
|
|
91
|
+
...x(l, a),
|
|
92
|
+
[o.valuePropName]: r(c),
|
|
93
|
+
[`onUpdate:${o.valuePropName}`]: I
|
|
94
94
|
});
|
|
95
95
|
}
|
|
96
|
-
function I(
|
|
97
|
-
|
|
96
|
+
function I(e) {
|
|
97
|
+
g?.(o.name, e);
|
|
98
98
|
}
|
|
99
99
|
function S() {
|
|
100
|
-
|
|
100
|
+
d.value = !0;
|
|
101
101
|
}
|
|
102
102
|
function T() {
|
|
103
|
-
|
|
103
|
+
d.value = !1;
|
|
104
104
|
}
|
|
105
105
|
function w() {
|
|
106
|
-
|
|
106
|
+
n.value?.onFieldBlur();
|
|
107
107
|
}
|
|
108
108
|
function R() {
|
|
109
|
-
|
|
109
|
+
n.value?.onFieldChange();
|
|
110
110
|
}
|
|
111
111
|
function z() {
|
|
112
|
-
|
|
112
|
+
n.value?.clearValidate();
|
|
113
113
|
}
|
|
114
114
|
function A() {
|
|
115
|
-
|
|
115
|
+
n.value?.resetField();
|
|
116
116
|
}
|
|
117
|
-
function D(
|
|
118
|
-
const t =
|
|
119
|
-
if (!
|
|
117
|
+
function D(e = !1) {
|
|
118
|
+
const t = r(c);
|
|
119
|
+
if (!e || !o.transform)
|
|
120
120
|
return t;
|
|
121
|
-
const
|
|
122
|
-
return
|
|
121
|
+
const l = v(o.transform) ? o.transform : o.transform.transformer;
|
|
122
|
+
return o.transform ? l(t) : t;
|
|
123
123
|
}
|
|
124
124
|
return h({
|
|
125
125
|
onFieldBlur: w,
|
|
@@ -127,41 +127,41 @@ const Ce = /* @__PURE__ */ L({
|
|
|
127
127
|
clearValidate: z,
|
|
128
128
|
resetField: A,
|
|
129
129
|
getFieldValue: D
|
|
130
|
-
}), (
|
|
130
|
+
}), (e, t) => (b(), y(r(ee).Item, q(
|
|
131
131
|
{
|
|
132
132
|
ref_key: "formItemRef",
|
|
133
|
-
ref:
|
|
133
|
+
ref: n
|
|
134
134
|
},
|
|
135
|
-
|
|
135
|
+
r(F)(o, [...r(se), "tooltip", "label", "description"]),
|
|
136
136
|
{
|
|
137
137
|
class: {
|
|
138
|
-
[
|
|
139
|
-
[
|
|
140
|
-
[
|
|
141
|
-
[
|
|
142
|
-
[
|
|
138
|
+
[r(u)("bordered")]: e.bordered,
|
|
139
|
+
[r(u)("focused")]: e.bordered && d.value,
|
|
140
|
+
[r(u)("disabled")]: e.bordered && e.disabled,
|
|
141
|
+
[r(C)()]: !0,
|
|
142
|
+
[r(k)]: !0
|
|
143
143
|
},
|
|
144
|
-
colon:
|
|
144
|
+
colon: e.bordered ? !1 : o.colon
|
|
145
145
|
}
|
|
146
|
-
),
|
|
147
|
-
default:
|
|
148
|
-
(
|
|
146
|
+
), K({
|
|
147
|
+
default: i(() => [
|
|
148
|
+
(b(), y(Q(N())))
|
|
149
149
|
]),
|
|
150
150
|
_: 2
|
|
151
151
|
}, [
|
|
152
|
-
|
|
152
|
+
o.tooltip ? {
|
|
153
153
|
name: "tooltip",
|
|
154
|
-
fn:
|
|
155
|
-
|
|
156
|
-
class:
|
|
154
|
+
fn: i(({ class: l }) => [
|
|
155
|
+
Y("span", {
|
|
156
|
+
class: G(l)
|
|
157
157
|
}, [
|
|
158
|
-
|
|
159
|
-
title:
|
|
158
|
+
f(r(oe), {
|
|
159
|
+
title: o.tooltip
|
|
160
160
|
}, {
|
|
161
|
-
default:
|
|
162
|
-
|
|
163
|
-
style:
|
|
164
|
-
color:
|
|
161
|
+
default: i(() => [
|
|
162
|
+
f(r(Z), {
|
|
163
|
+
style: H({
|
|
164
|
+
color: r(P).colorTextTertiary,
|
|
165
165
|
fontSize: "14px",
|
|
166
166
|
transform: "translateY(1px)"
|
|
167
167
|
})
|
|
@@ -173,26 +173,26 @@ const Ce = /* @__PURE__ */ L({
|
|
|
173
173
|
]),
|
|
174
174
|
key: "0"
|
|
175
175
|
} : void 0,
|
|
176
|
-
|
|
176
|
+
e.label ? {
|
|
177
177
|
name: "label",
|
|
178
|
-
fn:
|
|
179
|
-
|
|
180
|
-
content:
|
|
181
|
-
ellipsis: { tooltip:
|
|
178
|
+
fn: i(() => [
|
|
179
|
+
f(r(te), {
|
|
180
|
+
content: e.label,
|
|
181
|
+
ellipsis: { tooltip: e.label },
|
|
182
182
|
style: { "min-width": "0px", flex: "1" }
|
|
183
183
|
}, null, 8, ["content", "ellipsis"])
|
|
184
184
|
]),
|
|
185
185
|
key: "1"
|
|
186
186
|
} : void 0,
|
|
187
|
-
|
|
188
|
-
name:
|
|
189
|
-
fn:
|
|
190
|
-
|
|
187
|
+
U(r(F)(m, "default"), (l, a) => ({
|
|
188
|
+
name: a,
|
|
189
|
+
fn: i((s) => [
|
|
190
|
+
J(e.$slots, a, W(X(s || {})))
|
|
191
191
|
])
|
|
192
192
|
}))
|
|
193
193
|
]), 1040, ["class", "colon"]));
|
|
194
194
|
}
|
|
195
195
|
});
|
|
196
196
|
export {
|
|
197
|
-
|
|
197
|
+
ke as default
|
|
198
198
|
};
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { defineComponent as f, useSlots as m, createBlock as u, openBlock as c, normalizeProps as
|
|
1
|
+
import { defineComponent as f, useSlots as m, createBlock as u, openBlock as c, normalizeProps as a, guardReactiveProps as t, unref as o, createSlots as b, withCtx as r, createVNode as B, mergeProps as _, renderList as v, renderSlot as x } from "vue";
|
|
2
2
|
import { omit as i } from "lodash-unified";
|
|
3
3
|
import "../../../ap-field/index.mjs";
|
|
4
4
|
import "../../item/index.vue2.mjs";
|
|
5
|
-
import
|
|
6
|
-
import
|
|
5
|
+
import y from "../../item/index.vue.mjs";
|
|
6
|
+
import g from "../../../ap-field/checkbox/index.vue.mjs";
|
|
7
7
|
const w = /* @__PURE__ */ f({
|
|
8
8
|
name: "ApFormItemCheckbox",
|
|
9
9
|
__name: "index",
|
|
@@ -51,18 +51,18 @@ const w = /* @__PURE__ */ f({
|
|
|
51
51
|
disabled: { type: Boolean, default: void 0 },
|
|
52
52
|
field: { default: () => ({}) }
|
|
53
53
|
},
|
|
54
|
-
setup(
|
|
55
|
-
const d =
|
|
56
|
-
return (
|
|
54
|
+
setup(s) {
|
|
55
|
+
const d = s, n = m();
|
|
56
|
+
return (e, h) => (c(), u(y, a(t(o(i)(d, ["field"]))), b({
|
|
57
57
|
default: r(() => [
|
|
58
|
-
|
|
58
|
+
B(o(g), _({ disabled: e.disabled }, e.field), null, 16, ["disabled"])
|
|
59
59
|
]),
|
|
60
60
|
_: 2
|
|
61
61
|
}, [
|
|
62
|
-
v(
|
|
63
|
-
name:
|
|
62
|
+
v(o(i)(n, "default"), (C, l) => ({
|
|
63
|
+
name: l,
|
|
64
64
|
fn: r((p) => [
|
|
65
|
-
|
|
65
|
+
x(e.$slots, l, a(t(p || {})))
|
|
66
66
|
])
|
|
67
67
|
}))
|
|
68
68
|
]), 1040));
|