send emojis as unicode also in MUCs

This commit is contained in:
Christoph Scholz 2018-03-02 15:45:36 +01:00
parent 34ac7e99ab
commit 2195e8de7e
2 changed files with 4 additions and 0 deletions

View File

@ -5,6 +5,7 @@
- Avoid `eval` (via `_.template` from lodash). - Avoid `eval` (via `_.template` from lodash).
- Don't show bookmark toggles when PEP bookmarking not supported by the XMPP server. - Don't show bookmark toggles when PEP bookmarking not supported by the XMPP server.
- Add LibreJS support - Add LibreJS support
- Emojis are now sent in unicode instead of short names (also in MUCs)
### Bugfixes ### Bugfixes

View File

@ -13,6 +13,7 @@
define([ define([
"form-utils", "form-utils",
"converse-core", "converse-core",
"emojione",
"lodash.fp", "lodash.fp",
"tpl!chatarea", "tpl!chatarea",
"tpl!chatroom", "tpl!chatroom",
@ -44,6 +45,7 @@
}(this, function ( }(this, function (
u, u,
converse, converse,
emojione,
fp, fp,
tpl_chatarea, tpl_chatarea,
tpl_chatroom, tpl_chatroom,
@ -969,6 +971,7 @@
* Parameters: * Parameters:
* (String) text: The message text to be sent. * (String) text: The message text to be sent.
*/ */
text = emojione.shortnameToUnicode(text)
const msgid = _converse.connection.getUniqueId(); const msgid = _converse.connection.getUniqueId();
const msg = $msg({ const msg = $msg({
to: this.model.get('jid'), to: this.model.get('jid'),