@glimpse-of-life/hugo-font-emoticons
v1.0.5
Published
Font-based emoticons for Hugo - automatic text emoticon to icon conversion
Maintainers
Readme
Hugo Font Emoticons
A Hugo module for automatically converting text emoticons into graphical icons.
Installation
Via npm (recommended for Thulite/Doks)
npm install @glimpse-of-life/hugo-font-emoticonsThen in config/_default/module.toml:
## Font Emoticons
[[mounts]]
source = "node_modules/@glimpse-of-life/hugo-font-emoticons/assets"
target = "assets"
[[mounts]]
source = "node_modules/@glimpse-of-life/hugo-font-emoticons/static"
target = "static"Via Hugo-Modul
hugo mod init github.com/your-username/your-siteIn config/_default/module.toml:
[[imports]]
path = "github.com/cnichte/hugo-font-emoticons"Local development
[[mounts]]
source = "../hugo-font-emoticons/assets"
target = "assets"
[[mounts]]
source = "../hugo-font-emoticons/static"
target = "static"integration
SCSS
In your _custom.scss or main SCSS file:
@import "components/emoticons";JavaScript
In your footer partial or script inclusion:
{{ partial "footer/esbuild" (dict "src" "js/emoticons.js" "load" "defer" "transpile" false) }}Or manually:
{{ $emoticons := resources.Get "js/emoticons.js" | minify | fingerprint }}
<script defer src="{{ $emoticons.RelPermalink }}"></script>Usage
Simply write emoticons in your Markdown text:
That's great. :D
Would you like some coffee? :coffee:
I love that. <3Unterstützte Emoticons
Smileys
| Icon | Patterns |
|------|----------|
| 😊 Happy | :) :-) (: (-: :smile: |
| 😞 Sad | :( :-( :sad: |
| 😉 Wink | ;) ;-) :wink: |
| 😛 Tongue | :P :-P :p :-p :razz: |
| 😁 Grin | :D :-D :grin: |
| 😎 Cool | 8) 8-) B) B-) :cool: |
| 😮 Surprised | :o :-o :O :-O :eek: :shock: |
| 😴 Sleep | -.- -_- :sleep: |
| 😢 Cry | :'( :'-( :cry: |
| 😆 Laugh | ^^ ^_^ :lol: |
| 😠 Angry | X( X-( :angry: :mad: |
| 😕 Displeased | :/ :-/ |
| 👼 Saint | O:) O:-) :saint: |
| 😈 Devil | >:) >:-) :devil: :twisted: |
| 😑 Squint | \|) :squint: |
Symbole
| Icon | Patterns |
|------|----------|
| ❤️ Heart | <3 :heart: |
| ☕ Coffee | :coffee: |
| 🍺 Beer | :beer: |
| ⭐ Star | :star: |
| ❓ Help | :?: |
| ℹ️ Info | :!: :idea: |
Gesten
| Icon | Patterns |
|------|----------|
| 👍 Thumbs Up | :thumbsup: :thumbs: |
| 👎 Thumbs Down | :thumbsdown: |
| ✅ OK | (ok) (/) |
| ❌ Cancel | (x) |
| ➕ Plus | (+) |
| ➖ Minus | (-) |
| 🔫 Shoot | :shoot: |
Adjustments
Content selectors
By default, JavaScript searches in:
article p, li, td, blockquote, dd.content p, li, td, blockquote, ddmain p, li, td, blockquote, dd
Lizenz
- Font-Emoticons: GPLv2 or later
- Dieses Modul: MIT
Credits
Basierend auf dem WordPress Plugin font-emoticons
