Review main Merged

86351[TASK] Enhance color switcher to a smart toggle w/ advanced options

Benjamin Franzke CR +2 V +2 Hard +210 −41 updated 09/27/24, 12:03

Commit message

Implement a color-scheme toggle button, that toggles between light
and dark color scheme, but takes "auto" into account by toggling
based on the auto-detected (dark/light) mode, when current mode is auto,
and toggles to "auto" when the to-state matched the auto-detected state
as this transition basically means user wants the color scheme to match
the current system settings (and is very likely fine if the scheme
is updated automatically, when the user changes the light/dark setting
on system level).

Additionally an expander is added, in order for all options
(including auto-detect) to be selectable within the user toolbar menu.

We have noticed that technical and subjective labels like "OS default"
or "User agent preference" are not perceived very well.
Therefore we removed "OS Default" from the toolbar in #104942.

Now this rather unintuitive option was gone from the user toolbar –
which was good for users that just wanted to toggle – but bad for power
users that like to enable "auto", but found it hard to discover the
auto option withing the user settings tab "Backend appearance".

Therefore the switcher now has an embedded advanced mode, where the
the "auto" item is available again and the label is combined of
"Auto detect" and the (auto detected) mode that it will be changed to.

The advantage is that there is less surprise when clicking auto detect,
when switching from "Dark mode" to "Auto detect (Dark mode)" or from
"Light mode" to "Auto detect (Light mode)".

Review

  • Code review CR +2 Done
    • Andreas Kienast +2
    • Benjamin Kott +1
  • Verified V +2 Done
    • Andreas Kienast +2
    • Benjamin Kott +1
    • core-ci +1 CI

Issues 1

Files 9

Review log 1425

  1. Benjamin Franzke uploaded patch set 1 09/26/24, 20:36

  2. core-ci voted on patch set 1 V +1 09/26/24, 20:41 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/66684

  3. Benjamin Franzke uploaded patch set 2 V +1 09/26/24, 21:07

  4. core-ci voted on patch set 2 V +1 09/26/24, 21:12 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/66685

  5. Benjamin Franzke uploaded patch set 3 V +1 09/26/24, 21:15

  6. core-ci voted on patch set 3 V +1 09/26/24, 21:20 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/66686

  7. Benjamin Franzke uploaded patch set 4 V +1 09/26/24, 21:29

  8. core-ci voted on patch set 4 V +1 09/26/24, 21:35 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/66687

  9. Benjamin Franzke uploaded patch set 5 V +1 09/26/24, 21:54

  10. core-ci voted on patch set 5 V +1 09/26/24, 22:00 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/66689

  11. Benjamin Franzke uploaded patch set 6 V +1 09/27/24, 09:24

  12. core-ci voted on patch set 6 V +1 09/27/24, 09:29 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/66722

  13. Benjamin Franzke uploaded patch set 7 V +1 09/27/24, 10:23

  14. core-ci voted on patch set 7 V +1 09/27/24, 10:28 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/66734

  15. Benjamin Franzke uploaded patch set 8 V +1 09/27/24, 10:35

  16. core-ci voted on patch set 8 V +1 09/27/24, 10:40 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/66735

  17. Benjamin Franzke uploaded patch set 9 V +1 09/27/24, 10:42

  18. core-ci voted on patch set 9 V +1 09/27/24, 10:50 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/66736

  19. Benjamin Franzke uploaded patch set 10 V +1 09/27/24, 11:14

  20. core-ci voted on patch set 10 V +1 09/27/24, 11:20 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/66742

  21. Benjamin Franzke uploaded patch set 11 V +1 09/27/24, 11:35

  22. core-ci voted on patch set 11 V +1 09/27/24, 11:40 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/66745

  23. Benjamin Kott voted on patch set 11 CR +1 V +1 09/27/24, 11:44

  24. Andreas Kienast voted on patch set 11 CR +2 V +2 09/27/24, 12:03

  25. Andreas Kienast merged patch set 12 09/27/24, 12:03