diff --git a/ai_docs/agent/web_v2/task_list.json b/ai_docs/agent/web_v2/task_list.json index 751acba..fca2e47 100644 --- a/ai_docs/agent/web_v2/task_list.json +++ b/ai_docs/agent/web_v2/task_list.json @@ -1,8 +1,261 @@ { "project": "mnemo_cards_web_v2", "component": "web_v2", - "version": "1.1", - "generated_at": "2025-11-21T11:51:47.671045+00:00", + "version": "1.2", + "generated_at": "2025-01-21T23:27:35.316993+00:00", "generated_by": "planning_agent", - "tasks": [] -} \ No newline at end of file + "tasks": [ + { + "id": "WEB-001", + "title": "Complete PurchaseService Migration Verification", + "priority": "high", + "status": "pending", + "estimated_hours": 2, + "description": "Verify that PurchaseService is fully migrated to HttpRepositoryV2 and all API calls use v2 endpoints. Update any remaining v1 dependencies and ensure all tests pass with v2 API.", + "acceptance_criteria": [ + "PurchaseService uses only HttpRepositoryV2 (no v1 dependencies)", + "All API calls in PurchaseService use v2 endpoints", + "All existing PurchaseService tests pass", + "No deprecated v1 code remains in PurchaseService", + "Linter passes with zero warnings" + ], + "dependencies": [], + "files_to_modify": [ + "mnemo_cards_web_v2/lib/domain/services/purchases_service.dart", + "mnemo_cards_web_v2/test/domain/services/purchases_service_test.dart" + ], + "component": "web_v2" + }, + { + "id": "WEB-002", + "title": "Integrate Adsgram SDK into AdsRewardService", + "priority": "high", + "status": "pending", + "estimated_hours": 3, + "description": "Integrate the existing Adsgram SDK wrapper (adsgram_stub.dart) into AdsRewardService to show rewarded ads. Handle ad lifecycle (loading, showing, completion, errors) and connect to the service's acquireReward method.", + "acceptance_criteria": [ + "AdsRewardService can show rewarded ads using Adsgram SDK", + "Ad loading state is properly managed", + "Ad completion triggers acquireReward call", + "Ad errors are handled gracefully with user feedback", + "Ad lifecycle is properly managed (show, complete, error)", + "Unit tests cover ad show success and failure scenarios (5+ tests)" + ], + "dependencies": [], + "files_to_modify": [ + "mnemo_cards_web_v2/lib/domain/services/ads_reward_service.dart", + "mnemo_cards_web_v2/test/domain/services/ads_reward_service_test.dart" + ], + "component": "web_v2" + }, + { + "id": "WEB-003", + "title": "Create AdsRewardButton Widget", + "priority": "high", + "status": "pending", + "estimated_hours": 2, + "description": "Create a reusable AdsRewardButton widget that shows 'Unlock by watching ad' CTA when adsKey is present. The button should integrate with AdsRewardService, show loading states, handle errors, and refresh pack/user data after successful reward.", + "acceptance_criteria": [ + "AdsRewardButton widget created with proper styling", + "Button shows when adsKey is present in pack/product", + "Button shows loading state during ad playback", + "Button handles errors with user-friendly messages", + "Button refreshes pack/user purchases after successful reward", + "Widget tests cover all states (5+ tests)" + ], + "dependencies": ["WEB-002"], + "files_to_modify": [ + "mnemo_cards_web_v2/lib/presentation/widgets/ads_reward_button.dart", + "mnemo_cards_web_v2/test/presentation/widgets/ads_reward_button_test.dart" + ], + "component": "web_v2" + }, + { + "id": "WEB-004", + "title": "Add Ads Reward CTA to PackDetailsPage", + "priority": "high", + "status": "pending", + "estimated_hours": 2, + "description": "Integrate AdsRewardButton into PackDetailsPage. Show the 'Unlock by watching ad' button when pack has adsKey. Position it appropriately near purchase options and ensure it works with existing purchase flow.", + "acceptance_criteria": [ + "AdsRewardButton appears in PackDetailsPage when pack has adsKey", + "Button is positioned appropriately in UI", + "Button works correctly with existing purchase flow", + "Pack data refreshes after successful ad reward", + "User can see updated pack access status after reward" + ], + "dependencies": ["WEB-003"], + "files_to_modify": [ + "mnemo_cards_web_v2/lib/presentation/pages/pack_details/pack_details_page.dart" + ], + "component": "web_v2" + }, + { + "id": "WEB-005", + "title": "Add Buy Pack Button to PackDetailsPage", + "priority": "high", + "status": "pending", + "estimated_hours": 2, + "description": "Add a 'Buy Pack' button to PackDetailsPage that navigates to PurchasePage. The button should only show for unpurchased packs and integrate with the existing purchase status checking.", + "acceptance_criteria": [ + "'Buy Pack' button appears in PackDetailsPage for unpurchased packs", + "Button navigates to PurchasePage with correct packId", + "Button is hidden for already purchased packs", + "Button styling matches app design system", + "Button works correctly with purchase status checking" + ], + "dependencies": [], + "files_to_modify": [ + "mnemo_cards_web_v2/lib/presentation/pages/pack_details/pack_details_page.dart" + ], + "component": "web_v2" + }, + { + "id": "WEB-006", + "title": "Create SubscriptionPage UI", + "priority": "medium", + "status": "pending", + "estimated_hours": 3, + "description": "Create SubscriptionPage with subscription plans display, plan comparison, purchase flow, current subscription status, and management options (cancel/renew). Use existing SubscriptionService and SubscriptionPlansWidget as foundation.", + "acceptance_criteria": [ + "SubscriptionPage created with Material Design UI", + "Subscription plans are displayed correctly", + "Plan comparison and features are shown", + "Purchase flow for subscriptions works", + "Current subscription status is displayed", + "Subscription cancellation flow works", + "Page is responsive (mobile/tablet/desktop)", + "Widget tests cover main UI states (6+ tests)" + ], + "dependencies": ["backend:API-007"], + "files_to_modify": [ + "mnemo_cards_web_v2/lib/presentation/pages/subscription/subscription_page.dart", + "mnemo_cards_web_v2/test/presentation/pages/subscription/subscription_page_test.dart" + ], + "component": "web_v2" + }, + { + "id": "WEB-007", + "title": "Add Subscription Status to ProfilePage", + "priority": "medium", + "status": "pending", + "estimated_hours": 2, + "description": "Add subscription status display to ProfilePage showing current subscription plan, expiration date, and quick link to SubscriptionPage. Use SubscriptionService to fetch status.", + "acceptance_criteria": [ + "Subscription status displayed in ProfilePage", + "Current plan name and expiration date shown", + "Link to SubscriptionPage works correctly", + "Status updates when subscription changes", + "Loading and error states handled properly" + ], + "dependencies": ["WEB-006"], + "files_to_modify": [ + "mnemo_cards_web_v2/lib/presentation/pages/profile/profile_page.dart" + ], + "component": "web_v2" + }, + { + "id": "WEB-008", + "title": "Create PromocodeInput Widget", + "priority": "medium", + "status": "pending", + "estimated_hours": 2, + "description": "Create a reusable PromocodeInput widget with text field, validation, apply button, and discount display. The widget should use PromocodeService for validation and application.", + "acceptance_criteria": [ + "PromocodeInput widget created with text field and apply button", + "Promocode validation works using PromocodeService", + "Discount amount is displayed after successful application", + "Error messages shown for invalid/expired promocodes", + "Widget is reusable and properly styled", + "Widget tests cover validation and application (5+ tests)" + ], + "dependencies": ["backend:API-008"], + "files_to_modify": [ + "mnemo_cards_web_v2/lib/presentation/widgets/promocode_input.dart", + "mnemo_cards_web_v2/test/presentation/widgets/promocode_input_test.dart" + ], + "component": "web_v2" + }, + { + "id": "WEB-009", + "title": "Integrate PromocodeInput into PurchasePage", + "priority": "medium", + "status": "pending", + "estimated_hours": 2, + "description": "Add PromocodeInput widget to PurchasePage. Apply promocode discount to pack purchase price and pass promocode to payment creation if applicable.", + "acceptance_criteria": [ + "PromocodeInput appears in PurchasePage", + "Promocode discount is applied to purchase price", + "Discounted price is displayed correctly", + "Promocode is passed to payment creation", + "Promocode validation works in purchase flow" + ], + "dependencies": ["WEB-008"], + "files_to_modify": [ + "mnemo_cards_web_v2/lib/presentation/pages/purchase/purchase_page.dart" + ], + "component": "web_v2" + }, + { + "id": "WEB-010", + "title": "Integrate PromocodeInput into SubscriptionPage", + "priority": "medium", + "status": "pending", + "estimated_hours": 2, + "description": "Add PromocodeInput widget to SubscriptionPage. Apply promocode discount to subscription purchase price and pass promocode to subscription purchase if applicable.", + "acceptance_criteria": [ + "PromocodeInput appears in SubscriptionPage", + "Promocode discount is applied to subscription price", + "Discounted price is displayed correctly", + "Promocode is passed to subscription purchase", + "Promocode validation works in subscription flow" + ], + "dependencies": ["WEB-006", "WEB-008"], + "files_to_modify": [ + "mnemo_cards_web_v2/lib/presentation/pages/subscription/subscription_page.dart" + ], + "component": "web_v2" + }, + { + "id": "WEB-011", + "title": "Fix Empty Test Files", + "priority": "medium", + "status": "pending", + "estimated_hours": 2, + "description": "Fix 24 failing tests that are mostly empty test files. Investigate each failing test, add proper test implementations or remove obsolete tests, and ensure all tests compile and pass.", + "acceptance_criteria": [ + "All 24 failing tests are fixed or removed", + "All tests compile without errors", + "All tests pass successfully", + "No empty test files remain", + "Test coverage is maintained or improved" + ], + "dependencies": [], + "files_to_modify": [ + "mnemo_cards_web_v2/test/**/*_test.dart" + ], + "component": "web_v2" + }, + { + "id": "WEB-012", + "title": "Verify All API v2 Migrations Complete", + "priority": "high", + "status": "pending", + "estimated_hours": 2, + "description": "Final verification that all services are migrated to API v2. Check all services use HttpRepositoryV2, all API calls use v2 endpoints, no v1 dependencies remain, and all functionality works with v2 API.", + "acceptance_criteria": [ + "All services use HttpRepositoryV2 (no v1 dependencies)", + "All API calls use v2 endpoints", + "No deprecated v1 code remains in codebase", + "All tests pass with v2 API", + "All functionality verified working with v2", + "Linter passes with zero warnings" + ], + "dependencies": ["WEB-001"], + "files_to_modify": [ + "mnemo_cards_web_v2/lib/domain/services/**/*.dart" + ], + "component": "web_v2" + } + ] +}