- Sync favorites capability spec and frontend-mall live-favorites requirement into openspec/specs/ - Split catalog spec into new category and product capability specs; remove now-empty catalog spec - Move both completed changes to openspec/changes/archive/ - Ignore .superpowers/ scratch directory
27 lines
1.5 KiB
Markdown
27 lines
1.5 KiB
Markdown
## Why
|
|
|
|
Favorites are the last existing mall UI capability that still reads fixed fixtures directly. Persisting product and shop favorites completes the buyer-center journey and makes the product-detail heart survive reloads without touching checkout or payment.
|
|
|
|
## What Changes
|
|
|
|
- Add customer-owned product and shop favorites with database-enforced target shape and per-target uniqueness.
|
|
- Add authenticated APIs to list, add, and remove each favorite kind; repeated add/remove operations are idempotent.
|
|
- Return current target data with each favorite so the Mall does not issue one request per saved item.
|
|
- Replace fixture-derived favorites, buyer-center previews/counts, and the product-detail local heart state with the shared live API contract.
|
|
- Keep equivalent fixed-data adapter behavior as the rollback implementation.
|
|
|
|
## Capabilities
|
|
|
|
### New Capabilities
|
|
- `favorites`: Customer ownership, product/shop target integrity, idempotent mutation, and target-aware listing.
|
|
|
|
### Modified Capabilities
|
|
- `frontend-mall`: Product detail and buyer-center favorites use the selected API adapter instead of local state and `MOCK_FAVORITES`.
|
|
|
|
## Non-goals
|
|
|
|
Favorite folders, notes, sharing, notifications, ranking, merchant analytics, bulk mutation, and automatic migration of fixture favorites are excluded.
|
|
|
|
## Impact
|
|
|
|
Adds one Postgres migration, a Rust favorites module and customer routes, shared types/API methods, a `favorites` live-domain pick, fixed-adapter parity, and Mall updates for product detail and buyer-center pages. |