diff --git a/curriculum/challenges/english/14-responsive-web-design-22/learn-html-forms-by-building-a-registration-form/60fab8367d35de04e5cb7929.md b/curriculum/challenges/english/14-responsive-web-design-22/learn-html-forms-by-building-a-registration-form/60fab8367d35de04e5cb7929.md index 493d7d99bc3..8d0c3bf7b9f 100644 --- a/curriculum/challenges/english/14-responsive-web-design-22/learn-html-forms-by-building-a-registration-form/60fab8367d35de04e5cb7929.md +++ b/curriculum/challenges/english/14-responsive-web-design-22/learn-html-forms-by-building-a-registration-form/60fab8367d35de04e5cb7929.md @@ -42,7 +42,15 @@ assert.match(document.querySelector('fieldset:nth-child(3) + label > input + a') You should only wrap the `a` element around the text `terms and conditions`. ```js -assert.equal(document.querySelector('fieldset:nth-child(3) + label > input + a')?.textContent, 'terms and conditions'); +assert.equal(document.querySelector('fieldset:nth-child(3) + label > input + a')?.textContent.trim(), 'terms and conditions'); +``` + +The text inside your anchor element has extra leading or trailing whitespace. The only spaces in the anchor text should be between the words `terms`, `and`, and `conditions`. + +```js +const nestedAnchor = document.querySelector('fieldset:nth-child(3) + label > input + a')?.textContent; +const innerContent = nestedAnchor.innerHTML; +assert.isNotTrue(/^\s+|\s+$/.test(innerContent)); ``` # --seed--