Glass
glasswave/glassFreeUtility
Glassmorphism class-string utilities and the glass surface CSS.
Live preview
live · rendered by the registry
Rendered by glasswave on their own page — this is the component running, not a screenshot of it.Install it
npx shadcn@latest add https://glasswave.denizisik.com/r/glass.jsonSource
1export const glassBase =2 "backdrop-blur-2xl backdrop-saturate-150 bg-gradient-to-br from-white/[0.10] via-white/[0.06] to-white/[0.02] dark:from-white/[0.14] dark:via-white/[0.09] dark:to-white/[0.04] border border-white/[0.10] dark:border-white/[0.12] shadow-[inset_0_1px_0_0_rgba(255,255,255,0.20),inset_0_0_24px_0_rgba(255,255,255,0.04),0_8px_32px_0_rgba(0,0,0,0.12)] dark:shadow-[inset_0_1px_0_0_rgba(255,255,255,0.15),inset_0_0_24px_0_rgba(255,255,255,0.03),0_8px_32px_0_rgba(0,0,0,0.35)]";34export const glassInteractive =5 "transition duration-300 ease-out hover:from-white/[0.15] hover:via-white/[0.10] hover:to-white/[0.05] dark:hover:from-white/[0.20] dark:hover:via-white/[0.14] dark:hover:to-white/[0.08] hover:border-white/[0.18] dark:hover:border-white/[0.22] hover:shadow-[inset_0_1px_0_0_rgba(255,255,255,0.30),inset_0_0_32px_0_rgba(255,255,255,0.06),0_12px_40px_0_rgba(0,0,0,0.16)] dark:hover:shadow-[inset_0_1px_0_0_rgba(255,255,255,0.25),inset_0_0_32px_0_rgba(255,255,255,0.05),0_12px_40px_0_rgba(0,0,0,0.45)] hover:scale-[1.01] active:scale-[0.99] disabled:opacity-40 disabled:cursor-not-allowed disabled:hover:scale-100";67export const rounded = "rounded-[32px]";89export const textOnGlass = "text-gray-900/90 dark:text-white/95 font-medium";1011export const focusRing =12 "focus:outline-none focus-visible:ring-[3px] focus-visible:ring-blue-500/40 dark:focus-visible:ring-blue-400/50 focus-visible:ring-offset-2 focus-visible:ring-offset-transparent";1314// Gradient 1px edge (lit from the top) — defined in packages/index.css15export const glassEdge = "glass-edge";1617// Subtle film grain over the surface — defined in packages/index.css18export const glassNoise = "glass-noise";1920export const glass = `${glassBase} ${glassEdge} ${glassNoise} ${rounded} ${textOnGlass} relative overflow-hidden`;
Files it writes
More from glasswave
All 60 items| Component | Registry | Kind | Access | Installs | Command |
|---|---|---|---|---|---|
| Menu Classesmenu-classes | glasswave | Utilities | Free | no deps |
