]type=text] {Padding} - what does it do?

Lesson: Basic CSS Rules and Selectors
[type-text] {Padding }
What output should it make?
it does not do anything on my website?
Should the output be the:
“Coin” the coin selektor and “Amount” place to enter the amount and button “buy”?

2 Likes

Hey @Kacper, hope you are well.

Check out here: https://www.w3schools.com/css/css_padding.asp

[type-text] will apply the style inside the brackets {} on all text type tags (like <input type="text" name="coin">)

Carlos Z

Also, check what CSS selectors are (see videos), and CSS rules formats.

[type=text] selects a field that has the type attribute key and value text. Example: is selected this way. Then come the rules such as padding, margin etc. You will find countless examples on this e.g. in the box model video. For padding specifically, thecil’s link is correct.

1 Like