Icons, Emojis¶
One of the best features of Zensical is the possibility to use more than 10,000 icons and thousands of emojis in your project documentation with practically zero additional effort. Moreover, custom icons can be added and used in your configuration, documents and templates.
Configuration¶
This configuration enables the use of icons and emojis by using simple shortcodes. Add the following lines to your configuration:
See additional configuration options:
Included icon sets¶
The following icon sets are bundled with Zensical (links lead to search page for each):
- - Lucide
- – Material Design
- – FontAwesome
- – Octicons
- – Simple Icons
Note that you are not limited to these icons as you can add your own icons.
Usage¶
Use emojis¶
Emojis can be integrated in Markdown by putting the shortcode of the emoji between two colons. If you're using Twemoji (recommended), you can look up the shortcodes at Emojipedia:
Use icons¶
When Emoji is enabled, icons can be used similar to emojis, by referencing
a valid path to any icon bundled with the theme, which are located in the
.icons directory, and replacing / with -:
with colors¶
When Attribute Lists is enabled, custom CSS classes can be added to icons. While HTML allows inline styles, it's always recommended to add an additional style sheet and move declarations into dedicated CSS classes:
After applying the customization, add the CSS class to the icon shortcode:
with animations¶
Similar to adding colors, it's just as easy to add animations to icons by
using an additional style sheet, defining a @keyframes rule and adding a
dedicated CSS class to the icon:
After applying the customization, add the CSS class to the icon shortcode:
Customization¶
Use icons in templates¶
When you're extending the theme with partials or blocks, you can simply
reference any available icon with Jinja's include function and
wrap it with the .twemoji CSS class:
This is exactly what Zensical does in its templates.