@jiaozhiye/qm-design-react 1.7.38 → 1.7.40
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/lib/form/src/form-upload-file.d.ts +0 -8
- package/lib/form/src/form-upload-img.d.ts +0 -8
- package/lib/form/src/types.d.ts +4 -1
- package/lib/index.esm.js +1 -1
- package/lib/index.full.js +1 -1
- package/lib/index.js +1 -1
- package/lib/table/src/table/props.d.ts +1 -0
- package/lib/table/src/table/types.d.ts +2 -1
- package/lib/upload-file/src/upload-file.d.ts +13 -2
- package/lib/upload-file/style/index.less +18 -18
- package/lib/upload-img/src/upload-img.d.ts +9 -1
- package/package.json +1 -1
|
@@ -32,6 +32,7 @@ import type { ITableProps } from './types';
|
|
|
32
32
|
* cornerSign: PropTypes.bool,
|
|
33
33
|
* password: PropTypes.bool,
|
|
34
34
|
* disabledColor: PropTypes.string,
|
|
35
|
+
* disabledBackgroundColor: PropTypes.string,
|
|
35
36
|
* }),
|
|
36
37
|
* helper: PropTypes.shape({
|
|
37
38
|
* filters: PropTypes.object,
|
|
@@ -111,7 +111,8 @@ export type IEditerReturn = {
|
|
|
111
111
|
maxTagTextLength?: number;
|
|
112
112
|
cornerSign?: boolean;
|
|
113
113
|
password?: boolean;
|
|
114
|
-
disabledColor?: string
|
|
114
|
+
disabledColor?: string;
|
|
115
|
+
disabledBackgroundColor?: string;
|
|
115
116
|
autoSize?: {
|
|
116
117
|
minRows?: number;
|
|
117
118
|
maxRows?: number;
|
|
@@ -1,11 +1,20 @@
|
|
|
1
1
|
import React, { Component } from 'react';
|
|
2
2
|
import type { UploadProps, ButtonProps } from '../../antd';
|
|
3
|
-
|
|
3
|
+
export interface UploadFile {
|
|
4
|
+
uid: string;
|
|
5
|
+
name: string;
|
|
6
|
+
fileName?: string;
|
|
7
|
+
url?: string;
|
|
8
|
+
thumbUrl?: string;
|
|
9
|
+
status?: 'error' | 'success' | 'done' | 'uploading' | 'removed';
|
|
10
|
+
}
|
|
11
|
+
type IProps = Omit<UploadProps, 'onPreview'> & {
|
|
4
12
|
fileTypes?: string[];
|
|
5
13
|
fileSize?: number;
|
|
6
14
|
button?: {
|
|
7
15
|
text?: string;
|
|
8
16
|
} & ButtonProps;
|
|
17
|
+
onPreview?: (file: UploadFile, cb: (file?: UploadFile) => void) => void;
|
|
9
18
|
};
|
|
10
19
|
export type UploadFileProps = IProps;
|
|
11
20
|
declare class QmUploadFile extends Component<IProps> {
|
|
@@ -13,12 +22,14 @@ declare class QmUploadFile extends Component<IProps> {
|
|
|
13
22
|
name: string;
|
|
14
23
|
multiple: boolean;
|
|
15
24
|
showUploadList: {
|
|
25
|
+
showPreviewIcon: boolean;
|
|
16
26
|
showDownloadIcon: boolean;
|
|
17
|
-
|
|
27
|
+
showRemoveIcon: boolean;
|
|
18
28
|
};
|
|
19
29
|
};
|
|
20
30
|
beforeUpload: (file: any, fileList: any) => Promise<any>;
|
|
21
31
|
downloadFile(url: string, fileName?: string): Promise<void>;
|
|
32
|
+
doDownload: (file: any) => Promise<void>;
|
|
22
33
|
render(): React.JSX.Element;
|
|
23
34
|
}
|
|
24
35
|
export default QmUploadFile;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* @Author: 焦质晔
|
|
3
|
-
* @Date: 2021-07-23 19:05:57
|
|
4
|
-
* @Last Modified by: 焦质晔
|
|
5
|
-
* @Last Modified time: 2023-10-18 09:35:59
|
|
6
|
-
*/
|
|
7
|
-
@import '../../style/common';
|
|
8
|
-
|
|
9
|
-
@prefix-upload-file: ~'@{qm-prefix}-upload-file';
|
|
10
|
-
|
|
11
|
-
.@{prefix-upload-file} {
|
|
12
|
-
&.disabled {
|
|
13
|
-
.ant-upload-list-item-name {
|
|
14
|
-
color: @--disabled-color;
|
|
15
|
-
cursor: not-allowed;
|
|
16
|
-
}
|
|
17
|
-
}
|
|
18
|
-
}
|
|
1
|
+
/*
|
|
2
|
+
* @Author: 焦质晔
|
|
3
|
+
* @Date: 2021-07-23 19:05:57
|
|
4
|
+
* @Last Modified by: 焦质晔
|
|
5
|
+
* @Last Modified time: 2023-10-18 09:35:59
|
|
6
|
+
*/
|
|
7
|
+
@import '../../style/common';
|
|
8
|
+
|
|
9
|
+
@prefix-upload-file: ~'@{qm-prefix}-upload-file';
|
|
10
|
+
|
|
11
|
+
.@{prefix-upload-file} {
|
|
12
|
+
&.disabled {
|
|
13
|
+
.ant-upload-list-item-name {
|
|
14
|
+
color: @--disabled-color;
|
|
15
|
+
cursor: not-allowed;
|
|
16
|
+
}
|
|
17
|
+
}
|
|
18
|
+
}
|
|
@@ -1,12 +1,20 @@
|
|
|
1
1
|
import React, { Component } from 'react';
|
|
2
2
|
import type { UploadProps } from '../../antd';
|
|
3
|
+
export interface UploadFile {
|
|
4
|
+
uid: string;
|
|
5
|
+
name: string;
|
|
6
|
+
fileName?: string;
|
|
7
|
+
url?: string;
|
|
8
|
+
thumbUrl?: string;
|
|
9
|
+
status?: 'error' | 'success' | 'done' | 'uploading' | 'removed';
|
|
10
|
+
}
|
|
3
11
|
type IProps = UploadProps & {
|
|
4
12
|
fixedSize?: [number, number] | undefined;
|
|
5
13
|
quality?: number;
|
|
6
14
|
fileTypes?: string[];
|
|
7
15
|
fileSize?: number;
|
|
8
16
|
openCropper?: boolean;
|
|
9
|
-
beforeCrop?: (file:
|
|
17
|
+
beforeCrop?: (file: UploadFile, fileList: UploadFile[]) => Promise<boolean>;
|
|
10
18
|
};
|
|
11
19
|
type IState = {
|
|
12
20
|
previewVisible: boolean;
|