Skip to content

[Help] How to limit dropdown search results only to enabled items? #1682

Discussion options

You must be logged in to vote

As far as I know, there's no option and callback to achieve this. But, when you start typing to search, the special class name filtered will be added to the text container. You can use this class to hide the disabled item from your menu.

.ui.search.dropdown .text.filtered + .menu .disabled.item {
    display: none;
}

Here's fiddle (https://jsfiddle.net/ko2in/ur2awmdt/8/). Try to type 'A' and you'll only see one active item.

Replies: 2 comments

Comment options

You must be logged in to vote
0 replies
Answer selected by lubber-de
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #1682 on October 06, 2020 21:42.