Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

227
Views
How to style the dropdown UI in the basic html select element in React?
      <select className="option-select">
        <option value="volvo">Volvo</option>
        <option value="saab">Saab</option>
        <option value="opel">Opel</option>
        <option value="audi">Audi</option>
      </select>

Here is how the basic select is defined. How to target the dropdown list UI? For example, changing the default background of the dropdown.

EDIT:

I find that it does work in Chrome if I target the <option> element. But on firefox, it does not work.

about 4 years ago · Juan Pablo Isaza
3 answers
Answer question

0

select {
  background: yellow    
}
option {
  color: red 
}
<select className="option-select">
  <option value="volvo">Volvo</option>
  <option value="saab">Saab</option>
  <option value="opel">Opel</option>
  <option value="audi">Audi</option>
</select>

about 4 years ago · Juan Pablo Isaza Report

0

Just a few CSS properties can change dropdown appearance and it's better to use a react components library such as material-ui.

about 4 years ago · Juan Pablo Isaza Report

0

It's possible to style the select menu 'button', but not the dropdown itself. To accomplish that you need to mimic the functionality with javascript. https://www.w3schools.com/howto/howto_custom_select.asp

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!