-
Notifications
You must be signed in to change notification settings - Fork 83
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
[date-picker] Date elements are not scrolled into view when navigating within the same month #4037
Comments
The fix was backported to Vaadin 14 by vaadin/vaadin-date-picker#799 and released in 14.8.11 |
Vaadin 23 is actually not without this flaw too but there it is mitigated by the fact that the browser appears to scroll the element receiving native focus into view which is not the case for Vaadin 14 where dates are not natively focusable. In Vaadin 23, the default browser behavior sometimes clashes with the Screen.Recording.2022-06-14.at.10.38.07.movSo what could I suggest?
(2) sounds like a challenge though because you first need to smoothly scroll the month into view and then smoothly scroll to the actual date. Perhaps, there is a way to calculate an optimal scroller position with the date in mind before any scrolling begins. |
Let's investigate if we can fix this, it looks pretty annoying. Maybe it's worth creating a separate issue? |
Well, now I think that (2) should be enough to get the issue fixed in both versions. If the date element was correctly scrolled into view by |
Fixed by #4759 and vaadin/vaadin-date-picker#809 (for Vaadin 14). |
Description
Moving the focus ring in a date picker in Vaadin 14 makes it to disappear if the date picker is small enough. A similar issue was fixed apparently only in Vaadin 23, but it behaves differently in Vaadin 14:
In Vaadin 23 it works fine (recorded from the docs):UPD: #4037 (comment)As you can see the date picker is correctly auto scrolled to the focused date.
In Vaadin 14 the focused ring gets lost (also recorded from the docs):
As you can see the focus ring gets hidden.
Expected outcome
In Vaadin 14 it should behave in the same way as in Vaadin 23, where the focus ring is never hidden.
Minimal reproducible example
Steps to reproduce
Just put a DatePicker in a page, and resize the browser as little as possible so you can reproduce the issue as seen in the attached videos.
Environment
Vaadin version(s): 14
Browsers
Issue is not browser related
The text was updated successfully, but these errors were encountered: