feat: fix signature editor init and expand README
Build and Push Multi-Platform Images / build-and-push (push) Successful in 18s
Build and Push Multi-Platform Images / build-and-push (push) Successful in 18s
- Pass initialContent prop to WysiwygEditor instead of imperative setContent to ensure mail signature loads correctly on mount - Rewrite README to reflect full project scope (scanner inbox, email import, postprocessing rules, label printing, OIDC auth) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
1 parent
2df3af719b
commit
f482304061
3 files changed
+82
-11
No files matched your search
@@ -68,6 +68,7 @@ function MailSettingsTab() {
|
||||
const [testing, setTesting] = useState(false);
|
||||
const [testResult, setTestResult] = useState<{ ok: boolean; error?: string } | null>(null);
|
||||
const [passSet, setPassSet] = useState(false);
|
||||
const [signatureHtml, setSignatureHtml] = useState<string | null>(null);
|
||||
const editorRef = useRef<WysiwygEditorHandle>(null);
|
||||
|
||||
useEffect(() => {
|
||||
@@ -81,9 +82,7 @@ function MailSettingsTab() {
|
||||
smtpFromName: data.smtpFromName ?? '',
|
||||
});
|
||||
setPassSet(data.smtpPassSet);
|
||||
if (data.mailSignatureHtml) {
|
||||
editorRef.current?.setContent(data.mailSignatureHtml);
|
||||
}
|
||||
setSignatureHtml(data.mailSignatureHtml ?? null);
|
||||
}).catch(() => {
|
||||
message.error('Einstellungen konnten nicht geladen werden');
|
||||
}).finally(() => setLoading(false));
|
||||
@@ -167,7 +166,7 @@ function MailSettingsTab() {
|
||||
</Form.Item>
|
||||
|
||||
<Form.Item label="Signatur">
|
||||
<WysiwygEditor ref={editorRef} minHeight={180} />
|
||||
<WysiwygEditor ref={editorRef} initialContent={signatureHtml ?? ''} minHeight={180} />
|
||||
</Form.Item>
|
||||
|
||||
<Form.Item>
|
||||
|
||||
Reference in new issue
Block a user