diff --git a/view/theme/frio/js/theme.js b/view/theme/frio/js/theme.js index 3846c2c3e3..28bc0c4332 100644 --- a/view/theme/frio/js/theme.js +++ b/view/theme/frio/js/theme.js @@ -941,4 +941,36 @@ function toggleDropdownText(elm) { function hasClass(elem, cls) { return (" " + elem.className + " ").indexOf(" " + cls + " ") > -1; } + +function insertEmoji(target, item){ + let dest = ''; + switch (target) { + case 'comment': + dest='#comment-edit-text-' + item; + break; + case 'jot': + dest='.profile-jot-text'; + break; + case 'pn': + dest='#comment-edit-text-input'; + } + emojiPicker(dest) +}; + +function emojiPicker(dest) { + console.log(this); + if (typeof this.EmojiPicker == "undefined") { + + new EmojiPicker({ + trigger: [ + { + selector: '.emojis', + insertInto: dest + } + ], + closeButton: true, + }); + } + console.log(this); +} // @license-end diff --git a/view/theme/frio/templates/comment_item.tpl b/view/theme/frio/templates/comment_item.tpl index 45a6116aa3..b9fc557833 100644 --- a/view/theme/frio/templates/comment_item.tpl +++ b/view/theme/frio/templates/comment_item.tpl @@ -36,6 +36,9 @@ +