Tags not appearing in tag dropdown

There are tags displaying on the tags page which aren’t appearing in the tags dropdown or search.

One example (of many) here on Meta is #bug::tag

6 إعجابات

This is because of site setting max tags in filter list which defaults to 30. The description of the site setting is:

Maximum number of tags to show in the filter dropdown. The most used tags will be shown.

I just increased that setting to 100 here on Meta and #bug::tag is appearing in dropdown now.

5 إعجابات

If that is the case, this is not a bug @hawk.

إعجاب واحد (1)

what we could do though is making this component make ajax request if filtering doesnt return anything. Or apply filtering on the full list even if we only show a partial list in the first place.

5 إعجابات

I’d favor this solution: users usually don’t know about the max tags limit, and would expect they search the complete tag set when entering anything into the Search… field.

Is this still the case? We should at least hint at the existence of more tags at the bottom with more … or similar.

إعجابَين (2)

@codinghorror long time ago I implemented this:

It is however true, that you have to filter to find it, and nothing hints you that there are more than the displayed list. Do you still want to implement more… ?

إعجابَين (2)

Yes – I think there should be some kind of visual hint that “ah, there is more here, not just the visible items”… whatever is easy.

3 إعجابات

On second thought, I don’t think I can do this, at least not with a perf hit.

If we limit the tags displayed it’s basically to not have to fetch (or even count) all tags. So the only thing I know is if we have less displayed tags than the max setting, but I have no way to know if we have more tags than the max displayed, because in this case: displayed === max.

إعجاب واحد (1)

A trick I commonly use, have the backend always return max+1 rows, only display max. If +1 exists you have more.

6 إعجابات

Cool trick thanks :+1:

That should do it:

https://github.com/discourse/discourse/pull/12649

إعجابَين (2)

That is… One Weird Old Trick™

إعجاب واحد (1)