Is there a official way on how to reset a search input to make it look the same as a text field in Safari?
screenshot
Safari is adding some annoying padding to the left side which I can't remove.
input {
-webkit-appearance: none;
padding: 0;
}
<input type="search" value="abc"><br>
<input type="text" value="abc">
Found the solution myself.
input {
padding: 0;
}
input[type="search"] {
-webkit-appearance: textfield;
}
input[type="search"]::-webkit-search-decoration {
-webkit-appearance: none;
}
<input type="search" value="abc"><br>
<input type="text" value="abc">
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