How to make Datalist arrow to be always visible

amol01 picture amol01 · Feb 4, 2016 · Viewed 15.3k times · Source

I am trying to have datalist list element always visible. As standard after focused lost, the arrow disappears.

I would like to have it always like this: Here is the plunker: https://plnkr.co/edit/?p=preview

enter image description here

ENVIRONMENT: Angular directive

Any ideas how to achieve it?

Best,

Answer

amol01 picture amol01 · Feb 4, 2016

I have got the arrow always visible using css:

input::-webkit-calendar-picker-indicator {
              opacity: 100;
           }
    <input list="browsers" name="myBrowser" />
    <datalist id="browsers">
      <option value="Chrome">
      <option value="Firefox">
      <option value="Internet Explorer">
      <option value="Opera">
      <option value="Safari">
    </datalist>