@jiovan-labs/ant-buddy-pro 2.0.0 → 2.0.2

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 (40) hide show
  1. package/README.md +1 -2
  2. package/README.zh-CN.md +55 -0
  3. package/README.zh-TW.md +55 -0
  4. package/dist/cjs/field/CountField/index.d.ts +2 -2
  5. package/dist/cjs/field/LabelField/index.d.ts +2 -2
  6. package/dist/cjs/field/ThumbToggle/index.d.ts +2 -2
  7. package/dist/cjs/form/AvatarUpload/index.d.ts +3 -3
  8. package/dist/cjs/form/AvatarUpload/index.js +6 -3
  9. package/dist/cjs/form/CronInput/index.js +6 -3
  10. package/dist/cjs/form/DivideSelect/index.js +17 -15
  11. package/dist/cjs/form/IconSelect/index.js +31 -23
  12. package/dist/cjs/form/TagInput/index.d.ts +1 -1
  13. package/dist/cjs/form/TagInput/index.js +2 -1
  14. package/dist/cjs/layout/CardTabs/index.js +12 -2
  15. package/dist/cjs/layout/CardTabs/styles.js +12 -60
  16. package/dist/cjs/layout/CodePreview/styles.js +0 -48
  17. package/dist/cjs/layout/MenuTabs/styles.js +0 -48
  18. package/dist/cjs/layout/SpaceBox/styles.js +5 -2
  19. package/dist/cjs/type/declaration.d.ts +2 -2
  20. package/dist/cjs/util/FieldUtils.d.ts +2 -2
  21. package/dist/cjs/util/PaginationUtils.js +4 -2
  22. package/dist/esm/field/CountField/index.d.ts +2 -2
  23. package/dist/esm/field/LabelField/index.d.ts +2 -2
  24. package/dist/esm/field/ThumbToggle/index.d.ts +2 -2
  25. package/dist/esm/form/AvatarUpload/index.d.ts +3 -3
  26. package/dist/esm/form/AvatarUpload/index.js +3 -3
  27. package/dist/esm/form/CronInput/index.js +3 -3
  28. package/dist/esm/form/DivideSelect/index.js +22 -16
  29. package/dist/esm/form/IconSelect/index.js +74 -68
  30. package/dist/esm/form/TagInput/index.d.ts +1 -1
  31. package/dist/esm/form/TagInput/index.js +1 -1
  32. package/dist/esm/layout/CardTabs/index.js +13 -3
  33. package/dist/esm/layout/CardTabs/styles.js +12 -48
  34. package/dist/esm/layout/CodePreview/styles.js +3 -40
  35. package/dist/esm/layout/MenuTabs/styles.js +1 -37
  36. package/dist/esm/layout/SpaceBox/styles.js +4 -2
  37. package/dist/esm/type/declaration.d.ts +2 -2
  38. package/dist/esm/util/FieldUtils.d.ts +2 -2
  39. package/dist/esm/util/PaginationUtils.js +2 -2
  40. package/package.json +8 -7
@@ -51,7 +51,7 @@ var buildFieldStyle = (token) => {
51
51
  borderRight: `${(0, import_cssinjs.unit)(token.lineWidth)} ${token.lineType} ${token.colorSplit}`,
52
52
  borderTop: `${(0, import_cssinjs.unit)(token.lineWidth)} ${token.lineType} ${token.colorSplit}`
53
53
  },
54
- [`&${token.componentCls}-content-border > ${token.antCls}-tabs-content-holder`]: {
54
+ [`&${token.componentCls}-content-border > ${token.antCls}-tabs-body-holder > ${token.antCls}-tabs-body`]: {
55
55
  border: `${(0, import_cssinjs.unit)(token.lineWidth)} ${token.lineType} ${token.colorSplit}`,
56
56
  borderRadius: `0 ${token.borderRadiusLG}px ${token.borderRadiusLG}px ${token.borderRadiusLG}px`,
57
57
  marginTop: -1
@@ -66,7 +66,7 @@ var buildFieldStyle = (token) => {
66
66
  borderRight: `${(0, import_cssinjs.unit)(token.lineWidth)} ${token.lineType} ${token.colorSplit}`,
67
67
  borderBottom: `${(0, import_cssinjs.unit)(token.lineWidth)} ${token.lineType} ${token.colorSplit}`
68
68
  },
69
- [`&${token.componentCls}-content-border > ${token.antCls}-tabs-content-holder`]: {
69
+ [`&${token.componentCls}-content-border > ${token.antCls}-tabs-body-holder > ${token.antCls}-tabs-body`]: {
70
70
  border: `${(0, import_cssinjs.unit)(token.lineWidth)} ${token.lineType} ${token.colorSplit}`,
71
71
  borderRadius: `${token.borderRadiusLG}px ${token.borderRadiusLG}px ${token.borderRadiusLG}px 0`,
72
72
  marginBottom: -1
@@ -78,7 +78,7 @@ var buildFieldStyle = (token) => {
78
78
  borderTop: `${(0, import_cssinjs.unit)(token.lineWidth)} ${token.lineType} ${token.colorSplit}`,
79
79
  borderBottom: `${(0, import_cssinjs.unit)(token.lineWidth)} ${token.lineType} ${token.colorSplit}`
80
80
  },
81
- [`&${token.componentCls}-content-border > ${token.antCls}-tabs-content-holder`]: {
81
+ [`&${token.componentCls}-content-border > ${token.antCls}-tabs-body-holder > ${token.antCls}-tabs-body`]: {
82
82
  borderRight: `${(0, import_cssinjs.unit)(token.lineWidth)} ${token.lineType} ${token.colorSplit}`,
83
83
  borderTop: `${(0, import_cssinjs.unit)(token.lineWidth)} ${token.lineType} ${token.colorSplit}`,
84
84
  borderBottom: `${(0, import_cssinjs.unit)(token.lineWidth)} ${token.lineType} ${token.colorSplit}`,
@@ -91,7 +91,7 @@ var buildFieldStyle = (token) => {
91
91
  borderTop: `${(0, import_cssinjs.unit)(token.lineWidth)} ${token.lineType} ${token.colorSplit}`,
92
92
  borderBottom: `${(0, import_cssinjs.unit)(token.lineWidth)} ${token.lineType} ${token.colorSplit}`
93
93
  },
94
- [`&${token.componentCls}-content-border > ${token.antCls}-tabs-content-holder`]: {
94
+ [`&${token.componentCls}-content-border > ${token.antCls}-tabs-body-holder > ${token.antCls}-tabs-body`]: {
95
95
  borderLeft: `${(0, import_cssinjs.unit)(token.lineWidth)} ${token.lineType} ${token.colorSplit}`,
96
96
  borderTop: `${(0, import_cssinjs.unit)(token.lineWidth)} ${token.lineType} ${token.colorSplit}`,
97
97
  borderBottom: `${(0, import_cssinjs.unit)(token.lineWidth)} ${token.lineType} ${token.colorSplit}`,
@@ -101,7 +101,7 @@ var buildFieldStyle = (token) => {
101
101
  },
102
102
  [`&${token.componentCls}-top-end`]: {
103
103
  [`> ${token.antCls}-tabs`]: {
104
- [`&${token.componentCls}-content-border > ${token.antCls}-tabs-content-holder`]: {
104
+ [`&${token.componentCls}-content-border > ${token.antCls}-tabs-body-holder > ${token.antCls}-tabs-body`]: {
105
105
  borderRadius: `${token.borderRadiusLG}px 0 ${token.borderRadiusLG}px ${token.borderRadiusLG}px`,
106
106
  marginTop: -1
107
107
  }
@@ -109,7 +109,7 @@ var buildFieldStyle = (token) => {
109
109
  },
110
110
  [`&${token.componentCls}-bottom-end`]: {
111
111
  [`> ${token.antCls}-tabs`]: {
112
- [`&${token.componentCls}-content-border > ${token.antCls}-tabs-content-holder`]: {
112
+ [`&${token.componentCls}-content-border > ${token.antCls}-tabs-body-holder > ${token.antCls}-tabs-body`]: {
113
113
  borderRadius: `${token.borderRadiusLG}px ${token.borderRadiusLG}px 0 ${token.borderRadiusLG}px`,
114
114
  marginBottom: -1
115
115
  }
@@ -125,71 +125,23 @@ var buildFieldStyle = (token) => {
125
125
  borderBottom: "none"
126
126
  }
127
127
  },
128
- [`&${token.componentCls}-padding-0 > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
128
+ [`${token.componentCls}-pane-padding-0`]: {
129
129
  padding: 0
130
130
  },
131
- [`&${token.componentCls}-padding-xxs > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
131
+ [`${token.componentCls}-pane-padding-xxs`]: {
132
132
  padding: `${token.paddingXXS}px ${token.paddingXXS}px`
133
133
  },
134
- [`&${token.componentCls}-padding-xs > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder > ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
134
+ [`${token.componentCls}-pane-padding-xs`]: {
135
135
  padding: `${token.paddingXS}px ${token.paddingXS}px`
136
136
  },
137
- [`&${token.componentCls}-padding-sm > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder > ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
137
+ [`${token.componentCls}-pane-padding-sm`]: {
138
138
  padding: `${token.paddingSM}px ${token.paddingSM}px`
139
139
  },
140
- [`&${token.componentCls}-padding-md > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder > ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
140
+ [`${token.componentCls}-pane-padding-md`]: {
141
141
  padding: `${token.paddingMD}px ${token.paddingMD}px`
142
142
  },
143
- [`&${token.componentCls}-padding-lg > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder > ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
143
+ [`${token.componentCls}-pane-padding-lg`]: {
144
144
  padding: `${token.paddingLG}px ${token.paddingLG}px`
145
- },
146
- [`&${token.componentCls}-padding-x-0 > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder > ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
147
- paddingLeft: 0,
148
- paddingRight: 0
149
- },
150
- [`&${token.componentCls}-padding-x-xxs > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder > ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
151
- paddingLeft: token.paddingXXS,
152
- paddingRight: token.paddingXXS
153
- },
154
- [`&${token.componentCls}-padding-x-xs > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder > ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
155
- paddingLeft: token.paddingXS,
156
- paddingRight: token.paddingXS
157
- },
158
- [`&${token.componentCls}-padding-x-sm > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder > ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
159
- paddingLeft: token.paddingSM,
160
- paddingRight: token.paddingSM
161
- },
162
- [`&${token.componentCls}-padding-x-md > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder > ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
163
- paddingLeft: token.paddingMD,
164
- paddingRight: token.paddingMD
165
- },
166
- [`&${token.componentCls}-padding-x-lg > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder > ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
167
- paddingLeft: token.paddingLG,
168
- paddingRight: token.paddingLG
169
- },
170
- [`&${token.componentCls}-padding-y-0 > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder > ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
171
- paddingTop: 0,
172
- paddingBottom: 0
173
- },
174
- [`&${token.componentCls}-padding-y-xxs > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder > ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
175
- paddingTop: token.paddingXXS,
176
- paddingBottom: token.paddingXXS
177
- },
178
- [`&${token.componentCls}-padding-y-xs > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder > ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
179
- paddingTop: token.paddingXS,
180
- paddingBottom: token.paddingXS
181
- },
182
- [`&${token.componentCls}-padding-y-sm > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder > ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
183
- paddingTop: token.paddingSM,
184
- paddingBottom: token.paddingSM
185
- },
186
- [`&${token.componentCls}-padding-y-md > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder > ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
187
- paddingTop: token.paddingMD,
188
- paddingBottom: token.paddingMD
189
- },
190
- [`&${token.componentCls}-padding-y-lg > ${token.antCls}-tabs > ${token.antCls}-tabs-content-holder > ${token.antCls}-tabs-content > ${token.antCls}-tabs-tabpane`]: {
191
- paddingTop: token.paddingLG,
192
- paddingBottom: token.paddingLG
193
145
  }
194
146
  }
195
147
  };
@@ -57,54 +57,6 @@ var buildFieldStyle = (token) => {
57
57
  },
58
58
  [`&${token.componentCls}-padding-lg pre code`]: {
59
59
  padding: `${token.paddingLG}px ${token.paddingLG}px`
60
- },
61
- [`&${token.componentCls}-padding-x-0 pre code`]: {
62
- paddingLeft: 0,
63
- paddingRight: 0
64
- },
65
- [`&${token.componentCls}-padding-x-xxs pre code`]: {
66
- paddingLeft: token.paddingXXS,
67
- paddingRight: token.paddingXXS
68
- },
69
- [`&${token.componentCls}-padding-x-xs pre code`]: {
70
- paddingLeft: token.paddingXS,
71
- paddingRight: token.paddingXS
72
- },
73
- [`&${token.componentCls}-padding-x-sm pre code`]: {
74
- paddingLeft: token.paddingSM,
75
- paddingRight: token.paddingSM
76
- },
77
- [`&${token.componentCls}-padding-x-md pre code`]: {
78
- paddingLeft: token.paddingMD,
79
- paddingRight: token.paddingMD
80
- },
81
- [`&${token.componentCls}-padding-x-lg pre code`]: {
82
- paddingLeft: token.paddingLG,
83
- paddingRight: token.paddingLG
84
- },
85
- [`&${token.componentCls}-padding-y-0 pre code`]: {
86
- paddingTop: 0,
87
- paddingBottom: 0
88
- },
89
- [`&${token.componentCls}-padding-y-xxs pre code`]: {
90
- paddingTop: token.paddingXXS,
91
- paddingBottom: token.paddingXXS
92
- },
93
- [`&${token.componentCls}-padding-y-xs pre code`]: {
94
- paddingTop: token.paddingXS,
95
- paddingBottom: token.paddingXS
96
- },
97
- [`&${token.componentCls}-padding-y-sm pre code`]: {
98
- paddingTop: token.paddingSM,
99
- paddingBottom: token.paddingSM
100
- },
101
- [`&${token.componentCls}-padding-y-md pre code`]: {
102
- paddingTop: token.paddingMD,
103
- paddingBottom: token.paddingMD
104
- },
105
- [`&${token.componentCls}-padding-y-lg pre code`]: {
106
- paddingTop: token.paddingLG,
107
- paddingBottom: token.paddingLG
108
60
  }
109
61
  }
110
62
  };
@@ -79,54 +79,6 @@ var buildFieldStyle = (token) => {
79
79
  },
80
80
  [`&${token.componentCls}-padding-lg ${token.componentCls}-tab`]: {
81
81
  padding: `${token.paddingLG}px ${token.paddingLG}px`
82
- },
83
- [`&${token.componentCls}-padding-x-0 ${token.componentCls}-tab`]: {
84
- paddingLeft: 0,
85
- paddingRight: 0
86
- },
87
- [`&${token.componentCls}-padding-x-xxs ${token.componentCls}-tab`]: {
88
- paddingLeft: token.paddingXXS,
89
- paddingRight: token.paddingXXS
90
- },
91
- [`&${token.componentCls}-padding-x-xs ${token.componentCls}-tab`]: {
92
- paddingLeft: token.paddingXS,
93
- paddingRight: token.paddingXS
94
- },
95
- [`&${token.componentCls}-padding-x-sm ${token.componentCls}-tab`]: {
96
- paddingLeft: token.paddingSM,
97
- paddingRight: token.paddingSM
98
- },
99
- [`&${token.componentCls}-padding-x-md ${token.componentCls}-tab`]: {
100
- paddingLeft: token.paddingMD,
101
- paddingRight: token.paddingMD
102
- },
103
- [`&${token.componentCls}-padding-x-lg ${token.componentCls}-tab`]: {
104
- paddingLeft: token.paddingLG,
105
- paddingRight: token.paddingLG
106
- },
107
- [`&${token.componentCls}-padding-y-0 ${token.componentCls}-tab`]: {
108
- paddingTop: 0,
109
- paddingBottom: 0
110
- },
111
- [`&${token.componentCls}-padding-y-xxs ${token.componentCls}-tab`]: {
112
- paddingTop: token.paddingXXS,
113
- paddingBottom: token.paddingXXS
114
- },
115
- [`&${token.componentCls}-padding-y-xs ${token.componentCls}-tab`]: {
116
- paddingTop: token.paddingXS,
117
- paddingBottom: token.paddingXS
118
- },
119
- [`&${token.componentCls}-padding-y-sm ${token.componentCls}-tab`]: {
120
- paddingTop: token.paddingSM,
121
- paddingBottom: token.paddingSM
122
- },
123
- [`&${token.componentCls}-padding-y-md ${token.componentCls}-tab`]: {
124
- paddingTop: token.paddingMD,
125
- paddingBottom: token.paddingMD
126
- },
127
- [`&${token.componentCls}-padding-y-lg ${token.componentCls}-tab`]: {
128
- paddingTop: token.paddingLG,
129
- paddingBottom: token.paddingLG
130
82
  }
131
83
  },
132
84
  [`@media screen and (max-width:${token.screenMD}px)`]: {
@@ -30,9 +30,12 @@ var buildFieldStyle = (token) => {
30
30
  [`${token.componentCls}`]: {
31
31
  display: "inline-block",
32
32
  [`&&-width-block`]: {
33
- width: "100%",
33
+ display: "flex",
34
34
  [`> ${token.antCls}-space`]: {
35
- width: "100%"
35
+ width: "100%",
36
+ [`> ${token.antCls}-space-item`]: {
37
+ width: "100%"
38
+ }
36
39
  }
37
40
  },
38
41
  [`&&-bound-border`]: {
@@ -1,14 +1,14 @@
1
1
  import { type TabsType } from 'antd/es/tabs';
2
2
  import { type Placement as RcPlacement } from '@rc-component/select/es/BaseSelect';
3
3
  export type ActionStyleType = 'success' | 'info' | 'warning' | 'error';
4
- export type AxisDirectionType = 'horizontal' | 'vertical';
4
+ export type AxisOrientationType = 'horizontal' | 'vertical';
5
5
  export type BeforeAfterType = 'before' | 'after';
6
6
  export type ClickHoverType = 'click' | 'hover';
7
7
  export type CircleSquareShape = 'circle' | 'square';
8
8
  export type FileSizeUint = 'KB' | 'MB' | 'GB' | 'TB';
9
9
  export type LabelValueType = 'label' | 'value';
10
10
  export type LabelMixinType = LabelValueType | 'code';
11
- export type PaddingSpaceType = WithFalse<'padding-0' | 'padding-xxs' | 'padding-xs' | 'padding-sm' | 'padding-md' | 'padding-lg' | 'padding-x-0' | 'padding-x-xxs' | 'padding-x-xs' | 'padding-x-sm' | 'padding-x-md' | 'padding-x-lg' | 'padding-y-0' | 'padding-y-xxs' | 'padding-y-xs' | 'padding-y-sm' | 'padding-y-md' | 'padding-y-lg'>;
11
+ export type PaddingSpaceType = WithFalse<'padding-0' | 'padding-xxs' | 'padding-xs' | 'padding-sm' | 'padding-md' | 'padding-lg'>;
12
12
  export type ReadonlyTabsType = Exclude<TabsType, 'editable-card'>;
13
13
  export type RectZenithPlace = RcPlacement;
14
14
  export type RequestOptionPlace = BeforeAfterType | 'override';
@@ -2,6 +2,6 @@ import { type DefaultOptionType } from 'antd/es/select';
2
2
  import { type SegmentedLabeledOption } from 'antd/es/segmented';
3
3
  import { type ProSchemaValueEnumObj, type ProSchemaValueEnumMap } from '@ant-design/pro-components';
4
4
  export declare abstract class FieldUtils {
5
- static valueEnumToSelectOptions: (source?: ProSchemaValueEnumMap | ProSchemaValueEnumObj | ((params: any) => ProSchemaValueEnumMap | ProSchemaValueEnumObj) | undefined) => DefaultOptionType[] | undefined;
6
- static valueEnumToSegmentOptions: (source?: ProSchemaValueEnumMap | ProSchemaValueEnumObj | ((params: any) => ProSchemaValueEnumMap | ProSchemaValueEnumObj) | undefined) => SegmentedLabeledOption[] | undefined;
5
+ static valueEnumToSelectOptions: (source?: ProSchemaValueEnumObj | ProSchemaValueEnumMap | ((params: any) => ProSchemaValueEnumMap | ProSchemaValueEnumObj) | undefined) => DefaultOptionType[] | undefined;
6
+ static valueEnumToSegmentOptions: (source?: ProSchemaValueEnumObj | ProSchemaValueEnumMap | ((params: any) => ProSchemaValueEnumMap | ProSchemaValueEnumObj) | undefined) => SegmentedLabeledOption[] | undefined;
7
7
  }
@@ -48,7 +48,8 @@ PaginationUtils.reloadAfterDelete = (actionRef, deletedCount = 1) => {
48
48
  }
49
49
  const pageInfo = actionRef.current.pageInfo;
50
50
  if (!pageInfo || deletedCount <= 0) {
51
- actionRef.current.reload();
51
+ actionRef.current.reload().then(() => {
52
+ });
52
53
  return;
53
54
  }
54
55
  const { current, pageSize, total } = pageInfo;
@@ -59,7 +60,8 @@ PaginationUtils.reloadAfterDelete = (actionRef, deletedCount = 1) => {
59
60
  current: current - 1
60
61
  });
61
62
  }
62
- actionRef.current.reload();
63
+ actionRef.current.reload().then(() => {
64
+ });
63
65
  };
64
66
  // Annotate the CommonJS export names for ESM import in node:
65
67
  0 && (module.exports = {
@@ -1,7 +1,7 @@
1
1
  import React from 'react';
2
2
  import { type BadgeProps, type TooltipProps } from 'antd';
3
3
  import { type SpaceSize } from 'antd/es/space';
4
- import { type AxisDirectionType } from "../../type/declaration";
4
+ import { type AxisOrientationType } from "../../type/declaration";
5
5
  export type CountFieldRef = {
6
6
  getCount: () => number;
7
7
  setCount: (count: number) => void;
@@ -15,7 +15,7 @@ export type CountFieldProps = React.PropsWithChildren<{
15
15
  field?: React.ReactNode | (() => React.ReactNode | undefined);
16
16
  count?: number;
17
17
  countProps?: Omit<BadgeProps, 'children' | 'color' | 'count' | 'dot' | 'showZero' | 'size' | 'status' | 'text'>;
18
- layout?: AxisDirectionType;
18
+ layout?: AxisOrientationType;
19
19
  showCount?: boolean;
20
20
  spaceSize?: SpaceSize;
21
21
  tooltipCtrl?: boolean;
@@ -1,12 +1,12 @@
1
1
  import React from 'react';
2
2
  import { type SpaceSize } from 'antd/es/space';
3
- import { type WithFalse, type AxisDirectionType } from "../../type/declaration";
3
+ import { type WithFalse, type AxisOrientationType } from "../../type/declaration";
4
4
  export type LabelPresetStyle = WithFalse<'label-prior' | 'field-prior'>;
5
5
  export type LabelFieldProps = React.PropsWithChildren<{
6
6
  clazzPrefix?: string;
7
7
  containerClazz?: string;
8
8
  containerStyle?: React.CSSProperties;
9
- layout?: AxisDirectionType;
9
+ layout?: AxisOrientationType;
10
10
  label?: React.ReactNode | (() => React.ReactNode | undefined);
11
11
  labelClazz?: string;
12
12
  labelStyle?: React.CSSProperties;
@@ -1,6 +1,6 @@
1
1
  import React from 'react';
2
2
  import { type BadgeProps, type CheckboxProps, type TooltipProps } from 'antd';
3
- import { type AxisDirectionType } from "../../type/declaration";
3
+ import { type AxisOrientationType } from "../../type/declaration";
4
4
  import { type CountFieldRef } from "../CountField";
5
5
  export type ThumbActionType = 'like' | 'dislike' | 'favorite';
6
6
  export type ThumbToggleRef = CountFieldRef & {
@@ -31,7 +31,7 @@ export type ThumbToggleProps = Pick<CheckboxProps, 'checked' | 'defaultChecked'>
31
31
  uncheckedStyle?: React.CSSProperties;
32
32
  count?: number;
33
33
  countProps?: Omit<BadgeProps, 'color' | 'count' | 'dot' | 'showZero' | 'size' | 'status' | 'text'>;
34
- layout?: AxisDirectionType;
34
+ layout?: AxisOrientationType;
35
35
  showCount?: boolean;
36
36
  tooltipCtrl?: boolean;
37
37
  tooltipProps?: Omit<TooltipProps, 'title'>;
@@ -45,7 +45,7 @@ export type AvatarUploadProps = Omit<ProFormFieldItemProps, 'children' | 'fieldR
45
45
  locale?: string;
46
46
  localeProps?: IntlLocaleProps;
47
47
  };
48
- export declare const AvatarUpload: React.ForwardRefExoticComponent<Omit<ProFormFieldItemProps, "children" | "disabled" | "placeholder" | "fieldProps" | "readonly" | "fieldRef"> & {
48
+ export declare const AvatarUpload: React.ForwardRefExoticComponent<Omit<ProFormFieldItemProps, "children" | "disabled" | "fieldProps" | "placeholder" | "readonly" | "fieldRef"> & {
49
49
  clazzPrefix?: string | undefined;
50
50
  containerClazz?: string | undefined;
51
51
  containerStyle?: React.CSSProperties | undefined;
@@ -53,8 +53,8 @@ export declare const AvatarUpload: React.ForwardRefExoticComponent<Omit<ProFormF
53
53
  imageSrc?: string | undefined;
54
54
  fallbackSrc?: string | undefined;
55
55
  shape?: CircleSquareShape | undefined;
56
- avatarProps?: Omit<AvatarProps, "shape" | "src" | "srcSet" | "children"> | undefined;
57
- imageProps?: Omit<ImageProps, "height" | "width" | "src" | "srcSet" | "title" | "fallback" | "preview"> | undefined;
56
+ avatarProps?: Omit<AvatarProps, "children" | "shape" | "src" | "srcSet"> | undefined;
57
+ imageProps?: Omit<ImageProps, "title" | "width" | "height" | "src" | "srcSet" | "fallback" | "preview"> | undefined;
58
58
  uploadEnabled?: boolean | undefined;
59
59
  uploadProps?: FileUploadProps | undefined;
60
60
  cropEnabled?: boolean | undefined;
@@ -89,14 +89,14 @@ var AvatarUploadField = /*#__PURE__*/React.forwardRef(function (props, ref) {
89
89
  var _props$uploadProps2;
90
90
  if (!(props !== null && props !== void 0 && (_props$uploadProps2 = props.uploadProps) !== null && _props$uploadProps2 !== void 0 && _props$uploadProps2.warnWithTypes)) {
91
91
  var _props$localeProps;
92
- messageApi.error(ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps = props.localeProps) === null || _props$localeProps === void 0 ? void 0 : _props$localeProps.disallowType, intlLocales.get([locale, 'disallowType']), intlLocales.get(['en_US', 'disallowType'])));
92
+ messageApi.error(ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps = props.localeProps) === null || _props$localeProps === void 0 ? void 0 : _props$localeProps.disallowType, intlLocales.get([locale, 'disallowType']), intlLocales.get(['en_US', 'disallowType']))).then(function () {});
93
93
  } else {
94
94
  var _props$localeProps2;
95
95
  var template = ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps2 = props.localeProps) === null || _props$localeProps2 === void 0 ? void 0 : _props$localeProps2.allowTypes, intlLocales.get([locale, 'allowTypes']), intlLocales.get(['en_US', 'allowTypes']));
96
96
  var types = StringUtils.join(props.uploadProps.allowedFileTypes.map(function (item) {
97
97
  return item === 'image/jpeg' ? 'jpg' : StringUtils.substringAfterLast(item, '/');
98
98
  }), '/');
99
- messageApi.error(StringUtils.formatBrace(template, types));
99
+ messageApi.error(StringUtils.formatBrace(template, types)).then(function () {});
100
100
  }
101
101
  return false;
102
102
  }
@@ -121,7 +121,7 @@ var AvatarUploadField = /*#__PURE__*/React.forwardRef(function (props, ref) {
121
121
  if (fileSize > props.uploadProps.maxFileSize) {
122
122
  var _props$localeProps3;
123
123
  var _template = ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps3 = props.localeProps) === null || _props$localeProps3 === void 0 ? void 0 : _props$localeProps3.maxFileSize, intlLocales.get([locale, 'maxFileSize']), intlLocales.get(['en_US', 'maxFileSize']));
124
- messageApi.error(StringUtils.formatBrace(_template, props.uploadProps.maxFileSize, props.uploadProps.fileSizeUint));
124
+ messageApi.error(StringUtils.formatBrace(_template, props.uploadProps.maxFileSize, props.uploadProps.fileSizeUint)).then(function () {});
125
125
  return false;
126
126
  }
127
127
  }
@@ -344,7 +344,7 @@ export var CronInput = /*#__PURE__*/React.forwardRef(function (props, ref) {
344
344
  var validate = cronValidate(event.target.value, validateOptions);
345
345
  if (validate.isError()) {
346
346
  var _props$localeProps3;
347
- messageInvoker.warning(ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps3 = props.localeProps) === null || _props$localeProps3 === void 0 ? void 0 : _props$localeProps3.invalidExpress, intlLocales.get([locale, 'invalidExpress']), intlLocales.get(['en_US', 'invalidExpress'])));
347
+ messageInvoker.warning(ObjectUtils.firstNotNil(props === null || props === void 0 || (_props$localeProps3 = props.localeProps) === null || _props$localeProps3 === void 0 ? void 0 : _props$localeProps3.invalidExpress, intlLocales.get([locale, 'invalidExpress']), intlLocales.get(['en_US', 'invalidExpress']))).then(function () {});
348
348
  }
349
349
  }
350
350
  setIncomeExpress(event.target.value);
@@ -530,7 +530,7 @@ export var CronInput = /*#__PURE__*/React.forwardRef(function (props, ref) {
530
530
  _setShowSecond(checked);
531
531
  var rawName = (_props$name3 = props === null || props === void 0 ? void 0 : props.name) !== null && _props$name3 !== void 0 ? _props$name3 : props === null || props === void 0 || (_props$fieldProps11 = props.fieldProps) === null || _props$fieldProps11 === void 0 ? void 0 : _props$fieldProps11.name;
532
532
  if (validateRule && rawName && form && form.getFieldValue(rawName)) {
533
- form.validateFields([rawName]);
533
+ form.validateFields([rawName]).then(function () {});
534
534
  }
535
535
  }
536
536
  })
@@ -547,7 +547,7 @@ export var CronInput = /*#__PURE__*/React.forwardRef(function (props, ref) {
547
547
  _setShowYear(checked);
548
548
  var rawName = (_props$name4 = props === null || props === void 0 ? void 0 : props.name) !== null && _props$name4 !== void 0 ? _props$name4 : props === null || props === void 0 || (_props$fieldProps12 = props.fieldProps) === null || _props$fieldProps12 === void 0 ? void 0 : _props$fieldProps12.name;
549
549
  if (validateRule && rawName && form && form.getFieldValue(rawName)) {
550
- form.validateFields([rawName]);
550
+ form.validateFields([rawName]).then(function () {});
551
551
  }
552
552
  }
553
553
  })
@@ -27,7 +27,7 @@ import { jsx as _jsx } from "react/jsx-runtime";
27
27
  import { jsxs as _jsxs } from "react/jsx-runtime";
28
28
  import { Fragment as _Fragment } from "react/jsx-runtime";
29
29
  export var DivideSelect = function DivideSelect(props) {
30
- var _props$clazzPrefix;
30
+ var _props$clazzPrefix, _props$fieldProps, _props$fieldProps2, _resolvedClassNames$p;
31
31
  var form = Form.useFormInstance();
32
32
  var clazzPrefix = (_props$clazzPrefix = props === null || props === void 0 ? void 0 : props.clazzPrefix) !== null && _props$clazzPrefix !== void 0 ? _props$clazzPrefix : 'abp-divide-select';
33
33
  var _ref = props !== null && props !== void 0 ? props : {},
@@ -40,9 +40,15 @@ export var DivideSelect = function DivideSelect(props) {
40
40
  _ref$presetStyle = _ref.presetStyle,
41
41
  presetStyle = _ref$presetStyle === void 0 ? 'before-prior' : _ref$presetStyle;
42
42
  var fieldStyle = useFieldStyle(clazzPrefix);
43
+ var userClassNames = props === null || props === void 0 || (_props$fieldProps = props.fieldProps) === null || _props$fieldProps === void 0 ? void 0 : _props$fieldProps.classNames;
44
+ var resolvedClassNames = typeof userClassNames === 'function' ? userClassNames({
45
+ props: (_props$fieldProps2 = props === null || props === void 0 ? void 0 : props.fieldProps) !== null && _props$fieldProps2 !== void 0 ? _props$fieldProps2 : {}
46
+ }) : userClassNames;
47
+ var userRootClassName = resolvedClassNames === null || resolvedClassNames === void 0 ? void 0 : resolvedClassNames.root;
48
+ var userPopupRootClassName = resolvedClassNames === null || resolvedClassNames === void 0 || (_resolvedClassNames$p = resolvedClassNames.popup) === null || _resolvedClassNames$p === void 0 ? void 0 : _resolvedClassNames$p.root;
43
49
  var _React$useState = React.useState(function () {
44
- var _props$fieldProps$opt, _props$fieldProps, _FieldUtils$valueEnum;
45
- var rawOptions = (_props$fieldProps$opt = props === null || props === void 0 || (_props$fieldProps = props.fieldProps) === null || _props$fieldProps === void 0 ? void 0 : _props$fieldProps.options) !== null && _props$fieldProps$opt !== void 0 ? _props$fieldProps$opt : [];
50
+ var _props$fieldProps$opt, _props$fieldProps3, _FieldUtils$valueEnum;
51
+ var rawOptions = (_props$fieldProps$opt = props === null || props === void 0 || (_props$fieldProps3 = props.fieldProps) === null || _props$fieldProps3 === void 0 ? void 0 : _props$fieldProps3.options) !== null && _props$fieldProps$opt !== void 0 ? _props$fieldProps$opt : [];
46
52
  var enumOptions = (_FieldUtils$valueEnum = FieldUtils.valueEnumToSelectOptions(props === null || props === void 0 ? void 0 : props.valueEnum)) !== null && _FieldUtils$valueEnum !== void 0 ? _FieldUtils$valueEnum : [];
47
53
  return [].concat(_toConsumableArray(rawOptions), _toConsumableArray(enumOptions));
48
54
  }),
@@ -72,12 +78,12 @@ export var DivideSelect = function DivideSelect(props) {
72
78
  }, []);
73
79
  }
74
80
  var renderContent = function renderContent(item, before) {
75
- var _ObjectUtils$getProp, _props$fieldProps2, _item$data, _ObjectUtils$getProp2, _props$fieldProps3, _item$data2;
81
+ var _ObjectUtils$getProp, _props$fieldProps4, _item$data, _ObjectUtils$getProp2, _props$fieldProps5, _item$data2;
76
82
  if (!item) {
77
83
  return undefined;
78
84
  }
79
- var label = (_ObjectUtils$getProp = ObjectUtils.getProp(item, props === null || props === void 0 || (_props$fieldProps2 = props.fieldProps) === null || _props$fieldProps2 === void 0 || (_props$fieldProps2 = _props$fieldProps2.fieldNames) === null || _props$fieldProps2 === void 0 ? void 0 : _props$fieldProps2.label)) !== null && _ObjectUtils$getProp !== void 0 ? _ObjectUtils$getProp : item === null || item === void 0 || (_item$data = item.data) === null || _item$data === void 0 ? void 0 : _item$data.label;
80
- var value = (_ObjectUtils$getProp2 = ObjectUtils.getProp(item, props === null || props === void 0 || (_props$fieldProps3 = props.fieldProps) === null || _props$fieldProps3 === void 0 || (_props$fieldProps3 = _props$fieldProps3.fieldNames) === null || _props$fieldProps3 === void 0 ? void 0 : _props$fieldProps3.value)) !== null && _ObjectUtils$getProp2 !== void 0 ? _ObjectUtils$getProp2 : item === null || item === void 0 || (_item$data2 = item.data) === null || _item$data2 === void 0 ? void 0 : _item$data2.value;
85
+ var label = (_ObjectUtils$getProp = ObjectUtils.getProp(item, props === null || props === void 0 || (_props$fieldProps4 = props.fieldProps) === null || _props$fieldProps4 === void 0 || (_props$fieldProps4 = _props$fieldProps4.fieldNames) === null || _props$fieldProps4 === void 0 ? void 0 : _props$fieldProps4.label)) !== null && _ObjectUtils$getProp !== void 0 ? _ObjectUtils$getProp : item === null || item === void 0 || (_item$data = item.data) === null || _item$data === void 0 ? void 0 : _item$data.label;
86
+ var value = (_ObjectUtils$getProp2 = ObjectUtils.getProp(item, props === null || props === void 0 || (_props$fieldProps5 = props.fieldProps) === null || _props$fieldProps5 === void 0 || (_props$fieldProps5 = _props$fieldProps5.fieldNames) === null || _props$fieldProps5 === void 0 ? void 0 : _props$fieldProps5.value)) !== null && _ObjectUtils$getProp2 !== void 0 ? _ObjectUtils$getProp2 : item === null || item === void 0 || (_item$data2 = item.data) === null || _item$data2 === void 0 ? void 0 : _item$data2.value;
81
87
  var code = ObjectUtils.getProp(item === null || item === void 0 ? void 0 : item.data, 'code');
82
88
  if (before) {
83
89
  if (optionBeforeContent !== 'label' && (item === null || item === void 0 ? void 0 : item.optionType) === 'optGroup') {
@@ -144,15 +150,15 @@ export var DivideSelect = function DivideSelect(props) {
144
150
  }, key !== null && key !== void 0 ? key : item === null || item === void 0 || (_item$data3 = item.data) === null || _item$data3 === void 0 ? void 0 : _item$data3.value);
145
151
  };
146
152
  if (proField) {
147
- var _props$fieldProps4, _props$fieldProps5, _props$fieldProps$opt2, _props$fieldProps6, _props$fieldProps7, _props$fieldProps$fie, _props$fieldProps8, _props$proFieldProps$, _props$proFieldProps, _props$proFieldProps3, _props$proFieldProps4;
153
+ var _props$fieldProps$opt2, _props$fieldProps6, _props$fieldProps7, _props$fieldProps$fie, _props$fieldProps8, _props$proFieldProps$, _props$proFieldProps, _props$proFieldProps3, _props$proFieldProps4;
148
154
  var restProps = !props ? {} : omit(props, ['fieldProps', 'proFieldProps', 'request', 'valueEnum', 'clazzPrefix', 'optionClazz', 'optionStyle', 'optionBeforeClazz', 'optionBeforeStyle', 'optionBeforeContent', 'optionAfterClazz', 'optionAfterStyle', 'optionAfterContent', 'requestOptionPlace', 'proField', 'presetStyle']);
149
155
  var omitFieldProps = !(props !== null && props !== void 0 && props.fieldProps) ? {} : omit(props === null || props === void 0 ? void 0 : props.fieldProps, ['classNames', 'options', 'optionRender', 'optionLabelProp']);
150
156
  return /*#__PURE__*/_jsx(ProFormSelect, _objectSpread(_objectSpread({}, restProps), {}, {
151
157
  fieldProps: _objectSpread({
152
158
  classNames: {
153
- root: classnames(clazzPrefix, props === null || props === void 0 || (_props$fieldProps4 = props.fieldProps) === null || _props$fieldProps4 === void 0 || (_props$fieldProps4 = _props$fieldProps4.classNames) === null || _props$fieldProps4 === void 0 ? void 0 : _props$fieldProps4.root),
159
+ root: classnames(clazzPrefix, userRootClassName),
154
160
  popup: {
155
- root: classnames("".concat(clazzPrefix, "-popup"), fieldStyle.hashId, props === null || props === void 0 || (_props$fieldProps5 = props.fieldProps) === null || _props$fieldProps5 === void 0 || (_props$fieldProps5 = _props$fieldProps5.classNames) === null || _props$fieldProps5 === void 0 || (_props$fieldProps5 = _props$fieldProps5.popup) === null || _props$fieldProps5 === void 0 ? void 0 : _props$fieldProps5.root)
161
+ root: classnames("".concat(clazzPrefix, "-popup"), fieldStyle.hashId, userPopupRootClassName)
156
162
  }
157
163
  },
158
164
  options: optionItems,
@@ -173,7 +179,7 @@ export var DivideSelect = function DivideSelect(props) {
173
179
  }), !(props !== null && props !== void 0 && props.proFieldProps) ? {} : omit(props === null || props === void 0 ? void 0 : props.proFieldProps, ['render']))
174
180
  }));
175
181
  } else {
176
- var _props$fieldProps21, _props$fieldProps22, _StringUtils$join, _props$fieldProps23, _ref2, _props$fieldProps24, _props$fieldProps$opt3, _props$fieldProps25;
182
+ var _StringUtils$join, _props$fieldProps21, _ref2, _props$fieldProps22, _props$fieldProps$opt3, _props$fieldProps23;
177
183
  var rebuildOptions = function rebuildOptions() {
178
184
  if (!optionItems) {
179
185
  return undefined;
@@ -214,20 +220,20 @@ export var DivideSelect = function DivideSelect(props) {
214
220
  var _omitFieldProps = !(props !== null && props !== void 0 && props.fieldProps) ? {} : omit(props.fieldProps, ['classNames', 'id', 'placeholder', 'options', 'optionLabelProp', 'searchOnFocus', 'resetAfterSelect', 'fetchDataOnSearch', 'optionRender', 'onChange']);
215
221
  return /*#__PURE__*/_jsx(Select, _objectSpread({
216
222
  classNames: {
217
- root: classnames(clazzPrefix, props === null || props === void 0 || (_props$fieldProps21 = props.fieldProps) === null || _props$fieldProps21 === void 0 || (_props$fieldProps21 = _props$fieldProps21.classNames) === null || _props$fieldProps21 === void 0 ? void 0 : _props$fieldProps21.root),
223
+ root: classnames(clazzPrefix, userRootClassName),
218
224
  popup: {
219
- root: classnames("".concat(clazzPrefix, "-popup"), fieldStyle.hashId, props === null || props === void 0 || (_props$fieldProps22 = props.fieldProps) === null || _props$fieldProps22 === void 0 || (_props$fieldProps22 = _props$fieldProps22.classNames) === null || _props$fieldProps22 === void 0 || (_props$fieldProps22 = _props$fieldProps22.popup) === null || _props$fieldProps22 === void 0 ? void 0 : _props$fieldProps22.root)
225
+ root: classnames("".concat(clazzPrefix, "-popup"), fieldStyle.hashId, userPopupRootClassName)
220
226
  }
221
227
  },
222
- placeholder: (_StringUtils$join = StringUtils.join(props === null || props === void 0 ? void 0 : props.placeholder)) !== null && _StringUtils$join !== void 0 ? _StringUtils$join : props === null || props === void 0 || (_props$fieldProps23 = props.fieldProps) === null || _props$fieldProps23 === void 0 ? void 0 : _props$fieldProps23.placeholder,
228
+ placeholder: (_StringUtils$join = StringUtils.join(props === null || props === void 0 ? void 0 : props.placeholder)) !== null && _StringUtils$join !== void 0 ? _StringUtils$join : props === null || props === void 0 || (_props$fieldProps21 = props.fieldProps) === null || _props$fieldProps21 === void 0 ? void 0 : _props$fieldProps21.placeholder,
223
229
  options: (_ref2 = !presetStyle ? optionItems : rebuildOptions()) !== null && _ref2 !== void 0 ? _ref2 : [],
224
- optionLabelProp: !(props !== null && props !== void 0 && (_props$fieldProps24 = props.fieldProps) !== null && _props$fieldProps24 !== void 0 && _props$fieldProps24.optionLabelProp) || props.fieldProps.optionLabelProp === 'label' ? 'labelOrigin' : (_props$fieldProps$opt3 = props === null || props === void 0 || (_props$fieldProps25 = props.fieldProps) === null || _props$fieldProps25 === void 0 ? void 0 : _props$fieldProps25.optionLabelProp) !== null && _props$fieldProps$opt3 !== void 0 ? _props$fieldProps$opt3 : 'value',
230
+ optionLabelProp: !(props !== null && props !== void 0 && (_props$fieldProps22 = props.fieldProps) !== null && _props$fieldProps22 !== void 0 && _props$fieldProps22.optionLabelProp) || props.fieldProps.optionLabelProp === 'label' ? 'labelOrigin' : (_props$fieldProps$opt3 = props === null || props === void 0 || (_props$fieldProps23 = props.fieldProps) === null || _props$fieldProps23 === void 0 ? void 0 : _props$fieldProps23.optionLabelProp) !== null && _props$fieldProps$opt3 !== void 0 ? _props$fieldProps$opt3 : 'value',
225
231
  onChange: function onChange(event) {
226
- var _props$fieldProps26, _props$fieldProps26$o;
232
+ var _props$fieldProps24, _props$fieldProps24$o;
227
233
  if (props !== null && props !== void 0 && props.name) {
228
234
  form === null || form === void 0 || form.setFieldValue(props.name, event.target.value);
229
235
  }
230
- props === null || props === void 0 || (_props$fieldProps26 = props.fieldProps) === null || _props$fieldProps26 === void 0 || (_props$fieldProps26$o = _props$fieldProps26.onChange) === null || _props$fieldProps26$o === void 0 || _props$fieldProps26$o.call(_props$fieldProps26, event);
236
+ props === null || props === void 0 || (_props$fieldProps24 = props.fieldProps) === null || _props$fieldProps24 === void 0 || (_props$fieldProps24$o = _props$fieldProps24.onChange) === null || _props$fieldProps24$o === void 0 || _props$fieldProps24$o.call(_props$fieldProps24, event);
231
237
  }
232
238
  }, _omitFieldProps));
233
239
  }