@aplus-frontend/ui 0.0.14 → 0.0.16
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-action/interface.d.ts +11 -0
- package/es/src/ap-action/item/index.vue.d.ts +2 -4
- package/es/src/ap-action/item/index.vue2.mjs +34 -28
- package/es/src/ap-action/item-modal/index.vue.d.ts +8 -3
- package/es/src/ap-action/item-modal/index.vue.mjs +20 -13
- package/es/src/ap-action/item-popconfirm/index.vue.d.ts +8 -3
- package/es/src/ap-action/item-popconfirm/index.vue.mjs +23 -16
- package/es/src/ap-form/ap-form-item.vue.mjs +45 -42
- package/es/src/ap-form/modal-form/index.vue.mjs +68 -66
- package/es/src/ap-table/ap-table.vue.d.ts +2 -2
- package/es/src/ap-table/ap-table.vue.mjs +90 -92
- package/es/src/ap-table/interface.d.ts +12 -11
- package/es/src/ap-table/style/ap-table.css +6 -0
- package/es/src/ap-table/utils.d.ts +2188 -5
- package/es/src/business/title/style.css +29 -9
- package/es/src/editable-table/hooks/use-get-columns.d.ts +26 -3
- package/es/src/editable-table/hooks/use-get-columns.mjs +54 -52
- package/es/src/editable-table/interface.d.ts +24 -7
- package/es/src/editable-table/style/index.css +7 -8
- package/es/src/theme/antd-global-overwrite/admin/index.css +6 -6
- package/es/src/theme/antd-global-overwrite/admin/modal.css +6 -6
- package/es/src/theme/antd-global-overwrite/aplus/index.css +6 -6
- package/es/src/theme/antd-global-overwrite/aplus/modal.css +6 -6
- package/es/src/theme/ap-table/ap-table.css +6 -0
- package/es/src/theme/ap-title/ap-title.css +29 -9
- package/es/src/theme/editable-table/index.css +7 -8
- package/lib/src/ap-action/interface.d.ts +11 -0
- package/lib/src/ap-action/item/index.vue.d.ts +2 -4
- package/lib/src/ap-action/item/index.vue2.js +1 -1
- package/lib/src/ap-action/item-modal/index.vue.d.ts +8 -3
- package/lib/src/ap-action/item-modal/index.vue.js +1 -1
- package/lib/src/ap-action/item-popconfirm/index.vue.d.ts +8 -3
- package/lib/src/ap-action/item-popconfirm/index.vue.js +1 -1
- package/lib/src/ap-form/ap-form-item.vue.js +1 -1
- package/lib/src/ap-form/modal-form/index.vue.js +1 -1
- package/lib/src/ap-table/ap-table.vue.d.ts +2 -2
- package/lib/src/ap-table/ap-table.vue.js +1 -1
- package/lib/src/ap-table/interface.d.ts +12 -11
- package/lib/src/ap-table/style/ap-table.css +6 -0
- package/lib/src/ap-table/utils.d.ts +2188 -5
- package/lib/src/business/title/style.css +29 -9
- package/lib/src/editable-table/hooks/use-get-columns.d.ts +26 -3
- package/lib/src/editable-table/hooks/use-get-columns.js +1 -1
- package/lib/src/editable-table/interface.d.ts +24 -7
- package/lib/src/editable-table/style/index.css +7 -8
- package/lib/src/theme/antd-global-overwrite/admin/index.css +6 -6
- package/lib/src/theme/antd-global-overwrite/admin/modal.css +6 -6
- package/lib/src/theme/antd-global-overwrite/aplus/index.css +6 -6
- package/lib/src/theme/antd-global-overwrite/aplus/modal.css +6 -6
- package/lib/src/theme/ap-table/ap-table.css +6 -0
- package/lib/src/theme/ap-title/ap-title.css +29 -9
- package/lib/src/theme/editable-table/index.css +7 -8
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
.aplus-ap-title {
|
|
2
2
|
position: relative;
|
|
3
3
|
width: 100%;
|
|
4
|
-
height:
|
|
4
|
+
height: 20px;
|
|
5
5
|
display: flex;
|
|
6
6
|
align-items: center;
|
|
7
7
|
justify-content: space-between;
|
|
@@ -12,17 +12,12 @@
|
|
|
12
12
|
position: absolute;
|
|
13
13
|
content: '';
|
|
14
14
|
left: 0;
|
|
15
|
-
top:
|
|
15
|
+
top: 2px;
|
|
16
16
|
width: 3px;
|
|
17
|
-
height:
|
|
17
|
+
height: 16px;
|
|
18
18
|
background: #0070ff;
|
|
19
19
|
border-radius: 0px 4px 4px 0px;
|
|
20
|
-
|
|
21
|
-
.aplus-ap-title--aplus::before {
|
|
22
|
-
background: #0070ff;
|
|
23
|
-
}
|
|
24
|
-
.aplus-ap-title--admin::before {
|
|
25
|
-
background: #34b77c;
|
|
20
|
+
z-index: 1;
|
|
26
21
|
}
|
|
27
22
|
.aplus-ap-title__prefix {
|
|
28
23
|
font-weight: bold;
|
|
@@ -34,6 +29,31 @@
|
|
|
34
29
|
margin-left: 5px;
|
|
35
30
|
color: #8896b0;
|
|
36
31
|
}
|
|
32
|
+
.aplus-ap-title--admin {
|
|
33
|
+
height: 22px;
|
|
34
|
+
padding-left: 14px;
|
|
35
|
+
}
|
|
36
|
+
.aplus-ap-title--admin::before {
|
|
37
|
+
top: 7px;
|
|
38
|
+
width: 8px;
|
|
39
|
+
height: 8px;
|
|
40
|
+
border-radius: 50%;
|
|
41
|
+
border-width: 2px;
|
|
42
|
+
border-style: solid;
|
|
43
|
+
border-color: #34b77c;
|
|
44
|
+
background: #fff;
|
|
45
|
+
z-index: 1;
|
|
46
|
+
}
|
|
47
|
+
.aplus-ap-title--admin .aplus-ap-title__prefix {
|
|
48
|
+
font-weight: bold;
|
|
49
|
+
color: #333;
|
|
50
|
+
display: flex;
|
|
51
|
+
align-items: center;
|
|
52
|
+
}
|
|
53
|
+
.aplus-ap-title--admin .aplus-ap-title__prefix .anticon-question-circle {
|
|
54
|
+
margin-left: 5px;
|
|
55
|
+
color: #8896b0;
|
|
56
|
+
}
|
|
37
57
|
.aplus-ap-title__suffix {
|
|
38
58
|
color: #526a90;
|
|
39
59
|
}
|
|
@@ -1,5 +1,28 @@
|
|
|
1
|
-
import { EditableTableFormItemProps, EditableTableProps
|
|
2
|
-
import { ComputedRef } from 'vue';
|
|
1
|
+
import { EditableTableFormItemProps, EditableTableProps } from '../interface';
|
|
2
|
+
import { ComputedRef, VNode, RendererNode, RendererElement } from 'vue';
|
|
3
|
+
import { TableColumnType } from 'ant-design-vue';
|
|
4
|
+
import { ValueEnum } from '../..';
|
|
3
5
|
|
|
4
|
-
declare const useGetColumns: (props: EditableTableProps | EditableTableFormItemProps) => ComputedRef<
|
|
6
|
+
declare const useGetColumns: (props: EditableTableProps | EditableTableFormItemProps) => ComputedRef<(Omit< TableColumnType<any>, "children" | "customRender"> & {
|
|
7
|
+
children?: (Omit< TableColumnType<any>, "children" | "customRender"> & any) | undefined;
|
|
8
|
+
tooltip?: string | undefined;
|
|
9
|
+
copyable?: boolean | undefined;
|
|
10
|
+
editable?: boolean | ((text: any, record: any, index: number) => boolean) | undefined;
|
|
11
|
+
valueEnum?: ValueEnum | undefined;
|
|
12
|
+
customRenderFormItem?: ((config: Omit< TableColumnType<any>, "children" | "customRender"> & any) => any) | undefined;
|
|
13
|
+
valueType?: any;
|
|
14
|
+
fieldProps?: any;
|
|
15
|
+
customRender?: ((opt: {
|
|
16
|
+
value: any;
|
|
17
|
+
text: any;
|
|
18
|
+
record: any;
|
|
19
|
+
index: number;
|
|
20
|
+
renderIndex: number;
|
|
21
|
+
column: TableColumnType<any>;
|
|
22
|
+
editable?: boolean | undefined;
|
|
23
|
+
originalNode?: VNode<RendererNode, RendererElement, {
|
|
24
|
+
[key: string]: any;
|
|
25
|
+
}> | undefined;
|
|
26
|
+
}) => any) | undefined;
|
|
27
|
+
})[]>;
|
|
5
28
|
export default useGetColumns;
|
|
@@ -1,76 +1,78 @@
|
|
|
1
|
-
import { computed as
|
|
1
|
+
import { computed as g, createVNode as c, mergeProps as x } from "vue";
|
|
2
2
|
import { isFunction as C } from "lodash-unified";
|
|
3
3
|
import { getEditableComponent as T } from "../utils.mjs";
|
|
4
4
|
import { updateFormProps as h, getFieldProps as F, getPlaceholder as R, getTableRenderProps as I } from "../../ap-table/utils.mjs";
|
|
5
5
|
import "../../config-provider/index.mjs";
|
|
6
|
-
import { apTableRenderItemMap as
|
|
7
|
-
import { Typography as
|
|
8
|
-
import { useLocale as
|
|
9
|
-
const
|
|
6
|
+
import { apTableRenderItemMap as N, noRenderAsFormItemValueList as v } from "../../ap-table/constants.mjs";
|
|
7
|
+
import { Typography as L } from "ant-design-vue";
|
|
8
|
+
import { useLocale as M } from "../../config-provider/hooks/use-locale.mjs";
|
|
9
|
+
const k = (a) => {
|
|
10
10
|
const {
|
|
11
|
-
t:
|
|
12
|
-
} =
|
|
13
|
-
let
|
|
14
|
-
return
|
|
11
|
+
t: s
|
|
12
|
+
} = M(), f = g(() => {
|
|
13
|
+
let o = a.columns;
|
|
14
|
+
return o ? (o = o.map((e) => ({
|
|
15
15
|
...e,
|
|
16
16
|
customRender({
|
|
17
|
-
value:
|
|
18
|
-
...
|
|
17
|
+
value: l,
|
|
18
|
+
...t
|
|
19
19
|
}) {
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
20
|
+
const u = C(e.editable) ? e.editable(t.text, t.record, t.index) : !!e.editable;
|
|
21
|
+
let d;
|
|
22
|
+
if (u) {
|
|
23
|
+
const r = T(e.valueType), n = h(e, F(e.fieldProps, {
|
|
24
|
+
value: l,
|
|
25
|
+
...t
|
|
26
|
+
})), i = {};
|
|
27
|
+
a.onFieldChange && (i[`onUpdate:${n.valuePropName || "value"}`] = (y) => {
|
|
28
|
+
var p;
|
|
29
|
+
return (p = a.onFieldChange) == null ? void 0 : p.call(a, t.index, e.dataIndex, y);
|
|
25
30
|
});
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
style: "width: 100%",
|
|
43
|
-
...(t == null ? void 0 : t.field) || {},
|
|
44
|
-
...r
|
|
45
|
-
}
|
|
46
|
-
};
|
|
47
|
-
return d(m, b, null);
|
|
48
|
-
}
|
|
49
|
-
const s = v[e.valueType], f = I(e, {
|
|
50
|
-
value: o,
|
|
51
|
-
...l
|
|
31
|
+
const b = {
|
|
32
|
+
name: [a.name, t.index, e.dataIndex],
|
|
33
|
+
...n || {},
|
|
34
|
+
// 格式化placeholder
|
|
35
|
+
placeholder: R(s, e.valueType, n == null ? void 0 : n.placeholder),
|
|
36
|
+
field: {
|
|
37
|
+
style: "width: 100%",
|
|
38
|
+
...(n == null ? void 0 : n.field) || {},
|
|
39
|
+
...i
|
|
40
|
+
}
|
|
41
|
+
};
|
|
42
|
+
d = c(r, b, null);
|
|
43
|
+
} else {
|
|
44
|
+
const r = N[e.valueType], n = I(e, {
|
|
45
|
+
value: l,
|
|
46
|
+
...t
|
|
52
47
|
});
|
|
53
|
-
|
|
48
|
+
d = m(e, l, c(r, x(n, {
|
|
54
49
|
mode: "read"
|
|
55
50
|
}), null));
|
|
56
51
|
}
|
|
52
|
+
return e.customRender ? e.customRender({
|
|
53
|
+
value: l,
|
|
54
|
+
...t,
|
|
55
|
+
column: e,
|
|
56
|
+
editable: u,
|
|
57
|
+
originalNode: d
|
|
58
|
+
}) : d;
|
|
57
59
|
}
|
|
58
|
-
})),
|
|
60
|
+
})), o) : [];
|
|
59
61
|
});
|
|
60
|
-
function
|
|
61
|
-
return
|
|
62
|
-
copyable:
|
|
62
|
+
function m(o, e, l) {
|
|
63
|
+
return v.includes(o.valueType) ? l : o.copyable || o.ellipsis ? c(L.Text, {
|
|
64
|
+
copyable: o.copyable ? {
|
|
63
65
|
text: e,
|
|
64
66
|
tooltip: !1
|
|
65
67
|
} : !1,
|
|
66
|
-
ellipsis:
|
|
68
|
+
ellipsis: o.ellipsis ? {
|
|
67
69
|
tooltip: e
|
|
68
70
|
} : !1,
|
|
69
|
-
content:
|
|
70
|
-
}, null) :
|
|
71
|
+
content: l
|
|
72
|
+
}, null) : l;
|
|
71
73
|
}
|
|
72
|
-
return
|
|
74
|
+
return f;
|
|
73
75
|
};
|
|
74
76
|
export {
|
|
75
|
-
|
|
77
|
+
k as default
|
|
76
78
|
};
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import { ColumnType, TableProps } from 'ant-design-vue/es/table';
|
|
2
|
-
import { ApTableValueFields, ValueEnum } from '../ap-table';
|
|
2
|
+
import { ApTableValueFields, ApTableValueTypes, ValueEnum } from '../ap-table';
|
|
3
3
|
import { NamePath, ValidateOptions } from 'ant-design-vue/es/form/interface';
|
|
4
4
|
import { DataIndex } from 'ant-design-vue/es/vc-table/interface';
|
|
5
5
|
import { FormItemProps } from 'ant-design-vue';
|
|
6
|
+
import { VNode } from 'vue';
|
|
6
7
|
|
|
7
|
-
export type EditableColumnType<ValueType extends
|
|
8
|
+
export type EditableColumnType<RecordType = any, ValueType extends ApTableValueTypes = ApTableValueTypes> = ValueType extends ApTableValueTypes ? Omit<ColumnType<RecordType>, 'children' | 'customRender'> & {
|
|
9
|
+
children?: EditableColumnType<RecordType, ValueType>;
|
|
8
10
|
/**
|
|
9
11
|
* 在title之后展示一个icon并触发tooltip
|
|
10
12
|
*/
|
|
@@ -25,11 +27,11 @@ export type EditableColumnType<ValueType extends keyof ApTableValueFields = 'tex
|
|
|
25
27
|
* 自定义表单
|
|
26
28
|
* @deprecated 未实现,请使用`customRender`
|
|
27
29
|
*/
|
|
28
|
-
customRenderFormItem?: (config: EditableColumnType<
|
|
30
|
+
customRenderFormItem?: (config: EditableColumnType<RecordType, ValueType>) => any;
|
|
29
31
|
/**
|
|
30
32
|
* 指定值类型(将会用于普通列和可编辑表格的渲染)
|
|
31
33
|
*/
|
|
32
|
-
valueType?:
|
|
34
|
+
valueType?: ValueType;
|
|
33
35
|
/**
|
|
34
36
|
* 值类型额外配置的参数(支持函数)
|
|
35
37
|
*/
|
|
@@ -39,14 +41,29 @@ export type EditableColumnType<ValueType extends keyof ApTableValueFields = 'tex
|
|
|
39
41
|
record: RecordType;
|
|
40
42
|
index: number;
|
|
41
43
|
renderIndex: number;
|
|
42
|
-
column: EditableColumnType<
|
|
44
|
+
column: EditableColumnType<RecordType, ValueType>;
|
|
43
45
|
}) => ApTableValueFields[ValueType]);
|
|
44
|
-
|
|
46
|
+
/**
|
|
47
|
+
* 自定义渲染,添加了`editable`以及`originalNode`
|
|
48
|
+
* @param opt
|
|
49
|
+
* @returns
|
|
50
|
+
*/
|
|
51
|
+
customRender?: (opt: {
|
|
52
|
+
value: any;
|
|
53
|
+
text: any;
|
|
54
|
+
record: RecordType;
|
|
55
|
+
index: number;
|
|
56
|
+
renderIndex: number;
|
|
57
|
+
column: ColumnType<RecordType>;
|
|
58
|
+
editable?: boolean;
|
|
59
|
+
originalNode?: VNode;
|
|
60
|
+
}) => any;
|
|
61
|
+
} : never;
|
|
45
62
|
export type EditableTableProps<RecordType = any> = Omit<TableProps<RecordType>, 'columns' | 'dataSource'> & {
|
|
46
63
|
/**
|
|
47
64
|
* 列配置
|
|
48
65
|
*/
|
|
49
|
-
columns?: EditableColumnType<
|
|
66
|
+
columns?: EditableColumnType<RecordType, any>[];
|
|
50
67
|
/**
|
|
51
68
|
* 表格数据v-model
|
|
52
69
|
*/
|
|
@@ -1,12 +1,5 @@
|
|
|
1
|
-
.aplus-editable-table .ant-table-cell:has(> .ant-form-item) {
|
|
2
|
-
padding-top: 20px !important;
|
|
3
|
-
padding-bottom: 0 !important;
|
|
4
|
-
}
|
|
5
1
|
.aplus-editable-table .ant-form-item {
|
|
6
|
-
margin-bottom:
|
|
7
|
-
}
|
|
8
|
-
.aplus-editable-table .ant-form-item-explain-error {
|
|
9
|
-
line-height: 20px;
|
|
2
|
+
margin-bottom: 0px;
|
|
10
3
|
}
|
|
11
4
|
.aplus-editable-table__header-cell--required {
|
|
12
5
|
color: #FF4D4F;
|
|
@@ -44,3 +37,9 @@
|
|
|
44
37
|
.aplus-editable-table-admin tr > td.ant-table-cell {
|
|
45
38
|
border-top-color: #E9E9E9;
|
|
46
39
|
}
|
|
40
|
+
.aplus-editable-table .ant-table-middle .ant-table-cell {
|
|
41
|
+
padding: 12px 16px !important;
|
|
42
|
+
}
|
|
43
|
+
.aplus-editable-table .ant-table-small .ant-table-cell {
|
|
44
|
+
padding: 9px 16px !important;
|
|
45
|
+
}
|
|
@@ -157,7 +157,7 @@ div[class$='-basic-table-form-container'] form[class$='-basic-form--compact'] di
|
|
|
157
157
|
vertical-align: -0.18em;
|
|
158
158
|
margin-inline-end: 9px;
|
|
159
159
|
}
|
|
160
|
-
.ant-modal-root .ant-modal-close {
|
|
160
|
+
.ant-modal-root .ant-modal .ant-modal-close {
|
|
161
161
|
top: 0;
|
|
162
162
|
right: 0;
|
|
163
163
|
width: auto;
|
|
@@ -167,28 +167,28 @@ div[class$='-basic-table-form-container'] form[class$='-basic-form--compact'] di
|
|
|
167
167
|
outline: none;
|
|
168
168
|
cursor: default;
|
|
169
169
|
}
|
|
170
|
-
.ant-modal-root .ant-modal-close:hover {
|
|
170
|
+
.ant-modal-root .ant-modal .ant-modal-close:hover {
|
|
171
171
|
color: #666666;
|
|
172
172
|
background-color: transparent;
|
|
173
173
|
}
|
|
174
|
-
.ant-modal-root .ant-modal-close-x {
|
|
174
|
+
.ant-modal-root .ant-modal .ant-modal-close-x {
|
|
175
175
|
display: inline-block;
|
|
176
176
|
width: 96px;
|
|
177
177
|
height: 54px;
|
|
178
178
|
line-height: 54px;
|
|
179
179
|
text-align: start;
|
|
180
180
|
}
|
|
181
|
-
.ant-modal-root .ant-modal-close-x > div {
|
|
181
|
+
.ant-modal-root .ant-modal .ant-modal-close-x > div {
|
|
182
182
|
height: 100%;
|
|
183
183
|
}
|
|
184
|
-
.ant-modal-root .ant-modal-close-x > span {
|
|
184
|
+
.ant-modal-root .ant-modal .ant-modal-close-x > span {
|
|
185
185
|
display: inline-block;
|
|
186
186
|
margin-left: 48px;
|
|
187
187
|
padding: 10px;
|
|
188
188
|
cursor: pointer;
|
|
189
189
|
transition: all 0.2s;
|
|
190
190
|
}
|
|
191
|
-
.ant-modal-root .ant-modal-close-x > span:hover {
|
|
191
|
+
.ant-modal-root .ant-modal .ant-modal-close-x > span:hover {
|
|
192
192
|
color: #ed6f6f;
|
|
193
193
|
}
|
|
194
194
|
.ant-modal-root .ant-modal .ant-modal-content {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
.ant-modal-root .ant-modal-close {
|
|
1
|
+
.ant-modal-root .ant-modal .ant-modal-close {
|
|
2
2
|
top: 0;
|
|
3
3
|
right: 0;
|
|
4
4
|
width: auto;
|
|
@@ -8,28 +8,28 @@
|
|
|
8
8
|
outline: none;
|
|
9
9
|
cursor: default;
|
|
10
10
|
}
|
|
11
|
-
.ant-modal-root .ant-modal-close:hover {
|
|
11
|
+
.ant-modal-root .ant-modal .ant-modal-close:hover {
|
|
12
12
|
color: #666666;
|
|
13
13
|
background-color: transparent;
|
|
14
14
|
}
|
|
15
|
-
.ant-modal-root .ant-modal-close-x {
|
|
15
|
+
.ant-modal-root .ant-modal .ant-modal-close-x {
|
|
16
16
|
display: inline-block;
|
|
17
17
|
width: 96px;
|
|
18
18
|
height: 54px;
|
|
19
19
|
line-height: 54px;
|
|
20
20
|
text-align: start;
|
|
21
21
|
}
|
|
22
|
-
.ant-modal-root .ant-modal-close-x > div {
|
|
22
|
+
.ant-modal-root .ant-modal .ant-modal-close-x > div {
|
|
23
23
|
height: 100%;
|
|
24
24
|
}
|
|
25
|
-
.ant-modal-root .ant-modal-close-x > span {
|
|
25
|
+
.ant-modal-root .ant-modal .ant-modal-close-x > span {
|
|
26
26
|
display: inline-block;
|
|
27
27
|
margin-left: 48px;
|
|
28
28
|
padding: 10px;
|
|
29
29
|
cursor: pointer;
|
|
30
30
|
transition: all 0.2s;
|
|
31
31
|
}
|
|
32
|
-
.ant-modal-root .ant-modal-close-x > span:hover {
|
|
32
|
+
.ant-modal-root .ant-modal .ant-modal-close-x > span:hover {
|
|
33
33
|
color: #ed6f6f;
|
|
34
34
|
}
|
|
35
35
|
.ant-modal-root .ant-modal .ant-modal-content {
|
|
@@ -182,7 +182,7 @@ div[class$='-basic-table-form-container'] form[class$='-basic-form--compact'] di
|
|
|
182
182
|
vertical-align: -0.18em;
|
|
183
183
|
margin-inline-end: 9px;
|
|
184
184
|
}
|
|
185
|
-
.ant-modal-root .ant-modal-close {
|
|
185
|
+
.ant-modal-root .ant-modal .ant-modal-close {
|
|
186
186
|
top: 0;
|
|
187
187
|
right: 0;
|
|
188
188
|
width: auto;
|
|
@@ -192,28 +192,28 @@ div[class$='-basic-table-form-container'] form[class$='-basic-form--compact'] di
|
|
|
192
192
|
outline: none;
|
|
193
193
|
cursor: default;
|
|
194
194
|
}
|
|
195
|
-
.ant-modal-root .ant-modal-close:hover {
|
|
195
|
+
.ant-modal-root .ant-modal .ant-modal-close:hover {
|
|
196
196
|
color: #8796b0;
|
|
197
197
|
background-color: transparent;
|
|
198
198
|
}
|
|
199
|
-
.ant-modal-root .ant-modal-close-x {
|
|
199
|
+
.ant-modal-root .ant-modal .ant-modal-close-x {
|
|
200
200
|
display: inline-block;
|
|
201
201
|
width: 96px;
|
|
202
202
|
height: 54px;
|
|
203
203
|
line-height: 54px;
|
|
204
204
|
text-align: start;
|
|
205
205
|
}
|
|
206
|
-
.ant-modal-root .ant-modal-close-x > div {
|
|
206
|
+
.ant-modal-root .ant-modal .ant-modal-close-x > div {
|
|
207
207
|
height: 100%;
|
|
208
208
|
}
|
|
209
|
-
.ant-modal-root .ant-modal-close-x > span {
|
|
209
|
+
.ant-modal-root .ant-modal .ant-modal-close-x > span {
|
|
210
210
|
display: inline-block;
|
|
211
211
|
margin-left: 48px;
|
|
212
212
|
padding: 10px;
|
|
213
213
|
cursor: pointer;
|
|
214
214
|
transition: all 0.2s;
|
|
215
215
|
}
|
|
216
|
-
.ant-modal-root .ant-modal-close-x > span:hover {
|
|
216
|
+
.ant-modal-root .ant-modal .ant-modal-close-x > span:hover {
|
|
217
217
|
color: #ed6f6f;
|
|
218
218
|
}
|
|
219
219
|
.ant-modal-root .ant-modal .ant-modal-content {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
.ant-modal-root .ant-modal-close {
|
|
1
|
+
.ant-modal-root .ant-modal .ant-modal-close {
|
|
2
2
|
top: 0;
|
|
3
3
|
right: 0;
|
|
4
4
|
width: auto;
|
|
@@ -8,28 +8,28 @@
|
|
|
8
8
|
outline: none;
|
|
9
9
|
cursor: default;
|
|
10
10
|
}
|
|
11
|
-
.ant-modal-root .ant-modal-close:hover {
|
|
11
|
+
.ant-modal-root .ant-modal .ant-modal-close:hover {
|
|
12
12
|
color: #8796b0;
|
|
13
13
|
background-color: transparent;
|
|
14
14
|
}
|
|
15
|
-
.ant-modal-root .ant-modal-close-x {
|
|
15
|
+
.ant-modal-root .ant-modal .ant-modal-close-x {
|
|
16
16
|
display: inline-block;
|
|
17
17
|
width: 96px;
|
|
18
18
|
height: 54px;
|
|
19
19
|
line-height: 54px;
|
|
20
20
|
text-align: start;
|
|
21
21
|
}
|
|
22
|
-
.ant-modal-root .ant-modal-close-x > div {
|
|
22
|
+
.ant-modal-root .ant-modal .ant-modal-close-x > div {
|
|
23
23
|
height: 100%;
|
|
24
24
|
}
|
|
25
|
-
.ant-modal-root .ant-modal-close-x > span {
|
|
25
|
+
.ant-modal-root .ant-modal .ant-modal-close-x > span {
|
|
26
26
|
display: inline-block;
|
|
27
27
|
margin-left: 48px;
|
|
28
28
|
padding: 10px;
|
|
29
29
|
cursor: pointer;
|
|
30
30
|
transition: all 0.2s;
|
|
31
31
|
}
|
|
32
|
-
.ant-modal-root .ant-modal-close-x > span:hover {
|
|
32
|
+
.ant-modal-root .ant-modal .ant-modal-close-x > span:hover {
|
|
33
33
|
color: #ed6f6f;
|
|
34
34
|
}
|
|
35
35
|
.ant-modal-root .ant-modal .ant-modal-content {
|
|
@@ -72,3 +72,9 @@
|
|
|
72
72
|
.aplus-ap-table-table-admin tr > td.ant-table-cell {
|
|
73
73
|
border-top-color: #E9E9E9;
|
|
74
74
|
}
|
|
75
|
+
.aplus-ap-table .ant-table-middle .ant-table-cell {
|
|
76
|
+
padding: 12px 16px !important;
|
|
77
|
+
}
|
|
78
|
+
.aplus-ap-table .ant-table-small .ant-table-cell {
|
|
79
|
+
padding: 9px 16px !important;
|
|
80
|
+
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
.aplus-ap-title {
|
|
2
2
|
position: relative;
|
|
3
3
|
width: 100%;
|
|
4
|
-
height:
|
|
4
|
+
height: 20px;
|
|
5
5
|
display: flex;
|
|
6
6
|
align-items: center;
|
|
7
7
|
justify-content: space-between;
|
|
@@ -12,17 +12,12 @@
|
|
|
12
12
|
position: absolute;
|
|
13
13
|
content: '';
|
|
14
14
|
left: 0;
|
|
15
|
-
top:
|
|
15
|
+
top: 2px;
|
|
16
16
|
width: 3px;
|
|
17
|
-
height:
|
|
17
|
+
height: 16px;
|
|
18
18
|
background: #0070ff;
|
|
19
19
|
border-radius: 0px 4px 4px 0px;
|
|
20
|
-
|
|
21
|
-
.aplus-ap-title--aplus::before {
|
|
22
|
-
background: #0070ff;
|
|
23
|
-
}
|
|
24
|
-
.aplus-ap-title--admin::before {
|
|
25
|
-
background: #34b77c;
|
|
20
|
+
z-index: 1;
|
|
26
21
|
}
|
|
27
22
|
.aplus-ap-title__prefix {
|
|
28
23
|
font-weight: bold;
|
|
@@ -34,6 +29,31 @@
|
|
|
34
29
|
margin-left: 5px;
|
|
35
30
|
color: #8896b0;
|
|
36
31
|
}
|
|
32
|
+
.aplus-ap-title--admin {
|
|
33
|
+
height: 22px;
|
|
34
|
+
padding-left: 14px;
|
|
35
|
+
}
|
|
36
|
+
.aplus-ap-title--admin::before {
|
|
37
|
+
top: 7px;
|
|
38
|
+
width: 8px;
|
|
39
|
+
height: 8px;
|
|
40
|
+
border-radius: 50%;
|
|
41
|
+
border-width: 2px;
|
|
42
|
+
border-style: solid;
|
|
43
|
+
border-color: #34b77c;
|
|
44
|
+
background: #fff;
|
|
45
|
+
z-index: 1;
|
|
46
|
+
}
|
|
47
|
+
.aplus-ap-title--admin .aplus-ap-title__prefix {
|
|
48
|
+
font-weight: bold;
|
|
49
|
+
color: #333;
|
|
50
|
+
display: flex;
|
|
51
|
+
align-items: center;
|
|
52
|
+
}
|
|
53
|
+
.aplus-ap-title--admin .aplus-ap-title__prefix .anticon-question-circle {
|
|
54
|
+
margin-left: 5px;
|
|
55
|
+
color: #8896b0;
|
|
56
|
+
}
|
|
37
57
|
.aplus-ap-title__suffix {
|
|
38
58
|
color: #526a90;
|
|
39
59
|
}
|
|
@@ -1,12 +1,5 @@
|
|
|
1
|
-
.aplus-editable-table .ant-table-cell:has(> .ant-form-item) {
|
|
2
|
-
padding-top: 20px !important;
|
|
3
|
-
padding-bottom: 0 !important;
|
|
4
|
-
}
|
|
5
1
|
.aplus-editable-table .ant-form-item {
|
|
6
|
-
margin-bottom:
|
|
7
|
-
}
|
|
8
|
-
.aplus-editable-table .ant-form-item-explain-error {
|
|
9
|
-
line-height: 20px;
|
|
2
|
+
margin-bottom: 0px;
|
|
10
3
|
}
|
|
11
4
|
.aplus-editable-table__header-cell--required {
|
|
12
5
|
color: #FF4D4F;
|
|
@@ -44,3 +37,9 @@
|
|
|
44
37
|
.aplus-editable-table-admin tr > td.ant-table-cell {
|
|
45
38
|
border-top-color: #E9E9E9;
|
|
46
39
|
}
|
|
40
|
+
.aplus-editable-table .ant-table-middle .ant-table-cell {
|
|
41
|
+
padding: 12px 16px !important;
|
|
42
|
+
}
|
|
43
|
+
.aplus-editable-table .ant-table-small .ant-table-cell {
|
|
44
|
+
padding: 9px 16px !important;
|
|
45
|
+
}
|
|
@@ -80,3 +80,14 @@ export type ApActionItemModalProps = ApActionItemProps & {
|
|
|
80
80
|
export type ApActionItemPopconfirmProps = ApActionItemProps & {
|
|
81
81
|
popconfirmProps?: PopconfirmProps;
|
|
82
82
|
};
|
|
83
|
+
/**
|
|
84
|
+
* ApActionItem支持的插槽
|
|
85
|
+
*/
|
|
86
|
+
export type ApActionItemSlots = {
|
|
87
|
+
default?: any;
|
|
88
|
+
trigger?: (options: {
|
|
89
|
+
loading: boolean;
|
|
90
|
+
disabled: boolean;
|
|
91
|
+
onClick: (e: MouseEvent) => void;
|
|
92
|
+
}) => any;
|
|
93
|
+
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ApActionItemProps, ActionColor } from '../interface';
|
|
1
|
+
import { ApActionItemProps, ApActionItemSlots, ActionColor } from '../interface';
|
|
2
2
|
import { DefineComponent, ComponentOptionsMixin, PublicProps, ExtractPropTypes, PropType } from 'vue';
|
|
3
3
|
|
|
4
4
|
declare const _default: __VLS_WithTemplateSlots< DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<ApActionItemProps>, {
|
|
@@ -16,9 +16,7 @@ declare const _default: __VLS_WithTemplateSlots< DefineComponent<__VLS_WithDefau
|
|
|
16
16
|
disabled: boolean;
|
|
17
17
|
visible: boolean;
|
|
18
18
|
loading: boolean;
|
|
19
|
-
}, {}>,
|
|
20
|
-
default?(_: {}): any;
|
|
21
|
-
}>;
|
|
19
|
+
}, {}>, Readonly<ApActionItemSlots> & ApActionItemSlots>;
|
|
22
20
|
export default _default;
|
|
23
21
|
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
24
22
|
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue");require("../../config-provider/index.js");const m=require("ant-design-vue/es/button/LoadingIcon");require("../style/item.css");const p=require("../../config-provider/hooks/use-namespace.js"),
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue");require("../../config-provider/index.js");const m=require("ant-design-vue/es/button/LoadingIcon");require("../style/item.css");const p=require("../../config-provider/hooks/use-namespace.js"),g=require("../../config-provider/hooks/use-global-config.js"),k={key:1},b=e.defineComponent({name:"ApActionItem",__name:"index",props:{text:{},color:{default:"primary"},disabled:{type:Boolean,default:!1},visible:{type:Boolean,default:!0},onAction:{},onClick:{},loading:{type:Boolean,default:!1}},setup(s){const n=s,{b:u,m:i,bm:c}=p.useNamespace("action-item"),d=g.useGlobalConfig("uiMode","aplus"),t=e.ref(!1);function r(o){var a;e.unref(l)||n.disabled||((a=n.onClick)==null||a.call(n,o),n.onAction&&(t.value=!0,n.onAction(o).finally(()=>t.value=!1)))}const l=e.computed(()=>n.loading||e.unref(t)),f=e.computed(()=>[u(),c(e.unref(d),n.color),n.disabled?i("disabled"):null,l.value?i("loading"):null].filter(Boolean));return(o,a)=>e.renderSlot(o.$slots,"trigger",{loading:l.value,disabled:o.disabled,onClick:r},()=>[o.visible?(e.openBlock(),e.createElementBlock("span",{key:0,onClick:r,class:e.normalizeClass(f.value)},[l.value?(e.openBlock(),e.createBlock(e.unref(m),{key:0,prefixCls:"btn",existIcon:!1,loading:""})):e.createCommentVNode("",!0),e.renderSlot(o.$slots,"default",{},()=>[e.isVNode(o.text)?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(o.text),{key:0})):(e.openBlock(),e.createElementBlock("span",k,e.toDisplayString(o.text||""),1))])],2)):e.createCommentVNode("",!0)])}});exports.default=b;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { ApActionItemModalProps, ActionColor } from '../interface';
|
|
1
|
+
import { ApActionItemModalProps, ApActionItemSlots, ActionColor } from '../interface';
|
|
2
2
|
import { DefineComponent, ComponentOptionsMixin, PublicProps, ExtractPropTypes, PropType } from 'vue';
|
|
3
3
|
import { ModalFuncProps } from 'ant-design-vue';
|
|
4
4
|
|
|
5
|
-
declare const _default: DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<ApActionItemModalProps>, {
|
|
5
|
+
declare const _default: __VLS_WithTemplateSlots< DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<ApActionItemModalProps>, {
|
|
6
6
|
color: string;
|
|
7
7
|
disabled: boolean;
|
|
8
8
|
visible: boolean;
|
|
@@ -20,7 +20,7 @@ declare const _default: DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRunt
|
|
|
20
20
|
visible: boolean;
|
|
21
21
|
loading: boolean;
|
|
22
22
|
modalProps: Omit< ModalFuncProps, "type">;
|
|
23
|
-
}, {}>;
|
|
23
|
+
}, {}>, Readonly<ApActionItemSlots> & ApActionItemSlots>;
|
|
24
24
|
export default _default;
|
|
25
25
|
type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
|
|
26
26
|
type __VLS_TypePropsToRuntimeProps<T> = {
|
|
@@ -39,3 +39,8 @@ type __VLS_WithDefaults<P, D> = {
|
|
|
39
39
|
type __VLS_Prettify<T> = {
|
|
40
40
|
[K in keyof T]: T[K];
|
|
41
41
|
} & {};
|
|
42
|
+
type __VLS_WithTemplateSlots<T, S> = T & {
|
|
43
|
+
new (): {
|
|
44
|
+
$slots: S;
|
|
45
|
+
};
|
|
46
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("vue"),c=require("ant-design-vue");require("../item/index.vue.js");const d=require("lodash-unified"),p=require("../item/index.vue2.js"),f=e.defineComponent({name:"ApActionItemModal",__name:"index",props:{text:{},color:{default:"primary"},disabled:{type:Boolean,default:!1},visible:{type:Boolean,default:!0},onAction:{},onClick:{},loading:{type:Boolean,default:!1},modalProps:{default:()=>({})}},setup(l){const s=e.useSlots(),o=l;async function i(n){c.Modal.confirm({...o.modalProps,onOk:async()=>{var r,a,t;(a=(r=o.modalProps).onOk)==null||a.call(r),await((t=o.onAction)==null?void 0:t.call(o,n))}})}return(n,r)=>(e.openBlock(),e.createBlock(p.default,e.mergeProps(e.unref(d.omit)(o,["modalProps","onAction"]),{onAction:i}),e.createSlots({_:2},[e.renderList(s,(a,t)=>({name:t,fn:e.withCtx(u=>[e.renderSlot(n.$slots,t,e.normalizeProps(e.guardReactiveProps(u||{})))])}))]),1040))}});exports.default=f;
|