[5.x]: FLD library HUD affects page scroll position when it opens
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 3.6k
- Forks
- 705
- Avg merge
- 1d 5h
- Merged PRs (30d)
- 134
Description
What happened?
Description
The new FLD library HUD in 5.6 is great, but has an annoying behaviour where it sometimes changes the page's scroll position when it opens – sometimes to such a degree that the active tab is scrolled completely out of view.
This doesn't occur consistently, but often enough that it's disorienting and a bit annoying.
Unfortunately I've been unable to figure out exactly the circumstances that triggers this, so I'm unable to provide clear steps to reproduce this one. Here's a video to demonstrate the issue:
https://github.com/user-attachments/assets/328a3e73-5b1d-4f48-9dde-b04c3952cfcf
Steps to reproduce
- Have a lot of fields (the height of the FLD HUD feels relevant), and a modestly sized viewport
- Crack open a field layout designer and click the "Add" button in a tab
Expected behavior
The page scroll position shouldn't change when opening the HUD.
Actual behavior
The page scroll position often changes a lot.
Craft CMS version
5.6.1
PHP version
No response
Operating system and version
macOS 14.6.1, MS Edge 131.0.2903.112
Database type and version
No response
Image driver and version
No response
Installed plugins and versions
A few, but I'm able to reproduce the issue with all installed plugins disabled.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
The issue names the FLD library HUD and the Add button in a field layout designer; begin by reproducing it with many fields in a modest viewport. Compare the page scroll position before and after opening the HUD, and verify that opening it leaves the active tab in view without changing the page position.
Written by the indexing model from the issue text.
Assessment
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100