AstroGlass follows a standard Astro project structure with a few key organizational patterns.
Key Directories
src/components/pages/
Contains full-page components for dynamic routes, such as the Portfolio Page. Organized by page type:
pages/βββ portfolio/β βββ aurora/β β βββ PortfolioHeroAurora.astroβ β βββ ...β βββ liquid/β β βββ PortfolioHeroLiquid.astroβ β βββ PortfolioGridLiquid.astroβ β βββ PortfolioModalLiquid.astroβ β βββ PortfolioCTALiquid.astroβ β βββ ...β βββ ...src/components/sections/
Contains all page section components, organized by section type. Each section has a subdirectory with one variant per theme:
sections/βββ hero/β βββ HeroLiquid.astroβ βββ HeroGlass.astroβ βββ HeroNeo.astroβ βββ HeroLuxury.astroβ βββ HeroMinimal.astroβ βββ HeroAurora.astroβββ about/βββ features/βββ portfolio/βββ pricing/βββ testimonial/βββ faq/βββ cta/βββ contact/βββ footer/src/components/layout/header/
Theme-specific header/navbar components (e.g., HeaderGlass.astro, HeaderLuxury.astro).
src/components/ui/
Reusable UI primitives: Button, Card, Badge, Avatar, Input, Tabs, Charts, ThemeSwitcher, LanguageSwitcher, and Search.
src/config/
Central configuration files:
themes.tsβ Theme registry (IDs, names, enabled status, section lists)locales.tsβ Supported languages and their metadatanavigation.tsβ Main site navigation structuredocs.tsβ Documentation sidebar config and version management
src/content/
Astro Content Collections for docs and blog posts. Structure inside docs/[lang]/ determines the URL paths for documentation.
src/locales/
JSON translation files organized by language code. Each file corresponds to a page section (e.g., hero.json, pricing.json, contact.json).
src/pages/
File-based routing. The [theme].astro dynamic route generates pages for each enabled theme. The [...lang] directory patterns handle localized page variants across the entire architecture.
src/styles/
Global CSS, theme overrides (_themes.css), animation keyframes, and component-specific stylesheets in components/.
src/utils/
Utility functions for i18n translations (i18n.ts), locale detection (locale-utils.ts), and documentation navigation (docs-nav.ts).