I have a select and I would like to change the design of the options container, especially by changing it with rounded corners and removing the borders
<select>
<option val="0" selected></option>
<option val="1"></option>
<option val="2"></option>
<option val="3"></option>
<option val="4"></option>
<option val="5"></option>
</select>
I know the solution to change the style of the select and the options but I don’t know how to change in css the options container
2
Answers
You can change the
select
tag with CSS just like any other element:However, styling
select
oroption
tags is somewhat very limited. For example, changing the appearance of the dropdown arrow icon will be difficult. Furthermore, changing the style of theoption
container is not possible (or at least very limited).State of the art would be to discard the HTML built-in component and write your own dropdown component (example).
there are multiple ways to style your select option.Here is one way