Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
  • Loading branch information
hoangndm3139 committed Jul 23, 2024
1 parent 330be74 commit afaf2ef
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/sections/blogs/components/Slider/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -98,8 +98,8 @@ const BlogsSlider = forwardRef((props, ref: any) => {
}
}}
>
{posts.map((post: Post) => (
<SwiperSlide key={post.id}><Card post={post} /></SwiperSlide>
{posts.map((post: Post, i: number) => (
<SwiperSlide key={post.id} className={`${ i === 0 && 'xl:ml-[calc((100vw_-_1408px)_/_2)]'} w-[323px] h-[335px] xl:h-[474px] xl:w-[540px]`}><Card post={post} /></SwiperSlide>
))}
</Swiper>
);
Expand Down
2 changes: 1 addition & 1 deletion src/sections/blogs/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ function Blogs() {
<SwiperButton onClickPrev={() => sliderRef.current?.slidePrev()} onClickNext={() => sliderRef.current?.slideNext()} />
</div>
</div>
<div className="w-screen pl-6 xl:w-[calc(100vw_-_6px)] xl:pl-[calc((100vw_-_1408px)_/_2)]">
<div className="w-screen pl-6 xl:w-[calc(100vw_-_6px)] xl:pl-0">
<BlogsSlider ref={sliderRef} />
</div>
</div>
Expand Down

0 comments on commit afaf2ef

Please sign in to comment.