Skill
/apply-comments
Resolve pending @openpress-comment markers. For each marker: read surrounding text, decide how to edit, apply it, delete the marker. Report what was handled and what needs human assistance.
Resolve pending @openpress-comment markers in the source code.
/apply-comments This document explains how to find and resolve inline comments in MDX files.
Step 1: Find Pending Markers
Use grep or ripgrep to find all comment markers in the project:
rg "@openpress-comment" press -n
Step 2: Inspect Comment Content and Source Code
Open the source file containing the marker. Read the lines surrounding the marker to understand the comment’s context and requirement.
Step 3: Apply Modifications
Based on the comment’s instructions, make the minimal source code change that satisfies the comment.
- Preserve the original localized styles, component APIs, and MDX structure.
- If the meaning of the comment is unclear, keep the marker and do not make guess-work modifications.
Step 4: Remove the Marker
Only after confirming the modification is complete, delete the {@openpress-comment ...} marker line from the source code. Do not remove the marker directly without making any changes.
Step 5: Validate Changes
Run the build command to ensure no structures are broken and no syntax errors are introduced:
npm run build
Step 6: Report Results
Record the IDs of the processed markers and report any comments that were not handled due to unclear semantics.