diff options
author | Volpeon <git@volpeon.ink> | 2023-01-20 17:47:42 +0100 |
---|---|---|
committer | Volpeon <git@volpeon.ink> | 2023-01-20 17:47:42 +0100 |
commit | 4a567c385f7d16e12da46718d2ee4ff970072711 (patch) | |
tree | adaeb338facfc99e2bc9602588b43f7ff735301f /tpl | |
parent | Fixed flaws (diff) | |
download | iro-design-4a567c385f7d16e12da46718d2ee4ff970072711.tar.gz iro-design-4a567c385f7d16e12da46718d2ee4ff970072711.tar.bz2 iro-design-4a567c385f7d16e12da46718d2ee4ff970072711.zip |
Add emoji object
Diffstat (limited to 'tpl')
-rw-r--r-- | tpl/index.pug | 3 | ||||
-rw-r--r-- | tpl/objects/emoji.pug | 13 | ||||
-rw-r--r-- | tpl/views/emoji.pug | 8 |
3 files changed, 24 insertions, 0 deletions
diff --git a/tpl/index.pug b/tpl/index.pug index 854cb4b..1f4f522 100644 --- a/tpl/index.pug +++ b/tpl/index.pug | |||
@@ -22,6 +22,7 @@ include objects/avatar.pug | |||
22 | include objects/action-menu.pug | 22 | include objects/action-menu.pug |
23 | include objects/menu.pug | 23 | include objects/menu.pug |
24 | include objects/icon-nav.pug | 24 | include objects/icon-nav.pug |
25 | include objects/emoji.pug | ||
25 | include objects/backdrop.pug | 26 | include objects/backdrop.pug |
26 | include objects/dialog.pug | 27 | include objects/dialog.pug |
27 | include objects/lightbox.pug | 28 | include objects/lightbox.pug |
@@ -77,6 +78,7 @@ include views/table.pug | |||
77 | include views/alert.pug | 78 | include views/alert.pug |
78 | include views/bubble.pug | 79 | include views/bubble.pug |
79 | include views/bubble-group.pug | 80 | include views/bubble-group.pug |
81 | include views/emoji.pug | ||
80 | 82 | ||
81 | 83 | ||
82 | doctype html | 84 | doctype html |
@@ -96,6 +98,7 @@ html | |||
96 | +view-code | 98 | +view-code |
97 | +view-blockquote | 99 | +view-blockquote |
98 | +view-list | 100 | +view-list |
101 | +view-emoji | ||
99 | +view-badge | 102 | +view-badge |
100 | +view-button | 103 | +view-button |
101 | +view-text-field | 104 | +view-text-field |
diff --git a/tpl/objects/emoji.pug b/tpl/objects/emoji.pug new file mode 100644 index 0000000..5bf3a3b --- /dev/null +++ b/tpl/objects/emoji.pug | |||
@@ -0,0 +1,13 @@ | |||
1 | mixin emoji(id) | ||
2 | - | ||
3 | let classes = { | ||
4 | 'o-emoji': true, | ||
5 | 'o-emoji--zoomable': attributes.zoomable, | ||
6 | } | ||
7 | if (attributes.class) { | ||
8 | classes[attributes.class] = true; | ||
9 | } | ||
10 | |||
11 | src = id + '.png' | ||
12 | |||
13 | img(src=src, class=classes) | ||
diff --git a/tpl/views/emoji.pug b/tpl/views/emoji.pug new file mode 100644 index 0000000..70c13a4 --- /dev/null +++ b/tpl/views/emoji.pug | |||
@@ -0,0 +1,8 @@ | |||
1 | mixin view-emoji | ||
2 | +view('emoji', 'Emoji') | ||
3 | .c-box | ||
4 | =loremIpsum | ||
5 | +emoji('drgn') | ||
6 | =loremIpsum | ||
7 | +emoji('drgn')(zoomable=true) | ||
8 | =loremIpsum | ||