Philipp M
Philipp M

Reputation: 3488

Datatables Editor - Custom color for select placeholder

I would like to style the placeholder of a select (default value empty '') (https://editor.datatables.net/examples/simple/fieldTypes.html) a bit different than when a value is selected.

I've tried so far:

CSS:

.DTE_Field_InputControl select::placeholder {
  color: #999;
}
/*
.DTE_Field select::placeholder {
  color: #999;
}
*/
/*
.DTE_Field select[placeholder="Select"] {
  color: #999
}
*/
/*
.DTE_Field select option:disabled {
  color: #999
}
*/

HTML:

<select id="DTE_Field_groups-status" class="form-control">
    <option value="" hidden="" disabled="">Select</option>
    <option value="0">Inactive</option>
    <option value="1">Active</option>
</select>

Any idea how to accomplish this?

Upvotes: 0

Views: 39

Answers (0)

Related Questions