Conversation
There was a problem hiding this comment.
Pull request overview
Updates the editor instructions panel styling to align with the new CCP project markdown conventions (using plain markdown headings/IDs instead of task-fencing and bespoke heading classes), while preserving compatibility for existing content.
Changes:
- Adjust
h2spacing in the instructions panel to better suit markdown-rendered headings. - Add CCP-specific styling for step headings (
id="step-*"), and the “Now run your code” heading (id="now-run-your-code"), including a new play icon. - Remove the old “task” heading/box styling while keeping
.c-project-taskpresent for legacy content.
Reviewed changes
Copilot reviewed 1 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
src/assets/stylesheets/Instructions.scss |
Updates heading margins, adds new ID-based CCP step/run styling, and removes legacy task heading styling. |
src/assets/play_filled.svg |
Adds a new play icon used by the “Now run your code” styling. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| background-image: url("../play_filled.svg"); | ||
| background-repeat: no-repeat; | ||
| background-position: center; | ||
| background-size: 1.5rem 1.5rem; |
There was a problem hiding this comment.
background-size: 1.5rem 1.5rem bypasses the spacing scale-factor system used elsewhere in this file ($space-*). Consider using the matching spacing token (e.g. $space-1-5) so the icon scales consistently with the rest of the UI.
| background-size: 1.5rem 1.5rem; | |
| background-size: $space-1-5 $space-1-5; |
| h2 { | ||
| @include typography.style-1-5(bold); | ||
| margin: 0; | ||
| margin-block-start: $space-0-5; |
There was a problem hiding this comment.
The h2 rule now sets only margin-block-start, which re-enables the browser default margin-block-end (since margin: 0 was removed). If the intent is to control heading spacing precisely, set margin-block-end explicitly (or use a margin-block shorthand) so the bottom spacing is not left to UA defaults.
| margin-block-start: $space-0-5; | |
| margin-block-start: $space-0-5; | |
| margin-block-end: $space-0-5; |
| [id^="step-"]{ | ||
| background: #ECF8EE; | ||
| border-radius: $space-0-5; | ||
| color: #276D32; | ||
| display: inline-block; |
There was a problem hiding this comment.
New CCP step styling introduces hard-coded hex colors (#ECF8EE, #276D32). This stylesheet already uses shared colour tokens (e.g. $rpf-green-* from rpf_design_system/colours.scss), so using tokens here (or introducing new named tokens for the CCP palette) will keep colours consistent and easier to update.
closes #1324
Changes for CCP editor projects
Heading
instructions.scsswhich made the markdown h2 look strange..c-project-taskcss class for existing projects that contain the task fencing.Steps
id = step-1etc. probably by kramdown during project build'Now run your code`
id = now-run-your-codeCallouts
Impact on CEfE instructions panel?
CEfE instructions panel does use the
.project-instructionsclass with markdowns; however, the markdown headings don't get ids when used to populate the instruction panel. So there won't be any impact on CEfE.