Upload增加文件上传大小默认限制10M
parent
7876a92b2e
commit
10139b2e6e
|
|
@ -11,7 +11,7 @@ export interface UploadProps extends Omit<AntUploadProps, "fileList"> {
|
||||||
ratio?: `${number}*${number}`;
|
ratio?: `${number}*${number}`;
|
||||||
/** 是否显示提示,默认 true */
|
/** 是否显示提示,默认 true */
|
||||||
showTip?: boolean;
|
showTip?: boolean;
|
||||||
/** 文件大小限制(单位:MB) */
|
/** 文件大小限制(单位:MB),默认 10 */
|
||||||
size?: number;
|
size?: number;
|
||||||
/** 自定义提示内容 */
|
/** 自定义提示内容 */
|
||||||
tipContent?: ReactNode;
|
tipContent?: ReactNode;
|
||||||
|
|
|
||||||
|
|
@ -103,7 +103,7 @@ const Upload = (props) => {
|
||||||
return externalSize;
|
return externalSize;
|
||||||
if (isVideoType)
|
if (isVideoType)
|
||||||
return 100;
|
return 100;
|
||||||
return 0;
|
return 10;
|
||||||
};
|
};
|
||||||
const size = getSize();
|
const size = getSize();
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue