I have a few input[type=text]
fields, which I would like to customize in a different way.
I have got to know, that we can apply our styling even for the name
property.
Can I apply a CSS style to an element name?
Unfortunately, it doesn't work in my case.
My code looks like this:
fig input[type=text]
{
width: 250px;
min-width: 100px;
padding: 12px 20px;
box-sizing: border-box;
outline: none;
border: 1px solid #f7fbff;
background-color: #f7fbff;
display: inline-block;
}
<figure class="fig">
<input type="text" name="riser_cupboard_key_type"
pattern="[A-Za-z].{4,}"
title="The text should include at least 4
letters" placeholder="Enter your answer" required>
</figure>
All thhe options beloe weren't working
.fig input[type=text] > input[name="riser_cupboard_key_type"] {
width: 600px;
}
.fig input[type=text] input[name="riser_cupboard_key_type"] {
width: 600px;
}
.fig input[name="riser_cupboard_key_type"] {
width: 600px;
}
How can I make only this specified input different than others?