MovieNight icon indicating copy to clipboard operation
MovieNight copied to clipboard

Sort emote autocomplete properly

Open zorchenhimer opened this issue 5 years ago • 0 comments

Currently, the emote autocomplete popup is sorted alphabetically form the top down, and is case sensitive. When the default selection was moved to the bottom in 40f4cc7 the sort order was not reversed and made the incorrect sort order much more noticeable.

Given the autocomplete input of :pog the list from top to bottom is

POGGERS
Pog
PogChamp
peepogun

with the last item being selected. The correct order should be reversed, sorted ignoring case, and the shortest at the bottom:

POGGERS
PogChamp
Pog
peepogun

Additionally, if an option matches the input exactly (eg, :pog matches Pog in the list) that should be selected even though peepogun contains the input and would normally be the default selection.

zorchenhimer avatar Apr 29 '19 20:04 zorchenhimer