css - 无法更改电子邮件和密码输入元素背景颜色 Shopify

标签 css shopify

<分区>

我遇到了一个非常大的问题,我无法在登录和注册页面的 Shopify 站点中更改电子邮件和密码输入元素的背景颜色。

我刚刚意识到问题只存在于 chrome 中。

最佳答案

尝试将其放入您的 css 中,它应该会覆盖当前样式...

input[type="text"],
input[type="search"],
input[type="password"],
input[type="email"],
input[type="file"],
input[type="number"],
input[type="tel"],
textarea,
select {
  background-color: #ff9900;
}

但是

如果它的自动完成那只发生在 chrome 那么 this应该修复它:

您可以使用任何颜色,例如白色,#DDD,rgba(102, 163, 177, 0.45)。

/* Change the white to any color ;) */
input:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 30px white inset;
}

此外,您可以使用它来更改文本颜色:

/*Change text in autofill textbox*/
input:-webkit-autofill {
    -webkit-text-fill-color: yellow !important;
}

关于css - 无法更改电子邮件和密码输入元素背景颜色 Shopify,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/47207825/

相关文章:

javascript - 阻止 Android WebView 尝试在 loadData() 上加载/捕获 CSS 等资源

html - 在 Shopify 的页面上显示产品变体

html - 在桌面上水平对齐图像,在移动设备上垂直对齐图像

Shopify API 调用以了解用户的位置/国家/地区

html - 垂直和水平对齐容器中的多个 div 子项

css - H2元素问题

javascript - MD 波纹按钮无法打开链接

javascript - .hover 和 div 出现干扰

html - 如何在 Shopify 主题中为我的网站创建一个新的单独页面?

shopify - 将自定义分析与 Shopify 集成