diff options
| author | syuilo <Syuilotan@yahoo.co.jp> | 2022-12-27 14:36:33 +0900 |
|---|---|---|
| committer | syuilo <Syuilotan@yahoo.co.jp> | 2022-12-27 14:36:33 +0900 |
| commit | 9384f5399da39e53855beb8e7f8ded1aa56bf72e (patch) | |
| tree | ce5959571a981b9c4047da3c7b3fd080aa44222c /packages/client/src/pages/admin/overview.users.vue | |
| parent | wip: retention for dashboard (diff) | |
| download | sharkey-9384f5399da39e53855beb8e7f8ded1aa56bf72e.tar.gz sharkey-9384f5399da39e53855beb8e7f8ded1aa56bf72e.tar.bz2 sharkey-9384f5399da39e53855beb8e7f8ded1aa56bf72e.zip | |
rename: client -> frontend
Diffstat (limited to 'packages/client/src/pages/admin/overview.users.vue')
| -rw-r--r-- | packages/client/src/pages/admin/overview.users.vue | 57 |
1 files changed, 0 insertions, 57 deletions
diff --git a/packages/client/src/pages/admin/overview.users.vue b/packages/client/src/pages/admin/overview.users.vue deleted file mode 100644 index 5d4be11742..0000000000 --- a/packages/client/src/pages/admin/overview.users.vue +++ /dev/null @@ -1,57 +0,0 @@ -<template> -<div :class="$style.root"> - <transition :name="$store.state.animation ? 'zoom' : ''" mode="out-in"> - <MkLoading v-if="fetching"/> - <div v-else class="users"> - <MkA v-for="(user, i) in newUsers" :key="user.id" :to="`/user-info/${user.id}`" class="user"> - <MkUserCardMini :user="user"/> - </MkA> - </div> - </transition> -</div> -</template> - -<script lang="ts" setup> -import { onMounted, onUnmounted, ref } from 'vue'; -import * as os from '@/os'; -import { useInterval } from '@/scripts/use-interval'; -import MkUserCardMini from '@/components/MkUserCardMini.vue'; - -let newUsers = $ref(null); -let fetching = $ref(true); - -const fetch = async () => { - const _newUsers = await os.api('admin/show-users', { - limit: 5, - sort: '+createdAt', - origin: 'local', - }); - newUsers = _newUsers; - fetching = false; -}; - -useInterval(fetch, 1000 * 60, { - immediate: true, - afterMounted: true, -}); -</script> - -<style lang="scss" module> -.root { - &:global { - > .users { - .chart-move { - transition: transform 1s ease; - } - - display: grid; - grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); - grid-gap: 12px; - - > .user:hover { - text-decoration: none; - } - } - } -} -</style> |