diff --git a/xwiki-platform-core/xwiki-platform-annotation/xwiki-platform-annotation-ui/src/main/resources/AnnotationCode/Script.xml b/xwiki-platform-core/xwiki-platform-annotation/xwiki-platform-annotation-ui/src/main/resources/AnnotationCode/Script.xml index 65ece4740eca..5e5a1e155628 100644 --- a/xwiki-platform-core/xwiki-platform-annotation/xwiki-platform-annotation-ui/src/main/resources/AnnotationCode/Script.xml +++ b/xwiki-platform-core/xwiki-platform-annotation/xwiki-platform-annotation-ui/src/main/resources/AnnotationCode/Script.xml @@ -563,6 +563,7 @@ return XWiki; // Retrieve the annotation settings from the configuration object const config = JSON.parse(document.getElementById('annotation-config').text); +// TODO: Many messages below rely on string concatenation instead of parameters (XWIKI-21961). define('xwiki-annotation-messages', { prefix: '', keys: [ @@ -1317,7 +1318,9 @@ require(['xwiki-l10n!xwiki-annotation-messages'], function(l10n) { onFailure: function(response) { var failureReason = response.statusText || 'Server not responding'; // show the error message at the bottom - this._x_notification = new XWiki.widgets.Notification(l10n.get('annotations.action.edit.form.loaderror') + failureReason, 'error', {timeout : 5}); + this._x_notification = new + XWiki.widgets.Notification(l10n.get('annotations.action.edit.form.loaderror', failureReason), + 'error', {timeout: 5}); // load the original content of the container this.fillViewPanel(container, container.originalContentHTML, id, inBubble); }.bind(this), diff --git a/xwiki-platform-core/xwiki-platform-annotation/xwiki-platform-annotation-ui/src/main/resources/AnnotationCode/Translations.xml b/xwiki-platform-core/xwiki-platform-annotation/xwiki-platform-annotation-ui/src/main/resources/AnnotationCode/Translations.xml index 8d21738b3f8e..673b4beb08cb 100644 --- a/xwiki-platform-core/xwiki-platform-annotation/xwiki-platform-annotation-ui/src/main/resources/AnnotationCode/Translations.xml +++ b/xwiki-platform-core/xwiki-platform-annotation/xwiki-platform-annotation-ui/src/main/resources/AnnotationCode/Translations.xml @@ -59,6 +59,8 @@ annotations.action.edit.success=Annotation updated. annotations.action.edit.loaderror=Failed: annotations.action.edit.error.notfound=This annotation does not exist anymore. Please refresh the page for an updated view. +annotations.action.edit.form.loaderror=Failed: {0} + annotations.action.delete.text=[Delete] annotations.action.delete.tooltip=Delete annotation annotations.action.delete.confirm=Are you sure you want to delete this annotation?