<script lang="ts">
	import { onDestroy } from 'svelte';

	let show = $state(false);
	const timeout = setTimeout(() => (show = true), 150);

	onDestroy(() => clearTimeout(timeout));
</script>

{#if show}
	<div class="flex h-full w-full items-center justify-center">
		<span class="h-16 w-16 animate-spin rounded-full border-4 border-white/80 border-b-transparent"
		></span>
	</div>
{/if}
