File tree Expand file tree Collapse file tree 6 files changed +70
-50
lines changed Expand file tree Collapse file tree 6 files changed +70
-50
lines changed Original file line number Diff line number Diff line change @@ -21,7 +21,7 @@ export const globalStyles = css`
21
21
}
22
22
${ bpMaxSM } {
23
23
h1 {
24
- font-size: 30px ;
24
+ font-size: 28px ;
25
25
}
26
26
h2 {
27
27
font-size: 24px;
@@ -41,6 +41,14 @@ export const globalStyles = css`
41
41
font-family: ${ fonts . semiboldItalic } ;
42
42
}
43
43
}
44
+ h1,
45
+ h2,
46
+ h3,
47
+ h4 {
48
+ a {
49
+ color: inherit;
50
+ }
51
+ }
44
52
input {
45
53
border-radius: 4px;
46
54
border: 1px solid ${ theme . colors . gray } ;
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ export const bpMinLG = `@media (min-width: ${minLG}px)`
10
10
export const bpMinXL = `@media (min-width: ${ minXL } px)`
11
11
export const bpMinXXL = `@media (min-width: ${ minXXL } px)`
12
12
13
- export const bpMaxXS = `' @media (max-width: ${ minSM - 1 } px)' `
14
- export const bpMaxSM = `' @media (max-width: ${ minMD - 1 } px)' `
15
- export const bpMaxMD = `' @media (max-width: ${ minLG - 1 } px)' `
16
- export const bpMaxLG = `' @media (max-width: ${ minXL - 1 } px)' `
13
+ export const bpMaxXS = `@media (max-width: ${ minSM - 1 } px)`
14
+ export const bpMaxSM = `@media (max-width: ${ minMD - 1 } px)`
15
+ export const bpMaxMD = `@media (max-width: ${ minLG - 1 } px)`
16
+ export const bpMaxLG = `@media (max-width: ${ minXL - 1 } px)`
Original file line number Diff line number Diff line change @@ -30,7 +30,9 @@ ul, ol {
30
30
box-sizing : border-box;
31
31
-ms-overflow-style : scrollbar;
32
32
-webkit-tap-highlight-color : rgba (0 , 0 , 0 , 0 );
33
-
33
+ -webkit-font-smoothing : antialiased;
34
+ -moz-osx-font-smoothing : grayscale;
35
+ }
34
36
body {
35
37
color : ${ theme . colors . body_color } ;
36
38
background-color : ${ theme . colors . bg_color } ;
Original file line number Diff line number Diff line change @@ -47,15 +47,6 @@ const Hero = ({ description }) => (
47
47
</ section >
48
48
)
49
49
50
- const PostTitle = styled . h2 `
51
- margin-bottom: ${ rhythm ( 0.3 ) } ;
52
- transition: ${ theme . transition . ease } ;
53
- :hover {
54
- color: ${ theme . brand . primary } ;
55
- transition: ${ theme . transition . ease } ;
56
- }
57
- `
58
-
59
50
const Description = styled . p `
60
51
margin-bottom: 10px;
61
52
display: inline-block;
@@ -81,12 +72,22 @@ export default function Index({ data: { site, allMdx } }) {
81
72
margin-bottom: 40px;
82
73
` }
83
74
>
84
- < Link
85
- to = { post . frontmatter . slug }
86
- aria-label = { `View ${ post . frontmatter . title } ` }
75
+ < h2
76
+ css = { css ( {
77
+ marginBottom : rhythm ( 0.3 ) ,
78
+ transition : theme . transition . ease ,
79
+ ':hover' : {
80
+ color : theme . brand . primary ,
81
+ } ,
82
+ } ) }
87
83
>
88
- < PostTitle > { post . frontmatter . title } </ PostTitle >
89
- </ Link >
84
+ < Link
85
+ to = { post . frontmatter . slug }
86
+ aria-label = { `View ${ post . frontmatter . title } ` }
87
+ >
88
+ { post . frontmatter . title }
89
+ </ Link >
90
+ </ h2 >
90
91
< Description >
91
92
{ post . excerpt } { ' ' }
92
93
< Link
Original file line number Diff line number Diff line change @@ -6,7 +6,7 @@ import Container from 'components/Container'
6
6
import SEO from '../components/SEO'
7
7
import Layout from '../components/Layout'
8
8
import Link from '../components/Link'
9
- import { bpMaxSM } from '../lib/breakpoints'
9
+ import { bpMaxSM , bpMinMD } from '../lib/breakpoints'
10
10
11
11
const Blog = ( {
12
12
data : { site, allMdx } ,
@@ -18,8 +18,9 @@ const Blog = ({
18
18
. map ( id =>
19
19
allMdx . edges . find (
20
20
edge =>
21
- edge . node . id === id && edge . node . parent . sourceInstanceName !== 'pages'
22
- )
21
+ edge . node . id === id &&
22
+ edge . node . parent . sourceInstanceName !== 'pages' ,
23
+ ) ,
23
24
)
24
25
. filter ( post => post !== undefined )
25
26
@@ -58,25 +59,25 @@ const Blog = ({
58
59
margin-top: 20px;
59
60
}
60
61
}
61
- .gatsby-image-wrapper {
62
- }
63
62
background: white;
64
63
padding: 40px;
65
64
${ bpMaxSM } {
66
- padding: 20px;
65
+ padding: ${ post . frontmatter . banner
66
+ ? '0 20px 20px 20px'
67
+ : '20px' } ;
67
68
}
68
69
display: flex;
69
70
flex-direction: column;
70
71
` }
71
72
>
72
73
{ post . frontmatter . banner && (
73
74
< div
74
- css = { css `
75
- padding: 60px 60px 40px 60px;
76
- ${ bpMaxSM } {
77
- padding: 20px;
78
- }
79
- ` }
75
+ css = { css ( {
76
+ margin : '0 -20px 30px -20px' ,
77
+ [ bpMinMD ] : {
78
+ margin : '0 0 40px 0' ,
79
+ } ,
80
+ } ) }
80
81
>
81
82
< Link
82
83
aria-label = { `View ${ post . frontmatter . title } article` }
@@ -88,8 +89,7 @@ const Blog = ({
88
89
) }
89
90
< h2
90
91
css = { css `
91
- margin-top: 30px;
92
- margin-bottom: 10px;
92
+ margin: 0 0 20px 0;
93
93
` }
94
94
>
95
95
< Link
Original file line number Diff line number Diff line change @@ -8,7 +8,7 @@ import Container from 'components/Container'
8
8
import Layout from '../components/Layout'
9
9
import Share from '../components/Share'
10
10
import config from '../../config/website'
11
- import { bpMaxSM } from '../lib/breakpoints'
11
+ import { bpMaxSM , bpMinMD , bpMinLG } from '../lib/breakpoints'
12
12
import get from 'lodash/get'
13
13
14
14
export default function Post ( {
@@ -29,36 +29,45 @@ export default function Post({
29
29
isBlogPost
30
30
/>
31
31
< article
32
- css = { css `
33
- width: 100%;
34
- display: flex;
35
- ` }
32
+ css = { css ( {
33
+ width : '100%' ,
34
+ display : 'flex' ,
35
+ '.gatsby-resp-image-link' : {
36
+ margin : '0 -20px' ,
37
+ [ bpMinMD ] : {
38
+ margin : 0 ,
39
+ } ,
40
+ } ,
41
+ } ) }
36
42
>
37
43
< Container >
38
44
< h1
39
- css = { css `
40
- text-align: center;
41
- margin-bottom: 20px;
42
- ` }
45
+ css = { css ( {
46
+ textAlign : 'center' ,
47
+ margin : '0 0 30px 0' ,
48
+ [ bpMinMD ] : {
49
+ margin : '0 0 50px 0' ,
50
+ } ,
51
+ } ) }
43
52
>
44
53
{ title }
45
54
</ h1 >
46
55
{ banner && (
47
56
< div
48
- css = { css `
49
- padding: 30px;
50
- ${ bpMaxSM } {
51
- padding: 0;
52
- }
53
- ` }
57
+ css = { css ( {
58
+ margin : '0 -20px 30px -20px' ,
59
+ [ bpMinMD ] : {
60
+ width : '90%' ,
61
+ margin : '0 auto 50px auto' ,
62
+ } ,
63
+ } ) }
54
64
>
55
65
< Img
56
66
sizes = { banner . childImageSharp . fluid }
57
67
alt = { site . siteMetadata . keywords . join ( ', ' ) }
58
68
/>
59
69
</ div >
60
70
) }
61
- < br />
62
71
< MDXRenderer > { mdx . code . body } </ MDXRenderer >
63
72
</ Container >
64
73
{ /* <SubscribeForm /> */ }
You can’t perform that action at this time.
0 commit comments