File tree Expand file tree Collapse file tree 1 file changed +16
-3
lines changed Expand file tree Collapse file tree 1 file changed +16
-3
lines changed Original file line number Diff line number Diff line change @@ -117,7 +117,12 @@ class CodeBlock extends React.PureComponent<
117
117
function PlainImage ( imageProps ) {
118
118
const { isRss, src, ...props } = imageProps ;
119
119
return (
120
- < Box as = "span" align = "center" justify = "center" style = { { display : 'flex' } } >
120
+ < Box
121
+ margin = { { vertical : 'medium' } }
122
+ as = "span"
123
+ align = "center"
124
+ justify = "center"
125
+ style = { { display : 'flex' } } >
121
126
{ /*eslint-disable-next-line jsx-a11y/alt-text*/ }
122
127
< img style = { { maxWidth : '100%' } } src = { imageUrl ( { src} ) } { ...props } />
123
128
{ props . isRss ? < br /> : null }
@@ -143,7 +148,11 @@ function isGif(src: string) {
143
148
144
149
function Image ( props ) {
145
150
if ( props . src && isGif ( props . src ) ) {
146
- return < GifPlayer style = { { maxWidth : '100%' } } src = { props . src } /> ;
151
+ return (
152
+ < Box margin = { { vertical : 'medium' } } >
153
+ < GifPlayer style = { { maxWidth : '100%' } } src = { props . src } />
154
+ </ Box >
155
+ ) ;
147
156
}
148
157
return < PlainImage { ...props } /> ;
149
158
}
@@ -293,7 +302,11 @@ const defaultRenderers = ({
293
302
if ( props . language === 'backmatter' ) {
294
303
return null ;
295
304
}
296
- return < CodeBlock { ...props } /> ;
305
+ return (
306
+ < Box margin = { { vertical : 'small' } } >
307
+ < CodeBlock { ...props } />
308
+ </ Box >
309
+ ) ;
297
310
} ,
298
311
image : Image ,
299
312
paragraph : ParagraphWrapper ,
You can’t perform that action at this time.
0 commit comments