Review main Merged

80732[BUGFIX] Allow access to TypoScript overrides for labels in _LOCAL_LANG

Christian Kuhn CR +2 V +2 Hard +250 −110 updated 12/05/23, 09:09

Commit message

This bugfix enables the possibility to access _LOCAL_LANG
values from TypoScript properly again via Extbase's
LocalizationUtility, and thus for <f:translate> ViewHelpers
as well again.

This is what has changed under-the-hood:

The TranslateViewHelper is now only a thin layer
to Extbase's LocalizationUtility (as before), and only
checks if a current request or Locale/languageKey is
given, if a locale can be resolved. Everything else
is then dispatched to the LocalizationUtility.

<f:translate> is very clean now and has almost no further
responsibility than to call LocalizationUtility::translate

Instead of adding further LocalizationUtility magic,
overriding of TypoScript is now enabled for any kind
of plugin which hands in $extensionName. This is achieved
by building proper Locale objects from the request which
are then used to build the respective LanguageService.

As it turned out after the 12.4.0 release, the "Locales"
class is indeed the factory for creating a Locale, which
is decoupled from the actual LanguageService (= label magic),
the Locales factory receives a few create methods to make
life easier for usage, which both f:translate AND
LocalizationUtility receive, making their parts much smaller.

Further work will disolve the usage of the Configuration
Manager of Extbase, but this won't happen in v12 anymore.

Review

  • Code review CR +2 Done
    • Benni Mack +2
    • Anja Leichsenring +1
  • Verified V +2 Done
    • Benni Mack +2
    • Anja Leichsenring +1
    • core-ci +1 CI

Issues 1

Files 13

Review log 1321

  1. Christian Kuhn uploaded patch set 1 08/28/23, 14:09

  2. core-ci voted on patch set 1 V -1 08/28/23, 14:42 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/45919

  3. Christian Kuhn uploaded patch set 2 V -1 08/28/23, 15:28

  4. core-ci voted on patch set 2 V -1 08/28/23, 15:36 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/45923

  5. Christian Kuhn uploaded patch set 3 V -1 08/29/23, 09:35

  6. core-ci voted on patch set 3 V +1 08/29/23, 09:45 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/45962

  7. Christian Kuhn uploaded patch set 4 V +1 08/29/23, 11:53

  8. core-ci voted on patch set 4 V +1 08/29/23, 12:00 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/45974

  9. Christian Kuhn updated the commit message in patch set 5 V +1 08/29/23, 12:33

  10. core-ci voted on patch set 5 V -1 08/29/23, 12:40 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/45977

  11. Benni Mack commented on patch set 5 12/01/23, 22:32

    I think I have a fix for this, but lets get this one in first, which also re-activates some tests: https://review.typo3.org/c/Packages/TYPO3.CMS/+/82065
  12. Benni Mack uploaded patch set 6 V -1 12/04/23, 14:48

  13. core-ci voted on patch set 6 V +1 12/04/23, 14:54 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/50323

  14. Benni Mack uploaded patch set 7 V +1 12/04/23, 17:02

  15. core-ci voted on patch set 7 V -1 12/04/23, 17:10 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/50331

  16. Benni Mack uploaded patch set 8 V -1 12/04/23, 18:18

  17. core-ci voted on patch set 8 V +1 12/04/23, 18:24 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/50337

  18. Benni Mack voted on patch set 8 CR +1 V +1 12/04/23, 18:26

  19. Anja Leichsenring voted on patch set 8 CR +1 V +1 12/05/23, 08:58

  20. Benni Mack voted on patch set 8 CR +2 V +2 12/05/23, 09:09

  21. Benni Mack merged patch set 9 12/05/23, 09:09