@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.
Files changed (53) hide show
  1. package/es/src/ap-action/interface.d.ts +11 -0
  2. package/es/src/ap-action/item/index.vue.d.ts +2 -4
  3. package/es/src/ap-action/item/index.vue2.mjs +34 -28
  4. package/es/src/ap-action/item-modal/index.vue.d.ts +8 -3
  5. package/es/src/ap-action/item-modal/index.vue.mjs +20 -13
  6. package/es/src/ap-action/item-popconfirm/index.vue.d.ts +8 -3
  7. package/es/src/ap-action/item-popconfirm/index.vue.mjs +23 -16
  8. package/es/src/ap-form/ap-form-item.vue.mjs +45 -42
  9. package/es/src/ap-form/modal-form/index.vue.mjs +68 -66
  10. package/es/src/ap-table/ap-table.vue.d.ts +2 -2
  11. package/es/src/ap-table/ap-table.vue.mjs +90 -92
  12. package/es/src/ap-table/interface.d.ts +12 -11
  13. package/es/src/ap-table/style/ap-table.css +6 -0
  14. package/es/src/ap-table/utils.d.ts +2188 -5
  15. package/es/src/business/title/style.css +29 -9
  16. package/es/src/editable-table/hooks/use-get-columns.d.ts +26 -3
  17. package/es/src/editable-table/hooks/use-get-columns.mjs +54 -52
  18. package/es/src/editable-table/interface.d.ts +24 -7
  19. package/es/src/editable-table/style/index.css +7 -8
  20. package/es/src/theme/antd-global-overwrite/admin/index.css +6 -6
  21. package/es/src/theme/antd-global-overwrite/admin/modal.css +6 -6
  22. package/es/src/theme/antd-global-overwrite/aplus/index.css +6 -6
  23. package/es/src/theme/antd-global-overwrite/aplus/modal.css +6 -6
  24. package/es/src/theme/ap-table/ap-table.css +6 -0
  25. package/es/src/theme/ap-title/ap-title.css +29 -9
  26. package/es/src/theme/editable-table/index.css +7 -8
  27. package/lib/src/ap-action/interface.d.ts +11 -0
  28. package/lib/src/ap-action/item/index.vue.d.ts +2 -4
  29. package/lib/src/ap-action/item/index.vue2.js +1 -1
  30. package/lib/src/ap-action/item-modal/index.vue.d.ts +8 -3
  31. package/lib/src/ap-action/item-modal/index.vue.js +1 -1
  32. package/lib/src/ap-action/item-popconfirm/index.vue.d.ts +8 -3
  33. package/lib/src/ap-action/item-popconfirm/index.vue.js +1 -1
  34. package/lib/src/ap-form/ap-form-item.vue.js +1 -1
  35. package/lib/src/ap-form/modal-form/index.vue.js +1 -1
  36. package/lib/src/ap-table/ap-table.vue.d.ts +2 -2
  37. package/lib/src/ap-table/ap-table.vue.js +1 -1
  38. package/lib/src/ap-table/interface.d.ts +12 -11
  39. package/lib/src/ap-table/style/ap-table.css +6 -0
  40. package/lib/src/ap-table/utils.d.ts +2188 -5
  41. package/lib/src/business/title/style.css +29 -9
  42. package/lib/src/editable-table/hooks/use-get-columns.d.ts +26 -3
  43. package/lib/src/editable-table/hooks/use-get-columns.js +1 -1
  44. package/lib/src/editable-table/interface.d.ts +24 -7
  45. package/lib/src/editable-table/style/index.css +7 -8
  46. package/lib/src/theme/antd-global-overwrite/admin/index.css +6 -6
  47. package/lib/src/theme/antd-global-overwrite/admin/modal.css +6 -6
  48. package/lib/src/theme/antd-global-overwrite/aplus/index.css +6 -6
  49. package/lib/src/theme/antd-global-overwrite/aplus/modal.css +6 -6
  50. package/lib/src/theme/ap-table/ap-table.css +6 -0
  51. package/lib/src/theme/ap-title/ap-title.css +29 -9
  52. package/lib/src/theme/editable-table/index.css +7 -8
  53. package/package.json +1 -1
@@ -1,7 +1,7 @@
1
1
  .aplus-ap-title {
2
2
  position: relative;
3
3
  width: 100%;
4
- height: 32px;
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: 6px;
15
+ top: 2px;
16
16
  width: 3px;
17
- height: 20px;
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, EditableColumnType } from '../interface';
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< EditableColumnType<any, any>[]>;
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 x, createVNode as d, mergeProps as g } from "vue";
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 v, noRenderAsFormItemValueList as L } from "../../ap-table/constants.mjs";
7
- import { Typography as M } from "ant-design-vue";
8
- import { useLocale as N } from "../../config-provider/hooks/use-locale.mjs";
9
- const q = (a) => {
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: u
12
- } = N(), i = x(() => {
13
- let n = a.columns;
14
- return n ? (n = n.map((e) => ({
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: o,
18
- ...l
17
+ value: l,
18
+ ...t
19
19
  }) {
20
- if (e.customRender)
21
- return e.customRender({
22
- value: o,
23
- ...l,
24
- column: e
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
- if (C(e.editable) ? e.editable(l.text, l.record, l.index) : !!e.editable) {
28
- const m = T(e.valueType), t = h(e, F(e.fieldProps, {
29
- value: o,
30
- ...l
31
- })), r = {};
32
- a.onFieldChange && (r[`onUpdate:${t.valuePropName || "value"}`] = (y) => {
33
- var c;
34
- return (c = a.onFieldChange) == null ? void 0 : c.call(a, l.index, e.dataIndex, y);
35
- });
36
- const b = {
37
- name: [a.name, l.index, e.dataIndex],
38
- ...t || {},
39
- // 格式化placeholder
40
- placeholder: R(u, e.valueType, t == null ? void 0 : t.placeholder),
41
- field: {
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
- return p(e, o, d(s, g(f, {
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
- })), n) : [];
60
+ })), o) : [];
59
61
  });
60
- function p(n, e, o) {
61
- return L.includes(n.valueType) ? o : n.copyable || n.ellipsis ? d(M.Text, {
62
- copyable: n.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: n.ellipsis ? {
68
+ ellipsis: o.ellipsis ? {
67
69
  tooltip: e
68
70
  } : !1,
69
- content: o
70
- }, null) : o;
71
+ content: l
72
+ }, null) : l;
71
73
  }
72
- return i;
74
+ return f;
73
75
  };
74
76
  export {
75
- q as default
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 keyof ApTableValueFields = 'text', RecordType = any> = Omit<ColumnType<RecordType>, 'children'> & {
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<ValueType, RecordType>) => any;
30
+ customRenderFormItem?: (config: EditableColumnType<RecordType, ValueType>) => any;
29
31
  /**
30
32
  * 指定值类型(将会用于普通列和可编辑表格的渲染)
31
33
  */
32
- valueType?: keyof ApTableValueFields;
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<ValueType, RecordType>;
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<any, RecordType>[];
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: 20px;
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: 32px;
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: 6px;
15
+ top: 2px;
16
16
  width: 3px;
17
- height: 20px;
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: 20px;
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"),k=require("../../config-provider/hooks/use-global-config.js"),g={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(r){const o=r,{b:s,m:i,bm:u}=p.useNamespace("action-item"),c=k.useGlobalConfig("uiMode","aplus"),t=e.ref(!1);function d(n){var a;e.unref(l)||o.disabled||((a=o.onClick)==null||a.call(o,n),o.onAction&&(t.value=!0,o.onAction(n).finally(()=>t.value=!1)))}const l=e.computed(()=>o.loading||e.unref(t)),f=e.computed(()=>[s(),u(e.unref(c),o.color),o.disabled?i("disabled"):null,l.value?i("loading"):null].filter(Boolean));return(n,a)=>n.visible?(e.openBlock(),e.createElementBlock("span",{key:0,onClick:d,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(n.$slots,"default",{},()=>[e.isVNode(n.text)?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(n.text),{key:0})):(e.openBlock(),e.createElementBlock("span",g,e.toDisplayString(n.text||""),1))])],2)):e.createCommentVNode("",!0)}});exports.default=b;
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 o=require("vue"),u=require("ant-design-vue");require("../item/index.vue.js");const c=require("lodash-unified"),s=require("../item/index.vue2.js"),d=o.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(r){const e=r;async function i(t){u.Modal.confirm({...e.modalProps,onOk:async()=>{var n,a,l;(a=(n=e.modalProps).onOk)==null||a.call(n),await((l=e.onAction)==null?void 0:l.call(e,t))}})}return(t,n)=>(o.openBlock(),o.createBlock(s.default,o.mergeProps(o.unref(c.omit)(e,["modalProps","onAction"]),{onAction:i}),null,16))}});exports.default=d;
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;