modernize group.vue

This commit is contained in:
ThatOneCalculator 2022-09-13 17:08:09 -07:00
parent 7a21709309
commit 031b3661e2

View file

@ -1,5 +1,7 @@
<template> <template>
<div class="mk-group-page"> <MkStickyContainer>
<template #header><MkPageHeader/></template>
<div class="mk-group-page">
<transition :name="$store.state.animation ? 'zoom' : ''" mode="out-in"> <transition :name="$store.state.animation ? 'zoom' : ''" mode="out-in">
<div v-if="group" class="_section"> <div v-if="group" class="_section">
<div class="_content" style="display: flex; gap: var(--margin); flex-wrap: wrap;"> <div class="_content" style="display: flex; gap: var(--margin); flex-wrap: wrap;">
@ -10,10 +12,8 @@
</div> </div>
</div> </div>
</transition> </transition>
<transition :name="$store.state.animation ? 'zoom' : ''" mode="out-in"> <transition :name="$store.state.animation ? 'zoom' : ''" mode="out-in">
<div v-if="group" class="_section members _gap"> <div v-if="group" class="_section members _gap">
<div class="_title">{{ $ts.members }}</div>
<div class="_content"> <div class="_content">
<div class="users"> <div class="users">
<div v-for="user in users" :key="user.id" class="user _panel"> <div v-for="user in users" :key="user.id" class="user _panel">
@ -30,12 +30,15 @@
</div> </div>
</div> </div>
</transition> </transition>
</div> </div>
</MkStickyContainer>
</template> </template>
<script lang="ts"> <script lang="ts" setup>
import { computed, defineComponent } from 'vue'; import { computed, defineComponent } from 'vue';
import MkButton from '@/components/MkButton.vue'; import MkButton from '@/components/MkButton.vue';
import { definePageMetadata } from '@/scripts/page-metadata';\
import { i18n } from '@/i18n';
import * as os from '@/os'; import * as os from '@/os';
export default defineComponent({ export default defineComponent({
@ -139,10 +142,22 @@ export default defineComponent({
} }
} }
}); });
definePageMetadata(computed(() => ({
title: i18n.ts.members,
icon: 'fas fa-users',
})));
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.mk-group-page { .mk-group-page {
> ._section {
> ._content {
padding-top: 1rem;
justify-content: center;
}
}
> .members { > .members {
> ._content { > ._content {
> .users { > .users {
@ -173,5 +188,5 @@ export default defineComponent({
} }
} }
} }
} }
</style> </style>