Toggle dropdown
A trigger that opens a vertical toggle menu that acts as a custom select menu.
Default toggle dropdown orc-c-toggle-dropdown
A trigger that opens a vertical toggle menu that acts as a custom select menu.
-
<div class="orc-c-toggle-dropdown orc-js-toggle-dropdown"> <div class="orc-c-toggle-dropdown__selected orc-js-toggle-dropdown-selected" tabindex="0"> <div class="orc-c-toggle-dropdown__content orc-js-toggle-dropdown-content">All Offers </div> <svg class="orc-c-icon orc-c-toggle-dropdown__icon"> <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="../../orchid-icons.svg#chevron-down"></use> </svg> </div> <!--end orc-c-toggle-dropdown__selected--> <div class="orc-c-toggle-dropdown__panel orc-js-toggle-dropdown-panel"> <div class="orc-c-field orc-c-field--toggle orc-c-field--toggle-vertical orc-js-field"> <div class="orc-c-field__body"> <div class="orc-c-toggle orc-js-toggle"> <input class="orc-c-toggle__input orc-js-toggle-input orc-u-is-vishidden" type="radio" id="offers-1" name="togglename" title="The Cosmopolitan Las Vegas" value="" /> <label class="orc-c-toggle__label orc-js-toggle-label" for="offers-1"> All Offers </label> <input class="orc-c-toggle__input orc-js-toggle-input orc-u-is-vishidden" type="radio" id="offers-2" name="togglename" title="The Cosmopolitan Las Vegas" value="" /> <label class="orc-c-toggle__label orc-js-toggle-label" for="offers-2"> <svg class="orc-c-icon orc-c-toggle__icon"> <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="../../orchid-icons.svg#rooms-suites"></use> </svg> Rooms & Suites </label> <input class="orc-c-toggle__input orc-js-toggle-input orc-u-is-vishidden" type="radio" id="offers-3" name="togglename" title="The Cosmopolitan Las Vegas" value="" /> <label class="orc-c-toggle__label orc-js-toggle-label" for="offers-3"> <svg class="orc-c-icon orc-c-toggle__icon"> <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="../../orchid-icons.svg#casino"></use> </svg> At The Casino </label> <input class="orc-c-toggle__input orc-js-toggle-input orc-u-is-vishidden" type="radio" id="offers-4" name="togglename" title="The Cosmopolitan Las Vegas" value="" /> <label class="orc-c-toggle__label orc-js-toggle-label" for="offers-4"> <svg class="orc-c-icon orc-c-toggle__icon"> <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="../../orchid-icons.svg#entertainment"></use> </svg> Entertainment </label> <input class="orc-c-toggle__input orc-js-toggle-input orc-u-is-vishidden" type="radio" id="toggle-5" name="togglename" title="The Cosmopolitan Las Vegas" value="" /> <label class="orc-c-toggle__label orc-js-toggle-label" for="toggle-5"> <svg class="orc-c-icon orc-c-toggle__icon"> <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="../../orchid-icons.svg#food-drink"></use> </svg> Food & Drink </label> <input class="orc-c-toggle__input orc-js-toggle-input orc-u-is-vishidden" type="radio" id="toggle-6" name="togglename" title="The Cosmopolitan Las Vegas" value="" /> <label class="orc-c-toggle__label orc-js-toggle-label" for="toggle-6"> <svg class="orc-c-icon orc-c-toggle__icon"> <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="../../orchid-icons.svg#resort-credit"></use> </svg> Resort Credit </label> <input class="orc-c-toggle__input orc-js-toggle-input orc-u-is-vishidden" type="radio" id="toggle-7" name="togglename" title="The Cosmopolitan Las Vegas" value="" /> <label class="orc-c-toggle__label orc-js-toggle-label" for="toggle-7"> <svg class="orc-c-icon orc-c-toggle__icon"> <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="../../orchid-icons.svg#identity-light"></use> </svg> Identity Play </label> <input class="orc-c-toggle__input orc-js-toggle-input orc-u-is-vishidden" type="radio" id="toggle-8" name="togglename" title="The Cosmopolitan Las Vegas" value="" /> <label class="orc-c-toggle__label orc-js-toggle-label" for="toggle-8"> <svg class="orc-c-icon orc-c-toggle__icon"> <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="../../orchid-icons.svg#rooms-suites"></use> </svg> Tier Benefits </label> <input class="orc-c-toggle__input orc-js-toggle-input orc-u-is-vishidden" type="radio" id="toggle-9" name="togglename" title="The Cosmopolitan Las Vegas" value="" /> <label class="orc-c-toggle__label orc-js-toggle-label" for="toggle-9"> <svg class="orc-c-icon orc-c-toggle__icon"> <use xmlns:xlink="http://www.w3.org/1999/xlink" xlink:href="../../orchid-icons.svg#rooms-suites"></use> </svg> Just For You </label> </div> <!-- end orc-c-toggle --> </div> <!-- end orc-c-field__body --> </div> <!-- end orc-c-field --> </div> <!--end orc-c-toggle-dropdown__panel--> </div> <!--end orc-c-toggle-dropdown-->
Usage
When to use
Toggle dropdowns are select fields with more style. Use these to support custom menus containing high-priority user options.
When to consider an alternative
When the dropdown options are more administrative in nature, use a select field.
Class Name | Description |
---|---|
Required
|
Apply to the toggle dropdown’s containing HTML element. This contains the toggle dropdown trigger that opens the toggle dropdown panel. |
JS
|
Apply in addition to |
Required
|
Apply to |
JS
|
Apply in addition to |
Required
|
Apply to |
JS
|
Apply in addition |
Required
|
Base icon class for icons within design system. |
Required
|
Apply in addition to |
Required
|
Apply to |
JS
|
Apply in addition to |
Required
|
Apply to the actual toggle component within the |