diff --git a/app/javascript/dashboard/components-next/message/bubbles/Attachments.vue b/app/javascript/dashboard/components-next/message/bubbles/Attachments.vue
index d3cfb6c1d..1dcdf21d7 100644
--- a/app/javascript/dashboard/components-next/message/bubbles/Attachments.vue
+++ b/app/javascript/dashboard/components-next/message/bubbles/Attachments.vue
@@ -1,13 +1,7 @@
-
-
-
-
-
-
-
-
-
-
+
diff --git a/app/javascript/dashboard/components-next/message/bubbles/Email.vue b/app/javascript/dashboard/components-next/message/bubbles/Email.vue
index 3863405df..a61d95d6d 100644
--- a/app/javascript/dashboard/components-next/message/bubbles/Email.vue
+++ b/app/javascript/dashboard/components-next/message/bubbles/Email.vue
@@ -3,14 +3,9 @@ import { computed, useTemplateRef, ref, watch } from 'vue';
import { Letter } from 'vue-letter';
import Icon from 'next/icon/Icon.vue';
import BaseBubble from 'next/message/bubbles/Base.vue';
-
-import ImageChip from 'next/message/chips/Image.vue';
-import VideoChip from 'next/message/chips/Video.vue';
-import AudioChip from 'next/message/chips/Audio.vue';
-import FileChip from 'next/message/chips/File.vue';
+import AttachmentChips from 'next/message/chips/AttachmentChips.vue';
import { MESSAGE_STATUS } from '../constants';
-import { ATTACHMENT_TYPES } from '../constants';
const props = defineProps({
content: {
@@ -101,30 +96,6 @@ const showMeta = computed(() => {
subject.value
);
});
-
-const mediaAttachments = computed(() => {
- const allowedTypes = [ATTACHMENT_TYPES.IMAGE, ATTACHMENT_TYPES.VIDEO];
- const mediaTypes = props.attachments.filter(attachment =>
- allowedTypes.includes(attachment.fileType)
- );
-
- return mediaTypes.sort(
- (a, b) =>
- allowedTypes.indexOf(a.fileType) - allowedTypes.indexOf(b.fileType)
- );
-});
-
-const recordings = computed(() => {
- return props.attachments.filter(
- attachment => attachment.fileType === ATTACHMENT_TYPES.AUDIO
- );
-});
-
-const files = computed(() => {
- return props.attachments.filter(
- attachment => attachment.fileType === ATTACHMENT_TYPES.FILE
- );
-});
@@ -182,33 +153,7 @@ const files = computed(() => {
/>
diff --git a/app/javascript/dashboard/components-next/message/bubbles/Text.vue b/app/javascript/dashboard/components-next/message/bubbles/Text.vue
index 8d8231512..b269264e1 100644
--- a/app/javascript/dashboard/components-next/message/bubbles/Text.vue
+++ b/app/javascript/dashboard/components-next/message/bubbles/Text.vue
@@ -1,15 +1,11 @@
-
-
-
-
-
-
-
-
-
-
+
diff --git a/app/javascript/dashboard/components-next/message/chips/AttachmentChips.vue b/app/javascript/dashboard/components-next/message/chips/AttachmentChips.vue
new file mode 100644
index 000000000..0a14b4666
--- /dev/null
+++ b/app/javascript/dashboard/components-next/message/chips/AttachmentChips.vue
@@ -0,0 +1,92 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+