Skip to content

Commit 3e06b79

Browse files
moved pagination closer to cards
1 parent d21db7c commit 3e06b79

File tree

2 files changed

+12
-11
lines changed

2 files changed

+12
-11
lines changed

components/CardsColumns.js

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
11
import { Swiper, SwiperSlide } from 'swiper/react';
2-
import { Pagination } from 'swiper';
2+
import { Pagination, Navigation } from 'swiper';
33
import 'swiper/css';
44
import "swiper/css/pagination";
5+
import "swiper/css/navigation";
56

67
import Card from './Card';
78
import Container from './Container';
@@ -17,15 +18,15 @@ export default function CardsColumns({
1718
}) {
1819
return (
1920
<Container>
20-
<Swiper
21+
<Swiper className={styles.swiper}
2122
mousewheel={true}
2223
grabCursor={true}
23-
navigation={true}
24-
pagination={true} modules={[Pagination]}
24+
modules={[Pagination]}
25+
pagination
2526
centerInsufficientSlides={true}
26-
slidesPerView={1}
27+
slidesPerView={1.09}
2728
breakpoints={{
28-
780: {
29+
769: {
2930
slidesPerView: 2,
3031
spaceBetween: 50,
3132
},

styles/CardsColumns.module.scss

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,18 +3,18 @@
33

44
.inner__content {
55
margin: 0 auto;
6-
padding-bottom: 12rem;
6+
padding-bottom: 4rem;
77
justify-content: center;
88

99
@include desktop-breakpoint-plus {
1010
display: flex;
1111
}
1212

1313
@include desktop-breakpoint-minus {
14-
padding-bottom: 5rem;
14+
padding-bottom: 1rem;
1515
}
1616
}
1717

18-
.swiper-slide {
19-
height: auto;
20-
}
18+
.swiper{
19+
margin-bottom: 6rem;
20+
}

0 commit comments

Comments
 (0)