Admin-teksten en merklogo: Weergavenaam, Wachtwoord wijzigen, Eerste account aanmaken, logo per thema

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-08 14:36:10 +01:00
co-authored by Claude Sonnet 5.5
parent cd81723bf5
commit 55dcab121b
20 changed files with 350 additions and 25 deletions
+26
View File
@@ -0,0 +1,26 @@
import { describe, expect, it } from 'vitest';
import { getBrand, themeLogo } from '@/lib/brand';
describe('themeLogo', () => {
it('points at the emitted logo files under the app base path', () => {
expect(themeLogo(true, '/admin/')).toEqual({
onLight: '/admin/brand-logo-on-light.png',
onDark: '/admin/brand-logo-on-dark.png',
});
});
it('tolerates a base without trailing slash and the dev root', () => {
expect(themeLogo(true, '/admin')?.onLight).toBe('/admin/brand-logo-on-light.png');
expect(themeLogo(true, '/')?.onDark).toBe('/brand-logo-on-dark.png');
});
it('has no logo when the theme ships none', () => {
expect(themeLogo(false)).toBeNull();
});
});
describe('getBrand', () => {
it('has no logo without a theme (the default admin is unchanged)', () => {
expect(getBrand().logo).toBeNull();
});
});