@f1studio/form-spec 5.0.0-alpha.139 → 5.0.0-alpha.141
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/FormSpec.FS/FormSpec.d.ts +5 -4
- package/FormSpec.FS/FormSpec.d.ts.map +1 -1
- package/FormSpec.FS/FormSpecValues.d.ts +0 -5
- package/FormSpec.FS/FormSpecValues.d.ts.map +1 -1
- package/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRElementTypeMap.d.ts +3 -2
- package/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRElementTypeMap.d.ts.map +1 -1
- package/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRFieldTypeMapper.d.ts.map +1 -1
- package/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMREncoder.d.ts.map +1 -1
- package/FormSpec.FS/Integrations/CorEMR/TemplateManifestDecoder.d.ts +1 -1
- package/FormSpec.FS/Integrations/CorEMR/TemplateManifestDecoder.d.ts.map +1 -1
- package/FormSpec.FS/Integrations/OpenFda/OpenFdaTypes.d.ts +74 -0
- package/FormSpec.FS/Integrations/OpenFda/OpenFdaTypes.d.ts.map +1 -0
- package/FormSpec.FS/Interop/Facade/BlueprintFilledForm.d.ts +106 -0
- package/FormSpec.FS/Interop/Facade/BlueprintFilledForm.d.ts.map +1 -0
- package/FormSpec.FS/Interop/Facade/FormAnswersGate.d.ts +105 -0
- package/FormSpec.FS/Interop/Facade/FormAnswersGate.d.ts.map +1 -0
- package/FormSpec.FS/Interop/FormSpec.Api.Helpers.d.ts +26 -13
- package/FormSpec.FS/Interop/FormSpec.Api.Helpers.d.ts.map +1 -1
- package/FormSpec.FS/Interop/FormSpec.Api.Option.d.ts +1 -2
- package/FormSpec.FS/Interop/FormSpec.Api.Option.d.ts.map +1 -1
- package/FormSpec.FS/Interop/FormSpec.Values.Api.Option.d.ts +5 -3
- package/FormSpec.FS/Interop/FormSpec.Values.Api.Option.d.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/BlueprintValidation.js +1 -1
- package/FormSpec.TS/FormSpec.FS/BlueprintValidation.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/BlueprintValidation.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Designer.js +1 -1
- package/FormSpec.TS/FormSpec.FS/Designer.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Designer.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/FormSpec.js +13 -8
- package/FormSpec.TS/FormSpec.FS/FormSpec.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/FormSpec.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/FormSpecHelpers.js +5 -5
- package/FormSpec.TS/FormSpec.FS/FormSpecHelpers.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/FormSpecHelpers.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/FormSpecValues.js +2 -21
- package/FormSpec.TS/FormSpec.FS/FormSpecValues.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/FormSpecValues.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Helpers.js +12 -12
- package/FormSpec.TS/FormSpec.FS/Helpers.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Helpers.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRElementTypeMap.js +36 -30
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRElementTypeMap.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRElementTypeMap.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRFieldTypeMapper.js +5 -20
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRFieldTypeMapper.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRFieldTypeMapper.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRStepsBuilder.js +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRStepsBuilder.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRStepsBuilder.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRTemplateToFormSpec.js +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRTemplateToFormSpec.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRTemplateToFormSpec.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMREncoder.js +24 -10
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMREncoder.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMREncoder.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMRSourceMap.js +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMRSourceMap.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMRSourceMap.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/Adapters/CorEMR/FormSpecToCoreMRInsert.js +2 -2
- package/FormSpec.TS/FormSpec.FS/Integrations/CorEMR/TemplateManifestDecoder.js +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/CorEMR/TemplateManifestDecoder.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/CorEMR/TemplateManifestDecoder.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Integrations/OpenFda/OpenFdaTypes.js +282 -0
- package/FormSpec.TS/FormSpec.FS/Integrations/OpenFda/OpenFdaTypes.js.map +1 -0
- package/FormSpec.TS/FormSpec.FS/Integrations/OpenFda/OpenFdaTypes.ts.map +1 -0
- package/FormSpec.TS/FormSpec.FS/Interop/Facade/BlueprintFilledForm.js +184 -0
- package/FormSpec.TS/FormSpec.FS/Interop/Facade/BlueprintFilledForm.js.map +1 -0
- package/FormSpec.TS/FormSpec.FS/Interop/Facade/BlueprintFilledForm.ts.map +1 -0
- package/FormSpec.TS/FormSpec.FS/Interop/Facade/FormAnswersGate.js +752 -0
- package/FormSpec.TS/FormSpec.FS/Interop/Facade/FormAnswersGate.js.map +1 -0
- package/FormSpec.TS/FormSpec.FS/Interop/Facade/FormAnswersGate.ts.map +1 -0
- package/FormSpec.TS/FormSpec.FS/Interop/FormSpec.Api.Helpers.js +317 -81
- package/FormSpec.TS/FormSpec.FS/Interop/FormSpec.Api.Helpers.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Interop/FormSpec.Api.Helpers.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Interop/FormSpec.Api.Option.js +5 -10
- package/FormSpec.TS/FormSpec.FS/Interop/FormSpec.Api.Option.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Interop/FormSpec.Api.Option.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Interop/FormSpec.Values.Api.Option.js +20 -10
- package/FormSpec.TS/FormSpec.FS/Interop/FormSpec.Values.Api.Option.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Interop/FormSpec.Values.Api.Option.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Migrator.js +1 -1
- package/FormSpec.TS/FormSpec.FS/Migrator.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/Migrator.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/PathwayExecutor.js +3 -3
- package/FormSpec.TS/FormSpec.FS/PathwayExecutor.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/PathwayExecutor.ts.map +1 -1
- package/FormSpec.TS/FormSpec.FS/PathwayValidator.js +1 -1
- package/FormSpec.TS/FormSpec.FS/PathwayValidator.js.map +1 -1
- package/FormSpec.TS/FormSpec.FS/PathwayValidator.ts.map +1 -1
- package/FormSpec.TS/PluginRegistration.js +2 -0
- package/FormSpec.TS/PluginRegistration.js.map +1 -1
- package/FormSpec.TS/PluginRegistration.ts.map +1 -1
- package/FormSpec.TS/{libs/Thoth.Json → Thoth.Json}/packages/Thoth.Json/Decode.js +63 -69
- package/FormSpec.TS/Thoth.Json/packages/Thoth.Json/Decode.js.map +1 -0
- package/FormSpec.TS/Thoth.Json/packages/Thoth.Json/Decode.ts.map +1 -0
- package/FormSpec.TS/{libs/Thoth.Json → Thoth.Json}/packages/Thoth.Json/Encode.js +6 -10
- package/FormSpec.TS/Thoth.Json/packages/Thoth.Json/Encode.js.map +1 -0
- package/FormSpec.TS/Thoth.Json/packages/Thoth.Json/Encode.ts.map +1 -0
- package/FormSpec.TS/Thoth.Json/packages/Thoth.Json/Extra.js.map +1 -0
- package/FormSpec.TS/Thoth.Json/packages/Thoth.Json/Extra.ts.map +1 -0
- package/FormSpec.TS/Thoth.Json/packages/Thoth.Json/Types.js.map +1 -0
- package/FormSpec.TS/Thoth.Json/packages/Thoth.Json/Types.ts.map +1 -0
- package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/AsyncIterable.fs +57 -0
- package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/AsyncIterable.fs.js +119 -0
- package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/AsyncIterable.fs.js.map +1 -0
- package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/AsyncIterable.fs.ts.map +1 -0
- package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/Fable.Promise.fableproj +20 -0
- package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/Promise.fs +766 -0
- package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/Promise.fs.js +165 -0
- package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/Promise.fs.js.map +1 -0
- package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/Promise.fs.ts.map +1 -0
- package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/PromiseImpl.fs +31 -0
- package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/PromiseImpl.fs.js +32 -0
- package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/PromiseImpl.fs.js.map +1 -0
- package/FormSpec.TS/fable_modules/Fable.Promise.3.2.0/PromiseImpl.fs.ts.map +1 -0
- package/FormSpec.TS/fable_modules/Feliz.2.8.0/DateParsing.fs.js.map +1 -1
- package/FormSpec.TS/fable_modules/Feliz.2.8.0/DateParsing.fs.ts.map +1 -1
- package/FormSpec.TS/fable_modules/project_cracked.json +1 -1
- package/FormSpec.TS/plugins/allergyfinder/src/AllergyFinderField.js +2431 -0
- package/FormSpec.TS/plugins/allergyfinder/src/AllergyFinderField.js.map +1 -0
- package/FormSpec.TS/plugins/allergyfinder/src/AllergyFinderField.ts.map +1 -0
- package/FormSpec.TS/plugins/allergyfinder/src/OpenFdaClient.js +107 -0
- package/FormSpec.TS/plugins/allergyfinder/src/OpenFdaClient.js.map +1 -0
- package/FormSpec.TS/plugins/allergyfinder/src/OpenFdaClient.ts.map +1 -0
- package/FormSpec.TS/plugins/signature/src/SignatureField.js +1 -1
- package/FormSpec.TS/plugins/signature/src/SignatureField.js.map +1 -1
- package/FormSpec.TS/plugins/signature/src/SignatureField.ts.map +1 -1
- package/FormSpec.TS/plugins/vitals/src/VitalsField.js +29 -312
- package/FormSpec.TS/plugins/vitals/src/VitalsField.js.map +1 -1
- package/FormSpec.TS/plugins/vitals/src/VitalsField.ts.map +1 -1
- package/FormSpec.TS/plugins/vitals/src/VitalsLogic.js +506 -0
- package/FormSpec.TS/plugins/vitals/src/VitalsLogic.js.map +1 -0
- package/FormSpec.TS/plugins/vitals/src/VitalsLogic.ts.map +1 -0
- package/README.md +7 -7
- package/{libs/Thoth.Json → Thoth.Json}/packages/Thoth.Json/Decode.d.ts +2 -2
- package/Thoth.Json/packages/Thoth.Json/Decode.d.ts.map +1 -0
- package/Thoth.Json/packages/Thoth.Json/Encode.d.ts.map +1 -0
- package/Thoth.Json/packages/Thoth.Json/Extra.d.ts.map +1 -0
- package/Thoth.Json/packages/Thoth.Json/Types.d.ts.map +1 -0
- package/fable_modules/Fable.Promise.3.2.0/Promise.fs.d.ts +112 -0
- package/fable_modules/Fable.Promise.3.2.0/Promise.fs.d.ts.map +1 -0
- package/fable_modules/Fable.Promise.3.2.0/PromiseImpl.fs.d.ts +8 -0
- package/fable_modules/Fable.Promise.3.2.0/PromiseImpl.fs.d.ts.map +1 -0
- package/package.json +9 -1
- package/plugins/allergyfinder/src/AllergyFinderField.d.ts +116 -0
- package/plugins/allergyfinder/src/AllergyFinderField.d.ts.map +1 -0
- package/plugins/allergyfinder/src/OpenFdaClient.d.ts +5 -0
- package/plugins/allergyfinder/src/OpenFdaClient.d.ts.map +1 -0
- package/plugins/vitals/src/VitalsField.d.ts +4 -43
- package/plugins/vitals/src/VitalsField.d.ts.map +1 -1
- package/plugins/vitals/src/VitalsLogic.d.ts +72 -0
- package/plugins/vitals/src/VitalsLogic.d.ts.map +1 -0
- package/src/FormSpec.FS/BlueprintValidation.ts +1 -1
- package/src/FormSpec.FS/Designer.ts +1 -1
- package/src/FormSpec.FS/FormSpec.ts +10 -8
- package/src/FormSpec.FS/FormSpecHelpers.ts +5 -5
- package/src/FormSpec.FS/FormSpecValues.ts +2 -25
- package/src/FormSpec.FS/Helpers.ts +12 -12
- package/src/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRElementTypeMap.ts +35 -32
- package/src/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRFieldTypeMapper.ts +6 -23
- package/src/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRStepsBuilder.ts +1 -1
- package/src/FormSpec.FS/Integrations/Adapters/CorEMR/CorEMRTemplateToFormSpec.ts +1 -1
- package/src/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMREncoder.ts +27 -11
- package/src/FormSpec.FS/Integrations/Adapters/CorEMR/CoreMRSourceMap.ts +1 -1
- package/src/FormSpec.FS/Integrations/Adapters/CorEMR/FormSpecToCoreMRInsert.ts +3 -3
- package/src/FormSpec.FS/Integrations/CorEMR/TemplateManifestDecoder.ts +3 -3
- package/src/FormSpec.FS/Integrations/OpenFda/OpenFdaTypes.ts +160 -0
- package/src/FormSpec.FS/Interop/Facade/BlueprintFilledForm.ts +244 -0
- package/src/FormSpec.FS/Interop/Facade/FormAnswersGate.ts +508 -0
- package/src/FormSpec.FS/Interop/FormSpec.Api.Helpers.ts +376 -128
- package/src/FormSpec.FS/Interop/FormSpec.Api.Option.ts +6 -8
- package/src/FormSpec.FS/Interop/FormSpec.Values.Api.Option.ts +17 -13
- package/src/FormSpec.FS/Migrator.ts +1 -1
- package/src/FormSpec.FS/PathwayExecutor.ts +3 -3
- package/src/FormSpec.FS/PathwayValidator.ts +1 -1
- package/src/PluginRegistration.ts +2 -0
- package/src/{libs/Thoth.Json → Thoth.Json}/packages/Thoth.Json/Decode.ts +38 -55
- package/src/{libs/Thoth.Json → Thoth.Json}/packages/Thoth.Json/Encode.ts +10 -16
- package/src/plugins/allergyfinder/src/AllergyFinderField.ts +1341 -0
- package/src/plugins/allergyfinder/src/OpenFdaClient.ts +103 -0
- package/src/plugins/signature/src/SignatureField.ts +1 -1
- package/src/plugins/vitals/src/VitalsField.ts +35 -244
- package/src/plugins/vitals/src/VitalsLogic.ts +360 -0
- package/FormSpec.TS/libs/Thoth.Json/packages/Thoth.Json/Decode.js.map +0 -1
- package/FormSpec.TS/libs/Thoth.Json/packages/Thoth.Json/Decode.ts.map +0 -1
- package/FormSpec.TS/libs/Thoth.Json/packages/Thoth.Json/Encode.js.map +0 -1
- package/FormSpec.TS/libs/Thoth.Json/packages/Thoth.Json/Encode.ts.map +0 -1
- package/FormSpec.TS/libs/Thoth.Json/packages/Thoth.Json/Extra.js.map +0 -1
- package/FormSpec.TS/libs/Thoth.Json/packages/Thoth.Json/Extra.ts.map +0 -1
- package/FormSpec.TS/libs/Thoth.Json/packages/Thoth.Json/Types.js.map +0 -1
- package/FormSpec.TS/libs/Thoth.Json/packages/Thoth.Json/Types.ts.map +0 -1
- package/libs/Thoth.Json/packages/Thoth.Json/Decode.d.ts.map +0 -1
- package/libs/Thoth.Json/packages/Thoth.Json/Encode.d.ts.map +0 -1
- package/libs/Thoth.Json/packages/Thoth.Json/Extra.d.ts.map +0 -1
- package/libs/Thoth.Json/packages/Thoth.Json/Types.d.ts.map +0 -1
- /package/FormSpec.TS/{libs/Thoth.Json → Thoth.Json}/packages/Thoth.Json/Extra.js +0 -0
- /package/FormSpec.TS/{libs/Thoth.Json → Thoth.Json}/packages/Thoth.Json/Types.js +0 -0
- /package/{libs/Thoth.Json → Thoth.Json}/packages/Thoth.Json/Encode.d.ts +0 -0
- /package/{libs/Thoth.Json → Thoth.Json}/packages/Thoth.Json/Extra.d.ts +0 -0
- /package/{libs/Thoth.Json → Thoth.Json}/packages/Thoth.Json/Types.d.ts +0 -0
- /package/src/{libs/Thoth.Json → Thoth.Json}/packages/Thoth.Json/Extra.ts +0 -0
- /package/src/{libs/Thoth.Json → Thoth.Json}/packages/Thoth.Json/Types.ts +0 -0
|
@@ -60,87 +60,24 @@ _export(exports, {
|
|
|
60
60
|
get VitalsField_Field$1_$reflection () {
|
|
61
61
|
return VitalsField_Field$1_$reflection;
|
|
62
62
|
},
|
|
63
|
-
get VitalsField_VitalsConfig () {
|
|
64
|
-
return VitalsField_VitalsConfig;
|
|
65
|
-
},
|
|
66
|
-
get VitalsField_VitalsConfig_$reflection () {
|
|
67
|
-
return VitalsField_VitalsConfig_$reflection;
|
|
68
|
-
},
|
|
69
|
-
get VitalsField_VitalsData () {
|
|
70
|
-
return VitalsField_VitalsData;
|
|
71
|
-
},
|
|
72
|
-
get VitalsField_VitalsData_$reflection () {
|
|
73
|
-
return VitalsField_VitalsData_$reflection;
|
|
74
|
-
},
|
|
75
63
|
get VitalsField_VitalsFieldComponent () {
|
|
76
64
|
return VitalsField_VitalsFieldComponent;
|
|
77
65
|
},
|
|
78
66
|
get VitalsField_form () {
|
|
79
67
|
return VitalsField_form;
|
|
80
|
-
},
|
|
81
|
-
get VitalsField_getVitalStatus () {
|
|
82
|
-
return VitalsField_getVitalStatus;
|
|
83
|
-
},
|
|
84
|
-
get VitalsField_isCriticalDiastolicBP () {
|
|
85
|
-
return VitalsField_isCriticalDiastolicBP;
|
|
86
|
-
},
|
|
87
|
-
get VitalsField_isCriticalOxygenSat () {
|
|
88
|
-
return VitalsField_isCriticalOxygenSat;
|
|
89
|
-
},
|
|
90
|
-
get VitalsField_isCriticalPulse () {
|
|
91
|
-
return VitalsField_isCriticalPulse;
|
|
92
|
-
},
|
|
93
|
-
get VitalsField_isCriticalRespiration () {
|
|
94
|
-
return VitalsField_isCriticalRespiration;
|
|
95
|
-
},
|
|
96
|
-
get VitalsField_isCriticalSystolicBP () {
|
|
97
|
-
return VitalsField_isCriticalSystolicBP;
|
|
98
|
-
},
|
|
99
|
-
get VitalsField_isCriticalTemperature () {
|
|
100
|
-
return VitalsField_isCriticalTemperature;
|
|
101
|
-
},
|
|
102
|
-
get VitalsField_isNormalTemperature () {
|
|
103
|
-
return VitalsField_isNormalTemperature;
|
|
104
|
-
},
|
|
105
|
-
get VitalsField_isValidDiastolicBP () {
|
|
106
|
-
return VitalsField_isValidDiastolicBP;
|
|
107
|
-
},
|
|
108
|
-
get VitalsField_isValidOxygenSat () {
|
|
109
|
-
return VitalsField_isValidOxygenSat;
|
|
110
|
-
},
|
|
111
|
-
get VitalsField_isValidPainScale () {
|
|
112
|
-
return VitalsField_isValidPainScale;
|
|
113
|
-
},
|
|
114
|
-
get VitalsField_isValidPulse () {
|
|
115
|
-
return VitalsField_isValidPulse;
|
|
116
|
-
},
|
|
117
|
-
get VitalsField_isValidRespiration () {
|
|
118
|
-
return VitalsField_isValidRespiration;
|
|
119
|
-
},
|
|
120
|
-
get VitalsField_isValidSystolicBP () {
|
|
121
|
-
return VitalsField_isValidSystolicBP;
|
|
122
|
-
},
|
|
123
|
-
get VitalsField_isValidTemperature () {
|
|
124
|
-
return VitalsField_isValidTemperature;
|
|
125
|
-
},
|
|
126
|
-
get VitalsField_parseVitalsData () {
|
|
127
|
-
return VitalsField_parseVitalsData;
|
|
128
|
-
},
|
|
129
|
-
get VitalsField_serializeVitalsData () {
|
|
130
|
-
return VitalsField_serializeVitalsData;
|
|
131
68
|
}
|
|
132
69
|
});
|
|
133
70
|
const _Types = require("@fable-org/fable-library-js/Types.js");
|
|
134
|
-
const
|
|
71
|
+
const _VitalsLogic = require("./VitalsLogic.js");
|
|
135
72
|
const _Util = require("@fable-org/fable-library-js/Util.js");
|
|
136
|
-
const _Reflection = require("@fable-org/fable-library-js/Reflection.js");
|
|
137
73
|
const _Fieldfs = require("../../../fable_modules/Fable.Form.3.0.0/Field.fs.js");
|
|
74
|
+
const _Reflection = require("@fable-org/fable-library-js/Reflection.js");
|
|
138
75
|
const _Basefs = require("../../../fable_modules/Fable.Form.3.0.0/Base.fs.js");
|
|
139
76
|
const _String = require("@fable-org/fable-library-js/String.js");
|
|
140
|
-
const _Array = require("@fable-org/fable-library-js/Array.js");
|
|
141
|
-
const _Double = require("@fable-org/fable-library-js/Double.js");
|
|
142
77
|
const _react = require("react");
|
|
78
|
+
const _Option = require("@fable-org/fable-library-js/Option.js");
|
|
143
79
|
const _Interopfs = require("../../../fable_modules/Feliz.2.8.0/Interop.fs.js");
|
|
80
|
+
const _Double = require("@fable-org/fable-library-js/Double.js");
|
|
144
81
|
const _List = require("@fable-org/fable-library-js/List.js");
|
|
145
82
|
const _HtmlViewfs = require("../../../fable_modules/Fable.Form.Simple.Bulma.5.0.1/Html.View.fs.js");
|
|
146
83
|
const _Seq = require("@fable-org/fable-library-js/Seq.js");
|
|
@@ -149,89 +86,6 @@ const _FormSpec = require("../../../FormSpec.FS/FormSpec.js");
|
|
|
149
86
|
const _Result = require("@fable-org/fable-library-js/Result.js");
|
|
150
87
|
const _PluginInterface = require("../../../FormSpec.FS/PluginInterface.js");
|
|
151
88
|
const _ElementBuildersfs = require("../../../fable_modules/Feliz.Bulma.3.0.0/ElementBuilders.fs.js");
|
|
152
|
-
class VitalsField_VitalsData extends _Types.Record {
|
|
153
|
-
constructor(Temperature, SystolicBP, DiastolicBP, Pulse, Respiration, OxygenSaturation, PainScale){
|
|
154
|
-
super();
|
|
155
|
-
this.Temperature = Temperature;
|
|
156
|
-
this.SystolicBP = SystolicBP;
|
|
157
|
-
this.DiastolicBP = DiastolicBP;
|
|
158
|
-
this.Pulse = Pulse;
|
|
159
|
-
this.Respiration = Respiration;
|
|
160
|
-
this.OxygenSaturation = OxygenSaturation;
|
|
161
|
-
this.PainScale = PainScale;
|
|
162
|
-
}
|
|
163
|
-
}
|
|
164
|
-
function VitalsField_VitalsData_$reflection() {
|
|
165
|
-
return (0, _Reflection.record_type)("Fable.Form.Simple.Bulma.Fields.VitalsField.VitalsField.VitalsData", [], VitalsField_VitalsData, ()=>[
|
|
166
|
-
[
|
|
167
|
-
"Temperature",
|
|
168
|
-
(0, _Reflection.option_type)(_Reflection.float64_type)
|
|
169
|
-
],
|
|
170
|
-
[
|
|
171
|
-
"SystolicBP",
|
|
172
|
-
(0, _Reflection.option_type)(_Reflection.float64_type)
|
|
173
|
-
],
|
|
174
|
-
[
|
|
175
|
-
"DiastolicBP",
|
|
176
|
-
(0, _Reflection.option_type)(_Reflection.float64_type)
|
|
177
|
-
],
|
|
178
|
-
[
|
|
179
|
-
"Pulse",
|
|
180
|
-
(0, _Reflection.option_type)(_Reflection.float64_type)
|
|
181
|
-
],
|
|
182
|
-
[
|
|
183
|
-
"Respiration",
|
|
184
|
-
(0, _Reflection.option_type)(_Reflection.float64_type)
|
|
185
|
-
],
|
|
186
|
-
[
|
|
187
|
-
"OxygenSaturation",
|
|
188
|
-
(0, _Reflection.option_type)(_Reflection.float64_type)
|
|
189
|
-
],
|
|
190
|
-
[
|
|
191
|
-
"PainScale",
|
|
192
|
-
(0, _Reflection.option_type)(_Reflection.float64_type)
|
|
193
|
-
]
|
|
194
|
-
]);
|
|
195
|
-
}
|
|
196
|
-
class VitalsField_VitalsConfig extends _Types.Record {
|
|
197
|
-
constructor(IncludeTemperature, IncludeBP, IncludePulse, IncludeRespiration, IncludeOxygenSat, IncludePainScale){
|
|
198
|
-
super();
|
|
199
|
-
this.IncludeTemperature = IncludeTemperature;
|
|
200
|
-
this.IncludeBP = IncludeBP;
|
|
201
|
-
this.IncludePulse = IncludePulse;
|
|
202
|
-
this.IncludeRespiration = IncludeRespiration;
|
|
203
|
-
this.IncludeOxygenSat = IncludeOxygenSat;
|
|
204
|
-
this.IncludePainScale = IncludePainScale;
|
|
205
|
-
}
|
|
206
|
-
}
|
|
207
|
-
function VitalsField_VitalsConfig_$reflection() {
|
|
208
|
-
return (0, _Reflection.record_type)("Fable.Form.Simple.Bulma.Fields.VitalsField.VitalsField.VitalsConfig", [], VitalsField_VitalsConfig, ()=>[
|
|
209
|
-
[
|
|
210
|
-
"IncludeTemperature",
|
|
211
|
-
_Reflection.bool_type
|
|
212
|
-
],
|
|
213
|
-
[
|
|
214
|
-
"IncludeBP",
|
|
215
|
-
_Reflection.bool_type
|
|
216
|
-
],
|
|
217
|
-
[
|
|
218
|
-
"IncludePulse",
|
|
219
|
-
_Reflection.bool_type
|
|
220
|
-
],
|
|
221
|
-
[
|
|
222
|
-
"IncludeRespiration",
|
|
223
|
-
_Reflection.bool_type
|
|
224
|
-
],
|
|
225
|
-
[
|
|
226
|
-
"IncludeOxygenSat",
|
|
227
|
-
_Reflection.bool_type
|
|
228
|
-
],
|
|
229
|
-
[
|
|
230
|
-
"IncludePainScale",
|
|
231
|
-
_Reflection.bool_type
|
|
232
|
-
]
|
|
233
|
-
]);
|
|
234
|
-
}
|
|
235
89
|
class VitalsField_Attributes extends _Types.Record {
|
|
236
90
|
GetFieldId() {
|
|
237
91
|
const this$ = this;
|
|
@@ -256,153 +110,16 @@ function VitalsField_Attributes_$reflection() {
|
|
|
256
110
|
],
|
|
257
111
|
[
|
|
258
112
|
"Config",
|
|
259
|
-
|
|
113
|
+
(0, _VitalsLogic.VitalsConfig_$reflection)()
|
|
260
114
|
]
|
|
261
115
|
]);
|
|
262
116
|
}
|
|
263
117
|
function VitalsField_form() {
|
|
264
118
|
return (build)=>(config)=>(0, _Basefs.field)(_String.isNullOrEmpty, build, config);
|
|
265
119
|
}
|
|
266
|
-
function VitalsField_isValidTemperature(temp) {
|
|
267
|
-
if (temp >= 95) {
|
|
268
|
-
return temp <= 108;
|
|
269
|
-
} else {
|
|
270
|
-
return false;
|
|
271
|
-
}
|
|
272
|
-
}
|
|
273
|
-
function VitalsField_isValidSystolicBP(sys) {
|
|
274
|
-
if (sys >= 60) {
|
|
275
|
-
return sys <= 200;
|
|
276
|
-
} else {
|
|
277
|
-
return false;
|
|
278
|
-
}
|
|
279
|
-
}
|
|
280
|
-
function VitalsField_isValidDiastolicBP(dia) {
|
|
281
|
-
if (dia >= 40) {
|
|
282
|
-
return dia <= 120;
|
|
283
|
-
} else {
|
|
284
|
-
return false;
|
|
285
|
-
}
|
|
286
|
-
}
|
|
287
|
-
function VitalsField_isValidPulse(pulse) {
|
|
288
|
-
if (pulse >= 40) {
|
|
289
|
-
return pulse <= 180;
|
|
290
|
-
} else {
|
|
291
|
-
return false;
|
|
292
|
-
}
|
|
293
|
-
}
|
|
294
|
-
function VitalsField_isValidRespiration(resp) {
|
|
295
|
-
if (resp >= 8) {
|
|
296
|
-
return resp <= 35;
|
|
297
|
-
} else {
|
|
298
|
-
return false;
|
|
299
|
-
}
|
|
300
|
-
}
|
|
301
|
-
function VitalsField_isValidOxygenSat(sat) {
|
|
302
|
-
if (sat >= 70) {
|
|
303
|
-
return sat <= 100;
|
|
304
|
-
} else {
|
|
305
|
-
return false;
|
|
306
|
-
}
|
|
307
|
-
}
|
|
308
|
-
function VitalsField_isValidPainScale(pain) {
|
|
309
|
-
if (pain >= 0) {
|
|
310
|
-
return pain <= 10;
|
|
311
|
-
} else {
|
|
312
|
-
return false;
|
|
313
|
-
}
|
|
314
|
-
}
|
|
315
|
-
function VitalsField_isCriticalTemperature(temp) {
|
|
316
|
-
if (temp < 96) {
|
|
317
|
-
return true;
|
|
318
|
-
} else {
|
|
319
|
-
return temp > 104;
|
|
320
|
-
}
|
|
321
|
-
}
|
|
322
|
-
function VitalsField_isNormalTemperature(temp) {
|
|
323
|
-
if (temp >= 97) {
|
|
324
|
-
return temp <= 99;
|
|
325
|
-
} else {
|
|
326
|
-
return false;
|
|
327
|
-
}
|
|
328
|
-
}
|
|
329
|
-
function VitalsField_isCriticalSystolicBP(sys) {
|
|
330
|
-
if (sys < 90) {
|
|
331
|
-
return true;
|
|
332
|
-
} else {
|
|
333
|
-
return sys > 180;
|
|
334
|
-
}
|
|
335
|
-
}
|
|
336
|
-
function VitalsField_isCriticalDiastolicBP(dia) {
|
|
337
|
-
if (dia < 60) {
|
|
338
|
-
return true;
|
|
339
|
-
} else {
|
|
340
|
-
return dia > 110;
|
|
341
|
-
}
|
|
342
|
-
}
|
|
343
|
-
function VitalsField_isCriticalPulse(pulse) {
|
|
344
|
-
if (pulse < 50) {
|
|
345
|
-
return true;
|
|
346
|
-
} else {
|
|
347
|
-
return pulse > 120;
|
|
348
|
-
}
|
|
349
|
-
}
|
|
350
|
-
function VitalsField_isCriticalRespiration(resp) {
|
|
351
|
-
if (resp < 12) {
|
|
352
|
-
return true;
|
|
353
|
-
} else {
|
|
354
|
-
return resp > 25;
|
|
355
|
-
}
|
|
356
|
-
}
|
|
357
|
-
function VitalsField_isCriticalOxygenSat(sat) {
|
|
358
|
-
return sat < 95;
|
|
359
|
-
}
|
|
360
|
-
function VitalsField_parseVitalsData(value) {
|
|
361
|
-
try {
|
|
362
|
-
if ((0, _String.isNullOrWhiteSpace)(value)) {
|
|
363
|
-
return new VitalsField_VitalsData(undefined, undefined, undefined, undefined, undefined, undefined, undefined);
|
|
364
|
-
} else {
|
|
365
|
-
const parts = (0, _String.split)(value, [
|
|
366
|
-
"|"
|
|
367
|
-
], undefined, 0);
|
|
368
|
-
return new VitalsField_VitalsData(parts.length > 0 && !(0, _String.isNullOrWhiteSpace)((0, _Array.item)(0, parts)) ? (0, _Double.parse)((0, _Array.item)(0, parts)) : undefined, parts.length > 1 && !(0, _String.isNullOrWhiteSpace)((0, _Array.item)(1, parts)) ? (0, _Double.parse)((0, _Array.item)(1, parts)) : undefined, parts.length > 2 && !(0, _String.isNullOrWhiteSpace)((0, _Array.item)(2, parts)) ? (0, _Double.parse)((0, _Array.item)(2, parts)) : undefined, parts.length > 3 && !(0, _String.isNullOrWhiteSpace)((0, _Array.item)(3, parts)) ? (0, _Double.parse)((0, _Array.item)(3, parts)) : undefined, parts.length > 4 && !(0, _String.isNullOrWhiteSpace)((0, _Array.item)(4, parts)) ? (0, _Double.parse)((0, _Array.item)(4, parts)) : undefined, parts.length > 5 && !(0, _String.isNullOrWhiteSpace)((0, _Array.item)(5, parts)) ? (0, _Double.parse)((0, _Array.item)(5, parts)) : undefined, parts.length > 6 && !(0, _String.isNullOrWhiteSpace)((0, _Array.item)(6, parts)) ? (0, _Double.parse)((0, _Array.item)(6, parts)) : undefined);
|
|
369
|
-
}
|
|
370
|
-
} catch (matchValue) {
|
|
371
|
-
return new VitalsField_VitalsData(undefined, undefined, undefined, undefined, undefined, undefined, undefined);
|
|
372
|
-
}
|
|
373
|
-
}
|
|
374
|
-
function VitalsField_serializeVitalsData(vitalsData) {
|
|
375
|
-
const optToString = (opt)=>(0, _Option.defaultArg)((0, _Option.map)((value)=>value.toString(), opt), "");
|
|
376
|
-
return (0, _String.join)("|", [
|
|
377
|
-
optToString(vitalsData.Temperature),
|
|
378
|
-
optToString(vitalsData.SystolicBP),
|
|
379
|
-
optToString(vitalsData.DiastolicBP),
|
|
380
|
-
optToString(vitalsData.Pulse),
|
|
381
|
-
optToString(vitalsData.Respiration),
|
|
382
|
-
optToString(vitalsData.OxygenSaturation),
|
|
383
|
-
optToString(vitalsData.PainScale)
|
|
384
|
-
]);
|
|
385
|
-
}
|
|
386
|
-
function VitalsField_getVitalStatus(value, isValid, isCritical, isNormal) {
|
|
387
|
-
let v_2;
|
|
388
|
-
if (value == null) {
|
|
389
|
-
return "empty";
|
|
390
|
-
} else if (isCritical((0, _Option.value)(value))) {
|
|
391
|
-
const v_3 = (0, _Option.value)(value);
|
|
392
|
-
return "critical";
|
|
393
|
-
} else if (!isValid((0, _Option.value)(value))) {
|
|
394
|
-
const v_4 = (0, _Option.value)(value);
|
|
395
|
-
return "abnormal";
|
|
396
|
-
} else if (v_2 = (0, _Option.value)(value), isNormal != null && !(0, _Option.value)(isNormal)(v_2)) {
|
|
397
|
-
const v_5 = (0, _Option.value)(value);
|
|
398
|
-
return "abnormal";
|
|
399
|
-
} else {
|
|
400
|
-
return "normal";
|
|
401
|
-
}
|
|
402
|
-
}
|
|
403
120
|
function VitalsField_VitalsFieldComponent(config) {
|
|
404
121
|
let elems_12;
|
|
405
|
-
const vitalsData =
|
|
122
|
+
const vitalsData = (0, _VitalsLogic.parseVitalsData)(config.Value);
|
|
406
123
|
const vitalsConfig = config.Attributes.Config;
|
|
407
124
|
let patternInput;
|
|
408
125
|
const initial = (0, _Option.defaultArg)((0, _Option.map)((value)=>value.toString(), vitalsData.Temperature), "");
|
|
@@ -461,7 +178,7 @@ function VitalsField_VitalsFieldComponent(config) {
|
|
|
461
178
|
}
|
|
462
179
|
}
|
|
463
180
|
};
|
|
464
|
-
config.OnChange(
|
|
181
|
+
config.OnChange((0, _VitalsLogic.serializeVitalsData)(new _VitalsLogic.VitalsData(parseOpt(temperature), parseOpt(systolicBP), parseOpt(diastolicBP), parseOpt(pulse), parseOpt(respiration), parseOpt(oxygenSat), parseOpt(painScale))));
|
|
465
182
|
}, dependencies);
|
|
466
183
|
const parseNumeric = (raw)=>{
|
|
467
184
|
if ((0, _String.isNullOrWhiteSpace)(raw)) {
|
|
@@ -488,7 +205,7 @@ function VitalsField_VitalsFieldComponent(config) {
|
|
|
488
205
|
});
|
|
489
206
|
const createVitalInput = (label_1, value_18, setValue, unitText, placeholder, isValid, isCritical, isNormal)=>{
|
|
490
207
|
let elems_1, elems;
|
|
491
|
-
const vitalStatus =
|
|
208
|
+
const vitalStatus = (0, _VitalsLogic.getVitalStatus)(parseNumeric(value_18), isValid, isCritical, isNormal);
|
|
492
209
|
let inputClass;
|
|
493
210
|
const baseClass = "mt-1 block w-full rounded-md border bg-white px-2.5 py-1.5 text-sm text-slate-900 shadow-sm transition placeholder:text-slate-400 focus:outline-none focus:ring-2 disabled:cursor-not-allowed disabled:bg-slate-100 disabled:text-slate-500";
|
|
494
211
|
inputClass = config.ShowError && config.Error != null ? `${baseClass} border-red-400 focus:border-red-500 focus:ring-red-500/30` : `${baseClass} ${vitalStatus === "critical" ? "border-red-300 focus:border-red-500 focus:ring-red-500/30" : vitalStatus === "abnormal" ? "border-amber-300 focus:border-amber-500 focus:ring-amber-500/30" : "border-slate-300 focus:border-sky-500 focus:ring-sky-500/30"}`;
|
|
@@ -546,9 +263,9 @@ function VitalsField_VitalsFieldComponent(config) {
|
|
|
546
263
|
"className",
|
|
547
264
|
"grid grid-cols-1 auto-rows-min content-start items-start gap-2 md:grid-cols-2 lg:grid-cols-3"
|
|
548
265
|
],
|
|
549
|
-
(elems_8 = (0, _Seq.toList)((0, _Seq.delay)(()=>(0, _Seq.append)(vitalsConfig.IncludeTemperature ? (0, _Seq.singleton)(createVitalInput("Temperature", temperature, patternInput[1], "Normal: 97-99°F", "98.6",
|
|
266
|
+
(elems_8 = (0, _Seq.toList)((0, _Seq.delay)(()=>(0, _Seq.append)(vitalsConfig.IncludeTemperature ? (0, _Seq.singleton)(createVitalInput("Temperature", temperature, patternInput[1], "Normal: 97-99°F", "98.6", _VitalsLogic.isValidTemperature, _VitalsLogic.isCriticalTemperature, _VitalsLogic.isNormalTemperature)) : (0, _Seq.empty)(), (0, _Seq.delay)(()=>{
|
|
550
267
|
let systolicStatus, diastolicStatus, elems_7, elems_3, elems_2, elems_6, elems_4, value_66, elems_5, value_85;
|
|
551
|
-
return (0, _Seq.append)(vitalsConfig.IncludeBP ? (systolicStatus =
|
|
268
|
+
return (0, _Seq.append)(vitalsConfig.IncludeBP ? (systolicStatus = (0, _VitalsLogic.getVitalStatus)(parseNumeric(systolicBP), _VitalsLogic.isValidSystolicBP, _VitalsLogic.isCriticalSystolicBP, undefined), diastolicStatus = (0, _VitalsLogic.getVitalStatus)(parseNumeric(diastolicBP), _VitalsLogic.isValidDiastolicBP, _VitalsLogic.isCriticalDiastolicBP, undefined), (0, _Seq.singleton)((0, _react.createElement)("div", (0, _Util.createObj)((0, _List.ofArray)([
|
|
552
269
|
[
|
|
553
270
|
"className",
|
|
554
271
|
"rounded-lg border border-slate-200 bg-white p-2.5 shadow-sm"
|
|
@@ -679,7 +396,7 @@ function VitalsField_VitalsFieldComponent(config) {
|
|
|
679
396
|
"children",
|
|
680
397
|
_Interopfs.reactApi.Children.toArray(Array.from(elems_7))
|
|
681
398
|
])
|
|
682
|
-
]))))) : (0, _Seq.empty)(), (0, _Seq.delay)(()=>(0, _Seq.append)(vitalsConfig.IncludePulse ? (0, _Seq.singleton)(createVitalInput("Pulse Rate", pulse, patternInput_3[1], "BPM", "72",
|
|
399
|
+
]))))) : (0, _Seq.empty)(), (0, _Seq.delay)(()=>(0, _Seq.append)(vitalsConfig.IncludePulse ? (0, _Seq.singleton)(createVitalInput("Pulse Rate", pulse, patternInput_3[1], "BPM", "72", _VitalsLogic.isValidPulse, _VitalsLogic.isCriticalPulse, undefined)) : (0, _Seq.empty)(), (0, _Seq.delay)(()=>(0, _Seq.append)(vitalsConfig.IncludeRespiration ? (0, _Seq.singleton)(createVitalInput("Respiration Rate", respiration, patternInput_4[1], "per minute", "16", _VitalsLogic.isValidRespiration, _VitalsLogic.isCriticalRespiration, undefined)) : (0, _Seq.empty)(), (0, _Seq.delay)(()=>(0, _Seq.append)(vitalsConfig.IncludeOxygenSat ? (0, _Seq.singleton)(createVitalInput("Oxygen Saturation", oxygenSat, patternInput_5[1], "%", "98", _VitalsLogic.isValidOxygenSat, _VitalsLogic.isCriticalOxygenSat, undefined)) : (0, _Seq.empty)(), (0, _Seq.delay)(()=>vitalsConfig.IncludePainScale ? (0, _Seq.singleton)(createVitalInput("Pain Scale", painScale, patternInput_6[1], "0-10 scale", "0", _VitalsLogic.isValidPainScale, (_arg)=>false, undefined)) : (0, _Seq.empty)()))))))));
|
|
683
400
|
})))), [
|
|
684
401
|
"children",
|
|
685
402
|
_Interopfs.reactApi.Children.toArray(Array.from(elems_8))
|
|
@@ -810,10 +527,10 @@ const Form_enhancedVitalsConverter = new _PluginInterface.IPluginValueConverter(
|
|
|
810
527
|
return undefined;
|
|
811
528
|
}
|
|
812
529
|
}, (0, _List.tryFind)((p)=>p.Name === name, properties));
|
|
813
|
-
return (0, _Option.some)(new
|
|
530
|
+
return (0, _Option.some)(new _VitalsLogic.VitalsData(getPropertyValue("temperature"), getPropertyValue("systolic_bp"), getPropertyValue("diastolic_bp"), getPropertyValue("pulse"), getPropertyValue("respiration"), getPropertyValue("oxygen_saturation"), getPropertyValue("pain_scale")));
|
|
814
531
|
}
|
|
815
532
|
case /* Single */ 0:
|
|
816
|
-
return (0, _Option.some)(
|
|
533
|
+
return (0, _Option.some)((0, _VitalsLogic.parseVitalsData)(fieldValue.fields[0].Value));
|
|
817
534
|
default:
|
|
818
535
|
return undefined;
|
|
819
536
|
}
|
|
@@ -831,7 +548,7 @@ const Form_enhancedVitalsConverter = new _PluginInterface.IPluginValueConverter(
|
|
|
831
548
|
return (0, _List.tryFind)((p_2)=>p_2.Name === propertyName_1, fieldValue_1.fields[0]);
|
|
832
549
|
case /* Single */ 0:
|
|
833
550
|
{
|
|
834
|
-
const vitalsData_1 =
|
|
551
|
+
const vitalsData_1 = (0, _VitalsLogic.parseVitalsData)(fieldValue_1.fields[0].Value);
|
|
835
552
|
return propertyName_1 === "temperature" ? (0, _Option.map)((v_1)=>new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_Temperature, "temperature", "float", v_1.toString(), "Temperature", "°F", "Body temperature in Fahrenheit"), vitalsData_1.Temperature) : propertyName_1 === "systolic_bp" ? (0, _Option.map)((v_2)=>new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_SystolicBP, "systolic_bp", "float", v_2.toString(), "Systolic BP", "mmHg", "Systolic blood pressure"), vitalsData_1.SystolicBP) : propertyName_1 === "diastolic_bp" ? (0, _Option.map)((v_3)=>new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_DiastolicBP, "diastolic_bp", "float", v_3.toString(), "Diastolic BP", "mmHg", "Diastolic blood pressure"), vitalsData_1.DiastolicBP) : propertyName_1 === "pulse" ? (0, _Option.map)((v_4)=>new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_Pulse, "pulse", "float", v_4.toString(), "Pulse Rate", "BPM", "Heart rate in beats per minute"), vitalsData_1.Pulse) : propertyName_1 === "respiration" ? (0, _Option.map)((v_5)=>new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_Respiration, "respiration", "float", v_5.toString(), "Respiration Rate", "RPM", "Respiratory rate per minute"), vitalsData_1.Respiration) : propertyName_1 === "oxygen_saturation" ? (0, _Option.map)((v_6)=>new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_OxygenSaturation, "oxygen_saturation", "float", v_6.toString(), "O2 Saturation", "%", "Oxygen saturation percentage"), vitalsData_1.OxygenSaturation) : propertyName_1 === "pain_scale" ? (0, _Option.map)((v_7)=>new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_PainScale, "pain_scale", "float", v_7.toString(), "Pain Level", "/10", "Pain scale from 0 to 10"), vitalsData_1.PainScale) : undefined;
|
|
836
553
|
}
|
|
837
554
|
default:
|
|
@@ -843,7 +560,7 @@ const Form_enhancedVitalsConverter = new _PluginInterface.IPluginValueConverter(
|
|
|
843
560
|
return (0, _List.tryFind)((p_3)=>(0, _Util.equals)(p_3.PropertyKey, propertyKey_1), fieldValue_2.fields[0]);
|
|
844
561
|
case /* Single */ 0:
|
|
845
562
|
{
|
|
846
|
-
const vitalsData_2 =
|
|
563
|
+
const vitalsData_2 = (0, _VitalsLogic.parseVitalsData)(fieldValue_2.fields[0].Value);
|
|
847
564
|
return (0, _Util.equals)(propertyKey_1, Form_PropertyKeys_Temperature) ? (0, _Option.map)((v_8)=>new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_Temperature, "temperature", "float", v_8.toString(), "Temperature", "°F", "Body temperature in Fahrenheit"), vitalsData_2.Temperature) : (0, _Util.equals)(propertyKey_1, Form_PropertyKeys_SystolicBP) ? (0, _Option.map)((v_9)=>new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_SystolicBP, "systolic_bp", "float", v_9.toString(), "Systolic BP", "mmHg", "Systolic blood pressure"), vitalsData_2.SystolicBP) : (0, _Util.equals)(propertyKey_1, Form_PropertyKeys_DiastolicBP) ? (0, _Option.map)((v_10)=>new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_DiastolicBP, "diastolic_bp", "float", v_10.toString(), "Diastolic BP", "mmHg", "Diastolic blood pressure"), vitalsData_2.DiastolicBP) : (0, _Util.equals)(propertyKey_1, Form_PropertyKeys_Pulse) ? (0, _Option.map)((v_11)=>new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_Pulse, "pulse", "float", v_11.toString(), "Pulse Rate", "BPM", "Heart rate in beats per minute"), vitalsData_2.Pulse) : (0, _Util.equals)(propertyKey_1, Form_PropertyKeys_Respiration) ? (0, _Option.map)((v_12)=>new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_Respiration, "respiration", "float", v_12.toString(), "Respiration Rate", "RPM", "Respiratory rate per minute"), vitalsData_2.Respiration) : (0, _Util.equals)(propertyKey_1, Form_PropertyKeys_OxygenSaturation) ? (0, _Option.map)((v_13)=>new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_OxygenSaturation, "oxygen_saturation", "float", v_13.toString(), "O2 Saturation", "%", "Oxygen saturation percentage"), vitalsData_2.OxygenSaturation) : (0, _Util.equals)(propertyKey_1, Form_PropertyKeys_PainScale) ? (0, _Option.map)((v_14)=>new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_PainScale, "pain_scale", "float", v_14.toString(), "Pain Level", "/10", "Pain scale from 0 to 10"), vitalsData_2.PainScale) : undefined;
|
|
848
565
|
}
|
|
849
566
|
default:
|
|
@@ -861,7 +578,7 @@ const Form_enhancedVitalsConverter = new _PluginInterface.IPluginValueConverter(
|
|
|
861
578
|
})),
|
|
862
579
|
outArg_1
|
|
863
580
|
];
|
|
864
|
-
return matchValue_1[0] ?
|
|
581
|
+
return matchValue_1[0] ? (0, _VitalsLogic.isValidTemperature)(matchValue_1[1]) ? (0, _Result.FSharpResult$2_Ok)(undefined) : (0, _Result.FSharpResult$2_Error)("Temperature must be between 95-108°F, got " + matchValue_1[1].toString() + "°F") : (0, _Result.FSharpResult$2_Error)("Temperature must be a valid number");
|
|
865
582
|
}
|
|
866
583
|
case "systolic_bp":
|
|
867
584
|
{
|
|
@@ -873,7 +590,7 @@ const Form_enhancedVitalsConverter = new _PluginInterface.IPluginValueConverter(
|
|
|
873
590
|
})),
|
|
874
591
|
outArg_2
|
|
875
592
|
];
|
|
876
|
-
return matchValue_2[0] ?
|
|
593
|
+
return matchValue_2[0] ? (0, _VitalsLogic.isValidSystolicBP)(matchValue_2[1]) ? (0, _Result.FSharpResult$2_Ok)(undefined) : (0, _Result.FSharpResult$2_Error)("Systolic BP must be between 60-200 mmHg, got " + matchValue_2[1].toString()) : (0, _Result.FSharpResult$2_Error)("Systolic BP must be a valid number");
|
|
877
594
|
}
|
|
878
595
|
case "diastolic_bp":
|
|
879
596
|
{
|
|
@@ -885,7 +602,7 @@ const Form_enhancedVitalsConverter = new _PluginInterface.IPluginValueConverter(
|
|
|
885
602
|
})),
|
|
886
603
|
outArg_3
|
|
887
604
|
];
|
|
888
|
-
return matchValue_3[0] ?
|
|
605
|
+
return matchValue_3[0] ? (0, _VitalsLogic.isValidDiastolicBP)(matchValue_3[1]) ? (0, _Result.FSharpResult$2_Ok)(undefined) : (0, _Result.FSharpResult$2_Error)("Diastolic BP must be between 40-120 mmHg, got " + matchValue_3[1].toString()) : (0, _Result.FSharpResult$2_Error)("Diastolic BP must be a valid number");
|
|
889
606
|
}
|
|
890
607
|
case "pulse":
|
|
891
608
|
{
|
|
@@ -897,7 +614,7 @@ const Form_enhancedVitalsConverter = new _PluginInterface.IPluginValueConverter(
|
|
|
897
614
|
})),
|
|
898
615
|
outArg_4
|
|
899
616
|
];
|
|
900
|
-
return matchValue_4[0] ?
|
|
617
|
+
return matchValue_4[0] ? (0, _VitalsLogic.isValidPulse)(matchValue_4[1]) ? (0, _Result.FSharpResult$2_Ok)(undefined) : (0, _Result.FSharpResult$2_Error)("Pulse must be between 40-180 BPM, got " + matchValue_4[1].toString()) : (0, _Result.FSharpResult$2_Error)("Pulse must be a valid number");
|
|
901
618
|
}
|
|
902
619
|
case "respiration":
|
|
903
620
|
{
|
|
@@ -909,7 +626,7 @@ const Form_enhancedVitalsConverter = new _PluginInterface.IPluginValueConverter(
|
|
|
909
626
|
})),
|
|
910
627
|
outArg_5
|
|
911
628
|
];
|
|
912
|
-
return matchValue_5[0] ?
|
|
629
|
+
return matchValue_5[0] ? (0, _VitalsLogic.isValidRespiration)(matchValue_5[1]) ? (0, _Result.FSharpResult$2_Ok)(undefined) : (0, _Result.FSharpResult$2_Error)("Respiration rate must be between 8-35 RPM, got " + matchValue_5[1].toString()) : (0, _Result.FSharpResult$2_Error)("Respiration rate must be a valid number");
|
|
913
630
|
}
|
|
914
631
|
case "oxygen_saturation":
|
|
915
632
|
{
|
|
@@ -921,7 +638,7 @@ const Form_enhancedVitalsConverter = new _PluginInterface.IPluginValueConverter(
|
|
|
921
638
|
})),
|
|
922
639
|
outArg_6
|
|
923
640
|
];
|
|
924
|
-
return matchValue_6[0] ?
|
|
641
|
+
return matchValue_6[0] ? (0, _VitalsLogic.isValidOxygenSat)(matchValue_6[1]) ? (0, _Result.FSharpResult$2_Ok)(undefined) : (0, _Result.FSharpResult$2_Error)("Oxygen saturation must be between 70-100%, got " + matchValue_6[1].toString() + "%") : (0, _Result.FSharpResult$2_Error)("Oxygen saturation must be a valid number");
|
|
925
642
|
}
|
|
926
643
|
case "pain_scale":
|
|
927
644
|
{
|
|
@@ -933,7 +650,7 @@ const Form_enhancedVitalsConverter = new _PluginInterface.IPluginValueConverter(
|
|
|
933
650
|
})),
|
|
934
651
|
outArg_7
|
|
935
652
|
];
|
|
936
|
-
return matchValue_7[0] ?
|
|
653
|
+
return matchValue_7[0] ? (0, _VitalsLogic.isValidPainScale)(matchValue_7[1]) ? (0, _Result.FSharpResult$2_Ok)(undefined) : (0, _Result.FSharpResult$2_Error)("Pain scale must be between 0-10, got " + matchValue_7[1].toString()) : (0, _Result.FSharpResult$2_Error)("Pain scale must be a valid number");
|
|
937
654
|
}
|
|
938
655
|
default:
|
|
939
656
|
return (0, _Result.FSharpResult$2_Error)("Unknown property: " + propertyName_2);
|
|
@@ -944,7 +661,7 @@ const Form_enhancedVitalsConverter = new _PluginInterface.IPluginValueConverter(
|
|
|
944
661
|
return fieldValue_3.fields[0];
|
|
945
662
|
case /* Single */ 0:
|
|
946
663
|
{
|
|
947
|
-
const vitalsData_3 =
|
|
664
|
+
const vitalsData_3 = (0, _VitalsLogic.parseVitalsData)(fieldValue_3.fields[0].Value);
|
|
948
665
|
return (0, _Seq.toList)((0, _Seq.delay)(()=>(0, _Seq.append)(vitalsData_3.Temperature != null ? (0, _Seq.singleton)(new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_Temperature, "temperature", "float", (0, _Option.value)(vitalsData_3.Temperature).toString(), "Temperature", "°F", "Body temperature in Fahrenheit")) : (0, _Seq.empty)(), (0, _Seq.delay)(()=>(0, _Seq.append)(vitalsData_3.SystolicBP != null ? (0, _Seq.singleton)(new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_SystolicBP, "systolic_bp", "float", (0, _Option.value)(vitalsData_3.SystolicBP).toString(), "Systolic BP", "mmHg", "Systolic blood pressure")) : (0, _Seq.empty)(), (0, _Seq.delay)(()=>(0, _Seq.append)(vitalsData_3.DiastolicBP != null ? (0, _Seq.singleton)(new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_DiastolicBP, "diastolic_bp", "float", (0, _Option.value)(vitalsData_3.DiastolicBP).toString(), "Diastolic BP", "mmHg", "Diastolic blood pressure")) : (0, _Seq.empty)(), (0, _Seq.delay)(()=>(0, _Seq.append)(vitalsData_3.Pulse != null ? (0, _Seq.singleton)(new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_Pulse, "pulse", "float", (0, _Option.value)(vitalsData_3.Pulse).toString(), "Pulse Rate", "BPM", "Heart rate in beats per minute")) : (0, _Seq.empty)(), (0, _Seq.delay)(()=>(0, _Seq.append)(vitalsData_3.Respiration != null ? (0, _Seq.singleton)(new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_Respiration, "respiration", "float", (0, _Option.value)(vitalsData_3.Respiration).toString(), "Respiration Rate", "RPM", "Respiratory rate per minute")) : (0, _Seq.empty)(), (0, _Seq.delay)(()=>(0, _Seq.append)(vitalsData_3.OxygenSaturation != null ? (0, _Seq.singleton)(new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_OxygenSaturation, "oxygen_saturation", "float", (0, _Option.value)(vitalsData_3.OxygenSaturation).toString(), "O2 Saturation", "%", "Oxygen saturation percentage")) : (0, _Seq.empty)(), (0, _Seq.delay)(()=>vitalsData_3.PainScale != null ? (0, _Seq.singleton)(new _FormSpec.Shared_PluginDataProperty(Form_PropertyKeys_PainScale, "pain_scale", "float", (0, _Option.value)(vitalsData_3.PainScale).toString(), "Pain Level", "/10", "Pain scale from 0 to 10")) : (0, _Seq.empty)()))))))))))))));
|
|
949
666
|
}
|
|
950
667
|
default:
|
|
@@ -1086,7 +803,7 @@ function Form_markdownRenderer(field, fieldDetails) {
|
|
|
1086
803
|
return `**${field.Label}:** *[No vital signs recorded]*`;
|
|
1087
804
|
} else {
|
|
1088
805
|
try {
|
|
1089
|
-
const vitalsData =
|
|
806
|
+
const vitalsData = (0, _VitalsLogic.parseVitalsData)(value);
|
|
1090
807
|
if ((0, _List.exists)((option)=>option != null, (0, _List.ofArray)([
|
|
1091
808
|
vitalsData.Temperature,
|
|
1092
809
|
vitalsData.SystolicBP,
|
|
@@ -1104,28 +821,28 @@ function Form_markdownRenderer(field, fieldDetails) {
|
|
|
1104
821
|
]);
|
|
1105
822
|
if (vitalsData.Temperature != null) {
|
|
1106
823
|
const temp = (0, _Option.value)(vitalsData.Temperature);
|
|
1107
|
-
const status =
|
|
824
|
+
const status = (0, _VitalsLogic.isCriticalTemperature)(temp) ? "🚨 CRITICAL" : !(0, _VitalsLogic.isValidTemperature)(temp) ? "⚠️ ABNORMAL" : !(0, _VitalsLogic.isNormalTemperature)(temp) ? "⚠️ ABNORMAL" : "✅ Normal";
|
|
1108
825
|
rows = (0, _List.append)(rows, (0, _List.singleton)("| **Temperature** | " + (0, _String.toText)((0, _String.printf)("%.1f"))(temp) + "°F | " + status + " |"));
|
|
1109
826
|
}
|
|
1110
827
|
if (vitalsData.SystolicBP != null && vitalsData.DiastolicBP != null) {
|
|
1111
828
|
const sys = (0, _Option.value)(vitalsData.SystolicBP);
|
|
1112
829
|
const dia = (0, _Option.value)(vitalsData.DiastolicBP);
|
|
1113
|
-
const status_1 = (
|
|
830
|
+
const status_1 = ((0, _VitalsLogic.isCriticalSystolicBP)(sys) ? true : (0, _VitalsLogic.isCriticalDiastolicBP)(dia)) ? "🚨 CRITICAL" : (!(0, _VitalsLogic.isValidSystolicBP)(sys) ? true : !(0, _VitalsLogic.isValidDiastolicBP)(dia)) ? "⚠️ ABNORMAL" : "✅ Normal";
|
|
1114
831
|
rows = (0, _List.append)(rows, (0, _List.singleton)("| **Blood Pressure** | " + (0, _String.toText)((0, _String.printf)("%.0f"))(sys) + "/" + (0, _String.toText)((0, _String.printf)("%.0f"))(dia) + " mmHg | " + status_1 + " |"));
|
|
1115
832
|
}
|
|
1116
833
|
if (vitalsData.Pulse != null) {
|
|
1117
834
|
const pulse = (0, _Option.value)(vitalsData.Pulse);
|
|
1118
|
-
const status_2 =
|
|
835
|
+
const status_2 = (0, _VitalsLogic.isCriticalPulse)(pulse) ? "🚨 CRITICAL" : !(0, _VitalsLogic.isValidPulse)(pulse) ? "⚠️ ABNORMAL" : "✅ Normal";
|
|
1119
836
|
rows = (0, _List.append)(rows, (0, _List.singleton)("| **Pulse Rate** | " + (0, _String.toText)((0, _String.printf)("%.0f"))(pulse) + " BPM | " + status_2 + " |"));
|
|
1120
837
|
}
|
|
1121
838
|
if (vitalsData.Respiration != null) {
|
|
1122
839
|
const resp = (0, _Option.value)(vitalsData.Respiration);
|
|
1123
|
-
const status_3 =
|
|
840
|
+
const status_3 = (0, _VitalsLogic.isCriticalRespiration)(resp) ? "🚨 CRITICAL" : !(0, _VitalsLogic.isValidRespiration)(resp) ? "⚠️ ABNORMAL" : "✅ Normal";
|
|
1124
841
|
rows = (0, _List.append)(rows, (0, _List.singleton)("| **Respiration** | " + (0, _String.toText)((0, _String.printf)("%.0f"))(resp) + " RPM | " + status_3 + " |"));
|
|
1125
842
|
}
|
|
1126
843
|
if (vitalsData.OxygenSaturation != null) {
|
|
1127
844
|
const sat = (0, _Option.value)(vitalsData.OxygenSaturation);
|
|
1128
|
-
const status_4 =
|
|
845
|
+
const status_4 = (0, _VitalsLogic.isCriticalOxygenSat)(sat) ? "🚨 CRITICAL" : !(0, _VitalsLogic.isValidOxygenSat)(sat) ? "⚠️ ABNORMAL" : "✅ Normal";
|
|
1129
846
|
rows = (0, _List.append)(rows, (0, _List.singleton)("| **O2 Saturation** | " + (0, _String.toText)((0, _String.printf)("%.0f"))(sat) + "% | " + status_4 + " |"));
|
|
1130
847
|
}
|
|
1131
848
|
if (vitalsData.PainScale != null) {
|