en un clic
code-review
// Review code changes for contract compliance, type safety, and regression risk. Use after completing any non-trivial implementation, before merging PRs, or when asked to review code quality across any mercur package.
// Review code changes for contract compliance, type safety, and regression risk. Use after completing any non-trivial implementation, before merging PRs, or when asked to review code quality across any mercur package.
| name | code-review |
| description | Review code changes for contract compliance, type safety, and regression risk. Use after completing any non-trivial implementation, before merging PRs, or when asked to review code quality across any mercur package. |
| allowed-tools | Read, Grep, Glob |
Use this skill when:
admin-ui-review is too narrow (backend, registry, cross-package changes)For admin UI-specific review, prefer admin-ui-review — it has deeper UI pattern coverage.
references/review-checklist.mdany types on public API boundaries or shared DTOs@components/, @hooks/, @lib/index.ts in registry workflows/ or steps/AuthenticatedMedusaRequest<T> / MedusaResponse<T>Prioritize checks by blast radius:
any on boundaries, missing generics, type widening## Code Review: [scope description]
### P1 (Blocker)
1. **[Issue]** in `file:line` — [description]
Fix: [concrete suggestion]
### P2 (Should fix)
1. **[Issue]** in `file:line` — [description]
### P3 (Suggestion)
1. **[Issue]** in `file:line` — [description]
### Verified
- [what was checked]
### Not verified
- [what was skipped and why]
### Residual risk
- [any remaining concerns]
## Code Review: [scope description]
No findings. Changes are consistent with mercur patterns and contracts.
### Verified
- [list of checks performed]
### Not verified
- [anything skipped]
When changes span multiple packages:
When reviewing your own implementation:
Plan and execute migration from Mercur 1.x to 2.0. Classifies project difficulty, reads relevant migration docs, and follows stop conditions.
Analyze a Mercur 1.x project and guide migration to 2.0. Self-contained — works without access to the mercur monorepo.
Enforce correct form UI patterns when creating or modifying forms in packages/admin. Use when writing form fields, edit drawers, create modals, or any form-based UI in the admin package. Covers Form.Field pattern, labels, errors, hints, grids, submit guards, drawer/modal structure.
Enforce correct page and section UI patterns when creating or modifying admin pages. Use when building list pages, detail pages, Container sections, action menus, empty states, delete flows, or any page-level UI in packages/admin.
Enforce correct tab UI patterns when creating custom tabs for TabbedForm wizards in packages/admin. Use when adding new tabs to product create, price list create, or any multi-step form wizard. Covers defineTabMeta, layout, heading levels, section structure, i18n.
Review admin UI code for consistency with established patterns. Use after writing any UI code in packages/admin to catch anti-patterns — wrong form components, hardcoded strings, missing i18n, incorrect heading levels, manual error rendering, missing data-testid, raw Controller usage.