Select: fix resetInputHeight (#21201)

pull/21203/head
好多大米 2021-08-04 11:25:18 +08:00 committed by GitHub
parent 69fa9dcd8d
commit a54484e8b3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -646,7 +646,7 @@
let inputChildNodes = this.$refs.reference.$el.childNodes;
let input = [].filter.call(inputChildNodes, item => item.tagName === 'INPUT')[0];
const tags = this.$refs.tags;
const tagsHeight = Math.round(tags.getBoundingClientRect().height);
const tagsHeight = tags ? Math.round(tags.getBoundingClientRect().height) : 0;
const sizeInMap = this.initialInputHeight || 40;
input.style.height = this.selected.length === 0
? sizeInMap + 'px'