Review main Merged

90281[BUGFIX] Don't use label fallback in page module

Lisa Kreitz CR +2 V +2 Easy +6 −3 updated 08/09/25, 07:41

Commit message

Don't use BackendUtility::getRecordTitle to avoid
duplicated subheader output in page module.

Review

  • Code review CR +2 Done
    • Oli Bartsch +2
    • Georg Ringer +1
  • Verified V +2 Done
    • Oli Bartsch +2
    • Georg Ringer +1
    • core-ci +1 CI

Issues 2

Files 1

Review log 89

  1. Lisa Kreitz uploaded patch set 1 08/07/25, 20:49

  2. Georg Ringer voted on patch set 1 CR +1 V +1 08/07/25, 20:54

  3. core-ci voted on patch set 1 V +1 08/07/25, 21:10 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/82929

  4. Oli Bartsch commented on patch set 1 08/07/25, 21:26

    StandardContentPreviewRenderer.php:77

    I'm currently trying to streamline label usage, see e.g. https://review.typo3.org/c/Packages/TYPO3.CMS/+/90155. I therefore think we should check via the capability for all label fields instead of using "subheader" hardcoded below. This way, we support even customized tt_content definition and the reported issue is still resolved. What do you think?
  5. Georg Ringer commented on patch set 1 08/07/25, 21:28

    StandardContentPreviewRenderer.php:77 Reply

    not really sure, subheader is always shown below if available. so this is somehow wrong as soon as BU::recordTitle is used. So as alternative maybe even drop the subheader rendering completly?
  6. Oli Bartsch commented on patch set 1 08/07/25, 22:09

    StandardContentPreviewRenderer.php:77 Reply

    Sure. So my suggestion was to drop the static rendering and use `primaryField` as well as iterating over `getAdditionalFieldNames()`. However, `bodytext` is defined as `label_alt`. So we might manually filter this list? Actually, the right approach would be to render `getAdditionalFieldNames()` only if `alwaysRenderAdditionalFields()` is `true`. But for `tt_content`, that is not the case by default and we would lose `subheader`. Not quite sure currently. Will need to think about this again. What is your opinion?
  7. Georg Ringer commented on patch set 1 08/09/25, 07:25

    StandardContentPreviewRenderer.php:77 Reply

    I did the patch together with Lisa, IMO this is best way to have the state like before. In the longrun we should look at the preview of all content elements and then we can also e.g. remove bodytext from the label_alt and improve the rendering but this is out of scrope.
  8. Oli Bartsch commented on patch set 1 CR +2 V +2 08/09/25, 07:41

    StandardContentPreviewRenderer.php:77 Reply

    Acknowledged
  9. Oli Bartsch merged patch set 2 08/09/25, 07:41