Skip to content

Commit b80e10d

Browse files
committed
Add fade transition when swapping to experimental without cache
1 parent 4d045c3 commit b80e10d

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

src/components/data/SoftwareDownload.svelte

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
import type { Snippet } from "svelte";
1212
import { fetchBuildsOrError, type ProjectBuildsOrError } from "@/utils/download";
1313
import { watch } from "runed";
14+
import { fade } from "svelte/transition";
1415
1516
interface Props {
1617
id: "paper" | "velocity" | "folia" | "waterfall" | (string & {});
@@ -149,11 +150,13 @@
149150
</p>
150151

151152
{#if buildsLoading}
152-
<div class="text-center text-sm text-gray-400">Loading builds…</div>
153+
<div transition:fade class="text-center text-sm text-gray-400">Loading builds…</div>
153154
{:else if builds.error}
154-
<div class="text-center text-sm text-red-500">{builds.error}</div>
155+
<div transition:fade class="text-center text-sm text-red-500">{builds.error}</div>
155156
{:else if builds.value && builds.value.builds && builds.value.builds.length > 0}
156-
<SoftwareBuilds project={id} {version} builds={builds.value.builds} eol={!!eol} />
157+
<div transition:fade>
158+
<SoftwareBuilds project={id} {version} builds={builds.value.builds} eol={!!eol} />
159+
</div>
157160
{/if}
158161
</section>
159162

0 commit comments

Comments
 (0)