Hola amigos el <strong>hover</strong> no me funciona <code>&lt;&lt;!DOCTYPE html&gt; &lt;html lang="en"&gt; &lt;head&gt; &lt;meta chars...

Pregunta de la clase:
Layout de Instagram
Alejandro Guerrero

Alejandro Guerrero

Pregunta
studenthace 6 años

Hola amigos el hover no me funciona

<<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <meta http-equiv="X-UA-Compatible" content="ie=edge"> <link rel="stylesheet" href="./style.css"> <title>Layout de Instagram</title> </head> <body> <section class="post-list"> <a href="" class="post"> <figure class="post-image"> <img src="../instagram/compu.jpg" alt=""> </figure> </a> <span class="post-overlay"> <p> <span class="post-likes">150</span> <span class="post-comments">10</span> </p> </span> </section> </body> </html> body { margin: 0; font-family: Arial, Helvetica, sans-serif; } .post { cursor: pointer; position: relative; display: flex; width: 200px; } .post-image { margin: 0; } .post-image img { width: 100%; vertical-align: top; } .post-overlay { background: rgba(0, 0, 0, .5); position: absolute; top: 0; right: 0; bottom: 0; left: 0; display: none; align-items: center; justify-content: center; color: white; text-align: center; } .post:hover .post-overlay { display: flex; } >
2 respuestas
para escribir tu comentario
    Alejo Fonseca

    Alejo Fonseca

    studenthace 6 años

    Encerrá todo dentro de <a href="" class="post"> Así Captura de pantalla (37).png

    Stefanny Torres

    Stefanny Torres

    studenthace 6 años

    En el HTML el contenido de post-overlay debe estar dentro de post. O sea queda así:

    <a href="" class="post"> <figure class="post-image"> <img src="img/compu.jpg" alt=""> </figure> <span class="post-overlay"> <p> <span class="post-likes">150</span> <span class="post-comments">10</span> </p> </span> </a>
Curso de CSS Grid Layout 2017

Curso de CSS Grid Layout 2017

El módulo CSS Grid Layout nos permite generar distribuciones del contenido en nuestros sitios web de forma eficiente. Controla esta estructura bidimensional de filas y columnas con propiedades de CSS. Crea layouts increíbles de manera fácil, rápida y sin repetir código.

Curso de CSS Grid Layout 2017
Curso de CSS Grid Layout 2017

Curso de CSS Grid Layout 2017

El módulo CSS Grid Layout nos permite generar distribuciones del contenido en nuestros sitios web de forma eficiente. Controla esta estructura bidimensional de filas y columnas con propiedades de CSS. Crea layouts increíbles de manera fácil, rápida y sin repetir código.