Skip to content

Commit cc52183

Browse files
committed
Init the chat. Add the chat stub feature.
1 parent bc1038c commit cc52183

File tree

2 files changed

+38
-2
lines changed

2 files changed

+38
-2
lines changed

quasar.conf.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,8 @@ module.exports = function (ctx) {
6060
'QImg',
6161
'QBanner',
6262
'QSpace',
63-
'QTooltip'
63+
'QTooltip',
64+
'QChatMessage'
6465
],
6566

6667
directives: [

src/pages/Index.vue

Lines changed: 36 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@
3535
Update your private key. It is required to install the node.
3636
</q-banner> -->
3737
<q-btn color="vgreen" class="text-vdark q-mx-xs" label="Get the vDex node" @click=getInstaller />
38+
<q-btn color="vdark" class="text-vgrey q-mx-xs" label="Chat" @click="chatDialog=true" />
3839
</div>
3940
</div>
4041
</div>
@@ -363,6 +364,39 @@
363364
</q-card-actions>
364365
</q-card>
365366
</q-dialog>
367+
<!-- chat dialog -->
368+
<q-dialog v-model="chatDialog">
369+
<q-card style="min-width: 50vw; max-width: 50vw;" class="bg-vdark text-vgrey">
370+
<q-card-section>
371+
<div class="text-h6">Chat</div>
372+
<q-banner dense inline-actions class="text-vdark bg-vgreen">
373+
The chat widget is currently disabled, the data is artificial.
374+
</q-banner>
375+
</q-card-section>
376+
<q-card-section style="min-height: 40vh; max-height: 40vh" class="scroll bg-vblack q-ma-sm">
377+
<div style="width: 100%;">
378+
<q-chat-message name="me" bg-color="vgreen" :text="['hey, how are you?']" sent />
379+
<q-chat-message name="Support" bg-color="vdark" text-color="white" :text="['doing fine, how r you?']" />
380+
<q-chat-message name="me" bg-color="vgreen" :text="['hey, how are you?']" sent />
381+
<q-chat-message name="Support" bg-color="vdark" text-color="white" :text="['doing fine, how r you?']" />
382+
<q-chat-message name="me" bg-color="vgreen" :text="['hey, how are you?']" sent />
383+
<q-chat-message name="Support" bg-color="vdark" text-color="white" :text="['doing fine, how r you?']" />
384+
<q-chat-message name="me" bg-color="vgreen" :text="['hey, how are you?']" sent />
385+
<q-chat-message name="Support" bg-color="vdark" text-color="white" :text="['doing fine, how r you?']" />
386+
</div>
387+
</q-card-section>
388+
<q-card-section>
389+
<q-input filled autogrow dark >
390+
<template v-slot:after>
391+
<q-btn round dense flat icon="send" />
392+
</template>
393+
</q-input>
394+
</q-card-section>
395+
<q-card-actions align="right">
396+
<q-btn flat label="Close" v-close-popup />
397+
</q-card-actions>
398+
</q-card>
399+
</q-dialog>
366400
</q-page>
367401
</q-page-container>
368402
</q-layout>
@@ -440,7 +474,8 @@ export default {
440474
registered_nodes: 0,
441475
registered_nodes_names: [],
442476
privateState: 'none',
443-
geoData: 'test'
477+
geoData: 'test',
478+
chatDialog: false
444479
}
445480
},
446481
mounted () {

0 commit comments

Comments
 (0)