Skip to content

Conversation

edmundmiller
Copy link
Member

@edmundmiller edmundmiller commented Sep 20, 2025

Summary

This implements Expressive Code for enhanced code examples with line numbers and better readability.

I wanted to start with a simple one to show the changes and I'll follow up with a reorganization PR and then one with the content updates.

Changes

  • Add line numbers plugin and enable by default
  • Increase code font size to 24px for better readability
  • Create separate ec.config.mjs for plugin configuration
  • Convert basic-pipeline example to use MDX with external .nf file
  • Maintain existing text markers and clean site styling

- Configure comprehensive style overrides to match site's clean, minimal aesthetic
- Use pure white backgrounds and site's CSS variables (--nextflow-green colors)
- Set proper text marker highlighting with site's light green accent color
- Remove frame titles and switch to 'nextflow' language for syntax highlighting
- Maintain advanced highlighting functionality while achieving visual integration
- Result: Code blocks now blend seamlessly with site design while providing enhanced educational features

The example pages now have clean, professional code blocks that match the site's
design system perfectly, with clearly visible line highlighting using the site's
signature green color scheme.
Copy link

netlify bot commented Sep 20, 2025

Deploy Preview for nextflow-staging ready!

Name Link
🔨 Latest commit b40db46
🔍 Latest deploy log https://app.netlify.com/projects/nextflow-staging/deploys/68cfc25d4c227f000890339d
😎 Deploy Preview https://deploy-preview-423--nextflow-staging.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 72 (🟢 up 14 from production)
Accessibility: 74 (no change from production)
Best Practices: 83 (no change from production)
SEO: 88 (no change from production)
PWA: -
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to your Netlify project configuration.

- Create separate ec.config.mjs for Expressive Code plugin configuration
- Install @expressive-code/plugin-line-numbers plugin
- Enable line numbers by default with showLineNumbers: true
- Set optimal font size (1.5rem/24px) for better code readability
- Simplify astro.config.mjs to use basic expressiveCode() integration
- Maintain all existing styling and text marker functionality
- Fix MDX Code component compatibility with plugin-based configuration
- Support external file imports with ?raw suffix for clean separation

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <[email protected]>
@edmundmiller edmundmiller force-pushed the expressive-code-implementation branch from 9ae2899 to b40db46 Compare September 21, 2025 09:16
@mavi-sqr
Copy link
Collaborator

mavi-sqr commented Sep 23, 2025

Hi @edmundmiller :) Nice work

Captura de pantalla 2025-09-23 a las 12 44 41

WDYT about styling the highlight like this? It aligns better with how we use highlight. ☝️
Also, I’d keep highlights minimal—ideally 1–2 lines per case.
One more thing: I’d keep the vertical separator between line numbers and code inside the highlight; it reinforces the code structure.

Copy link
Member

@bentsherman bentsherman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM as long as you address comments from design team 😄

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants