when I focus my input with border-radius
, a square border appears out.
Can i make this second border dispear or just set a border radius
to it?
input[type="text"]{
border: 1px solid red;
border-radius:10px;
}
<input type="text">
This is the square border:
Thanks.
The blue rectangle is referenced as outline
you can hide it via the outline: none
rule
input[type="text"] {
border: 1px solid red;
border-radius:10px;
}
input[type="text"]:focus {
outline: none
}
<input type="text">
Of course you can style it.. See this doc to see applicable rules.
I looked up for some extra resources and found out someone made a website about this and it's clearly stated that:
Defining focus to navigation elements is an accessibility requirement, it's clearly stated in the Web Content Accessibility Guidelines:
2.4.7 Focus Visible: Any keyboard operable user interface has a mode of operation where the keyboard focus indicator is visible. (Level AA)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With