- Issue created by @mstrelan
- ๐ฎ๐ณIndia maithri shetty
Maithri Shetty โ made their first commit to this issueโs fork.
- Assigned to maithri shetty
- last update
7 months ago 536 pass - Issue was unassigned.
- Status changed to Needs review
7 months ago 6:26am 4 June 2024 - ๐ฎ๐ณIndia maithri shetty
@mstrelan I have raised a PR for requested change. Can you please provide me the steps to reproduce the issue so that I can cross verify in my local as well. Thank you.
- ๐ฆ๐บAustralia mstrelan
- Install Drupal standard profile
- Install Webform and Webform UI module
- Edit the default Contact webform and enabled AJAX
- Go to /form/contact and hit submit to trigger a validation error
- Inspect the page markup and notice an empty span above the webform, rather than wrapping the webform
- ๐ฎ๐ณIndia maithri shetty
@mstrelan cross verified and works fine. Thank you
- ๐ซ๐ทFrance mh_nichts
Hello,
Thanks for filing this issue.
However, I suggest solving it in another way, as using a span to wrap a div and a whole form is invalid according to W3C HTML standards.
My suggestion would be :
- in JS : remove '-content' from the selector, so it targets the initial wrapper div which effectively contains the form
- in PHP : keep span where it is, but add tabindex="-1" so it can effectively get the focus (currently it can't, whether wrapping the form or not)
I will try to commit this changes next week.
- Merge request !496Issue #3452360 by mstrelan: Fix focus in webformScrollTop โ (Open) created by mh_nichts
- ๐จ๐ฆCanada Liam Morland Ontario, CA ๐จ๐ฆ
Please rebase against 6.3.x.
- ๐ซ๐ทFrance mh_nichts
@lkmorlan Thank you ! It should be OK now, I could apply the patch from the MR locally.