@Lescano713
Posted
I like how you used the linear-gradient property; it looks better than the original design. Overall, your code looks great, but here are a few suggestions for improvement:
- Try using more semantic tags like main and section.Consider replacing the iteration with a forEach loop.
- To align the button, you could use align-items on the div.container, or alternatively, use align-self on the button. This will keep the alignment of the other elements to the left.
- I noticed that when you select an option, the background color doesn’t remain orange.
- To fix this, you can use the :checked selector or handle it in JavaScript by adding a class to the selected button and another class to the unselected ones.
- To minimize the code inside the submit() function, you can wrap the message in a separate function and call it from submit().
- Another way to use querySelector is with querySelectorAll('button[type="submit"]'), which will select the button based on its type.
Marked as helpful