Merge conflict Gerrit cannot merge this change. It needs a rebase onto main.

Review main Work in progress

96718[WIP] Add device preview with zoom and pan to the preview module

Benjamin Kott CR 0 V 0 Nightmare +5791 −649 updated 11/10/26, 10:38

Commit message

The module "Content > Preview" shows the page at the size of a device
screen, zoomed to fit or at a fixed factor, so a screen wider than the
module keeps the breakpoints of the page. The screen is panned and
zoomed as in a design tool, and a custom size has handles. Fitted with
a width and a height, the screen stays in place and only the page in
it scrolls, unless even the smallest zoom leaves a part of it out of
view.

A drag with the middle button pans also from within the page. Only a
drag takes the pointer from the page: a middle click on a link still
opens it in a new tab.

A screen without a height gets the full height of the page. The module
shows the page with a preview token, and a frontend middleware adds a
small script to pages shown with one. The script reports the height of
the page and passes the zoom and pan gestures in the page on to the
module. The preview token keeps the frame in the preview on every
navigation within the sites of the installation; any other origin
opens in a new window.

The module follows a navigation in the frame: the page tree selects
the page that the frame shows, also of another site, and the document
header, the title and the URL of the module show it. A change of the
language in the frame is stored as with the language selector.

The backend now also notices when a module in the content frame
changes its URL with history.pushState() or replaceState().

Where a page has no preview, the module says why instead of an empty
module, and leads to the module that helps. The buttons of the document
header stay, disabled.

Test this change

Run a command in your clone of the TYPO3 Core. Then try what the change does and vote on Verified in Gerrit. How to review a patch

Check out patch set 10
git fetch https://review.typo3.org/Packages/TYPO3.CMS refs/changes/18/96718/10 && git checkout FETCH_HEAD
Cherry-pick onto main
git fetch https://review.typo3.org/Packages/TYPO3.CMS refs/changes/18/96718/10 && git cherry-pick FETCH_HEAD

Review

  • Code review CR 0 Needs a vote
  • Verified V 0 Needs a vote
    • core-ci +1 CI

Relation chain 4

  1. main 96720fix Based on this change Abandoned Benjamin Franzke CR 0 V 0 Easy +0 −8
  2. 96718 [WIP] Add device preview with zoom and pan to the preview module This change

  3. main 97236[FEATURE] Compare every preview with the live page This change is based on it Work in progress Merge conflict Matthias Vogel CR 0 V 0 Expert +1248 −698
  4. main 97235[BUGFIX] Preview hidden pages across site domains This change is based on it Matthias Vogel CR 0 V 0 → 14.3 Impossible +10762 −91

    The chain has patch set 4 of 12, the changes above it need a rebase.

Issues 2

Files 47

Show 27 more files

Review log 1121

  1. Benjamin Kott uploaded patch set 1 10/15/26, 11:46

  2. core-ci voted on patch set 1 V +1 10/15/26, 12:00 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111187

  3. Benjamin Franzke rebased onto patch set 2 V +1 10/15/26, 13:26

  4. Benjamin Franzke rebased onto patch set 3 10/15/26, 13:39

  5. core-ci voted on patch set 2 V -1 10/15/26, 13:40 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111194

  6. core-ci voted on patch set 3 V +1 10/15/26, 13:53 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111199

  7. Benjamin Kott rebased onto patch set 4 V +1 10/15/26, 15:57

  8. core-ci voted on patch set 4 V +1 10/15/26, 16:09 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111221

  9. Benjamin Kott marked it work in progress 10/16/26, 12:02

  10. Benjamin Kott uploaded patch set 5 V +1 10/19/26, 16:34

  11. core-ci voted on patch set 5 V +1 10/19/26, 16:49 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111680

  12. Matthias Vogel uploaded patch set 6 V +1 10/26/26, 08:52

  13. core-ci voted on patch set 6 V +1 10/26/26, 09:02 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/112582

  14. Matthias Vogel uploaded patch set 7 V +1 10/27/26, 10:30

    Follow navigation in the frame, keep a fitted screen in place, pan with the middle button - The frame keeps the preview on every navigation within the sites of the installation: links, forms, scripts and redirects, also to another site or language. Any other origin opens in a new window. - The module follows a navigation in the frame: the page tree selects the page, and the docheader, the title, the URL and the stored language follow. - The backend notices URL changes of a module by history.pushState() and replaceState(). - "Zoom to fit" with a width and a height keeps the whole screen in place, only the page scrolls. A screen that does not fit even at 10 % still pans. - A drag with the middle button pans also from within the page; a middle click on a link still opens it in a new tab. - Changelog, unit and e2e tests updated.
  15. core-ci voted on patch set 7 V +1 10/27/26, 10:40 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/112642

  16. Matthias Vogel uploaded patch set 8 V +1 10/30/26, 14:19

  17. core-ci voted on patch set 8 V +1 10/30/26, 14:34 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/112881

  18. Matthias Vogel uploaded patch set 9 V +1 11/09/26, 16:51

  19. core-ci voted on patch set 9 V +1 11/09/26, 17:06 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/113742

  20. Matthias Vogel uploaded patch set 10 V +1 11/10/26, 10:22

  21. core-ci voted on patch set 10 V +1 11/10/26, 10:38 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/113873