-
-
Notifications
You must be signed in to change notification settings - Fork 400
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into aleene-week6
- Loading branch information
Showing
441 changed files
with
39,423 additions
and
3,301 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
$ref: ../schemas/nutrients.yaml |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
description: | | ||
The unit in which the nutrient for 100g or per serving is measured. | ||
The possible values depends on the nutrient. | ||
* `g` for grams | ||
* `mg` for milligrams | ||
* `μg` for micrograms | ||
* `cl` for centiliters | ||
* `ml` for mililiters | ||
* `dv` for recommended daily intakes (aka [Dietary Reference Intake](https://en.wikipedia.org/wiki/Dietary_Reference_Intake)) | ||
* `% vol` for percentage per volume (e.g. alcohol vol per 100 ml) | ||
* `%` for percentage | ||
🤓 code: see the [Units module][units-module], | ||
and [Food:default_unit_for_nid function][default-unit] | ||
[units-module]: https://openfoodfacts.github.io/openfoodfacts-server/dev/ref-perl-pod/ProductOpener/Units.html | ||
[default-unit]: https://openfoodfacts.github.io/openfoodfacts-server/dev/ref-perl-pod/ProductOpener/Food.html#default_unit_for_nid_(_%24nid) | ||
type: string | ||
enum: ['g','mg','μg','cl','ml','dv','% vol','%'] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
type: array | ||
description: | | ||
Nutrients and sub-nutrients of a product, with their name and default unit. | ||
items: | ||
type: object | ||
properties: | ||
id: | ||
type: string | ||
description: id of the nutrient | ||
name: | ||
type: string | ||
description: Name of the nutrient in the requested language | ||
important: | ||
type: boolean | ||
description: Indicates if the nutrient is always shown on the nutrition facts table | ||
display_in_edit_form: | ||
type: boolean | ||
description: Indicates if the nutrient should be shown in the nutrition facts edit form | ||
unit: | ||
description: Default unit of the nutrient | ||
$ref: "./nutrient_unit.yaml" | ||
nutrients: | ||
description: | | ||
Sub-nutrients (e.g. saturated-fat is a sub-nutrient of fat). | ||
# self recursive | ||
$ref: "#/" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.