<script lang="ts">
	import { getTabContext } from '$lib/Tabs';
	import { fadeDefault } from '$lib/Transitions';
	import { fade } from 'svelte/transition';

	const context = getTabContext();
	export let id: string;
</script>

{#if $context.current === id}
	<div class="h-full overflow-auto py-2 pe-3" in:fade={fadeDefault}>
		<slot />
	</div>
{/if}
