diff --git a/frontend/src/app.css b/frontend/src/app.css index df7acd7..22d6aa7 100644 --- a/frontend/src/app.css +++ b/frontend/src/app.css @@ -35,6 +35,10 @@ --shadow-md: 0 4px 12px rgb(15 23 42 / 0.1); --shadow-lg: 0 12px 32px rgb(15 23 42 / 0.18); --space: 8px; + + /* motion */ + --ease: cubic-bezier(0.2, 0, 0, 1); + --dur: 180ms; } @media (prefers-color-scheme: dark) { @@ -174,6 +178,34 @@ a { flex: none; } +/* reliability status badge (used by the station detail panel) */ +.badge { + display: inline-flex; + align-items: center; + gap: 7px; + padding: 4px 11px; + border-radius: 999px; + font-size: 0.82rem; + font-weight: 600; + border: 1px solid color-mix(in srgb, currentColor 35%, transparent); + background: color-mix(in srgb, currentColor 12%, var(--surface)); +} +.badge .dot { + background: currentColor; +} +.badge-green { + color: var(--rel-green); +} +.badge-amber { + color: var(--rel-amber); +} +.badge-red { + color: var(--rel-red); +} +.badge-grey { + color: var(--rel-grey); +} + /* accessible focus ring everywhere */ :focus-visible { outline: 2px solid var(--accent); diff --git a/frontend/src/lib/Header.svelte b/frontend/src/lib/Header.svelte index 7dc3c3a..9a83e2a 100644 --- a/frontend/src/lib/Header.svelte +++ b/frontend/src/lib/Header.svelte @@ -20,9 +20,11 @@
- + + + PlugPulse @@ -68,19 +70,27 @@ background: color-mix(in srgb, var(--surface) 82%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--border); + box-shadow: var(--shadow-sm); } .brand { display: inline-flex; align-items: center; - gap: 8px; + gap: 9px; text-decoration: none; color: var(--text); font-weight: 800; font-size: 18px; letter-spacing: -0.01em; } - .bolt { - color: var(--primary); + .mark { + display: inline-grid; + place-items: center; + width: 30px; + height: 30px; + border-radius: 9px; + background: var(--primary); + color: var(--on-primary); + box-shadow: var(--shadow-sm); } .word { color: var(--text); diff --git a/frontend/src/lib/Legend.svelte b/frontend/src/lib/Legend.svelte new file mode 100644 index 0000000..76c190d --- /dev/null +++ b/frontend/src/lib/Legend.svelte @@ -0,0 +1,52 @@ + + + + + diff --git a/frontend/src/lib/StationDetail.svelte b/frontend/src/lib/StationDetail.svelte index 3254dd7..121a813 100644 --- a/frontend/src/lib/StationDetail.svelte +++ b/frontend/src/lib/StationDetail.svelte @@ -1,6 +1,8 @@