Created
May 18, 2017 05:58
-
-
Save AmatsukiKu/e80e34452f45beeb577a3b597a64647d to your computer and use it in GitHub Desktop.
srcsetにアスペクト比が異なる画像を入れてしまったサンプル
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<meta name="viewport" content="width=device-width,initial-scale=1,user-scalable=no" /> | |
<style> | |
body { | |
padding: 0; | |
margin: 0; | |
} | |
img { | |
float: left; | |
padding: 0; | |
margin: 0; | |
} | |
</style> | |
</head> | |
<body> | |
<img sizes="(max-width: 400px) 100px, 200px" srcset="https://dummyimage.com/100x400/000/fff 100w, https://dummyimage.com/400x100/000/fff 200w" src="https://dummyimage.com/10x10/000/fff" /> | |
<p>Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.</p> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment