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

fix: pass missing highlight class #21

Merged
merged 8 commits into from
Sep 6, 2023
Merged

fix: pass missing highlight class #21

merged 8 commits into from
Sep 6, 2023

Conversation

nobkd
Copy link
Contributor

@nobkd nobkd commented Sep 4, 2023

Supposed to fix #19 when ready

Currently, investigating where the highlights go missing in the process...
If you have any ideas, please share them.


In this function we never add/use highlights:

highlighter: (code, lang, theme) => {

const task = options.highlighter!(toString(node as any), _node.properties!.language as string, options.theme!)

@farnabaz
Copy link
Collaborator

farnabaz commented Sep 5, 2023

Hey @nobkd,
Thanks for the PR.
Indeed, as you said, the issue is that highlights did not pass to highlighter function. Updating shiki/event-handler.ts and parser/shiki.ts should fix the issue.

@nobkd nobkd marked this pull request as ready for review September 5, 2023 12:22
@nobkd
Copy link
Contributor Author

nobkd commented Sep 5, 2023

This should work now.

@nobkd nobkd changed the title fix: missing highlight class fix: pass missing highlight class Sep 5, 2023
@atinux atinux requested a review from farnabaz September 5, 2023 17:35
Copy link
Collaborator

@farnabaz farnabaz left a comment

Choose a reason for hiding this comment

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

Thanks ❤️

@farnabaz farnabaz merged commit f5985c2 into nuxt-modules:main Sep 6, 2023
@nobkd nobkd deleted the fix-prose/highlights branch September 6, 2023 12:45
@farnabaz farnabaz mentioned this pull request Sep 19, 2023
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.

Highlight specific lines does not work anymore / 'highlight' class not added
2 participants