mirror of
https://github.com/fergalmoran/opengifame.git
synced 2025-12-22 09:38:44 +00:00
Image page added
This commit is contained in:
@@ -6,7 +6,24 @@ type PostPageProps = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const PostPage: React.FC<PostPageProps> = ({ post }) => {
|
const PostPage: React.FC<PostPageProps> = ({ post }) => {
|
||||||
return <div>{post.title}</div>;
|
return (
|
||||||
|
<div className="grid grid-cols-3">
|
||||||
|
<div id="left"></div>
|
||||||
|
<div id="centre">
|
||||||
|
<div className="flex max-w-lg flex-col justify-center">
|
||||||
|
<img
|
||||||
|
src={post.imageUrl}
|
||||||
|
className="w-full overflow-hidden rounded-lg border shadow"
|
||||||
|
/>
|
||||||
|
<div className="mt-8">
|
||||||
|
<h4 className="text-xl font-bold">{post.title}</h4>
|
||||||
|
<p className="mt-2 text-gray-600">{post.description}</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div id="right"></div>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
export default PostPage;
|
export default PostPage;
|
||||||
|
|||||||
@@ -19,7 +19,7 @@ export const TrendingImages: React.FC = async () => {
|
|||||||
return latestImages.length !== 0 ? (
|
return latestImages.length !== 0 ? (
|
||||||
<div className="masonry sm:masonry-sm md:masonry-md">
|
<div className="masonry sm:masonry-sm md:masonry-md">
|
||||||
{latestImages.map((image) => (
|
{latestImages.map((image) => (
|
||||||
<Link href={`/image/${image.slug}`} key={image.slug}>
|
<Link href={`/post/${image.slug}`} key={image.slug}>
|
||||||
<div className="break-inside rounded-lg">
|
<div className="break-inside rounded-lg">
|
||||||
<div className="relative m-6 flex-shrink-0 overflow-hidden rounded-lg bg-muted shadow-lg hover:bg-accent">
|
<div className="relative m-6 flex-shrink-0 overflow-hidden rounded-lg bg-muted shadow-lg hover:bg-accent">
|
||||||
<div className="relative flex items-center justify-center px-2 pt-4">
|
<div className="relative flex items-center justify-center px-2 pt-4">
|
||||||
|
|||||||
Reference in New Issue
Block a user