diff --git a/frontend/src/lib/components/ShortenerCard.svelte b/frontend/src/lib/components/ShortenerCard.svelte
index 739bc21..ce019cf 100644
--- a/frontend/src/lib/components/ShortenerCard.svelte
+++ b/frontend/src/lib/components/ShortenerCard.svelte
@@ -8,6 +8,7 @@
import { Badge } from '$lib/components/ui/badge'
import { ScrollArea } from '$lib/components/ui/scroll-area'
import { Separator } from '$lib/components/ui/separator'
+ import { Skeleton } from '$lib/components/ui/skeleton'
import type { Project, Shortener } from '$lib/db/types'
import {
BarChart,
@@ -47,11 +48,14 @@
}
let editProjectLinkOpen = false
+ let isLoadingEditProjectData = false
let editData:
| typeof $page.state.editLink
| typeof $page.state.editProjectLink
const showEditModal = async (code: string) => {
+ isLoadingEditProjectData = true
+ editProjectLinkOpen = true
const href = project
? `/dashboard/projects/${project.uuid}/links/${shortener.id}/edit`
: `/dashboard/links/${code}/edit`
@@ -61,7 +65,9 @@
editData = project
? (result.data as typeof $page.state.editProjectLink)
: (result.data as typeof $page.state.editLink)
- editProjectLinkOpen = true
+ setTimeout(() => {
+ isLoadingEditProjectData = false
+ }, 5000)
} else {
// something bad happened! try navigating
goto(href)
@@ -181,10 +187,12 @@
{/if}
-
+ {#if shortener.ios || shortener.android}
+
+ {/if}
{#if shortener.ios}
-
+
iOS
@@ -194,7 +202,7 @@
{/if}
{#if shortener.android}
-
+
Android
@@ -207,7 +215,9 @@
{#if project}
-
{project.name}
+
+ {project.name}
+
{/if}
{#if shortener.active}
@@ -238,7 +248,9 @@
- {#if project}
+ {#if isLoadingEditProjectData}
+
+ {:else if project}
{:else}