Review main Merged

93236[BUGFIX] Fix context panel save button usability issues

Benjamin Kott CR +2 V +2 Normal +3 −49 updated 03/18/26, 07:25

Commit message

The save button in the contextual record edit panel used a custom
JavaScript intercept to call FormEngine.saveDocument() on click.
This duplicated logic that FormEngine already provides natively:
submitFormWithAction() looks for a button[name="_savedok"] associated
with the form and uses it as the submitter via requestSubmit().

The button now carries name="_savedok" value="1" directly in the
markup, aligning it with the standard save button pattern used by
EditDocumentController and ComponentFactory::createSaveButton(). The
redundant click handler and MutationObserver that toggled the disabled
state have been removed. The icon was changed from actions-check to
actions-document-save to match the rest of the backend. The check icon
is conventionally used to confirm a completed action or selection,
while the document-save icon clearly communicates a persist operation
to the user. Since FormEngine now resolves the button as the native
submitter, it also handles the intermediate saving state including the
spinner icon and disabling the button during submission, which was not
covered before.

The initial disabled state on the save button has been removed. Using
the disabled attribute is problematic for accessibility as it removes
the button from the tab order, making it invisible to keyboard and
screen reader users. It also caused the double-click bug: when a user
changed a field and immediately clicked save, the first click would
trigger the MutationObserver to enable the button but the click event
itself was swallowed by the disabled state, forcing a second click to
actually submit. With the button always enabled, the save action works
on the first click regardless of timing.

Review

  • Code review CR +2 Done
    • Benjamin Kott +2
    • Benjamin Franzke +1
    • Josua Vogel +1
  • Verified V +2 Done
    • Benjamin Kott +2
    • Benjamin Franzke +1
    • Josua Vogel +1
    • core-ci +1 CI

Issues 2

Files 3

Review log 79

  1. Benjamin Kott uploaded patch set 1 03/17/26, 14:26

  2. Benjamin Kott updated the commit message in patch set 2 03/17/26, 14:35

  3. core-ci voted on patch set 1 V +1 03/17/26, 14:36 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/98093

  4. core-ci voted on patch set 2 V +1 03/17/26, 14:44 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/98094

  5. Benjamin Franzke voted on patch set 2 CR +1 03/17/26, 16:08

  6. Benjamin Franzke voted on patch set 2 V +1 03/18/26, 05:18

  7. Josua Vogel voted on patch set 2 CR +1 V +1 03/18/26, 07:20

  8. Benjamin Kott voted on patch set 2 CR +2 V +2 03/18/26, 07:25

  9. Benjamin Kott merged patch set 3 03/18/26, 07:25