From da1bcd8794022d11e1a18e860787e20da5c34a9a Mon Sep 17 00:00:00 2001 From: Steffen Becker Date: Sat, 18 Jul 2026 15:50:26 +0200 Subject: [PATCH] feat: images in header/footer --- src/lib/components/ToolbarExpanded.svelte | 5 +- src/lib/editor/extensions/headerFooter.ts | 8 ++- src/lib/export/odt.ts | 85 +++++++++++++++++++++-- src/lib/i18n/locales/de.ts | 1 - src/lib/i18n/locales/en.ts | 1 - src/lib/import/docx.ts | 10 ++- src/lib/import/odt.ts | 8 ++- tests/docx-roundtrip.test.ts | 18 +++++ tests/roundtrip.test.ts | 27 +++++++ 9 files changed, 145 insertions(+), 18 deletions(-) diff --git a/src/lib/components/ToolbarExpanded.svelte b/src/lib/components/ToolbarExpanded.svelte index 206fa81..1783e54 100644 --- a/src/lib/components/ToolbarExpanded.svelte +++ b/src/lib/components/ToolbarExpanded.svelte @@ -823,7 +823,7 @@ const input = e.target as HTMLInputElement; const file = input.files?.[0]; input.value = ''; // allow re-selecting the same file - if (!file || !editor || hfActive) return; + if (!file || !editor) return; // editor = activeEditor (body or the active HF zone) const reader = new FileReader(); reader.onload = () => { const src = reader.result as string; @@ -1348,8 +1348,7 @@ />