Skip to content

[BUGFIX] Preserve page layout position after container actions - #767

Open
infabo wants to merge 1 commit into
b13:masterfrom
infabo:fix/preserve-page-layout-position
Open

[BUGFIX] Preserve page layout position after container actions#767
infabo wants to merge 1 commit into
b13:masterfrom
infabo:fix/preserve-page-layout-position

Conversation

@infabo

@infabo infabo commented Aug 11, 2026

Copy link
Copy Markdown

Problem

In the TYPO3 page layout, creating, saving, or deleting a child content element inside a large container returns editors to the top of the module. This is particularly
disruptive for containers with many nested records and backend previews.

TYPO3 already preserves the current position for visibility toggles by adding a content-element fragment to the action URL. Container child create and delete actions did
not provide an equivalent target.

Solution

  • Add the insertion target as a fragment to the returnUrl for both the new-content wizard and the direct record editor.
  • Add a fragment to child deletion URLs.
  • Return to the previous sibling where possible.
  • Fall back to the next sibling or the parent container.
  • Support both TYPO3 13 array records and TYPO3 14 RecordInterface records.

Verification

  • Functional coverage for wizard and direct-editor return URLs.
  • Acceptance coverage proving that save-and-close preserves the page layout position.
  • Acceptance coverage performing an actual confirmed deletion and verifying the resulting fragment.
  • Tested with TYPO3 13 / PHP 8.3 and TYPO3 14 / PHP 8.4.
  • PHPStan checks for TYPO3 13 and 14 pass.
  • The coding-style dry run passes.

AI disclosure

This pull request, including its implementation, tests, and description, was generated by OpenAI Codex using the GPT-5 model. The resulting changes were verified through
automated functional, acceptance, static-analysis, and coding-style checks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant