1 | cases:
|
2 | - title: Simple Admonition
|
3 | mdast:
|
4 | type: root
|
5 | children:
|
6 | - type: mystDirective
|
7 | name: admonition
|
8 | args: This is a title
|
9 | value: An example of an admonition with a _title_.
|
10 | children:
|
11 | - type: admonition
|
12 | children:
|
13 | - type: admonitionTitle
|
14 | children:
|
15 | - type: text
|
16 | value: This is a title
|
17 | - type: paragraph
|
18 | children:
|
19 | - type: text
|
20 | value: 'An example of an admonition with a '
|
21 | - type: emphasis
|
22 | children:
|
23 | - type: text
|
24 | value: title
|
25 | - type: text
|
26 | value: '.'
|
27 | myst: |-
|
28 | ```{admonition} This is a title
|
29 | An example of an admonition with a _title_.
|
30 | ```
|
31 | html: |-
|
32 | <aside class="admonition">
|
33 | <p class="admonition-title">This is a title</p>
|
34 | <p>An example of an admonition with a <em>title</em>.</p>
|
35 | </aside>
|
36 | latex: |-
|
37 | \begin{mdframed}
|
38 | \section*{This is a title}
|
39 | An example of an admonition with a \textit{title}.
|
40 | \end{mdframed}
|
41 |
|
42 | - title: Note with no title
|
43 | mdast:
|
44 | type: root
|
45 | children:
|
46 | - type: mystDirective
|
47 | name: note
|
48 | value: Please note!
|
49 | children:
|
50 | - type: admonition
|
51 | kind: note
|
52 | children:
|
53 | - type: paragraph
|
54 | children:
|
55 | - type: text
|
56 | value: Please note!
|
57 | myst: |-
|
58 | ```{note}
|
59 | Please note!
|
60 | ```
|
61 | html: |-
|
62 | <aside class="admonition note">
|
63 | <p class="admonition-title">Note</p>
|
64 | <p>Please note!</p>
|
65 | </aside>
|
66 | latex: |-
|
67 | \begin{mdframed}[style=note]
|
68 | Please note!
|
69 | \end{mdframed}
|
70 |
|
71 | - title: Note with split title
|
72 | id: admonition
|
73 | mdast:
|
74 | type: root
|
75 | children:
|
76 | - type: mystDirective
|
77 | name: note
|
78 | args: This is a title in myst
|
79 | value: and an example of a note admonition.
|
80 | children:
|
81 | - type: admonition
|
82 | kind: note
|
83 | children:
|
84 | - type: admonitionTitle
|
85 | children:
|
86 | - type: text
|
87 | value: This is a title in myst
|
88 | - type: paragraph
|
89 | children:
|
90 | - type: text
|
91 | value: |-
|
92 | and an example of a note admonition.
|
93 |
|
94 | - title: Danger on a single line
|
95 | mdast:
|
96 | type: root
|
97 | children:
|
98 | - type: mystDirective
|
99 | name: danger
|
100 | args: This is a title!
|
101 | children:
|
102 | - type: admonition
|
103 | kind: danger
|
104 | children:
|
105 | - type: admonitionTitle
|
106 | children:
|
107 | - type: text
|
108 | value: This is a title!
|
109 |
|
110 | - title: Admonition with overridding class name
|
111 | mdast:
|
112 | type: root
|
113 | children:
|
114 | - type: mystDirective
|
115 | name: admonition
|
116 | args: This is a title!
|
117 | options:
|
118 | class: tip
|
119 | value: An example of a general `admonition` with a custom _class_.
|
120 | children:
|
121 | - type: admonition
|
122 | class: tip
|
123 | children:
|
124 | - type: admonitionTitle
|
125 | children:
|
126 | - type: text
|
127 | value: This is a title!
|
128 | - type: paragraph
|
129 | children:
|
130 | - type: text
|
131 | value: 'An example of a general '
|
132 | - type: inlineCode
|
133 | value: admonition
|
134 | - type: text
|
135 | value: ' with a custom '
|
136 | - type: emphasis
|
137 | children:
|
138 | - type: text
|
139 | value: 'class'
|
140 | - type: text
|
141 | value: '.'
|
142 | myst: |-
|
143 | ```{admonition} This is a title!
|
144 | :class: tip
|
145 |
|
146 | An example of a general `admonition` with a custom _class_.
|
147 | ```
|
148 | html: |-
|
149 | <aside class="tip admonition">
|
150 | <p class="admonition-title">This is a title!</p>
|
151 | <p>An example of a general <code>admonition</code> with a custom <em>class</em>.</p>
|
152 | </aside>
|
153 | latex: |-
|
154 | \begin{mdframed}[style=tip]
|
155 | \section*{This is a title!}
|
156 | An example of a general \texttt{admonition} with a custom \textit{class}.
|
157 | \end{mdframed}
|
158 |
|
159 | - title: See Also with overridding class name of tip
|
160 | description: The `tip` class must be appended to the start
|
161 | mdast:
|
162 | type: root
|
163 | children:
|
164 | - type: mystDirective
|
165 | name: seealso
|
166 | options:
|
167 | class: tip
|
168 | value: |-
|
169 | Tip class comes first!!
|
170 | children:
|
171 | - type: admonition
|
172 | kind: seealso
|
173 | class: tip
|
174 | children:
|
175 | - type: paragraph
|
176 | children:
|
177 | - type: text
|
178 | value: |-
|
179 | Tip class comes first!!
|
180 | myst: |-
|
181 | ```{seealso}
|
182 | :class: tip
|
183 | Tip class comes first!!
|
184 | ```
|
185 | html: |-
|
186 | <aside class="tip admonition seealso">
|
187 | <p class="admonition-title">See Also</p>
|
188 | <p>Tip class comes first!!</p>
|
189 | </aside>
|
190 | latex: |-
|
191 | \begin{mdframed}[style=tip]
|
192 | Tip class comes first!!
|
193 | \end{mdframed}
|