@flatbiz/antd 2.3.21 → 2.3.22
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/esm/index.css +60 -12
- package/esm/index.js +1 -1
- package/esm/index.js.map +1 -1
- package/index.d.ts +51 -28
- package/package.json +3 -3
package/index.d.ts
CHANGED
|
@@ -91,7 +91,7 @@ export interface DrawerOperationOldProps {
|
|
|
91
91
|
okButtonProps?: Omit<ButtonProps, "onClick" | "loading" | "className">;
|
|
92
92
|
cancelButtonProps?: Omit<ButtonProps, "onClick" | "loading" | "className">;
|
|
93
93
|
}
|
|
94
|
-
export declare type
|
|
94
|
+
export declare type DrawerFormProps = {
|
|
95
95
|
className?: string;
|
|
96
96
|
/**
|
|
97
97
|
* 整个drawer页面级的spinning <Page loading />
|
|
@@ -106,7 +106,7 @@ export declare type DrawerFormOldProps = {
|
|
|
106
106
|
* 2. 默认 forceRender = false
|
|
107
107
|
* ```
|
|
108
108
|
*/
|
|
109
|
-
export declare const DrawerWraper: FC<
|
|
109
|
+
export declare const DrawerWraper: FC<DrawerFormProps>;
|
|
110
110
|
/**
|
|
111
111
|
* drawer弹窗模型
|
|
112
112
|
* @param key 唯一值必传
|
|
@@ -146,14 +146,21 @@ export interface DrawerOperationProps {
|
|
|
146
146
|
okButtonProps?: Omit<ButtonProps, "onClick" | "loading" | "className">;
|
|
147
147
|
cancelButtonProps?: Omit<ButtonProps, "onClick" | "loading" | "className">;
|
|
148
148
|
}
|
|
149
|
-
export declare type
|
|
149
|
+
export declare type DrawerWrapperStaticMethods = {
|
|
150
|
+
Content: typeof DrawerWrapperContent;
|
|
151
|
+
Footer: typeof DrawerWrapperFooter;
|
|
152
|
+
};
|
|
153
|
+
export declare type DrawerWrapperProps = {
|
|
150
154
|
className?: string;
|
|
151
155
|
/**
|
|
152
156
|
* 整个drawer页面级的spinning <Page loading />
|
|
153
157
|
*/
|
|
154
158
|
pageLoading?: boolean;
|
|
159
|
+
} & Omit<DrawerProps, "footer">;
|
|
160
|
+
declare const DrawerWrapperContent: FC<{
|
|
155
161
|
operationProps?: DrawerOperationProps;
|
|
156
|
-
}
|
|
162
|
+
}>;
|
|
163
|
+
declare const DrawerWrapperFooter: (props: any) => JSX.Element;
|
|
157
164
|
/**
|
|
158
165
|
* 弹窗机制
|
|
159
166
|
* ```
|
|
@@ -161,7 +168,7 @@ export declare type DrawerFormProps = {
|
|
|
161
168
|
* 2. 默认 forceRender = false
|
|
162
169
|
* ```
|
|
163
170
|
*/
|
|
164
|
-
export declare const DrawerWrapper: FC<
|
|
171
|
+
export declare const DrawerWrapper: FC<DrawerWrapperProps> & DrawerWrapperStaticMethods;
|
|
165
172
|
/**
|
|
166
173
|
* drawer弹窗模型
|
|
167
174
|
* @param key 唯一值必传
|
|
@@ -300,7 +307,7 @@ export declare const SelectorWrapper: import("react").ForwardRefExoticComponent<
|
|
|
300
307
|
export declare type UploadWrapperFileItem = {
|
|
301
308
|
uid: string;
|
|
302
309
|
name: string;
|
|
303
|
-
url
|
|
310
|
+
url?: string;
|
|
304
311
|
};
|
|
305
312
|
export declare type UploadWrapperProps<T extends TPlainObject = TPlainObject> = {
|
|
306
313
|
value?: T[];
|
|
@@ -311,9 +318,9 @@ export declare type UploadWrapperProps<T extends TPlainObject = TPlainObject> =
|
|
|
311
318
|
* 属性映射
|
|
312
319
|
*/
|
|
313
320
|
fieldNames?: {
|
|
314
|
-
uid
|
|
315
|
-
name
|
|
316
|
-
url
|
|
321
|
+
uid?: string;
|
|
322
|
+
name?: string;
|
|
323
|
+
url?: string;
|
|
317
324
|
};
|
|
318
325
|
/**
|
|
319
326
|
* 接口响应数据适配器,如果配置了fieldNames,适配器返回值会再进过fieldNames转换
|
|
@@ -325,19 +332,20 @@ export declare type UploadWrapperProps<T extends TPlainObject = TPlainObject> =
|
|
|
325
332
|
* ```
|
|
326
333
|
* 1. 可通过配置children替换默认上传触发布局
|
|
327
334
|
* 2. 接口返回结构:
|
|
328
|
-
*
|
|
329
|
-
*
|
|
330
|
-
*
|
|
331
|
-
*
|
|
332
|
-
*
|
|
333
|
-
*
|
|
334
|
-
*
|
|
335
|
-
*
|
|
336
|
-
*
|
|
337
|
-
*
|
|
338
|
-
*
|
|
335
|
+
* formData上传接口返回值
|
|
336
|
+
* {
|
|
337
|
+
* code: '0000',
|
|
338
|
+
* data: {
|
|
339
|
+
* uid: '唯一值,可使用fileKey值'
|
|
340
|
+
* name: '文件名称'
|
|
341
|
+
* url: '预览地址'
|
|
342
|
+
* }
|
|
343
|
+
* }
|
|
344
|
+
* 3. 如果接口返回的不是上面的字段名称,可通过fieldNames配置接口返回字段名称映射
|
|
345
|
+
*
|
|
346
|
+
* 4. 最佳使用方式,与Form结合使用
|
|
339
347
|
* <Form.Item name="attachmentList" label="附件">
|
|
340
|
-
* <UploadWrapper action={uploadUrl}
|
|
348
|
+
* <UploadWrapper action={uploadUrl} />
|
|
341
349
|
* </Form.Item>
|
|
342
350
|
* ```
|
|
343
351
|
*
|
|
@@ -572,6 +580,15 @@ export declare type GapProps = {
|
|
|
572
580
|
export declare const Gap: VFC<GapProps>;
|
|
573
581
|
export declare const useEffectCustom: (fn: EffectCallback, deps: DependencyList) => void;
|
|
574
582
|
export declare const useEffectCustomAsync: (fn: () => Promise<void>, deps: DependencyList) => void;
|
|
583
|
+
export declare type IconWrapperProps = {
|
|
584
|
+
hoverTips?: string;
|
|
585
|
+
icon?: React.ReactNode;
|
|
586
|
+
style?: CSSProperties;
|
|
587
|
+
text?: string | React.ReactElement;
|
|
588
|
+
className?: string;
|
|
589
|
+
size?: "small" | "middle" | "large";
|
|
590
|
+
};
|
|
591
|
+
export declare const IconWrapper: VFC<IconWrapperProps>;
|
|
575
592
|
export interface ModalStateType {
|
|
576
593
|
title?: string;
|
|
577
594
|
/**
|
|
@@ -590,7 +607,7 @@ export interface ModalActionsParamType {
|
|
|
590
607
|
closeModal: void;
|
|
591
608
|
setModalItemData: Record<string, unknown>;
|
|
592
609
|
}
|
|
593
|
-
export interface
|
|
610
|
+
export interface ModalOperationProps {
|
|
594
611
|
loading?: boolean;
|
|
595
612
|
okText?: string;
|
|
596
613
|
cancelText?: string;
|
|
@@ -603,7 +620,7 @@ export interface ModalOperationOldProps {
|
|
|
603
620
|
export declare type ModalFormProps = {
|
|
604
621
|
className?: string;
|
|
605
622
|
pageLoading?: boolean;
|
|
606
|
-
operationProps?:
|
|
623
|
+
operationProps?: ModalOperationProps;
|
|
607
624
|
footer?: null | React.ReactNode;
|
|
608
625
|
} & Omit<ModalProps, "footer" | "onOk" | "okText" | "cancelText" | "okButtonProps" | "cancelButtonProps" | "okType" | "confirmLoading">;
|
|
609
626
|
/**
|
|
@@ -643,7 +660,7 @@ export interface ModalActionsParamType {
|
|
|
643
660
|
closeModal: void;
|
|
644
661
|
setModalItemData: Record<string, unknown>;
|
|
645
662
|
}
|
|
646
|
-
export interface
|
|
663
|
+
export interface ModalOperationOldProps {
|
|
647
664
|
loading?: boolean;
|
|
648
665
|
okText?: string;
|
|
649
666
|
cancelText?: string;
|
|
@@ -653,12 +670,18 @@ export interface ModalOperationProps {
|
|
|
653
670
|
okButtonProps?: Omit<ButtonProps, "onClick" | "loading" | "className">;
|
|
654
671
|
cancelButtonProps?: Omit<ButtonProps, "onClick" | "loading" | "className">;
|
|
655
672
|
}
|
|
656
|
-
export declare type
|
|
673
|
+
export declare type ModalWrapperStaticMethods = {
|
|
674
|
+
Content: typeof ModalWrapperContent;
|
|
675
|
+
Footer: typeof ModalWrapperFooter;
|
|
676
|
+
};
|
|
677
|
+
export declare type ModalWrapperProps = {
|
|
657
678
|
className?: string;
|
|
658
679
|
pageLoading?: boolean;
|
|
659
|
-
operationProps?: ModalOperationProps;
|
|
660
|
-
footer?: null | React.ReactNode;
|
|
661
680
|
} & Omit<ModalProps, "footer" | "onOk" | "okText" | "cancelText" | "okButtonProps" | "cancelButtonProps" | "okType" | "confirmLoading">;
|
|
681
|
+
declare const ModalWrapperContent: FC<{
|
|
682
|
+
operationProps?: ModalOperationOldProps;
|
|
683
|
+
}>;
|
|
684
|
+
declare const ModalWrapperFooter: (props: any) => JSX.Element;
|
|
662
685
|
/**
|
|
663
686
|
* 弹窗机制
|
|
664
687
|
* ```
|
|
@@ -666,7 +689,7 @@ export declare type ModalFormOldProps = {
|
|
|
666
689
|
* 2. 默认 forceRender = false
|
|
667
690
|
* ```
|
|
668
691
|
*/
|
|
669
|
-
export declare const ModalWrapper: FC<
|
|
692
|
+
export declare const ModalWrapper: FC<ModalWrapperProps> & ModalWrapperStaticMethods;
|
|
670
693
|
/**
|
|
671
694
|
* modal弹窗模型
|
|
672
695
|
* @param key 唯一值必传
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@flatbiz/antd",
|
|
3
|
-
"version": "2.3.
|
|
3
|
+
"version": "2.3.22",
|
|
4
4
|
"description": "flat-biz oss ui components",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"typings": "index.d.ts",
|
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
"@dimjs/model": "^1.1.3",
|
|
41
41
|
"@dimjs/model-react": "^1.1.4",
|
|
42
42
|
"@dimjs/utils": "^1.2.9",
|
|
43
|
-
"@flatbiz/utils": "^2.3.
|
|
43
|
+
"@flatbiz/utils": "^2.3.22",
|
|
44
44
|
"@wove/react": "^1.2.10",
|
|
45
45
|
"antd": "^4.20.0",
|
|
46
46
|
"moment": "^2.29.3",
|
|
@@ -49,5 +49,5 @@
|
|
|
49
49
|
"react-router": "^6.3.0",
|
|
50
50
|
"react-router-dom": "^6.3.0"
|
|
51
51
|
},
|
|
52
|
-
"gitHead": "
|
|
52
|
+
"gitHead": "5bdec797ea14cb89889db3ee835a07353db26c0e"
|
|
53
53
|
}
|