Design comparison
SolutionDesign
Solution retrospective
Any feedbak is wellcome 😊
Community feedback
- @vanzasetiaPosted over 2 years ago
Hi! 👋
Nice work on this challenge! Your solution is responsive and looks great! 👍
I have a few suggestions for this solution.
- There should not be text in
span
anddiv
alone whenever possible. Instead, wrap the text with a meaningful element like a paragraph element. - I recommend making the
icon-error.svg
as abackground-image
of theinput
element. - In order for the alert messages to be accessible (or read) by screenreaders, it requires some work to be done.
- Have a
p
element that is already exists on the DOM for each alert message. Leave them empty.- Add
aria-live
attribute - Add an
id
- Add
- Add
aria-describedby
to eachinput
element. The value of it should point to theid
of each error message. - On JavaScript
- Grab the
form
element. Make it listens to thesubmit
event. (not the click event of the submit button) - If the inputs are not valid then prevent the form from submitting.
- Add the text content through JavaScript for each error message.
- Grab the
- Have a
input
withtype="submit"
was used before thebutton
element exist. It's best to avoid using legacy elements. So, I recommend usingbutton
element instead.- Code your font size in rem, not pixels. This means the text size will be responsive if people want to adjust the size.
Hope this helps. Happy coding! 😁
Marked as helpful2 - There should not be text in
- @CodinGitHubPosted over 2 years ago
Hi Vanza thank you very much for your feedback. I really appreciate it. This will help me improve my developer's skill a lot.
0
Please log in to post a comment
Log in with GitHubJoin our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord