I am currently utilizing a select dropdown feature from the MaterializeCSS library. My goal is to implement a specific class that will change the text color of certain options within the dropdown. Is there a method available for accomplishing this?
Upon researching, I discovered that I can adjust the color globally using the following code:
.dropdown-content li>a, .dropdown-content li>span {
color: red;
}
However, this would result in all dropdown option colors being set to red. Is there a way to define a class that can modify the text color for only select options?
I was hoping to achieve something similar to the example below:
<option value='A'>A</option>
<option value='B' class='red'>B</option>
<option value='C'>C</option>