想要修改element-ui 输入框的边框背景颜色一直不生效?

想要修改element-ui 输入框的边框背景颜色一直不生效?


<el-input type="text" v-model="ruleForm.username" placeholder="用户名"></el-input>

可以确定的告诉你,elementui 样式是可以更改的;
但是需要注意一点,style上的scope 必须去掉;
还不行的需要加!important

<style lang="scss">
    .login-input{
        .el-input__inner{
            height: 50px!important;
            border:none;
        }
        .el-input__inner:focus{
            border:none;
        }
    }
</style>

在style scope修改样式,参考:

<style scoped>
.el-input__inner[DangerColor="danger"] {
  background-color: #F56C6C;    //红色
}
</style>