Open ebanner opened 3 months ago
Hello!
One or more of the commit messages in this PR do not match the SerenityOS code submission policy, please check the lint_commits
CI job for more details on which commits were flagged and why.
Please do not close this PR and open another, instead modify your commit message(s) with git commit --amend and force push those changes to update this PR.
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions!
Seems alright, we don't squash commits on merge tho, please fixup your second commit into the first one.
This pull request has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions!
done 👍
This PR aims to improve emoji search in the emoji input dialog.
When I type
fire
I'd ideally like for the fire emoji 🔥 to be the first one that comes up.Before
As you can see the fire emoji 🔥 is way down on the list. That is because the current logic doesn't do any re-ranking based on the query - it just filters away emojis which don't match the query (keeps the original ordering).
After
Now the fire emoji 🔥 ranks highly up on the list because we re-rank by the fuzzy scores.
Notes
Unfortunately fire 🔥 is not the first emoji that comes up. This is because of the scores thatfuzzy_match()
is returning:I basically consider this a bug in AK/FuzzyMatch.cpp and I think it's worth opening an issue for it. I expect that fire should get the highest score.EDIT: Looks like this issue has been fixed!