<script lang="ts">
	let { bodyText = '' } = $props<{
		bodyText: string;
	}>();
</script>

{#if bodyText}
	<details class="border rounded p-2 bg-white text-sm">
		<summary class="cursor-pointer font-semibold">📝 View Extracted Text</summary>
		<div class="mt-2 pt-2 border-t whitespace-pre-wrap break-word max-h-48 overflow-y-auto text-xs">
			{bodyText}
		</div>
	</details>
{/if}
