aboutsummaryrefslogtreecommitdiff
path: root/docs/templates.md
diff options
context:
space:
mode:
authorpraschke <stel@comfy.monster>2023-10-17 22:25:30 +0100
committerpraschke <stel@comfy.monster>2023-10-17 22:25:30 +0100
commit9b798601b48a40b65e38b433924a99d155872ba7 (patch)
tree02ada4e52d83b4febfbf763b9cf1f1348c65e5cd /docs/templates.md
parent9f8269606fdf51765f6d13de4caac709691b0fea (diff)
update: hasMedia and getMedia
Diffstat (limited to 'docs/templates.md')
-rw-r--r--docs/templates.md18
1 files changed, 9 insertions, 9 deletions
diff --git a/docs/templates.md b/docs/templates.md
index e19309a7..0aa26b84 100644
--- a/docs/templates.md
+++ b/docs/templates.md
@@ -686,8 +686,8 @@ These functions are used together in order to request media and other types of o
<details>
<summary>Syntax:</summary>
- <code>{{#hasMedia <i>type</i> <i>args</i>...}}{{/hasMedia}}</code><br>
- <code>{{#getMedia <i>type</i> <i>args</i>... <i>[escape=true|false]</i>}}{{/getMedia}}</code><br>
+ <code>{{hasMedia <i>type</i> <i>args</i>...}}</code><br>
+ <code>{{getMedia <i>type</i> <i>args</i>... <i>[escape=true|false]</i>}}</code><br>
* _`type`_ <br>
The type of media to check for.
@@ -710,19 +710,19 @@ These functions are used together in order to request media and other types of o
<summary>Examples:</summary>
```handlebars
- {{#if (hasMedia "audio")}}The audio file name is: {{#getMedia "audio"}}{{/getMedia}}{{/if}}
+ {{#if (hasMedia "audio")}}The audio file name is: {{getMedia "audio"}}{{/if}}
- {{#if (hasMedia "screenshot")}}The screenshot file name is: {{#getMedia "screenshot"}}{{/getMedia}}{{/if}}
+ {{#if (hasMedia "screenshot")}}The screenshot file name is: {{getMedia "screenshot"}}{{/if}}
- {{#if (hasMedia "clipboardImage")}}The clipboard image file name is: {{#getMedia "clipboardImage"}}{{/getMedia}}{{/if}}
+ {{#if (hasMedia "clipboardImage")}}The clipboard image file name is: {{getMedia "clipboardImage"}}{{/if}}
- {{#if (hasMedia "clipboardText")}}The clipboard text is: {{#getMedia "clipboardText"}}{{/getMedia}}{{/if}}
+ {{#if (hasMedia "clipboardText")}}The clipboard text is: {{getMedia "clipboardText"}}{{/if}}
- {{#if (hasMedia "selectionText")}}The selection text is: {{#getMedia "selectionText"}}{{/getMedia}}{{/if}}
+ {{#if (hasMedia "selectionText")}}The selection text is: {{getMedia "selectionText"}}{{/if}}
- {{#if (hasMedia "textFurigana" "日本語")}}This is an example of text with generated furigana: {{#getMedia "textFurigana" "日本語" escape=false}}{{/getMedia}}{{/if}}
+ {{#if (hasMedia "textFurigana" "日本語")}}This is an example of text with generated furigana: {{getMedia "textFurigana" "日本語" escape=false}}{{/if}}
- {{#if (hasMedia "dictionaryMedia" "image.png" dictionary="Example Dictionary")}}The remapped file name for image.png is: {{#getMedia "dictionaryMedia" "image.png" dictionary="Example Dictionary"}}{{/getMedia}}{{/if}}
+ {{#if (hasMedia "dictionaryMedia" "image.png" dictionary="Example Dictionary")}}The remapped file name for image.png is: {{getMedia "dictionaryMedia" "image.png" dictionary="Example Dictionary"}}{{/if}}
```
Output: