Shortcodes on Hugo Relearn Theme https://McShelby.github.io/hugo-theme-relearn/shortcodes/ Recent content in Shortcodes on Hugo Relearn Theme Hugo -- gohugo.io en Children https://McShelby.github.io/hugo-theme-relearn/shortcodes/children/ Mon, 01 Jan 0001 00:00:00 +0000 https://McShelby.github.io/hugo-theme-relearn/shortcodes/children/ Use the children shortcode to list the child pages of a page and the further descendants (children’s children). By default, the shortcode displays links to the child pages. Usage Parameter Default Description page current Specify the page name (section name) to display children for containerstyle “ul” Choose the style used to group all children. It could be any HTML tag name style “li” Choose the style used to display each descendant. Swagger https://McShelby.github.io/hugo-theme-relearn/shortcodes/swagger/ Mon, 01 Jan 0001 00:00:00 +0000 https://McShelby.github.io/hugo-theme-relearn/shortcodes/swagger/ This shortcode uses the RapiDoc library to display your OpenAPI Specifications. Note This only works in modern browsers. Configuration Swagger is configured with default settings. You can customize Swagger’s default settings for all of your files thru a JSON object in your config.toml or override these settings per page thru your pages frontmatter. The JSON object of your config.toml / frontmatter is forwarded into Swagger’s initialization. At the moment, only the theme setting is supported. Attachments https://McShelby.github.io/hugo-theme-relearn/shortcodes/attachments/ Mon, 01 Jan 0001 00:00:00 +0000 https://McShelby.github.io/hugo-theme-relearn/shortcodes/attachments/ The Attachments shortcode displays a list of files attached to a page. Attachments adivorciarsetoca00cape.pdf (361 KB) BachGavotteShort.mp3 (357 KB) Carroll_AliceAuPaysDesMerveilles.pdf (175 KB) hugo.png (17 KB) hugo.txt (20 B) movieselectricsheep-flock-244-32500-2.mp4 (340 KB) Usage The shortcurt lists files found in a specific folder. Currently, it support two implementations for pages If your page is a Markdown file, attachements must be placed in a folder named like your page and ending with . Button https://McShelby.github.io/hugo-theme-relearn/shortcodes/button/ Mon, 01 Jan 0001 00:00:00 +0000 https://McShelby.github.io/hugo-theme-relearn/shortcodes/button/ A button is a just a clickable button with optional icon. {{% button href="https://gohugo.io/" %}}Get Hugo{{% /button %}} {{% button href="https://gohugo.io/" icon="fas fa-download" %}}Get Hugo with icon{{% /button %}} {{% button href="https://gohugo.io/" icon="fas fa-download" icon-position="right" %}}Get Hugo with icon right{{% /button %}} Get Hugo Get Hugo with icon Get Hugo with icon right Expand https://McShelby.github.io/hugo-theme-relearn/shortcodes/expand/ Mon, 01 Jan 0001 00:00:00 +0000 https://McShelby.github.io/hugo-theme-relearn/shortcodes/expand/ The Expand shortcode displays an expandable/collapsible section of text on your page. Usage {{% expand [ <string> [ "true" | "false" ] ] %}} Yes! {{% /expand %}} The first optional parameter defines the text that appears next to the expand/collapse icon. The default text is "Expand me...". The second optional parameter controls if the block is initially shown as expanded ("true") or collapsed ("false"). The default ist "false". Examples I'll tell you a secret. Include https://McShelby.github.io/hugo-theme-relearn/shortcodes/include/ Mon, 01 Jan 0001 00:00:00 +0000 https://McShelby.github.io/hugo-theme-relearn/shortcodes/include/ The include shortcode includes other files from your project inside of the current file. This can even contain Markdown and will be taken into account when generating the table of contents. Usage {{% include <string> [ "true" | "false" ] %}} The first required parameter is the path to the file to be included. If the file’s content will be displayed as HTML, the second optional parameter controls if the first heading of the included file should be displayed ("true")- which is the default - or be hidden. Mermaid https://McShelby.github.io/hugo-theme-relearn/shortcodes/mermaid/ Mon, 01 Jan 0001 00:00:00 +0000 https://McShelby.github.io/hugo-theme-relearn/shortcodes/mermaid/ Mermaid is a library helping you to generate diagram and flowcharts from text, in a similar manner as Markdown. Note This only works in modern browsers. Warning Due to limitations with Mermaid, it is currently not possible to use Mermaid code fences in an initially collapsed expand shortcode. This is a know issue and can’t be fixed by this theme. Usage Just insert your Mermaid code in the mermaid shortcode like this: Notice https://McShelby.github.io/hugo-theme-relearn/shortcodes/notice/ Mon, 01 Jan 0001 00:00:00 +0000 https://McShelby.github.io/hugo-theme-relearn/shortcodes/notice/ The notice shortcode shows four types of disclaimers to help you structure your page. Usage {{% notice ( note | info | tip | warning ) [ <string> [ <string> ] ] %}} Some markup {{% /notice %}} The first parameter is required and indicates the type of notice. The second parameter is optional. If provided, it will be used as the title of the notice. If not provided, then the type of notice will be used as the title. Site param https://McShelby.github.io/hugo-theme-relearn/shortcodes/siteparam/ Mon, 01 Jan 0001 00:00:00 +0000 https://McShelby.github.io/hugo-theme-relearn/shortcodes/siteparam/ The siteparam shortcode is used to help you print values of site params. Usage {{% siteparam <string> %}} The first required parameter is the name of the site param to be displayed. Examples For instance, in this current site, the editURL variable is used in config.toml [params] editURL = "https://github.com/McShelby/hugo-theme-relearn/edit/main/exampleSite/content/" Use the siteparam shortcode to display its value. `editURL` Value : {{% siteparam "editURL" %}} is displayed as editURL Value : https://github. Tabbed views https://McShelby.github.io/hugo-theme-relearn/shortcodes/tabs/ Mon, 01 Jan 0001 00:00:00 +0000 https://McShelby.github.io/hugo-theme-relearn/shortcodes/tabs/ Choose which content to see across the page. Very handy for providing code snippets for multiple languages or providing configuration in different formats. Code example {{< tabs >}} {{% tab name="python" %}} ```python print("Hello World!") ``` {{% /tab %}} {{% tab name="R" %}} ```R > print("Hello World!") ``` {{% /tab %}} {{% tab name="Bash" %}} ```Bash echo "Hello World!" ``` {{% /tab %}} {{< /tabs >}} Renders as: python R Bash print("Hello World!