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

(markdown-it-figure) Pass additional classes? #21

Open
robdodson opened this issue May 11, 2020 · 0 comments
Open

(markdown-it-figure) Pass additional classes? #21

robdodson opened this issue May 11, 2020 · 0 comments

Comments

@robdodson
Copy link
Contributor

We have a few classes that authors can apply to an images, for example w-screenshot will put a dark grey border all the way around the image, which is useful if the background of the image is similar to our page background. Or w-fullbleed which will let the image break outside of the page a bit.

We currently use markdown-it-attrs to let authors specify a class or id on an element. Unfortunately it doesn't seem to work with the figure plugin. I'm actually not sure if the responsibility lies with the figure plugin or the markdown-it-attrs plugin. The markdown-it-attrs plugin does support custom renderers so maybe I should see if one of those resolves the issue?

Just sort of brain dumping in this issue in case others run into a similar problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants