tommilligan / mdbook-admonish

A preprocessor for mdbook to add Material Design admonishments.
MIT License
171 stars 18 forks source link

fix: support toml values with equal sign #181

Closed tommilligan closed 3 months ago

tommilligan commented 3 months ago

Closes #179

The v2 config format is not suitable for parsing complex toml values, specifically containing = values. This is due to the pre-parsing wrangling to marshal key-value pairs into a valid TOML format using = as a marker for TOML keys, when in fact it can appear in values too.

To fix this, introduce the new v3 config format which uses the TOML Inline Table syntax to support this natively.

This PR adds the config back-compatibly, falling back to v2 (and v1) if parsing with the new format fails. It also updates all docs/examples to use the new comma separated format where appropriate.