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

Create a controllable Nutrition table #72

Open
Tracked by #70
alexfauquette opened this issue Jul 26, 2022 · 0 comments
Open
Tracked by #70

Create a controllable Nutrition table #72

alexfauquette opened this issue Jul 26, 2022 · 0 comments
Assignees

Comments

@alexfauquette
Copy link
Member

alexfauquette commented Jul 26, 2022

Part of #70

The idea is to do the table that takes two props data and onDataChange

the format of the data could be an array of objects

[{
	off_nutriment_id: "energy_kj",
	label: "Energie (kJ)",
	value: '25.3',
	unit: null,
	quantification: '=',
	robotoffPrediction: null
	},
{
	off_nutriment_id: "energy_kcal",
	label: "Energie (kCal)",
	value: '',
	unit: null,
	quantification: '<',
	robotoffPrediction: null
	}
]

Here is how it looked liked in the previous version (not perfect design)


Here is a list of nutrients key and their usual units

https://github.com/openfoodfacts/openfoodfacts-hungergames/blob/master/src/data/nutritions.json

@teolemon teolemon changed the title Create a controllable table Create a controllable Nutrition table Sep 28, 2022
@teolemon teolemon added the ✨ Enhancement New feature or request label Sep 28, 2022
@teolemon teolemon removed the ✨ Enhancement New feature or request label Oct 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

No branches or pull requests

3 participants