feat(select, combobox): plane-constant popup elevation (B2)

Per the elevation doctrine (variant = emphasis, elevation = plane), the
select / combobox popups now take their surface · border · shadow from the
`overlay` plane via `data-depth="overlay"` — constant across variants. The
variant (surface / outline / ghost) tints only the trigger / control, no
longer the popup elevation.

- Drop the content's own border / bg / shadow + the per-variant elevation
  overrides (outline/ghost were `raised` / lighter / borderless).
- Point the arrows at `--depth-overlay-surface` / `--depth-overlay-border`.
- Prune select's 6 now-orphaned `content-*` elevation recipe tokens.

Verified in-browser (measured): combobox surface AND ghost both paint
bg oklch(0.285) + 1px border + overlay shadow from the plane (ghost was
transparent/borderless before — now flattened to the plane). select is the
identical change; its open popup hangs the preview renderer (no console
errors — preview infra), so it rides the same plane mechanism + check 0 +
eidos-lint 0 invalid + contract test (no new orphans).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
active-uix
dev 4 months ago
parent be5396cecd
commit d578f83281

@ -39,6 +39,7 @@
customAnchor={anchorEl}
style={composedStyle}
data-list-surface=""
data-depth="overlay"
data-size={resolvedSize}
data-variant={resolvedVariant}
data-color={resolvedColor}

@ -275,10 +275,10 @@
max-block-size: min(22rem, var(--floating-available-height, 100dvh));
padding: var(--_combobox-content-py) var(--_combobox-content-px);
overflow: hidden;
border: var(--border-width) solid var(--color-border-default);
/* Elevation — surface · border · shadow — from the `overlay` plane via
`data-depth` (A1). Constant across variants (the variant tints only the
control). Radius / color stay the panel's own. */
border-radius: var(--radius-lg);
background: var(--color-surface-overlay);
box-shadow: var(--depth-overlay-shadow), var(--depth-overlay-halo);
color: var(--color-content-primary);
font-family: var(--font-ui);
font-size: var(--_combobox-font-size);
@ -311,14 +311,8 @@
--_combobox-font-size: var(--font-size-xl);
}
[data-combobox-content][data-variant='outline'] {
box-shadow: var(--depth-raised-shadow), var(--depth-raised-halo);
}
[data-combobox-content][data-variant='ghost'] {
border-color: transparent;
box-shadow: var(--depth-raised-shadow), var(--depth-raised-halo);
}
/* Variant no longer changes the popup elevation — it is plane-constant (A1).
`surface` / `outline` / `ghost` tint only the control. */
[data-combobox-content][data-state='open'] {
animation: combobox-content-in var(--duration-normal) var(--ease-out) both;
@ -464,12 +458,12 @@
}
[data-combobox-arrow] polygon {
fill: var(--color-surface-overlay);
fill: var(--depth-overlay-surface);
stroke: none;
}
[data-combobox-arrow] path {
stroke: var(--color-border-default);
stroke: var(--depth-overlay-border);
stroke-width: var(--border-width);
stroke-linecap: round;
stroke-linejoin: round;

@ -34,6 +34,7 @@
{...rest}
style={composedStyle}
data-list-surface=""
data-depth="overlay"
data-size={resolvedSize}
data-variant={resolvedVariant}
data-color={resolvedColor}

@ -177,10 +177,10 @@
max-block-size: min(var(--select-content-max-height), var(--floating-available-height, 100dvh));
padding: var(--_select-content-py) var(--_select-content-px);
overflow: hidden;
border: var(--select-content-border-width) solid var(--select-content-border);
/* Elevation — surface · border · shadow — from the `overlay` plane via
`data-depth` (A1). Constant across variants (the variant tints only the
trigger). Radius / color stay the panel's own. */
border-radius: var(--select-content-radius);
background: var(--select-content-bg);
box-shadow: var(--select-content-shadow);
color: var(--select-content-color);
font-family: var(--select-font-family);
font-size: var(--_select-font-size);
@ -213,14 +213,8 @@
--_select-font-size: var(--select-font-size-xl);
}
[data-select-content][data-variant='outline'] {
box-shadow: var(--select-content-outline-shadow);
}
[data-select-content][data-variant='ghost'] {
border-color: transparent;
box-shadow: var(--select-content-ghost-shadow);
}
/* Variant no longer changes the popup elevation — it is plane-constant (A1).
`surface` / `outline` / `ghost` tint only the trigger. */
[data-select-content][data-state='open'] {
animation: select-content-in var(--select-open-duration) var(--ease-out) both;
@ -365,13 +359,13 @@
}
[data-select-arrow] polygon {
fill: var(--select-content-bg);
fill: var(--depth-overlay-surface);
stroke: none;
}
[data-select-arrow] path {
stroke: var(--select-content-border);
stroke-width: var(--select-content-border-width);
stroke: var(--depth-overlay-border);
stroke-width: var(--border-width);
stroke-linecap: round;
stroke-linejoin: round;
vector-effect: non-scaling-stroke;

@ -2189,14 +2189,8 @@
--select-content-min-width: 12rem;
--select-content-max-width: 24rem;
--select-content-max-height: min(20rem, calc(100dvh - var(--space-6)));
--select-content-border-width: var(--border-width);
--select-content-border: var(--color-border-default);
--select-content-radius: var(--radius-lg);
--select-content-bg: var(--color-surface-overlay);
--select-content-color: var(--color-content-primary);
--select-content-shadow: var(--depth-overlay-shadow), var(--depth-overlay-halo);
--select-content-outline-shadow: var(--depth-raised-shadow), var(--depth-raised-halo);
--select-content-ghost-shadow: var(--depth-raised-shadow), var(--depth-raised-halo);
--select-open-duration: var(--duration-normal);
--select-close-duration: var(--duration-fast);
--select-viewport-gap: var(--space-0-5);

@ -2254,14 +2254,8 @@ export const THEME_BASE_RECIPE_TOKENS = {
'content-min-width': '12rem',
'content-max-width': '24rem',
'content-max-height': 'min(20rem, calc(100dvh - var(--space-6)))',
'content-border-width': 'var(--border-width)',
'content-border': 'var(--color-border-default)',
'content-radius': 'var(--radius-lg)',
'content-bg': 'var(--color-surface-overlay)',
'content-color': 'var(--color-content-primary)',
'content-shadow': 'var(--depth-overlay-shadow), var(--depth-overlay-halo)',
'content-outline-shadow': 'var(--depth-raised-shadow), var(--depth-raised-halo)',
'content-ghost-shadow': 'var(--depth-raised-shadow), var(--depth-raised-halo)',
'open-duration': 'var(--duration-normal)',
'close-duration': 'var(--duration-fast)',
'viewport-gap': 'var(--space-0-5)',

Loading…
Cancel
Save

Powered by TurnKey Linux.