Skip to content

Instantly share code, notes, and snippets.

@zempo
Created December 9, 2018 07:07
Show Gist options
  • Save zempo/453e551dea9f4cc2acce5152ec53c78e to your computer and use it in GitHub Desktop.
Save zempo/453e551dea9f4cc2acce5152ec53c78e to your computer and use it in GitHub Desktop.
Background images drill created by zempo1 - https://repl.it/@zempo1/Background-images-drill
main {
padding: 60px;
}
.animal {
width: 400px;
height: 400px;
border: 1px solid black;
background-image: url(https://picsum.photos/200/200?image=1084);
margin-bottom: 50px;
background-repeat: no-repeat;
background-size: cover;
}
.animals {
border: 1px solid black;
width: 400px;
height: 400px;
background-image: url(https://picsum.photos/200/200?image=1074);
}
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>background images drill</title>
<link href="index.css" rel="stylesheet" type="text/css" />
</head>
<body>
<main role="main">
<div class="animal"></div>
<div class="animals"></div>
</main>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment