your personal website on atproto - mirror
blento.app
1<script lang="ts">
2 import type { ContentComponentProps } from '../types';
3
4 let { item }: ContentComponentProps = $props();
5
6 // svelte-ignore state_referenced_locally
7 let domain = new URL(item.cardData.embed || item.cardData.href).hostname;
8</script>
9
10{#if domain === 'stream.place'}
11 <iframe
12 src={item.cardData.embed || item.cardData.href}
13 sandbox="allow-scripts allow-same-origin"
14 referrerpolicy="no-referrer"
15 class="absolute inset-0 h-full w-full"
16 title=""
17 ></iframe>
18{:else}
19 <div class="p-4">Invalid domain</div>
20{/if}