Upload增加文件上传大小默认限制10M

master
LiuJiaNan 2026-01-09 13:50:02 +08:00
parent 7876a92b2e
commit 10139b2e6e
2 changed files with 2 additions and 2 deletions

View File

@ -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;

View File

@ -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();