mdbook-admonish icon indicating copy to clipboard operation
mdbook-admonish copied to clipboard

Set collapsible default value per directive

Open yannickseurin opened this issue 11 months ago • 1 comments

Hi!

If I'm not mistaken, currently it seems that the default collapsible value must be set globally for all directives.

It would be great if it were possible to set this default value to true for specific directives only.

yannickseurin avatar Mar 06 '24 15:03 yannickseurin

Thanks for the suggestion - I agree that most global options should be applicable per block style.

I think the appropriate way to configure this would be like the custom array in the book.toml file, except with a collapsible property: https://tommilligan.github.io/mdbook-admonish/#custom-blocks

I think one of:

  • A new array of overrides for builtin directives
  • Just use the existing custom block, and if you specify a built-in directive, it overrides the default value

would work fine.

tommilligan avatar Mar 06 '24 17:03 tommilligan

Closed with PR #174

yannickseurin avatar May 27 '24 08:05 yannickseurin