Review and Spoilers
- Assignment 1 CPNT-201 is due today at 11:59pm.
- Initializing a git repository from the command line.
- HTML and CSS Validation
Activity: Easy Images
Materials
Tools
Instructions
Responsive Image
- Copy and paste the starter code into your workspace or use your own code from yesterday.
- Add an
<img>
element to the top of the page inside the<section>
element:- Set
src
to a Lorem Picsum images such as:https://picsum.photos/id/237/200/300
- Experiment with the last two numbers in the URL to set different a height and width of the image.
- Set
alt
text to something that describes your image;
- Set
- In your CSS, target your new image with a type selector:
- Set
display
toblock
- Set
width
to100%
(this makes your image responsive)
- Set
Floated Circular Image
- Repeat Steps 1 and 2 above, placing the image before an
<h2>
element; - In your CSS, target your second image using a class selector and:
- Set
float
property toleft
orright
(try both and see what happens) - Set
border-radius
to50%
or some other length value.
- Set
Activity: Adding a Splash of Colour
Materials
- Your Moodboard colour palettes!
- The Ultimate Collection of Google Font Pairings (for its colours)
Tools
Instructions
- In Firefox, go to a webpage with a colour pallette you’d like to copy such as The Ultimate Collection of Google Font Pairings.
- Inspect the page by right-clicking on the page;
- Click the eyedropper tool and click a light colour to copy it to your clipboard;
- In the CSS of your starter code:
- Set the
color
of yourbody
element to the colour you copied.
- Set the
- Repeat Step 3 with a dark colour;
- In the CSS of your starter code:
- Set the
background-color
of yourbody
element to the second colour you copied.
- Set the
- Important! Use the Contrast Ration Checker to confirm that your colour selections have enough contrast.
- Now try adding a third colour to the
section
element.
Today's Achievement
HTML/CSS Video or Article
Find a video (> 10 mins) or article (> 350 words) about HTML/CSS that you found during today’s coding activities. It should be current, helpful and come from a credible source.
Instructions
- Submit the link to your chosen video or article in Brightspace.
- Include answers to the following questions with your submission:
- How did this resource help you?
- What problem were you trying to solve?
- Does the content creator have any other videos or articles that might be helpful?
Prep
Watch list
- Read color hex codes by David DeSandro
- HTML & CSS for Beginners Part 6: Images by Kevin Powell
Reading List
Mozilla Developer Network