mirror of
https://github.com/IT4Change/Ocelot-Social.git
synced 2025-12-13 07:45:56 +00:00
add store chat-modul, showChatModul
This commit is contained in:
parent
9a690d6051
commit
9b4a71bd96
@ -14,11 +14,12 @@
|
|||||||
<modal />
|
<modal />
|
||||||
</client-only>
|
</client-only>
|
||||||
<client-only>
|
<client-only>
|
||||||
<div v-if="true" class="chat-modul" ><chat-modul :singleRoom="true"/></div>
|
<div v-if="$store.getters['chat-modul/showChatModul'].showChatModul" class="chat-modul" >
|
||||||
|
<div class="close" @click="$store.commit('chat-modul/SET_OPEN_CHAT_MODUL', false)">x close chat</div>
|
||||||
|
<chat-modul :singleRoom="true"/></div>
|
||||||
</client-only>
|
</client-only>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import seo from '~/mixins/seo'
|
import seo from '~/mixins/seo'
|
||||||
import mobile from '~/mixins/mobile'
|
import mobile from '~/mixins/mobile'
|
||||||
@ -48,12 +49,17 @@ export default {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.chat-modul {
|
.chat-modul {
|
||||||
background-color: red;
|
background-color: rgb(233, 228, 228);
|
||||||
height: 594px;
|
height: 634px;
|
||||||
width: 355px;
|
width: 355px;
|
||||||
position: absolute;
|
position: fixed;
|
||||||
bottom: 45px;
|
bottom: 45px;
|
||||||
right: 0;
|
right: 0;
|
||||||
z-index: 10000;
|
z-index: 10000;
|
||||||
|
.close {
|
||||||
|
padding: 10px;
|
||||||
|
color: blue;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
@ -80,7 +80,7 @@
|
|||||||
@update="updateFollow"
|
@update="updateFollow"
|
||||||
/>
|
/>
|
||||||
<base-button
|
<base-button
|
||||||
|
@click="$store.commit('chat-modul/SET_OPEN_CHAT_MODUL', true)"
|
||||||
v-tooltip="{
|
v-tooltip="{
|
||||||
content: $t('notifications.headerMenuButton.chat'),
|
content: $t('notifications.headerMenuButton.chat'),
|
||||||
placement: 'bottom-start',
|
placement: 'bottom-start',
|
||||||
|
|||||||
19
webapp/store/chat-modul.js
Normal file
19
webapp/store/chat-modul.js
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
export const state = () => {
|
||||||
|
return {
|
||||||
|
showChatModul: false,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export const mutations = {
|
||||||
|
SET_OPEN_CHAT_MODUL(state, ctx) {
|
||||||
|
console.log(ctx)
|
||||||
|
state.showChatModul = ctx || false
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
|
export const getters = {
|
||||||
|
showChatModul(state) {
|
||||||
|
console.log('getter', state)
|
||||||
|
return state
|
||||||
|
},
|
||||||
|
}
|
||||||
Loading…
x
Reference in New Issue
Block a user