whoa svelte is here
Co-authored-by: Astra <Astrrra@users.noreply.github.com>
This commit is contained in:
parent
76d837320d
commit
3f03c12152
24 changed files with 1080 additions and 16 deletions
21
web/src/lib/PostComponent.svelte
Normal file
21
web/src/lib/PostComponent.svelte
Normal file
|
@ -0,0 +1,21 @@
|
|||
<script lang="ts">
|
||||
import { Post } from "./pdsfetch";
|
||||
let { post } : { post : Post } = $props();
|
||||
</script>
|
||||
|
||||
<div>
|
||||
<p>{post.displayName} | {post.timenotstamp}</p>
|
||||
<p>{post.text}</p>
|
||||
{#if post.replyingDid}
|
||||
<p>Replying to: {post.replyingDid}</p>
|
||||
{/if}
|
||||
{#if post.imagesLinksCid}
|
||||
{#each post.imagesLinksCid as imageLink}
|
||||
<img src="https://pds.witchcraft.systems/xrpc/com.atproto.sync.getBlob?did={post.authorDid}&cid={imageLink}" />
|
||||
{/each}
|
||||
{/if}
|
||||
{#if post.videosLinkCid}
|
||||
<video src="https://pds.witchcraft.systems/xrpc/com.atproto.sync.getBlob?did={post.authorDid}&cid={post.videosLinkCid}" />
|
||||
{/if}
|
||||
|
||||
</div>
|
Loading…
Add table
Add a link
Reference in a new issue