Enhanced template; Added images/folder and fixed img path in solution

This commit is contained in:
dev-ethanjohn 2023-08-26 08:56:31 -07:00
parent ea34148b29
commit 21e8746579
6 changed files with 12 additions and 10 deletions

View File

@ -3,11 +3,11 @@
Credits for the images in this exercise go to [Katho Mutodo](https://linktr.ee/photobykatho_) and [Andrea Piacquadio](https://www.pexels.com/@olly?utm_content=attributionCopyText&utm_medium=referral&utm_source=pexels).
With this exercise, we've provided you with a partially completed HTML file which you'll configure. The purpose of this exercise is to focus on understanding how to chain different selectors, rather than solely adding attributes.
With this exercise, we've provided you with a partially completed HTML file which you'll configure. The purpose of this exercise is to focus on understanding how to chain different selectors, rather than solely adding attributes. Additionally, you'll have the chance to review your HTML images.
We have two images for you to style, each with two class names, where one of the class names is shared. The goal here is to chain the selectors for both elements, so that each have a unique style applied, despite using a shared class selector. For example, you want an element that has both X and Y to have one set of styles, while an element with X and Z has a completely different set of styles. We included the original images as well, so that you can see how the styles you will be adding look in comparison, so do not add any styles to them.
**Note:** Group the images in a separate "images" folder. Ensure correct image source paths in your HTML to avoid image loading issues. This is crucial for a cleaner project structure.
**Note:** Download and group the images in a separate "images" folder. Ensure correct image source paths in your HTML to avoid image loading issues. This is crucial for a cleaner project structure.
The properties you need to add to each element are:

View File

@ -8,15 +8,16 @@
<link rel="stylesheet" href="style.css">
</head>
<body>
<!-- Check image source path. Review Foundations lesson - Links and Images -->
<!-- Use the classes BELOW this line -->
<div>
<img class="avatar proportioned" src="./pexels-katho-mutodo-8434791.jpg" alt="Woman with glasses">
<img class="avatar distorted" src="./pexels-andrea-piacquadio-3777931.jpg" alt="Man with surprised expression">
<img class="avatar proportioned" src="" alt="Woman with glasses">
<img class="avatar distorted" src="" alt="Man with surprised expression">
</div>
<!-- Use the classes ABOVE this line -->
<div>
<img class="original proportioned" src="./pexels-katho-mutodo-8434791.jpg" alt="Woman with glasses">
<img class="original distorted" src="./pexels-andrea-piacquadio-3777931.jpg" alt="Man with surprised expression">
<img class="original proportioned" src="" alt="Woman with glasses">
<img class="original distorted" src="" alt="Man with surprised expression">
</div>
</body>
</html>

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 32 KiB

View File

@ -9,12 +9,12 @@
</head>
<body>
<div>
<img class="avatar proportioned" src="../pexels-katho-mutodo-8434791.jpg" alt="Woman with glasses">
<img class="avatar distorted" src="../pexels-andrea-piacquadio-3777931.jpg" alt="Man with surprised expression">
<img class="avatar proportioned" src="./images/pexels-katho-mutodo-8434791.jpg" alt="Woman with glasses">
<img class="avatar distorted" src="./images/pexels-andrea-piacquadio-3777931.jpg" alt="Man with surprised expression">
</div>
<div>
<img class="original proportioned" src="../pexels-katho-mutodo-8434791.jpg" alt="Woman with glasses">
<img class="original distorted" src="../pexels-andrea-piacquadio-3777931.jpg" alt="Man with surprised expression">
<img class="original proportioned" src="./images/pexels-katho-mutodo-8434791.jpg" alt="Woman with glasses">
<img class="original distorted" src="./images/pexels-andrea-piacquadio-3777931.jpg" alt="Man with surprised expression">
</div>
</body>
</html>

View File

@ -0,0 +1 @@
/* Add CSS Styling */