freeCodeCamp/curriculum/challenges/italian/14-responsive-web-design-22/learn-the-css-box-model-by-.../60a3e3396c7b40068ad6996f.md

48 lines
817 B
Markdown
Raw Normal View History

---
id: 60a3e3396c7b40068ad6996f
title: Step 6
challengeType: 0
dashedName: step-6
---
# --description--
Aggiungi un elemento `div` all'interno del `body`.
Imposta l'attributo `class` su `canvas`. Ad esempio, `<div class="my-div">`.
Questo elemento fungerà da tela per il tuo dipinto.
# --hints--
Il codice dovrebbe avere un elemento `div`.
```js
assert(document.querySelectorAll('div').length === 1)
```
L'elemento `div` dovrebbe avere un attributo `class` con il valore `canvas`.
```js
assert(document.querySelector('div').className.split(' ').includes('canvas'))
```
# --seed--
## --seed-contents--
```html
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Rothko Painting</title>
</head>
<body>
--fcc-editable-region--
--fcc-editable-region--
</body>
</html>
```