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

[Bug Report] Time picker doesn't visually select the part being edited via directional keys #16866

Closed
mattheyan opened this issue Aug 1, 2019 · 2 comments · Fixed by #16868
Closed
Assignees
Milestone

Comments

@mattheyan
Copy link
Contributor

Element UI version

2.11.1

OS/Browsers version

Windows 10 / Google Chrome 75

Vue version

2.6.10

Reproduction Link

https://codepen.io/mattheyan/pen/gVxMbM

Steps to reproduce

  1. Click into the text input so that one of the time parts (hours, minutes, seconds) is selected
  2. Press the up or down keys to increase or decrease the value

What is Expected?

The value show increase or decrease, and that part of the time should remain selected

What is actually happening?

The value is increased or decreased, but the text selection disappears and the cursor moves to the end of the input.

@mattheyan
Copy link
Contributor Author

I am able to implement a fix and will submit a PR for your review

@mattheyan
Copy link
Contributor Author

Adding this at the end of the scrollDown method fixes the problem.

this.$nextTick(() => this.emitSelectRange(this.currentScrollbar));

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants