我想在浏览器自动完成我的表单时将背景颜色设置为对我的输入透明,目前看起来像添加的图像,有人知道如何实现吗?
我已经试过了,但它设置为白色,边框的样式默认为黄色,我希望文本的颜色也为白色。
input:-webkit-autofill {
-webkit-box-shadow: 0 0 0px 1000px white inset;
}
它是这样的:
提前致谢:)
最佳答案
最后我用这段代码得到了结果:
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
input:-webkit-autofill:active {
transition: background-color 5000s ease-in-out 0s;
-webkit-text-fill-color: #fff !important;
}
关于html - 在自动完成表单上将输入背景更改为透明,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29580704/