1. 一般设置input
// 设置el-input_inner
/deep/ .el-input__inner {
height: 47px;
background-color: rgba(255, 255, 255, 0.247);
}
2. 如果不生效,看下是否该input被el-form-item包裹
如果是,则设置
/deep/ .el-form-item {
background-color: unset !important;
}
防止被el-form-item的背景色污染,因此将其去除
3. 更改input中的文字颜色
/deep/ .el-input input {
color: #fff !important;
}
有时候背景色过于暗,文字也是暗色,则可能看不太清,这里的文字颜色根据自己的实际情况进行修改
网友评论