Skip to content

Commit eda6ea6

Browse files
committed
Also translate 'Add notes, ...' inside Editor
Signed-off-by: Georg Ehrke <[email protected]>
1 parent 8deeaf7 commit eda6ea6

File tree

3 files changed

+6
-4
lines changed

3 files changed

+6
-4
lines changed

package-lock.json

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
"@nextcloud/axios": "^1.3.2",
2727
"@nextcloud/event-bus": "^1.1.3",
2828
"@nextcloud/initial-state": "^1.1.1",
29+
"@nextcloud/l10n": "^1.3.0",
2930
"@nextcloud/router": "^1.0.2",
3031
"@nextcloud/vue": "^1.5.0",
3132
"escape-html": "^1.0.3",

src/EditorFactory.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ import { Strong, Italic, Strike } from './marks'
3838
import { Image, PlainTextDocument, ListItem } from './nodes'
3939
import MarkdownIt from 'markdown-it'
4040
import taskLists from 'markdown-it-task-lists'
41+
import { translate as t } from '@nextcloud/l10n'
4142

4243
import { MarkdownSerializer, defaultMarkdownSerializer } from 'prosemirror-markdown'
4344

@@ -81,7 +82,7 @@ const createEditor = ({ content, onInit, onUpdate, extensions, enableRichEditing
8182
new Image(),
8283
new Placeholder({
8384
emptyNodeClass: 'is-empty',
84-
emptyNodeText: 'Add notes, lists or links …',
85+
emptyNodeText: t('text', 'Add notes, lists or links …'),
8586
showOnlyWhenEditable: true,
8687
}),
8788
]

0 commit comments

Comments
 (0)