git ssb

16+

Dominic / patchbay



Tree: 9746cd345f014701f5911b233fe5aec3e3c52edb

Files: 9746cd345f014701f5911b233fe5aec3e3c52edb / modules_extra / emoji.js

530 bytesRaw
1var emojis = require('emoji-named-characters')
2var emojiNames = Object.keys(emojis)
3
4//var plugs = require('../plugs')
5//var blob_url = plugs.first(exports.blob_url = [])
6//
7
8exports.needs = { blob_url: 'first' }
9exports.gives = { emoji_names: true, emoji_url: true }
10
11exports.create = function (api) {
12 return {
13 emoji_names: function () {
14 return emojiNames
15 },
16 emoji_url: function (emoji) {
17 return emoji in emojis &&
18 api.blob_url(emoji).replace(/\/blobs\/get/, '/img/emoji') + '.png'
19 }
20 }
21}
22
23

Built with git-ssb-web