fix(curriculum): update description and hints of lab-football-team-cards (#61437)

This commit is contained in:
Vivaan Teotia
2025-07-23 09:17:12 +05:30
committed by GitHub
parent df7e70b36b
commit 35ce565807
@@ -37,7 +37,7 @@ Fulfill the user stories below and get all the tests to pass to complete the lab
</div>
```
1. When the dropdown menu is used to select one of the positions, only players of that position should be shown. If the `"All Players"` option is selected, then all of the players should display on the page.
1. When the dropdown menu is used to select one of the positions, only the `.player-card` elements for players of that position should be present. If the `"All Players"` option is selected, then all of the players should display on the page.
# --hints--
@@ -117,7 +117,7 @@ assert.equal(yearElement?.innerText.trim(), footballTeam.year);
assert.equal(headCoachElement?.innerText.trim(), footballTeam.headCoach);
```
When the option `All Players` is selected, all players should be shown within `#player-cards`.
When the option `All Players` is selected, all players should be present within `#player-cards`.
```js
const select = document.querySelector('#players')
@@ -133,7 +133,7 @@ const arrayFromPage = Array.from(playerCards).map(el => ({
assert.sameDeepMembers(arrayFromPage, footballTeam.players);
```
When the option `Position Forward` is selected, only forward players should be shown within `#player-cards`.
When the option `Position Forward` is selected, only forward players should be present within `#player-cards`.
```js
const forwards = footballTeam.players.filter(({position}) => position === 'forward')
@@ -150,7 +150,7 @@ const arrayFromPage = Array.from(playerCards).map(el => ({
assert.sameDeepMembers(arrayFromPage, forwards);
```
When the option `Position Midfielder` is selected, only midfielder players should be shown within `#player-cards`.
When the option `Position Midfielder` is selected, only midfielder players should be present within `#player-cards`.
```js
const midfielders = footballTeam.players.filter(({position}) => position === 'midfielder')
@@ -167,7 +167,7 @@ const arrayFromPage = Array.from(playerCards).map(el => ({
assert.sameDeepMembers(arrayFromPage, midfielders);
```
When the option `Position Defender` is selected, only defender players should be shown within `#player-cards`.
When the option `Position Defender` is selected, only defender players should be present within `#player-cards`.
```js
const defenders = footballTeam.players.filter(({position}) => position === 'defender')
@@ -184,7 +184,7 @@ const arrayFromPage = Array.from(playerCards).map(el => ({
assert.sameDeepMembers(arrayFromPage, defenders);
```
When the option `Position Goalkeeper` is selected, only goalkeeper players should be shown.
When the option `Position Goalkeeper` is selected, only goalkeeper players should be present.
```js
const goalkeepers = footballTeam.players.filter(({position}) => position === 'goalkeeper')