Review main Merged

96376[BUGFIX] Detect capslock independent of shift key

Georg Ringer CR +2 V +2 Hard +216 −139 updated 10/22/26, 16:36

Commit message

The capslock warning of the backend login guessed the capslock state
from the case of the typed character and the shift key. On macOS
capslock combined with shift still produces upper case characters, so
the warning disappeared, and non-letter keys removed it as well.

The state is now read with KeyboardEvent.getModifierState() on keydown
and keyup, which also reacts to toggling capslock itself. The handling
is moved into its own module, which is loaded by the password reset
form as well, whose fields now use an input group to show the warning.

Review

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

Issues 1

Files 8

Review log 1418

  1. Georg Ringer uploaded patch set 1 10/05/26, 20:50

  2. Georg Ringer commented on patch set 1 10/05/26, 20:51

    This change is ready for review.
  3. core-ci voted on patch set 1 V +1 10/05/26, 20:58 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/110155

  4. Simon Schaufelberger commented on patch set 1 10/05/26, 23:53

    the icon is shown immediately but does not disappear when i press the capslock again. somehow it disappears when i doublepress it. that doesn't feel right.
  5. Simon Schaufelberger commented on patch set 1 10/05/26, 23:54

    Reply

    tested on Firefox Ubuntu
  6. Georg Ringer uploaded patch set 2 V +1 10/10/26, 09:21

  7. core-ci voted on patch set 2 V +1 10/10/26, 09:30 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/110783

  8. Simon Schaufelberger commented on patch set 2 CR +1 V +1 10/12/26, 00:37

    Reply

    Done
    well done!
  9. Guido Schmechel commented on patch set 2 CR +1 V +1 10/12/26, 17:19

    Technically, it works. The icon itself isn't really my style, but that's just a matter of taste ;-)
  10. Oli Bartsch uploaded patch set 3 CR +1 V +1 10/20/26, 16:32

  11. Oli Bartsch commented on patch set 3 10/20/26, 16:37

    The capslock module is now loaded via a side-effect import in `login.ts` (same as `input/clearable`) instead of an `<f:asset.module>` in each template. `login.js` is loaded on every login page anyway: by the `Login` layout, which login providers have to use, and by `ResetPasswordController`. Before this patch the binding came with `user-pass-login.js`. With the per-template asset, an overridden `UserPassLoginForm` or `ResetPasswordForm` would keep the `t3js-capslockwarning` fields but silently lose the warning. That matters more since this goes to 14.3 as well.
  12. Oli Bartsch uploaded patch set 4 10/20/26, 16:37

  13. Oli Bartsch voted on patch set 4 CR +1 V +1 10/20/26, 16:44

  14. core-ci voted on patch set 3 V +1 10/20/26, 16:54 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111887

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

  16. Simon Schaufelberger voted on patch set 4 CR +1 V +1 10/20/26, 17:43

  17. Oli Bartsch voted on patch set 4 CR +2 V +2 10/22/26, 16:35

  18. Oli Bartsch merged patch set 5 10/22/26, 16:36