File size: 646 Bytes
8efb28e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
<script lang="ts">
	import { chatStore } from '$lib/stores/chat.svelte';
	import { StreamConnectionState } from '$lib/enums';
	import { Loader2 } from '@lucide/svelte';

	let state = $derived(chatStore.streamConnectionState);
</script>

{#if state === StreamConnectionState.RESUMING}
	<div
		class="pointer-events-auto mx-auto mt-2 mb-2 flex max-w-[48rem] items-center gap-2 rounded-md border border-blue-400/40 bg-blue-50/60 px-3 py-1.5 text-sm text-blue-700 dark:bg-blue-950/40 dark:text-blue-200"
		role="status"
		aria-live="polite"
	>
		<Loader2 class="h-3.5 w-3.5 animate-spin" />
		<span>Reconnecting to the stream...</span>
	</div>
{/if}