<script>
	let { loading = false, text = 'Loading...' } = $props();
</script>

{#if loading}
	<div class="flex items-center justify-center py-12">
		<div class="flex flex-col items-center gap-3">
			<div class="w-8 h-8 border-2 border-pos-highlight border-t-transparent rounded-full animate-spin"></div>
			<span class="text-sm text-gray-500">{text}</span>
		</div>
	</div>
{/if}
