feat: improve email verification stage
This commit is contained in:
3 files changed
+21
-12
No files matched your search
@@ -92,12 +92,8 @@
|
||||
) {
|
||||
if (res.verify_email_sent) return (stage = 'verify')
|
||||
|
||||
if (registrationMode == 'RequireApplication') {
|
||||
return toast({
|
||||
content: $t('toast.waitApplication'),
|
||||
type: 'info',
|
||||
})
|
||||
}
|
||||
if (registrationMode == 'RequireApplication')
|
||||
return stage == 'application'
|
||||
} else {
|
||||
throw new Error($t('toast.failSignup'))
|
||||
}
|
||||
@@ -319,6 +315,16 @@
|
||||
</Button>
|
||||
</form>
|
||||
</div>
|
||||
{:else if stage == 'application'}
|
||||
<div class="flex-2/3 flex flex-col h-full justify-center gap-8">
|
||||
<h2 class="font-medium text-3xl">
|
||||
{$t('form.signup.application.notice')}
|
||||
</h2>
|
||||
<Button href="/signup" rounding="pill">
|
||||
<Icon src={ArrowLeft} size="16" micro />
|
||||
{$t('common.back')}
|
||||
</Button>
|
||||
</div>
|
||||
{/if}
|
||||
<Material
|
||||
color="uniform"
|
||||
|
||||
@@ -1,16 +1,18 @@
|
||||
<script>
|
||||
import { LINKED_INSTANCE_URL } from '$lib/instance.svelte'
|
||||
import { t } from '$lib/i18n/translations'
|
||||
import { Check, Icon } from 'svelte-hero-icons'
|
||||
import { CheckCircle, Icon } from 'svelte-hero-icons'
|
||||
</script>
|
||||
|
||||
<div class="flex flex-col items-center h-max my-auto gap-2">
|
||||
<div class="flex flex-col h-max my-auto gap-2 max-w-xl mx-auto">
|
||||
<div
|
||||
class="rounded-full bg-green-200 dark:bg-green-700 text-green-600 dark:text-green-200 p-3"
|
||||
class="rounded-full bg-green-200 dark:bg-green-500/20 text-white p-2 w-max"
|
||||
>
|
||||
<Icon src={Check} size="32" mini />
|
||||
<Icon src={CheckCircle} size="48" solid />
|
||||
</div>
|
||||
<h1 class="text-green-800 dark:text-green-200 text-2xl font-semibold">
|
||||
<h1
|
||||
class="text-green-800 dark:text-green-200 text-2xl font-medium tracking-tight"
|
||||
>
|
||||
{$t('message.success')}
|
||||
</h1>
|
||||
<p class="text-green-800 dark:text-green-200">
|
||||
|
||||
Reference in new issue
Block a user