diff --git a/_includes/emoji-icon.html b/_includes/emoji-icon.html new file mode 100644 index 0000000..d3bf911 --- /dev/null +++ b/_includes/emoji-icon.html @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/_includes/emoji.html b/_includes/emoji.html new file mode 100644 index 0000000..a6c5a56 --- /dev/null +++ b/_includes/emoji.html @@ -0,0 +1,5 @@ +{% capture alternative_names %} +{% if emoji.alt_names.size > 1 %}{{ emoji.alt_names | join:',' }}{% else %}{{ emoji.name }} +{% endif %} +{% endcapture %} +{% include emoji-icon.html emoji=emoji %} em-{{ emoji.name }} \ No newline at end of file diff --git a/index.html b/index.html index 95bff24..d5df7a2 100755 --- a/index.html +++ b/index.html @@ -23,15 +23,21 @@
Want to include emoji in your HTML? Just include the (minified) stylesheet below, then add <i>
tags to insert emoji. That's it!
✈ Click the emoji code and it will be copied to your clipboard.
-
<link href="https://afeld.github.io/emoji-css/emoji.css" rel="stylesheet">
+
+{% highlight html %}
+
+
+{% assign emoji=site.data.emoji[104] %}{% include emoji-icon.html %}
-<i class="em em-some-emoji"></i>
+{% endhighlight %}
+
By default, the emoji will be served as PNGs. To use SVG instead, use the em-svg
class instead of em
. This will scale better, but has larger file size.