@mkbabb/glass-ui 3.10.0 → 3.10.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{CardAction-DuArVky-.js → CardAction-DrAcAV4d.js} +2 -2
- package/dist/{CommandShortcut-CefCj5mt.js → CommandShortcut-mV2e1aG6.js} +2 -2
- package/dist/{DataTable-CUHMukiQ.js → DataTable-C3E6jZ5B.js} +2 -2
- package/dist/{DialogContent-BRkT1cjP.js → DialogContent-BxaaafFi.js} +1 -1
- package/dist/{HoverPopover-2LOIW34a.js → HoverPopover-CDA_SaCe.js} +1 -1
- package/dist/{MetricBadge-BZVWIxNy.js → MetricBadge-idgrkqoP.js} +5 -7
- package/dist/{Notification-DLMhblXR.js → Notification-Cu0nN17_.js} +1 -1
- package/dist/{NumberFieldContent-BbLOh8RU.js → NumberFieldContent-CHEWghnY.js} +2 -2
- package/dist/{PopoverContent-BId6ggf_.js → PopoverContent-DpUvdYY-.js} +1 -1
- package/dist/{Progress-iEuD9pxG.js → Progress-BW-StFw2.js} +1 -1
- package/dist/{ScrollingText-BPP84wKo.js → ScrollingText-DruYCni_.js} +1 -1
- package/dist/{SelectScrollDownButton-T32cVFeM.js → SelectScrollDownButton-pirzjm--.js} +3 -3
- package/dist/{Switch-Ch-k3Rv-.js → Switch-DeAqg6pi.js} +1 -1
- package/dist/{TabsList-B8CVOQPC.js → TabsList-BAVzOZpg.js} +2 -2
- package/dist/{Toaster-1rYWrmAm.js → Toaster-CvuuW_y9.js} +49 -46
- package/dist/{ToggleGroupItem-Cev4pOVK.js → ToggleGroupItem-DtD37b4G.js} +4 -4
- package/dist/animated-digit.js +2 -2
- package/dist/api/index.d.ts +3 -4
- package/dist/api.js +1 -1
- package/dist/aurora.js +66 -66
- package/dist/{badge-CaoFJzRb.js → badge-NdCQMvvB.js} +1 -1
- package/dist/badge.js +1 -1
- package/dist/{button-DN39cGqL.js → button-DyiWFAOE.js} +12 -12
- package/dist/button.js +1 -1
- package/dist/canvas.js +2 -2
- package/dist/card.js +1 -1
- package/dist/carousel.js +5 -5
- package/dist/collapsible.js +1 -1
- package/dist/{color-C5ls_QF7.js → color-B65wWyQz.js} +9 -7
- package/dist/color.js +1 -1
- package/dist/command.js +1 -1
- package/dist/components/custom/aurora/constants/shaders/mediums.glsl.d.ts +1 -1
- package/dist/components/custom/aurora/constants/shaders/vangogh-medium.glsl.d.ts +1 -0
- package/dist/components/custom/constellation/Constellation.vue.d.ts +12 -0
- package/dist/components/custom/constellation/composables/createConstellationField.d.ts +35 -0
- package/dist/components/custom/constellation/composables/useConstellationPointer.d.ts +35 -0
- package/dist/components/custom/constellation/constants.d.ts +36 -0
- package/dist/components/custom/constellation/constellationDraw.d.ts +18 -0
- package/dist/components/custom/constellation/constellationField.d.ts +10 -151
- package/dist/components/custom/constellation/constellationInteraction.d.ts +102 -0
- package/dist/components/custom/constellation/index.d.ts +3 -1
- package/dist/components/custom/controls/DarkModeToggle.vue.d.ts +11 -0
- package/dist/components/custom/dock/DockTabButton.vue.d.ts +3 -4
- package/dist/components/custom/dock/GlassDock.vue.d.ts +2 -110
- package/dist/components/custom/dock/composables/dockMorphContext.d.ts +36 -0
- package/dist/components/custom/dock/composables/useDockMorphWindow.d.ts +15 -0
- package/dist/components/custom/dock/composables/useDockShellProps.d.ts +131 -0
- package/dist/components/custom/dock/composables/useLayerTransition.d.ts +44 -0
- package/dist/components/custom/dock/constants.d.ts +23 -0
- package/dist/components/custom/expandable-container/ExpandableContainer.vue.d.ts +0 -29
- package/dist/components/custom/fourier-field/index.d.ts +1 -1
- package/dist/components/custom/fourier-field/math.d.ts +17 -0
- package/dist/components/custom/fourier-field/presets.d.ts +54 -0
- package/dist/components/custom/goo-blob/composables/buildMetaballProgram.d.ts +18 -0
- package/dist/components/custom/goo-blob/composables/uploadBlobUniforms.d.ts +41 -0
- package/dist/components/custom/goo-blob/composables/useBlobPointer.d.ts +4 -3
- package/dist/components/custom/goo-blob/composables/useMetaballRenderer.d.ts +11 -8
- package/dist/components/custom/goo-blob/constants.d.ts +52 -0
- package/dist/components/custom/goo-blob/shaders/metaball-uniforms.glsl.d.ts +1 -0
- package/dist/components/custom/instrument-chassis/InstrumentChassis.vue.d.ts +2 -2
- package/dist/components/custom/metric-badge/MetricBadge.vue.d.ts +0 -8
- package/dist/components/custom/tabs/constants.d.ts +12 -0
- package/dist/components/custom/underline/GlassUnderline.vue.d.ts +84 -0
- package/dist/components/custom/underline/index.d.ts +2 -0
- package/dist/components/custom/underline/types.d.ts +56 -0
- package/dist/components/ui/drawer/Drawer.vue.d.ts +1 -0
- package/dist/components/ui/dropdown-menu/DropdownMenuSubContent.vue.d.ts +2 -2
- package/dist/components/ui/slider/index.d.ts +22 -19
- package/dist/components/ui/toast/use-toast.d.ts +2 -2
- package/dist/composables/color/index.d.ts +12 -0
- package/dist/composables/glass/useSpecularTracking.d.ts +12 -3
- package/dist/composables/motion/core/index.d.ts +0 -1
- package/dist/composables/motion/curves.d.ts +48 -0
- package/dist/composables/motion/index.d.ts +2 -0
- package/dist/composables/motion/springPresets.d.ts +33 -0
- package/dist/composables/motion/suite.d.ts +2 -0
- package/dist/composables/motion/useSpringMount.d.ts +1 -1
- package/dist/configurator.js +1 -1
- package/dist/confirm-dialog.js +2 -2
- package/dist/constellation.js +260 -225
- package/dist/controls.js +48 -14
- package/dist/dark.js +1 -1
- package/dist/data-table.js +1 -1
- package/dist/dialog.js +2 -2
- package/dist/dock.js +339 -327
- package/dist/dockContext-bho8B1A4.js +17 -0
- package/dist/{dropdown-menu-D77jX6Df.js → dropdown-menu-DVnQcA0E.js} +7 -4
- package/dist/dropdown-menu.js +1 -1
- package/dist/expandable-container.js +38 -61
- package/dist/forms.js +2 -2
- package/dist/fourier-field.js +137 -102
- package/dist/fourier-math.js +2 -2
- package/dist/glass-ui.css +1 -1
- package/dist/glass-ui.js +287 -209
- package/dist/goo-blob.js +243 -212
- package/dist/hover-popover.js +1 -1
- package/dist/icon-tooltip.js +1 -1
- package/dist/index.d.ts +0 -3
- package/dist/keyboard.js +1 -1
- package/dist/labeled-field.js +5 -5
- package/dist/{math-DTpRVC0e.js → math-BUU9hHID.js} +18 -2
- package/dist/metric-badge.js +1 -1
- package/dist/metric-stack.js +1 -1
- package/dist/motion-core.js +69 -70
- package/dist/motion-curves.d.ts +1 -0
- package/dist/motion-curves.js +130 -0
- package/dist/motion.js +38 -37
- package/dist/notification.js +1 -1
- package/dist/number-field.js +1 -1
- package/dist/popover.js +1 -1
- package/dist/progress.js +1 -1
- package/dist/pulse.js +1 -1
- package/dist/reactive.js +1 -1
- package/dist/scrolling-text.js +1 -1
- package/dist/search.js +6 -6
- package/dist/select.js +1 -1
- package/dist/{sheet-VZEtNFvO.js → sheet-ChSXcJpU.js} +1 -1
- package/dist/sheet.js +1 -1
- package/dist/{slider-CyzcxBoh.js → slider-sfl8gFDD.js} +4 -4
- package/dist/slider.js +1 -1
- package/dist/sortable-list.js +2 -2
- package/dist/springPresets-aRSm-4_k.js +40 -0
- package/dist/stacked-icons.js +6 -6
- package/dist/styles/animations.css +18 -74
- package/dist/styles/components.css +1 -1
- package/dist/styles/dock/layer-group.css +22 -0
- package/dist/styles/dock/layers.css +11 -1
- package/dist/styles/dock/morph.css +95 -19
- package/dist/styles/dock/shell.css +12 -0
- package/dist/styles/dock-controls.css +28 -31
- package/dist/styles/drawer.css +2 -0
- package/dist/styles/floating-panel.css +2 -0
- package/dist/styles/glass/a11y-fallback.css +245 -0
- package/dist/styles/glass/ladder.css +304 -0
- package/dist/styles/glass/material.css +238 -0
- package/dist/styles/glass/progress-rail.css +78 -0
- package/dist/styles/glass/squircle.css +66 -0
- package/dist/styles/glass/surfaces.css +306 -0
- package/dist/styles/glass-refract.css +2 -0
- package/dist/styles/glass.css +31 -1188
- package/dist/styles/hover-popover.css +2 -0
- package/dist/styles/index.css +24 -6
- package/dist/styles/instrument-chassis.css +4 -0
- package/dist/styles/paper.css +2 -68
- package/dist/styles/theme.css +13 -20
- package/dist/styles/tokens/color-radius.css +250 -0
- package/dist/styles/tokens/dark-arm.css +194 -0
- package/dist/styles/tokens/glass.css +413 -0
- package/dist/styles/tokens/light-dark.css +158 -0
- package/dist/styles/tokens/offsets-sizing.css +406 -0
- package/dist/styles/tokens/property-regs.css +169 -0
- package/dist/styles/tokens/scale-paper.css +361 -0
- package/dist/styles/tokens/scheme-motion.css +334 -0
- package/dist/styles/tokens/shadow.css +132 -0
- package/dist/styles/tokens.css +22 -2355
- package/dist/styles/typography.css +18 -6
- package/dist/styles/utilities/a11y-overrides.css +140 -0
- package/dist/styles/utilities/animate.css +26 -0
- package/dist/styles/utilities/base.css +365 -0
- package/dist/styles/utilities/btn.css +399 -0
- package/dist/styles/utilities/components.css +317 -0
- package/dist/styles/utilities.css +19 -1260
- package/dist/styles/view-transition.css +0 -51
- package/dist/switch.js +1 -1
- package/dist/tabs.js +98 -98
- package/dist/timeline.js +2 -2
- package/dist/toast.js +1 -1
- package/dist/toggle-group.js +1 -1
- package/dist/typewriter.js +1 -1
- package/dist/underline.d.ts +1 -0
- package/dist/underline.js +85 -0
- package/dist/{useAnimatedNumber-Bcpy5Etf.js → useAnimatedNumber-DfVgP4te.js} +1 -1
- package/dist/{useConfiguratorState-DxAqksK6.js → useConfiguratorState-BdQXh9ie.js} +1 -1
- package/dist/useSpecularTracking-DFK_fhpG.js +32 -0
- package/dist/useSpringMount-DXUzxBjV.js +108 -0
- package/dist/vReveal-CqaCz_mC.js +44 -0
- package/dist/watercolor-dot.js +2 -2
- package/package.json +34 -52
- package/src/styles/animations.css +18 -74
- package/src/styles/dock/layer-group.css +22 -0
- package/src/styles/dock/layers.css +11 -1
- package/src/styles/dock/morph.css +95 -19
- package/src/styles/dock/shell.css +12 -0
- package/src/styles/dock-controls.css +28 -31
- package/src/styles/glass/a11y-fallback.css +245 -0
- package/src/styles/glass/ladder.css +304 -0
- package/src/styles/glass/material.css +238 -0
- package/src/styles/glass/progress-rail.css +78 -0
- package/src/styles/glass/squircle.css +66 -0
- package/src/styles/glass/surfaces.css +306 -0
- package/src/styles/glass.css +31 -1188
- package/src/styles/index.css +24 -6
- package/src/styles/paper.css +2 -68
- package/src/styles/theme.css +13 -20
- package/src/styles/tokens/color-radius.css +250 -0
- package/src/styles/tokens/dark-arm.css +194 -0
- package/src/styles/tokens/glass.css +413 -0
- package/src/styles/tokens/light-dark.css +158 -0
- package/src/styles/tokens/offsets-sizing.css +406 -0
- package/src/styles/tokens/property-regs.css +169 -0
- package/src/styles/tokens/scale-paper.css +361 -0
- package/src/styles/tokens/scheme-motion.css +334 -0
- package/src/styles/tokens/shadow.css +132 -0
- package/src/styles/tokens.css +22 -2355
- package/src/styles/typography.css +18 -6
- package/src/styles/utilities/a11y-overrides.css +140 -0
- package/src/styles/utilities/animate.css +26 -0
- package/src/styles/utilities/base.css +365 -0
- package/src/styles/utilities/btn.css +399 -0
- package/src/styles/utilities/components.css +317 -0
- package/src/styles/utilities.css +19 -1260
- package/src/styles/view-transition.css +0 -51
- package/dist/DeckProgress-Dmk4_AKN.js +0 -23
- package/dist/InstrumentRail-CUJ05YVG.js +0 -44
- package/dist/components/custom/deck-progress/DeckProgress.vue.d.ts +0 -27
- package/dist/components/custom/deck-progress/index.d.ts +0 -2
- package/dist/components/custom/dialog-native/GlassDialogNative.vue.d.ts +0 -57
- package/dist/components/custom/dialog-native/index.d.ts +0 -1
- package/dist/components/custom/glass-panel/GlassPanel.vue.d.ts +0 -41
- package/dist/components/custom/glass-panel/index.d.ts +0 -2
- package/dist/components/custom/handmark/HandMark.vue.d.ts +0 -29
- package/dist/components/custom/handmark/brush.d.ts +0 -219
- package/dist/components/custom/handmark/freehand.d.ts +0 -69
- package/dist/components/custom/handmark/geometry.d.ts +0 -32
- package/dist/components/custom/handmark/index.d.ts +0 -21
- package/dist/components/custom/handmark/ink.d.ts +0 -11
- package/dist/components/custom/handmark/texture.d.ts +0 -39
- package/dist/components/custom/handmark/types.d.ts +0 -53
- package/dist/components/custom/handmark/useHandMark.d.ts +0 -66
- package/dist/components/custom/header-ribbon/HeaderRibbon.vue.d.ts +0 -31
- package/dist/components/custom/header-ribbon/index.d.ts +0 -2
- package/dist/components/custom/header-ribbon/types.d.ts +0 -7
- package/dist/components/custom/instrument-rail/InstrumentRail.vue.d.ts +0 -91
- package/dist/components/custom/instrument-rail/index.d.ts +0 -2
- package/dist/composables/motion/useRouteTransition.d.ts +0 -42
- package/dist/deck-progress.d.ts +0 -1
- package/dist/deck-progress.js +0 -2
- package/dist/dockContext-BKeIMmNk.js +0 -9
- package/dist/glass-panel.d.ts +0 -1
- package/dist/glass-panel.js +0 -44
- package/dist/handmark.d.ts +0 -1
- package/dist/handmark.js +0 -609
- package/dist/header-ribbon.d.ts +0 -1
- package/dist/header-ribbon.js +0 -63
- package/dist/instrument-rail.d.ts +0 -1
- package/dist/instrument-rail.js +0 -2
- package/dist/useGlassRenderer-D7YGOYiM.js +0 -69
- package/dist/useSpecularTracking-BVRZsRHA.js +0 -26
- package/dist/useSpringMount-BJSHcLl3.js +0 -113
- package/dist/useViewTransition-DaN5Zrox.js +0 -21
- package/dist/vReveal-zUIQk-rJ.js +0 -53
- /package/dist/{CollapsibleContent-CP9qF1v4.js → CollapsibleContent-Drow5WkV.js} +0 -0
- /package/dist/{DialogFooter-Gprw8H_A.js → DialogFooter-DufLHi0y.js} +0 -0
- /package/dist/{IconTooltip-Cus0fvK0.js → IconTooltip-BrQ5p181.js} +0 -0
- /package/dist/{Input-xuDwALQR.js → Input-B-F818RU.js} +0 -0
- /package/dist/{_plugin-vue_export-helper-ok8pgSl5.js → _plugin-vue_export-helper-DWghtRt7.js} +0 -0
- /package/dist/{compile-BOXjLUxu.js → compile-Ce_V55zi.js} +0 -0
- /package/dist/{constants-yKeKnE84.js → constants-C8NMonuo.js} +0 -0
- /package/dist/{presets-Dkdv55Gt.js → presets-1OhFpaIC.js} +0 -0
- /package/dist/{prng-D27-B3tK.js → prng-CjVgzjQT.js} +0 -0
- /package/dist/{resolveCanvasColor-BBiYfp8g.js → resolveCanvasColor-CRvVzOvP.js} +0 -0
- /package/dist/{useCanvas2D-ClrQuZtp.js → useCanvas2D-CSeH8h16.js} +0 -0
- /package/dist/{useGlobalDark-d6waty-X.js → useGlobalDark-D7R9OypB.js} +0 -0
- /package/dist/{useIntersectionPause-Cck5Uxk8.js → useIntersectionPause-DAdVPVp4.js} +0 -0
- /package/dist/{useInterval-Dsmqwi03.js → useInterval-D3USn0yc.js} +0 -0
- /package/dist/{useKeyboardShortcuts-CyIYrndH.js → useKeyboardShortcuts-i8tHd5WO.js} +0 -0
- /package/dist/{useScrollProgress-CffFGLa5.js → useScrollProgress-CcgmgMQt.js} +0 -0
- /package/dist/{useSortable-C8ReQ50P.js → useSortable-DnyGXKKY.js} +0 -0
- /package/dist/{useTextHighlight-CWEi25hf.js → useTextHighlight-B3b10W6r.js} +0 -0
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/* glass/squircle.css
|
|
2
|
+
The AX.W56 rounded-vs-squircle policy + the @supports (corner-shape: superellipse(2)) squircle coupling onto the overlay-band glass. After the base ladder (overrides it).
|
|
3
|
+
Carved from the glass.css cascade root; @import-ed by glass.css in cascade
|
|
4
|
+
order, each in its own @layer components (isomorphic to the monolith).
|
|
5
|
+
See docs/precepts/design-idioms.md §cohesion-aware partials. */
|
|
6
|
+
/* ── AX.W56 — the rounded-vs-squircle POLICY (re-homes AW.W23's squircle) ─────
|
|
7
|
+
Cards, glass buttons, and pills stay ROUND. The earlier AW.W23 block applied
|
|
8
|
+
`corner-shape: squircle` to `.glass-card`/`.glass-btn`/`.btn-pill`, which
|
|
9
|
+
inverted the design intent — the superellipse is imperceptible at a 16px card
|
|
10
|
+
radius or a stadium pill, so the squircle on those surfaces was visual cost
|
|
11
|
+
without read. The squircle is RE-HOMED onto the one surface where it reads: the
|
|
12
|
+
big-dock card shell (`dock.css` → `var(--corner-shape-bigdock)` under
|
|
13
|
+
`@supports (corner-shape: superellipse(2))`). This is a clean break — no alias,
|
|
14
|
+
no `--corner-shape-card` decl here (it resolves `round`, the default, so a
|
|
15
|
+
`corner-shape` rule would be a no-op). The `--corner-shape-*` token axis lives
|
|
16
|
+
in `theme.css`; a consumer who WANTS a squircle card opts in by re-pointing
|
|
17
|
+
`--corner-shape-card` at `superellipse(var(--corner-k-squircle))`. Do NOT
|
|
18
|
+
re-add a squircle rule to the card/button/pill surfaces — they are round by
|
|
19
|
+
policy. */
|
|
20
|
+
|
|
21
|
+
/* ── AX.W56(R1) + W56b — squircle coupling onto the large-radius glass FAMILY ───
|
|
22
|
+
W54 makes GLASS the default for the overlay-band surfaces; W56(R1)+W56b couple
|
|
23
|
+
the SQUIRCLE onto the whole LARGE-RADIUS glass family — Dialog + Sheet content
|
|
24
|
+
(`.glass-floating.{rounded-dialog,sheet-animate}`), the Configurator/floating
|
|
25
|
+
PANEL (`.configurator`, `.floating-panel`), and the glass HERO overlay
|
|
26
|
+
(`.glass-hero`, the thin opt-in utility the page-redesign hero reads). Every one
|
|
27
|
+
sits AT or ABOVE the ~--radius-xl threshold where the superellipse READS — the
|
|
28
|
+
same iOS-26 idiom the big-dock card shell carries (the backdrop-filter blur halo
|
|
29
|
+
+ the cartoon under-shadow follow the shape). Each surface reads its OWN
|
|
30
|
+
tokenized `var(--corner-shape-<surface>)` (theme.css) so it is independently
|
|
31
|
+
overridable — never a blanket `.glass-floating` rule (data cards + pills stay
|
|
32
|
+
round by policy; the compound selectors scope to the named surface only). Mirrors
|
|
33
|
+
the big-dock idiom EXACTLY: an `@supports`-gated ENHANCEMENT (Chrome 139+, no
|
|
34
|
+
FF/Safari 2026) over the `border-radius` round CONTRACT — the squircle is the
|
|
35
|
+
better tier, NOT a degraded fallback. The `@supports` condition tests the LITERAL
|
|
36
|
+
`superellipse(2)` (a `var()` is not evaluable in an `@supports` query) — the same
|
|
37
|
+
Chrome-139 feature the token resolves to. */
|
|
38
|
+
@layer components {
|
|
39
|
+
@supports (corner-shape: superellipse(2)) {
|
|
40
|
+
.glass-floating.rounded-dialog {
|
|
41
|
+
corner-shape: var(--corner-shape-dialog);
|
|
42
|
+
}
|
|
43
|
+
.glass-floating.sheet-animate {
|
|
44
|
+
corner-shape: var(--corner-shape-sheet);
|
|
45
|
+
}
|
|
46
|
+
.configurator,
|
|
47
|
+
.floating-panel {
|
|
48
|
+
corner-shape: var(--corner-shape-panel);
|
|
49
|
+
}
|
|
50
|
+
.glass-hero {
|
|
51
|
+
corner-shape: var(--corner-shape-hero);
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
/* ── The glass HERO opt-in utility (W56b fold 7) ────────────────────────────────
|
|
57
|
+
A thin large-radius editorial glass OVERLAY — distinct from a data Card (which
|
|
58
|
+
stays round by policy). It is the surface the page-redesign hero (W60) reads;
|
|
59
|
+
minting it here (with its consumer) keeps the squircle off every `.glass-card`.
|
|
60
|
+
The corner-shape squircle rides the `@supports` block above; the un-gated
|
|
61
|
+
`border-radius` here is the cross-engine round CONTRACT. */
|
|
62
|
+
@layer components {
|
|
63
|
+
.glass-hero {
|
|
64
|
+
border-radius: var(--radius-2xl);
|
|
65
|
+
}
|
|
66
|
+
}
|
|
@@ -0,0 +1,306 @@
|
|
|
1
|
+
/* glass/surfaces.css
|
|
2
|
+
The convenience-shorthand surfaces — .glass-card / .glass-pill / .glass-btn + the glass pill-input + the chromatic edge-dispersion rim fringe.
|
|
3
|
+
Carved from the glass.css cascade root; @import-ed by glass.css in cascade
|
|
4
|
+
order, each in its own @layer components (isomorphic to the monolith).
|
|
5
|
+
See docs/precepts/design-idioms.md §cohesion-aware partials. */
|
|
6
|
+
@layer components {
|
|
7
|
+
/* ── Convenience shorthands (tier + shape) ── */
|
|
8
|
+
|
|
9
|
+
/* Static surface utility — no hover lift, no transition.
|
|
10
|
+
Interactive cards live in <Card> (which owns its own hover composition)
|
|
11
|
+
or in components that explicitly opt into a hover variant. */
|
|
12
|
+
.glass-card {
|
|
13
|
+
/* Focus-elevation rungs (AQ.W3 §W3.1a) — identity = at-rest paint; the
|
|
14
|
+
`:has(:focus-visible)` rule redefines them (one source, shared with
|
|
15
|
+
the fallback). */
|
|
16
|
+
--card-focus-shadow: var(--shadow-card);
|
|
17
|
+
--card-focus-border: var(--glass-border-quiet);
|
|
18
|
+
position: relative;
|
|
19
|
+
background: color-mix(in oklab, var(--glass-bg-quiet), var(--glass-tint-source) var(--glass-tint-strength));
|
|
20
|
+
backdrop-filter: var(--glass-blur-quiet);
|
|
21
|
+
border: 1px solid var(--card-focus-border);
|
|
22
|
+
border-radius: var(--radius-card);
|
|
23
|
+
box-shadow: var(--glass-material-rim), var(--card-focus-shadow);
|
|
24
|
+
/* AY.W-A11Y-PERF O-4 — upgrade `layout style` → include `paint` so the
|
|
25
|
+
maximal-glass nested backdrop-filter sample (a glass Button in this card)
|
|
26
|
+
does not escape the card box (the standard nested-backdrop-cost mitigation;
|
|
27
|
+
`contain: paint` clips DESCENDANTS only — the card's own rim/drop-shadow is
|
|
28
|
+
NOT clipped, device-verified). */
|
|
29
|
+
contain: layout style paint;
|
|
30
|
+
transition:
|
|
31
|
+
box-shadow var(--duration-fast) var(--ease-standard),
|
|
32
|
+
border-color var(--duration-fast) var(--ease-standard);
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
/* Elevate one rung on descendant KEYBOARD focus (`:focus-visible`, not
|
|
36
|
+
pointer). Scoped to `.glass-card`. `:has()` Baseline Widely; the
|
|
37
|
+
`@supports not selector(:has(*))` class fallback (below) ships anyway
|
|
38
|
+
(focus-elevation is UX-critical — child-state-styling MANDATORY clause). */
|
|
39
|
+
.glass-card:has(:focus-visible) {
|
|
40
|
+
--card-focus-shadow: var(--shadow-md);
|
|
41
|
+
--card-focus-border: var(--glass-border-floating);
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
/* ── Glassmorphic circular icon button ── */
|
|
45
|
+
|
|
46
|
+
.glass-btn {
|
|
47
|
+
@apply flex items-center justify-center cursor-pointer;
|
|
48
|
+
|
|
49
|
+
/* Individual-transform identity base (AQ.W3 §W3.2) — `scale: 1` at rest
|
|
50
|
+
mints the stacking context once so the hover/press scale below does
|
|
51
|
+
not flicker it into being (the z-index/anchor hazard). */
|
|
52
|
+
scale: 1;
|
|
53
|
+
width: var(--size-icon-btn);
|
|
54
|
+
height: var(--size-icon-btn);
|
|
55
|
+
border-radius: var(--radius-pill);
|
|
56
|
+
border: 1.5px solid var(--glass-border-wash);
|
|
57
|
+
background: var(--glass-bg-wash);
|
|
58
|
+
backdrop-filter: var(--glass-blur-wash);
|
|
59
|
+
/* AY.W-A11Y-PERF O-4 — paint containment so the glass button's own
|
|
60
|
+
backdrop-filter sample stays inside the box when it nests in a glass card /
|
|
61
|
+
dialog / dock (the nested-backdrop-cost mitigation; clips descendants only,
|
|
62
|
+
the button's own rim/shadow is unaffected — device-verified). */
|
|
63
|
+
contain: paint;
|
|
64
|
+
color: var(--muted-foreground);
|
|
65
|
+
/* AX.W52 §6 doctrine — the surface legs ride the bezier `--ease-standard`;
|
|
66
|
+
the `scale` leg is reconciled onto `--spring-smooth` (was `--spring-snappy`)
|
|
67
|
+
so the icon-button hover settles on the SAME ONE register as `.btn-pill` /
|
|
68
|
+
`.tap-squish` / `btn-interactive` (the gate asserts one scale register
|
|
69
|
+
across all four). The press still reads crisp — `--spring-smooth` ζ=0.86
|
|
70
|
+
settles fast without a visible bounce. */
|
|
71
|
+
transition:
|
|
72
|
+
background var(--duration-fast) var(--ease-standard),
|
|
73
|
+
border-color var(--duration-fast) var(--ease-standard),
|
|
74
|
+
color var(--duration-fast) var(--ease-standard),
|
|
75
|
+
scale var(--duration-normal) var(--spring-smooth);
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
.glass-btn:hover:not(:disabled) {
|
|
79
|
+
background: color-mix(in srgb, var(--background) 85%, transparent);
|
|
80
|
+
border-color: var(--surface-tint-22);
|
|
81
|
+
color: var(--foreground);
|
|
82
|
+
scale: var(--scale-hover);
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.glass-btn:active:not(:disabled) {
|
|
86
|
+
scale: var(--scale-press);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.glass-btn:focus-visible {
|
|
90
|
+
outline: none;
|
|
91
|
+
box-shadow: var(--focus-ring-shadow);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.glass-btn:disabled {
|
|
95
|
+
opacity: 0.35;
|
|
96
|
+
cursor: not-allowed;
|
|
97
|
+
pointer-events: none;
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.glass-btn.is-active,
|
|
101
|
+
.glass-btn[aria-pressed="true"] {
|
|
102
|
+
background: var(--surface-tint-10);
|
|
103
|
+
border-color: var(--surface-tint-25);
|
|
104
|
+
color: var(--foreground);
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
/* ── Pill button base ─────────────────────────── */
|
|
108
|
+
.btn-pill {
|
|
109
|
+
@apply inline-flex items-center justify-center cursor-pointer font-medium border-none;
|
|
110
|
+
|
|
111
|
+
/* AX.W52 §6 identity base — `scale: 1` at rest so the hover/press scale
|
|
112
|
+
below animates the `scale` longhand (not `transform`) coherently and
|
|
113
|
+
does not flicker the stacking context into being (AQ.W3 §W3.2). */
|
|
114
|
+
scale: 1;
|
|
115
|
+
/* AX.W51 D18 — the pill GEOMETRY rides the ONE `--ui-scale` comfort axis.
|
|
116
|
+
gap / padding scale by the master scalar; the font reads the
|
|
117
|
+
`--control-text` register (`calc(--type-small * --ui-scale)`, the same
|
|
118
|
+
`text-sm` register the Button CVA paints), so a bare `.btn-pill` consumer
|
|
119
|
+
and a `<Button>` agree on the control font, and ONE `--ui-scale` override
|
|
120
|
+
grows the pill's height (via padding) + gap + font in lockstep. Desktop
|
|
121
|
+
default is the identity (scale 1 → the prior proportion). */
|
|
122
|
+
gap: calc(0.375rem * var(--ui-scale));
|
|
123
|
+
border-radius: var(--radius-pill);
|
|
124
|
+
padding: calc(0.5rem * var(--ui-scale)) calc(1rem * var(--ui-scale));
|
|
125
|
+
font-size: var(--control-text);
|
|
126
|
+
/* AX.W52 — the ONE coherent button transition (RED witness 5/6). The
|
|
127
|
+
SURFACE legs (bg/border/box-shadow/color/opacity) ride the bezier
|
|
128
|
+
`--ease-standard` (a colour cross-fade reads as a wobble on a spring);
|
|
129
|
+
the TRANSFORM leg (`scale`) rides `--spring-smooth` (the sub-perceptual
|
|
130
|
+
settle), so the hover lift + the surface cross-fade read as ONE glide.
|
|
131
|
+
The DEAD `transform` leg is retired — the variants animate the `scale`
|
|
132
|
+
longhand. CRITICAL: `.tap-squish` (composed alongside on the button
|
|
133
|
+
base, utilities.css) ALSO lists this full coherent set, so neither
|
|
134
|
+
class's `transition` shorthand can clobber the other down to a
|
|
135
|
+
scale-only animation — the cascade bug that left every button
|
|
136
|
+
transitioning ONLY `scale` (the live-readback RED, RED witness 5). The
|
|
137
|
+
doctrine: surface-props→bezier, transform→spring (tokens.css §2). */
|
|
138
|
+
transition:
|
|
139
|
+
background-color var(--duration-fast) var(--ease-standard),
|
|
140
|
+
border-color var(--duration-fast) var(--ease-standard),
|
|
141
|
+
box-shadow var(--duration-fast) var(--ease-standard),
|
|
142
|
+
color var(--duration-fast) var(--ease-standard),
|
|
143
|
+
opacity var(--duration-fast) var(--ease-standard),
|
|
144
|
+
scale var(--duration-fast) var(--spring-smooth);
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
.btn-pill > * {
|
|
148
|
+
@apply flex-shrink-0;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
|
|
152
|
+
.btn-pill:disabled {
|
|
153
|
+
opacity: var(--opacity-disabled);
|
|
154
|
+
cursor: not-allowed;
|
|
155
|
+
pointer-events: none;
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
/* ── Glass-button backdrop ─────────────────────────────────────────────
|
|
159
|
+
AX.W52 — the `glass`/`glass-wash` Button variants compose `.glass-wash`,
|
|
160
|
+
which resolves `--glass-blur-wash` = `blur(1px)` — a sub-perceptual
|
|
161
|
+
diffusion authored for a small detail TILE, not a button the user reads
|
|
162
|
+
as "glass" (the live readback found the glass variants at a negligible
|
|
163
|
+
1px). A hero control wants a real glass blur. `.btn-glass` re-points the
|
|
164
|
+
backdrop at `--glass-blur-btn` (the `quiet`-tier 10px radius + the gentle
|
|
165
|
+
`saturate(1.05) brightness(1.02)` light-concentration), so the glass
|
|
166
|
+
button variants actually read as liquid glass while the wash TILE tier
|
|
167
|
+
keeps its 1px untouched. Declares the UNPREFIXED `backdrop-filter` ONLY —
|
|
168
|
+
Lightning CSS emits the `-webkit-` companion per the single-source
|
|
169
|
+
authorship discipline above (hand-authoring both forms makes Lightning
|
|
170
|
+
dedup-and-keep-prefixed, which modern Chromium then drops). */
|
|
171
|
+
.btn-glass {
|
|
172
|
+
backdrop-filter: var(--glass-blur-btn);
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
/* ── Pill input ───────────────────────────────── */
|
|
176
|
+
.input-pill {
|
|
177
|
+
@apply flex w-full;
|
|
178
|
+
|
|
179
|
+
/* AX.W51 D18 — the input pill rides the ONE `--ui-scale` comfort axis: the
|
|
180
|
+
height reads the `--control-h-md` cohort (`max(calc(2.5rem * --ui-scale),
|
|
181
|
+
--control-floor)`, the h-10 register with the WCAG-44px coarse clamp), the
|
|
182
|
+
font reads `--control-text`, the inline padding scales — so ONE override
|
|
183
|
+
grows the field's height + padding + font in lockstep. Desktop default is
|
|
184
|
+
the identity. */
|
|
185
|
+
height: var(--control-h-md);
|
|
186
|
+
border-radius: var(--radius-pill);
|
|
187
|
+
/* AW.W13 — the resting field edge reads as an enclosed control at rest
|
|
188
|
+
(~15%α — ~2× the prior 8% glass-wash floor that vanished on cream). The
|
|
189
|
+
`:focus-visible` accent ring + the `:user-invalid`/`[aria-invalid]`
|
|
190
|
+
destructive ring below still win by order + specificity.
|
|
191
|
+
AX.W54 — moved off the srgb `--surface-tint-15` fork onto the glass
|
|
192
|
+
border seam (`--glass-border-floating`, the matching 15%α rung) so the
|
|
193
|
+
pill is ONE glass model with the rest of the ladder, not a divergent
|
|
194
|
+
tint axis. */
|
|
195
|
+
border: 1.5px solid var(--glass-border-floating);
|
|
196
|
+
background: var(--glass-bg-quiet);
|
|
197
|
+
/* AX.W54 — the pill reads as REAL glass: the quiet-tier 10px blur (the
|
|
198
|
+
same `--glass-blur-quiet` its `--glass-bg-quiet` background pairs with),
|
|
199
|
+
not the sub-perceptual `blur(1px)` wash it carried — and the
|
|
200
|
+
`--glass-level` knob now clarifies it in lockstep with every surface. */
|
|
201
|
+
backdrop-filter: var(--glass-blur-quiet);
|
|
202
|
+
padding: 0 calc(1rem * var(--ui-scale));
|
|
203
|
+
font-size: var(--control-text);
|
|
204
|
+
color: var(--foreground);
|
|
205
|
+
transition:
|
|
206
|
+
background-color var(--duration-fast) var(--ease-standard),
|
|
207
|
+
border-color var(--duration-fast) var(--ease-standard),
|
|
208
|
+
box-shadow var(--duration-fast) var(--ease-standard),
|
|
209
|
+
color var(--duration-fast) var(--ease-standard),
|
|
210
|
+
opacity var(--duration-fast) var(--ease-standard);
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
.input-pill::placeholder {
|
|
214
|
+
color: var(--surface-tint-35);
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
/* AQ.W4 §W4.6 — keyboard-focus ring only. Was bare `:focus` (showed the
|
|
218
|
+
accent ring on a mouse click); `:focus-visible` matches the
|
|
219
|
+
`.focus-ring` / `.glass-btn` / dock-control discipline. Ordered BEFORE
|
|
220
|
+
the `:user-invalid` rungs so an invalid focused field shows destructive,
|
|
221
|
+
not accent (the `:user-invalid:focus-visible` rule below wins by order +
|
|
222
|
+
specificity). `:focus-visible` Baseline Widely — no fallback. */
|
|
223
|
+
.input-pill:focus-visible {
|
|
224
|
+
outline: none;
|
|
225
|
+
border-color: var(--color-accent-opaque, var(--ring));
|
|
226
|
+
box-shadow: 0 0 0 2px var(--color-accent, color-mix(in srgb, var(--ring) 30%, transparent));
|
|
227
|
+
}
|
|
228
|
+
|
|
229
|
+
/* AQ.W4 §W4.1 — validity vocabulary on `.input-pill` (Input + Textarea).
|
|
230
|
+
The forgiving `:where(:user-invalid, .user-invalid-fallback,
|
|
231
|
+
[aria-invalid="true"])` group is ONE rule covering THREE trigger surfaces:
|
|
232
|
+
native constraint-validation (`:user-invalid`), the `useUserInvalidAria`
|
|
233
|
+
fallback class for engines without `:user-invalid` (css §3.2; NOT a
|
|
234
|
+
live+dead alias — the class is the SOLE fallback), AND (AW.W18) the
|
|
235
|
+
imperative `[aria-invalid="true"]` attribute. The `[aria-invalid]` arm
|
|
236
|
+
serves APP-DRIVEN validity — a custom key match, an async server check —
|
|
237
|
+
where there is no native constraint to trip `:user-invalid`, so the app
|
|
238
|
+
sets the ARIA attribute and the library's own ring paints with no
|
|
239
|
+
`:deep()` re-paint at the consumer. The destructive/success tints reuse
|
|
240
|
+
the semantic tokens via `color-mix` per the house pattern (W2). Non-color
|
|
241
|
+
reinforcement is the error TEXT (W4.5 `error` slot) + the `required`
|
|
242
|
+
asterisk — the border/bg shift is the supplementary cue, never the sole
|
|
243
|
+
one. `:user-valid` is intentionally subtle (border only, no bg fill) so
|
|
244
|
+
a long valid form is not a wall of green. */
|
|
245
|
+
.input-pill:where(:user-invalid, .user-invalid-fallback, [aria-invalid="true"]) {
|
|
246
|
+
border-color: var(--destructive);
|
|
247
|
+
background: color-mix(in srgb, var(--destructive) 8%, var(--glass-bg-quiet));
|
|
248
|
+
}
|
|
249
|
+
.input-pill:where(:user-valid, .user-valid-fallback) {
|
|
250
|
+
border-color: var(--success);
|
|
251
|
+
}
|
|
252
|
+
/* Invalid + keyboard-focused → destructive ring (overrides the accent
|
|
253
|
+
`:focus-visible` ring above by order + the extra invalid compound). The
|
|
254
|
+
`[aria-invalid]` arm rides the same widened group so an app-driven
|
|
255
|
+
invalid field shows the destructive ring on focus too. */
|
|
256
|
+
.input-pill:where(:user-invalid, .user-invalid-fallback, [aria-invalid="true"]):focus-visible {
|
|
257
|
+
border-color: var(--destructive);
|
|
258
|
+
box-shadow: 0 0 0 var(--focus-ring-width)
|
|
259
|
+
color-mix(in srgb, var(--destructive) 35%, transparent);
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
/* AQ.W4 §W4.3 — `field-sizing: content` autosize (opt-in via the Textarea
|
|
263
|
+
`autosize` prop → `[data-autosize]`). The textarea grows vertically with
|
|
264
|
+
content between a 3-line floor and a token-driven ceiling, then scrolls.
|
|
265
|
+
`field-sizing` Baseline Newly (Chromium 2024) — on a non-supporting
|
|
266
|
+
engine the declaration is ignored and the element keeps the
|
|
267
|
+
`min/max-block-size` bounds + standard scroll (no JS, no `@supports`,
|
|
268
|
+
no grid-mirror polyfill). The fixed-size path (default, `min-h-20`) is
|
|
269
|
+
the unchanged no-op fallback. */
|
|
270
|
+
.input-pill[data-autosize] {
|
|
271
|
+
field-sizing: content;
|
|
272
|
+
width: 100%;
|
|
273
|
+
min-block-size: 3lh;
|
|
274
|
+
max-block-size: var(--textarea-autosize-max, 12lh);
|
|
275
|
+
resize: vertical;
|
|
276
|
+
}
|
|
277
|
+
|
|
278
|
+
.input-pill:disabled {
|
|
279
|
+
opacity: 0.5;
|
|
280
|
+
cursor: not-allowed;
|
|
281
|
+
}
|
|
282
|
+
|
|
283
|
+
/* AW.W13 — the Select trigger mirrors the input pill's resting border lift.
|
|
284
|
+
The reka-ui SelectTrigger renders `role="combobox"` over the `.glass-wash`
|
|
285
|
+
surface; its 8%α `--glass-border-wash` field edge vanished on cream just
|
|
286
|
+
like the input pill, so the same `--surface-tint-15` lift makes the
|
|
287
|
+
trigger read as an enclosed control at rest. Scoped to the combobox role
|
|
288
|
+
so the lift reaches ONLY the Select trigger, not every `.glass-wash`
|
|
289
|
+
surface. */
|
|
290
|
+
.glass-wash[role="combobox"] {
|
|
291
|
+
border-color: var(--surface-tint-15);
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
/* ── AW.W23 — chromatic edge dispersion (the polished-glass rim fringe) ──
|
|
295
|
+
An opt-in `.glass-chromatic` composes the warm/cool oklab fringe OVER the
|
|
296
|
+
W22 uniform rim (it does NOT replace it — the rim still rides each rung's
|
|
297
|
+
box-shadow). The fringe is a transparency garnish, so it composes ONLY
|
|
298
|
+
under `prefers-reduced-transparency: no-preference` and drops under
|
|
299
|
+
`reduce` (handled by the bracket below). The fringe lands as a dedicated
|
|
300
|
+
inset box-shadow pair on the material surface so it adds onto the rim. */
|
|
301
|
+
@media (prefers-reduced-transparency: no-preference) {
|
|
302
|
+
.glass-chromatic {
|
|
303
|
+
box-shadow: var(--glass-edge-dispersion), var(--glass-material-rim);
|
|
304
|
+
}
|
|
305
|
+
}
|
|
306
|
+
}
|