Review main Merged

89829[BUGFIX] Prevent modals from closing on Escape in search

Oli Bartsch CR +2 V +2 Normal +60 −2 updated 06/24/25, 09:29

Commit message

When pressing Escape inside an input[type="search"],
browsers clear the input value by default. However,
Bootstrap modals also listen for Escape globally and
close the modal, which is unintended in this case.

This change stops Escape key propagation when a
search input is focused, allowing only the input to
clear, but keeping the modal open.

The event listener is registered in the capture phase
to ensure it runs before Bootstrap's internal handler.

Review

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

Issues 1

Files 5

Review log 1014

  1. Oli Bartsch uploaded patch set 1 06/24/25, 07:32

  2. core-ci voted on patch set 1 V -1 06/24/25, 07:46 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/80691

  3. Oli Bartsch uploaded patch set 2 V -1 06/24/25, 07:51

  4. core-ci voted on patch set 2 V +1 06/24/25, 07:58 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/80693

  5. Benjamin Franzke commented on patch set 1 06/24/25, 08:00

    key-bindings.ts:25

    awaiting Document ready is unneeded for events registered on the document.
  6. Oli Bartsch uploaded patch set 3 V +1 06/24/25, 08:08

  7. core-ci voted on patch set 3 V +1 06/24/25, 08:16 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/80697

  8. Oli Bartsch uploaded patch set 4 V +1 06/24/25, 08:16

  9. Oli Bartsch commented on patch set 3 06/24/25, 08:17

    key-bindings.ts:25 Reply

    Done
  10. Benjamin Franzke voted on patch set 4 CR +1 V +1 06/24/25, 08:18

  11. core-ci voted on patch set 4 V +1 06/24/25, 08:23 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/80698

  12. Andreas Kienast voted on patch set 4 CR +1 V +1 06/24/25, 09:16

  13. Oli Bartsch voted on patch set 4 CR +2 V +2 06/24/25, 09:29

  14. Oli Bartsch merged patch set 5 06/24/25, 09:29