How to implement a group of parameters in a semantic dropdown menu

I want to show categories and subcategories in a dropdown similar to a selection with a group of options in html.

How to do it in semantic-ui. I didn't find any help.


source to share

1 answer

I don't know if you need this problem as the question is a bit old, but I found this on Fiddle .

Basically you would use div

instead of select

and option



<div class="ui selection dropdown multiple search optgroup">
    <div class="text">Select</div>
    <i class="dropdown icon"></i>
    <div class="menu">
        <div class="ui horizontal divider">Optgroup 1</div>
        <div class="item">Option 1</div>
        <div class="item">Option 2</div>
        <div class="ui horizontal divider">Optgroup 2</div>
        <div class="item">Option 3</div>
        <div class="item">Option 4</div>



.dropdown.optgroup .divider {
    border-top: none !important;







All Articles