Skip to content

Commit

Permalink
fix: fix theme slider breakpoints
Browse files Browse the repository at this point in the history
  • Loading branch information
aaronchan32 committed Jun 2, 2024
1 parent ad4c225 commit ea78c3a
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/app/components/Navbar/Navbar.scss
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ nav {
padding-block: $main-padding-mobile-block;
width: 100vw;
max-width: 400px;
background: rgb(255, 255, 255);
background: #fcfcfc;
height: 100dvh;
display: flex;
flex-direction: column;
Expand Down
2 changes: 1 addition & 1 deletion src/app/components/Overview/PastProjects/PastProjects.scss
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
transition:
background-color 0.3s,
border-color 0.3s;
border: 2px solid $primary-black;
border: 1px solid $primary-black;
background-color: $primary-black;
border-radius: 4px;
padding-block: 4px;
Expand Down
2 changes: 1 addition & 1 deletion src/app/components/Testimonial/Testimonial.scss
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@
}

.testimonials-modal-button {
border: 2px solid $primary-black;
border: 1px solid $primary-black;
text-transform: uppercase;
font-family: $p-font;
font-size: $h3-size;
Expand Down
20 changes: 19 additions & 1 deletion src/app/components/ThemesSlider/ThemesSlider.scss
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,12 @@
rgba(252, 252, 252, 0) 78.04%,
$primary-white 100%
);
$right-hide-slides-gradient: linear-gradient(
90deg,
rgba(252, 252, 252, 0) 0%,
rgba(252, 252, 252, 0) 78.04%,
$primary-white 100%
);

border: 1px solid $outline-gray;

Expand Down Expand Up @@ -54,7 +60,7 @@
.keen-slider::before {
content: '';
z-index: 1;
width: calc(100vw - 2 * clamp(50px, 25px + 1.8vw, 80px));
width: 100%;
height: 100%;
display: block;
position: absolute;
Expand All @@ -69,6 +75,18 @@
}
}

@media ($mobile-breakpoint < width < 1400px) {
.keen-slider::before {
content: '';
z-index: 1;
width: 100%;
height: 100%;
display: block;
position: absolute;
background: $right-hide-slides-gradient;
}
}

@media (min-width: $tablet-breakpoint) {
height: 100%;

Expand Down
6 changes: 6 additions & 0 deletions src/app/components/ThemesSlider/ThemesSlider.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,12 @@ export default function ThemesSlider({
slides: { origin: 'center', perView: 1.5, spacing: 10 }
},
'(min-width: 979px)': {
slides: { perView: 1.5, spacing: 10 }
},
'(min-width: 1200px)': {
slides: { perView: 2.5, spacing: 20 }
},
'(min-width: 1400px)': {
slides: { perView: 3, spacing: 20 }
}
},
Expand Down

0 comments on commit ea78c3a

Please sign in to comment.