[BUGFIX] Avoid autofocus on preselected useOrOverridePlaceholder fields
With #90879 useOrOverridePlaceholder fields have been adapted to autofocus the related field when the related checkbox (e.g in sys_file_references) are triggered in FormEngine.toggleCheckboxField. This has the side effect that input fields whose checkbox is preselected are autofocused on initial page load, when FormEngine.toggleCheckboxField() is called from FormEngine.initializeNullWithPlaceholderCheckboxes. This caused the browser to scroll to these fields. The autofocus is now changed to not be triggered on initial pageload, only when FormEngine.toggleCheckboxField() is used due to user input. This also had the effect that acceptance tests failed randomly as automated tab-clicks didn't work (for example in #93629), when the formengine iframe was scrolled all the way to the last useOrOverridePlaceholder field, rendering the tab-selection invisible. Releases: main, 11.5 Resolves: #96947 Related: #90879 Related: #93629 Change-Id: Ie880595079e60421556994b14af0b94bba67b73c Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/73578 Tested-by: core-ci <email@example.com> Tested-by: Stefan Bürk <firstname.lastname@example.org> Tested-by: Benni Mack <email@example.com> Tested-by: Nikita Hovratov <firstname.lastname@example.org> Tested-by: Benjamin Franzke <email@example.com> Reviewed-by: Stefan Bürk <firstname.lastname@example.org> Reviewed-by: Benni Mack <email@example.com> Reviewed-by: Nikita Hovratov <firstname.lastname@example.org> Reviewed-by: Benjamin Franzke <email@example.com>
This diff is collapsed.