vibecarbon 0.1.0
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/LICENSE +663 -0
- package/README.md +188 -0
- package/carbon/.claude/hooks/task-completed-gate.sh +19 -0
- package/carbon/.claude/hooks/teammate-idle-gate.sh +29 -0
- package/carbon/.claude/settings.json +29 -0
- package/carbon/.cursor/rules/vibecarbon.mdc +6 -0
- package/carbon/.dockerignore +57 -0
- package/carbon/.env.example +219 -0
- package/carbon/.github/copilot-instructions.md +3 -0
- package/carbon/.github/workflows/deploy.yml +346 -0
- package/carbon/.github/workflows/vibecarbon-build.yml +81 -0
- package/carbon/.windsurfrules +74 -0
- package/carbon/AGENTS.md +422 -0
- package/carbon/CLAUDE.md +3 -0
- package/carbon/DEVELOPMENT.md +187 -0
- package/carbon/Dockerfile +98 -0
- package/carbon/LICENSE +21 -0
- package/carbon/PRODUCTION.md +364 -0
- package/carbon/README.md +193 -0
- package/carbon/TESTING.md +138 -0
- package/carbon/backup/Dockerfile +75 -0
- package/carbon/backup/backup.sh +95 -0
- package/carbon/backup/compose-backup.sh +140 -0
- package/carbon/biome.json +83 -0
- package/carbon/cloud-init/docker-ce-setup.yaml +55 -0
- package/carbon/cloud-init/k3s/master-init.sh +215 -0
- package/carbon/cloud-init/k3s/supabase-init.sh +167 -0
- package/carbon/cloud-init/k3s/worker-init.sh +147 -0
- package/carbon/components.json +24 -0
- package/carbon/content/blog/authentication-guide.mdx +34 -0
- package/carbon/content/blog/getting-started.mdx +41 -0
- package/carbon/content/changelog/v0-1-0.mdx +40 -0
- package/carbon/content/docs/analytics.mdx +90 -0
- package/carbon/content/docs/authentication.mdx +231 -0
- package/carbon/content/docs/background-jobs.mdx +116 -0
- package/carbon/content/docs/cli.mdx +630 -0
- package/carbon/content/docs/database.mdx +236 -0
- package/carbon/content/docs/deployment.mdx +227 -0
- package/carbon/content/docs/development.mdx +238 -0
- package/carbon/content/docs/environments.mdx +84 -0
- package/carbon/content/docs/getting-started.mdx +112 -0
- package/carbon/content/docs/legal/privacy-policy.mdx +89 -0
- package/carbon/content/docs/legal/terms-of-service.mdx +99 -0
- package/carbon/content/docs/optional-services.mdx +160 -0
- package/carbon/db/Dockerfile +23 -0
- package/carbon/docker-compose.dev-init.yml +5 -0
- package/carbon/docker-compose.metabase.override.yml +14 -0
- package/carbon/docker-compose.metabase.prod.yml +28 -0
- package/carbon/docker-compose.metabase.yml +84 -0
- package/carbon/docker-compose.n8n.override.yml +14 -0
- package/carbon/docker-compose.n8n.prod.yml +31 -0
- package/carbon/docker-compose.n8n.yml +97 -0
- package/carbon/docker-compose.observability.override.yml +18 -0
- package/carbon/docker-compose.observability.prod.yml +28 -0
- package/carbon/docker-compose.observability.yml +125 -0
- package/carbon/docker-compose.override.yml +28 -0
- package/carbon/docker-compose.prod.yml +294 -0
- package/carbon/docker-compose.yml +508 -0
- package/carbon/docker-entrypoint.sh +12 -0
- package/carbon/ha/activate-standby.sh +52 -0
- package/carbon/ha/primary-init.sql +36 -0
- package/carbon/ha/standby-init.sh +74 -0
- package/carbon/k8s/LICENSE +99 -0
- package/carbon/k8s/README.md +272 -0
- package/carbon/k8s/base/app/deployment.yaml +130 -0
- package/carbon/k8s/base/app/hpa.yaml +44 -0
- package/carbon/k8s/base/app/kustomization.yaml +10 -0
- package/carbon/k8s/base/app/network-policy.yaml +124 -0
- package/carbon/k8s/base/app/pdb.yaml +14 -0
- package/carbon/k8s/base/app/rbac.yaml +36 -0
- package/carbon/k8s/base/app/service.yaml +16 -0
- package/carbon/k8s/base/backup/cronjob.yaml +120 -0
- package/carbon/k8s/base/backup/kustomization.yaml +7 -0
- package/carbon/k8s/base/backup/network-policy.yaml +31 -0
- package/carbon/k8s/base/backup/rbac.yaml +7 -0
- package/carbon/k8s/base/cluster-autoscaler/deployment.yaml +103 -0
- package/carbon/k8s/base/cluster-autoscaler/kustomization.yaml +17 -0
- package/carbon/k8s/base/cluster-autoscaler/rbac.yaml +109 -0
- package/carbon/k8s/base/config/configmap.yaml +48 -0
- package/carbon/k8s/base/config/kustomization.yaml +8 -0
- package/carbon/k8s/base/hetzner-ccm/kustomization.yaml +9 -0
- package/carbon/k8s/base/hetzner-csi/kustomization.yaml +9 -0
- package/carbon/k8s/base/kustomization.yaml +43 -0
- package/carbon/k8s/base/namespace.yaml +7 -0
- package/carbon/k8s/base/network-policies.yaml +95 -0
- package/carbon/k8s/base/registry/kustomization.yaml +5 -0
- package/carbon/k8s/base/registry/local-registry.yaml +193 -0
- package/carbon/k8s/base/traefik/certificate.yaml +21 -0
- package/carbon/k8s/base/traefik/configmap.yaml +13 -0
- package/carbon/k8s/base/traefik/deployment.yaml +165 -0
- package/carbon/k8s/base/traefik/ingressroute.yaml +141 -0
- package/carbon/k8s/base/traefik/kustomization.yaml +11 -0
- package/carbon/k8s/base/traefik/middleware.yaml +109 -0
- package/carbon/k8s/base/traefik/network-policy.yaml +92 -0
- package/carbon/k8s/base/traefik/service.yaml +38 -0
- package/carbon/k8s/flux/README.md +49 -0
- package/carbon/k8s/flux/clusters/primary/vibecarbon.yaml +128 -0
- package/carbon/k8s/flux/clusters/standby/vibecarbon.yaml +83 -0
- package/carbon/k8s/gitops/cert-manager-webhook-hetzner/helm-release.yaml +38 -0
- package/carbon/k8s/gitops/cert-manager-webhook-hetzner/helm-repository.yaml +16 -0
- package/carbon/k8s/gitops/cert-manager-webhook-hetzner/kustomization.yaml +10 -0
- package/carbon/k8s/gitops/supabase/helm-release.yaml +66 -0
- package/carbon/k8s/gitops/supabase/helm-repository.yaml +18 -0
- package/carbon/k8s/gitops/supabase/kustomization.yaml +33 -0
- package/carbon/k8s/infra/cert-manager-resources/cluster-issuers-cloudflare.yaml +51 -0
- package/carbon/k8s/infra/cert-manager-resources/cluster-issuers-hetzner.yaml +59 -0
- package/carbon/k8s/infra/cert-manager-resources/cluster-issuers-manual.yaml +43 -0
- package/carbon/k8s/infra/cert-manager-resources/kustomization.yaml +15 -0
- package/carbon/k8s/infra/kustomization.yaml +21 -0
- package/carbon/k8s/infra/traefik-crds/kustomization.yaml +10 -0
- package/carbon/k8s/overlays/local/configmap.yaml +23 -0
- package/carbon/k8s/overlays/local/ingressroute-studio.yaml +104 -0
- package/carbon/k8s/overlays/local/kustomization.yaml +215 -0
- package/carbon/k8s/overlays/local/namespace.yaml +8 -0
- package/carbon/k8s/overlays/local/secrets.yaml +32 -0
- package/carbon/k8s/overlays/production/kustomization.yaml +34 -0
- package/carbon/k8s/test-local.sh +318 -0
- package/carbon/k8s/values/supabase.values.yaml +133 -0
- package/carbon/package.json +154 -0
- package/carbon/runtime.Dockerfile +17 -0
- package/carbon/scripts/_dev-jwt.mjs +45 -0
- package/carbon/scripts/check-rls.ts +53 -0
- package/carbon/scripts/dev-init.js +191 -0
- package/carbon/scripts/dev.js +191 -0
- package/carbon/scripts/docker-down.js +63 -0
- package/carbon/scripts/docker-logs.js +59 -0
- package/carbon/scripts/docker-up.js +222 -0
- package/carbon/scripts/generate-dev-configs.sh +131 -0
- package/carbon/scripts/generate-rss.ts +116 -0
- package/carbon/scripts/generate-sitemap.ts +102 -0
- package/carbon/scripts/k8s-apply.js +71 -0
- package/carbon/scripts/k8s-delete.js +75 -0
- package/carbon/scripts/lib/manifest.js +176 -0
- package/carbon/scripts/secret-scan.mjs +278 -0
- package/carbon/scripts/validate-dev-configs.sh +101 -0
- package/carbon/src/client/App.tsx +202 -0
- package/carbon/src/client/assets/hyperformant-dark.svg +29 -0
- package/carbon/src/client/assets/hyperformant-light.svg +29 -0
- package/carbon/src/client/assets/logos/aider.svg +1 -0
- package/carbon/src/client/assets/logos/antigravity.svg +1 -0
- package/carbon/src/client/assets/logos/bolt.svg +1 -0
- package/carbon/src/client/assets/logos/claude-code.svg +1 -0
- package/carbon/src/client/assets/logos/copilot.svg +1 -0
- package/carbon/src/client/assets/logos/cursor.svg +1 -0
- package/carbon/src/client/assets/logos/gemini-cli.svg +1 -0
- package/carbon/src/client/assets/logos/lovable.svg +1 -0
- package/carbon/src/client/assets/logos/openai-codex.svg +1 -0
- package/carbon/src/client/assets/logos/v0.svg +1 -0
- package/carbon/src/client/assets/logos/windsurf.svg +1 -0
- package/carbon/src/client/assets/vibecarbon-icon.svg +19 -0
- package/carbon/src/client/assets/vibecarbon-logo-dark.svg +29 -0
- package/carbon/src/client/assets/vibecarbon-logo-light.svg +29 -0
- package/carbon/src/client/components/AIIntegrationSection.tsx +120 -0
- package/carbon/src/client/components/AppSidebar.tsx +760 -0
- package/carbon/src/client/components/ArchitectureSection.tsx +46 -0
- package/carbon/src/client/components/CTAFooter.tsx +59 -0
- package/carbon/src/client/components/ComparisonSection.tsx +132 -0
- package/carbon/src/client/components/ContentPanel.tsx +66 -0
- package/carbon/src/client/components/ContentSkeleton.tsx +21 -0
- package/carbon/src/client/components/ErrorBoundary.tsx +46 -0
- package/carbon/src/client/components/FAQSection.tsx +76 -0
- package/carbon/src/client/components/FileUpload.tsx +210 -0
- package/carbon/src/client/components/HeaderActions.tsx +17 -0
- package/carbon/src/client/components/Hero.tsx +608 -0
- package/carbon/src/client/components/ImpersonationBanner.tsx +31 -0
- package/carbon/src/client/components/LanguageSwitcher.tsx +67 -0
- package/carbon/src/client/components/Logo.tsx +87 -0
- package/carbon/src/client/components/LogoStrip.tsx +76 -0
- package/carbon/src/client/components/MetricsStrip.tsx +48 -0
- package/carbon/src/client/components/Nav.tsx +195 -0
- package/carbon/src/client/components/NewsletterSignup.tsx +147 -0
- package/carbon/src/client/components/NotificationDrawer.tsx +171 -0
- package/carbon/src/client/components/PageHeader.tsx +24 -0
- package/carbon/src/client/components/PlanGate.tsx +36 -0
- package/carbon/src/client/components/PricingSection.tsx +371 -0
- package/carbon/src/client/components/SEO.tsx +34 -0
- package/carbon/src/client/components/SmoothScroll.tsx +45 -0
- package/carbon/src/client/components/TechStackSection.tsx +165 -0
- package/carbon/src/client/components/WorkflowSection.tsx +604 -0
- package/carbon/src/client/components/admin/DockerLogs.tsx +276 -0
- package/carbon/src/client/components/admin/PerformanceMetrics.tsx +230 -0
- package/carbon/src/client/components/admin/ServiceCard.tsx +45 -0
- package/carbon/src/client/components/admin/ServicesStatus.tsx +296 -0
- package/carbon/src/client/components/architecture/ArchitectureDiagram.tsx +413 -0
- package/carbon/src/client/components/auth/AuthProvider.tsx +466 -0
- package/carbon/src/client/components/effects/FilmGrainOverlay.tsx +35 -0
- package/carbon/src/client/components/effects/FresnelEdge.tsx +49 -0
- package/carbon/src/client/components/effects/GlowTracker.tsx +46 -0
- package/carbon/src/client/components/effects/SparkBurst.tsx +145 -0
- package/carbon/src/client/components/effects/VGlowEffect.tsx +83 -0
- package/carbon/src/client/components/effects/index.ts +2 -0
- package/carbon/src/client/components/layouts/SidebarLayout.tsx +20 -0
- package/carbon/src/client/components/scroll/ScrollSection.tsx +76 -0
- package/carbon/src/client/components/scroll/ScrollytellingProvider.tsx +81 -0
- package/carbon/src/client/components/scroll/index.ts +2 -0
- package/carbon/src/client/components/ui/accordion.tsx +71 -0
- package/carbon/src/client/components/ui/alert-dialog.tsx +162 -0
- package/carbon/src/client/components/ui/alert.tsx +73 -0
- package/carbon/src/client/components/ui/aspect-ratio.tsx +22 -0
- package/carbon/src/client/components/ui/avatar.tsx +91 -0
- package/carbon/src/client/components/ui/badge.tsx +50 -0
- package/carbon/src/client/components/ui/breadcrumb.tsx +100 -0
- package/carbon/src/client/components/ui/button-group.tsx +78 -0
- package/carbon/src/client/components/ui/button.tsx +120 -0
- package/carbon/src/client/components/ui/calendar.tsx +182 -0
- package/carbon/src/client/components/ui/card.tsx +85 -0
- package/carbon/src/client/components/ui/carousel.tsx +227 -0
- package/carbon/src/client/components/ui/chart.tsx +357 -0
- package/carbon/src/client/components/ui/checkbox.tsx +27 -0
- package/carbon/src/client/components/ui/collapsible.tsx +15 -0
- package/carbon/src/client/components/ui/command.tsx +178 -0
- package/carbon/src/client/components/ui/context-menu.tsx +233 -0
- package/carbon/src/client/components/ui/dialog.tsx +132 -0
- package/carbon/src/client/components/ui/drawer.tsx +118 -0
- package/carbon/src/client/components/ui/dropdown-menu.tsx +242 -0
- package/carbon/src/client/components/ui/empty.tsx +94 -0
- package/carbon/src/client/components/ui/field.tsx +226 -0
- package/carbon/src/client/components/ui/hover-card.tsx +44 -0
- package/carbon/src/client/components/ui/input-group.tsx +146 -0
- package/carbon/src/client/components/ui/input-otp.tsx +83 -0
- package/carbon/src/client/components/ui/input.tsx +20 -0
- package/carbon/src/client/components/ui/item.tsx +188 -0
- package/carbon/src/client/components/ui/kbd.tsx +26 -0
- package/carbon/src/client/components/ui/label.tsx +21 -0
- package/carbon/src/client/components/ui/menubar.tsx +250 -0
- package/carbon/src/client/components/ui/navigation-menu.tsx +155 -0
- package/carbon/src/client/components/ui/pagination.tsx +102 -0
- package/carbon/src/client/components/ui/popover.tsx +75 -0
- package/carbon/src/client/components/ui/progress.tsx +66 -0
- package/carbon/src/client/components/ui/radio-group.tsx +36 -0
- package/carbon/src/client/components/ui/resizable.tsx +46 -0
- package/carbon/src/client/components/ui/scroll-area.tsx +48 -0
- package/carbon/src/client/components/ui/select.tsx +186 -0
- package/carbon/src/client/components/ui/separator.tsx +21 -0
- package/carbon/src/client/components/ui/sheet.tsx +124 -0
- package/carbon/src/client/components/ui/sidebar.tsx +702 -0
- package/carbon/src/client/components/ui/skeleton.tsx +13 -0
- package/carbon/src/client/components/ui/slider.tsx +57 -0
- package/carbon/src/client/components/ui/sonner.tsx +45 -0
- package/carbon/src/client/components/ui/spinner.tsx +15 -0
- package/carbon/src/client/components/ui/switch.tsx +30 -0
- package/carbon/src/client/components/ui/table.tsx +89 -0
- package/carbon/src/client/components/ui/tabs.tsx +73 -0
- package/carbon/src/client/components/ui/textarea.tsx +18 -0
- package/carbon/src/client/components/ui/toggle-group.tsx +87 -0
- package/carbon/src/client/components/ui/toggle.tsx +44 -0
- package/carbon/src/client/components/ui/tooltip.tsx +56 -0
- package/carbon/src/client/hooks/api/index.ts +14 -0
- package/carbon/src/client/hooks/api/useAuthSettings.ts +80 -0
- package/carbon/src/client/hooks/api/useSubscription.ts +87 -0
- package/carbon/src/client/hooks/use-mobile.ts +21 -0
- package/carbon/src/client/hooks/useMousePosition.ts +91 -0
- package/carbon/src/client/hooks/useNotifications.tsx +124 -0
- package/carbon/src/client/hooks/useOrganizationMembers.ts +127 -0
- package/carbon/src/client/hooks/useOrganizations.tsx +230 -0
- package/carbon/src/client/hooks/usePackageManager.ts +69 -0
- package/carbon/src/client/hooks/useReducedMotion.ts +20 -0
- package/carbon/src/client/hooks/useRunningServices.ts +114 -0
- package/carbon/src/client/hooks/useScrollProgress.ts +56 -0
- package/carbon/src/client/index.css +467 -0
- package/carbon/src/client/index.html +56 -0
- package/carbon/src/client/lib/admin-services.ts +151 -0
- package/carbon/src/client/lib/api.ts +32 -0
- package/carbon/src/client/lib/blog.ts +35 -0
- package/carbon/src/client/lib/changelog.ts +33 -0
- package/carbon/src/client/lib/docs-search.ts +101 -0
- package/carbon/src/client/lib/docs.ts +37 -0
- package/carbon/src/client/lib/i18n.ts +32 -0
- package/carbon/src/client/lib/supabase.ts +72 -0
- package/carbon/src/client/lib/tailwind-colors.ts +357 -0
- package/carbon/src/client/lib/theme.ts +117 -0
- package/carbon/src/client/lib/utils.ts +22 -0
- package/carbon/src/client/locales/de.json +529 -0
- package/carbon/src/client/locales/en.json +461 -0
- package/carbon/src/client/locales/es.json +529 -0
- package/carbon/src/client/locales/fr.json +529 -0
- package/carbon/src/client/locales/pt.json +529 -0
- package/carbon/src/client/main.tsx +56 -0
- package/carbon/src/client/mdx.d.ts +13 -0
- package/carbon/src/client/pages/ApiDocs.tsx +76 -0
- package/carbon/src/client/pages/AuthCallback.tsx +34 -0
- package/carbon/src/client/pages/Blog.tsx +167 -0
- package/carbon/src/client/pages/Changelog.tsx +171 -0
- package/carbon/src/client/pages/Charts.tsx +388 -0
- package/carbon/src/client/pages/Checkout.tsx +227 -0
- package/carbon/src/client/pages/Contact.tsx +174 -0
- package/carbon/src/client/pages/Dashboard.tsx +368 -0
- package/carbon/src/client/pages/Docs.tsx +372 -0
- package/carbon/src/client/pages/ForgotPassword.tsx +111 -0
- package/carbon/src/client/pages/Home.tsx +187 -0
- package/carbon/src/client/pages/Legal.tsx +100 -0
- package/carbon/src/client/pages/Login.tsx +408 -0
- package/carbon/src/client/pages/MFAVerify.tsx +156 -0
- package/carbon/src/client/pages/NotFound.tsx +21 -0
- package/carbon/src/client/pages/Onboarding.tsx +246 -0
- package/carbon/src/client/pages/ResetPassword.tsx +200 -0
- package/carbon/src/client/pages/UIComponents.tsx +390 -0
- package/carbon/src/client/pages/admin/ContactSubmissions.tsx +220 -0
- package/carbon/src/client/pages/admin/Dashboard.tsx +24 -0
- package/carbon/src/client/pages/admin/Infrastructure.tsx +257 -0
- package/carbon/src/client/pages/admin/Jobs.tsx +225 -0
- package/carbon/src/client/pages/admin/Logs.tsx +18 -0
- package/carbon/src/client/pages/admin/Newsletter.tsx +300 -0
- package/carbon/src/client/pages/admin/Notifications.tsx +603 -0
- package/carbon/src/client/pages/admin/Organizations.tsx +306 -0
- package/carbon/src/client/pages/admin/Settings.tsx +314 -0
- package/carbon/src/client/pages/admin/Theme.tsx +465 -0
- package/carbon/src/client/pages/admin/Users.tsx +365 -0
- package/carbon/src/client/pages/api-docs.css +156 -0
- package/carbon/src/client/pages/organizations/Details.tsx +200 -0
- package/carbon/src/client/pages/organizations/Members.tsx +402 -0
- package/carbon/src/client/pages/settings/Billing.tsx +473 -0
- package/carbon/src/client/pages/settings/Profile.tsx +160 -0
- package/carbon/src/client/pages/settings/Security.tsx +341 -0
- package/carbon/src/client/public/favicon.svg +19 -0
- package/carbon/src/client/public/robots.txt +8 -0
- package/carbon/src/server/billing/index.ts +104 -0
- package/carbon/src/server/billing/provider.ts +81 -0
- package/carbon/src/server/billing/providers/paddle.ts +314 -0
- package/carbon/src/server/billing/providers/polar.ts +325 -0
- package/carbon/src/server/billing/providers/stripe.ts +233 -0
- package/carbon/src/server/emails/templates.ts +116 -0
- package/carbon/src/server/index.ts +554 -0
- package/carbon/src/server/lib/auth.ts +6 -0
- package/carbon/src/server/lib/email.ts +64 -0
- package/carbon/src/server/lib/env.ts +112 -0
- package/carbon/src/server/lib/errors.ts +21 -0
- package/carbon/src/server/lib/logger.ts +17 -0
- package/carbon/src/server/lib/rate-limiter.ts +288 -0
- package/carbon/src/server/lib/request.ts +34 -0
- package/carbon/src/server/lib/stripe.ts +42 -0
- package/carbon/src/server/lib/supabase.ts +65 -0
- package/carbon/src/server/middleware/requirePlan.ts +80 -0
- package/carbon/src/server/routes/_internal/services-status.ts +958 -0
- package/carbon/src/server/routes/_internal/verify-role.ts +185 -0
- package/carbon/src/server/routes/health.ts +48 -0
- package/carbon/src/server/routes/v1/admin/contact.ts +128 -0
- package/carbon/src/server/routes/v1/admin/jobs.ts +171 -0
- package/carbon/src/server/routes/v1/admin/newsletter.ts +237 -0
- package/carbon/src/server/routes/v1/auth.ts +390 -0
- package/carbon/src/server/routes/v1/billing.ts +718 -0
- package/carbon/src/server/routes/v1/contact.ts +93 -0
- package/carbon/src/server/routes/v1/index.ts +1333 -0
- package/carbon/src/server/routes/v1/newsletter.ts +181 -0
- package/carbon/src/server/routes/v1/performance.ts +157 -0
- package/carbon/src/server/routes/v1/stats.ts +170 -0
- package/carbon/src/server/routes/v1/theme.ts +106 -0
- package/carbon/src/server/routes/webhooks/billing.ts +376 -0
- package/carbon/src/server/routes/webhooks/stripe.ts +276 -0
- package/carbon/src/server/types.ts +11 -0
- package/carbon/src/shared/pricing.ts +155 -0
- package/carbon/src/shared/types.ts +338 -0
- package/carbon/supabase/migrations/00001_init.sql +717 -0
- package/carbon/supabase/migrations/00002_theme_settings.sql +13 -0
- package/carbon/supabase/migrations/00003_pg_cron.sql +121 -0
- package/carbon/supabase/migrations/00004_contact_newsletter.sql +81 -0
- package/carbon/supabase/migrations/00005_localization_languages.sql +22 -0
- package/carbon/supabase/seed.sql +16 -0
- package/carbon/tests/_helpers/app.ts +45 -0
- package/carbon/tests/_helpers/env.ts +37 -0
- package/carbon/tests/_helpers/factories.ts +69 -0
- package/carbon/tests/_helpers/jwt.ts +23 -0
- package/carbon/tests/_helpers/setup-integration.ts +20 -0
- package/carbon/tests/_helpers/setup-rtl.ts +12 -0
- package/carbon/tests/component/ErrorBoundary.test.tsx +53 -0
- package/carbon/tests/component/use-auth-settings.test.tsx +119 -0
- package/carbon/tests/integration/server/routes/contact.test.ts +162 -0
- package/carbon/tests/integration/server/routes/health.test.ts +61 -0
- package/carbon/tests/structural/i18n-parity.test.ts +42 -0
- package/carbon/tests/unit/client/utils.test.ts +49 -0
- package/carbon/tests/unit/shared/pricing.test.ts +93 -0
- package/carbon/tsconfig.json +27 -0
- package/carbon/tsconfig.server.json +27 -0
- package/carbon/tsconfig.test.json +9 -0
- package/carbon/vite.config.ts +110 -0
- package/carbon/vitest.config.ts +74 -0
- package/carbon/volumes/db/jwt.sql +57 -0
- package/carbon/volumes/db/metabase-init.sh +29 -0
- package/carbon/volumes/db/n8n-init.sh +25 -0
- package/carbon/volumes/db/realtime.sql +33 -0
- package/carbon/volumes/db/roles.sql +93 -0
- package/carbon/volumes/db/set-passwords.sh +12 -0
- package/carbon/volumes/db/super-admin.dev.sql +113 -0
- package/carbon/volumes/db/super-admin.generated.sql +113 -0
- package/carbon/volumes/db/super-admin.sql +114 -0
- package/carbon/volumes/grafana/dashboards/logs.json +179 -0
- package/carbon/volumes/grafana/dashboards/overview.json +523 -0
- package/carbon/volumes/grafana/dashboards/postgresql.json +337 -0
- package/carbon/volumes/grafana/dashboards.dev/logs.json +179 -0
- package/carbon/volumes/grafana/dashboards.dev/overview.json +156 -0
- package/carbon/volumes/grafana/dashboards.dev/postgresql.json +337 -0
- package/carbon/volumes/grafana/provisioning/dashboards/dashboards.dev.yml +16 -0
- package/carbon/volumes/grafana/provisioning/dashboards/dashboards.yml +16 -0
- package/carbon/volumes/grafana/provisioning/datasources/datasources.yml +43 -0
- package/carbon/volumes/kong/docker-entrypoint.sh +9 -0
- package/carbon/volumes/kong/kong.yml +208 -0
- package/carbon/volumes/loki/loki-config.yml +58 -0
- package/carbon/volumes/n8n/hooks.js +131 -0
- package/carbon/volumes/n8n/scripts/setup.sh +66 -0
- package/carbon/volumes/prometheus/prometheus.yml +43 -0
- package/carbon/volumes/promtail/promtail-config.yml +64 -0
- package/carbon/volumes/traefik/middlewares.dev.yml +83 -0
- package/carbon/volumes/traefik/middlewares.yml +95 -0
- package/carbon/volumes/traefik/vite-dev.yml +20 -0
- package/package.json +95 -0
- package/src/access.js +354 -0
- package/src/activate.js +187 -0
- package/src/add.js +718 -0
- package/src/backup.js +786 -0
- package/src/cli.js +350 -0
- package/src/configure.js +967 -0
- package/src/console.js +155 -0
- package/src/create.js +1499 -0
- package/src/deploy.js +311 -0
- package/src/destroy.js +2033 -0
- package/src/diagnose.js +735 -0
- package/src/down.js +80 -0
- package/src/failover.js +1032 -0
- package/src/lib/backup-s3.js +179 -0
- package/src/lib/build.js +33 -0
- package/src/lib/checksum.js +28 -0
- package/src/lib/ci-setup.js +666 -0
- package/src/lib/cli/help.js +129 -0
- package/src/lib/cli/parse-flags.js +160 -0
- package/src/lib/cli/select-action.js +65 -0
- package/src/lib/cli/select-environment.js +108 -0
- package/src/lib/cli/tty-guard.js +75 -0
- package/src/lib/cloudflare.js +447 -0
- package/src/lib/colors.js +52 -0
- package/src/lib/command.js +361 -0
- package/src/lib/config.js +359 -0
- package/src/lib/cost.js +103 -0
- package/src/lib/deploy/bundle.js +231 -0
- package/src/lib/deploy/compose/acme-verify.js +121 -0
- package/src/lib/deploy/compose/build-args.js +78 -0
- package/src/lib/deploy/compose/ha.js +1874 -0
- package/src/lib/deploy/compose/index.js +1294 -0
- package/src/lib/deploy/compose/reconcile.js +74 -0
- package/src/lib/deploy/github.js +382 -0
- package/src/lib/deploy/image.js +191 -0
- package/src/lib/deploy/index.js +119 -0
- package/src/lib/deploy/k8s/LICENSE +99 -0
- package/src/lib/deploy/k8s/gitops-deploy.js +298 -0
- package/src/lib/deploy/k8s/ha/index.js +1000 -0
- package/src/lib/deploy/k8s/index.js +62 -0
- package/src/lib/deploy/k8s/k3s.js +2515 -0
- package/src/lib/deploy/orchestrator.js +1401 -0
- package/src/lib/deploy/prompts.js +545 -0
- package/src/lib/deploy/remote-build.js +130 -0
- package/src/lib/deploy/state.js +120 -0
- package/src/lib/deploy/utils.js +328 -0
- package/src/lib/deploy-logger.js +93 -0
- package/src/lib/dns-propagation.js +48 -0
- package/src/lib/environment.js +58 -0
- package/src/lib/fetch-retry.js +103 -0
- package/src/lib/github-environments.js +335 -0
- package/src/lib/hetzner-dns.js +377 -0
- package/src/lib/hetzner-guided-setup.js +275 -0
- package/src/lib/host-keys.js +37 -0
- package/src/lib/iac/cloud-init.js +52 -0
- package/src/lib/iac/index.js +325 -0
- package/src/lib/iac/programs/hetzner-compose.js +130 -0
- package/src/lib/iac/programs/hetzner-k8s.js +320 -0
- package/src/lib/kubectl.js +81 -0
- package/src/lib/licensing/index.js +259 -0
- package/src/lib/licensing/tiers.js +181 -0
- package/src/lib/licensing/validator.js +171 -0
- package/src/lib/merge-package-json.js +90 -0
- package/src/lib/operator-ip.js +381 -0
- package/src/lib/package-manager.js +111 -0
- package/src/lib/perf.js +71 -0
- package/src/lib/project-guard.js +39 -0
- package/src/lib/project.js +334 -0
- package/src/lib/providers/base.js +276 -0
- package/src/lib/providers/hetzner-s3.js +656 -0
- package/src/lib/providers/hetzner.js +755 -0
- package/src/lib/providers/index.js +164 -0
- package/src/lib/s3.js +510 -0
- package/src/lib/secret-scan.js +583 -0
- package/src/lib/secrets.js +63 -0
- package/src/lib/server-types.js +195 -0
- package/src/lib/shell.js +91 -0
- package/src/lib/ssh.js +241 -0
- package/src/lib/tracker.js +242 -0
- package/src/lib/upgrade-policy.js +170 -0
- package/src/lib/validators.js +105 -0
- package/src/lib/version.js +5 -0
- package/src/remove.js +292 -0
- package/src/reset.js +97 -0
- package/src/restore.js +871 -0
- package/src/scale.js +1734 -0
- package/src/shell.js +222 -0
- package/src/status.js +981 -0
- package/src/up.js +264 -0
- package/src/upgrade.js +721 -0
|
@@ -0,0 +1,171 @@
|
|
|
1
|
+
import { AlertCircle, AlertTriangle, CheckCircle2, Info, X } from 'lucide-react';
|
|
2
|
+
import { useEffect, useRef } from 'react';
|
|
3
|
+
import { Button } from '@/components/ui/button';
|
|
4
|
+
import { type NotificationType, useNotifications } from '@/hooks/useNotifications';
|
|
5
|
+
import { cn } from '@/lib/utils';
|
|
6
|
+
|
|
7
|
+
function getNotificationIcon(type: NotificationType) {
|
|
8
|
+
switch (type) {
|
|
9
|
+
case 'error':
|
|
10
|
+
return <AlertCircle className="size-4" />;
|
|
11
|
+
case 'warning':
|
|
12
|
+
return <AlertTriangle className="size-4" />;
|
|
13
|
+
case 'success':
|
|
14
|
+
return <CheckCircle2 className="size-4" />;
|
|
15
|
+
default:
|
|
16
|
+
return <Info className="size-4" />;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
function getNotificationStyles(type: NotificationType) {
|
|
21
|
+
switch (type) {
|
|
22
|
+
case 'error':
|
|
23
|
+
return 'bg-destructive border-destructive text-white';
|
|
24
|
+
case 'warning':
|
|
25
|
+
return 'bg-warning border-warning text-white';
|
|
26
|
+
case 'success':
|
|
27
|
+
return 'bg-success border-success text-white';
|
|
28
|
+
default:
|
|
29
|
+
return 'bg-primary border-primary text-white';
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
export function NotificationBar() {
|
|
34
|
+
const { notifications, hasNotifications, isDrawerOpen, toggleDrawer, dismissNotification } =
|
|
35
|
+
useNotifications();
|
|
36
|
+
const barRef = useRef<HTMLDivElement>(null);
|
|
37
|
+
|
|
38
|
+
// Measure bar height and set CSS variable so fixed elements (Nav, Sidebar) can offset their top
|
|
39
|
+
useEffect(() => {
|
|
40
|
+
const el = barRef.current;
|
|
41
|
+
if (!el || !hasNotifications) {
|
|
42
|
+
document.documentElement.style.removeProperty('--notification-bar-h');
|
|
43
|
+
return;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
const observer = new ResizeObserver(([entry]) => {
|
|
47
|
+
const height = entry.borderBoxSize?.[0]?.blockSize ?? entry.contentRect.height;
|
|
48
|
+
document.documentElement.style.setProperty('--notification-bar-h', `${height}px`);
|
|
49
|
+
});
|
|
50
|
+
|
|
51
|
+
observer.observe(el);
|
|
52
|
+
return () => {
|
|
53
|
+
observer.disconnect();
|
|
54
|
+
document.documentElement.style.removeProperty('--notification-bar-h');
|
|
55
|
+
};
|
|
56
|
+
}, [hasNotifications]);
|
|
57
|
+
|
|
58
|
+
if (!hasNotifications) {
|
|
59
|
+
return null;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
const latestNotification = notifications[0];
|
|
63
|
+
|
|
64
|
+
const handleAction = (url: string) => {
|
|
65
|
+
window.open(url, '_blank', 'noopener,noreferrer');
|
|
66
|
+
};
|
|
67
|
+
|
|
68
|
+
return (
|
|
69
|
+
<div ref={barRef} className="sticky top-0 z-50 border-b">
|
|
70
|
+
{/* Always visible bar showing latest notification */}
|
|
71
|
+
<div
|
|
72
|
+
className={cn(
|
|
73
|
+
'flex items-center gap-3 px-4 py-2 transition-colors',
|
|
74
|
+
getNotificationStyles(latestNotification.type)
|
|
75
|
+
)}
|
|
76
|
+
>
|
|
77
|
+
<span className="shrink-0">{getNotificationIcon(latestNotification.type)}</span>
|
|
78
|
+
<div className="flex-1 min-w-0 flex items-center gap-2">
|
|
79
|
+
<span className="font-medium text-sm truncate">{latestNotification.title}</span>
|
|
80
|
+
{latestNotification.message && (
|
|
81
|
+
<span className="text-sm opacity-80 truncate hidden sm:inline">
|
|
82
|
+
- {latestNotification.message}
|
|
83
|
+
</span>
|
|
84
|
+
)}
|
|
85
|
+
</div>
|
|
86
|
+
<div className="flex items-center gap-1 shrink-0">
|
|
87
|
+
{latestNotification.action &&
|
|
88
|
+
(() => {
|
|
89
|
+
const action = latestNotification.action;
|
|
90
|
+
return (
|
|
91
|
+
<Button
|
|
92
|
+
variant="ghost"
|
|
93
|
+
size="sm"
|
|
94
|
+
className="h-7"
|
|
95
|
+
onClick={() => handleAction(action.url)}
|
|
96
|
+
>
|
|
97
|
+
{action.label}
|
|
98
|
+
</Button>
|
|
99
|
+
);
|
|
100
|
+
})()}
|
|
101
|
+
{notifications.length > 1 && (
|
|
102
|
+
<Button variant="ghost" size="sm" className="h-7" onClick={toggleDrawer}>
|
|
103
|
+
{isDrawerOpen ? 'Hide' : `+${notifications.length - 1} more`}
|
|
104
|
+
</Button>
|
|
105
|
+
)}
|
|
106
|
+
{latestNotification.dismissible && (
|
|
107
|
+
<Button
|
|
108
|
+
variant="ghost"
|
|
109
|
+
size="icon-sm"
|
|
110
|
+
onClick={() => dismissNotification(latestNotification.id)}
|
|
111
|
+
>
|
|
112
|
+
<X className="size-3.5" />
|
|
113
|
+
</Button>
|
|
114
|
+
)}
|
|
115
|
+
</div>
|
|
116
|
+
</div>
|
|
117
|
+
|
|
118
|
+
{/* Expanded section showing additional notifications */}
|
|
119
|
+
<div
|
|
120
|
+
className={cn(
|
|
121
|
+
'overflow-hidden transition-all duration-300 ease-in-out',
|
|
122
|
+
isDrawerOpen && notifications.length > 1 ? 'max-h-60' : 'max-h-0'
|
|
123
|
+
)}
|
|
124
|
+
>
|
|
125
|
+
<div className="max-h-60 overflow-y-auto border-t">
|
|
126
|
+
{notifications.slice(1).map((notification) => (
|
|
127
|
+
<div
|
|
128
|
+
key={notification.id}
|
|
129
|
+
className={cn(
|
|
130
|
+
'flex items-center gap-3 px-4 py-2 border-b last:border-b-0',
|
|
131
|
+
getNotificationStyles(notification.type)
|
|
132
|
+
)}
|
|
133
|
+
>
|
|
134
|
+
<span className="shrink-0">{getNotificationIcon(notification.type)}</span>
|
|
135
|
+
<div className="flex-1 min-w-0">
|
|
136
|
+
<span className="font-medium text-sm truncate">{notification.title}</span>
|
|
137
|
+
{notification.message && (
|
|
138
|
+
<span className="text-sm opacity-80 ml-1 truncate">- {notification.message}</span>
|
|
139
|
+
)}
|
|
140
|
+
</div>
|
|
141
|
+
{notification.action &&
|
|
142
|
+
(() => {
|
|
143
|
+
const action = notification.action;
|
|
144
|
+
return (
|
|
145
|
+
<Button
|
|
146
|
+
variant="ghost"
|
|
147
|
+
size="sm"
|
|
148
|
+
className="h-7 shrink-0"
|
|
149
|
+
onClick={() => handleAction(action.url)}
|
|
150
|
+
>
|
|
151
|
+
{action.label}
|
|
152
|
+
</Button>
|
|
153
|
+
);
|
|
154
|
+
})()}
|
|
155
|
+
{notification.dismissible && (
|
|
156
|
+
<Button
|
|
157
|
+
variant="ghost"
|
|
158
|
+
size="icon-sm"
|
|
159
|
+
className="shrink-0"
|
|
160
|
+
onClick={() => dismissNotification(notification.id)}
|
|
161
|
+
>
|
|
162
|
+
<X className="size-3.5" />
|
|
163
|
+
</Button>
|
|
164
|
+
)}
|
|
165
|
+
</div>
|
|
166
|
+
))}
|
|
167
|
+
</div>
|
|
168
|
+
</div>
|
|
169
|
+
</div>
|
|
170
|
+
);
|
|
171
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { HeaderActions } from '@/components/HeaderActions';
|
|
2
|
+
|
|
3
|
+
interface PageHeaderProps {
|
|
4
|
+
title: string;
|
|
5
|
+
description?: string;
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
export function PageHeader({ title, description }: PageHeaderProps) {
|
|
9
|
+
return (
|
|
10
|
+
<header className="flex h-10 items-center justify-between pl-1 pr-6 mt-6">
|
|
11
|
+
<div className="flex items-center gap-3">
|
|
12
|
+
<div className="relative">
|
|
13
|
+
<h1 className="text-lg font-semibold leading-tight">{title}</h1>
|
|
14
|
+
{description && (
|
|
15
|
+
<p className="absolute top-full text-sm text-muted-foreground whitespace-nowrap">
|
|
16
|
+
{description}
|
|
17
|
+
</p>
|
|
18
|
+
)}
|
|
19
|
+
</div>
|
|
20
|
+
</div>
|
|
21
|
+
<HeaderActions />
|
|
22
|
+
</header>
|
|
23
|
+
);
|
|
24
|
+
}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import type { PlanId } from '@shared/pricing';
|
|
2
|
+
import type { ReactNode } from 'react';
|
|
3
|
+
import { useSubscription } from '@/hooks/api';
|
|
4
|
+
|
|
5
|
+
const planHierarchy: Record<PlanId, number> = {
|
|
6
|
+
free: 0,
|
|
7
|
+
starter: 1,
|
|
8
|
+
pro: 2,
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
interface PlanGateProps {
|
|
12
|
+
plan: PlanId;
|
|
13
|
+
children: ReactNode;
|
|
14
|
+
fallback?: ReactNode;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* Gate content behind a minimum plan requirement.
|
|
19
|
+
*
|
|
20
|
+
* Usage:
|
|
21
|
+
* <PlanGate plan="pro">
|
|
22
|
+
* <SecretFeature />
|
|
23
|
+
* </PlanGate>
|
|
24
|
+
*
|
|
25
|
+
* <PlanGate plan="starter" fallback={<UpgradePrompt />}>
|
|
26
|
+
* <PaidFeature />
|
|
27
|
+
* </PlanGate>
|
|
28
|
+
*/
|
|
29
|
+
export function PlanGate({ plan, children, fallback = null }: PlanGateProps) {
|
|
30
|
+
const { planId, isActive } = useSubscription();
|
|
31
|
+
|
|
32
|
+
const hasAccess = isActive ? planHierarchy[planId] >= planHierarchy[plan] : plan === 'free';
|
|
33
|
+
|
|
34
|
+
if (!hasAccess) return <>{fallback}</>;
|
|
35
|
+
return <>{children}</>;
|
|
36
|
+
}
|
|
@@ -0,0 +1,371 @@
|
|
|
1
|
+
import { motion } from 'framer-motion';
|
|
2
|
+
import { Atom, Check, Diamond, Hexagon, type LucideIcon, X } from 'lucide-react';
|
|
3
|
+
import { useEffect, useRef, useState } from 'react';
|
|
4
|
+
import { useTranslation } from 'react-i18next';
|
|
5
|
+
import { Link } from 'react-router-dom';
|
|
6
|
+
import { cn } from '@/lib/utils';
|
|
7
|
+
import vibecarbonIcon from '../assets/vibecarbon-icon.svg';
|
|
8
|
+
import { FresnelEdge } from './effects/FresnelEdge';
|
|
9
|
+
import { Button } from './ui/button';
|
|
10
|
+
|
|
11
|
+
interface Tier {
|
|
12
|
+
id: string;
|
|
13
|
+
name: string;
|
|
14
|
+
tagline: string;
|
|
15
|
+
price: number;
|
|
16
|
+
originalPrice: number | null;
|
|
17
|
+
unit: string;
|
|
18
|
+
cta: string;
|
|
19
|
+
ctaHref: string;
|
|
20
|
+
ctaVariant: 'outline' | 'exciting' | 'default';
|
|
21
|
+
popular: boolean;
|
|
22
|
+
icon: LucideIcon;
|
|
23
|
+
accent: {
|
|
24
|
+
icon: string;
|
|
25
|
+
bg: string;
|
|
26
|
+
shadow: string;
|
|
27
|
+
glow: string;
|
|
28
|
+
priceGradient: string | null;
|
|
29
|
+
check: string;
|
|
30
|
+
};
|
|
31
|
+
features: { text: string; included: boolean }[];
|
|
32
|
+
delay: number;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export function PricingSection() {
|
|
36
|
+
const { t } = useTranslation();
|
|
37
|
+
|
|
38
|
+
const tiers: Tier[] = [
|
|
39
|
+
{
|
|
40
|
+
id: 'graphite',
|
|
41
|
+
name: 'Graphite',
|
|
42
|
+
tagline: t('landing.pricing.graphite.tagline'),
|
|
43
|
+
price: 0,
|
|
44
|
+
originalPrice: null,
|
|
45
|
+
unit: t('landing.pricing.units.forever'),
|
|
46
|
+
cta: t('landing.pricing.graphite.cta'),
|
|
47
|
+
ctaHref: '/docs/getting-started',
|
|
48
|
+
ctaVariant: 'outline',
|
|
49
|
+
popular: false,
|
|
50
|
+
icon: Hexagon,
|
|
51
|
+
accent: {
|
|
52
|
+
icon: 'text-muted-foreground',
|
|
53
|
+
bg: 'bg-muted/30 dark:bg-background/50',
|
|
54
|
+
shadow: '',
|
|
55
|
+
glow: 'oklch(0.7 0.02 250 / 0.06)',
|
|
56
|
+
priceGradient: null,
|
|
57
|
+
check: 'text-muted-foreground',
|
|
58
|
+
},
|
|
59
|
+
features: [
|
|
60
|
+
{ text: t('landing.pricing.graphite.features.unlimitedProjects'), included: true },
|
|
61
|
+
{ text: t('landing.pricing.graphite.features.localDev'), included: true },
|
|
62
|
+
{ text: t('landing.pricing.graphite.features.addOns'), included: true },
|
|
63
|
+
{ text: t('landing.pricing.graphite.features.supabase'), included: true },
|
|
64
|
+
{ text: t('landing.pricing.graphite.features.community'), included: true },
|
|
65
|
+
{ text: t('landing.pricing.graphite.features.production'), included: false },
|
|
66
|
+
{ text: t('landing.pricing.graphite.features.ha'), included: false },
|
|
67
|
+
{ text: t('landing.pricing.graphite.features.k8s'), included: false },
|
|
68
|
+
],
|
|
69
|
+
delay: 0.1,
|
|
70
|
+
},
|
|
71
|
+
{
|
|
72
|
+
id: 'diamond',
|
|
73
|
+
name: 'Diamond',
|
|
74
|
+
tagline: t('landing.pricing.diamond.tagline'),
|
|
75
|
+
price: 149,
|
|
76
|
+
originalPrice: 299,
|
|
77
|
+
unit: t('landing.pricing.units.oneTime'),
|
|
78
|
+
cta: t('landing.pricing.diamond.cta'),
|
|
79
|
+
ctaHref: '/checkout?tier=diamond',
|
|
80
|
+
ctaVariant: 'exciting',
|
|
81
|
+
popular: true,
|
|
82
|
+
icon: Diamond,
|
|
83
|
+
accent: {
|
|
84
|
+
icon: 'text-primary',
|
|
85
|
+
bg: 'bg-primary/[0.03] dark:bg-primary/[0.05]',
|
|
86
|
+
shadow: 'shadow-lg shadow-primary/10',
|
|
87
|
+
glow: 'oklch(0.82 0.14 192 / 0.08)',
|
|
88
|
+
priceGradient: 'from-primary to-primary/70',
|
|
89
|
+
check: 'text-primary',
|
|
90
|
+
},
|
|
91
|
+
features: [
|
|
92
|
+
{ text: t('landing.pricing.diamond.features.graphite'), included: true },
|
|
93
|
+
{ text: t('landing.pricing.diamond.features.deployModes'), included: true },
|
|
94
|
+
{ text: t('landing.pricing.diamond.features.replication'), included: true },
|
|
95
|
+
{ text: t('landing.pricing.diamond.features.healthChecks'), included: true },
|
|
96
|
+
{ text: t('landing.pricing.diamond.features.backups'), included: true },
|
|
97
|
+
{ text: t('landing.pricing.diamond.features.cicd'), included: true },
|
|
98
|
+
{ text: t('landing.pricing.diamond.features.unlimited'), included: true },
|
|
99
|
+
{ text: t('landing.pricing.diamond.features.commercial'), included: false },
|
|
100
|
+
],
|
|
101
|
+
delay: 0.2,
|
|
102
|
+
},
|
|
103
|
+
{
|
|
104
|
+
id: 'fullerene',
|
|
105
|
+
name: 'Fullerene',
|
|
106
|
+
tagline: t('landing.pricing.fullerene.tagline'),
|
|
107
|
+
price: 499,
|
|
108
|
+
originalPrice: 999,
|
|
109
|
+
unit: t('landing.pricing.units.oneTime'),
|
|
110
|
+
cta: t('landing.pricing.fullerene.cta'),
|
|
111
|
+
ctaHref: '/checkout?tier=fullerene',
|
|
112
|
+
ctaVariant: 'exciting',
|
|
113
|
+
popular: false,
|
|
114
|
+
icon: Atom,
|
|
115
|
+
accent: {
|
|
116
|
+
icon: 'text-secondary-accent',
|
|
117
|
+
bg: 'bg-secondary-accent/[0.03] dark:bg-secondary-accent/[0.05]',
|
|
118
|
+
shadow: 'shadow-lg shadow-secondary-accent/10',
|
|
119
|
+
glow: 'oklch(0.65 0.26 350 / 0.06)',
|
|
120
|
+
priceGradient: 'from-secondary-accent to-fuchsia-400',
|
|
121
|
+
check: 'text-secondary-accent',
|
|
122
|
+
},
|
|
123
|
+
features: [
|
|
124
|
+
{ text: t('landing.pricing.fullerene.features.diamond'), included: true },
|
|
125
|
+
{ text: t('landing.pricing.fullerene.features.commercial'), included: true },
|
|
126
|
+
{ text: t('landing.pricing.fullerene.features.clients'), included: true },
|
|
127
|
+
{ text: t('landing.pricing.fullerene.features.corporate'), included: true },
|
|
128
|
+
{ text: t('landing.pricing.fullerene.features.support'), included: true },
|
|
129
|
+
{ text: t('landing.pricing.fullerene.features.lifetime'), included: true },
|
|
130
|
+
],
|
|
131
|
+
delay: 0.3,
|
|
132
|
+
},
|
|
133
|
+
];
|
|
134
|
+
|
|
135
|
+
return (
|
|
136
|
+
<section id="pricing" className="py-24 md:py-36 overflow-hidden">
|
|
137
|
+
<div className="mx-auto max-w-7xl px-6">
|
|
138
|
+
{/* Header */}
|
|
139
|
+
<motion.div
|
|
140
|
+
initial={{ opacity: 0, y: 20 }}
|
|
141
|
+
whileInView={{ opacity: 1, y: 0 }}
|
|
142
|
+
viewport={{ once: true, margin: '-100px' }}
|
|
143
|
+
transition={{ duration: 0.5 }}
|
|
144
|
+
className="mx-auto mb-16 max-w-2xl text-center"
|
|
145
|
+
>
|
|
146
|
+
<motion.div
|
|
147
|
+
className="flex justify-center mb-6"
|
|
148
|
+
animate={{ y: [0, -6, 0] }}
|
|
149
|
+
transition={{ duration: 3, repeat: Infinity, ease: 'easeInOut' }}
|
|
150
|
+
>
|
|
151
|
+
<img
|
|
152
|
+
src={vibecarbonIcon}
|
|
153
|
+
alt=""
|
|
154
|
+
width={56}
|
|
155
|
+
height={56}
|
|
156
|
+
className="drop-shadow-[0_0_12px_oklch(0.82_0.14_192/0.6)]"
|
|
157
|
+
/>
|
|
158
|
+
</motion.div>
|
|
159
|
+
<h2 className="mb-4 text-3xl font-black tracking-tight md:text-5xl">
|
|
160
|
+
{t('landing.pricing.headline1')}{' '}
|
|
161
|
+
<span className="bg-gradient-to-r from-muted-foreground to-foreground bg-clip-text text-transparent">
|
|
162
|
+
{t('landing.pricing.headlineSketch')}
|
|
163
|
+
</span>{' '}
|
|
164
|
+
{t('landing.pricing.headline2')}{' '}
|
|
165
|
+
<span className="bg-gradient-to-r from-primary to-secondary-accent bg-clip-text text-transparent">
|
|
166
|
+
{t('landing.pricing.headlineScale')}
|
|
167
|
+
</span>
|
|
168
|
+
</h2>
|
|
169
|
+
<p className="text-lg text-muted-foreground">{t('landing.pricing.subheading')}</p>
|
|
170
|
+
</motion.div>
|
|
171
|
+
|
|
172
|
+
{/* Background glow */}
|
|
173
|
+
<div className="relative">
|
|
174
|
+
{/* Pricing Cards */}
|
|
175
|
+
<div className="relative grid gap-8 md:grid-cols-3">
|
|
176
|
+
{tiers.map((tier) => (
|
|
177
|
+
<TierCard key={tier.id} tier={tier} />
|
|
178
|
+
))}
|
|
179
|
+
</div>
|
|
180
|
+
</div>
|
|
181
|
+
</div>
|
|
182
|
+
</section>
|
|
183
|
+
);
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
function TierCard({ tier }: { tier: Tier }) {
|
|
187
|
+
const { t } = useTranslation();
|
|
188
|
+
const Icon = tier.icon;
|
|
189
|
+
|
|
190
|
+
return (
|
|
191
|
+
<motion.div
|
|
192
|
+
initial={{ opacity: 0, y: 24, scale: 0.97 }}
|
|
193
|
+
whileInView={{ opacity: 1, y: 0, scale: 1 }}
|
|
194
|
+
whileHover={{ scale: 1.02 }}
|
|
195
|
+
viewport={{ once: true, margin: '-60px' }}
|
|
196
|
+
transition={{ type: 'spring', stiffness: 300, damping: 30, delay: tier.delay }}
|
|
197
|
+
className="relative"
|
|
198
|
+
>
|
|
199
|
+
{/* Badge — rendered outside FresnelEdge so it paints above the edge highlight line */}
|
|
200
|
+
{tier.popular && (
|
|
201
|
+
<div className="absolute -top-3.5 left-1/2 -translate-x-1/2 z-10">
|
|
202
|
+
<span className="relative inline-flex items-center rounded-full px-5 py-1.5 text-xs font-semibold text-white">
|
|
203
|
+
{/* Animated gradient border */}
|
|
204
|
+
<span className="absolute inset-0 rounded-full bg-gradient-to-r from-violet-500 via-fuchsia-400 via-amber-300 to-violet-500 badge-shimmer" />
|
|
205
|
+
{/* Inner dark fill */}
|
|
206
|
+
<span className="absolute inset-[1.5px] rounded-full bg-gradient-to-r from-violet-950 via-fuchsia-950 to-violet-950" />
|
|
207
|
+
{/* Shimmer highlight */}
|
|
208
|
+
<span className="absolute inset-[1.5px] rounded-full bg-gradient-to-r from-transparent via-white/10 to-transparent badge-shimmer opacity-60" />
|
|
209
|
+
<span className="relative">{t('landing.pricing.popular')}</span>
|
|
210
|
+
</span>
|
|
211
|
+
</div>
|
|
212
|
+
)}
|
|
213
|
+
<FresnelEdge
|
|
214
|
+
className="h-full rounded-2xl"
|
|
215
|
+
edgeColor={
|
|
216
|
+
tier.id === 'diamond'
|
|
217
|
+
? 'oklch(0.82 0.14 192 / 0.2)'
|
|
218
|
+
: tier.id === 'fullerene'
|
|
219
|
+
? 'oklch(0.65 0.26 350 / 0.15)'
|
|
220
|
+
: 'rgba(255, 255, 255, 0.08)'
|
|
221
|
+
}
|
|
222
|
+
glowStrength={tier.popular ? 0.8 : 0.3}
|
|
223
|
+
>
|
|
224
|
+
<div
|
|
225
|
+
className={cn(
|
|
226
|
+
'relative flex h-full flex-col rounded-2xl p-8 backdrop-blur-sm',
|
|
227
|
+
'transition-shadow duration-300',
|
|
228
|
+
tier.accent.bg,
|
|
229
|
+
tier.accent.shadow
|
|
230
|
+
)}
|
|
231
|
+
>
|
|
232
|
+
{/* Mouse-tracking glow */}
|
|
233
|
+
<div className="absolute inset-0 z-0 pointer-events-none">
|
|
234
|
+
<GlowTrackerCustom color={tier.accent.glow} />
|
|
235
|
+
</div>
|
|
236
|
+
|
|
237
|
+
{/* Icon + Tier name */}
|
|
238
|
+
<div className="relative z-[1] mb-1 flex items-center gap-3">
|
|
239
|
+
<div
|
|
240
|
+
className={cn(
|
|
241
|
+
'flex size-10 items-center justify-center rounded-xl border',
|
|
242
|
+
tier.id === 'diamond'
|
|
243
|
+
? 'border-primary/20 bg-primary/10'
|
|
244
|
+
: tier.id === 'fullerene'
|
|
245
|
+
? 'border-secondary-accent/20 bg-secondary-accent/10'
|
|
246
|
+
: 'border-border/50 bg-muted/50'
|
|
247
|
+
)}
|
|
248
|
+
>
|
|
249
|
+
<Icon className={cn('size-5', tier.accent.icon)} />
|
|
250
|
+
</div>
|
|
251
|
+
<h3 className="text-xl font-bold">{tier.name}</h3>
|
|
252
|
+
</div>
|
|
253
|
+
|
|
254
|
+
{/* Tagline */}
|
|
255
|
+
<p className="relative z-[1] mb-6 text-sm text-muted-foreground">{tier.tagline}</p>
|
|
256
|
+
|
|
257
|
+
{/* Price */}
|
|
258
|
+
<div className="relative z-[1] mb-2">
|
|
259
|
+
{tier.originalPrice && (
|
|
260
|
+
<span className="mr-2 text-base text-muted-foreground/40 line-through">
|
|
261
|
+
${tier.originalPrice}
|
|
262
|
+
</span>
|
|
263
|
+
)}
|
|
264
|
+
{tier.accent.priceGradient ? (
|
|
265
|
+
<span
|
|
266
|
+
className={cn(
|
|
267
|
+
'text-5xl font-black bg-gradient-to-r bg-clip-text text-transparent',
|
|
268
|
+
tier.accent.priceGradient
|
|
269
|
+
)}
|
|
270
|
+
>
|
|
271
|
+
${tier.price}
|
|
272
|
+
</span>
|
|
273
|
+
) : (
|
|
274
|
+
<span className="text-5xl font-black">{t('common.free')}</span>
|
|
275
|
+
)}
|
|
276
|
+
</div>
|
|
277
|
+
|
|
278
|
+
{/* Price unit pill */}
|
|
279
|
+
<div className="relative z-[1] mb-6">
|
|
280
|
+
<span className="inline-flex rounded-full bg-muted/60 px-2.5 py-0.5 text-xs text-muted-foreground">
|
|
281
|
+
{tier.unit}
|
|
282
|
+
</span>
|
|
283
|
+
</div>
|
|
284
|
+
|
|
285
|
+
{/* CTA */}
|
|
286
|
+
<div className="relative z-[1]">
|
|
287
|
+
<Button variant={tier.ctaVariant} size="lg" className="mb-8 w-full" asChild>
|
|
288
|
+
<Link to={tier.ctaHref}>{tier.cta}</Link>
|
|
289
|
+
</Button>
|
|
290
|
+
</div>
|
|
291
|
+
|
|
292
|
+
{/* Divider */}
|
|
293
|
+
<div
|
|
294
|
+
className={cn(
|
|
295
|
+
'relative z-[1] mb-6 h-px',
|
|
296
|
+
tier.id === 'diamond'
|
|
297
|
+
? 'bg-gradient-to-r from-transparent via-primary/30 to-transparent'
|
|
298
|
+
: tier.id === 'fullerene'
|
|
299
|
+
? 'bg-gradient-to-r from-transparent via-secondary-accent/20 to-transparent'
|
|
300
|
+
: 'bg-border/50'
|
|
301
|
+
)}
|
|
302
|
+
/>
|
|
303
|
+
|
|
304
|
+
{/* Features */}
|
|
305
|
+
<ul className="relative z-[1] flex-1 space-y-3">
|
|
306
|
+
{tier.features.map((feature) => (
|
|
307
|
+
<li key={feature.text} className="flex items-start gap-2.5">
|
|
308
|
+
{feature.included ? (
|
|
309
|
+
<Check className={cn('mt-0.5 size-4 flex-shrink-0', tier.accent.check)} />
|
|
310
|
+
) : (
|
|
311
|
+
<X className="mt-0.5 size-4 flex-shrink-0 text-muted-foreground/30" />
|
|
312
|
+
)}
|
|
313
|
+
<span
|
|
314
|
+
className={cn(
|
|
315
|
+
'text-sm',
|
|
316
|
+
feature.included ? 'text-muted-foreground' : 'text-muted-foreground/30'
|
|
317
|
+
)}
|
|
318
|
+
>
|
|
319
|
+
{feature.text}
|
|
320
|
+
</span>
|
|
321
|
+
</li>
|
|
322
|
+
))}
|
|
323
|
+
</ul>
|
|
324
|
+
</div>
|
|
325
|
+
</FresnelEdge>
|
|
326
|
+
</motion.div>
|
|
327
|
+
);
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
/**
|
|
331
|
+
* GlowTracker with customizable glow color per tier.
|
|
332
|
+
*/
|
|
333
|
+
function GlowTrackerCustom({ color }: { color: string }) {
|
|
334
|
+
const ref = useRef<HTMLDivElement>(null);
|
|
335
|
+
const [pos, setPos] = useState({ x: 0, y: 0 });
|
|
336
|
+
const [visible, setVisible] = useState(false);
|
|
337
|
+
|
|
338
|
+
useEffect(() => {
|
|
339
|
+
const el = ref.current;
|
|
340
|
+
const parent = el?.parentElement;
|
|
341
|
+
if (!parent) return;
|
|
342
|
+
|
|
343
|
+
const handleMove = (e: MouseEvent) => {
|
|
344
|
+
const rect = parent.getBoundingClientRect();
|
|
345
|
+
setPos({ x: e.clientX - rect.left, y: e.clientY - rect.top });
|
|
346
|
+
};
|
|
347
|
+
const handleEnter = () => setVisible(true);
|
|
348
|
+
const handleLeave = () => setVisible(false);
|
|
349
|
+
|
|
350
|
+
parent.addEventListener('mousemove', handleMove);
|
|
351
|
+
parent.addEventListener('mouseenter', handleEnter);
|
|
352
|
+
parent.addEventListener('mouseleave', handleLeave);
|
|
353
|
+
return () => {
|
|
354
|
+
parent.removeEventListener('mousemove', handleMove);
|
|
355
|
+
parent.removeEventListener('mouseenter', handleEnter);
|
|
356
|
+
parent.removeEventListener('mouseleave', handleLeave);
|
|
357
|
+
};
|
|
358
|
+
}, []);
|
|
359
|
+
|
|
360
|
+
return (
|
|
361
|
+
<div ref={ref} className="absolute inset-0 z-0 pointer-events-none">
|
|
362
|
+
<div
|
|
363
|
+
className="absolute -inset-px rounded-[inherit] transition-opacity duration-300"
|
|
364
|
+
style={{
|
|
365
|
+
opacity: visible ? 1 : 0,
|
|
366
|
+
background: `radial-gradient(600px circle at ${pos.x}px ${pos.y}px, ${color} 0%, transparent 90%)`,
|
|
367
|
+
}}
|
|
368
|
+
/>
|
|
369
|
+
</div>
|
|
370
|
+
);
|
|
371
|
+
}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { useEffect } from 'react';
|
|
2
|
+
|
|
3
|
+
const PROJECT_NAME = import.meta.env.VITE_PROJECT_NAME ?? '{{PROJECT_NAME}}';
|
|
4
|
+
|
|
5
|
+
interface SEOProps {
|
|
6
|
+
title?: string;
|
|
7
|
+
description?: string;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* Lightweight SEO component that updates document title and meta description.
|
|
12
|
+
*
|
|
13
|
+
* Usage:
|
|
14
|
+
* <SEO title="Pricing" description="See our plans" />
|
|
15
|
+
* <SEO title="Dashboard" />
|
|
16
|
+
*/
|
|
17
|
+
export function SEO({ title, description }: SEOProps) {
|
|
18
|
+
useEffect(() => {
|
|
19
|
+
document.title = title ? `${title} | ${PROJECT_NAME}` : PROJECT_NAME;
|
|
20
|
+
}, [title]);
|
|
21
|
+
|
|
22
|
+
useEffect(() => {
|
|
23
|
+
if (!description) return;
|
|
24
|
+
let meta = document.querySelector('meta[name="description"]');
|
|
25
|
+
if (!meta) {
|
|
26
|
+
meta = document.createElement('meta');
|
|
27
|
+
meta.setAttribute('name', 'description');
|
|
28
|
+
document.head.appendChild(meta);
|
|
29
|
+
}
|
|
30
|
+
meta.setAttribute('content', description);
|
|
31
|
+
}, [description]);
|
|
32
|
+
|
|
33
|
+
return null;
|
|
34
|
+
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import Lenis from 'lenis';
|
|
2
|
+
import { useEffect, useRef } from 'react';
|
|
3
|
+
|
|
4
|
+
export function SmoothScroll({ children }: { children: React.ReactNode }) {
|
|
5
|
+
const lenisRef = useRef<Lenis | null>(null);
|
|
6
|
+
|
|
7
|
+
useEffect(() => {
|
|
8
|
+
const lenis = new Lenis({
|
|
9
|
+
duration: 1.2,
|
|
10
|
+
easing: (t) => Math.min(1, 1.001 - 2 ** (-10 * t)),
|
|
11
|
+
smoothWheel: true,
|
|
12
|
+
touchMultiplier: 2,
|
|
13
|
+
});
|
|
14
|
+
lenisRef.current = lenis;
|
|
15
|
+
|
|
16
|
+
function raf(time: number) {
|
|
17
|
+
lenis.raf(time);
|
|
18
|
+
requestAnimationFrame(raf);
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
requestAnimationFrame(raf);
|
|
22
|
+
|
|
23
|
+
return () => {
|
|
24
|
+
lenis.destroy();
|
|
25
|
+
lenisRef.current = null;
|
|
26
|
+
};
|
|
27
|
+
}, []);
|
|
28
|
+
|
|
29
|
+
// Listen for theme scroll settings changes and mutate Lenis options at runtime
|
|
30
|
+
useEffect(() => {
|
|
31
|
+
const handler = (e: Event) => {
|
|
32
|
+
const { enabled, intensity } = (e as CustomEvent).detail;
|
|
33
|
+
const lenis = lenisRef.current;
|
|
34
|
+
if (!lenis) return;
|
|
35
|
+
|
|
36
|
+
lenis.options.smoothWheel = enabled;
|
|
37
|
+
lenis.options.duration = (intensity / 100) * 2.0;
|
|
38
|
+
};
|
|
39
|
+
|
|
40
|
+
document.addEventListener('theme:scroll-settings', handler);
|
|
41
|
+
return () => document.removeEventListener('theme:scroll-settings', handler);
|
|
42
|
+
}, []);
|
|
43
|
+
|
|
44
|
+
return <>{children}</>;
|
|
45
|
+
}
|