mirror of
https://github.com/appwrite/console.git
synced 2026-06-06 19:27:48 +00:00
feat: trigger card page on first login
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
<script lang="ts">
|
||||
import { beforeNavigate } from '$app/navigation';
|
||||
import { beforeNavigate, goto } from '$app/navigation';
|
||||
import { page } from '$app/stores';
|
||||
import { INTERVAL } from '$lib/constants';
|
||||
import { Logs } from '$lib/layout';
|
||||
@@ -14,10 +14,20 @@
|
||||
import { onMount } from 'svelte';
|
||||
import { loading } from '../store';
|
||||
import Create from './createOrganization.svelte';
|
||||
import { isCloud } from '$lib/system';
|
||||
|
||||
onMount(() => {
|
||||
loading.set(false);
|
||||
|
||||
// Check if user already viewed cloud card
|
||||
if (isCloud) {
|
||||
const viewed = localStorage.getItem('cloud-card-viewed');
|
||||
if (!viewed) {
|
||||
localStorage.setItem('cloud-card-viewed', 'true');
|
||||
goto('/card');
|
||||
}
|
||||
}
|
||||
|
||||
setInterval(() => {
|
||||
checkForFeedback(INTERVAL);
|
||||
}, INTERVAL);
|
||||
|
||||
Reference in New Issue
Block a user