
Design comparison
Solution retrospective
I am proud that I at least tried to write my README.md file properly this time. I often consider it something outside the project, but after reading the article here on Frontend Mentor, I spent some time writing it, and I am content with my decision.
What challenges did you encounter, and how did you overcome them?There were some struggles in sizing and aligning items, which I have written in detail in my README.md file. Overall, it was alright.
What specific areas of your project would you like help with?I am still learning JavaScript and hence still very much a beginner, so I would appreciate any feedback. Thank you.
Community feedback
- @MarziaJaliliPosted about 2 months ago
Nice work!
Some areas you can amend:
- First, for a smoother color change of the buttons, you can use the
transition
property.
Take the code below as an example:
button { transition: background-color 0.5s; /* or .5s for short */ }
This ensures that the color will change after 500 milliseconds. Which makes it look even better.
- Second, when the user tries again to provide valid data, the error states are still there.
It would be better if you got rid of them using the onChange on the inputs for a more user friendly layout.
This is how you can set the event listener for it:
input.addEventListener('change', function() { // some conditions to remove the error states according to your code });
Other than this you're doing great!
If you find any difficulties, let me know.
😎😎😎
Marked as helpful0@TarestaPosted about 2 months ago@MarziaJalili I really appreciate your helpful advice! I went ahead and made the changes you suggested, but I’m feeling a bit uncertain about my input field. If you have a moment, would you mind taking another look to see if I captured what you were aiming for?
1@MarziaJaliliPosted about 2 months agoAhhh, stupid me!
I am used to
React JS
, so I forgot that the event listen here can't bechange
.The only thing you have to do is to change the
change
toinput
.This will remove the error states every time the user types into the email field.
The very last line of your code has to be changed to:
// current code => emailField.addEventListener('change', handleInputChange); // change it to => emailField.addEventListener('input', handleInputChange);
This will definitely solve the issue.
0 - First, for a smoother color change of the buttons, you can use the
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