@aplus-frontend/ui 6.35.2 → 6.37.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/src/ag-grid/index.vue.d.ts +2 -30
- package/es/src/ag-grid/index.vue.mjs +1 -1
- package/es/src/ag-grid/interface.d.ts +15 -0
- package/es/src/ap-action/group/index.vue.mjs +41 -34
- package/es/src/ap-action/interface.d.ts +17 -0
- package/es/src/ap-action/item/index.vue2.mjs +34 -25
- package/es/src/ap-action/item-dropdown/index.vue.mjs +22 -20
- package/es/src/ap-action/item-modal/index.vue.mjs +14 -12
- package/es/src/ap-action/item-popconfirm/index.vue.mjs +13 -11
- package/es/src/ap-field/date/index.vue.mjs +6 -5
- package/es/src/ap-field/date/read.vue2.mjs +8 -7
- package/es/src/ap-field/date-range/index.vue.mjs +20 -17
- package/es/src/ap-field/date-range/read.vue2.mjs +3 -2
- package/es/src/ap-field/index.d.ts +3 -3
- package/es/src/ap-field/text/index.vue.d.ts +1 -1
- package/es/src/ap-field/text/password.vue.d.ts +1 -1
- package/es/src/ap-field/text/read-password.vue.d.ts +1 -1
- package/es/src/ap-field/text/read.vue.d.ts +1 -1
- package/es/src/ap-field/text-area/index.vue.d.ts +1 -1
- package/es/src/ap-field/text-area/read.vue.d.ts +1 -1
- package/es/src/ap-form/ap-form.vue.d.ts +1 -1
- package/es/src/ap-form/drawer-form/index.vue.d.ts +20 -20
- package/es/src/ap-form/interface.d.ts +12 -1
- package/es/src/ap-form/item/index.vue.d.ts +34 -34
- package/es/src/ap-form/items/checkbox/index.vue.d.ts +2 -2
- package/es/src/ap-form/items/date/index.vue.d.ts +2 -2
- package/es/src/ap-form/items/date-range/index.vue.d.ts +2 -2
- package/es/src/ap-form/items/number/index.vue.d.ts +2 -2
- package/es/src/ap-form/items/radio/index.vue.d.ts +2 -2
- package/es/src/ap-form/items/select/index.vue.d.ts +2 -2
- package/es/src/ap-form/items/switch/index.vue.d.ts +2 -2
- package/es/src/ap-form/items/text/index.vue.d.ts +8 -8
- package/es/src/ap-form/items/text/password.vue.d.ts +8 -8
- package/es/src/ap-form/items/text-area/index.vue.d.ts +6 -6
- package/es/src/ap-form/items/tree-select/index.vue.d.ts +2 -2
- package/es/src/ap-form/modal-form/index.vue.d.ts +30 -21
- package/es/src/ap-form/render/item.vue.d.ts +2 -2
- package/es/src/ap-form/search-form/hooks/use-count-per-row.d.ts +13 -2
- package/es/src/ap-form/search-form/hooks/use-count-per-row.mjs +32 -22
- package/es/src/ap-form/search-form/index.vue.d.ts +298 -20
- package/es/src/ap-form/search-form/index.vue.mjs +94 -88
- package/es/src/ap-modal/utils/createModal.mjs +38 -35
- package/es/src/ap-pro-card/components/card/index.vue.d.ts +1 -1
- package/es/src/ap-table/constants.d.ts +77 -77
- package/es/src/ap-upload/components/MultipleFile.vue2.mjs +132 -109
- package/es/src/business/ap-attachment/ApAttachment.d.ts +9 -0
- package/es/src/business/ap-attachment/ApAttachment.mjs +48 -47
- package/es/src/business/ap-attachment/constans.d.ts +4 -0
- package/es/src/business/ap-attachment/constans.mjs +4 -0
- package/es/src/business/ap-attachment/index.d.ts +15 -0
- package/es/src/business/ap-attachment/interface.d.ts +1 -0
- package/es/src/business/ap-table-modal/table-modal.vue2.mjs +15 -13
- package/es/src/business/ap-view/components/main-button-content.vue.d.ts +10 -10
- package/es/src/business/ap-view/components/menu-list-content.vue.d.ts +10 -10
- package/es/src/business/batch-input-group/form-item.vue.d.ts +2 -2
- package/es/src/business/batch-input-group/index.vue.d.ts +4 -4
- package/es/src/config-provider/config-provider-props.d.ts +5 -1
- package/es/src/config-provider/config-provider.d.ts +10 -1
- package/es/src/config-provider/hooks/use-global-config.d.ts +5 -1
- package/es/src/config-provider/index.d.ts +16 -1
- package/es/src/utils/config-provider-preset.d.ts +3 -1
- package/es/src/version.d.ts +1 -1
- package/es/src/version.mjs +1 -1
- package/es/src/work-order-modal/work-order-modal.vue.d.ts +10 -10
- package/es/src/work-order-modal/work-order-modal.vue.mjs +6 -4
- package/lib/src/ag-grid/index.vue.d.ts +2 -30
- package/lib/src/ag-grid/index.vue.js +1 -1
- package/lib/src/ag-grid/interface.d.ts +15 -0
- package/lib/src/ap-action/group/index.vue.js +1 -1
- package/lib/src/ap-action/interface.d.ts +17 -0
- 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-action/item-modal/index.vue.js +1 -1
- package/lib/src/ap-action/item-popconfirm/index.vue.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/index.d.ts +3 -3
- package/lib/src/ap-field/text/index.vue.d.ts +1 -1
- package/lib/src/ap-field/text/password.vue.d.ts +1 -1
- package/lib/src/ap-field/text/read-password.vue.d.ts +1 -1
- package/lib/src/ap-field/text/read.vue.d.ts +1 -1
- package/lib/src/ap-field/text-area/index.vue.d.ts +1 -1
- package/lib/src/ap-field/text-area/read.vue.d.ts +1 -1
- package/lib/src/ap-form/ap-form.vue.d.ts +1 -1
- package/lib/src/ap-form/drawer-form/index.vue.d.ts +20 -20
- package/lib/src/ap-form/interface.d.ts +12 -1
- package/lib/src/ap-form/item/index.vue.d.ts +34 -34
- package/lib/src/ap-form/items/checkbox/index.vue.d.ts +2 -2
- package/lib/src/ap-form/items/date/index.vue.d.ts +2 -2
- package/lib/src/ap-form/items/date-range/index.vue.d.ts +2 -2
- package/lib/src/ap-form/items/number/index.vue.d.ts +2 -2
- package/lib/src/ap-form/items/radio/index.vue.d.ts +2 -2
- package/lib/src/ap-form/items/select/index.vue.d.ts +2 -2
- package/lib/src/ap-form/items/switch/index.vue.d.ts +2 -2
- package/lib/src/ap-form/items/text/index.vue.d.ts +8 -8
- package/lib/src/ap-form/items/text/password.vue.d.ts +8 -8
- package/lib/src/ap-form/items/text-area/index.vue.d.ts +6 -6
- package/lib/src/ap-form/items/tree-select/index.vue.d.ts +2 -2
- package/lib/src/ap-form/modal-form/index.vue.d.ts +30 -21
- package/lib/src/ap-form/render/item.vue.d.ts +2 -2
- package/lib/src/ap-form/search-form/hooks/use-count-per-row.d.ts +13 -2
- package/lib/src/ap-form/search-form/hooks/use-count-per-row.js +1 -1
- package/lib/src/ap-form/search-form/index.vue.d.ts +298 -20
- package/lib/src/ap-form/search-form/index.vue.js +1 -1
- package/lib/src/ap-modal/utils/createModal.js +1 -1
- package/lib/src/ap-pro-card/components/card/index.vue.d.ts +1 -1
- package/lib/src/ap-table/constants.d.ts +77 -77
- package/lib/src/ap-upload/components/MultipleFile.vue2.js +1 -1
- package/lib/src/business/ap-attachment/ApAttachment.d.ts +9 -0
- package/lib/src/business/ap-attachment/ApAttachment.js +1 -1
- package/lib/src/business/ap-attachment/constans.d.ts +4 -0
- package/lib/src/business/ap-attachment/constans.js +1 -1
- package/lib/src/business/ap-attachment/index.d.ts +15 -0
- package/lib/src/business/ap-attachment/interface.d.ts +1 -0
- package/lib/src/business/ap-table-modal/table-modal.vue2.js +1 -1
- package/lib/src/business/ap-view/components/main-button-content.vue.d.ts +10 -10
- package/lib/src/business/ap-view/components/menu-list-content.vue.d.ts +10 -10
- package/lib/src/business/batch-input-group/form-item.vue.d.ts +2 -2
- package/lib/src/business/batch-input-group/index.vue.d.ts +4 -4
- package/lib/src/config-provider/config-provider-props.d.ts +5 -1
- package/lib/src/config-provider/config-provider.d.ts +10 -1
- package/lib/src/config-provider/hooks/use-global-config.d.ts +5 -1
- package/lib/src/config-provider/index.d.ts +16 -1
- package/lib/src/utils/config-provider-preset.d.ts +3 -1
- package/lib/src/version.d.ts +1 -1
- package/lib/src/version.js +1 -1
- package/lib/src/work-order-modal/work-order-modal.vue.d.ts +10 -10
- package/lib/src/work-order-modal/work-order-modal.vue.js +1 -1
- package/package.json +3 -3
- package/theme/ag-grid/index.css +6 -0
- package/theme/ap-action/item.css +6 -0
- package/theme/ap-action/item.less +9 -0
- package/theme/ap-attachment/ap-attachment.css +8 -4
- package/theme/ap-attachment/ap-attachment.less +8 -4
- package/theme/ap-grid/index.css +6 -0
- package/theme/ap-table/ap-table.css +6 -0
- package/theme/ap-table-modal/index.css +6 -0
- package/theme/ap-upload/index.css +6 -0
- package/theme/ap-upload/multiple-file.css +6 -0
- package/theme/ap-upload/multiple-file.less +7 -0
- package/theme/editable-table/index.css +6 -0
- package/theme/index.css +20 -4
|
@@ -1,28 +1,29 @@
|
|
|
1
|
-
import { isVNode as
|
|
2
|
-
import { Col as
|
|
1
|
+
import { isVNode as ie, defineComponent as ce, useSlots as ue, ref as B, shallowRef as M, computed as w, unref as a, watch as q, createVNode as o, Fragment as R, createBlock as x, openBlock as p, mergeProps as pe, withCtx as I, resolveDynamicComponent as T, createElementBlock as de, renderList as fe, normalizeStyle as me } from "vue";
|
|
2
|
+
import { Col as _, Flex as k, Button as H, Row as he } from "@aplus-frontend/antdv";
|
|
3
3
|
import "../ap-form.vue.mjs";
|
|
4
4
|
import "../item/index.vue2.mjs";
|
|
5
|
-
import { genRealChildren as
|
|
5
|
+
import { genRealChildren as G } from "../item-group/helper.mjs";
|
|
6
6
|
import "../../config-provider/index.mjs";
|
|
7
|
-
import { isArray as
|
|
8
|
-
import { isDef as
|
|
9
|
-
import { execFunc as
|
|
7
|
+
import { isArray as ge, isBoolean as xe, omit as ye } from "lodash-unified";
|
|
8
|
+
import { isDef as J } from "../../utils/index.mjs";
|
|
9
|
+
import { execFunc as K, diffFormItem as ve } from "./utils.mjs";
|
|
10
10
|
import "./components/popover-filter.vue.mjs";
|
|
11
|
-
import { useCountPerRow as
|
|
11
|
+
import { useCountPerRow as Se } from "./hooks/use-count-per-row.mjs";
|
|
12
12
|
import "./components/popover-sorter/index.vue.mjs";
|
|
13
13
|
import { useSorter as Ce } from "./hooks/use-sorter.mjs";
|
|
14
|
-
import { getTargetNode as
|
|
15
|
-
import { floorWith as
|
|
14
|
+
import { getTargetNode as we } from "./hooks/use-collapse-input-count.mjs";
|
|
15
|
+
import { floorWith as Q } from "@fruits-chain/utils";
|
|
16
|
+
import { useDevWarning as Re } from "../../utils/warning.mjs";
|
|
16
17
|
import { useNamespace as _e } from "../../config-provider/hooks/use-namespace.mjs";
|
|
17
|
-
import { useLocale as
|
|
18
|
-
import
|
|
19
|
-
import
|
|
20
|
-
import
|
|
21
|
-
import
|
|
22
|
-
function
|
|
23
|
-
return typeof d == "function" || Object.prototype.toString.call(d) === "[object Object]" && !
|
|
18
|
+
import { useLocale as be } from "../../config-provider/hooks/use-locale.mjs";
|
|
19
|
+
import X from "../item/index.vue.mjs";
|
|
20
|
+
import Fe from "./components/popover-filter.vue2.mjs";
|
|
21
|
+
import Ae from "./components/popover-sorter/index.vue2.mjs";
|
|
22
|
+
import Ne from "../ap-form.vue2.mjs";
|
|
23
|
+
function Be(d) {
|
|
24
|
+
return typeof d == "function" || Object.prototype.toString.call(d) === "[object Object]" && !ie(d);
|
|
24
25
|
}
|
|
25
|
-
const r = 100,
|
|
26
|
+
const r = 100, et = /* @__PURE__ */ ce({
|
|
26
27
|
name: "ApFormSearchForm",
|
|
27
28
|
__name: "index",
|
|
28
29
|
props: {
|
|
@@ -114,164 +115,169 @@ const r = 100, Qe = /* @__PURE__ */ ie({
|
|
|
114
115
|
default: !0
|
|
115
116
|
},
|
|
116
117
|
resizeTarget: {},
|
|
118
|
+
resize: {},
|
|
117
119
|
loadingDelay: {
|
|
118
120
|
default: 300
|
|
119
121
|
}
|
|
120
122
|
},
|
|
121
123
|
setup(d, {
|
|
122
|
-
expose:
|
|
124
|
+
expose: Y
|
|
123
125
|
}) {
|
|
124
|
-
const
|
|
126
|
+
const y = ue(), t = d;
|
|
127
|
+
Re("SearchForm").deprecated(typeof t.resizeTarget < "u", "resizeTarget", "resize.target");
|
|
128
|
+
const {
|
|
125
129
|
b: f
|
|
126
130
|
} = _e("ap-form-search-form"), {
|
|
127
|
-
t:
|
|
128
|
-
} =
|
|
129
|
-
function
|
|
131
|
+
t: P
|
|
132
|
+
} = be(), v = B(), E = B(), Z = Se(t, E), W = B();
|
|
133
|
+
function z() {
|
|
130
134
|
const e = v.value?.getFieldsValueTransformed(!0);
|
|
131
|
-
|
|
135
|
+
K(t.onSubmit, e);
|
|
132
136
|
}
|
|
133
|
-
function
|
|
134
|
-
t.customReset || v.value?.resetFields?.(),
|
|
137
|
+
function ee() {
|
|
138
|
+
t.customReset || v.value?.resetFields?.(), K(t.onReset);
|
|
135
139
|
}
|
|
136
|
-
const
|
|
140
|
+
const te = (e) => J(e) ? (ge(e) ? e : [e]).join("") : Date.now();
|
|
137
141
|
let O = [];
|
|
138
|
-
const m =
|
|
142
|
+
const m = M(G(y.default())), c = M(y.extra?.()), L = w(() => Q(r / a(Z), 4)), {
|
|
139
143
|
items: b,
|
|
140
|
-
sorted:
|
|
144
|
+
sorted: $,
|
|
141
145
|
handleClickConfirm: F
|
|
142
146
|
} = Ce(m);
|
|
143
|
-
|
|
144
|
-
O = m.value, m.value =
|
|
145
|
-
}),
|
|
146
|
-
|
|
147
|
+
q(() => y.default(), (e) => {
|
|
148
|
+
O = m.value, m.value = ve(O, G(e)), $.value = !1;
|
|
149
|
+
}), q(() => y.extra?.(), (e) => {
|
|
150
|
+
c.value = e;
|
|
147
151
|
});
|
|
148
|
-
function
|
|
149
|
-
return
|
|
152
|
+
function oe(e) {
|
|
153
|
+
return Q(e * (r / 24), 4);
|
|
150
154
|
}
|
|
151
|
-
const n =
|
|
152
|
-
const e = m.value,
|
|
153
|
-
let
|
|
154
|
-
const
|
|
155
|
+
const n = w(() => {
|
|
156
|
+
const e = m.value, u = [], l = [], g = [], s = a(L);
|
|
157
|
+
let S = 0, A = 0;
|
|
158
|
+
const le = r * t.maxRows - s * (a(c) && !t.extraInAction ? 2 : 1);
|
|
155
159
|
e.forEach((N) => {
|
|
156
|
-
const
|
|
157
|
-
if (!
|
|
160
|
+
const D = we(N);
|
|
161
|
+
if (!D)
|
|
158
162
|
return;
|
|
159
|
-
const i =
|
|
160
|
-
if (xe(i.hidden) ? !!i.hidden :
|
|
161
|
-
|
|
163
|
+
const i = D.props;
|
|
164
|
+
if (xe(i.hidden) ? !!i.hidden : J(i.hidden))
|
|
165
|
+
u.push(N);
|
|
162
166
|
else {
|
|
163
|
-
let
|
|
167
|
+
let C = i.span ? oe(i.span) : s;
|
|
164
168
|
const V = {
|
|
165
169
|
node: N,
|
|
166
|
-
span:
|
|
167
|
-
key: `ApFormSearchFormItem-${
|
|
168
|
-
},
|
|
169
|
-
|
|
170
|
+
span: C,
|
|
171
|
+
key: `ApFormSearchFormItem-${te(i.name)}-${i._signal}`
|
|
172
|
+
}, U = r - S % r;
|
|
173
|
+
U < C && (C += U), S += C, S > le ? l.push(V) : (A = S, g.push(V));
|
|
170
174
|
}
|
|
171
175
|
});
|
|
172
|
-
const
|
|
176
|
+
const j = r - (A + s) % r, re = Math.ceil(A) % r < s, se = j < s ? r : j;
|
|
173
177
|
return {
|
|
174
|
-
hideNode: o(
|
|
175
|
-
nodes:
|
|
178
|
+
hideNode: o(R, null, [u]),
|
|
179
|
+
nodes: g,
|
|
176
180
|
collapseNodes: l,
|
|
177
|
-
extraSpan:
|
|
178
|
-
lastRowOnlyIncludeActionAndExtra:
|
|
181
|
+
extraSpan: se,
|
|
182
|
+
lastRowOnlyIncludeActionAndExtra: re
|
|
179
183
|
};
|
|
180
|
-
}), h = (e) => `${e}%`,
|
|
184
|
+
}), h = (e) => `${e}%`, ae = w(() => {
|
|
181
185
|
let e;
|
|
182
|
-
const
|
|
186
|
+
const u = n.value.collapseNodes.length || t.sortable && m.value.length, l = o(_, {
|
|
183
187
|
flex: h(a(L)),
|
|
184
188
|
key: "actionWrapper"
|
|
185
189
|
}, {
|
|
186
|
-
default: () => [o(
|
|
190
|
+
default: () => [o(X, null, {
|
|
187
191
|
default: () => [o(k, {
|
|
188
192
|
wrap: "wrap",
|
|
189
|
-
justify: n.value.lastRowOnlyIncludeActionAndExtra && !(a(
|
|
193
|
+
justify: n.value.lastRowOnlyIncludeActionAndExtra && !(a(c) && t.extraInAction) ? "flex-end" : "space-between"
|
|
190
194
|
}, {
|
|
191
195
|
default: () => [o(k, {
|
|
192
196
|
gap: 8,
|
|
193
197
|
wrap: "wrap"
|
|
194
198
|
}, {
|
|
195
|
-
default: () => [
|
|
199
|
+
default: () => [u ? o("div", {
|
|
196
200
|
class: f("column-setting-trigger-wrapper")
|
|
197
|
-
}, [n.value.collapseNodes.length ? o(
|
|
198
|
-
onSubmit:
|
|
201
|
+
}, [n.value.collapseNodes.length ? o(Fe, {
|
|
202
|
+
onSubmit: z,
|
|
199
203
|
config: n.value.collapseNodes,
|
|
200
204
|
submitLoading: t.submitLoading
|
|
201
|
-
}, null) : null, t.sortable && b.value.length ? o(
|
|
202
|
-
ref:
|
|
205
|
+
}, null) : null, t.sortable && b.value.length ? o(Ae, {
|
|
206
|
+
ref: W,
|
|
203
207
|
items: b.value,
|
|
204
208
|
onClickConfirm: F,
|
|
205
|
-
sorted:
|
|
206
|
-
}, null) : null]) : null, o(
|
|
209
|
+
sorted: $.value
|
|
210
|
+
}, null) : null]) : null, o(H, {
|
|
207
211
|
type: "primary",
|
|
208
|
-
onClick:
|
|
212
|
+
onClick: z,
|
|
209
213
|
loading: t.submitLoading ? {
|
|
210
214
|
delay: t.loadingDelay
|
|
211
215
|
} : !1,
|
|
212
216
|
htmlType: "submit",
|
|
213
217
|
class: f("action-btn")
|
|
214
218
|
}, {
|
|
215
|
-
default: () => [t.searchText ||
|
|
216
|
-
}), o(
|
|
217
|
-
onClick:
|
|
219
|
+
default: () => [t.searchText || P("ap.apForm.search.search")]
|
|
220
|
+
}), o(H, {
|
|
221
|
+
onClick: ee,
|
|
218
222
|
type: "text",
|
|
219
223
|
class: [f("action-btn"), f("action-btn-reset")]
|
|
220
224
|
}, {
|
|
221
|
-
default: () => [t.resetText ||
|
|
225
|
+
default: () => [t.resetText || P("ap.apForm.search.reset")]
|
|
222
226
|
})]
|
|
223
|
-
}), t.extraInAction ? a(
|
|
227
|
+
}), t.extraInAction ? a(c) : null]
|
|
224
228
|
})]
|
|
225
229
|
})]
|
|
226
|
-
}),
|
|
230
|
+
}), g = !t.extraInAction && a(c) ? o(_, {
|
|
227
231
|
flex: h(n.value.extraSpan),
|
|
228
232
|
key: "extraNode"
|
|
229
233
|
}, {
|
|
230
|
-
default: () => [o(
|
|
234
|
+
default: () => [o(X, null, {
|
|
231
235
|
default: () => [o(k, {
|
|
232
236
|
justify: n.value.extraSpan === r || n.value.lastRowOnlyIncludeActionAndExtra ? "start" : "flex-end"
|
|
233
|
-
},
|
|
237
|
+
}, Be(e = a(c)) ? e : {
|
|
234
238
|
default: () => [e]
|
|
235
239
|
})]
|
|
236
240
|
})]
|
|
237
|
-
}) : null, s = o(
|
|
241
|
+
}) : null, s = o(_, {
|
|
238
242
|
flex: h(n.value.extraSpan)
|
|
239
243
|
}, null);
|
|
240
|
-
return n.value.lastRowOnlyIncludeActionAndExtra ? o(
|
|
244
|
+
return n.value.lastRowOnlyIncludeActionAndExtra ? o(R, null, [g || s, l]) : o(R, null, [l, g]);
|
|
241
245
|
});
|
|
242
|
-
function
|
|
243
|
-
const e =
|
|
246
|
+
function ne() {
|
|
247
|
+
const e = W.value?.getCachedList();
|
|
244
248
|
F(e);
|
|
245
249
|
}
|
|
246
|
-
return
|
|
247
|
-
apForm:
|
|
250
|
+
return Y({
|
|
251
|
+
apForm: w(() => a(v)),
|
|
248
252
|
getSorterItems: () => b.value,
|
|
249
253
|
setSorterItems: F,
|
|
250
|
-
resetSorterItems:
|
|
251
|
-
}), (e,
|
|
254
|
+
resetSorterItems: ne
|
|
255
|
+
}), (e, u) => (p(), x(Ne, pe({
|
|
252
256
|
ref_key: "apForm",
|
|
253
257
|
ref: v,
|
|
254
258
|
class: a(f)()
|
|
255
259
|
}, a(ye)(t, ["collapse", "defaultCollapse", "onUpdate:collapse", "searchText", "resetText", "onSubmit", "onReset", "extraInAction", "forceExpand", "countPerRow"])), {
|
|
256
|
-
default:
|
|
260
|
+
default: I(() => [(p(), x(T(n.value.hideNode))), o(a(he), {
|
|
261
|
+
ref_key: "contentWrapperRef",
|
|
262
|
+
ref: E,
|
|
257
263
|
gutter: 8
|
|
258
264
|
}, {
|
|
259
|
-
default:
|
|
265
|
+
default: I(() => [(p(!0), de(R, null, fe(n.value.nodes, (l) => (p(), x(a(_), {
|
|
260
266
|
key: l.key,
|
|
261
267
|
flex: h(l.span),
|
|
262
|
-
style:
|
|
268
|
+
style: me({
|
|
263
269
|
maxWidth: h(l.span)
|
|
264
270
|
})
|
|
265
271
|
}, {
|
|
266
|
-
default:
|
|
272
|
+
default: I(() => [(p(), x(T(l.node)))]),
|
|
267
273
|
_: 2
|
|
268
|
-
}, 1032, ["flex", "style"]))), 128)), (p(),
|
|
274
|
+
}, 1032, ["flex", "style"]))), 128)), (p(), x(T(ae.value)))]),
|
|
269
275
|
_: 1
|
|
270
|
-
})]),
|
|
276
|
+
}, 512)]),
|
|
271
277
|
_: 1
|
|
272
278
|
}, 16, ["class"]));
|
|
273
279
|
}
|
|
274
280
|
});
|
|
275
281
|
export {
|
|
276
|
-
|
|
282
|
+
et as default
|
|
277
283
|
};
|
|
@@ -1,39 +1,38 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Modal as
|
|
3
|
-
import { ConfigProvider as
|
|
4
|
-
import { omit as
|
|
5
|
-
import { isNumeric as
|
|
1
|
+
import { defineComponent as w, createVNode as l, mergeProps as P, render as h, h as N } from "vue";
|
|
2
|
+
import { Modal as L } from "@aplus-frontend/antdv";
|
|
3
|
+
import { ConfigProvider as M, globalConfigCached as C } from "../../config-provider/config-provider.mjs";
|
|
4
|
+
import { omit as A } from "lodash-unified";
|
|
5
|
+
import { isNumeric as D } from "@aplus-frontend/utils";
|
|
6
6
|
import "../../config-provider/index.mjs";
|
|
7
|
-
import { getContainerDom as u, getModalGlobalAppContext as
|
|
8
|
-
import { getTopWindow as
|
|
9
|
-
import { useNamespace as
|
|
10
|
-
const
|
|
7
|
+
import { getContainerDom as u, getModalGlobalAppContext as E } from "./util.mjs";
|
|
8
|
+
import { getTopWindow as G } from "../../utils/index.mjs";
|
|
9
|
+
import { useNamespace as H } from "../../config-provider/hooks/use-namespace.mjs";
|
|
10
|
+
const F = (a) => {
|
|
11
11
|
let o, t;
|
|
12
12
|
const {
|
|
13
|
-
destroyOnClose:
|
|
13
|
+
destroyOnClose: p = !0,
|
|
14
14
|
wrapperOffset: n = !1
|
|
15
|
-
} =
|
|
15
|
+
} = a, {
|
|
16
16
|
b: s
|
|
17
|
-
} =
|
|
17
|
+
} = H("ap-modal");
|
|
18
|
+
let m = !1;
|
|
18
19
|
function i() {
|
|
19
|
-
o && o(!1),
|
|
20
|
-
m(null, r), r.parentElement?.removeChild(r);
|
|
21
|
-
}, 500);
|
|
20
|
+
o && o(!1), m = !0;
|
|
22
21
|
}
|
|
23
|
-
function
|
|
22
|
+
function g() {
|
|
24
23
|
o && o(!0);
|
|
25
24
|
}
|
|
26
25
|
function c() {
|
|
27
26
|
o && o(!1);
|
|
28
27
|
}
|
|
29
|
-
function
|
|
28
|
+
function x(e) {
|
|
30
29
|
t && t(e);
|
|
31
30
|
}
|
|
32
|
-
const
|
|
31
|
+
const O = /* @__PURE__ */ w({
|
|
33
32
|
data() {
|
|
34
33
|
return {
|
|
35
|
-
open:
|
|
36
|
-
props:
|
|
34
|
+
open: p,
|
|
35
|
+
props: a
|
|
37
36
|
};
|
|
38
37
|
},
|
|
39
38
|
created() {
|
|
@@ -52,7 +51,7 @@ const z = (p) => {
|
|
|
52
51
|
const e = this.props?.content?.component?.exposed ?? void 0;
|
|
53
52
|
await this.props?.onCancel(e);
|
|
54
53
|
}
|
|
55
|
-
|
|
54
|
+
p ? i() : c();
|
|
56
55
|
},
|
|
57
56
|
async handleOk() {
|
|
58
57
|
try {
|
|
@@ -64,7 +63,7 @@ const z = (p) => {
|
|
|
64
63
|
}
|
|
65
64
|
t({
|
|
66
65
|
confirmLoading: !1
|
|
67
|
-
}),
|
|
66
|
+
}), p ? i() : c();
|
|
68
67
|
} catch {
|
|
69
68
|
t({
|
|
70
69
|
confirmLoading: !1
|
|
@@ -73,39 +72,43 @@ const z = (p) => {
|
|
|
73
72
|
}
|
|
74
73
|
},
|
|
75
74
|
render() {
|
|
76
|
-
const e =
|
|
77
|
-
return l(
|
|
78
|
-
default: () => [l(
|
|
75
|
+
const e = A(this.props, ["onCancel", "onOk", "open", "onUpdate:open", "getContainer", "icon"]);
|
|
76
|
+
return l(M, C.value, {
|
|
77
|
+
default: () => [l(L, P({
|
|
79
78
|
class: {
|
|
80
79
|
[s()]: !0,
|
|
81
80
|
[s("wrapper")]: n
|
|
82
81
|
},
|
|
82
|
+
centered: !0
|
|
83
|
+
}, e, {
|
|
83
84
|
open: this.open,
|
|
84
85
|
onCancel: this.handleCancel,
|
|
85
86
|
onOk: this.handleOk,
|
|
86
|
-
|
|
87
|
-
|
|
87
|
+
afterOpenChange: (f) => {
|
|
88
|
+
!f && m && (h(null, r), r.parentElement?.removeChild(r)), e?.afterOpenChange && e?.afterOpenChange?.(f);
|
|
89
|
+
}
|
|
90
|
+
}), {
|
|
88
91
|
default: () => [l("div", {
|
|
89
92
|
class: {
|
|
90
93
|
[s("body-wrapper")]: n
|
|
91
94
|
},
|
|
92
95
|
style: n === !1 ? {} : {
|
|
93
|
-
maxHeight: `calc(100vh - ${(n === !0 ? 100 :
|
|
96
|
+
maxHeight: `calc(100vh - ${(n === !0 ? 100 : D(n) ? Number(n) : 100) * 2}px)`
|
|
94
97
|
}
|
|
95
98
|
}, [this.props?.content])]
|
|
96
99
|
})]
|
|
97
100
|
});
|
|
98
101
|
}
|
|
99
|
-
}),
|
|
100
|
-
|
|
101
|
-
const d =
|
|
102
|
-
return d.appContext =
|
|
102
|
+
}), v = u(C?.value?.getPopupContainer), y = u(a.getContainer), b = v || y || G().document.body, r = document.createElement("div");
|
|
103
|
+
b.appendChild(r);
|
|
104
|
+
const d = N(O), k = E();
|
|
105
|
+
return d.appContext = a.appContext || k || d.appContext, h(d, r), {
|
|
103
106
|
destroy: i,
|
|
104
|
-
update:
|
|
105
|
-
open:
|
|
107
|
+
update: x,
|
|
108
|
+
open: g,
|
|
106
109
|
close: c
|
|
107
110
|
};
|
|
108
111
|
};
|
|
109
112
|
export {
|
|
110
|
-
|
|
113
|
+
F as createModal
|
|
111
114
|
};
|
|
@@ -21,9 +21,9 @@ declare const __VLS_component: DefineComponent<__VLS_PublicProps, {}, {}, {}, {}
|
|
|
21
21
|
gutter: ApProCardGutter | ApProCardGutter[];
|
|
22
22
|
ghost: boolean;
|
|
23
23
|
bordered: boolean;
|
|
24
|
+
hoverable: boolean;
|
|
24
25
|
collapsible: boolean;
|
|
25
26
|
headerBordered: boolean;
|
|
26
|
-
hoverable: boolean;
|
|
27
27
|
defaultCollapsed: boolean;
|
|
28
28
|
}, {}, {}, {}, string, ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
29
29
|
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|