mirror of
https://github.com/freeCodeCamp/freeCodeCamp.git
synced 2026-05-28 18:26:54 +00:00
fix(curriculum): add hint for feature selection labels (#64156)
This commit is contained in:
+10
-1
@@ -45,13 +45,22 @@ You should have a `div` element with the class `feature-card-container`.
|
||||
assert.exists(document.querySelector('div.feature-card-container'));
|
||||
```
|
||||
|
||||
You should have at least two `label` elements with the class `feature-card` inside `.feature-card-container`.
|
||||
You should have at least two `label` elements inside `.feature-card-container`.
|
||||
|
||||
```js
|
||||
const labels = document.querySelectorAll('.feature-card-container label');
|
||||
assert.isAtLeast(labels.length, 2);
|
||||
```
|
||||
|
||||
Each `label` element inside `.feature-card-container` should have the class `feature-card`.
|
||||
|
||||
```js
|
||||
const labels = document.querySelectorAll('.feature-card-container label');
|
||||
assert.isNotEmpty(labels);
|
||||
|
||||
labels.forEach(label => assert.isTrue(label.classList.contains('feature-card')));
|
||||
```
|
||||
|
||||
Inside each `label` element you should have label text.
|
||||
|
||||
```js
|
||||
|
||||
Reference in New Issue
Block a user