aboutsummaryrefslogtreecommitdiff
path: root/components/PostPreview.js
diff options
context:
space:
mode:
authorAndrew Lee <alee14498@protonmail.com>2023-07-15 13:43:54 -0400
committerAndrew Lee <alee14498@protonmail.com>2023-07-15 13:43:54 -0400
commitb5b66d3841cebac5ab34744e63fc60e2a69a7252 (patch)
tree5a01d5bc019b118f38bebde87b96611aa8a233a7 /components/PostPreview.js
parent959996961284a2800004eca2205add8e7d4f40f2 (diff)
downloadalure-website-b5b66d3841cebac5ab34744e63fc60e2a69a7252.tar.gz
alure-website-b5b66d3841cebac5ab34744e63fc60e2a69a7252.tar.bz2
alure-website-b5b66d3841cebac5ab34744e63fc60e2a69a7252.zip
New page; Post system; Fixed more padding
Diffstat (limited to 'components/PostPreview.js')
-rw-r--r--components/PostPreview.js14
1 files changed, 14 insertions, 0 deletions
diff --git a/components/PostPreview.js b/components/PostPreview.js
new file mode 100644
index 0000000..6eca000
--- /dev/null
+++ b/components/PostPreview.js
@@ -0,0 +1,14 @@
+import Link from "next/link";
+
+export default function PostPreview(props) {
+ return (
+ <div key="post" className="py-2 bg-zinc-800 py-3 px-5 border border-gray-600 rounded-lg space-y-3">
+ <Link href={`/updates/${props.slug}`}>
+ <h2 className="font-medium text-2xl hover:underline">{props.title}</h2>
+ </Link>
+ <span>By {props.author}</span>
+ <p>{props.description}</p>
+ <p className="font-medium text-sm">Posted on {props.date}</p>
+ </div>
+ )
+}