码迷,mamicode.com
首页 > Web开发 > 详细

input:-webkit-autofill使输入框变成黄色

时间:2018-05-25 22:44:51      阅读:217      评论:0      收藏:0      [点我收藏+]

标签:back   ble   tag   ext   over   efault   AC   let   解决办法   

解决办法:

把以下代码复制粘贴在css文件的前部,其中的具体设置项可改。

/* Change autocomplete styles in WebKit */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus
input:-webkit-autofill,
textarea:-webkit-autofill,
textarea:-webkit-autofill:hover
textarea:-webkit-autofill:focus,
select:-webkit-autofill,
select:-webkit-autofill:hover,
select:-webkit-autofill:focus {
border: 1px solid green;
-webkit-text-fill-color: green;
-webkit-box-shadow: 0 0 0px 1000px #000 inset;
transition: background-color 5000s ease-in-out 0s;
}


input:-webkit-autofill使输入框变成黄色

标签:back   ble   tag   ext   over   efault   AC   let   解决办法   

原文地址:https://www.cnblogs.com/reiko/p/9090821.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!