|
@@ -123,7 +123,8 @@ const props = defineProps<{
|
|
|
secretNumber?: string | number | null
|
|
|
}>()
|
|
|
|
|
|
-const emits = defineEmits(['close', 'change-type', 'reply', 'refresh'])
|
|
|
+// const emits = defineEmits(['close', 'change-type', 'reply', 'refresh'])
|
|
|
+const emits = defineEmits(['close', 'reply', 'refresh', 'clear-search'])
|
|
|
const { fetch: getMessageHistory, result: history, loading } = useFetch('getMessageHistory')
|
|
|
const historyReverse = computed(() => {
|
|
|
return ((history.value as any) || []).reverse()
|
|
@@ -276,12 +277,12 @@ const toggleHistory = () => {
|
|
|
showHistory.value = !showHistory.value
|
|
|
}
|
|
|
|
|
|
-const onReply = () => {
|
|
|
- if (currentMessage.value) {
|
|
|
- emits('change-type', 'send')
|
|
|
- emits('reply', currentMessage.value.sendUserId, currentMessage.value.sendUserName)
|
|
|
- }
|
|
|
-}
|
|
|
+// const onReply = () => {
|
|
|
+// if (currentMessage.value) {
|
|
|
+// emits('change-type', 'send')
|
|
|
+// emits('reply', currentMessage.value.sendUserId, currentMessage.value.sendUserName)
|
|
|
+// }
|
|
|
+// }
|
|
|
|
|
|
const onContentClick = (e: Event) => {
|
|
|
const target = e.target as HTMLButtonElement
|
|
@@ -290,6 +291,7 @@ const onContentClick = (e: Event) => {
|
|
|
previewModalVisible.value = true
|
|
|
paperPath.value = path
|
|
|
}
|
|
|
+ bus.emit('clear-search')
|
|
|
}
|
|
|
|
|
|
onUnmounted(() => {
|