Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Animate `Manage your cloud native mess' section #5753

Merged
merged 2 commits into from
Jul 31, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
126 changes: 79 additions & 47 deletions src/sections/Home/Playground-home/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -107,32 +107,58 @@ const ViewsSectionWrapper = styled.div`

.overlay {
width: 483px;
height: 680x;
height: 680px;
}

.container {
display: flex;
justify-content: center;
}

.line1 {
.line {
display: flex;
flex-direction: column;
align-items: center;
margin-right: 2rem;
transform: translateY(50px);
flex-wrap: wrap;
}
.position-line-down{
transform: translateY(-20em);
}
.position-line-up{
transform: translateY(20em);
}

.line2 {
display: flex;
flex-direction: column;
align-items: center;
margin-right: 2rem;
transform: translateY(-50px);
flex-wrap: wrap;
.line-primary, .line-secondary {
width: 100%;
display: flex;
flex-direction: column;
}

.animation-up-scroll {
animation: scroll-up-animation 15s linear infinite;

@keyframes scroll-up-animation {
0% {
transform: translateY(0%);
}
100% {
transform: translateY(-100%);
}
}
}
.animation-down-scroll {

animation: scroll-down-animation 15s linear infinite;
@keyframes scroll-down-animation {
0% {
transform: translateY(0);
}
100% {
transform: translateY(100%);
}
}
}

.box {
display: flex;
flex-direction: column;
Expand Down Expand Up @@ -179,7 +205,7 @@ const ViewsSectionWrapper = styled.div`
`;

const MeshmapVisualizerViews = () => {
const [imageRef, inView] = useInView({ threshold: 0.4 });
const [imageRef, inView] = useInView({ threshold: 0.3 });
const [imageInView, setimageInView] = useState(false);

if (inView && !imageInView) setimageInView(true);
Expand All @@ -195,44 +221,50 @@ const MeshmapVisualizerViews = () => {
alt=""
/> */}
<div
className={
imageInView ? "visible container" : "not-visible container"
}
// className={
// imageInView ? "visible container" : "not-visible container"
// }
className="visible container"
>
<div className="line1">
<div className="box">
<img className="boxImg" src={argocd} alt="" />
<div className="boxText">Argo CD</div>
</div>
<div className="box">
<img className="boxImg" src={cilium} alt="" />
<div>Cilium</div>
</div>
<div className="box">
<img className="boxImg" src={prometheus} alt="" />
<div>Prometheus</div>
</div>
<div className="box">
<img className="boxImg" src={prometheus} alt="" />
<div>Prometheus</div>
<div className="line position-line-down">
<div className="line-primary animation-down-scroll">
<div className="box">
<img className="boxImg" src={prometheus} alt="" />
<div>Prometheus</div>
</div>
<div className="box">
<img className="boxImg" src={argocd} alt="" />
<div className="boxText">Argo CD</div>
</div>
<div className="box">
<img className="boxImg" src={cilium} alt="" />
<div>Cilium</div>
</div>
<div className="box">
<img className="boxImg" src={prometheus} alt="" />
<div>Prometheus</div>
</div>
</div>

</div>
<div className="line2">
<div className="box">
<img className="boxImg" src={kubernetes} alt="" />
<div>Kubernetes</div>
</div>
<div className="box">
<img className="boxImg" src={keda} alt="" />
<div>Keda</div>
</div>
<div className="box">
<img className="boxImg" src={linkerd} alt="" />
<div>Linkerd</div>
</div>
<div className="box">
<img className="boxImg" src={kubernetes} alt="" />
<div>Kubernetes</div>
<div className="line position-line-up">
<div className="line-primary animation-up-scroll">
<div className="box">
<img className="boxImg" src={kubernetes} alt="" />
<div>Kubernetes</div>
</div>
<div className="box">
<img className="boxImg" src={keda} alt="" />
<div>Keda</div>
</div>
<div className="box">
<img className="boxImg" src={linkerd} alt="" />
<div>Linkerd</div>
</div>
<div className="box">
<img className="boxImg" src={kubernetes} alt="" />
<div>Kubernetes</div>
</div>
</div>
</div>
</div>
Expand Down