gatsby-casper icon indicating copy to clipboard operation
gatsby-casper copied to clipboard

[Solution] Full width images in markdown

Open Necmttn opened this issue 5 years ago • 3 comments

in PostContent.tsx

export const PostFullContent = styled.section`
	max-width: 1040px;
	...

   ...
	 .gatsby-resp-image-wrapper {
    	// For Full size images
    	max-width: none !important;
  	}

	img[alt$='full'] {
    max-width: none;
    position: absolute !important;
    width: 100vw !important;
    margin-left: calc((-100vw + 1040px) / 2) !important;
  	}
	...
`

and remove inner outer style from post.tsx wrapper div.

Necmttn avatar Jan 09 '19 12:01 Necmttn

and forgot to mention you need to add full at the end of alt for example.

![test image full](img/testimg1.jpg)

Necmttn avatar Jan 10 '19 03:01 Necmttn

Any update on this @scttcper ?

amaljithev avatar May 20 '20 20:05 amaljithev

i'm not sure casper 3 even has full width images

scttcper avatar May 20 '20 20:05 scttcper