vibefast-cli 1.2.1 → 1.3.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/README.md +30 -95
- package/dist/__tests__/recipes.test.js +94 -91
- package/dist/__tests__/recipes.test.js.map +1 -1
- package/dist/commands/add.d.ts.map +1 -1
- package/dist/commands/add.js +301 -125
- package/dist/commands/add.js.map +1 -1
- package/dist/commands/checklist.d.ts.map +1 -1
- package/dist/commands/checklist.js +85 -44
- package/dist/commands/checklist.js.map +1 -1
- package/dist/commands/health.d.ts.map +1 -1
- package/dist/commands/health.js +13 -4
- package/dist/commands/health.js.map +1 -1
- package/dist/commands/init.d.ts.map +1 -1
- package/dist/commands/init.js +118 -26
- package/dist/commands/init.js.map +1 -1
- package/dist/commands/migrate.d.ts +3 -0
- package/dist/commands/migrate.d.ts.map +1 -0
- package/dist/commands/migrate.js +202 -0
- package/dist/commands/migrate.js.map +1 -0
- package/dist/commands/remove.d.ts.map +1 -1
- package/dist/commands/remove.js +61 -3
- package/dist/commands/remove.js.map +1 -1
- package/dist/core/auth.d.ts.map +1 -1
- package/dist/core/auth.js +20 -18
- package/dist/core/auth.js.map +1 -1
- package/dist/core/codemod.d.ts +33 -0
- package/dist/core/codemod.d.ts.map +1 -1
- package/dist/core/codemod.js +116 -0
- package/dist/core/codemod.js.map +1 -1
- package/dist/core/detect.d.ts.map +1 -1
- package/dist/core/detect.js +24 -7
- package/dist/core/detect.js.map +1 -1
- package/dist/core/journal.d.ts +1 -0
- package/dist/core/journal.d.ts.map +1 -1
- package/dist/core/journal.js.map +1 -1
- package/dist/core/recipes.d.ts.map +1 -1
- package/dist/core/recipes.js +25 -7
- package/dist/core/recipes.js.map +1 -1
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/docs/architecture.md +50 -0
- package/docs/commands.md +78 -0
- package/docs/contributing.md +27 -0
- package/docs/quickstart.md +50 -0
- package/docs/recipes.md +57 -0
- package/docs/troubleshooting.md +31 -0
- package/package.json +2 -2
- package/recipes/0/apps/native/src/components/advanced-ui/timeline/demo.tsx +445 -0
- package/recipes/0/apps/native/src/components/advanced-ui/timeline/timeline-view.tsx +355 -0
- package/recipes/0/apps/native/src/components/advanced-ui/timeline/types.ts +31 -0
- package/recipes/0/recipe.json +18 -0
- package/recipes/animated-chip/apps/native/src/components/advanced-ui/chip/demo.tsx +2 -1
- package/recipes/animated-chip/recipe.json +5 -2
- package/recipes/animated-chip-native@latest.zip +0 -0
- package/recipes/animated-chip@latest.zip +0 -0
- package/recipes/animated-switch/apps/native/src/components/advanced-ui/switch/demo.tsx +1 -1
- package/recipes/animated-switch/recipe.json +5 -2
- package/recipes/animated-switch-native@latest.zip +0 -0
- package/recipes/animated-switch@latest.zip +0 -0
- package/recipes/audio-recorder/apps/native/src/features/audio-recorder/components/audio-recorder.tsx +2 -1
- package/recipes/audio-recorder/apps/native/src/features/audio-recorder/demo/with-recording-list-demo.tsx +2 -2
- package/recipes/audio-recorder/recipe.json +7 -2
- package/recipes/audio-recorder-native@latest.zip +0 -0
- package/recipes/audio-recorder-supabase/apps/native/src/features/audio-recorder/components/audio-recorder.tsx +2 -1
- package/recipes/audio-recorder-supabase/apps/native/src/features/audio-recorder/demo/with-recording-list-demo.tsx +2 -1
- package/recipes/audio-recorder-supabase/recipe.json +12 -16
- package/recipes/audio-recorder-supabase-native@latest.zip +0 -0
- package/recipes/audio-recorder-supabase@latest.zip +0 -0
- package/recipes/audio-recorder@latest.zip +0 -0
- package/recipes/charts/apps/native/src/app/charts/index.tsx +3 -0
- package/recipes/charts/apps/native/src/features/charts/components/bar-chart.tsx +3 -1
- package/recipes/charts/apps/native/src/features/charts/components/candlestick-chart.tsx +3 -1
- package/recipes/charts/apps/native/src/features/charts/components/column-chart.tsx +3 -1
- package/recipes/charts/apps/native/src/features/charts/components/doughnut-chart.tsx +3 -1
- package/recipes/charts/apps/native/src/features/charts/components/line-chart.tsx +3 -1
- package/recipes/charts/apps/native/src/features/charts/components/radar-chart.tsx +3 -1
- package/recipes/charts/apps/native/src/features/charts/components/stacked-bar-chart.tsx +3 -1
- package/recipes/charts/recipe.json +13 -4
- package/recipes/charts-native@latest.zip +0 -0
- package/recipes/charts@latest.zip +0 -0
- package/recipes/chatbot/apps/native/src/features/chatbot/components/chat-markdown.tsx +86 -86
- package/recipes/chatbot/apps/native/src/features/chatbot/components/markdown/code-block.tsx +4 -4
- package/recipes/chatbot/recipe.json +3 -40
- package/recipes/chatbot-native@latest.zip +0 -0
- package/recipes/chatbot-supabase/apps/native/src/features/chatbot/components/chat-markdown.tsx +4 -1
- package/recipes/chatbot-supabase/apps/native/src/features/chatbot/components/markdown/code-block.tsx +86 -53
- package/recipes/chatbot-supabase/recipe.json +3 -42
- package/recipes/chatbot-supabase-native@latest.zip +0 -0
- package/recipes/chatbot-supabase@latest.zip +0 -0
- package/recipes/chatbot@latest.zip +0 -0
- package/recipes/glowing-button/recipe.json +6 -2
- package/recipes/glowing-button-native@latest.zip +0 -0
- package/recipes/glowing-button@latest.zip +0 -0
- package/recipes/image-analysis/apps/native/src/app/analysis/[type]/_layout.tsx +5 -0
- package/recipes/image-analysis/apps/native/src/app/analysis/[type]/analysis-options.tsx +50 -0
- package/recipes/image-analysis/apps/native/src/app/analysis/[type]/camera.tsx +2 -0
- package/recipes/image-analysis/apps/native/src/app/analysis/[type]/index.tsx +50 -0
- package/recipes/image-analysis/apps/native/src/app/analysis/[type]/loading.tsx +50 -0
- package/recipes/image-analysis/apps/native/src/app/analysis/[type]/results.tsx +2 -0
- package/recipes/image-analysis/apps/native/src/app/analysis/[type]/trait-details.tsx +3 -0
- package/recipes/image-analysis/apps/native/src/features/image-analyzer/app/analysis-options-screen.tsx +2 -2
- package/recipes/image-analysis/apps/native/src/features/image-analyzer/app/camera.tsx +72 -65
- package/recipes/image-analysis/apps/native/src/features/image-analyzer/app/image-capture-screen.tsx +65 -47
- package/recipes/image-analysis/apps/native/src/features/image-analyzer/app/loading-screen.tsx +43 -2
- package/recipes/image-analysis/apps/native/src/features/image-analyzer/app/loading.tsx +34 -1
- package/recipes/image-analysis/apps/native/src/features/image-analyzer/hooks/use-image-analysis.ts +83 -2
- package/recipes/image-analysis/recipe.json +11 -19
- package/recipes/image-analysis-native@latest.zip +0 -0
- package/recipes/image-analysis-supabase/apps/native/src/app/analysis/[type]/_layout.tsx +5 -0
- package/recipes/image-analysis-supabase/apps/native/src/app/analysis/[type]/analysis-options.tsx +50 -0
- package/recipes/image-analysis-supabase/apps/native/src/app/analysis/[type]/camera.tsx +2 -0
- package/recipes/image-analysis-supabase/apps/native/src/app/analysis/[type]/index.tsx +50 -0
- package/recipes/image-analysis-supabase/apps/native/src/app/analysis/[type]/loading.tsx +50 -0
- package/recipes/image-analysis-supabase/apps/native/src/app/analysis/[type]/results.tsx +2 -0
- package/recipes/image-analysis-supabase/apps/native/src/app/analysis/[type]/trait-details.tsx +3 -0
- package/recipes/image-analysis-supabase/recipe.json +10 -37
- package/recipes/image-analysis-supabase-native@latest.zip +0 -0
- package/recipes/image-analysis-supabase@latest.zip +0 -0
- package/recipes/image-analysis@latest.zip +0 -0
- package/recipes/image-analyzer/apps/native/src/app/(root)/(protected)/image-analyzer/index.tsx +2 -0
- package/recipes/image-generator/apps/native/src/app/image-generator/gallery.tsx +3 -0
- package/recipes/image-generator/apps/native/src/app/image-generator/index.tsx +3 -0
- package/recipes/image-generator/recipe.json +8 -18
- package/recipes/image-generator-native@latest.zip +0 -0
- package/recipes/image-generator-supabase/recipe.json +6 -35
- package/recipes/image-generator-supabase-native@latest.zip +0 -0
- package/recipes/image-generator-supabase@latest.zip +0 -0
- package/recipes/image-generator@latest.zip +0 -0
- package/recipes/ios-widget/recipe.json +18 -119
- package/recipes/ios-widget-native@latest.zip +0 -0
- package/recipes/ios-widget@latest.zip +0 -0
- package/recipes/number-stepper/apps/native/src/components/advanced-ui/stepper/demo.tsx +1 -1
- package/recipes/number-stepper/recipe.json +5 -2
- package/recipes/number-stepper-native@latest.zip +0 -0
- package/recipes/number-stepper@latest.zip +0 -0
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/interactive-onboarding.tsx +11 -18
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/steps/ai-tone-step.tsx +5 -7
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/steps/currency-step.tsx +9 -7
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/steps/feature-ai-step.tsx +8 -7
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/steps/feature-chatbot-step.tsx +6 -5
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/steps/feature-manual-step.tsx +4 -3
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/steps/feature-scan-step.tsx +6 -5
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/steps/main-reason-step.tsx +5 -7
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/steps/notification-step.tsx +7 -6
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/steps/overspend-step.tsx +5 -7
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/steps/personalizing-step.tsx +8 -7
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/steps/rating-step.tsx +6 -5
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/steps/reminder-step.tsx +5 -6
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/steps/safety-step.tsx +5 -4
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/steps/struggle-step.tsx +5 -7
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/steps/welcome-step.tsx +7 -6
- package/recipes/onboarding/apps/native/src/features/onboarding/expense-tracker/components/ui/onboarding-header.tsx +4 -3
- package/recipes/onboarding/recipe.json +9 -6
- package/recipes/onboarding-native@latest.zip +0 -0
- package/recipes/onboarding@latest.zip +0 -0
- package/recipes/payments/apps/native/src/app/paywall/index.tsx +74 -0
- package/recipes/payments/apps/native/src/app/paywall/local.tsx +25 -0
- package/recipes/payments/apps/native/src/app/paywall/remote.tsx +23 -0
- package/recipes/payments/packages/backend/convex/payments.ts +21 -3
- package/recipes/payments/recipe.json +14 -34
- package/recipes/payments-native@latest.zip +0 -0
- package/recipes/payments-supabase/apps/native/src/app/paywall/index.tsx +74 -0
- package/recipes/payments-supabase/apps/native/src/app/paywall/local.tsx +25 -0
- package/recipes/payments-supabase/apps/native/src/app/paywall/remote.tsx +23 -0
- package/recipes/payments-supabase/recipe.json +16 -23
- package/recipes/payments-supabase-native@latest.zip +0 -0
- package/recipes/payments-supabase@latest.zip +0 -0
- package/recipes/payments@latest.zip +0 -0
- package/recipes/posthog/apps/native/src/components/analytics/navigation-tracker.tsx +14 -0
- package/recipes/posthog/apps/native/src/lib/hooks/use-navigation-analytics.ts +44 -0
- package/recipes/posthog/apps/native/src/providers/posthog-provider.tsx +51 -0
- package/recipes/posthog/recipe.json +60 -0
- package/recipes/posthog-native@latest.zip +0 -0
- package/recipes/progress-circle/apps/native/src/components/advanced-ui/progress-bars/progress-circle-page.tsx +1 -1
- package/recipes/progress-circle/recipe.json +5 -2
- package/recipes/progress-circle-native@latest.zip +0 -0
- package/recipes/progress-circle@latest.zip +0 -0
- package/recipes/quiz/apps/native/src/app/quiz/index.tsx +47 -0
- package/recipes/quiz/recipe.json +9 -6
- package/recipes/quiz-native@latest.zip +0 -0
- package/recipes/quiz@latest.zip +0 -0
- package/recipes/screen-kits/apps/native/src/app/screen-kits/_layout.tsx +12 -0
- package/recipes/screen-kits/apps/native/src/app/screen-kits/index.tsx +114 -0
- package/recipes/screen-kits/apps/native/src/features/screen-kits/index.ts +1 -0
- package/recipes/screen-kits/apps/native/src/features/screen-kits/types.ts +28 -0
- package/recipes/screen-kits/recipe.json +26 -0
- package/recipes/screen-kits-duolingo/apps/native/src/app/screen-kits/duolingo/_layout.tsx +12 -0
- package/recipes/screen-kits-duolingo/apps/native/src/app/screen-kits/duolingo/home.tsx +5 -0
- package/recipes/screen-kits-duolingo/apps/native/src/app/screen-kits/duolingo/index.tsx +5 -0
- package/recipes/screen-kits-duolingo/apps/native/src/app/screen-kits/duolingo/lesson-complete.tsx +5 -0
- package/recipes/screen-kits-duolingo/apps/native/src/app/screen-kits/duolingo/lesson-fail.tsx +5 -0
- package/recipes/screen-kits-duolingo/apps/native/src/app/screen-kits/duolingo/lesson.tsx +5 -0
- package/recipes/screen-kits-duolingo/apps/native/src/app/screen-kits/duolingo/skill-tree.tsx +5 -0
- package/recipes/screen-kits-duolingo/apps/native/src/features/screen-kits/duolingo/components/duo-button.tsx +174 -0
- package/recipes/screen-kits-duolingo/apps/native/src/features/screen-kits/duolingo/components/skill-button.tsx +186 -0
- package/recipes/screen-kits-duolingo/apps/native/src/features/screen-kits/duolingo/components/xp-header.tsx +115 -0
- package/recipes/screen-kits-duolingo/apps/native/src/features/screen-kits/duolingo/constants.ts +89 -0
- package/recipes/screen-kits-duolingo/apps/native/src/features/screen-kits/duolingo/index.ts +3 -0
- package/recipes/screen-kits-duolingo/apps/native/src/features/screen-kits/duolingo/screens/home-screen.tsx +225 -0
- package/recipes/screen-kits-duolingo/apps/native/src/features/screen-kits/duolingo/screens/lesson-complete-screen.tsx +485 -0
- package/recipes/screen-kits-duolingo/apps/native/src/features/screen-kits/duolingo/screens/lesson-fail-screen.tsx +105 -0
- package/recipes/screen-kits-duolingo/apps/native/src/features/screen-kits/duolingo/screens/lesson-screen.tsx +384 -0
- package/recipes/screen-kits-duolingo/recipe.json +58 -0
- package/recipes/screen-kits-duolingo-native@latest.zip +0 -0
- package/recipes/screen-kits-finance/apps/native/src/app/screen-kits/finance/_layout.tsx +45 -0
- package/recipes/screen-kits-finance/apps/native/src/app/screen-kits/finance/asset-detail.tsx +3 -0
- package/recipes/screen-kits-finance/apps/native/src/app/screen-kits/finance/notifications.tsx +3 -0
- package/recipes/screen-kits-finance/apps/native/src/app/screen-kits/finance/receive.tsx +3 -0
- package/recipes/screen-kits-finance/apps/native/src/app/screen-kits/finance/send.tsx +3 -0
- package/recipes/screen-kits-finance/apps/native/src/app/screen-kits/finance/swap.tsx +3 -0
- package/recipes/screen-kits-finance/apps/native/src/app/screen-kits/finance/wallet.tsx +3 -0
- package/recipes/screen-kits-finance/apps/native/src/features/screen-kits/finance/components/ActionButtons.tsx +78 -0
- package/recipes/screen-kits-finance/apps/native/src/features/screen-kits/finance/components/AssetRow.tsx +94 -0
- package/recipes/screen-kits-finance/apps/native/src/features/screen-kits/finance/components/BalanceCard.tsx +118 -0
- package/recipes/screen-kits-finance/apps/native/src/features/screen-kits/finance/constants.ts +85 -0
- package/recipes/screen-kits-finance/apps/native/src/features/screen-kits/finance/screens/asset-detail.tsx +378 -0
- package/recipes/screen-kits-finance/apps/native/src/features/screen-kits/finance/screens/notifications.tsx +210 -0
- package/recipes/screen-kits-finance/apps/native/src/features/screen-kits/finance/screens/receive-modal.tsx +317 -0
- package/recipes/screen-kits-finance/apps/native/src/features/screen-kits/finance/screens/send-modal.tsx +420 -0
- package/recipes/screen-kits-finance/apps/native/src/features/screen-kits/finance/screens/swap-modal.tsx +363 -0
- package/recipes/screen-kits-finance/apps/native/src/features/screen-kits/finance/screens/wallet-dashboard.tsx +281 -0
- package/recipes/screen-kits-finance/recipe.json +46 -0
- package/recipes/screen-kits-finance-native@latest.zip +0 -0
- package/recipes/screen-kits-fitness/apps/native/assets/sounds/timer-beep.wav +0 -0
- package/recipes/screen-kits-fitness/apps/native/src/app/screen-kits/fitness/_layout.tsx +10 -0
- package/recipes/screen-kits-fitness/apps/native/src/app/screen-kits/fitness/index.tsx +6 -0
- package/recipes/screen-kits-fitness/apps/native/src/app/screen-kits/fitness/timer.tsx +3 -0
- package/recipes/screen-kits-fitness/apps/native/src/app/screen-kits/fitness/workout.tsx +3 -0
- package/recipes/screen-kits-fitness/apps/native/src/features/screen-kits/fitness/components/timer-components.tsx +500 -0
- package/recipes/screen-kits-fitness/apps/native/src/features/screen-kits/fitness/components/timer-settings-modal.tsx +352 -0
- package/recipes/screen-kits-fitness/apps/native/src/features/screen-kits/fitness/components/workout-card.tsx +105 -0
- package/recipes/screen-kits-fitness/apps/native/src/features/screen-kits/fitness/constants.ts +189 -0
- package/recipes/screen-kits-fitness/apps/native/src/features/screen-kits/fitness/hooks/use-timer.ts +307 -0
- package/recipes/screen-kits-fitness/apps/native/src/features/screen-kits/fitness/index.ts +1 -0
- package/recipes/screen-kits-fitness/apps/native/src/features/screen-kits/fitness/screens/timer-screen.tsx +278 -0
- package/recipes/screen-kits-fitness/apps/native/src/features/screen-kits/fitness/screens/workout-dashboard.tsx +350 -0
- package/recipes/screen-kits-fitness/recipe.json +63 -0
- package/recipes/screen-kits-fitness-native@latest.zip +0 -0
- package/recipes/screen-kits-habits/apps/native/src/app/screen-kits/productivity/habits.tsx +1 -0
- package/recipes/screen-kits-habits/apps/native/src/app/screen-kits/productivity/kanban.tsx +1 -0
- package/recipes/screen-kits-habits/apps/native/src/app/screen-kits/productivity/routes.ts +4 -0
- package/recipes/screen-kits-habits/apps/native/src/features/screen-kits/productivity/components/AddTaskModal.tsx +246 -0
- package/recipes/screen-kits-habits/apps/native/src/features/screen-kits/productivity/components/DraggableTaskCard.tsx +92 -0
- package/recipes/screen-kits-habits/apps/native/src/features/screen-kits/productivity/components/KanbanColumn.tsx +238 -0
- package/recipes/screen-kits-habits/apps/native/src/features/screen-kits/productivity/components/TaskCard.tsx +144 -0
- package/recipes/screen-kits-habits/apps/native/src/features/screen-kits/productivity/components/add-habit-modal.tsx +271 -0
- package/recipes/screen-kits-habits/apps/native/src/features/screen-kits/productivity/constants.ts +295 -0
- package/recipes/screen-kits-habits/apps/native/src/features/screen-kits/productivity/kanban-utils.ts +62 -0
- package/recipes/screen-kits-habits/apps/native/src/features/screen-kits/productivity/screens/habit-tracker.tsx +1160 -0
- package/recipes/screen-kits-habits/apps/native/src/features/screen-kits/productivity/screens/kanban-board.tsx +432 -0
- package/recipes/screen-kits-habits/recipe.json +52 -0
- package/recipes/screen-kits-habits-native@latest.zip +0 -0
- package/recipes/screen-kits-native@latest.zip +0 -0
- package/recipes/sentry/apps/native/src/providers/sentry-provider.tsx +64 -0
- package/recipes/sentry/recipe.json +39 -0
- package/recipes/sentry-native@latest.zip +0 -0
- package/recipes/swipe-slider/apps/native/src/components/advanced-ui/sliders/swipe-slider-page.tsx +1 -1
- package/recipes/swipe-slider/recipe.json +5 -2
- package/recipes/swipe-slider-native@latest.zip +0 -0
- package/recipes/swipe-slider@latest.zip +0 -0
- package/recipes/timeline/apps/native/src/components/advanced-ui/timeline/demo.tsx +2 -1
- package/recipes/timeline/recipe.json +5 -2
- package/recipes/timeline-native@latest.zip +0 -0
- package/recipes/timeline@latest.zip +0 -0
- package/recipes/tracker-app/apps/native/src/app/tracker-app/index.tsx +1 -0
- package/recipes/tracker-app/recipe.json +10 -7
- package/recipes/tracker-app-native@latest.zip +0 -0
- package/recipes/tracker-app@latest.zip +0 -0
- package/recipes/upload-all.sh +8 -31
- package/recipes/voice-bot/apps/native/src/app/voice-bot/index.tsx +56 -0
- package/recipes/voice-bot/recipe.json +31 -7
- package/recipes/voice-bot-native@latest.zip +0 -0
- package/recipes/voice-bot@latest.zip +0 -0
- package/recipes/wake-word/apps/native/src/app/{(root)/(protected)/test-wake-word.tsx → test-wake-word.tsx} +43 -4
- package/recipes/wake-word/recipe.json +16 -26
- package/recipes/wake-word-native@latest.zip +0 -0
- package/recipes/wake-word@latest.zip +0 -0
- package/scripts/create-advanced-ui-recipes.sh +46 -19
- package/scripts/create-recipes.mjs +471 -117
- package/scripts/package-recipes.mjs +76 -0
- package/scripts/publish-all.sh +6 -2
- package/CHANGELOG.md +0 -198
- package/docs/archive/AUTO-DETECT-DEPS.md +0 -607
- package/docs/archive/FINAL-PACKAGE-STRATEGY.md +0 -583
- package/docs/archive/FINAL-SIMPLE-PLAN.md +0 -487
- package/docs/archive/FINAL-STATUS.md +0 -144
- package/docs/archive/FLOW-DIAGRAM.md +0 -1629
- package/docs/archive/GOTCHAS-AND-RISKS.md +0 -801
- package/docs/archive/IMPLEMENTATION-PLAN.md +0 -1360
- package/docs/archive/PLAN.md +0 -453
- package/docs/archive/PRODUCTION-READINESS.md +0 -684
- package/docs/archive/PRODUCTION-TEST-RESULTS.md +0 -465
- package/docs/archive/SIMPLIFIED-PLAN.md +0 -578
- package/docs/archive/STATUS.md +0 -199
- package/docs/archive/SUCCESS.md +0 -259
- package/docs/archive/TEST-SUMMARY.md +0 -261
- package/docs/archive/TESTING-CHECKLIST.md +0 -450
- package/docs/archive/USER-MODIFICATIONS.md +0 -448
- package/docs/decisions.md +0 -55
- package/docs/manual-testing.md +0 -91
- package/docs/next-steps.md +0 -12
- package/recipes/README.md +0 -156
- package/recipes/audio-recorder-supabase/packages/backend/src/services/recordings.ts +0 -369
- package/recipes/chatbot/apps/native/src/api-client/chatbot.ts +0 -83
- package/recipes/chatbot/packages/backend/convex/agents.ts +0 -115
- package/recipes/chatbot/packages/backend/convex/tools/index.ts +0 -18
- package/recipes/chatbot/packages/backend/convex/tools/knowledgeRetrieval.ts +0 -97
- package/recipes/chatbot/packages/backend/convex/tools/tavilySearch.ts +0 -83
- package/recipes/chatbot/packages/backend/convex/tools/userProfile.ts +0 -72
- package/recipes/chatbot-supabase/apps/native/src/api-client/supabase/chatbot.ts +0 -515
- package/recipes/chatbot-supabase/packages/backend/src/services/conversations.ts +0 -243
- package/recipes/chatbot-supabase/packages/backend/src/services/messages.ts +0 -327
- package/recipes/image-analysis/apps/native/src/api-client/image-analyzer.ts +0 -62
- package/recipes/image-analysis-supabase/packages/backend/src/services/image-analyses.ts +0 -132
- package/recipes/image-generator/apps/native/src/api-client/image-generator.ts +0 -34
- package/recipes/payments/apps/native/src/api-client/payments.ts +0 -44
- package/recipes/payments-supabase/packages/backend/src/services/payments.ts +0 -201
- package/recipes/posthog.json +0 -47
- package/recipes/revenuecat.json +0 -43
- package/recipes/sentry.json +0 -47
- package/recipes/wake-word/apps/native/assets/vosk-model/README.md +0 -103
- package/recipes/wake-word/apps/native/scripts/download-vosk-model.mjs +0 -127
- /package/recipes/{audio-recorder/apps/native/src/app/(root)/(protected) → audio-recorder-supabase/apps/native/src/app}/audio-recorder/index.tsx +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/AppIntent.swift +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Assets.xcassets/AppIcon.appiconset/App-Icon-20x20@1x.png +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Assets.xcassets/AppIcon.appiconset/App-Icon-20x20@2x.png +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Assets.xcassets/AppIcon.appiconset/App-Icon-20x20@3x.png +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Assets.xcassets/AppIcon.appiconset/App-Icon-29x29@1x.png +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Assets.xcassets/AppIcon.appiconset/App-Icon-29x29@2x.png +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Assets.xcassets/AppIcon.appiconset/App-Icon-29x29@3x.png +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Assets.xcassets/AppIcon.appiconset/App-Icon-40x40@1x.png +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Assets.xcassets/AppIcon.appiconset/App-Icon-40x40@2x.png +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Assets.xcassets/AppIcon.appiconset/App-Icon-40x40@3x.png +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Assets.xcassets/AppIcon.appiconset/App-Icon-60x60@2x.png +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Assets.xcassets/AppIcon.appiconset/App-Icon-60x60@3x.png +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Assets.xcassets/AppIcon.appiconset/App-Icon-76x76@1x.png +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Assets.xcassets/AppIcon.appiconset/App-Icon-76x76@2x.png +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Assets.xcassets/AppIcon.appiconset/App-Icon-83.5x83.5@2x.png +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Assets.xcassets/AppIcon.appiconset/Contents.json +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Assets.xcassets/AppIcon.appiconset/ItunesArtwork@2x.png +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/CalorieTrackerWidget.swift +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/HabitTrackerWidget.swift +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/Info.plist +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/WidgetLiveActivity.swift +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/expo-target.config.js +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/generated.entitlements +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/index.swift +0 -0
- /package/recipes/ios-widget/{targets → apps/native/targets}/widget/widgets.swift +0 -0
|
@@ -0,0 +1,352 @@
|
|
|
1
|
+
import { Ionicons } from '@expo/vector-icons';
|
|
2
|
+
import { BottomSheetScrollView } from '@gorhom/bottom-sheet';
|
|
3
|
+
import React, { forwardRef, useImperativeHandle, useState } from 'react';
|
|
4
|
+
import { View } from 'react-native';
|
|
5
|
+
import Animated, { FadeInDown } from 'react-native-reanimated';
|
|
6
|
+
|
|
7
|
+
import { Button, Pressable, Text } from '@/components/ui';
|
|
8
|
+
import { Modal, useModal } from '@/components/ui/core/overlays/modal';
|
|
9
|
+
|
|
10
|
+
import {
|
|
11
|
+
FITNESS_COLORS,
|
|
12
|
+
TIMER_PRESETS,
|
|
13
|
+
type TimerMode,
|
|
14
|
+
type TimerPreset,
|
|
15
|
+
} from '../constants';
|
|
16
|
+
|
|
17
|
+
export type TimerSettings = {
|
|
18
|
+
mode: TimerMode;
|
|
19
|
+
workDuration: number;
|
|
20
|
+
restDuration: number;
|
|
21
|
+
rounds: number;
|
|
22
|
+
soundEnabled: boolean;
|
|
23
|
+
hapticEnabled: boolean;
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
export type TimerSettingsModalRef = {
|
|
27
|
+
open: (currentSettings: TimerSettings) => void;
|
|
28
|
+
close: () => void;
|
|
29
|
+
};
|
|
30
|
+
|
|
31
|
+
type TimerSettingsModalProps = {
|
|
32
|
+
onSave: (settings: TimerSettings) => void;
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
const DURATION_OPTIONS = [10, 15, 20, 30, 45, 60, 90, 120];
|
|
36
|
+
const ROUND_OPTIONS = [4, 6, 8, 10, 12, 15, 20];
|
|
37
|
+
|
|
38
|
+
export const TimerSettingsModal = forwardRef<
|
|
39
|
+
TimerSettingsModalRef,
|
|
40
|
+
TimerSettingsModalProps
|
|
41
|
+
>(({ onSave }, ref) => {
|
|
42
|
+
const modal = useModal();
|
|
43
|
+
const [settings, setSettings] = useState<TimerSettings>({
|
|
44
|
+
mode: 'interval',
|
|
45
|
+
workDuration: 45,
|
|
46
|
+
restDuration: 15,
|
|
47
|
+
rounds: 8,
|
|
48
|
+
soundEnabled: true,
|
|
49
|
+
hapticEnabled: true,
|
|
50
|
+
});
|
|
51
|
+
|
|
52
|
+
useImperativeHandle(ref, () => ({
|
|
53
|
+
open: (currentSettings: TimerSettings) => {
|
|
54
|
+
setSettings(currentSettings);
|
|
55
|
+
modal.present();
|
|
56
|
+
},
|
|
57
|
+
close: () => modal.dismiss(),
|
|
58
|
+
}));
|
|
59
|
+
|
|
60
|
+
const handlePresetSelect = (preset: TimerPreset) => {
|
|
61
|
+
setSettings((prev) => ({
|
|
62
|
+
...prev,
|
|
63
|
+
mode: preset.mode,
|
|
64
|
+
workDuration: preset.workDuration,
|
|
65
|
+
restDuration: preset.restDuration,
|
|
66
|
+
rounds: preset.rounds,
|
|
67
|
+
}));
|
|
68
|
+
};
|
|
69
|
+
|
|
70
|
+
const handleSave = () => {
|
|
71
|
+
onSave(settings);
|
|
72
|
+
modal.dismiss();
|
|
73
|
+
};
|
|
74
|
+
|
|
75
|
+
const formatDuration = (seconds: number) => {
|
|
76
|
+
if (seconds >= 60) {
|
|
77
|
+
const mins = Math.floor(seconds / 60);
|
|
78
|
+
const secs = seconds % 60;
|
|
79
|
+
return secs > 0 ? `${mins}m ${secs}s` : `${mins}m`;
|
|
80
|
+
}
|
|
81
|
+
return `${seconds}s`;
|
|
82
|
+
};
|
|
83
|
+
|
|
84
|
+
return (
|
|
85
|
+
<Modal ref={modal.ref} title="Timer Settings" snapPoints={['85%']}>
|
|
86
|
+
<BottomSheetScrollView
|
|
87
|
+
contentContainerStyle={{ paddingHorizontal: 16, paddingBottom: 24 }}
|
|
88
|
+
showsVerticalScrollIndicator={false}
|
|
89
|
+
>
|
|
90
|
+
{/* Mode Presets */}
|
|
91
|
+
<View className="mb-6">
|
|
92
|
+
<Text className="text-zinc-400 text-xs font-bold uppercase tracking-widest mb-3">
|
|
93
|
+
Workout Mode
|
|
94
|
+
</Text>
|
|
95
|
+
<View className="flex-row flex-wrap gap-2">
|
|
96
|
+
{TIMER_PRESETS.map((preset, index) => {
|
|
97
|
+
const isSelected = settings.mode === preset.mode;
|
|
98
|
+
return (
|
|
99
|
+
<Animated.View
|
|
100
|
+
key={preset.id}
|
|
101
|
+
entering={FadeInDown.delay(index * 50)}
|
|
102
|
+
className="flex-1 min-w-[45%]"
|
|
103
|
+
>
|
|
104
|
+
<Pressable
|
|
105
|
+
onPress={() => handlePresetSelect(preset)}
|
|
106
|
+
className="p-4 rounded-2xl border-2"
|
|
107
|
+
style={{
|
|
108
|
+
backgroundColor: isSelected
|
|
109
|
+
? `${FITNESS_COLORS.primary}15`
|
|
110
|
+
: FITNESS_COLORS.card,
|
|
111
|
+
borderColor: isSelected
|
|
112
|
+
? FITNESS_COLORS.primary
|
|
113
|
+
: FITNESS_COLORS.card,
|
|
114
|
+
}}
|
|
115
|
+
>
|
|
116
|
+
<View className="flex-row items-center gap-2 mb-1">
|
|
117
|
+
<Ionicons
|
|
118
|
+
name={preset.icon}
|
|
119
|
+
size={20}
|
|
120
|
+
color={
|
|
121
|
+
isSelected
|
|
122
|
+
? FITNESS_COLORS.primary
|
|
123
|
+
: FITNESS_COLORS.textMuted
|
|
124
|
+
}
|
|
125
|
+
/>
|
|
126
|
+
<Text
|
|
127
|
+
className="font-bold"
|
|
128
|
+
style={{
|
|
129
|
+
color: isSelected
|
|
130
|
+
? FITNESS_COLORS.primary
|
|
131
|
+
: FITNESS_COLORS.text,
|
|
132
|
+
}}
|
|
133
|
+
>
|
|
134
|
+
{preset.name}
|
|
135
|
+
</Text>
|
|
136
|
+
</View>
|
|
137
|
+
<Text className="text-zinc-500 text-xs">
|
|
138
|
+
{preset.description}
|
|
139
|
+
</Text>
|
|
140
|
+
</Pressable>
|
|
141
|
+
</Animated.View>
|
|
142
|
+
);
|
|
143
|
+
})}
|
|
144
|
+
</View>
|
|
145
|
+
</View>
|
|
146
|
+
|
|
147
|
+
{/* Work Duration */}
|
|
148
|
+
<View className="mb-5">
|
|
149
|
+
<Text className="text-zinc-400 text-xs font-bold uppercase tracking-widest mb-3">
|
|
150
|
+
Work Duration
|
|
151
|
+
</Text>
|
|
152
|
+
<View className="flex-row flex-wrap gap-2">
|
|
153
|
+
{DURATION_OPTIONS.map((duration) => (
|
|
154
|
+
<Pressable
|
|
155
|
+
key={duration}
|
|
156
|
+
onPress={() =>
|
|
157
|
+
setSettings((prev) => ({ ...prev, workDuration: duration }))
|
|
158
|
+
}
|
|
159
|
+
className="px-4 py-2 rounded-xl"
|
|
160
|
+
style={{
|
|
161
|
+
backgroundColor:
|
|
162
|
+
settings.workDuration === duration
|
|
163
|
+
? FITNESS_COLORS.work
|
|
164
|
+
: FITNESS_COLORS.card,
|
|
165
|
+
}}
|
|
166
|
+
>
|
|
167
|
+
<Text
|
|
168
|
+
className="font-bold"
|
|
169
|
+
style={{
|
|
170
|
+
color:
|
|
171
|
+
settings.workDuration === duration
|
|
172
|
+
? FITNESS_COLORS.background
|
|
173
|
+
: FITNESS_COLORS.text,
|
|
174
|
+
}}
|
|
175
|
+
>
|
|
176
|
+
{formatDuration(duration)}
|
|
177
|
+
</Text>
|
|
178
|
+
</Pressable>
|
|
179
|
+
))}
|
|
180
|
+
</View>
|
|
181
|
+
</View>
|
|
182
|
+
|
|
183
|
+
{/* Rest Duration (hidden for countdown/emom) */}
|
|
184
|
+
{settings.mode !== 'countdown' && settings.mode !== 'emom' && (
|
|
185
|
+
<View className="mb-5">
|
|
186
|
+
<Text className="text-zinc-400 text-xs font-bold uppercase tracking-widest mb-3">
|
|
187
|
+
Rest Duration
|
|
188
|
+
</Text>
|
|
189
|
+
<View className="flex-row flex-wrap gap-2">
|
|
190
|
+
{DURATION_OPTIONS.filter((d) => d <= 60).map((duration) => (
|
|
191
|
+
<Pressable
|
|
192
|
+
key={duration}
|
|
193
|
+
onPress={() =>
|
|
194
|
+
setSettings((prev) => ({ ...prev, restDuration: duration }))
|
|
195
|
+
}
|
|
196
|
+
className="px-4 py-2 rounded-xl"
|
|
197
|
+
style={{
|
|
198
|
+
backgroundColor:
|
|
199
|
+
settings.restDuration === duration
|
|
200
|
+
? FITNESS_COLORS.rest
|
|
201
|
+
: FITNESS_COLORS.card,
|
|
202
|
+
}}
|
|
203
|
+
>
|
|
204
|
+
<Text
|
|
205
|
+
className="font-bold"
|
|
206
|
+
style={{
|
|
207
|
+
color:
|
|
208
|
+
settings.restDuration === duration
|
|
209
|
+
? FITNESS_COLORS.background
|
|
210
|
+
: FITNESS_COLORS.text,
|
|
211
|
+
}}
|
|
212
|
+
>
|
|
213
|
+
{formatDuration(duration)}
|
|
214
|
+
</Text>
|
|
215
|
+
</Pressable>
|
|
216
|
+
))}
|
|
217
|
+
</View>
|
|
218
|
+
</View>
|
|
219
|
+
)}
|
|
220
|
+
|
|
221
|
+
{/* Rounds (hidden for countdown) */}
|
|
222
|
+
{settings.mode !== 'countdown' && (
|
|
223
|
+
<View className="mb-5">
|
|
224
|
+
<Text className="text-zinc-400 text-xs font-bold uppercase tracking-widest mb-3">
|
|
225
|
+
Rounds
|
|
226
|
+
</Text>
|
|
227
|
+
<View className="flex-row flex-wrap gap-2">
|
|
228
|
+
{ROUND_OPTIONS.map((round) => (
|
|
229
|
+
<Pressable
|
|
230
|
+
key={round}
|
|
231
|
+
onPress={() =>
|
|
232
|
+
setSettings((prev) => ({ ...prev, rounds: round }))
|
|
233
|
+
}
|
|
234
|
+
className="w-12 h-12 rounded-xl items-center justify-center"
|
|
235
|
+
style={{
|
|
236
|
+
backgroundColor:
|
|
237
|
+
settings.rounds === round
|
|
238
|
+
? FITNESS_COLORS.primary
|
|
239
|
+
: FITNESS_COLORS.card,
|
|
240
|
+
}}
|
|
241
|
+
>
|
|
242
|
+
<Text
|
|
243
|
+
className="font-black text-lg"
|
|
244
|
+
style={{
|
|
245
|
+
color:
|
|
246
|
+
settings.rounds === round
|
|
247
|
+
? FITNESS_COLORS.background
|
|
248
|
+
: FITNESS_COLORS.text,
|
|
249
|
+
}}
|
|
250
|
+
>
|
|
251
|
+
{round}
|
|
252
|
+
</Text>
|
|
253
|
+
</Pressable>
|
|
254
|
+
))}
|
|
255
|
+
</View>
|
|
256
|
+
</View>
|
|
257
|
+
)}
|
|
258
|
+
|
|
259
|
+
{/* Toggle Options */}
|
|
260
|
+
<View className="mb-6">
|
|
261
|
+
<Text className="text-zinc-400 text-xs font-bold uppercase tracking-widest mb-3">
|
|
262
|
+
Feedback
|
|
263
|
+
</Text>
|
|
264
|
+
<View className="gap-3">
|
|
265
|
+
<Pressable
|
|
266
|
+
onPress={() =>
|
|
267
|
+
setSettings((prev) => ({
|
|
268
|
+
...prev,
|
|
269
|
+
soundEnabled: !prev.soundEnabled,
|
|
270
|
+
}))
|
|
271
|
+
}
|
|
272
|
+
className="flex-row items-center justify-between p-4 rounded-2xl"
|
|
273
|
+
style={{ backgroundColor: FITNESS_COLORS.card }}
|
|
274
|
+
>
|
|
275
|
+
<View className="flex-row items-center gap-3">
|
|
276
|
+
<Ionicons
|
|
277
|
+
name="volume-high"
|
|
278
|
+
size={22}
|
|
279
|
+
color={FITNESS_COLORS.textMuted}
|
|
280
|
+
/>
|
|
281
|
+
<Text className="text-white font-medium">Sound Cues</Text>
|
|
282
|
+
</View>
|
|
283
|
+
<View
|
|
284
|
+
className="w-12 h-7 rounded-full justify-center px-1"
|
|
285
|
+
style={{
|
|
286
|
+
backgroundColor: settings.soundEnabled
|
|
287
|
+
? FITNESS_COLORS.primary
|
|
288
|
+
: '#3f3f46',
|
|
289
|
+
}}
|
|
290
|
+
>
|
|
291
|
+
<View
|
|
292
|
+
className="w-5 h-5 rounded-full bg-white"
|
|
293
|
+
style={{
|
|
294
|
+
alignSelf: settings.soundEnabled
|
|
295
|
+
? 'flex-end'
|
|
296
|
+
: 'flex-start',
|
|
297
|
+
}}
|
|
298
|
+
/>
|
|
299
|
+
</View>
|
|
300
|
+
</Pressable>
|
|
301
|
+
|
|
302
|
+
<Pressable
|
|
303
|
+
onPress={() =>
|
|
304
|
+
setSettings((prev) => ({
|
|
305
|
+
...prev,
|
|
306
|
+
hapticEnabled: !prev.hapticEnabled,
|
|
307
|
+
}))
|
|
308
|
+
}
|
|
309
|
+
className="flex-row items-center justify-between p-4 rounded-2xl"
|
|
310
|
+
style={{ backgroundColor: FITNESS_COLORS.card }}
|
|
311
|
+
>
|
|
312
|
+
<View className="flex-row items-center gap-3">
|
|
313
|
+
<Ionicons
|
|
314
|
+
name="phone-portrait"
|
|
315
|
+
size={22}
|
|
316
|
+
color={FITNESS_COLORS.textMuted}
|
|
317
|
+
/>
|
|
318
|
+
<Text className="text-white font-medium">Haptic Feedback</Text>
|
|
319
|
+
</View>
|
|
320
|
+
<View
|
|
321
|
+
className="w-12 h-7 rounded-full justify-center px-1"
|
|
322
|
+
style={{
|
|
323
|
+
backgroundColor: settings.hapticEnabled
|
|
324
|
+
? FITNESS_COLORS.primary
|
|
325
|
+
: '#3f3f46',
|
|
326
|
+
}}
|
|
327
|
+
>
|
|
328
|
+
<View
|
|
329
|
+
className="w-5 h-5 rounded-full bg-white"
|
|
330
|
+
style={{
|
|
331
|
+
alignSelf: settings.hapticEnabled
|
|
332
|
+
? 'flex-end'
|
|
333
|
+
: 'flex-start',
|
|
334
|
+
}}
|
|
335
|
+
/>
|
|
336
|
+
</View>
|
|
337
|
+
</Pressable>
|
|
338
|
+
</View>
|
|
339
|
+
</View>
|
|
340
|
+
|
|
341
|
+
{/* Save Button */}
|
|
342
|
+
<Button
|
|
343
|
+
label="Apply Settings"
|
|
344
|
+
onPress={handleSave}
|
|
345
|
+
className="mt-4 mb-4"
|
|
346
|
+
style={{ backgroundColor: FITNESS_COLORS.primary }}
|
|
347
|
+
textClassName="text-zinc-950 font-bold"
|
|
348
|
+
/>
|
|
349
|
+
</BottomSheetScrollView>
|
|
350
|
+
</Modal>
|
|
351
|
+
);
|
|
352
|
+
});
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
import { Ionicons } from '@expo/vector-icons';
|
|
2
|
+
import { LinearGradient } from 'expo-linear-gradient';
|
|
3
|
+
import React from 'react';
|
|
4
|
+
import { ImageBackground, TouchableOpacity, View } from 'react-native';
|
|
5
|
+
import Animated, { FadeInRight } from 'react-native-reanimated';
|
|
6
|
+
|
|
7
|
+
import { Text } from '@/components/ui';
|
|
8
|
+
|
|
9
|
+
import { FITNESS_COLORS } from '../constants';
|
|
10
|
+
|
|
11
|
+
interface WorkoutCardProps {
|
|
12
|
+
item: {
|
|
13
|
+
id: string;
|
|
14
|
+
title: string;
|
|
15
|
+
duration: string;
|
|
16
|
+
cals: number;
|
|
17
|
+
difficulty: string;
|
|
18
|
+
image: string;
|
|
19
|
+
exercises: number;
|
|
20
|
+
};
|
|
21
|
+
index: number;
|
|
22
|
+
onPress: () => void;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
export default function WorkoutCard({
|
|
26
|
+
item,
|
|
27
|
+
index,
|
|
28
|
+
onPress,
|
|
29
|
+
}: WorkoutCardProps) {
|
|
30
|
+
return (
|
|
31
|
+
<Animated.View
|
|
32
|
+
entering={FadeInRight.delay(index * 100).springify()}
|
|
33
|
+
className="mr-5 w-72 h-44 rounded-3xl overflow-hidden"
|
|
34
|
+
>
|
|
35
|
+
<TouchableOpacity
|
|
36
|
+
activeOpacity={0.9}
|
|
37
|
+
onPress={onPress}
|
|
38
|
+
className="flex-1"
|
|
39
|
+
>
|
|
40
|
+
<ImageBackground
|
|
41
|
+
source={{ uri: item.image }}
|
|
42
|
+
className="flex-1 justify-end p-4"
|
|
43
|
+
resizeMode="cover"
|
|
44
|
+
>
|
|
45
|
+
<LinearGradient
|
|
46
|
+
colors={['transparent', 'rgba(0,0,0,0.8)']}
|
|
47
|
+
style={{
|
|
48
|
+
position: 'absolute',
|
|
49
|
+
left: 0,
|
|
50
|
+
right: 0,
|
|
51
|
+
bottom: 0,
|
|
52
|
+
height: '70%',
|
|
53
|
+
}}
|
|
54
|
+
/>
|
|
55
|
+
|
|
56
|
+
<View className="flex-row justify-between items-start mb-auto">
|
|
57
|
+
<View className="bg-black/40 px-3 py-1.5 rounded-full backdrop-blur-md border border-white/10">
|
|
58
|
+
<Text className="text-xs font-bold text-white uppercase tracking-wider">
|
|
59
|
+
{item.difficulty}
|
|
60
|
+
</Text>
|
|
61
|
+
</View>
|
|
62
|
+
</View>
|
|
63
|
+
|
|
64
|
+
<View>
|
|
65
|
+
<Text className="text-white font-bold text-xl mb-1">
|
|
66
|
+
{item.title}
|
|
67
|
+
</Text>
|
|
68
|
+
<View className="flex-row items-center space-x-4">
|
|
69
|
+
<View className="flex-row items-center">
|
|
70
|
+
<Ionicons
|
|
71
|
+
name="time-outline"
|
|
72
|
+
size={14}
|
|
73
|
+
color={FITNESS_COLORS.textMuted}
|
|
74
|
+
/>
|
|
75
|
+
<Text className="text-gray-300 text-xs ml-1 font-medium">
|
|
76
|
+
{item.duration}
|
|
77
|
+
</Text>
|
|
78
|
+
</View>
|
|
79
|
+
<View className="flex-row items-center ml-4">
|
|
80
|
+
<Ionicons
|
|
81
|
+
name="flame-outline"
|
|
82
|
+
size={14}
|
|
83
|
+
color={FITNESS_COLORS.orange}
|
|
84
|
+
/>
|
|
85
|
+
<Text className="text-gray-300 text-xs ml-1 font-medium">
|
|
86
|
+
{item.cals} kCal
|
|
87
|
+
</Text>
|
|
88
|
+
</View>
|
|
89
|
+
<View className="flex-row items-center ml-4">
|
|
90
|
+
<Ionicons
|
|
91
|
+
name="barbell-outline"
|
|
92
|
+
size={14}
|
|
93
|
+
color={FITNESS_COLORS.accent}
|
|
94
|
+
/>
|
|
95
|
+
<Text className="text-gray-300 text-xs ml-1 font-medium">
|
|
96
|
+
{item.exercises} Exercises
|
|
97
|
+
</Text>
|
|
98
|
+
</View>
|
|
99
|
+
</View>
|
|
100
|
+
</View>
|
|
101
|
+
</ImageBackground>
|
|
102
|
+
</TouchableOpacity>
|
|
103
|
+
</Animated.View>
|
|
104
|
+
);
|
|
105
|
+
}
|
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
import type { Ionicons } from '@expo/vector-icons';
|
|
2
|
+
|
|
3
|
+
export const FITNESS_COLORS = {
|
|
4
|
+
primary: '#CCF381', // Neon Lime (Keep as brand)
|
|
5
|
+
background: '#09090b', // Zinc 950
|
|
6
|
+
card: '#18181b', // Zinc 900
|
|
7
|
+
text: '#ffffff',
|
|
8
|
+
textMuted: '#a1a1aa', // Zinc 400
|
|
9
|
+
accent: '#4834d4', // Deep Blue
|
|
10
|
+
success: '#6ab04c', // Grass Green
|
|
11
|
+
warning: '#f0932b', // Orange
|
|
12
|
+
danger: '#eb4d4b', // Red
|
|
13
|
+
ring1: '#ff0055', // Neon Red/Pink
|
|
14
|
+
ring2: '#00ccff', // Neon Cyan
|
|
15
|
+
ring3: '#ccf381', // Neon Lime (Matches Primary)
|
|
16
|
+
orange: '#f0932b',
|
|
17
|
+
// Timer-specific colors
|
|
18
|
+
work: '#CCF381', // Lime for work phase
|
|
19
|
+
rest: '#00ccff', // Cyan for rest phase
|
|
20
|
+
getReady: '#f0932b', // Orange for countdown
|
|
21
|
+
complete: '#6ab04c', // Green for completion
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
// Timer Types
|
|
25
|
+
export type TimerMode = 'countdown' | 'interval' | 'tabata' | 'emom';
|
|
26
|
+
export type TimerPhase = 'idle' | 'getReady' | 'work' | 'rest' | 'complete';
|
|
27
|
+
|
|
28
|
+
export type Exercise = {
|
|
29
|
+
id: string;
|
|
30
|
+
name: string;
|
|
31
|
+
duration: number; // in seconds
|
|
32
|
+
icon: keyof typeof Ionicons.glyphMap;
|
|
33
|
+
tip: string;
|
|
34
|
+
};
|
|
35
|
+
|
|
36
|
+
export type TimerPreset = {
|
|
37
|
+
id: string;
|
|
38
|
+
name: string;
|
|
39
|
+
mode: TimerMode;
|
|
40
|
+
icon: keyof typeof Ionicons.glyphMap;
|
|
41
|
+
workDuration: number;
|
|
42
|
+
restDuration: number;
|
|
43
|
+
rounds: number;
|
|
44
|
+
description: string;
|
|
45
|
+
};
|
|
46
|
+
|
|
47
|
+
// Timer mode presets
|
|
48
|
+
export const TIMER_PRESETS: TimerPreset[] = [
|
|
49
|
+
{
|
|
50
|
+
id: 'countdown',
|
|
51
|
+
name: 'Countdown',
|
|
52
|
+
mode: 'countdown',
|
|
53
|
+
icon: 'timer-outline',
|
|
54
|
+
workDuration: 60,
|
|
55
|
+
restDuration: 0,
|
|
56
|
+
rounds: 1,
|
|
57
|
+
description: 'Simple countdown timer',
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
id: 'interval',
|
|
61
|
+
name: 'Intervals',
|
|
62
|
+
mode: 'interval',
|
|
63
|
+
icon: 'repeat',
|
|
64
|
+
workDuration: 45,
|
|
65
|
+
restDuration: 15,
|
|
66
|
+
rounds: 8,
|
|
67
|
+
description: 'Work/rest intervals',
|
|
68
|
+
},
|
|
69
|
+
{
|
|
70
|
+
id: 'tabata',
|
|
71
|
+
name: 'Tabata',
|
|
72
|
+
mode: 'tabata',
|
|
73
|
+
icon: 'flash',
|
|
74
|
+
workDuration: 20,
|
|
75
|
+
restDuration: 10,
|
|
76
|
+
rounds: 8,
|
|
77
|
+
description: '20s work / 10s rest × 8',
|
|
78
|
+
},
|
|
79
|
+
{
|
|
80
|
+
id: 'emom',
|
|
81
|
+
name: 'EMOM',
|
|
82
|
+
mode: 'emom',
|
|
83
|
+
icon: 'stopwatch',
|
|
84
|
+
workDuration: 60,
|
|
85
|
+
restDuration: 0,
|
|
86
|
+
rounds: 10,
|
|
87
|
+
description: 'Every Minute on the Minute',
|
|
88
|
+
},
|
|
89
|
+
];
|
|
90
|
+
|
|
91
|
+
// Sample exercise queue
|
|
92
|
+
export const SAMPLE_EXERCISES: Exercise[] = [
|
|
93
|
+
{
|
|
94
|
+
id: '1',
|
|
95
|
+
name: 'High Knees',
|
|
96
|
+
duration: 45,
|
|
97
|
+
icon: 'body',
|
|
98
|
+
tip: 'Keep your core tight and maintain a steady pace.',
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
id: '2',
|
|
102
|
+
name: 'Burpees',
|
|
103
|
+
duration: 45,
|
|
104
|
+
icon: 'fitness',
|
|
105
|
+
tip: 'Explode up from the ground with power.',
|
|
106
|
+
},
|
|
107
|
+
{
|
|
108
|
+
id: '3',
|
|
109
|
+
name: 'Mountain Climbers',
|
|
110
|
+
duration: 45,
|
|
111
|
+
icon: 'walk',
|
|
112
|
+
tip: 'Drive your knees toward your chest rapidly.',
|
|
113
|
+
},
|
|
114
|
+
{
|
|
115
|
+
id: '4',
|
|
116
|
+
name: 'Jump Squats',
|
|
117
|
+
duration: 45,
|
|
118
|
+
icon: 'trending-up',
|
|
119
|
+
tip: 'Land softly and immediately sink into the next squat.',
|
|
120
|
+
},
|
|
121
|
+
{
|
|
122
|
+
id: '5',
|
|
123
|
+
name: 'Plank Hold',
|
|
124
|
+
duration: 60,
|
|
125
|
+
icon: 'body',
|
|
126
|
+
tip: 'Keep your body in a straight line from head to heels.',
|
|
127
|
+
},
|
|
128
|
+
];
|
|
129
|
+
|
|
130
|
+
// Phase colors mapping
|
|
131
|
+
export const PHASE_COLORS: Record<TimerPhase, string> = {
|
|
132
|
+
idle: FITNESS_COLORS.textMuted,
|
|
133
|
+
getReady: FITNESS_COLORS.getReady,
|
|
134
|
+
work: FITNESS_COLORS.work,
|
|
135
|
+
rest: FITNESS_COLORS.rest,
|
|
136
|
+
complete: FITNESS_COLORS.complete,
|
|
137
|
+
};
|
|
138
|
+
|
|
139
|
+
// Phase labels
|
|
140
|
+
export const PHASE_LABELS: Record<TimerPhase, string> = {
|
|
141
|
+
idle: 'READY',
|
|
142
|
+
getReady: 'GET READY',
|
|
143
|
+
work: 'WORK',
|
|
144
|
+
rest: 'REST',
|
|
145
|
+
complete: 'COMPLETE',
|
|
146
|
+
};
|
|
147
|
+
|
|
148
|
+
export const MOCK_WORKOUTS = [
|
|
149
|
+
{
|
|
150
|
+
id: '1',
|
|
151
|
+
title: 'Full Body Crush',
|
|
152
|
+
duration: '45 min',
|
|
153
|
+
cals: 320,
|
|
154
|
+
difficulty: 'Advanced',
|
|
155
|
+
image:
|
|
156
|
+
'https://images.unsplash.com/photo-1517836357463-d25dfeac3438?w=800&q=80',
|
|
157
|
+
exercises: 8,
|
|
158
|
+
},
|
|
159
|
+
{
|
|
160
|
+
id: '2',
|
|
161
|
+
title: 'Morning Yoga Flow',
|
|
162
|
+
duration: '20 min',
|
|
163
|
+
cals: 120,
|
|
164
|
+
difficulty: 'Beginner',
|
|
165
|
+
image:
|
|
166
|
+
'https://images.unsplash.com/photo-1544367563-121955375ebb?w=800&q=80',
|
|
167
|
+
exercises: 5,
|
|
168
|
+
},
|
|
169
|
+
{
|
|
170
|
+
id: '3',
|
|
171
|
+
title: 'HIIT Cardio',
|
|
172
|
+
duration: '30 min',
|
|
173
|
+
cals: 450,
|
|
174
|
+
difficulty: 'Intermediate',
|
|
175
|
+
image:
|
|
176
|
+
'https://images.unsplash.com/photo-1601422407692-ec4eeec1d9b3?w=800&q=80',
|
|
177
|
+
exercises: 12,
|
|
178
|
+
},
|
|
179
|
+
];
|
|
180
|
+
|
|
181
|
+
export const WEEKLY_STATS = [
|
|
182
|
+
{ day: 'M', value: 350, active: false },
|
|
183
|
+
{ day: 'T', value: 820, active: true },
|
|
184
|
+
{ day: 'W', value: 610, active: false },
|
|
185
|
+
{ day: 'T', value: 950, active: true },
|
|
186
|
+
{ day: 'F', value: 880, active: true },
|
|
187
|
+
{ day: 'S', value: 320, active: false },
|
|
188
|
+
{ day: 'S', value: 540, active: false },
|
|
189
|
+
];
|