Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Personalized Search - Select user preferences and save them locally in the browser #4119

Closed
stephanegigandet opened this issue Sep 1, 2020 · 3 comments
Assignees
Labels
✨ Feature Features or enhancements to Open Food Facts server JavaScript personal search https://wiki.openfoodfacts.org/Project:Personalized_Search product attributes

Comments

@stephanegigandet
Copy link
Contributor

For the Personal Search project ( https://wiki.openfoodfacts.org/Project:Personalized_Search ), we need to allow users to select user preferences and save them locally. Those preferences will then be used to locally filter and rank products, and locally filter and rank which information is displayed about them.

Preferences are grouped in sections (e.g. nutritional quality, allergens) and each preference has 4 possible values:

  • Not important
  • Important
  • Very important
  • Mandatory

The set of preferences groups and preferences will be defined by the server (they correspond to the product attributes defined in Attributes.pm), but the actual values will never be sent to the server.

e.g.

  • Nutritional quality
    ** The product has a good Nutri-Score
    ** The product is low in salt
    ...
  • Allergens
    ** The product does not contain gluten
    ...

We could create a JS interface, with radio buttons for the different settings. Possibly with some CSS or JS effects to make it nicer than standard radio buttons. e.g. https://codepen.io/Hiswe/pen/yszkE

@stephanegigandet
Copy link
Contributor Author

@stephanegigandet
Copy link
Contributor Author

The structure is there, we can make it prettier after :)

image

stephanegigandet added a commit that referenced this issue Sep 13, 2020
Personal Search - Selection and local storage of user product preferences, #4119
@stephanegigandet
Copy link
Contributor Author

Deployed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
✨ Feature Features or enhancements to Open Food Facts server JavaScript personal search https://wiki.openfoodfacts.org/Project:Personalized_Search product attributes
Projects
None yet
Development

No branches or pull requests

1 participant