15 lines
948 B
Markdown
15 lines
948 B
Markdown
|
# Grouping Selectors
|
||
|
|
||
|
Let's build a little off the previous exercise, where you (hopefully) added multiple classes to a single element in order to apply two different rules to it.
|
||
|
|
||
|
Instead of having a single element with two different rules applied, though, we're instead going to give two elements each a unique class name, then add rules for styles that both elements share as well as their own unique styles. Make sure you take a good look at the outcome image below to see exactly what is unique about each element, and what both elements have in common.
|
||
|
|
||
|
This will help you further practice adding classes and using class selectors, so be sure you add the class attribute in the HTML file.
|
||
|
|
||
|
## Desired Outcome
|
||
|
<!-- Insert Outcome Image -->
|
||
|
|
||
|
### Self Check
|
||
|
- Does each element have a unique class name?
|
||
|
- Did you use the grouping selector for styles that both elements share?
|
||
|
- Did you make separate rules for the styles unique to each element?
|