freeCodeCamp/curriculum/challenges/italian/14-responsive-web-design-22/learn-css-grid-by-building-.../61439e33e4fb7967609e0c83.md

149 lines
5.0 KiB
Markdown
Raw Normal View History

---
id: 61439e33e4fb7967609e0c83
title: Step 14
challengeType: 0
dashedName: step-14
---
# --description--
Dopo i tre elementi `p` all'interno dell'elemento `.text` crea un elemento `blockquote`. All'interno di questo, aggiungi un elemento `hr`, un elemento `p` con l'attributo `class` impostato su `quote` e un secondo elemento `hr`.
Dai all'elemento `.quote` il testo `The entire curriculum should be a series of projects`.
# --hints--
Dovresti creare un nuovo elemento `blockquote` all'interno dell'elemento `.text`.
```js
assert.exists(document.querySelector('.text blockquote'));
```
L'elemento `blockquote` dovrebbe trovarsi dopo i tre elementi `p`.
```js
assert(document.querySelector('.text')?.children?.[3]?.localName === 'blockquote');
```
L'elemento `blockquote` dovrebbe avere due elementi `hr`.
```js
assert(document.querySelectorAll('.text blockquote hr')?.length === 2);
```
L'elemento `blockquote` dovrebbe contenere un elemento `p`.
```js
assert.exists(document.querySelector('.text blockquote p'));
```
Gli elementi figli di `blockquote` dovrebbero essere nell'ordine corretto.
```js
const children = document.querySelector('.text blockquote')?.children;
assert(children?.[0]?.localName === 'hr');
assert(children?.[1]?.localName === 'p');
assert(children?.[2]?.localName === 'hr');
```
Il nuovo elemento `p` dovrebbe avere l'attributo `class` impostato su `quote`.
```js
assert(document.querySelector('.text blockquote p')?.className === 'quote');
```
Il nuovo elemento `p` dovrebbe contenere il testo `The entire curriculum should be a series of projects`.
```js
assert(document.querySelector('.text blockquote p')?.innerText === 'The entire curriculum should be a series of projects');
```
# --seed--
## --seed-contents--
```html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Magazine</title>
<link
href="https://fonts.googleapis.com/css?family=Anton%7CBaskervville%7CRaleway&display=swap"
rel="stylesheet"
/>
<link
rel="stylesheet"
href="https://use.fontawesome.com/releases/v5.8.2/css/all.css"
/>
<link rel="stylesheet" href="styles.css" />
</head>
<body>
<main>
<section class="heading">
<header class="hero">
<img
src="https://cdn.freecodecamp.org/platform/universal/fcc_meta_1920X1080-indigo.png"
alt="freecodecamp logo"
loading="lazy"
class="hero-img"
width="400"
/>
<h1 class="hero-title">OUR NEW CURRICULUM</h1>
<p class="hero-subtitle">
Our efforts to restructure our curriculum with a more project-based
focus
</p>
</header>
<div class="author">
<p class="author-name">
By
<a href="https://freecodecamp.org" target="_blank" rel="noreferrer"
>freeCodeCamp</a
>
</p>
<p class="publish-date">March 7, 2019</p>
</div>
<div class="social-icons">
<a href="https://www.facebook.com/freecodecamp/">
<i class="fab fa-facebook-f"></i>
</a>
<a href="https://twitter.com/freecodecamp/">
<i class="fab fa-twitter"></i>
</a>
<a href="https://instagram.com/freecodecamp">
<i class="fab fa-instagram"></i>
</a>
<a href="https://www.linkedin.com/school/free-code-camp/">
<i class="fab fa-linkedin-in"></i>
</a>
<a href="https://www.youtube.com/freecodecamp">
<i class="fab fa-youtube"></i>
</a>
</div>
</section>
<section class="text">
<p class="first-paragraph">
Soon the freeCodeCamp curriculum will be 100% project-driven learning. Instead of a series of coding challenges, you'll learn through building projects - step by step. Before we get into the details, let me emphasize: we are not changing the certifications. All 6 certifications will still have the same 5 required projects. We are only changing the optional coding challenges.
</p>
<p>
After years - years - of pondering these two problems and how to solve them, I slipped, hit my head on the sink, and when I came to I had a revelation! A vision! A picture in my head! A picture of this! This is what makes time travel possible: the flux capacitor!
</p>
<p>
It wasn't as dramatic as Doc's revelation in Back to the Future. It
just occurred to me while I was going for a run. The revelation: the entire curriculum should be a series of projects. Instead of individual coding challenges, we'll just have projects, each with their own seamless series of tests. Each test gives you just enough information to figure out how to get it to pass. (And you can view hints if that isn't enough.)
</p>
--fcc-editable-region--
--fcc-editable-region--
</section>
</main>
</body>
</html>
```
```css
```