3

I want to remove all the webkit stuff (chrome) associated with the type time. I don't want to change the type.

<input type="time">

http://jsfiddle.net/dDqX4/

I have found similar questions removing the webkit stuff.

Can I hide the HTML5 number input’s spin box?

Thanks!

Update:
Chrome enter image description here

IE
enter image description here

As you can see chrome breaks its.

Community
  • 1
  • 1
Kevin Kohler
  • 364
  • 4
  • 21

4 Answers4

7

Try this:

::-webkit-datetime-edit-ampm-field,
::-webkit-datetime-edit-day-field,
::-webkit-datetime-edit-hour-field,
::-webkit-datetime-edit-millisecond-field,
::-webkit-datetime-edit-minute-field,
::-webkit-datetime-edit-month-field,
::-webkit-datetime-edit-second-field,
::-webkit-datetime-edit-week-field,
::-webkit-datetime-edit-year-field,
::-webkit-datetime-edit-text {
  color: transparent;
}
Bartezz
  • 474
  • 4
  • 13
3
input[type=time]::-webkit-clear-button,
input[type=time]::-webkit-outer-spin-button,
input[type=time]::-webkit-inner-spin-button {
    display:none;
}

http://jsfiddle.net/dDqX4/3/

Michael Tempest
  • 814
  • 7
  • 12
0

try this

input[type=time]::-webkit-outer-spin-button,
input[type=time]::-webkit-inner-spin-button {
    -webkit-appearance: none;
}

input[type=time] {
    -moz-appearance:textfield;
}
Rolwin Crasta
  • 4,219
  • 3
  • 35
  • 45
0

Incase you want your input to remain visible when valid but not in focus

input:not( :focus ) {
  color: transparent;
}
input:valid {
  color: inherit;
}
MColl
  • 1