@@ -4,21 +4,17 @@ import { rem } from 'polished'
44import styled from 'styled-components'
55
66import { Heading } from 'components'
7- import { FlexSectionContent } from 'components/layout'
87import { useIsMaxScreenSize } from 'helpers/hooks'
9- import ChevronSvg from 'public/chevron.svg'
10- import {
11- TABLET_LARGE_SIZE ,
12- MOBILE_SIZE ,
13- TABLET_SMALL_SIZE ,
14- } from 'styles/constants'
8+ import { TABLET_LARGE_SIZE , TABLET_SMALL_SIZE } from 'styles/constants'
159
10+ import ChevronSvg from '../../static/icons/chevron.svg'
1611import ExecutiveAvatar from './executive-avatar'
12+ import { people } from './people'
1713
1814const { h2 } = Heading . VARIANT
1915
2016const StyledSection = styled . section `
21- padding: ${ rem ( '164px ' ) } 0;
17+ padding: ${ rem ( '100px ' ) } 0;
2218
2319 @media only screen and (max-width: ${ TABLET_LARGE_SIZE } ) {
2420 padding: ${ rem ( '124px' ) } 0;
@@ -27,23 +23,28 @@ const StyledSection = styled.section`
2723
2824const StyledHeading = styled ( ( props ) => < Heading { ...props } /> ) `
2925 text-align: center;
26+ margin-bottom: ${ rem ( '42px' ) } ;
27+
28+ @media only screen and (min-width: ${ TABLET_SMALL_SIZE } ) {
29+ margin-bottom: ${ rem ( '108px' ) } ;
30+ }
3031`
3132
3233const AvatarList = styled . div `
3334 display: flex;
3435 flex-direction: row;
3536 flex-wrap: wrap;
36- justify-content: space-around;
37- margin: 0 120px;
38- padding-top: ${ rem ( '108px' ) } ;
37+ justify-content: center;
38+ margin: 0 auto;
39+ max-width: ${ rem ( '1240px' ) } ;
40+ padding: 0 ${ rem ( '35px' ) } ;
3941
40- @media only screen and (max -width: ${ TABLET_LARGE_SIZE } ) {
41- margin : 0 10% ;
42+ @media only screen and (min -width: ${ TABLET_SMALL_SIZE } ) {
43+ padding : 0 ${ rem ( '40px' ) } ;
4244 }
4345
44- @media only screen and (max-width: ${ MOBILE_SIZE } ) {
45- padding-top: ${ rem ( '42px' ) } ;
46- margin: 0;
46+ @media only screen and (min-width: ${ TABLET_LARGE_SIZE } ) {
47+ padding: 0 ${ rem ( '60px' ) } ;
4748 }
4849`
4950
@@ -52,16 +53,19 @@ const LinkButtonContainer = styled.div`
5253 flex-direction: column;
5354 align-self: flex-end;
5455 margin-top: ${ rem ( '24px' ) } ;
55- margin-bottom: ${ rem ( '32px' ) } ;
56+ margin-bottom: ${ rem ( '65px' ) } ;
57+ max-width: 50%;
58+ flex: 0 0 50%;
5659`
5760
5861const LinkButton = styled . button `
59- color: #8493b0 ;
62+ color: #ff6ab9 ;
6063 text-decoration: underline;
6164 font-size: 18px;
6265 font-weight: 700;
6366 border: none;
6467 background: none;
68+ cursor: pointer;
6569`
6670
6771const InvertedChevronSvg = styled ( ChevronSvg ) `
@@ -73,52 +77,6 @@ const LinkButtonTextContainer = styled.span`
7377 padding-right: ${ rem ( '4px' ) } ;
7478`
7579
76- const people = [
77- { name : 'Greg Gunn' , postion : 'Co-Founder' , src : '/greg.jpeg' } ,
78- {
79- name : 'Beier Cai' ,
80- postion : 'Co-Founder' ,
81- src : '/beier.jpeg' ,
82- } ,
83- { name : 'Noel Pullen' , postion : 'CXO' , src : '/noel.jpeg' } ,
84- { name : 'Cong Ly' , postion : 'VP Growth' , src : '/cong.jpeg' } ,
85- {
86- name : 'Ashley Brookes' ,
87- postion : 'VP Marketing' ,
88- src : '/ashley.jpeg' ,
89- } ,
90- {
91- name : 'Tiffany Jung' ,
92- postion : 'VP Strategy & OPS' ,
93- src : '/tiffany.jpeg' ,
94- } ,
95- {
96- name : 'Sarah Marion' ,
97- postion : 'Founder Partnerships' ,
98- src : '/sarah.jpeg' ,
99- } ,
100- {
101- name : 'Bill Monkman' ,
102- postion : 'Chief Architect' ,
103- src : '/bill.jpeg' ,
104- } ,
105- {
106- name : 'Steven Shi' ,
107- postion : 'Staff Devops Engineer' ,
108- src : '/steven.jpeg' ,
109- } ,
110- {
111- name : 'Phong Thieu' ,
112- postion : 'Engineering Manager' ,
113- src : '/phong.jpeg' ,
114- } ,
115- {
116- name : 'Renee Tung' ,
117- postion : 'Finance' ,
118- src : '/renee.jpeg' ,
119- } ,
120- ]
121-
12280const ExecutiveTeamSection = ( ) => {
12381 const isCompactScreen = useIsMaxScreenSize ( TABLET_SMALL_SIZE )
12482 const [ showAllPeople , setShowAllPeople ] = useState ( false )
@@ -130,27 +88,25 @@ const ExecutiveTeamSection = () => {
13088
13189 return (
13290 < StyledSection >
133- < FlexSectionContent >
134- < StyledHeading variant = { h2 } > Our Executive Team</ StyledHeading >
135- < AvatarList >
136- { peopleToShow . map ( ( person ) => (
137- < ExecutiveAvatar { ...person } key = { person . name } />
138- ) ) }
139- { isCompactScreen && (
140- < LinkButtonContainer >
141- < LinkButton
142- onClick = { ( ) => setShowAllPeople ( ! showAllPeople ) }
143- type = "button"
144- >
145- < LinkButtonTextContainer >
146- { showAllPeople ? 'Collapse' : 'Whole Team' }
147- </ LinkButtonTextContainer >
148- { showAllPeople ? < InvertedChevronSvg /> : < ChevronSvg /> }
149- </ LinkButton >
150- </ LinkButtonContainer >
151- ) }
152- </ AvatarList >
153- </ FlexSectionContent >
91+ < StyledHeading variant = { h2 } > Our Executive Team</ StyledHeading >
92+ < AvatarList >
93+ { peopleToShow . map ( ( person ) => (
94+ < ExecutiveAvatar { ...person } key = { person . name } />
95+ ) ) }
96+ { isCompactScreen && (
97+ < LinkButtonContainer >
98+ < LinkButton
99+ onClick = { ( ) => setShowAllPeople ( ! showAllPeople ) }
100+ type = "button"
101+ >
102+ < LinkButtonTextContainer >
103+ { showAllPeople ? 'Collapse' : 'Whole Team' }
104+ </ LinkButtonTextContainer >
105+ { showAllPeople ? < InvertedChevronSvg /> : < ChevronSvg /> }
106+ </ LinkButton >
107+ </ LinkButtonContainer >
108+ ) }
109+ </ AvatarList >
154110 </ StyledSection >
155111 )
156112}
0 commit comments