fix: the empty document's placeholder follows the UI language

The body said "Start typing…" in every language while the header and
footer zones were localized; switching the language now redraws it.
This commit is contained in:
Steffen Becker committed 2026-09-04 19:30:12 +02:00
1 parent 9335f392ce
commit bc8f8d89d1
4 files changed
+11 -1

No files matched your search

+2 -1
View File
@@ -24,6 +24,7 @@ import { Table, TableHeader, TableCell } from '@tiptap/extension-table';
import { ResizableTableRow } from './extensions/tableRow';
import History from '@tiptap/extension-history';
import Placeholder from '@tiptap/extension-placeholder';
import { t } from '../i18n/i18n.svelte';
import { PageBreaks } from './extensions/pageBreaks';
import { LineHeight } from './extensions/lineHeight';
@@ -224,7 +225,7 @@ export const extensions = [
// and the user can keep writing below a table at the document's end.
TrailingNode,
History,
Placeholder.configure({ placeholder: 'Start typing…' }),
Placeholder.configure({ placeholder: () => t().app.startTyping }),
// No defaultAlignment: it would put textAlign:'left' on every block, and that inline
// style beats the paragraph style's alignment. Unset = follow the style; an explicit
// 'left' stays direct formatting that overrides it, as in Word/LibreOffice.