ResponsiveWrapper

A responsive wrapper that works well with images. Adds a padding element based on the natural height and width that is given as props which makes the image more responsive.

<ResponsiveWrapper
	naturalWidth={ 2000 }
	naturalHeight={ 680 }
>
	<img src="https://natureconservancy-h.assetsadobe.com/is/image/content/dam/tnc/nature/en/photos/tnc_69881045.jpg?crop=240,0,2400,1320&wid=4000&hei=2200&scl=0.6" alt="WordPress" />
</ResponsiveWrapper>

Seems to only allow one child.

GitHub URL
Classification

Category

Components