frontend: one glass token pair in place of three copied light and dark blocks
Headers, badges, terminal panes, the message box and the dashboard's bars read --glass-clear and --glass-filter from theme.css; the light palette (colors.css) and the solid-backgrounds setting set them. Each surface keeps a single rule, the per-theme override blocks and the quiet-badge specificity workaround go, and the dashboard and agent page now follow the light palette like the swarm UI.
This commit is contained in:
parent
2a719a52e8
commit
1ca82b3e09
2 changed files with 93 additions and 122 deletions
|
|
@ -39,31 +39,18 @@
|
|||
/* Frosted glass, the recipe of the badges (`Badge.css`): translucent over a
|
||||
blur, so the rows scroll behind it. Dark only, as there: on a light page
|
||||
the busy content behind would wash the text out, so light keeps the solid
|
||||
fill. */
|
||||
background: color-mix(in srgb, var(--bg-elev) 55%, transparent);
|
||||
-webkit-backdrop-filter: blur(10px) saturate(140%);
|
||||
backdrop-filter: blur(10px) saturate(140%);
|
||||
fill (`--glass-clear` in theme.css). */
|
||||
background: color-mix(
|
||||
in srgb,
|
||||
var(--bg-elev) calc(100% - 45% * var(--glass-clear)),
|
||||
transparent
|
||||
);
|
||||
-webkit-backdrop-filter: var(--glass-filter);
|
||||
backdrop-filter: var(--glass-filter);
|
||||
box-shadow:
|
||||
0 0.3em 1em rgba(0, 0, 0, 0.45),
|
||||
0 0 0 1px color-mix(in srgb, var(--purple) 12%, transparent);
|
||||
}
|
||||
@media (prefers-color-scheme: light) {
|
||||
.ui-agent-input-form {
|
||||
background: var(--bg-elev);
|
||||
-webkit-backdrop-filter: none;
|
||||
backdrop-filter: none;
|
||||
}
|
||||
}
|
||||
:root[data-theme="light"] .ui-agent-input-form {
|
||||
background: var(--bg-elev);
|
||||
-webkit-backdrop-filter: none;
|
||||
backdrop-filter: none;
|
||||
}
|
||||
:root[data-theme="dark"] .ui-agent-input-form {
|
||||
background: color-mix(in srgb, var(--bg-elev) 55%, transparent);
|
||||
-webkit-backdrop-filter: blur(10px) saturate(140%);
|
||||
backdrop-filter: blur(10px) saturate(140%);
|
||||
}
|
||||
.ui-agent-input-form:focus-within {
|
||||
border-color: var(--purple);
|
||||
box-shadow:
|
||||
|
|
|
|||
|
|
@ -22,8 +22,8 @@
|
|||
/* Sticky + frosted glass (mara: "sticky header bar ... frosted glass")
|
||||
— same `color-mix` + `backdrop-filter` recipe `.terminal-wrap`/
|
||||
`.ui-badge` (@hive/shared) already use, dark-only same as those (a
|
||||
light bg behind glass washes out). `z-index` keeps it above
|
||||
`.shell-body` once content scrolls underneath. */
|
||||
light bg behind glass washes out; `--glass-clear` in theme.css).
|
||||
`z-index` keeps it above `.shell-body` once content scrolls underneath. */
|
||||
.shell-header {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
|
@ -31,30 +31,17 @@
|
|||
gap: 1.5em;
|
||||
padding: 0.75em 1.25em;
|
||||
border-bottom: 1px solid var(--border);
|
||||
background: color-mix(in srgb, var(--bg-elev) 80%, transparent);
|
||||
-webkit-backdrop-filter: blur(8px) saturate(120%);
|
||||
backdrop-filter: blur(8px) saturate(120%);
|
||||
background: color-mix(
|
||||
in srgb,
|
||||
var(--bg-elev) calc(100% - 20% * var(--glass-clear)),
|
||||
transparent
|
||||
);
|
||||
-webkit-backdrop-filter: var(--glass-filter);
|
||||
backdrop-filter: var(--glass-filter);
|
||||
position: sticky;
|
||||
top: 0;
|
||||
z-index: 10;
|
||||
}
|
||||
@media (prefers-color-scheme: light) {
|
||||
.shell-header {
|
||||
background: var(--bg-elev);
|
||||
-webkit-backdrop-filter: none;
|
||||
backdrop-filter: none;
|
||||
}
|
||||
}
|
||||
:root[data-theme="light"] .shell-header {
|
||||
background: var(--bg-elev);
|
||||
-webkit-backdrop-filter: none;
|
||||
backdrop-filter: none;
|
||||
}
|
||||
:root[data-theme="dark"] .shell-header {
|
||||
background: color-mix(in srgb, var(--bg-elev) 80%, transparent);
|
||||
-webkit-backdrop-filter: blur(8px) saturate(120%);
|
||||
backdrop-filter: blur(8px) saturate(120%);
|
||||
}
|
||||
/* The swarm name links to the start page; the link adds no look of its own,
|
||||
so the brand's accent and glow (on the span inside) are all that show. */
|
||||
.shell-brand-link {
|
||||
|
|
|
|||
Loading…
Reference in a new issue