-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
db7182c
commit c227aba
Showing
4 changed files
with
48 additions
and
42 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -56,5 +56,6 @@ | |
"svelte-icons": "^2.1.0", | ||
"tailwind-merge": "^2.5.2", | ||
"tailwind-variants": "^0.2.1" | ||
} | ||
}, | ||
"packageManager": "[email protected]+sha512.38dc6fba8dba35b39340b9700112c2fe1e12f10b17134715a4aa98ccf7bb035e76fd981cf0bb384dfa98f8d6af5481c2bef2f4266a24bfa20c34eb7147ce0b5e" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,24 @@ | ||
<main class="w-screen h-screen bg-gradient-to-b flex items-center justify-center overflow-hidden from-blue-950 to-gray-900"> | ||
<main | ||
class="w-screen h-screen bg-gradient-to-b flex items-center justify-center overflow-hidden from-blue-950 to-gray-900" | ||
> | ||
<!-- from-blue-950 to-gray-900 --> | ||
<div class=" bg-slate-600 p-4 rounded-2xl shadow-xl"> | ||
<div class="w-96"> | ||
<!-- Change bg-base-100 to bg-blue-100 or any other color --> | ||
<h2 class="text-xl font-bold text-gray-300">Oops, looks like this page doesn´t exist</h2> | ||
<figure class="px-10 pt-6"> | ||
<img src="../images/itsfine.gif" alt="gif" class="rounded-xl" /> | ||
</figure> | ||
|
||
<!-- from-blue-950 to-gray-900 --> | ||
<div class=' bg-slate-600 p-4 rounded-2xl shadow-xl'> | ||
<div class="w-96"> <!-- Change bg-base-100 to bg-blue-100 or any other color --> | ||
<h2 class="text-xl font-bold text-gray-300">Oops, looks like this page doesn´t exist</h2> | ||
<figure class="px-10 pt-6 "> | ||
<img src="../images/itsfine.gif" alt="gif" class="rounded-xl" /> | ||
</figure> | ||
|
||
<div class="card-body items-center text-center"> | ||
<p class='text-secondary'>It's ok it sometimes happens to everyone</p> | ||
<div class="card-actions"> | ||
<a class="mx-6 mt-2 flex items-center justify-center h-6 rounded-lg bg-blue-600 text-lg hover:bg-blue-500 transition-all text-white font-bold" href="/">Go back to the landing page</a> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</main> | ||
<div class="card-body items-center text-center"> | ||
<p class="text-secondary">It's ok it sometimes happens to everyone</p> | ||
<div class="card-actions"> | ||
<a | ||
class="mx-6 mt-2 flex items-center justify-center h-6 rounded-lg bg-blue-600 text-lg hover:bg-blue-500 transition-all text-white font-bold" | ||
href="/">Go back to the landing page</a | ||
> | ||
</div> | ||
</div> | ||
</div> | ||
</div> | ||
</main> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,16 @@ | ||
export const ssr = false; | ||
|
||
import { redirect } from '@sveltejs/kit'; | ||
import getLocalDB from '$lib/utils/localDB/manager'; | ||
import { redirect } from "@sveltejs/kit"; | ||
import getLocalDB from "$lib/utils/localDB/manager"; | ||
|
||
const loginLock = ['/interface']; | ||
const loginLock = ["/interface"]; | ||
//redirect to login in locked pages | ||
export const load = async ({ url }) => { | ||
const db = getLocalDB(); | ||
if (loginLock.includes(url?.pathname) && !db.userID) { | ||
throw redirect(302, '/auth/login'); | ||
throw redirect(302, "/auth/login"); | ||
} | ||
return { | ||
user: db?.userID || null | ||
user: db?.userID || null, | ||
}; | ||
}; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters