From c0746289e8ff1c4509ea544469333baf116dbeb8 Mon Sep 17 00:00:00 2001 From: ivarlovlie Date: Mon, 10 Oct 2022 00:38:10 +0800 Subject: refactor: Update imports and clean up --- .../routes/(main)/(public)/sign-up/+page.svelte | 24 +++++----------------- 1 file changed, 5 insertions(+), 19 deletions(-) (limited to 'code/app/src/routes/(main)/(public)/sign-up') diff --git a/code/app/src/routes/(main)/(public)/sign-up/+page.svelte b/code/app/src/routes/(main)/(public)/sign-up/+page.svelte index 0dfa41a..f2f1695 100644 --- a/code/app/src/routes/(main)/(public)/sign-up/+page.svelte +++ b/code/app/src/routes/(main)/(public)/sign-up/+page.svelte @@ -3,8 +3,8 @@ import { create_account } from "$lib/api/user"; import { Button, Input, Alert } from "$lib/components"; import LL from "$lib/i18n/i18n-svelte"; - import type { CreateAccountPayload } from "$lib/models/CreateAccountPayload"; - import type { ErrorResult } from "$lib/models/ErrorResult"; + import type { CreateAccountPayload } from "$lib/models/internal/CreateAccountPayload"; + import type { ErrorResult } from "$lib/models/internal/ErrorResult"; const formData = { username: "", @@ -16,8 +16,7 @@ title: "", } as ErrorResult; let loading = false; - $: showErrorAlert = - (errorData?.text.length ?? 0 + errorData?.title.length ?? 0) > 0; + $: showErrorAlert = (errorData?.text.length ?? 0 + errorData?.title.length ?? 0) > 0; async function submitFormAsync() { loading = true; @@ -49,13 +48,7 @@
- +
- +
-- cgit v1.3