Skip to content

Commit

Permalink
Remove conflicting cta (#180)
Browse files Browse the repository at this point in the history
* Remove conflicting cta

* Make arrow clickable

* Add smooth scrolling

* Run prettier
  • Loading branch information
dangjoey authored Jan 28, 2022
1 parent 10ca1fb commit 1073c88
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 7 deletions.
9 changes: 7 additions & 2 deletions src/sections/home/Home.Hero.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,10 @@ const HomeHero: React.FC = () => {
return undefined
}, [scrolled])

const scrollDown = () => {
window.scrollBy({ top: window.innerHeight, behavior: "smooth" })
}

return (
<section className="home__hero">
<div className="home__hero--grid">
Expand All @@ -51,7 +55,6 @@ const HomeHero: React.FC = () => {
<span>community.&nbsp;</span>
</Typist>
<div className="buttons">
<Button title="Learn More!" link="/about" type="secondary" />
<Button
title="Join Us Now!"
link="https://members.acmucsd.com"
Expand All @@ -60,7 +63,9 @@ const HomeHero: React.FC = () => {
</div>
</div>
</div>
{scrolled ? null : <img className="arrow" alt="" src={Arrow} />}
{scrolled ? null : (
<img className="arrow" alt="" onClick={scrollDown} src={Arrow} />
)}
</div>
</section>
)
Expand Down
5 changes: 0 additions & 5 deletions src/sections/home/styles.less
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,6 @@

.buttons {
width: fit-content;
display: flex;
flex-direction: row;
align-items: center;
width: 100%;
margin: 37px 0px;
> a {
Expand Down Expand Up @@ -104,7 +101,6 @@

.buttons {
display: flex;
align-items: center;
justify-content: center;
width: 100%;
margin: 1em 0 0 0 !important;
Expand Down Expand Up @@ -146,7 +142,6 @@
}
.buttons {
display: flex;
align-items: center;
justify-content: center;
width: 100%;
margin-top: 1em !important;
Expand Down
1 change: 1 addition & 0 deletions src/styles/mixins.less
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
}

.arrow {
cursor: pointer;
left: 50vw;
bottom: 50px;
height: 30px;
Expand Down

1 comment on commit 1073c88

@vercel
Copy link

@vercel vercel bot commented on 1073c88 Feb 3, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

main-website – ./

main-website-orcin.vercel.app
main-website-acmucsd.vercel.app
main-website-git-master-acmucsd.vercel.app

Please sign in to comment.