Mail-logo als vooraf samengestelde witte badge (geen grijze plaat); succes-toast bij rolwijziging

- themes/asf/logo-mail.png (+ make-mail-logo.py), geleverd als /admin/brand-logo-mail.png; ASF Email:LogoUrl wijst ernaar
- Renderer: plaat weggehaald, licht logo 56px, dark-swap naar LogoDarkUrl blijft
- UsersPage: toast na geslaagde rolwijziging (nl+en, ook Owner-bevestiging)

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-09 16:11:33 +01:00
co-authored by Claude Sonnet 5.5
parent 07bad14453
commit a9b9ad2931
13 changed files with 107 additions and 22 deletions
+4 -2
View File
@@ -11,7 +11,7 @@ export interface ResolvedTheme {
* ink), or null when the theme ships none. Both or neither: a logo that is invisible in one
* colour mode is worse than none.
*/
logo: { onLight: string; onDark: string } | null;
logo: { onLight: string; onDark: string; mail: string | null } | null;
}
const THEMES_DIR = import.meta.dirname;
@@ -47,9 +47,11 @@ export function resolveTheme(name: string | undefined, dir: string = THEMES_DIR)
const favicon = path.join(dir, trimmed, 'favicon.png');
const onLight = path.join(dir, trimmed, 'logo-on-light.png');
const onDark = path.join(dir, trimmed, 'logo-on-dark.png');
// Optional: the logo for e-mail headers, on a baked-in white badge (see themes/asf/make-mail-logo.py).
const mail = path.join(dir, trimmed, 'logo-mail.png');
return {
css: path.join(dir, trimmed, 'theme.css'),
favicon: fs.existsSync(favicon) ? favicon : null,
logo: fs.existsSync(onLight) && fs.existsSync(onDark) ? { onLight, onDark } : null,
logo: fs.existsSync(onLight) && fs.existsSync(onDark) ? { onLight, onDark, mail: fs.existsSync(mail) ? mail : null } : null,
};
}