#79879Missing translations for modal cancel / close buttons
Description
The cancel / close buttons of modals are not translated. Noticed in these use cases:
- Moving a file in the file list
- Reload required dialog of the form engine (e.g. when changing the page type)
Those problems seem to come from the typo3/sysext/backend/Resources/Public/JavaScript/Modal.js code.
Modal.confirm tries to use translations as defaults which do not exist:
text: $(this).data('button-close-text') || TYPO3.lang['button.cancel'] || 'Cancel',
The initialization for the .t3js-modal-trigger markup does not even try to use translations. It uses a hardcoded “close” string.
My suggestion so solve this issue would be:
- Add
'button.ok'and'button.cancelto theTYPO3.langarray by default - Use those translations in both modals as default fallback
I can provide a patch if you can point me to the place where I can add translations to TYPO3.lang by default. I do not want to put it in the PageRenderer.