feat: implement debug logging cleanup and i18n coverage proposals
## cleanup-debug-logging - Create environment-aware logger utility (logger.ts) - Replace 60+ console.log/error statements across 28 files - Production: only warn/error logs visible - Development: all log levels with prefixes Updated files: - Contexts: NotificationContext, ProjectSyncContext, AuthContext - Components: GanttChart, CalendarView, ErrorBoundary, and 11 others - Pages: Tasks, Projects, Dashboard, and 7 others - Services: api.ts ## complete-i18n-coverage - WeeklyReportPreview: all strings translated, dynamic locale - ReportHistory: all strings translated, dynamic locale - AuditPage: detail modal and verification modal translated - WorkloadPage: error message translated Locale files updated: - en/common.json, zh-TW/common.json: reports section - en/audit.json, zh-TW/audit.json: modal sections - en/workload.json, zh-TW/workload.json: errors section Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -1,28 +1,28 @@
|
||||
## 1. Create Logging Utility
|
||||
- [ ] 1.1 Create `utils/logger.ts` with environment-aware logging
|
||||
- [ ] 1.2 Export debug, info, warn, error functions
|
||||
- [ ] 1.3 Only output logs when `import.meta.env.DEV` is true
|
||||
- [x] 1.1 Create `utils/logger.ts` with environment-aware logging
|
||||
- [x] 1.2 Export debug, info, warn, error functions
|
||||
- [x] 1.3 Only output logs when `import.meta.env.DEV` is true
|
||||
|
||||
## 2. Cleanup Context Files
|
||||
- [ ] 2.1 Remove/replace console statements in NotificationContext.tsx
|
||||
- [ ] 2.2 Remove/replace console statements in ProjectSyncContext.tsx
|
||||
- [ ] 2.3 Remove/replace console statements in AuthContext.tsx
|
||||
- [x] 2.1 Remove/replace console statements in NotificationContext.tsx
|
||||
- [x] 2.2 Remove/replace console statements in ProjectSyncContext.tsx
|
||||
- [x] 2.3 Remove/replace console statements in AuthContext.tsx
|
||||
|
||||
## 3. Cleanup Component Files
|
||||
- [ ] 3.1 Remove/replace console statements in GanttChart.tsx
|
||||
- [ ] 3.2 Remove/replace console statements in CalendarView.tsx
|
||||
- [ ] 3.3 Audit and clean remaining components
|
||||
- [x] 3.1 Remove/replace console statements in GanttChart.tsx
|
||||
- [x] 3.2 Remove/replace console statements in CalendarView.tsx
|
||||
- [x] 3.3 Audit and clean remaining components
|
||||
|
||||
## 4. Cleanup Page Files
|
||||
- [ ] 4.1 Remove/replace console statements in Tasks.tsx
|
||||
- [ ] 4.2 Remove/replace console statements in other page files
|
||||
- [ ] 4.3 Audit and clean remaining pages
|
||||
- [x] 4.1 Remove/replace console statements in Tasks.tsx
|
||||
- [x] 4.2 Remove/replace console statements in other page files
|
||||
- [x] 4.3 Audit and clean remaining pages
|
||||
|
||||
## 5. Cleanup Service Files
|
||||
- [ ] 5.1 Remove/replace console statements in api.ts
|
||||
- [ ] 5.2 Audit and clean remaining services
|
||||
- [x] 5.1 Remove/replace console statements in api.ts
|
||||
- [x] 5.2 Audit and clean remaining services
|
||||
|
||||
## 6. Verification
|
||||
- [ ] 6.1 Run frontend build successfully
|
||||
- [ ] 6.2 Verify no console.log in production build
|
||||
- [ ] 6.3 Test error handling still works correctly
|
||||
- [x] 6.1 Run frontend build successfully
|
||||
- [x] 6.2 Verify no console.log in production build
|
||||
- [x] 6.3 Test error handling still works correctly
|
||||
|
||||
Reference in New Issue
Block a user