@aplus-frontend/ui 0.6.0-beta.0 → 0.6.0-beta.1
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-form/ap-form.vue2.mjs +57 -58
- package/es/src/ap-form/interface.d.ts +4 -0
- package/es/src/ap-form/item/index.vue.mjs +33 -28
- package/es/src/ap-form/items/checkbox/index.vue.mjs +1 -0
- package/es/src/ap-form/items/date/index.vue.mjs +8 -7
- package/es/src/ap-form/items/date-range/index.vue.mjs +1 -0
- package/es/src/ap-form/items/number/index.vue.mjs +9 -8
- package/es/src/ap-form/items/radio/index.vue.mjs +1 -0
- package/es/src/ap-form/items/select/index.vue.mjs +7 -6
- package/es/src/ap-form/items/switch/index.vue.mjs +1 -0
- package/es/src/ap-form/items/text/index.vue2.mjs +8 -7
- package/es/src/ap-form/items/text/password.vue.mjs +1 -0
- package/es/src/ap-form/items/text-area/index.vue.mjs +1 -0
- package/es/src/ap-form/items/tree-select/index.vue.mjs +6 -5
- package/es/src/ap-form/render/item.vue.mjs +5 -4
- package/es/src/ap-form/search-form/components/popover-filter.vue2.mjs +10 -10
- package/es/src/ap-form/search-form/components/popover-sorter/sortable-item.vue2.mjs +8 -8
- package/es/src/ap-form/search-form/index.vue.mjs +35 -34
- package/es/src/ap-grid/editable/form-item.vue.mjs +1 -1
- package/es/src/ap-grid/editable/index.vue.mjs +1 -1
- package/es/src/ap-grid/index.vue.mjs +24 -23
- package/es/src/ap-grid/interface.d.ts +1 -1
- package/es/src/business/ap-view/ap-view.vue2.mjs +91 -88
- package/es/src/business/ap-view/components/main-button-content.vue2.mjs +25 -23
- package/es/src/business/ap-view/components/menu-list-content.vue2.mjs +38 -38
- package/es/src/business/batch-input-group/form-item.vue.mjs +1 -0
- package/es/src/check-card/index.vue2.mjs +1 -1
- package/es/src/design-token/index.mjs +9 -3
- package/es/src/editable-table/form-item.vue.mjs +1 -1
- package/es/src/editable-table/index.vue.mjs +27 -27
- package/lib/src/ap-form/ap-form.vue2.js +1 -1
- package/lib/src/ap-form/interface.d.ts +4 -0
- package/lib/src/ap-form/item/index.vue.js +1 -1
- package/lib/src/ap-form/items/checkbox/index.vue.js +1 -1
- package/lib/src/ap-form/items/date/index.vue.js +1 -1
- package/lib/src/ap-form/items/date-range/index.vue.js +1 -1
- package/lib/src/ap-form/items/number/index.vue.js +1 -1
- package/lib/src/ap-form/items/radio/index.vue.js +1 -1
- package/lib/src/ap-form/items/select/index.vue.js +1 -1
- package/lib/src/ap-form/items/switch/index.vue.js +1 -1
- package/lib/src/ap-form/items/text/index.vue2.js +1 -1
- package/lib/src/ap-form/items/text/password.vue.js +1 -1
- package/lib/src/ap-form/items/text-area/index.vue.js +1 -1
- package/lib/src/ap-form/items/tree-select/index.vue.js +1 -1
- package/lib/src/ap-form/render/item.vue.js +1 -1
- package/lib/src/ap-form/search-form/components/popover-filter.vue2.js +1 -1
- package/lib/src/ap-form/search-form/components/popover-sorter/sortable-item.vue2.js +1 -1
- package/lib/src/ap-form/search-form/index.vue.js +1 -1
- package/lib/src/ap-grid/editable/form-item.vue.js +1 -1
- package/lib/src/ap-grid/editable/index.vue.js +1 -1
- package/lib/src/ap-grid/index.vue.js +1 -1
- package/lib/src/ap-grid/interface.d.ts +1 -1
- package/lib/src/business/ap-view/ap-view.vue2.js +1 -1
- package/lib/src/business/ap-view/components/main-button-content.vue2.js +1 -1
- package/lib/src/business/ap-view/components/menu-list-content.vue2.js +1 -1
- package/lib/src/business/batch-input-group/form-item.vue.js +1 -1
- package/lib/src/check-card/index.vue2.js +1 -1
- package/lib/src/design-token/index.js +1 -1
- package/lib/src/editable-table/form-item.vue.js +1 -1
- package/lib/src/editable-table/index.vue.js +1 -1
- package/package.json +1 -1
- package/theme/ap-action/item-dropdown.css +5 -5
- package/theme/ap-action/item-dropdown.less +1 -1
- package/theme/ap-action/item.css +5 -5
- package/theme/ap-action/item.less +1 -1
- package/theme/ap-appendix/ap-appendix.css +3 -3
- package/theme/ap-attachment/ap-attachment.css +3 -3
- package/theme/ap-batch-action/ap-batch-action.css +3 -3
- package/theme/ap-button/ap-button.css +3 -3
- package/theme/ap-card/ap-card.css +3 -3
- package/theme/ap-descriptions/ap-descriptions.css +3 -3
- package/theme/ap-download/ap-download.css +3 -3
- package/theme/ap-expand-alert/ap-expand-alert.css +3 -3
- package/theme/ap-field/checkbox.css +4 -4
- package/theme/ap-field/checkbox.less +2 -1
- package/theme/ap-field/index.css +5 -5
- package/theme/ap-field/number.css +3 -3
- package/theme/ap-field/radio.css +4 -4
- package/theme/ap-field/radio.less +1 -1
- package/theme/ap-field/text-area.css +3 -3
- package/theme/ap-form/ap-form-item-group.css +3 -3
- package/theme/ap-form/ap-form-item.css +10 -8
- package/theme/ap-form/ap-form-item.less +8 -6
- package/theme/ap-form/drawer-form.css +3 -3
- package/theme/ap-form/index.css +21 -19
- package/theme/ap-form/item-text-group.css +3 -3
- package/theme/ap-form/item-text.css +3 -3
- package/theme/ap-form/modal-form.css +3 -3
- package/theme/ap-form/search-form-sorter.css +12 -12
- package/theme/ap-form/search-form-sorter.less +7 -7
- package/theme/ap-form/search-form.css +21 -19
- package/theme/ap-form/search-form.less +5 -5
- package/theme/ap-grid/editable.css +5 -5
- package/theme/ap-grid/editable.less +2 -2
- package/theme/ap-grid/index.css +44 -33
- package/theme/ap-grid/index.less +17 -8
- package/theme/ap-group-search/ap-extension-select.css +3 -3
- package/theme/ap-group-search/ap-group-search.css +3 -3
- package/theme/ap-group-search/ap-popover-select.css +3 -3
- package/theme/ap-image/ap-image.css +3 -3
- package/theme/ap-input-radio/ap-input-radio.css +3 -3
- package/theme/ap-label/ap-label.css +3 -3
- package/theme/ap-ladder/ap-ladder.css +3 -3
- package/theme/ap-layout/ap-info-layout.css +3 -3
- package/theme/ap-list/index.css +4 -4
- package/theme/ap-list/index.less +2 -1
- package/theme/ap-product-info/ap-product-info.css +3 -3
- package/theme/ap-select-layout/ap-select-layout.css +3 -3
- package/theme/ap-size-input/ap-size-input.css +3 -3
- package/theme/ap-status/ap-status.css +3 -3
- package/theme/ap-summary/index.css +3 -3
- package/theme/ap-table/ap-table-index.css +3 -3
- package/theme/ap-table/ap-table-paragraph-ellipsis.css +3 -3
- package/theme/ap-table/ap-table.css +43 -37
- package/theme/ap-table/ap-table.less +12 -8
- package/theme/ap-table/setting/index.css +7 -7
- package/theme/ap-table/setting/modal.css +5 -5
- package/theme/ap-table/setting/select-group.css +3 -3
- package/theme/ap-table/setting/sortable-item-meta.css +3 -3
- package/theme/ap-table/setting/sortable-item.css +3 -3
- package/theme/ap-table/setting/sorter.css +5 -5
- package/theme/ap-table-modal/index.css +43 -37
- package/theme/ap-tag/ap-tag-group.css +3 -3
- package/theme/ap-tag/ap-tag.css +3 -3
- package/theme/ap-title/ap-title.css +3 -3
- package/theme/ap-upload/index.css +3 -3
- package/theme/ap-upload/multiple-file.css +3 -3
- package/theme/ap-upload/picture.css +3 -3
- package/theme/ap-upload/single-file.css +3 -3
- package/theme/ap-upload/upload.css +3 -3
- package/theme/ap-upload-single/index.css +3 -3
- package/theme/ap-view/ap-view.css +3 -3
- package/theme/batch-input-group/index.css +5 -5
- package/theme/batch-input-group/popover-input.css +3 -3
- package/theme/check-card/index.css +22 -22
- package/theme/check-card/index.less +17 -15
- package/theme/editable-table/index.css +36 -32
- package/theme/editable-table/index.less +9 -7
- package/theme/full-screen/index.css +3 -3
- package/theme/index.css +98 -81
- package/theme/mask/index.css +3 -3
- package/theme/mixins/config.less +26 -4
- package/theme/mixins/mixins.css +3 -3
- package/theme/scroll-bar/index.css +3 -3
- package/theme/scroll-view/index.css +3 -3
- package/theme/splitter/index.css +8 -8
- package/theme/text/group.css +3 -3
- package/theme/text/index.css +5 -5
- package/theme/work-order-modal/index.css +3 -3
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as B, ref as x, useSlots as S, computed as g, createBlock as k, openBlock as F, normalizeProps as n, guardReactiveProps as i, unref as l, createSlots as u, withCtx as p, createVNode as C, mergeProps as P, renderList as
|
|
1
|
+
import { defineComponent as B, ref as x, useSlots as S, computed as g, createBlock as k, openBlock as F, normalizeProps as n, guardReactiveProps as i, unref as l, createSlots as u, withCtx as p, createVNode as C, mergeProps as P, renderList as c, renderSlot as m } from "vue";
|
|
2
2
|
import "../../item/index.vue2.mjs";
|
|
3
3
|
import "../../../ap-field/index.mjs";
|
|
4
4
|
import { isUndefined as q, omit as b, pick as $ } from "lodash-unified";
|
|
@@ -48,6 +48,7 @@ const E = /* @__PURE__ */ B({
|
|
|
48
48
|
initialValue: {},
|
|
49
49
|
_signal: {},
|
|
50
50
|
transform: {},
|
|
51
|
+
description: {},
|
|
51
52
|
field: { default: () => ({}) },
|
|
52
53
|
placeholder: {},
|
|
53
54
|
disabled: { type: Boolean, default: void 0 }
|
|
@@ -83,20 +84,20 @@ const E = /* @__PURE__ */ B({
|
|
|
83
84
|
ref_key: "treeSelectRef",
|
|
84
85
|
ref: a
|
|
85
86
|
}), u({ _: 2 }, [
|
|
86
|
-
|
|
87
|
+
c(l(b)(f, l(_)), (d, t) => ({
|
|
87
88
|
name: t,
|
|
88
89
|
fn: p((s) => [
|
|
89
|
-
|
|
90
|
+
m(e.$slots, t, n(i(s || {})))
|
|
90
91
|
])
|
|
91
92
|
}))
|
|
92
93
|
]), 1040)
|
|
93
94
|
]),
|
|
94
95
|
_: 2
|
|
95
96
|
}, [
|
|
96
|
-
|
|
97
|
+
c(l($)(f, l(_)), (d, t) => ({
|
|
97
98
|
name: t,
|
|
98
99
|
fn: p((s) => [
|
|
99
|
-
|
|
100
|
+
m(e.$slots, t, n(i(s || {})))
|
|
100
101
|
])
|
|
101
102
|
}))
|
|
102
103
|
]), 1040));
|
|
@@ -43,11 +43,12 @@ const S = /* @__PURE__ */ m({
|
|
|
43
43
|
valuePropName: { default: "value" },
|
|
44
44
|
initialValue: {},
|
|
45
45
|
_signal: {},
|
|
46
|
-
transform: {}
|
|
46
|
+
transform: {},
|
|
47
|
+
description: {}
|
|
47
48
|
},
|
|
48
49
|
setup(d) {
|
|
49
|
-
const
|
|
50
|
-
return (a, h) => (v(), B(e(p).FormItem, o(l(
|
|
50
|
+
const i = d, u = c();
|
|
51
|
+
return (a, h) => (v(), B(e(p).FormItem, o(l(i)), y({
|
|
51
52
|
default: t(() => [
|
|
52
53
|
x(e(p).ControlRender, null, {
|
|
53
54
|
default: t((r) => [
|
|
@@ -58,7 +59,7 @@ const S = /* @__PURE__ */ m({
|
|
|
58
59
|
]),
|
|
59
60
|
_: 2
|
|
60
61
|
}, [
|
|
61
|
-
_(e(g)(
|
|
62
|
+
_(e(g)(u, "default"), (r, n) => ({
|
|
62
63
|
name: n,
|
|
63
64
|
fn: t((f) => [
|
|
64
65
|
s(a.$slots, n, o(l(f || {})))
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { defineComponent as y, ref as k, createBlock as s, openBlock as
|
|
2
|
-
import { Popover as B, Tooltip as
|
|
1
|
+
import { defineComponent as y, ref as k, createBlock as s, openBlock as l, unref as e, withCtx as o, createVNode as t, createElementVNode as d, normalizeClass as c, createElementBlock as C, Fragment as F, renderList as _, resolveDynamicComponent as b, createTextVNode as f, toDisplayString as v } from "vue";
|
|
2
|
+
import { Popover as B, Tooltip as x, Button as u, Row as h, Col as L, Divider as N, Flex as S } from "@aplus-frontend/antdv";
|
|
3
3
|
import { IconApFilterOutlined as w } from "@aplus-frontend/icon";
|
|
4
4
|
import "../../../config-provider/index.mjs";
|
|
5
5
|
import { useNamespace as D } from "../../../config-provider/hooks/use-namespace.mjs";
|
|
@@ -17,9 +17,9 @@ const O = /* @__PURE__ */ y({
|
|
|
17
17
|
function g(n) {
|
|
18
18
|
return n.closest(".ant-form") || document.body;
|
|
19
19
|
}
|
|
20
|
-
return (n,
|
|
20
|
+
return (n, p) => (l(), s(e(B), {
|
|
21
21
|
open: m.value,
|
|
22
|
-
"onUpdate:open":
|
|
22
|
+
"onUpdate:open": p[1] || (p[1] = (r) => m.value = r),
|
|
23
23
|
"overlay-class-name": e(a)("popover"),
|
|
24
24
|
trigger: "click",
|
|
25
25
|
placement: "bottom",
|
|
@@ -30,16 +30,16 @@ const O = /* @__PURE__ */ y({
|
|
|
30
30
|
content: o(() => [
|
|
31
31
|
d("div", {
|
|
32
32
|
class: c([e(a)("popover-content")]),
|
|
33
|
-
style: { paddingBottom:
|
|
33
|
+
style: { paddingBottom: "4px", width: "825px" }
|
|
34
34
|
}, [
|
|
35
|
-
t(e(
|
|
35
|
+
t(e(h), { gutter: 16 }, {
|
|
36
36
|
default: o(() => [
|
|
37
|
-
(
|
|
37
|
+
(l(!0), C(F, null, _(n.config, (r) => (l(), s(e(L), {
|
|
38
38
|
key: r.key,
|
|
39
39
|
span: 8
|
|
40
40
|
}, {
|
|
41
41
|
default: o(() => [
|
|
42
|
-
(
|
|
42
|
+
(l(), s(b(r.node)))
|
|
43
43
|
]),
|
|
44
44
|
_: 2
|
|
45
45
|
}, 1024))), 128))
|
|
@@ -54,7 +54,7 @@ const O = /* @__PURE__ */ y({
|
|
|
54
54
|
t(e(S), { justify: "end" }, {
|
|
55
55
|
default: o(() => [
|
|
56
56
|
t(e(u), {
|
|
57
|
-
onClick:
|
|
57
|
+
onClick: p[0] || (p[0] = (r) => m.value = !1)
|
|
58
58
|
}, {
|
|
59
59
|
default: o(() => [
|
|
60
60
|
f(v(e(i)("ap.common.cancelText")), 1)
|
|
@@ -78,7 +78,7 @@ const O = /* @__PURE__ */ y({
|
|
|
78
78
|
], 2)
|
|
79
79
|
]),
|
|
80
80
|
default: o(() => [
|
|
81
|
-
t(e(
|
|
81
|
+
t(e(x), {
|
|
82
82
|
title: e(i)("ap.apForm.search.moreFilter"),
|
|
83
83
|
placement: "top"
|
|
84
84
|
}, {
|
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as c, computed as n, createElementBlock as a, openBlock as d, normalizeClass as r, unref as t, createElementVNode as l, createVNode as u, toDisplayString as f } from "vue";
|
|
2
2
|
import { HolderOutlined as h } from "@ant-design/icons-vue";
|
|
3
3
|
import "../../../../config-provider/index.mjs";
|
|
4
4
|
import { isBoolean as _ } from "lodash-unified";
|
|
5
5
|
import { isDef as v } from "@fruits-chain/utils";
|
|
6
6
|
import { useNamespace as b } from "../../../../config-provider/hooks/use-namespace.mjs";
|
|
7
|
-
const x = ["title"], C = /* @__PURE__ */
|
|
7
|
+
const x = ["title"], C = /* @__PURE__ */ c({
|
|
8
8
|
name: "ApFormSearchFormPopoverSorterItem",
|
|
9
9
|
__name: "sortable-item",
|
|
10
10
|
props: {
|
|
11
11
|
item: {}
|
|
12
12
|
},
|
|
13
13
|
setup(m) {
|
|
14
|
-
const s = m,
|
|
14
|
+
const s = m, i = n(() => {
|
|
15
15
|
const e = s.item.props;
|
|
16
|
-
return e.label || e.placeholder;
|
|
17
|
-
}), p =
|
|
16
|
+
return e.description || e.label || e.placeholder;
|
|
17
|
+
}), p = n(() => {
|
|
18
18
|
const e = s.item.props;
|
|
19
19
|
return _(e.hidden) ? !!e.hidden : v(e.hidden);
|
|
20
20
|
}), { b: o } = b("search-form-sorter");
|
|
21
|
-
return (e, B) => (d(),
|
|
21
|
+
return (e, B) => (d(), a("div", {
|
|
22
22
|
class: r([t(o)("sorter-item"), { [t(o)("sorter-item--hidden")]: p.value }])
|
|
23
23
|
}, [
|
|
24
24
|
l("div", null, [
|
|
@@ -28,8 +28,8 @@ const x = ["title"], C = /* @__PURE__ */ a({
|
|
|
28
28
|
}, null, 8, ["class"]),
|
|
29
29
|
l("span", {
|
|
30
30
|
class: r(t(o)("sorter-item-text")),
|
|
31
|
-
title:
|
|
32
|
-
}, f(
|
|
31
|
+
title: i.value
|
|
32
|
+
}, f(i.value), 11, x)
|
|
33
33
|
])
|
|
34
34
|
], 2));
|
|
35
35
|
}
|
|
@@ -4,7 +4,7 @@ import "../ap-form.vue.mjs";
|
|
|
4
4
|
import "../item/index.vue2.mjs";
|
|
5
5
|
import { genRealChildren as V } from "../item-group/helper.mjs";
|
|
6
6
|
import "../../config-provider/index.mjs";
|
|
7
|
-
import { isArray as ie, isBoolean as
|
|
7
|
+
import { isArray as ie, isBoolean as ue, omit as ce } from "lodash-unified";
|
|
8
8
|
import { isDef as M } from "../../utils/index.mjs";
|
|
9
9
|
import { execFunc as W, diffFormItem as pe } from "./utils.mjs";
|
|
10
10
|
import "./components/popover-filter.vue.mjs";
|
|
@@ -113,15 +113,16 @@ const s = 24, Le = /* @__PURE__ */ te({
|
|
|
113
113
|
setup(f, {
|
|
114
114
|
expose: q
|
|
115
115
|
}) {
|
|
116
|
-
var
|
|
116
|
+
var E;
|
|
117
117
|
const i = oe(), o = f, {
|
|
118
118
|
b: m
|
|
119
119
|
} = fe("ap-form-search-form"), {
|
|
120
120
|
t: N
|
|
121
121
|
} = me(), z = de(o), y = ae();
|
|
122
122
|
function k() {
|
|
123
|
-
var
|
|
124
|
-
|
|
123
|
+
var a;
|
|
124
|
+
const e = (a = y.value) == null ? void 0 : a.getFieldsValueTransformed(!0);
|
|
125
|
+
W(o.onSubmit, e);
|
|
125
126
|
}
|
|
126
127
|
function H() {
|
|
127
128
|
var e, a;
|
|
@@ -129,22 +130,22 @@ const s = 24, Le = /* @__PURE__ */ te({
|
|
|
129
130
|
}
|
|
130
131
|
const G = (e) => M(e) ? (ie(e) ? e : [e]).join("") : Date.now();
|
|
131
132
|
let I = [];
|
|
132
|
-
const
|
|
133
|
+
const u = j(V(i.default())), c = j((E = i.extra) == null ? void 0 : E.call(i)), T = _(() => Math.floor(s / n(z)));
|
|
133
134
|
L(() => i.default(), (e) => {
|
|
134
|
-
I =
|
|
135
|
+
I = u.value, u.value = pe(I, V(e));
|
|
135
136
|
}), L(() => {
|
|
136
137
|
var e;
|
|
137
138
|
return (e = i.extra) == null ? void 0 : e.call(i);
|
|
138
139
|
}, (e) => {
|
|
139
|
-
|
|
140
|
+
c.value = e;
|
|
140
141
|
});
|
|
141
|
-
const
|
|
142
|
-
const e =
|
|
142
|
+
const l = _(() => {
|
|
143
|
+
const e = u.value, a = [], r = [], g = [], h = n(T);
|
|
143
144
|
let v = 0, b = 0;
|
|
144
|
-
const Q = s * o.maxRows - h * (n(
|
|
145
|
+
const Q = s * o.maxRows - h * (n(c) && !o.extraInAction ? 2 : 1);
|
|
145
146
|
e.forEach((S, Z) => {
|
|
146
147
|
const p = S.props;
|
|
147
|
-
if (
|
|
148
|
+
if (ue(p.hidden) ? !!p.hidden : M(p.hidden))
|
|
148
149
|
a.push(S);
|
|
149
150
|
else {
|
|
150
151
|
let C = p.span || h;
|
|
@@ -153,31 +154,31 @@ const s = 24, Le = /* @__PURE__ */ te({
|
|
|
153
154
|
span: C,
|
|
154
155
|
key: `ApFormSearchFormItem-${Z}-${G(p.name)}-${p._signal}`
|
|
155
156
|
}, $ = s - v % s;
|
|
156
|
-
$ < C && (C += $), v += C, v > Q ?
|
|
157
|
+
$ < C && (C += $), v += C, v > Q ? r.push(O) : (b = v, g.push(O));
|
|
157
158
|
}
|
|
158
159
|
});
|
|
159
|
-
const
|
|
160
|
+
const P = s - (b + h) % s, X = b % s < h, Y = P < h ? s : P;
|
|
160
161
|
return {
|
|
161
162
|
hideNode: t(w, null, [a]),
|
|
162
163
|
nodes: g,
|
|
163
|
-
collapseNodes:
|
|
164
|
+
collapseNodes: r,
|
|
164
165
|
extraSpan: Y,
|
|
165
166
|
lastRowOnlyIncludeActionAndExtra: X
|
|
166
167
|
};
|
|
167
168
|
});
|
|
168
169
|
function J(e) {
|
|
169
|
-
|
|
170
|
+
u.value = [...e];
|
|
170
171
|
}
|
|
171
172
|
const K = _(() => {
|
|
172
173
|
let e;
|
|
173
174
|
const a = t(R, {
|
|
174
|
-
span: n(
|
|
175
|
+
span: n(T),
|
|
175
176
|
key: "actionWrapper"
|
|
176
177
|
}, {
|
|
177
178
|
default: () => [t(D, null, {
|
|
178
179
|
default: () => [t(B, {
|
|
179
180
|
wrap: "wrap",
|
|
180
|
-
justify:
|
|
181
|
+
justify: l.value.lastRowOnlyIncludeActionAndExtra && !(n(c) && o.extraInAction) ? "flex-end" : "space-between"
|
|
181
182
|
}, {
|
|
182
183
|
default: () => [t(B, {
|
|
183
184
|
gap: 8,
|
|
@@ -185,12 +186,12 @@ const s = 24, Le = /* @__PURE__ */ te({
|
|
|
185
186
|
}, {
|
|
186
187
|
default: () => [t("div", {
|
|
187
188
|
class: m("column-setting-trigger-wrapper")
|
|
188
|
-
}, [
|
|
189
|
+
}, [l.value.collapseNodes.length ? t(he, {
|
|
189
190
|
onSubmit: k,
|
|
190
|
-
config:
|
|
191
|
+
config: l.value.collapseNodes,
|
|
191
192
|
submitLoading: o.submitLoading
|
|
192
|
-
}, null) : null, o.sortable &&
|
|
193
|
-
children:
|
|
193
|
+
}, null) : null, o.sortable && u.value.length ? t(xe, {
|
|
194
|
+
children: u.value,
|
|
194
195
|
onClickConfirm: J
|
|
195
196
|
}, null) : null]), t(U, {
|
|
196
197
|
type: "primary",
|
|
@@ -207,24 +208,24 @@ const s = 24, Le = /* @__PURE__ */ te({
|
|
|
207
208
|
}, {
|
|
208
209
|
default: () => [o.resetText || N("ap.apForm.search.reset")]
|
|
209
210
|
})]
|
|
210
|
-
}), o.extraInAction ? n(
|
|
211
|
+
}), o.extraInAction ? n(c) : null]
|
|
211
212
|
})]
|
|
212
213
|
})]
|
|
213
|
-
}),
|
|
214
|
-
span:
|
|
214
|
+
}), r = !o.extraInAction && n(c) ? t(R, {
|
|
215
|
+
span: l.value.extraSpan,
|
|
215
216
|
key: "extraNode"
|
|
216
217
|
}, {
|
|
217
218
|
default: () => [t(D, null, {
|
|
218
219
|
default: () => [t(B, {
|
|
219
|
-
justify:
|
|
220
|
-
}, ge(e = n(
|
|
220
|
+
justify: l.value.extraSpan === s || l.value.lastRowOnlyIncludeActionAndExtra ? "start" : "flex-end"
|
|
221
|
+
}, ge(e = n(c)) ? e : {
|
|
221
222
|
default: () => [e]
|
|
222
223
|
})]
|
|
223
224
|
})]
|
|
224
225
|
}) : null, g = t(R, {
|
|
225
|
-
span:
|
|
226
|
+
span: l.value.extraSpan
|
|
226
227
|
}, null);
|
|
227
|
-
return
|
|
228
|
+
return l.value.lastRowOnlyIncludeActionAndExtra ? t(w, null, [r || g, a]) : t(w, null, [a, r]);
|
|
228
229
|
});
|
|
229
230
|
return q({
|
|
230
231
|
apForm: _(() => n(y))
|
|
@@ -232,15 +233,15 @@ const s = 24, Le = /* @__PURE__ */ te({
|
|
|
232
233
|
ref_key: "apForm",
|
|
233
234
|
ref: y,
|
|
234
235
|
class: n(m)()
|
|
235
|
-
}, n(
|
|
236
|
-
default: F(() => [(d(), x(A(
|
|
236
|
+
}, n(ce)(o, ["collapse", "defaultCollapse", "onUpdate:collapse", "searchText", "resetText", "onSubmit", "onReset", "extraInAction", "forceExpand", "countPerRow"])), {
|
|
237
|
+
default: F(() => [(d(), x(A(l.value.hideNode))), t(n(se), {
|
|
237
238
|
gutter: 16
|
|
238
239
|
}, {
|
|
239
|
-
default: F(() => [(d(!0), le(w, null, re(
|
|
240
|
-
key:
|
|
241
|
-
span:
|
|
240
|
+
default: F(() => [(d(!0), le(w, null, re(l.value.nodes, (r) => (d(), x(n(R), {
|
|
241
|
+
key: r.key,
|
|
242
|
+
span: r.span
|
|
242
243
|
}, {
|
|
243
|
-
default: F(() => [(d(), x(A(
|
|
244
|
+
default: F(() => [(d(), x(A(r.node)))]),
|
|
244
245
|
_: 2
|
|
245
246
|
}, 1032, ["span"]))), 128)), (d(), x(A(K.value)))]),
|
|
246
247
|
_: 1
|
|
@@ -101,7 +101,7 @@ const Bo = /* @__PURE__ */ ke({
|
|
|
101
101
|
tableWrapperStyle: {},
|
|
102
102
|
wrapperStyle: {},
|
|
103
103
|
manual: { type: Boolean, default: !1 },
|
|
104
|
-
size: { default:
|
|
104
|
+
size: { default: "mini" },
|
|
105
105
|
adaptive: { type: Boolean, default: !1 },
|
|
106
106
|
columnResizable: { type: [Boolean, Object], default: !1 },
|
|
107
107
|
rowKey: { default: "key" },
|
|
@@ -114,11 +114,11 @@ const Bo = /* @__PURE__ */ ke({
|
|
|
114
114
|
var G;
|
|
115
115
|
const O = Be(), a = re, w = (G = Fe()) == null ? void 0 : G.appContext.app;
|
|
116
116
|
w && !w.__VXE_PC_UI_INSTALLED__ && (w.use(Z), w.__VXE_PC_UI_INSTALLED__ = !0);
|
|
117
|
-
const { e: E, b: c, be: le } = Je("ap-grid"), ne = Qe("valueTypeMap"),
|
|
117
|
+
const { e: E, b: c, be: le } = Je("ap-grid"), ne = Qe("valueTypeMap"), i = k([]), $ = k([]), m = k(), C = k(a.size), [, d] = Xe(), { t: se } = Ye();
|
|
118
118
|
Z.setConfig({
|
|
119
119
|
i18n: (e, r) => se(`ap.${e}`, r)
|
|
120
120
|
});
|
|
121
|
-
const { renderConfig:
|
|
121
|
+
const { renderConfig: ie, updateSignal: de } = Ge(i);
|
|
122
122
|
let K = 0;
|
|
123
123
|
const ce = n(() => {
|
|
124
124
|
if (m.value)
|
|
@@ -156,10 +156,10 @@ const Bo = /* @__PURE__ */ ke({
|
|
|
156
156
|
a.card ? null : c("wrapper"),
|
|
157
157
|
a.adaptive ? c("adaptive") : null,
|
|
158
158
|
a.sticky ? c("sticky") : null
|
|
159
|
-
].filter(Boolean)), j = n(() => oe(o(
|
|
159
|
+
].filter(Boolean)), j = n(() => oe(o(i), (e) => {
|
|
160
160
|
if (e.sorter === !0)
|
|
161
161
|
return e.key || e.dataIndex;
|
|
162
|
-
}).filter(Boolean)), H = n(() => oe(o(
|
|
162
|
+
}).filter(Boolean)), H = n(() => oe(o(i), (e) => {
|
|
163
163
|
if (e.filters && !e.onFilter)
|
|
164
164
|
return e.key || e.dataIndex;
|
|
165
165
|
}).filter(Boolean)), {
|
|
@@ -197,19 +197,19 @@ const Bo = /* @__PURE__ */ ke({
|
|
|
197
197
|
pagination: a.pagination
|
|
198
198
|
}), { sortChangeEvent: ge, filterChangeEvent: he, paginationChangeEvent: ve } = Oe(fe);
|
|
199
199
|
He({
|
|
200
|
-
columns: n(() =>
|
|
200
|
+
columns: n(() => i.value),
|
|
201
201
|
columnsBackup: n(() => $.value),
|
|
202
202
|
size: n(() => C.value ? qe[C.value] : "middle"),
|
|
203
203
|
updateColumns(e) {
|
|
204
204
|
var r;
|
|
205
|
-
|
|
205
|
+
i.value = e, (r = a.onShownColumnsChange) == null || r.call(a, e);
|
|
206
206
|
},
|
|
207
207
|
updateSize(e) {
|
|
208
208
|
C.value = Me[e];
|
|
209
209
|
},
|
|
210
210
|
renderConfig: n(() => ({
|
|
211
211
|
className: le("table-header", "title"),
|
|
212
|
-
color:
|
|
212
|
+
color: d.value.colorPrimary
|
|
213
213
|
})),
|
|
214
214
|
dataSource: n(() => o(f).records),
|
|
215
215
|
getSearchFormValues: U,
|
|
@@ -218,7 +218,7 @@ const Bo = /* @__PURE__ */ ke({
|
|
|
218
218
|
reset: T
|
|
219
219
|
});
|
|
220
220
|
const Ce = n(
|
|
221
|
-
() =>
|
|
221
|
+
() => i.value.some(
|
|
222
222
|
(e) => e.fixed === "left" || e.fixed === !0
|
|
223
223
|
) ? "left" : void 0
|
|
224
224
|
), ye = n(
|
|
@@ -268,7 +268,7 @@ const Bo = /* @__PURE__ */ ke({
|
|
|
268
268
|
() => {
|
|
269
269
|
var r;
|
|
270
270
|
const e = xe();
|
|
271
|
-
|
|
271
|
+
i.value = e, (r = a.onShownColumnsChange) == null || r.call(a, e), $.value = e;
|
|
272
272
|
},
|
|
273
273
|
{
|
|
274
274
|
deep: !0,
|
|
@@ -297,7 +297,7 @@ const Bo = /* @__PURE__ */ ke({
|
|
|
297
297
|
refresh: pe,
|
|
298
298
|
setSearchFormValues: q,
|
|
299
299
|
getSearchFormValues: U,
|
|
300
|
-
getShowColumns: () => o(
|
|
300
|
+
getShowColumns: () => o(i),
|
|
301
301
|
rowSelection: {
|
|
302
302
|
selectedRows: n(() => x.value),
|
|
303
303
|
clearAll: _
|
|
@@ -352,7 +352,7 @@ const Bo = /* @__PURE__ */ ke({
|
|
|
352
352
|
D(e.$slots, "title", {
|
|
353
353
|
selectedRows: o(x),
|
|
354
354
|
selectedRowKeys: o(R).selectedRowKeys,
|
|
355
|
-
shownColumns:
|
|
355
|
+
shownColumns: i.value,
|
|
356
356
|
clearAll: _
|
|
357
357
|
})
|
|
358
358
|
], 2),
|
|
@@ -362,23 +362,24 @@ const Bo = /* @__PURE__ */ ke({
|
|
|
362
362
|
(s(), p(o(Pe), h(o($e)(a), {
|
|
363
363
|
ref_key: "tableRef",
|
|
364
364
|
ref: m,
|
|
365
|
-
key: o(
|
|
365
|
+
key: o(de),
|
|
366
366
|
data: o(f).records,
|
|
367
367
|
"sort-config": { remote: j.value.length > 0 },
|
|
368
368
|
"filter-config": { remote: H.value.length > 0 },
|
|
369
369
|
loading: ye.value,
|
|
370
370
|
style: {
|
|
371
|
-
"--vxe-ui-table-row-checkbox-checked-background-color": o(
|
|
372
|
-
"--vxe-ui-table-row-hover-checkbox-checked-background-color": o(
|
|
373
|
-
"--vxe-ui-font-primary-color": o(
|
|
371
|
+
"--vxe-ui-table-row-checkbox-checked-background-color": o(d).controlItemBgActive,
|
|
372
|
+
"--vxe-ui-table-row-hover-checkbox-checked-background-color": o(d).controlItemBgActiveHover,
|
|
373
|
+
"--vxe-ui-font-primary-color": o(d).colorPrimary,
|
|
374
374
|
"--vxe-ui-table-header-background-color": "var(--ap-table-header-bg)",
|
|
375
375
|
"--vxe-ui-table-cell-padding-default": "12px",
|
|
376
376
|
"--vxe-ui-table-cell-padding-medium": "9px",
|
|
377
|
-
"--vxe-ui-table-row-radio-checked-background-color": o(
|
|
378
|
-
"--vxe-ui-table-row-hover-radio-checked-background-color": o(
|
|
379
|
-
"--vxe-ui-font-color": o(
|
|
380
|
-
"--vxe-ui-table-border-color": o(
|
|
381
|
-
"--vxe-ui-table-header-font-color": o(
|
|
377
|
+
"--vxe-ui-table-row-radio-checked-background-color": o(d).controlItemBgActive,
|
|
378
|
+
"--vxe-ui-table-row-hover-radio-checked-background-color": o(d).controlItemBgActiveHover,
|
|
379
|
+
"--vxe-ui-font-color": o(d).colorTextBase,
|
|
380
|
+
"--vxe-ui-table-border-color": o(d).colorBorderSecondary,
|
|
381
|
+
"--vxe-ui-table-header-font-color": o(d).colorTextBase,
|
|
382
|
+
"--vxe-ui-table-cell-padding-mini": "8px"
|
|
382
383
|
},
|
|
383
384
|
size: C.value,
|
|
384
385
|
onSortChange: o(ge),
|
|
@@ -400,8 +401,8 @@ const Bo = /* @__PURE__ */ ke({
|
|
|
400
401
|
]),
|
|
401
402
|
_: 1
|
|
402
403
|
}, 16, ["fixed"])) : S("", !0),
|
|
403
|
-
a.rowSelection ? (s(), p(o(Y), h({ key: 1 }, o(We)(o(R),
|
|
404
|
-
(s(!0), F(Q, null, V(o(
|
|
404
|
+
a.rowSelection ? (s(), p(o(Y), h({ key: 1 }, o(We)(o(R), i.value), { field: o(Ue) }), null, 16, ["field"])) : S("", !0),
|
|
405
|
+
(s(!0), F(Q, null, V(o(ie), (l) => (s(), p(L(l), {
|
|
405
406
|
key: l.props.colId
|
|
406
407
|
}))), 128))
|
|
407
408
|
]),
|
|
@@ -19,7 +19,7 @@ export type ApGridColumnType<RecordType = any, ExtraValueType = 'text', ValueTyp
|
|
|
19
19
|
/**
|
|
20
20
|
* 在title之后展示一个icon并触发tooltip
|
|
21
21
|
*/
|
|
22
|
-
tooltip?: string;
|
|
22
|
+
tooltip?: string | ((column: ApGridColumnType<RecordType, ExtraValueType, ValueType, MergedValueType>) => VNode);
|
|
23
23
|
/**
|
|
24
24
|
* 是否可以复制
|
|
25
25
|
*/
|