Skip to content

Commit f334700

Browse files
Merge pull request #7580 from Bharath314/slide-transitions
[Products] Resolve slider carousel image invisibility in production build
2 parents 5158f46 + 600fe9e commit f334700

File tree

2 files changed

+45
-21
lines changed

2 files changed

+45
-21
lines changed

src/sections/Meshery/Features-section/features-section.style.js

Lines changed: 16 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -30,14 +30,14 @@ const FeaturesSectionWrapper = styled.section`
3030
top: 0.5px;
3131
}
3232
.rect-2-left {
33-
background: ${props => props.theme.secondaryColor};
33+
background: ${(props) => props.theme.secondaryColor};
3434
border-radius: 0 0 3.5rem 0;
3535
grid-column: 1/2;
3636
height: 5rem;
3737
grid-row: 2;
3838
}
3939
.rect-3-right {
40-
background: ${props => props.theme.secondaryColor};
40+
background: ${(props) => props.theme.secondaryColor};
4141
border-radius: 3.5rem 0 0 0;
4242
grid-column: 10/11;
4343
grid-row: 1;
@@ -74,7 +74,7 @@ const FeaturesSectionWrapper = styled.section`
7474
h1 {
7575
line-height: 3.125rem;
7676
span {
77-
color: ${props => props.theme.secondaryColor};
77+
color: ${(props) => props.theme.secondaryColor};
7878
}
7979
}
8080
h2 {
@@ -108,14 +108,20 @@ const FeaturesSectionWrapper = styled.section`
108108
}
109109
}
110110
111-
.smp-section-caraousel {
111+
.smp-section-carousel {
112112
.slick-slider {
113113
max-height: 520px;
114114
.slick-list {
115115
max-width: 50rem;
116116
max-height: 520px;
117+
height: auto;
118+
119+
.slick-track {
120+
height: auto;
121+
}
117122
118123
.slick-slide {
124+
height: auto;
119125
img {
120126
max-height: 20rem;
121127
margin: auto;
@@ -160,7 +166,7 @@ const FeaturesSectionWrapper = styled.section`
160166
}
161167
162168
@media screen and (max-width: 1600px) {
163-
.smp-section .smp-section-caraousel .slick-slider {
169+
.smp-section .smp-section-carousel .slick-slider {
164170
.slick-list {
165171
max-width: 38rem;
166172
}
@@ -191,7 +197,7 @@ const FeaturesSectionWrapper = styled.section`
191197
}
192198
}
193199
194-
.smp-section-caraousel .slick-slider {
200+
.smp-section-carousel .slick-slider {
195201
.slick-list {
196202
max-width: 80%;
197203
margin: 2rem auto;
@@ -207,7 +213,7 @@ const FeaturesSectionWrapper = styled.section`
207213
@media screen and (max-width: 960px) {
208214
padding-bottom: 0rem;
209215
margin-bottom: 4rem;
210-
.smp-section .smp-section-caraousel .slick-slider .slick-list {
216+
.smp-section .smp-section-carousel .slick-slider .slick-list {
211217
.slick-slide {
212218
img {
213219
max-height: 16rem;
@@ -220,7 +226,7 @@ const FeaturesSectionWrapper = styled.section`
220226
.smp-section {
221227
max-width: 95%;
222228
223-
.smp-section-caraousel .slick-slider {
229+
.smp-section-carousel .slick-slider {
224230
.slick-list {
225231
max-width: 85%;
226232
margin: 2rem 0;
@@ -241,7 +247,7 @@ const FeaturesSectionWrapper = styled.section`
241247
.smp-section {
242248
max-width: 95%;
243249
244-
.smp-section-caraousel .slick-slider {
250+
.smp-section-carousel .slick-slider {
245251
.slick-list {
246252
max-width: 80%;
247253
.slick-slide {
@@ -297,4 +303,4 @@ const FeaturesSectionWrapper = styled.section`
297303
}
298304
`;
299305

300-
export default FeaturesSectionWrapper;
306+
export default FeaturesSectionWrapper;

src/sections/Meshery/Features-section/index.js

Lines changed: 29 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
21
import React from "react";
32
import { Row, Col } from "../../../reusecore/Layout";
43
import Button from "../../../reusecore/Button";
@@ -7,6 +6,7 @@ import Slide1 from "../../../assets/images/kanvas/gifs/start-from-scratch.gif";
76
import Slide2 from "../../../assets/images/kanvas/gifs/catalog.gif";
87
import Slide3 from "../../../assets/images/kanvas/gifs/rendered-design.webp";
98
import FeaturesSectionWrapper from "./features-section.style";
9+
1010
import { StaticImage } from "gatsby-plugin-image";
1111

1212
const slide2Path = "../../../assets/images/kanvas/gifs/catalog.gif";
@@ -15,12 +15,11 @@ const slide3Path = "../../../assets/images/kanvas/gifs/rendered-design.webp";
1515
const slides_list = [Slide1, Slide2, Slide3];
1616

1717
const FeaturesSection = () => {
18-
1918
var settings = {
2019
customPaging: function (i) {
2120
return (
2221
<p>
23-
<img src={slides_list[i]} loading="lazy" alt={"slide-img" + [i]}/>
22+
<img src={slides_list[i]} loading="lazy" alt={"slide-img" + [i]} />
2423
</p>
2524
);
2625
},
@@ -30,7 +29,7 @@ const FeaturesSection = () => {
3029
slidesToScroll: 1,
3130
dots: true,
3231
vertical: true,
33-
verticalSwiping: true
32+
verticalSwiping: true,
3433
};
3534

3635
return (
@@ -47,7 +46,9 @@ const FeaturesSection = () => {
4746
</div> */}
4847
<div className="section-header">
4948
<h2>Cloud native infrastructure is complex.</h2>
50-
<h1>Design it <span>visually and collaboratively</span></h1>
49+
<h1>
50+
Design it <span>visually and collaboratively</span>
51+
</h1>
5152
{/* <h1>
5253
<span>Meshery</span> supports the most service meshes.
5354
</h1> */}
@@ -64,7 +65,7 @@ const FeaturesSection = () => {
6465
Drag, drop, and deploy your infrastructure with ease. Kanvas, built on Meshery, simplifies Kubernetes and cloud management through intuitive visual designer and operator.
6566
</p>
6667
</Col>
67-
<Col $xs={12} $xl={8} className="smp-section-caraousel">
68+
<Col $xs={12} $xl={8} className="smp-section-carousel">
6869
<Slider {...settings}>
6970
<div>
7071
<img src={Slide1} alt="Slide 1" />
@@ -83,17 +84,34 @@ const FeaturesSection = () => {
8384
<div>
8485
<h3>One step to managing your microservices</h3>
8586
<h1>Cloud Native Application Management</h1>
86-
<p>Confidently take full advantage of all that your infrastructure offers.</p>
87+
<p>
88+
Confidently take full advantage of all that your infrastructure offers.
89+
</p>
8790
</div>
8891
<div className="mesh-mngmnt-btn">
8992
<Col $xs={12} $sm={6} $md={4}>
90-
<Button $secondary className="mgmt_button" title="Install" $url="/cloud-native-management/meshery/getting-started" />
93+
<Button
94+
$secondary
95+
className="mgmt_button"
96+
title="Install"
97+
$url="/cloud-native-management/meshery/getting-started"
98+
/>
9199
</Col>
92100
<Col $xs={12} $sm={6} $md={4}>
93-
<Button $secondary className="mgmt_button" title="Manage" $url="/cloud-native-management/meshery/operating-cloud-native-infra" />
101+
<Button
102+
$secondary
103+
className="mgmt_button"
104+
title="Manage"
105+
$url="/cloud-native-management/meshery/operating-cloud-native-infra"
106+
/>
94107
</Col>
95108
<Col $xs={12} $sm={6} $md={4}>
96-
<Button $secondary className="mgmt_button" title="Catalog" $url="/cloud-native-management/catalog" />
109+
<Button
110+
$secondary
111+
className="mgmt_button"
112+
title="Catalog"
113+
$url="/cloud-native-management/catalog"
114+
/>
97115
</Col>
98116
</div>
99117
</div>
@@ -102,4 +120,4 @@ const FeaturesSection = () => {
102120
);
103121
};
104122

105-
export default FeaturesSection;
123+
export default FeaturesSection;

0 commit comments

Comments
 (0)