bitwarden / jslib

Common code referenced across Bitwarden JavaScript projects.
https://bitwarden.com
GNU General Public License v3.0
134 stars 138 forks source link

[ps-136] Ignore accented characters in vault search #804

Closed gbubemismith closed 2 years ago

gbubemismith commented 2 years ago

Type of change

Objective

Ignore accented characters in vault searches.

Code changes

Before you submit

Hinton commented 2 years ago

We could look into extending Lunr to be unicode safe per https://github.com/olivernn/lunr.js/issues/269. The last gist is compatible with 2 but not something I've used.

gbubemismith commented 2 years ago

We could look into extending Lunr to be unicode safe per olivernn/lunr.js#269. The last gist is compatible with 2 but not something I've used.

I would look into this right away

gbubemismith commented 2 years ago

We could look into extending Lunr to be unicode safe per olivernn/lunr.js#269. The last gist is compatible with 2 but not something I've used.

@Hinton I was able to customise lunr and added a pipeline function to handle accented characters. This is a cleaner approach as we follow DRY principle.