Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
fix: replace emoji-mart-vue-fast lib usage with nextcloud/vue function
Signed-off-by: Maksim Sukharev <[email protected]>
  • Loading branch information
Antreesy committed May 7, 2024
commit 90054adfce5af926d413c6453773f80e8c964752
Original file line number Diff line number Diff line change
Expand Up @@ -248,8 +248,6 @@
</template>

<script>
import { frequently, EmojiIndex as EmojiIndexFactory } from 'emoji-mart-vue-fast'
import data from 'emoji-mart-vue-fast/data/all.json'
import { toRefs } from 'vue'

import AccountIcon from 'vue-material-design-icons/Account.vue'
Expand Down Expand Up @@ -286,6 +284,7 @@ import NcActionSeparator from '@nextcloud/vue/dist/Components/NcActionSeparator.
import NcActionText from '@nextcloud/vue/dist/Components/NcActionText.js'
import NcButton from '@nextcloud/vue/dist/Components/NcButton.js'
import NcEmojiPicker from '@nextcloud/vue/dist/Components/NcEmojiPicker.js'
import { emojiSearch } from '@nextcloud/vue/dist/Functions/emoji.js'

import { useMessageInfo } from '../../../../../composables/useMessageInfo.js'
import { CONVERSATION, ATTENDEE } from '../../../../../constants.js'
Expand All @@ -295,7 +294,6 @@ import { useReactionsStore } from '../../../../../stores/reactions.js'
import { copyConversationLinkToClipboard } from '../../../../../utils/handleUrl.ts'
import { parseMentions } from '../../../../../utils/textParse.ts'

const EmojiIndex = new EmojiIndexFactory(data)
const supportReminders = getCapabilities()?.spreed?.features?.includes('remind-me-later')

export default {
Expand Down Expand Up @@ -759,9 +757,7 @@ export default {
},

updateFrequentlyUsedEmojis() {
this.frequentlyUsedEmojis = frequently.get(5).map(emojiStrings => {
return EmojiIndex.emoji(emojiStrings).native
})
this.frequentlyUsedEmojis = emojiSearch('', 5).map(emoji => emoji.native)
},

getTimestamp(momentObject) {
Expand Down