@aplus-frontend/ui 0.0.7 → 0.0.9
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/index.mjs +102 -98
- package/es/src/ap-field/date/index.vue.d.ts +2 -2
- package/es/src/ap-field/date/index.vue.mjs +1 -1
- package/es/src/ap-field/date-range/index.vue.d.ts +2 -2
- package/es/src/ap-field/date-range/index.vue.mjs +1 -1
- package/es/src/ap-field/index.d.ts +3 -1
- package/es/src/ap-field/index.mjs +7 -3
- package/es/src/ap-field/interface.d.ts +12 -1
- package/es/src/ap-field/rate/index.vue.d.ts +64 -0
- package/es/src/ap-field/rate/index.vue.mjs +64 -0
- package/es/src/ap-field/rate/index.vue2.mjs +4 -0
- package/es/src/ap-field/segmented/index.vue.d.ts +27 -4
- package/es/src/ap-field/segmented/index.vue.mjs +29 -25
- package/es/src/ap-field/select/index.vue.d.ts +5 -2
- package/es/src/ap-field/select/index.vue.mjs +46 -37
- package/es/src/ap-field/text/index.vue.d.ts +2 -2
- package/es/src/ap-field/text/index.vue2.mjs +1 -1
- package/es/src/ap-field/text/password.vue.d.ts +2 -2
- package/es/src/ap-field/text/password.vue.mjs +1 -1
- package/es/src/ap-field/text-area/index.vue.d.ts +3 -0
- package/es/src/ap-field/text-area/index.vue.mjs +1 -1
- package/es/src/ap-form/items/index.d.ts +2 -2
- package/es/src/ap-form/items/index.mjs +4 -1
- package/es/src/ap-form/items/interface.d.ts +6 -1
- package/es/src/ap-form/items/text/index.d.ts +8 -0
- package/es/src/ap-form/items/text/index.mjs +10 -0
- package/es/src/ap-form/items/text/index.vue.mjs +2 -93
- package/es/src/ap-form/items/text/index.vue2.mjs +93 -2
- package/es/src/ap-form/items/text/password.vue.d.ts +63 -0
- package/es/src/ap-form/items/text/password.vue.mjs +83 -0
- package/es/src/ap-form/items/text/password.vue2.mjs +4 -0
- package/es/src/ap-form/search-form/index.vue.mjs +53 -53
- package/es/src/ap-table/ap-table.vue.d.ts +2 -1
- package/es/src/ap-table/ap-table.vue.mjs +71 -70
- package/es/src/ap-table/constants.d.ts +3264 -903
- package/es/src/ap-table/constants.mjs +33 -30
- package/es/src/ap-table/interface.d.ts +11 -3
- package/es/src/ap-table/utils.d.ts +1 -1
- package/es/src/index.mjs +94 -90
- package/lib/index.js +1 -1
- package/lib/src/ap-field/date/index.vue.d.ts +2 -2
- package/lib/src/ap-field/date/index.vue.js +1 -1
- package/lib/src/ap-field/date-range/index.vue.d.ts +2 -2
- package/lib/src/ap-field/date-range/index.vue.js +1 -1
- package/lib/src/ap-field/index.d.ts +3 -1
- package/lib/src/ap-field/index.js +1 -1
- package/lib/src/ap-field/interface.d.ts +12 -1
- package/lib/src/ap-field/rate/index.vue.d.ts +64 -0
- package/lib/src/ap-field/rate/index.vue.js +1 -0
- package/lib/src/ap-field/rate/index.vue2.js +1 -0
- package/lib/src/ap-field/segmented/index.vue.d.ts +27 -4
- package/lib/src/ap-field/segmented/index.vue.js +1 -1
- package/lib/src/ap-field/select/index.vue.d.ts +5 -2
- package/lib/src/ap-field/select/index.vue.js +1 -1
- package/lib/src/ap-field/text/index.vue.d.ts +2 -2
- package/lib/src/ap-field/text/index.vue2.js +1 -1
- package/lib/src/ap-field/text/password.vue.d.ts +2 -2
- package/lib/src/ap-field/text/password.vue.js +1 -1
- package/lib/src/ap-field/text-area/index.vue.d.ts +3 -0
- package/lib/src/ap-field/text-area/index.vue.js +1 -1
- package/lib/src/ap-form/items/index.d.ts +2 -2
- package/lib/src/ap-form/items/index.js +1 -1
- package/lib/src/ap-form/items/interface.d.ts +6 -1
- package/lib/src/ap-form/items/text/index.d.ts +8 -0
- package/lib/src/ap-form/items/text/index.js +1 -0
- package/lib/src/ap-form/items/text/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.d.ts +63 -0
- package/lib/src/ap-form/items/text/password.vue.js +1 -0
- package/lib/src/ap-form/items/text/password.vue2.js +1 -0
- package/lib/src/ap-form/search-form/index.vue.js +1 -1
- package/lib/src/ap-table/ap-table.vue.d.ts +2 -1
- package/lib/src/ap-table/ap-table.vue.js +1 -1
- package/lib/src/ap-table/constants.d.ts +3264 -903
- package/lib/src/ap-table/constants.js +1 -1
- package/lib/src/ap-table/interface.d.ts +11 -3
- package/lib/src/ap-table/utils.d.ts +1 -1
- package/lib/src/index.js +1 -1
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as S, ref as
|
|
1
|
+
import { defineComponent as S, ref as c, useSlots as B, onMounted as U, computed as V, unref as o, createVNode as s, Fragment as a, openBlock as r, createBlock as m, createElementBlock as _, resolveDynamicComponent as h, mergeProps as N, withCtx as q, renderSlot as z, normalizeProps as F, guardReactiveProps as P } from "vue";
|
|
2
2
|
import { Spin as T, Segmented as R } from "ant-design-vue";
|
|
3
3
|
import { isFunction as v, isUndefined as w, isString as A, isNumber as D, omit as E } from "lodash-unified";
|
|
4
4
|
import "../../hooks/index.mjs";
|
|
@@ -7,67 +7,71 @@ const J = /* @__PURE__ */ S({
|
|
|
7
7
|
name: "ApFieldSegmented",
|
|
8
8
|
__name: "index",
|
|
9
9
|
props: {
|
|
10
|
-
mode: {
|
|
10
|
+
mode: {
|
|
11
|
+
default: "edit"
|
|
12
|
+
},
|
|
11
13
|
prefixCls: {},
|
|
12
14
|
options: {},
|
|
13
15
|
block: {
|
|
14
|
-
type: Boolean
|
|
16
|
+
type: Boolean,
|
|
17
|
+
default: void 0
|
|
15
18
|
},
|
|
16
19
|
disabled: {
|
|
17
|
-
type: Boolean
|
|
20
|
+
type: Boolean,
|
|
21
|
+
default: void 0
|
|
18
22
|
},
|
|
19
23
|
size: {},
|
|
20
24
|
value: {},
|
|
21
25
|
motionName: {},
|
|
22
26
|
onChange: {},
|
|
23
27
|
"onUpdate:value": {},
|
|
24
|
-
emptyText: {
|
|
28
|
+
emptyText: {
|
|
29
|
+
default: "--"
|
|
30
|
+
},
|
|
25
31
|
defaultValue: {},
|
|
26
|
-
request: {
|
|
27
|
-
type: Function
|
|
28
|
-
}
|
|
32
|
+
request: {}
|
|
29
33
|
},
|
|
30
34
|
emits: ["update:value"],
|
|
31
35
|
setup(y, {
|
|
32
36
|
emit: g
|
|
33
37
|
}) {
|
|
34
|
-
const e = y, i =
|
|
38
|
+
const e = y, i = c((e == null ? void 0 : e.options) || []), k = g, {
|
|
35
39
|
value: p,
|
|
36
40
|
updateValue: b
|
|
37
|
-
} = M(e, k),
|
|
41
|
+
} = M(e, k), d = c(!1), x = B();
|
|
38
42
|
U(() => {
|
|
39
|
-
v(e.request) && (
|
|
40
|
-
|
|
43
|
+
v(e.request) && (d.value = !0, e.request().then((t) => i.value = t).finally(() => {
|
|
44
|
+
d.value = !1;
|
|
41
45
|
}));
|
|
42
46
|
});
|
|
43
47
|
const C = V(() => {
|
|
44
|
-
var
|
|
45
|
-
const t =
|
|
48
|
+
var f;
|
|
49
|
+
const t = o(p);
|
|
46
50
|
if (w(t))
|
|
47
51
|
return s(a, null, [e.emptyText]);
|
|
48
|
-
const l = (
|
|
52
|
+
const l = (f = o(i)) == null ? void 0 : f.find((u) => u === t || (u == null ? void 0 : u.value) === t);
|
|
49
53
|
if (A(l) || D(l))
|
|
50
54
|
return s(a, null, [l]);
|
|
51
|
-
const
|
|
52
|
-
return v(
|
|
55
|
+
const n = (l == null ? void 0 : l.label) || x.label;
|
|
56
|
+
return v(n) ? s(a, null, [n == null ? void 0 : n({
|
|
53
57
|
...l
|
|
54
|
-
})]) : s(a, null, [
|
|
58
|
+
})]) : s(a, null, [n || e.emptyText]);
|
|
55
59
|
});
|
|
56
|
-
return (t, l) =>
|
|
60
|
+
return (t, l) => d.value ? (r(), m(o(T), {
|
|
57
61
|
key: 0,
|
|
58
62
|
size: "small"
|
|
59
63
|
})) : (r(), _(a, {
|
|
60
64
|
key: 1
|
|
61
|
-
}, [t.mode === "read" ? (r(),
|
|
65
|
+
}, [t.mode === "read" ? (r(), m(h(C.value), {
|
|
62
66
|
key: 0
|
|
63
|
-
})) : (r(),
|
|
67
|
+
})) : (r(), m(o(R), N({
|
|
64
68
|
key: 1
|
|
65
|
-
},
|
|
66
|
-
value:
|
|
67
|
-
"onUpdate:value":
|
|
69
|
+
}, o(E)(e, ["onUpdate:value", "value", "defaultValue", "options"]), {
|
|
70
|
+
value: o(p),
|
|
71
|
+
"onUpdate:value": o(b),
|
|
68
72
|
options: i.value
|
|
69
73
|
}), {
|
|
70
|
-
label:
|
|
74
|
+
label: q((n) => [z(t.$slots, "label", F(P(n)))]),
|
|
71
75
|
_: 3
|
|
72
76
|
}, 16, ["value", "onUpdate:value", "options"]))], 64));
|
|
73
77
|
}
|
|
@@ -26,7 +26,7 @@ declare const _default: __VLS_WithTemplateSlots< DefineComponent<__VLS_WithDefau
|
|
|
26
26
|
autofocus: undefined;
|
|
27
27
|
virtual: undefined;
|
|
28
28
|
loading: undefined;
|
|
29
|
-
allowClear:
|
|
29
|
+
allowClear: boolean;
|
|
30
30
|
showSearch: undefined;
|
|
31
31
|
defaultOpen: undefined;
|
|
32
32
|
showArrow: undefined;
|
|
@@ -34,6 +34,7 @@ declare const _default: __VLS_WithTemplateSlots< DefineComponent<__VLS_WithDefau
|
|
|
34
34
|
defaultActiveFirstOption: undefined;
|
|
35
35
|
labelInValue: undefined;
|
|
36
36
|
multiple: undefined;
|
|
37
|
+
searchMode: string;
|
|
37
38
|
}>, {
|
|
38
39
|
focus: typeof focus;
|
|
39
40
|
blur: typeof blur;
|
|
@@ -48,7 +49,7 @@ declare const _default: __VLS_WithTemplateSlots< DefineComponent<__VLS_WithDefau
|
|
|
48
49
|
autofocus: undefined;
|
|
49
50
|
virtual: undefined;
|
|
50
51
|
loading: undefined;
|
|
51
|
-
allowClear:
|
|
52
|
+
allowClear: boolean;
|
|
52
53
|
showSearch: undefined;
|
|
53
54
|
defaultOpen: undefined;
|
|
54
55
|
showArrow: undefined;
|
|
@@ -56,6 +57,7 @@ declare const _default: __VLS_WithTemplateSlots< DefineComponent<__VLS_WithDefau
|
|
|
56
57
|
defaultActiveFirstOption: undefined;
|
|
57
58
|
labelInValue: undefined;
|
|
58
59
|
multiple: undefined;
|
|
60
|
+
searchMode: string;
|
|
59
61
|
}>>> & {
|
|
60
62
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
61
63
|
}, {
|
|
@@ -75,6 +77,7 @@ declare const _default: __VLS_WithTemplateSlots< DefineComponent<__VLS_WithDefau
|
|
|
75
77
|
defaultActiveFirstOption: boolean;
|
|
76
78
|
labelInValue: boolean;
|
|
77
79
|
emptyText: string;
|
|
80
|
+
searchMode: "filter" | "request";
|
|
78
81
|
}, {}>, Readonly<ApFieldSelectSlots> & ApFieldSelectSlots>;
|
|
79
82
|
export default _default;
|
|
80
83
|
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { defineComponent as P, ref as c, onMounted as k, computed as p, unref as
|
|
2
|
-
import { debounce as L, isFunction as h, isArray as z,
|
|
1
|
+
import { defineComponent as P, ref as c, onMounted as k, computed as p, unref as a, openBlock as m, createElementBlock as A, toDisplayString as M, createBlock as O, mergeProps as T, createSlots as q, renderList as N, withCtx as v, renderSlot as _, normalizeProps as R, guardReactiveProps as U, createVNode as D } from "vue";
|
|
2
|
+
import { debounce as L, isFunction as h, isArray as z, isNil as K, omit as H } from "lodash-unified";
|
|
3
3
|
import { Select as $, Spin as j } from "ant-design-vue";
|
|
4
4
|
import "../../hooks/index.mjs";
|
|
5
5
|
import { omitUndefined as E } from "../../utils/index.mjs";
|
|
@@ -50,7 +50,7 @@ const G = { key: 0 }, oe = /* @__PURE__ */ P({
|
|
|
50
50
|
onDeselect: {},
|
|
51
51
|
loading: { type: Boolean, default: void 0 },
|
|
52
52
|
clearIcon: {},
|
|
53
|
-
allowClear: { type: Boolean, default:
|
|
53
|
+
allowClear: { type: Boolean, default: !0 },
|
|
54
54
|
fieldNames: {},
|
|
55
55
|
dropdownStyle: {},
|
|
56
56
|
dropdownRender: {},
|
|
@@ -84,61 +84,70 @@ const G = { key: 0 }, oe = /* @__PURE__ */ P({
|
|
|
84
84
|
request: {},
|
|
85
85
|
multiple: { type: Boolean, default: void 0 },
|
|
86
86
|
value: {},
|
|
87
|
-
"onUpdate:value": {}
|
|
87
|
+
"onUpdate:value": {},
|
|
88
|
+
searchMode: { default: "filter" }
|
|
88
89
|
},
|
|
89
90
|
emits: ["update:value"],
|
|
90
91
|
setup(y, { expose: w, emit: g }) {
|
|
91
|
-
let
|
|
92
|
+
let r = 0;
|
|
92
93
|
const S = (o, t) => typeof (t == null ? void 0 : t.label) == "string" && t.label.indexOf(o) > -1, B = L((o) => {
|
|
93
94
|
if (!h(e.request))
|
|
94
95
|
return;
|
|
95
|
-
|
|
96
|
-
const t =
|
|
97
|
-
|
|
98
|
-
|
|
96
|
+
r += 1;
|
|
97
|
+
const t = r;
|
|
98
|
+
i.value = [], l.value = !0, e.request(o).then((n) => {
|
|
99
|
+
r === t && (i.value = n);
|
|
99
100
|
}).finally(() => {
|
|
100
|
-
|
|
101
|
+
l.value = !1;
|
|
101
102
|
});
|
|
102
|
-
}, 300), e = y,
|
|
103
|
+
}, 300), e = y, i = c((e == null ? void 0 : e.options) || []), d = c(), l = c((e == null ? void 0 : e.loading) || !1), C = g;
|
|
103
104
|
k(() => {
|
|
104
105
|
if (h(e.request)) {
|
|
105
|
-
|
|
106
|
-
const o =
|
|
106
|
+
l.value = !0, r += 1;
|
|
107
|
+
const o = r;
|
|
107
108
|
e.request().then((t) => {
|
|
108
|
-
o ===
|
|
109
|
+
o === r && (i.value = t);
|
|
109
110
|
}).finally(() => {
|
|
110
|
-
|
|
111
|
+
l.value = !1;
|
|
111
112
|
});
|
|
112
113
|
}
|
|
113
114
|
});
|
|
114
115
|
const { value: f, updateValue: b } = W(e, C), x = p(() => {
|
|
115
|
-
const o =
|
|
116
|
+
const o = a(f);
|
|
116
117
|
if (!o)
|
|
117
118
|
return e.emptyText;
|
|
118
119
|
if (z(o))
|
|
119
120
|
return o.map(
|
|
120
|
-
(
|
|
121
|
+
(n) => {
|
|
121
122
|
var u;
|
|
122
|
-
return (u =
|
|
123
|
+
return (u = a(i).find((s) => s.value === n)) == null ? void 0 : u.label;
|
|
123
124
|
}
|
|
124
125
|
).filter(Boolean).join("、") || e.emptyText;
|
|
125
|
-
const t =
|
|
126
|
+
const t = a(i).find((n) => n.value === o);
|
|
126
127
|
return (t == null ? void 0 : t.label) || e.emptyText;
|
|
127
128
|
}), F = p(() => {
|
|
128
|
-
const
|
|
129
|
+
const o = !!(e != null && e.showSearch), t = e.searchMode;
|
|
130
|
+
let n = {};
|
|
131
|
+
return o && (n = t === "request" ? {
|
|
129
132
|
showArrow: !1,
|
|
130
133
|
defaultActiveFirstOption: !1,
|
|
131
134
|
onSearch: B,
|
|
132
|
-
notFoundContent:
|
|
135
|
+
notFoundContent: l.value ? void 0 : null
|
|
133
136
|
} : {
|
|
134
|
-
showArrow: !0
|
|
135
|
-
|
|
136
|
-
|
|
137
|
+
showArrow: !0,
|
|
138
|
+
filterOption: K(e == null ? void 0 : e.filterOption) ? S : e == null ? void 0 : e.filterOption
|
|
139
|
+
}), {
|
|
137
140
|
...E(
|
|
138
|
-
|
|
141
|
+
H(e, [
|
|
142
|
+
"mode",
|
|
143
|
+
"value",
|
|
144
|
+
"onUpdate:value",
|
|
145
|
+
"onSearch",
|
|
146
|
+
"request",
|
|
147
|
+
"searchMode"
|
|
148
|
+
])
|
|
139
149
|
),
|
|
140
|
-
...
|
|
141
|
-
filterOption: e.showSearch ? !1 : H(e == null ? void 0 : e.filterOption) ? S : e == null ? void 0 : e.filterOption
|
|
150
|
+
...n
|
|
142
151
|
};
|
|
143
152
|
});
|
|
144
153
|
function I() {
|
|
@@ -152,28 +161,28 @@ const G = { key: 0 }, oe = /* @__PURE__ */ P({
|
|
|
152
161
|
return w({
|
|
153
162
|
focus: I,
|
|
154
163
|
blur: V
|
|
155
|
-
}), (o, t) => o.mode === "read" ? (m(), A("span", G,
|
|
164
|
+
}), (o, t) => o.mode === "read" ? (m(), A("span", G, M(x.value), 1)) : (m(), O(a($), T({
|
|
156
165
|
key: 1,
|
|
157
166
|
"allow-clear": "",
|
|
158
167
|
ref_key: "selectRef",
|
|
159
168
|
ref: d
|
|
160
169
|
}, F.value, {
|
|
161
170
|
mode: o.multiple ? "multiple" : void 0,
|
|
162
|
-
value:
|
|
163
|
-
"onUpdate:value":
|
|
164
|
-
options:
|
|
165
|
-
loading:
|
|
166
|
-
}),
|
|
167
|
-
|
|
171
|
+
value: a(f),
|
|
172
|
+
"onUpdate:value": a(b),
|
|
173
|
+
options: i.value,
|
|
174
|
+
loading: l.value
|
|
175
|
+
}), q({ _: 2 }, [
|
|
176
|
+
N(o.$slots, (n, u) => ({
|
|
168
177
|
name: u,
|
|
169
178
|
fn: v((s) => [
|
|
170
|
-
|
|
179
|
+
_(o.$slots, u, R(U(s || {})))
|
|
171
180
|
])
|
|
172
181
|
})),
|
|
173
|
-
|
|
182
|
+
l.value ? {
|
|
174
183
|
name: "notFoundContent",
|
|
175
184
|
fn: v(() => [
|
|
176
|
-
D(
|
|
185
|
+
D(a(j), { size: "small" })
|
|
177
186
|
]),
|
|
178
187
|
key: "0"
|
|
179
188
|
} : void 0
|
|
@@ -15,7 +15,7 @@ declare const _default: __VLS_WithTemplateSlots< DefineComponent<__VLS_WithDefau
|
|
|
15
15
|
bordered: boolean;
|
|
16
16
|
type: string;
|
|
17
17
|
lazy: boolean;
|
|
18
|
-
allowClear:
|
|
18
|
+
allowClear: boolean;
|
|
19
19
|
}>, {
|
|
20
20
|
focus: (options?: InputFocusOptions | undefined) => void;
|
|
21
21
|
blur: () => void;
|
|
@@ -30,7 +30,7 @@ declare const _default: __VLS_WithTemplateSlots< DefineComponent<__VLS_WithDefau
|
|
|
30
30
|
bordered: boolean;
|
|
31
31
|
type: string;
|
|
32
32
|
lazy: boolean;
|
|
33
|
-
allowClear:
|
|
33
|
+
allowClear: boolean;
|
|
34
34
|
}>>> & {
|
|
35
35
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
36
36
|
}, {
|
|
@@ -15,7 +15,7 @@ declare const _default: __VLS_WithTemplateSlots< DefineComponent<__VLS_WithDefau
|
|
|
15
15
|
bordered: boolean;
|
|
16
16
|
type: string;
|
|
17
17
|
lazy: boolean;
|
|
18
|
-
allowClear:
|
|
18
|
+
allowClear: boolean;
|
|
19
19
|
visibilityToggle: boolean;
|
|
20
20
|
action: string;
|
|
21
21
|
visible: undefined;
|
|
@@ -31,7 +31,7 @@ declare const _default: __VLS_WithTemplateSlots< DefineComponent<__VLS_WithDefau
|
|
|
31
31
|
bordered: boolean;
|
|
32
32
|
type: string;
|
|
33
33
|
lazy: boolean;
|
|
34
|
-
allowClear:
|
|
34
|
+
allowClear: boolean;
|
|
35
35
|
visibilityToggle: boolean;
|
|
36
36
|
action: string;
|
|
37
37
|
visible: undefined;
|
|
@@ -8,6 +8,7 @@ declare const _default: DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRunt
|
|
|
8
8
|
mode: string;
|
|
9
9
|
type: string;
|
|
10
10
|
lazy: boolean;
|
|
11
|
+
allowClear: boolean;
|
|
11
12
|
}>, {
|
|
12
13
|
focus: (options?: InputFocusOptions | undefined) => void;
|
|
13
14
|
blur: () => void;
|
|
@@ -20,12 +21,14 @@ declare const _default: DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRunt
|
|
|
20
21
|
mode: string;
|
|
21
22
|
type: string;
|
|
22
23
|
lazy: boolean;
|
|
24
|
+
allowClear: boolean;
|
|
23
25
|
}>>> & {
|
|
24
26
|
"onUpdate:value"?: ((...args: any[]) => any) | undefined;
|
|
25
27
|
}, {
|
|
26
28
|
type: "number" | "text" | "color" | "button" | "time" | "image" | "search" | "submit" | "reset" | "hidden" | "tel" | "url" | "email" | "checkbox" | "radio" | "range" | "date" | "week" | "month" | "datetime-local" | "file" | "password";
|
|
27
29
|
mode: FieldMode;
|
|
28
30
|
bordered: boolean;
|
|
31
|
+
allowClear: boolean;
|
|
29
32
|
lazy: boolean;
|
|
30
33
|
emptyText: string;
|
|
31
34
|
}, {}>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { ApFormItemText, ApFormItemTextPassword } from './text';
|
|
2
2
|
import { default as ApFormItemTextArea } from './text-area/index.vue';
|
|
3
3
|
import { default as ApFormItemNumber } from './number/index.vue';
|
|
4
4
|
import { default as ApFormItemDate } from './date/index.vue';
|
|
@@ -8,4 +8,4 @@ import { default as ApFormItemSelect } from './select/index.vue';
|
|
|
8
8
|
import { default as ApFormItemSwitch } from './switch/index.vue';
|
|
9
9
|
import { default as ApFormItemCheckbox } from './checkbox/index.vue';
|
|
10
10
|
|
|
11
|
-
export { ApFormItemText, ApFormItemTextArea, ApFormItemNumber, ApFormItemDate, ApFormItemDateRange, ApFormItemRadio, ApFormItemSelect, ApFormItemSwitch, ApFormItemCheckbox };
|
|
11
|
+
export { ApFormItemText, ApFormItemTextArea, ApFormItemNumber, ApFormItemDate, ApFormItemDateRange, ApFormItemRadio, ApFormItemSelect, ApFormItemSwitch, ApFormItemCheckbox, ApFormItemTextPassword };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "./text/index.
|
|
1
|
+
import { ApFormItemText as F } from "./text/index.mjs";
|
|
2
2
|
import "./text-area/index.vue2.mjs";
|
|
3
3
|
import "./number/index.vue2.mjs";
|
|
4
4
|
import "./date/index.vue2.mjs";
|
|
@@ -7,3 +7,6 @@ import "./radio/index.vue2.mjs";
|
|
|
7
7
|
import "./select/index.vue2.mjs";
|
|
8
8
|
import "./switch/index.vue2.mjs";
|
|
9
9
|
import "./checkbox/index.vue2.mjs";
|
|
10
|
+
export {
|
|
11
|
+
F as ApFormItemText
|
|
12
|
+
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ApFieldCheckboxProps, ApFieldDateProps, ApFieldDateRangeProps, ApFieldNumberProps, ApFieldRadioProps, ApFieldSelectProps, ApFieldSwitchProps, ApFieldTextAreaProps, ApFieldTextProps } from '../../ap-field';
|
|
1
|
+
import { ApFieldCheckboxProps, ApFieldDateProps, ApFieldDateRangeProps, ApFieldNumberProps, ApFieldRadioProps, ApFieldSelectProps, ApFieldSwitchProps, ApFieldTextAreaProps, ApFieldTextPasswordProps, ApFieldTextProps } from '../../ap-field';
|
|
2
2
|
import { ApFormItemProps } from '../interface';
|
|
3
3
|
|
|
4
4
|
export type ApFormItemTextProps = ApFormItemProps & {
|
|
@@ -6,6 +6,11 @@ export type ApFormItemTextProps = ApFormItemProps & {
|
|
|
6
6
|
placeholder?: string;
|
|
7
7
|
disabled?: boolean;
|
|
8
8
|
};
|
|
9
|
+
export type ApFormItemTextPasswordProps = ApFormItemProps & {
|
|
10
|
+
field?: Omit<ApFieldTextPasswordProps, 'value' | 'onUpdate:value'>;
|
|
11
|
+
placeholder?: string;
|
|
12
|
+
disabled?: boolean;
|
|
13
|
+
};
|
|
9
14
|
export type ApFormItemTextAreaProps = Omit<ApFormItemProps, 'bordered'> & {
|
|
10
15
|
field?: Omit<ApFieldTextAreaProps, 'value' | 'onUpdate:value'>;
|
|
11
16
|
placeholder?: string;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { default as _ApFormItemText } from './index.vue';
|
|
2
|
+
import { default as ApFormItemTextPassword } from './password.vue';
|
|
3
|
+
|
|
4
|
+
type ApFormItemTextType = typeof _ApFormItemText & {
|
|
5
|
+
Password: typeof ApFormItemTextPassword;
|
|
6
|
+
};
|
|
7
|
+
declare const ApFormItemText: ApFormItemTextType;
|
|
8
|
+
export { ApFormItemText, ApFormItemTextPassword };
|
|
@@ -1,95 +1,4 @@
|
|
|
1
|
-
import
|
|
2
|
-
import "../../ap-form-item.vue2.mjs";
|
|
3
|
-
import { ApField as R } from "../../../ap-field/index.mjs";
|
|
4
|
-
import { omit as k } from "lodash-unified";
|
|
5
|
-
import C from "../../ap-form-item.vue.mjs";
|
|
6
|
-
const q = /* @__PURE__ */ m({
|
|
7
|
-
name: "ApFormItemText",
|
|
8
|
-
__name: "index",
|
|
9
|
-
props: {
|
|
10
|
-
htmlFor: {},
|
|
11
|
-
prefixCls: {},
|
|
12
|
-
label: {},
|
|
13
|
-
help: {},
|
|
14
|
-
extra: {},
|
|
15
|
-
labelCol: {},
|
|
16
|
-
wrapperCol: {},
|
|
17
|
-
hasFeedback: { type: Boolean, default: !1 },
|
|
18
|
-
colon: { type: Boolean, default: void 0 },
|
|
19
|
-
labelAlign: {},
|
|
20
|
-
prop: {},
|
|
21
|
-
name: {},
|
|
22
|
-
rules: {},
|
|
23
|
-
autoLink: { type: Boolean, default: !0 },
|
|
24
|
-
required: { type: Boolean, default: void 0 },
|
|
25
|
-
validateFirst: { type: Boolean, default: void 0 },
|
|
26
|
-
validateStatus: {},
|
|
27
|
-
validateTrigger: {},
|
|
28
|
-
messageVariables: {},
|
|
29
|
-
hidden: { type: Boolean },
|
|
30
|
-
noStyle: { type: Boolean },
|
|
31
|
-
tooltip: {},
|
|
32
|
-
span: {},
|
|
33
|
-
order: {},
|
|
34
|
-
offset: {},
|
|
35
|
-
push: {},
|
|
36
|
-
pull: {},
|
|
37
|
-
xs: {},
|
|
38
|
-
sm: {},
|
|
39
|
-
md: {},
|
|
40
|
-
lg: {},
|
|
41
|
-
xl: {},
|
|
42
|
-
xxl: {},
|
|
43
|
-
flex: {},
|
|
44
|
-
bordered: { type: Boolean },
|
|
45
|
-
valuePropName: {},
|
|
46
|
-
field: { default: () => ({}) },
|
|
47
|
-
placeholder: {},
|
|
48
|
-
disabled: { type: Boolean, default: !1 }
|
|
49
|
-
},
|
|
50
|
-
setup(p, { expose: i }) {
|
|
51
|
-
const { Text: u } = R, f = p, l = b();
|
|
52
|
-
return i({
|
|
53
|
-
focus: (e) => {
|
|
54
|
-
var o;
|
|
55
|
-
(o = l.value) == null || o.focus(e);
|
|
56
|
-
},
|
|
57
|
-
blur: () => {
|
|
58
|
-
var e;
|
|
59
|
-
(e = l.value) == null || e.blur();
|
|
60
|
-
},
|
|
61
|
-
setSelectionRange: (e, o, a) => {
|
|
62
|
-
var t;
|
|
63
|
-
(t = l.value) == null || t.setSelectionRange(e, o, a);
|
|
64
|
-
},
|
|
65
|
-
select: () => {
|
|
66
|
-
var e;
|
|
67
|
-
(e = l.value) == null || e.select();
|
|
68
|
-
},
|
|
69
|
-
input: v(() => {
|
|
70
|
-
var e;
|
|
71
|
-
return (e = l.value) == null ? void 0 : e.input;
|
|
72
|
-
})
|
|
73
|
-
}), (e, o) => (h(), y(C, r(s(n(k)(f, ["field", "disabled", "placeholder"]))), {
|
|
74
|
-
default: d(() => [
|
|
75
|
-
B(n(u), g({
|
|
76
|
-
ref_key: "inputRef",
|
|
77
|
-
ref: l,
|
|
78
|
-
disabled: e.disabled,
|
|
79
|
-
placeholder: e.placeholder
|
|
80
|
-
}, e.field), x({ _: 2 }, [
|
|
81
|
-
S(e.$slots, (a, t) => ({
|
|
82
|
-
name: t,
|
|
83
|
-
fn: d((c) => [
|
|
84
|
-
_(e.$slots, t, r(s(c || {})))
|
|
85
|
-
])
|
|
86
|
-
}))
|
|
87
|
-
]), 1040, ["disabled", "placeholder"])
|
|
88
|
-
]),
|
|
89
|
-
_: 3
|
|
90
|
-
}, 16));
|
|
91
|
-
}
|
|
92
|
-
});
|
|
1
|
+
import f from "./index.vue2.mjs";
|
|
93
2
|
export {
|
|
94
|
-
|
|
3
|
+
f as default
|
|
95
4
|
};
|
|
@@ -1,4 +1,95 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { defineComponent as m, ref as b, computed as v, openBlock as h, createBlock as y, normalizeProps as r, guardReactiveProps as s, unref as n, withCtx as d, createVNode as B, mergeProps as g, createSlots as x, renderList as S, renderSlot as _ } from "vue";
|
|
2
|
+
import "../../ap-form-item.vue2.mjs";
|
|
3
|
+
import { ApField as R } from "../../../ap-field/index.mjs";
|
|
4
|
+
import { omit as k } from "lodash-unified";
|
|
5
|
+
import C from "../../ap-form-item.vue.mjs";
|
|
6
|
+
const q = /* @__PURE__ */ m({
|
|
7
|
+
name: "ApFormItemText",
|
|
8
|
+
__name: "index",
|
|
9
|
+
props: {
|
|
10
|
+
htmlFor: {},
|
|
11
|
+
prefixCls: {},
|
|
12
|
+
label: {},
|
|
13
|
+
help: {},
|
|
14
|
+
extra: {},
|
|
15
|
+
labelCol: {},
|
|
16
|
+
wrapperCol: {},
|
|
17
|
+
hasFeedback: { type: Boolean, default: !1 },
|
|
18
|
+
colon: { type: Boolean, default: void 0 },
|
|
19
|
+
labelAlign: {},
|
|
20
|
+
prop: {},
|
|
21
|
+
name: {},
|
|
22
|
+
rules: {},
|
|
23
|
+
autoLink: { type: Boolean, default: !0 },
|
|
24
|
+
required: { type: Boolean, default: void 0 },
|
|
25
|
+
validateFirst: { type: Boolean, default: void 0 },
|
|
26
|
+
validateStatus: {},
|
|
27
|
+
validateTrigger: {},
|
|
28
|
+
messageVariables: {},
|
|
29
|
+
hidden: { type: Boolean },
|
|
30
|
+
noStyle: { type: Boolean },
|
|
31
|
+
tooltip: {},
|
|
32
|
+
span: {},
|
|
33
|
+
order: {},
|
|
34
|
+
offset: {},
|
|
35
|
+
push: {},
|
|
36
|
+
pull: {},
|
|
37
|
+
xs: {},
|
|
38
|
+
sm: {},
|
|
39
|
+
md: {},
|
|
40
|
+
lg: {},
|
|
41
|
+
xl: {},
|
|
42
|
+
xxl: {},
|
|
43
|
+
flex: {},
|
|
44
|
+
bordered: { type: Boolean },
|
|
45
|
+
valuePropName: {},
|
|
46
|
+
field: { default: () => ({}) },
|
|
47
|
+
placeholder: {},
|
|
48
|
+
disabled: { type: Boolean, default: !1 }
|
|
49
|
+
},
|
|
50
|
+
setup(p, { expose: i }) {
|
|
51
|
+
const { Text: u } = R, f = p, l = b();
|
|
52
|
+
return i({
|
|
53
|
+
focus: (e) => {
|
|
54
|
+
var o;
|
|
55
|
+
(o = l.value) == null || o.focus(e);
|
|
56
|
+
},
|
|
57
|
+
blur: () => {
|
|
58
|
+
var e;
|
|
59
|
+
(e = l.value) == null || e.blur();
|
|
60
|
+
},
|
|
61
|
+
setSelectionRange: (e, o, a) => {
|
|
62
|
+
var t;
|
|
63
|
+
(t = l.value) == null || t.setSelectionRange(e, o, a);
|
|
64
|
+
},
|
|
65
|
+
select: () => {
|
|
66
|
+
var e;
|
|
67
|
+
(e = l.value) == null || e.select();
|
|
68
|
+
},
|
|
69
|
+
input: v(() => {
|
|
70
|
+
var e;
|
|
71
|
+
return (e = l.value) == null ? void 0 : e.input;
|
|
72
|
+
})
|
|
73
|
+
}), (e, o) => (h(), y(C, r(s(n(k)(f, ["field", "disabled", "placeholder"]))), {
|
|
74
|
+
default: d(() => [
|
|
75
|
+
B(n(u), g({
|
|
76
|
+
ref_key: "inputRef",
|
|
77
|
+
ref: l,
|
|
78
|
+
disabled: e.disabled,
|
|
79
|
+
placeholder: e.placeholder
|
|
80
|
+
}, e.field), x({ _: 2 }, [
|
|
81
|
+
S(e.$slots, (a, t) => ({
|
|
82
|
+
name: t,
|
|
83
|
+
fn: d((c) => [
|
|
84
|
+
_(e.$slots, t, r(s(c || {})))
|
|
85
|
+
])
|
|
86
|
+
}))
|
|
87
|
+
]), 1040, ["disabled", "placeholder"])
|
|
88
|
+
]),
|
|
89
|
+
_: 3
|
|
90
|
+
}, 16));
|
|
91
|
+
}
|
|
92
|
+
});
|
|
2
93
|
export {
|
|
3
|
-
|
|
94
|
+
q as default
|
|
4
95
|
};
|