Skip to content

Commit 77334b3

Browse files
committed
feat: add blog post image to article page
1 parent 4d9f6ef commit 77334b3

File tree

1 file changed

+9
-0
lines changed
  • web/src/app/(content)/(info)/blog/[id]

1 file changed

+9
-0
lines changed

web/src/app/(content)/(info)/blog/[id]/page.tsx

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,15 @@ const BlogPost = ({ params }: BlogPageProps) => {
4444

4545
return (
4646
<>
47+
{post.image && (
48+
<Image
49+
src={post.image}
50+
alt=''
51+
className='w-full h-[30vh] md:h-[50vh] object-cover mb-8 mt-[-2.5rem] rounded-xl'
52+
width={1920}
53+
height={1080}
54+
/>
55+
)}
4756
<article className='max-w-screen-md mx-auto mb-36'>
4857
<Link
4958
href='/help'

0 commit comments

Comments
 (0)