diff --git a/components/post-list-item.tsx b/components/post-list-item.tsx index 8950d30..8051a43 100644 --- a/components/post-list-item.tsx +++ b/components/post-list-item.tsx @@ -18,44 +18,42 @@ export function PostListItem({ post }: Props) { post.description || post.custom_excerpt || post.body?.raw?.slice(0, 120); return ( -
-
-
- {cover && ( -
- {/* eslint-disable-next-line @next/next/no-img-element */} - {post.title} -
- )} -
-
- {post.published_at && ( - - {new Date(post.published_at).toLocaleDateString( - siteConfig.defaultLocale - )} - - )} - {post.tags && post.tags.length > 0 && ( - - {post.tags.slice(0, 3).join(', ')} - - )} -
-

- {post.title} -

- {excerpt && ( -

- {excerpt} -

+
+
+ {cover && ( +
+ {/* eslint-disable-next-line @next/next/no-img-element */} + {post.title} +
+ )} +
+
+ {post.published_at && ( + + {new Date(post.published_at).toLocaleDateString( + siteConfig.defaultLocale + )} + + )} + {post.tags && post.tags.length > 0 && ( + + {post.tags.slice(0, 3).join(', ')} + )}
-
-
+

+ {post.title} +

+ {excerpt && ( +

+ {excerpt} +

+ )} +
+
); } diff --git a/components/timeline-wrapper.tsx b/components/timeline-wrapper.tsx index 980a42a..8b9eacf 100644 --- a/components/timeline-wrapper.tsx +++ b/components/timeline-wrapper.tsx @@ -1,4 +1,4 @@ -import { ReactNode } from 'react'; +import { Children, ReactNode } from 'react'; import clsx from 'clsx'; interface TimelineWrapperProps { @@ -7,21 +7,26 @@ interface TimelineWrapperProps { } export function TimelineWrapper({ children, className }: TimelineWrapperProps) { + const items = Children.toArray(children); return ( -
-