样式自动填充或自动完成默认浏览器下拉列表 [英] Style Autofill or Autocomplete Default Browser Dropdown
问题描述
是否有某种类型的 css 前缀、插件、javascript 或 jquery 允许您设置默认浏览器自动完成/自动填充的样式下拉.不是用于搜索字段...而是用于
Is there some type of css prefix, plugin, javascript, or jquery that allows you to style the default browser autocomplete/autofill dropdown. Not for a search field... but for <input type="email">
我已经使用了 input:-webkit-autofill
、input:-webkit-autofill:hover
和 input:-webkit-autofill:first-line
更改黄色背景的外观、字体系列、颜色等(在 Chrome 中)
I already use input:-webkit-autofill
, input:-webkit-autofill:hover
, and input:-webkit-autofill:first-line
to change the appearence of the yellow background, the font-family, color, etc. (in Chrome)
现在我试图覆盖由您的浏览器生成的下拉菜单的默认外观.
Now I'm trying to override the default look of the dropdown - which is generated by your browser.
我正在尝试为所有用户名/电子邮件自动填充下拉列表自定义外观、文本颜色、:hover 颜色、字体等.
I'm trying to customize the appearence, text color, :hover color, font, etc. for all Username/Email autofill dropdowns.
我不想指定数据列表,或有任何预定义的变量...
I do not want to specify a data-list, or have any prefdefined variables...
我不想关闭autocomplete="off"
我使用 dropkick.js 来自定义我所有的 下拉菜单 - 并将它们更改为
元素.
I use dropkick.js to customize all of my <select>
dropdowns - and change them into <ul>
elements.
我想知道是否存在这样的东西来以类似的方式自定义所有其他自动填充或自动完成下拉菜单.
I am wondering if something like this exists for customizing all the other autofill or autocomplete dropdowns in a similar way.
这可能吗?
推荐答案
我遇到了同样的问题,不幸的是 一切 我见过说这不能以任何本地"方式完成.大多数人给出的主要建议是将自动完成设置为关闭,然后构建 &样式 您的 拥有,在大多数情况下,这可能比它更有价值.
I had this identical question, unfortunately everything I've seen says that this can't be done in any sort of "native" way. The primary suggestion that most give is setting auto-complete to off and then building & styling your own, which in most instances is probably more work then it's worth.
这篇关于样式自动填充或自动完成默认浏览器下拉列表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!