Skip to content

Search: match each typed word - #71

Merged
ru44 merged 1 commit into
mainfrom
fix/search-words
Nov 26, 2026
Merged

ru44 merged 1 commit into
mainfrom
fix/search-words

Conversation

@ru44

@ru44 ru44 commented Nov 26, 2026

Copy link
Copy Markdown
Owner

Searching for two or more words always found nothing: "AES RSA ML-kem", "AES RSA" and even "rsa encryption" showed "Nothing matches", because the whole query was looked up as one phrase.

  • Each word is now looked up on its own. "AES RSA ML-kem" lists the RSA, AES and Lattices (ML-KEM) lessons at the top.
  • Lessons matching more of the words come first.
  • A word found at the start of a word ranks above one inside another word, so "rsa" no longer ranks "universal" or "conversation" lessons above real matches.
  • Single-word searches (prime, orbit, battery, تشفير, بطارية) return the same lessons as before.

Tested in a browser on a local build in English and Arabic. Type-check, lint, tests and build pass.

… finds the lessons

The whole query used to be looked up as one phrase, so any search with two
words found nothing. Lessons matching more of the words now come first, and a
word found at the start of a word ranks above one buried inside another word
("rsa" in "universal").
@ru44
ru44 merged commit eccfdc3 into main Nov 26, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant