mirror of
https://github.com/lingble/chatwoot.git
synced 2026-03-19 22:52:35 +00:00
fix: Remove the usage of asyncComponent in emoji picker (#10232)
This PR has the following fixes 1. preview of article inside the iframe, earlier this didn't work because the iframe didn't get the URL correctly. We fix that by passing the URL is a query instead 2. Emoji picker caused a weird redirect, this was only happening when the chunk was loaded async, this PR changes it to use regular loading instead
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
<script>
|
||||
import { defineAsyncComponent } from 'vue';
|
||||
import { mapGetters } from 'vuex';
|
||||
|
||||
import ChatAttachmentButton from 'widget/components/ChatAttachment.vue';
|
||||
@@ -9,9 +8,7 @@ import FluentIcon from 'shared/components/FluentIcon/Index.vue';
|
||||
import ResizableTextArea from 'shared/components/ResizableTextArea.vue';
|
||||
import { useDarkMode } from 'widget/composables/useDarkMode';
|
||||
|
||||
const EmojiInput = defineAsyncComponent(
|
||||
() => import('shared/components/emoji/EmojiInput.vue')
|
||||
);
|
||||
import EmojiInput from 'shared/components/emoji/EmojiInput.vue';
|
||||
|
||||
export default {
|
||||
name: 'ChatInputWrap',
|
||||
|
||||
@@ -36,7 +36,6 @@ export default createRouter({
|
||||
{
|
||||
path: '/article',
|
||||
name: 'article-viewer',
|
||||
props: true,
|
||||
component: () => import('./views/ArticleViewer.vue'),
|
||||
},
|
||||
],
|
||||
|
||||
@@ -6,17 +6,11 @@ export default {
|
||||
components: {
|
||||
IframeLoader,
|
||||
},
|
||||
props: {
|
||||
link: {
|
||||
type: String,
|
||||
default: '',
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<div class="bg-white h-full">
|
||||
<IframeLoader :url="link" />
|
||||
<IframeLoader :url="$route.query.link" />
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -79,7 +79,7 @@ export default {
|
||||
}
|
||||
this.$router.push({
|
||||
name: 'article-viewer',
|
||||
params: { link: linkToOpen },
|
||||
query: { link: linkToOpen },
|
||||
});
|
||||
},
|
||||
viewAllArticles() {
|
||||
|
||||
Reference in New Issue
Block a user