Remove background arrow from date input in Google Chrome v20

后端 未结 6 1543
我寻月下人不归
我寻月下人不归 2020-11-28 08:06

Since Google Chrome v20 a new calendar has been added to date inputs. The issue with this is that I\'m using javascript to create my own calendar and I have an icon already

6条回答
  •  星月不相逢
    2020-11-28 08:38

     input[type="date"] {
            &::-webkit-inner-spin-button,
            &::-webkit-calendar-picker-indicator {
                -webkit-appearance: none;
                position: absolute;
                right: 0;
                opacity: 0;
            }
            width: 100%;
        }
    

    Here, I have a fontawesome pseudo-icon(caret) at the far right. Therefore, i place the calendar icon in that position, whenever a user clicked on the caret it performs the function of the invisible calendar icon

提交回复
热议问题