mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-16 07:22:16 -07:00
initial commit
This commit is contained in:
parent
e7a6126fbd
commit
4b0dff4102
40 changed files with 13635 additions and 0 deletions
48
webclientvue/src/pages/HomePage.vue
Normal file
48
webclientvue/src/pages/HomePage.vue
Normal file
|
|
@ -0,0 +1,48 @@
|
|||
<template>
|
||||
<q-page class="row items-center justify-evenly q-pa-md" style="height: 90vh; width: 100vw">
|
||||
<div class="justify-center" style="height: 90%; width: 65%">
|
||||
<q-table
|
||||
title="Games"
|
||||
:rows="games"
|
||||
:columns="gameColumns"
|
||||
row-key="name"
|
||||
:rows-per-page-options="[0]"
|
||||
virtual-scroll
|
||||
:pagination-label="(start, end, total) => `Total games: ${total}`"
|
||||
style="height: 60%"
|
||||
/>
|
||||
|
||||
<q-card style="height: 30%" class="q-mt-md">
|
||||
<q-list bordered separator>
|
||||
<q-item clickable v-ripple v-for="chat in chats" :key="chat.timestamp + Math.random()">
|
||||
<q-item-section
|
||||
style="
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
justify-content: start;
|
||||
align-items: center;
|
||||
"
|
||||
>{{ chat.timestamp }}
|
||||
<q-avatar size=".9em" class="q-ml-sm q-mr-sm"
|
||||
><img :class="chat.avatar === 'user' && 'filter-green'" :src="userBadge"
|
||||
/></q-avatar>
|
||||
{{ `${chat.username}: ${chat.message}` }}
|
||||
</q-item-section>
|
||||
</q-item>
|
||||
</q-list>
|
||||
</q-card>
|
||||
</div>
|
||||
</q-page>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import userBadge from 'assets/pawn_single.svg';
|
||||
import { games, gameColumns } from 'src/fake-data/gameColumns';
|
||||
import { chats } from 'src/fake-data/chats';
|
||||
</script>
|
||||
|
||||
<style scoped>
|
||||
.filter-green {
|
||||
filter: invert(48%) sepia(79%) saturate(2476%) hue-rotate(86deg) brightness(118%) contrast(119%);
|
||||
}
|
||||
</style>
|
||||
Loading…
Add table
Add a link
Reference in a new issue