@argobox/glass-ui
v0.1.0
Published
A premium glassmorphic design system for Astro sites with cosmic effects, animations, and themeable components
Maintainers
Readme
@argobox/glass-ui
A premium glassmorphic design system for Astro with cosmic effects, sci-fi animations, and fully themeable components.
Zero JavaScript. Pure CSS. Drop it into any Astro site.
What You Get
- 5 glass tiers — light, standard, heavy, solid, premium (with glow effects)
- 97 design tokens — colors, blur levels, transitions, fonts — all overridable via CSS custom properties
- Full component set — cards, buttons, inputs, tabs, status indicators, heroes, stats, grids
- Sci-fi animations — glitch text, HUD scan lines, holographic shimmer, neon flicker, data streams, typing effects
- Cosmic backgrounds — Starfield and Nebula Astro components with configurable colors
- Accessibility —
prefers-reduced-motion,focus-visible, 44px touch targets,backdrop-filterfallbacks - 4 bundled fonts — Inter, Orbitron, Space Grotesk, JetBrains Mono (woff2)
Install
npm install @argobox/glass-uiQuick Start
---
// src/layouts/Layout.astro
import '@argobox/glass-ui/styles/theme-base.css'
import '@argobox/glass-ui/styles/glass-morphism.css'
import '@argobox/glass-ui/styles/animations.css'
import Starfield from '@argobox/glass-ui/components/effects/Starfield.astro'
---
<html>
<body>
<Starfield />
<div class="glass-hero">
<h1 class="glass-hero-title">My Dashboard</h1>
<p class="glass-hero-subtitle">Built with glass-ui</p>
</div>
<div class="glass-grid glass-grid-3">
<div class="glass-card glass-glow">
<div class="glass-status online">
<span class="glass-status-dot"></span>
Online
</div>
<h3>Server Alpha</h3>
</div>
</div>
</body>
</html>Glass Variants
<div class="glass">Standard glass panel</div>
<div class="glass-light">Subtle, lightweight</div>
<div class="glass-heavy">More opacity, stronger blur</div>
<div class="glass-solid">Near-opaque, maximum blur</div>
<div class="glass-premium">Gradient background + accent glow</div>Animations
<span class="glitch-text" data-text="SYSTEM ONLINE">SYSTEM ONLINE</span>
<div class="hud-scan">Scanning...</div>
<div class="holo-badge">Holographic</div>
<span class="neon-text">Neon Glow</span>
<span class="typing-effect">Hello, world...</span>Theming
Override any token in your site's CSS:
:root {
--gui-accent-primary: #10b981; /* Change accent to green */
--gui-accent-primary-rgb: 16, 185, 129;
--gui-bg-void: #0a0a0a; /* Darker background */
--gui-glass-blur: 24px; /* More blur */
--gui-font-display: 'Rajdhani', sans-serif; /* Different display font */
}Components
| Component | Import |
|-----------|--------|
| Starfield | @argobox/glass-ui/components/effects/Starfield.astro |
| Nebula | @argobox/glass-ui/components/effects/Nebula.astro |
| GlassCard | @argobox/glass-ui/components/ui/GlassCard.astro |
| ScrollProgress | @argobox/glass-ui/components/layout/ScrollProgress.astro |
| SEO | @argobox/glass-ui/components/SEO.astro |
CSS-Only Usage (Any Framework)
The styles work without Astro. In React, Vue, Svelte, or plain HTML:
import '@argobox/glass-ui/styles/theme-base.css'
import '@argobox/glass-ui/styles/glass-morphism.css'Then use the CSS classes directly. The Astro components are a convenience, not a requirement.
License
MIT
