Skip to content

Add support for theming admonition blocks by type #1685

@Hamsterbau

Description

@Hamsterbau

Current behaviour

Currently if i want to use asciidoc pdf generator with theming, it is possible (thanks to another issue) to change basic stuff for admonition blocks:
https://github.com/asciidoctor/asciidoctor-pdf/blob/master/docs/theming-guide.adoc#keys-admonition

Example:

admonition:
  background_color: f5f5f5
  border_color: 7d7d7d
  border_width: $base_border_width
  padding: [0, $horizontal_rhythm, 0, $horizontal_rhythm]

Issue:
#444

But i cannot change these settings (especially background color) for a specific block type (e. g. caution in red or warning in orange).

Improvement: Admonition settings based on type

It would be nice to be able to configure admonition settings based on the current type.

Example:

admonition:
  caution:  
    background_color: ff0000
    border_color: ff0000
  warning:  
    background_color: ffa500
    border_color: ffa500

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions