diff --git a/pwa/src/components/DiagnosisFields.json b/pwa/src/components/DiagnosisFields.json index 4934d85..73838e4 100644 --- a/pwa/src/components/DiagnosisFields.json +++ b/pwa/src/components/DiagnosisFields.json @@ -73,16 +73,12 @@ "id": "headache" }, { - "name": "Hernia", + "group-title": "Hernia", "id": "hernia", - "radio-buttons": { - "radio-buttons-title": "Hernia Type", - "radio-buttons": [ - { "name": "Inguinal", "id": "inguinal" }, - { "name": "Umbilical", "id": "umbilical" }, - { "name": "Both", "id": "both" } - ] - } + "group": [ + { "name": "Inguinal", "id": "inguinal" }, + { "name": "Umbilical", "id": "umbilical" } + ] }, { "id": "cardiovascular", @@ -99,41 +95,29 @@ "id": "musculoskeletal" }, { - "name": "Otitis", + "group-title": "Otitis", "id": "otitis", - "radio-buttons": { - "radio-buttons-title": "", - "radio-buttons": [ - { "name": "Right", "id": "right" }, - { "name": "Left", "id": "left" }, - { "name": "Both", "id": "both" } - ] - } + "group": [ + { "name": "Right", "id": "right" }, + { "name": "Left", "id": "left" } + ] }, { - "name": "Pneumonia", + "group-title": "Pneumonia", "id": "pneumonia", - "radio-buttons": { - "radio-buttons-title": "", - "radio-buttons": [ - { "name": "Right", "id": "right" }, - { "name": "Left", "id": "left" }, - { "name": "Both", "id": "both" } - ] - } + + "group": [ + { "name": "Right", "id": "right" }, + { "name": "Left", "id": "left" } + ] }, { - "name": "Sinusitis", "id": "sinusitis", - "group-title": "", - "radio-buttons": { - "radio-buttons-title": "", - "radio-buttons": [ - { "name": "Right", "id": "right" }, - { "name": "Left", "id": "left" }, - { "name": "Both", "id": "both" } - ] - } + "group-title": "Sinusitis", + "group": [ + { "name": "Right", "id": "right" }, + { "name": "Left", "id": "left" } + ] }, { "name": "URI", diff --git a/pwa/src/components/DiagnosisForm.tsx b/pwa/src/components/DiagnosisForm.tsx index 9361d72..59650a6 100644 --- a/pwa/src/components/DiagnosisForm.tsx +++ b/pwa/src/components/DiagnosisForm.tsx @@ -77,26 +77,6 @@ export default function DiagnosisForm(): ReactElement { formElements.push() } - // TODO: radio buttons displayed this way are indented badly - if (field['radio-buttons'] != null) { - { - field['radio-buttons']['radio-buttons'].map((i) => - formElements.push( - setSex(i.value)} - > - {i.name} - , - ), - ) - } - } - return <> {formElements} })}