Skip to content
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

Shiki code extensions not working when using a different theme than default #4087

Closed
4 tasks done
everdrone opened this issue Jul 29, 2024 · 3 comments
Closed
4 tasks done
Labels
upstream Related to the dependencies

Comments

@everdrone
Copy link

Describe the bug

The feature allowing // [!code --], // [!code focus] etc is seemingly disabled when the theme isn't the default "github" theme from Shiki.

Reproduction

Add a theme to the markdown configuration:

markdown: {
    theme: { dark: "rose-pine", light: "rose-pine-dawn" },
}

And add a code block with a transformation

```js
export default {
  data () {
    return {
      msg: 'Removed' // [!code --]
      msg: 'Added' // [!code ++]
    }
  }
}
```

Expected behavior

The effects work with other themes other than the default one

System Info

System:
    OS: Windows 11 10.0.22631
    CPU: (32) x64 AMD Ryzen 9 7950X 16-Core Processor
    Memory: 33.50 GB / 63.14 GB
  Binaries:
    Node: 20.15.0 - ~\AppData\Local\fnm_multishells\736048_1722274229696\node.EXE
    npm: 10.7.0 - ~\AppData\Local\fnm_multishells\736048_1722274229696\npm.CMD
  Browsers:
    Edge: Chromium (127.0.2651.74)
    Internet Explorer: 11.0.22621.3527
    Firefox: 128.0.3

Additional context

No response

Validations

@everdrone everdrone added the bug: pending triage Maybe a bug, waiting for confirmation label Jul 29, 2024
@brc-dd
Copy link
Member

brc-dd commented Jul 29, 2024

Something seems wrong with rose-pine related themes. Other themes are working fine.

@brc-dd
Copy link
Member

brc-dd commented Jul 29, 2024

Linking discussion on #4248 for reference.

It's same as #3503 (antfu/shikiji#110 (comment)). Please create an issue at https://github.com/shikijs/shiki.

@brc-dd brc-dd added bug upstream Related to the dependencies and removed bug: pending triage Maybe a bug, waiting for confirmation labels Jul 29, 2024
@github-actions github-actions bot added the stale label Sep 1, 2024
@github-actions github-actions bot removed the stale label Oct 12, 2024
@brc-dd
Copy link
Member

brc-dd commented Oct 13, 2024

Duplicate of #3503

@brc-dd brc-dd marked this as a duplicate of #3503 Oct 13, 2024
@brc-dd brc-dd closed this as completed Oct 13, 2024
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Oct 21, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
upstream Related to the dependencies
Projects
None yet
Development

No branches or pull requests

2 participants