Sha256: 346107e867cf02a500189d5e2bf8f741895d43fa9963ca9089e38127f8e6d395

Contents?: true

Size: 831 Bytes

Versions: 2

Compression:

Stored size: 831 Bytes

Contents

$(function(){
    emojify.setConfig({
        img_dir: '/images/emoji',
        ignored_tags: {
            'SCRIPT': 1,
            'TEXTAREA': 1,
            'A': 1,
            'PRE': 1,
            'CODE': 1
        }
    });
    emojify.run();
 
    $('textarea').textcomplete([{ // emoji strategy
        match: /\B:([\-+\w]*)$/,
        search: function(term, callback) {
            callback($.map(emojies, function(emoji) {
                return emoji.indexOf(term) === 0 ? emoji : null;
            }));
        },
        template: function(value) {
            return '<img src="/images/emoji/' + value + '.png" class="emoji"></img>' + value;
        },
        replace: function(value) {
            return ':' + value + ': ';
        },
        index: 1,
        maxCount: 5
    }]);
});

Version data entries

2 entries across 1 versions & 1 rubygems

Version Path
easy-emoji-0.0.1 app/assets/javascripts/easy-emoji/config.js
easy-emoji-0.0.1 app/assets/javascripts/emoji-normal.js