withastro / astro

The web framework for content-driven websites. ⭐️ Star to support our work!
https://astro.build
Other
45.82k stars 2.41k forks source link

Feature: add support for shiki `defaultColors` option #11341

Closed madcampos closed 2 months ago

madcampos commented 3 months ago

Changes

This add support for for the defaultColor option from shiki. It exposes the option both to the internal highlighter and to astro's config.

Resolves: #11238

Testing

Two unit tests were added to ensure the setting is respected.

Docs

I think a reference to shiki's docs will help. Will create a PR to add the doc reference soon.

/cc @withastro/maintainers-docs for feedback!

PS: Thanks to @0916dhkim and @ettavolt for the help with the code

changeset-bot[bot] commented 3 months ago

🦋 Changeset detected

Latest commit: 29f056e11e91dde1811b587e83fefd5ed2ba2050

The changes in this PR will be included in the next version bump.

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

matthewp commented 2 months ago

Thanks @madcampos, we will need docs in order to get this into 4.12. Thanks!

madcampos commented 2 months ago

Sorry for the delay folks, here is the docs PR: https://github.com/withastro/docs/pull/8722