Skip to content

Commit acb3b28

Browse files
committed
chore: last minute changes
1 parent e782ce2 commit acb3b28

File tree

10 files changed

+38
-35
lines changed

10 files changed

+38
-35
lines changed

src/components/Button/Button.styles.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,11 @@ const getSize = (size?: 'small' | 'large') => ({
66
default: '14px 30px 16px'
77
})[size || 'default']
88

9-
export const StyledButton = styled.button<{ size?: 'small' | 'large' }>`
9+
export const StyledButton = styled.a<{ size?: 'small' | 'large' }>`
1010
line-height: 1;
1111
font-size: 15px;
1212
cursor: pointer;
13+
text-decoration: none;
1314
font-weight: 700;
1415
display: inline-block;
1516
color: #1b116e;
@@ -20,6 +21,7 @@ export const StyledButton = styled.button<{ size?: 'small' | 'large' }>`
2021
padding: ${props => getSize(props.size)};
2122
&:hover {
2223
background-color: #55bd90;
24+
color: #1b116e;
2325
};
2426
&:active {
2527
border: solid 2px #1b116e;

src/components/Hero/Hero.styles.tsx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,12 +55,17 @@ export const HeroImage = styled.img`
5555
}
5656
`
5757

58-
export const HeroButton = styled.button`
58+
export const HeroButton = styled.a`
5959
margin: auto;
6060
width: max-content;
6161
color: black;
62+
cursor: pointer;
63+
text-decoration: none;
6264
border-radius: 40px;
6365
border: 1px solid rgb(97, 218, 251);
6466
padding: 0.5rem 2rem;
6567
background: ${props => props.theme.colors.gradientButton};
68+
&:hover {
69+
color: black;
70+
}
6671
`

src/components/Hero/Hero.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ export const Hero: React.FC = () => {
2323
</HeroTitle>
2424
<HeroSubtitle>{t('subtitle', { interpolation: { escapeValue: true } })}</HeroSubtitle>
2525
<HeroDescription>{t('description')}</HeroDescription>
26-
<HeroButton>{t('button')}</HeroButton>
26+
<HeroButton href='#startNow'>{t('button')}</HeroButton>
2727
</HeroContent>
2828
<HeroImage src={shieldjsLogo} alt="ShieldJS logo" />
2929
</HeroSection>

src/components/NavBar/NavBar.tsx

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,16 @@
11
import React, { useState } from 'react'
22
import {
33
StyledDesktopNav, StyledMobileNav,
4-
StyledNav, StyledMobileNavMenu, StyledImage, StyledNavButton, StyledRightContainer
4+
StyledNav, StyledMobileNavMenu, StyledImage, StyledRightContainer
55
} from '@/components/NavBar/Navbar.styles'
66
import shieldjsLogo from '@/assets/shieldjs.svg'
77
import { Link } from 'react-router-dom'
88
import { NavBarItems } from './components/NavBarItems/NavBarItems'
99
import { HamburguerMenu } from './components/HamburguerMenu/HamburguerMenu'
1010
import { LanguageSelector } from './components/LanguageSelector'
11-
import { useTranslation } from 'react-i18next'
1211

1312
export const NavBar: React.FC = () => {
1413
const [expanded, setExpanded] = useState(false)
15-
const { t } = useTranslation('navBar')
1614

1715
const handleToggleMenu = () => {
1816
setExpanded(!expanded)
@@ -38,9 +36,6 @@ export const NavBar: React.FC = () => {
3836

3937
<StyledRightContainer>
4038
<LanguageSelector />
41-
<StyledNavButton>
42-
{t('startButton')}
43-
</StyledNavButton>
4439
</StyledRightContainer>
4540

4641
</StyledNav>

src/components/NavBar/Navbar.styles.tsx

Lines changed: 4 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
import styled from 'styled-components'
2-
import { StyledButton } from '../Button/Button.styles'
32

43
export const StyledNavMenu = styled.ul`
54
display: flex;
@@ -24,14 +23,16 @@ export const StyledMobileNav = styled.div`
2423
`
2524

2625
export const StyledNav = styled.nav`
26+
position: sticky;
27+
top: 0;
2728
display: flex;
2829
align-items: center;
2930
justify-content: space-between;
3031
background-color: #1E1E1E;
3132
padding: 1rem 2rem;
3233
width: 100vw;
3334
height: 6.6rem;
34-
box-shadow: 0 0 5px rgba(0,0,0,.2);
35+
box-shadow: 0 9px 15px rgba(0,0,0,0.4);
3536
${props => props.theme.mediaQueries.sm} {
3637
padding: 1rem 2rem;
3738
}
@@ -63,6 +64,7 @@ export const StyledRightContainer = styled.div`
6364
align-items: center;
6465
justify-content: space-between;
6566
gap: 1rem;
67+
margin-left: auto;
6668
`
6769

6870
export const StyledImage = styled.img`
@@ -71,19 +73,3 @@ export const StyledImage = styled.img`
7173
height: 3rem;
7274
}
7375
`
74-
75-
export const StyledNavButton = styled(StyledButton)`
76-
display: none;
77-
color: black;
78-
border-radius: 40px;
79-
border: 1px solid rgb(97, 218, 251);
80-
padding: 0.5rem 1rem;
81-
min-width: auto;
82-
background: ${props => props.theme.colors.gradientButton};
83-
${props => props.theme.mediaQueries.sm} {
84-
display: flex;
85-
}
86-
&:hover {
87-
background: ${props => props.theme.colors.gradientButton};
88-
}
89-
`

src/components/Technologies/Technologies.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ export const Technologies: React.FC = () => {
1212
<TechnologiesTitle>{t('title')}</TechnologiesTitle>
1313
<TechnologiesSubtitle>{t('subtitle')}</TechnologiesSubtitle>
1414
</TechnologiesTextsContainer>
15-
<TechnologiesList>
15+
<TechnologiesList id="startNow">
1616
{technologiesImages.map(({ src, alt, key, href }) =>
1717
<TechnologiesListItem key={key}>
1818
<a href={href} target='_blank' rel="noreferrer">

src/index.css

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,8 @@
2626
-webkit-text-size-adjust: 100%;
2727
max-width: 1280px;
2828
text-align: center;
29+
scroll-behavior: smooth;
30+
2931
}
3032

3133
* {

src/layout/MainLayout/MainLayout.styles.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ export const MainWrapper = styled.div`
55
flex-direction: column;
66
min-height: 100vh;
77
width: 100%;
8+
89
`
910

1011
export const Main = styled.main`

src/pages/About/About.styles.tsx

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
import styled from 'styled-components'
2+
3+
export const AboutWrapper = styled.div`
4+
min-height: 100vh;
5+
max-width: 1000px;
6+
display: flex;
7+
flex-direction: column;
8+
margin: 0 auto;
9+
`

src/pages/About/About.tsx

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,22 @@
11
import { MainLayout } from '@/layout/MainLayout/MainLayout'
22
import { useTranslation } from 'react-i18next'
33
import { Link } from 'react-router-dom'
4+
import { AboutWrapper } from './About.styles'
45

56
export const About = () => {
67
const { t } = useTranslation('about')
78

89
return (
910
<MainLayout>
10-
<h1>{t('title')}</h1>
11-
<h2>{t('subtitle')}</h2>
12-
<p>{t('description.p1')}</p>
13-
<p>{t('description.p2')}</p>
14-
<p>{t('description.p3')}</p>
15-
<h3>{t('conclusion')}</h3>
16-
<Link to="/">{t('sendBack')}</Link>
11+
<AboutWrapper>
12+
<h1>{t('title')}</h1>
13+
<h2>{t('subtitle')}</h2>
14+
<p>{t('description.p1')}</p>
15+
<p>{t('description.p2')}</p>
16+
<p>{t('description.p3')}</p>
17+
<h3>{t('conclusion')}</h3>
18+
<Link to="/">{t('sendBack')}</Link>
19+
</AboutWrapper>
1720
</MainLayout>
1821
)
1922
}

0 commit comments

Comments
 (0)