@aplus-frontend/ui 0.0.35 → 0.0.37
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 +16 -14
- package/es/src/ap-descriptions/ap-descriptions.vue.d.ts +27 -0
- package/es/src/ap-descriptions/ap-descriptions.vue.mjs +97 -0
- package/es/src/ap-descriptions/ap-descriptions.vue2.mjs +5 -0
- package/es/src/ap-descriptions/formatter/index.d.ts +78 -0
- package/es/src/ap-descriptions/formatter/index.mjs +127 -0
- package/es/src/ap-descriptions/formatter/utils.d.ts +7 -0
- package/es/src/ap-descriptions/formatter/utils.mjs +6 -0
- package/es/src/ap-descriptions/help-message/index.vue.d.ts +23 -0
- package/es/src/ap-descriptions/help-message/index.vue.mjs +4 -0
- package/es/src/ap-descriptions/help-message/index.vue2.mjs +27 -0
- package/es/src/ap-descriptions/helper.d.ts +10 -0
- package/es/src/ap-descriptions/helper.mjs +24 -0
- package/es/src/ap-descriptions/index.d.ts +4 -0
- package/es/src/ap-descriptions/index.mjs +2 -0
- package/es/src/ap-descriptions/interface.d.ts +50 -0
- package/es/src/ap-descriptions/interface.mjs +1 -0
- package/es/src/ap-descriptions/style/ap-descriptions.css +57 -0
- package/es/src/ap-download/ap-download.vue.mjs +27 -21
- package/es/src/ap-field/date/index.vue.mjs +35 -33
- package/es/src/ap-field/date-range/index.vue.mjs +55 -53
- package/es/src/ap-field/hooks/use-default-placeholder.d.ts +16 -0
- package/es/src/ap-field/hooks/use-default-placeholder.mjs +25 -0
- package/es/src/ap-field/interface.d.ts +4 -3
- package/es/src/ap-field/number/index.vue.mjs +25 -23
- package/es/src/ap-field/select/index.vue.d.ts +2 -0
- package/es/src/ap-field/select/index.vue.mjs +63 -53
- package/es/src/ap-field/text/index.vue2.mjs +26 -24
- package/es/src/ap-field/text/password.vue.mjs +28 -26
- package/es/src/ap-field/text-area/index.vue.mjs +15 -13
- package/es/src/ap-table/constants.d.ts +9 -0
- package/es/src/config-provider/config-provider-props.d.ts +5 -1
- package/es/src/config-provider/config-provider-props.mjs +6 -2
- package/es/src/config-provider/config-provider.d.ts +14 -1
- package/es/src/config-provider/config-provider.mjs +17 -16
- package/es/src/config-provider/constants.d.ts +3 -0
- package/es/src/config-provider/hooks/use-global-config.d.ts +5 -1
- package/es/src/config-provider/index.d.ts +20 -1
- package/es/src/index.d.ts +1 -0
- package/es/src/index.mjs +241 -238
- package/es/src/theme/ap-descriptions/ap-descriptions.css +57 -0
- package/lib/index.js +1 -1
- package/lib/src/ap-descriptions/ap-descriptions.vue.d.ts +27 -0
- package/lib/src/ap-descriptions/ap-descriptions.vue.js +1 -0
- package/lib/src/ap-descriptions/ap-descriptions.vue2.js +1 -0
- package/lib/src/ap-descriptions/formatter/index.d.ts +78 -0
- package/lib/src/ap-descriptions/formatter/index.js +1 -0
- package/lib/src/ap-descriptions/formatter/utils.d.ts +7 -0
- package/lib/src/ap-descriptions/formatter/utils.js +1 -0
- package/lib/src/ap-descriptions/help-message/index.vue.d.ts +23 -0
- package/lib/src/ap-descriptions/help-message/index.vue.js +1 -0
- package/lib/src/ap-descriptions/help-message/index.vue2.js +1 -0
- package/lib/src/ap-descriptions/helper.d.ts +10 -0
- package/lib/src/ap-descriptions/helper.js +1 -0
- package/lib/src/ap-descriptions/index.d.ts +4 -0
- package/lib/src/ap-descriptions/index.js +1 -0
- package/lib/src/ap-descriptions/interface.d.ts +50 -0
- package/lib/src/ap-descriptions/interface.js +1 -0
- package/lib/src/ap-descriptions/style/ap-descriptions.css +57 -0
- package/lib/src/ap-download/ap-download.vue.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/hooks/use-default-placeholder.d.ts +16 -0
- package/lib/src/ap-field/hooks/use-default-placeholder.js +1 -0
- package/lib/src/ap-field/interface.d.ts +4 -3
- package/lib/src/ap-field/number/index.vue.js +1 -1
- package/lib/src/ap-field/select/index.vue.d.ts +2 -0
- package/lib/src/ap-field/select/index.vue.js +1 -1
- package/lib/src/ap-field/text/index.vue2.js +1 -1
- package/lib/src/ap-field/text/password.vue.js +1 -1
- package/lib/src/ap-field/text-area/index.vue.js +1 -1
- package/lib/src/ap-table/constants.d.ts +9 -0
- package/lib/src/config-provider/config-provider-props.d.ts +5 -1
- package/lib/src/config-provider/config-provider-props.js +1 -1
- package/lib/src/config-provider/config-provider.d.ts +14 -1
- package/lib/src/config-provider/config-provider.js +1 -1
- package/lib/src/config-provider/constants.d.ts +3 -0
- package/lib/src/config-provider/hooks/use-global-config.d.ts +5 -1
- package/lib/src/config-provider/index.d.ts +20 -1
- package/lib/src/index.d.ts +1 -0
- package/lib/src/index.js +1 -1
- package/lib/src/theme/ap-descriptions/ap-descriptions.css +57 -0
- package/package.json +1 -1
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { debounce as
|
|
3
|
-
import { Select as
|
|
1
|
+
import { defineComponent as k, ref as c, onMounted as q, computed as m, unref as a, openBlock as v, createElementBlock as A, toDisplayString as M, createBlock as O, mergeProps as T, createSlots as _, renderList as R, withCtx as h, renderSlot as D, normalizeProps as U, guardReactiveProps as L, createVNode as z } from "vue";
|
|
2
|
+
import { debounce as K, isFunction as y, isArray as H, isNil as $, omit as j } from "lodash-unified";
|
|
3
|
+
import { Select as E, Spin as W } from "ant-design-vue";
|
|
4
4
|
import "../../hooks/index.mjs";
|
|
5
|
-
import { omitUndefined as
|
|
6
|
-
import {
|
|
7
|
-
|
|
5
|
+
import { omitUndefined as G } from "../../utils/index.mjs";
|
|
6
|
+
import { useDefaultPlaceholder as J } from "../hooks/use-default-placeholder.mjs";
|
|
7
|
+
import { useControllableValue as Q } from "../../hooks/useControllableValue.mjs";
|
|
8
|
+
const X = { key: 0 }, ae = /* @__PURE__ */ k({
|
|
8
9
|
name: "ApFieldSelect",
|
|
9
10
|
__name: "index",
|
|
10
11
|
props: {
|
|
@@ -90,61 +91,68 @@ const G = { key: 0 }, oe = /* @__PURE__ */ P({
|
|
|
90
91
|
searchMode: { default: "filter" }
|
|
91
92
|
},
|
|
92
93
|
emits: ["update:value"],
|
|
93
|
-
setup(
|
|
94
|
+
setup(w, { expose: S, emit: g }) {
|
|
94
95
|
let i = 0;
|
|
95
|
-
const
|
|
96
|
-
if (!
|
|
96
|
+
const B = K((o) => {
|
|
97
|
+
if (!y(e.request))
|
|
97
98
|
return;
|
|
98
99
|
i += 1;
|
|
99
100
|
const t = i;
|
|
100
|
-
|
|
101
|
-
i === t && (
|
|
101
|
+
r.value = [], u.value = !0, e.request(o).then((l) => {
|
|
102
|
+
i === t && (r.value = l);
|
|
102
103
|
}).finally(() => {
|
|
103
|
-
|
|
104
|
+
u.value = !1;
|
|
104
105
|
});
|
|
105
|
-
}, 300), e =
|
|
106
|
+
}, 300), e = w, b = (o, t) => {
|
|
106
107
|
var n;
|
|
107
108
|
const l = ((n = e.fieldNames) == null ? void 0 : n.label) || "label";
|
|
108
109
|
return typeof (t == null ? void 0 : t.label) == "string" && t[l].indexOf(o) > -1;
|
|
109
|
-
},
|
|
110
|
-
|
|
111
|
-
if (
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
110
|
+
}, r = c((e == null ? void 0 : e.options) || []), d = c(), u = c((e == null ? void 0 : e.loading) || !1), C = g;
|
|
111
|
+
async function f(o = !0) {
|
|
112
|
+
if (!y(e.request))
|
|
113
|
+
return;
|
|
114
|
+
u.value = !0, i += 1;
|
|
115
|
+
const t = i;
|
|
116
|
+
try {
|
|
117
|
+
o && (r.value = []);
|
|
118
|
+
const l = await e.request();
|
|
119
|
+
if (t !== i)
|
|
120
|
+
return;
|
|
121
|
+
r.value = l;
|
|
122
|
+
} finally {
|
|
123
|
+
u.value = !1;
|
|
119
124
|
}
|
|
125
|
+
}
|
|
126
|
+
q(() => {
|
|
127
|
+
f();
|
|
120
128
|
});
|
|
121
|
-
const { value:
|
|
122
|
-
const o =
|
|
129
|
+
const { value: p, updateValue: x } = Q(e, C), F = J("Select", e), I = m(() => {
|
|
130
|
+
const o = a(p);
|
|
123
131
|
if (!o)
|
|
124
132
|
return e.emptyText;
|
|
125
|
-
if (
|
|
133
|
+
if (H(o))
|
|
126
134
|
return o.map(
|
|
127
135
|
(l) => {
|
|
128
136
|
var n;
|
|
129
|
-
return (n = r
|
|
137
|
+
return (n = a(r).find((s) => s.value === l)) == null ? void 0 : n.label;
|
|
130
138
|
}
|
|
131
139
|
).filter(Boolean).join("、") || e.emptyText;
|
|
132
|
-
const t = r
|
|
140
|
+
const t = a(r).find((l) => l.value === o);
|
|
133
141
|
return (t == null ? void 0 : t.label) || e.emptyText;
|
|
134
|
-
}),
|
|
142
|
+
}), P = m(() => {
|
|
135
143
|
const o = !!(e != null && e.showSearch), t = e.searchMode;
|
|
136
144
|
let l = {};
|
|
137
145
|
return o && (l = t === "request" ? {
|
|
138
146
|
showArrow: !1,
|
|
139
147
|
defaultActiveFirstOption: !1,
|
|
140
|
-
onSearch:
|
|
141
|
-
notFoundContent:
|
|
148
|
+
onSearch: B,
|
|
149
|
+
notFoundContent: u.value ? void 0 : null
|
|
142
150
|
} : {
|
|
143
151
|
showArrow: !0,
|
|
144
|
-
filterOption:
|
|
152
|
+
filterOption: $(e == null ? void 0 : e.filterOption) ? b : e == null ? void 0 : e.filterOption
|
|
145
153
|
}), {
|
|
146
|
-
...
|
|
147
|
-
|
|
154
|
+
...G(
|
|
155
|
+
j(e, [
|
|
148
156
|
"mode",
|
|
149
157
|
"value",
|
|
150
158
|
"onUpdate:value",
|
|
@@ -153,42 +161,44 @@ const G = { key: 0 }, oe = /* @__PURE__ */ P({
|
|
|
153
161
|
"searchMode"
|
|
154
162
|
])
|
|
155
163
|
),
|
|
164
|
+
placeholder: a(F),
|
|
156
165
|
...l
|
|
157
166
|
};
|
|
158
167
|
});
|
|
159
|
-
function
|
|
168
|
+
function V() {
|
|
160
169
|
var o;
|
|
161
170
|
(o = d.value) == null || o.focus();
|
|
162
171
|
}
|
|
163
|
-
function
|
|
172
|
+
function N() {
|
|
164
173
|
var o;
|
|
165
174
|
(o = d.value) == null || o.blur();
|
|
166
175
|
}
|
|
167
|
-
return
|
|
168
|
-
focus:
|
|
169
|
-
blur:
|
|
170
|
-
|
|
176
|
+
return S({
|
|
177
|
+
focus: V,
|
|
178
|
+
blur: N,
|
|
179
|
+
request: f
|
|
180
|
+
}), (o, t) => o.mode === "read" ? (v(), A("span", X, M(I.value), 1)) : (v(), O(a(E), T({
|
|
171
181
|
key: 1,
|
|
172
182
|
"allow-clear": "",
|
|
173
183
|
ref_key: "selectRef",
|
|
174
184
|
ref: d
|
|
175
|
-
},
|
|
185
|
+
}, P.value, {
|
|
176
186
|
mode: o.multiple ? "multiple" : void 0,
|
|
177
|
-
value:
|
|
178
|
-
"onUpdate:value":
|
|
179
|
-
options:
|
|
180
|
-
loading:
|
|
181
|
-
}),
|
|
182
|
-
|
|
187
|
+
value: a(p),
|
|
188
|
+
"onUpdate:value": a(x),
|
|
189
|
+
options: r.value,
|
|
190
|
+
loading: u.value
|
|
191
|
+
}), _({ _: 2 }, [
|
|
192
|
+
R(o.$slots, (l, n) => ({
|
|
183
193
|
name: n,
|
|
184
|
-
fn:
|
|
185
|
-
|
|
194
|
+
fn: h((s) => [
|
|
195
|
+
D(o.$slots, n, U(L(s || {})))
|
|
186
196
|
])
|
|
187
197
|
})),
|
|
188
|
-
|
|
198
|
+
u.value ? {
|
|
189
199
|
name: "notFoundContent",
|
|
190
|
-
fn:
|
|
191
|
-
|
|
200
|
+
fn: h(() => [
|
|
201
|
+
z(a(W), { size: "small" })
|
|
192
202
|
]),
|
|
193
203
|
key: "0"
|
|
194
204
|
} : void 0
|
|
@@ -196,5 +206,5 @@ const G = { key: 0 }, oe = /* @__PURE__ */ P({
|
|
|
196
206
|
}
|
|
197
207
|
});
|
|
198
208
|
export {
|
|
199
|
-
|
|
209
|
+
ae as default
|
|
200
210
|
};
|
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import { isVNode as
|
|
1
|
+
import { isVNode as v, defineComponent as B, ref as g, useSlots as h, computed as b, createVNode as i, mergeProps as C, unref as u, Fragment as S, openBlock as _, createBlock as R, resolveDynamicComponent as T } from "vue";
|
|
2
2
|
import { Input as V } from "ant-design-vue";
|
|
3
3
|
import "../../hooks/index.mjs";
|
|
4
4
|
import { omit as j } from "lodash-unified";
|
|
5
|
-
import {
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
import { useDefaultPlaceholder as F } from "../hooks/use-default-placeholder.mjs";
|
|
6
|
+
import { useControllableValue as w } from "../../hooks/useControllableValue.mjs";
|
|
7
|
+
function z(l) {
|
|
8
|
+
return typeof l == "function" || Object.prototype.toString.call(l) === "[object Object]" && !v(l);
|
|
8
9
|
}
|
|
9
|
-
const
|
|
10
|
+
const M = /* @__PURE__ */ B({
|
|
10
11
|
name: "ApFieldText",
|
|
11
12
|
__name: "index",
|
|
12
13
|
props: {
|
|
@@ -90,46 +91,47 @@ const K = /* @__PURE__ */ v({
|
|
|
90
91
|
expose: c,
|
|
91
92
|
emit: d
|
|
92
93
|
}) {
|
|
93
|
-
const
|
|
94
|
+
const a = g(), t = h();
|
|
94
95
|
c({
|
|
95
96
|
focus: (e) => {
|
|
96
97
|
var o;
|
|
97
|
-
(o =
|
|
98
|
+
(o = a.value) == null || o.focus(e);
|
|
98
99
|
},
|
|
99
100
|
blur: () => {
|
|
100
101
|
var e;
|
|
101
|
-
(e =
|
|
102
|
+
(e = a.value) == null || e.blur();
|
|
102
103
|
},
|
|
103
|
-
setSelectionRange: (e, o,
|
|
104
|
-
var
|
|
105
|
-
(
|
|
104
|
+
setSelectionRange: (e, o, x) => {
|
|
105
|
+
var p;
|
|
106
|
+
(p = a.value) == null || p.setSelectionRange(e, o, x);
|
|
106
107
|
},
|
|
107
108
|
select: () => {
|
|
108
109
|
var e;
|
|
109
|
-
(e =
|
|
110
|
+
(e = a.value) == null || e.select();
|
|
110
111
|
},
|
|
111
112
|
input: b(() => {
|
|
112
113
|
var e;
|
|
113
|
-
return (e =
|
|
114
|
+
return (e = a.value) == null ? void 0 : e.input;
|
|
114
115
|
})
|
|
115
116
|
});
|
|
116
|
-
const f = d,
|
|
117
|
-
value:
|
|
117
|
+
const f = d, n = l, {
|
|
118
|
+
value: r,
|
|
118
119
|
updateValue: s
|
|
119
|
-
} =
|
|
120
|
-
function
|
|
120
|
+
} = w(n, f), m = F("Text", n);
|
|
121
|
+
function y() {
|
|
121
122
|
var e, o;
|
|
122
|
-
return
|
|
123
|
-
|
|
123
|
+
return n.mode === "edit" ? i(V, C(j(n, ["mode", "emptyText", "value", "onUpdate:value"]), {
|
|
124
|
+
placeholder: u(m),
|
|
125
|
+
value: u(r),
|
|
124
126
|
"onUpdate:value": s,
|
|
125
|
-
ref:
|
|
126
|
-
}),
|
|
127
|
+
ref: a
|
|
128
|
+
}), z(t) ? t : {
|
|
127
129
|
default: () => [t]
|
|
128
|
-
}) :
|
|
130
|
+
}) : i(S, null, [n.prefix || ((e = t == null ? void 0 : t.prefix) == null ? void 0 : e.call(t)), u(r) || n.emptyText, n.suffix || ((o = t == null ? void 0 : t.suffix) == null ? void 0 : o.call(t))]);
|
|
129
131
|
}
|
|
130
|
-
return (e, o) => (
|
|
132
|
+
return (e, o) => (_(), R(T(y())));
|
|
131
133
|
}
|
|
132
134
|
});
|
|
133
135
|
export {
|
|
134
|
-
|
|
136
|
+
M as default
|
|
135
137
|
};
|
|
@@ -1,13 +1,14 @@
|
|
|
1
|
-
import { isVNode as
|
|
2
|
-
import { Input as
|
|
1
|
+
import { isVNode as x, defineComponent as h, ref as C, useSlots as g, unref as i, createVNode as o, mergeProps as P, Fragment as w, openBlock as V, createBlock as _, resolveDynamicComponent as S } from "vue";
|
|
2
|
+
import { Input as T, Space as U } from "ant-design-vue";
|
|
3
3
|
import "../../hooks/index.mjs";
|
|
4
4
|
import { omit as O } from "lodash-unified";
|
|
5
|
-
import { EyeOutlined as
|
|
5
|
+
import { EyeOutlined as j, EyeInvisibleOutlined as k } from "@ant-design/icons-vue";
|
|
6
|
+
import { useDefaultPlaceholder as E } from "../hooks/use-default-placeholder.mjs";
|
|
6
7
|
import { useControllableValue as d } from "../../hooks/useControllableValue.mjs";
|
|
7
|
-
function
|
|
8
|
-
return typeof
|
|
8
|
+
function F(l) {
|
|
9
|
+
return typeof l == "function" || Object.prototype.toString.call(l) === "[object Object]" && !x(l);
|
|
9
10
|
}
|
|
10
|
-
const
|
|
11
|
+
const G = /* @__PURE__ */ h({
|
|
11
12
|
name: "ApFieldTextPassword",
|
|
12
13
|
__name: "password",
|
|
13
14
|
props: {
|
|
@@ -100,7 +101,7 @@ const D = /* @__PURE__ */ x({
|
|
|
100
101
|
}
|
|
101
102
|
},
|
|
102
103
|
emits: ["update:value", "update:visible"],
|
|
103
|
-
setup(
|
|
104
|
+
setup(l, {
|
|
104
105
|
expose: c,
|
|
105
106
|
emit: f
|
|
106
107
|
}) {
|
|
@@ -115,40 +116,41 @@ const D = /* @__PURE__ */ x({
|
|
|
115
116
|
(e = a.value) == null || e.blur();
|
|
116
117
|
}
|
|
117
118
|
});
|
|
118
|
-
const
|
|
119
|
+
const s = f, t = l, {
|
|
119
120
|
value: m,
|
|
120
121
|
updateValue: y
|
|
121
|
-
} = d(
|
|
122
|
-
value:
|
|
123
|
-
updateValue:
|
|
124
|
-
} = d(
|
|
122
|
+
} = d(t, s), v = E("TextPassword", t), {
|
|
123
|
+
value: b,
|
|
124
|
+
updateValue: r
|
|
125
|
+
} = d(t, s, {
|
|
125
126
|
valuePropName: "visible"
|
|
126
127
|
});
|
|
127
|
-
function
|
|
128
|
-
const e =
|
|
129
|
-
if (
|
|
130
|
-
return
|
|
128
|
+
function B() {
|
|
129
|
+
const e = i(m), n = i(b);
|
|
130
|
+
if (t.mode === "edit")
|
|
131
|
+
return o(T.Password, P(O(t, ["mode", "emptyText", "value", "onUpdate:value", "visible", "onUpdate:visible"]), {
|
|
132
|
+
placeholder: i(v),
|
|
131
133
|
value: e,
|
|
132
134
|
"onUpdate:value": y,
|
|
133
135
|
visible: n,
|
|
134
|
-
"onUpdate:visible":
|
|
136
|
+
"onUpdate:visible": r,
|
|
135
137
|
ref: a
|
|
136
|
-
}),
|
|
138
|
+
}), F(u) ? u : {
|
|
137
139
|
default: () => [u]
|
|
138
140
|
});
|
|
139
|
-
let
|
|
140
|
-
return e && (
|
|
141
|
-
default: () => [
|
|
141
|
+
let p = o(w, null, [t.emptyText]);
|
|
142
|
+
return e && (p = o(U, null, {
|
|
143
|
+
default: () => [o("span", null, [n ? e : "********"]), o("span", {
|
|
142
144
|
style: {
|
|
143
145
|
cursor: "pointer"
|
|
144
146
|
},
|
|
145
|
-
onClick: () =>
|
|
146
|
-
}, [n ?
|
|
147
|
-
})),
|
|
147
|
+
onClick: () => r(!n)
|
|
148
|
+
}, [n ? o(j, null, null) : o(k, null, null)])]
|
|
149
|
+
})), p;
|
|
148
150
|
}
|
|
149
|
-
return (e, n) => (
|
|
151
|
+
return (e, n) => (V(), _(S(B())));
|
|
150
152
|
}
|
|
151
153
|
});
|
|
152
154
|
export {
|
|
153
|
-
|
|
155
|
+
G as default
|
|
154
156
|
};
|
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { isNil as C, omit as
|
|
1
|
+
import { defineComponent as f, ref as y, computed as B, openBlock as r, createElementBlock as x, normalizeClass as v, unref as o, toDisplayString as h, createBlock as b, mergeProps as z } from "vue";
|
|
2
|
+
import { isNil as C, omit as A } from "lodash-unified";
|
|
3
3
|
import "../../hooks/index.mjs";
|
|
4
4
|
import "../../config-provider/index.mjs";
|
|
5
5
|
import { Input as g } from "ant-design-vue";
|
|
6
6
|
import "./style.css";
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
|
|
7
|
+
import { useDefaultPlaceholder as T } from "../hooks/use-default-placeholder.mjs";
|
|
8
|
+
import { useControllableValue as k } from "../../hooks/useControllableValue.mjs";
|
|
9
|
+
import { useNamespace as _ } from "../../config-provider/hooks/use-namespace.mjs";
|
|
10
|
+
const S = /* @__PURE__ */ f({
|
|
10
11
|
name: "ApFieldTextArea",
|
|
11
12
|
__name: "index",
|
|
12
13
|
props: {
|
|
@@ -58,31 +59,32 @@ const I = /* @__PURE__ */ c({
|
|
|
58
59
|
},
|
|
59
60
|
emits: ["update:value"],
|
|
60
61
|
setup(u, { expose: p, emit: s }) {
|
|
61
|
-
const t =
|
|
62
|
+
const t = y(), l = u, i = s, { value: a, updateValue: d } = k(l, i), { b: m } = _("field-text-area"), c = T("TextArea", l);
|
|
62
63
|
return p({
|
|
63
64
|
focus: (e) => {
|
|
64
|
-
var
|
|
65
|
-
(
|
|
65
|
+
var n;
|
|
66
|
+
(n = t.value) == null || n.focus(e);
|
|
66
67
|
},
|
|
67
68
|
blur: () => {
|
|
68
69
|
var e;
|
|
69
70
|
(e = t.value) == null || e.blur();
|
|
70
71
|
},
|
|
71
|
-
resizableTextArea:
|
|
72
|
+
resizableTextArea: B(() => {
|
|
72
73
|
var e;
|
|
73
74
|
return (e = t.value) == null ? void 0 : e.resizableTextArea;
|
|
74
75
|
})
|
|
75
|
-
}), (e,
|
|
76
|
+
}), (e, n) => e.mode === "read" ? (r(), x("span", {
|
|
76
77
|
key: 0,
|
|
77
78
|
class: v(o(m)())
|
|
78
|
-
},
|
|
79
|
+
}, h(o(C)(o(a)) || o(a) === "" ? e.emptyText : o(a)), 3)) : (r(), b(o(g).TextArea, z({ key: 1 }, o(A)(l, ["onUpdate:value", "value"]), {
|
|
80
|
+
placeholder: o(c),
|
|
79
81
|
value: o(a),
|
|
80
82
|
"onUpdate:value": o(d),
|
|
81
83
|
ref_key: "textAreaRef",
|
|
82
84
|
ref: t
|
|
83
|
-
}), null, 16, ["value", "onUpdate:value"]));
|
|
85
|
+
}), null, 16, ["placeholder", "value", "onUpdate:value"]));
|
|
84
86
|
}
|
|
85
87
|
});
|
|
86
88
|
export {
|
|
87
|
-
|
|
89
|
+
S as default
|
|
88
90
|
};
|
|
@@ -12144,6 +12144,7 @@ export declare const apTableRenderItemMap: {
|
|
|
12144
12144
|
}, {
|
|
12145
12145
|
focus: () => void;
|
|
12146
12146
|
blur: () => void;
|
|
12147
|
+
request: (clear?: boolean) => Promise<void>;
|
|
12147
12148
|
}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
|
|
12148
12149
|
"update:value": (...args: any[]) => void;
|
|
12149
12150
|
}, VNodeProps & AllowedComponentProps & ComponentCustomProps & Readonly< ExtractPropTypes<{
|
|
@@ -12694,6 +12695,7 @@ export declare const apTableRenderItemMap: {
|
|
|
12694
12695
|
}, {
|
|
12695
12696
|
focus: () => void;
|
|
12696
12697
|
blur: () => void;
|
|
12698
|
+
request: (clear?: boolean) => Promise<void>;
|
|
12697
12699
|
}, {}, {}, {}, {
|
|
12698
12700
|
disabled: boolean;
|
|
12699
12701
|
loading: boolean;
|
|
@@ -12979,6 +12981,7 @@ export declare const apTableRenderItemMap: {
|
|
|
12979
12981
|
}, {
|
|
12980
12982
|
focus: () => void;
|
|
12981
12983
|
blur: () => void;
|
|
12984
|
+
request: (clear?: boolean) => Promise<void>;
|
|
12982
12985
|
}, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
|
|
12983
12986
|
"update:value": (...args: any[]) => void;
|
|
12984
12987
|
}, string, {
|
|
@@ -15204,12 +15207,18 @@ export declare const apTableRenderItemMap: {
|
|
|
15204
15207
|
$slots: Readonly<{
|
|
15205
15208
|
addonAfter: any;
|
|
15206
15209
|
addonBefore: any;
|
|
15210
|
+
/**
|
|
15211
|
+
* 表格到查询表单的映射
|
|
15212
|
+
*/
|
|
15207
15213
|
prefix: any;
|
|
15208
15214
|
suffix: any;
|
|
15209
15215
|
clearIcon: any;
|
|
15210
15216
|
}> & {
|
|
15211
15217
|
addonAfter: any;
|
|
15212
15218
|
addonBefore: any;
|
|
15219
|
+
/**
|
|
15220
|
+
* 表格到查询表单的映射
|
|
15221
|
+
*/
|
|
15213
15222
|
prefix: any;
|
|
15214
15223
|
suffix: any;
|
|
15215
15224
|
clearIcon: any;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ExtractPropTypes, PropType } from 'vue';
|
|
2
2
|
import { LocaleType } from '../locale/interface';
|
|
3
|
-
import { ApiType, ScrollbarGlobalConfig, TableDefaultConfig, ApUploadConfig } from './constants';
|
|
3
|
+
import { ApiType, ScrollbarGlobalConfig, TableDefaultConfig, ApUploadConfig, ApDescriptionsConfig } from './constants';
|
|
4
4
|
import { default as __DTS_DEFAULT_0__ } from 'ant-design-vue/es/config-provider/renderEmpty';
|
|
5
5
|
import { TransformCellTextProps } from 'ant-design-vue/es/table/interface';
|
|
6
6
|
import { CSPConfig, SizeType, ThemeConfig } from 'ant-design-vue/es/config-provider/context';
|
|
@@ -152,5 +152,9 @@ export declare const configProviderProps: () => {
|
|
|
152
152
|
type: PropType<ApUploadConfig>;
|
|
153
153
|
default: () => {};
|
|
154
154
|
};
|
|
155
|
+
apDescriptions: {
|
|
156
|
+
type: PropType<ApDescriptionsConfig>;
|
|
157
|
+
default: () => {};
|
|
158
|
+
};
|
|
155
159
|
};
|
|
156
160
|
export type ConfigProviderProps = Partial<ExtractPropTypes<ReturnType<typeof configProviderProps>>>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { configProviderProps as e } from "ant-design-vue/es/config-provider/context";
|
|
2
|
-
const
|
|
2
|
+
const p = () => ({
|
|
3
3
|
/**
|
|
4
4
|
* @description aplus-ui的locale
|
|
5
5
|
*/
|
|
@@ -29,8 +29,12 @@ const a = () => ({
|
|
|
29
29
|
type: Object,
|
|
30
30
|
default: () => ({})
|
|
31
31
|
},
|
|
32
|
+
apDescriptions: {
|
|
33
|
+
type: Object,
|
|
34
|
+
default: () => ({})
|
|
35
|
+
},
|
|
32
36
|
...e()
|
|
33
37
|
});
|
|
34
38
|
export {
|
|
35
|
-
|
|
39
|
+
p as configProviderProps
|
|
36
40
|
};
|
|
@@ -8,7 +8,7 @@ import { ValidateMessages } from 'ant-design-vue/es/form/interface';
|
|
|
8
8
|
import { RequiredMark } from 'ant-design-vue/es/form/Form';
|
|
9
9
|
import { ThemeConfig } from 'ant-design-vue/es/config-provider/context';
|
|
10
10
|
import { LocaleType } from 'src';
|
|
11
|
-
import { ApiType, TableDefaultConfig, ScrollbarGlobalConfig, ApUploadConfig } from './constants';
|
|
11
|
+
import { ApiType, TableDefaultConfig, ScrollbarGlobalConfig, ApUploadConfig, ApDescriptionsConfig } from './constants';
|
|
12
12
|
|
|
13
13
|
export declare const globalConfigCached: Ref<Partial< ExtractPropTypes<{
|
|
14
14
|
iconPrefixCls: StringConstructor;
|
|
@@ -151,6 +151,10 @@ export declare const globalConfigCached: Ref<Partial< ExtractPropTypes<{
|
|
|
151
151
|
type: PropType<ApUploadConfig>;
|
|
152
152
|
default: () => {};
|
|
153
153
|
};
|
|
154
|
+
apDescriptions: {
|
|
155
|
+
type: PropType<ApDescriptionsConfig>;
|
|
156
|
+
default: () => {};
|
|
157
|
+
};
|
|
154
158
|
}>>>;
|
|
155
159
|
export declare const ConfigProvider: DefineComponent<{
|
|
156
160
|
iconPrefixCls: StringConstructor;
|
|
@@ -293,6 +297,10 @@ export declare const ConfigProvider: DefineComponent<{
|
|
|
293
297
|
type: PropType<ApUploadConfig>;
|
|
294
298
|
default: () => {};
|
|
295
299
|
};
|
|
300
|
+
apDescriptions: {
|
|
301
|
+
type: PropType<ApDescriptionsConfig>;
|
|
302
|
+
default: () => {};
|
|
303
|
+
};
|
|
296
304
|
}, () => import("vue/jsx-runtime").JSX.Element, unknown, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {}, string, PublicProps, Readonly< ExtractPropTypes<{
|
|
297
305
|
iconPrefixCls: StringConstructor;
|
|
298
306
|
getTargetContainer: {
|
|
@@ -434,6 +442,10 @@ export declare const ConfigProvider: DefineComponent<{
|
|
|
434
442
|
type: PropType<ApUploadConfig>;
|
|
435
443
|
default: () => {};
|
|
436
444
|
};
|
|
445
|
+
apDescriptions: {
|
|
446
|
+
type: PropType<ApDescriptionsConfig>;
|
|
447
|
+
default: () => {};
|
|
448
|
+
};
|
|
437
449
|
}>>, {
|
|
438
450
|
theme: ThemeConfig;
|
|
439
451
|
direction: "ltr" | "rtl";
|
|
@@ -471,5 +483,6 @@ export declare const ConfigProvider: DefineComponent<{
|
|
|
471
483
|
scrollbar: ScrollbarGlobalConfig;
|
|
472
484
|
uiMode: "aplus" | "admin";
|
|
473
485
|
apUpload: ApUploadConfig;
|
|
486
|
+
apDescriptions: ApDescriptionsConfig;
|
|
474
487
|
}, {}>;
|
|
475
488
|
export type ConfigProviderInstance = InstanceType<typeof ConfigProvider>;
|
|
@@ -1,38 +1,39 @@
|
|
|
1
|
-
import { isVNode as
|
|
1
|
+
import { isVNode as n, ref as l, defineComponent as c, computed as f, watch as d, createVNode as m, renderSlot as u } from "vue";
|
|
2
2
|
import { ConfigProvider as p } from "ant-design-vue";
|
|
3
3
|
import { provideGlobalConfig as g } from "./hooks/use-global-config.mjs";
|
|
4
|
-
import { configProviderProps as
|
|
5
|
-
import { tableDefaultConfig as
|
|
6
|
-
import { mergeAntdProvideConfig as
|
|
7
|
-
function
|
|
8
|
-
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !
|
|
4
|
+
import { configProviderProps as s } from "./config-provider-props.mjs";
|
|
5
|
+
import { tableDefaultConfig as b } from "./constants.mjs";
|
|
6
|
+
import { mergeAntdProvideConfig as v } from "../utils/config-provider-preset.mjs";
|
|
7
|
+
function C(e) {
|
|
8
|
+
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !n(e);
|
|
9
9
|
}
|
|
10
|
-
const r =
|
|
10
|
+
const r = l({}), A = /* @__PURE__ */ c({
|
|
11
11
|
name: "AplusConfigProvider",
|
|
12
|
-
props:
|
|
12
|
+
props: s(),
|
|
13
13
|
setup(e, {
|
|
14
|
-
slots:
|
|
14
|
+
slots: i
|
|
15
15
|
}) {
|
|
16
|
-
const
|
|
16
|
+
const a = f(() => ({
|
|
17
17
|
namespace: e.namespace,
|
|
18
18
|
aplusLocale: e.aplusLocale,
|
|
19
19
|
api: e.api,
|
|
20
20
|
table: {
|
|
21
|
-
...
|
|
21
|
+
...b,
|
|
22
22
|
...e.table || {}
|
|
23
23
|
},
|
|
24
24
|
scrollbar: e.scrollbar,
|
|
25
25
|
uiMode: e.uiMode,
|
|
26
|
-
apUpload: e.apUpload
|
|
27
|
-
|
|
26
|
+
apUpload: e.apUpload,
|
|
27
|
+
apDescriptions: e.apDescriptions
|
|
28
|
+
})), t = g(a);
|
|
28
29
|
return d(() => e, (o) => {
|
|
29
|
-
r.value =
|
|
30
|
+
r.value = v(o);
|
|
30
31
|
}, {
|
|
31
32
|
deep: !0,
|
|
32
33
|
immediate: !0
|
|
33
34
|
}), () => {
|
|
34
35
|
let o;
|
|
35
|
-
return m(p, r.value,
|
|
36
|
+
return m(p, r.value, C(o = u(i, "default", {
|
|
36
37
|
config: t == null ? void 0 : t.value
|
|
37
38
|
})) ? o : {
|
|
38
39
|
default: () => [o]
|
|
@@ -41,6 +42,6 @@ const r = n({}), L = /* @__PURE__ */ f({
|
|
|
41
42
|
}
|
|
42
43
|
});
|
|
43
44
|
export {
|
|
44
|
-
|
|
45
|
+
A as ConfigProvider,
|
|
45
46
|
r as globalConfigCached
|
|
46
47
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { MaybeRef } from '@aplus-frontend/utils';
|
|
2
2
|
import { App, Ref, ComputedRef, ExtractPropTypes, PropType } from 'vue';
|
|
3
|
-
import { ConfigProviderContext, ApiType, TableDefaultConfig, ScrollbarGlobalConfig, ApUploadConfig } from '../constants';
|
|
3
|
+
import { ConfigProviderContext, ApiType, TableDefaultConfig, ScrollbarGlobalConfig, ApUploadConfig, ApDescriptionsConfig } from '../constants';
|
|
4
4
|
import { default as __DTS_DEFAULT_0__ } from 'ant-design-vue/es/config-provider/renderEmpty';
|
|
5
5
|
import { TransformCellTextProps } from 'ant-design-vue/es/table/interface';
|
|
6
6
|
import { CSPConfig } from 'ant-design-vue/es/config-provider';
|
|
@@ -155,4 +155,8 @@ export declare const provideGlobalConfig: (config: MaybeRef<ConfigProviderContex
|
|
|
155
155
|
type: PropType<ApUploadConfig>;
|
|
156
156
|
default: () => {};
|
|
157
157
|
};
|
|
158
|
+
apDescriptions: {
|
|
159
|
+
type: PropType<ApDescriptionsConfig>;
|
|
160
|
+
default: () => {};
|
|
161
|
+
};
|
|
158
162
|
}>>>> | undefined;
|