-
Notifications
You must be signed in to change notification settings - Fork 11
[CC Projects] Extra line added to the start of some code blocks #1268
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[CC Projects] Extra line added to the start of some code blocks #1268
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR fixes an issue where extra blank lines were being added to the start of code blocks in the instructions panel. The fix introduces a Prism hook that removes multiple leading blank lines from code content before syntax highlighting is applied.
Key changes:
- Added a Prism hook to strip leading blank lines from code blocks
- Implemented a flag to ensure Prism configuration only runs once
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| src/components/Menus/Sidebar/InstructionsPanel/InstructionsPanel.jsx | Added Prism hook to remove leading blank lines and configuration flag |
| CHANGELOG.md | Added entry documenting the fix for extra lines in code blocks |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
src/components/Menus/Sidebar/InstructionsPanel/InstructionsPanel.jsx
Outdated
Show resolved
Hide resolved
…_the_start_of_some_code_blocks
loiswells97
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice 👍
Fixes the following extra line bug in projects-ui editor projects:

closes #1267