@ovok/native 1.16.1-rc.5 → 1.16.1-rc.7
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/lib/commonjs/modules/auth/google-return-page/index.js +24 -0
- package/lib/commonjs/modules/auth/google-return-page/index.js.map +1 -0
- package/lib/commonjs/modules/auth/hooks/use-social-sign-in.web.js +15 -0
- package/lib/commonjs/modules/auth/hooks/use-social-sign-in.web.js.map +1 -0
- package/lib/commonjs/modules/auth/index.js +21 -10
- package/lib/commonjs/modules/auth/index.js.map +1 -1
- package/lib/commonjs/modules/auth/session/logout-session.js +1 -1
- package/lib/commonjs/modules/auth/sign-in/components/social-logins/apple-login-button.web.js +73 -0
- package/lib/commonjs/modules/auth/sign-in/components/social-logins/apple-login-button.web.js.map +1 -0
- package/lib/commonjs/modules/auth/sign-in/components/social-logins/apple-login.js +1 -1
- package/lib/commonjs/modules/auth/sign-in/components/social-logins/google-login-button.web.js +73 -0
- package/lib/commonjs/modules/auth/sign-in/components/social-logins/google-login-button.web.js.map +1 -0
- package/lib/commonjs/modules/auth/sign-in/components/social-logins/google-login.js +1 -1
- package/lib/commonjs/modules/auth/sign-in/index.js +24 -0
- package/lib/commonjs/modules/auth/sign-in/index.js.map +1 -1
- package/lib/commonjs/modules/auth/sign-in/utils/apple-web-sign-in.js +90 -0
- package/lib/commonjs/modules/auth/sign-in/utils/apple-web-sign-in.js.map +1 -0
- package/lib/commonjs/modules/auth/sign-in/utils/google-redirect-sign-in.js +89 -0
- package/lib/commonjs/modules/auth/sign-in/utils/google-redirect-sign-in.js.map +1 -0
- package/lib/commonjs/modules/auth/sign-in/utils/jwt-claims.js +21 -0
- package/lib/commonjs/modules/auth/sign-in/utils/jwt-claims.js.map +1 -0
- package/lib/commonjs/modules/auth/utils/sign-out-google.web.js +10 -0
- package/lib/commonjs/modules/auth/utils/sign-out-google.web.js.map +1 -0
- package/lib/commonjs/modules/bt-management/components/bt-provider-child-wrapper.js +19 -7
- package/lib/commonjs/modules/bt-management/components/bt-provider-child-wrapper.js.map +1 -1
- package/lib/commonjs/modules/bt-management/hooks/runtime-context.js.map +1 -1
- package/lib/commonjs/modules/bt-management/index.js +12 -0
- package/lib/commonjs/modules/bt-management/index.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/bt-manager.js +27 -1
- package/lib/commonjs/modules/bt-management/services/bt-manager.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/custom/compile-custom-lepu.js +42 -2
- package/lib/commonjs/modules/bt-management/services/custom/compile-custom-lepu.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/blood-glucose/blood-glucose.device.js +64 -44
- package/lib/commonjs/modules/bt-management/services/devices/blood-glucose/blood-glucose.device.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/blood-glucose/telebgm.protocol.js +98 -0
- package/lib/commonjs/modules/bt-management/services/devices/blood-glucose/telebgm.protocol.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/blood-glucose/telebgm.sequencer.js +127 -0
- package/lib/commonjs/modules/bt-management/services/devices/blood-glucose/telebgm.sequencer.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/bp2/bp2.device.js +48 -17
- package/lib/commonjs/modules/bt-management/services/devices/bp2/bp2.device.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/bp2/bp2.frame-reader.js +2 -2
- package/lib/commonjs/modules/bt-management/services/devices/bp2/bp2.frame-reader.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/bp2/bp2.history-sequencer.js +78 -19
- package/lib/commonjs/modules/bt-management/services/devices/bp2/bp2.history-sequencer.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/bt-command-writer.js +30 -2
- package/lib/commonjs/modules/bt-management/services/devices/bt-command-writer.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/bt-data-processor.js +11 -3
- package/lib/commonjs/modules/bt-management/services/devices/bt-data-processor.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/bt-managed-device.js +48 -3
- package/lib/commonjs/modules/bt-management/services/devices/bt-managed-device.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/cofoe/cofoe.records.js +2 -7
- package/lib/commonjs/modules/bt-management/services/devices/cofoe/cofoe.records.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/custom/custom-lepu-sequencer.js +6 -2
- package/lib/commonjs/modules/bt-management/services/devices/custom/custom-lepu-sequencer.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/custom/custom.device.js +115 -26
- package/lib/commonjs/modules/bt-management/services/devices/custom/custom.device.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.advertisement.js +19 -2
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.advertisement.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.connect-retry.js +32 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.connect-retry.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.delivered-files.js +73 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.delivered-files.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.ecg-transfer.js +130 -30
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.ecg-transfer.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.encryption-handshake.js +103 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.encryption-handshake.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.file-transfer.js +20 -14
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.file-transfer.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.frame-reader.js +4 -2
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.frame-reader.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.identity-gate.js +94 -10
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.identity-gate.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.live-ecg-chunks.js +75 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.live-ecg-chunks.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.pulse-wave-chunks.js +113 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.pulse-wave-chunks.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.pulse-wave.js +67 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.pulse-wave.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.recorder.js +55 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.recorder.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.recording-watch.js +57 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.recording-watch.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.session.js +49 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.session.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.stored-files.js +46 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.stored-files.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.transports.js +10 -4
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.transports.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.waveform.js +27 -0
- package/lib/commonjs/modules/bt-management/services/devices/lepu/lepu.waveform.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.bp-monitors.js +0 -1
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.bp-monitors.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.ecg-files.js +75 -20
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.ecg-files.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.ecg-recorders.js +21 -12
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.ecg-recorders.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.ecg-recording-status.js +47 -0
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.ecg-recording-status.js.map +1 -0
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.oximeters.js +58 -32
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.oximeters.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.wbp02.protocol.js +3 -7
- package/lib/commonjs/modules/bt-management/services/devices/viatom/viatom.wbp02.protocol.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/series-recorder.js +27 -5
- package/lib/commonjs/modules/bt-management/services/series-recorder.js.map +1 -1
- package/lib/commonjs/modules/bt-management/types/device-waveform.js +6 -0
- package/lib/commonjs/modules/bt-management/types/device-waveform.js.map +1 -0
- package/lib/commonjs/modules/bt-management/utils/calculate-crc-16-modbus.js +23 -0
- package/lib/commonjs/modules/bt-management/utils/calculate-crc-16-modbus.js.map +1 -0
- package/lib/commonjs/modules/bt-management/utils/i-16-from-hex.js.map +1 -1
- package/lib/commonjs/modules/bt-management/utils/le-32-from-hex.js.map +1 -1
- package/lib/commonjs/modules/bt-management/utils/tenths-mmol-to-mg-per-dl.js +13 -0
- package/lib/commonjs/modules/bt-management/utils/tenths-mmol-to-mg-per-dl.js.map +1 -0
- package/lib/commonjs/modules/data-sync/components/apple/apple-health-authorization-provider.js +15 -8
- package/lib/commonjs/modules/data-sync/components/apple/apple-health-authorization-provider.js.map +1 -1
- package/lib/commonjs/modules/data-sync/components/apple/apple-health-authorization-utils.js +1 -1
- package/lib/commonjs/modules/data-sync/components/apple/apple-health-authorization-utils.js.map +1 -1
- package/lib/commonjs/modules/data-sync/constants.js +4 -1
- package/lib/commonjs/modules/data-sync/constants.js.map +1 -1
- package/lib/commonjs/modules/data-sync/hooks/use-listen-changes.js +6 -9
- package/lib/commonjs/modules/data-sync/hooks/use-listen-changes.js.map +1 -1
- package/lib/commonjs/modules/data-sync/services/managers/data-processor.js +8 -7
- package/lib/commonjs/modules/data-sync/services/managers/data-processor.js.map +1 -1
- package/lib/commonjs/modules/data-sync/types/health-sync-keys.js +13 -0
- package/lib/commonjs/modules/data-sync/types/health-sync-keys.js.map +1 -1
- package/lib/commonjs/modules/data-sync/utils/convert-ecg-samples-to-observation.js +47 -0
- package/lib/commonjs/modules/data-sync/utils/convert-ecg-samples-to-observation.js.map +1 -0
- package/lib/commonjs/modules/data-sync/utils/convert-generic-health-data.js +14 -6
- package/lib/commonjs/modules/data-sync/utils/convert-generic-health-data.js.map +1 -1
- package/lib/commonjs/modules/data-sync/utils/convert-samples-to-observation.js +7 -15
- package/lib/commonjs/modules/data-sync/utils/convert-samples-to-observation.js.map +1 -1
- package/lib/commonjs/modules/data-sync/utils/default-health-coding.js +68 -0
- package/lib/commonjs/modules/data-sync/utils/default-health-coding.js.map +1 -0
- package/lib/commonjs/modules/data-sync/utils/get-records-from-health-connect.js +20 -4
- package/lib/commonjs/modules/data-sync/utils/get-records-from-health-connect.js.map +1 -1
- package/lib/commonjs/modules/data-sync/utils/get-samples-from-health.js +43 -86
- package/lib/commonjs/modules/data-sync/utils/get-samples-from-health.js.map +1 -1
- package/lib/commonjs/modules/data-sync/utils/get-total-samples-count.js +6 -5
- package/lib/commonjs/modules/data-sync/utils/get-total-samples-count.js.map +1 -1
- package/lib/commonjs/modules/data-sync/utils/health-data-catalog.js +15 -15
- package/lib/commonjs/modules/data-sync/utils/health-data-catalog.js.map +1 -1
- package/lib/commonjs/modules/data-sync/utils/health-units.js +11 -1
- package/lib/commonjs/modules/data-sync/utils/health-units.js.map +1 -1
- package/lib/commonjs/modules/data-sync/utils/healthkit-daily-statistics.js +64 -0
- package/lib/commonjs/modules/data-sync/utils/healthkit-daily-statistics.js.map +1 -0
- package/lib/commonjs/modules/data-sync/utils/healthkit-data-types.js.map +1 -1
- package/lib/commonjs/modules/data-sync/utils/healthkit-query-options.js +20 -0
- package/lib/commonjs/modules/data-sync/utils/healthkit-query-options.js.map +1 -0
- package/lib/commonjs/modules/data-sync/utils/healthkit-sample-source.js +21 -0
- package/lib/commonjs/modules/data-sync/utils/healthkit-sample-source.js.map +1 -0
- package/lib/commonjs/modules/data-sync/utils/healthkit-samples.js +59 -0
- package/lib/commonjs/modules/data-sync/utils/healthkit-samples.js.map +1 -0
- package/lib/commonjs/modules/data-sync/utils/healthkit-series.js +20 -11
- package/lib/commonjs/modules/data-sync/utils/healthkit-series.js.map +1 -1
- package/lib/commonjs/modules/next/bluetooth/ble-plx/built-in-devices.js +12 -2
- package/lib/commonjs/modules/next/bluetooth/ble-plx/built-in-devices.js.map +1 -1
- package/lib/commonjs/modules/next/bluetooth/ble-plx/legacy-driver.js +39 -5
- package/lib/commonjs/modules/next/bluetooth/ble-plx/legacy-driver.js.map +1 -1
- package/lib/commonjs/modules/next/bluetooth/connections.js +45 -2
- package/lib/commonjs/modules/next/bluetooth/connections.js.map +1 -1
- package/lib/commonjs/modules/next/bluetooth/driver.js.map +1 -1
- package/lib/commonjs/modules/next/bluetooth/errors.js.map +1 -1
- package/lib/commonjs/modules/next/bluetooth/index.js.map +1 -1
- package/lib/commonjs/modules/next/bluetooth/readings.js +10 -2
- package/lib/commonjs/modules/next/bluetooth/readings.js.map +1 -1
- package/lib/commonjs/modules/next/bluetooth/runtime.js +37 -1
- package/lib/commonjs/modules/next/bluetooth/runtime.js.map +1 -1
- package/lib/commonjs/modules/next/bluetooth/web/index.js.map +1 -1
- package/lib/module/modules/auth/google-return-page/index.js +21 -0
- package/lib/module/modules/auth/google-return-page/index.js.map +1 -0
- package/lib/module/modules/auth/hooks/use-social-sign-in.web.js +10 -0
- package/lib/module/modules/auth/hooks/use-social-sign-in.web.js.map +1 -0
- package/lib/module/modules/auth/index.js +2 -1
- package/lib/module/modules/auth/index.js.map +1 -1
- package/lib/module/modules/auth/session/logout-session.js +1 -1
- package/lib/module/modules/auth/session/logout-session.js.map +1 -1
- package/lib/module/modules/auth/sign-in/components/social-logins/apple-login-button.web.js +67 -0
- package/lib/module/modules/auth/sign-in/components/social-logins/apple-login-button.web.js.map +1 -0
- package/lib/module/modules/auth/sign-in/components/social-logins/apple-login.js +1 -1
- package/lib/module/modules/auth/sign-in/components/social-logins/apple-login.js.map +1 -1
- package/lib/module/modules/auth/sign-in/components/social-logins/google-login-button.web.js +68 -0
- package/lib/module/modules/auth/sign-in/components/social-logins/google-login-button.web.js.map +1 -0
- package/lib/module/modules/auth/sign-in/components/social-logins/google-login.js +1 -1
- package/lib/module/modules/auth/sign-in/components/social-logins/google-login.js.map +1 -1
- package/lib/module/modules/auth/sign-in/index.js +2 -0
- package/lib/module/modules/auth/sign-in/index.js.map +1 -1
- package/lib/module/modules/auth/sign-in/utils/apple-web-sign-in.js +84 -0
- package/lib/module/modules/auth/sign-in/utils/apple-web-sign-in.js.map +1 -0
- package/lib/module/modules/auth/sign-in/utils/google-redirect-sign-in.js +84 -0
- package/lib/module/modules/auth/sign-in/utils/google-redirect-sign-in.js.map +1 -0
- package/lib/module/modules/auth/sign-in/utils/jwt-claims.js +17 -0
- package/lib/module/modules/auth/sign-in/utils/jwt-claims.js.map +1 -0
- package/lib/module/modules/auth/utils/sign-out-google.web.js +5 -0
- package/lib/module/modules/auth/utils/sign-out-google.web.js.map +1 -0
- package/lib/module/modules/bt-management/components/bt-provider-child-wrapper.js +19 -7
- package/lib/module/modules/bt-management/components/bt-provider-child-wrapper.js.map +1 -1
- package/lib/module/modules/bt-management/hooks/runtime-context.js.map +1 -1
- package/lib/module/modules/bt-management/index.js +1 -0
- package/lib/module/modules/bt-management/index.js.map +1 -1
- package/lib/module/modules/bt-management/services/bt-manager.js +27 -1
- package/lib/module/modules/bt-management/services/bt-manager.js.map +1 -1
- package/lib/module/modules/bt-management/services/custom/compile-custom-lepu.js +42 -2
- package/lib/module/modules/bt-management/services/custom/compile-custom-lepu.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/blood-glucose/blood-glucose.device.js +64 -44
- package/lib/module/modules/bt-management/services/devices/blood-glucose/blood-glucose.device.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/blood-glucose/telebgm.protocol.js +91 -0
- package/lib/module/modules/bt-management/services/devices/blood-glucose/telebgm.protocol.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/blood-glucose/telebgm.sequencer.js +123 -0
- package/lib/module/modules/bt-management/services/devices/blood-glucose/telebgm.sequencer.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/bp2/bp2.device.js +48 -17
- package/lib/module/modules/bt-management/services/devices/bp2/bp2.device.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/bp2/bp2.frame-reader.js +2 -3
- package/lib/module/modules/bt-management/services/devices/bp2/bp2.frame-reader.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/bp2/bp2.history-sequencer.js +77 -19
- package/lib/module/modules/bt-management/services/devices/bp2/bp2.history-sequencer.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/bt-command-writer.js +30 -2
- package/lib/module/modules/bt-management/services/devices/bt-command-writer.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/bt-data-processor.js +11 -3
- package/lib/module/modules/bt-management/services/devices/bt-data-processor.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/bt-managed-device.js +48 -3
- package/lib/module/modules/bt-management/services/devices/bt-managed-device.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/cofoe/cofoe.records.js +2 -7
- package/lib/module/modules/bt-management/services/devices/cofoe/cofoe.records.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/custom/custom-lepu-sequencer.js +6 -2
- package/lib/module/modules/bt-management/services/devices/custom/custom-lepu-sequencer.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/custom/custom.device.js +115 -26
- package/lib/module/modules/bt-management/services/devices/custom/custom.device.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.advertisement.js +17 -1
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.advertisement.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.connect-retry.js +28 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.connect-retry.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.delivered-files.js +69 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.delivered-files.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.ecg-transfer.js +129 -30
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.ecg-transfer.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.encryption-handshake.js +99 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.encryption-handshake.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.file-transfer.js +20 -14
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.file-transfer.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.frame-reader.js +4 -2
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.frame-reader.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.identity-gate.js +94 -10
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.identity-gate.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.live-ecg-chunks.js +72 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.live-ecg-chunks.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.pulse-wave-chunks.js +109 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.pulse-wave-chunks.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.pulse-wave.js +64 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.pulse-wave.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.recorder.js +51 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.recorder.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.recording-watch.js +53 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.recording-watch.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.session.js +45 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.session.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.stored-files.js +42 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.stored-files.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.transports.js +10 -4
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.transports.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.waveform.js +22 -0
- package/lib/module/modules/bt-management/services/devices/lepu/lepu.waveform.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.bp-monitors.js +0 -1
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.bp-monitors.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.ecg-files.js +75 -21
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.ecg-files.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.ecg-recorders.js +21 -12
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.ecg-recorders.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.ecg-recording-status.js +44 -0
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.ecg-recording-status.js.map +1 -0
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.oximeters.js +58 -32
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.oximeters.js.map +1 -1
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.wbp02.protocol.js +3 -7
- package/lib/module/modules/bt-management/services/devices/viatom/viatom.wbp02.protocol.js.map +1 -1
- package/lib/module/modules/bt-management/services/series-recorder.js +27 -5
- package/lib/module/modules/bt-management/services/series-recorder.js.map +1 -1
- package/lib/module/modules/bt-management/types/device-waveform.js +4 -0
- package/lib/module/modules/bt-management/types/device-waveform.js.map +1 -0
- package/lib/module/modules/bt-management/utils/calculate-crc-16-modbus.js +18 -0
- package/lib/module/modules/bt-management/utils/calculate-crc-16-modbus.js.map +1 -0
- package/lib/module/modules/bt-management/utils/i-16-from-hex.js.map +1 -1
- package/lib/module/modules/bt-management/utils/le-32-from-hex.js.map +1 -1
- package/lib/module/modules/bt-management/utils/tenths-mmol-to-mg-per-dl.js +8 -0
- package/lib/module/modules/bt-management/utils/tenths-mmol-to-mg-per-dl.js.map +1 -0
- package/lib/module/modules/data-sync/components/apple/apple-health-authorization-provider.js +16 -9
- package/lib/module/modules/data-sync/components/apple/apple-health-authorization-provider.js.map +1 -1
- package/lib/module/modules/data-sync/components/apple/apple-health-authorization-utils.js +2 -2
- package/lib/module/modules/data-sync/components/apple/apple-health-authorization-utils.js.map +1 -1
- package/lib/module/modules/data-sync/constants.js +4 -1
- package/lib/module/modules/data-sync/constants.js.map +1 -1
- package/lib/module/modules/data-sync/hooks/use-listen-changes.js +7 -10
- package/lib/module/modules/data-sync/hooks/use-listen-changes.js.map +1 -1
- package/lib/module/modules/data-sync/services/managers/data-processor.js +8 -7
- package/lib/module/modules/data-sync/services/managers/data-processor.js.map +1 -1
- package/lib/module/modules/data-sync/types/health-sync-keys.js +13 -0
- package/lib/module/modules/data-sync/types/health-sync-keys.js.map +1 -1
- package/lib/module/modules/data-sync/utils/convert-ecg-samples-to-observation.js +43 -0
- package/lib/module/modules/data-sync/utils/convert-ecg-samples-to-observation.js.map +1 -0
- package/lib/module/modules/data-sync/utils/convert-generic-health-data.js +14 -6
- package/lib/module/modules/data-sync/utils/convert-generic-health-data.js.map +1 -1
- package/lib/module/modules/data-sync/utils/convert-samples-to-observation.js +7 -15
- package/lib/module/modules/data-sync/utils/convert-samples-to-observation.js.map +1 -1
- package/lib/module/modules/data-sync/utils/default-health-coding.js +65 -0
- package/lib/module/modules/data-sync/utils/default-health-coding.js.map +1 -0
- package/lib/module/modules/data-sync/utils/get-records-from-health-connect.js +20 -4
- package/lib/module/modules/data-sync/utils/get-records-from-health-connect.js.map +1 -1
- package/lib/module/modules/data-sync/utils/get-samples-from-health.js +44 -87
- package/lib/module/modules/data-sync/utils/get-samples-from-health.js.map +1 -1
- package/lib/module/modules/data-sync/utils/get-total-samples-count.js +5 -4
- package/lib/module/modules/data-sync/utils/get-total-samples-count.js.map +1 -1
- package/lib/module/modules/data-sync/utils/health-data-catalog.js +15 -15
- package/lib/module/modules/data-sync/utils/health-data-catalog.js.map +1 -1
- package/lib/module/modules/data-sync/utils/health-units.js +11 -1
- package/lib/module/modules/data-sync/utils/health-units.js.map +1 -1
- package/lib/module/modules/data-sync/utils/healthkit-daily-statistics.js +59 -0
- package/lib/module/modules/data-sync/utils/healthkit-daily-statistics.js.map +1 -0
- package/lib/module/modules/data-sync/utils/healthkit-data-types.js.map +1 -1
- package/lib/module/modules/data-sync/utils/healthkit-query-options.js +16 -0
- package/lib/module/modules/data-sync/utils/healthkit-query-options.js.map +1 -0
- package/lib/module/modules/data-sync/utils/healthkit-sample-source.js +17 -0
- package/lib/module/modules/data-sync/utils/healthkit-sample-source.js.map +1 -0
- package/lib/module/modules/data-sync/utils/healthkit-samples.js +52 -0
- package/lib/module/modules/data-sync/utils/healthkit-samples.js.map +1 -0
- package/lib/module/modules/data-sync/utils/healthkit-series.js +19 -10
- package/lib/module/modules/data-sync/utils/healthkit-series.js.map +1 -1
- package/lib/module/modules/next/bluetooth/ble-plx/built-in-devices.js +12 -2
- package/lib/module/modules/next/bluetooth/ble-plx/built-in-devices.js.map +1 -1
- package/lib/module/modules/next/bluetooth/ble-plx/legacy-driver.js +39 -5
- package/lib/module/modules/next/bluetooth/ble-plx/legacy-driver.js.map +1 -1
- package/lib/module/modules/next/bluetooth/connections.js +45 -2
- package/lib/module/modules/next/bluetooth/connections.js.map +1 -1
- package/lib/module/modules/next/bluetooth/driver.js.map +1 -1
- package/lib/module/modules/next/bluetooth/errors.js.map +1 -1
- package/lib/module/modules/next/bluetooth/index.js.map +1 -1
- package/lib/module/modules/next/bluetooth/readings.js +10 -2
- package/lib/module/modules/next/bluetooth/readings.js.map +1 -1
- package/lib/module/modules/next/bluetooth/runtime.js +37 -1
- package/lib/module/modules/next/bluetooth/runtime.js.map +1 -1
- package/lib/module/modules/next/bluetooth/web/index.js.map +1 -1
- package/lib/typescript/commonjs/src/modules/auth/google-return-page/index.d.ts +8 -0
- package/lib/typescript/commonjs/src/modules/auth/google-return-page/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/auth/hooks/use-social-sign-in.web.d.ts +7 -0
- package/lib/typescript/commonjs/src/modules/auth/hooks/use-social-sign-in.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/auth/index.d.ts +1 -0
- package/lib/typescript/commonjs/src/modules/auth/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/auth/register/components/register.d.ts +2 -2
- package/lib/typescript/commonjs/src/modules/auth/sign-in/components/sign-in.d.ts +2 -2
- package/lib/typescript/commonjs/src/modules/auth/sign-in/components/social-logins/apple-login-button.web.d.ts +5 -0
- package/lib/typescript/commonjs/src/modules/auth/sign-in/components/social-logins/apple-login-button.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/auth/sign-in/components/social-logins/apple-login.d.ts +1 -1
- package/lib/typescript/commonjs/src/modules/auth/sign-in/components/social-logins/google-login-button.web.d.ts +5 -0
- package/lib/typescript/commonjs/src/modules/auth/sign-in/components/social-logins/google-login-button.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/auth/sign-in/components/social-logins/google-login.d.ts +1 -1
- package/lib/typescript/commonjs/src/modules/auth/sign-in/components/social-logins/social-logins.d.ts +2 -2
- package/lib/typescript/commonjs/src/modules/auth/sign-in/index.d.ts +2 -0
- package/lib/typescript/commonjs/src/modules/auth/sign-in/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/auth/sign-in/types/apple-login-props.d.ts +13 -0
- package/lib/typescript/commonjs/src/modules/auth/sign-in/types/apple-login-props.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/auth/sign-in/types/google-login-props.d.ts +13 -0
- package/lib/typescript/commonjs/src/modules/auth/sign-in/types/google-login-props.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/auth/sign-in/utils/apple-web-sign-in.d.ts +17 -0
- package/lib/typescript/commonjs/src/modules/auth/sign-in/utils/apple-web-sign-in.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/auth/sign-in/utils/google-redirect-sign-in.d.ts +14 -0
- package/lib/typescript/commonjs/src/modules/auth/sign-in/utils/google-redirect-sign-in.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/auth/sign-in/utils/jwt-claims.d.ts +9 -0
- package/lib/typescript/commonjs/src/modules/auth/sign-in/utils/jwt-claims.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/auth/utils/sign-out-google.web.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/auth/utils/sign-out-google.web.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/components/bt-provider-child-wrapper.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/hooks/runtime-context.d.ts +4 -1
- package/lib/typescript/commonjs/src/modules/bt-management/hooks/runtime-context.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/index.d.ts +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/bt-manager.d.ts +21 -5
- package/lib/typescript/commonjs/src/modules/bt-management/services/bt-manager.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/custom/compile-custom-lepu.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/blood-glucose/blood-glucose.device.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/blood-glucose/telebgm.protocol.d.ts +34 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/blood-glucose/telebgm.protocol.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/blood-glucose/telebgm.sequencer.d.ts +32 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/blood-glucose/telebgm.sequencer.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bp2/bp2.device.d.ts +4 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bp2/bp2.device.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bp2/bp2.frame-reader.d.ts +2 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bp2/bp2.frame-reader.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bp2/bp2.history-sequencer.d.ts +29 -3
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bp2/bp2.history-sequencer.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-command-writer.d.ts +6 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-command-writer.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-data-processor.d.ts +2 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-data-processor.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-managed-device.d.ts +23 -3
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/bt-managed-device.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/cofoe/cofoe.records.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/custom/custom-lepu-sequencer.d.ts +6 -3
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/custom/custom-lepu-sequencer.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/custom/custom.device.d.ts +20 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/custom/custom.device.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.advertisement.d.ts +8 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.advertisement.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.connect-retry.d.ts +12 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.connect-retry.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.delivered-files.d.ts +24 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.delivered-files.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.ecg-transfer.d.ts +40 -5
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.ecg-transfer.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.encryption-handshake.d.ts +20 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.encryption-handshake.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.file-transfer.d.ts +6 -3
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.file-transfer.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.frame-reader.d.ts +3 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.frame-reader.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.identity-gate.d.ts +26 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.identity-gate.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.live-ecg-chunks.d.ts +42 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.live-ecg-chunks.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.pulse-wave-chunks.d.ts +28 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.pulse-wave-chunks.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.pulse-wave.d.ts +16 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.pulse-wave.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.recorder.d.ts +32 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.recorder.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.recording-watch.d.ts +28 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.recording-watch.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.session.d.ts +17 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.session.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.stored-files.d.ts +33 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.stored-files.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.transports.d.ts +6 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.transports.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.waveform.d.ts +9 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/lepu/lepu.waveform.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/viatom/viatom.bp-monitors.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/viatom/viatom.ecg-files.d.ts +9 -3
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/viatom/viatom.ecg-files.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/viatom/viatom.ecg-recorders.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/viatom/viatom.ecg-recording-status.d.ts +8 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/viatom/viatom.ecg-recording-status.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/viatom/viatom.oximeters.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/devices/viatom/viatom.wbp02.protocol.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/series-recorder.d.ts +6 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/series-recorder.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/create-device-params.d.ts +7 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/create-device-params.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-lepu-spec.d.ts +47 -3
- package/lib/typescript/commonjs/src/modules/bt-management/types/custom-lepu-spec.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/device-connection-event.d.ts +17 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/device-connection-event.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/device-waveform.d.ts +15 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/device-waveform.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/calculate-crc-16-modbus.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/calculate-crc-16-modbus.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/i-16-from-hex.d.ts +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/utils/i-16-from-hex.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/utils/le-32-from-hex.d.ts +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/utils/le-32-from-hex.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/utils/tenths-mmol-to-mg-per-dl.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/bt-management/utils/tenths-mmol-to-mg-per-dl.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/data-sync/components/apple/apple-health-authorization-provider.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/components/apple/apple-health-authorization-utils.d.ts +2 -2
- package/lib/typescript/commonjs/src/modules/data-sync/components/apple/apple-health-authorization-utils.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/constants.d.ts +3 -1
- package/lib/typescript/commonjs/src/modules/data-sync/constants.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/hooks/use-listen-changes.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/services/managers/data-processor.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/types/apple-health-authorization-provider-props.d.ts +2 -2
- package/lib/typescript/commonjs/src/modules/data-sync/types/apple-health-authorization-provider-props.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/types/apple-health-sync-props.d.ts +4 -7
- package/lib/typescript/commonjs/src/modules/data-sync/types/apple-health-sync-props.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/types/get-data-from-provider-props.d.ts +3 -1
- package/lib/typescript/commonjs/src/modules/data-sync/types/get-data-from-provider-props.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/types/health-authorization-status.d.ts +2 -2
- package/lib/typescript/commonjs/src/modules/data-sync/types/health-authorization-status.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/types/health-sync-keys.d.ts +11 -1
- package/lib/typescript/commonjs/src/modules/data-sync/types/health-sync-keys.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/types/health-sync-props.d.ts +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/types/health-sync-props.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/utils/convert-ecg-samples-to-observation.d.ts +6 -0
- package/lib/typescript/commonjs/src/modules/data-sync/utils/convert-ecg-samples-to-observation.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/data-sync/utils/convert-generic-health-data.d.ts +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/utils/convert-generic-health-data.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/utils/convert-samples-to-observation.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/utils/default-health-coding.d.ts +10 -0
- package/lib/typescript/commonjs/src/modules/data-sync/utils/default-health-coding.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/data-sync/utils/get-records-from-health-connect.d.ts +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/utils/get-records-from-health-connect.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/utils/get-samples-from-health.d.ts +12 -46
- package/lib/typescript/commonjs/src/modules/data-sync/utils/get-samples-from-health.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/utils/get-total-samples-count.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/utils/health-data-catalog.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/utils/health-units.d.ts +2 -2
- package/lib/typescript/commonjs/src/modules/data-sync/utils/health-units.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/utils/healthkit-daily-statistics.d.ts +10 -0
- package/lib/typescript/commonjs/src/modules/data-sync/utils/healthkit-daily-statistics.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/data-sync/utils/healthkit-data-types.d.ts +5 -5
- package/lib/typescript/commonjs/src/modules/data-sync/utils/healthkit-data-types.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/utils/healthkit-query-options.d.ts +7 -0
- package/lib/typescript/commonjs/src/modules/data-sync/utils/healthkit-query-options.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/data-sync/utils/healthkit-sample-source.d.ts +8 -0
- package/lib/typescript/commonjs/src/modules/data-sync/utils/healthkit-sample-source.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/data-sync/utils/healthkit-samples.d.ts +30 -0
- package/lib/typescript/commonjs/src/modules/data-sync/utils/healthkit-samples.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/data-sync/utils/healthkit-series.d.ts +2 -2
- package/lib/typescript/commonjs/src/modules/data-sync/utils/healthkit-series.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/utils/to-core-health-observations.d.ts +1 -0
- package/lib/typescript/commonjs/src/modules/data-sync/utils/to-core-health-observations.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/ble-plx/built-in-devices.d.ts +12 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/ble-plx/built-in-devices.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/ble-plx/legacy-driver.d.ts +2 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/ble-plx/legacy-driver.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/connections.d.ts +13 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/connections.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/driver.d.ts +20 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/driver.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/errors.d.ts +1 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/errors.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/index.d.ts +2 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/readings.d.ts +3 -2
- package/lib/typescript/commonjs/src/modules/next/bluetooth/readings.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/runtime.d.ts +19 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/runtime.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/snapshot.d.ts +33 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/snapshot.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/index.d.ts +1 -0
- package/lib/typescript/commonjs/src/modules/next/bluetooth/web/index.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/auth/google-return-page/index.d.ts +8 -0
- package/lib/typescript/module/src/modules/auth/google-return-page/index.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/auth/hooks/use-social-sign-in.web.d.ts +7 -0
- package/lib/typescript/module/src/modules/auth/hooks/use-social-sign-in.web.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/auth/index.d.ts +1 -0
- package/lib/typescript/module/src/modules/auth/index.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/auth/register/components/register.d.ts +2 -2
- package/lib/typescript/module/src/modules/auth/sign-in/components/sign-in.d.ts +2 -2
- package/lib/typescript/module/src/modules/auth/sign-in/components/social-logins/apple-login-button.web.d.ts +5 -0
- package/lib/typescript/module/src/modules/auth/sign-in/components/social-logins/apple-login-button.web.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/auth/sign-in/components/social-logins/apple-login.d.ts +1 -1
- package/lib/typescript/module/src/modules/auth/sign-in/components/social-logins/google-login-button.web.d.ts +5 -0
- package/lib/typescript/module/src/modules/auth/sign-in/components/social-logins/google-login-button.web.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/auth/sign-in/components/social-logins/google-login.d.ts +1 -1
- package/lib/typescript/module/src/modules/auth/sign-in/components/social-logins/social-logins.d.ts +2 -2
- package/lib/typescript/module/src/modules/auth/sign-in/index.d.ts +2 -0
- package/lib/typescript/module/src/modules/auth/sign-in/index.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/auth/sign-in/types/apple-login-props.d.ts +13 -0
- package/lib/typescript/module/src/modules/auth/sign-in/types/apple-login-props.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/auth/sign-in/types/google-login-props.d.ts +13 -0
- package/lib/typescript/module/src/modules/auth/sign-in/types/google-login-props.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/auth/sign-in/utils/apple-web-sign-in.d.ts +17 -0
- package/lib/typescript/module/src/modules/auth/sign-in/utils/apple-web-sign-in.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/auth/sign-in/utils/google-redirect-sign-in.d.ts +14 -0
- package/lib/typescript/module/src/modules/auth/sign-in/utils/google-redirect-sign-in.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/auth/sign-in/utils/jwt-claims.d.ts +9 -0
- package/lib/typescript/module/src/modules/auth/sign-in/utils/jwt-claims.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/auth/utils/sign-out-google.web.d.ts +3 -0
- package/lib/typescript/module/src/modules/auth/utils/sign-out-google.web.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/components/bt-provider-child-wrapper.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/hooks/runtime-context.d.ts +4 -1
- package/lib/typescript/module/src/modules/bt-management/hooks/runtime-context.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/index.d.ts +1 -0
- package/lib/typescript/module/src/modules/bt-management/index.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/bt-manager.d.ts +21 -5
- package/lib/typescript/module/src/modules/bt-management/services/bt-manager.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/custom/compile-custom-lepu.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/blood-glucose/blood-glucose.device.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/blood-glucose/telebgm.protocol.d.ts +34 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/blood-glucose/telebgm.protocol.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/blood-glucose/telebgm.sequencer.d.ts +32 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/blood-glucose/telebgm.sequencer.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/bp2/bp2.device.d.ts +4 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/bp2/bp2.device.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bp2/bp2.frame-reader.d.ts +2 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bp2/bp2.frame-reader.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bp2/bp2.history-sequencer.d.ts +29 -3
- package/lib/typescript/module/src/modules/bt-management/services/devices/bp2/bp2.history-sequencer.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-command-writer.d.ts +6 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-command-writer.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-data-processor.d.ts +2 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-data-processor.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-managed-device.d.ts +23 -3
- package/lib/typescript/module/src/modules/bt-management/services/devices/bt-managed-device.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/cofoe/cofoe.records.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/custom/custom-lepu-sequencer.d.ts +6 -3
- package/lib/typescript/module/src/modules/bt-management/services/devices/custom/custom-lepu-sequencer.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/custom/custom.device.d.ts +20 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/custom/custom.device.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.advertisement.d.ts +8 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.advertisement.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.connect-retry.d.ts +12 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.connect-retry.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.delivered-files.d.ts +24 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.delivered-files.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.ecg-transfer.d.ts +40 -5
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.ecg-transfer.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.encryption-handshake.d.ts +20 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.encryption-handshake.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.file-transfer.d.ts +6 -3
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.file-transfer.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.frame-reader.d.ts +3 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.frame-reader.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.identity-gate.d.ts +26 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.identity-gate.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.live-ecg-chunks.d.ts +42 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.live-ecg-chunks.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.pulse-wave-chunks.d.ts +28 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.pulse-wave-chunks.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.pulse-wave.d.ts +16 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.pulse-wave.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.recorder.d.ts +32 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.recorder.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.recording-watch.d.ts +28 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.recording-watch.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.session.d.ts +17 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.session.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.stored-files.d.ts +33 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.stored-files.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.transports.d.ts +6 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.transports.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.waveform.d.ts +9 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/lepu/lepu.waveform.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/viatom/viatom.bp-monitors.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/viatom/viatom.ecg-files.d.ts +9 -3
- package/lib/typescript/module/src/modules/bt-management/services/devices/viatom/viatom.ecg-files.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/viatom/viatom.ecg-recorders.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/viatom/viatom.ecg-recording-status.d.ts +8 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/viatom/viatom.ecg-recording-status.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/services/devices/viatom/viatom.oximeters.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/devices/viatom/viatom.wbp02.protocol.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/series-recorder.d.ts +6 -1
- package/lib/typescript/module/src/modules/bt-management/services/series-recorder.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/create-device-params.d.ts +7 -1
- package/lib/typescript/module/src/modules/bt-management/types/create-device-params.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/custom-lepu-spec.d.ts +47 -3
- package/lib/typescript/module/src/modules/bt-management/types/custom-lepu-spec.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/device-connection-event.d.ts +17 -1
- package/lib/typescript/module/src/modules/bt-management/types/device-connection-event.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/device-waveform.d.ts +15 -0
- package/lib/typescript/module/src/modules/bt-management/types/device-waveform.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/utils/calculate-crc-16-modbus.d.ts +3 -0
- package/lib/typescript/module/src/modules/bt-management/utils/calculate-crc-16-modbus.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/utils/i-16-from-hex.d.ts +1 -1
- package/lib/typescript/module/src/modules/bt-management/utils/i-16-from-hex.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/utils/le-32-from-hex.d.ts +1 -1
- package/lib/typescript/module/src/modules/bt-management/utils/le-32-from-hex.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/utils/tenths-mmol-to-mg-per-dl.d.ts +3 -0
- package/lib/typescript/module/src/modules/bt-management/utils/tenths-mmol-to-mg-per-dl.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/data-sync/components/apple/apple-health-authorization-provider.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/components/apple/apple-health-authorization-utils.d.ts +2 -2
- package/lib/typescript/module/src/modules/data-sync/components/apple/apple-health-authorization-utils.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/constants.d.ts +3 -1
- package/lib/typescript/module/src/modules/data-sync/constants.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/hooks/use-listen-changes.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/services/managers/data-processor.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/types/apple-health-authorization-provider-props.d.ts +2 -2
- package/lib/typescript/module/src/modules/data-sync/types/apple-health-authorization-provider-props.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/types/apple-health-sync-props.d.ts +4 -7
- package/lib/typescript/module/src/modules/data-sync/types/apple-health-sync-props.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/types/get-data-from-provider-props.d.ts +3 -1
- package/lib/typescript/module/src/modules/data-sync/types/get-data-from-provider-props.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/types/health-authorization-status.d.ts +2 -2
- package/lib/typescript/module/src/modules/data-sync/types/health-authorization-status.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/types/health-sync-keys.d.ts +11 -1
- package/lib/typescript/module/src/modules/data-sync/types/health-sync-keys.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/types/health-sync-props.d.ts +1 -1
- package/lib/typescript/module/src/modules/data-sync/types/health-sync-props.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/utils/convert-ecg-samples-to-observation.d.ts +6 -0
- package/lib/typescript/module/src/modules/data-sync/utils/convert-ecg-samples-to-observation.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/data-sync/utils/convert-generic-health-data.d.ts +1 -1
- package/lib/typescript/module/src/modules/data-sync/utils/convert-generic-health-data.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/utils/convert-samples-to-observation.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/utils/default-health-coding.d.ts +10 -0
- package/lib/typescript/module/src/modules/data-sync/utils/default-health-coding.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/data-sync/utils/get-records-from-health-connect.d.ts +1 -1
- package/lib/typescript/module/src/modules/data-sync/utils/get-records-from-health-connect.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/utils/get-samples-from-health.d.ts +12 -46
- package/lib/typescript/module/src/modules/data-sync/utils/get-samples-from-health.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/utils/get-total-samples-count.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/utils/health-data-catalog.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/utils/health-units.d.ts +2 -2
- package/lib/typescript/module/src/modules/data-sync/utils/health-units.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/utils/healthkit-daily-statistics.d.ts +10 -0
- package/lib/typescript/module/src/modules/data-sync/utils/healthkit-daily-statistics.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/data-sync/utils/healthkit-data-types.d.ts +5 -5
- package/lib/typescript/module/src/modules/data-sync/utils/healthkit-data-types.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/utils/healthkit-query-options.d.ts +7 -0
- package/lib/typescript/module/src/modules/data-sync/utils/healthkit-query-options.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/data-sync/utils/healthkit-sample-source.d.ts +8 -0
- package/lib/typescript/module/src/modules/data-sync/utils/healthkit-sample-source.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/data-sync/utils/healthkit-samples.d.ts +30 -0
- package/lib/typescript/module/src/modules/data-sync/utils/healthkit-samples.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/data-sync/utils/healthkit-series.d.ts +2 -2
- package/lib/typescript/module/src/modules/data-sync/utils/healthkit-series.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/utils/to-core-health-observations.d.ts +1 -0
- package/lib/typescript/module/src/modules/data-sync/utils/to-core-health-observations.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/next/bluetooth/ble-plx/built-in-devices.d.ts +12 -1
- package/lib/typescript/module/src/modules/next/bluetooth/ble-plx/built-in-devices.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/next/bluetooth/ble-plx/legacy-driver.d.ts +2 -1
- package/lib/typescript/module/src/modules/next/bluetooth/ble-plx/legacy-driver.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/next/bluetooth/connections.d.ts +13 -1
- package/lib/typescript/module/src/modules/next/bluetooth/connections.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/next/bluetooth/driver.d.ts +20 -0
- package/lib/typescript/module/src/modules/next/bluetooth/driver.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/next/bluetooth/errors.d.ts +1 -1
- package/lib/typescript/module/src/modules/next/bluetooth/errors.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/next/bluetooth/index.d.ts +2 -1
- package/lib/typescript/module/src/modules/next/bluetooth/index.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/next/bluetooth/readings.d.ts +3 -2
- package/lib/typescript/module/src/modules/next/bluetooth/readings.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/next/bluetooth/runtime.d.ts +19 -1
- package/lib/typescript/module/src/modules/next/bluetooth/runtime.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/next/bluetooth/snapshot.d.ts +33 -1
- package/lib/typescript/module/src/modules/next/bluetooth/snapshot.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/next/bluetooth/web/index.d.ts +1 -0
- package/lib/typescript/module/src/modules/next/bluetooth/web/index.d.ts.map +1 -1
- package/package.json +8 -3
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["Healthkit","
|
|
1
|
+
{"version":3,"names":["Healthkit","UpdateFrequency","React","useListenChanges","dataToSync","onChange","backgroundDelivery","onError","timeoutRef","useRef","undefined","onChangeRef","onErrorRef","identifiers","useMemo","Object","values","flatMap","data","typeIdentifiers","map","identifier","typeIdentifier","backgroundDeliveryEnabled","backgroundDeliveryFrequency","frequency","hourly","debouncedOnChange","useCallback","current","clearTimeout","setTimeout","useEffect","subscriptions","initSubscriptions","Promise","all","enableBackgroundDelivery","push","subscribeToChanges","error","forEach","subscription","remove","disableBackgroundDelivery","catch"],"sourceRoot":"../../../../../src","sources":["modules/data-sync/hooks/use-listen-changes.ts"],"mappings":";;AAAA,OAAOA,SAAS,IAEdC,eAAe,QACV,oCAAoC;AAC3C,OAAO,KAAKC,KAAK,MAAM,OAAO;AAO9B,OAAO,MAAMC,gBAAgB,GAAGA,CAC9BC,UAA8C,EAC9CC,QAAyD,EACzDC,kBAA+D,EAC/DC,OAAgC,KAC7B;EACH,MAAMC,UAAU,GAAGN,KAAK,CAACO,MAAM,CAA6BC,SAAS,CAAC;EAEtE,MAAMC,WAAW,GAAGT,KAAK,CAACO,MAAM,CAACJ,QAAQ,CAAC;EAC1C,MAAMO,UAAU,GAAGV,KAAK,CAACO,MAAM,CAACF,OAAO,CAAC;EAExC,MAAMM,WAAW,GAAGX,KAAK,CAACY,OAAO,CAAC,MAAM;IACtC,OAAOC,MAAM,CAACC,MAAM,CAACZ,UAAU,CAAC,CAACa,OAAO,CACrCC,IAAI,IACHA,IAAI,EAAEC,eAAe,CAACC,GAAG,CAAEC,UAAU,IAAKA,UAAU,CAACC,cAAc,CAAC,IACpE,EACJ,CAAC;EACH,CAAC,EAAE,CAAClB,UAAU,CAAC,CAAC;EAEhB,MAAMmB,yBAAyB,GAAGjB,kBAAkB,KAAKI,SAAS;EAElE,MAAMc,2BAA2B,GAC/BlB,kBAAkB,EAAEmB,SAAS,IAAIxB,eAAe,CAACyB,MAAM;EAEzD,MAAMC,iBAAiB,GAAGzB,KAAK,CAAC0B,WAAW,CACxCP,UAAyC,IAAK;IAC7C,IAAIb,UAAU,CAACqB,OAAO,EAAE;MACtBC,YAAY,CAACtB,UAAU,CAACqB,OAAO,CAAC;IAClC;IAEArB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C;IAEnB,OAAO,MAAM;MACXD,aAAa,CAACQ,OAAO,CAAEC,YAAY,IAAK;QACtCA,YAAY,CAACC,MAAM,CAAC,CAAC;MACvB,CAAC,CAAC;MAEF,IAAIpB,yBAAyB,EAAE;QAC7B,KAAKY,OAAO,CAACC,GAAG,CACdvB,WAAW,CAACO,GAAG,CAAEC,UAAU,IACzBrB,SAAS,CAAC4C,yBAAyB,CAACvB,UAAU,CAChD,CACF,CAAC,CAACwB,KAAK,CAAEL,KAAc,IAAK5B,UAAU,CAACiB,OAAO,GAAGW,KAAc,CAAC,CAAC;MACnE;IACF,CAAC;EACH,CAAC,EAAE,CACD3B,WAAW,EACXc,iBAAiB,EACjBJ,yBAAyB,EACzBC,2BAA2B,CAC5B,CAAC;AACJ,CAAC","ignoreList":[]}
|
|
@@ -4,12 +4,12 @@
|
|
|
4
4
|
|
|
5
5
|
import { MeasurementTypeKey } from "@ovok/core/next";
|
|
6
6
|
import { getHealthDataMode, HealthDataType } from "../../types/health-sync-keys.js";
|
|
7
|
+
import { getDefaultHealthCoding } from "../../utils/default-health-coding.js";
|
|
7
8
|
import { getHealthRecordSourceId, getHealthRecordSyncId } from "../../utils/get-health-record-sync-id.js";
|
|
8
9
|
import { getLatestObservationDatesByCode } from "../../utils/get-latest-observation-dates-by-code.js";
|
|
9
10
|
import { getLatestValidStartDate } from "../../utils/get-latest-valid-start-date.js";
|
|
10
11
|
import { groupSamplesByInterval } from "../../utils/group-samples-by-interval.js";
|
|
11
12
|
import { groupSleepSamples } from "../../utils/group-sleep-samples.js";
|
|
12
|
-
import { getHealthDataCoding } from "../../utils/health-data-catalog.js";
|
|
13
13
|
import { identifyImportedObservations } from "../../utils/identify-imported-observations.js";
|
|
14
14
|
export class DataProcessor {
|
|
15
15
|
constructor(client, patientId, provider, chunkSize, storageManager, getTotalCountsFunction, getDataFromProviderFunction, getConverterFunction) {
|
|
@@ -27,7 +27,7 @@ export class DataProcessor {
|
|
|
27
27
|
return entries.flatMap(([key, data]) => data?.typeIdentifiers.map(({
|
|
28
28
|
typeIdentifier,
|
|
29
29
|
code
|
|
30
|
-
}) => String(code ??
|
|
30
|
+
}) => String(code ?? getDefaultHealthCoding(this.provider, key, String(typeIdentifier), getHealthDataMode(key, data.mode)).code)) ?? []);
|
|
31
31
|
}
|
|
32
32
|
async getLatestObservationDates(dataToSync) {
|
|
33
33
|
const codes = this.extractCodes(dataToSync);
|
|
@@ -61,12 +61,12 @@ export class DataProcessor {
|
|
|
61
61
|
system,
|
|
62
62
|
display
|
|
63
63
|
}) => {
|
|
64
|
-
const
|
|
64
|
+
const defaultCoding = getDefaultHealthCoding(this.provider, measurementTypeKey, String(typeIdentifier), mode);
|
|
65
65
|
return {
|
|
66
66
|
typeIdentifier: String(typeIdentifier),
|
|
67
|
-
code: String(code ??
|
|
68
|
-
system: system ?? (code ? undefined :
|
|
69
|
-
display: display ?? (code ? undefined :
|
|
67
|
+
code: String(code ?? defaultCoding.code),
|
|
68
|
+
system: system ?? (code ? undefined : defaultCoding.system),
|
|
69
|
+
display: display ?? (code ? undefined : defaultCoding.display)
|
|
70
70
|
};
|
|
71
71
|
});
|
|
72
72
|
const typeIdentifierCodes = Object.fromEntries(configuredCodings.map(({
|
|
@@ -89,6 +89,7 @@ export class DataProcessor {
|
|
|
89
89
|
typeIdentifier,
|
|
90
90
|
result: await this.getDataFromProviderFunction({
|
|
91
91
|
typeIdentifier: typeIdentifier,
|
|
92
|
+
key: measurementTypeKey,
|
|
92
93
|
startDate: latestValidStartDate?.toISOString(),
|
|
93
94
|
anchor,
|
|
94
95
|
chunkSize: this.chunkSize,
|
|
@@ -150,7 +151,7 @@ export class DataProcessor {
|
|
|
150
151
|
code
|
|
151
152
|
}) => ({
|
|
152
153
|
typeIdentifier,
|
|
153
|
-
code: code ??
|
|
154
|
+
code: code ?? getDefaultHealthCoding(this.provider, measurementTypeKey, String(typeIdentifier), resolvedMode).code
|
|
154
155
|
}))
|
|
155
156
|
};
|
|
156
157
|
return getLatestValidStartDate({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["MeasurementTypeKey","getHealthDataMode","HealthDataType","getHealthRecordSourceId","getHealthRecordSyncId","getLatestObservationDatesByCode","getLatestValidStartDate","groupSamplesByInterval","groupSleepSamples","
|
|
1
|
+
{"version":3,"names":["MeasurementTypeKey","getHealthDataMode","HealthDataType","getDefaultHealthCoding","getHealthRecordSourceId","getHealthRecordSyncId","getLatestObservationDatesByCode","getLatestValidStartDate","groupSamplesByInterval","groupSleepSamples","identifyImportedObservations","DataProcessor","constructor","client","patientId","provider","chunkSize","storageManager","getTotalCountsFunction","getDataFromProviderFunction","getConverterFunction","extractCodes","dataToSync","entries","Object","flatMap","key","data","typeIdentifiers","map","typeIdentifier","code","String","mode","getLatestObservationDates","codes","getTotalRecordsCountForType","measurementTypeKey","latestValidStartDate","totalCounts","Promise","all","anchor","getAnchor","startDate","toISOString","reduce","acc","count","getObservationBodiesForType","configuredCodings","system","display","defaultCoding","undefined","typeIdentifierCodes","fromEntries","typeIdentifierCodeSystems","typeIdentifierCodeDisplays","results","result","newAnchors","flat","filter","Boolean","allData","deletedRecordIds","dataGroups","sleep","bloodPressure","observationBodies","group","length","observationSyncIds","observationRecordIds","hasMore","some","anchors","identifyObservations","groupedObservationBodies","groupedObservationSyncIds","groupedRecordIds","latestObservationDates","resolvedMode","resolvedData"],"sourceRoot":"../../../../../../src","sources":["modules/data-sync/services/managers/data-processor.ts"],"mappings":";;AAAA;;AAGA,SAASA,kBAAkB,QAAQ,iBAAiB;AAWpD,SACEC,iBAAiB,EACjBC,cAAc,QAET,iCAA8B;AACrC,SAASC,sBAAsB,QAAQ,sCAAmC;AAC1E,SACEC,uBAAuB,EACvBC,qBAAqB,QAChB,0CAAuC;AAC9C,SAASC,+BAA+B,QAAQ,qDAAkD;AAClG,SAASC,uBAAuB,QAAQ,4CAAyC;AACjF,SAASC,sBAAsB,QAAQ,0CAAuC;AAC9E,SAASC,iBAAiB,QAAQ,oCAAiC;A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AC;IAE7E,MAAMmD,YAAY,GAAG;MACnB,GAAGzD,IAAI;MACPC,eAAe,EAAED,IAAI,CAACC,eAAe,CAACC,GAAG,CAAC,CAAC;QAAEC,cAAc;QAAEC;MAAK,CAAC,MAAM;QACvED,cAAc;QACdC,IAAI,EACFA,IAAI,IACJ5B,sBAAsB,CACpB,IAAI,CAACY,QAAQ,EACbsB,kBAAkB,EAClBL,MAAM,CAACF,cAAc,CAAC,EACtBqD,YACF,CAAC,CAACpD;MACJ,CAAC,CACH;IACF,CAAC;IAED,OAAOxB,uBAAuB,CAAC;MAC7B2E,sBAAsB;MACtBvD,IAAI,EAAEyD,YAAqE;MAC3EnD,IAAI,EAAEkD;IACR,CAAC,CAAC;EACJ;AACF","ignoreList":[]}
|
|
@@ -27,6 +27,16 @@ var HealthDataType = /*#__PURE__*/function (HealthDataType) {
|
|
|
27
27
|
HealthDataType["sleep"] = "sleep";
|
|
28
28
|
/** Workout sessions. */
|
|
29
29
|
HealthDataType["workout"] = "workout";
|
|
30
|
+
/** Water drunk. */
|
|
31
|
+
HealthDataType["water"] = "water";
|
|
32
|
+
/** Carbohydrates eaten. */
|
|
33
|
+
HealthDataType["carbohydrates"] = "carbohydrates";
|
|
34
|
+
/** Food energy eaten. */
|
|
35
|
+
HealthDataType["caloriesEaten"] = "calories-eaten";
|
|
36
|
+
/** Blood alcohol content. */
|
|
37
|
+
HealthDataType["bloodAlcohol"] = "blood-alcohol";
|
|
38
|
+
/** Insulin delivered. */
|
|
39
|
+
HealthDataType["insulin"] = "insulin";
|
|
30
40
|
return HealthDataType;
|
|
31
41
|
}(HealthDataType || {});
|
|
32
42
|
/** Measurement type or health-only data type that can be synced. */
|
|
@@ -42,6 +52,9 @@ const getHealthDataMode = (key, configuredMode) => {
|
|
|
42
52
|
case HealthDataType.activeEnergy:
|
|
43
53
|
case HealthDataType.flightsClimbed:
|
|
44
54
|
case HealthDataType.exerciseMinutes:
|
|
55
|
+
case HealthDataType.water:
|
|
56
|
+
case HealthDataType.carbohydrates:
|
|
57
|
+
case HealthDataType.caloriesEaten:
|
|
45
58
|
return "daily-total";
|
|
46
59
|
case MeasurementTypeKey.heartRate:
|
|
47
60
|
case HealthDataType.heartRateSummary:
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["MeasurementTypeKey","HealthDataType","getHealthDataMode","key","configuredMode","stepCount","distance","activeEnergy","flightsClimbed","exerciseMinutes","heartRate","heartRateSummary","sleep","workout"],"sourceRoot":"../../../../../src","sources":["modules/data-sync/types/health-sync-keys.ts"],"mappings":";;AAAA,SAASA,kBAAkB,QAAQ,iBAAiB;;AAEpD;AAMA;AAAA,IACKC,cAAc,0BAAdA,cAAc;EAEjB;EAFGA,cAAc;EAKjB;EALGA,cAAc;EAQjB;EARGA,cAAc;EAWjB;EAXGA,cAAc;EAcjB;EAdGA,cAAc;EAiBjB;EAjBGA,cAAc;EAoBjB;EApBGA,cAAc;EAuBjB;EAvBGA,cAAc;EA0BjB;EA1BGA,cAAc;EA6BjB;EA7BGA,cAAc;EAgCjB;EAhCGA,cAAc;EAAA,OAAdA,cAAc;AAAA,EAAdA,cAAc;
|
|
1
|
+
{"version":3,"names":["MeasurementTypeKey","HealthDataType","getHealthDataMode","key","configuredMode","stepCount","distance","activeEnergy","flightsClimbed","exerciseMinutes","water","carbohydrates","caloriesEaten","heartRate","heartRateSummary","sleep","workout"],"sourceRoot":"../../../../../src","sources":["modules/data-sync/types/health-sync-keys.ts"],"mappings":";;AAAA,SAASA,kBAAkB,QAAQ,iBAAiB;;AAEpD;AAMA;AAAA,IACKC,cAAc,0BAAdA,cAAc;EAEjB;EAFGA,cAAc;EAKjB;EALGA,cAAc;EAQjB;EARGA,cAAc;EAWjB;EAXGA,cAAc;EAcjB;EAdGA,cAAc;EAiBjB;EAjBGA,cAAc;EAoBjB;EApBGA,cAAc;EAuBjB;EAvBGA,cAAc;EA0BjB;EA1BGA,cAAc;EA6BjB;EA7BGA,cAAc;EAgCjB;EAhCGA,cAAc;EAmCjB;EAnCGA,cAAc;EAsCjB;EAtCGA,cAAc;EAyCjB;EAzCGA,cAAc;EA4CjB;EA5CGA,cAAc;EA+CjB;EA/CGA,cAAc;EAAA,OAAdA,cAAc;AAAA,EAAdA,cAAc;AAmDnB;AAGA;AAUA;AACA,MAAMC,iBAAiB,GAAGA,CACxBC,GAAkB,EAClBC,cAA+B,KACZ;EACnB,IAAIA,cAAc,EAAE;IAClB,OAAOA,cAAc;EACvB;EAEA,QAAQD,GAAG;IACT,KAAKH,kBAAkB,CAACK,SAAS;IACjC,KAAKJ,cAAc,CAACK,QAAQ;IAC5B,KAAKL,cAAc,CAACM,YAAY;IAChC,KAAKN,cAAc,CAACO,cAAc;IAClC,KAAKP,cAAc,CAACQ,eAAe;IACnC,KAAKR,cAAc,CAACS,KAAK;IACzB,KAAKT,cAAc,CAACU,aAAa;IACjC,KAAKV,cAAc,CAACW,aAAa;MAC/B,OAAO,aAAa;IACtB,KAAKZ,kBAAkB,CAACa,SAAS;IACjC,KAAKZ,cAAc,CAACa,gBAAgB;MAClC,OAAO,eAAe;IACxB,KAAKb,cAAc,CAACc,KAAK;IACzB,KAAKd,cAAc,CAACe,OAAO;MACzB,OAAO,SAAS;IAClB;MACE,OAAO,OAAO;EAClB;AACF,CAAC;AAED,SACEf,cAAc,EACdC,iBAAiB","ignoreList":[]}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { MeasurementTypeKey } from "@ovok/core/next";
|
|
4
|
+
import { getHealthKitSampleSource } from "./healthkit-sample-source.js";
|
|
5
|
+
import { toCoreHealthObservations } from "./to-core-health-observations.js";
|
|
6
|
+
const MILLIVOLTS_PER_VOLT = 1000;
|
|
7
|
+
const MILLISECONDS_PER_SECOND = 1000;
|
|
8
|
+
/** The waveform in millivolts with its heart rate; Apple's classification is never part of it. */
|
|
9
|
+
const toEcgMeasurement = record => {
|
|
10
|
+
const diagramPoints = (record.voltages ?? []).map(({
|
|
11
|
+
voltage
|
|
12
|
+
}) => voltage * MILLIVOLTS_PER_VOLT);
|
|
13
|
+
if (diagramPoints.length === 0) {
|
|
14
|
+
return undefined;
|
|
15
|
+
}
|
|
16
|
+
return {
|
|
17
|
+
measurementTypeKey: MeasurementTypeKey.ecg,
|
|
18
|
+
diagramPoints,
|
|
19
|
+
duration: (record.endDate.getTime() - record.startDate.getTime()) / MILLISECONDS_PER_SECOND,
|
|
20
|
+
heartRate: record.averageHeartRateBpm,
|
|
21
|
+
recordedAt: record.startDate
|
|
22
|
+
};
|
|
23
|
+
};
|
|
24
|
+
|
|
25
|
+
/** Core's own ECG service cannot convert a sample, so the recording is built into a measurement here. */
|
|
26
|
+
const convertEcgSamplesToObservation = async props => {
|
|
27
|
+
const observations = await Promise.all(props.data.map(async record => {
|
|
28
|
+
const measurement = toEcgMeasurement(record);
|
|
29
|
+
if (!measurement) {
|
|
30
|
+
return [];
|
|
31
|
+
}
|
|
32
|
+
const observationBody = await props.client.measurements.build({
|
|
33
|
+
measurement
|
|
34
|
+
});
|
|
35
|
+
return toCoreHealthObservations(observationBody, {
|
|
36
|
+
...props,
|
|
37
|
+
data: [record]
|
|
38
|
+
}, () => getHealthKitSampleSource(record));
|
|
39
|
+
}));
|
|
40
|
+
return observations.flat();
|
|
41
|
+
};
|
|
42
|
+
export { convertEcgSamplesToObservation };
|
|
43
|
+
//# sourceMappingURL=convert-ecg-samples-to-observation.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["MeasurementTypeKey","getHealthKitSampleSource","toCoreHealthObservations","MILLIVOLTS_PER_VOLT","MILLISECONDS_PER_SECOND","toEcgMeasurement","record","diagramPoints","voltages","map","voltage","length","undefined","measurementTypeKey","ecg","duration","endDate","getTime","startDate","heartRate","averageHeartRateBpm","recordedAt","convertEcgSamplesToObservation","props","observations","Promise","all","data","measurement","observationBody","client","measurements","build","flat"],"sourceRoot":"../../../../../src","sources":["modules/data-sync/utils/convert-ecg-samples-to-observ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rB,MAAM;IAAE,CAAC,EAC5B,MAAML,wBAAwB,CAACK,MAAM,CACvC,CAAC;EACH,CAAC,CACH,CAAC;EAED,OAAOkB,YAAY,CAACS,IAAI,CAAC,CAAC;AAC5B,CAAC;AAED,SAASX,8BAA8B","ignoreList":[]}
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
/* eslint-disable max-lines */
|
|
4
4
|
|
|
5
5
|
import { isAggregatedHealthData, isSeriesHealthData } from "../types/health-data.js";
|
|
6
|
+
import { HealthDataType } from "../types/health-sync-keys.js";
|
|
6
7
|
import { LOINC_SYSTEM, UCUM_SYSTEM } from "./fhir-systems.js";
|
|
7
8
|
import { getHealthObservationDevice } from "./health-observation-device.js";
|
|
8
9
|
const HEALTH_RECORD_DATA_EXTENSION = "https://api.ovok.com/fhir/StructureDefinition/health-record-data";
|
|
@@ -10,6 +11,7 @@ const HEALTHKIT_BODY_MASS_INDEX = "HKQuantityTypeIdentifierBodyMassIndex";
|
|
|
10
11
|
const convertGenericHealthDataToObservation = async ({
|
|
11
12
|
data,
|
|
12
13
|
patientId,
|
|
14
|
+
measurementTypeKey,
|
|
13
15
|
mode,
|
|
14
16
|
typeIdentifier: configuredTypeIdentifier,
|
|
15
17
|
typeIdentifierCodes,
|
|
@@ -81,7 +83,7 @@ const convertGenericHealthDataToObservation = async ({
|
|
|
81
83
|
if (mode === "daily-summary" && isAggregatedHealthData(first)) {
|
|
82
84
|
observation.component = [...(first.minimum === undefined ? [] : [component("Minimum", first.minimum, first.unit)]), ...(first.maximum === undefined ? [] : [component("Maximum", first.maximum, first.unit)])];
|
|
83
85
|
}
|
|
84
|
-
const stageComponents = getSleepStageComponents(data);
|
|
86
|
+
const stageComponents = measurementTypeKey === HealthDataType.sleep ? getSleepStageComponents(data) : [];
|
|
85
87
|
if (stageComponents.length > 0) {
|
|
86
88
|
observation.component = [...(observation.component ?? []), ...stageComponents];
|
|
87
89
|
}
|
|
@@ -140,8 +142,10 @@ const getMeasurement = (value, mode, interval, typeIdentifier) => {
|
|
|
140
142
|
};
|
|
141
143
|
const extractValue = raw => {
|
|
142
144
|
if (typeof raw.quantity === "number") {
|
|
145
|
+
// HealthKit's percent unit counts 1 as 100%.
|
|
146
|
+
const value = raw.unit === "%" ? raw.quantity * 100 : raw.quantity;
|
|
143
147
|
return {
|
|
144
|
-
value
|
|
148
|
+
value,
|
|
145
149
|
unit: String(raw.unit ?? "1")
|
|
146
150
|
};
|
|
147
151
|
}
|
|
@@ -164,7 +168,7 @@ const extractValue = raw => {
|
|
|
164
168
|
};
|
|
165
169
|
}
|
|
166
170
|
}
|
|
167
|
-
const scalarCandidates = [["count", "count"], ["floors", "count"], ["rate", "count/min"], ["beatsPerMinute", "count/min"], ["percentage", "%"], ["vo2MillilitersPerMinuteKilogram", "mL/kg/min"]];
|
|
171
|
+
const scalarCandidates = [["count", "count"], ["floors", "count"], ["rate", "count/min"], ["beatsPerMinute", "count/min"], ["percentage", "%"], ["vo2MillilitersPerMinuteKilogram", "mL/kg/min"], ["heartRateVariabilityMillis", "ms"]];
|
|
168
172
|
for (const [key, unit] of scalarCandidates) {
|
|
169
173
|
if (typeof raw[key] === "number") {
|
|
170
174
|
return {
|
|
@@ -288,11 +292,12 @@ const getUcumCode = (unit, typeIdentifier) => {
|
|
|
288
292
|
"breaths/min": "{breaths}/min",
|
|
289
293
|
"°C": "Cel",
|
|
290
294
|
mmHg: "mm[Hg]",
|
|
291
|
-
degC: "Cel"
|
|
295
|
+
degC: "Cel",
|
|
296
|
+
IU: "[iU]"
|
|
292
297
|
}[unit] ?? unit;
|
|
293
298
|
return UCUM_CODES.has(normalized) ? normalized : undefined;
|
|
294
299
|
};
|
|
295
|
-
const UCUM_CODES = new Set(["1", "%", "Cel", "cal", "g", "h", "kcal", "kg", "kg/m2", "km", "m", "mL/kg/min", "mg", "mg/dL", "min", "[mi_i]", "mm[Hg]", "mmol/L", "ms", "mV", "s", "{beats}/min", "{breaths}/min", "{count}", "{counts}/min", "{ratio}", "{steps}"]);
|
|
300
|
+
const UCUM_CODES = new Set(["1", "%", "Cel", "cal", "g", "h", "kcal", "kg", "kg/m2", "km", "m", "mL", "mL/kg/min", "mg", "mg/dL", "min", "[mi_i]", "[iU]", "mm[Hg]", "mmol/L", "ms", "mV", "s", "{beats}/min", "{breaths}/min", "{count}", "{counts}/min", "{ratio}", "{steps}"]);
|
|
296
301
|
const normalizeUnit = (unit, typeIdentifier) => getUcumCode(unit, typeIdentifier) ?? unit;
|
|
297
302
|
const getStableObservationId = ({
|
|
298
303
|
typeIdentifier,
|
|
@@ -303,7 +308,10 @@ const getStableObservationId = ({
|
|
|
303
308
|
}) => {
|
|
304
309
|
const time = interval ? `${interval.start.toISOString()}-${interval.end.toISOString()}` : date?.toISOString() ?? "undated";
|
|
305
310
|
const value = measurement.valueQuantity?.value ?? measurement.valueString ?? "empty";
|
|
306
|
-
|
|
311
|
+
|
|
312
|
+
// A code that repeats a long type would push the time past the cut, and every day would share one id.
|
|
313
|
+
const parts = code === typeIdentifier ? [typeIdentifier, time, value] : [typeIdentifier, code, time, value];
|
|
314
|
+
return `health-${parts.join("-").replace(/[^a-zA-Z0-9.-]/g, "-").slice(0, 64)}`;
|
|
307
315
|
};
|
|
308
316
|
export { convertGenericHealthDataToObservation, extractValue, getUcumCode };
|
|
309
317
|
//# sourceMappingURL=convert-generic-health-data.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["isAggregatedHealthData","isSeriesHealthData","LOINC_SYSTEM","UCUM_SYSTEM","getHealthObservationDevice","HEALTH_RECORD_DATA_EXTENSION","HEALTHKIT_BODY_MASS_INDEX","convertGenericHealthDataToObservation","data","patientId","mode","typeIdentifier","configuredTypeIdentifier","typeIdentifierCodes","typeIdentifierCodeSystems","typeIdentifierCodeDisplays","first","value","String","quantityType","categoryType","recordType","configuredCode","code","configuredSystem","system","isLoincCode","undefined","interval","getInterval","measurement","getMeasurement","metadata","getMetadata","device","observationDate","start","getDate","observation","resourceType","id","getStableObservationId","date","status","subject","reference","coding","display","extension","url","valueString","JSON","stringify","map","toPortableRecordData","effectivePeriod","toISOString","end","effectiveDateTime","component","minimum","unit","maximum","stageComponents","getSleepStageComponents","length","test","OMITTED_RECORD_FIELDS","Set","Date","Array","isArray","Object","fromEntries","entries","filter","key","has","child","raw","valueSampledData","origin","quantity","period","periodMs","dimensions","values","slot","Number","toFixed","join","number","kind","average","valueQuantity","getTime","extracted","extractValue","candidates","containerKey","valueKey","fallbackUnit","container","normalizeUnit","scalarCandidates","intervals","item","startValue","startDate","startTime","time","endDate","endTime","endValue","isNaN","Boolean","Math","min","max","parsed","sourceRevision","source","manufacturer","dataOrigin","model","sourceApp","name","recordingMethod","flatMap","stages","duration","isFinite","stage","label","text","getUcumCode","includes","normalized","kilometers","meters","miles","count","steps","kilograms","grams","milligrams","kilocalories","calories","minutes","seconds","beatsPerMinute","bpm","mmHg","degC","UCUM_CODES","replace","slice"],"sourceRoot":"../../../../../src","sources":["modules/data-sync/utils/convert-generic-health-data.ts"],"mappings":";;AAAA;;AAKA,SAASA,sBAAsB,EAAEC,kBAAkB,QAAQ,yBAAsB;AAGjF,SAASC,YAAY,EAAEC,WAAW,QAAQ,mBAAgB;AAC1D,SAASC,0BAA0B,QAAQ,gCAA6B;AAOxE,MAAMC,4BAA4B,GAChC,kEAAkE;AAEpE,MAAMC,yBAAyB,GAAG,uCAAuC;AAEzE,MAAMC,qCAAqC,GAAG,MAAAA,CAAO;EACnDC,IAAI;EACJC,SAAS;EACTC,IAAI;EACJC,cAAc,EAAEC,wBAAwB;EACxCC,mBAAmB;EACnBC,yBAAyB;EACzBC;AACsB,CAAC,KAA6B;EACpD,MAAMC,KAAK,GAAGR,IAAI,CAAC,CAAC,CAAC;EAErB,IAAI,CAACQ,KAAK,EAAE;IACV,OAAO,EAAE;EACX;EAEA,MAAMC,KAAK,GAAGD,KAAgC;EAE9C,MAAML,cAAc,GAAGO,MAAM,CAC3BN,wBAAwB,IACtBK,KAAK,CAACN,cAAc,IAC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,CAAC;EAC9B9B,cAAc;EACdY,IAAI;EACJK,QAAQ;EACRc,IAAI;EACJZ;AAOF,CAAC,KAAa;EACZ,MAAMgF,IAAI,GAAGlF,QAAQ,GACjB,GAAGA,QAAQ,CAACQ,KAAK,CAACoB,WAAW,CAAC,CAAC,IAAI5B,QAAQ,CAAC6B,GAAG,CAACD,WAAW,CAAC,CAAC,EAAE,GAC/Dd,IAAI,EAAEc,WAAW,CAAC,CAAC,IAAI,SAAS;EAEpC,MAAMvC,KAAK,GACTa,WAAW,CAACgE,aAAa,EAAE7E,KAAK,IAAIa,WAAW,CAACoB,WAAW,IAAI,OAAO;EAExE,OAAO,UAAU,CAACvC,cAAc,EAAEY,IAAI,EAAEuF,IAAI,EAAE7F,KAAK,CAAC,CACjDyE,IAAI,CAAC,GAAG,CAAC,CACTiE,OAAO,CAAC,iBAAiB,EAAE,GAAG,CAAC,CAC/BC,KAAK,CAAC,CAAC,EAAE,EAAE,CAAC,EAAE;AACnB,CAAC;AAED,SAASrJ,qCAAqC,EAAE0F,YAAY,EAAEsC,WAAW","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["isAggregatedHealthData","isSeriesHealthData","HealthDataType","LOINC_SYSTEM","UCUM_SYSTEM","getHealthObservationDevice","HEALTH_RECORD_DATA_EXTENSION","HEALTHKIT_BODY_MASS_INDEX","convertGenericHealthDataToObservation","data","patientId","measurementTypeKey","mode","typeIdentifier","configuredTypeIdentifier","typeIdentifierCodes","typeIdentifierCodeSystems","typeIdentifierCodeDisplays","first","value","String","quantityType","categoryType","recordType","configuredCode","code","configuredSystem","system","isLoincCode","undefined","interval","getInterval","measurement","getMeasurement","metadata","getMetadata","device","observationDate","start","getDate","observation","resourceType","id","getStableObservationId","date","status","subject","reference","coding","display","extension","url","valueString","JSON","stringify","map","toPortableRecordData","effectivePeriod","toISOString","end","effectiveDateTime","component","minimum","unit","maximum","stageComponents","sleep","getSleepStageComponents","length","test","OMITTED_RECORD_FIELDS","Set","Date","Array","isArray","Object","fromEntries","entries","filter","key","has","child","raw","valueSampledData","origin","quantity","period","periodMs","dimensions","values","slot","Number","toFixed","join","number","kind","average","valueQuantity","getTime","extracted","extractValue","candidates","containerKey","valueKey","fallbackUnit","container","normalizeUnit","scalarCandidates","intervals","item","startValue","startDate","startTime","time","endDate","endTime","endValue","isNaN","Boolean","Math","min","max","parsed","sourceRevision","source","manufacturer","dataOrigin","model","sourceApp","name","recordingMethod","flatMap","stages","duration","isFinite","stage","label","text","getUcumCode","includes","normalized","kilometers","meters","miles","count","steps","kilograms","grams","milligrams","kilocalories","calories","minutes","seconds","beatsPerMinute","bpm","mmHg","degC","IU","UCUM_CODES","parts","replace","slice"],"sourceRoot":"../../../../../src","sources":["modules/data-sync/utils/convert-generic-health-data.ts"],"mappings":";;AAAA;;AAKA,SAASA,sBAAsB,EAAEC,kBAAkB,QAAQ,yBAAsB;AACjF,SAAyBC,cAAc,QAAQ,8BAA2B;AAE1E,SAASC,YAAY,EAAEC,WAAW,QAAQ,mBAAgB;AAC1D,SAASC,0BAA0B,QAAQ,gCAA6B;AAOxE,MAAMC,4BAA4B,GAChC,kEAAkE;AAEpE,MAAMC,yBAAyB,GAAG,uCAAuC;AAEzE,MAAMC,qCAAqC,GAAG,MAAAA,CAAO;EACnDC,IAAI;EACJC,SAAS;EACTC,kBAAkB;EAClBC,IAAI;EACJC,cAAc,EAAEC,wBAAwB;EACxCC,mBAAmB;EACnBC,yBAAyB;EACzBC;AACsB,CAAC,KAA6B;EACpD,MAAMC,KAAK,GAAGT,IAAI,CAAC,CAAC,CAAC;EAErB,IAAI,CAACS,KAAK,EAAE;IACV,OAAO,EAAE;EACX;EAEA,MAAMC,KAAK,GAAGD,KAAgC;EAE9C,MAAML,cAAc,GAAGO,MAAM,CAC3BN,wBAAwB,IACtBK,KAAK,CAACN,cAAc,IACpBM,KAAK,CAACE,YAAY,IAClBF,KAAK,CAACG,YAAY,IAClBH,KAAK,CAACI,UAAU,IAChB,aACJ,CAAC;EAED,MAA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AEF,MAAMmC,aAAa,GAAGA,CAAC3C,IAAY,EAAElD,cAAuB,KAC1D6H,WAAW,CAAC3E,IAAI,EAAElD,cAAc,CAAC,IAAIkD,IAAI;AAE3C,MAAMpB,sBAAsB,GAAGA,CAAC;EAC9B9B,cAAc;EACdY,IAAI;EACJK,QAAQ;EACRc,IAAI;EACJZ;AAOF,CAAC,KAAa;EACZ,MAAMiF,IAAI,GAAGnF,QAAQ,GACjB,GAAGA,QAAQ,CAACQ,KAAK,CAACoB,WAAW,CAAC,CAAC,IAAI5B,QAAQ,CAAC6B,GAAG,CAACD,WAAW,CAAC,CAAC,EAAE,GAC/Dd,IAAI,EAAEc,WAAW,CAAC,CAAC,IAAI,SAAS;EAEpC,MAAMvC,KAAK,GACTa,WAAW,CAACiE,aAAa,EAAE9E,KAAK,IAAIa,WAAW,CAACoB,WAAW,IAAI,OAAO;;EAExE;EACA,MAAM2G,KAAK,GACTtI,IAAI,KAAKZ,cAAc,GACnB,CAACA,cAAc,EAAEoG,IAAI,EAAE9F,KAAK,CAAC,GAC7B,CAACN,cAAc,EAAEY,IAAI,EAAEwF,IAAI,EAAE9F,KAAK,CAAC;EAEzC,OAAO,UAAU4I,KAAK,CACnBlE,IAAI,CAAC,GAAG,CAAC,CACTmE,OAAO,CAAC,iBAAiB,EAAE,GAAG,CAAC,CAC/BC,KAAK,CAAC,CAAC,EAAE,EAAE,CAAC,EAAE;AACnB,CAAC;AAED,SAASzJ,qCAAqC,EAAE4F,YAAY,EAAEsC,WAAW","ignoreList":[]}
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
3
|
import { ObservationServiceCreator } from "@ovok/core/dist/client/observation/services/creator";
|
|
4
|
+
import { MeasurementTypeKey } from "@ovok/core/next";
|
|
5
|
+
import { convertEcgSamplesToObservation } from "./convert-ecg-samples-to-observation.js";
|
|
4
6
|
import { convertGenericHealthDataToObservation } from "./convert-generic-health-data.js";
|
|
5
|
-
import {
|
|
7
|
+
import { getHealthKitSampleSource } from "./healthkit-sample-source.js";
|
|
6
8
|
import { hasConfiguredNonLoincCoding } from "./normalize-core-health-observation.js";
|
|
7
9
|
import { isCoreMeasurementTypeKey, toCoreHealthObservations } from "./to-core-health-observations.js";
|
|
8
10
|
export const convertSamplesToObservation = async props => {
|
|
@@ -33,6 +35,9 @@ export const convertSamplesToObservation = async props => {
|
|
|
33
35
|
mode
|
|
34
36
|
});
|
|
35
37
|
}
|
|
38
|
+
if (measurementTypeKey === MeasurementTypeKey.ecg) {
|
|
39
|
+
return convertEcgSamplesToObservation(props);
|
|
40
|
+
}
|
|
36
41
|
const service = ObservationServiceCreator.getInstance().getService(measurementTypeKey);
|
|
37
42
|
const measurement = service.convertSamplesToMeasurement(data);
|
|
38
43
|
if (!measurement) {
|
|
@@ -41,19 +46,6 @@ export const convertSamplesToObservation = async props => {
|
|
|
41
46
|
const observationBody = await client.measurements.build({
|
|
42
47
|
measurement
|
|
43
48
|
});
|
|
44
|
-
return toCoreHealthObservations(observationBody, props, index =>
|
|
45
|
-
const sample = data?.[index];
|
|
46
|
-
return {
|
|
47
|
-
device: sample ? getHealthObservationDevice({
|
|
48
|
-
manufacturer: sample.device?.manufacturer,
|
|
49
|
-
model: sample.device?.model,
|
|
50
|
-
sourceApp: sample.sourceRevision?.source?.name
|
|
51
|
-
}) : undefined,
|
|
52
|
-
timing: {
|
|
53
|
-
start: sample?.startDate,
|
|
54
|
-
end: sample?.endDate
|
|
55
|
-
}
|
|
56
|
-
};
|
|
57
|
-
});
|
|
49
|
+
return toCoreHealthObservations(observationBody, props, index => getHealthKitSampleSource(data[index]));
|
|
58
50
|
};
|
|
59
51
|
//# sourceMappingURL=convert-samples-to-observation.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["ObservationServiceCreator","convertGenericHealthDataToObservation","
|
|
1
|
+
{"version":3,"names":["ObservationServiceCreator","MeasurementTypeKey","convertEcgSamplesToObservation","convertGenericHealthDataToObservation","getHealthKitSampleSource","hasConfiguredNonLoincCoding","isCoreMeasurementTypeKey","toCoreHealthObservations","convertSamplesToObservation","props","data","client","measurementTypeKey","mode","length","ecg","service","getInstance","getService","measurement","convertSamplesToMeasurement","observationBody","measurements","build","index"],"sourceRoot":"../../../../../src","sources":["modules/data-sync/utils/convert-samples-to-observation.ts"],"mappings":";;AACA,SAASA,yBAAyB,QAAQ,qDAAqD;AAC/F,SAASC,kBAAkB,QAAQ,iBAAiB;AAMpD,SAASC,8BAA8B,QAAQ,yCAAsC;AACrF,SAASC,qCAAqC,QAAQ,kCAA+B;AACrF,SACEC,wBAAwB,QAEnB,8BAA2B;AAClC,SAASC,2BAA2B,QAAQ,wCAAqC;AACjF,SACEC,wBAAwB,EACxBC,wBAAwB,QACnB,kCAA+B;AAEtC,OAAO,MAAMC,2BAA2B,GAAG,MACzCC,KAAgC,IACL;EAC3B,MAAM;IAAEC,IAAI;IAAEC,MAAM;IAAEC,kBAAkB;IAAEC,IAAI,GAAG;EAAQ,CAAC,GAAGJ,KAAK;EAElE,IAAII,IAAI,KAAK,OAAO,EAAE;IACpB,OAAOV,qCAAqC,CAAC;MAAE,GAAGM,KAAK;MAAEI;IAAK,CAAC,CAAC;EAClE;EAEA,IAAIH,IAAI,CAACI,MAAM,KAAK,CAAC,EAAE;IACrB,OAAO,EAAE;EACX;EAEA,IAAIT,2BAA2B,CAACI,KAAK,CAAC,EAAE;IACtC,OAAON,qCAAqC,CAAC;MAAE,GAAGM,KAAK;MAAEI;IAAK,CAAC,CAAC;EAClE;EAEA,IAAI,CAACP,wBAAwB,CAACM,kBAAkB,CAAC,EAAE;IACjD,OAAOT,qCAAqC,CAAC;MAAE,GAAGM,KAAK;MAAEI;IAAK,CAAC,CAAC;EAClE;EAEA,IAAID,kBAAkB,KAAKX,kBAAkB,CAACc,GAAG,EAAE;IACjD,OAAOb,8BAA8B,CAACO,KAAK,CAAC;EAC9C;EAEA,MAAMO,OAAO,GAAGhB,yBAAyB,CAACiB,WAAW,CAAC,CAAC,CAACC,UAAU,CAChEN,kBACF,CAAC;EAED,MAAMO,WAAW,GAAGH,OAAO,CAACI,2BAA2B,CACrDV,IACF,CAAC;EAED,IAAI,CAACS,WAAW,EAAE;IAChB,OAAO,EAAE;EACX;EAEA,MAAME,eAAe,GAAG,MAAMV,MAAM,CAACW,YAAY,CAACC,KAAK,CAAC;IACtDJ;EACF,CAAC,CAAC;EAEF,OAAOZ,wBAAwB,CAACc,eAAe,EAAEZ,KAAK,EAAGe,KAAK,IAC5DpB,wBAAwB,CAACM,IAAI,CAACc,KAAK,CAAsC,CAC3E,CAAC;AACH,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { ObservationCode } from "@ovok/core/next";
|
|
4
|
+
import { HealthDataType } from "../types/health-sync-keys.js";
|
|
5
|
+
import { LOINC_SYSTEM } from "./fhir-systems.js";
|
|
6
|
+
import { getHealthDataCoding } from "./health-data-catalog.js";
|
|
7
|
+
import { isCoreMeasurementTypeKey } from "./to-core-health-observations.js";
|
|
8
|
+
|
|
9
|
+
/** The code @ovok/core gives each core measurement, by the Apple Health or Health Connect type it is imported from. */
|
|
10
|
+
const CORE_MEASUREMENT_CODES = {
|
|
11
|
+
HKQuantityTypeIdentifierBloodPressureSystolic: ObservationCode.SYSTOLIC_BLOOD_PRESSURE,
|
|
12
|
+
HKQuantityTypeIdentifierBloodPressureDiastolic: ObservationCode.DIASTOLIC_BLOOD_PRESSURE,
|
|
13
|
+
HKQuantityTypeIdentifierHeartRate: ObservationCode.HEART_RATE,
|
|
14
|
+
HKQuantityTypeIdentifierBloodGlucose: ObservationCode.BLOOD_GLUCOSE,
|
|
15
|
+
HKQuantityTypeIdentifierBodyMass: ObservationCode.BODY_WEIGHT,
|
|
16
|
+
HKQuantityTypeIdentifierOxygenSaturation: ObservationCode.OXYGEN_SATURATION,
|
|
17
|
+
HKQuantityTypeIdentifierRespiratoryRate: ObservationCode.RESPIRATORY_RATE,
|
|
18
|
+
HKQuantityTypeIdentifierBodyTemperature: ObservationCode.BODY_TEMPERATURE,
|
|
19
|
+
HKQuantityTypeIdentifierStepCount: ObservationCode.STEPS,
|
|
20
|
+
HKQuantityTypeIdentifierHeartRateVariabilitySDNN: ObservationCode.HEART_RATE_VARIABILITY,
|
|
21
|
+
HKQuantityTypeIdentifierRestingHeartRate: ObservationCode.RESTING_HEART_RATE,
|
|
22
|
+
HKQuantityTypeIdentifierWalkingHeartRateAverage: ObservationCode.WALKING_HEART_RATE_AVERAGE,
|
|
23
|
+
HKQuantityTypeIdentifierVO2Max: ObservationCode.VO2_MAX,
|
|
24
|
+
HKElectrocardiogramType: ObservationCode.ECG,
|
|
25
|
+
BloodPressure: ObservationCode.SYSTOLIC_BLOOD_PRESSURE,
|
|
26
|
+
HeartRate: ObservationCode.HEART_RATE,
|
|
27
|
+
BloodGlucose: ObservationCode.BLOOD_GLUCOSE,
|
|
28
|
+
Weight: ObservationCode.BODY_WEIGHT,
|
|
29
|
+
OxygenSaturation: ObservationCode.OXYGEN_SATURATION,
|
|
30
|
+
RespiratoryRate: ObservationCode.RESPIRATORY_RATE,
|
|
31
|
+
BodyTemperature: ObservationCode.BODY_TEMPERATURE,
|
|
32
|
+
Steps: ObservationCode.STEPS,
|
|
33
|
+
RestingHeartRate: ObservationCode.RESTING_HEART_RATE,
|
|
34
|
+
Vo2Max: ObservationCode.VO2_MAX
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
/** Health Connect records that feed more than one data type: each type is coded by the record field it reads. */
|
|
38
|
+
const SHARED_RECORD_FIELDS = {
|
|
39
|
+
Nutrition: {
|
|
40
|
+
[HealthDataType.carbohydrates]: "totalCarbohydrate",
|
|
41
|
+
[HealthDataType.caloriesEaten]: "energy"
|
|
42
|
+
},
|
|
43
|
+
ExerciseSession: {
|
|
44
|
+
[HealthDataType.exerciseMinutes]: "duration"
|
|
45
|
+
}
|
|
46
|
+
};
|
|
47
|
+
|
|
48
|
+
/** The coding a type is saved under when the app names none: core's own code for a core measurement, else the catalog's. */
|
|
49
|
+
const getDefaultHealthCoding = (provider, key, identifier, mode) => {
|
|
50
|
+
const coreCode = isCoreMeasurementTypeKey(key) ? CORE_MEASUREMENT_CODES[identifier] : undefined;
|
|
51
|
+
if (coreCode) {
|
|
52
|
+
return {
|
|
53
|
+
code: coreCode,
|
|
54
|
+
system: LOINC_SYSTEM
|
|
55
|
+
};
|
|
56
|
+
}
|
|
57
|
+
const coding = getHealthDataCoding(provider, identifier, mode);
|
|
58
|
+
const field = SHARED_RECORD_FIELDS[identifier]?.[key];
|
|
59
|
+
return field ? {
|
|
60
|
+
code: `${coding.code}.${field}`,
|
|
61
|
+
system: coding.system
|
|
62
|
+
} : coding;
|
|
63
|
+
};
|
|
64
|
+
export { getDefaultHealthCoding };
|
|
65
|
+
//# sourceMappingURL=default-health-coding.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["ObservationCode","HealthDataType","LOINC_SYSTEM","getHealthDataCoding","isCoreMeasurementTypeKey","CORE_MEASUREMENT_CODES","HKQuantityTypeIdentifierBloodPressureSystolic","SYSTOLIC_BLOOD_PRESSURE","HKQuantityTypeIdentifierBloodPressureDiastolic","DIASTOLIC_BLOOD_PRESSURE","HKQuantityTypeIdentifierHeartRate","HEART_RATE","HKQuantityTypeIdentifierBloodGlucose","BLOOD_GLUCOSE","HKQuantityTypeIdentifierBodyMass","BODY_WEIGHT","HKQuantityTypeIdentifierOxygenSaturation","OXYGEN_SATURATION","HKQuantityTypeIdentifierRespiratoryRate","RESPIRATORY_RATE","HKQuantityTypeIdentifierBodyTemperature","BODY_TEMPERATURE","HKQuantityTypeIdentifierStepCount","STEPS","HKQuantityTypeIdentifierHeartRateVariabilitySDNN","HEART_RATE_VARIABILITY","HKQuantityTypeIdentifierRestingHeartRate","RESTING_HEART_RATE","HKQuantityTypeIdentifierWalkingHeartRateAverage","WALKING_HEART_RATE_AVERAGE","HKQuantityTypeIdentifierVO2Max","VO2_MAX","HKElectrocardiogramType","ECG","BloodPressure","HeartRate","BloodGlucose","Weight","OxygenSaturation","RespiratoryRate","BodyTemperature","Steps","RestingHeartRate","Vo2Max","SHARED_RECORD_FIELDS","Nutrition","carbohydrates","caloriesEaten","ExerciseSession","exerciseMinutes","getDefaultHealthCoding","provider","key","identifier","mode","coreCode","undefined","code","system","coding","field"],"sourceRoot":"../../../../../src","sources":["modules/data-sync/utils/default-health-coding.ts"],"mappings":";;AAAA,SAASA,eAAe,QAAQ,iBAAiB;AAGjD,SAAyBC,cAAc,QAAuB,8BAA2B;AAEzF,SAASC,YAAY,QAAQ,mBAAgB;AAC7C,SAASC,mBAAmB,QAAQ,0BAAuB;AAC3D,SAASC,wBAAwB,QAAQ,kCAA+B;;AAExE;AACA,MAAMC,sBAA0E,GAAG;EACjFC,6CAA6C,EAAEN,eAAe,CAACO,uBAAuB;EACtFC,8CAA8C,EAAER,eAAe,CAACS,wBAAwB;EACxFC,iCAAiC,EAAEV,eAAe,CAACW,UAAU;EAC7DC,oCAAoC,EAAEZ,eAAe,CAACa,aAAa;EACnEC,gCAAgC,EAAEd,eAAe,CAACe,WAAW;EAC7DC,wCAAwC,EAAEhB,eAAe,CAACiB,iBAAiB;EAC3EC,uCAAuC,EAAElB,eAAe,CAACmB,gBAAgB;EACzEC,uCAAuC,EAAEpB,eAAe,CAACqB,gBAAgB;EACzEC,iCAAiC,EAAEtB,eAAe,CAACuB,KAAK;EACxDC,gDAAgD,EAAExB,eAAe,CAACyB,sBAAsB;EACxFC,wCAAwC,EAAE1B,eAAe,CAAC2B,kBAAkB;EAC5EC,+CAA+C,EAAE5B,eAAe,CAAC6B,0BAA0B;EAC3FC,8BAA8B,EAAE9B,eAAe,CAAC+B,OAAO;EACvDC,uBAAuB,EAAEhC,eAAe,CAACiC,GAAG;EAC5CC,aAAa,EAAElC,eAAe,CAACO,uBAAuB;EACtD4B,SAAS,EAAEnC,eAAe,CAACW,UAAU;EACr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ignoreList":[]}
|
|
@@ -5,18 +5,20 @@
|
|
|
5
5
|
import { startOfDay, subDays } from "date-fns";
|
|
6
6
|
import { aggregateGroupByPeriod, getChanges, readRecords } from "react-native-health-connect";
|
|
7
7
|
import { DEFAULT_HEALTH_SYNC_CHUNK_SIZE, DEFAULT_SYNC_LOOKBACK_DAYS } from "../constants.js";
|
|
8
|
+
import { HealthDataType } from "../types/health-sync-keys.js";
|
|
8
9
|
import { getHealthConnectSeries } from "./health-connect-series.js";
|
|
9
10
|
import { isDailyAggregateMode } from "./is-daily-aggregate-mode.js";
|
|
10
11
|
import { syncWindowStart } from "./sync-window-start.js";
|
|
11
12
|
export const getRecordsFromHealthConnect = async ({
|
|
12
13
|
typeIdentifier,
|
|
14
|
+
key,
|
|
13
15
|
startDate: _startDate,
|
|
14
16
|
chunkSize = DEFAULT_HEALTH_SYNC_CHUNK_SIZE,
|
|
15
17
|
anchor,
|
|
16
18
|
mode = "point"
|
|
17
19
|
}) => {
|
|
18
20
|
if (isDailyAggregateMode(mode)) {
|
|
19
|
-
return getDailyAggregates(typeIdentifier, mode, _startDate);
|
|
21
|
+
return getDailyAggregates(typeIdentifier, mode, _startDate, key);
|
|
20
22
|
}
|
|
21
23
|
if (mode === "series") {
|
|
22
24
|
return getHealthConnectSeries(typeIdentifier, syncWindowStart(_startDate));
|
|
@@ -133,7 +135,7 @@ const decodeAnchor = anchor => {
|
|
|
133
135
|
return undefined;
|
|
134
136
|
}
|
|
135
137
|
};
|
|
136
|
-
const getDailyAggregates = async (typeIdentifier, mode, _startDate) => {
|
|
138
|
+
const getDailyAggregates = async (typeIdentifier, mode, _startDate, key) => {
|
|
137
139
|
const aggregateType = typeIdentifier;
|
|
138
140
|
const startDate = _startDate ? startOfDay(new Date(_startDate)) : startOfDay(subDays(new Date(), DEFAULT_SYNC_LOOKBACK_DAYS));
|
|
139
141
|
const today = startOfDay(new Date());
|
|
@@ -155,7 +157,7 @@ const getDailyAggregates = async (typeIdentifier, mode, _startDate) => {
|
|
|
155
157
|
return [];
|
|
156
158
|
}
|
|
157
159
|
const result = group.result;
|
|
158
|
-
const measurement = aggregateMeasurement(typeIdentifier, result, mode);
|
|
160
|
+
const measurement = aggregateMeasurement(typeIdentifier, result, mode, key);
|
|
159
161
|
if (!measurement) {
|
|
160
162
|
return [];
|
|
161
163
|
}
|
|
@@ -174,7 +176,7 @@ const getDailyAggregates = async (typeIdentifier, mode, _startDate) => {
|
|
|
174
176
|
anchor: undefined
|
|
175
177
|
};
|
|
176
178
|
};
|
|
177
|
-
const aggregateMeasurement = (typeIdentifier, result, mode) => {
|
|
179
|
+
const aggregateMeasurement = (typeIdentifier, result, mode, key) => {
|
|
178
180
|
if (mode === "daily-summary" && typeIdentifier === "HeartRate") {
|
|
179
181
|
const average = numberValue(result.BPM_AVG);
|
|
180
182
|
return average === undefined ? undefined : {
|
|
@@ -195,10 +197,24 @@ const aggregateMeasurement = (typeIdentifier, result, mode) => {
|
|
|
195
197
|
return value(numberValue(result.FLOORS_CLIMBED_TOTAL), "count");
|
|
196
198
|
case "ExerciseSession":
|
|
197
199
|
return value(scale(nestedNumber(result.EXERCISE_DURATION_TOTAL, "inSeconds"), 1 / 60), "min");
|
|
200
|
+
case "Hydration":
|
|
201
|
+
return value(nestedNumber(result.VOLUME_TOTAL, "inMilliliters"), "mL");
|
|
202
|
+
case "Nutrition":
|
|
203
|
+
return nutrientTotal(result, key);
|
|
198
204
|
default:
|
|
199
205
|
return undefined;
|
|
200
206
|
}
|
|
201
207
|
};
|
|
208
|
+
|
|
209
|
+
/** The nutrient each data type reads from Health Connect's Nutrition record: its daily total and that total's unit. */
|
|
210
|
+
const NUTRIENT_TOTALS = {
|
|
211
|
+
[HealthDataType.carbohydrates]: ["TOTAL_CARBOHYDRATE_TOTAL", "inGrams", "g"],
|
|
212
|
+
[HealthDataType.caloriesEaten]: ["ENERGY_TOTAL", "inKilocalories", "kcal"]
|
|
213
|
+
};
|
|
214
|
+
const nutrientTotal = (result, key) => {
|
|
215
|
+
const nutrient = key && NUTRIENT_TOTALS[key];
|
|
216
|
+
return nutrient && value(nestedNumber(result[nutrient[0]], nutrient[1]), nutrient[2]);
|
|
217
|
+
};
|
|
202
218
|
const value = (measurement, unit) => measurement === undefined ? undefined : {
|
|
203
219
|
unit,
|
|
204
220
|
value: measurement
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["startOfDay","subDays","aggregateGroupByPeriod","getChanges","readRecords","DEFAULT_HEALTH_SYNC_CHUNK_SIZE","DEFAULT_SYNC_LOOKBACK_DAYS","getHealthConnectSeries","isDailyAggregateMode","syncWindowStart","getRecordsFromHealthConnect","typeIdentifier","startDate","_startDate","chunkSize","anchor","mode","getDailyAggregates","savedAnchor","decodeAnchor","phase","changes","changesToken","recordTypes","changesTokenExpired","data","upsertionChanges","map","record","deletionChanges","length","deletedRecordIds","recordId","hasMore","encodeAnchor","version","nextChangesToken","baseline","readSnapshot","pageToken","undefined","snapshotAnchor","endDate","Date","toISOString","resolvedStartDate","result","timeRangeFilter","operator","startTime","endTime","pageSize","nextAnchor","records","Boolean","JSON","stringify","startsWith","parsed","parse","aggregateType","today","groups","recordType","timeRangeSlicer","period","flatMap","group","end","measurement","aggregateMeasurement","dataOrigins","kind","sourceApp","average","numberValue","BPM_AVG","unit","minimum","BPM_MIN","maximum","BPM_MAX","value","COUNT_TOTAL","nestedNumber","DISTANCE","ACTIVE_CALORIES_TOTAL","FLOORS_CLIMBED_TOTAL","scale","EXERCISE_DURATION_TOTAL","
|
|
1
|
+
{"version":3,"names":["startOfDay","subDays","aggregateGroupByPeriod","getChanges","readRecords","DEFAULT_HEALTH_SYNC_CHUNK_SIZE","DEFAULT_SYNC_LOOKBACK_DAYS","HealthDataType","getHealthConnectSeries","isDailyAggregateMode","syncWindowStart","getRecordsFromHealthConnect","typeIdentifier","key","startDate","_startDate","chunkSize","anchor","mode","getDailyAggregates","savedAnchor","decodeAnchor","phase","changes","changesToken","recordTypes","changesTokenExpired","data","upsertionChanges","map","record","deletionChanges","length","deletedRecordIds","recordId","hasMore","encodeAnchor","version","nextChangesToken","baseline","readSnapshot","pageToken","undefined","snapshotAnchor","endDate","Date","toISOString","resolvedStartDate","result","timeRangeFilter","operator","startTime","endTime","pageSize","nextAnchor","records","Boolean","JSON","stringify","startsWith","parsed","parse","aggregateType","today","groups","recordType","timeRangeSlicer","period","flatMap","group","end","measurement","aggregateMeasurement","dataOrigins","kind","sourceApp","average","numberValue","BPM_AVG","unit","minimum","BPM_MIN","maximum","BPM_MAX","value","COUNT_TOTAL","nestedNumber","DISTANCE","ACTIVE_CALORIES_TOTAL","FLOORS_CLIMBED_TOTAL","scale","EXERCISE_DURATION_TOTAL","VOLUME_TOTAL","nutrientTotal","NUTRIENT_TOTALS","carbohydrates","caloriesEaten","nutrient","Number","isFinite","factor"],"sourceRoot":"../../../../../src","sources":["modules/data-sync/utils/get-records-from-health-connect.ts"],"mappings":";;AAAA;;AAEA,SAASA,UAAU,EAAEC,OAAO,QAAQ,UAAU;AAC9C,SACEC,sBAAsB,EAEtBC,UAAU,EACVC,WAAW,QAGN,6BAA6B;AAEpC,SAASC,8BAA8B,EAAEC,0BAA0B,QAAQ,iBAAc;AAIzF,SAAyBC,cAAc,QAAuB,8BAA2B;AAEzF,SAASC,sBAAsB,QAAQ,4BAAyB;AAChE,SAASC,oBAAoB,QAAQ,8BAA2B;AAChE,SAASC,eAAe,QAAQ,wBAAqB;AAOrD,OAAO,MAAMC,2BAA2B,GAAG,MAAAA,CAAO;EAChDC,cAAc;EACdC,GAAG;EACHC,SAAS,EAAEC,UAAU;EACrBC,SAAS,GAAGX,8BAA8B;EAC1CY,MAAM;EACNC,IAAI,GAAG;AAC6B,CAAC,KAElC;EACH,IAAIT,oBAAoB,CAACS,IAAI,CAAC,EAAE;IAC9B,OAAOC,kBAAkB,CAACP,cAAc,EAAEM,IAAI,EAAEH,UAAU,EAAEF,GAAG,CAAC;EAClE;EAEA,IAAIK,IAAI,KAAK,QAAQ,EAAE;I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