From 83b11393da8f733c0ffc5abed5d1e0e827d04b61 Mon Sep 17 00:00:00 2001
From: ivarlovlie <git@ivarlovlie.no>
Date: Thu, 2 Jun 2022 23:02:22 +0200
Subject: refactor: Rename accounts to portal

---
 apps/accounts/src/app/index.svelte | 61 --------------------------------------
 1 file changed, 61 deletions(-)
 delete mode 100644 apps/accounts/src/app/index.svelte

(limited to 'apps/accounts/src/app/index.svelte')

diff --git a/apps/accounts/src/app/index.svelte b/apps/accounts/src/app/index.svelte
deleted file mode 100644
index 40fe6ae..0000000
--- a/apps/accounts/src/app/index.svelte
+++ /dev/null
@@ -1,61 +0,0 @@
-<svelte:options immutable={true}/>
-<svelte:window bind:online={online}/>
-
-<script>
-	import {projects_base} from "$shared/lib/configuration";
-	import Router from "svelte-spa-router";
-	import {wrap} from "svelte-spa-router/wrap";
-	import {is_active} from "$shared/lib/session";
-	import NotFound from "$app/pages/not-found.svelte";
-	import SignUp from "$app/pages/sign-up.svelte";
-	import Login from "$app/pages/login.svelte";
-	import Forgot from "$app/pages/forgot.svelte";
-	import Reset from "$app/pages/reset-password.svelte";
-    import PreHeader from "$shared/components/pre-header.svelte";
-
-	let online = true;
-
-	async function user_is_logged_in() {
-		if (await is_active()) {
-			location.replace(projects_base("#/home"));
-		}
-		return true;
-	}
-
-	const routes = {
-		"/login": wrap({
-			component: Login,
-			conditions: [user_is_logged_in],
-		}),
-		"/": wrap({
-			component: Login,
-			conditions: [user_is_logged_in],
-		}),
-		"/signup": wrap({
-			component: SignUp,
-			conditions: [user_is_logged_in],
-		}),
-		"/reset-password": wrap({
-			component: Reset,
-			conditions: [user_is_logged_in],
-		}),
-		"/forgot": wrap({
-			component: Forgot,
-			conditions: [user_is_logged_in],
-		}),
-		"*": NotFound,
-	};
-</script>
-
-<PreHeader show="{!online}">You seem to be offline, please check your internet connection.</PreHeader>
-
-<Router
-        {routes}
-        restoreScrollState={true}
-        on:routeLoading={() => {
-            document.getElementById("loader").style.display = "inline-block";
-        }}
-        on:routeLoaded={() => {
-            document.getElementById("loader").style.display = "none";
-        }}
-/>
-- 
cgit v1.3

