Skip to content

Commit b2ed2cd

Browse files
committed
Added more examples to documentation
1 parent 156b52c commit b2ed2cd

File tree

3 files changed

+16
-0
lines changed

3 files changed

+16
-0
lines changed

docs/setup/changing-the-colors.md

+6
Original file line numberDiff line numberDiff line change
@@ -166,6 +166,7 @@ See our guide below to learn how to set [custom colors].
166166

167167
<!-- md:version 7.1.0 -->
168168
<!-- md:default none -->
169+
<!-- md:example color-palette-toggle -->
169170

170171
Offering a light _and_ dark color palette makes your documentation pleasant to
171172
read at different times of the day, so the user can choose accordingly. Add the
@@ -235,6 +236,7 @@ The following properties must be set for each toggle:
235236

236237
<!-- md:version 7.1.0 -->
237238
<!-- md:default none -->
239+
<!-- md:example color-palette-system-preference -->
238240

239241
Each color palette can be linked to the user's system preference for light and
240242
dark appearance by using a media query. Simply add a `media` property next to
@@ -268,6 +270,7 @@ default color palette.
268270
<!-- md:sponsors -->
269271
<!-- md:version insiders-4.18.0 -->
270272
<!-- md:flag experimental -->
273+
<!-- md:example color-palette-system-preference -->
271274

272275
Newer operating system allow to automatically switch between light and dark
273276
appearance during day and night times. [Insiders] adds support for automatic
@@ -313,6 +316,9 @@ reload the site.
313316

314317
### Custom colors
315318

319+
<!-- md:version 5.0.0 -->
320+
<!-- md:example custom-colors -->
321+
316322
Material for MkDocs implements colors using [CSS variables] (custom
317323
properties). If you want to customize the colors beyond the palette (e.g. to
318324
use your brand-specific colors), you can add an [additional style sheet] and

docs/setup/ensuring-data-privacy.md

+4
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ automatically downloaded for [self-hosting].
1616
<!-- md:version 8.4.0 -->
1717
<!-- md:default none -->
1818
<!-- md:flag experimental -->
19+
<!-- md:example cookie-consent -->
1920

2021
Material for MkDocs ships a native and extensible cookie consent form which
2122
asks the user for consent prior to sending requests to third parties. Add the
@@ -284,6 +285,9 @@ For a list of all settings, please consult the [plugin documentation].
284285

285286
### Custom cookies
286287

288+
<!-- md:version 8.4.0 -->
289+
<!-- md:example custom-cookies -->
290+
287291
If you've customized the [cookie consent] and added a `custom` cookie, the user
288292
will be prompted to accept or reject your custom cookie. Once the user accepts
289293
or rejects the cookie consent, or [changes the settings], the page reloads[^1].

docs/setup/setting-up-tags.md

+6
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,9 @@ setting:
112112

113113
### Adding tags
114114

115+
<!-- md:version 8.2.0 -->
116+
<!-- md:example tags -->
117+
115118
When the [built-in tags plugin] is enabled, tags can be added for a document
116119
with the front matter `tags` property. Add the following lines at the top of a
117120
Markdown file:
@@ -153,6 +156,9 @@ search preview, which now allows to __find pages by tags__.
153156

154157
### Adding a tags index
155158

159+
<!-- md:version 8.2.0 -->
160+
<!-- md:example tags -->
161+
156162
The [built-in tags plugin] allows to define a file to render a [tags index]
157163
[tags.tags_file], which can be any page that is part of the `nav` section. To
158164
add a tags index, create a page, e.g. `tags.md`:

0 commit comments

Comments
 (0)