diff --git a/gatsby-browser.js b/gatsby-browser.js index b1e5c31..9dfa471 100644 --- a/gatsby-browser.js +++ b/gatsby-browser.js @@ -4,4 +4,4 @@ * See: https://www.gatsbyjs.org/docs/browser-apis/ */ -// You can delete this file if you're not using it +import "@styles/global.css"; diff --git a/src/components/global.js b/src/components/global.js index 371295c..bc66907 100644 --- a/src/components/global.js +++ b/src/components/global.js @@ -30,7 +30,10 @@ export const Container = styled.div` `; export const Section = styled.section` - padding: 7rem 0; + padding: 1rem 0; + @media (min-width: ${props => props.theme.screen.md}) { + padding: 2rem 0; + } ${props => props.accent && `background-color: ${props.theme.color.black.lighter}`} diff --git a/src/components/sections/Gallery.js b/src/components/sections/Gallery.js index abbdc7c..cf560ff 100644 --- a/src/components/sections/Gallery.js +++ b/src/components/sections/Gallery.js @@ -1,5 +1,4 @@ import React from 'react'; -import styled from 'styled-components'; import { StaticQuery, graphql } from 'gatsby'; import Img from 'gatsby-image'; @@ -71,7 +70,7 @@ const Gallery = () => ( )} /> ); -const Grid = styled.div` - display: grid; - grid-template-columns: repeat(auto-fill, 200px); - grid-gap: 24px; - - > a { - text-decoration: none; - color: inherit; - } -`; - export default Gallery; diff --git a/src/components/sections/Header.js b/src/components/sections/Header.js index 8f76438..680e5eb 100644 --- a/src/components/sections/Header.js +++ b/src/components/sections/Header.js @@ -7,7 +7,7 @@ import { Container, Button } from '@components/global'; const Header = props => (
-
+
diff --git a/src/components/sections/Schedule.js b/src/components/sections/Schedule.js index 53b6388..d1781f9 100644 --- a/src/components/sections/Schedule.js +++ b/src/components/sections/Schedule.js @@ -92,7 +92,7 @@ class Schedule extends React.PureComponent { return (
-

+

Schedule

@@ -121,13 +121,14 @@ class Schedule extends React.PureComponent { } const Tabs = styled.div` - display: grid; - grid-template-columns: ${props => `repeat(${props.num}, 200px)`}; - grid-gap: 32px; + display: flex; justify-content: center; + flex-wrap: wrap; `; const Tab = styled(Button)` + margin: 10px; + padding: 10px 4rem; background-color: ${props => props.theme.color.blue[props.active ? 'dark' : 'regular']}; diff --git a/src/components/sections/Sponsors.js b/src/components/sections/Sponsors.js index c1ba22c..b25b0cc 100644 --- a/src/components/sections/Sponsors.js +++ b/src/components/sections/Sponsors.js @@ -29,7 +29,7 @@ const SPONSORS = [ const Sponsors = () => (
-

Sponsors

+

Sponsors

{SPONSORS.map(({ logo, link }) => ( @@ -49,11 +49,13 @@ const Flex = styled.div` const Sponsor = styled(ExternalLink)` max-width: 160px; - margin-bottom: 2rem; + margin: 1rem; - &:not(:last-child) { - margin-right: 4rem; - } + @media (min-width: ${props => props.theme.screen.md}) { + &:not(:last-child) { + margin-right: 4rem; + } + } > svg { width: 100%; diff --git a/src/styles/global.css b/src/styles/global.css new file mode 100644 index 0000000..53a1003 --- /dev/null +++ b/src/styles/global.css @@ -0,0 +1,21 @@ +.header{ + display: flex; + align-items: center; + flex-wrap: wrap; +} + +.gallery{ + display: flex; + justify-content: space-around; + align-items: center; + flex-wrap: wrap; +} + +.gallery > a{ + display:block; + text-decoration: none; + color: inherit; + max-width:340px; + width:90%; + text-align:center; +} \ No newline at end of file