diff --git a/src/lib/components/embedded_events/EmbeddedEvent.svelte b/src/lib/components/embedded_events/EmbeddedEvent.svelte
deleted file mode 100644
index 7b0c9a6..0000000
--- a/src/lib/components/embedded_events/EmbeddedEvent.svelte
+++ /dev/null
@@ -1,752 +0,0 @@
-
-
-{#if nestingLevel >= MAX_NESTING_LEVEL}
-
-
-
-
-
-
- Kind {event.kind}
-
-
- ({getEventType(event.kind || 0)})
-
- {#if event.pubkey}
-
•
-
Author:
-
- {#if toNpub(event.pubkey)}
- {@render userBadge(
- toNpub(event.pubkey) as string,
- authorDisplayName,
- ndk,
- )}
- {:else}
-
- {authorDisplayName || event.pubkey.slice(0, 8)}...{event.pubkey.slice(-4)}
-
- {/if}
-
- {/if}
-
-
-
-
- {#if getEventTitle(event)}
-
- {getEventTitle(event)}
-
- {/if}
-
-
- {#if event.kind !== 1 && getEventSummary(event)}
-
-
- {getEventSummary(event)}
-
-
- {/if}
-
-
- {#if event.kind === 1 || repostKinds.includes(event.kind)}
-
- {#if repostKinds.includes(event.kind)}
-
-
-
- {event.kind === 6 ? 'Reposted content:' : 'Generic reposted content:'}
-
- {@render repostContent(event.content)}
-
- {:else if event.kind === 1 && event.getMatchingTags("q").length > 0}
-
-
-
- Quote repost:
-
- {@render quotedContent(event, [], ndk)}
- {#if event.content && event.content.trim()}
-
-
- Added comment:
-
- {@render parsedContent(event.content)}
-
- {/if}
-
- {:else}
-
- {@render parsedContent(event.content.slice(0, 300))}
- {#if event.content.length > 300}
-
...
- {/if}
- {/if}
-
-
- {:else if event.kind === 3}
-
- {#if event.content}
- {@const contactData = (() => {
- try {
- return JSON.parse(event.content);
- } catch {
- return null;
- }
- })()}
- {#if contactData}
-
-
-
Contact List
- {#if contactData.relays}
-
- Relays: {Object.keys(contactData.relays).length}
-
- {/if}
-
- {#if contactData.follows}
-
- Following: {contactData.follows.length} users
-
- {/if}
-
- {:else}
-
- Invalid contact list data
-
- {/if}
- {:else}
-
- Empty contact list
-
- {/if}
-
-
- {:else if event.kind === 30040}
-
- {#if event.content}
- {@const indexData = (() => {
- try {
- return JSON.parse(event.content);
- } catch {
- return null;
- }
- })()}
- {#if indexData}
-
-
-
Publication Index
- {#if indexData.title}
-
- Title: {indexData.title}
-
- {/if}
- {#if indexData.summary}
-
- Summary: {indexData.summary}
-
- {/if}
- {#if indexData.authors}
-
- Authors: {indexData.authors.length}
-
- {/if}
-
-
- {:else}
-
- Invalid publication index data
-
- {/if}
- {:else}
-
- Empty publication index
-
- {/if}
-
-
- {:else if event.kind === 30041 || event.kind === 30818}
-
- {#if event.content}
-
-
-
- {event.kind === 30041 ? 'Publication Content' : 'Wiki Content'}
-
-
-
-
- {event.content.slice(0, 300)}
- {#if event.content.length > 300}
- ...
- {/if}
-
-
-
- {:else}
-
- Empty {event.kind === 30041 ? 'publication' : 'wiki'} content
-
- {/if}
-
-
- {:else if event.kind === 30023}
-
- {#if event.content}
-
-
- Long-form Content
-
-
-
- {event.content.slice(0, 300)}
- {#if event.content.length > 300}
- ...
- {/if}
-
-
-
- {:else}
-
- Empty long-form content
-
- {/if}
-
-
- {:else if event.kind === 1111}
-
-
-
- Reply/Comment
-
- {#if event.content && event.content.trim()}
-
- {@render parsedContent(event.content)}
-
- {:else}
-
- Empty reply
-
- {/if}
-
-
-
- {:else if event.kind === 1621}
-
-
-
-
Git Issue
- {#if event.tags}
- {@const subjectTag = event.tags.find(tag => tag[0] === 'subject')}
- {#if subjectTag && subjectTag[1]}
-
- Subject: {subjectTag[1]}
-
- {/if}
- {/if}
-
- {#if event.content && event.content.trim()}
-
- {@render parsedContent(event.content)}
-
- {:else}
-
- Empty issue description
-
- {/if}
-
-
-
- {:else if event.kind === 1622}
-
-
-
- Git Comment
-
- {#if event.content && event.content.trim()}
-
- {@render parsedContent(event.content)}
-
- {:else}
-
- Empty comment
-
- {/if}
-
-
-
- {:else if event.kind === 7}
-
-
-
- Reaction
-
- {#if event.content && event.content.trim()}
-
- {event.content}
-
- {:else}
-
- Empty reaction
-
- {/if}
-
-
-
- {:else if event.kind === 9735}
-
-
-
- Zap Receipt
-
- {#if event.content && event.content.trim()}
- {@const zapData = (() => {
- try {
- return JSON.parse(event.content);
- } catch {
- return null;
- }
- })()}
- {#if zapData}
-
- {#if zapData.amount}
-
Amount: {zapData.amount} sats
- {/if}
- {#if zapData.preimage}
-
Preimage: {zapData.preimage.slice(0, 8)}...
- {/if}
- {#if zapData.bolt11}
-
Invoice: {zapData.bolt11.slice(0, 20)}...
- {/if}
-
- {:else}
-
-
- {event.content.slice(0, 200)}
- {#if event.content.length > 200}
- ...
- {/if}
-
-
- {/if}
- {:else}
-
- Empty zap receipt
-
- {/if}
-
-
-
- {:else if event.kind === 20}
-
-
-
- Image/Media Post
-
-
-
- {#if event.tags}
- {@const imetaTags = event.tags.filter(tag => tag[0] === 'imeta')}
- {#if imetaTags.length > 0}
-
- {#each imetaTags as imetaTag}
- {@const imetaData = (() => {
- const data: any = {};
- for (let i = 1; i < imetaTag.length; i++) {
- const item = imetaTag[i];
- if (item.startsWith('url ')) {
- data.url = item.substring(4);
- } else if (item.startsWith('dim ')) {
- data.dimensions = item.substring(4);
- } else if (item.startsWith('m ')) {
- data.mimeType = item.substring(2);
- } else if (item.startsWith('size ')) {
- data.size = item.substring(5);
- } else if (item.startsWith('blurhash ')) {
- data.blurhash = item.substring(9);
- } else if (item.startsWith('x ')) {
- data.x = item.substring(2);
- }
- }
- return data;
- })()}
-
- {#if imetaData.url && imetaData.mimeType?.startsWith('image/')}
-
-

{
- (e.target as HTMLImageElement).style.display = 'none';
- const fallback = (e.target as HTMLImageElement).nextElementSibling;
- if (fallback) fallback.classList.remove('hidden');
- }}
- />
-
- Image failed to load: {imetaData.url}
-
-
-
-
- {#if imetaData.dimensions}
- Size: {imetaData.dimensions}
- {/if}
- {#if imetaData.size}
- File: {Math.round(parseInt(imetaData.size) / 1024)}KB
- {/if}
- {#if imetaData.mimeType}
- Type: {imetaData.mimeType}
- {/if}
-
-
- {:else if imetaData.url}
-
-
-
- {#if imetaData.size}
-
- Size: {Math.round(parseInt(imetaData.size) / 1024)}KB
-
- {/if}
-
- {/if}
- {/each}
-
- {/if}
- {/if}
-
-
- {#if event.content && event.content.trim()}
-
- {@render parsedContent(event.content)}
-
- {/if}
-
-
- {#if event.tags}
- {@const altTag = event.tags.find(tag => tag[0] === 'alt')}
- {#if altTag && altTag[1]}
-
- Alt: {altTag[1]}
-
- {/if}
- {/if}
-
-
-
- {:else if event.kind === 0 && profile}
-
- {#if profile.picture}
-

{
- (e.target as HTMLImageElement).style.display = 'none';
- (e.target as HTMLImageElement).nextElementSibling?.classList.remove('hidden');
- }}
- />
-
-
-
- {:else}
-
-
-
- {/if}
- {#if profile.about}
-
- {profile.about.slice(0, 200)}
- {#if profile.about.length > 200}
- ...
- {/if}
-
- {/if}
-
-
- {:else if event.content}
-
-
- {event.content.slice(0, 300)}
- {#if event.content.length > 300}
- ...
- {/if}
-
-
- {:else}
-
- No content
-
- {/if}
-
-
-
-
-{/if}