Is there any way to remove these in input (type="number")?
<input type="number" />
It's for the users to input their phone numbers.
this
Using inputmode=”numeric” attribute you can find an input box without an arrow. The older browsers might not support this feature for example Internet Explorer and Safari but most of the modern browsers like Chrome, Firefox, Edge, Opera support this attribute.
If you want to hide arrow buttons of the HTML <input> element with the “number” type, you need to use CSS. As there is no longer a problem in Chrome, you can only set the display property to “none” to hide the arrow buttons.
If you don't want the spin arrows, then don't use type="number" . You can use type="text" and the pattern attribute to set a regex to make sure it's a number.
This can be done through CSS if you wish,
input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button {
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
margin: 0;
}
<input type="number" />
Hope this helps!
Just these was enought for my code.
.input[type=number] {
&::-webkit-inner-spin-button{ display: none; }
-moz-appearance:textfield;
}
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