Input box modifications in CSS

I have not seen any example of how to modify the size of input boxes for several different inputs in previous form building exercises. I accomplished this by assigning a class for each input and then using input.class in css. Is there an accepted practice that is more efficient?

if you want to change them in the same way, you can give them all the same class

also, the Registration Form project has css applied to the input elements, and shows how to select by type

1 Like

What are the reasons to assign an element by type rather than class?

it’s a different way to style things. Also if you style via type, then the elements of that type are styled always. The class need to applied individually

1 Like