@digilogiclabs/create-saas-app 2.11.0 → 2.12.1
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/CHANGELOG.md +12 -0
- package/dist/.tsbuildinfo +1 -1
- package/dist/cli/index.js +1 -1
- package/dist/cli/index.js.map +1 -1
- package/dist/generators/template-generator.d.ts +0 -2
- package/dist/generators/template-generator.d.ts.map +1 -1
- package/dist/generators/template-generator.js +18 -17
- package/dist/generators/template-generator.js.map +1 -1
- package/dist/templates/mobile/base/template/App.tsx +7 -4
- package/dist/templates/mobile/base/template/app/checkout.tsx +5 -2
- package/dist/templates/mobile/ui-auth-payments/template/app/(tabs)/_layout.tsx +6 -2
- package/dist/templates/mobile/ui-auth-payments/template/app/(tabs)/billing.tsx +7 -3
- package/dist/templates/mobile/ui-auth-payments/template/app/(tabs)/index.tsx +5 -2
- package/dist/templates/mobile/ui-auth-payments/template/app/(tabs)/profile.tsx +7 -2
- package/dist/templates/mobile/ui-auth-payments/template/app/_layout.tsx +2 -4
- package/dist/templates/mobile/ui-auth-payments/template/app/auth/login.tsx +6 -3
- package/dist/templates/mobile/ui-auth-payments/template/app/auth/signup.tsx +6 -3
- package/dist/templates/mobile/ui-auth-payments-ai/template/app/(tabs)/_layout.tsx +6 -2
- package/dist/templates/mobile/ui-auth-payments-ai/template/app/(tabs)/billing.tsx +7 -3
- package/dist/templates/mobile/ui-auth-payments-ai/template/app/(tabs)/index.tsx +5 -2
- package/dist/templates/mobile/ui-auth-payments-ai/template/app/(tabs)/profile.tsx +7 -2
- package/dist/templates/mobile/ui-auth-payments-ai/template/app/_layout.tsx +2 -4
- package/dist/templates/mobile/ui-auth-payments-ai/template/app/auth/login.tsx +6 -3
- package/dist/templates/mobile/ui-auth-payments-ai/template/app/auth/signup.tsx +6 -3
- package/dist/templates/shared/admin/web/src/components/admin-nav.tsx +3 -3
- package/dist/templates/shared/auth/supabase/web/src/lib/auth-session.ts +36 -16
- package/dist/templates/shared/auth/supabase/web/src/middleware.ts +6 -0
- package/dist/templates/shared/config/web/next.config.mjs +0 -1
- package/dist/templates/shared/cookie-consent/web/components/cookie-consent.tsx +5 -5
- package/dist/templates/shared/design/web/src/components/ui/button.tsx +56 -0
- package/dist/templates/shared/email/web/src/lib/email/client.ts +1 -1
- package/dist/templates/shared/error-pages/web/src/app/error.tsx +13 -11
- package/dist/templates/shared/error-pages/web/src/app/global-error.tsx +2 -0
- package/dist/templates/shared/error-pages/web/src/app/not-found.tsx +6 -6
- package/dist/templates/shared/legal/web/src/app/(legal)/privacy/page.tsx +4 -4
- package/dist/templates/shared/legal/web/src/app/(legal)/terms/page.tsx +4 -4
- package/dist/templates/shared/loading/web/components/skeleton.tsx +4 -4
- package/dist/templates/shared/mock/web/.env.local +55 -0
- package/dist/templates/shared/mock/web/src/components/mock-auth-provider.tsx +72 -0
- package/dist/templates/shared/mock/web/src/components/mock-banner.tsx +29 -0
- package/dist/templates/shared/mock/web/src/lib/mock.ts +147 -0
- package/dist/templates/shared/payments/web/src/app/api/webhooks/stripe/route.ts +10 -4
- package/dist/templates/shared/redis/web/src/lib/redis.ts +1 -1
- package/dist/templates/web/ai-platform/template/package.json +0 -1
- package/dist/templates/web/ai-platform/template/src/app/chat/page.tsx +5 -2
- package/dist/templates/web/ai-platform/template/src/app/playground/page.tsx +5 -2
- package/dist/templates/web/ai-platform/template/src/components/providers/app-providers.tsx +2 -5
- package/dist/templates/web/base/template/eslint.config.mjs +14 -0
- package/dist/templates/web/base/template/src/app/auth/callback/route.ts +1 -1
- package/dist/templates/web/base/template/src/app/checkout/page.tsx +76 -103
- package/dist/templates/web/base/template/src/app/dashboard/page.tsx +145 -329
- package/dist/templates/web/base/template/src/app/layout.tsx +40 -38
- package/dist/templates/web/base/template/src/app/login/page.tsx +116 -66
- package/dist/templates/web/base/template/src/app/page.tsx +97 -193
- package/dist/templates/web/base/template/src/app/settings/page.tsx +154 -0
- package/dist/templates/web/base/template/src/app/signup/page.tsx +117 -66
- package/dist/templates/web/base/template/src/components/providers/app-providers.tsx +8 -3
- package/dist/templates/web/base/template/src/components/shared/header.tsx +229 -63
- package/dist/templates/web/iot-dashboard/template/package.json +0 -1
- package/dist/templates/web/iot-dashboard/template/src/components/providers/app-providers.tsx +2 -5
- package/dist/templates/web/marketplace/template/package.json +0 -1
- package/dist/templates/web/marketplace/template/src/components/providers/app-providers.tsx +2 -5
- package/dist/templates/web/micro-saas/template/package.json +0 -1
- package/dist/templates/web/micro-saas/template/src/components/providers/app-providers.tsx +2 -5
- package/dist/templates/web/ui-auth/template/eslint.config.mjs +14 -0
- package/dist/templates/web/ui-auth/template/src/app/checkout/page.tsx +3 -3
- package/dist/templates/web/ui-auth/template/src/app/dev-setup/page.tsx +81 -91
- package/dist/templates/web/ui-auth/template/src/app/layout.tsx +38 -36
- package/dist/templates/web/ui-auth/template/src/app/login/page.tsx +22 -45
- package/dist/templates/web/ui-auth/template/src/app/page.tsx +106 -306
- package/dist/templates/web/ui-auth/template/src/app/setup/page.tsx +387 -402
- package/dist/templates/web/ui-auth/template/src/app/signup/page.tsx +24 -47
- package/dist/templates/web/ui-auth/template/src/components/providers/app-providers.tsx +8 -3
- package/dist/templates/web/ui-auth/template/src/components/shared/header.tsx +229 -94
- package/dist/templates/web/ui-auth-ai/template/src/app/layout.tsx +38 -45
- package/dist/templates/web/ui-auth-ai/template/src/app/login/page.tsx +86 -0
- package/dist/templates/web/ui-auth-ai/template/src/app/page.tsx +107 -193
- package/dist/templates/web/ui-auth-ai/template/src/app/signup/page.tsx +105 -0
- package/dist/templates/web/ui-auth-ai/template/src/components/ai/audio-generator.tsx +144 -140
- package/dist/templates/web/ui-auth-ai/template/src/components/ai/video-generator.tsx +156 -157
- package/dist/templates/web/ui-auth-ai/template/src/components/auth/login-form.tsx +7 -3
- package/dist/templates/web/ui-auth-ai/template/src/components/providers/app-providers.tsx +25 -0
- package/dist/templates/web/ui-auth-ai/template/src/components/shared/footer.tsx +36 -0
- package/dist/templates/web/ui-auth-ai/template/src/components/shared/header.tsx +228 -0
- package/dist/templates/web/ui-auth-ai/template/src/components/ui/button.tsx +5 -5
- package/dist/templates/web/ui-auth-ai/template/src/components/ui/input.tsx +1 -1
- package/dist/templates/web/ui-auth-ai/template/src/components/ui/select.tsx +1 -1
- package/dist/templates/web/ui-auth-ai/template/src/components/ui/textarea.tsx +1 -1
- package/dist/templates/web/ui-auth-ai/template/src/components/ui/theme-toggle.tsx +34 -0
- package/dist/templates/web/ui-auth-ai/template/src/lib/supabase.ts +6 -4
- package/dist/templates/web/ui-auth-ai/template/src/providers/auth-provider.tsx +7 -5
- package/dist/templates/web/ui-auth-payments/template/src/app/billing/page.tsx +63 -192
- package/dist/templates/web/ui-auth-payments/template/src/app/checkout/page.tsx +104 -296
- package/dist/templates/web/ui-auth-payments/template/src/app/dashboard/page.tsx +27 -27
- package/dist/templates/web/ui-auth-payments/template/src/app/dev-setup/page.tsx +70 -81
- package/dist/templates/web/ui-auth-payments/template/src/app/layout.tsx +38 -36
- package/dist/templates/web/ui-auth-payments/template/src/app/login/loading.tsx +9 -9
- package/dist/templates/web/ui-auth-payments/template/src/app/login/page.tsx +4 -104
- package/dist/templates/web/ui-auth-payments/template/src/app/page.tsx +69 -337
- package/dist/templates/web/ui-auth-payments/template/src/app/setup/page.tsx +55 -68
- package/dist/templates/web/ui-auth-payments/template/src/app/signup/loading.tsx +13 -13
- package/dist/templates/web/ui-auth-payments/template/src/app/signup/page.tsx +4 -123
- package/dist/templates/web/ui-auth-payments/template/src/components/client/auth-status.tsx +37 -52
- package/dist/templates/web/ui-auth-payments/template/src/components/client/login-form.tsx +49 -103
- package/dist/templates/web/ui-auth-payments/template/src/components/client/newsletter-signup.tsx +4 -4
- package/dist/templates/web/ui-auth-payments/template/src/components/client/signup-form.tsx +60 -140
- package/dist/templates/web/ui-auth-payments/template/src/components/providers/app-providers.tsx +25 -28
- package/dist/templates/web/ui-auth-payments/template/src/components/shared/header.tsx +229 -230
- package/dist/templates/web/ui-auth-payments/template/src/lib/actions/auth.ts +245 -245
- package/dist/templates/web/ui-auth-payments/template/src/lib/actions/index.ts +339 -339
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/ai/page.tsx +305 -309
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/billing/page.tsx +62 -312
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/checkout/page.tsx +109 -125
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/dashboard/page.tsx +27 -27
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/dev-setup/page.tsx +68 -83
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/layout.tsx +40 -38
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/onboarding/page.tsx +20 -20
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/page.tsx +140 -394
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/settings/page.tsx +28 -27
- package/dist/templates/web/ui-auth-payments-ai/template/src/app/setup/page.tsx +51 -66
- package/dist/templates/web/ui-auth-payments-ai/template/src/components/client/auth-status.tsx +37 -52
- package/dist/templates/web/ui-auth-payments-ai/template/src/components/client/login-form.tsx +50 -79
- package/dist/templates/web/ui-auth-payments-ai/template/src/components/client/signup-form.tsx +58 -111
- package/dist/templates/web/ui-auth-payments-ai/template/src/components/providers/app-providers.tsx +8 -3
- package/dist/templates/web/ui-auth-payments-ai/template/src/components/shared/header.tsx +229 -252
- package/dist/templates/web/ui-auth-payments-ai/template/src/lib/actions/auth.ts +245 -245
- package/dist/templates/web/ui-auth-payments-audio/template/src/app/billing/page.tsx +63 -192
- package/dist/templates/web/ui-auth-payments-audio/template/src/app/checkout/page.tsx +109 -125
- package/dist/templates/web/ui-auth-payments-audio/template/src/app/dashboard/page.tsx +27 -27
- package/dist/templates/web/ui-auth-payments-audio/template/src/app/layout.tsx +40 -38
- package/dist/templates/web/ui-auth-payments-audio/template/src/app/page.tsx +122 -385
- package/dist/templates/web/ui-auth-payments-audio/template/src/app/setup/page.tsx +340 -344
- package/dist/templates/web/ui-auth-payments-audio/template/src/components/client/auth-status.tsx +37 -52
- package/dist/templates/web/ui-auth-payments-audio/template/src/components/client/login-form.tsx +49 -103
- package/dist/templates/web/ui-auth-payments-audio/template/src/components/client/signup-form.tsx +60 -140
- package/dist/templates/web/ui-auth-payments-audio/template/src/components/providers/app-providers.tsx +8 -3
- package/dist/templates/web/ui-auth-payments-audio/template/src/components/shared/header.tsx +229 -252
- package/dist/templates/web/ui-auth-payments-audio/template/src/lib/actions/auth.ts +3 -3
- package/dist/templates/web/ui-auth-payments-video/template/src/app/billing/page.tsx +63 -192
- package/dist/templates/web/ui-auth-payments-video/template/src/app/checkout/page.tsx +109 -125
- package/dist/templates/web/ui-auth-payments-video/template/src/app/layout.tsx +38 -36
- package/dist/templates/web/ui-auth-payments-video/template/src/app/login/page.tsx +9 -109
- package/dist/templates/web/ui-auth-payments-video/template/src/app/page.tsx +132 -392
- package/dist/templates/web/ui-auth-payments-video/template/src/app/setup/page.tsx +346 -350
- package/dist/templates/web/ui-auth-payments-video/template/src/app/signup/page.tsx +9 -128
- package/dist/templates/web/ui-auth-payments-video/template/src/components/client/login-form.tsx +90 -0
- package/dist/templates/web/ui-auth-payments-video/template/src/components/client/signup-form.tsx +105 -0
- package/dist/templates/web/ui-auth-payments-video/template/src/components/providers/app-providers.tsx +8 -3
- package/dist/templates/web/ui-auth-payments-video/template/src/components/shared/header.tsx +229 -246
- package/dist/templates/web/ui-only/template/eslint.config.mjs +14 -0
- package/dist/templates/web/ui-only/template/src/app/checkout/page.tsx +2 -2
- package/dist/templates/web/ui-only/template/src/app/login/page.tsx +69 -63
- package/dist/templates/web/ui-only/template/src/app/page.tsx +69 -91
- package/dist/templates/web/ui-only/template/src/app/signup/page.tsx +94 -79
- package/dist/templates/web/ui-only/template/src/components/providers/app-providers.tsx +1 -6
- package/dist/templates/web/ui-only/template/src/components/shared/header.tsx +90 -53
- package/dist/templates/web/ui-package-test/template/package.json +19 -23
- package/dist/templates/web/ui-package-test/template/postcss.config.mjs +8 -0
- package/dist/templates/web/ui-package-test/template/src/app/globals.css +88 -0
- package/dist/templates/web/ui-package-test/template/src/app/layout.tsx +27 -0
- package/dist/templates/web/ui-package-test/template/src/app/page.tsx +46 -106
- package/package.json +1 -1
- package/src/templates/mobile/base/template/App.tsx +7 -4
- package/src/templates/mobile/base/template/app/checkout.tsx +5 -2
- package/src/templates/mobile/ui-auth-payments/template/app/(tabs)/_layout.tsx +6 -2
- package/src/templates/mobile/ui-auth-payments/template/app/(tabs)/billing.tsx +7 -3
- package/src/templates/mobile/ui-auth-payments/template/app/(tabs)/index.tsx +5 -2
- package/src/templates/mobile/ui-auth-payments/template/app/(tabs)/profile.tsx +7 -2
- package/src/templates/mobile/ui-auth-payments/template/app/_layout.tsx +2 -4
- package/src/templates/mobile/ui-auth-payments/template/app/auth/login.tsx +6 -3
- package/src/templates/mobile/ui-auth-payments/template/app/auth/signup.tsx +6 -3
- package/src/templates/mobile/ui-auth-payments-ai/template/app/(tabs)/_layout.tsx +6 -2
- package/src/templates/mobile/ui-auth-payments-ai/template/app/(tabs)/billing.tsx +7 -3
- package/src/templates/mobile/ui-auth-payments-ai/template/app/(tabs)/index.tsx +5 -2
- package/src/templates/mobile/ui-auth-payments-ai/template/app/(tabs)/profile.tsx +7 -2
- package/src/templates/mobile/ui-auth-payments-ai/template/app/_layout.tsx +2 -4
- package/src/templates/mobile/ui-auth-payments-ai/template/app/auth/login.tsx +6 -3
- package/src/templates/mobile/ui-auth-payments-ai/template/app/auth/signup.tsx +6 -3
- package/src/templates/shared/admin/web/src/components/admin-nav.tsx +3 -3
- package/src/templates/shared/auth/supabase/web/src/lib/auth-session.ts +36 -16
- package/src/templates/shared/auth/supabase/web/src/middleware.ts +6 -0
- package/src/templates/shared/config/web/next.config.mjs +0 -1
- package/src/templates/shared/cookie-consent/web/components/cookie-consent.tsx +5 -5
- package/src/templates/shared/design/web/src/components/ui/button.tsx +56 -0
- package/src/templates/shared/email/web/src/lib/email/client.ts +1 -1
- package/src/templates/shared/error-pages/web/src/app/error.tsx +13 -11
- package/src/templates/shared/error-pages/web/src/app/global-error.tsx +2 -0
- package/src/templates/shared/error-pages/web/src/app/not-found.tsx +6 -6
- package/src/templates/shared/legal/web/src/app/(legal)/privacy/page.tsx +4 -4
- package/src/templates/shared/legal/web/src/app/(legal)/terms/page.tsx +4 -4
- package/src/templates/shared/loading/web/components/skeleton.tsx +4 -4
- package/src/templates/shared/mock/web/.env.local +55 -0
- package/src/templates/shared/mock/web/src/components/mock-auth-provider.tsx +72 -0
- package/src/templates/shared/mock/web/src/components/mock-banner.tsx +29 -0
- package/src/templates/shared/mock/web/src/lib/mock.ts +147 -0
- package/src/templates/shared/payments/web/src/app/api/webhooks/stripe/route.ts +10 -4
- package/src/templates/shared/redis/web/src/lib/redis.ts +1 -1
- package/src/templates/web/ai-platform/template/package.json +0 -1
- package/src/templates/web/ai-platform/template/src/app/chat/page.tsx +5 -2
- package/src/templates/web/ai-platform/template/src/app/playground/page.tsx +5 -2
- package/src/templates/web/ai-platform/template/src/components/providers/app-providers.tsx +2 -5
- package/src/templates/web/base/template/eslint.config.mjs +14 -0
- package/src/templates/web/base/template/src/app/auth/callback/route.ts +1 -1
- package/src/templates/web/base/template/src/app/checkout/page.tsx +76 -103
- package/src/templates/web/base/template/src/app/dashboard/page.tsx +145 -329
- package/src/templates/web/base/template/src/app/layout.tsx +40 -38
- package/src/templates/web/base/template/src/app/login/page.tsx +116 -66
- package/src/templates/web/base/template/src/app/page.tsx +97 -193
- package/src/templates/web/base/template/src/app/settings/page.tsx +154 -0
- package/src/templates/web/base/template/src/app/signup/page.tsx +117 -66
- package/src/templates/web/base/template/src/components/providers/app-providers.tsx +8 -3
- package/src/templates/web/base/template/src/components/shared/header.tsx +229 -63
- package/src/templates/web/iot-dashboard/template/package.json +0 -1
- package/src/templates/web/iot-dashboard/template/src/components/providers/app-providers.tsx +2 -5
- package/src/templates/web/marketplace/template/package.json +0 -1
- package/src/templates/web/marketplace/template/src/components/providers/app-providers.tsx +2 -5
- package/src/templates/web/micro-saas/template/package.json +0 -1
- package/src/templates/web/micro-saas/template/src/components/providers/app-providers.tsx +2 -5
- package/src/templates/web/ui-auth/template/eslint.config.mjs +14 -0
- package/src/templates/web/ui-auth/template/src/app/checkout/page.tsx +3 -3
- package/src/templates/web/ui-auth/template/src/app/dev-setup/page.tsx +81 -91
- package/src/templates/web/ui-auth/template/src/app/layout.tsx +38 -36
- package/src/templates/web/ui-auth/template/src/app/login/page.tsx +22 -45
- package/src/templates/web/ui-auth/template/src/app/page.tsx +106 -306
- package/src/templates/web/ui-auth/template/src/app/setup/page.tsx +387 -402
- package/src/templates/web/ui-auth/template/src/app/signup/page.tsx +24 -47
- package/src/templates/web/ui-auth/template/src/components/providers/app-providers.tsx +8 -3
- package/src/templates/web/ui-auth/template/src/components/shared/header.tsx +229 -94
- package/src/templates/web/ui-auth-ai/template/src/app/layout.tsx +38 -45
- package/src/templates/web/ui-auth-ai/template/src/app/login/page.tsx +86 -0
- package/src/templates/web/ui-auth-ai/template/src/app/page.tsx +107 -193
- package/src/templates/web/ui-auth-ai/template/src/app/signup/page.tsx +105 -0
- package/src/templates/web/ui-auth-ai/template/src/components/ai/audio-generator.tsx +144 -140
- package/src/templates/web/ui-auth-ai/template/src/components/ai/video-generator.tsx +156 -157
- package/src/templates/web/ui-auth-ai/template/src/components/auth/login-form.tsx +7 -3
- package/src/templates/web/ui-auth-ai/template/src/components/providers/app-providers.tsx +25 -0
- package/src/templates/web/ui-auth-ai/template/src/components/shared/footer.tsx +36 -0
- package/src/templates/web/ui-auth-ai/template/src/components/shared/header.tsx +228 -0
- package/src/templates/web/ui-auth-ai/template/src/components/ui/button.tsx +5 -5
- package/src/templates/web/ui-auth-ai/template/src/components/ui/input.tsx +1 -1
- package/src/templates/web/ui-auth-ai/template/src/components/ui/select.tsx +1 -1
- package/src/templates/web/ui-auth-ai/template/src/components/ui/textarea.tsx +1 -1
- package/src/templates/web/ui-auth-ai/template/src/components/ui/theme-toggle.tsx +34 -0
- package/src/templates/web/ui-auth-ai/template/src/lib/supabase.ts +6 -4
- package/src/templates/web/ui-auth-ai/template/src/providers/auth-provider.tsx +7 -5
- package/src/templates/web/ui-auth-payments/template/src/app/billing/page.tsx +63 -192
- package/src/templates/web/ui-auth-payments/template/src/app/checkout/page.tsx +104 -296
- package/src/templates/web/ui-auth-payments/template/src/app/dashboard/page.tsx +27 -27
- package/src/templates/web/ui-auth-payments/template/src/app/dev-setup/page.tsx +70 -81
- package/src/templates/web/ui-auth-payments/template/src/app/layout.tsx +38 -36
- package/src/templates/web/ui-auth-payments/template/src/app/login/loading.tsx +9 -9
- package/src/templates/web/ui-auth-payments/template/src/app/login/page.tsx +4 -104
- package/src/templates/web/ui-auth-payments/template/src/app/page.tsx +69 -337
- package/src/templates/web/ui-auth-payments/template/src/app/setup/page.tsx +55 -68
- package/src/templates/web/ui-auth-payments/template/src/app/signup/loading.tsx +13 -13
- package/src/templates/web/ui-auth-payments/template/src/app/signup/page.tsx +4 -123
- package/src/templates/web/ui-auth-payments/template/src/components/client/auth-status.tsx +37 -52
- package/src/templates/web/ui-auth-payments/template/src/components/client/login-form.tsx +49 -103
- package/src/templates/web/ui-auth-payments/template/src/components/client/newsletter-signup.tsx +4 -4
- package/src/templates/web/ui-auth-payments/template/src/components/client/signup-form.tsx +60 -140
- package/src/templates/web/ui-auth-payments/template/src/components/providers/app-providers.tsx +25 -28
- package/src/templates/web/ui-auth-payments/template/src/components/shared/header.tsx +229 -230
- package/src/templates/web/ui-auth-payments/template/src/lib/actions/auth.ts +245 -245
- package/src/templates/web/ui-auth-payments/template/src/lib/actions/index.ts +339 -339
- package/src/templates/web/ui-auth-payments-ai/template/src/app/ai/page.tsx +305 -309
- package/src/templates/web/ui-auth-payments-ai/template/src/app/billing/page.tsx +62 -312
- package/src/templates/web/ui-auth-payments-ai/template/src/app/checkout/page.tsx +109 -125
- package/src/templates/web/ui-auth-payments-ai/template/src/app/dashboard/page.tsx +27 -27
- package/src/templates/web/ui-auth-payments-ai/template/src/app/dev-setup/page.tsx +68 -83
- package/src/templates/web/ui-auth-payments-ai/template/src/app/layout.tsx +40 -38
- package/src/templates/web/ui-auth-payments-ai/template/src/app/onboarding/page.tsx +20 -20
- package/src/templates/web/ui-auth-payments-ai/template/src/app/page.tsx +140 -394
- package/src/templates/web/ui-auth-payments-ai/template/src/app/settings/page.tsx +28 -27
- package/src/templates/web/ui-auth-payments-ai/template/src/app/setup/page.tsx +51 -66
- package/src/templates/web/ui-auth-payments-ai/template/src/components/client/auth-status.tsx +37 -52
- package/src/templates/web/ui-auth-payments-ai/template/src/components/client/login-form.tsx +50 -79
- package/src/templates/web/ui-auth-payments-ai/template/src/components/client/signup-form.tsx +58 -111
- package/src/templates/web/ui-auth-payments-ai/template/src/components/providers/app-providers.tsx +8 -3
- package/src/templates/web/ui-auth-payments-ai/template/src/components/shared/header.tsx +229 -252
- package/src/templates/web/ui-auth-payments-ai/template/src/lib/actions/auth.ts +245 -245
- package/src/templates/web/ui-auth-payments-audio/template/src/app/billing/page.tsx +63 -192
- package/src/templates/web/ui-auth-payments-audio/template/src/app/checkout/page.tsx +109 -125
- package/src/templates/web/ui-auth-payments-audio/template/src/app/dashboard/page.tsx +27 -27
- package/src/templates/web/ui-auth-payments-audio/template/src/app/layout.tsx +40 -38
- package/src/templates/web/ui-auth-payments-audio/template/src/app/page.tsx +122 -385
- package/src/templates/web/ui-auth-payments-audio/template/src/app/setup/page.tsx +340 -344
- package/src/templates/web/ui-auth-payments-audio/template/src/components/client/auth-status.tsx +37 -52
- package/src/templates/web/ui-auth-payments-audio/template/src/components/client/login-form.tsx +49 -103
- package/src/templates/web/ui-auth-payments-audio/template/src/components/client/signup-form.tsx +60 -140
- package/src/templates/web/ui-auth-payments-audio/template/src/components/providers/app-providers.tsx +8 -3
- package/src/templates/web/ui-auth-payments-audio/template/src/components/shared/header.tsx +229 -252
- package/src/templates/web/ui-auth-payments-audio/template/src/lib/actions/auth.ts +3 -3
- package/src/templates/web/ui-auth-payments-video/template/src/app/billing/page.tsx +63 -192
- package/src/templates/web/ui-auth-payments-video/template/src/app/checkout/page.tsx +109 -125
- package/src/templates/web/ui-auth-payments-video/template/src/app/layout.tsx +38 -36
- package/src/templates/web/ui-auth-payments-video/template/src/app/login/page.tsx +9 -109
- package/src/templates/web/ui-auth-payments-video/template/src/app/page.tsx +132 -392
- package/src/templates/web/ui-auth-payments-video/template/src/app/setup/page.tsx +346 -350
- package/src/templates/web/ui-auth-payments-video/template/src/app/signup/page.tsx +9 -128
- package/src/templates/web/ui-auth-payments-video/template/src/components/client/login-form.tsx +90 -0
- package/src/templates/web/ui-auth-payments-video/template/src/components/client/signup-form.tsx +105 -0
- package/src/templates/web/ui-auth-payments-video/template/src/components/providers/app-providers.tsx +8 -3
- package/src/templates/web/ui-auth-payments-video/template/src/components/shared/header.tsx +229 -246
- package/src/templates/web/ui-only/template/eslint.config.mjs +14 -0
- package/src/templates/web/ui-only/template/src/app/checkout/page.tsx +2 -2
- package/src/templates/web/ui-only/template/src/app/login/page.tsx +69 -63
- package/src/templates/web/ui-only/template/src/app/page.tsx +69 -91
- package/src/templates/web/ui-only/template/src/app/signup/page.tsx +94 -79
- package/src/templates/web/ui-only/template/src/components/providers/app-providers.tsx +1 -6
- package/src/templates/web/ui-only/template/src/components/shared/header.tsx +90 -53
- package/src/templates/web/ui-package-test/template/package.json +19 -23
- package/src/templates/web/ui-package-test/template/postcss.config.mjs +8 -0
- package/src/templates/web/ui-package-test/template/src/app/globals.css +88 -0
- package/src/templates/web/ui-package-test/template/src/app/layout.tsx +27 -0
- package/src/templates/web/ui-package-test/template/src/app/page.tsx +46 -106
- package/dist/templates/mobile/ui-auth-payments-ai-rag/template/README.md +0 -655
- package/dist/templates/mobile/ui-auth-payments-ai-rag/template/app/(tabs)/ai.tsx +0 -683
- package/dist/templates/mobile/ui-auth-payments-ai-rag/template/app/_layout.tsx +0 -124
- package/dist/templates/mobile/ui-auth-payments-ai-rag/template/app.json +0 -74
- package/dist/templates/mobile/ui-auth-payments-ai-rag/template/babel.config.js +0 -25
- package/dist/templates/mobile/ui-auth-payments-ai-rag/template/docs/MOBILE-SETUP.md +0 -787
- package/dist/templates/mobile/ui-auth-payments-ai-rag/template/eas.json +0 -25
- package/dist/templates/mobile/ui-auth-payments-ai-rag/template/expo-env.d.ts +0 -3
- package/dist/templates/mobile/ui-auth-payments-ai-rag/template/hooks/useRAGSystem.ts +0 -346
- package/dist/templates/mobile/ui-auth-payments-ai-rag/template/jest-setup.ts +0 -37
- package/dist/templates/mobile/ui-auth-payments-ai-rag/template/lib/rag/config.ts +0 -180
- package/dist/templates/mobile/ui-auth-payments-ai-rag/template/metro.config.js +0 -11
- package/dist/templates/mobile/ui-auth-payments-ai-rag/template/package.json +0 -122
- package/dist/templates/mobile/ui-auth-payments-ai-rag/template/scripts/setup-rag.js +0 -599
- package/dist/templates/mobile/ui-auth-payments-ai-rag/template/tsconfig.json +0 -32
- package/dist/templates/web/base/template/.eslintrc.js +0 -8
- package/dist/templates/web/base/template/src/components/__tests__/example.test.tsx +0 -49
- package/dist/templates/web/base/template/src/test/setup.ts +0 -74
- package/dist/templates/web/base/template/vitest.config.ts +0 -17
- package/dist/templates/web/ui-auth/template/.eslintrc.js +0 -8
- package/dist/templates/web/ui-auth/template/src/components/__tests__/example.test.tsx +0 -49
- package/dist/templates/web/ui-auth/template/src/test/setup.ts +0 -74
- package/dist/templates/web/ui-auth/template/vitest.config.ts +0 -17
- package/dist/templates/web/ui-auth-payments/template/src/components/__tests__/example.test.tsx +0 -49
- package/dist/templates/web/ui-auth-payments/template/src/test/setup.ts +0 -74
- package/dist/templates/web/ui-auth-payments/template/vitest.config.ts +0 -17
- package/dist/templates/web/ui-auth-payments-ai/template/src/components/__tests__/example.test.tsx +0 -49
- package/dist/templates/web/ui-auth-payments-ai/template/src/test/setup.ts +0 -74
- package/dist/templates/web/ui-auth-payments-ai/template/vitest.config.ts +0 -17
- package/dist/templates/web/ui-auth-payments-ai-rag/template/README.md +0 -434
- package/dist/templates/web/ui-auth-payments-ai-rag/template/components/rag/KnowledgeManager.tsx +0 -642
- package/dist/templates/web/ui-auth-payments-ai-rag/template/components/rag/RAGAnalytics.tsx +0 -466
- package/dist/templates/web/ui-auth-payments-ai-rag/template/components/rag/RAGChatInterface.tsx +0 -393
- package/dist/templates/web/ui-auth-payments-ai-rag/template/docs/GETTING-STARTED.md +0 -457
- package/dist/templates/web/ui-auth-payments-ai-rag/template/hooks/useRAGSystem.ts +0 -478
- package/dist/templates/web/ui-auth-payments-ai-rag/template/lib/rag/config.ts +0 -250
- package/dist/templates/web/ui-auth-payments-ai-rag/template/package.json +0 -73
- package/dist/templates/web/ui-auth-payments-ai-rag/template/scripts/setup-rag.js +0 -622
- package/dist/templates/web/ui-auth-payments-ai-rag/template/src/app/ai/page.tsx +0 -396
- package/dist/templates/web/ui-auth-payments-audio/template/src/components/__tests__/example.test.tsx +0 -49
- package/dist/templates/web/ui-auth-payments-audio/template/src/test/setup.ts +0 -74
- package/dist/templates/web/ui-auth-payments-audio/template/vitest.config.ts +0 -17
- package/dist/templates/web/ui-auth-payments-video/template/src/components/__tests__/example.test.tsx +0 -49
- package/dist/templates/web/ui-auth-payments-video/template/src/test/setup.ts +0 -74
- package/dist/templates/web/ui-auth-payments-video/template/vitest.config.ts +0 -17
- package/dist/templates/web/ui-only/template/.eslintrc.js +0 -8
- package/dist/templates/web/ui-only/template/src/components/__tests__/example.test.tsx +0 -49
- package/dist/templates/web/ui-only/template/src/test/setup.ts +0 -74
- package/dist/templates/web/ui-only/template/vitest.config.ts +0 -17
- package/src/templates/mobile/ui-auth-payments-ai-rag/template/README.md +0 -655
- package/src/templates/mobile/ui-auth-payments-ai-rag/template/app/(tabs)/ai.tsx +0 -683
- package/src/templates/mobile/ui-auth-payments-ai-rag/template/app/_layout.tsx +0 -124
- package/src/templates/mobile/ui-auth-payments-ai-rag/template/app.json +0 -74
- package/src/templates/mobile/ui-auth-payments-ai-rag/template/babel.config.js +0 -25
- package/src/templates/mobile/ui-auth-payments-ai-rag/template/docs/MOBILE-SETUP.md +0 -787
- package/src/templates/mobile/ui-auth-payments-ai-rag/template/eas.json +0 -25
- package/src/templates/mobile/ui-auth-payments-ai-rag/template/expo-env.d.ts +0 -3
- package/src/templates/mobile/ui-auth-payments-ai-rag/template/hooks/useRAGSystem.ts +0 -346
- package/src/templates/mobile/ui-auth-payments-ai-rag/template/jest-setup.ts +0 -37
- package/src/templates/mobile/ui-auth-payments-ai-rag/template/lib/rag/config.ts +0 -180
- package/src/templates/mobile/ui-auth-payments-ai-rag/template/metro.config.js +0 -11
- package/src/templates/mobile/ui-auth-payments-ai-rag/template/package.json +0 -122
- package/src/templates/mobile/ui-auth-payments-ai-rag/template/scripts/setup-rag.js +0 -599
- package/src/templates/mobile/ui-auth-payments-ai-rag/template/tsconfig.json +0 -32
- package/src/templates/web/base/template/.eslintrc.js +0 -8
- package/src/templates/web/base/template/src/components/__tests__/example.test.tsx +0 -49
- package/src/templates/web/base/template/src/test/setup.ts +0 -74
- package/src/templates/web/base/template/vitest.config.ts +0 -17
- package/src/templates/web/ui-auth/template/.eslintrc.js +0 -8
- package/src/templates/web/ui-auth/template/src/components/__tests__/example.test.tsx +0 -49
- package/src/templates/web/ui-auth/template/src/test/setup.ts +0 -74
- package/src/templates/web/ui-auth/template/vitest.config.ts +0 -17
- package/src/templates/web/ui-auth-payments/template/src/components/__tests__/example.test.tsx +0 -49
- package/src/templates/web/ui-auth-payments/template/src/test/setup.ts +0 -74
- package/src/templates/web/ui-auth-payments/template/vitest.config.ts +0 -17
- package/src/templates/web/ui-auth-payments-ai/template/src/components/__tests__/example.test.tsx +0 -49
- package/src/templates/web/ui-auth-payments-ai/template/src/test/setup.ts +0 -74
- package/src/templates/web/ui-auth-payments-ai/template/vitest.config.ts +0 -17
- package/src/templates/web/ui-auth-payments-ai-rag/template/README.md +0 -434
- package/src/templates/web/ui-auth-payments-ai-rag/template/components/rag/KnowledgeManager.tsx +0 -642
- package/src/templates/web/ui-auth-payments-ai-rag/template/components/rag/RAGAnalytics.tsx +0 -466
- package/src/templates/web/ui-auth-payments-ai-rag/template/components/rag/RAGChatInterface.tsx +0 -393
- package/src/templates/web/ui-auth-payments-ai-rag/template/docs/GETTING-STARTED.md +0 -457
- package/src/templates/web/ui-auth-payments-ai-rag/template/hooks/useRAGSystem.ts +0 -478
- package/src/templates/web/ui-auth-payments-ai-rag/template/lib/rag/config.ts +0 -250
- package/src/templates/web/ui-auth-payments-ai-rag/template/package.json +0 -73
- package/src/templates/web/ui-auth-payments-ai-rag/template/scripts/setup-rag.js +0 -622
- package/src/templates/web/ui-auth-payments-ai-rag/template/src/app/ai/page.tsx +0 -396
- package/src/templates/web/ui-auth-payments-audio/template/src/components/__tests__/example.test.tsx +0 -49
- package/src/templates/web/ui-auth-payments-audio/template/src/test/setup.ts +0 -74
- package/src/templates/web/ui-auth-payments-audio/template/vitest.config.ts +0 -17
- package/src/templates/web/ui-auth-payments-video/template/src/components/__tests__/example.test.tsx +0 -49
- package/src/templates/web/ui-auth-payments-video/template/src/test/setup.ts +0 -74
- package/src/templates/web/ui-auth-payments-video/template/vitest.config.ts +0 -17
- package/src/templates/web/ui-only/template/.eslintrc.js +0 -8
- package/src/templates/web/ui-only/template/src/components/__tests__/example.test.tsx +0 -49
- package/src/templates/web/ui-only/template/src/test/setup.ts +0 -74
- package/src/templates/web/ui-only/template/vitest.config.ts +0 -17
|
@@ -16,8 +16,8 @@ import {
|
|
|
16
16
|
AppShell
|
|
17
17
|
} from '@digilogiclabs/saas-factory-ui/native';
|
|
18
18
|
|
|
19
|
-
//
|
|
20
|
-
|
|
19
|
+
// TODO: Replace with direct auth/payments provider setup
|
|
20
|
+
// DLLProvider from @digilogiclabs/app-sdk has been deprecated
|
|
21
21
|
|
|
22
22
|
// Prevent the splash screen from auto-hiding before asset loading is complete
|
|
23
23
|
SplashScreen.preventAutoHideAsync();
|
|
@@ -53,7 +53,6 @@ export default function RootLayout() {
|
|
|
53
53
|
backgroundSync={true}
|
|
54
54
|
>
|
|
55
55
|
<NetworkAwareContent>
|
|
56
|
-
<DLLProvider>
|
|
57
56
|
<StripeProvider
|
|
58
57
|
publishableKey={process.env.EXPO_PUBLIC_STRIPE_PUBLISHABLE_KEY!}
|
|
59
58
|
merchantIdentifier="merchant.com.{{packageName}}.app"
|
|
@@ -113,7 +112,6 @@ export default function RootLayout() {
|
|
|
113
112
|
<Toast />
|
|
114
113
|
<StatusBar style="auto" />
|
|
115
114
|
</StripeProvider>
|
|
116
|
-
</DLLProvider>
|
|
117
115
|
</NetworkAwareContent>
|
|
118
116
|
</OfflineWrapper>
|
|
119
117
|
</HapticsProvider>
|
|
@@ -16,8 +16,8 @@ import {
|
|
|
16
16
|
NativeMobileHero as MobileHero
|
|
17
17
|
} from '@digilogiclabs/saas-factory-ui/native';
|
|
18
18
|
|
|
19
|
-
//
|
|
20
|
-
import { useAuth } from '@digilogiclabs/app-sdk';
|
|
19
|
+
// TODO: Replace with direct @digilogiclabs/saas-factory-auth usage
|
|
20
|
+
// import { useAuth } from '@digilogiclabs/app-sdk';
|
|
21
21
|
|
|
22
22
|
// Validation Schema
|
|
23
23
|
const loginSchema = z.object({
|
|
@@ -28,7 +28,10 @@ const loginSchema = z.object({
|
|
|
28
28
|
type LoginFormData = z.infer<typeof loginSchema>;
|
|
29
29
|
|
|
30
30
|
export default function LoginScreen() {
|
|
31
|
-
|
|
31
|
+
// TODO: Replace with direct auth provider hook
|
|
32
|
+
// const { signIn, loading } = useAuth();
|
|
33
|
+
const signIn = async (_email: string, _password: string) => { throw new Error('Wire up auth provider'); };
|
|
34
|
+
const loading = false;
|
|
32
35
|
const [error, setError] = useState<string | null>(null);
|
|
33
36
|
|
|
34
37
|
const { control, handleSubmit, formState: { errors, isValid } } = useForm<LoginFormData>({
|
|
@@ -16,8 +16,8 @@ import {
|
|
|
16
16
|
NativeCheckbox as Checkbox
|
|
17
17
|
} from '@digilogiclabs/saas-factory-ui/native';
|
|
18
18
|
|
|
19
|
-
//
|
|
20
|
-
import { useAuth } from '@digilogiclabs/app-sdk';
|
|
19
|
+
// TODO: Replace with direct @digilogiclabs/saas-factory-auth usage
|
|
20
|
+
// import { useAuth } from '@digilogiclabs/app-sdk';
|
|
21
21
|
|
|
22
22
|
// Validation Schema
|
|
23
23
|
const signupSchema = z.object({
|
|
@@ -36,7 +36,10 @@ const signupSchema = z.object({
|
|
|
36
36
|
type SignupFormData = z.infer<typeof signupSchema>;
|
|
37
37
|
|
|
38
38
|
export default function SignupScreen() {
|
|
39
|
-
|
|
39
|
+
// TODO: Replace with direct auth provider hook
|
|
40
|
+
// const { signUp, loading } = useAuth();
|
|
41
|
+
const signUp = async (_email: string, _password: string, _meta?: any) => { throw new Error('Wire up auth provider'); };
|
|
42
|
+
const loading = false;
|
|
40
43
|
const [error, setError] = useState<string | null>(null);
|
|
41
44
|
const [success, setSuccess] = useState<string | null>(null);
|
|
42
45
|
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { View } from 'react-native';
|
|
3
3
|
import { Tabs } from 'expo-router';
|
|
4
|
-
|
|
4
|
+
// TODO: Replace with direct @digilogiclabs/saas-factory-auth usage
|
|
5
|
+
// import { useAuth } from '@digilogiclabs/app-sdk';
|
|
5
6
|
import { Redirect } from 'expo-router';
|
|
6
7
|
|
|
7
8
|
// UI Components - Updated for v0.22.0
|
|
@@ -79,7 +80,10 @@ const tabConfig = [
|
|
|
79
80
|
];
|
|
80
81
|
|
|
81
82
|
export default function TabLayout() {
|
|
82
|
-
|
|
83
|
+
// TODO: Replace with direct auth provider hook
|
|
84
|
+
// const { user, loading } = useAuth();
|
|
85
|
+
const user = null as any; // placeholder — wire up your auth provider
|
|
86
|
+
const loading = false;
|
|
83
87
|
const { colors } = useTheme();
|
|
84
88
|
|
|
85
89
|
// Show loading state while checking authentication
|
|
@@ -19,8 +19,8 @@ import {
|
|
|
19
19
|
useTheme
|
|
20
20
|
} from '@digilogiclabs/saas-factory-ui/native';
|
|
21
21
|
|
|
22
|
-
//
|
|
23
|
-
import { usePayments } from '@digilogiclabs/app-sdk';
|
|
22
|
+
// TODO: Replace with direct @digilogiclabs/saas-factory-payments usage
|
|
23
|
+
// import { usePayments } from '@digilogiclabs/app-sdk';
|
|
24
24
|
|
|
25
25
|
// Icons
|
|
26
26
|
import {
|
|
@@ -129,7 +129,11 @@ const mockInvoices: Invoice[] = [
|
|
|
129
129
|
|
|
130
130
|
export default function BillingScreen() {
|
|
131
131
|
const { initPaymentSheet, presentPaymentSheet } = useStripe();
|
|
132
|
-
|
|
132
|
+
// TODO: Replace with direct payments provider hook
|
|
133
|
+
// const { createPaymentMethod, deletePaymentMethod, updateSubscription } = usePayments();
|
|
134
|
+
const createPaymentMethod = async (_data: any) => { throw new Error('Wire up payments provider'); };
|
|
135
|
+
const deletePaymentMethod = async (_id: string) => { throw new Error('Wire up payments provider'); };
|
|
136
|
+
const updateSubscription = async (_data: any) => { throw new Error('Wire up payments provider'); };
|
|
133
137
|
const { theme, isDark } = useTheme();
|
|
134
138
|
|
|
135
139
|
const [paymentMethods, setPaymentMethods] = useState<PaymentMethod[]>(mockPaymentMethods);
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import React, { useState, useEffect } from 'react';
|
|
2
2
|
import { View, Text, StyleSheet, ScrollView, RefreshControl, Dimensions, Animated } from 'react-native';
|
|
3
|
-
|
|
3
|
+
// TODO: Replace with direct @digilogiclabs/saas-factory-auth usage
|
|
4
|
+
// import { useAuth } from '@digilogiclabs/app-sdk';
|
|
4
5
|
import { LinearGradient } from 'expo-linear-gradient';
|
|
5
6
|
import { BlurView } from 'expo-blur';
|
|
6
7
|
import * as Haptics from 'expo-haptics';
|
|
@@ -63,7 +64,9 @@ interface DashboardData {
|
|
|
63
64
|
}
|
|
64
65
|
|
|
65
66
|
export default function HomeScreen() {
|
|
66
|
-
|
|
67
|
+
// TODO: Replace with direct auth provider hook
|
|
68
|
+
// const { user } = useAuth();
|
|
69
|
+
const user = null as any; // placeholder — wire up your auth provider
|
|
67
70
|
const { colors, isDark } = useTheme();
|
|
68
71
|
const [data, setData] = useState<DashboardData | null>(null);
|
|
69
72
|
const [loading, setLoading] = useState(true);
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import React, { useState } from 'react';
|
|
2
2
|
import { View, Text, StyleSheet, ScrollView, Alert, RefreshControl, Animated } from 'react-native';
|
|
3
3
|
import { router } from 'expo-router';
|
|
4
|
-
|
|
4
|
+
// TODO: Replace with direct @digilogiclabs/saas-factory-auth usage
|
|
5
|
+
// import { useAuth } from '@digilogiclabs/app-sdk';
|
|
5
6
|
import { LinearGradient } from 'expo-linear-gradient';
|
|
6
7
|
import { BlurView } from 'expo-blur';
|
|
7
8
|
import * as Haptics from 'expo-haptics';
|
|
@@ -40,7 +41,11 @@ import {
|
|
|
40
41
|
} from 'react-native-heroicons/outline';
|
|
41
42
|
|
|
42
43
|
export default function ProfileScreen() {
|
|
43
|
-
|
|
44
|
+
// TODO: Replace with direct auth provider hook
|
|
45
|
+
// const { user, signOut, updateProfile } = useAuth();
|
|
46
|
+
const user = null as any; // placeholder — wire up your auth provider
|
|
47
|
+
const signOut = async () => { throw new Error('Wire up auth provider'); };
|
|
48
|
+
const updateProfile = async (_data: any) => { throw new Error('Wire up auth provider'); };
|
|
44
49
|
const { theme, isDark } = useTheme();
|
|
45
50
|
const [notificationsEnabled, setNotificationsEnabled] = useState(true);
|
|
46
51
|
const [emailUpdates, setEmailUpdates] = useState(true);
|
|
@@ -16,8 +16,8 @@ import {
|
|
|
16
16
|
AppShell
|
|
17
17
|
} from '@digilogiclabs/saas-factory-ui/native';
|
|
18
18
|
|
|
19
|
-
//
|
|
20
|
-
|
|
19
|
+
// TODO: Replace with direct auth/payments provider setup
|
|
20
|
+
// DLLProvider from @digilogiclabs/app-sdk has been deprecated
|
|
21
21
|
|
|
22
22
|
// Prevent the splash screen from auto-hiding before asset loading is complete
|
|
23
23
|
SplashScreen.preventAutoHideAsync();
|
|
@@ -53,7 +53,6 @@ export default function RootLayout() {
|
|
|
53
53
|
backgroundSync={true}
|
|
54
54
|
>
|
|
55
55
|
<NetworkAwareContent>
|
|
56
|
-
<DLLProvider>
|
|
57
56
|
<StripeProvider
|
|
58
57
|
publishableKey={process.env.EXPO_PUBLIC_STRIPE_PUBLISHABLE_KEY!}
|
|
59
58
|
merchantIdentifier="merchant.com.{{packageName}}.app"
|
|
@@ -113,7 +112,6 @@ export default function RootLayout() {
|
|
|
113
112
|
<Toast />
|
|
114
113
|
<StatusBar style="auto" />
|
|
115
114
|
</StripeProvider>
|
|
116
|
-
</DLLProvider>
|
|
117
115
|
</NetworkAwareContent>
|
|
118
116
|
</OfflineWrapper>
|
|
119
117
|
</HapticsProvider>
|
|
@@ -16,8 +16,8 @@ import {
|
|
|
16
16
|
NativeMobileHero as MobileHero
|
|
17
17
|
} from '@digilogiclabs/saas-factory-ui/native';
|
|
18
18
|
|
|
19
|
-
//
|
|
20
|
-
import { useAuth } from '@digilogiclabs/app-sdk';
|
|
19
|
+
// TODO: Replace with direct @digilogiclabs/saas-factory-auth usage
|
|
20
|
+
// import { useAuth } from '@digilogiclabs/app-sdk';
|
|
21
21
|
|
|
22
22
|
// Validation Schema
|
|
23
23
|
const loginSchema = z.object({
|
|
@@ -28,7 +28,10 @@ const loginSchema = z.object({
|
|
|
28
28
|
type LoginFormData = z.infer<typeof loginSchema>;
|
|
29
29
|
|
|
30
30
|
export default function LoginScreen() {
|
|
31
|
-
|
|
31
|
+
// TODO: Replace with direct auth provider hook
|
|
32
|
+
// const { signIn, loading } = useAuth();
|
|
33
|
+
const signIn = async (_email: string, _password: string) => { throw new Error('Wire up auth provider'); };
|
|
34
|
+
const loading = false;
|
|
32
35
|
const [error, setError] = useState<string | null>(null);
|
|
33
36
|
|
|
34
37
|
const { control, handleSubmit, formState: { errors, isValid } } = useForm<LoginFormData>({
|
|
@@ -16,8 +16,8 @@ import {
|
|
|
16
16
|
NativeCheckbox as Checkbox
|
|
17
17
|
} from '@digilogiclabs/saas-factory-ui/native';
|
|
18
18
|
|
|
19
|
-
//
|
|
20
|
-
import { useAuth } from '@digilogiclabs/app-sdk';
|
|
19
|
+
// TODO: Replace with direct @digilogiclabs/saas-factory-auth usage
|
|
20
|
+
// import { useAuth } from '@digilogiclabs/app-sdk';
|
|
21
21
|
|
|
22
22
|
// Validation Schema
|
|
23
23
|
const signupSchema = z.object({
|
|
@@ -36,7 +36,10 @@ const signupSchema = z.object({
|
|
|
36
36
|
type SignupFormData = z.infer<typeof signupSchema>;
|
|
37
37
|
|
|
38
38
|
export default function SignupScreen() {
|
|
39
|
-
|
|
39
|
+
// TODO: Replace with direct auth provider hook
|
|
40
|
+
// const { signUp, loading } = useAuth();
|
|
41
|
+
const signUp = async (_email: string, _password: string, _meta?: any) => { throw new Error('Wire up auth provider'); };
|
|
42
|
+
const loading = false;
|
|
40
43
|
const [error, setError] = useState<string | null>(null);
|
|
41
44
|
const [success, setSuccess] = useState<string | null>(null);
|
|
42
45
|
|
|
@@ -20,7 +20,7 @@ export function AdminNav() {
|
|
|
20
20
|
const pathname = usePathname();
|
|
21
21
|
|
|
22
22
|
return (
|
|
23
|
-
<nav className="border-b border-
|
|
23
|
+
<nav className="border-b border-border">
|
|
24
24
|
<div className="flex gap-1">
|
|
25
25
|
{ADMIN_LINKS.map((link) => {
|
|
26
26
|
const isActive =
|
|
@@ -34,8 +34,8 @@ export function AdminNav() {
|
|
|
34
34
|
href={link.href}
|
|
35
35
|
className={`rounded-t-lg px-4 py-2.5 text-sm font-medium transition-colors ${
|
|
36
36
|
isActive
|
|
37
|
-
? 'border-b-2 border-
|
|
38
|
-
: 'text-
|
|
37
|
+
? 'border-b-2 border-primary text-primary'
|
|
38
|
+
: 'text-muted-foreground hover:text-foreground'
|
|
39
39
|
}`}
|
|
40
40
|
>
|
|
41
41
|
{link.label}
|
|
@@ -1,9 +1,14 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* Auth session adapter
|
|
3
|
-
*
|
|
2
|
+
* Auth session adapter — provider-agnostic.
|
|
3
|
+
*
|
|
4
|
+
* Provides getSession() and getUser() used by api-security.ts and server pages.
|
|
5
|
+
* In mock mode, returns a demo user without any backend connection.
|
|
6
|
+
*
|
|
7
|
+
* TODO: [REAL_DATA] To connect your auth provider, update the else branch below.
|
|
8
|
+
* Works with: Supabase, Firebase, Keycloak, Auth0, NextAuth, or any custom provider.
|
|
4
9
|
*/
|
|
5
10
|
import 'server-only';
|
|
6
|
-
import {
|
|
11
|
+
import { MOCK_MODE, MOCK_USER } from '@/lib/mock';
|
|
7
12
|
|
|
8
13
|
type Session = {
|
|
9
14
|
user?: {
|
|
@@ -14,21 +19,36 @@ type Session = {
|
|
|
14
19
|
};
|
|
15
20
|
|
|
16
21
|
export async function getSession(): Promise<Session | null> {
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
error,
|
|
21
|
-
} = await supabase.auth.getUser();
|
|
22
|
+
if (MOCK_MODE) {
|
|
23
|
+
return { user: { id: MOCK_USER.id, email: MOCK_USER.email, name: MOCK_USER.name } };
|
|
24
|
+
}
|
|
22
25
|
|
|
23
|
-
|
|
26
|
+
// TODO: [REAL_DATA] Replace with your auth provider's session check.
|
|
27
|
+
// Examples:
|
|
28
|
+
// Supabase: const { data: { user } } = await supabase.auth.getUser()
|
|
29
|
+
// NextAuth: const session = await getServerSession(authOptions)
|
|
30
|
+
// Keycloak: const session = await auth() // from @auth/core
|
|
31
|
+
// Firebase: const user = await adminAuth.verifyIdToken(token)
|
|
32
|
+
try {
|
|
33
|
+
const { createClient } = await import('@/lib/supabase/server');
|
|
34
|
+
const supabase = await createClient();
|
|
35
|
+
const {
|
|
36
|
+
data: { user },
|
|
37
|
+
error,
|
|
38
|
+
} = await supabase.auth.getUser();
|
|
24
39
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
40
|
+
if (error || !user) return null;
|
|
41
|
+
|
|
42
|
+
return {
|
|
43
|
+
user: {
|
|
44
|
+
id: user.id,
|
|
45
|
+
email: user.email ?? null,
|
|
46
|
+
name: user.user_metadata?.name ?? user.user_metadata?.full_name ?? null,
|
|
47
|
+
},
|
|
48
|
+
};
|
|
49
|
+
} catch {
|
|
50
|
+
return null;
|
|
51
|
+
}
|
|
32
52
|
}
|
|
33
53
|
|
|
34
54
|
export async function getUser() {
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
* Refreshes the Supabase auth session on every request and
|
|
5
5
|
* protects routes under /dashboard from unauthenticated access.
|
|
6
6
|
*
|
|
7
|
+
* Mock mode: set NEXT_PUBLIC_MOCK_MODE=true to bypass auth entirely.
|
|
7
8
|
* Add more protected routes to the `protectedPrefixes` array below.
|
|
8
9
|
*/
|
|
9
10
|
import { createServerClient } from '@supabase/ssr';
|
|
@@ -13,6 +14,11 @@ import { NextResponse, type NextRequest } from 'next/server';
|
|
|
13
14
|
const protectedPrefixes = ['/dashboard', '/settings', '/account'];
|
|
14
15
|
|
|
15
16
|
export async function middleware(request: NextRequest) {
|
|
17
|
+
// Mock mode — skip all auth, allow every route
|
|
18
|
+
if (process.env.NEXT_PUBLIC_MOCK_MODE === 'true') {
|
|
19
|
+
return NextResponse.next();
|
|
20
|
+
}
|
|
21
|
+
|
|
16
22
|
let supabaseResponse = NextResponse.next({ request });
|
|
17
23
|
|
|
18
24
|
const supabase = createServerClient(
|
|
@@ -48,7 +48,6 @@ const nextConfig = {
|
|
|
48
48
|
// Stub main barrel only — subpaths like /auth and /security-headers
|
|
49
49
|
// are Edge-safe and must NOT be stubbed.
|
|
50
50
|
'@digilogiclabs/platform-core$': false,
|
|
51
|
-
'@digilogiclabs/app-sdk$': false,
|
|
52
51
|
'ioredis$': false,
|
|
53
52
|
'pg$': false,
|
|
54
53
|
'nodemailer$': false,
|
|
@@ -26,24 +26,24 @@ export function CookieConsent() {
|
|
|
26
26
|
};
|
|
27
27
|
|
|
28
28
|
return (
|
|
29
|
-
<div className="fixed bottom-0 left-0 right-0 z-50 border-t border-
|
|
29
|
+
<div className="fixed bottom-0 left-0 right-0 z-50 border-t border-border bg-card p-4 shadow-lg">
|
|
30
30
|
<div className="mx-auto flex max-w-5xl flex-col items-center gap-4 sm:flex-row sm:justify-between">
|
|
31
|
-
<p className="text-sm text-
|
|
31
|
+
<p className="text-sm text-muted-foreground">
|
|
32
32
|
We use cookies to improve your experience.{' '}
|
|
33
|
-
<Link href="/privacy" className="underline hover:text-
|
|
33
|
+
<Link href="/privacy" className="underline hover:text-foreground">
|
|
34
34
|
Learn more
|
|
35
35
|
</Link>
|
|
36
36
|
</p>
|
|
37
37
|
<div className="flex gap-3">
|
|
38
38
|
<button
|
|
39
39
|
onClick={() => handleChoice('declined')}
|
|
40
|
-
className="rounded-lg border border-
|
|
40
|
+
className="rounded-lg border border-border px-4 py-2 text-sm font-medium text-foreground transition-colors hover:bg-muted"
|
|
41
41
|
>
|
|
42
42
|
Decline
|
|
43
43
|
</button>
|
|
44
44
|
<button
|
|
45
45
|
onClick={() => handleChoice('accepted')}
|
|
46
|
-
className="rounded-lg bg-
|
|
46
|
+
className="rounded-lg bg-primary px-4 py-2 text-sm font-medium text-primary-foreground transition-colors hover:bg-primary/90"
|
|
47
47
|
>
|
|
48
48
|
Accept
|
|
49
49
|
</button>
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import * as React from "react"
|
|
2
|
+
import { Slot } from "@radix-ui/react-slot"
|
|
3
|
+
import { cva, type VariantProps } from "class-variance-authority"
|
|
4
|
+
import { cn } from "@/lib/utils"
|
|
5
|
+
|
|
6
|
+
const buttonVariants = cva(
|
|
7
|
+
"inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50",
|
|
8
|
+
{
|
|
9
|
+
variants: {
|
|
10
|
+
variant: {
|
|
11
|
+
default: "bg-primary text-primary-foreground hover:bg-primary/90",
|
|
12
|
+
destructive:
|
|
13
|
+
"bg-destructive text-destructive-foreground hover:bg-destructive/90",
|
|
14
|
+
outline:
|
|
15
|
+
"border border-input bg-background hover:bg-accent hover:text-accent-foreground",
|
|
16
|
+
secondary:
|
|
17
|
+
"bg-secondary text-secondary-foreground hover:bg-secondary/80",
|
|
18
|
+
ghost: "hover:bg-accent hover:text-accent-foreground",
|
|
19
|
+
link: "text-primary underline-offset-4 hover:underline",
|
|
20
|
+
},
|
|
21
|
+
size: {
|
|
22
|
+
default: "h-10 px-4 py-2",
|
|
23
|
+
sm: "h-9 rounded-md px-3",
|
|
24
|
+
lg: "h-11 rounded-md px-8",
|
|
25
|
+
icon: "h-10 w-10",
|
|
26
|
+
},
|
|
27
|
+
},
|
|
28
|
+
defaultVariants: {
|
|
29
|
+
variant: "default",
|
|
30
|
+
size: "default",
|
|
31
|
+
},
|
|
32
|
+
}
|
|
33
|
+
)
|
|
34
|
+
|
|
35
|
+
export interface ButtonProps
|
|
36
|
+
extends React.ButtonHTMLAttributes<HTMLButtonElement>,
|
|
37
|
+
VariantProps<typeof buttonVariants> {
|
|
38
|
+
asChild?: boolean
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
const Button = React.forwardRef<HTMLButtonElement, ButtonProps>(
|
|
42
|
+
({ className, variant, size, asChild = false, ...props }, ref) => {
|
|
43
|
+
const Comp = asChild ? Slot : "button"
|
|
44
|
+
return (
|
|
45
|
+
<Comp
|
|
46
|
+
className={cn(buttonVariants({ variant, size, className }))}
|
|
47
|
+
ref={ref}
|
|
48
|
+
{...props}
|
|
49
|
+
/>
|
|
50
|
+
)
|
|
51
|
+
}
|
|
52
|
+
)
|
|
53
|
+
Button.displayName = "Button"
|
|
54
|
+
|
|
55
|
+
export { Button, buttonVariants }
|
|
56
|
+
|
|
@@ -37,7 +37,7 @@ function getResend(): Resend | null {
|
|
|
37
37
|
|
|
38
38
|
try {
|
|
39
39
|
// Dynamic import to avoid requiring resend in all environments
|
|
40
|
-
// eslint-disable-next-line
|
|
40
|
+
// eslint-disable-next-line
|
|
41
41
|
const { Resend } = require('resend');
|
|
42
42
|
resendClient = new Resend(apiKey);
|
|
43
43
|
return resendClient;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
|
|
3
|
+
import Link from 'next/link';
|
|
4
|
+
|
|
3
5
|
/**
|
|
4
6
|
* Error boundary page.
|
|
5
7
|
*
|
|
@@ -14,11 +16,11 @@ export default function Error({
|
|
|
14
16
|
reset: () => void;
|
|
15
17
|
}) {
|
|
16
18
|
return (
|
|
17
|
-
<main className="flex min-h-screen items-center justify-center bg-
|
|
19
|
+
<main className="flex min-h-screen items-center justify-center bg-background px-4">
|
|
18
20
|
<div className="text-center">
|
|
19
|
-
<div className="mx-auto mb-4 flex h-16 w-16 items-center justify-center rounded-full bg-
|
|
21
|
+
<div className="mx-auto mb-4 flex h-16 w-16 items-center justify-center rounded-full bg-destructive/10">
|
|
20
22
|
<svg
|
|
21
|
-
className="h-8 w-8 text-
|
|
23
|
+
className="h-8 w-8 text-destructive"
|
|
22
24
|
fill="none"
|
|
23
25
|
viewBox="0 0 24 24"
|
|
24
26
|
strokeWidth="1.5"
|
|
@@ -31,20 +33,20 @@ export default function Error({
|
|
|
31
33
|
/>
|
|
32
34
|
</svg>
|
|
33
35
|
</div>
|
|
34
|
-
<h1 className="text-2xl font-semibold text-
|
|
36
|
+
<h1 className="text-2xl font-semibold text-foreground">
|
|
35
37
|
Something went wrong
|
|
36
38
|
</h1>
|
|
37
|
-
<p className="mt-2 max-w-md text-
|
|
39
|
+
<p className="mt-2 max-w-md text-muted-foreground">
|
|
38
40
|
An unexpected error occurred. Please try again.
|
|
39
41
|
</p>
|
|
40
42
|
{error.digest && (
|
|
41
|
-
<p className="mt-1 text-xs text-
|
|
43
|
+
<p className="mt-1 text-xs text-muted-foreground/70">
|
|
42
44
|
Error ID: {error.digest}
|
|
43
45
|
</p>
|
|
44
46
|
)}
|
|
45
47
|
|
|
46
48
|
{process.env.NODE_ENV === 'development' && (
|
|
47
|
-
<pre className="mx-auto mt-4 max-w-lg overflow-auto rounded-lg bg-
|
|
49
|
+
<pre className="mx-auto mt-4 max-w-lg overflow-auto rounded-lg bg-muted p-4 text-left text-xs text-destructive">
|
|
48
50
|
{error.message}
|
|
49
51
|
{error.stack && `\n\n${error.stack}`}
|
|
50
52
|
</pre>
|
|
@@ -53,16 +55,16 @@ export default function Error({
|
|
|
53
55
|
<div className="mt-8 flex items-center justify-center gap-4">
|
|
54
56
|
<button
|
|
55
57
|
onClick={reset}
|
|
56
|
-
className="rounded-lg bg-
|
|
58
|
+
className="rounded-lg bg-primary px-5 py-2.5 text-sm font-medium text-primary-foreground transition-colors hover:bg-primary/90"
|
|
57
59
|
>
|
|
58
60
|
Try Again
|
|
59
61
|
</button>
|
|
60
|
-
<
|
|
62
|
+
<Link
|
|
61
63
|
href="/"
|
|
62
|
-
className="rounded-lg border border-
|
|
64
|
+
className="rounded-lg border border-border px-5 py-2.5 text-sm font-medium text-foreground transition-colors hover:bg-muted"
|
|
63
65
|
>
|
|
64
66
|
Go Home
|
|
65
|
-
</
|
|
67
|
+
</Link>
|
|
66
68
|
</div>
|
|
67
69
|
</div>
|
|
68
70
|
</main>
|
|
@@ -8,27 +8,27 @@ import Link from 'next/link';
|
|
|
8
8
|
*/
|
|
9
9
|
export default function NotFound() {
|
|
10
10
|
return (
|
|
11
|
-
<main className="flex min-h-screen items-center justify-center bg-
|
|
11
|
+
<main className="flex min-h-screen items-center justify-center bg-background px-4">
|
|
12
12
|
<div className="text-center">
|
|
13
|
-
<p className="bg-gradient-to-r from-
|
|
13
|
+
<p className="bg-gradient-to-r from-primary to-accent bg-clip-text text-8xl font-bold text-transparent">
|
|
14
14
|
404
|
|
15
15
|
</p>
|
|
16
|
-
<h1 className="mt-4 text-2xl font-semibold text-
|
|
16
|
+
<h1 className="mt-4 text-2xl font-semibold text-foreground">
|
|
17
17
|
Page not found
|
|
18
18
|
</h1>
|
|
19
|
-
<p className="mt-2 max-w-md text-
|
|
19
|
+
<p className="mt-2 max-w-md text-muted-foreground">
|
|
20
20
|
The page you're looking for doesn't exist or has been moved.
|
|
21
21
|
</p>
|
|
22
22
|
<div className="mt-8 flex items-center justify-center gap-4">
|
|
23
23
|
<Link
|
|
24
24
|
href="/"
|
|
25
|
-
className="rounded-lg bg-
|
|
25
|
+
className="rounded-lg bg-primary px-5 py-2.5 text-sm font-medium text-primary-foreground transition-colors hover:bg-primary/90"
|
|
26
26
|
>
|
|
27
27
|
Go Home
|
|
28
28
|
</Link>
|
|
29
29
|
<Link
|
|
30
30
|
href="/dashboard"
|
|
31
|
-
className="rounded-lg border border-
|
|
31
|
+
className="rounded-lg border border-border px-5 py-2.5 text-sm font-medium text-foreground transition-colors hover:bg-muted"
|
|
32
32
|
>
|
|
33
33
|
Dashboard
|
|
34
34
|
</Link>
|
|
@@ -23,16 +23,16 @@ export default function PrivacyPage() {
|
|
|
23
23
|
} = LEGAL_CONFIG;
|
|
24
24
|
|
|
25
25
|
return (
|
|
26
|
-
<main className="min-h-screen bg-
|
|
26
|
+
<main className="min-h-screen bg-background">
|
|
27
27
|
<div className="mx-auto max-w-3xl px-4 py-16 sm:px-6 lg:px-8">
|
|
28
|
-
<h1 className="mb-2 text-3xl font-bold tracking-tight text-
|
|
28
|
+
<h1 className="mb-2 text-3xl font-bold tracking-tight text-foreground">
|
|
29
29
|
Privacy Policy
|
|
30
30
|
</h1>
|
|
31
|
-
<p className="mb-8 text-sm text-
|
|
31
|
+
<p className="mb-8 text-sm text-muted-foreground">
|
|
32
32
|
Effective: {effectiveDate}
|
|
33
33
|
</p>
|
|
34
34
|
|
|
35
|
-
<div className="prose
|
|
35
|
+
<div className="prose dark:prose-invert max-w-none">
|
|
36
36
|
<section>
|
|
37
37
|
<h2>1. Information We Collect</h2>
|
|
38
38
|
<p>We collect information you provide directly:</p>
|
|
@@ -23,16 +23,16 @@ export default function TermsPage() {
|
|
|
23
23
|
} = LEGAL_CONFIG;
|
|
24
24
|
|
|
25
25
|
return (
|
|
26
|
-
<main className="min-h-screen bg-
|
|
26
|
+
<main className="min-h-screen bg-background">
|
|
27
27
|
<div className="mx-auto max-w-3xl px-4 py-16 sm:px-6 lg:px-8">
|
|
28
|
-
<h1 className="mb-2 text-3xl font-bold tracking-tight text-
|
|
28
|
+
<h1 className="mb-2 text-3xl font-bold tracking-tight text-foreground">
|
|
29
29
|
Terms of Service
|
|
30
30
|
</h1>
|
|
31
|
-
<p className="mb-8 text-sm text-
|
|
31
|
+
<p className="mb-8 text-sm text-muted-foreground">
|
|
32
32
|
Effective: {effectiveDate}
|
|
33
33
|
</p>
|
|
34
34
|
|
|
35
|
-
<div className="prose
|
|
35
|
+
<div className="prose dark:prose-invert max-w-none">
|
|
36
36
|
<section>
|
|
37
37
|
<h2>1. Acceptance of Terms</h2>
|
|
38
38
|
<p>
|