- index.html
- style.css
HTML
<!DOCTYPE html>
<html lang="es">
<head>
<title>Rotación animada y transform-origin</title>
<meta charset="utf-8">
<link rel="stylesheet" href="world.css">
<link rel="stylesheet" href="style.css">
</head>
<body>
<div class="world homeworld">
<div class="picture-frame">
<div class="picture"></div>
</div>
<button class="btn-activate">Ejecutar</button>
</div>
</body>
</html>
CSS
.picture {
transition: transform 1s ease;
transform: rotate(0deg);
}
.picture.active {
transform: rotate(360deg);
}
Ha ido a otra página
ObjetivosRealizado
0
Cambia el valor de transform-origin del bloque .picture a:
top left.top right.bottom left.50% 100%.
Después de cada cambio, pulsa «Ejecutar».