Commit Graph

12 Commits

Author SHA1 Message Date
Paul Huliganga 9f49223df3 Add import telemetry logging for success and failure reasons 2026-03-25 00:07:38 -04:00
Paul Huliganga 1ca21889ca Add URL import retry/timeout handling and friendly failure messaging 2026-03-24 23:54:23 -04:00
Paul Huliganga d3eeeb2833 feat(import): add heuristic fallback parser for recipe URL imports 2026-03-24 23:43:41 -04:00
Paul Huliganga 87e9181e11 test(import): add malformed JSON-LD endpoint case 2026-03-24 22:02:10 -04:00
Paul Huliganga 3987083e46 feat(import): normalize parsed recipe into internal draft format 2026-03-24 21:47:27 -04:00
Paul Huliganga 64a1229ff0 feat(import): implement Schema.org Recipe JSON-LD parser and draft normalization for import endpoint 2026-03-24 20:37:46 -04:00
Paul Huliganga 146dc3325a feat(backend): add URL import endpoint foundation 2026-03-24 20:25:35 -04:00
Paul Huliganga afdc915aa2 fix(backend): remove require() usage in ESM database saver
Use writeFileSync import instead of require('fs') to avoid runtime
ReferenceError in Node ESM mode during periodic DB saves.
2026-03-24 20:04:28 -04:00
Paul Huliganga dbdbcf43fa feat(tags): implement tag management with create, assign, and display functionality
Backend:
- Add Tag type definitions (Tag, CreateTagInput, UpdateTagInput)
- Implement TagRepository with CRUD and recipe assignment methods
- Implement TagService with business logic and validation
- Create tag API routes (GET, POST, PUT, DELETE /api/tags)
- Add recipe-tag assignment endpoints (POST/DELETE /api/tags/recipes/:id/tags)
- Write 18 integration tests for tag functionality (all passing)
- Mount tag routes in main Express app

Frontend:
- Extend API client with tag CRUD and assignment methods
- Create useTags hook for tag state management
- Create TagSelector component for tag selection with inline tag creation
- Update RecipeForm to accept initialTags and pass selected tags to onSubmit
- Update RecipeDetailPage to fetch, display, and manage recipe tags
- Update RecipeCard to display tags with custom colors
- Add tag filter UI to RecipeListPage (note: backend filtering pending)
- Display tags in recipe detail view with color styling

Testing:
- All 34 backend tests passing (16 recipe + 18 tag tests)
- Frontend builds successfully with TypeScript strict mode
- Tag assignment and removal working end-to-end

Note: Tag filtering in recipe list shows UI but doesn't filter results yet.
Backend support for tag-based filtering can be added in future iteration.
2026-03-24 04:02:51 -04:00
Paul Huliganga e2599b81f4 feat(api): implement recipe CRUD API endpoints
- Add Recipe type definitions (Recipe, CreateRecipeInput, UpdateRecipeInput)
- Implement RecipeRepository for database operations (CRUD + search)
- Implement RecipeService with business logic validation
- Create Express routes with Zod validation schemas
- Add database initialization module with auto-save functionality
- Implement comprehensive integration tests (16 tests, all passing)
- Support pagination, search filtering, and proper error handling
- Follow layered architecture pattern (Routes → Services → Repositories)

All tests passing (16/16). TypeScript strict mode enabled.
2026-03-24 00:13:58 -04:00
Paul Huliganga 394aa22df1 feat(db): enable schema migration using sql.js and export to data/recipes.db 2026-03-24 00:01:41 -04:00
Paul Huliganga ed1f4f88be feat(backend): initialize Node.js project with Express 2026-03-23 23:40:36 -04:00