Skip to content

Commit

Permalink
Improve units, weight, and height questions
Browse files Browse the repository at this point in the history
  • Loading branch information
ibevers committed Nov 5, 2024
1 parent ba7af45 commit 10c18f6
Show file tree
Hide file tree
Showing 6 changed files with 73 additions and 26 deletions.
21 changes: 21 additions & 0 deletions generic/q_generic_confounders/items/height_cm
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"id": "height_cm",
"category": "reproschema:Item",
"description": {
"en": "inches or centimeters"
},

"prefLabel": {
"en": "height centimeters"
},
"question": {
"en": "Height (centimeters)"
},
"responseOptions": {
"valueType": "xsd:decimal"
},
"ui": {
"inputType": "float"
},
"@context": "https://raw.githubusercontent.com/ReproNim/reproschema/main/releases/1.0.0/reproschema"
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"id": "height",
"id": "height_in",
"category": "reproschema:Item",
"description": {
"en": "inches or centimeters"
Expand All @@ -8,15 +8,13 @@
"en": "Height and Weight"
},
"prefLabel": {
"en": "height"
"en": "height inches"
},
"question": {
"en": "Height (inches or centimeters)"
"en": "Height (inches)"
},
"responseOptions": {
"valueType": [
"xsd:decimal"
]
"valueType": "xsd:decimal"
},
"ui": {
"inputType": "float"
Expand Down
6 changes: 2 additions & 4 deletions generic/q_generic_confounders/items/unit
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"en": "unit"
},
"question": {
"en": "Unit"
"en": "Please enter the measurement system for entering your height and weight:"
},
"responseOptions": {
"choices": [
Expand All @@ -22,9 +22,7 @@
"value": 2
}
],
"valueType": [
"xsd:integer"
]
"valueType": "xsd:integer"
},
"ui": {
"inputType": "select"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,17 @@
{
"id": "weight",
"id": "weight_kg",
"category": "reproschema:Item",
"description": {
"en": "lbs or kg"
},
"prefLabel": {
"en": "weight"
"en": "weight kilograms"
},
"question": {
"en": "Weight (pounds or kilograms)"
"en": "Weight (kilograms)"
},
"responseOptions": {
"valueType": [
"xsd:decimal"
]
"valueType": "xsd:decimal"
},
"ui": {
"inputType": "float"
Expand Down
20 changes: 20 additions & 0 deletions generic/q_generic_confounders/items/weight_lbs
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
{
"id": "weight_lbs",
"category": "reproschema:Item",
"description": {
"en": "lbs or kg"
},
"prefLabel": {
"en": "weight pounds"
},
"question": {
"en": "Weight (pounds)"
},
"responseOptions": {
"valueType": "xsd:decimal"
},
"ui": {
"inputType": "float"
},
"@context": "https://raw.githubusercontent.com/ReproNim/reproschema/main/releases/1.0.0/reproschema"
}
32 changes: 22 additions & 10 deletions generic/q_generic_confounders/q_generic_confounders_schema
Original file line number Diff line number Diff line change
Expand Up @@ -199,19 +199,29 @@
"variableName": "tired_measure"
},
{
"isAbout": "items/height",
"isAbout": "items/unit",
"isVis": true,
"variableName": "height"
"variableName": "unit"
},
{
"isAbout": "items/weight",
"isVis": true,
"variableName": "weight"
"isAbout": "items/height_cm",
"isVis": "unit == 1",
"variableName": "height_cm"
},
{
"isAbout": "items/unit",
"isVis": true,
"variableName": "unit"
"isAbout": "items/weight_kg",
"isVis": "unit == 1",
"variableName": "weight_kg"
},
{
"isAbout": "items/height_in",
"isVis": "unit == 2",
"variableName": "height_in"
},
{
"isAbout": "items/weight_lbs",
"isVis": "unit == 2",
"variableName": "weight_lbs"
},
{
"isAbout": "items/symptoms",
Expand Down Expand Up @@ -544,9 +554,11 @@
"items/seasonal_allergies",
"items/seasonal_allergies_options",
"items/tired_measure",
"items/height",
"items/weight",
"items/unit",
"items/height_cm",
"items/weight_kg",
"items/height_in",
"items/weight_lbs",
"items/symptoms",
"items/ent_introduction",
"items/ear_med_history",
Expand Down

0 comments on commit 10c18f6

Please sign in to comment.