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).