- index.html
- style.css
HTML
<!DOCTYPE html>
<html lang="es">
<head>
<title>Construir un fondo complejo: final</title>
<meta charset="utf-8">
<link rel="stylesheet" href="style.css">
</head>
<body>
<div class="pattern"></div>
</body>
</html>
CSS
.pattern {
height: 100%;
background-color: #333333;
background-image:
linear-gradient(135deg, white 25%, transparent 25%),
linear-gradient(225deg, white 25%, transparent 25%),
linear-gradient(45deg, white 25%, transparent 25%),
linear-gradient(315deg, white 25%, transparent 25%);
background-position:
0 0,
0 0,
0 0,
0 0;
background-size: 100px 100px;
background-repeat: no-repeat;
}
html,
body {
margin: 0;
height: 100%;
}
Ha ido a otra página
ObjetivosRealizado
0
- Reduce el tamaño de todas las imágenes de fondo a
50pxde ancho y de alto. - Después, asigna a los dos primeros fondos la posición
25px 0. - Después, activa la repetición horizontal de todas las imágenes de fondo.
- Por último, activa su repetición en todas las direcciones.