# Track Spec: Dashboard Shell Redesign & Core CRUD Cleanup

**Track ID**: `redesign_crud_cleanup_20260311`
**Status**: Draft
**Persona**: PO (Vision), Dev (Architecture), QA (Validation)

## 1. Goal
Redesign the Jomblo Admin Dashboard shell using `uncodixfy` and `shadcn/ui` and improve the reliability of the core Product CRUD operation through an anti-mocking testing approach.

## 2. Requirements
- **UI Redesign**:
    - Implement a modern, premium sidebar and header layout.
    - Use `shadcn/ui` components for navigation and layout primitives.
    - Follow `uncodixfy` guidelines for aesthetics (minimalist, high-signal, dark/light mode optimization).
- **CRUD Improvement (Product)**:
    - Clean up the Product creation and edit forms.
    - Standardize server action responses using `lib/action-response.ts`.
    - Ensure zero `as any` casting in the Product repository and actions.
- **New Test Style**:
    - Write a comprehensive integration test for the Product repository using a real database.
    - Implement an E2E test for the full Product creation flow (Form -> Action -> Repo -> DB -> Verification).

## 3. Architecture
- **Components**: `components/dashboard/` for the new layout.
- **Actions**: `actions/catalog.ts` (Product mutations).
- **Repositories**: `lib/db/repositories/catalog.repository.ts`.
- **Tests**: `tests/integration/catalog.repository.test.ts` and `e2e/product-crud.spec.ts`.

## 4. Resource Budgets
- **LCP (Largest Contentful Paint)**: < 1.2s
- **Test Success**: 100% (zero skipped)
- **Coverage**: 100% on modified files
- **Build**: `pnpm build` must pass.

## 5. Acceptance Criteria
- [ ] Sidebar and Header redesigned and responsive.
- [ ] Product CRUD (Create/Edit/Delete) fully functional and validated with Zod.
- [ ] Integration tests pass without mocks.
- [ ] E2E tests pass for all happy and unhappy paths.
- [ ] Zero linting/TSC errors.
