fix(components): [el-form] adjust the warn about label (#9889)

This commit is contained in:
btea 2022-10-03 13:26:41 +08:00 committed by GitHub
parent e582a2f4cf
commit 5497f0c234
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -17,7 +17,7 @@ export function useFormLabelWidth() {
function getLabelWidthIndex(width: number) {
const index = potentialLabelWidthArr.value.indexOf(width)
if (index === -1) {
if (index === -1 && autoLabelWidth.value === '0') {
debugWarn(SCOPE, `unexpected width ${width}`)
}
return index