How to change text(foreground) color when control is disabled

I need to change the text color of a Vue ejs-textbox when the control is disabled.
I set the property :enabled='false' and I have the following situation:

<template>
     <div>
          <ejs-textbox cssClass='e-custom' :enabled='false'></ejs-textbox>
     </div>
</template>

<script>
...
</script>

<style>

.e-input-group.e-disabled.e-custom input.e-input,
.e-input-group.e-control-wrapper.e-disabled.e-custom input.e-input {
background-color: yellow; --> it works
font-style: italic; --> it works
font-weight: bold; --> it works
color: hotpink !important; --> DOESN'T WORK
    }


</style>
It seems that all the css properties are applied, but color is not.
Why?
Any help is appreciated.
Thank You in advance.
Alberto.


3 Replies 1 reply marked as answer

VS Vignesh Srinivasan Syncfusion Team February 22, 2021 08:57 AM UTC

Hi Alberto, 
 
We have checked you reported query the color of the text inside the textbox component was not updated. It is because the text color for the disabled textbox is updated in the -webkit-text-fill-color attribute. Please find the code below. 
 
Code snippet: 
 
 
.e-input-group.e-disabled.e-custom input.e-input, 
.e-input-group.e-control-wrapper.e-disabled.e-custom input.e-input { 
  background-coloryellow; 
  font-styleitalic; 
  font-weightbold; 
  -webkit-text-fill-colorhotpink; 
} 
 
 
Screenshot: 
 
 
 
 
 
 
Kindly check with the above sample. Please let us know if you need any further assistance. 
 
Regards, 
 
Vignesh Srinivasan. 


Marked as answer

AM Alberto Monteverdi February 24, 2021 01:54 AM UTC

Thank You Vignesh, it works perfectly.
Best Regards.
Alberto.


VS Vignesh Srinivasan Syncfusion Team February 24, 2021 03:37 AM UTC

Hi Alberto, 
You are welcome. 
We are glad to know that the provided solutions worked for you. Please contact us if you require any further assistance. 
  
Regards, 
Vignesh Srinivasan. 


Loader.
Up arrow icon