Новые изменения в коде проекта
This commit is contained in:
parent
0777fc201f
commit
aef12e853d
12 changed files with 159 additions and 15 deletions
|
|
@ -7,7 +7,7 @@ import BlogCard from '@components/blog/BlogCard.astro';
|
|||
import Pagination from '@components/base/Pagination.astro';
|
||||
import CTA from '@components/base/CTA.astro';
|
||||
import SearchModal from '@components/base/SearchModal.astro';
|
||||
import { getPosts, getAllCategories } from '@lib/pb';
|
||||
import { getPosts, getAllCategories, getPostImageUrl } from '@lib/pb';
|
||||
|
||||
const POSTS_PER_PAGE = 6;
|
||||
const currentPage = 1;
|
||||
|
|
@ -64,7 +64,7 @@ const formatDate = (date: string) => {
|
|||
categoryColor={post.categoryColor}
|
||||
date={formatDate(post.date)}
|
||||
readTime={post.readTime}
|
||||
imageUrl={post.imageUrl}
|
||||
image={getPostImageUrl(post)}
|
||||
slug={`/blog/${post.slug}`}
|
||||
/>
|
||||
</article>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue