The AsciiDoc theme attribute is used to select an alternative CSS stylesheet and to optionally include additional JavaScript code.
- Theme files reside in an AsciiDoc configuration directory named
themes/<theme>/(where<theme>is the the theme name set by the theme attribute). asciidoc(1) sets the themedir attribute to the theme directory path name. - The theme attribute can also be set using the asciidoc(1)
--themeoption, the--themeoption can also be used to manage theme plugins. - AsciiDoc ships with two themes: flask and volnitsky.
- The
<theme>.cssfile replaces the defaultasciidoc.cssCSS file. - The
<theme>.jsfile is included in addition to the defaultasciidoc.jsJavaScript file. - If the data-uri attribute is defined then icons are loaded from the theme
iconssub-directory if it exists (i.e. the iconsdir attribute is set to themeiconssub-directory path). - Embedded theme files are automatically inserted in the output files but you need to manually copy linked CSS and Javascript files to the location of the output documents.
- Linked CSS and JavaScript theme files are linked to the same linked locations as other CSS and JavaScript files.
For example, the command-line option --theme foo (or --attribute theme=foo) will cause asciidoc(1) to search configuration file locations 1 for a sub-directory called themes/foo containing the stylesheet foo.css and optionally a JavaScript file name foo.js.