mangojuice33

challenge5

Feb 14th, 2020
117
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
HTML 2.64 KB | None | 0 0
  1. <!DOCTYPE html>
  2. <html lang="en">
  3.     <head>
  4.         <meta charset="UTF-8">
  5.         <title>Catch'em all!</title>
  6.         <link rel="stylesheet" href="style.css">
  7.     </head>
  8.     <body>
  9.         <main>  
  10.             <img class="hover-effect" src="http://images.innoveduc.fr/integration_parcours/css/css_selectors_props/hobbit-house.jpg" alt="Hobbit house">
  11.             <p>Photo by conner Bowe on Unsplash</p>
  12.             <img  src="http://images.innoveduc.fr/integration_parcours/css/css_selectors_props/hobbit-house-grass.jpg" alt="Hobbit house with grass">
  13.             <p>Photo by Jeff Finley on Unsplash</p>
  14.             <img class="hover-effect" src="http://images.innoveduc.fr/integration_parcours/css/css_selectors_props/hobbit-house-grey-grass.jpg" alt="Hobbit house with grey grass">
  15.             <p>Photo by Tyler Lastovich on Unsplash</p>
  16.         </main>
  17.     </body>
  18. </html>
  19.  
  20.  
  21.  
  22.  
  23. /* CSS file */
  24.  
  25. body {
  26.     font-family: 'Courier New', Courier, monospace;
  27. }
  28.  
  29. /* English : Replace the dots below by a selector targeting all the images of the page. */
  30. /* Français : Remplace les points ci-dessous par un sélecteur ciblant toutes les images de la page. */
  31.  
  32. img {
  33.     width: 300px;
  34.     height: 300px;
  35.     border-radius: 10px;
  36.   /* English : Replace with a property that makes the image borders look rounded. */
  37.             /* Français : Remplace par une propriété arrondissant les angles de l'image. */
  38. }
  39.  
  40.  
  41.  
  42. /* English : Replace the dots below by a class named "hover-effect" with a :hover pseudo-class. This class has to target the first image and the last image of the page. */
  43. /* Français : Remplace les points ci-dessous par une classe "hover-effect" avec une pseudo-classe :hover. Cette classe doit cibler la première image et la troisième image de la page. */
  44.  
  45. .hover-effect:hover {
  46.     opacity : 0.8;      /* English : Replace with a property responsible for opacity changes. */
  47.                     /* Français : Remplace par une propriété modifiant l'opacité. */
  48.     cursor: pointer;
  49. }
  50.  
  51. /* English : Replace the dots below by a selector targeting the second image of the page. Do not use a class or an id! */
  52. /* Français : Remplace les points ci-dessous par un sélecteur ciblant la seconde image de la page. N'utilise pas de classe ou d'id ! */
  53.  
  54. img:nth-child(3) {
  55.   filter: grayscale(100%);
  56.     -webkit-filter: grayscale(100%);
  57.     -moz-filter: grayscale(100%);
  58.     -ms-filter: grayscale(100%);
  59.     -o-filter: grayscale(100%);
  60.       /* English : Replace with a property that makes the image look black & white. */
  61.                /* Français : Remplace par une propriété faisant paraître l'image en noir et blanc. */
  62. }
Advertisement
Add Comment
Please, Sign In to add comment