Deprecation: #93975 - TBE_EDITOR.fieldChanged()

See forge#93975

Description

The JavaScript function TBE_EDITOR.fieldChanged() is a precursor of the rewritten FormEngine that started with TYPO3 v7 already. Now, FormEngine has proper change handling which renders the function TBE_EDITOR.fieldChanged() obsolete, thus this function became marked as deprecated.

Impact

Using TBE_EDITOR.fieldChanged() will trigger a deprecation entry in the browser's console.

Affected Installations

Every installation with 3rd-party extensions installed using this function is affected.

Migration

It is possible to trigger the change event on the given field, if FormEngine is unable to detect changes automatically.

Example:

// Previous invocation
TBE_EDITOR.fieldChanged('table', 'field_name', 42);

// Migrate to event-based handling
document
  .querySelector('[name="data[table][field_name][42]"]')
  .dispatchEvent(new Event('change', {bubbles: true, cancelable: true}));