@@ -56,10 +56,10 @@ jobs:
5656 track_progress : true
5757 prompt : |
5858 You are reviewing code changes for a React component library with git diffs included in the prompt. Focus on ensuring the changes are sound, clean, intentional, and void of regressions.
59-
59+
6060 REPO: ${{ github.repository }}
6161 PR NUMBER: ${{ github.event.pull_request.number }}
62-
62+
6363 Context:
6464 - This is a frontend React component library published to npm as @zenml-io/react-component-library
6565 - Uses TypeScript, Tailwind CSS, Radix UI primitives, Vitest for testing, and Storybook for documentation
@@ -68,52 +68,52 @@ jobs:
6868 - gh pr view ${{ github.event.pull_request.number }} --json title,body,author,headRefName,baseRefName,commits
6969 - gh pr diff ${{ github.event.pull_request.number }} --name-only
7070 - Use the repository's CLAUDE.md (if present) and existing code patterns for conventions.
71-
71+
7272 Primary Review Goals:
73-
73+
7474 1) Verify Change Correctness
7575 - Confirm the changes achieve their intended purpose
7676 - Check for unintended side effects or regressions in component behavior
7777 - Validate edge cases are handled properly (empty states, loading states, error states)
7878 - Ensure error paths are covered
7979 - Verify prop validation and TypeScript types are correct
80-
80+
8181 2) Code Quality & Cleanliness
8282 - Is the code readable and self-documenting?
8383 - Are the changes minimal and focused?
8484 - Do they follow existing patterns in the codebase?
8585 - Are there any code smells or anti-patterns?
8686 - Is the component structure logical and maintainable?
87-
87+
8888 3) Frontend-Specific Concerns
8989 - **Accessibility (a11y)**: ARIA attributes, keyboard navigation, focus management, semantic HTML
9090 - **TypeScript**: Proper typing, no `any` types, exported types are correctly defined
9191 - **Bundle Size**: Unnecessary dependencies, code bloat, tree-shaking considerations
9292 - **Performance**: Unnecessary re-renders, proper memoization, efficient event handlers
9393 - **Styling**: Tailwind classes used correctly, no inline styles, responsive design
9494 - **Browser Compatibility**: Works across target browsers
95-
95+
9696 4) Component API Design
9797 - Are component props intuitive and consistent with existing components?
9898 - Are breaking changes to component APIs clearly justified?
9999 - Is the component composable and flexible?
100100 - Are default prop values sensible?
101101 - Is the component API backward compatible?
102-
102+
103103 5) Potential Issues to Flag
104104 - Accessibility violations (missing labels, improper ARIA, keyboard traps)
105105 - Performance degradations (unnecessary re-renders, memory leaks)
106106 - Security vulnerabilities (XSS risks, unsafe HTML rendering)
107107 - Breaking changes to public component APIs
108108 - TypeScript type errors or unsafe type assertions
109109 - Missing error boundaries or error handling
110-
110+
111111 6) Constructive Suggestions
112112 - Alternative approaches that might be cleaner
113113 - Opportunities to reduce complexity
114114 - Missing test coverage for critical component behavior
115115 - Opportunities to improve accessibility
116-
116+
117117 Documentation & Storybook Review:
118118 - Determine if component behavior, props, or APIs have changed.
119119 - Heuristics (run): gh pr diff ${{ github.event.pull_request.number }} --name-only
@@ -123,18 +123,18 @@ jobs:
123123 - Check that JSDoc comments are present for complex props or components.
124124 - If breaking changes are introduced to component APIs, recommend adding migration notes in the PR description or changelog.
125125 - If documentation is needed, explicitly call it out in the review with concrete file/section suggestions.
126-
126+
127127 Review Format:
128128 - Start with a summary of what the changes accomplish.
129129 - List any critical issues that must be addressed.
130130 - Note minor improvements that would enhance quality.
131131 - Acknowledge what's done particularly well.
132132 - End with specific, actionable next steps if needed.
133-
133+
134134 Output Instructions:
135135 - Provide detailed feedback using inline-style code references in your comment for specific issues (quote file paths and line ranges when possible).
136136 - Use top-level comments for general observations or praise.
137137 - Use `gh pr comment` to post your review comment to the PR.
138-
138+
139139 Be constructive and helpful in your feedback.
140- claude_args : --max-turns 5 -- allowed-tools "mcp__github_inline_comment__create_inline_comment,Bash(gh issue view:*),Bash(gh search:*),Bash(gh issue list:*),Bash(gh pr comment:*),Bash(gh pr diff:*),Bash(gh pr view:*),Bash(gh pr list:*)"
140+ claude_args : --allowed-tools "mcp__github_inline_comment__create_inline_comment,Bash(gh issue view:*),Bash(gh search:*),Bash(gh issue list:*),Bash(gh pr comment:*),Bash(gh pr diff:*),Bash(gh pr view:*),Bash(gh pr list:*)"
0 commit comments