Tag plugins are a unique feature of Hexo and are not part of the standard Markdown format.
The following syntax is only applicable to the Butterfly theme. It will not work on other themes and may even cause errors. Please be aware before using it.
Although tag plugins can provide additional functionality and UI enhancements to the theme, they also come with notable limitations. Please be mindful when using them.
Note (Bootstrap Callout)
Ported from the Next theme and modified.
1 2 3 4 5 6 7 8 9 10 11 12
note: # Note tag style values: # - simple bs-callout old alert style. Default. # - modern bs-callout new (v2-v3) alert style. # - flat flat callout style with background, like on Mozilla or StackOverflow. # - disabled disable all CSS styles import of note tag. style:simple icons:false border_radius:3 # Offset lighter of background in % for modern and flat styles (modern: -12 | 12; flat: -18 | 6). # Offset also applied to label tag variables. This option can work with disabled note tag. light_bg_offset:0
Name
Description
style
[Optional] Tag style (simple/modern/flat/disabled)
{% note 'fab fa-cc-visa' simple %} Do you use Visa or UnionPay? {% endnote %} {% note blue 'fas fa-bullhorn' simple %} 2021 is coming soon.... {% endnote %} {% note pink 'fas fa-car-crash' simple %} Drive carefully, safety first. {% endnote %} {% note red 'fas fa-fan' simple%} Is this three pieces? Or four pieces? {% endnote %} {% note orange 'fas fa-battery-half' simple %} Do you use Visa or UnionPay? {% endnote %} {% note purple 'far fa-hand-scissors' simple %} Rock, Paper, Scissors {% endnote %} {% note green 'fab fa-internet-explorer' simple %} The most hated browser by front-end developers {% endnote %}
{% note 'fab fa-cc-visa' modern %} Do you use Visa or UnionPay? {% endnote %} {% note blue 'fas fa-bullhorn' modern %} 2021 is coming soon.... {% endnote %} {% note pink 'fas fa-car-crash' modern %} Drive carefully, safety first. {% endnote %} {% note red 'fas fa-fan' modern%} Is this three pieces? Or four pieces? {% endnote %} {% note orange 'fas fa-battery-half' modern %} Do you use Visa or UnionPay? {% endnote %} {% note purple 'far fa-hand-scissors' modern %} Rock, Paper, Scissors {% endnote %} {% note green 'fab fa-internet-explorer' modern %} The most hated browser by front-end developers {% endnote %}
{% note 'fab fa-cc-visa' flat %} Do you use Visa or UnionPay? {% endnote %} {% note blue 'fas fa-bullhorn' flat %} 2021 is coming soon.... {% endnote %} {% note pink 'fas fa-car-crash' flat %} Drive carefully, safety first. {% endnote %} {% note red 'fas fa-fan' flat%} Is this three pieces? Or four pieces? {% endnote %} {% note orange 'fas fa-battery-half' flat %} Do you use Visa or UnionPay? {% endnote %} {% note purple 'far fa-hand-scissors' flat %} Rock, Paper, Scissors {% endnote %} {% note green 'fab fa-internet-explorer' flat %} The most hated browser by front-end developers {% endnote %}
{% note 'fab fa-cc-visa' disabled %} Do you use Visa or UnionPay? {% endnote %} {% note blue 'fas fa-bullhorn' disabled %} 2021 is coming soon.... {% endnote %} {% note pink 'fas fa-car-crash' disabled %} Drive carefully, safety first. {% endnote %} {% note red 'fas fa-fan' disabled %} Is this three pieces? Or four pieces? {% endnote %} {% note orange 'fas fa-battery-half' disabled %} Do you use Visa or UnionPay? {% endnote %} {% note purple 'far fa-hand-scissors' disabled %} Rock, Paper, Scissors {% endnote %} {% note green 'fab fa-internet-explorer' disabled %} The most hated browser by front-end developers {% endnote %}
{% note no-icon %} Do you use Visa or UnionPay? {% endnote %} {% note blue no-icon %} 2021 is coming soon.... {% endnote %} {% note pink no-icon %} Drive carefully, safety first. {% endnote %} {% note red no-icon %} Is this three pieces? Or four pieces? {% endnote %} {% note orange no-icon %} Do you use Visa or UnionPay? {% endnote %} {% note purple no-icon %} Rock, Paper, Scissors {% endnote %} {% note green no-icon %} The most hated browser by front-end developers {% endnote %}
Do you use Visa or UnionPay?
2021 is coming soon....
Drive carefully, safety first.
Is this three pieces? Or four pieces?
Do you use Visa or UnionPay?
Rock, Paper, Scissors
The most hated browser by front-end developers
Gallery Album
Available from version 2.2.0 and above
A gallery collection.
Usage:
1 2 3 4 5
<div class="gallery-group-main"> {% galleryGroup name description link img-url %} {% galleryGroup name description link img-url %} {% galleryGroup name description link img-url %} </div>
Parameter
Description
name
Gallery name
description
Gallery description
link
Link to the album
img-url
Gallery cover URL
Sample
1 2 3 4 5
<div class="gallery-group-main"> {% galleryGroup 'Wallpapers' 'A collection of wallpapers' '/Gallery/wallpaper' https://i.loli.net/2019/11/10/T7Mu8Aod3egmC4Q.png %} {% galleryGroup 'Marvel' 'Images related to Marvel' '/Gallery/marvel' https://i.loli.net/2019/12/25/8t97aVlp4hgyBGu.jpg %} {% galleryGroup 'OH MY GIRL' 'Images related to OH MY GIRL' '/Gallery/ohmygirl' https://i.loli.net/2019/12/25/hOqbQ3BIwa6KWpo.jpg %} </div>
Gallery
Available from version 2.0.0 and above
Unlike the old version of the Gallery album, the new Gallery album automatically arranges images based on their length, making it easier to write, similar to the markdown format. It can be inserted into the corresponding markdown as needed.
Usage:
1 2 3
{% gallery [button] %} markdown image format {% endgallery %}
Parameter
Description
button
[Optional] Load more images on button click, set to true/false. Default is false.
Sample
1 2 3
{% gallery %} markdown image format {% endgallery %}
Please note that it is not recommended to have h1 - h6 headers within the tag-hide plugin content. This is because the Toc will display the hidden content headers, and if the hidden content is not displayed when scrolling the screen, it will cause abnormal scrolling of the Toc.
If you want to hide some text or content and provide a button for users to click to display it, you can use this tag plugin.
inline adds a button to hide content within the text, limited to text only.
(content cannot contain commas, use ‚ instead)
1
{% hideInline content,display,bg,color %}
Parameter
Description
content
Text content
display
[Optional] Text displayed on the button
bg
[Optional] Background color of the button
color
[Optional] Text color of the button
Sample
1 2 3
Which letter is the coolest? {% hideInline Because "C" is for Cool, See Answer, #FF7242, #fff %}
Who is standing behind the door? {% hideInline Flash %}
Which letter is the coolest? Because C is for Cool
Who is standing behind the door? Flash
block is an independent block for hiding content. It can hide a lot of content, including images, code blocks, etc.
(display cannot contain commas, use ‚ instead)
Using the mermaid tag, you can draw Flowcharts, Sequence diagrams, Class Diagrams, State Diagrams, Gantt charts, and Pie Charts. For more details, refer to the mermaid documentation.
{% mermaid %} pie title Key elements in Product X "Calcium" : 42.96 "Potassium" : 50.05 "Magnesium" : 10.01 "Iron" : 5 {% endmermaid %}
pie
title Key elements in Product X
"Calcium" : 42.96
"Potassium" : 50.05
"Magnesium" : 10.01
"Iron" : 5
Tabs
Ported from the NexT theme
Usage๏ผ
1 2 3 4 5 6 7 8 9
{% tabs Unique name, [index] %}
<!-- tab [Tab caption] [@icon] -->
Any content (support inline tags too).
<!-- endtab -->
{% endtabs %}
Parameter
Description
Unique name
The unique name of the tabs block, without commas. It will be used as the #id prefix for each tab, appended with its index number. If the name contains spaces, they will be replaced with hyphens in the generated #id. Must be unique within the current article/page URL!
[index]
[Optional] The index number of the active tab. If not specified, the first tab (1) will be selected. If the index is -1, no tab will be selected, similar to collapsed content. Optional parameter.
[Tab caption]
The title of the current tab. If not specified, the unique name with the tab index suffix will be used as the tab title. If no title is specified but an icon is provided, the title will be empty.
[@icon]
[Optional] FontAwesome icon name (full name, e.g., 'fas fa-font'). Can be with or without spaces; for example, 'Tab caption @icon' is similar to 'Tab caption@icon'.
[Optional] Button background color (default style) or button font and border color (outline style) Options: default/blue/pink/red/purple/orange/green
style
[Optional] Button style, default is solid Options: outline/empty
layout
[Optional] Button layout, default is line Options: block/empty
position
[Optional] Button position, applicable when layout is set to block, default is left Options: center/right/empty
size
[Optional] Button size Options: larger/empty
Sample
1 2 3 4 5
This is my website, click the button {% btn 'https://butterfly.js.org/',Butterfly %} This is my website, click the button {% btn 'https://butterfly.js.org/',Butterfly,far fa-hand-point-right %} This is my website, click the button {% btn 'https://butterfly.js.org/',Butterfly,,outline %} This is my website, click the button {% btn 'https://butterfly.js.org/',Butterfly,far fa-hand-point-right,outline %} This is my website, click the button {% btn 'https://butterfly.js.org/',Butterfly,far fa-hand-point-right,larger %}
This is my website, click the button Butterfly This is my website, click the buttonButterfly This is my website, click the button Butterfly This is my website, click the buttonButterfly This is my website, click the buttonButterfly
1 2 3
{% btn 'https://butterfly.js.org/',Butterfly,far fa-hand-point-right,block %} {% btn 'https://butterfly.js.org/',Butterfly,far fa-hand-point-right,block center larger %} {% btn 'https://butterfly.js.org/',Butterfly,far fa-hand-point-right,block right outline larger %}
I think she looks beautiful. {% inlineImg https://i.loli.net/2021/03/19/5M4jUB3ynq7ePgw.png 150px %}
Do you think she looks beautiful?
I think she looks beautiful.
Label
Due to the rendering limitations of Hexo, using the label tag plugin at the beginning of a paragraph can cause some issues. For example, paragraphs that consecutively start with the label tag plugin cannot break lines.
It is recommended not to use the label tag plugin at the beginning of a paragraph.
Text to be highlighted
1
{% label text color %}
Parameter
Description
text
Text
color
[Optional] Background color, default is default Options: default/blue/pink/red/purple/orange/green
Sample
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17
{% label "Shall I compare thee to a summer's day?" blue %} Thou art more lovely and more temperate: {% label "Rough winds do shake the darling buds of May," purple %} And summer's lease hath all too short a date:
{% label "Sometime too hot the eye of heaven shines," red %} And often is his gold complexion dimmed; And every fair from fair sometime declines, {% label "By chance or nature's changing course untrimmed;" yellow %}
{% label "But thy eternal summer shall not fade," green %} Nor lose possession of that fair thou owest; Nor shall Death brag thou wanderest in his shade, {% label "When in eternal lines to time thou growest:" pink %}
So long as men can breathe or eyes can see, So long lives this, and this gives life to thee.
Shall I compare thee to a summer's day?
Thou art more lovely and more temperate:
Rough winds do shake the darling buds of May,
And summer's lease hath all too short a date:
Sometime too hot the eye of heaven shines,
And often is his gold complexion dimmed; And every fair from fair sometime declines,
By chance or nature's changing course untrimmed; But thy eternal summer shall not fade,
Nor lose possession of that fair thou owest; Nor shall Death brag thou wanderest in his shade,
When in eternal lines to time thou growest:
So long as men can breathe or eyes can see, So long lives this, and this gives life to thee.
Timeline
Supported from version 4.0.0 and above
1 2 3 4 5 6 7 8 9 10 11 12 13 14
{% timeline title,color %}
<!-- timeline title -->
xxxxx
<!-- endtimeline --> <!-- timeline title -->
xxxxx
<!-- endtimeline -->
{% endtimeline %}
Parameter
Description
title
Title/Timeline
color
Timeline color default (leave blank) / blue / pink / red / purple / orange / green
Example
1 2 3 4 5 6 7 8 9
{% timeline 2022 %}
<!-- timeline 01-02 -->
This is a test page
<!-- endtimeline -->
{% endtimeline %}
2022
01-02
This is a test page
1 2 3 4 5 6 7 8 9
{% timeline 2022,blue %}
<!-- timeline 01-02 -->
This is a test page
<!-- endtimeline -->
{% endtimeline %}
2022
01-02
This is a test page
1 2 3 4 5 6 7 8 9
{% timeline 2022,pink %}
<!-- timeline 01-02 -->
This is a test page
<!-- endtimeline -->
{% endtimeline %}
2022
01-02
This is a test page
1 2 3 4 5 6 7 8 9
{% timeline 2022,red %}
<!-- timeline 01-02 -->
This is a test page
<!-- endtimeline -->
{% endtimeline %}
2022
01-02
This is a test page
1 2 3 4 5 6 7 8 9
{% timeline 2022,purple %}
<!-- timeline 01-02 -->
This is a test page
<!-- endtimeline -->
{% endtimeline %}
2022
01-02
This is a test page
1 2 3 4 5 6 7 8 9
{% timeline 2022,orange %}
<!-- timeline 01-02 -->
This is a test page
<!-- endtimeline -->
{% endtimeline %}
2022
01-02
This is a test page
1 2 3 4 5 6 7 8 9
{% timeline 2022,green %}
<!-- timeline 01-02 -->
This is a test page
<!-- endtimeline -->
{% endtimeline %}
2022
01-02
This is a test page
Flink
Support for version 4.1.0
You can insert a friend link list effect on any page.
The content format is the same as the friend link page and supports the yml format.
# chartjs # see https://www.chartjs.org/docs/latest/ chartjs: enable:false # Do not modify unless you understand how they work. # The default settings are only used when the MD syntax is not specified. # General font color for the chart fontColor: light:"rgba(0, 0, 0, 0.8)" dark:"rgba(255, 255, 255, 0.8)" # General border color for the chart borderColor: light:"rgba(0, 0, 0, 0.1)" dark:"rgba(255, 255, 255, 0.2)" # Background color for scale labels on radar and polar area charts scale_ticks_backdropColor: light:"transparent" dark:"transparent"
Parameter
Description
enable
Whether to enable chartjs
fontColor
Font color of the chart
borderColor
Border color of the chart
scale_ticks_backdropColor
Background color of the scale labels for radar and polar area charts
[Optional] Whether to display side by side. When you write <!-- desc -->, the chart and description will be displayed side by side. When abreast is true, the width value needs to be configured
้คไบ่ฎก็ฎๆบ็ผ็จๅค๏ผๆๆณไธๅบ่ฟๆๅ ถไป่ฎฉๆๆๅ ด่ถฃ็ๅทฅไฝใ ๆๅฏไปฅๆ ไธญ็ๆๅฐๅ้ ๅบ็ฒพ็พ็่ๅผๅ็ปๆ๏ผ ๅจๆญค่ฟ็จไธญไน่งฃๅณไบๆ ๆฐ็ๅฐ่ฐๅขใ I can't think of any other job other than computer programming that interests me. I can create beautiful paradigms and structures out of nothing, Countless small mysteries are also solved in the process.