From 94966dc256c8c29f842fa08f5a63d43290cf68a9 Mon Sep 17 00:00:00 2001 From: Alicia Sykes Date: Sun, 24 Mar 2024 13:00:04 +0000 Subject: [PATCH] Writes component to show reddit info --- .../things/RedditDetailedInfo.astro | 164 ++++++++++++++++++ 1 file changed, 164 insertions(+) create mode 100644 web/src/components/things/RedditDetailedInfo.astro diff --git a/web/src/components/things/RedditDetailedInfo.astro b/web/src/components/things/RedditDetailedInfo.astro new file mode 100644 index 0000000..1b99cc0 --- /dev/null +++ b/web/src/components/things/RedditDetailedInfo.astro @@ -0,0 +1,164 @@ +--- + +import type { RedditData } from '@utils/fetch-reddit-info'; +import { timestampToDate, timeAgo } from '@utils/dates-n-stuff'; +import FontAwesome from "@components/form/FontAwesome.svelte" + + +interface Props { + redditData: RedditData; +}; + +const { redditData } = Astro.props; + + +--- + +
+

Reddit

+ +

+ + {redditData.info.title || redditData.info.name} +

+

{redditData.info.description}

+ {redditData.info.banner && ()} + + +

Posts

+ +
+ + +