@aplus-frontend/ui 0.4.1 → 0.4.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.
- package/es/src/ap-field/date/helper.d.ts +1 -1
- package/es/src/ap-field/date/helper.mjs +9 -9
- package/es/src/ap-field/date/index.vue.mjs +33 -25
- package/es/src/ap-field/date-range/index.vue.mjs +44 -43
- package/es/src/ap-field/interface.d.ts +0 -6
- package/es/src/ap-field/number/index.vue.d.ts +322 -1
- package/es/src/ap-field/radio/index.vue.d.ts +98 -2
- package/es/src/ap-field/rate/index.vue.d.ts +82 -1
- package/es/src/ap-field/select/index.vue.d.ts +407 -1
- package/es/src/ap-field/select/index.vue.mjs +14 -13
- package/es/src/ap-field/slider/index.vue.d.ts +257 -1
- package/es/src/ap-field/text-area/index.vue.d.ts +267 -2
- package/es/src/ap-form/ap-form.vue.d.ts +636 -1
- package/es/src/ap-form/drawer-form/index.vue.d.ts +1454 -4
- package/es/src/ap-form/item/index.vue.d.ts +777 -1
- package/es/src/ap-form/items/number/index.vue.d.ts +783 -2
- package/es/src/ap-form/items/radio/index.vue.d.ts +221 -3
- package/es/src/ap-form/items/text/index.vue.d.ts +139 -2
- package/es/src/ap-form/items/text/password.vue.d.ts +148 -1
- package/es/src/ap-form/items/text-area/index.vue.d.ts +566 -3
- package/es/src/ap-form/modal-form/index.vue.d.ts +1454 -5
- package/es/src/ap-form/modal-form/index.vue.mjs +64 -66
- package/es/src/ap-form/search-form/index.vue.d.ts +1454 -3
- package/es/src/ap-info-layout/ap-info-layout-admin/ApInfoLayoutAdmin.vue.d.ts +4 -1
- package/es/src/ap-list/index.vue.d.ts +1 -1
- package/es/src/ap-scroll-bar/ap-scroll-bar.vue.d.ts +3 -1
- package/es/src/ap-scroll-bar/index.d.ts +3 -1
- package/es/src/ap-table/ap-table.vue.d.ts +1 -1
- package/es/src/ap-table/ap-table.vue2.mjs +98 -97
- package/es/src/ap-table/constants.d.ts +2263 -13
- package/es/src/ap-table/context.d.ts +1 -0
- package/es/src/ap-table/context.mjs +11 -10
- package/es/src/ap-table/utils.d.ts +1180 -8
- package/es/src/ap-tag/ap-tag-group.vue.d.ts +3 -1
- package/es/src/ap-upload/apUpload.vue.d.ts +3 -1
- package/es/src/ap-upload/components/MultipleFile.vue.d.ts +453 -2
- package/es/src/ap-upload/components/Picture.vue.d.ts +3 -1
- package/es/src/ap-upload/components/SingleFile.vue.d.ts +3 -1
- package/es/src/business/ap-batch-action/ApBatchAction.vue.d.ts +8 -4
- package/es/src/business/ap-batch-action/ApBatchAction.vue2.mjs +45 -55
- package/es/src/business/ap-batch-action/index.d.ts +5 -3
- package/es/src/business/ap-expand-alert/ApExpandAlert.vue.d.ts +1 -1
- package/es/src/business/ap-export-group/ApExportGroup.vue2.mjs +66 -61
- package/es/src/business/ap-group-search/ap-group-search.vue.d.ts +3 -1
- package/es/src/business/ap-group-search/ap-group-search.vue2.mjs +9 -8
- package/es/src/business/ap-group-search/extension-select/index.vue.d.ts +3 -1
- package/es/src/business/ap-group-search/extension-select/index.vue2.mjs +8 -7
- package/es/src/business/ap-group-search/index.d.ts +418 -4
- package/es/src/business/ap-group-search/popover-select/index.vue.d.ts +413 -3
- package/es/src/business/ap-group-search/popover-select/index.vue2.mjs +15 -14
- package/es/src/business/ap-select-layout/select-layout.vue.d.ts +1 -1
- package/es/src/business/ap-table-modal/index.d.ts +22 -2
- package/es/src/business/ap-table-modal/interface.d.ts +2 -2
- package/es/src/business/ap-table-modal/table-modal.vue.d.ts +22 -2
- package/es/src/business/batch-input-group/index.vue.d.ts +146 -3
- package/es/src/business/batch-input-group/popover-input/index.vue.d.ts +267 -2
- package/es/src/business/hooks/usePageListApTable.mjs +20 -18
- package/es/src/editable-table/form-item.vue.d.ts +1 -1
- package/es/src/editable-table/index.vue.d.ts +1 -1
- package/es/src/work-order-modal/work-order-modal.vue.d.ts +827 -2
- package/lib/src/ap-field/date/helper.d.ts +1 -1
- package/lib/src/ap-field/date/helper.js +1 -1
- package/lib/src/ap-field/date/index.vue.js +1 -1
- package/lib/src/ap-field/date-range/index.vue.js +1 -1
- package/lib/src/ap-field/interface.d.ts +0 -6
- package/lib/src/ap-field/number/index.vue.d.ts +322 -1
- package/lib/src/ap-field/radio/index.vue.d.ts +98 -2
- package/lib/src/ap-field/rate/index.vue.d.ts +82 -1
- package/lib/src/ap-field/select/index.vue.d.ts +407 -1
- package/lib/src/ap-field/select/index.vue.js +1 -1
- package/lib/src/ap-field/slider/index.vue.d.ts +257 -1
- package/lib/src/ap-field/text-area/index.vue.d.ts +267 -2
- package/lib/src/ap-form/ap-form.vue.d.ts +636 -1
- package/lib/src/ap-form/drawer-form/index.vue.d.ts +1454 -4
- package/lib/src/ap-form/item/index.vue.d.ts +777 -1
- package/lib/src/ap-form/items/number/index.vue.d.ts +783 -2
- package/lib/src/ap-form/items/radio/index.vue.d.ts +221 -3
- package/lib/src/ap-form/items/text/index.vue.d.ts +139 -2
- package/lib/src/ap-form/items/text/password.vue.d.ts +148 -1
- package/lib/src/ap-form/items/text-area/index.vue.d.ts +566 -3
- package/lib/src/ap-form/modal-form/index.vue.d.ts +1454 -5
- package/lib/src/ap-form/modal-form/index.vue.js +1 -1
- package/lib/src/ap-form/search-form/index.vue.d.ts +1454 -3
- package/lib/src/ap-info-layout/ap-info-layout-admin/ApInfoLayoutAdmin.vue.d.ts +4 -1
- package/lib/src/ap-list/index.vue.d.ts +1 -1
- package/lib/src/ap-scroll-bar/ap-scroll-bar.vue.d.ts +3 -1
- package/lib/src/ap-scroll-bar/index.d.ts +3 -1
- package/lib/src/ap-table/ap-table.vue.d.ts +1 -1
- package/lib/src/ap-table/ap-table.vue2.js +1 -1
- package/lib/src/ap-table/constants.d.ts +2263 -13
- package/lib/src/ap-table/context.d.ts +1 -0
- package/lib/src/ap-table/context.js +1 -1
- package/lib/src/ap-table/utils.d.ts +1180 -8
- package/lib/src/ap-tag/ap-tag-group.vue.d.ts +3 -1
- package/lib/src/ap-upload/apUpload.vue.d.ts +3 -1
- package/lib/src/ap-upload/components/MultipleFile.vue.d.ts +453 -2
- package/lib/src/ap-upload/components/Picture.vue.d.ts +3 -1
- package/lib/src/ap-upload/components/SingleFile.vue.d.ts +3 -1
- package/lib/src/business/ap-batch-action/ApBatchAction.vue.d.ts +8 -4
- package/lib/src/business/ap-batch-action/ApBatchAction.vue2.js +1 -1
- package/lib/src/business/ap-batch-action/index.d.ts +5 -3
- package/lib/src/business/ap-expand-alert/ApExpandAlert.vue.d.ts +1 -1
- package/lib/src/business/ap-export-group/ApExportGroup.vue2.js +1 -1
- package/lib/src/business/ap-group-search/ap-group-search.vue.d.ts +3 -1
- package/lib/src/business/ap-group-search/ap-group-search.vue2.js +1 -1
- package/lib/src/business/ap-group-search/extension-select/index.vue.d.ts +3 -1
- package/lib/src/business/ap-group-search/extension-select/index.vue2.js +1 -1
- package/lib/src/business/ap-group-search/index.d.ts +418 -4
- package/lib/src/business/ap-group-search/popover-select/index.vue.d.ts +413 -3
- package/lib/src/business/ap-group-search/popover-select/index.vue2.js +2 -2
- package/lib/src/business/ap-select-layout/select-layout.vue.d.ts +1 -1
- package/lib/src/business/ap-table-modal/index.d.ts +22 -2
- package/lib/src/business/ap-table-modal/interface.d.ts +2 -2
- package/lib/src/business/ap-table-modal/table-modal.vue.d.ts +22 -2
- package/lib/src/business/batch-input-group/index.vue.d.ts +146 -3
- package/lib/src/business/batch-input-group/popover-input/index.vue.d.ts +267 -2
- package/lib/src/business/hooks/usePageListApTable.js +1 -1
- package/lib/src/editable-table/form-item.vue.d.ts +1 -1
- package/lib/src/editable-table/index.vue.d.ts +1 -1
- package/lib/src/work-order-modal/work-order-modal.vue.d.ts +827 -2
- package/package.json +5 -5
- package/theme/ap-form/index.css +3 -4
- package/theme/ap-form/modal-form.css +3 -4
- package/theme/ap-form/modal-form.less +3 -4
- package/theme/ap-table/ap-table.css +3 -4
- package/theme/ap-table-modal/index.css +3 -4
- package/theme/editable-table/index.css +3 -4
- package/theme/index.css +3 -4
|
@@ -7,5 +7,5 @@ export declare const formatDay: (d: Dayjs, f: string, begin?: boolean) => number
|
|
|
7
7
|
* @param timezone
|
|
8
8
|
* @returns
|
|
9
9
|
*/
|
|
10
|
-
export declare function formatDayWithTimezone(timezone?: ZoneAlias): (d: Dayjs, f
|
|
10
|
+
export declare function formatDayWithTimezone(timezone?: ZoneAlias): (d: Dayjs, f?: string, begin?: boolean) => number | null;
|
|
11
11
|
export declare const formatValue: (v: EventValue<Dayjs>) => number | null;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import { getUtcTimestamp as m } from "@aplus-frontend/utils";
|
|
2
2
|
import n from "dayjs";
|
|
3
|
-
const i = (
|
|
4
|
-
if (!
|
|
3
|
+
const i = (e, r, o = !0) => {
|
|
4
|
+
if (!e)
|
|
5
5
|
return null;
|
|
6
|
-
let t =
|
|
7
|
-
return t = t.millisecond(0),
|
|
6
|
+
let t = e.clone();
|
|
7
|
+
return t = t.millisecond(0), r.indexOf("ss") === -1 && (t = t.second(o ? 0 : 59)), r.indexOf("mm") === -1 && (t = t.minute(o ? 0 : 59)), r.indexOf("HH") === -1 && (t = t.hour(o ? 0 : 23)), r.indexOf("DD") === -1 && (t = t.date(o ? 1 : 0), o || (t = t.month(t.month() + 1))), r.indexOf("MM") === -1 && (t = t.month(o ? 0 : 12)), t.valueOf();
|
|
8
8
|
};
|
|
9
|
-
function d(
|
|
10
|
-
return (
|
|
11
|
-
const f = i(
|
|
12
|
-
return
|
|
9
|
+
function d(e) {
|
|
10
|
+
return (r, o, t = !0) => {
|
|
11
|
+
const f = o ? i(r, o, t) : r.valueOf();
|
|
12
|
+
return e ? m(n(f), e) : f;
|
|
13
13
|
};
|
|
14
14
|
}
|
|
15
|
-
const l = (
|
|
15
|
+
const l = (e) => e && e.valueOf();
|
|
16
16
|
export {
|
|
17
17
|
i as formatDay,
|
|
18
18
|
d as formatDayWithTimezone,
|
|
@@ -87,20 +87,20 @@ const le = /* @__PURE__ */ b({
|
|
|
87
87
|
},
|
|
88
88
|
emits: ["update:value"],
|
|
89
89
|
setup(h, { emit: B }) {
|
|
90
|
-
const e = h, k = B, { value: p, updateValue:
|
|
90
|
+
const e = h, k = B, { value: p, updateValue: c } = Z(
|
|
91
91
|
e,
|
|
92
92
|
k
|
|
93
|
-
), P = Y("Date", e),
|
|
93
|
+
), P = Y("Date", e), n = i(
|
|
94
94
|
() => I.indexOf(e.format) > -1
|
|
95
95
|
), d = i(
|
|
96
|
-
() =>
|
|
97
|
-
),
|
|
96
|
+
() => n.value ? H[e.format] : e.format
|
|
97
|
+
), m = i(() => {
|
|
98
98
|
if (y(t(p)))
|
|
99
99
|
return;
|
|
100
100
|
let o = r(t(p));
|
|
101
101
|
return e.timezone && (o = r(W(t(p), e.timezone))), o;
|
|
102
|
-
}), g = i(() => t(
|
|
103
|
-
const o = t(
|
|
102
|
+
}), g = i(() => t(n) ? e.picker ?? U[e.format] : e.picker), C = i(() => {
|
|
103
|
+
const o = t(n) ? K[e.format] : {};
|
|
104
104
|
return {
|
|
105
105
|
...$(e, [
|
|
106
106
|
"value",
|
|
@@ -114,39 +114,47 @@ const le = /* @__PURE__ */ b({
|
|
|
114
114
|
placeholder: t(P),
|
|
115
115
|
...o
|
|
116
116
|
};
|
|
117
|
-
}),
|
|
118
|
-
function
|
|
117
|
+
}), f = L(e.timezone);
|
|
118
|
+
function O(o) {
|
|
119
119
|
if (y(o)) {
|
|
120
|
-
|
|
120
|
+
c(null);
|
|
121
121
|
return;
|
|
122
122
|
}
|
|
123
|
-
const
|
|
124
|
-
|
|
123
|
+
const l = r(o);
|
|
124
|
+
c(
|
|
125
|
+
f(l, t(n) ? t(d) : void 0)
|
|
126
|
+
);
|
|
125
127
|
}
|
|
126
|
-
function T(o,
|
|
128
|
+
function T(o, l) {
|
|
127
129
|
var s;
|
|
128
|
-
const u = r(o),
|
|
129
|
-
|
|
130
|
+
const u = r(o), a = o ? f(
|
|
131
|
+
u,
|
|
132
|
+
t(n) ? t(d) : void 0
|
|
133
|
+
) : null;
|
|
134
|
+
(s = e.onChange) == null || s.call(e, a, l);
|
|
130
135
|
}
|
|
131
136
|
function S(o) {
|
|
132
|
-
var
|
|
133
|
-
const
|
|
134
|
-
|
|
137
|
+
var a;
|
|
138
|
+
const l = r(o), u = o ? f(
|
|
139
|
+
l,
|
|
140
|
+
t(n) ? t(d) : void 0
|
|
141
|
+
) : null;
|
|
142
|
+
(a = e.onOk) == null || a.call(e, u);
|
|
135
143
|
}
|
|
136
|
-
return (o,
|
|
137
|
-
M(R(
|
|
138
|
-
], 64)) : (v(), F(t(j), A({ key: 1 },
|
|
139
|
-
value:
|
|
144
|
+
return (o, l) => o.mode === "read" ? (v(), _(w, { key: 0 }, [
|
|
145
|
+
M(R(m.value ? t(r)(m.value).format(d.value) : o.emptyText), 1)
|
|
146
|
+
], 64)) : (v(), F(t(j), A({ key: 1 }, C.value, {
|
|
147
|
+
value: m.value,
|
|
140
148
|
format: d.value,
|
|
141
149
|
picker: g.value,
|
|
142
|
-
"onUpdate:value":
|
|
150
|
+
"onUpdate:value": O,
|
|
143
151
|
onChange: T,
|
|
144
152
|
onOk: S
|
|
145
153
|
}), D({ _: 2 }, [
|
|
146
|
-
x(o.$slots, (u,
|
|
147
|
-
name:
|
|
154
|
+
x(o.$slots, (u, a) => ({
|
|
155
|
+
name: a,
|
|
148
156
|
fn: E((s) => [
|
|
149
|
-
V(o.$slots,
|
|
157
|
+
V(o.$slots, a, z(N(s || {})))
|
|
150
158
|
])
|
|
151
159
|
}))
|
|
152
160
|
]), 1040, ["value", "format", "picker"]));
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { defineComponent as U, useSlots as H, computed as
|
|
1
|
+
import { defineComponent as U, useSlots as H, computed as m, unref as n, isVNode as K, createVNode as T, Fragment as h, openBlock as g, createElementBlock as v, createTextVNode as B, toDisplayString as P, createBlock as O, resolveDynamicComponent as $, mergeProps as L, createSlots as W, renderList as Y, withCtx as Z, renderSlot as q, normalizeProps as G, guardReactiveProps as J } from "vue";
|
|
2
2
|
import { ApFieldDatePresetFormats as Q, PRESET_FORMAT_MAP as X, PRESET_FORMAT_PICK_MAP as ee, PRESET_FORMAT_TIME_MAP as oe } from "../date/constant.mjs";
|
|
3
3
|
import "../../hooks/index.mjs";
|
|
4
|
-
import { isNil as
|
|
5
|
-
import
|
|
4
|
+
import { isNil as b, omit as R, isString as c, isFunction as ne } from "lodash-unified";
|
|
5
|
+
import u from "dayjs";
|
|
6
6
|
import { DatePicker as te } from "@aplus-frontend/antdv";
|
|
7
|
-
import { formatDayWithTimezone as ae
|
|
7
|
+
import { formatDayWithTimezone as ae } from "../date/helper.mjs";
|
|
8
8
|
import { SwapRightOutlined as re } from "@ant-design/icons-vue";
|
|
9
9
|
import { omitUndefined as le } from "../../utils/index.mjs";
|
|
10
10
|
import { getTimeFormatToZone as w } from "@aplus-frontend/utils";
|
|
@@ -153,76 +153,77 @@ const Be = /* @__PURE__ */ U({
|
|
|
153
153
|
setup(_, {
|
|
154
154
|
emit: A
|
|
155
155
|
}) {
|
|
156
|
-
const o = _, F = A,
|
|
157
|
-
value:
|
|
158
|
-
updateValue:
|
|
159
|
-
} = de(o, F), N = ue("DateRange", o),
|
|
160
|
-
var
|
|
161
|
-
const e = n(
|
|
162
|
-
if (
|
|
156
|
+
const o = _, F = A, k = H(), d = m(() => Q.indexOf(o.format) > -1), i = m(() => d.value ? X[o.format] : o.format), {
|
|
157
|
+
value: y,
|
|
158
|
+
updateValue: C
|
|
159
|
+
} = de(o, F), N = ue("DateRange", o), f = ae(o.timezone), S = m(() => {
|
|
160
|
+
var a, l;
|
|
161
|
+
const e = n(y);
|
|
162
|
+
if (b(e) || !(e != null && e.length))
|
|
163
163
|
return e;
|
|
164
|
-
const
|
|
165
|
-
return [
|
|
166
|
-
}), x =
|
|
167
|
-
const e = n(
|
|
164
|
+
const r = o.timezone ? w(n(y)[0], o.timezone) : (a = n(y)) == null ? void 0 : a[0], t = o.timezone ? w(n(y)[1], o.timezone) : (l = n(y)) == null ? void 0 : l[1];
|
|
165
|
+
return [u(r), u(t)];
|
|
166
|
+
}), x = m(() => n(d) ? o.picker ?? ee[o.format] : o.picker), z = m(() => {
|
|
167
|
+
const e = n(d) ? oe[o.format] : {};
|
|
168
168
|
return {
|
|
169
|
-
...le(
|
|
169
|
+
...le(R(o, ["value", "onUpdate:value", "onChange", "onOk", "format", "mode"])),
|
|
170
170
|
placeholder: n(N),
|
|
171
171
|
...e
|
|
172
172
|
};
|
|
173
173
|
});
|
|
174
174
|
function E(e) {
|
|
175
175
|
if (!e) {
|
|
176
|
-
|
|
176
|
+
C(e);
|
|
177
177
|
return;
|
|
178
178
|
}
|
|
179
|
-
let
|
|
180
|
-
|
|
179
|
+
let r = c(e[0]) ? u(e[0]) : e[0], t = c(e[1]) ? u(e[1]) : e[1];
|
|
180
|
+
const a = n(d) ? n(i) : void 0;
|
|
181
|
+
C([f(r, a), f(t, a, !1)]);
|
|
181
182
|
}
|
|
182
183
|
function V(e) {
|
|
183
|
-
var
|
|
184
|
-
const
|
|
185
|
-
(
|
|
184
|
+
var p;
|
|
185
|
+
const r = c(e[0]) ? u(e[0]) : e[0], t = c(e[1]) ? u(e[1]) : e[1], a = n(d) ? n(i) : void 0, l = e[0] ? f(r, a) : null, s = e[1] ? f(t, a, !1) : null;
|
|
186
|
+
(p = o.onOk) == null || p.call(o, [l, s]);
|
|
186
187
|
}
|
|
187
|
-
function I(e,
|
|
188
|
-
var
|
|
189
|
-
if (
|
|
190
|
-
(
|
|
188
|
+
function I(e, r) {
|
|
189
|
+
var M, D;
|
|
190
|
+
if (b(e)) {
|
|
191
|
+
(M = o.onChange) == null || M.call(o, e, r);
|
|
191
192
|
return;
|
|
192
193
|
}
|
|
193
|
-
const t =
|
|
194
|
-
(
|
|
194
|
+
const t = c(e[0]) ? u(e[0]) : e[0], a = c(e[1]) ? u(e[1]) : e[1], l = n(d) ? n(i) : void 0, s = e[0] ? f(t, l) : null, p = e[1] ? f(a, l, !1) : null;
|
|
195
|
+
(D = o.onChange) == null || D.call(o, [s, p], r);
|
|
195
196
|
}
|
|
196
|
-
const j =
|
|
197
|
+
const j = m(() => {
|
|
197
198
|
var t;
|
|
198
199
|
const e = o.readModeSeparator;
|
|
199
200
|
if (e)
|
|
200
|
-
return K(e) || ne(e) ? o.readModeSeparator :
|
|
201
|
-
const
|
|
202
|
-
return
|
|
201
|
+
return K(e) || ne(e) ? o.readModeSeparator : T(h, null, [o.readModeSeparator]);
|
|
202
|
+
const r = (t = k.readModeSeparator) == null ? void 0 : t.call(k);
|
|
203
|
+
return r ? T(h, null, [r]) : re;
|
|
203
204
|
});
|
|
204
|
-
return (e,
|
|
205
|
-
var t,
|
|
206
|
-
return e.mode === "read" ? (
|
|
205
|
+
return (e, r) => {
|
|
206
|
+
var t, a;
|
|
207
|
+
return e.mode === "read" ? (g(), v(h, {
|
|
207
208
|
key: 0
|
|
208
|
-
}, [
|
|
209
|
+
}, [S.value ? (g(), v(h, {
|
|
209
210
|
key: 0
|
|
210
|
-
}, [
|
|
211
|
+
}, [B(P((t = S.value[0]) == null ? void 0 : t.format(i.value)) + " ", 1), (g(), O($(j.value))), B(" " + P((a = S.value[1]) == null ? void 0 : a.format(i.value)), 1)], 64)) : (g(), v(h, {
|
|
211
212
|
key: 1
|
|
212
|
-
}, [
|
|
213
|
+
}, [B(P(e.emptyText), 1)], 64))], 64)) : (g(), O(n(te).RangePicker, L({
|
|
213
214
|
key: 1
|
|
214
215
|
}, z.value, {
|
|
215
|
-
value:
|
|
216
|
+
value: S.value,
|
|
216
217
|
picker: x.value,
|
|
217
|
-
format:
|
|
218
|
+
format: i.value,
|
|
218
219
|
"onUpdate:value": E,
|
|
219
220
|
onChange: I,
|
|
220
221
|
onOk: V
|
|
221
222
|
}), W({
|
|
222
223
|
_: 2
|
|
223
|
-
}, [Y(n(
|
|
224
|
-
name:
|
|
225
|
-
fn: Z((
|
|
224
|
+
}, [Y(n(R)(e.$slots, "readModeSeparator"), (l, s) => ({
|
|
225
|
+
name: s,
|
|
226
|
+
fn: Z((p) => [q(e.$slots, s, G(J(p || {})))])
|
|
226
227
|
}))]), 1040, ["value", "picker", "format"]));
|
|
227
228
|
};
|
|
228
229
|
}
|
|
@@ -6,7 +6,6 @@ import { RangePickerProps } from '@aplus-frontend/antdv/es/date-picker/dayjs';
|
|
|
6
6
|
import { LiteralUnion } from '../type';
|
|
7
7
|
import { InputPasswordProps } from './text/input-password-props';
|
|
8
8
|
import { ZoneAlias } from '@aplus-frontend/utils';
|
|
9
|
-
import { SelectValue } from '@aplus-frontend/antdv/es/select';
|
|
10
9
|
export type FieldMode = 'read' | 'edit';
|
|
11
10
|
export type BasicApFieldProps<FieldPropsType = any> = {
|
|
12
11
|
mode?: FieldMode;
|
|
@@ -119,11 +118,6 @@ export type ApFieldSelectProps = BasicApFieldProps<Omit<SelectProps, 'mode' | 'v
|
|
|
119
118
|
* 是否延迟请求选项列表
|
|
120
119
|
*/
|
|
121
120
|
lazy?: boolean;
|
|
122
|
-
/**
|
|
123
|
-
* 选中之前调用,如果返回false,则不更新值,支持异步
|
|
124
|
-
* @returns
|
|
125
|
-
*/
|
|
126
|
-
onBeforeSelect?: (newVal: SelectValue) => boolean | Promise<boolean>;
|
|
127
121
|
};
|
|
128
122
|
export type ApFieldSelectExpose = {
|
|
129
123
|
focus: () => void;
|
|
@@ -360,7 +360,328 @@ declare const __VLS_component: DefineComponent<ApFieldNumberProps, {
|
|
|
360
360
|
controls: boolean;
|
|
361
361
|
emptyText: string;
|
|
362
362
|
thousands: boolean;
|
|
363
|
-
}, {}, {}, {}, string, ComponentProvideOptions, false, {
|
|
363
|
+
}, {}, {}, {}, string, ComponentProvideOptions, false, {
|
|
364
|
+
inputRef: CreateComponentPublicInstanceWithMixins<Readonly< ExtractPropTypes<{
|
|
365
|
+
size: {
|
|
366
|
+
type: PropType<ButtonSize>;
|
|
367
|
+
default: ButtonSize;
|
|
368
|
+
};
|
|
369
|
+
bordered: {
|
|
370
|
+
type: BooleanConstructor;
|
|
371
|
+
default: boolean;
|
|
372
|
+
};
|
|
373
|
+
placeholder: StringConstructor;
|
|
374
|
+
name: StringConstructor;
|
|
375
|
+
id: StringConstructor;
|
|
376
|
+
type: StringConstructor;
|
|
377
|
+
addonBefore: VueTypeValidableDef<any>;
|
|
378
|
+
addonAfter: VueTypeValidableDef<any>;
|
|
379
|
+
prefix: VueTypeValidableDef<any>;
|
|
380
|
+
suffix: VueTypeValidableDef<any>;
|
|
381
|
+
'onUpdate:value': {
|
|
382
|
+
type: PropType<(value: ValueType) => void>;
|
|
383
|
+
default: (value: ValueType) => void;
|
|
384
|
+
};
|
|
385
|
+
valueModifiers: ObjectConstructor;
|
|
386
|
+
status: {
|
|
387
|
+
type: PropType<"" | "error" | "warning">;
|
|
388
|
+
default: "" | "error" | "warning";
|
|
389
|
+
};
|
|
390
|
+
stringMode: {
|
|
391
|
+
type: BooleanConstructor;
|
|
392
|
+
default: boolean;
|
|
393
|
+
};
|
|
394
|
+
defaultValue: {
|
|
395
|
+
type: PropType<ValueType>;
|
|
396
|
+
default: ValueType;
|
|
397
|
+
};
|
|
398
|
+
value: {
|
|
399
|
+
type: PropType<ValueType>;
|
|
400
|
+
default: ValueType;
|
|
401
|
+
};
|
|
402
|
+
prefixCls: {
|
|
403
|
+
type: PropType<string>;
|
|
404
|
+
default: string;
|
|
405
|
+
};
|
|
406
|
+
min: {
|
|
407
|
+
type: PropType<ValueType>;
|
|
408
|
+
default: ValueType;
|
|
409
|
+
};
|
|
410
|
+
max: {
|
|
411
|
+
type: PropType<ValueType>;
|
|
412
|
+
default: ValueType;
|
|
413
|
+
};
|
|
414
|
+
step: {
|
|
415
|
+
type: PropType<ValueType>;
|
|
416
|
+
default: ValueType;
|
|
417
|
+
};
|
|
418
|
+
tabindex: NumberConstructor;
|
|
419
|
+
controls: {
|
|
420
|
+
type: BooleanConstructor;
|
|
421
|
+
default: boolean;
|
|
422
|
+
};
|
|
423
|
+
readonly: {
|
|
424
|
+
type: BooleanConstructor;
|
|
425
|
+
default: boolean;
|
|
426
|
+
};
|
|
427
|
+
disabled: {
|
|
428
|
+
type: BooleanConstructor;
|
|
429
|
+
default: boolean;
|
|
430
|
+
};
|
|
431
|
+
autofocus: {
|
|
432
|
+
type: BooleanConstructor;
|
|
433
|
+
default: boolean;
|
|
434
|
+
};
|
|
435
|
+
keyboard: {
|
|
436
|
+
type: BooleanConstructor;
|
|
437
|
+
default: boolean;
|
|
438
|
+
};
|
|
439
|
+
parser: {
|
|
440
|
+
type: PropType<(displayValue: string) => ValueType>;
|
|
441
|
+
default: (displayValue: string) => ValueType;
|
|
442
|
+
};
|
|
443
|
+
formatter: {
|
|
444
|
+
type: PropType<(value: ValueType, info: {
|
|
445
|
+
userTyping: boolean;
|
|
446
|
+
input: string;
|
|
447
|
+
}) => string>;
|
|
448
|
+
default: (value: ValueType, info: {
|
|
449
|
+
userTyping: boolean;
|
|
450
|
+
input: string;
|
|
451
|
+
}) => string;
|
|
452
|
+
};
|
|
453
|
+
precision: NumberConstructor;
|
|
454
|
+
decimalSeparator: StringConstructor;
|
|
455
|
+
onInput: {
|
|
456
|
+
type: PropType<(text: string) => void>;
|
|
457
|
+
default: (text: string) => void;
|
|
458
|
+
};
|
|
459
|
+
onChange: {
|
|
460
|
+
type: PropType<(value: ValueType) => void>;
|
|
461
|
+
default: (value: ValueType) => void;
|
|
462
|
+
};
|
|
463
|
+
onPressEnter: {
|
|
464
|
+
type: PropType<KeyboardEventHandler>;
|
|
465
|
+
default: KeyboardEventHandler;
|
|
466
|
+
};
|
|
467
|
+
onStep: {
|
|
468
|
+
type: PropType<(value: ValueType, info: {
|
|
469
|
+
offset: ValueType;
|
|
470
|
+
type: "up" | "down";
|
|
471
|
+
}) => void>;
|
|
472
|
+
default: (value: ValueType, info: {
|
|
473
|
+
offset: ValueType;
|
|
474
|
+
type: "up" | "down";
|
|
475
|
+
}) => void;
|
|
476
|
+
};
|
|
477
|
+
onBlur: {
|
|
478
|
+
type: PropType<(e: FocusEvent) => void>;
|
|
479
|
+
default: (e: FocusEvent) => void;
|
|
480
|
+
};
|
|
481
|
+
onFocus: {
|
|
482
|
+
type: PropType<(e: FocusEvent) => void>;
|
|
483
|
+
default: (e: FocusEvent) => void;
|
|
484
|
+
};
|
|
485
|
+
}>> & Readonly<{}>, () => VueNode, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, PublicProps, {
|
|
486
|
+
size: ButtonSize;
|
|
487
|
+
value: ValueType;
|
|
488
|
+
onFocus: (e: FocusEvent) => void;
|
|
489
|
+
onBlur: (e: FocusEvent) => void;
|
|
490
|
+
onChange: (value: ValueType) => void;
|
|
491
|
+
onInput: (text: string) => void;
|
|
492
|
+
disabled: boolean;
|
|
493
|
+
max: ValueType;
|
|
494
|
+
min: ValueType;
|
|
495
|
+
prefixCls: string;
|
|
496
|
+
autofocus: boolean;
|
|
497
|
+
readonly: boolean;
|
|
498
|
+
status: "" | "error" | "warning";
|
|
499
|
+
defaultValue: ValueType;
|
|
500
|
+
'onUpdate:value': (value: ValueType) => void;
|
|
501
|
+
step: ValueType;
|
|
502
|
+
bordered: boolean;
|
|
503
|
+
onPressEnter: KeyboardEventHandler;
|
|
504
|
+
formatter: (value: ValueType, info: {
|
|
505
|
+
userTyping: boolean;
|
|
506
|
+
input: string;
|
|
507
|
+
}) => string;
|
|
508
|
+
keyboard: boolean;
|
|
509
|
+
onStep: (value: ValueType, info: {
|
|
510
|
+
offset: ValueType;
|
|
511
|
+
type: "up" | "down";
|
|
512
|
+
}) => void;
|
|
513
|
+
stringMode: boolean;
|
|
514
|
+
controls: boolean;
|
|
515
|
+
parser: (displayValue: string) => ValueType;
|
|
516
|
+
}, true, {}, CustomSlotsType<{
|
|
517
|
+
addonBefore?: any;
|
|
518
|
+
addonAfter?: any;
|
|
519
|
+
prefix?: any;
|
|
520
|
+
suffix?: any;
|
|
521
|
+
default?: any;
|
|
522
|
+
upIcon?: any;
|
|
523
|
+
downIcon?: any;
|
|
524
|
+
}>, GlobalComponents, GlobalDirectives, string, {}, any, ComponentProvideOptions, {
|
|
525
|
+
P: {};
|
|
526
|
+
B: {};
|
|
527
|
+
D: {};
|
|
528
|
+
C: {};
|
|
529
|
+
M: {};
|
|
530
|
+
Defaults: {};
|
|
531
|
+
}, Readonly< ExtractPropTypes<{
|
|
532
|
+
size: {
|
|
533
|
+
type: PropType<ButtonSize>;
|
|
534
|
+
default: ButtonSize;
|
|
535
|
+
};
|
|
536
|
+
bordered: {
|
|
537
|
+
type: BooleanConstructor;
|
|
538
|
+
default: boolean;
|
|
539
|
+
};
|
|
540
|
+
placeholder: StringConstructor;
|
|
541
|
+
name: StringConstructor;
|
|
542
|
+
id: StringConstructor;
|
|
543
|
+
type: StringConstructor;
|
|
544
|
+
addonBefore: VueTypeValidableDef<any>;
|
|
545
|
+
addonAfter: VueTypeValidableDef<any>;
|
|
546
|
+
prefix: VueTypeValidableDef<any>;
|
|
547
|
+
suffix: VueTypeValidableDef<any>;
|
|
548
|
+
'onUpdate:value': {
|
|
549
|
+
type: PropType<(value: ValueType) => void>;
|
|
550
|
+
default: (value: ValueType) => void;
|
|
551
|
+
};
|
|
552
|
+
valueModifiers: ObjectConstructor;
|
|
553
|
+
status: {
|
|
554
|
+
type: PropType<"" | "error" | "warning">;
|
|
555
|
+
default: "" | "error" | "warning";
|
|
556
|
+
};
|
|
557
|
+
stringMode: {
|
|
558
|
+
type: BooleanConstructor;
|
|
559
|
+
default: boolean;
|
|
560
|
+
};
|
|
561
|
+
defaultValue: {
|
|
562
|
+
type: PropType<ValueType>;
|
|
563
|
+
default: ValueType;
|
|
564
|
+
};
|
|
565
|
+
value: {
|
|
566
|
+
type: PropType<ValueType>;
|
|
567
|
+
default: ValueType;
|
|
568
|
+
};
|
|
569
|
+
prefixCls: {
|
|
570
|
+
type: PropType<string>;
|
|
571
|
+
default: string;
|
|
572
|
+
};
|
|
573
|
+
min: {
|
|
574
|
+
type: PropType<ValueType>;
|
|
575
|
+
default: ValueType;
|
|
576
|
+
};
|
|
577
|
+
max: {
|
|
578
|
+
type: PropType<ValueType>;
|
|
579
|
+
default: ValueType;
|
|
580
|
+
};
|
|
581
|
+
step: {
|
|
582
|
+
type: PropType<ValueType>;
|
|
583
|
+
default: ValueType;
|
|
584
|
+
};
|
|
585
|
+
tabindex: NumberConstructor;
|
|
586
|
+
controls: {
|
|
587
|
+
type: BooleanConstructor;
|
|
588
|
+
default: boolean;
|
|
589
|
+
};
|
|
590
|
+
readonly: {
|
|
591
|
+
type: BooleanConstructor;
|
|
592
|
+
default: boolean;
|
|
593
|
+
};
|
|
594
|
+
disabled: {
|
|
595
|
+
type: BooleanConstructor;
|
|
596
|
+
default: boolean;
|
|
597
|
+
};
|
|
598
|
+
autofocus: {
|
|
599
|
+
type: BooleanConstructor;
|
|
600
|
+
default: boolean;
|
|
601
|
+
};
|
|
602
|
+
keyboard: {
|
|
603
|
+
type: BooleanConstructor;
|
|
604
|
+
default: boolean;
|
|
605
|
+
};
|
|
606
|
+
parser: {
|
|
607
|
+
type: PropType<(displayValue: string) => ValueType>;
|
|
608
|
+
default: (displayValue: string) => ValueType;
|
|
609
|
+
};
|
|
610
|
+
formatter: {
|
|
611
|
+
type: PropType<(value: ValueType, info: {
|
|
612
|
+
userTyping: boolean;
|
|
613
|
+
input: string;
|
|
614
|
+
}) => string>;
|
|
615
|
+
default: (value: ValueType, info: {
|
|
616
|
+
userTyping: boolean;
|
|
617
|
+
input: string;
|
|
618
|
+
}) => string;
|
|
619
|
+
};
|
|
620
|
+
precision: NumberConstructor;
|
|
621
|
+
decimalSeparator: StringConstructor;
|
|
622
|
+
onInput: {
|
|
623
|
+
type: PropType<(text: string) => void>;
|
|
624
|
+
default: (text: string) => void;
|
|
625
|
+
};
|
|
626
|
+
onChange: {
|
|
627
|
+
type: PropType<(value: ValueType) => void>;
|
|
628
|
+
default: (value: ValueType) => void;
|
|
629
|
+
};
|
|
630
|
+
onPressEnter: {
|
|
631
|
+
type: PropType<KeyboardEventHandler>;
|
|
632
|
+
default: KeyboardEventHandler;
|
|
633
|
+
};
|
|
634
|
+
onStep: {
|
|
635
|
+
type: PropType<(value: ValueType, info: {
|
|
636
|
+
offset: ValueType;
|
|
637
|
+
type: "up" | "down";
|
|
638
|
+
}) => void>;
|
|
639
|
+
default: (value: ValueType, info: {
|
|
640
|
+
offset: ValueType;
|
|
641
|
+
type: "up" | "down";
|
|
642
|
+
}) => void;
|
|
643
|
+
};
|
|
644
|
+
onBlur: {
|
|
645
|
+
type: PropType<(e: FocusEvent) => void>;
|
|
646
|
+
default: (e: FocusEvent) => void;
|
|
647
|
+
};
|
|
648
|
+
onFocus: {
|
|
649
|
+
type: PropType<(e: FocusEvent) => void>;
|
|
650
|
+
default: (e: FocusEvent) => void;
|
|
651
|
+
};
|
|
652
|
+
}>> & Readonly<{}>, () => VueNode, {}, {}, {}, {
|
|
653
|
+
size: ButtonSize;
|
|
654
|
+
value: ValueType;
|
|
655
|
+
onFocus: (e: FocusEvent) => void;
|
|
656
|
+
onBlur: (e: FocusEvent) => void;
|
|
657
|
+
onChange: (value: ValueType) => void;
|
|
658
|
+
onInput: (text: string) => void;
|
|
659
|
+
disabled: boolean;
|
|
660
|
+
max: ValueType;
|
|
661
|
+
min: ValueType;
|
|
662
|
+
prefixCls: string;
|
|
663
|
+
autofocus: boolean;
|
|
664
|
+
readonly: boolean;
|
|
665
|
+
status: "" | "error" | "warning";
|
|
666
|
+
defaultValue: ValueType;
|
|
667
|
+
'onUpdate:value': (value: ValueType) => void;
|
|
668
|
+
step: ValueType;
|
|
669
|
+
bordered: boolean;
|
|
670
|
+
onPressEnter: KeyboardEventHandler;
|
|
671
|
+
formatter: (value: ValueType, info: {
|
|
672
|
+
userTyping: boolean;
|
|
673
|
+
input: string;
|
|
674
|
+
}) => string;
|
|
675
|
+
keyboard: boolean;
|
|
676
|
+
onStep: (value: ValueType, info: {
|
|
677
|
+
offset: ValueType;
|
|
678
|
+
type: "up" | "down";
|
|
679
|
+
}) => void;
|
|
680
|
+
stringMode: boolean;
|
|
681
|
+
controls: boolean;
|
|
682
|
+
parser: (displayValue: string) => ValueType;
|
|
683
|
+
}> | null;
|
|
684
|
+
}, any>;
|
|
364
685
|
declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, __VLS_TemplateResult["slots"]>;
|
|
365
686
|
export default _default;
|
|
366
687
|
type __VLS_WithTemplateSlots<T, S> = T & {
|