Review 13.4 Merged

92863[BUGFIX] Allow capturing regexp replace in CKEditor 5

Garvin Hicking CR +2 V +2 Easy +3 −3 updated 02/17/26, 10:18

Commit message

With #104827 the support for regular expression replacements
in CKEditor 5 via `editor.config.typing.transformations` was
added.

This missed the possible scenario, where the target replacements
may contain capturing replacement groups with entries having
`null` as their values instead of strings.

For this, an exemption in the JavaScipt evaluation needs to be
made for these `null` types to not break the execution flow.

This now allows to use such a YAML configuration:

```
editor:
  config:
    typing:
      transformations:
        remove:
          - 'symbols'
          - 'quotes'
          - 'arrowLeft'
          - 'arrowRight'
        extra:
          - {from: {pattern: '(tsconf|t3ts)$', flags: ''}, to: 'TYPO3 TypoScript TSConfig'}
          - {from: {pattern: '(")([^"]*)(")$', flags: ''}, to: ['»', null, '«']}

```

(Note for this replacement group to work the "normal" quote conversion
mechanism first needs to be disabled)

Review

  • Code review CR +2 Done
    • Garvin Hicking +2
  • Verified V +2 Done
    • Garvin Hicking +2
    • core-ci +1 CI

Issues 2

Files 2

Review log 34

  1. Garvin Hicking commented on patch set 1 02/17/26, 10:02

    Cherry Picked from branch main.
  2. core-ci voted on patch set 1 V +1 02/17/26, 10:12 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/96019

  3. Garvin Hicking voted on patch set 1 CR +2 V +2 02/17/26, 10:18

  4. Garvin Hicking merged patch set 2 02/17/26, 10:18