Describe the Bug.
When using theme: 'all' (the default) in the admin config, the login page always renders with the light theme even when the user's system is set to dark mode. After logging in, the dark theme works correctly on all other admin pages.
Reproduction Steps
- Set up Payload with default theme settings (or explicitly set
admin.theme: 'all')
- Set your system to dark mode
- Visit the login page
- Observe that the login page shows light theme
- Log in
- Observe that authenticated pages correctly show dark theme
Environment Info
Binaries:
Node: 22.22.0
npm: 10.9.4
Yarn: 1.22.19
pnpm: 9.15.4
Relevant Packages:
payload: 3.72.0
Operating System:
Platform: darwin
Arch: arm64
Version: Darwin Kernel Version 24.3.0: Thu Jan 2 20:24:23 PST 2025; root:xnu-11215.81.4~3/RELEASE_ARM64_T6020
Available memory (MB): 16384
Available CPU cores: 10
Describe the Bug.
When using
theme: 'all'(the default) in the admin config, the login page always renders with the light theme even when the user's system is set to dark mode. After logging in, the dark theme works correctly on all other admin pages.Reproduction Steps
admin.theme: 'all')Environment Info