Topic: Style select options
dhermann premium asked 1 year ago
I would like to style individual options inside of an mdb select. It looks like there are only a few attributes that are passed into the
div.select-option elements and even the ids appear to be random so I cannot target with external CSS. Is there a way to do this? If not, can this feature be added?
Keep in mind that I want to style individual options, not all options, so targeting
.select-option in my CSS is not sufficient.
No ids, classes, or styles can be passed from the
option elements that will appear in their respective
Resources (screenshots, code snippets etc.) https://mdbootstrap.com/snippets/standard/dhermann/4066455
currently the only way to style options is via CSS selectors. Use
nth-child to style them individualy.
Thank you. I think adding a way to style individual options through attributes or just class options would be great. If possible, please add it to the upgrade list.
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
- User: Premium
- Premium support: Yes
- Technology: MDB Standard
- MDB Version: MDB5 4.1.0
- Device: Desktop
- Browser: Safari
- OS: macOS Monterrey 12.0.1
- Provided sample code: Yes
- Provided link: Yes