aboutsummaryrefslogtreecommitdiff
path: root/src/components
diff options
context:
space:
mode:
Diffstat (limited to 'src/components')
-rw-r--r--src/components/features_panel/features_panel.js2
-rw-r--r--src/components/features_panel/features_panel.vue4
-rw-r--r--src/components/shout_panel/shout_panel.js (renamed from src/components/chat_panel/chat_panel.js)8
-rw-r--r--src/components/shout_panel/shout_panel.vue (renamed from src/components/chat_panel/chat_panel.vue)44
-rw-r--r--src/components/side_drawer/side_drawer.js1
5 files changed, 29 insertions, 30 deletions
diff --git a/src/components/features_panel/features_panel.js b/src/components/features_panel/features_panel.js
index 8b142d08..d177efeb 100644
--- a/src/components/features_panel/features_panel.js
+++ b/src/components/features_panel/features_panel.js
@@ -2,7 +2,7 @@ import fileSizeFormatService from '../../services/file_size_format/file_size_for
const FeaturesPanel = {
computed: {
- chat: function () { return this.$store.state.instance.chatAvailable },
+ shout: function () { return this.$store.state.instance.shoutAvailable },
pleromaChatMessages: function () { return this.$store.state.instance.pleromaChatMessagesAvailable },
gopher: function () { return this.$store.state.instance.gopherAvailable },
whoToFollow: function () { return this.$store.state.instance.suggestionsEnabled },
diff --git a/src/components/features_panel/features_panel.vue b/src/components/features_panel/features_panel.vue
index 9605d09d..a58a99af 100644
--- a/src/components/features_panel/features_panel.vue
+++ b/src/components/features_panel/features_panel.vue
@@ -8,8 +8,8 @@
</div>
<div class="panel-body features-panel">
<ul>
- <li v-if="chat">
- {{ $t('features_panel.chat') }}
+ <li v-if="shout">
+ {{ $t('features_panel.shout') }}
</li>
<li v-if="pleromaChatMessages">
{{ $t('features_panel.pleroma_chat_messages') }}
diff --git a/src/components/chat_panel/chat_panel.js b/src/components/shout_panel/shout_panel.js
index 556694ae..a6168971 100644
--- a/src/components/chat_panel/chat_panel.js
+++ b/src/components/shout_panel/shout_panel.js
@@ -10,7 +10,7 @@ library.add(
faTimes
)
-const chatPanel = {
+const shoutPanel = {
props: [ 'floating' ],
data () {
return {
@@ -21,12 +21,12 @@ const chatPanel = {
},
computed: {
messages () {
- return this.$store.state.chat.messages
+ return this.$store.state.shout.messages
}
},
methods: {
submit (message) {
- this.$store.state.chat.channel.push('new_msg', { text: message }, 10000)
+ this.$store.state.shout.channel.push('new_msg', { text: message }, 10000)
this.currentMessage = ''
},
togglePanel () {
@@ -50,4 +50,4 @@ const chatPanel = {
}
}
-export default chatPanel
+export default shoutPanel
diff --git a/src/components/chat_panel/chat_panel.vue b/src/components/shout_panel/shout_panel.vue
index 8a829115..f90baf80 100644
--- a/src/components/chat_panel/chat_panel.vue
+++ b/src/components/shout_panel/shout_panel.vue
@@ -1,12 +1,12 @@
<template>
<div
v-if="!collapsed || !floating"
- class="chat-panel"
+ class="shout-panel"
>
<div class="panel panel-default">
<div
class="panel-heading timeline-heading"
- :class="{ 'chat-heading': floating }"
+ :class="{ 'shout-heading': floating }"
@click.stop.prevent="togglePanel"
>
<div class="title">
@@ -18,33 +18,33 @@
/>
</div>
</div>
- <div class="chat-window">
+ <div class="shout-window">
<div
v-for="message in messages"
:key="message.id"
- class="chat-message"
+ class="shout-message"
>
- <span class="chat-avatar">
+ <span class="shout-avatar">
<img :src="message.author.avatar">
</span>
- <div class="chat-content">
+ <div class="shout-content">
<router-link
- class="chat-name"
+ class="shout-name"
:to="userProfileLink(message.author)"
>
{{ message.author.username }}
</router-link>
<br>
- <span class="chat-text">
+ <span class="shout-text">
{{ message.text }}
</span>
</div>
</div>
</div>
- <div class="chat-input">
+ <div class="shout-input">
<textarea
v-model="currentMessage"
- class="chat-input-textarea"
+ class="shout-input-textarea"
rows="1"
@keyup.enter="submit(currentMessage)"
/>
@@ -53,11 +53,11 @@
</div>
<div
v-else
- class="chat-panel"
+ class="shout-panel"
>
<div class="panel panel-default">
<div
- class="panel-heading stub timeline-heading chat-heading"
+ class="panel-heading stub timeline-heading shout-heading"
@click.stop.prevent="togglePanel"
>
<div class="title">
@@ -72,12 +72,12 @@
</div>
</template>
-<script src="./chat_panel.js"></script>
+<script src="./shout_panel.js"></script>
<style lang="scss">
@import '../../_variables.scss';
-.floating-chat {
+.floating-shout {
position: fixed;
right: 0px;
bottom: 0px;
@@ -85,8 +85,8 @@
max-width: 25em;
}
-.chat-panel {
- .chat-heading {
+.shout-panel {
+ .shout-heading {
cursor: pointer;
.icon {
@@ -102,22 +102,22 @@
}
}
- .chat-window {
+ .shout-window {
overflow-y: auto;
overflow-x: hidden;
max-height: 20em;
}
- .chat-window-container {
+ .shout-window-container {
height: 100%;
}
- .chat-message {
+ .shout-message {
display: flex;
padding: 0.2em 0.5em
}
- .chat-avatar {
+ .shout-avatar {
img {
height: 24px;
width: 24px;
@@ -128,7 +128,7 @@
}
}
- .chat-input {
+ .shout-input {
display: flex;
textarea {
flex: 1;
@@ -138,7 +138,7 @@
}
}
- .chat-panel {
+ .shout-panel {
.title {
display: flex;
justify-content: space-between;
diff --git a/src/components/side_drawer/side_drawer.js b/src/components/side_drawer/side_drawer.js
index fe736168..0faf3b9e 100644
--- a/src/components/side_drawer/side_drawer.js
+++ b/src/components/side_drawer/side_drawer.js
@@ -49,7 +49,6 @@ const SideDrawer = {
currentUser () {
return this.$store.state.users.currentUser
},
- chat () { return this.$store.state.chat.channel.state === 'joined' },
unseenNotifications () {
return unseenNotificationsFromStore(this.$store)
},