diff --git a/src/components/emoji_input/emoji_input.js b/src/components/emoji_input/emoji_input.js
index 6dc006f8..94af6e2f 100644
--- a/src/components/emoji_input/emoji_input.js
+++ b/src/components/emoji_input/emoji_input.js
@@ -54,17 +54,28 @@ const EmojiInput = {
required: true,
type: String
},
- emojiPicker: {
+ enableEmojiPicker: {
+ /**
+ * Enables emoji picker support, this implies that custom emoji are supported
+ */
required: false,
type: Boolean,
default: false
},
- emojiPickerExternalTrigger: {
+ hideEmojiButton: {
+ /**
+ enableStickerPicker: {
+ * intended to use with external picker trigger, i.e. you have a button outside
+ * input that will open up the picker, see triggerShowPicker()
+ */
required: false,
type: Boolean,
default: false
},
- stickerPicker: {
+ enableStickerPicker: {
+ /**
+ * Enables sticker picker support, only makes sense when enableEmojiPicker=true
+ */
required: false,
type: Boolean,
default: false
diff --git a/src/components/emoji_input/emoji_input.vue b/src/components/emoji_input/emoji_input.vue
index b077e6e9..53b38573 100644
--- a/src/components/emoji_input/emoji_input.vue
+++ b/src/components/emoji_input/emoji_input.vue
@@ -4,19 +4,19 @@
class="emoji-input"
>
-
+
{
const EmojiPicker = {
props: {
- stickerPicker: {
+ enableStickerPicker: {
required: false,
type: Boolean,
default: false
@@ -97,6 +97,9 @@ const EmojiPicker = {
},
emojisView () {
return this.emojis.filter(value => value.emojis.length > 0)
+ },
+ stickerPickerEnabled () {
+ return (this.$store.state.instance.stickers || []).length !== 0
}
}
}
diff --git a/src/components/emoji_picker/emoji_picker.vue b/src/components/emoji_picker/emoji_picker.vue
index 901520aa..5c139d0e 100644
--- a/src/components/emoji_picker/emoji_picker.vue
+++ b/src/components/emoji_picker/emoji_picker.vue
@@ -17,7 +17,7 @@
@@ -78,9 +78,9 @@
v-model="newStatus.status"
:suggest="emojiUserSuggestor"
class="form-control main-input"
- emoji-picker
- emoji-picker-external-trigger
- sticker-picker
+ enable-emoji-picker
+ hide-emoji-button
+ enable-sticker-picker
@sticker-uploaded="addMediaFile"
@sticker-upload-failed="uploadFailed"
>