Nokome Bentley2 min read

Admonition

A admonition within a document.

Properties

The Admonition type has these properties:

Name Description Type Inherited from JSON-LD @id Aliases
id The identifier for this item. String Entity schema:id -
admonitionType The type of admonition. AdmonitionType - stencila:admonitionType admonition-type, admonition_type
title The title of the admonition. Inline* - schema:headline -
isFolded Whether the admonition is folded. Boolean - stencila:isFolded is-folded, is_folded
content The content within the section. Block* - stencila:content -
authors The authors of the admonition. Author* - schema:author author
provenance A summary of the provenance of the content within the admonition. ProvenanceCount* - stencila:provenance -

Related

The Admonition type is related to these types:

Formats

The Admonition type can be encoded (serialized) to, and/or decoded (deserialized) from, these formats:

Format Encoding Decoding Support Notes
DOM HTML 🟢 No loss
HTML 🔷 Low loss Encoded as <aside>
JATS 🟢 No loss 🟢 No loss Encoded as <boxed-text>
Markdown 🟢 No loss 🟢 No loss Encoded using implemented function
Stencila Markdown 🟢 No loss 🟢 No loss
Quarto Markdown 🟢 No loss 🟢 No loss
MyST Markdown 🟢 No loss 🟢 No loss
LLM Markdown 🟢 No loss 🟢 No loss
LaTeX 🔷 Low loss 🔷 Low loss
PDF 🔷 Low loss
Plain text ⚠️ High loss
IPYNB 🔷 Low loss 🔷 Low loss
Microsoft Word DOCX 🔷 Low loss 🔷 Low loss
OpenDocument ODT 🔷 Low loss 🔷 Low loss
TeX 🔷 Low loss 🔷 Low loss
JSON 🟢 No loss 🟢 No loss
JSON+Zip 🟢 No loss 🟢 No loss
JSON5 🟢 No loss 🟢 No loss
JSON-LD 🟢 No loss 🟢 No loss
CBOR 🟢 No loss 🟢 No loss
CBOR+Zstandard 🟢 No loss 🟢 No loss
YAML 🟢 No loss 🟢 No loss
Lexical JSON 🔷 Low loss 🔷 Low loss
Koenig JSON 🔷 Low loss 🔷 Low loss
Pandoc AST 🔷 Low loss 🔷 Low loss
Directory
Stencila Web Bundle
Debug 🔷 Low loss

Bindings

The Admonition type is represented in:

Testing

During property-based (a.k.a generative) testing, the properties of the Admonition type are generated using the following strategies for each complexity level. Any optional properties that are not in this table are set to None.

Property Complexity Description Strategy
admonitionType Min+ Fixed admonition type. AdmonitionType::Info
Low+ Generate an arbitrary admonition type. AdmonitionType::arbitrary()
title Min+ No title. None
Low+ Generate up to two arbitrary, non-recursive, inline nodes. option::of(vec_inlines_non_recursive(2))
High+ Generate up to four arbitrary, non-recursive, inline nodes. option::of(vec_inlines_non_recursive(4))
isFolded Min+ Not foldable. None
Low+ Arbitrarily, un-foldable, folded, or unfolded. option::of(bool::arbitrary())
content Min+ A single, simple paragraph. vec![p([t("Admonition content")])]
Low+ Generate up to two arbitrary paragraphs. vec_paragraphs(2)
High+ Generate up to four arbitrary, non-recursive, block nodes. vec_blocks_non_recursive(4)

Source

This documentation was generated from Admonition.yaml by docs_types.rs.