Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Select:fix Select box jitter when the window is zoomed bug(对应issue:#21142) #21143

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion packages/select/src/select.vue
Original file line number Diff line number Diff line change
Expand Up @@ -795,7 +795,6 @@

handleResize() {
this.resetInputWidth();
if (this.multiple) this.resetInputHeight();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这行不能删

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

但是一直重新计算的问题是这个引起的 能解决下吗?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@cs1707 老哥 你看348 行已经监听value来重置高度了,handleResize的绑定那就会无限触发,只要我新增或者移除一个选项,你可以对比下看下348行 已经在重算和重置高度了 那你这行监听大小变化不久一直会触发了?无限循环了 只用value更改的时候重置就够了 你不信你可以跑一下我改的这个代码试下 解决了了这个issue ,麻烦看下 谢谢

},

checkDefaultFirstOption() {
Expand Down