Skip to content

Commit c34097e

Browse files
committed
update documentation for "material-encryptcontent: reload all subscriptions"
1 parent 9c4f0e9 commit c34097e

File tree

4 files changed

+17
-24
lines changed

4 files changed

+17
-24
lines changed

README.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -926,20 +926,20 @@ graph LR
926926

927927
#### mkdocs-material
928928

929+
> **Enable by default**
930+
929931
Add support for mermaid graphs by adding the `pymdownx.superfences` to `markdown_extensions` as
930932
described [here]( https://squidfunk.github.io/mkdocs-material/reference/diagrams/).
931933

932-
Copy the "material-encryptcontent.mjs" file from
933-
[here](https://github.com/unverbuggt/mkdocs-encryptcontent-plugin/tree/version3/fixes)
934-
to "/assets/javascripts/" and include it to "mkdocs.yml" like this:
934+
After successful decryption all subscriptions of the document are recalled to render the marmaid graph,
935+
see [here](https://github.com/unverbuggt/mkdocs-encryptcontent-plugin/pull/81).
935936

936-
```yaml
937-
extra_javascript:
938-
- assets/javascripts/material-encryptcontent.mjs
937+
```jinja
938+
{%- if material %}
939+
document$.next(document);
940+
{%- endif %}
939941
```
940942

941-
The script is called after successful decryption and renders the mermaid graphs in a similar way as
942-
the theme would normally do.
943943

944944
### mkdocs-glightbox
945945

documentation/docs/features/jsext.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -121,20 +121,20 @@ graph LR
121121

122122
#### mkdocs-material
123123

124+
> **Enable by default**
125+
124126
Add support for mermaid graphs by adding the `pymdownx.superfences` to `markdown_extensions` as
125127
described [here]( https://squidfunk.github.io/mkdocs-material/reference/diagrams/).
126128

127-
Copy the "material-encryptcontent.mjs" file from
128-
[here](https://github.com/unverbuggt/mkdocs-encryptcontent-plugin/tree/version3/fixes)
129-
to "/assets/javascripts/" and include it to "mkdocs.yml" like this:
129+
After successful decryption all subscriptions of the document are recalled to render the marmaid graph,
130+
see [here](https://github.com/unverbuggt/mkdocs-encryptcontent-plugin/pull/81).
130131

131-
```yaml
132-
extra_javascript:
133-
- assets/javascripts/material-encryptcontent.mjs
132+
```jinja
133+
{%- if material %}
134+
document$.next(document);
135+
{%- endif %}
134136
```
135137

136-
The script is called after successful decryption and renders the mermaid graphs in a similar way as
137-
the theme would normally do.
138138

139139
### mkdocs-glightbox
140140

documentation/docs/features/security.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,4 +128,4 @@ all files and verify the signatures.
128128
As long as the private key used for signing remains secret, the canary script will be able to determine
129129
if someone tampered with the files on the server. But you should run the canary script from another machine
130130
that is not related to the server, otherwise the attacker could also modify the canary script and sign with his
131-
private key instead.
131+
private key instead.

fixes/material-encryptcontent.mjs

Lines changed: 0 additions & 7 deletions
This file was deleted.

0 commit comments

Comments
 (0)