Replies: 1 comment
-
Bug reported in #2213 |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi!
A few months back I asked about an issue I was seeing, where I had an sl-dialog which had enough items in it to gain an internal scroller. The first field in the dialog is set to "autofocus" as outlined on the website, and as expected, when the dialog is opened, that field has the focus. Here's a codePen: https://codepen.io/ourson66/full/poYJLKK
Using that pen, click the "Open" button and the dialog will open. The first field should be focused and ready to go. Great!
Now scroll down through the fields until the focused field is not visible at the top of the display. Manually click on one of the fields you have visible now (Field 18 for example). Then click the "X" at the top of the dialog to close it.
Click the "Open" button again, to re-open the dialog. Notice how the scroller has not changed, however, if you scroll to the top, you'll see the first field again has focus. This is the issue I was talking about. When a field gains focus, it should be automatically scrolled into view, especially if that gain of focus happens because of an autofocus when a dialog is opened.
I noticed that this was marked as "closed" in a previous build, and I'm not sure if this represents a regression, but I'm using the latest 2.17.0 in the codePen, and it doesn't appear to be fixed... Any help would be greatly appreciated!
Beta Was this translation helpful? Give feedback.
All reactions