perf: 优化头像图标不超过10MB

(cherry picked from commit 889ebe4ed5)
This commit is contained in:
wangdan-fit2cloud 2024-08-07 11:21:46 +08:00 committed by shaohuzhang1
parent ebcef8f126
commit 7974aeaa86
4 changed files with 8 additions and 8 deletions

View File

@ -48,10 +48,10 @@ export default {
upload: 'Upload',
default: 'Default Logo',
custom: 'Custom',
sizeTip: 'Suggested size 32*32, supports jpg, png, gif, size no more than 10 M',
sizeTip: 'Suggested size 32*32, supports jpg, png, gif, size no more than 10 MB',
cancel: 'Cancel',
save: 'Save',
fileSizeExceeded: 'File size exceeds 10 M',
fileSizeExceeded: 'File size exceeds 10 MB',
setSuccess: 'Setting Successful',
uploadImagePrompt: 'Please upload an image'
},

View File

@ -47,10 +47,10 @@ export default {
upload: '上传',
default: '默认logo',
custom: '自定义',
sizeTip: '建议尺寸 32*32支持 JPG、PNG, GIF大小不超过 10 M',
sizeTip: '建议尺寸 32*32支持 JPG、PNG, GIF大小不超过 10 MB',
cancel: '取消',
save: '保存',
fileSizeExceeded: '文件大小超过 10 M',
fileSizeExceeded: '文件大小超过 10 MB',
setSuccess: '设置成功',
uploadImagePrompt: '请上传一张图片'
},

View File

@ -47,7 +47,7 @@
}}</el-button>
<template #tip>
<div class="el-upload__tip info" style="margin-top: 0">
建议尺寸 32*32支持 JPGPNG, GIF大小不超过 10 M
建议尺寸 32*32支持 JPGPNG, GIF大小不超过 10 MB
</div>
</template>
</el-upload>
@ -84,7 +84,7 @@
}}</el-button>
<template #tip>
<div class="el-upload__tip info" style="margin-top: 0">
建议尺寸 32*32支持 JPGPNG, GIF大小不超过 10 M
建议尺寸 32*32支持 JPGPNG, GIF大小不超过 10 MB
</div>
</template>
</el-upload>
@ -178,7 +178,7 @@ function resetForm() {
}
const onChange = (file: any, fileList: UploadFiles, attr: string) => {
//1 10 M
//1 10 MB
const isLimit = file?.size / 1024 / 1024 < 10
if (!isLimit) {
// @ts-ignore

View File

@ -103,7 +103,7 @@ const open = (data: any) => {
}
const onChange = (file: any) => {
//1 10M
//110MB
const isLimit = file?.size / 1024 / 1024 < 10
if (!isLimit) {
// @ts-ignore