Skip to content
Snippets Groups Projects
Commit e8a3c357 authored by Marcelo Schmidt's avatar Marcelo Schmidt
Browse files

Adds emojione as official package

parent e6ecfbe6
No related branches found
No related tags found
No related merge requests found
......@@ -17,7 +17,6 @@ markdown
meteor-platform
reactive-var
service-configuration
chrismbeckett:toastr
francocatena:status
iframely:oembed
......@@ -39,7 +38,7 @@ pauli:accounts-linkedin
percolate:migrations
percolatestudio:synced-cron
pierreeric:rxfavico
qnub:emojione
raix:handlebar-helpers
rocketchat:file
rocketchat:lib
......@@ -49,6 +48,7 @@ rocketchat:highlight
rocketchat:autolinker
rocketchat:markdown
rocketchat:emojione
simple:highlight.js
tap:i18n
tmeasday:crypto-md5
......@@ -56,3 +56,4 @@ tmeasday:errors
todda00:friendly-slugs
underscorestring:underscore.string
yasaricli:slugify
emojione:emojione
\ No newline at end of file
......@@ -22,6 +22,7 @@ ddp@1.1.0
deps@1.0.7
ejson@1.0.6
email@1.0.6
emojione:emojione@1.4.1
facebook@1.2.0
fastclick@1.0.3
francocatena:status@1.2.3
......@@ -84,7 +85,6 @@ pauli:linkedin@1.1.2
percolate:migrations@0.7.5
percolatestudio:synced-cron@1.1.0
pierreeric:rxfavico@0.3.5_1
qnub:emojione@0.0.3
raix:handlebar-helpers@0.2.4
random@1.0.3
reactive-dict@1.1.0
......
......@@ -11,10 +11,7 @@ Meteor.methods
username: Meteor.user().username
message.html = message.msg
if _.trim(message.html) isnt ''
message.html = _.escapeHTML message.html
message = RocketChat.callbacks.run 'beforeSaveMessage', message
message.html = message.html.replace /\n/g, '<br/>'
console.log message
......
......@@ -31,10 +31,6 @@ Meteor.startup ->
$.getScript filename, (data) ->
moment.locale(userLanguage)
# Add ascii support to emojione
emojione?.ascii = true
Tracker.autorun ->
unreadCount = 0
subscriptions = ChatSubscription.find({}, { fields: { unread: 1 } })
......
......@@ -42,7 +42,7 @@
</span>
{{/if}}
<div>
{{#emojione}}{{html}}{{/emojione}}
{{{html}}}
</div>
{{/if}}
{{/if}}
......
# Add ascii support to emojione
emojione?.ascii = true
\ No newline at end of file
......@@ -10,4 +10,4 @@ class Emojione
return message
RocketChat.callbacks.add 'renderMessage', Emojione, RocketChat.callbacks.priority.LOW
\ No newline at end of file
RocketChat.callbacks.add 'beforeSaveMessage', Emojione, RocketChat.callbacks.priority.LOW
\ No newline at end of file
......@@ -10,7 +10,7 @@ Package.onUse(function(api) {
api.use([
'coffeescript',
'qnub:emojione',
'emojione:emojione',
'rocketchat:lib@0.0.1'
]);
......
......@@ -8,7 +8,7 @@ Meteor.methods
if not room
return false
console.log '[methods] sendMessage -> '.green, 'userId:', Meteor.userId(), 'arguments:', arguments
# console.log '[methods] sendMessage -> '.green, 'userId:', Meteor.userId(), 'arguments:', arguments
message.u = Meteor.users.findOne Meteor.userId(), fields: username: 1
message.ts = new Date()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment