You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
38 lines
832 B
Vue
38 lines
832 B
Vue
<script setup>
|
|
import MessageComposition from "../keyboard/MessageComposition.vue";
|
|
import ChatHistory from "./ChatHistory.vue";
|
|
</script>
|
|
|
|
<template>
|
|
<div>
|
|
<!-- Move this button in the header -->
|
|
<div id="chat-view" v-show="!writeMessage">
|
|
<button alt="Back" name="Back" @click="this.$emit('hideChat')">←</button>
|
|
<ChatHistory :chat-id="chatId" />
|
|
<button
|
|
alt="write message"
|
|
name="write-message"
|
|
@click="this.writeMessage = true"
|
|
>
|
|
+
|
|
</button>
|
|
</div>
|
|
<MessageComposition
|
|
v-if="writeMessage"
|
|
:chat-id="chatId"
|
|
@hideMessageHistory="this.writeMessage = false"
|
|
/>
|
|
</div>
|
|
</template>
|
|
|
|
<script>
|
|
export default {
|
|
data() {
|
|
return { writeMessage: false };
|
|
},
|
|
props: { chatId: Number },
|
|
};
|
|
</script>
|
|
|
|
<style scoped></style>
|