myst_parser.sphinx_ext.directives
#
MyST specific directives
1. Module Contents#
1.1. Classes#
Implement substitution references as a role. |
|
Directive for creating a figure with Markdown compatible syntax. |
1.2. Functions#
1.3. API#
- class myst_parser.sphinx_ext.directives.SubstitutionReferenceRole[源代码]#
Bases:
sphinx.util.docutils.SphinxRole
Implement substitution references as a role.
Note, in
docutils/parsers/rst/roles.py
this is left unimplemented.
- class myst_parser.sphinx_ext.directives.FigureMarkdown(name, arguments, options, content, lineno, content_offset, block_text, state, state_machine)[源代码]#
Bases:
sphinx.util.docutils.SphinxDirective
Directive for creating a figure with Markdown compatible syntax.
Example:
:::{figure-md} target <img src="img/fun-fish.png" alt="fishy" class="bg-primary mb-1" width="200px"> This is a caption in **Markdown** :::
Initialization
- required_arguments = 0#
- optional_arguments = 1#
- final_argument_whitespace = True#
- has_content = True#
- option_spec = None#