Skip to content

feat(transformers): add support for [!code info] notation#1237

Merged
antfu merged 1 commit intoshikijs:mainfrom
Divyapahuja31:feat/transformers-notation-info
Feb 6, 2026
Merged

feat(transformers): add support for [!code info] notation#1237
antfu merged 1 commit intoshikijs:mainfrom
Divyapahuja31:feat/transformers-notation-info

Conversation

@Divyapahuja31
Copy link
Copy Markdown
Contributor

  • -

Description

This PR adds support for [!code info] notation to transformerNotationErrorLevel.

What:
It extends the supported notations ([!code error], [!code warning]) to include [!code info]. Lines marked with this notation will be wrapped in a span with the classes highlighted info.

Why:
This allows users to highlight lines as informational notes in their code snippets, distinct from errors or warnings, which is common in documentation and tutorials.

Changes:

  • Updated notation-error-level.ts to include the info class map.
  • Updated documentation to include usages of [!code info].
  • Updated test fixtures to include an example of [!code info].

@netlify
Copy link
Copy Markdown

netlify Bot commented Feb 6, 2026

Deploy Preview for shiki-next ready!

Name Link
🔨 Latest commit 719eb58
🔍 Latest deploy log https://app.netlify.com/projects/shiki-next/deploys/6986454665dcbf00082fd0ca
😎 Deploy Preview https://deploy-preview-1237--shiki-next.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

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

@netlify
Copy link
Copy Markdown

netlify Bot commented Feb 6, 2026

Deploy Preview for shiki-matsu ready!

Name Link
🔨 Latest commit 719eb58
🔍 Latest deploy log https://app.netlify.com/projects/shiki-matsu/deploys/69864546be501900070afe42
😎 Deploy Preview https://deploy-preview-1237--shiki-matsu.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

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

@codecov
Copy link
Copy Markdown

codecov Bot commented Feb 6, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 95.25%. Comparing base (49cbb76) to head (719eb58).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1237   +/-   ##
=======================================
  Coverage   95.25%   95.25%           
=======================================
  Files          92       92           
  Lines        8007     8008    +1     
  Branches     1705     1704    -1     
=======================================
+ Hits         7627     7628    +1     
  Misses        374      374           
  Partials        6        6           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@antfu antfu merged commit cd2a6d9 into shikijs:main Feb 6, 2026
14 checks passed
This was referenced Feb 27, 2026
This was referenced Mar 1, 2026
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.

2 participants