From bed109ae46a7ae6db7264b9cfb1d3ed88372e270 Mon Sep 17 00:00:00 2001 From: Henry Jameson Date: Tue, 8 Oct 2019 20:54:30 +0300 Subject: [PATCH] start loading emoji when picker is open --- src/components/emoji_input/emoji_input.js | 2 ++ src/components/emoji_picker/emoji_picker.js | 3 --- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/components/emoji_input/emoji_input.js b/src/components/emoji_input/emoji_input.js index a586b8191e..920fd4bd9c 100644 --- a/src/components/emoji_input/emoji_input.js +++ b/src/components/emoji_input/emoji_input.js @@ -165,6 +165,7 @@ const EmojiInput = { methods: { triggerShowPicker () { this.showPicker = true + this.$refs.picker.startEmojiLoad() this.$nextTick(() => { this.scrollIntoView() }) @@ -181,6 +182,7 @@ const EmojiInput = { this.showPicker = !this.showPicker if (this.showPicker) { this.scrollIntoView() + this.$refs.picker.startEmojiLoad() } }, replace (replacement) { diff --git a/src/components/emoji_picker/emoji_picker.js b/src/components/emoji_picker/emoji_picker.js index 11dbdf4485..29e072996d 100644 --- a/src/components/emoji_picker/emoji_picker.js +++ b/src/components/emoji_picker/emoji_picker.js @@ -33,9 +33,6 @@ const EmojiPicker = { components: { StickerPicker: () => import('../sticker_picker/sticker_picker.vue') }, - mounted () { - this.startEmojiLoad() - }, methods: { onEmoji (emoji) { const value = emoji.imageUrl ? `:${emoji.displayText}:` : emoji.replacement