theme auth/setup pages and unify resets

Phase 7: add LoadTheme to base :browser pipeline so auth and setup
pages get theme settings. Update root.html.heex with .themed wrapper,
font preloads, layer declaration, and generated CSS injection.
Remove old data-theme JS toggle script.

Phase 8: upgrade admin/reset.css to a proper @layer reset matching
the shop reset structure. Remove dead theme toggle CSS rules.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
jamey
2026-02-21 00:17:23 +00:00
parent 65ea11c3a2
commit 8f9ed5657f
4 changed files with 84 additions and 46 deletions

View File

@@ -1,20 +1,68 @@
/* Minimal resets for admin pages */
/* Minimal reset for admin and auth pages.
When shop.css is also loaded (admin pages), the shop reset takes precedence
since both sit in @layer reset. This ensures auth/setup pages still get
baseline resets when shop.css isn't present. */
*, *::before, *::after {
box-sizing: border-box;
}
@layer reset {
*,
*::before,
*::after {
box-sizing: border-box;
}
body {
margin: 0;
font-family: system-ui, -apple-system, sans-serif;
}
* {
margin: 0;
}
/* Make LiveView wrapper divs transparent for layout */
[data-phx-session], [data-phx-teleported-src] {
display: contents;
}
html {
height: 100%;
-webkit-text-size-adjust: 100%;
text-size-adjust: 100%;
}
/* Phoenix LiveView loading states */
.phx-no-feedback.phx-no-feedback {
/* Suppress validation styles until form is interacted with */
body {
height: 100%;
line-height: 1.5;
-webkit-font-smoothing: antialiased;
}
img,
picture,
video,
canvas,
svg {
display: block;
max-width: 100%;
}
input,
button,
textarea,
select {
font: inherit;
color: inherit;
}
a {
color: inherit;
text-decoration-skip-ink: auto;
}
button {
background: none;
border: none;
padding: 0;
cursor: pointer;
}
fieldset {
border: none;
padding: 0;
}
/* LiveView wrapper divs are layout-invisible */
[data-phx-session],
[data-phx-teleported-src] {
display: contents;
}
}