Open History to see the last commit
1<script lang="ts">
2 import { ChevronDown, ChevronRight } from 'lucide-svelte'
3
4 interface Props {
5 content: string
6 isComplete: boolean
7 class?: string
8 }
9
10 let { content, isComplete, class: className = '' }: Props = $props()
11
12 let isExpanded = $state(false)
13</script>
14
15<div class={`${className}`}>
16 <button
17 onclick={() => (isExpanded = !isExpanded)}
18 class="flex items-center gap-2 text-gray-400 hover:text-gray-300 transition-colors w-full text-left"
19 >
20 {#if isExpanded}
21 <ChevronDown size={16} />
22 {:else}
23 <ChevronRight size={16} />
24 {/if}
25 <span class="text-sm font-medium">
26 {isComplete ? '💭 Thinking (complete)' : '💭 Thinking...'}
27 </span>
28 </button>
29
30 {#if isExpanded}
31 <div class="mt-2 pl-6 text-gray-400 text-sm whitespace-pre-wrap">
32 {content}
33 </div>
34 {/if}
35</div>