2023-04-27 11:44:38 +09:00
|
|
|
<template>
|
|
|
|
<div>
|
|
|
|
{{ i18n.ts.processing }}
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
|
|
|
|
<script lang="ts" setup>
|
|
|
|
import { onMounted } from "vue";
|
|
|
|
import * as os from "@/os";
|
|
|
|
import { i18n } from "@/i18n";
|
|
|
|
import { definePageMetadata } from "@/scripts/page-metadata";
|
2023-04-27 12:10:42 +09:00
|
|
|
import { useRouter } from "@/router";
|
|
|
|
|
|
|
|
const router = useRouter();
|
2023-04-27 11:44:38 +09:00
|
|
|
|
|
|
|
const props = defineProps<{
|
|
|
|
code: string;
|
|
|
|
}>();
|
|
|
|
|
|
|
|
onMounted(async () => {
|
|
|
|
await os.alert({
|
|
|
|
type: "info",
|
|
|
|
text: i18n.t("clickToFinishEmailVerification", { ok: i18n.ts.gotIt }),
|
|
|
|
});
|
2023-04-27 12:03:04 +09:00
|
|
|
await os.api("verify-email", {
|
2023-04-27 11:44:38 +09:00
|
|
|
code: props.code,
|
|
|
|
});
|
2023-04-27 12:10:42 +09:00
|
|
|
router.push("/");
|
2023-04-27 11:44:38 +09:00
|
|
|
});
|
|
|
|
|
|
|
|
const headerActions = $computed(() => []);
|
|
|
|
|
|
|
|
const headerTabs = $computed(() => []);
|
|
|
|
|
|
|
|
definePageMetadata({
|
|
|
|
title: "Verify email",
|
|
|
|
icon: "ph-user ph-bold ph-lg",
|
|
|
|
});
|
|
|
|
</script>
|