.e-error.e-control.e-textbox{
color: #f44336
}
|
<ejs-textbox #name name="name" formControlName="display" placeholder='Enter your name'floatLabelType="Always"
[class.e-error]="getClass(display)">
</ejs-textbox> |
public getClass(valid) {
if (valid.valid) {
return false;
} else {
return true;
}
} |
<style>
/* To change the textbox input color to e-error class */
.e-textbox.e-error .e-float-input.e-control-wrapper,
.e-textbox.e-error .e-float-input.e-control-wrapper input,.e-textbox.e-error .e-float-input.e-control-wrapper:hover{
border-color:#a94442 !important;
}
/* To change the textbox float label text color to e-error class */
.e-textbox.e-error .e-float-input.e-control-wrapper label.e-float-text {
color: #a94442 !important;
}
</style> |