Files
Nicholas Carrigan (he/him) 59c24bd4be chore: rename cafe menu (#44201)
* chore: rename files

* chore: update codebase

* chore: proper title case

* chore: missed block name

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
Co-authored-by: Tom <20648924+moT01@users.noreply.github.com>
2021-11-19 22:22:24 -06:00

74 lines
1.4 KiB
Markdown

---
id: 5f3477ae34c1239cafe128be
title: Step 14
challengeType: 0
dashedName: step-14
---
# --description--
You now have three type selectors with the exact same styling. You can add the same group of styles to many elements by separating the selectors with commas like this:
```css
selector1, selector2 {
property: value;
}
```
Use a single type selector to center the `h1`, `h2` and `p` elements at the same time.
# --hints--
You should use a single type selector for all three elements, `h1, h2, p`. Be sure to use that order.
```js
const hasSelector = new __helpers.CSSHelp(document).getStyle('h1, h2, p');
assert(hasSelector);
```
You should only have one selector in your `style` element.
```js
const selectors = new __helpers.CSSHelp(document).getCSSRules().filter(x => x.selectorText)
assert(selectors.length === 1);
```
# --seed--
## --seed-contents--
```html
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8" />
<title>Camper Cafe Menu</title>
--fcc-editable-region--
<style>
h1 {
text-align: center;
}
h2 {
text-align: center;
}
p {
text-align: center;
}
</style>
--fcc-editable-region--
</head>
<body>
<header>
<h1>CAMPER CAFE</h1>
<p>Est. 2020</p>
</header>
<main>
<section>
<h2>Coffee</h2>
</section>
</main>
</body>
<html>
```