codex-lv2-may-2025

Level Navigation: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 Current Level: 29 30 31 32


đź§Ş Level 29: Clear Validation on Valid Input

What You’ll Do

Clear validation messages when input is valid.

Instructions

If the input has text:

đź’ˇ Code Hints

Clearing validation messages? You’ll need to hide error messages when input is valid. Check out the Input/Output section in SNIPPETS.md for clearing text and the Helper Functions section for clearing styling.

âś… Check

  1. Open your webpage in a browser
  2. First, click Send with empty input to trigger a validation message
  3. Then type something in the input field (like “Hello”)
  4. Click Send again
  5. The validation message should disappear and be replaced with “Thinking…”
  6. The AI response should appear normally
  7. Open Chrome DevTools (F12) and check the Console tab for any errors
  8. If the validation message doesn’t clear, check that you’re removing/hiding it when input has text

Next: Level 30 - Keep Validation Consistent



Level Navigation: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 Current Level: 29 30 31 32