我在我的
Vue
项目中实现了暗模式,这是我用 Bootstrap 5.2
创建的。
但是我不知道如何改变下面两个的颜色(应该是白色)
icons
:
这是来自
form-select
这是来自
input type="time"
我怎样才能做到这一点?
代码
<template>
<input class="form-control" type="time" />
<select class="form-select"></select>
</template>
Bootstrap 5.3 实现暗模式。如果升级到 5.3,只需使用
<html data-bs-theme="dark">..
,输入插入符就会变成浅色
如果你想使用 5.2,你需要覆盖
form-select
类背景图像 SVGs stroke
颜色以更改插入符号颜色...
.form-select {
background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23ffffff' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m2 5 6 6 6-6'/%3e%3c/svg%3e")
}