1.9 KiB
1.9 KiB
id | title | challengeType | dashedName |
---|---|---|---|
61fd6cc9475a784b7776233e | Passo 7 | 0 | step-7 |
--description--
Abaixo do elemento div
existente, adicione um novo elemento div
com a class
definida como table-wrap
. Este será o contêiner das suas tabelas.
Dentro dela, adicione três elementos table
. Você usará o CSS para estilizá-las em uma única tabela, mas usar tabelas separadas ajudará os leitores de tela a entender o fluxo do documento.
--hints--
Você deve criar um elemento div
.
assert(document.querySelectorAll('div')?.length === 2);
O novo elemento div
deve ter a class
definida como table-wrap
.
assert(document.querySelector('.table-wrap')?.localName === 'div');
O elemento .table-wrap
deve vir após o elemento div
existente.
assert(document.querySelectorAll('div')?.[1]?.classList?.contains('table-wrap'));
O elemento .table-wrap
deve ter três elementos table
.
const children = [...(document.querySelector('.table-wrap')?.children ?? [])];
assert(children?.length === 3);
children.forEach(child => assert(child?.localName === 'table'));
--seed--
--seed-contents--
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Balance Sheet</title>
<link rel="stylesheet" type="text/css" href="./styles.css">
</head>
<body>
<main>
<section>
<h1>
<span class="flex">
<span>AcmeWidgetCorp</span>
<span>Balance Sheet</span>
</span>
</h1>
<div id="years" aria-hidden="true">
<span class="year">2019</span>
<span class="year">2020</span>
<span class="year">2021</span>
</div>
--fcc-editable-region--
--fcc-editable-region--
</section>
</main>
</body>
</html>