2022-04-02 13:30:16 +00:00
<!DOCTYPE html>
2022-11-01 01:10:49 +00:00
< html lang = "en" dir = "ltr" >
2022-04-02 13:30:16 +00:00
< head >
< meta charset = "utf-8" >
< meta name = "viewport" content = "height=device-height, width=device-width, initial-scale=1.0, minimum-scale=1.0" >
2023-11-12 12:44:57 +00:00
< meta name = "generator" content = "Hugo 0.120.4" >
2023-11-03 22:37:57 +00:00
< meta name = "generator" content = "Relearn 5.23.2+tip" >
2022-04-02 13:30:16 +00:00
< meta name = "description" content = "Documentation for Hugo Relearn Theme" >
2023-10-10 21:22:41 +00:00
< meta name = "author" content = "Sören Weber" >
2023-10-11 16:03:03 +00:00
< meta name = "twitter:card" content = "summary_large_image" >
< meta name = "twitter:image" content = "https://McShelby.github.io/hugo-theme-relearn/images/hero.png" >
< meta name = "twitter:title" content = "Shortcodes :: Hugo Relearn Theme" >
< meta name = "twitter:description" content = "Documentation for Hugo Relearn Theme" >
2023-10-11 15:32:39 +00:00
< meta property = "og:title" content = "Shortcodes :: Hugo Relearn Theme" >
< meta property = "og:description" content = "Documentation for Hugo Relearn Theme" >
< meta property = "og:type" content = "website" >
2023-10-11 15:42:11 +00:00
< meta property = "og:url" content = "https://McShelby.github.io/hugo-theme-relearn/shortcodes/index.html" >
2023-10-11 15:32:39 +00:00
< meta property = "og:image" content = "https://McShelby.github.io/hugo-theme-relearn/images/hero.png" >
< meta property = "og:site_name" content = "Hugo Relearn Theme" >
2022-04-02 13:30:16 +00:00
< title > Shortcodes :: Hugo Relearn Theme< / title >
2023-01-25 11:42:06 +00:00
< link href = "https://McShelby.github.io/hugo-theme-relearn/shortcodes/index.html" rel = "alternate" hreflang = "x-default" >
< link href = "https://McShelby.github.io/hugo-theme-relearn/shortcodes/index.html" rel = "alternate" hreflang = "en" >
2023-11-28 21:01:15 +00:00
< link href = "https://McShelby.github.io/hugo-theme-relearn/pir/shortcodes/index.html" rel = "alternate" hreflang = "art-pir" >
2022-11-15 06:35:08 +00:00
< link href = "https://McShelby.github.io/hugo-theme-relearn/shortcodes/index.html" rel = "canonical" type = "text/html" title = "Shortcodes :: Hugo Relearn Theme" >
2022-11-06 00:38:34 +00:00
< link href = "../shortcodes/index.xml" rel = "alternate" type = "application/rss+xml" title = "Shortcodes :: Hugo Relearn Theme" >
2023-12-03 14:23:32 +00:00
< link href = "../images/logo.svg?1701613407" rel = "icon" type = "image/svg+xml" >
2022-07-15 13:20:02 +00:00
<!-- https://github.com/filamentgroup/loadCSS/blob/master/README.md#how - to - use -->
2023-12-03 14:23:32 +00:00
< link href = "../css/fontawesome-all.min.css?1701613408" rel = "stylesheet" media = "print" onload = "this.media='all';this.onload=null;" > < noscript > < link href = "../css/fontawesome-all.min.css?1701613408" rel = "stylesheet" > < / noscript >
< link href = "../css/nucleus.css?1701613408" rel = "stylesheet" >
< link href = "../css/auto-complete.css?1701613408" rel = "stylesheet" media = "print" onload = "this.media='all';this.onload=null;" > < noscript > < link href = "../css/auto-complete.css?1701613408" rel = "stylesheet" > < / noscript >
< link href = "../css/perfect-scrollbar.min.css?1701613408" rel = "stylesheet" >
< link href = "../css/fonts.css?1701613408" rel = "stylesheet" media = "print" onload = "this.media='all';this.onload=null;" > < noscript > < link href = "../css/fonts.css?1701613408" rel = "stylesheet" > < / noscript >
< link href = "../css/theme.css?1701613408" rel = "stylesheet" >
< link href = "../css/theme-relearn-auto.css?1701613408" rel = "stylesheet" id = "R-variant-style" >
< link href = "../css/chroma-relearn-auto.css?1701613408" rel = "stylesheet" id = "R-variant-chroma-style" >
< link href = "../css/variant.css?1701613408" rel = "stylesheet" >
< link href = "../css/print.css?1701613408" rel = "stylesheet" media = "print" >
< link href = "../css/format-print.css?1701613408" rel = "stylesheet" >
< link href = "../css/ie.css?1701613408" rel = "stylesheet" >
< script src = "../js/url.js?1701613408" > < / script >
< script src = "../js/variant.js?1701613408" > < / script >
2022-04-02 13:30:16 +00:00
< script >
// hack to let hugo tell us how to get to the root when using relativeURLs, it needs to be called *url= for it to do its magic:
// https://github.com/gohugoio/hugo/blob/145b3fcce35fbac25c7033c91c1b7ae6d1179da8/transform/urlreplacers/absurlreplacer.go#L72
2022-11-05 23:35:48 +00:00
window.index_js_url="../index.search.js";
var root_url="../";
2022-04-02 13:30:16 +00:00
var baseUri=root_url.replace(/\/$/, '');
2023-11-16 22:53:34 +00:00
window.relearn = window.relearn || {};
window.relearn.baseUriFull='https:\/\/McShelby.github.io\/hugo-theme-relearn/';
// variant stuff
2023-12-03 14:23:32 +00:00
window.relearn.themeVariantModifier='';
2023-11-23 00:05:57 +00:00
window.variants & & variants.init( [ 'relearn-auto', 'relearn-light', 'relearn-dark', 'relearn-bright', 'zen-auto', 'zen-light', 'zen-dark', 'neon', 'learn', 'blue', 'green', 'red' ] );
2023-11-16 22:53:34 +00:00
// translations
window.T_Copy_to_clipboard = `Copy to clipboard`;
window.T_Copied_to_clipboard = `Copied to clipboard!`;
window.T_Copy_link_to_clipboard = `Copy link to clipboard`;
window.T_Link_copied_to_clipboard = `Copied link to clipboard!`;
window.T_Reset_view = `Reset view`;
window.T_View_reset = `View reset!`;
window.T_No_results_found = `No results found for "{0}"`;
window.T_N_results_found = `{1} results found for "{0}"`;
2022-04-02 13:30:16 +00:00
< / script >
2022-12-02 15:05:54 +00:00
< style >
2023-09-23 08:19:35 +00:00
#R-body img.bg-white {
2022-12-02 15:05:54 +00:00
background-color: white;
}
< / style >
2022-04-02 13:30:16 +00:00
< / head >
2022-11-15 06:35:08 +00:00
< body class = "mobile-support print disableInlineCopyToClipboard" data-url = "../shortcodes/index.html" >
2023-09-23 08:19:35 +00:00
< div id = "R-body" class = "default-animation" >
< div id = "R-body-overlay" > < / div >
< nav id = "R-topbar" >
2023-09-18 18:49:44 +00:00
< div class = "topbar-wrapper" >
2023-09-13 21:30:04 +00:00
< div class = "topbar-sidebar-divider" > < / div >
2023-09-18 18:49:44 +00:00
< div class = "topbar-area topbar-area-start" data-area = "start" >
< div class = "topbar-button topbar-button-sidebar" data-content-empty = "disable" data-width-s = "show" data-width-m = "hide" data-width-l = "hide" >
< button class = "topbar-control" onclick = "toggleNav()" type = "button" title = "Menu (CTRL+ALT+n)" >
2023-09-12 21:10:21 +00:00
< i class = "fa-fw fas fa-bars" > < / i >
< / button >
< / div >
2023-09-13 21:30:04 +00:00
< / div >
2023-09-20 22:28:27 +00:00
< ol class = "topbar-breadcrumbs breadcrumbs highlightable" itemscope itemtype = "http://schema.org/BreadcrumbList" > < li
2023-09-23 22:28:49 +00:00
itemscope itemtype="https://schema.org/ListItem" itemprop="itemListElement">< span itemprop = "name" > Shortcodes< / span > < meta itemprop = "position" content = "1" > < / li >
2023-09-13 21:30:04 +00:00
< / ol >
2023-09-18 18:49:44 +00:00
< div class = "topbar-area topbar-area-end" data-area = "end" >
2023-09-12 21:19:47 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< / div >
< / nav >
2023-09-23 08:19:35 +00:00
< div id = "R-main-overlay" > < / div >
< main id = "R-body-inner" class = "highlightable chapter narrow" tabindex = "-1" >
2022-04-02 13:30:16 +00:00
< div class = "flex-block-wrapper" >
2022-11-07 19:58:08 +00:00
< article class = "chapter" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
< / header >
2022-07-05 22:16:52 +00:00
< div class = "article-subheading" > Chapter 3< / div >
2022-11-13 21:34:47 +00:00
< h1 id = "shortcodes" > Shortcodes< / h1 >
2022-04-02 13:30:16 +00:00
< p > Hugo uses Markdown for its simple content format. However, there are a lot of things that Markdown doesn’ t support well. You could use pure HTML to expand possibilities.< / p >
< p > But this happens to be a bad idea. Everyone uses Markdown because it’ s pure and simple to read even non-rendered. You should avoid HTML to keep it as simple as possible.< / p >
2023-10-28 20:28:18 +00:00
< p > To avoid this limitations, Hugo created < a href = "https://gohugo.io/extras/shortcodes/" target = "_blank" > shortcodes< / a > . A shortcode is a simple snippet inside a page.< / p >
2022-04-02 13:30:16 +00:00
< p > The Relearn theme provides multiple shortcodes on top of existing ones.< / p >
2023-06-03 20:59:23 +00:00
2022-04-02 13:30:16 +00:00
< div class = "children children-h2 children-sort-" >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< h2 > < a href = "../shortcodes/attachments/index.html" > Attachments< / a > < / h2 > < p > List of files attached to a page< / p >
2022-12-01 00:38:08 +00:00
< h2 > < a href = "../shortcodes/badge/index.html" > Badge< / a > < / h2 > < p > Marker badges to display in your text< / p >
2022-11-08 14:43:28 +00:00
< h2 > < a href = "../shortcodes/button/index.html" > Button< / a > < / h2 > < p > Clickable buttons< / p >
< h2 > < a href = "../shortcodes/children/index.html" > Children< / a > < / h2 > < p > List the child pages of a page< / p >
< h2 > < a href = "../shortcodes/expand/index.html" > Expand< / a > < / h2 > < p > Expandable/collapsible sections of text< / p >
2023-06-21 23:35:19 +00:00
< h2 > < a href = "../shortcodes/highlight/index.html" > Highlight< / a > < / h2 > < p > Render code with a syntax highlighter< / p >
2022-12-02 17:32:53 +00:00
< h2 > < a href = "../shortcodes/icon/index.html" > Icon< / a > < / h2 > < p > Nice icons for your page< / p >
2022-11-08 14:43:28 +00:00
< h2 > < a href = "../shortcodes/include/index.html" > Include< / a > < / h2 > < p > Displays content from other files< / p >
< h2 > < a href = "../shortcodes/math/index.html" > Math< / a > < / h2 > < p > Beautiful math and chemical formulae< / p >
< h2 > < a href = "../shortcodes/mermaid/index.html" > Mermaid< / a > < / h2 > < p > Generate diagrams and flowcharts from text< / p >
< h2 > < a href = "../shortcodes/notice/index.html" > Notice< / a > < / h2 > < p > Disclaimers to help you structure your page< / p >
2023-05-14 21:06:26 +00:00
< h2 > < a href = "../shortcodes/openapi/index.html" > OpenAPI< / a > < / h2 > < p > UI for your OpenAPI / Swagger specifications< / p >
2023-07-26 20:30:13 +00:00
< h2 > < a href = "../shortcodes/siteparam/index.html" > SiteParam< / a > < / h2 > < p > Get value of site params< / p >
2023-05-25 10:46:07 +00:00
< h2 > < a href = "../shortcodes/tab/index.html" > Tab< / a > < / h2 > < p > Show content in a single tab< / p >
2023-01-14 00:40:32 +00:00
< h2 > < a href = "../shortcodes/tabs/index.html" > Tabs< / a > < / h2 > < p > Show content in tabbed views< / p >
2022-04-02 13:30:16 +00:00
< / div >
< footer class = "footline" >
< / footer >
< / article >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< section >
2022-10-07 18:46:19 +00:00
< h1 class = "a11y-only" > Subsections of Shortcodes< / h1 >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "attachments" > Attachments< / h1 >
2022-07-05 22:16:52 +00:00
2022-05-25 21:31:08 +00:00
< p > The < code > attachments< / code > shortcode displays a list of files attached to a page with adjustable color, title and icon.< / p >
2023-06-03 20:59:23 +00:00
2022-05-29 21:00:53 +00:00
< div class = "box attachments cstyle transparent" >
< div class = "box-label" > < i class = "fa-fw fas fa-paperclip" > < / i > Attachments< / div >
2022-04-02 13:30:16 +00:00
< ul class = "box-content attachments-files" >
2023-05-29 11:47:29 +00:00
< li > < a href = "../shortcodes/attachments/index.en.files/adivorciarsetoca00cape.pdf" > adivorciarsetoca00cape.pdf< / a > (361 KB)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/BachGavotteShort.mp3" > BachGavotteShort.mp3< / a > (357 KB)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/Carroll_AliceAuPaysDesMerveilles.pdf" > Carroll_AliceAuPaysDesMerveilles.pdf< / a > (175 KB)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/hugo.png" > hugo.png< / a > (17 KB)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/hugo.txt" > hugo.txt< / a > (20 B)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/movieselectricsheep-flock-244-32500-2.mp4" > movieselectricsheep-flock-244-32500-2.mp4< / a > (340 KB)< / li >
2022-04-02 13:30:16 +00:00
< / ul >
< / div >
2023-06-03 22:20:43 +00:00
2023-05-29 11:47:29 +00:00
< div class = "box notices cstyle warning" >
< div class = "box-label" > < i class = "fa-fw fas fa-exclamation-triangle" > < / i > Warning< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2023-05-29 11:47:29 +00:00
< p > Since Hugo < span class = "badge cstyle default badge-with-title" > < span class = "badge-title" > < i class = "fab fa-hackerrank" > < / i > < / span > < span class = "badge-content" style = "background-color: fuchsia;" > 0.112.0< / span > < / span > this only works for leaf bundles. Branch bundles and simple pages must be switched to leaf bundles or you are currently locked to a Hugo version < < code > 0.112.0< / code > .< / p >
2023-06-03 09:12:46 +00:00
< / div >
2023-05-29 11:47:29 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< h2 id = "usage" > Usage< / h2 >
2022-06-22 22:08:50 +00:00
< p > While the examples are using shortcodes with named parameter you are free to also call this shortcode from your own partials.< / p >
2023-07-27 15:06:14 +00:00
< div class = "tab-panel" data-tab-group = "shortcode-parameter" >
2022-06-22 22:08:50 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-06-22 22:08:50 +00:00
< button
data-tab-item="shortcode"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','shortcode')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-22 22:08:50 +00:00
< button
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','partial')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > partial< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-22 22:08:50 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="shortcode"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > attachments< / span > < span class = "nx" > sort< / span > < span class = "p" > =< / span > < span class = "s" > " asc" < / span > < span class = "o" > /%< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/attachments.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2022-06-22 22:08:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " sort" < / span > < span class = "s" > " asc" < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-06-22 22:08:50 +00:00
< / div >
< / div >
2023-01-23 22:49:15 +00:00
< h3 id = "parameter" > Parameter< / h3 >
< table >
< thead >
< tr >
2023-07-27 15:06:14 +00:00
< th > Name< / th >
< th > Default< / th >
< th > Notes< / th >
2023-01-23 22:49:15 +00:00
< / tr >
< / thead >
< tbody >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > style< / strong > < / td >
< td > < code > transparent< / code > < / td >
< td > The style scheme used for the box.< br > < br > - by severity: < code > info< / code > , < code > note< / code > , < code > tip< / code > , < code > warning< / code > < br > - by brand color: < code > primary< / code > , < code > secondary< / code > , < code > accent< / code > < br > - by color: < code > blue< / code > , < code > green< / code > , < code > grey< / code > , < code > orange< / code > , < code > red< / code > < br > - by special color: < code > default< / code > , < code > transparent< / code > , < code > code< / code > < / td >
2023-01-23 22:49:15 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > color< / strong > < / td >
< td > see notes< / td >
2023-10-28 20:28:18 +00:00
< td > The < a href = "https://developer.mozilla.org/en-US/docs/Web/CSS/color_value" target = "_blank" > CSS color value< / a > to be used. If not set, the chosen color depends on the < strong > style< / strong > . Any given value will overwrite the default.< br > < br > - for severity styles: a nice matching color for the severity< br > - for all other styles: the corresponding color< / td >
2023-01-23 22:49:15 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > title< / strong > < / td >
< td > see notes< / td >
< td > Arbitrary text for the box title. Depending on the < strong > style< / strong > there may be a default title. Any given value will overwrite the default.< br > < br > - for severity styles: the matching title for the severity< br > - for all other styles: < code > Attachments< / code > < br > < br > If you want no title for a severity style, you have to set this parameter to < code > " " < / code > (a non empty string filled with spaces)< / td >
2023-01-23 22:49:15 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > icon< / strong > < / td >
< td > see notes< / td >
2023-10-28 20:28:18 +00:00
< td > < a href = "../shortcodes/icon/index.html#finding-an-icon" > Font Awesome icon name< / a > set to the left of the title. Depending on the < strong > style< / strong > there may be a default icon. Any given value will overwrite the default.< br > < br > - for severity styles: a nice matching icon for the severity< br > - for all other styles: < code > paperclip< / code > < br > < br > If you want no icon, you have to set this parameter to < code > " " < / code > (a non empty d with spaces)< / td >
2023-01-23 22:49:15 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > sort< / strong > < / td >
< td > < code > asc< / code > < / td >
< td > Sorting the output in < code > asc< / code > ending or < code > desc< / code > ending order.< / td >
2023-01-23 22:49:15 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > pattern< / strong > < / td >
< td > < code > .*< / code > < / td >
2023-10-28 20:28:18 +00:00
< td > A < a href = "https://en.wikipedia.org/wiki/Regular_expression" target = "_blank" > regular expressions< / a > , used to filter the attachments by file name. For example:< br > < br > - to match a file suffix of ‘ jpg’ , use < code > .*\.jpg< / code > (not < code > *.\.jpg< / code > )< br > - to match file names ending in < code > jpg< / code > or < code > png< / code > , use < code > .*\.(jpg|png)< / code > < / td >
2023-01-23 22:49:15 +00:00
< / tr >
< / tbody >
< / table >
< h2 id = "setup" > Setup< / h2 >
< h3 id = "single-language" > Single language< / h3 >
2022-12-23 02:25:15 +00:00
< p > The shortcode lists files found in a specific folder. The name of the folder depends on your page type (either branch bundle, leaf bundle or page).< / p >
2022-04-02 13:30:16 +00:00
< ol >
< li >
2023-05-29 11:47:29 +00:00
< p > If your page is a leaf bundle, attachments must be placed in a nested < code > index.files< / code > folder, accordingly.< / p >
2022-04-02 13:30:16 +00:00
< blockquote >
< ul >
< li > content
< ul >
< li > _index.md< / li >
2023-05-29 11:47:29 +00:00
< li > page
< ul >
< li > _index.md< / li >
< li > < strong > _index.files< / strong >
2022-04-02 13:30:16 +00:00
< ul >
< li > attachment.pdf< / li >
< / ul >
< / li >
2023-05-29 11:47:29 +00:00
< / ul >
< / li >
2022-04-02 13:30:16 +00:00
< / ul >
< / li >
< / ul >
< / blockquote >
< / li >
< li >
2023-05-29 11:47:29 +00:00
< p > If your page is a branch bundle, attachments must be placed in a nested < code > _index.files< / code > folder, accordingly.< / p >
< p > < span class = "badge cstyle warning badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-exclamation-triangle" > < / i > < / span > < span class = "badge-content" > Warning< / span > < / span > This is only available for Hugo < < code > 0.112.0< / code > < / p >
2022-04-02 13:30:16 +00:00
< blockquote >
< ul >
< li > content
< ul >
< li > _index.md< / li >
< li > page
< ul >
< li > index.md< / li >
2022-12-23 02:25:15 +00:00
< li > < strong > index.files< / strong >
< ul >
< li > attachment.pdf< / li >
< / ul >
< / li >
< / ul >
< / li >
< / ul >
< / li >
< / ul >
< / blockquote >
2023-05-29 11:47:29 +00:00
< / li >
< li >
< p > For simple pages, attachments must be placed in a folder named like your page and ending with < code > .files< / code > .< / p >
< p > < span class = "badge cstyle warning badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-exclamation-triangle" > < / i > < / span > < span class = "badge-content" > Warning< / span > < / span > This is only available for Hugo < < code > 0.112.0< / code > < / p >
2022-12-23 02:25:15 +00:00
< blockquote >
< ul >
< li > content
< ul >
< li > _index.md< / li >
2023-05-29 11:47:29 +00:00
< li > < strong > page.files< / strong >
2022-04-02 13:30:16 +00:00
< ul >
< li > attachment.pdf< / li >
< / ul >
< / li >
2023-05-29 11:47:29 +00:00
< li > page.md< / li >
2022-04-02 13:30:16 +00:00
< / ul >
< / li >
< / ul >
< / blockquote >
< / li >
< / ol >
2023-01-23 22:49:15 +00:00
< h3 id = "multilingual" > Multilingual< / h3 >
2022-12-23 02:25:15 +00:00
< p > Be aware that if you use a multilingual website, you will need to have as many folders as languages and the language code must be part of the folder name.< / p >
< p > Eg. for a site in English and Piratish:< / p >
< blockquote >
< ul >
< li > content
< ul >
2023-05-29 11:47:29 +00:00
< li > index.en.md< / li >
< li > index.pir.md< / li >
< li > page
< ul >
< li > index.en.md< / li >
< li > index.pir.md< / li >
< li > < strong > index.en.files< / strong >
2022-12-23 02:25:15 +00:00
< ul >
< li > attachment.pdf< / li >
< / ul >
< / li >
2023-05-29 11:47:29 +00:00
< li > < strong > index.pir.files< / strong >
2022-12-23 02:25:15 +00:00
< ul >
< li > attachment.pdf< / li >
< / ul >
< / li >
2023-05-29 11:47:29 +00:00
< / ul >
< / li >
2022-12-23 02:25:15 +00:00
< / ul >
< / li >
< / ul >
< / blockquote >
2022-05-25 21:31:08 +00:00
< h2 id = "examples" > Examples< / h2 >
2022-06-05 17:32:37 +00:00
< h3 id = "custom-title-list-of-attachments-ending-in-pdf-or-mp4" > Custom Title, List of Attachments Ending in pdf or mp4< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > attachments< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Related **files**" < / span > < span class = "nx" > pattern< / span > < span class = "p" > =< / span > < span class = "s" > " .*\.(pdf|mp4)" < / span > < span class = "o" > /%< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 20:59:23 +00:00
< div class = "box attachments cstyle transparent" >
2023-03-14 20:49:22 +00:00
< div class = "box-label" > < i class = "fa-fw fas fa-paperclip" > < / i > Related < strong > files< / strong > < / div >
2022-04-02 13:30:16 +00:00
< ul class = "box-content attachments-files" >
2023-05-29 11:47:29 +00:00
< li > < a href = "../shortcodes/attachments/index.en.files/adivorciarsetoca00cape.pdf" > adivorciarsetoca00cape.pdf< / a > (361 KB)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/Carroll_AliceAuPaysDesMerveilles.pdf" > Carroll_AliceAuPaysDesMerveilles.pdf< / a > (175 KB)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/movieselectricsheep-flock-244-32500-2.mp4" > movieselectricsheep-flock-244-32500-2.mp4< / a > (340 KB)< / li >
2022-04-02 13:30:16 +00:00
< / ul >
< / div >
2022-06-05 17:32:37 +00:00
< h3 id = "info-styled-box-descending-sort-order" > Info Styled Box, Descending Sort Order< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > attachments< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " info" < / span > < span class = "nx" > sort< / span > < span class = "p" > =< / span > < span class = "s" > " desc" < / span > < span class = "o" > /%< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 20:59:23 +00:00
< div class = "box attachments cstyle info" >
2022-05-29 21:00:53 +00:00
< div class = "box-label" > < i class = "fa-fw fas fa-info-circle" > < / i > Info< / div >
2022-04-02 13:30:16 +00:00
< ul class = "box-content attachments-files" >
2023-05-29 11:47:29 +00:00
< li > < a href = "../shortcodes/attachments/index.en.files/movieselectricsheep-flock-244-32500-2.mp4" > movieselectricsheep-flock-244-32500-2.mp4< / a > (340 KB)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/hugo.txt" > hugo.txt< / a > (20 B)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/hugo.png" > hugo.png< / a > (17 KB)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/Carroll_AliceAuPaysDesMerveilles.pdf" > Carroll_AliceAuPaysDesMerveilles.pdf< / a > (175 KB)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/BachGavotteShort.mp3" > BachGavotteShort.mp3< / a > (357 KB)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/adivorciarsetoca00cape.pdf" > adivorciarsetoca00cape.pdf< / a > (361 KB)< / li >
2022-04-02 13:30:16 +00:00
< / ul >
< / div >
2023-01-23 22:49:15 +00:00
< h3 id = "with-user-defined-color-and-font-awesome-brand-icon" > With User-Defined Color and Font Awesome Brand Icon< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > attachments< / span > < span class = "nx" > color< / span > < span class = "p" > =< / span > < span class = "s" > " fuchsia" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " fab fa-hackerrank" < / span > < span class = "o" > /%< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 20:59:23 +00:00
< div class = "box attachments cstyle default" style = "--VARIABLE-BOX-color: fuchsia;" >
2023-01-23 22:49:15 +00:00
< div class = "box-label" > < i class = "fab fa-hackerrank" > < / i > Attachments< / div >
< ul class = "box-content attachments-files" >
2023-05-29 11:47:29 +00:00
< li > < a href = "../shortcodes/attachments/index.en.files/adivorciarsetoca00cape.pdf" > adivorciarsetoca00cape.pdf< / a > (361 KB)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/BachGavotteShort.mp3" > BachGavotteShort.mp3< / a > (357 KB)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/Carroll_AliceAuPaysDesMerveilles.pdf" > Carroll_AliceAuPaysDesMerveilles.pdf< / a > (175 KB)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/hugo.png" > hugo.png< / a > (17 KB)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/hugo.txt" > hugo.txt< / a > (20 B)< / li >
< li > < a href = "../shortcodes/attachments/index.en.files/movieselectricsheep-flock-244-32500-2.mp4" > movieselectricsheep-flock-244-32500-2.mp4< / a > (340 KB)< / li >
2023-01-23 22:49:15 +00:00
< / ul >
< / div >
< h3 id = "style-color-title-and-icons" > Style, Color, Title and Icons< / h3 >
2023-10-28 20:28:18 +00:00
< p > For further examples for < strong > style< / strong > , < strong > color< / strong > , < strong > title< / strong > and < strong > icon< / strong > , see the < a href = "../shortcodes/notice/index.html" > < code > notice< / code > shortcode< / a > documentation. The parameter are working the same way for both shortcodes, besides having different defaults.< / p >
2022-04-02 13:30:16 +00:00
< footer class = "footline" >
< / footer >
< / article >
2022-12-01 00:38:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
< / header >
2022-12-01 00:38:08 +00:00
< h1 id = "badge" > Badge< / h1 >
< p > The < code > badge< / code > shortcode displays little markers in your text with adjustable color, title and icon.< / p >
< p > < span class = "badge cstyle default" > < span class = "badge-content" > Important< / span > < / span >
< span class = "badge cstyle primary badge-with-title" > < span class = "badge-title" > Version< / span > < span class = "badge-content" > 6.6.6< / span > < / span >
2022-12-02 17:32:53 +00:00
< span class = "badge cstyle red badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-angle-double-up" > < / i > < / span > < span class = "badge-content" > Captain< / span > < / span >
2023-01-23 22:49:15 +00:00
< span class = "badge cstyle info badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-info-circle" > < / i > Info< / span > < span class = "badge-content" > New< / span > < / span >
< span class = "badge cstyle default badge-with-title" > < span class = "badge-title" > < i class = "fab fa-hackerrank" > < / i > < / span > < span class = "badge-content" style = "background-color: fuchsia;" > Awesome< / span > < / span > < / p >
2022-12-01 00:38:08 +00:00
< h2 id = "usage" > Usage< / h2 >
< p > While the examples are using shortcodes with named parameter you are free to also call this shortcode from your own partials.< / p >
2023-07-27 15:06:14 +00:00
< div class = "tab-panel" data-tab-group = "shortcode-parameter" >
2022-12-01 00:38:08 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-12-01 00:38:08 +00:00
< button
data-tab-item="shortcode"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','shortcode')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-12-01 00:38:08 +00:00
< button
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','partial')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > partial< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-12-01 00:38:08 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="shortcode"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Important< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-12-01 00:38:08 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " primary" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Version" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "mf" > 6.6.6< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-12-02 17:32:53 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " red" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " angle-double-up" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Captain< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-01-23 22:49:15 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " info" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > New< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > color< / span > < span class = "p" > =< / span > < span class = "s" > " fuchsia" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " fab fa-hackerrank" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Awesome< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/badge.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2022-12-01 00:38:08 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "s" > " Important" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/badge.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2022-12-01 00:38:08 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " style" < / span > < span class = "s" > " primary" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " title" < / span > < span class = "s" > " Version" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "s" > " 6.6.6" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/badge.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2022-12-01 00:38:08 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " style" < / span > < span class = "s" > " red" < / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " icon" < / span > < span class = "s" > " angle-double-up" < / span >
2022-12-01 00:38:08 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "s" > " Captain" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/badge.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2022-12-01 00:38:08 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " style" < / span > < span class = "s" > " info" < / span >
2023-01-23 22:49:15 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "s" > " New" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/badge.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2023-01-23 22:49:15 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " color" < / span > < span class = "s" > " fuchsia" < / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " icon" < / span > < span class = "s" > " fab fa-hackerrank" < / span >
2022-12-01 00:38:08 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "s" > " Awesome" < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-12-01 00:38:08 +00:00
< / div >
< / div >
< h3 id = "parameter" > Parameter< / h3 >
< table >
< thead >
< tr >
2023-07-27 15:06:14 +00:00
< th > Name< / th >
< th > Default< / th >
< th > Notes< / th >
2022-12-01 00:38:08 +00:00
< / tr >
< / thead >
< tbody >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > style< / strong > < / td >
< td > < code > default< / code > < / td >
< td > The style scheme used for the badge.< br > < br > - by severity: < code > info< / code > , < code > note< / code > , < code > tip< / code > , < code > warning< / code > < br > - by brand color: < code > primary< / code > , < code > secondary< / code > , < code > accent< / code > < br > - by color: < code > blue< / code > , < code > green< / code > , < code > grey< / code > , < code > orange< / code > , < code > red< / code > < br > - by special color: < code > default< / code > , < code > transparent< / code > , < code > code< / code > < / td >
2022-12-01 00:38:08 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > color< / strong > < / td >
< td > see notes< / td >
2023-10-28 20:28:18 +00:00
< td > The < a href = "https://developer.mozilla.org/en-US/docs/Web/CSS/color_value" target = "_blank" > CSS color value< / a > to be used. If not set, the chosen color depends on the < strong > style< / strong > . Any given value will overwrite the default.< br > < br > - for severity styles: a nice matching color for the severity< br > - for all other styles: the corresponding color< / td >
2022-12-01 00:38:08 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > title< / strong > < / td >
< td > see notes< / td >
< td > Arbitrary text for the badge title. Depending on the < strong > style< / strong > there may be a default title. Any given value will overwrite the default.< br > < br > - for severity styles: the matching title for the severity< br > - for all other styles: < em > < empty> < / em > < br > < br > If you want no title for a severity style, you have to set this parameter to < code > " " < / code > (a non empty string filled with spaces)< / td >
2023-01-23 22:49:15 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > icon< / strong > < / td >
< td > see notes< / td >
2023-10-28 20:28:18 +00:00
< td > < a href = "../shortcodes/icon/index.html#finding-an-icon" > Font Awesome icon name< / a > set to the left of the title. Depending on the < strong > style< / strong > there may be a default icon. Any given value will overwrite the default.< br > < br > - for severity styles: a nice matching icon for the severity< br > - for all other styles: < em > < empty> < / em > < br > < br > If you want no icon for a severity style, you have to set this parameter to < code > " " < / code > (a non empty string filled with spaces)< / td >
2022-12-01 00:38:08 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < em > < strong > < content> < / strong > < / em > < / td >
< td > < em > < empty> < / em > < / td >
< td > Arbitrary text for the badge.< / td >
2022-12-01 00:38:08 +00:00
< / tr >
< / tbody >
< / table >
< h2 id = "examples" > Examples< / h2 >
< h3 id = "style" > Style< / h3 >
< h4 id = "by-severity" > By Severity< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " info" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > New< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-12-01 00:38:08 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " note" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Change< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " tip" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Optional< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " warning" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Breaking< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > < span class = "badge cstyle info badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-info-circle" > < / i > Info< / span > < span class = "badge-content" > New< / span > < / span >
2022-12-01 00:38:08 +00:00
< span class = "badge cstyle note badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-exclamation-circle" > < / i > Note< / span > < span class = "badge-content" > Change< / span > < / span >
< span class = "badge cstyle tip badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-lightbulb" > < / i > Tip< / span > < span class = "badge-content" > Optional< / span > < / span >
< span class = "badge cstyle warning badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-exclamation-triangle" > < / i > Warning< / span > < span class = "badge-content" > Breaking< / span > < / span > < / p >
< h4 id = "by-brand-colors" > By Brand Colors< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " primary" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " bullhorn" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Announcement" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Mandatory< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-12-01 00:38:08 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " secondary" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " bullhorn" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Announcement" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Optional< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " accent" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " bullhorn" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Announcement" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Special< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > < span class = "badge cstyle primary badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-bullhorn" > < / i > Announcement< / span > < span class = "badge-content" > Mandatory< / span > < / span >
2023-01-23 23:14:54 +00:00
< span class = "badge cstyle secondary badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-bullhorn" > < / i > Announcement< / span > < span class = "badge-content" > Optional< / span > < / span >
< span class = "badge cstyle accent badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-bullhorn" > < / i > Announcement< / span > < span class = "badge-content" > Special< / span > < / span > < / p >
2022-12-01 00:38:08 +00:00
< h4 id = "by-color" > By Color< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " blue" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " palette" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Color" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Blue< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-12-01 00:38:08 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " green" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " palette" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Color" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Green< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " grey" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " palette" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Color" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Grey< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " orange" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " palette" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Color" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Orange< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " red" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " palette" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Color" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Red< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > < span class = "badge cstyle blue badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-palette" > < / i > Color< / span > < span class = "badge-content" > Blue< / span > < / span >
2022-12-01 00:38:08 +00:00
< span class = "badge cstyle green badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-palette" > < / i > Color< / span > < span class = "badge-content" > Green< / span > < / span >
< span class = "badge cstyle grey badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-palette" > < / i > Color< / span > < span class = "badge-content" > Grey< / span > < / span >
< span class = "badge cstyle orange badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-palette" > < / i > Color< / span > < span class = "badge-content" > Orange< / span > < / span >
< span class = "badge cstyle red badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-palette" > < / i > Color< / span > < span class = "badge-content" > Red< / span > < / span > < / p >
< h4 id = "by-special-color" > By Special Color< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " default" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " palette" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Color" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Default< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " transparent" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " palette" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Color" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Transparent< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > < span class = "badge cstyle default badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-palette" > < / i > Color< / span > < span class = "badge-content" > Default< / span > < / span >
2022-12-01 00:38:08 +00:00
< span class = "badge cstyle transparent badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-palette" > < / i > Color< / span > < span class = "badge-content" > Transparent< / span > < / span > < / p >
< h3 id = "variants" > Variants< / h3 >
< h4 id = "without-icon-and-title-text" > Without Icon and Title Text< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "mf" > 6.6.6< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-12-01 00:38:08 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " info" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " " < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " " < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Awesome< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " red" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Captain< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > < span class = "badge cstyle default" > < span class = "badge-content" > 6.6.6< / span > < / span >
2022-12-01 00:38:08 +00:00
< span class = "badge cstyle info" > < span class = "badge-content" > Awesome< / span > < / span >
< span class = "badge cstyle red" > < span class = "badge-content" > Captain< / span > < / span > < / p >
< h4 id = "without-icon" > Without Icon< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Version" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "mf" > 6.6.6< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-12-01 00:38:08 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " info" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " " < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Awesome< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " red" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Rank" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Captain< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > < span class = "badge cstyle default badge-with-title" > < span class = "badge-title" > Version< / span > < span class = "badge-content" > 6.6.6< / span > < / span >
2022-12-01 00:38:08 +00:00
< span class = "badge cstyle info badge-with-title" > < span class = "badge-title" > Info< / span > < span class = "badge-content" > Awesome< / span > < / span >
< span class = "badge cstyle red badge-with-title" > < span class = "badge-title" > Rank< / span > < span class = "badge-content" > Captain< / span > < / span > < / p >
< h4 id = "without-title-text" > Without Title Text< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " star" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "mf" > 6.6.6< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-12-01 00:38:08 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " info" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " " < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Awesome< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " red" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " angle-double-up" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Captain< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > < span class = "badge cstyle default badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-star" > < / i > < / span > < span class = "badge-content" > 6.6.6< / span > < / span >
2022-12-01 00:38:08 +00:00
< span class = "badge cstyle info badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-info-circle" > < / i > < / span > < span class = "badge-content" > Awesome< / span > < / span >
2022-12-02 17:32:53 +00:00
< span class = "badge cstyle red badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-angle-double-up" > < / i > < / span > < span class = "badge-content" > Captain< / span > < / span > < / p >
2022-12-01 00:38:08 +00:00
< h4 id = "all-set" > All Set< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " star" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Version" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "mf" > 6.6.6< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-12-01 00:38:08 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " info" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Awesome< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " red" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " angle-double-up" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Rank" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Captain< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > < span class = "badge cstyle default badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-star" > < / i > Version< / span > < span class = "badge-content" > 6.6.6< / span > < / span >
2022-12-01 00:38:08 +00:00
< span class = "badge cstyle info badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-info-circle" > < / i > Info< / span > < span class = "badge-content" > Awesome< / span > < / span >
2022-12-02 17:32:53 +00:00
< span class = "badge cstyle red badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-angle-double-up" > < / i > Rank< / span > < span class = "badge-content" > Captain< / span > < / span > < / p >
2022-12-01 00:38:08 +00:00
< h4 id = "override-for-severity" > Override for Severity< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " info" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " rocket" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Feature" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Awesome< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < span class = "badge cstyle info badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-rocket" > < / i > Feature< / span > < span class = "badge-content" > Awesome< / span > < / span >
2022-12-01 00:38:08 +00:00
< h3 id = "other" > Other< / h3 >
2023-03-14 20:49:22 +00:00
< h4 id = "with-user-defined-color-font-awesome-brand-icon-and-markdown-title-and-content" > With User-Defined Color, Font Awesome Brand Icon and Markdown Title and Content< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > color< / span > < span class = "p" > =< / span > < span class = "s" > " fuchsia" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " fab fa-hackerrank" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " **Font**" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "o" > **< / span > < span class = "nx" > Awesome< / span > < span class = "o" > **< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < span class = "badge cstyle default badge-with-title" > < span class = "badge-title" > < i class = "fab fa-hackerrank" > < / i > < strong > Font< / strong > < / span > < span class = "badge-content" style = "background-color: fuchsia;" > < strong > Awesome< / strong > < / span > < / span >
2022-12-02 17:32:53 +00:00
< h4 id = "with-icon-content" > With Icon Content< / h4 >
2023-10-28 20:28:18 +00:00
< p > You can combine the badge with the < a href = "../shortcodes/icon/index.html" > < code > icon< / code > shortcode< / a > to create even more stunning visuals.< / p >
2022-12-02 17:32:53 +00:00
< p > In this case you need to declare < code > {{< badge > }}< / code > instead of < code > {{% badge %}}< / code > . Note, that in this case it is not possible to put markdown in the content.< / p >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " primary" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " angle-double-up" < / span > < span class = "p" > > }}{{< / span > < span class = "o" > %< / span > < span class = "nx" > icon< / span > < span class = "nx" > skull< / span > < span class = "o" > -< / span > < span class = "nx" > crossbones< / span > < span class = "o" > %< / span > < span class = "p" > }}{{< < / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "p" > > }}< / span >
2022-12-02 18:27:40 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " primary" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " angle-double-up" < / span > < span class = "p" > > }}{{< / span > < span class = "o" > %< / span > < span class = "nx" > icon< / span > < span class = "nx" > skull< / span > < span class = "o" > -< / span > < span class = "nx" > crossbones< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Pirate< / span > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "p" > > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " primary" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Rank" < / span > < span class = "p" > > }}{{< / span > < span class = "o" > %< / span > < span class = "nx" > icon< / span > < span class = "nx" > skull< / span > < span class = "o" > -< / span > < span class = "nx" > crossbones< / span > < span class = "o" > %< / span > < span class = "p" > }}{{< < / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "p" > > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " primary" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Rank" < / span > < span class = "p" > > }}{{< / span > < span class = "o" > %< / span > < span class = "nx" > icon< / span > < span class = "nx" > skull< / span > < span class = "o" > -< / span > < span class = "nx" > crossbones< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Pirate< / span > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "p" > > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " primary" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " angle-double-up" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Rank" < / span > < span class = "p" > > }}{{< / span > < span class = "o" > %< / span > < span class = "nx" > icon< / span > < span class = "nx" > skull< / span > < span class = "o" > -< / span > < span class = "nx" > crossbones< / span > < span class = "o" > %< / span > < span class = "p" > }}{{< < / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "p" > > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " primary" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " angle-double-up" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Rank" < / span > < span class = "p" > > }}{{< / span > < span class = "o" > %< / span > < span class = "nx" > icon< / span > < span class = "nx" > skull< / span > < span class = "o" > -< / span > < span class = "nx" > crossbones< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Pirate< / span > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > < span class = "badge cstyle primary badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-angle-double-up" > < / i > < / span > < span class = "badge-content" > < i class = "fa-fw fas fa-skull-crossbones" > < / i > < / span > < / span > < br >
2023-06-08 11:37:35 +00:00
< span class = "badge cstyle primary badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-angle-double-up" > < / i > < / span > < span class = "badge-content" > < i class = "fa-fw fas fa-skull-crossbones" > < / i > Pirate< / span > < / span > < br >
< span class = "badge cstyle primary badge-with-title" > < span class = "badge-title" > Rank< / span > < span class = "badge-content" > < i class = "fa-fw fas fa-skull-crossbones" > < / i > < / span > < / span > < br >
< span class = "badge cstyle primary badge-with-title" > < span class = "badge-title" > Rank< / span > < span class = "badge-content" > < i class = "fa-fw fas fa-skull-crossbones" > < / i > Pirate< / span > < / span > < br >
< span class = "badge cstyle primary badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-angle-double-up" > < / i > Rank< / span > < span class = "badge-content" > < i class = "fa-fw fas fa-skull-crossbones" > < / i > < / span > < / span > < br >
< span class = "badge cstyle primary badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-angle-double-up" > < / i > Rank< / span > < span class = "badge-content" > < i class = "fa-fw fas fa-skull-crossbones" > < / i > Pirate< / span > < / span > < / p >
2022-12-01 00:38:08 +00:00
< h4 id = "inside-of-text" > Inside of Text< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "nx" > Lorem< / span > < span class = "nx" > ipsum< / span > < span class = "nx" > dolor< / span > < span class = "nx" > sit< / span > < span class = "nx" > amet< / span > < span class = "p" > ,< / span > < span class = "nx" > graecis< / span > < span class = "nx" > denique< / span > < span class = "nx" > ei< / span > < span class = "nx" > vel< / span > < span class = "p" > ,< / span > < span class = "nx" > at< / span > < span class = "nx" > duo< / span > < span class = "nx" > primis< / span > < span class = "nx" > mandamus< / span > < span class = "p" > .< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > badge< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " blue" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " rocket" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Awesome< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > badge< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Et< / span > < span class = "nx" > legere< / span > < span class = "nx" > ocurreret< / span > < span class = "nx" > pri< / span > < span class = "p" > ,< / span > < span class = "nx" > animal< / span > < span class = "nx" > tacimates< / span > < span class = "nx" > complectitur< / span > < span class = "nx" > ad< / span > < span class = "nx" > cum< / span > < span class = "p" > .< / span > < span class = "nx" > Cu< / span > < span class = "nx" > eum< / span > < span class = "nx" > inermis< / span > < span class = "nx" > inimicus< / span > < span class = "nx" > efficiendi< / span > < span class = "p" > .< / span > < span class = "nx" > Labore< / span > < span class = "nx" > officiis< / span > < span class = "nx" > his< / span > < span class = "nx" > ex< / span > < span class = "p" > ,< / span > < span class = "nx" > soluta< / span > < span class = "nx" > officiis< / span > < span class = "nx" > concludaturque< / span > < span class = "nx" > ei< / span > < span class = "nx" > qui< / span > < span class = "p" > ,< / span > < span class = "nx" > vide< / span > < span class = "nx" > sensibus< / span > < span class = "nx" > vim< / span > < span class = "nx" > ad< / span > < span class = "p" > .< / span > < / span > < / span > < / code > < / pre > < / div > < p > Lorem ipsum dolor sit amet, graecis denique ei vel, at duo primis mandamus. < span class = "badge cstyle blue badge-with-title" > < span class = "badge-title" > < i class = "fa-fw fas fa-rocket" > < / i > < / span > < span class = "badge-content" > Awesome< / span > < / span > Et legere ocurreret pri, animal tacimates complectitur ad cum. Cu eum inermis inimicus efficiendi. Labore officiis his ex, soluta officiis concludaturque ei qui, vide sensibus vim ad.< / p >
2022-12-01 00:38:08 +00:00
< footer class = "footline" >
< / footer >
< / article >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "button" > Button< / h1 >
2022-07-05 22:16:52 +00:00
2022-05-29 21:00:53 +00:00
< p > The < code > button< / code > shortcode displays a clickable button with adjustable color, title and icon.< / p >
2023-11-29 20:52:48 +00:00
< p > < span class = "btn cstyle interactive transparent" > < a href = "https://gohugo.io/" target = "_blank" > Get Hugo< / a > < / span >
< span class = "btn cstyle interactive warning" > < a href = "https://gohugo.io/" target = "_blank" > < i class = "fa-fw fas fa-dragon" > < / i > Get Hugo< / a > < / span > < / p >
2022-05-29 21:00:53 +00:00
< h2 id = "usage" > Usage< / h2 >
2022-06-22 22:08:50 +00:00
< p > While the examples are using shortcodes with named parameter you are free to also call this shortcode from your own partials.< / p >
2023-07-27 15:06:14 +00:00
< div class = "tab-panel" data-tab-group = "shortcode-parameter" >
2022-06-22 22:08:50 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-06-22 22:08:50 +00:00
< button
data-tab-item="shortcode"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','shortcode')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-22 22:08:50 +00:00
< button
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','partial')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > partial< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-22 22:08:50 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="shortcode"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " warning" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " dragon" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/button.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2022-06-22 22:08:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " href" < / span > < span class = "s" > " https://gohugo.io/" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "s" > " Get Hugo" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/button.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2022-06-22 22:08:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " href" < / span > < span class = "s" > " https://gohugo.io/" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " style" < / span > < span class = "s" > " warning" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " icon" < / span > < span class = "s" > " dragon" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "s" > " Get Hugo" < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-06-22 22:08:50 +00:00
< / div >
< / div >
< p > Once the button is clicked, it opens another browser tab for the given URL.< / p >
2022-06-05 17:32:37 +00:00
< h3 id = "parameter" > Parameter< / h3 >
2022-05-29 21:00:53 +00:00
< table >
< thead >
< tr >
2023-07-27 15:06:14 +00:00
< th > Name< / th >
< th > Default< / th >
< th > Notes< / th >
2022-05-29 21:00:53 +00:00
< / tr >
< / thead >
< tbody >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > href< / strong > < / td >
< td > < em > < empty> < / em > < / td >
< td > Either the destination URL for the button or JavaScript code to be executed on click. If this parameter is not set, the button will do nothing but is still displayed as clickable.< br > < br > - if starting with < code > javascript:< / code > all following text will be executed in your browser< br > - every other string will be interpreted as URL< / td >
2022-05-29 21:00:53 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > style< / strong > < / td >
< td > < code > transparent< / code > < / td >
< td > The style scheme used for the button.< br > < br > - by severity: < code > info< / code > , < code > note< / code > , < code > tip< / code > , < code > warning< / code > < br > - by brand color: < code > primary< / code > , < code > secondary< / code > , < code > accent< / code > < br > - by color: < code > blue< / code > , < code > green< / code > , < code > grey< / code > , < code > orange< / code > , < code > red< / code > < br > - by special color: < code > default< / code > , < code > transparent< / code > , < code > code< / code > < / td >
2023-01-23 22:49:15 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > color< / strong > < / td >
< td > see notes< / td >
2023-10-28 20:28:18 +00:00
< td > The < a href = "https://developer.mozilla.org/en-US/docs/Web/CSS/color_value" target = "_blank" > CSS color value< / a > to be used. If not set, the chosen color depends on the < strong > style< / strong > . Any given value will overwrite the default.< br > < br > - for severity styles: a nice matching color for the severity< br > - for all other styles: the corresponding color< / td >
2022-05-29 21:00:53 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > icon< / strong > < / td >
< td > see notes< / td >
2023-10-28 20:28:18 +00:00
< td > < a href = "../shortcodes/icon/index.html#finding-an-icon" > Font Awesome icon name< / a > set to the left of the title. Depending on the < strong > style< / strong > there may be a default icon. Any given value will overwrite the default.< br > < br > - for severity styles: a nice matching icon for the severity< br > - for all other styles: < em > < empty> < / em > < br > < br > If you want no icon for a severity style, you have to set this parameter to < code > " " < / code > (a non empty string filled with spaces)< / td >
2022-05-29 21:00:53 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > iconposition< / strong > < / td >
< td > < code > left< / code > < / td >
< td > Places the icon to the < code > left< / code > or < code > right< / code > of the title.< / td >
2022-05-29 21:00:53 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > target< / strong > < / td >
< td > see notes< / td >
< td > The destination frame/window if < strong > href< / strong > is an URL. Otherwise the parameter is not used. This behaves similar to normal links. If the parameter is not given it defaults to:< br > < br > - the setting of < code > externalLinkTarget< / code > or < code > _blank< / code > if not set, for any address starting with < code > http://< / code > or < code > https://< / code > < br > - no specific value for all other links< / td >
2022-11-28 17:44:03 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > type< / strong > < / td >
< td > see notes< / td >
2023-10-28 20:28:18 +00:00
< td > The < a href = "https://developer.mozilla.org/en-US/docs/Web/HTML/Element/button#attr-type" target = "_blank" > button type< / a > if < strong > href< / strong > is JavaScript. Otherwise the parameter is not used. If the parameter is not given it defaults to < code > button< / code > < / td >
2022-10-31 20:10:53 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < em > < strong > < content> < / strong > < / em > < / td >
< td > see notes< / td >
< td > Arbitrary text for the button title. Depending on the < strong > style< / strong > there may be a default title. Any given value will overwrite the default.< br > < br > - for severity styles: the matching title for the severity< br > - for all other styles: < em > < empty> < / em > < br > < br > If you want no title for a severity style, you have to set this parameter to < code > " " < / code > (a non empty string filled with spaces)< / td >
2022-05-29 21:00:53 +00:00
< / tr >
< / tbody >
< / table >
< h2 id = "examples" > Examples< / h2 >
< h3 id = "style" > Style< / h3 >
2022-06-05 17:32:37 +00:00
< h4 id = "by-severity" > By Severity< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " info" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-06-05 17:32:37 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " note" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " tip" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-11-29 20:52:48 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " warning" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > < span class = "btn cstyle interactive info" > < a href = "https://gohugo.io/" target = "_blank" > < i class = "fa-fw fas fa-info-circle" > < / i > Get Hugo< / a > < / span >
< span class = "btn cstyle interactive note" > < a href = "https://gohugo.io/" target = "_blank" > < i class = "fa-fw fas fa-exclamation-circle" > < / i > Get Hugo< / a > < / span >
< span class = "btn cstyle interactive tip" > < a href = "https://gohugo.io/" target = "_blank" > < i class = "fa-fw fas fa-lightbulb" > < / i > Get Hugo< / a > < / span >
< span class = "btn cstyle interactive warning" > < a href = "https://gohugo.io/" target = "_blank" > < i class = "fa-fw fas fa-exclamation-triangle" > < / i > Get Hugo< / a > < / span > < / p >
2022-06-05 17:32:37 +00:00
< h4 id = "by-brand-colors" > By Brand Colors< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " primary" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-06-05 17:32:37 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " secondary" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-11-29 20:52:48 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " accent" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > < span class = "btn cstyle interactive primary" > < a href = "https://gohugo.io/" target = "_blank" > Get Hugo< / a > < / span >
< span class = "btn cstyle interactive secondary" > < a href = "https://gohugo.io/" target = "_blank" > Get Hugo< / a > < / span >
< span class = "btn cstyle interactive accent" > < a href = "https://gohugo.io/" target = "_blank" > Get Hugo< / a > < / span > < / p >
2022-06-05 17:32:37 +00:00
< h4 id = "by-color" > By Color< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " blue" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-06-05 17:32:37 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " green" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " grey" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " orange" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-11-29 20:52:48 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " red" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > < span class = "btn cstyle interactive blue" > < a href = "https://gohugo.io/" target = "_blank" > Get Hugo< / a > < / span >
< span class = "btn cstyle interactive green" > < a href = "https://gohugo.io/" target = "_blank" > Get Hugo< / a > < / span >
< span class = "btn cstyle interactive grey" > < a href = "https://gohugo.io/" target = "_blank" > Get Hugo< / a > < / span >
< span class = "btn cstyle interactive orange" > < a href = "https://gohugo.io/" target = "_blank" > Get Hugo< / a > < / span >
< span class = "btn cstyle interactive red" > < a href = "https://gohugo.io/" target = "_blank" > Get Hugo< / a > < / span > < / p >
2022-06-05 17:32:37 +00:00
< h4 id = "by-special-color" > By Special Color< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " default" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-11-29 20:52:48 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " transparent" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > < span class = "btn cstyle interactive default" > < a href = "https://gohugo.io/" target = "_blank" > Get Hugo< / a > < / span >
< span class = "btn cstyle interactive transparent" > < a href = "https://gohugo.io/" target = "_blank" > Get Hugo< / a > < / span > < / p >
2022-05-29 21:00:53 +00:00
< h3 id = "icon" > Icon< / h3 >
2023-07-26 19:36:09 +00:00
< h4 id = "empty" > Empty< / h4 >
2023-11-29 20:52:48 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " " < / span > < span class = "o" > %< / span > < span class = "p" > }}{{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < span class = "btn cstyle interactive transparent" > < a href = "https://gohugo.io/" target = "_blank" > < / a > < / span >
2023-07-26 19:36:09 +00:00
< h4 id = "only" > Only< / h4 >
2023-11-29 20:52:48 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " download" < / span > < span class = "o" > %< / span > < span class = "p" > }}{{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < span class = "btn cstyle interactive transparent" > < a href = "https://gohugo.io/" target = "_blank" > < i class = "fa-fw fas fa-download" > < / i > < / a > < / span >
2022-06-05 17:32:37 +00:00
< h4 id = "to-the-left" > To the Left< / h4 >
2023-11-29 20:52:48 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " download" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < span class = "btn cstyle interactive transparent" > < a href = "https://gohugo.io/" target = "_blank" > < i class = "fa-fw fas fa-download" > < / i > Get Hugo< / a > < / span >
2022-06-05 17:32:37 +00:00
< h4 id = "to-the-right" > To the Right< / h4 >
2023-11-29 20:52:48 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " download" < / span > < span class = "nx" > iconposition< / span > < span class = "p" > =< / span > < span class = "s" > " right" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < span class = "btn cstyle interactive transparent" > < a href = "https://gohugo.io/" target = "_blank" > Get Hugo < i class = "fa-fw fas fa-download" > < / i > < / a > < / span >
2022-05-29 21:00:53 +00:00
< h4 id = "override-for-severity" > Override for Severity< / h4 >
2023-11-29 20:52:48 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " dragon" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " warning" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < span class = "btn cstyle interactive warning" > < a href = "https://gohugo.io/" target = "_blank" > < i class = "fa-fw fas fa-dragon" > < / i > Get Hugo< / a > < / span >
2022-10-31 20:10:53 +00:00
< h3 id = "target" > Target< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > target< / span > < span class = "p" > =< / span > < span class = "s" > " _self" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "nx" > in< / span > < span class = "nx" > same< / span > < span class = "nx" > window< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-11-29 20:52:48 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "nx" > Hugo< / span > < span class = "nx" > in< / span > < span class = "nx" > new< / span > < span class = "nx" > Window< / span > < span class = "o" > /< / span > < span class = "nf" > Frame< / span > < span class = "p" > (< / span > < span class = "k" > default< / span > < span class = "p" > ){{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > < span class = "btn cstyle interactive transparent" > < a href = "https://gohugo.io/" target = "_self" > Get Hugo in same Window/Frame< / a > < / span >
< span class = "btn cstyle interactive transparent" > < a href = "https://gohugo.io/" target = "_blank" > Get Hugo in new Window/Frame (default)< / a > < / span > < / p >
2022-05-29 21:00:53 +00:00
< h3 id = "other" > Other< / h3 >
2023-03-14 20:49:22 +00:00
< h4 id = "with-user-defined-color-font-awesome-brand-icon-and-markdown-title" > With User-Defined Color, Font Awesome Brand Icon and Markdown Title< / h4 >
2023-11-29 20:52:48 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > color< / span > < span class = "p" > =< / span > < span class = "s" > " fuchsia" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " fab fa-hackerrank" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Get< / span > < span class = "o" > **< / span > < span class = "nx" > Hugo< / span > < span class = "o" > **< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < span class = "btn cstyle interactive default" style = "--VARIABLE-BOX-color: fuchsia;" > < a href = "https://gohugo.io/" target = "_blank" > < i class = "fab fa-hackerrank" > < / i > Get < strong > Hugo< / strong > < / a > < / span >
2022-11-28 17:44:03 +00:00
< h4 id = "severity-style-with-all-defaults" > Severity Style with All Defaults< / h4 >
2023-11-29 20:52:48 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " https://gohugo.io/" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " tip" < / span > < span class = "o" > %< / span > < span class = "p" > }}{{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < span class = "btn cstyle interactive tip" > < a href = "https://gohugo.io/" target = "_blank" > < i class = "fa-fw fas fa-lightbulb" > < / i > Tip< / a > < / span >
2022-11-28 17:44:03 +00:00
< h4 id = "button-to-internal-page" > Button to Internal Page< / h4 >
2023-11-29 20:52:48 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " /index.html" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Home< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < span class = "btn cstyle interactive transparent" > < a href = "../index.html" > Home< / a > < / span >
2022-11-28 17:44:03 +00:00
< h4 id = "button-with-javascript-action" > Button with JavaScript Action< / h4 >
< p > If your JavaScript action does not change the focus afterwards, make sure to call < code > this.blur()< / code > in the end to unselect the button.< / p >
2023-11-29 20:52:48 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > button< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " primary" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " bullhorn" < / span > < span class = "nx" > href< / span > < span class = "p" > =< / span > < span class = "s" > " javascript:alert(' Hello world!' );this.blur();" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Shout< / span > < span class = "nx" > it< / span > < span class = "nx" > out< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > button< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < span class = "btn cstyle interactive primary" > < button onclick = "alert('Hello world!');this.blur();" type = "button" > < i class = "fa-fw fas fa-bullhorn" > < / i > Shout it out< / button > < / span >
2022-11-28 17:44:03 +00:00
< h4 id = "button-within-a-form-element" > Button within a < code > form< / code > Element< / h4 >
2023-11-29 23:15:02 +00:00
< p > To use native HTML elements in your Markdown, add this in your < code > hugo.toml< / code > < / p >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-toml" data-lang = "toml" > < span class = "line" > < span class = "cl" > < span class = "p" > [< / span > < span class = "nx" > markup< / span > < span class = "p" > .< / span > < span class = "nx" > goldmark< / span > < span class = "p" > .< / span > < span class = "nx" > renderer< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > unsafe< / span > < span class = "p" > =< / span > < span class = "kc" > true< / span > < / span > < / span > < / code > < / pre > < / div > < div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-html" data-lang = "html" > < span class = "line" > < span class = "cl" > < span class = "p" > < < / span > < span class = "nt" > form< / span > < span class = "na" > action< / span > < span class = "o" > =< / span > < span class = "s" > " ../../search.html" < / span > < span class = "na" > method< / span > < span class = "o" > =< / span > < span class = "s" > " get" < / span > < span class = "p" > > < / span >
2022-11-28 17:44:03 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > < < / span > < span class = "nt" > input< / span > < span class = "na" > name< / span > < span class = "o" > =< / span > < span class = "s" > " search-by-detail" < / span > < span class = "na" > class< / span > < span class = "o" > =< / span > < span class = "s" > " search-by" < / span > < span class = "na" > type< / span > < span class = "o" > =< / span > < span class = "s" > " search" < / span > < span class = "p" > > < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > {{% button type=" submit" style=" secondary" icon=" search" %}}Search{{% /button %}}
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > < /< / span > < span class = "nt" > form< / span > < span class = "p" > > < / span > < / span > < / span > < / code > < / pre > < / div > < form action = "../../search.html" method = "get" >
2022-11-28 17:44:03 +00:00
< div class = "searchform" style = "width: 20vw;" >
< input name = "search-by-detail" class = "search-by" type = "search" placeholder = "Search..." >
2023-11-29 20:52:48 +00:00
< span class = "btn cstyle interactive secondary" > < button onclick = "" type = "submit" > < i class = "fa-fw fas fa-search" > < / i > Search< / button > < / span >
2022-11-28 17:44:03 +00:00
< / div >
< / form >
2022-04-02 13:30:16 +00:00
< footer class = "footline" >
< / footer >
< / article >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "children" > Children< / h1 >
2022-07-05 22:16:52 +00:00
2023-01-14 00:40:32 +00:00
< p > The < code > children< / code > shortcode lists the child pages of the current page and its descendants.< / p >
2023-06-03 20:59:23 +00:00
2022-06-22 22:08:50 +00:00
< ul class = "children children-li children-sort-weight" >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/test/index.html" > page X< / a > < / li >
< li > < a href = "../shortcodes/children/children-1/index.html" > page 1< / a > < / li >
< li > < a href = "../shortcodes/children/children-2/index.html" > page 2< / a > < / li >
< li > < a href = "../shortcodes/children/children-3/index.html" > page 3< / a > < / li >
2022-06-22 22:08:50 +00:00
< / ul >
2022-04-02 13:30:16 +00:00
< h2 id = "usage" > Usage< / h2 >
2022-06-22 22:08:50 +00:00
< p > While the examples are using shortcodes with named parameter you are free to also call this shortcode from your own partials.< / p >
2023-07-27 15:06:14 +00:00
< div class = "tab-panel" data-tab-group = "shortcode-parameter" >
2022-06-22 22:08:50 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-06-22 22:08:50 +00:00
< button
data-tab-item="shortcode"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','shortcode')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-22 22:08:50 +00:00
< button
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','partial')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > partial< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-22 22:08:50 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="shortcode"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > children< / span > < span class = "nx" > sort< / span > < span class = "p" > =< / span > < span class = "s" > " weight" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/children.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2022-06-22 22:08:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " sort" < / span > < span class = "s" > " weight" < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-06-22 22:08:50 +00:00
< / div >
< / div >
< h3 id = "parameter" > Parameter< / h3 >
2022-04-02 13:30:16 +00:00
< table >
< thead >
< tr >
2023-07-27 15:06:14 +00:00
< th > Name< / th >
< th > Default< / th >
< th > Notes< / th >
2022-04-02 13:30:16 +00:00
< / tr >
< / thead >
< tbody >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > containerstyle< / strong > < / td >
< td > < code > ul< / code > < / td >
< td > Choose the style used to group all children. It could be any HTML tag name.< / td >
2022-04-02 13:30:16 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > style< / strong > < / td >
< td > < code > li< / code > < / td >
< td > Choose the style used to display each descendant. It could be any HTML tag name.< / td >
2022-04-02 13:30:16 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > showhidden< / strong > < / td >
< td > < code > false< / code > < / td >
< td > When < code > true< / code > , child pages hidden from the menu will be displayed as well.< / td >
2022-04-02 13:30:16 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > description< / strong > < / td >
< td > < code > false< / code > < / td >
2023-10-28 20:28:18 +00:00
< td > When < code > true< / code > shows a short text under each page in the list. When no description or summary exists for the page, the first 70 words of the content is taken - < a href = "https://gohugo.io/content/summaries/" target = "_blank" > read more info about summaries on gohugo.io< / a > .< / td >
2022-04-02 13:30:16 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > depth< / strong > < / td >
< td > < code > 1< / code > < / td >
< td > The depth of descendants to display. For example, if the value is < code > 2< / code > , the shortcode will display two levels of child pages. To get all descendants, set this value to a high number eg. < code > 999< / code > .< / td >
2022-04-02 13:30:16 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > sort< / strong > < / td >
2023-10-12 21:10:25 +00:00
< td > < code > auto< / code > < / td >
2023-11-20 23:54:13 +00:00
< td > The sort criteria of the displayed list.< br > < br > - < code > auto< / code > defaults to < a href = "../cont/pages/index.html#frontmatter-configuration" > < code > ordersectionsby< / code > of the pages frontmatter< / a > < br > or to < a href = "../basics/configuration/index.html" > < code > ordersectionsby< / code > of the site configuration< / a > < br > or to < code > weight< / code > < br > - < code > weight< / code > < br > - < code > title< / code > < br > - < code > linktitle< / code > < br > - < code > modifieddate< / code > < br > - < code > expirydate< / code > < br > - < code > publishdate< / code > < br > - < code > date< / code > < br > - < code > length< / code > < br > - < code > default< / code > adhering to Hugo’ s default sort criteria< / td >
2022-04-02 13:30:16 +00:00
< / tr >
< / tbody >
< / table >
2022-06-05 17:32:37 +00:00
< h2 id = "examples" > Examples< / h2 >
< h3 id = "all-default" > All Default< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > children< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 20:59:23 +00:00
< ul class = "children children-li children-sort-" >
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/test/index.html" > page X< / a > < / li >
< li > < a href = "../shortcodes/children/children-1/index.html" > page 1< / a > < / li >
< li > < a href = "../shortcodes/children/children-2/index.html" > page 2< / a > < / li >
< li > < a href = "../shortcodes/children/children-3/index.html" > page 3< / a > < / li >
2022-04-02 13:30:16 +00:00
< / ul >
2022-06-05 17:32:37 +00:00
< h3 id = "with-description" > With Description< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > children< / span > < span class = "nx" > description< / span > < span class = "p" > =< / span > < span class = "s" > " true" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 20:59:23 +00:00
< ul class = "children children-li children-sort-" >
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/test/index.html" > page X< / a > < p > This is a plain page test, and the beginning of a YAML multiline description...
2022-10-07 18:46:19 +00:00
< / p > < / li >
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/children-1/index.html" > page 1< / a > < p > This is a demo child page< / p > < / li >
< li > < a href = "../shortcodes/children/children-2/index.html" > page 2< / a > < p > This is a demo child page with no description.
2022-10-07 18:46:19 +00:00
So its content is used as description.< / p > < / li >
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/children-3/index.html" > page 3< / a > < p > This is a demo child page< / p > < / li >
2022-04-02 13:30:16 +00:00
< / ul >
2022-10-31 14:06:51 +00:00
< h3 id = "infinite-depth-and-hidden-pages" > Infinite Depth and Hidden Pages< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > children< / span > < span class = "nx" > depth< / span > < span class = "p" > =< / span > < span class = "s" > " 999" < / span > < span class = "nx" > showhidden< / span > < span class = "p" > =< / span > < span class = "s" > " true" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 20:59:23 +00:00
< ul class = "children children-li children-sort-" >
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/test/index.html" > page X< / a > < ul >
< / ul > < / li >
< li > < a href = "../shortcodes/children/children-1/index.html" > page 1< / a > < ul >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/children-1/children-1-1/index.html" > page 1-1< / a > < ul >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/children-1/children-1-1/children-1-1-1/index.html" > page 1-1-1 (hidden)< / a > < ul >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/children-1/children-1-1/children-1-1-1/children-1-1-1-1/index.html" > page 1-1-1-1< / a > < ul >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/children-1/children-1-1/children-1-1-1/children-1-1-1-1/children-1-1-1-1-1/index.html" > page 1-1-1-1-1 (hidden)< / a > < ul >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/children-1/children-1-1/children-1-1-1/children-1-1-1-1/children-1-1-1-1-1/children-1-1-1-1-1-1/index.html" > page 1-1-1-1-1-1< / a > < ul >
< / ul > < / li > < / ul > < / li > < / ul > < / li > < / ul > < / li >
2023-09-23 08:29:35 +00:00
< li > < span > page 1-1-2 (headless)< / span > < ul >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/children-1/children-1-1/children-1-1-2/children-1-1-2-1/index.html" > page 1-1-2-1< / a > < ul >
< / ul > < / li >
< li > < a href = "../shortcodes/children/children-1/children-1-1/children-1-1-2/children-1-1-2-2/index.html" > page 1-1-2-2< / a > < ul >
< / ul > < / li > < / ul > < / li >
< li > < a href = "../shortcodes/children/children-1/children-1-1/children-1-1-3/index.html" > page 1-1-3< / a > < ul >
< / ul > < / li > < / ul > < / li > < / ul > < / li >
< li > < a href = "../shortcodes/children/children-2/index.html" > page 2< / a > < ul >
< / ul > < / li >
< li > < a href = "../shortcodes/children/children-3/index.html" > page 3< / a > < ul >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/children-3/test3/index.html" > page 3-1< / a > < ul >
< / ul > < / li > < / ul > < / li >
< li > < a href = "../shortcodes/children/children-4/index.html" > page 4 (hidden)< / a > < ul >
< / ul > < / li >
2022-04-02 13:30:16 +00:00
< / ul >
2022-06-05 17:32:37 +00:00
< h3 id = "heading-styles-for-container-and-elements" > Heading Styles for Container and Elements< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > children< / span > < span class = "nx" > containerstyle< / span > < span class = "p" > =< / span > < span class = "s" > " div" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " h2" < / span > < span class = "nx" > depth< / span > < span class = "p" > =< / span > < span class = "s" > " 3" < / span > < span class = "nx" > description< / span > < span class = "p" > =< / span > < span class = "s" > " true" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 20:59:23 +00:00
< div class = "children children-h2 children-sort-" >
2022-11-08 14:43:28 +00:00
< h2 > < a href = "../shortcodes/children/test/index.html" > page X< / a > < / h2 > < p > This is a plain page test, and the beginning of a YAML multiline description...
2022-06-23 18:04:40 +00:00
< / p >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< h2 > < a href = "../shortcodes/children/children-1/index.html" > page 1< / a > < / h2 > < p > This is a demo child page< / p >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< h3 > < a href = "../shortcodes/children/children-1/children-1-1/index.html" > page 1-1< / a > < / h3 > < p > This is a demo child page< / p >
2023-06-03 20:59:23 +00:00
2023-09-23 08:29:35 +00:00
< h4 > < span > page 1-1-2 (headless)< / span > < / h4 > < p > This is a demo child page< / p >
2022-11-08 14:43:28 +00:00
< h4 > < a href = "../shortcodes/children/children-1/children-1-1/children-1-1-3/index.html" > page 1-1-3< / a > < / h4 > < p > This is a demo child page< / p >
< h2 > < a href = "../shortcodes/children/children-2/index.html" > page 2< / a > < / h2 > < p > This is a demo child page with no description.
2022-06-23 18:04:40 +00:00
So its content is used as description.< / p >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< h2 > < a href = "../shortcodes/children/children-3/index.html" > page 3< / a > < / h2 > < p > This is a demo child page< / p >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< h3 > < a href = "../shortcodes/children/children-3/test3/index.html" > page 3-1< / a > < / h3 > < p > This is a plain page test nested in a parent< / p >
2023-06-03 20:59:23 +00:00
2022-04-02 13:30:16 +00:00
< / div >
2022-06-05 17:32:37 +00:00
< h3 id = "divs-for-group-and-element-styles" > Divs for Group and Element Styles< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > children< / span > < span class = "nx" > containerstyle< / span > < span class = "p" > =< / span > < span class = "s" > " div" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " div" < / span > < span class = "nx" > depth< / span > < span class = "p" > =< / span > < span class = "s" > " 3" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 20:59:23 +00:00
< div class = "children children-div children-sort-" >
2022-11-08 14:43:28 +00:00
< div > < a href = "../shortcodes/children/test/index.html" > page X< / a > < / div >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< div > < a href = "../shortcodes/children/children-1/index.html" > page 1< / a > < / div >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< div > < a href = "../shortcodes/children/children-1/children-1-1/index.html" > page 1-1< / a > < / div >
2023-06-03 20:59:23 +00:00
2023-09-23 08:29:35 +00:00
< div > < span > page 1-1-2 (headless)< / span > < / div >
2022-11-08 14:43:28 +00:00
< div > < a href = "../shortcodes/children/children-1/children-1-1/children-1-1-3/index.html" > page 1-1-3< / a > < / div >
< div > < a href = "../shortcodes/children/children-2/index.html" > page 2< / a > < / div >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< div > < a href = "../shortcodes/children/children-3/index.html" > page 3< / a > < / div >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< div > < a href = "../shortcodes/children/children-3/test3/index.html" > page 3-1< / a > < / div >
2023-06-03 20:59:23 +00:00
2022-04-02 13:30:16 +00:00
< / div >
< footer class = "footline" >
< / footer >
< / article >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< section >
2022-10-07 18:46:19 +00:00
< h1 class = "a11y-only" > Subsections of Children< / h1 >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
2023-10-03 20:51:03 +00:00
< div class = " taxonomy-tags term-list cstyle tags" title = "Tags" style = "--VARIABLE-TAGS-BG-color: var(--INTERNAL-TAG-BG-color);" >
2023-10-03 11:21:35 +00:00
< ul >
< li > < a class = "term-link" href = "../tags/children/index.html" > Children< / a > < / li >
< / ul >
2023-05-19 18:46:07 +00:00
< / div >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "page-x" > page X< / h1 >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< p > This is a plain demo child page.< / p >
< footer class = "footline" >
< / footer >
< / article >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
2023-10-03 20:51:03 +00:00
< div class = " taxonomy-tags term-list cstyle tags" title = "Tags" style = "--VARIABLE-TAGS-BG-color: var(--INTERNAL-TAG-BG-color);" >
2023-10-03 11:21:35 +00:00
< ul >
< li > < a class = "term-link" href = "../tags/children/index.html" > Children< / a > < / li >
< li > < a class = "term-link" href = "../tags/non-hidden/index.html" > non-hidden< / a > < / li >
< / ul >
2023-05-19 18:46:07 +00:00
< / div >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "page-1" > page 1< / h1 >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< p > This is a demo child page.< / p >
< h2 id = "subpages-of-this-page" > Subpages of this page< / h2 >
2023-06-03 20:59:23 +00:00
2022-04-02 13:30:16 +00:00
< ul class = "children children-li children-sort-" >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/children-1/children-1-1/index.html" > page 1-1< / a > < / li >
2022-04-02 13:30:16 +00:00
< / ul >
< footer class = "footline" >
< / footer >
< / article >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< section >
2022-10-07 18:46:19 +00:00
< h1 class = "a11y-only" > Subsections of page 1< / h1 >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
2023-10-03 20:51:03 +00:00
< div class = " taxonomy-tags term-list cstyle tags" title = "Tags" style = "--VARIABLE-TAGS-BG-color: var(--INTERNAL-TAG-BG-color);" >
2023-10-03 11:21:35 +00:00
< ul >
< li > < a class = "term-link" href = "../tags/children/index.html" > Children< / a > < / li >
< li > < a class = "term-link" href = "../tags/non-hidden/index.html" > non-hidden< / a > < / li >
< / ul >
2023-05-19 18:46:07 +00:00
< / div >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "page-1-1" > page 1-1< / h1 >
2022-07-05 22:16:52 +00:00
2023-10-28 20:28:18 +00:00
< p > This is a demo child page with a hidden child. You can still access the hidden child < a href = "../shortcodes/children/children-1/children-1-1/children-1-1-1/index.html" > directly< / a > or via the search.< / p >
2022-04-02 13:30:16 +00:00
< h2 id = "subpages-of-this-page" > Subpages of this page< / h2 >
2023-06-03 20:59:23 +00:00
2022-04-02 13:30:16 +00:00
< ul class = "children children-li children-sort-" >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/children-1/children-1-1/children-1-1-1/index.html" > page 1-1-1 (hidden)< / a > < / li >
2023-09-23 08:29:35 +00:00
< li > < span > page 1-1-2 (headless)< / span > < / li >
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/children-1/children-1-1/children-1-1-3/index.html" > page 1-1-3< / a > < / li >
2022-04-02 13:30:16 +00:00
< / ul >
< footer class = "footline" >
< / footer >
< / article >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< section >
2022-10-07 18:46:19 +00:00
< h1 class = "a11y-only" > Subsections of page 1-1< / h1 >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
2023-10-03 20:51:03 +00:00
< div class = " taxonomy-tags term-list cstyle tags" title = "Tags" style = "--VARIABLE-TAGS-BG-color: var(--INTERNAL-TAG-BG-color);" >
2023-10-03 11:21:35 +00:00
< ul >
< li > < a class = "term-link" href = "../tags/children/index.html" > Children< / a > < / li >
< li > < a class = "term-link" href = "../tags/headless/index.html" > headless< / a > < / li >
< li > < a class = "term-link" href = "../tags/non-hidden/index.html" > non-hidden< / a > < / li >
< / ul >
2023-05-19 18:46:07 +00:00
< / div >
< / header >
2023-09-23 08:29:35 +00:00
< h1 id = "page-1-1-2-headless" > page 1-1-2 (headless)< / h1 >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< footer class = "footline" >
< / footer >
< / article >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< section >
2023-09-23 08:29:35 +00:00
< h1 class = "a11y-only" > Subsections of page 1-1-2 (headless)< / h1 >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
2023-10-03 20:51:03 +00:00
< div class = " taxonomy-tags term-list cstyle tags" title = "Tags" style = "--VARIABLE-TAGS-BG-color: var(--INTERNAL-TAG-BG-color);" >
2023-10-03 11:21:35 +00:00
< ul >
< li > < a class = "term-link" href = "../tags/children/index.html" > Children< / a > < / li >
< li > < a class = "term-link" href = "../tags/non-hidden/index.html" > non-hidden< / a > < / li >
< / ul >
2023-05-19 18:46:07 +00:00
< / div >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "page-1-1-2-1" > page 1-1-2-1< / h1 >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< p > This is a plain demo child page.< / p >
< footer class = "footline" >
< / footer >
< / article >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
2023-10-03 20:51:03 +00:00
< div class = " taxonomy-tags term-list cstyle tags" title = "Tags" style = "--VARIABLE-TAGS-BG-color: var(--INTERNAL-TAG-BG-color);" >
2023-10-03 11:21:35 +00:00
< ul >
< li > < a class = "term-link" href = "../tags/children/index.html" > Children< / a > < / li >
< li > < a class = "term-link" href = "../tags/non-hidden/index.html" > non-hidden< / a > < / li >
< / ul >
2023-05-19 18:46:07 +00:00
< / div >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "page-1-1-2-2" > page 1-1-2-2< / h1 >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< p > This is a plain demo child page.< / p >
< footer class = "footline" >
< / footer >
< / article >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< / section >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
2023-10-03 20:51:03 +00:00
< div class = " taxonomy-tags term-list cstyle tags" title = "Tags" style = "--VARIABLE-TAGS-BG-color: var(--INTERNAL-TAG-BG-color);" >
2023-10-03 11:21:35 +00:00
< ul >
< li > < a class = "term-link" href = "../tags/children/index.html" > Children< / a > < / li >
< li > < a class = "term-link" href = "../tags/non-hidden/index.html" > non-hidden< / a > < / li >
< / ul >
2023-05-19 18:46:07 +00:00
< / div >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "page-1-1-3" > page 1-1-3< / h1 >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< p > This is a plain demo child page.< / p >
< footer class = "footline" >
< / footer >
< / article >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< / section >
< / section >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
2023-10-03 20:51:03 +00:00
< div class = " taxonomy-tags term-list cstyle tags" title = "Tags" style = "--VARIABLE-TAGS-BG-color: var(--INTERNAL-TAG-BG-color);" >
2023-10-03 11:21:35 +00:00
< ul >
< li > < a class = "term-link" href = "../tags/children/index.html" > Children< / a > < / li >
< li > < a class = "term-link" href = "../tags/non-hidden/index.html" > non-hidden< / a > < / li >
< / ul >
2023-05-19 18:46:07 +00:00
< / div >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "page-2" > page 2< / h1 >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< p > This is a demo child page with no description.< / p >
< p > So its content is used as description.< / p >
< footer class = "footline" >
< / footer >
< / article >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
2023-10-03 20:51:03 +00:00
< div class = " taxonomy-tags term-list cstyle tags" title = "Tags" style = "--VARIABLE-TAGS-BG-color: var(--INTERNAL-TAG-BG-color);" >
2023-10-03 11:21:35 +00:00
< ul >
< li > < a class = "term-link" href = "../tags/children/index.html" > Children< / a > < / li >
< li > < a class = "term-link" href = "../tags/non-hidden/index.html" > non-hidden< / a > < / li >
< / ul >
2023-05-19 18:46:07 +00:00
< / div >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "page-3" > page 3< / h1 >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< p > This is a demo child page.< / p >
< h2 id = "subpages-of-this-page" > Subpages of this page< / h2 >
2023-06-03 20:59:23 +00:00
2022-04-02 13:30:16 +00:00
< ul class = "children children-li children-sort-" >
2023-06-03 20:59:23 +00:00
2022-11-08 14:43:28 +00:00
< li > < a href = "../shortcodes/children/children-3/test3/index.html" > page 3-1< / a > < / li >
2022-04-02 13:30:16 +00:00
< / ul >
< footer class = "footline" >
< / footer >
< / article >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< section >
2022-10-07 18:46:19 +00:00
< h1 class = "a11y-only" > Subsections of page 3< / h1 >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
2023-10-03 20:51:03 +00:00
< div class = " taxonomy-tags term-list cstyle tags" title = "Tags" style = "--VARIABLE-TAGS-BG-color: var(--INTERNAL-TAG-BG-color);" >
2023-10-03 11:21:35 +00:00
< ul >
< li > < a class = "term-link" href = "../tags/children/index.html" > Children< / a > < / li >
< li > < a class = "term-link" href = "../tags/non-hidden/index.html" > non-hidden< / a > < / li >
< / ul >
2023-05-19 18:46:07 +00:00
< / div >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "page-3-1" > page 3-1< / h1 >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< p > This is a plain demo child page.< / p >
< footer class = "footline" >
< / footer >
< / article >
2022-07-05 22:16:52 +00:00
2022-04-02 13:30:16 +00:00
< / section >
< / section >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "expand" > Expand< / h1 >
2022-07-05 22:16:52 +00:00
2022-06-05 17:32:37 +00:00
< p > The < code > expand< / code > shortcode displays an expandable/collapsible section of text.< / p >
2023-06-03 22:20:43 +00:00
2022-04-02 13:30:16 +00:00
< div class = "expand" >
2023-12-03 14:23:32 +00:00
< input type = "checkbox" id = "R-expand-29dbb5774223a283d94314cc689ad96c" aria-controls = "R-expandcontent-29dbb5774223a283d94314cc689ad96c" >
< label class = "expand-label" for = "R-expand-29dbb5774223a283d94314cc689ad96c" >
2022-04-02 13:30:16 +00:00
< i class = "fas fa-chevron-down" > < / i >
2023-02-09 00:02:54 +00:00
< i class = "fas fa-chevron-right" > < / i >
2023-03-14 20:49:22 +00:00
Expand me…
2023-02-03 07:58:48 +00:00
< / label >
2023-12-03 14:23:32 +00:00
< div id = "R-expandcontent-29dbb5774223a283d94314cc689ad96c" class = "expand-content" >
2023-06-04 22:25:27 +00:00
2023-06-03 22:20:43 +00:00
< p > Thank you!< / p >
2023-05-31 21:45:45 +00:00
< p > That’ s some text with a footnote< sup id = "fnref:1" > < a href = "#fn:1" class = "footnote-ref" role = "doc-noteref" > 1< / a > < / sup > < / p >
< p > That’ s some more text with a footnote.< sup id = "fnref:2" > < a href = "#fn:2" class = "footnote-ref" role = "doc-noteref" > 2< / a > < / sup > < / p >
2023-06-03 22:20:43 +00:00
< div class = "footnotes" role = "doc-endnotes" >
< hr >
< ol >
< li id = "fn:1" >
< p > And that’ s the footnote.  < a href = "#fnref:1" class = "footnote-backref" role = "doc-backlink" > ↩ ︎ < / a > < / p >
< / li >
< li id = "fn:2" >
< p > Anything of interest goes here.< / p >
< p > Blue light glows blue.  < a href = "#fnref:2" class = "footnote-backref" role = "doc-backlink" > ↩ ︎ < / a > < / p >
< / li >
< / ol >
2022-06-05 17:32:37 +00:00
< / div >
2023-06-03 09:12:46 +00:00
< / div >
2023-06-03 22:20:43 +00:00
< / div >
2023-02-03 07:58:48 +00:00
< div class = "box notices cstyle note" >
< div class = "box-label" > < i class = "fa-fw fas fa-exclamation-circle" > < / i > Note< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2023-02-04 15:02:34 +00:00
< p > This only works in modern browsers flawlessly. While Internet Explorer 11 has issues in displaying it, the functionality still works.< / p >
2023-06-03 09:12:46 +00:00
< / div >
2023-02-03 07:58:48 +00:00
< / div >
2022-06-05 17:32:37 +00:00
< h2 id = "usage" > Usage< / h2 >
2022-10-31 14:06:51 +00:00
< p > While the examples are using shortcodes with named parameter you are free to use positional as well or also call this shortcode from your own partials.< / p >
2022-04-02 13:30:16 +00:00
2023-07-27 15:06:14 +00:00
< div class = "tab-panel" data-tab-group = "shortcode-parameter" >
2022-06-05 17:32:37 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-06-05 17:32:37 +00:00
< button
2022-06-22 22:08:50 +00:00
data-tab-item="shortcode"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','shortcode')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-22 22:08:50 +00:00
< button
2023-09-05 11:10:04 +00:00
data-tab-item="shortcode-positional"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-09-05 11:10:04 +00:00
onclick="switchTab('shortcode-parameter','shortcode-positional')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode (positional)< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-05 17:32:37 +00:00
< button
2022-06-22 22:08:50 +00:00
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','partial')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > partial< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-05 17:32:37 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="shortcode"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > expand< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Expand me..." < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Thank< / span > < span class = "nx" > you< / span > < span class = "p" > !{{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > expand< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
2023-09-05 11:10:04 +00:00
data-tab-item="shortcode-positional"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > expand< / span > < span class = "s" > " Expand me..." < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Thank< / span > < span class = "nx" > you< / span > < span class = "p" > !{{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > expand< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/expand.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2022-06-22 22:08:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " title" < / span > < span class = "s" > " Expand me..." < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "s" > " Thank you!" < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-06-05 17:32:37 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< / div >
2022-06-05 17:32:37 +00:00
< h3 id = "parameter" > Parameter< / h3 >
< table >
< thead >
< tr >
2023-07-27 15:06:14 +00:00
< th > Name< / th >
< th > Position< / th >
< th > Default< / th >
< th > Notes< / th >
2022-06-05 17:32:37 +00:00
< / tr >
< / thead >
< tbody >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > title< / strong > < / td >
< td > 1< / td >
< td > < code > " Expand me..." < / code > < / td >
< td > Arbitrary text to appear next to the expand/collapse icon.< / td >
2022-06-05 17:32:37 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > open< / strong > < / td >
< td > 2< / td >
< td > < code > false< / code > < / td >
< td > When < code > true< / code > the content text will be initially shown as expanded.< / td >
2022-06-05 17:32:37 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < em > < strong > < content> < / strong > < / em > < / td >
< td > < / td >
< td > < em > < empty> < / em > < / td >
< td > Arbitrary text to be displayed on expand.< / td >
2022-06-05 17:32:37 +00:00
< / tr >
< / tbody >
< / table >
< h2 id = "examples" > Examples< / h2 >
< h3 id = "all-defaults" > All Defaults< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > expand< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > Yes< / span > < span class = "p" > ,< / span > < span class = "nx" > you< / span > < span class = "nx" > did< / span > < span class = "nx" > it< / span > < span class = "p" > !{{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > expand< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "expand" >
2023-12-03 14:23:32 +00:00
< input type = "checkbox" id = "R-expand-911617c9a215b5f318ec27f60388f57d" aria-controls = "R-expandcontent-911617c9a215b5f318ec27f60388f57d" >
< label class = "expand-label" for = "R-expand-911617c9a215b5f318ec27f60388f57d" >
2022-04-02 13:30:16 +00:00
< i class = "fas fa-chevron-down" > < / i >
2023-02-09 00:02:54 +00:00
< i class = "fas fa-chevron-right" > < / i >
2023-03-14 20:49:22 +00:00
Expand me…
2023-02-03 07:58:48 +00:00
< / label >
2023-12-03 14:23:32 +00:00
< div id = "R-expandcontent-911617c9a215b5f318ec27f60388f57d" class = "expand-content" >
2023-06-04 22:25:27 +00:00
< p >
2023-06-03 09:12:46 +00:00
Yes, you did it!< / div >
2022-04-02 13:30:16 +00:00
< / div >
2022-06-05 17:32:37 +00:00
< h3 id = "initially-expanded" > Initially Expanded< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > expand< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Expand me..." < / span > < span class = "nx" > open< / span > < span class = "p" > =< / span > < span class = "s" > " true" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > No< / span > < span class = "nx" > need< / span > < span class = "nx" > to< / span > < span class = "nx" > press< / span > < span class = "nx" > you< / span > < span class = "p" > !{{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > expand< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "expand" >
2023-12-03 14:23:32 +00:00
< input type = "checkbox" id = "R-expand-a04facb6adf8f38af107df8202c5732f" aria-controls = "R-expandcontent-a04facb6adf8f38af107df8202c5732f" checked >
< label class = "expand-label" for = "R-expand-a04facb6adf8f38af107df8202c5732f" >
2022-04-02 13:30:16 +00:00
< i class = "fas fa-chevron-down" > < / i >
2023-02-09 00:02:54 +00:00
< i class = "fas fa-chevron-right" > < / i >
2023-03-14 20:49:22 +00:00
Expand me…
2023-02-03 07:58:48 +00:00
< / label >
2023-12-03 14:23:32 +00:00
< div id = "R-expandcontent-a04facb6adf8f38af107df8202c5732f" class = "expand-content" >
2023-06-04 22:25:27 +00:00
< p >
2023-06-03 09:12:46 +00:00
No need to press you!< / div >
2022-04-02 13:30:16 +00:00
< / div >
2022-06-05 17:32:37 +00:00
< h3 id = "arbitrary-text" > Arbitrary Text< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > expand< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Show me almost **endless** possibilities" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-06-05 17:32:37 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > You< / span > < span class = "nx" > can< / span > < span class = "nx" > add< / span > < span class = "nx" > standard< / span > < span class = "nx" > markdown< / span > < span class = "nx" > syntax< / span > < span class = "p" > :< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "o" > -< / span > < span class = "nx" > multiple< / span > < span class = "nx" > paragraphs< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "o" > -< / span > < span class = "nx" > bullet< / span > < span class = "nx" > point< / span > < span class = "nx" > lists< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "o" > -< / span > < span class = "nx" > _emphasized_< / span > < span class = "p" > ,< / span > < span class = "o" > **< / span > < span class = "nx" > bold< / span > < span class = "o" > **< / span > < span class = "nx" > and< / span > < span class = "nx" > even< / span > < span class = "o" > **< / span > < span class = "nx" > _bold< / span > < span class = "nx" > emphasized_< / span > < span class = "o" > **< / span > < span class = "nx" > text< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "o" > -< / span > < span class = "p" > [< / span > < span class = "nx" > links< / span > < span class = "p" > ](< / span > < span class = "nx" > https< / span > < span class = "p" > :< / span > < span class = "c1" > //example.com)
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "c1" > < / span > < span class = "o" > -< / span > < span class = "nx" > etc< / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```plaintext
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ...and even source code
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
2022-10-31 14:06:51 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > > < / span > < span class = "nx" > the< / span > < span class = "nx" > possibilities< / span > < span class = "nx" > are< / span > < span class = "nf" > endless< / span > < span class = "p" > (< / span > < span class = "nx" > almost< / span > < span class = "o" > -< / span > < span class = "nx" > including< / span > < span class = "nx" > other< / span > < span class = "nx" > shortcodes< / span > < span class = "nx" > may< / span > < span class = "nx" > or< / span > < span class = "nx" > may< / span > < span class = "nx" > not< / span > < span class = "nx" > work< / span > < span class = "p" > )< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > expand< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "expand" >
2023-12-03 14:23:32 +00:00
< input type = "checkbox" id = "R-expand-0ff9938607a94de000d43c38799b2a5d" aria-controls = "R-expandcontent-0ff9938607a94de000d43c38799b2a5d" >
< label class = "expand-label" for = "R-expand-0ff9938607a94de000d43c38799b2a5d" >
2022-04-02 13:30:16 +00:00
< i class = "fas fa-chevron-down" > < / i >
2023-02-09 00:02:54 +00:00
< i class = "fas fa-chevron-right" > < / i >
2023-03-14 20:49:22 +00:00
Show me almost < strong > endless< / strong > possibilities
2023-02-03 07:58:48 +00:00
< / label >
2023-12-03 14:23:32 +00:00
< div id = "R-expandcontent-0ff9938607a94de000d43c38799b2a5d" class = "expand-content" >
2023-06-04 22:25:27 +00:00
2022-05-23 13:00:05 +00:00
< p > You can add standard markdown syntax:< / p >
2022-04-02 13:30:16 +00:00
< ul >
< li > multiple paragraphs< / li >
< li > bullet point lists< / li >
< li > < em > emphasized< / em > , < strong > bold< / strong > and even < strong > < em > bold emphasized< / em > < / strong > text< / li >
2023-10-28 20:28:18 +00:00
< li > < a href = "https://example.com" target = "_blank" > links< / a > < / li >
2022-04-02 13:30:16 +00:00
< li > etc.< / li >
< / ul >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-plaintext" data-lang = "plaintext" > < span class = "line" > < span class = "cl" > ...and even source code< / span > < / span > < / code > < / pre > < / div > < blockquote >
2022-10-31 14:06:51 +00:00
< p > the possibilities are endless (almost - including other shortcodes may or may not work)< / p >
2022-04-02 13:30:16 +00:00
< / blockquote >
2023-06-03 09:12:46 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< / div >
< footer class = "footline" >
< / footer >
< / article >
2023-06-21 23:23:13 +00:00
< article class = "default" >
< header class = "headline" >
< / header >
< h1 id = "highlight" > Highlight< / h1 >
< p > The < code > highlight< / code > shortcode renders your code with a syntax highlighter.< / p >
2023-08-12 22:59:45 +00:00
2023-12-03 14:23:32 +00:00
< div class = "tab-panel" data-tab-group = "e510584997fa902c63f9562832e8b57f" >
2023-08-12 22:59:45 +00:00
< div class = "tab-nav" >
< div class = "tab-nav-title" > ​ < / div >
< button
data-tab-item="python"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-12-03 14:23:32 +00:00
onclick="switchTab('e510584997fa902c63f9562832e8b57f','python')"
2023-08-12 22:59:45 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > python< / span >
2023-08-12 22:59:45 +00:00
< / button >
< / div >
< div class = "tab-content-container" >
< div
data-tab-item="python"
class="tab-content tab-panel-style cstyle initial active">
< div class = "tab-content-text" >
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-py" data-lang = "py" > < span class = "line" > < span class = "ln" > 1< / span > < span class = "cl" > < span class = "nb" > print< / span > < span class = "p" > (< / span > < span class = "s2" > " Hello World!" < / span > < span class = "p" > )< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
< / div >
< / div >
< / div >
2023-06-21 23:23:13 +00:00
< h2 id = "usage" > Usage< / h2 >
2023-10-28 20:28:18 +00:00
< p > This shortcode is fully compatible with Hugo’ s < a href = "https://gohugo.io/content-management/syntax-highlighting/#highlight-shortcode" target = "_blank" > < code > highlight< / code > shortcode< / a > but < strong > offers some extensions< / strong > .< / p >
2023-08-12 22:59:45 +00:00
< p > It is called interchangeably in the same way as Hugo’ s own shortcode providing positional parameter or by simply using codefences.< / p >
2023-10-28 20:28:18 +00:00
< p > You are free to also call this shortcode from your own partials. In this case it resembles Hugo’ s < a href = "https://gohugo.io/functions/highlight/" target = "_blank" > < code > highlight< / code > function< / a > syntax if you call this shortcode as a partial using compatiblity syntax.< / p >
2023-06-21 23:23:13 +00:00
< p > While the examples are using shortcodes with named parameter it is recommended to use codefences instead. This is because more and more other software supports codefences (eg. GitHub) and so your markdown becomes more portable.< / p >
2023-07-27 15:06:14 +00:00
< div class = "tab-panel" data-tab-group = "shortcode-parameter" >
2023-06-21 23:23:13 +00:00
< div class = "tab-nav" >
< div class = "tab-nav-title" > ​ < / div >
< button
data-tab-item="codefence"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','codefence')"
2023-06-21 23:23:13 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > codefence< / span >
2023-06-21 23:23:13 +00:00
< / button >
< button
data-tab-item="shortcode"
class="tab-nav-button tab-panel-style cstyle initial"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','shortcode')"
2023-06-21 23:23:13 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode< / span >
2023-06-21 23:23:13 +00:00
< / button >
< button
2023-09-05 11:10:04 +00:00
data-tab-item="shortcode-positional"
2023-06-21 23:23:13 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-09-05 11:10:04 +00:00
onclick="switchTab('shortcode-parameter','shortcode-positional')"
2023-06-21 23:23:13 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode (positional)< / span >
2023-06-21 23:23:13 +00:00
< / button >
< button
data-tab-item="partial"
class="tab-nav-button tab-panel-style cstyle initial"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','partial')"
2023-06-21 23:23:13 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > partial< / span >
2023-06-21 23:23:13 +00:00
< / button >
< button
2023-09-05 11:10:04 +00:00
data-tab-item="partial-compat"
2023-06-21 23:23:13 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-09-05 11:10:04 +00:00
onclick="switchTab('shortcode-parameter','partial-compat')"
2023-06-21 23:23:13 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > partial (compat)< / span >
2023-06-21 23:23:13 +00:00
< / button >
< / div >
< div class = "tab-content-container" >
< div
data-tab-item="codefence"
class="tab-content tab-panel-style cstyle initial active">
< div class = "tab-content-text" >
2023-08-12 22:59:45 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-md" data-lang = "md" > < span class = "line" > < span class = "cl" > ```py { lineNos=" true" wrap=" true" title=" python" }
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > print(" Hello World!" )
< / span > < / span > < span class = "line" > < span class = "cl" > ```< / span > < / span > < / code > < / pre > < / div > < / div >
< / div >
< div
data-tab-item="shortcode"
class="tab-content tab-panel-style cstyle initial">
< div class = "tab-content-text" >
2023-08-12 22:59:45 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > highlight< / span > < span class = "nx" > lineNos< / span > < span class = "p" > =< / span > < span class = "s" > " true" < / span > < span class = "kd" > type< / span > < span class = "p" > =< / span > < span class = "s" > " py" < / span > < span class = "nx" > wrap< / span > < span class = "p" > =< / span > < span class = "s" > " true" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " python" < / span > < span class = "p" > > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nb" > print< / span > < span class = "p" > (< / span > < span class = "s" > " Hello World!" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > highlight< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
< / div >
< div
2023-09-05 11:10:04 +00:00
data-tab-item="shortcode-positional"
2023-06-21 23:23:13 +00:00
class="tab-content tab-panel-style cstyle initial">
< div class = "tab-content-text" >
2023-08-12 22:59:45 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > highlight< / span > < span class = "nx" > py< / span > < span class = "s" > " lineNos=true,wrap=true,title=python" < / span > < span class = "p" > > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nb" > print< / span > < span class = "p" > (< / span > < span class = "s" > " Hello World!" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > highlight< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
< / div >
< div
data-tab-item="partial"
class="tab-content tab-panel-style cstyle initial">
< div class = "tab-content-text" >
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/highlight.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "s" > " print(\" Hello World!\" )" < / span >
2023-06-22 15:37:43 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " lineNos" < / span > < span class = "s" > " true" < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " type" < / span > < span class = "s" > " py" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " wrap" < / span > < span class = "s" > " true" < / span >
2023-08-12 22:59:45 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " title" < / span > < span class = "s" > " python" < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
< / div >
< div
2023-09-05 11:10:04 +00:00
data-tab-item="partial-compat"
2023-06-21 23:23:13 +00:00
class="tab-content tab-panel-style cstyle initial">
< div class = "tab-content-text" >
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/highlight.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "s" > " print(\" Hello World!\" )" < / span >
2023-08-12 22:59:45 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " options" < / span > < span class = "s" > " lineNos=true,wrap=true,title=python" < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " type" < / span > < span class = "s" > " py" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
< / div >
< / div >
< / div >
< h3 id = "parameter" > Parameter< / h3 >
< table >
< thead >
< tr >
2023-07-27 15:06:14 +00:00
< th > Name< / th >
2023-10-18 21:23:49 +00:00
< th > Position< / th >
2023-07-27 15:06:14 +00:00
< th > Default< / th >
< th > Notes< / th >
2023-06-21 23:23:13 +00:00
< / tr >
< / thead >
< tbody >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > type< / strong > < / td >
2023-10-18 21:23:49 +00:00
< td > 1< / td >
2023-07-27 15:06:14 +00:00
< td > < em > < empty> < / em > < / td >
2023-10-28 20:28:18 +00:00
< td > The language of the code to highlight. Choose from one of the < a href = "https://gohugo.io/content-management/syntax-highlighting/#list-of-chroma-highlighting-languages" target = "_blank" > supported languages< / a > . Case-insensitive.< / td >
2023-06-21 23:23:13 +00:00
< / tr >
< tr >
2023-08-12 22:59:45 +00:00
< td > < strong > title< / strong > < / td >
2023-10-18 21:23:49 +00:00
< td > < / td >
2023-08-12 22:59:45 +00:00
< td > < em > < empty> < / em > < / td >
2023-10-28 20:28:18 +00:00
< td > < strong > Extension< / strong > . Arbitrary title for code. This displays the code like a < a href = "../shortcodes/tab/index.html" > single tab< / a > if < code > hl_inline=false< / code > (which is Hugos default).< / td >
2023-08-12 22:59:45 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > wrap< / strong > < / td >
2023-10-18 21:23:49 +00:00
< td > < / td >
2023-07-27 15:06:14 +00:00
< td > see notes< / td >
2023-11-29 23:15:02 +00:00
< td > < strong > Extension< / strong > . When < code > true< / code > the content may wrap on long lines otherwise it will be scrollable.< br > < br > The default value can be set in your < code > hugo.toml< / code > and overwritten via frontmatter. < a href = "#configuration" > See below< / a > .< / td >
2023-06-21 23:23:13 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > options< / strong > < / td >
2023-10-18 21:23:49 +00:00
< td > 2< / td >
2023-07-27 15:06:14 +00:00
< td > < em > < empty> < / em > < / td >
2023-10-28 20:28:18 +00:00
< td > An optional, comma-separated list of zero or more < a href = "https://gohugo.io/functions/highlight/#options" target = "_blank" > Hugo supported options< / a > as well as extension parameter from this table.< / td >
2023-06-21 23:23:13 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < em > < strong > < option> < / strong > < / em > < / td >
2023-10-18 21:23:49 +00:00
< td > < / td >
2023-07-27 15:06:14 +00:00
< td > < em > < empty> < / em > < / td >
2023-10-28 20:28:18 +00:00
< td > Any of < a href = "https://gohugo.io/functions/highlight/#options" target = "_blank" > Hugo’ s supported options< / a > .< / td >
2023-06-21 23:23:13 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < em > < strong > < content> < / strong > < / em > < / td >
2023-10-18 21:23:49 +00:00
< td > < / td >
2023-07-27 15:06:14 +00:00
< td > < em > < empty> < / em > < / td >
< td > Your code to highlight.< / td >
2023-06-21 23:23:13 +00:00
< / tr >
< / tbody >
< / table >
< h2 id = "configuration" > Configuration< / h2 >
2023-11-29 23:15:02 +00:00
< p > Default values for < a href = "https://gohugo.io/functions/highlight/#options" target = "_blank" > Hugo’ s supported options< / a > can be set via < a href = "https://gohugo.io/getting-started/configuration-markup/#highlight" target = "_blank" > goldmark settings< / a > in your < code > hugo.toml< / code > < / p >
< p > Default values for extension options can be set via params settings in your < code > hugo.toml< / code > or be overwritten by frontmatter for each individual page.< / p >
2023-06-21 23:23:13 +00:00
< h3 id = "global-configuration-file" > Global Configuration File< / h3 >
2023-11-25 13:41:42 +00:00
< p > You can configure the color style used for code blocks in your < a href = "../basics/branding/index.html#syntax-highlightning" > color variants stylesheet< / a > file.< / p >
2023-06-21 23:23:13 +00:00
< h4 id = "recommended-settings" > Recommended Settings< / h4 >
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-toml" data-lang = "toml" > < span class = "line" > < span class = "cl" > < span class = "p" > [< / span > < span class = "nx" > markup< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > [< / span > < span class = "nx" > markup< / span > < span class = "p" > .< / span > < span class = "nx" > highlight< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "c" > # line numbers in a table layout will shift if code is wrapping, so better< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "c" > # use inline; besides that visually both layouts have the same look and behavior< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > lineNumbersInTable< / span > < span class = "p" > =< / span > < span class = "kc" > false< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "c" > # the shipped variants come with their own modified chroma syntax highlightning< / span >
2023-11-25 13:41:42 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "c" > # stylesheets which are linked in your generated HTML pages; you can use Hugo to generate< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "c" > # own stylesheets to your liking and use them in your variant;< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "c" > # if you want to use Hugo' s internal styles instead of the shipped stylesheets:< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "c" > # - remove `noClasses` or set `noClasses = true`< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "c" > # - set `style` to a predefined style name< / span >
2023-11-25 13:41:42 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "c" > # note: with using the internal styles, the `--CODE-theme` setting in your variant< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "c" > # stylesheet will be ignored and the internal style is used for all variants and< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "c" > # even print< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > noClasses< / span > < span class = "p" > =< / span > < span class = "kc" > false< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "c" > # style = " tango" < / span > < / span > < / span > < / code > < / pre > < / div > < h4 id = "optional-settings" > Optional Settings< / h4 >
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-toml" data-lang = "toml" > < span class = "line" > < span class = "cl" > < span class = "p" > [< / span > < span class = "nx" > params< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > highlightWrap< / span > < span class = "p" > =< / span > < span class = "kc" > true< / span > < / span > < / span > < / code > < / pre > < / div > < h3 id = "pages-frontmatter" > Page’ s Frontmatter< / h3 >
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-toml" data-lang = "toml" > < span class = "line" > < span class = "cl" > < span class = "err" > +++< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > highlightWrap< / span > < span class = "p" > =< / span > < span class = "kc" > true< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "err" > +++< / span > < / span > < / span > < / code > < / pre > < / div > < h2 id = "examples" > Examples< / h2 >
2023-08-12 22:59:45 +00:00
< h3 id = "line-numbers-with-starting-offset" > Line Numbers with Starting Offset< / h3 >
2023-11-29 23:15:02 +00:00
< p > As mentioned above, line numbers in a < code > table< / code > layout will shift if code is wrapping, so better use < code > inline< / code > . To make things easier for you, set < code > lineNumbersInTable = false< / code > in your < code > hugo.toml< / code > and add < code > lineNos = true< / code > when calling the shortcode instead of the specific values < code > table< / code > or < code > inline< / code > .< / p >
2023-08-12 22:59:45 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > highlight< / span > < span class = "nx" > lineNos< / span > < span class = "p" > =< / span > < span class = "s" > " true" < / span > < span class = "nx" > lineNoStart< / span > < span class = "p" > =< / span > < span class = "s" > " 666" < / span > < span class = "kd" > type< / span > < span class = "p" > =< / span > < span class = "s" > " py" < / span > < span class = "p" > > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "err" > #< / span > < span class = "nx" > the< / span > < span class = "nx" > hardest< / span > < span class = "nx" > part< / span > < span class = "nx" > is< / span > < span class = "nx" > to< / span > < span class = "nx" > start< / span > < span class = "nx" > writing< / span > < span class = "nx" > code< / span > < span class = "p" > ;< / span > < span class = "nx" > here< / span > < span class = "err" > ' < / span > < span class = "nx" > s< / span > < span class = "nx" > a< / span > < span class = "nx" > kickstart< / span > < span class = "p" > ;< / span > < span class = "nx" > just< / span > < span class = "nx" > copy< / span > < span class = "nx" > and< / span > < span class = "nx" > paste< / span > < span class = "nx" > this< / span > < span class = "p" > ;< / span > < span class = "nx" > it< / span > < span class = "err" > ' < / span > < span class = "nx" > s< / span > < span class = "nx" > free< / span > < span class = "p" > ;< / span > < span class = "nx" > the< / span > < span class = "nx" > next< / span > < span class = "nx" > lines< / span > < span class = "nx" > will< / span > < span class = "nx" > cost< / span > < span class = "nx" > you< / span > < span class = "nx" > serious< / span > < span class = "nx" > credits< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nb" > print< / span > < span class = "p" > (< / span > < span class = "s" > " Hello" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nb" > print< / span > < span class = "p" > (< / span > < span class = "s" > " " < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nb" > print< / span > < span class = "p" > (< / span > < span class = "s" > " World" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nb" > print< / span > < span class = "p" > (< / span > < span class = "s" > " !" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > highlight< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div > < div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-py" data-lang = "py" > < span class = "line" > < span class = "ln" > 666< / span > < span class = "cl" > < span class = "c1" > # the hardest part is to start writing code; here' s a kickstart; just copy and paste this; it' s free; the next lines will cost you serious credits< / span >
< / span > < / span > < span class = "line" > < span class = "ln" > 667< / span > < span class = "cl" > < span class = "nb" > print< / span > < span class = "p" > (< / span > < span class = "s2" > " Hello" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "ln" > 668< / span > < span class = "cl" > < span class = "nb" > print< / span > < span class = "p" > (< / span > < span class = "s2" > " " < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "ln" > 669< / span > < span class = "cl" > < span class = "nb" > print< / span > < span class = "p" > (< / span > < span class = "s2" > " World" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "ln" > 670< / span > < span class = "cl" > < span class = "nb" > print< / span > < span class = "p" > (< / span > < span class = "s2" > " !" < / span > < span class = "p" > )< / span > < / span > < / span > < / code > < / pre > < / div >
< h3 id = "codefence-with-title" > Codefence with Title< / h3 >
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-markdown" data-lang = "markdown" > < span class = "line" > < span class = "cl" > ```py { title=" python" }
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "gh" > # a bit shorter
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "gh" > < / span > print(" Hello World!" )
< / span > < / span > < span class = "line" > < span class = "cl" > ```< / span > < / span > < / code > < / pre > < / div >
2023-12-03 14:23:32 +00:00
< div class = "tab-panel" data-tab-group = "c2bbae6c61fdd8c093e745283ad0691a" >
2023-08-12 22:59:45 +00:00
< div class = "tab-nav" >
< div class = "tab-nav-title" > ​ < / div >
< button
data-tab-item="python"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-12-03 14:23:32 +00:00
onclick="switchTab('c2bbae6c61fdd8c093e745283ad0691a','python')"
2023-08-12 22:59:45 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > python< / span >
2023-08-12 22:59:45 +00:00
< / button >
< / div >
< div class = "tab-content-container" >
< div
data-tab-item="python"
class="tab-content tab-panel-style cstyle initial active">
< div class = "tab-content-text" >
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-py" data-lang = "py" > < span class = "line" > < span class = "cl" > < span class = "c1" > # a bit shorter< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nb" > print< / span > < span class = "p" > (< / span > < span class = "s2" > " Hello World!" < / span > < span class = "p" > )< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
< / div >
< / div >
< / div > < h3 id = "with-wrap" > With Wrap< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > highlight< / span > < span class = "kd" > type< / span > < span class = "p" > =< / span > < span class = "s" > " py" < / span > < span class = "nx" > wrap< / span > < span class = "p" > =< / span > < span class = "s" > " true" < / span > < span class = "nx" > hl_lines< / span > < span class = "p" > =< / span > < span class = "s" > " 2" < / span > < span class = "p" > > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "err" > #< / span > < span class = "nx" > Quicksort< / span > < span class = "nx" > Python< / span > < span class = "nx" > One< / span > < span class = "o" > -< / span > < span class = "nx" > liner< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > lambda< / span > < span class = "nx" > L< / span > < span class = "p" > :< / span > < span class = "p" > []< / span > < span class = "k" > if< / span > < span class = "nx" > L< / span > < span class = "o" > ==< / span > < span class = "p" > []< / span > < span class = "k" > else< / span > < span class = "nf" > qsort< / span > < span class = "p" > ([< / span > < span class = "nx" > x< / span > < span class = "k" > for< / span > < span class = "nx" > x< / span > < span class = "nx" > in< / span > < span class = "nx" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 1< / span > < span class = "p" > :]< / span > < span class = "k" > if< / span > < span class = "nx" > x< / span > < span class = "p" > < < / span > < span class = "nx" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 0< / span > < span class = "p" > ]])< / span > < span class = "o" > +< / span > < span class = "nx" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 0< / span > < span class = "p" > :< / span > < span class = "mi" > 1< / span > < span class = "p" > ]< / span > < span class = "o" > +< / span > < span class = "nf" > qsort< / span > < span class = "p" > ([< / span > < span class = "nx" > x< / span > < span class = "k" > for< / span > < span class = "nx" > x< / span > < span class = "nx" > in< / span > < span class = "nx" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 1< / span > < span class = "p" > :]< / span > < span class = "k" > if< / span > < span class = "nx" > x< / span > < span class = "o" > > =< / span > < span class = "nx" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 0< / span > < span class = "p" > ]])< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "err" > #< / span > < span class = "nx" > Some< / span > < span class = "nx" > more< / span > < span class = "nx" > stuff< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > highlight< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div > < div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-py" data-lang = "py" > < span class = "line" > < span class = "cl" > < span class = "c1" > # Quicksort Python One-liner< / span >
< / span > < / span > < span class = "line hl" > < span class = "cl" > < span class = "k" > lambda< / span > < span class = "n" > L< / span > < span class = "p" > :< / span > < span class = "p" > []< / span > < span class = "k" > if< / span > < span class = "n" > L< / span > < span class = "o" > ==< / span > < span class = "p" > []< / span > < span class = "k" > else< / span > < span class = "n" > qsort< / span > < span class = "p" > ([< / span > < span class = "n" > x< / span > < span class = "k" > for< / span > < span class = "n" > x< / span > < span class = "ow" > in< / span > < span class = "n" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 1< / span > < span class = "p" > :]< / span > < span class = "k" > if< / span > < span class = "n" > x< / span > < span class = "o" > < < / span > < span class = "n" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 0< / span > < span class = "p" > ]])< / span > < span class = "o" > +< / span > < span class = "n" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 0< / span > < span class = "p" > :< / span > < span class = "mi" > 1< / span > < span class = "p" > ]< / span > < span class = "o" > +< / span > < span class = "n" > qsort< / span > < span class = "p" > ([< / span > < span class = "n" > x< / span > < span class = "k" > for< / span > < span class = "n" > x< / span > < span class = "ow" > in< / span > < span class = "n" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 1< / span > < span class = "p" > :]< / span > < span class = "k" > if< / span > < span class = "n" > x< / span > < span class = "o" > > =< / span > < span class = "n" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 0< / span > < span class = "p" > ]])< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "c1" > # Some more stuff< / span > < / span > < / span > < / code > < / pre > < / div >
< h3 id = "without-wrap" > Without Wrap< / h3 >
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > highlight< / span > < span class = "kd" > type< / span > < span class = "p" > =< / span > < span class = "s" > " py" < / span > < span class = "nx" > wrap< / span > < span class = "p" > =< / span > < span class = "s" > " false" < / span > < span class = "nx" > hl_lines< / span > < span class = "p" > =< / span > < span class = "s" > " 2" < / span > < span class = "p" > > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "err" > #< / span > < span class = "nx" > Quicksort< / span > < span class = "nx" > Python< / span > < span class = "nx" > One< / span > < span class = "o" > -< / span > < span class = "nx" > liner< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > lambda< / span > < span class = "nx" > L< / span > < span class = "p" > :< / span > < span class = "p" > []< / span > < span class = "k" > if< / span > < span class = "nx" > L< / span > < span class = "o" > ==< / span > < span class = "p" > []< / span > < span class = "k" > else< / span > < span class = "nf" > qsort< / span > < span class = "p" > ([< / span > < span class = "nx" > x< / span > < span class = "k" > for< / span > < span class = "nx" > x< / span > < span class = "nx" > in< / span > < span class = "nx" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 1< / span > < span class = "p" > :]< / span > < span class = "k" > if< / span > < span class = "nx" > x< / span > < span class = "p" > < < / span > < span class = "nx" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 0< / span > < span class = "p" > ]])< / span > < span class = "o" > +< / span > < span class = "nx" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 0< / span > < span class = "p" > :< / span > < span class = "mi" > 1< / span > < span class = "p" > ]< / span > < span class = "o" > +< / span > < span class = "nf" > qsort< / span > < span class = "p" > ([< / span > < span class = "nx" > x< / span > < span class = "k" > for< / span > < span class = "nx" > x< / span > < span class = "nx" > in< / span > < span class = "nx" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 1< / span > < span class = "p" > :]< / span > < span class = "k" > if< / span > < span class = "nx" > x< / span > < span class = "o" > > =< / span > < span class = "nx" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 0< / span > < span class = "p" > ]])< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "err" > #< / span > < span class = "nx" > Some< / span > < span class = "nx" > more< / span > < span class = "nx" > stuff< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > highlight< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div > < div class = "highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-py" data-lang = "py" > < span class = "line" > < span class = "cl" > < span class = "c1" > # Quicksort Python One-liner< / span >
< / span > < / span > < span class = "line hl" > < span class = "cl" > < span class = "k" > lambda< / span > < span class = "n" > L< / span > < span class = "p" > :< / span > < span class = "p" > []< / span > < span class = "k" > if< / span > < span class = "n" > L< / span > < span class = "o" > ==< / span > < span class = "p" > []< / span > < span class = "k" > else< / span > < span class = "n" > qsort< / span > < span class = "p" > ([< / span > < span class = "n" > x< / span > < span class = "k" > for< / span > < span class = "n" > x< / span > < span class = "ow" > in< / span > < span class = "n" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 1< / span > < span class = "p" > :]< / span > < span class = "k" > if< / span > < span class = "n" > x< / span > < span class = "o" > < < / span > < span class = "n" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 0< / span > < span class = "p" > ]])< / span > < span class = "o" > +< / span > < span class = "n" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 0< / span > < span class = "p" > :< / span > < span class = "mi" > 1< / span > < span class = "p" > ]< / span > < span class = "o" > +< / span > < span class = "n" > qsort< / span > < span class = "p" > ([< / span > < span class = "n" > x< / span > < span class = "k" > for< / span > < span class = "n" > x< / span > < span class = "ow" > in< / span > < span class = "n" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 1< / span > < span class = "p" > :]< / span > < span class = "k" > if< / span > < span class = "n" > x< / span > < span class = "o" > > =< / span > < span class = "n" > L< / span > < span class = "p" > [< / span > < span class = "mi" > 0< / span > < span class = "p" > ]])< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "c1" > # Some more stuff< / span > < / span > < / span > < / code > < / pre > < / div >
< footer class = "footline" >
< / footer >
< / article >
2022-12-02 17:32:53 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
< / header >
2022-12-02 17:32:53 +00:00
< h1 id = "icon" > Icon< / h1 >
2023-10-28 20:28:18 +00:00
< p > The < code > icon< / code > shortcode displays icons using the < a href = "https://fontawesome.com" target = "_blank" > Font Awesome< / a > library.< / p >
2023-06-08 11:37:35 +00:00
< p > < i class = "fa-fw fas fa-exclamation-triangle" > < / i >
2023-06-03 20:59:23 +00:00
< i class = "fa-fw fas fa-angle-double-up" > < / i >
< i class = "fa-fw fas fa-skull-crossbones" > < / i > < / p >
2022-12-02 17:32:53 +00:00
< h2 id = "usage" > Usage< / h2 >
< p > While the examples are using shortcodes with positional parameter you are free to also call this shortcode from your own partials.< / p >
2023-07-27 15:06:14 +00:00
< div class = "tab-panel" data-tab-group = "shortcode-parameter" >
2022-12-02 17:32:53 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-12-02 17:32:53 +00:00
< button
data-tab-item="shortcode"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','shortcode')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-12-02 17:32:53 +00:00
< button
2023-09-05 11:10:04 +00:00
data-tab-item="shortcode-positional"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-09-05 11:10:04 +00:00
onclick="switchTab('shortcode-parameter','shortcode-positional')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode (positional)< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-12-02 17:32:53 +00:00
< button
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','partial')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > partial< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-12-02 17:32:53 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="shortcode"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > icon< / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " exclamation-triangle" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-12-02 17:32:53 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > icon< / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " angle-double-up" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > icon< / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " skull-crossbones" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
2023-09-05 11:10:04 +00:00
data-tab-item="shortcode-positional"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > icon< / span > < span class = "nx" > exclamation< / span > < span class = "o" > -< / span > < span class = "nx" > triangle< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-12-02 17:32:53 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > icon< / span > < span class = "nx" > angle< / span > < span class = "o" > -< / span > < span class = "nx" > double< / span > < span class = "o" > -< / span > < span class = "nx" > up< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > icon< / span > < span class = "nx" > skull< / span > < span class = "o" > -< / span > < span class = "nx" > crossbones< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/icon.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2022-12-02 17:32:53 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " icon" < / span > < span class = "s" > " exclamation-triangle" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/icon.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2022-12-02 17:32:53 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " icon" < / span > < span class = "s" > " angle-double-up" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/icon.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2022-12-02 17:32:53 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " icon" < / span > < span class = "s" > " skull-crossbones" < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-12-02 17:32:53 +00:00
< / div >
< / div >
< h3 id = "parameter" > Parameter< / h3 >
< table >
< thead >
< tr >
2023-07-27 15:06:14 +00:00
< th > Name< / th >
< th > Position< / th >
< th > Default< / th >
< th > Notes< / th >
2022-12-02 17:32:53 +00:00
< / tr >
< / thead >
< tbody >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > icon< / strong > < / td >
< td > 1< / td >
< td > < em > < empty> < / em > < / td >
2023-10-28 20:28:18 +00:00
< td > < a href = "#finding-an-icon" > Font Awesome icon name< / a > to be displayed. It will be displayed in the text color of its according context.< / td >
2022-12-02 17:32:53 +00:00
< / tr >
< / tbody >
< / table >
2022-12-02 18:27:40 +00:00
< h3 id = "finding-an-icon" > Finding an icon< / h3 >
2023-10-28 20:28:18 +00:00
< p > Browse through the available icons in the < a href = "https://fontawesome.com/v5/search?m=free" target = "_blank" > Font Awesome Gallery< / a > . Notice that the < strong > free< / strong > filter is enabled, as only the free icons are available by default.< / p >
< p > Once on the Font Awesome page for a specific icon, for example the page for the < a href = "https://fontawesome.com/v5/icons/heart?s=solid" target = "_blank" > heart< / a > , copy the icon name and paste into the Markdown content.< / p >
2022-12-02 18:27:40 +00:00
< h3 id = "customising-icons" > Customising Icons< / h3 >
2022-12-02 17:32:53 +00:00
< p > Font Awesome provides many ways to modify the icon< / p >
< ul >
< li > Change color (by default the icon will inherit the parent color)< / li >
< li > Increase or decrease size< / li >
< li > Rotate< / li >
< li > Combine with other icons< / li >
< / ul >
2023-10-28 20:28:18 +00:00
< p > Check the full documentation on < a href = "https://fontawesome.com/how-to-use/web-fonts-with-css" target = "_blank" > web fonts with CSS< / a > for more.< / p >
2022-12-02 17:32:53 +00:00
< h2 id = "examples" > Examples< / h2 >
2022-12-02 18:27:40 +00:00
< h3 id = "standard-usage" > Standard Usage< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "nx" > Built< / span > < span class = "nx" > with< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > icon< / span > < span class = "nx" > heart< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < span class = "nx" > by< / span > < span class = "nx" > Relearn< / span > < span class = "nx" > and< / span > < span class = "nx" > Hugo< / span > < / span > < / span > < / code > < / pre > < / div > < p > Built with < i class = "fa-fw fas fa-heart" > < / i > by Relearn and Hugo< / p >
2022-12-02 17:32:53 +00:00
< h3 id = "advanced-html-usage" > Advanced HTML Usage< / h3 >
2023-07-26 19:47:56 +00:00
< p > While the shortcode simplifies using standard icons, the icon customization and other advanced features of the Font Awesome library require you to use HTML directly. Paste the < code > < i> < / code > HTML into markup, and Font Awesome will load the relevant icon.< / p >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-html" data-lang = "html" > < span class = "line" > < span class = "cl" > Built with < span class = "p" > < < / span > < span class = "nt" > i< / span > < span class = "na" > class< / span > < span class = "o" > =< / span > < span class = "s" > " fas fa-heart" < / span > < span class = "p" > > < /< / span > < span class = "nt" > i< / span > < span class = "p" > > < / span > by Relearn and Hugo< / span > < / span > < / code > < / pre > < / div > < p > Built with < i class = "fas fa-heart" > < / i > by Relearn and Hugo< / p >
2023-11-29 23:15:02 +00:00
< p > To use these native HTML elements in your Markdown, add this in your < code > hugo.toml< / code > :< / p >
2023-07-26 19:47:56 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-toml" data-lang = "toml" > < span class = "line" > < span class = "cl" > < span class = "p" > [< / span > < span class = "nx" > markup< / span > < span class = "p" > .< / span > < span class = "nx" > goldmark< / span > < span class = "p" > .< / span > < span class = "nx" > renderer< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > unsafe< / span > < span class = "p" > =< / span > < span class = "kc" > true< / span > < / span > < / span > < / code > < / pre > < / div >
2022-12-02 17:32:53 +00:00
< footer class = "footline" >
< / footer >
< / article >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "include" > Include< / h1 >
2022-07-05 22:16:52 +00:00
2022-06-05 17:32:37 +00:00
< p > The < code > include< / code > shortcode includes other files from your project inside of the current page.< / p >
2022-04-02 13:30:16 +00:00
< h2 id = "usage" > Usage< / h2 >
2022-06-22 22:08:50 +00:00
< p > While the examples are using shortcodes with named parameter you are free to use positional aswell or also call this shortcode from your own partials.< / p >
2022-06-05 17:32:37 +00:00
2023-07-27 15:06:14 +00:00
< div class = "tab-panel" data-tab-group = "shortcode-parameter" >
2022-06-05 17:32:37 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-06-05 17:32:37 +00:00
< button
2022-06-22 22:08:50 +00:00
data-tab-item="shortcode"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','shortcode')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-22 22:08:50 +00:00
< button
2023-09-05 11:10:04 +00:00
data-tab-item="shortcode-positional"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-09-05 11:10:04 +00:00
onclick="switchTab('shortcode-parameter','shortcode-positional')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode (positional)< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-05 17:32:37 +00:00
< button
2022-06-22 22:08:50 +00:00
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','partial')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > partial< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-05 17:32:37 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="shortcode"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > include< / span > < span class = "nx" > file< / span > < span class = "p" > =< / span > < span class = "s" > " shortcodes/INCLUDE_ME.md" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
2023-09-05 11:10:04 +00:00
data-tab-item="shortcode-positional"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > include< / span > < span class = "s" > " shortcodes/INCLUDE_ME.md" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/include .html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2022-06-22 22:08:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " file" < / span > < span class = "s" > " shortcodes/INCLUDE_ME.md" < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-06-05 17:32:37 +00:00
< / div >
< / div >
< p > The included files can even contain Markdown and will be taken into account when generating the table of contents.< / p >
< h3 id = "parameter" > Parameter< / h3 >
< table >
< thead >
< tr >
2023-07-27 15:06:14 +00:00
< th > Name< / th >
< th > Position< / th >
< th > Default< / th >
< th > Notes< / th >
2022-06-05 17:32:37 +00:00
< / tr >
< / thead >
< tbody >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > file< / strong > < / td >
< td > 1< / td >
< td > < em > < empty> < / em > < / td >
2023-10-28 20:28:18 +00:00
< td > The path to the file to be included. Path resolution adheres to < a href = "https://gohugo.io/functions/readfile/" target = "_blank" > Hugo’ s build-in < code > readFile< / code > function< / a > < / td >
2022-06-05 17:32:37 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > hidefirstheading< / strong > < / td >
< td > 2< / td >
< td > < code > false< / code > < / td >
< td > When < code > true< / code > and the included file contains headings, the first heading will be hidden. This comes in handy, eg. if you include otherwise standalone Markdown files.< / td >
2022-06-05 17:32:37 +00:00
< / tr >
< / tbody >
< / table >
2022-04-02 13:30:16 +00:00
< h2 id = "examples" > Examples< / h2 >
2022-10-31 14:06:51 +00:00
< h3 id = "arbitrary-content" > Arbitrary Content< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > include< / span > < span class = "s" > " shortcodes/INCLUDE_ME.md" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > You can add standard markdown syntax:< / p >
2022-04-02 13:30:16 +00:00
< ul >
< li > multiple paragraphs< / li >
< li > bullet point lists< / li >
< li > < em > emphasized< / em > , < strong > bold< / strong > and even < strong > < em > bold emphasized< / em > < / strong > text< / li >
2023-10-28 20:28:18 +00:00
< li > < a href = "https://example.com" target = "_blank" > links< / a > < / li >
2023-05-31 21:45:45 +00:00
< li > etc.< sup id = "fnref:1" > < a href = "#fn:1" class = "footnote-ref" role = "doc-noteref" > 1< / a > < / sup > < / li >
2022-04-02 13:30:16 +00:00
< / ul >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-plaintext" data-lang = "plaintext" > < span class = "line" > < span class = "cl" > ...and even source code< / span > < / span > < / code > < / pre > < / div > < blockquote >
2022-10-31 14:06:51 +00:00
< p > the possibilities are endless (almost - including other shortcodes may or may not work) (almost - including other shortcodes may or may not work)< / p >
2022-04-02 13:30:16 +00:00
< / blockquote >
2023-05-31 21:45:45 +00:00
< div class = "footnotes" role = "doc-endnotes" >
< hr >
< ol >
< li id = "fn:1" >
< p > Et Cetera (English: /ɛtˈ sɛtərə/), abbreviated to etc., etc, et cet., is a Latin expression that is used in English to mean “ and other similar things” , or “ and so forth”   < a href = "#fnref:1" class = "footnote-backref" role = "doc-backlink" > ↩ ︎ < / a > < / p >
< / li >
< / ol >
< / div >
2022-04-02 13:30:16 +00:00
< footer class = "footline" >
< / footer >
< / article >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "math" > Math< / h1 >
2022-07-05 22:16:52 +00:00
2023-10-28 20:28:18 +00:00
< p > The < code > math< / code > shortcode generates beautiful formatted math and chemical formulae using the < a href = "https://mathjax.org/" target = "_blank" > MathJax< / a > library.< / p >
2022-07-02 12:20:53 +00:00
< span class = "math align-center" >
$$\left( \sum_{k=1}^n a_k b_k \right)^2 \leq \left( \sum_{k=1}^n a_k^2 \right) \left( \sum_{k=1}^n b_k^2 \right)$$
< / span >
2023-06-03 22:20:43 +00:00
2022-07-02 22:46:26 +00:00
< div class = "box notices cstyle note" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > < i class = "fa-fw fas fa-exclamation-circle" > < / i > Note< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-07-02 22:46:26 +00:00
< p > This only works in modern browsers.< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-07-02 22:46:26 +00:00
< / div >
2022-07-02 12:20:53 +00:00
< h2 id = "usage" > Usage< / h2 >
2022-10-04 13:36:17 +00:00
< p > While the examples are using shortcodes with named parameter it is recommended to use codefences instead. This is because more and more other software supports Math codefences (eg. GitHub) and so your markdown becomes more portable.< / p >
2022-07-02 12:20:53 +00:00
< p > You are free to also call this shortcode from your own partials.< / p >
2023-06-03 22:20:43 +00:00
2023-07-27 15:06:14 +00:00
< div class = "tab-panel" data-tab-group = "shortcode-parameter" >
2022-07-02 12:20:53 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-07-02 12:20:53 +00:00
< button
data-tab-item="codefence"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','codefence')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > codefence< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-07-02 12:20:53 +00:00
< button
data-tab-item="shortcode"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','shortcode')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-07-02 12:20:53 +00:00
< button
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','partial')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > partial< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-07-02 12:20:53 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="codefence"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-md" data-lang = "md" > < span class = "line" > < span class = "cl" > ```math { align=" center" }
2022-10-31 14:31:20 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > $$\left( \sum_{k=1}^n a_k b_k \right)^2 \leq \left( \sum_{k=1}^n a_k^2 \right) \left( \sum_{k=1}^n b_k^2 \right)$$
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > ```< / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="shortcode"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > math< / span > < span class = "nx" > align< / span > < span class = "p" > =< / span > < span class = "s" > " center" < / span > < span class = "p" > > }}< / span >
2022-07-02 12:20:53 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "err" > $$\< / span > < span class = "nf" > left< / span > < span class = "p" > (< / span > < span class = "err" > \< / span > < span class = "nx" > sum_< / span > < span class = "p" > {< / span > < span class = "nx" > k< / span > < span class = "p" > =< / span > < span class = "mi" > 1< / span > < span class = "p" > }^< / span > < span class = "nx" > n< / span > < span class = "nx" > a_k< / span > < span class = "nx" > b_k< / span > < span class = "err" > \< / span > < span class = "nx" > right< / span > < span class = "p" > )^< / span > < span class = "mi" > 2< / span > < span class = "err" > \< / span > < span class = "nx" > leq< / span > < span class = "err" > \< / span > < span class = "nf" > left< / span > < span class = "p" > (< / span > < span class = "err" > \< / span > < span class = "nx" > sum_< / span > < span class = "p" > {< / span > < span class = "nx" > k< / span > < span class = "p" > =< / span > < span class = "mi" > 1< / span > < span class = "p" > }^< / span > < span class = "nx" > n< / span > < span class = "nx" > a_k< / span > < span class = "p" > ^< / span > < span class = "mi" > 2< / span > < span class = "err" > \< / span > < span class = "nx" > right< / span > < span class = "p" > )< / span > < span class = "err" > \< / span > < span class = "nf" > left< / span > < span class = "p" > (< / span > < span class = "err" > \< / span > < span class = "nx" > sum_< / span > < span class = "p" > {< / span > < span class = "nx" > k< / span > < span class = "p" > =< / span > < span class = "mi" > 1< / span > < span class = "p" > }^< / span > < span class = "nx" > n< / span > < span class = "nx" > b_k< / span > < span class = "p" > ^< / span > < span class = "mi" > 2< / span > < span class = "err" > \< / span > < span class = "nx" > right< / span > < span class = "p" > )< / span > < span class = "err" > $$< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > math< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/math.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2022-07-02 12:20:53 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "s" > " $$left( \sum_{k=1}^n a_k b_k \right)^2 \leq \left( \sum_{k=1}^n a_k^2 \right) \left( \sum_{k=1}^n b_k^2 \right)$$" < / span >
2022-10-31 14:31:20 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " align" < / span > < span class = "s" > " center" < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-07-02 12:20:53 +00:00
< / div >
< / div >
< h3 id = "parameter" > Parameter< / h3 >
< table >
< thead >
< tr >
2023-07-27 15:06:14 +00:00
< th > Name< / th >
< th > Default< / th >
< th > Notes< / th >
2022-07-02 12:20:53 +00:00
< / tr >
< / thead >
< tbody >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > align< / strong > < / td >
< td > < code > center< / code > < / td >
< td > Allowed values are < code > left< / code > , < code > center< / code > or < code > right< / code > .< / td >
2022-07-02 12:20:53 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < em > < strong > < content> < / strong > < / em > < / td >
< td > < em > < empty> < / em > < / td >
< td > Your formuale.< / td >
2022-07-02 12:20:53 +00:00
< / tr >
< / tbody >
< / table >
< h2 id = "configuration" > Configuration< / h2 >
2023-11-29 23:15:02 +00:00
< p > MathJax is configured with default settings. You can customize MathJax’ s default settings for all of your files thru a JSON object in your < code > hugo.toml< / code > or override these settings per page thru your pages frontmatter.< / p >
< p > The JSON object of your < code > hugo.toml< / code > / frontmatter is forwarded into MathJax’ s configuration object.< / p >
2023-10-28 20:28:18 +00:00
< p > See < a href = "https://docs.mathjax.org/en/latest/options/index.html" target = "_blank" > MathJax documentation< / a > for all allowed settings.< / p >
2022-07-02 12:20:53 +00:00
< h3 id = "global-configuration-file" > Global Configuration File< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-toml" data-lang = "toml" > < span class = "line" > < span class = "cl" > < span class = "p" > [< / span > < span class = "nx" > params< / span > < span class = "p" > ]< / span >
2023-11-23 22:22:29 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > mathJaxInitialize< / span > < span class = "p" > =< / span > < span class = "s2" > " { \" chtml\" : { \" displayAlign\" : \" left\" } }" < / span > < / span > < / span > < / code > < / pre > < / div > < h3 id = "pages-frontmatter" > Page’ s Frontmatter< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-toml" data-lang = "toml" > < span class = "line" > < span class = "cl" > < span class = "err" > +++< / span >
2022-07-02 12:20:53 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > mathJaxInitialize< / span > < span class = "p" > =< / span > < span class = "s2" > " { \" chtml\" : { \" displayAlign\" : \" left\" } }" < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "err" > +++< / span > < / span > < / span > < / code > < / pre > < / div > < h2 id = "examples" > Examples< / h2 >
2022-07-02 12:20:53 +00:00
< h3 id = "inline-math" > Inline Math< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-md" data-lang = "md" > < span class = "line" > < span class = "cl" > Inline math is generated if you use a single < span class = "sb" > `$`< / span > as a delimiter around your formulae: {{< span class = "p" > < < / span > < span class = "nt" > math< / span > < span class = "p" > > < / span > }}$\sqrt{3}${{< span class = "p" > < < / span > < span class = "p" > /< / span > < span class = "nt" > math< / span > < span class = "p" > > < / span > }}< / span > < / span > < / code > < / pre > < / div > < p > Inline math is generated if you use a single < code > $< / code > as a delimiter around your formulae:
2022-07-02 12:20:53 +00:00
< span class = "math align-center" > $\sqrt{3}$< / span > < / p >
2022-11-05 12:01:19 +00:00
< h3 id = "blocklevel-math-with-right-alignment" > Blocklevel Math with Right Alignment< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-md" data-lang = "md" > < span class = "line" > < span class = "cl" > If you delimit your formulae by two consecutive < span class = "sb" > `$$`< / span > it generates a new block.
2022-07-02 12:20:53 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" >
2022-11-05 12:01:19 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > {{< span class = "p" > < < / span > < span class = "nt" > math< / span > < span class = "na" > align< / span > < span class = "o" > =< / span > < span class = "s" > " right" < / span > < span class = "p" > > < / span > }}
2022-07-02 12:20:53 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > $$\left( \sum_{k=1}^n a_k b_k \right)^2 \leq \left( \sum_{k=1}^n a_k^2 \right) \left( \sum_{k=1}^n b_k^2 \right)$$
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > {{< span class = "p" > < < / span > < span class = "p" > /< / span > < span class = "nt" > math< / span > < span class = "p" > > < / span > }}< / span > < / span > < / code > < / pre > < / div > < p > If you delimit your formulae by two consecutive < code > $$< / code > it generates a new block.< / p >
2022-07-02 12:20:53 +00:00
2022-11-05 12:01:19 +00:00
< span class = "math align-right" >
2022-07-02 12:20:53 +00:00
$$\left( \sum_{k=1}^n a_k b_k \right)^2 \leq \left( \sum_{k=1}^n a_k^2 \right) \left( \sum_{k=1}^n b_k^2 \right)$$
< / span >
< h3 id = "codefence" > Codefence< / h3 >
2023-01-14 00:40:32 +00:00
< p > You can also use codefences.< / p >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-md" data-lang = "md" > < span class = "line" > < span class = "cl" > < span class = "s" > ```math
2022-07-02 12:20:53 +00:00
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > < / span > $$\left( \sum_{k=1}^n a_k b_k \right)^2 \leq \left( \sum_{k=1}^n a_k^2 \right) \left( \sum_{k=1}^n b_k^2 \right)$$
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```< / span > < / span > < / span > < / code > < / pre > < / div >
2022-07-02 22:36:23 +00:00
< span class = "math align-center" > $$\left( \sum_{k=1}^n a_k b_k \right)^2 \leq \left( \sum_{k=1}^n a_k^2 \right) \left( \sum_{k=1}^n b_k^2 \right)$$< / span > < h3 id = "chemical-formulae" > Chemical Formulae< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-md" data-lang = "md" > < span class = "line" > < span class = "cl" > {{< span class = "p" > < < / span > < span class = "nt" > math< / span > < span class = "p" > > < / span > }}
2022-07-02 12:20:53 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > $$\ce{Hg^2+ -> [I-] HgI2 -> [I-] [Hg^{II}I4]^2-}$$
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > {{< span class = "p" > < < / span > < span class = "p" > /< / span > < span class = "nt" > math< / span > < span class = "p" > > < / span > }}< / span > < / span > < / code > < / pre > < / div >
2022-07-02 12:20:53 +00:00
< span class = "math align-center" >
$$\ce{Hg^2+ ->[I-] HgI2 ->[I-] [Hg^{II}I4]^2-}$$
< / span >
< footer class = "footline" >
< / footer >
< / article >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "mermaid" > Mermaid< / h1 >
2022-07-05 22:16:52 +00:00
2023-10-28 20:28:18 +00:00
< p > The < code > mermaid< / code > shortcode generates diagrams and flowcharts from text, in a similar manner as Markdown using the < a href = "https://mermaidjs.github.io/" target = "_blank" > Mermaid< / a > library.< / p >
2022-06-05 17:32:37 +00:00
2023-11-18 22:20:02 +00:00
< pre class = "mermaid align-center zoomable" >
2022-06-05 17:32:37 +00:00
graph LR;
2022-10-07 18:46:19 +00:00
If --> Then
Then --> Else
2023-09-30 19:51:47 +00:00
< / pre >
2023-06-03 22:20:43 +00:00
2022-05-29 21:00:53 +00:00
< div class = "box notices cstyle note" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > < i class = "fa-fw fas fa-exclamation-circle" > < / i > Note< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-04-02 13:30:16 +00:00
< p > This only works in modern browsers.< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< / div >
< h2 id = "usage" > Usage< / h2 >
2022-06-22 22:08:50 +00:00
< p > While the examples are using shortcodes with named parameter it is recommended to use codefences instead. This is because more and more other software supports Mermaid codefences (eg. GitHub) and so your markdown becomes more portable.< / p >
< p > You are free to also call this shortcode from your own partials.< / p >
2023-06-03 22:20:43 +00:00
2023-07-27 15:06:14 +00:00
< div class = "tab-panel" data-tab-group = "shortcode-parameter" >
2022-06-05 17:32:37 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-06-05 17:32:37 +00:00
< button
data-tab-item="codefence"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','codefence')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > codefence< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-05 17:32:37 +00:00
< button
data-tab-item="shortcode"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','shortcode')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-22 22:08:50 +00:00
< button
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','partial')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > partial< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-05 17:32:37 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="codefence"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-md" data-lang = "md" > < span class = "line" > < span class = "cl" > ```mermaid { align=" center" zoom=" true" }
2022-10-31 14:17:29 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > graph LR;
2022-06-05 17:32:37 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > If --> Then
< / span > < / span > < span class = "line" > < span class = "cl" > Then --> Else
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > ```< / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="shortcode"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > mermaid< / span > < span class = "nx" > align< / span > < span class = "p" > =< / span > < span class = "s" > " center" < / span > < span class = "nx" > zoom< / span > < span class = "p" > =< / span > < span class = "s" > " true" < / span > < span class = "p" > > }}< / span >
2022-06-05 17:32:37 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > graph< / span > < span class = "nx" > LR< / span > < span class = "p" > ;< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > If< / span > < span class = "o" > --< / span > < span class = "p" > > < / span > < span class = "nx" > Then< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Then< / span > < span class = "o" > --< / span > < span class = "p" > > < / span > < span class = "nx" > Else< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/mermaid.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2022-06-22 22:08:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "s" > " graph LR;\nIf --> Then\nThen --> Else" < / span >
2022-10-31 14:17:29 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " align" < / span > < span class = "s" > " center" < / span >
2023-02-05 10:13:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " zoom" < / span > < span class = "s" > " true" < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-06-05 17:32:37 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< / div >
2022-06-22 22:08:50 +00:00
< p > The generated graphs can be be panned by dragging them and zoomed by using the mousewheel. On mobile devices you can use finger gestures.< / p >
2022-06-05 17:32:37 +00:00
< h3 id = "parameter" > Parameter< / h3 >
< table >
< thead >
< tr >
2023-07-27 15:06:14 +00:00
< th > Name< / th >
< th > Default< / th >
< th > Notes< / th >
2022-06-05 17:32:37 +00:00
< / tr >
< / thead >
< tbody >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > align< / strong > < / td >
< td > < code > center< / code > < / td >
< td > Allowed values are < code > left< / code > , < code > center< / code > or < code > right< / code > .< / td >
2022-06-05 17:32:37 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > zoom< / strong > < / td >
< td > see notes< / td >
2023-10-28 20:28:18 +00:00
< td > Whether the graph is pan- and zoomable.< br > < br > If not set the value is determined by the < code > mermaidZoom< / code > setting of the < a href = "#global-configuration-file" > site< / a > or the < a href = "#pages-frontmatter" > pages frontmatter< / a > or < code > false< / code > if not set at all.< br > < br > - < code > false< / code > : no pan or zoom< br > - < code > true< / code > : pan and zoom active< / td >
2023-02-05 10:13:50 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < em > < strong > < content> < / strong > < / em > < / td >
< td > < em > < empty> < / em > < / td >
< td > Your Mermaid graph.< / td >
2022-06-05 17:32:37 +00:00
< / tr >
< / tbody >
< / table >
< h2 id = "configuration" > Configuration< / h2 >
2023-11-29 23:15:02 +00:00
< p > Mermaid is configured with default settings. You can customize Mermaid’ s default settings for all of your files thru a JSON object in your < code > hugo.toml< / code > , override these settings per page thru your pages frontmatter or override these setting per diagramm thru < a href = "https://mermaid-js.github.io/mermaid/#/directives?id=directives" target = "_blank" > diagram directives< / a > .< / p >
< p > The JSON object of your < code > hugo.toml< / code > / frontmatter is forwarded into Mermaid’ s < code > mermaid.initialize()< / code > function.< / p >
2023-10-28 20:28:18 +00:00
< p > See < a href = "https://mermaid-js.github.io/mermaid/#/Setup?id=mermaidapi-configuration-defaults" target = "_blank" > Mermaid documentation< / a > for all allowed settings.< / p >
2023-11-29 23:15:02 +00:00
< p > The < code > theme< / code > setting can also be set by your used color variant. This will be the sitewide default and can - again - be overridden by your settings in < code > hugo.toml< / code > , frontmatter or diagram directives.< / p >
2022-06-05 17:32:37 +00:00
< h3 id = "global-configuration-file" > Global Configuration File< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-toml" data-lang = "toml" > < span class = "line" > < span class = "cl" > < span class = "p" > [< / span > < span class = "nx" > params< / span > < span class = "p" > ]< / span >
2022-06-05 17:32:37 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > mermaidInitialize< / span > < span class = "p" > =< / span > < span class = "s2" > " { \" theme\" : \" dark\" }" < / span >
2023-11-23 22:22:29 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > mermaidZoom< / span > < span class = "p" > =< / span > < span class = "kc" > true< / span > < / span > < / span > < / code > < / pre > < / div > < h3 id = "pages-frontmatter" > Page’ s Frontmatter< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-toml" data-lang = "toml" > < span class = "line" > < span class = "cl" > < span class = "err" > +++< / span >
2022-06-05 17:32:37 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > mermaidInitialize< / span > < span class = "p" > =< / span > < span class = "s2" > " { \" theme\" : \" dark\" }" < / span >
2023-02-05 10:13:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > mermaidZoom< / span > < span class = "p" > =< / span > < span class = "kc" > true< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "err" > +++< / span > < / span > < / span > < / code > < / pre > < / div > < h2 id = "examples" > Examples< / h2 >
2023-06-09 19:48:05 +00:00
< h3 id = "flowchart-with-yaml-title" > Flowchart with YAML-Title< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span >
2023-06-09 19:48:05 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "o" > ---< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > title< / span > < span class = "p" > :< / span > < span class = "nx" > Example< / span > < span class = "nx" > Diagram< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "o" > ---< / span >
2022-04-02 13:30:16 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > graph< / span > < span class = "nx" > LR< / span > < span class = "p" > ;< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > A< / span > < span class = "p" > [< / span > < span class = "nx" > Hard< / span > < span class = "nx" > edge< / span > < span class = "p" > ]< / span > < span class = "o" > --< / span > < span class = "p" > > |< / span > < span class = "nx" > Link< / span > < span class = "nx" > text< / span > < span class = "p" > |< / span > < span class = "nf" > B< / span > < span class = "p" > (< / span > < span class = "nx" > Round< / span > < span class = "nx" > edge< / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > B< / span > < span class = "o" > --< / span > < span class = "p" > > < / span > < span class = "nx" > C< / span > < span class = "p" > {< < / span > < span class = "nx" > strong< / span > < span class = "p" > > < / span > < span class = "nx" > Decision< / span > < span class = "p" > < < / span > < span class = "o" > /< / span > < span class = "nx" > strong< / span > < span class = "p" > > }< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > C< / span > < span class = "o" > --< / span > < span class = "p" > > |< / span > < span class = "nx" > One< / span > < span class = "p" > |< / span > < span class = "nx" > D< / span > < span class = "p" > [< / span > < span class = "nx" > Result< / span > < span class = "nx" > one< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > C< / span > < span class = "o" > --< / span > < span class = "p" > > |< / span > < span class = "nx" > Two< / span > < span class = "p" > |< / span > < span class = "nx" > E< / span > < span class = "p" > [< / span > < span class = "nx" > Result< / span > < span class = "nx" > two< / span > < span class = "p" > ]< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-11-18 22:20:02 +00:00
< pre class = "mermaid align-center zoomable" >
2023-06-09 19:48:05 +00:00
---
title: Example Diagram
---
2022-06-05 17:32:37 +00:00
graph LR;
2022-10-07 18:46:19 +00:00
A[Hard edge] --> |Link text| B(Round edge)
B --> C{< strong> Decision< /strong> }
C --> |One| D[Result one]
C --> |Two| E[Result two]
2023-09-30 19:51:47 +00:00
< / pre >
2022-11-18 23:02:20 +00:00
< h3 id = "sequence-diagram-with-configuration-directive" > Sequence Diagram with Configuration Directive< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span >
2022-11-18 23:02:20 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "o" > %%< / span > < span class = "p" > {< / span > < span class = "nx" > init< / span > < span class = "p" > :{< / span > < span class = "s" > " fontFamily" < / span > < span class = "p" > :< / span > < span class = "s" > " monospace" < / span > < span class = "p" > ,< / span > < span class = "s" > " sequence" < / span > < span class = "p" > :{< / span > < span class = "s" > " showSequenceNumbers" < / span > < span class = "p" > :< / span > < span class = "kc" > true< / span > < span class = "p" > }}}< / span > < span class = "o" > %%< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > sequenceDiagram< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Alice< / span > < span class = "o" > -> > < / span > < span class = "nx" > John< / span > < span class = "p" > :< / span > < span class = "nx" > Hello< / span > < span class = "nx" > John< / span > < span class = "p" > ,< / span > < span class = "nx" > how< / span > < span class = "nx" > are< / span > < span class = "nx" > you< / span > < span class = "err" > ?< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > loop< / span > < span class = "nx" > Healthcheck< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > John< / span > < span class = "o" > -> > < / span > < span class = "nx" > John< / span > < span class = "p" > :< / span > < span class = "nx" > Fight< / span > < span class = "nx" > against< / span > < span class = "nx" > hypochondria< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > end< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Note< / span > < span class = "nx" > right< / span > < span class = "nx" > of< / span > < span class = "nx" > John< / span > < span class = "p" > :< / span > < span class = "nx" > Rational< / span > < span class = "nx" > thoughts< / span > < span class = "p" > !< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > John< / span > < span class = "o" > --> > < / span > < span class = "nx" > Alice< / span > < span class = "p" > :< / span > < span class = "nx" > Great< / span > < span class = "p" > !< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > John< / span > < span class = "o" > -> > < / span > < span class = "nx" > Bob< / span > < span class = "p" > :< / span > < span class = "nx" > How< / span > < span class = "nx" > about< / span > < span class = "nx" > you< / span > < span class = "err" > ?< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Bob< / span > < span class = "o" > --> > < / span > < span class = "nx" > John< / span > < span class = "p" > :< / span > < span class = "nx" > Jolly< / span > < span class = "nx" > good< / span > < span class = "p" > !< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-11-18 22:20:02 +00:00
< pre class = "mermaid align-center zoomable" >
2022-11-18 23:02:20 +00:00
%%{init:{" fontFamily" :" monospace" , " sequence" :{" showSequenceNumbers" :true}}}%%
sequenceDiagram
Alice-> > John: Hello John, how are you?
loop Healthcheck
John-> > John: Fight against hypochondria
end
Note right of John: Rational thoughts!
John--> > Alice: Great!
John-> > Bob: How about you?
Bob--> > John: Jolly good!
2023-09-30 19:51:47 +00:00
< / pre >
2022-11-17 22:36:34 +00:00
< h3 id = "class-diagram-with-codefence-syntax" > Class Diagram with Codefence Syntax< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "s" > ```mermaid
2022-11-17 22:36:34 +00:00
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > classDiagram
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > Animal < |-- Duck
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > Animal < |-- Fish
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > Animal < |-- Zebra
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > Animal : +int age
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > Animal : +String gender
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > Animal: +isMammal()
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > Animal: +mate()
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > class Duck{
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > +String beakColor
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > +swim()
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > +quack()
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > }
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > class Fish{
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > -int sizeInFeet
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > -canEat()
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > }
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > class Zebra{
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > +bool is_wild
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > +run()
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > }
2023-06-21 23:23:13 +00:00
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```< / span > < / span > < / span > < / code > < / pre > < / div >
2023-11-18 22:20:02 +00:00
< pre class = "mermaid align-center zoomable" > classDiagram
2022-11-17 22:36:34 +00:00
Animal < |-- Duck
Animal < |-- Fish
Animal < |-- Zebra
Animal : + int age
Animal : + String gender
Animal: + isMammal()
Animal: + mate()
class Duck{
+ String beakColor
+ swim()
+ quack()
}
class Fish{
-int sizeInFeet
-canEat()
}
class Zebra{
+ bool is_wild
+ run()
2023-09-30 19:51:47 +00:00
}< / pre > < h3 id = "state-diagram-aligned-to-the-right" > State Diagram Aligned to the Right< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > mermaid< / span > < span class = "nx" > align< / span > < span class = "p" > =< / span > < span class = "s" > " right" < / span > < span class = "p" > > }}< / span >
2022-11-17 22:36:34 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > stateDiagram< / span > < span class = "o" > -< / span > < span class = "nx" > v2< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > open< / span > < span class = "p" > :< / span > < span class = "nx" > Open< / span > < span class = "nx" > Door< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > closed< / span > < span class = "p" > :< / span > < span class = "nx" > Closed< / span > < span class = "nx" > Door< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > locked< / span > < span class = "p" > :< / span > < span class = "nx" > Locked< / span > < span class = "nx" > Door< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > open< / span > < span class = "o" > --< / span > < span class = "p" > > < / span > < span class = "nx" > closed< / span > < span class = "p" > :< / span > < span class = "nx" > Close< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > closed< / span > < span class = "o" > --< / span > < span class = "p" > > < / span > < span class = "nx" > locked< / span > < span class = "p" > :< / span > < span class = "nx" > Lock< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > locked< / span > < span class = "o" > --< / span > < span class = "p" > > < / span > < span class = "nx" > closed< / span > < span class = "p" > :< / span > < span class = "nx" > Unlock< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > closed< / span > < span class = "o" > --< / span > < span class = "p" > > < / span > < span class = "nx" > open< / span > < span class = "p" > :< / span > < span class = "nx" > Open< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-11-18 22:20:02 +00:00
< pre class = "mermaid align-right zoomable" >
2022-11-17 22:36:34 +00:00
stateDiagram-v2
open: Open Door
closed: Closed Door
locked: Locked Door
open --> closed: Close
closed --> locked: Lock
locked --> closed: Unlock
closed --> open: Open
2023-09-30 19:51:47 +00:00
< / pre >
2023-06-09 19:48:05 +00:00
< h3 id = "entity-relationship-model-with-non-default-mermaid-theme" > Entity Relationship Model with Non-Default Mermaid Theme< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span >
2023-06-09 19:48:05 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "o" > %%< / span > < span class = "p" > {< / span > < span class = "nx" > init< / span > < span class = "p" > :{< / span > < span class = "s" > " theme" < / span > < span class = "p" > :< / span > < span class = "s" > " forest" < / span > < span class = "p" > }}< / span > < span class = "o" > %%< / span >
2022-11-18 23:02:20 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > erDiagram< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > CUSTOMER< / span > < span class = "p" > }|..|{< / span > < span class = "nx" > DELIVERY< / span > < span class = "o" > -< / span > < span class = "nx" > ADDRESS< / span > < span class = "p" > :< / span > < span class = "nx" > has< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > CUSTOMER< / span > < span class = "o" > ||--< / span > < span class = "nx" > o< / span > < span class = "p" > {< / span > < span class = "nx" > ORDER< / span > < span class = "p" > :< / span > < span class = "nx" > places< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > CUSTOMER< / span > < span class = "o" > ||--< / span > < span class = "nx" > o< / span > < span class = "p" > {< / span > < span class = "nx" > INVOICE< / span > < span class = "p" > :< / span > < span class = "s" > " liable for" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > DELIVERY< / span > < span class = "o" > -< / span > < span class = "nx" > ADDRESS< / span > < span class = "o" > ||--< / span > < span class = "nx" > o< / span > < span class = "p" > {< / span > < span class = "nx" > ORDER< / span > < span class = "p" > :< / span > < span class = "nx" > receives< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > INVOICE< / span > < span class = "o" > ||--< / span > < span class = "p" > |{< / span > < span class = "nx" > ORDER< / span > < span class = "p" > :< / span > < span class = "nx" > covers< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > ORDER< / span > < span class = "o" > ||--< / span > < span class = "p" > |{< / span > < span class = "nx" > ORDER< / span > < span class = "o" > -< / span > < span class = "nx" > ITEM< / span > < span class = "p" > :< / span > < span class = "nx" > includes< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > PRODUCT< / span > < span class = "o" > -< / span > < span class = "nx" > CATEGORY< / span > < span class = "o" > ||--< / span > < span class = "p" > |{< / span > < span class = "nx" > PRODUCT< / span > < span class = "p" > :< / span > < span class = "nx" > contains< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > PRODUCT< / span > < span class = "o" > ||--< / span > < span class = "nx" > o< / span > < span class = "p" > {< / span > < span class = "nx" > ORDER< / span > < span class = "o" > -< / span > < span class = "nx" > ITEM< / span > < span class = "p" > :< / span > < span class = "s" > " ordered in" < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-11-18 22:20:02 +00:00
< pre class = "mermaid align-center zoomable" >
2023-06-09 19:48:05 +00:00
%%{init:{" theme" :" forest" }}%%
2022-11-18 23:02:20 +00:00
erDiagram
CUSTOMER }|..|{ DELIVERY-ADDRESS : has
CUSTOMER ||--o{ ORDER : places
CUSTOMER ||--o{ INVOICE : " liable for"
DELIVERY-ADDRESS ||--o{ ORDER : receives
INVOICE ||--|{ ORDER : covers
ORDER ||--|{ ORDER-ITEM : includes
PRODUCT-CATEGORY ||--|{ PRODUCT : contains
PRODUCT ||--o{ ORDER-ITEM : " ordered in"
2023-09-30 19:51:47 +00:00
< / pre >
2022-11-18 23:02:20 +00:00
< h3 id = "user-journey" > User Journey< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span >
2022-11-18 23:02:20 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > journey< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > title< / span > < span class = "nx" > My< / span > < span class = "nx" > working< / span > < span class = "nx" > day< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > section< / span > < span class = "nx" > Go< / span > < span class = "nx" > to< / span > < span class = "nx" > work< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Make< / span > < span class = "nx" > tea< / span > < span class = "p" > :< / span > < span class = "mi" > 5< / span > < span class = "p" > :< / span > < span class = "nx" > Me< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Go< / span > < span class = "nx" > upstairs< / span > < span class = "p" > :< / span > < span class = "mi" > 3< / span > < span class = "p" > :< / span > < span class = "nx" > Me< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Do< / span > < span class = "nx" > work< / span > < span class = "p" > :< / span > < span class = "mi" > 1< / span > < span class = "p" > :< / span > < span class = "nx" > Me< / span > < span class = "p" > ,< / span > < span class = "nx" > Cat< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > section< / span > < span class = "nx" > Go< / span > < span class = "nx" > home< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Go< / span > < span class = "nx" > downstairs< / span > < span class = "p" > :< / span > < span class = "mi" > 5< / span > < span class = "p" > :< / span > < span class = "nx" > Me< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Sit< / span > < span class = "nx" > down< / span > < span class = "p" > :< / span > < span class = "mi" > 3< / span > < span class = "p" > :< / span > < span class = "nx" > Me< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-11-18 22:20:02 +00:00
< pre class = "mermaid align-center zoomable" >
2022-11-18 23:02:20 +00:00
journey
title My working day
section Go to work
Make tea: 5: Me
Go upstairs: 3: Me
Do work: 1: Me, Cat
section Go home
Go downstairs: 5: Me
Sit down: 3: Me
2023-09-30 19:51:47 +00:00
< / pre >
2022-11-17 22:36:34 +00:00
< h3 id = "gantt-chart" > GANTT Chart< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span >
2022-04-02 13:30:16 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > gantt< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > dateFormat< / span > < span class = "nx" > YYYY< / span > < span class = "o" > -< / span > < span class = "nx" > MM< / span > < span class = "o" > -< / span > < span class = "nx" > DD< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > title< / span > < span class = "nx" > Adding< / span > < span class = "nx" > GANTT< / span > < span class = "nx" > diagram< / span > < span class = "nx" > functionality< / span > < span class = "nx" > to< / span > < span class = "nx" > Mermaid< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > section< / span > < span class = "nx" > A< / span > < span class = "nx" > section< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Completed< / span > < span class = "nx" > task< / span > < span class = "p" > :< / span > < span class = "nx" > done< / span > < span class = "p" > ,< / span > < span class = "nx" > des1< / span > < span class = "p" > ,< / span > < span class = "mi" > 2014< / span > < span class = "o" > -< / span > < span class = "mo" > 01< / span > < span class = "o" > -< / span > < span class = "mo" > 06< / span > < span class = "p" > ,< / span > < span class = "mi" > 2014< / span > < span class = "o" > -< / span > < span class = "mo" > 01< / span > < span class = "o" > -< / span > < span class = "mi" > 08< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Active< / span > < span class = "nx" > task< / span > < span class = "p" > :< / span > < span class = "nx" > active< / span > < span class = "p" > ,< / span > < span class = "nx" > des2< / span > < span class = "p" > ,< / span > < span class = "mi" > 2014< / span > < span class = "o" > -< / span > < span class = "mo" > 01< / span > < span class = "o" > -< / span > < span class = "mi" > 09< / span > < span class = "p" > ,< / span > < span class = "mi" > 3< / span > < span class = "nx" > d< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Future< / span > < span class = "nx" > task< / span > < span class = "p" > :< / span > < span class = "nx" > des3< / span > < span class = "p" > ,< / span > < span class = "nx" > after< / span > < span class = "nx" > des2< / span > < span class = "p" > ,< / span > < span class = "mi" > 5< / span > < span class = "nx" > d< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Future< / span > < span class = "nx" > task2< / span > < span class = "p" > :< / span > < span class = "nx" > des4< / span > < span class = "p" > ,< / span > < span class = "nx" > after< / span > < span class = "nx" > des3< / span > < span class = "p" > ,< / span > < span class = "mi" > 5< / span > < span class = "nx" > d< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > section< / span > < span class = "nx" > Critical< / span > < span class = "nx" > tasks< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Completed< / span > < span class = "nx" > task< / span > < span class = "nx" > in< / span > < span class = "nx" > the< / span > < span class = "nx" > critical< / span > < span class = "nx" > line< / span > < span class = "p" > :< / span > < span class = "nx" > crit< / span > < span class = "p" > ,< / span > < span class = "nx" > done< / span > < span class = "p" > ,< / span > < span class = "mi" > 2014< / span > < span class = "o" > -< / span > < span class = "mo" > 01< / span > < span class = "o" > -< / span > < span class = "mo" > 06< / span > < span class = "p" > ,< / span > < span class = "mi" > 24< / span > < span class = "nx" > h< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Implement< / span > < span class = "nx" > parser< / span > < span class = "nx" > and< / span > < span class = "nx" > jison< / span > < span class = "p" > :< / span > < span class = "nx" > crit< / span > < span class = "p" > ,< / span > < span class = "nx" > done< / span > < span class = "p" > ,< / span > < span class = "nx" > after< / span > < span class = "nx" > des1< / span > < span class = "p" > ,< / span > < span class = "mi" > 2< / span > < span class = "nx" > d< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Create< / span > < span class = "nx" > tests< / span > < span class = "k" > for< / span > < span class = "nx" > parser< / span > < span class = "p" > :< / span > < span class = "nx" > crit< / span > < span class = "p" > ,< / span > < span class = "nx" > active< / span > < span class = "p" > ,< / span > < span class = "mi" > 3< / span > < span class = "nx" > d< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Future< / span > < span class = "nx" > task< / span > < span class = "nx" > in< / span > < span class = "nx" > critical< / span > < span class = "nx" > line< / span > < span class = "p" > :< / span > < span class = "nx" > crit< / span > < span class = "p" > ,< / span > < span class = "mi" > 5< / span > < span class = "nx" > d< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Create< / span > < span class = "nx" > tests< / span > < span class = "k" > for< / span > < span class = "nx" > renderer< / span > < span class = "p" > :< / span > < span class = "mi" > 2< / span > < span class = "nx" > d< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Add< / span > < span class = "nx" > to< / span > < span class = "nx" > Mermaid< / span > < span class = "p" > :< / span > < span class = "mi" > 1< / span > < span class = "nx" > d< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-11-18 22:20:02 +00:00
< pre class = "mermaid align-center zoomable" >
2022-06-05 17:32:37 +00:00
gantt
dateFormat YYYY-MM-DD
title Adding GANTT diagram functionality to Mermaid
section A section
Completed task :done, des1, 2014-01-06,2014-01-08
Active task :active, des2, 2014-01-09, 3d
Future task : des3, after des2, 5d
Future task2 : des4, after des3, 5d
section Critical tasks
Completed task in the critical line :crit, done, 2014-01-06,24h
Implement parser and jison :crit, done, after des1, 2d
Create tests for parser :crit, active, 3d
Future task in critical line :crit, 5d
Create tests for renderer :2d
Add to Mermaid :1d
2023-09-30 19:51:47 +00:00
< / pre >
2023-02-05 10:13:50 +00:00
< h3 id = "pie-chart-without-zoom" > Pie Chart without Zoom< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > mermaid< / span > < span class = "nx" > zoom< / span > < span class = "p" > =< / span > < span class = "s" > " false" < / span > < span class = "p" > > }}< / span >
2022-11-18 23:02:20 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > pie< / span > < span class = "nx" > title< / span > < span class = "nx" > Pets< / span > < span class = "nx" > adopted< / span > < span class = "nx" > by< / span > < span class = "nx" > volunteers< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " Dogs" < / span > < span class = "p" > :< / span > < span class = "mi" > 386< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " Cats" < / span > < span class = "p" > :< / span > < span class = "mi" > 85< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " Rats" < / span > < span class = "p" > :< / span > < span class = "mi" > 15< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-09-30 19:51:47 +00:00
< pre class = "mermaid align-center" >
2022-11-18 23:02:20 +00:00
pie title Pets adopted by volunteers
" Dogs" : 386
" Cats" : 85
" Rats" : 15
2023-09-30 19:51:47 +00:00
< / pre >
2023-08-11 17:57:56 +00:00
< h3 id = "quadrant-chart" > Quadrant Chart< / h3 >
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > pie< / span > < span class = "nx" > title< / span > < span class = "nx" > Pets< / span > < span class = "nx" > adopted< / span > < span class = "nx" > by< / span > < span class = "nx" > volunteers< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > title< / span > < span class = "nx" > Reach< / span > < span class = "nx" > and< / span > < span class = "nx" > engagement< / span > < span class = "nx" > of< / span > < span class = "nx" > campaigns< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > x< / span > < span class = "o" > -< / span > < span class = "nx" > axis< / span > < span class = "nx" > Low< / span > < span class = "nx" > Reach< / span > < span class = "o" > --< / span > < span class = "p" > > < / span > < span class = "nx" > High< / span > < span class = "nx" > Reach< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > y< / span > < span class = "o" > -< / span > < span class = "nx" > axis< / span > < span class = "nx" > Low< / span > < span class = "nx" > Engagement< / span > < span class = "o" > --< / span > < span class = "p" > > < / span > < span class = "nx" > High< / span > < span class = "nx" > Engagement< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > quadrant< / span > < span class = "o" > -< / span > < span class = "mi" > 1< / span > < span class = "nx" > We< / span > < span class = "nx" > should< / span > < span class = "nx" > expand< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > quadrant< / span > < span class = "o" > -< / span > < span class = "mi" > 2< / span > < span class = "nx" > Need< / span > < span class = "nx" > to< / span > < span class = "nx" > promote< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > quadrant< / span > < span class = "o" > -< / span > < span class = "mi" > 3< / span > < span class = "nx" > Re< / span > < span class = "o" > -< / span > < span class = "nx" > evaluate< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > quadrant< / span > < span class = "o" > -< / span > < span class = "mi" > 4< / span > < span class = "nx" > May< / span > < span class = "nx" > be< / span > < span class = "nx" > improved< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Campaign< / span > < span class = "nx" > A< / span > < span class = "p" > :< / span > < span class = "p" > [< / span > < span class = "mf" > 0.3< / span > < span class = "p" > ,< / span > < span class = "mf" > 0.6< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Campaign< / span > < span class = "nx" > B< / span > < span class = "p" > :< / span > < span class = "p" > [< / span > < span class = "mf" > 0.45< / span > < span class = "p" > ,< / span > < span class = "mf" > 0.23< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Campaign< / span > < span class = "nx" > C< / span > < span class = "p" > :< / span > < span class = "p" > [< / span > < span class = "mf" > 0.57< / span > < span class = "p" > ,< / span > < span class = "mf" > 0.69< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Campaign< / span > < span class = "nx" > D< / span > < span class = "p" > :< / span > < span class = "p" > [< / span > < span class = "mf" > 0.78< / span > < span class = "p" > ,< / span > < span class = "mf" > 0.34< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Campaign< / span > < span class = "nx" > E< / span > < span class = "p" > :< / span > < span class = "p" > [< / span > < span class = "mf" > 0.40< / span > < span class = "p" > ,< / span > < span class = "mf" > 0.34< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Campaign< / span > < span class = "nx" > F< / span > < span class = "p" > :< / span > < span class = "p" > [< / span > < span class = "mf" > 0.35< / span > < span class = "p" > ,< / span > < span class = "mf" > 0.78< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-11-18 22:20:02 +00:00
< pre class = "mermaid align-center zoomable" >
2023-08-11 17:57:56 +00:00
quadrantChart
title Reach and engagement of campaigns
x-axis Low Reach --> High Reach
y-axis Low Engagement --> High Engagement
quadrant-1 We should expand
quadrant-2 Need to promote
quadrant-3 Re-evaluate
quadrant-4 May be improved
Campaign A: [0.3, 0.6]
Campaign B: [0.45, 0.23]
Campaign C: [0.57, 0.69]
Campaign D: [0.78, 0.34]
Campaign E: [0.40, 0.34]
Campaign F: [0.35, 0.78]
2023-09-30 19:51:47 +00:00
< / pre >
2022-11-18 23:02:20 +00:00
< h3 id = "requirement-diagram" > Requirement Diagram< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span >
2022-11-18 23:02:20 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > requirementDiagram< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > requirement< / span > < span class = "nx" > test_req< / span > < span class = "p" > {< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > id< / span > < span class = "p" > :< / span > < span class = "mi" > 1< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > text< / span > < span class = "p" > :< / span > < span class = "nx" > the< / span > < span class = "nx" > test< / span > < span class = "nx" > text< / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > risk< / span > < span class = "p" > :< / span > < span class = "nx" > high< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > verifymethod< / span > < span class = "p" > :< / span > < span class = "nx" > test< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > }< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > element< / span > < span class = "nx" > test_entity< / span > < span class = "p" > {< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "kd" > type< / span > < span class = "p" > :< / span > < span class = "nx" > simulation< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > }< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > test_entity< / span > < span class = "o" > -< / span > < span class = "nx" > satisfies< / span > < span class = "o" > -< / span > < span class = "p" > > < / span > < span class = "nx" > test_req< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-11-18 22:20:02 +00:00
< pre class = "mermaid align-center zoomable" >
2022-11-18 23:02:20 +00:00
requirementDiagram
requirement test_req {
id: 1
text: the test text.
risk: high
verifymethod: test
}
element test_entity {
type: simulation
}
test_entity - satisfies -> test_req
2023-09-30 19:51:47 +00:00
< / pre >
2022-11-17 22:36:34 +00:00
< h3 id = "git-graph" > Git Graph< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span >
2022-11-17 22:36:34 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > gitGraph< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > commit< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > commit< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > branch< / span > < span class = "nx" > develop< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > checkout< / span > < span class = "nx" > develop< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > commit< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > commit< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > checkout< / span > < span class = "nx" > main< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > merge< / span > < span class = "nx" > develop< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > commit< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > commit< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-11-18 22:20:02 +00:00
< pre class = "mermaid align-center zoomable" >
2022-11-17 22:36:34 +00:00
gitGraph
commit
commit
branch develop
checkout develop
commit
commit
checkout main
merge develop
commit
commit
2023-09-30 19:51:47 +00:00
< / pre >
2022-11-18 23:02:20 +00:00
< h3 id = "c4-diagrams" > C4 Diagrams< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span >
2022-11-18 23:02:20 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > C4Context< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > title< / span > < span class = "nx" > System< / span > < span class = "nx" > Context< / span > < span class = "nx" > diagram< / span > < span class = "k" > for< / span > < span class = "nx" > Internet< / span > < span class = "nx" > Banking< / span > < span class = "nx" > System< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > Enterprise_Boundary< / span > < span class = "p" > (< / span > < span class = "nx" > b0< / span > < span class = "p" > ,< / span > < span class = "s" > " BankBoundary0" < / span > < span class = "p" > )< / span > < span class = "p" > {< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > Person< / span > < span class = "p" > (< / span > < span class = "nx" > customerA< / span > < span class = "p" > ,< / span > < span class = "s" > " Banking Customer A" < / span > < span class = "p" > ,< / span > < span class = "s" > " A customer of the bank, with personal bank accounts." < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > Person< / span > < span class = "p" > (< / span > < span class = "nx" > customerB< / span > < span class = "p" > ,< / span > < span class = "s" > " Banking Customer B" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > Person_Ext< / span > < span class = "p" > (< / span > < span class = "nx" > customerC< / span > < span class = "p" > ,< / span > < span class = "s" > " Banking Customer C" < / span > < span class = "p" > ,< / span > < span class = "s" > " desc" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > Person< / span > < span class = "p" > (< / span > < span class = "nx" > customerD< / span > < span class = "p" > ,< / span > < span class = "s" > " Banking Customer D" < / span > < span class = "p" > ,< / span > < span class = "s" > " A customer of the bank, < br/> with personal bank accounts." < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > System< / span > < span class = "p" > (< / span > < span class = "nx" > SystemAA< / span > < span class = "p" > ,< / span > < span class = "s" > " Internet Banking System" < / span > < span class = "p" > ,< / span > < span class = "s" > " Allows customers to view information about their bank accounts, and make payments." < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > Enterprise_Boundary< / span > < span class = "p" > (< / span > < span class = "nx" > b1< / span > < span class = "p" > ,< / span > < span class = "s" > " BankBoundary" < / span > < span class = "p" > )< / span > < span class = "p" > {< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > SystemDb_Ext< / span > < span class = "p" > (< / span > < span class = "nx" > SystemE< / span > < span class = "p" > ,< / span > < span class = "s" > " Mainframe Banking System" < / span > < span class = "p" > ,< / span > < span class = "s" > " Stores all of the core banking information about customers, accounts, transactions, etc." < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > System_Boundary< / span > < span class = "p" > (< / span > < span class = "nx" > b2< / span > < span class = "p" > ,< / span > < span class = "s" > " BankBoundary2" < / span > < span class = "p" > )< / span > < span class = "p" > {< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > System< / span > < span class = "p" > (< / span > < span class = "nx" > SystemA< / span > < span class = "p" > ,< / span > < span class = "s" > " Banking System A" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > System< / span > < span class = "p" > (< / span > < span class = "nx" > SystemB< / span > < span class = "p" > ,< / span > < span class = "s" > " Banking System B" < / span > < span class = "p" > ,< / span > < span class = "s" > " A system of the bank, with personal bank accounts. next line." < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > }< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > System_Ext< / span > < span class = "p" > (< / span > < span class = "nx" > SystemC< / span > < span class = "p" > ,< / span > < span class = "s" > " E-mail system" < / span > < span class = "p" > ,< / span > < span class = "s" > " The internal Microsoft Exchange e-mail system." < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > SystemDb< / span > < span class = "p" > (< / span > < span class = "nx" > SystemD< / span > < span class = "p" > ,< / span > < span class = "s" > " Banking System D Database" < / span > < span class = "p" > ,< / span > < span class = "s" > " A system of the bank, with personal bank accounts." < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > Boundary< / span > < span class = "p" > (< / span > < span class = "nx" > b3< / span > < span class = "p" > ,< / span > < span class = "s" > " BankBoundary3" < / span > < span class = "p" > ,< / span > < span class = "s" > " boundary" < / span > < span class = "p" > )< / span > < span class = "p" > {< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > SystemQueue< / span > < span class = "p" > (< / span > < span class = "nx" > SystemF< / span > < span class = "p" > ,< / span > < span class = "s" > " Banking System F Queue" < / span > < span class = "p" > ,< / span > < span class = "s" > " A system of the bank." < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > SystemQueue_Ext< / span > < span class = "p" > (< / span > < span class = "nx" > SystemG< / span > < span class = "p" > ,< / span > < span class = "s" > " Banking System G Queue" < / span > < span class = "p" > ,< / span > < span class = "s" > " A system of the bank, with personal bank accounts." < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > }< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > }< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > }< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > BiRel< / span > < span class = "p" > (< / span > < span class = "nx" > customerA< / span > < span class = "p" > ,< / span > < span class = "nx" > SystemAA< / span > < span class = "p" > ,< / span > < span class = "s" > " Uses" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > BiRel< / span > < span class = "p" > (< / span > < span class = "nx" > SystemAA< / span > < span class = "p" > ,< / span > < span class = "nx" > SystemE< / span > < span class = "p" > ,< / span > < span class = "s" > " Uses" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > Rel< / span > < span class = "p" > (< / span > < span class = "nx" > SystemAA< / span > < span class = "p" > ,< / span > < span class = "nx" > SystemC< / span > < span class = "p" > ,< / span > < span class = "s" > " Sends e-mails" < / span > < span class = "p" > ,< / span > < span class = "s" > " SMTP" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > Rel< / span > < span class = "p" > (< / span > < span class = "nx" > SystemC< / span > < span class = "p" > ,< / span > < span class = "nx" > customerA< / span > < span class = "p" > ,< / span > < span class = "s" > " Sends e-mails to" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > UpdateElementStyle< / span > < span class = "p" > (< / span > < span class = "nx" > customerA< / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > fontColor< / span > < span class = "p" > =< / span > < span class = "s" > " red" < / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > bgColor< / span > < span class = "p" > =< / span > < span class = "s" > " grey" < / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > borderColor< / span > < span class = "p" > =< / span > < span class = "s" > " red" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > UpdateRelStyle< / span > < span class = "p" > (< / span > < span class = "nx" > customerA< / span > < span class = "p" > ,< / span > < span class = "nx" > SystemAA< / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > textColor< / span > < span class = "p" > =< / span > < span class = "s" > " blue" < / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > lineColor< / span > < span class = "p" > =< / span > < span class = "s" > " blue" < / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > offsetX< / span > < span class = "p" > =< / span > < span class = "s" > " 5" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > UpdateRelStyle< / span > < span class = "p" > (< / span > < span class = "nx" > SystemAA< / span > < span class = "p" > ,< / span > < span class = "nx" > SystemE< / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > textColor< / span > < span class = "p" > =< / span > < span class = "s" > " blue" < / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > lineColor< / span > < span class = "p" > =< / span > < span class = "s" > " blue" < / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > offsetY< / span > < span class = "p" > =< / span > < span class = "s" > " -10" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > UpdateRelStyle< / span > < span class = "p" > (< / span > < span class = "nx" > SystemAA< / span > < span class = "p" > ,< / span > < span class = "nx" > SystemC< / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > textColor< / span > < span class = "p" > =< / span > < span class = "s" > " blue" < / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > lineColor< / span > < span class = "p" > =< / span > < span class = "s" > " blue" < / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > offsetY< / span > < span class = "p" > =< / span > < span class = "s" > " -40" < / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > offsetX< / span > < span class = "p" > =< / span > < span class = "s" > " -50" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > UpdateRelStyle< / span > < span class = "p" > (< / span > < span class = "nx" > SystemC< / span > < span class = "p" > ,< / span > < span class = "nx" > customerA< / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > textColor< / span > < span class = "p" > =< / span > < span class = "s" > " red" < / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > lineColor< / span > < span class = "p" > =< / span > < span class = "s" > " red" < / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > offsetX< / span > < span class = "p" > =< / span > < span class = "s" > " -50" < / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > offsetY< / span > < span class = "p" > =< / span > < span class = "s" > " 20" < / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > UpdateLayoutConfig< / span > < span class = "p" > (< / span > < span class = "err" > $< / span > < span class = "nx" > c4ShapeInRow< / span > < span class = "p" > =< / span > < span class = "s" > " 3" < / span > < span class = "p" > ,< / span > < span class = "err" > $< / span > < span class = "nx" > c4BoundaryInRow< / span > < span class = "p" > =< / span > < span class = "s" > " 1" < / span > < span class = "p" > )< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-11-18 22:20:02 +00:00
< pre class = "mermaid align-center zoomable" >
2022-11-18 23:02:20 +00:00
C4Context
title System Context diagram for Internet Banking System
Enterprise_Boundary(b0, " BankBoundary0" ) {
Person(customerA, " Banking Customer A" , " A customer of the bank, with personal bank accounts." )
Person(customerB, " Banking Customer B" )
Person_Ext(customerC, " Banking Customer C" , " desc" )
Person(customerD, " Banking Customer D" , " A customer of the bank, < br/> with personal bank accounts." )
System(SystemAA, " Internet Banking System" , " Allows customers to view information about their bank accounts, and make payments." )
Enterprise_Boundary(b1, " BankBoundary" ) {
SystemDb_Ext(SystemE, " Mainframe Banking System" , " Stores all of the core banking information about customers, accounts, transactions, etc." )
System_Boundary(b2, " BankBoundary2" ) {
System(SystemA, " Banking System A" )
System(SystemB, " Banking System B" , " A system of the bank, with personal bank accounts. next line." )
}
System_Ext(SystemC, " E-mail system" , " The internal Microsoft Exchange e-mail system." )
SystemDb(SystemD, " Banking System D Database" , " A system of the bank, with personal bank accounts." )
Boundary(b3, " BankBoundary3" , " boundary" ) {
SystemQueue(SystemF, " Banking System F Queue" , " A system of the bank." )
SystemQueue_Ext(SystemG, " Banking System G Queue" , " A system of the bank, with personal bank accounts." )
}
}
}
BiRel(customerA, SystemAA, " Uses" )
BiRel(SystemAA, SystemE, " Uses" )
Rel(SystemAA, SystemC, " Sends e-mails" , " SMTP" )
Rel(SystemC, customerA, " Sends e-mails to" )
UpdateElementStyle(customerA, $fontColor=" red" , $bgColor=" grey" , $borderColor=" red" )
UpdateRelStyle(customerA, SystemAA, $textColor=" blue" , $lineColor=" blue" , $offsetX=" 5" )
UpdateRelStyle(SystemAA, SystemE, $textColor=" blue" , $lineColor=" blue" , $offsetY=" -10" )
UpdateRelStyle(SystemAA, SystemC, $textColor=" blue" , $lineColor=" blue" , $offsetY=" -40" , $offsetX=" -50" )
UpdateRelStyle(SystemC, customerA, $textColor=" red" , $lineColor=" red" , $offsetX=" -50" , $offsetY=" 20" )
UpdateLayoutConfig($c4ShapeInRow=" 3" , $c4BoundaryInRow=" 1" )
2023-09-30 19:51:47 +00:00
< / pre >
2023-05-25 10:46:07 +00:00
< h3 id = "mindmaps" > Mindmaps< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span >
2023-05-25 10:46:07 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > mindmap< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nf" > root< / span > < span class = "p" > ((< / span > < span class = "nx" > mindmap< / span > < span class = "p" > ))< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Origins< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Long< / span > < span class = "nx" > history< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > ::< / span > < span class = "nf" > icon< / span > < span class = "p" > (< / span > < span class = "nx" > fa< / span > < span class = "nx" > fa< / span > < span class = "o" > -< / span > < span class = "nx" > book< / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Popularisation< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > British< / span > < span class = "nx" > popular< / span > < span class = "nx" > psychology< / span > < span class = "nx" > author< / span > < span class = "nx" > Tony< / span > < span class = "nx" > Buzan< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Research< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > On< / span > < span class = "nx" > effectiveness< / span > < span class = "p" > < < / span > < span class = "nx" > br< / span > < span class = "o" > /< / span > < span class = "p" > > < / span > < span class = "nx" > and< / span > < span class = "nx" > features< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > On< / span > < span class = "nx" > Automatic< / span > < span class = "nx" > creation< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Uses< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Creative< / span > < span class = "nx" > techniques< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Strategic< / span > < span class = "nx" > planning< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Argument< / span > < span class = "nx" > mapping< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Tools< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Pen< / span > < span class = "nx" > and< / span > < span class = "nx" > paper< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Mermaid< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-11-18 22:20:02 +00:00
< pre class = "mermaid align-center zoomable" >
2023-05-25 10:46:07 +00:00
mindmap
root((mindmap))
Origins
Long history
::icon(fa fa-book)
Popularisation
British popular psychology author Tony Buzan
Research
On effectiveness< br/> and features
On Automatic creation
Uses
Creative techniques
Strategic planning
Argument mapping
Tools
Pen and paper
Mermaid
2023-09-30 19:51:47 +00:00
< / pre >
2023-05-25 10:46:07 +00:00
< h3 id = "timeline" > Timeline< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span >
2023-05-25 10:46:07 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > timeline< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > title< / span > < span class = "nx" > History< / span > < span class = "nx" > of< / span > < span class = "nx" > Social< / span > < span class = "nx" > Media< / span > < span class = "nx" > Platform< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "mi" > 2002< / span > < span class = "p" > :< / span > < span class = "nx" > LinkedIn< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "mi" > 2004< / span > < span class = "p" > :< / span > < span class = "nx" > Facebook< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > :< / span > < span class = "nx" > Google< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "mi" > 2005< / span > < span class = "p" > :< / span > < span class = "nx" > Youtube< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "mi" > 2006< / span > < span class = "p" > :< / span > < span class = "nx" > Twitter< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-11-18 22:20:02 +00:00
< pre class = "mermaid align-center zoomable" >
2023-05-25 10:46:07 +00:00
timeline
title History of Social Media Platform
2002 : LinkedIn
2004 : Facebook
: Google
2005 : Youtube
2006 : Twitter
2023-09-30 19:51:47 +00:00
< / pre >
2023-08-05 12:37:25 +00:00
< h3 id = "sankey" > Sankey< / h3 >
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > sankey< / span > < span class = "o" > -< / span > < span class = "nx" > beta< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "o" > %%< / span > < span class = "nx" > source< / span > < span class = "p" > ,< / span > < span class = "nx" > target< / span > < span class = "p" > ,< / span > < span class = "nx" > value< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Electricity< / span > < span class = "nx" > grid< / span > < span class = "p" > ,< / span > < span class = "nx" > Over< / span > < span class = "nx" > generation< / span > < span class = "o" > /< / span > < span class = "nx" > exports< / span > < span class = "p" > ,< / span > < span class = "mf" > 104.453< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Electricity< / span > < span class = "nx" > grid< / span > < span class = "p" > ,< / span > < span class = "nx" > Heating< / span > < span class = "nx" > and< / span > < span class = "nx" > cooling< / span > < span class = "o" > -< / span > < span class = "nx" > homes< / span > < span class = "p" > ,< / span > < span class = "mf" > 113.726< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Electricity< / span > < span class = "nx" > grid< / span > < span class = "p" > ,< / span > < span class = "nx" > H2< / span > < span class = "nx" > conversion< / span > < span class = "p" > ,< / span > < span class = "mf" > 27.14< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-11-18 22:20:02 +00:00
< pre class = "mermaid align-center zoomable" >
2023-08-05 12:37:25 +00:00
sankey-beta
%% source,target,value
Electricity grid,Over generation / exports,104.453
Electricity grid,Heating and cooling - homes,113.726
Electricity grid,H2 conversion,27.14
2023-10-29 17:51:28 +00:00
< / pre >
< h2 id = "xychart" > XYChart< / h2 >
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > xychart< / span > < span class = "o" > -< / span > < span class = "nx" > beta< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > title< / span > < span class = "s" > " Sales Revenue" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > x< / span > < span class = "o" > -< / span > < span class = "nx" > axis< / span > < span class = "p" > [< / span > < span class = "nx" > jan< / span > < span class = "p" > ,< / span > < span class = "nx" > feb< / span > < span class = "p" > ,< / span > < span class = "nx" > mar< / span > < span class = "p" > ,< / span > < span class = "nx" > apr< / span > < span class = "p" > ,< / span > < span class = "nx" > may< / span > < span class = "p" > ,< / span > < span class = "nx" > jun< / span > < span class = "p" > ,< / span > < span class = "nx" > jul< / span > < span class = "p" > ,< / span > < span class = "nx" > aug< / span > < span class = "p" > ,< / span > < span class = "nx" > sep< / span > < span class = "p" > ,< / span > < span class = "nx" > oct< / span > < span class = "p" > ,< / span > < span class = "nx" > nov< / span > < span class = "p" > ,< / span > < span class = "nx" > dec< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > y< / span > < span class = "o" > -< / span > < span class = "nx" > axis< / span > < span class = "s" > " Revenue (in $)" < / span > < span class = "mi" > 4000< / span > < span class = "o" > --< / span > < span class = "p" > > < / span > < span class = "mi" > 11000< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > bar< / span > < span class = "p" > [< / span > < span class = "mi" > 5000< / span > < span class = "p" > ,< / span > < span class = "mi" > 6000< / span > < span class = "p" > ,< / span > < span class = "mi" > 7500< / span > < span class = "p" > ,< / span > < span class = "mi" > 8200< / span > < span class = "p" > ,< / span > < span class = "mi" > 9500< / span > < span class = "p" > ,< / span > < span class = "mi" > 10500< / span > < span class = "p" > ,< / span > < span class = "mi" > 11000< / span > < span class = "p" > ,< / span > < span class = "mi" > 10200< / span > < span class = "p" > ,< / span > < span class = "mi" > 9200< / span > < span class = "p" > ,< / span > < span class = "mi" > 8500< / span > < span class = "p" > ,< / span > < span class = "mi" > 7000< / span > < span class = "p" > ,< / span > < span class = "mi" > 6000< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > line< / span > < span class = "p" > [< / span > < span class = "mi" > 5000< / span > < span class = "p" > ,< / span > < span class = "mi" > 6000< / span > < span class = "p" > ,< / span > < span class = "mi" > 7500< / span > < span class = "p" > ,< / span > < span class = "mi" > 8200< / span > < span class = "p" > ,< / span > < span class = "mi" > 9500< / span > < span class = "p" > ,< / span > < span class = "mi" > 10500< / span > < span class = "p" > ,< / span > < span class = "mi" > 11000< / span > < span class = "p" > ,< / span > < span class = "mi" > 10200< / span > < span class = "p" > ,< / span > < span class = "mi" > 9200< / span > < span class = "p" > ,< / span > < span class = "mi" > 8500< / span > < span class = "p" > ,< / span > < span class = "mi" > 7000< / span > < span class = "p" > ,< / span > < span class = "mi" > 6000< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > mermaid< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-11-18 22:20:02 +00:00
< pre class = "mermaid align-center zoomable" >
2023-10-29 17:51:28 +00:00
xychart-beta
title " Sales Revenue"
x-axis [jan, feb, mar, apr, may, jun, jul, aug, sep, oct, nov, dec]
y-axis " Revenue (in $)" 4000 --> 11000
bar [5000, 6000, 7500, 8200, 9500, 10500, 11000, 10200, 9200, 8500, 7000, 6000]
line [5000, 6000, 7500, 8200, 9500, 10500, 11000, 10200, 9200, 8500, 7000, 6000]
2023-09-30 19:51:47 +00:00
< / pre >
2022-11-17 22:36:34 +00:00
2022-04-02 13:30:16 +00:00
< footer class = "footline" >
< / footer >
< / article >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
< / header >
2022-11-13 21:34:47 +00:00
< h1 id = "notice" > Notice< / h1 >
2022-07-05 22:16:52 +00:00
2022-05-28 11:35:09 +00:00
< p > The < code > notice< / code > shortcode shows various types of disclaimers with adjustable color, title and icon to help you structure your page.< / p >
2023-06-03 22:20:43 +00:00
2022-05-29 21:00:53 +00:00
< div class = "box notices cstyle primary" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > < i class = "fa-fw fas fa-skull-crossbones" > < / i > There may be pirates< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-05-23 22:38:50 +00:00
< p > It is all about the boxes.< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-05-23 22:38:50 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< h2 id = "usage" > Usage< / h2 >
2022-10-31 14:06:51 +00:00
< p > While the examples are using shortcodes with named parameter you are free to use positional as well or also call this shortcode from your own partials.< / p >
2022-05-23 22:38:50 +00:00
2023-07-27 15:06:14 +00:00
< div class = "tab-panel" data-tab-group = "shortcode-parameter" >
2022-05-23 22:38:50 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-05-23 22:38:50 +00:00
< button
2022-06-22 22:08:50 +00:00
data-tab-item="shortcode"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','shortcode')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-05-23 22:38:50 +00:00
< button
2023-09-05 11:10:04 +00:00
data-tab-item="shortcode-positional"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-09-05 11:10:04 +00:00
onclick="switchTab('shortcode-parameter','shortcode-positional')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode (positional)< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-22 22:08:50 +00:00
< button
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','partial')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > partial< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-05-23 22:38:50 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="shortcode"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " primary" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " There may be pirates" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " skull-crossbones" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-05-23 22:38:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > It< / span > < span class = "nx" > is< / span > < span class = "nx" > all< / span > < span class = "nx" > about< / span > < span class = "nx" > the< / span > < span class = "nx" > boxes< / span > < span class = "p" > .< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
2023-09-05 11:10:04 +00:00
data-tab-item="shortcode-positional"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > primary< / span > < span class = "s" > " There may be pirates" < / span > < span class = "s" > " skull-crossbones" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-05-23 22:38:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > It< / span > < span class = "nx" > is< / span > < span class = "nx" > all< / span > < span class = "nx" > about< / span > < span class = "nx" > the< / span > < span class = "nx" > boxes< / span > < span class = "p" > .< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/notice.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2022-06-22 22:08:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " style" < / span > < span class = "s" > " primary" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " title" < / span > < span class = "s" > " There may be pirates" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " icon" < / span > < span class = "s" > " skull-crossbones" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "s" > " It is all about the boxes." < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-05-23 22:38:50 +00:00
< / div >
< / div >
< h3 id = "parameter" > Parameter< / h3 >
< table >
< thead >
< tr >
2023-07-27 15:06:14 +00:00
< th > Name< / th >
< th > Position< / th >
< th > Default< / th >
< th > Notes< / th >
2022-05-23 22:38:50 +00:00
< / tr >
< / thead >
< tbody >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > style< / strong > < / td >
< td > 1< / td >
< td > < code > default< / code > < / td >
< td > The style scheme used for the box.< br > < br > - by severity: < code > info< / code > , < code > note< / code > , < code > tip< / code > , < code > warning< / code > < br > - by brand color: < code > primary< / code > , < code > secondary< / code > , < code > accent< / code > < br > - by color: < code > blue< / code > , < code > green< / code > , < code > grey< / code > , < code > orange< / code > , < code > red< / code > < br > - by special color: < code > default< / code > , < code > transparent< / code > , < code > code< / code > < / td >
2023-01-23 22:49:15 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > color< / strong > < / td >
< td > < / td >
< td > see notes< / td >
2023-10-28 20:28:18 +00:00
< td > The < a href = "https://developer.mozilla.org/en-US/docs/Web/CSS/color_value" target = "_blank" > CSS color value< / a > to be used. If not set, the chosen color depends on the < strong > style< / strong > . Any given value will overwrite the default.< br > < br > - for severity styles: a nice matching color for the severity< br > - for all other styles: the corresponding color< / td >
2022-05-23 22:38:50 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > title< / strong > < / td >
< td > 2< / td >
< td > see notes< / td >
< td > Arbitrary text for the box title. Depending on the < strong > style< / strong > there may be a default title. Any given value will overwrite the default.< br > < br > - for severity styles: the matching title for the severity< br > - for all other styles: < em > < empty> < / em > < br > < br > If you want no title for a severity style, you have to set this parameter to < code > " " < / code > (a non empty string filled with spaces)< / td >
2022-05-23 22:38:50 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > icon< / strong > < / td >
< td > 3< / td >
< td > see notes< / td >
2023-10-28 20:28:18 +00:00
< td > < a href = "../shortcodes/icon/index.html#finding-an-icon" > Font Awesome icon name< / a > set to the left of the title. Depending on the < strong > style< / strong > there may be a default icon. Any given value will overwrite the default.< br > < br > - for severity styles: a nice matching icon for the severity< br > - for all other styles: < em > < empty> < / em > < br > < br > If you want no icon for a severity style, you have to set this parameter to < code > " " < / code > (a non empty string filled with spaces)< / td >
2022-05-23 22:38:50 +00:00
< / tr >
2022-06-22 22:08:50 +00:00
< tr >
2023-07-27 15:06:14 +00:00
< td > < em > < strong > < content> < / strong > < / em > < / td >
< td > < / td >
< td > < em > < empty> < / em > < / td >
< td > Arbitrary text to be displayed in box.< / td >
2022-06-22 22:08:50 +00:00
< / tr >
2022-05-23 22:38:50 +00:00
< / tbody >
< / table >
2022-04-02 13:30:16 +00:00
< h2 id = "examples" > Examples< / h2 >
2022-05-23 22:38:50 +00:00
< h3 id = "by-severity" > By Severity< / h3 >
< h4 id = "info-with-markup" > Info with markup< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " info" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-05-23 22:38:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > An< / span > < span class = "o" > **< / span > < span class = "nx" > information< / span > < span class = "o" > **< / span > < span class = "nx" > disclaimer< / span >
2022-04-02 13:30:16 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" >
2022-05-23 13:00:05 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > You< / span > < span class = "nx" > can< / span > < span class = "nx" > add< / span > < span class = "nx" > standard< / span > < span class = "nx" > markdown< / span > < span class = "nx" > syntax< / span > < span class = "p" > :< / span >
2022-04-02 13:30:16 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "o" > -< / span > < span class = "nx" > multiple< / span > < span class = "nx" > paragraphs< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "o" > -< / span > < span class = "nx" > bullet< / span > < span class = "nx" > point< / span > < span class = "nx" > lists< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "o" > -< / span > < span class = "nx" > _emphasized_< / span > < span class = "p" > ,< / span > < span class = "o" > **< / span > < span class = "nx" > bold< / span > < span class = "o" > **< / span > < span class = "nx" > and< / span > < span class = "nx" > even< / span > < span class = "o" > ***< / span > < span class = "nx" > bold< / span > < span class = "nx" > emphasized< / span > < span class = "o" > ***< / span > < span class = "nx" > text< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "o" > -< / span > < span class = "p" > [< / span > < span class = "nx" > links< / span > < span class = "p" > ](< / span > < span class = "nx" > https< / span > < span class = "p" > :< / span > < span class = "c1" > //example.com)
2022-05-23 13:00:05 +00:00
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "c1" > < / span > < span class = "o" > -< / span > < span class = "nx" > etc< / span > < span class = "p" > .< / span >
2022-04-02 13:30:16 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```plaintext
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ...and even source code
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
2022-10-31 14:06:51 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > > < / span > < span class = "nx" > the< / span > < span class = "nx" > possibilities< / span > < span class = "nx" > are< / span > < span class = "nf" > endless< / span > < span class = "p" > (< / span > < span class = "nx" > almost< / span > < span class = "o" > -< / span > < span class = "nx" > including< / span > < span class = "nx" > other< / span > < span class = "nx" > shortcodes< / span > < span class = "nx" > may< / span > < span class = "nx" > or< / span > < span class = "nx" > may< / span > < span class = "nx" > not< / span > < span class = "nx" > work< / span > < span class = "p" > )< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle info" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > < i class = "fa-fw fas fa-info-circle" > < / i > Info< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-06-07 18:30:50 +00:00
< p > An < strong > information< / strong > disclaimer< / p >
< p > You can add standard markdown syntax:< / p >
< ul >
< li > multiple paragraphs< / li >
< li > bullet point lists< / li >
< li > < em > emphasized< / em > , < strong > bold< / strong > and even < strong > < em > bold emphasized< / em > < / strong > text< / li >
2023-10-28 20:28:18 +00:00
< li > < a href = "https://example.com" target = "_blank" > links< / a > < / li >
2022-06-07 18:30:50 +00:00
< li > etc.< / li >
< / ul >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-plaintext" data-lang = "plaintext" > < span class = "line" > < span class = "cl" > ...and even source code< / span > < / span > < / code > < / pre > < / div > < blockquote >
2022-10-31 14:06:51 +00:00
< p > the possibilities are endless (almost - including other shortcodes may or may not work)< / p >
2022-06-07 18:30:50 +00:00
< / blockquote >
2023-06-03 09:12:46 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< / div >
2022-06-07 18:30:50 +00:00
< h4 id = "note" > Note< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " note" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-05-23 22:38:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > A< / span > < span class = "o" > **< / span > < span class = "nx" > notice< / span > < span class = "o" > **< / span > < span class = "nx" > disclaimer< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle note" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > < i class = "fa-fw fas fa-exclamation-circle" > < / i > Note< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-06-07 18:30:50 +00:00
< p > A < strong > notice< / strong > disclaimer< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< / div >
2022-05-23 22:38:50 +00:00
< h4 id = "tip" > Tip< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " tip" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > A< / span > < span class = "o" > **< / span > < span class = "nx" > tip< / span > < span class = "o" > **< / span > < span class = "nx" > disclaimer< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle tip" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > < i class = "fa-fw fas fa-lightbulb" > < / i > Tip< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-04-02 13:30:16 +00:00
< p > A < strong > tip< / strong > disclaimer< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< / div >
2022-05-23 22:38:50 +00:00
< h4 id = "warning" > Warning< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " warning" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-05-23 22:38:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > A< / span > < span class = "o" > **< / span > < span class = "nx" > warning< / span > < span class = "o" > **< / span > < span class = "nx" > disclaimer< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle warning" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > < i class = "fa-fw fas fa-exclamation-triangle" > < / i > Warning< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-05-23 22:38:50 +00:00
< p > A < strong > warning< / strong > disclaimer< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< / div >
2022-06-07 18:30:50 +00:00
< h4 id = "warning-with-non-default-title-and-icon" > Warning with Non-Default Title and Icon< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " warning" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Here are dragons" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " dragon" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-04-02 13:30:16 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > A< / span > < span class = "o" > **< / span > < span class = "nx" > warning< / span > < span class = "o" > **< / span > < span class = "nx" > disclaimer< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle warning" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > < i class = "fa-fw fas fa-dragon" > < / i > Here are dragons< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-05-23 22:38:50 +00:00
< p > A < strong > warning< / strong > disclaimer< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-05-23 22:38:50 +00:00
< / div >
2022-06-07 18:30:50 +00:00
< h4 id = "warning-without-a-title-and-icon" > Warning without a Title and Icon< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " warning" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " " < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " " < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-05-23 22:38:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > A< / span > < span class = "o" > **< / span > < span class = "nx" > warning< / span > < span class = "o" > **< / span > < span class = "nx" > disclaimer< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle warning" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > < / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-06-07 18:30:50 +00:00
< p > A < strong > warning< / strong > disclaimer< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-05-23 22:38:50 +00:00
< / div >
< h3 id = "by-brand-colors" > By Brand Colors< / h3 >
2022-06-05 17:32:37 +00:00
< h4 id = "primary-with-title-only" > Primary with Title only< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " primary" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Primary" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-06-07 18:30:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > A< / span > < span class = "o" > **< / span > < span class = "nx" > primary< / span > < span class = "o" > **< / span > < span class = "nx" > disclaimer< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle primary" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > Primary< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-05-23 22:38:50 +00:00
< p > A < strong > primary< / strong > disclaimer< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-05-23 22:38:50 +00:00
< / div >
2022-06-07 18:30:50 +00:00
< h4 id = "secondary-with-icon-only" > Secondary with Icon only< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " secondary" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " stopwatch" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-06-07 18:30:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > A< / span > < span class = "o" > **< / span > < span class = "nx" > secondary< / span > < span class = "o" > **< / span > < span class = "nx" > disclaimer< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle secondary" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > < i class = "fa-fw fas fa-stopwatch" > < / i > < / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-05-23 22:38:50 +00:00
< p > A < strong > secondary< / strong > disclaimer< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-05-23 22:38:50 +00:00
< / div >
2023-01-23 23:14:54 +00:00
< h4 id = "accent" > Accent< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " accent" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-01-23 23:14:54 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > An< / span > < span class = "o" > **< / span > < span class = "nx" > accent< / span > < span class = "o" > **< / span > < span class = "nx" > disclaimer< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle accent" >
2023-01-23 23:14:54 +00:00
< div class = "box-label" > < / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2023-01-23 23:14:54 +00:00
< p > An < strong > accent< / strong > disclaimer< / p >
2023-06-03 09:12:46 +00:00
< / div >
2023-01-23 23:14:54 +00:00
< / div >
2022-05-23 22:38:50 +00:00
< h3 id = "by-color" > By Color< / h3 >
2022-06-05 17:32:37 +00:00
< h4 id = "blue-without-a-title-and-icon" > Blue without a Title and Icon< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " blue" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-06-07 18:30:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > A< / span > < span class = "o" > **< / span > < span class = "nx" > blue< / span > < span class = "o" > **< / span > < span class = "nx" > disclaimer< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle blue" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > < / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-05-23 22:38:50 +00:00
< p > A < strong > blue< / strong > disclaimer< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-05-23 22:38:50 +00:00
< / div >
2022-06-07 18:30:50 +00:00
< h4 id = "green-with-title-only" > Green with Title only< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " green" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Green" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-06-07 18:30:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > A< / span > < span class = "o" > **< / span > < span class = "nx" > green< / span > < span class = "o" > **< / span > < span class = "nx" > disclaimer< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle green" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > Green< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-05-23 22:38:50 +00:00
< p > A < strong > green< / strong > disclaimer< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-05-23 22:38:50 +00:00
< / div >
2022-06-07 18:30:50 +00:00
< h4 id = "grey-with-icon-only" > Grey with Icon only< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " grey" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " bug" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-06-07 18:30:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > A< / span > < span class = "o" > **< / span > < span class = "nx" > grey< / span > < span class = "o" > **< / span > < span class = "nx" > disclaimer< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle grey" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > < i class = "fa-fw fas fa-bug" > < / i > < / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-05-23 22:38:50 +00:00
< p > A < strong > grey< / strong > disclaimer< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-05-23 22:38:50 +00:00
< / div >
2022-06-07 18:30:50 +00:00
< h4 id = "orange-with-title-and-icon" > Orange with Title and Icon< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " orange" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Orange" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " bug" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-06-07 18:30:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > A< / span > < span class = "o" > **< / span > < span class = "nx" > orange< / span > < span class = "o" > **< / span > < span class = "nx" > disclaimer< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle orange" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > < i class = "fa-fw fas fa-bug" > < / i > Orange< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-05-23 22:38:50 +00:00
< p > A < strong > orange< / strong > disclaimer< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-05-23 22:38:50 +00:00
< / div >
2023-01-14 00:40:32 +00:00
< h4 id = "red-without-a-title-and-icon" > Red without a Title and Icon< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " red" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-06-07 18:30:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > A< / span > < span class = "o" > **< / span > < span class = "nx" > red< / span > < span class = "o" > **< / span > < span class = "nx" > disclaimer< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle red" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > < / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-05-23 22:38:50 +00:00
< p > A < strong > red< / strong > disclaimer< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-05-23 22:38:50 +00:00
< / div >
< h3 id = "by-special-color" > By Special Color< / h3 >
2023-01-23 22:49:15 +00:00
< h4 id = "default-with-positional-parameter" > Default with Positional Parameter< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "k" > default< / span > < span class = "s" > " Pay Attention to this Note!" < / span > < span class = "s" > " skull-crossbones" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-05-23 22:38:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Some< / span > < span class = "nx" > serious< / span > < span class = "nx" > information< / span > < span class = "p" > .< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle default" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > < i class = "fa-fw fas fa-skull-crossbones" > < / i > Pay Attention to this Note!< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-05-23 22:38:50 +00:00
< p > Some serious information.< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< / div >
2022-06-07 18:30:50 +00:00
< h4 id = "transparent-with-title-and-icon" > Transparent with Title and Icon< / h4 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " transparent" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Pay Attention to this Note!" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " skull-crossbones" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-05-23 22:38:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Some< / span > < span class = "nx" > serious< / span > < span class = "nx" > information< / span > < span class = "p" > .< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle transparent" >
2022-12-01 00:38:08 +00:00
< div class = "box-label" > < i class = "fa-fw fas fa-skull-crossbones" > < / i > Pay Attention to this Note!< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2022-06-07 18:30:50 +00:00
< p > Some serious information.< / p >
2023-06-03 09:12:46 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< / div >
2023-03-14 20:49:22 +00:00
< h3 id = "with-user-defined-color-font-awesome-brand-icon-and-markdown-title" > With User-Defined Color, Font Awesome Brand Icon and Markdown Title< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > notice< / span > < span class = "nx" > color< / span > < span class = "p" > =< / span > < span class = "s" > " fuchsia" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " **Hugo**" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " fab fa-hackerrank" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-01-23 22:49:15 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Victor< / span > < span class = "err" > ?< / span > < span class = "nx" > Is< / span > < span class = "nx" > it< / span > < span class = "nx" > you< / span > < span class = "err" > ?< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > notice< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-03 22:20:43 +00:00
< div class = "box notices cstyle default" style = "--VARIABLE-BOX-color: fuchsia;" >
2023-03-14 20:49:22 +00:00
< div class = "box-label" > < i class = "fab fa-hackerrank" > < / i > < strong > Hugo< / strong > < / div >
2023-01-23 22:49:15 +00:00
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2023-01-23 22:49:15 +00:00
< p > Victor? Is it you?< / p >
2023-06-03 09:12:46 +00:00
< / div >
2023-01-23 22:49:15 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< footer class = "footline" >
< / footer >
< / article >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
< / header >
2023-05-14 21:06:26 +00:00
< h1 id = "openapi" > OpenAPI< / h1 >
2022-07-05 22:16:52 +00:00
2023-10-28 20:28:18 +00:00
< p > The < code > openapi< / code > shortcode uses the < a href = "https://github.com/swagger-api/swagger-ui" target = "_blank" > Swagger UI< / a > library to display your OpenAPI / Swagger specifications.< / p >
2023-06-03 22:20:43 +00:00
2023-05-14 21:06:26 +00:00
< div class = "box notices cstyle note" >
< div class = "box-label" > < i class = "fa-fw fas fa-exclamation-circle" > < / i > Note< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2023-05-14 21:06:26 +00:00
< p > This only works in modern browsers.< / p >
2023-06-03 09:12:46 +00:00
< / div >
2023-05-14 21:06:26 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< h2 id = "usage" > Usage< / h2 >
2023-05-14 21:06:26 +00:00
< p > While the examples are using shortcodes with named parameter you are free to also call this shortcode from your own partials.< / p >
2022-06-05 17:32:37 +00:00
2023-07-27 15:06:14 +00:00
< div class = "tab-panel" data-tab-group = "shortcode-parameter" >
2022-06-05 17:32:37 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-06-05 17:32:37 +00:00
< button
2022-06-22 22:08:50 +00:00
data-tab-item="shortcode"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','shortcode')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-22 22:08:50 +00:00
< button
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','partial')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > partial< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-05 17:32:37 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="shortcode"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > openapi< / span > < span class = "nx" > src< / span > < span class = "p" > =< / span > < span class = "s" > " https://petstore3.openapi.io/api/v3/openapi.json" < / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/openapi.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " src" < / span > < span class = "s" > " https://petstore3.openapi.io/api/v3/openapi.json" < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-06-05 17:32:37 +00:00
< / div >
< / div >
< h3 id = "parameter" > Parameter< / h3 >
< table >
< thead >
< tr >
2023-07-27 15:06:14 +00:00
< th > Name< / th >
< th > Default< / th >
< th > Notes< / th >
2022-06-05 17:32:37 +00:00
< / tr >
< / thead >
< tbody >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > src< / strong > < / td >
< td > < em > < empty> < / em > < / td >
< td > The URL to the OpenAPI specification file. This can be relative to the URL of your page if it is a leaf or branch bundle.< / td >
2022-06-05 17:32:37 +00:00
< / tr >
< / tbody >
< / table >
2023-06-03 22:20:43 +00:00
2023-05-14 21:06:26 +00:00
< div class = "box notices cstyle note" >
< div class = "box-label" > < i class = "fa-fw fas fa-exclamation-circle" > < / i > Note< / div >
< div class = "box-content" >
2023-06-04 22:25:27 +00:00
2023-05-14 21:06:26 +00:00
< p > If you want to print out (or generate a PDF) from your OpenAPI documentation, don’ t initiate printing directly from the page because the elements are optimized for interactive usage in a browser.< / p >
2023-11-20 23:54:13 +00:00
< p > Instead, open the < a href = "../basics/customization/index.html#activate-print-support" > print preview< / a > in your browser and initiate printing from that page. This page is optimized for reading and expands most of the available sections.< / p >
2023-06-03 09:12:46 +00:00
< / div >
2023-05-14 21:06:26 +00:00
< / div >
< h2 id = "example" > Example< / h2 >
< h3 id = "using-local-file" > Using Local File< / h3 >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > openapi< / span > < span class = "nx" > src< / span > < span class = "p" > =< / span > < span class = "s" > " petstore.json" < / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-05-14 21:06:26 +00:00
< div class = "sc-openapi-wrapper is-loading helper-loading-container" >
< div
class="sc-openapi-container"
2023-12-03 14:23:32 +00:00
id="R-openapi-e8b480e1f3e1ff42ea92840832fc866f"
2023-09-21 19:35:16 +00:00
data-openapi-url="../shortcodes/openapi/petstore.json"
2023-05-14 21:06:26 +00:00
>< / div >
< / div >
2022-04-02 13:30:16 +00:00
< footer class = "footline" >
< / footer >
< / article >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
< / header >
2023-07-26 20:30:13 +00:00
< h1 id = "siteparam" > SiteParam< / h1 >
2022-04-02 13:30:16 +00:00
2023-05-14 21:06:26 +00:00
< p > The < code > siteparam< / code > shortcode prints values of site params.< / p >
2022-06-05 17:32:37 +00:00
< h2 id = "usage" > Usage< / h2 >
2023-05-14 21:06:26 +00:00
< p > While the examples are using shortcodes with named parameter you are free to use positional aswell or call this shortcode from your own partials.< / p >
2022-06-22 22:08:50 +00:00
2023-07-27 15:06:14 +00:00
< div class = "tab-panel" data-tab-group = "shortcode-parameter" >
2022-06-22 22:08:50 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-06-22 22:08:50 +00:00
< button
data-tab-item="shortcode"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','shortcode')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode< / span >
2023-06-04 22:28:49 +00:00
< / button >
2023-05-14 21:06:26 +00:00
< button
2023-09-05 11:10:04 +00:00
data-tab-item="shortcode-positional"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-09-05 11:10:04 +00:00
onclick="switchTab('shortcode-parameter','shortcode-positional')"
2023-05-14 21:06:26 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode (positional)< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-22 22:08:50 +00:00
< button
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-07-27 15:06:14 +00:00
onclick="switchTab('shortcode-parameter','partial')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > partial< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-22 22:08:50 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="shortcode"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > siteparam< / span > < span class = "nx" > name< / span > < span class = "p" > =< / span > < span class = "s" > " editURL" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-05-14 21:06:26 +00:00
< div
2023-09-05 11:10:04 +00:00
data-tab-item="shortcode-positional"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > siteparam< / span > < span class = "s" > " editURL" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/siteparam.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2023-05-14 21:06:26 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " name" < / span > < span class = "s" > " editURL" < / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-06-22 22:08:50 +00:00
< / div >
< / div >
< h3 id = "parameter" > Parameter< / h3 >
2022-06-05 17:32:37 +00:00
< table >
< thead >
< tr >
2023-07-27 15:06:14 +00:00
< th > Name< / th >
< th > Position< / th >
< th > Default< / th >
< th > Notes< / th >
2022-06-05 17:32:37 +00:00
< / tr >
< / thead >
< tbody >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > name< / strong > < / td >
< td > 1< / td >
< td > < em > < empty> < / em > < / td >
< td > The name of the site param to be displayed.< / td >
2022-06-05 17:32:37 +00:00
< / tr >
< / tbody >
< / table >
2023-05-14 21:06:26 +00:00
< h2 id = "examples" > Examples< / h2 >
2023-11-29 23:15:02 +00:00
< h3 id = "editurl-from-hugotoml" > < code > editURL< / code > from < code > hugo.toml< / code > < / h3 >
2023-10-28 20:28:18 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "s" > `editURL`< / span > < span class = "nx" > value< / span > < span class = "p" > :< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > siteparam< / span > < span class = "nx" > name< / span > < span class = "p" > =< / span > < span class = "s" > " editURL" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > < code > editURL< / code > value: < a href = "https://github.com/McShelby/hugo-theme-relearn/edit/main/exampleSite/content/" target = "_blank" > https://github.com/McShelby/hugo-theme-relearn/edit/main/exampleSite/content/< / a > < / p >
2023-07-26 20:30:13 +00:00
< h3 id = "nested-parameter-with-markdown-and-html-formatting" > Nested parameter with Markdown and HTML formatting< / h3 >
2023-11-29 23:15:02 +00:00
< p > To use formatted parameter, add this in your < code > hugo.toml< / code > :< / p >
2023-07-26 20:30:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-toml" data-lang = "toml" > < span class = "line" > < span class = "cl" > < span class = "p" > [< / span > < span class = "nx" > markup< / span > < span class = "p" > .< / span > < span class = "nx" > goldmark< / span > < span class = "p" > .< / span > < span class = "nx" > renderer< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > unsafe< / span > < span class = "p" > =< / span > < span class = "kc" > true< / span > < / span > < / span > < / code > < / pre > < / div >
2023-12-03 14:23:32 +00:00
< div class = "tab-panel" data-tab-group = "93247099262111b8939061c8c7250e40" >
2023-07-26 20:30:13 +00:00
< div class = "tab-nav" >
< div class = "tab-nav-title" > ​ < / div >
< button
2023-11-29 23:15:02 +00:00
data-tab-item="hugotoml"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-12-03 14:23:32 +00:00
onclick="switchTab('93247099262111b8939061c8c7250e40','hugotoml')"
2023-07-26 20:30:13 +00:00
>
2023-11-29 23:15:02 +00:00
< span class = "tab-nav-text" > hugo.toml< / span >
2023-07-26 20:30:13 +00:00
< / button >
< / div >
< div class = "tab-content-container" >
< div
2023-11-29 23:15:02 +00:00
data-tab-item="hugotoml"
2023-07-26 20:30:13 +00:00
class="tab-content tab-panel-style cstyle initial active">
< div class = "tab-content-text" >
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-toml" data-lang = "toml" > < span class = "line" > < span class = "cl" > < span class = "p" > [< / span > < span class = "nx" > params< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > [< / span > < span class = "nx" > params< / span > < span class = "p" > .< / span > < span class = "nx" > siteparam< / span > < span class = "p" > .< / span > < span class = "nx" > test< / span > < span class = "p" > ]< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > text< / span > < span class = "p" > =< / span > < span class = "s2" > " A **nested** parameter < b> with< /b> formatting" < / span > < / span > < / span > < / code > < / pre > < / div > < / div >
< / div >
< / div >
< / div >
2023-11-15 23:21:36 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "nx" > Formatted< / span > < span class = "nx" > parameter< / span > < span class = "p" > :< / span > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > siteparam< / span > < span class = "nx" > name< / span > < span class = "p" > =< / span > < span class = "s" > " siteparam.test.text" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < p > Formatted parameter: A < strong > nested< / strong > option < b> with< /b> formatting< / p >
2022-04-02 13:30:16 +00:00
< footer class = "footline" >
< / footer >
< / article >
2023-05-25 10:46:07 +00:00
< article class = "default" >
< header class = "headline" >
< / header >
< h1 id = "tab" > Tab< / h1 >
< p > You can use a < code > tab< / code > shortcode to display a single tab.< / p >
< p > This is especially useful if you want to flag your code example with an explicit language.< / p >
2023-10-28 20:28:18 +00:00
< p > If you want multiple tabs grouped together you can wrap your tabs into the < a href = "../shortcodes/tabs/index.html" > < code > tabs< / code > shortcode< / a > .< / p >
2023-06-03 22:20:43 +00:00
2023-12-03 14:23:32 +00:00
< div class = "tab-panel" data-tab-group = "222766d21e9f5a4570f9d56ca6307297" >
2023-05-25 10:46:07 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2023-05-25 10:46:07 +00:00
< button
data-tab-item="c"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-12-03 14:23:32 +00:00
onclick="switchTab('222766d21e9f5a4570f9d56ca6307297','c')"
2023-05-25 10:46:07 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > c< / span >
2023-06-04 22:28:49 +00:00
< / button >
2023-05-25 10:46:07 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-05-25 10:46:07 +00:00
< div
data-tab-item="c"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-python" data-lang = "python" > < span class = "line" > < span class = "cl" > < span class = "n" > printf< / span > < span class = "p" > (< / span > < span class = "s2" > " Hello World!" < / span > < span class = "p" > );< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-05-25 10:46:07 +00:00
< / div >
< / div >
< h2 id = "usage" > Usage< / h2 >
< p > While the examples are using shortcodes with named parameter you are free to also call this shortcode from your own partials.< / p >
2023-06-05 16:33:00 +00:00
< div class = "tab-panel" data-tab-group = "shortcode-parameter" >
2023-05-25 10:46:07 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2023-05-25 10:46:07 +00:00
< button
data-tab-item="shortcode"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-05-25 10:46:07 +00:00
onclick="switchTab('shortcode-parameter','shortcode')"
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode< / span >
2023-06-04 22:28:49 +00:00
< / button >
2023-05-25 10:46:07 +00:00
< button
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-05-25 10:46:07 +00:00
onclick="switchTab('shortcode-parameter','partial')"
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > partial< / span >
2023-06-04 22:28:49 +00:00
< / button >
2023-05-25 10:46:07 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-05-25 10:46:07 +00:00
< div
data-tab-item="shortcode"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " c" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-05-25 10:46:07 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```c
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > printf(" Hello World!" );
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-05-25 10:46:07 +00:00
< div
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/tab.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2023-06-05 22:32:57 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " title" < / span > < span class = "s" > " c" < / span >
2023-06-03 21:51:49 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "p" > (< / span > < span class = "s" > " ```c\nprintf(\" Hello World!\" )\n```" < / span > < span class = "p" > |< / span > < span class = "p" > .< / span > < span class = "nx" > RenderString< / span > < span class = "p" > )< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-05-25 10:46:07 +00:00
< / div >
< / div >
< h3 id = "parameter" > Parameter< / h3 >
< table >
< thead >
< tr >
2023-07-27 15:06:14 +00:00
< th > Name< / th >
< th > Default< / th >
< th > Notes< / th >
2023-05-25 10:46:07 +00:00
< / tr >
< / thead >
< tbody >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > style< / strong > < / td >
< td > see notes< / td >
< td > The style scheme used for the tab. If you don’ t set a style and you display a single code block inside of the tab, its default styling will adapt to that of a < code > code< / code > block. Otherwise < code > default< / code > is used.< br > < br > - by severity: < code > info< / code > , < code > note< / code > , < code > tip< / code > , < code > warning< / code > < br > - by brand color: < code > primary< / code > , < code > secondary< / code > , < code > accent< / code > < br > - by color: < code > blue< / code > , < code > green< / code > , < code > grey< / code > , < code > orange< / code > , < code > red< / code > < br > - by special color: < code > default< / code > , < code > transparent< / code > , < code > code< / code > < / td >
2023-06-05 22:32:57 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > color< / strong > < / td >
< td > see notes< / td >
2023-10-28 20:28:18 +00:00
< td > The < a href = "https://developer.mozilla.org/en-US/docs/Web/CSS/color_value" target = "_blank" > CSS color value< / a > to be used. If not set, the chosen color depends on the < strong > style< / strong > . Any given value will overwrite the default.< br > < br > - for severity styles: a nice matching color for the severity< br > - for all other styles: the corresponding color< / td >
2023-06-05 22:32:57 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > title< / strong > < / td >
< td > see notes< / td >
< td > Arbitrary title for the tab. Depending on the < strong > style< / strong > there may be a default title. Any given value will overwrite the default.< br > < br > - for severity styles: the matching title for the severity< br > - for all other styles: < em > < empty> < / em > < br > < br > If you want no title for a severity style, you have to set this parameter to < code > " " < / code > (a non empty string filled with spaces)< / td >
2023-06-05 22:32:57 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > icon< / strong > < / td >
< td > see notes< / td >
2023-10-28 20:28:18 +00:00
< td > < a href = "../shortcodes/icon/index.html#finding-an-icon" > Font Awesome icon name< / a > set to the left of the title. Depending on the < strong > style< / strong > there may be a default icon. Any given value will overwrite the default.< br > < br > - for severity styles: a nice matching icon for the severity< br > - for all other styles: < em > < empty> < / em > < br > < br > If you want no icon for a severity style, you have to set this parameter to < code > " " < / code > (a non empty string filled with spaces)< / td >
2023-05-25 10:46:07 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < em > < strong > < content> < / strong > < / em > < / td >
< td > < em > < empty> < / em > < / td >
< td > Arbitrary text to be displayed in the tab.< / td >
2023-05-25 10:46:07 +00:00
< / tr >
< / tbody >
< / table >
< h2 id = "examples" > Examples< / h2 >
2023-06-05 22:32:57 +00:00
< h3 id = "single-code-block-with-collapsed-margins" > Single Code Block with Collapsed Margins< / h3 >
2023-08-12 23:25:30 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Code" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```python
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > printf(" Hello World!" );
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-12-03 14:23:32 +00:00
< div class = "tab-panel" data-tab-group = "b3d7113ceec91a36c16e51b6827d201c" >
2023-05-25 10:46:07 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2023-05-25 10:46:07 +00:00
< button
2023-09-05 11:10:04 +00:00
data-tab-item="code"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-12-03 14:23:32 +00:00
onclick="switchTab('b3d7113ceec91a36c16e51b6827d201c','code')"
2023-05-25 10:46:07 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > Code< / span >
2023-06-04 22:28:49 +00:00
< / button >
2023-05-25 10:46:07 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-05-25 10:46:07 +00:00
< div
2023-09-05 11:10:04 +00:00
data-tab-item="code"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-python" data-lang = "python" > < span class = "line" > < span class = "cl" > < span class = "n" > printf< / span > < span class = "p" > (< / span > < span class = "s2" > " Hello World!" < / span > < span class = "p" > );< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-05-25 10:46:07 +00:00
< / div >
< / div >
2023-06-05 22:32:57 +00:00
< h3 id = "mixed-markdown-content" > Mixed Markdown Content< / h3 >
2023-08-12 23:25:30 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " _**Mixed**_" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > A< / span > < span class = "nx" > tab< / span > < span class = "nx" > can< / span > < span class = "nx" > not< / span > < span class = "nx" > only< / span > < span class = "nx" > contain< / span > < span class = "nx" > code< / span > < span class = "nx" > but< / span > < span class = "nx" > arbitrary< / span > < span class = "nx" > text< / span > < span class = "p" > .< / span > < span class = "nx" > In< / span > < span class = "nx" > this< / span > < span class = "k" > case< / span > < span class = "nx" > text< / span > < span class = "o" > **< / span > < span class = "nx" > and< / span > < span class = "o" > **< / span > < span class = "nx" > code< / span > < span class = "nx" > will< / span > < span class = "nx" > get< / span > < span class = "nx" > a< / span > < span class = "nx" > margin< / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```python
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > printf(" Hello World!" );
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-12-03 14:23:32 +00:00
< div class = "tab-panel" data-tab-group = "29fb2f57e9e3c45fdea6c27acd1260b1" >
2023-05-25 10:46:07 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2023-05-25 10:46:07 +00:00
< button
2023-09-30 19:51:47 +00:00
data-tab-item="mixed"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-12-03 14:23:32 +00:00
onclick="switchTab('29fb2f57e9e3c45fdea6c27acd1260b1','mixed')"
2023-05-25 10:46:07 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > < em > < strong > Mixed< / strong > < / em > < / span >
2023-06-04 22:28:49 +00:00
< / button >
2023-05-25 10:46:07 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-05-25 10:46:07 +00:00
< div
2023-09-30 19:51:47 +00:00
data-tab-item="mixed"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-08-12 23:25:30 +00:00
< p > A tab can not only contain code but arbitrary text. In this case text < strong > and< / strong > code will get a margin.< / p >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-python" data-lang = "python" > < span class = "line" > < span class = "cl" > < span class = "n" > printf< / span > < span class = "p" > (< / span > < span class = "s2" > " Hello World!" < / span > < span class = "p" > );< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-05-25 10:46:07 +00:00
< / div >
< / div >
2023-06-05 22:32:57 +00:00
< h3 id = "understanding-style-and-color-behavior" > Understanding < code > style< / code > and < code > color< / code > Behavior< / h3 >
< p > The < code > style< / code > parameter affects how the < code > color< / code > parameter is applied.< / p >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > tabs< / span > < span class = "p" > > }}< / span >
2023-06-05 22:32:57 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " just colored style" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " blue" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > The< / span > < span class = "s" > `style`< / span > < span class = "nx" > parameter< / span > < span class = "nx" > is< / span > < span class = "nx" > set< / span > < span class = "nx" > to< / span > < span class = "nx" > a< / span > < span class = "nx" > color< / span > < span class = "nx" > style< / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > This< / span > < span class = "nx" > will< / span > < span class = "nx" > set< / span > < span class = "nx" > the< / span > < span class = "nx" > background< / span > < span class = "nx" > to< / span > < span class = "nx" > a< / span > < span class = "nx" > lighter< / span > < span class = "nx" > version< / span > < span class = "nx" > of< / span > < span class = "nx" > the< / span > < span class = "nx" > chosen< / span > < span class = "nx" > style< / span > < span class = "nx" > color< / span > < span class = "nx" > as< / span > < span class = "nx" > configured< / span > < span class = "nx" > in< / span > < span class = "nx" > your< / span > < span class = "nx" > theme< / span > < span class = "nx" > variant< / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " just color" < / span > < span class = "nx" > color< / span > < span class = "p" > =< / span > < span class = "s" > " blue" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Only< / span > < span class = "nx" > the< / span > < span class = "s" > `color`< / span > < span class = "nx" > parameter< / span > < span class = "nx" > is< / span > < span class = "nx" > set< / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > This< / span > < span class = "nx" > will< / span > < span class = "nx" > set< / span > < span class = "nx" > the< / span > < span class = "nx" > background< / span > < span class = "nx" > to< / span > < span class = "nx" > a< / span > < span class = "nx" > lighter< / span > < span class = "nx" > version< / span > < span class = "nx" > of< / span > < span class = "nx" > the< / span > < span class = "nx" > chosen< / span > < span class = "nx" > CSS< / span > < span class = "nx" > color< / span > < span class = "nx" > value< / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " default style and color" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " default" < / span > < span class = "nx" > color< / span > < span class = "p" > =< / span > < span class = "s" > " blue" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > The< / span > < span class = "s" > `style`< / span > < span class = "nx" > parameter< / span > < span class = "nx" > affects< / span > < span class = "nx" > how< / span > < span class = "nx" > the< / span > < span class = "s" > `color`< / span > < span class = "nx" > parameter< / span > < span class = "nx" > is< / span > < span class = "nx" > applied< / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > The< / span > < span class = "s" > `default`< / span > < span class = "nx" > style< / span > < span class = "nx" > will< / span > < span class = "nx" > set< / span > < span class = "nx" > the< / span > < span class = "nx" > background< / span > < span class = "nx" > to< / span > < span class = "nx" > your< / span > < span class = "s" > `--MAIN-BG-color`< / span > < span class = "nx" > as< / span > < span class = "nx" > configured< / span > < span class = "k" > for< / span > < span class = "nx" > your< / span > < span class = "nx" > theme< / span > < span class = "nx" > variant< / span > < span class = "nx" > resembling< / span > < span class = "nx" > the< / span > < span class = "k" > default< / span > < span class = "nx" > style< / span > < span class = "nx" > but< / span > < span class = "nx" > with< / span > < span class = "nx" > different< / span > < span class = "nx" > color< / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " just severity style" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " info" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > The< / span > < span class = "s" > `style`< / span > < span class = "nx" > parameter< / span > < span class = "nx" > is< / span > < span class = "nx" > set< / span > < span class = "nx" > to< / span > < span class = "nx" > a< / span > < span class = "nx" > severity< / span > < span class = "nx" > style< / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > This< / span > < span class = "nx" > will< / span > < span class = "nx" > set< / span > < span class = "nx" > the< / span > < span class = "nx" > background< / span > < span class = "nx" > to< / span > < span class = "nx" > a< / span > < span class = "nx" > lighter< / span > < span class = "nx" > version< / span > < span class = "nx" > of< / span > < span class = "nx" > the< / span > < span class = "nx" > chosen< / span > < span class = "nx" > style< / span > < span class = "nx" > color< / span > < span class = "nx" > as< / span > < span class = "nx" > configured< / span > < span class = "nx" > in< / span > < span class = "nx" > your< / span > < span class = "nx" > theme< / span > < span class = "nx" > variant< / span > < span class = "nx" > and< / span > < span class = "nx" > also< / span > < span class = "nx" > affects< / span > < span class = "nx" > the< / span > < span class = "nx" > chosen< / span > < span class = "nx" > icon< / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " severity style and color" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " info" < / span > < span class = "nx" > color< / span > < span class = "p" > =< / span > < span class = "s" > " blue" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > The< / span > < span class = "s" > `style`< / span > < span class = "nx" > parameter< / span > < span class = "nx" > affects< / span > < span class = "nx" > how< / span > < span class = "nx" > the< / span > < span class = "s" > `color`< / span > < span class = "nx" > parameter< / span > < span class = "nx" > is< / span > < span class = "nx" > applied< / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > This< / span > < span class = "nx" > will< / span > < span class = "nx" > set< / span > < span class = "nx" > the< / span > < span class = "nx" > background< / span > < span class = "nx" > to< / span > < span class = "nx" > a< / span > < span class = "nx" > lighter< / span > < span class = "nx" > version< / span > < span class = "nx" > of< / span > < span class = "nx" > the< / span > < span class = "nx" > chosen< / span > < span class = "nx" > CSS< / span > < span class = "nx" > color< / span > < span class = "nx" > value< / span > < span class = "nx" > and< / span > < span class = "nx" > also< / span > < span class = "nx" > affects< / span > < span class = "nx" > the< / span > < span class = "nx" > chosen< / span > < span class = "nx" > icon< / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > tabs< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-12-03 14:23:32 +00:00
< div class = "tab-panel" data-tab-group = "d3eefb5668ee93c2809fe04ad9f44e4e" >
2023-06-05 22:32:57 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2023-06-05 22:32:57 +00:00
< button
2023-09-05 11:10:04 +00:00
data-tab-item="just-colored-style"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle blue active" tabindex="-1"
2023-12-03 14:23:32 +00:00
onclick="switchTab('d3eefb5668ee93c2809fe04ad9f44e4e','just-colored-style')"
2023-06-05 22:32:57 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > just colored style< / span >
2023-06-05 22:32:57 +00:00
< / button >
< button
2023-09-05 11:10:04 +00:00
data-tab-item="just-color"
2023-06-05 22:32:57 +00:00
class="tab-nav-button tab-panel-style cstyle filled" style="--VARIABLE-BOX-color: blue;"
2023-12-03 14:23:32 +00:00
onclick="switchTab('d3eefb5668ee93c2809fe04ad9f44e4e','just-color')"
2023-06-05 22:32:57 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > just color< / span >
2023-06-05 22:32:57 +00:00
< / button >
< button
2023-09-05 11:10:04 +00:00
data-tab-item="default-style-and-color"
2023-06-05 22:32:57 +00:00
class="tab-nav-button tab-panel-style cstyle default" style="--VARIABLE-BOX-color: blue;"
2023-12-03 14:23:32 +00:00
onclick="switchTab('d3eefb5668ee93c2809fe04ad9f44e4e','default-style-and-color')"
2023-06-05 22:32:57 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > default style and color< / span >
2023-06-05 22:32:57 +00:00
< / button >
< button
2023-09-05 11:10:04 +00:00
data-tab-item="just-severity-stylefa-fw-fas-fa-info-circle"
2023-06-05 22:32:57 +00:00
class="tab-nav-button tab-panel-style cstyle info"
2023-12-03 14:23:32 +00:00
onclick="switchTab('d3eefb5668ee93c2809fe04ad9f44e4e','just-severity-stylefa-fw-fas-fa-info-circle')"
2023-06-05 22:32:57 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > < i class = "fa-fw fas fa-info-circle" > < / i > just severity style< / span >
2023-06-05 22:32:57 +00:00
< / button >
< button
2023-09-05 11:10:04 +00:00
data-tab-item="severity-style-and-colorfa-fw-fas-fa-info-circle"
2023-06-05 22:32:57 +00:00
class="tab-nav-button tab-panel-style cstyle info" style="--VARIABLE-BOX-color: blue;"
2023-12-03 14:23:32 +00:00
onclick="switchTab('d3eefb5668ee93c2809fe04ad9f44e4e','severity-style-and-colorfa-fw-fas-fa-info-circle')"
2023-06-05 22:32:57 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > < i class = "fa-fw fas fa-info-circle" > < / i > severity style and color< / span >
2023-06-05 22:32:57 +00:00
< / button >
< / div >
< div class = "tab-content-container" >
< div
2023-09-05 11:10:04 +00:00
data-tab-item="just-colored-style"
2023-06-05 22:32:57 +00:00
class="tab-content tab-panel-style cstyle blue active">
< div class = "tab-content-text" >
< p > The < code > style< / code > parameter is set to a color style.< / p >
< p > This will set the background to a lighter version of the chosen style color as configured in your theme variant.< / p >
< / div >
< / div >
< div
2023-09-05 11:10:04 +00:00
data-tab-item="just-color"
2023-06-05 22:32:57 +00:00
class="tab-content tab-panel-style cstyle filled" style="--VARIABLE-BOX-color: blue;">
< div class = "tab-content-text" >
< p > Only the < code > color< / code > parameter is set.< / p >
< p > This will set the background to a lighter version of the chosen CSS color value.< / p >
< / div >
< / div >
< div
2023-09-05 11:10:04 +00:00
data-tab-item="default-style-and-color"
2023-06-05 22:32:57 +00:00
class="tab-content tab-panel-style cstyle default" style="--VARIABLE-BOX-color: blue;">
< div class = "tab-content-text" >
< p > The < code > style< / code > parameter affects how the < code > color< / code > parameter is applied.< / p >
< p > The < code > default< / code > style will set the background to your < code > --MAIN-BG-color< / code > as configured for your theme variant resembling the default style but with different color.< / p >
< / div >
< / div >
< div
2023-09-05 11:10:04 +00:00
data-tab-item="just-severity-stylefa-fw-fas-fa-info-circle"
2023-06-05 22:32:57 +00:00
class="tab-content tab-panel-style cstyle info">
< div class = "tab-content-text" >
< p > The < code > style< / code > parameter is set to a severity style.< / p >
< p > This will set the background to a lighter version of the chosen style color as configured in your theme variant and also affects the chosen icon.< / p >
< / div >
< / div >
< div
2023-09-05 11:10:04 +00:00
data-tab-item="severity-style-and-colorfa-fw-fas-fa-info-circle"
2023-06-05 22:32:57 +00:00
class="tab-content tab-panel-style cstyle info" style="--VARIABLE-BOX-color: blue;">
< div class = "tab-content-text" >
< p > The < code > style< / code > parameter affects how the < code > color< / code > parameter is applied.< / p >
< p > This will set the background to a lighter version of the chosen CSS color value and also affects the chosen icon.< / p >
< / div >
< / div >
< / div >
< / div >
2023-05-25 10:46:07 +00:00
< footer class = "footline" >
< / footer >
< / article >
2022-11-07 19:58:08 +00:00
< article class = "default" >
2023-05-19 18:46:07 +00:00
< header class = "headline" >
< / header >
2023-01-14 00:40:32 +00:00
< h1 id = "tabs" > Tabs< / h1 >
2022-07-05 22:16:52 +00:00
2023-05-25 10:46:07 +00:00
< p > The < code > tabs< / code > shortcode displays arbitrary content in an unlimited number of tabs.< / p >
< p > This comes in handy eg. for providing code snippets for multiple languages.< / p >
2023-10-28 20:28:18 +00:00
< p > If you just want a single tab you can instead call the < a href = "../shortcodes/tab/index.html" > < code > tab< / code > shortcode< / a > standalone.< / p >
2022-04-02 13:30:16 +00:00
2023-12-03 14:23:32 +00:00
< div class = "tab-panel" data-tab-group = "956ffa668168c6ee7915c11652566743" >
2022-04-02 13:30:16 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > hello.< / div >
2022-04-02 13:30:16 +00:00
< button
2023-06-06 17:55:15 +00:00
data-tab-item="py"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-12-03 14:23:32 +00:00
onclick="switchTab('956ffa668168c6ee7915c11652566743','py')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > py< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-04-02 13:30:16 +00:00
< button
2023-06-06 17:55:15 +00:00
data-tab-item="sh"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-12-03 14:23:32 +00:00
onclick="switchTab('956ffa668168c6ee7915c11652566743','sh')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > sh< / span >
2023-06-06 17:55:15 +00:00
< / button >
< button
data-tab-item="c"
class="tab-nav-button tab-panel-style cstyle initial"
2023-12-03 14:23:32 +00:00
onclick="switchTab('956ffa668168c6ee7915c11652566743','c')"
2023-06-06 17:55:15 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > c< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-04-02 13:30:16 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
2023-06-06 17:55:15 +00:00
data-tab-item="py"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-python" data-lang = "python" > < span class = "line" > < span class = "cl" > < span class = "nb" > print< / span > < span class = "p" > (< / span > < span class = "s2" > " Hello World!" < / span > < span class = "p" > )< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
2023-06-06 17:55:15 +00:00
data-tab-item="sh"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-bash" data-lang = "bash" > < span class = "line" > < span class = "cl" > < span class = "nb" > echo< / span > < span class = "s2" > " Hello World!" < / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-06 17:55:15 +00:00
< / div >
< div
data-tab-item="c"
class="tab-content tab-panel-style cstyle initial">
< div class = "tab-content-text" >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-c" data-lang = "c" > < span class = "line" > < span class = "cl" > < span class = "nf" > printf< / span > < span class = "p" > (< / span > < span class = "s" > " Hello World!" < / span > < span class = "p" > );< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< / div >
< / div >
2022-06-05 17:32:37 +00:00
< h2 id = "usage" > Usage< / h2 >
2022-06-22 22:08:50 +00:00
< p > While the examples are using shortcodes with named parameter you are free to also call this shortcode from your own partials.< / p >
2023-10-28 20:28:18 +00:00
< p > See the < a href = "../shortcodes/tab/index.html" > < code > tab< / code > shortcode< / a > for a description of the parameter for nested tabs.< / p >
2022-06-22 22:08:50 +00:00
2023-06-05 16:33:00 +00:00
< div class = "tab-panel" data-tab-group = "shortcode-parameter" >
2022-06-22 22:08:50 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-06-22 22:08:50 +00:00
< button
data-tab-item="shortcode"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2022-06-22 22:08:50 +00:00
onclick="switchTab('shortcode-parameter','shortcode')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > shortcode< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-22 22:08:50 +00:00
< button
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2022-06-22 22:08:50 +00:00
onclick="switchTab('shortcode-parameter','partial')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > partial< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-22 22:08:50 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="shortcode"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > tabs< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " hello." < / span > < span class = "p" > > }}< / span >
2023-06-06 17:55:15 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " py" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-06-05 17:32:37 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```python
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > print(" Hello World!" )
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-06 17:55:15 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " sh" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-06-05 17:32:37 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```bash
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > echo " Hello World!"
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-06 17:55:15 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " c" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```c
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > printf" Hello World!" );
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > tabs< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="partial"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "nx" > partial< / span > < span class = "s" > " shortcodes/tabs.html" < / span > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-07-27 15:06:14 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " page" < / span > < span class = "p" > .< / span >
2023-06-06 17:55:15 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " title" < / span > < span class = "s" > " hello." < / span >
2023-05-25 10:46:07 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "p" > (< / span > < span class = "nf" > slice< / span >
2022-06-22 22:08:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-06-06 17:55:15 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " title" < / span > < span class = "s" > " py" < / span >
2023-06-03 11:16:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "p" > (< / span > < span class = "s" > " ```python\nprint(\" Hello World!\" )\n```" < / span > < span class = "p" > |< / span > < span class = "p" > .< / span > < span class = "nx" > RenderString< / span > < span class = "p" > )< / span >
2022-06-22 22:08:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
2023-06-06 17:55:15 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " title" < / span > < span class = "s" > " sh" < / span >
2023-06-03 11:16:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "p" > (< / span > < span class = "s" > " ```bash\necho \" Hello World!\" \n```" < / span > < span class = "p" > |< / span > < span class = "p" > .< / span > < span class = "nx" > RenderString< / span > < span class = "p" > )< / span >
2022-06-22 22:08:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )< / span >
2023-06-06 17:55:15 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > (< / span > < span class = "nx" > dict< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " title" < / span > < span class = "s" > " c" < / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > " content" < / span > < span class = "p" > (< / span > < span class = "s" > " ```c\nprintf(\" Hello World!\" );\n```" < / span > < span class = "p" > |< / span > < span class = "p" > .< / span > < span class = "nx" > RenderString< / span > < span class = "p" > )< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )< / span >
2022-06-22 22:08:50 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > )}}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-06-22 22:08:50 +00:00
< / div >
< / div >
< h3 id = "parameter" > Parameter< / h3 >
2022-06-05 17:32:37 +00:00
< table >
< thead >
< tr >
2023-07-27 15:06:14 +00:00
< th > Name< / th >
< th > Default< / th >
< th > Notes< / th >
2022-06-05 17:32:37 +00:00
< / tr >
< / thead >
< tbody >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > groupid< / strong > < / td >
< td > < em > < random> < / em > < / td >
< td > Arbitrary name of the group the tab view belongs to.< br > < br > Tab views with the same < strong > groupid< / strong > sychronize their selected tab. The tab selection is restored automatically based on the < code > groupid< / code > for tab view. If the selected tab can not be found in a tab group the first tab is selected instead.< br > < br > This sychronization applies to the whole site!< / td >
2022-06-05 17:32:37 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > style< / strong > < / td >
< td > < em > < empty> < / em > < / td >
2023-10-28 20:28:18 +00:00
< td > Sets a default value for every contained tab. Can be overridden by each tab. See the < a href = "../shortcodes/tab/index.html#parameter" > < code > tab< / code > shortcode< / a > for possible values.< / td >
2023-06-05 22:32:57 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > color< / strong > < / td >
< td > < em > < empty> < / em > < / td >
2023-10-28 20:28:18 +00:00
< td > Sets a default value for every contained tab. Can be overridden by each tab. See the < a href = "../shortcodes/tab/index.html#parameter" > < code > tab< / code > shortcode< / a > for possible values.< / td >
2023-06-05 22:32:57 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > title< / strong > < / td >
< td > < em > < empty> < / em > < / td >
< td > Arbitrary title written in front of the tab view.< / td >
2023-06-06 17:55:15 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < strong > icon< / strong > < / td >
< td > < em > < empty> < / em > < / td >
2023-10-28 20:28:18 +00:00
< td > < a href = "../shortcodes/icon/index.html#finding-an-icon" > Font Awesome icon name< / a > set to the left of the title.< / td >
2023-06-06 17:55:15 +00:00
< / tr >
< tr >
2023-07-27 15:06:14 +00:00
< td > < em > < strong > < content> < / strong > < / em > < / td >
< td > < em > < empty> < / em > < / td >
< td > Arbitrary number of tabs defined with the < code > tab< / code > sub-shortcode.< / td >
2022-06-05 17:32:37 +00:00
< / tr >
< / tbody >
< / table >
2023-05-25 10:46:07 +00:00
< h2 id = "examples" > Examples< / h2 >
< h3 id = "behavior-of-the-groupid" > Behavior of the < code > groupid< / code > < / h3 >
< p > See what happens to the tab views while you select different tabs.< / p >
2023-06-07 22:14:52 +00:00
< p > While pressing a tab of Group A switches all tab views of Group A in sync (if the tab is available), the tabs of Group B are left untouched.< / p >
2022-04-02 13:30:16 +00:00
2023-12-03 14:23:32 +00:00
< div class = "tab-panel" data-tab-group = "e7e29f248492fcf740e96521a907f23b" >
2023-05-25 10:46:07 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2023-05-25 10:46:07 +00:00
< button
2023-09-05 11:10:04 +00:00
data-tab-item="group-a-tab-view-1"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-12-03 14:23:32 +00:00
onclick="switchTab('e7e29f248492fcf740e96521a907f23b','group-a-tab-view-1')"
2023-05-25 10:46:07 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > Group A, Tab View 1< / span >
2023-06-04 22:28:49 +00:00
< / button >
2023-05-25 10:46:07 +00:00
< button
2023-09-05 11:10:04 +00:00
data-tab-item="group-a-tab-view-2"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-12-03 14:23:32 +00:00
onclick="switchTab('e7e29f248492fcf740e96521a907f23b','group-a-tab-view-2')"
2023-05-25 10:46:07 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > Group A, Tab View 2< / span >
2023-06-04 22:28:49 +00:00
< / button >
2023-05-25 10:46:07 +00:00
< button
2023-09-05 11:10:04 +00:00
data-tab-item="group-b"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-12-03 14:23:32 +00:00
onclick="switchTab('e7e29f248492fcf740e96521a907f23b','group-b')"
2023-05-25 10:46:07 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > Group B< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-12-04 09:16:01 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-05-25 10:46:07 +00:00
< div
2023-09-05 11:10:04 +00:00
data-tab-item="group-a-tab-view-1"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > tabs< / span > < span class = "nx" > groupid< / span > < span class = "p" > =< / span > < span class = "s" > " a" < / span > < span class = "p" > > }}< / span >
2023-06-05 22:32:57 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " json" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-15 17:38:49 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > highlight< / span > < span class = "nx" > json< / span > < span class = "s" > " linenos=true" < / span > < span class = "p" > > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {< / span > < span class = "s" > " Hello" < / span > < span class = "p" > :< / span > < span class = "s" > " World" < / span > < span class = "p" > }< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > highlight< / span > < span class = "p" > > }}< / span >
2022-04-02 13:30:16 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-05 22:32:57 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " _**XML**_ stuff" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-04-02 13:30:16 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```xml
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > < Hello> World< /Hello>
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-07 18:23:15 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " text" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Hello< / span > < span class = "nx" > World< / span >
2022-04-02 13:30:16 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > tabs< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-05-25 10:46:07 +00:00
< div
2023-09-05 11:10:04 +00:00
data-tab-item="group-a-tab-view-2"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > tabs< / span > < span class = "nx" > groupid< / span > < span class = "p" > =< / span > < span class = "s" > " a" < / span > < span class = "p" > > }}< / span >
2023-06-05 22:32:57 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " json" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-15 17:38:49 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > highlight< / span > < span class = "nx" > json< / span > < span class = "s" > " linenos=true" < / span > < span class = "p" > > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {< / span > < span class = "s" > " Hello" < / span > < span class = "p" > :< / span > < span class = "s" > " World" < / span > < span class = "p" > }< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > highlight< / span > < span class = "p" > > }}< / span >
2023-05-25 10:46:07 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-05 22:32:57 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " XML stuff" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-05-25 10:46:07 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```xml
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > < Hello> World< /Hello>
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > tabs< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-05-25 10:46:07 +00:00
< div
2023-09-05 11:10:04 +00:00
data-tab-item="group-b"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > tabs< / span > < span class = "nx" > groupid< / span > < span class = "p" > =< / span > < span class = "s" > " b" < / span > < span class = "p" > > }}< / span >
2023-06-05 22:32:57 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " json" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-15 17:38:49 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > highlight< / span > < span class = "nx" > json< / span > < span class = "s" > " linenos=true" < / span > < span class = "p" > > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {< / span > < span class = "s" > " Hello" < / span > < span class = "p" > :< / span > < span class = "s" > " World" < / span > < span class = "p" > }< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > highlight< / span > < span class = "p" > > }}< / span >
2023-05-25 10:46:07 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-05 22:32:57 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " XML stuff" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-05-25 10:46:07 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```xml
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > < Hello> World< /Hello>
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > tabs< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-05-25 10:46:07 +00:00
< / div >
< / div >
< h4 id = "group-a-tab-view-1" > Group A, Tab View 1< / h4 >
2023-06-05 16:33:00 +00:00
< div class = "tab-panel" data-tab-group = "tab-example-a" >
2022-04-02 13:30:16 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-04-02 13:30:16 +00:00
< button
data-tab-item="json"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-05-25 10:46:07 +00:00
onclick="switchTab('tab-example-a','json')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > json< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-04-02 13:30:16 +00:00
< button
2023-09-30 19:51:47 +00:00
data-tab-item="xml-stuff"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-09-30 19:51:47 +00:00
onclick="switchTab('tab-example-a','xml-stuff')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > < em > < strong > XML< / strong > < / em > stuff< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-04-02 13:30:16 +00:00
< button
2023-06-07 18:23:15 +00:00
data-tab-item="text"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-06-07 18:23:15 +00:00
onclick="switchTab('tab-example-a','text')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > text< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-04-02 13:30:16 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="json"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-json" data-lang = "json" > < span class = "line" > < span class = "ln" > 1< / span > < span class = "cl" > < span class = "p" > {< / span > < span class = "nt" > " Hello" < / span > < span class = "p" > :< / span > < span class = "s2" > " World" < / span > < span class = "p" > }< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-15 17:38:49 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
2023-09-30 19:51:47 +00:00
data-tab-item="xml-stuff"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-xml" data-lang = "xml" > < span class = "line" > < span class = "cl" > < span class = "nt" > < Hello> < / span > World< span class = "nt" > < /Hello> < / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
2023-06-07 18:23:15 +00:00
data-tab-item="text"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-07 18:23:15 +00:00
< pre > < code > Hello World
< / code > < / pre >
< / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< / div >
< / div >
2023-05-25 10:46:07 +00:00
< h4 id = "group-a-tab-view-2" > Group A, Tab View 2< / h4 >
2023-06-05 16:33:00 +00:00
< div class = "tab-panel" data-tab-group = "tab-example-a" >
2022-06-05 17:32:37 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-06-05 17:32:37 +00:00
< button
data-tab-item="json"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-05-25 10:46:07 +00:00
onclick="switchTab('tab-example-a','json')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > json< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-05 17:32:37 +00:00
< button
2023-09-05 11:10:04 +00:00
data-tab-item="xml-stuff"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-09-05 11:10:04 +00:00
onclick="switchTab('tab-example-a','xml-stuff')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > XML stuff< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-06-05 17:32:37 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="json"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-json" data-lang = "json" > < span class = "line" > < span class = "ln" > 1< / span > < span class = "cl" > < span class = "p" > {< / span > < span class = "nt" > " Hello" < / span > < span class = "p" > :< / span > < span class = "s2" > " World" < / span > < span class = "p" > }< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-15 17:38:49 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
2023-09-05 11:10:04 +00:00
data-tab-item="xml-stuff"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-xml" data-lang = "xml" > < span class = "line" > < span class = "cl" > < span class = "nt" > < Hello> < / span > World< span class = "nt" > < /Hello> < / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-05-25 10:46:07 +00:00
< / div >
< / div >
< h4 id = "group-b" > Group B< / h4 >
2023-06-05 16:33:00 +00:00
< div class = "tab-panel" data-tab-group = "tab-example-b" >
2023-05-25 10:46:07 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2023-05-25 10:46:07 +00:00
< button
data-tab-item="json"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2023-05-25 10:46:07 +00:00
onclick="switchTab('tab-example-b','json')"
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > json< / span >
2023-06-04 22:28:49 +00:00
< / button >
2023-05-25 10:46:07 +00:00
< button
2023-09-05 11:10:04 +00:00
data-tab-item="xml-stuff"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2023-09-05 11:10:04 +00:00
onclick="switchTab('tab-example-b','xml-stuff')"
2023-05-25 10:46:07 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > XML stuff< / span >
2023-06-04 22:28:49 +00:00
< / button >
2023-05-25 10:46:07 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-05-25 10:46:07 +00:00
< div
data-tab-item="json"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-json" data-lang = "json" > < span class = "line" > < span class = "ln" > 1< / span > < span class = "cl" > < span class = "p" > {< / span > < span class = "nt" > " Hello" < / span > < span class = "p" > :< / span > < span class = "s2" > " World" < / span > < span class = "p" > }< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-15 17:38:49 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-05-25 10:46:07 +00:00
< div
2023-09-05 11:10:04 +00:00
data-tab-item="xml-stuff"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-xml" data-lang = "xml" > < span class = "line" > < span class = "cl" > < span class = "nt" > < Hello> < / span > World< span class = "nt" > < /Hello> < / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-11-17 21:58:05 +00:00
< / div >
< / div >
2023-06-07 22:14:52 +00:00
< h3 id = "nested-tab-views-and-color" > Nested Tab Views and Color< / h3 >
< p > In case you want to nest tab views, the parent tab that contains nested tab views needs to be declared with < code > {{< tab > }}< / code > instead of < code > {{% tab %}}< / code > . Note, that in this case it is not possible to put markdown in the parent tab.< / p >
2023-10-28 20:28:18 +00:00
< p > You can also set style and color parameter for all tabs and overwrite them on tab level. See the < a href = "../shortcodes/tab/index.html#parameter" > < code > tab< / code > shortcode< / a > for possible values.< / p >
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-go" data-lang = "go" > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > tabs< / span > < span class = "nx" > groupid< / span > < span class = "p" > =< / span > < span class = "s" > " main" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " primary" < / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Rationale" < / span > < span class = "nx" > icon< / span > < span class = "p" > =< / span > < span class = "s" > " thumbtack" < / span > < span class = "p" > > }}< / span >
2023-06-05 22:32:57 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Text" < / span > < span class = "p" > > }}< / span >
2022-11-17 21:58:05 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Simple< / span > < span class = "nx" > text< / span > < span class = "nx" > is< / span > < span class = "nx" > possible< / span > < span class = "nx" > here< / span > < span class = "o" > ...< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > tabs< / span > < span class = "nx" > groupid< / span > < span class = "p" > =< / span > < span class = "s" > " tabs-example-language" < / span > < span class = "p" > > }}< / span >
2023-06-05 22:32:57 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " python" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-11-17 21:58:05 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Python< / span > < span class = "nx" > is< / span > < span class = "o" > **< / span > < span class = "nx" > super< / span > < span class = "o" > **< / span > < span class = "nx" > easy< / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "o" > -< / span > < span class = "nx" > most< / span > < span class = "nx" > of< / span > < span class = "nx" > the< / span > < span class = "nx" > time< / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "o" > -< / span > < span class = "k" > if< / span > < span class = "nx" > you< / span > < span class = "nx" > don< / span > < span class = "err" > ' < / span > < span class = "nx" > t< / span > < span class = "nx" > want< / span > < span class = "nx" > to< / span > < span class = "nx" > output< / span > < span class = "nx" > unicode< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-05 22:32:57 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " bash" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-11-17 21:58:05 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "nx" > Bash< / span > < span class = "nx" > is< / span > < span class = "k" > for< / span > < span class = "o" > **< / span > < span class = "nx" > hackers< / span > < span class = "o" > **< / span > < span class = "p" > .< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > tabs< / span > < span class = "p" > > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "p" > > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" >
2023-06-06 17:55:15 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " Code" < / span > < span class = "nx" > style< / span > < span class = "p" > =< / span > < span class = "s" > " default" < / span > < span class = "nx" > color< / span > < span class = "p" > =< / span > < span class = "s" > " darkorchid" < / span > < span class = "p" > > }}< / span >
2022-11-17 21:58:05 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "o" > ...< / span > < span class = "nx" > but< / span > < span class = "nx" > no< / span > < span class = "nx" > markdown< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "nx" > tabs< / span > < span class = "nx" > groupid< / span > < span class = "p" > =< / span > < span class = "s" > " tabs-example-language" < / span > < span class = "p" > > }}< / span >
2023-06-05 22:32:57 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " python" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-11-17 21:58:05 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```python
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > print(" Hello World!" )
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2023-06-05 22:32:57 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "nx" > tab< / span > < span class = "nx" > title< / span > < span class = "p" > =< / span > < span class = "s" > " bash" < / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
2022-11-17 21:58:05 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```bash
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > echo " Hello World!"
< / span > < / span > < / span > < span class = "line" > < span class = "cl" > < span class = "s" > ```< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< / span > < span class = "o" > %< / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "o" > %< / span > < span class = "p" > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > tabs< / span > < span class = "p" > > }}< / span >
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > tab< / span > < span class = "p" > > }}< / span >
2023-06-21 23:23:13 +00:00
< / span > < / span > < span class = "line" > < span class = "cl" > < span class = "p" > {{< < / span > < span class = "o" > /< / span > < span class = "nx" > tabs< / span > < span class = "p" > > }}< / span > < / span > < / span > < / code > < / pre > < / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-panel" data-tab-group = "main" >
2022-11-17 21:58:05 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > < i class = "fa-fw fas fa-thumbtack" > < / i > Rationale< / div >
2022-11-17 21:58:05 +00:00
< button
2023-09-05 11:10:04 +00:00
data-tab-item="text"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle primary active" tabindex="-1"
2023-09-05 11:10:04 +00:00
onclick="switchTab('main','text')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > Text< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-11-17 21:58:05 +00:00
< button
2023-09-05 11:10:04 +00:00
data-tab-item="code"
2023-06-06 17:55:15 +00:00
class="tab-nav-button tab-panel-style cstyle default" style="--VARIABLE-BOX-color: darkorchid;"
2023-09-05 11:10:04 +00:00
onclick="switchTab('main','code')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > Code< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-11-17 21:58:05 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
2023-09-05 11:10:04 +00:00
data-tab-item="text"
2023-06-05 22:32:57 +00:00
class="tab-content tab-panel-style cstyle primary active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
< p >
2022-11-17 21:58:05 +00:00
Simple text is possible here...
2023-06-05 16:33:00 +00:00
< div class = "tab-panel" data-tab-group = "tabs-example-language" >
2022-11-17 21:58:05 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-11-17 21:58:05 +00:00
< button
data-tab-item="python"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2022-11-17 21:58:05 +00:00
onclick="switchTab('tabs-example-language','python')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > python< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-11-17 21:58:05 +00:00
< button
data-tab-item="bash"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2022-11-17 21:58:05 +00:00
onclick="switchTab('tabs-example-language','bash')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > bash< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-11-17 21:58:05 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="python"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2022-11-17 21:58:05 +00:00
< p > Python is < strong > super< / strong > easy.< / p >
< ul >
< li > most of the time.< / li >
< li > if you don’ t want to output unicode< / li >
< / ul >
2023-05-25 10:46:07 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="bash"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2022-11-17 21:58:05 +00:00
< p > Bash is for < strong > hackers< / strong > .< / p >
2023-05-25 10:46:07 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-11-17 21:58:05 +00:00
< / div >
< / div >
2023-05-25 10:46:07 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
2023-09-05 11:10:04 +00:00
data-tab-item="code"
2023-06-06 17:55:15 +00:00
class="tab-content tab-panel-style cstyle default" style="--VARIABLE-BOX-color: darkorchid;">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
< p >
2022-11-17 21:58:05 +00:00
...but no markdown
2023-06-05 16:33:00 +00:00
< div class = "tab-panel" data-tab-group = "tabs-example-language" >
2022-11-17 21:58:05 +00:00
< div class = "tab-nav" >
2023-06-06 17:55:15 +00:00
< div class = "tab-nav-title" > ​ < / div >
2022-11-17 21:58:05 +00:00
< button
data-tab-item="python"
2023-11-18 23:55:52 +00:00
class="tab-nav-button tab-panel-style cstyle initial active" tabindex="-1"
2022-11-17 21:58:05 +00:00
onclick="switchTab('tabs-example-language','python')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > python< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-11-17 21:58:05 +00:00
< button
data-tab-item="bash"
2023-06-06 16:16:06 +00:00
class="tab-nav-button tab-panel-style cstyle initial"
2022-11-17 21:58:05 +00:00
onclick="switchTab('tabs-example-language','bash')"
2023-01-29 16:05:10 +00:00
>
2023-10-01 19:07:53 +00:00
< span class = "tab-nav-text" > bash< / span >
2023-06-04 22:28:49 +00:00
< / button >
2022-11-17 21:58:05 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< div class = "tab-content-container" >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="python"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial active">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-python" data-lang = "python" > < span class = "line" > < span class = "cl" > < span class = "nb" > print< / span > < span class = "p" > (< / span > < span class = "s2" > " Hello World!" < / span > < span class = "p" > )< / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2023-01-29 16:05:10 +00:00
< div
data-tab-item="bash"
2023-06-06 16:16:06 +00:00
class="tab-content tab-panel-style cstyle initial">
2023-06-05 16:33:00 +00:00
< div class = "tab-content-text" >
2023-06-04 22:25:27 +00:00
2023-06-21 23:23:13 +00:00
< div class = "wrap-code highlight" > < pre tabindex = "0" class = "chroma" > < code class = "language-bash" data-lang = "bash" > < span class = "line" > < span class = "cl" > < span class = "nb" > echo< / span > < span class = "s2" > " Hello World!" < / span > < / span > < / span > < / code > < / pre > < / div > < / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-11-17 21:58:05 +00:00
< / div >
< / div >
2023-05-25 10:46:07 +00:00
< / div >
2023-06-05 16:33:00 +00:00
< / div >
2022-06-05 17:32:37 +00:00
< / div >
2022-04-02 13:30:16 +00:00
< / div >
< footer class = "footline" >
< / footer >
< / article >
2022-07-05 22:16:52 +00:00
2023-05-17 22:13:41 +00:00
< / section >
< / div >
2022-04-02 13:30:16 +00:00
< / main >
< / div >
2023-12-03 14:23:32 +00:00
< script src = "../js/clipboard.min.js?1701613408" defer > < / script >
< script src = "../js/perfect-scrollbar.min.js?1701613408" defer > < / script >
2022-07-02 12:20:53 +00:00
< script >
function useMathJax( config ){
2022-07-17 18:04:59 +00:00
if( !Object.assign ){
return;
}
window.MathJax = Object.assign( window.MathJax || {}, {
2022-07-02 12:20:53 +00:00
loader: {
load: ['[tex]/mhchem']
},
startup: {
elements: [
'.math'
]
},
tex: {
inlineMath: [
['$', '$'],
['\\(', '\\)']
]
},
options: {
enableMenu: false
}
}, config );
}
2023-10-26 09:28:29 +00:00
useMathJax( JSON.parse("{}") );
2022-07-02 12:20:53 +00:00
< / script >
2023-12-03 14:23:32 +00:00
< script id = "MathJax-script" async src = "../js/mathjax/tex-mml-chtml.js?1701613408" > < / script >
< script src = "../js/d3/d3-color.min.js?1701613408" defer > < / script >
< script src = "../js/d3/d3-dispatch.min.js?1701613408" defer > < / script >
< script src = "../js/d3/d3-drag.min.js?1701613408" defer > < / script >
< script src = "../js/d3/d3-ease.min.js?1701613408" defer > < / script >
< script src = "../js/d3/d3-interpolate.min.js?1701613408" defer > < / script >
< script src = "../js/d3/d3-selection.min.js?1701613408" defer > < / script >
< script src = "../js/d3/d3-timer.min.js?1701613408" defer > < / script >
< script src = "../js/d3/d3-transition.min.js?1701613408" defer > < / script >
< script src = "../js/d3/d3-zoom.min.js?1701613408" defer > < / script >
< script src = "../js/js-yaml.min.js?1701613408" defer > < / script >
< script src = "../js/mermaid.min.js?1701613408" defer > < / script >
2022-04-02 13:30:16 +00:00
< script >
2023-10-26 09:28:29 +00:00
window.themeUseMermaid = JSON.parse("{ \"securityLevel\": \"loose\" }");
2023-05-16 02:04:42 +00:00
< / script >
< script > window . noZensmooth = true ; < / script >
2023-12-03 14:23:32 +00:00
< script src = "../js/swagger-ui/swagger-ui-bundle.js?1701613408" defer > < / script >
< script src = "../js/swagger-ui/swagger-ui-standalone-preset.js?1701613408" defer > < / script >
2022-04-02 13:30:16 +00:00
< script >
2023-12-03 14:23:32 +00:00
window.themeUseOpenapi = { css: "/js/swagger-ui/swagger-ui.css?1701613408", assetsBuster: 1701613408 };
2022-04-02 13:30:16 +00:00
< / script >
2023-12-03 14:23:32 +00:00
< script src = "../js/theme.js?1701613408" defer > < / script >
2022-04-02 13:30:16 +00:00
< / body >
< / html >