fixed login flow inconsistency

This commit is contained in:
ari melody 2024-07-02 20:21:34 +01:00
parent 998e8f2517
commit abab0df83f
Signed by: ari
GPG key ID: CF99829C92678188
10 changed files with 65 additions and 45 deletions

View file

@ -1,10 +1,16 @@
<script>
import { notifications, getNotifications } from '$lib/notifications.js';
import { logged_in } from '$lib/stores/user.js';
import { goto } from '$app/navigation';
import { get } from 'svelte/store';
import Notification from '$lib/ui/Notification.svelte';
if (!get(logged_in)) goto("/");
getNotifications();
/*
document.addEventListener("scroll", event => {
if (get(logged_in) && get(page).url.pathname !== "/") return;
if (window.innerHeight + window.scrollY >= document.body.offsetHeight - 2048) {
getNotifications();
}