Edit Content page auto-scrolls to JSON field instead of staying at top
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 970
- Forks
- 486
- Avg merge
- 3d 33m
- Merged PRs (30d)
- 170
Description
Problem Statement
While doing QA for #36318, we found that the Edit Content page automatically scrolls down to the JSON field when creating or re-opening a contentlet of the test Content Type from that ticket's sample bundle. The page should always default to the top of the scroll position — it should never auto-scroll to any field, including JSON.
This is a UX/UI regression in the new Edit Content mode. It doesn't cause data loss, but it disrupts the editing flow and can mislead the user into thinking they landed on the wrong field or that content is missing above the fold.
Steps to Reproduce
Content Type: Use the sample Content Type bundle attached to #36318 (contains a JSON field among others). Import it via Site → Publishing Queue → Bundles before following these steps.
- Go to Content → New Content and select the test Content Type.
- Add dummy values to the fields.
- Click Publish.
- Re-open the published contentlet for editing.
- Observed: The page scroll automatically moves down to the
JSONfield. - Expected: The page scroll stays at the very top by default, regardless of field types present.
Acceptance Criteria
- When creating a new contentlet of the test Content Type, the Edit Content page loads with the scroll position at the top.
- When publishing the contentlet and re-opening it for edit, the Edit Content page loads with the scroll position at the top — it does not auto-scroll to the
JSONfield or any other field. - The behavior is verified for a contentlet that has values in the
JSONfield (not just an empty one). - No regression in normal manual scrolling — users can still scroll to and interact with the
JSONfield as expected. - The original bug scenario (scroll auto-jumping to
JSONfield on reopen) no longer reproduces.
dotCMS Version
Latest from main branch
Severity
Low - Minor issue or cosmetic
Links
- Related: #36318 (New Edit mode has problems with specific field types) — found while doing QA for this ticket
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
Start at the Content → New Content and Edit Content flows using the sample Content Type bundle from #36318, then reproduce the scroll jump with a populated JSON field. Verify that both new and reopened contentlets load at the top, while manual scrolling and JSON-field interaction still work normally.
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
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 55/100