mirror of
https://github.com/Drop-OSS/drop.git
synced 2025-11-14 08:41:15 +10:00
Create signout.vue to sign out :shocked:
This commit is contained in:
41
pages/signout.vue
Normal file
41
pages/signout.vue
Normal file
@ -0,0 +1,41 @@
|
||||
<template>
|
||||
<div class="flex min-h-screen flex-1 bg-zinc-900">
|
||||
<div
|
||||
class="flex flex-1 flex-col justify-center px-4 py-12 sm:px-6 lg:flex-none lg:px-20 xl:px-24"
|
||||
>
|
||||
<div class="mx-auto w-full max-w-sm lg:w-96">
|
||||
<div>
|
||||
<Logo class="h-10 w-auto" />
|
||||
<h2
|
||||
class="mt-8 text-2xl font-bold font-display leading-9 tracking-tight text-zinc-100"
|
||||
>
|
||||
Signing out...
|
||||
</h2>
|
||||
<p class="mt-2 text-sm leading-6 text-zinc-400">
|
||||
You are being signed out of Drop.
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="relative hidden w-0 flex-1 lg:block">
|
||||
<img
|
||||
class="absolute inset-0 h-full w-full object-cover"
|
||||
src="/wallpapers/signin.jpg"
|
||||
alt=""
|
||||
/>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import Logo from "~/components/Logo.vue";
|
||||
const router = useRouter();
|
||||
|
||||
// Clear the user state
|
||||
const user = useUser();
|
||||
user.value = null;
|
||||
|
||||
// Redirect to signin page after signout
|
||||
await $fetch("/signout");
|
||||
router.push("/signin");
|
||||
</script>
|
||||
Reference in New Issue
Block a user