@ovok/native 1.10.2 → 1.10.4
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/README.md +5 -5
- package/lib/commonjs/modules/auth/default-translation.js +22 -0
- package/lib/commonjs/modules/auth/default-translation.js.map +1 -1
- package/lib/commonjs/modules/auth/hooks/use-session.js +3 -0
- package/lib/commonjs/modules/auth/hooks/use-session.js.map +1 -1
- package/lib/commonjs/modules/auth/profile/components/profile-form-provider.js +3 -6
- package/lib/commonjs/modules/auth/profile/components/profile-form-provider.js.map +1 -1
- package/lib/commonjs/modules/auth/register/components/form/register-form-provider.js +1 -0
- package/lib/commonjs/modules/auth/register/components/form/register-form-provider.js.map +1 -1
- package/lib/commonjs/modules/auth/reset-password/components/form/reset-password-form-provider.js +4 -3
- package/lib/commonjs/modules/auth/reset-password/components/form/reset-password-form-provider.js.map +1 -1
- package/lib/commonjs/modules/auth/session/logout-session.js +5 -2
- package/lib/commonjs/modules/auth/session/logout-session.js.map +1 -1
- package/lib/commonjs/modules/auth/session/session-store-refresh.js +125 -0
- package/lib/commonjs/modules/auth/session/session-store-refresh.js.map +1 -0
- package/lib/commonjs/modules/auth/session/session-store-request-state.js +73 -0
- package/lib/commonjs/modules/auth/session/session-store-request-state.js.map +1 -0
- package/lib/commonjs/modules/auth/session/session-store-types.js +17 -0
- package/lib/commonjs/modules/auth/session/session-store-types.js.map +1 -0
- package/lib/commonjs/modules/auth/session/session-store.js +56 -123
- package/lib/commonjs/modules/auth/session/session-store.js.map +1 -1
- package/lib/commonjs/modules/auth/utils/sign-in-error.js +10 -4
- package/lib/commonjs/modules/auth/utils/sign-in-error.js.map +1 -1
- package/lib/commonjs/modules/bt-management/components/bt-provider-child-wrapper.js +5 -0
- package/lib/commonjs/modules/bt-management/components/bt-provider-child-wrapper.js.map +1 -1
- package/lib/commonjs/modules/bt-management/hooks/declined-device-storage.js +36 -1
- package/lib/commonjs/modules/bt-management/hooks/declined-device-storage.js.map +1 -1
- package/lib/commonjs/modules/bt-management/hooks/nearby-device-offer-state.js +25 -0
- package/lib/commonjs/modules/bt-management/hooks/nearby-device-offer-state.js.map +1 -0
- package/lib/commonjs/modules/bt-management/hooks/nearby-device-offer-types.js +6 -0
- package/lib/commonjs/modules/bt-management/hooks/nearby-device-offer-types.js.map +1 -0
- package/lib/commonjs/modules/bt-management/hooks/use-nearby-device-offer.js +22 -36
- package/lib/commonjs/modules/bt-management/hooks/use-nearby-device-offer.js.map +1 -1
- package/lib/commonjs/modules/bt-management/services/background-sync/background-sync-coordinator.js +11 -0
- package/lib/commonjs/modules/bt-management/services/background-sync/background-sync-coordinator.js.map +1 -1
- package/lib/commonjs/modules/data-sync/components/apple/apple-health-authorization-provider.js.map +1 -1
- package/lib/commonjs/modules/data-sync/hooks/use-listen-changes.js.map +1 -1
- package/lib/commonjs/modules/data-sync/services/apple-health-sync-service.js.map +1 -1
- package/lib/commonjs/modules/data-sync/utils/convert-generic-health-data.js +74 -34
- package/lib/commonjs/modules/data-sync/utils/convert-generic-health-data.js.map +1 -1
- package/lib/commonjs/modules/data-sync/utils/convert-records-to-observation.js +19 -16
- package/lib/commonjs/modules/data-sync/utils/convert-records-to-observation.js.map +1 -1
- package/lib/commonjs/modules/data-sync/utils/convert-samples-to-observation.js +17 -4
- package/lib/commonjs/modules/data-sync/utils/convert-samples-to-observation.js.map +1 -1
- 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.map +1 -1
- package/lib/commonjs/modules/data-sync/utils/health-data-catalog.js +219 -16
- package/lib/commonjs/modules/data-sync/utils/health-data-catalog.js.map +1 -1
- package/lib/commonjs/modules/data-sync/utils/health-record-timing.js +52 -0
- package/lib/commonjs/modules/data-sync/utils/health-record-timing.js.map +1 -0
- package/lib/commonjs/modules/data-sync/utils/health-units.js +1 -0
- package/lib/commonjs/modules/data-sync/utils/health-units.js.map +1 -1
- package/lib/commonjs/modules/data-sync/utils/healthkit-data-types.js.map +1 -1
- package/lib/commonjs/modules/data-sync/utils/normalize-core-health-observation.js +74 -0
- package/lib/commonjs/modules/data-sync/utils/normalize-core-health-observation.js.map +1 -0
- package/lib/commonjs/modules/picker-sheet/components/value-wheel-picker.js +41 -0
- package/lib/commonjs/modules/picker-sheet/components/value-wheel-picker.js.map +1 -0
- package/lib/commonjs/modules/picker-sheet/components/wheel-picker.js +56 -15
- package/lib/commonjs/modules/picker-sheet/components/wheel-picker.js.map +1 -1
- package/lib/commonjs/modules/picker-sheet/index.js +11 -0
- package/lib/commonjs/modules/picker-sheet/index.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/README.md +59 -20
- package/lib/commonjs/modules/questionnaire-response-form/components/content/questionnaire-content-item.js +8 -0
- package/lib/commonjs/modules/questionnaire-response-form/components/content/questionnaire-content-item.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/components/content/questionnaire-content-specific-item.js +8 -0
- package/lib/commonjs/modules/questionnaire-response-form/components/content/questionnaire-content-specific-item.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/components/fields/common/questionnaire-field-wrapper.js +8 -3
- package/lib/commonjs/modules/questionnaire-response-form/components/fields/common/questionnaire-field-wrapper.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/components/fields/questionnaire-choice-field.js +9 -3
- package/lib/commonjs/modules/questionnaire-response-form/components/fields/questionnaire-choice-field.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/components/fields/questionnaire-date-field.js +18 -8
- package/lib/commonjs/modules/questionnaire-response-form/components/fields/questionnaire-date-field.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/components/fields/questionnaire-item-renderer.js +41 -2
- package/lib/commonjs/modules/questionnaire-response-form/components/fields/questionnaire-item-renderer.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/components/fields/questionnaire-text-field.js +43 -5
- package/lib/commonjs/modules/questionnaire-response-form/components/fields/questionnaire-text-field.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/components/header/questionnaire-header-title.js +3 -1
- package/lib/commonjs/modules/questionnaire-response-form/components/header/questionnaire-header-title.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/components/questionnaire-form-provider.js +37 -11
- package/lib/commonjs/modules/questionnaire-response-form/components/questionnaire-form-provider.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/components/questionnaire-form.js +1 -0
- package/lib/commonjs/modules/questionnaire-response-form/components/questionnaire-form.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/components/questionnaire-navigation-provider.js +9 -3
- package/lib/commonjs/modules/questionnaire-response-form/components/questionnaire-navigation-provider.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/hooks/use-initial-selected-values.js +5 -3
- package/lib/commonjs/modules/questionnaire-response-form/hooks/use-initial-selected-values.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/hooks/use-navigation-handlers.js +15 -4
- package/lib/commonjs/modules/questionnaire-response-form/hooks/use-navigation-handlers.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/hooks/use-questionnaire-navigation-state.js +14 -7
- package/lib/commonjs/modules/questionnaire-response-form/hooks/use-questionnaire-navigation-state.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/index.js +20 -0
- package/lib/commonjs/modules/questionnaire-response-form/index.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/types/questionnaire-form-values.js +4 -0
- package/lib/commonjs/modules/questionnaire-response-form/types/questionnaire-item-render-props.js +6 -0
- package/lib/commonjs/modules/questionnaire-response-form/types/questionnaire-item-render-props.js.map +1 -0
- package/lib/commonjs/modules/questionnaire-response-form/types/response-values.js +4 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/condition-utils.js +37 -6
- package/lib/commonjs/modules/questionnaire-response-form/utils/condition-utils.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/utils/conditions/fhir-condition.js +148 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/conditions/fhir-condition.js.map +1 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/create-answer-from-value.js +127 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/create-answer-from-value.js.map +1 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/fields/get-option-text.js +4 -3
- package/lib/commonjs/modules/questionnaire-response-form/utils/fields/get-option-text.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/utils/form-utils.js +71 -64
- package/lib/commonjs/modules/questionnaire-response-form/utils/form-utils.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/utils/form-validation.js +23 -5
- package/lib/commonjs/modules/questionnaire-response-form/utils/form-validation.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/utils/is-answerable-questionnaire-item.js +10 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/is-answerable-questionnaire-item.js.map +1 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/is-valid-questionnaire-answer.js +83 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/is-valid-questionnaire-answer.js.map +1 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/questionnaire-date-utils.js +54 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/questionnaire-date-utils.js.map +1 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/questionnaire-item-constraints.js +75 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/questionnaire-item-constraints.js.map +1 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/questionnaire-item-value-constraint-validators.js +63 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/questionnaire-item-value-constraint-validators.js.map +1 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/questionnaire-navigation-utils.js +49 -18
- package/lib/commonjs/modules/questionnaire-response-form/utils/questionnaire-navigation-utils.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/utils/questionnaire-picker-options.js +117 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/questionnaire-picker-options.js.map +1 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/questionnaire-string-constraint-validator.js +109 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/questionnaire-string-constraint-validator.js.map +1 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/questionnaire-submit-utils.js +2 -2
- package/lib/commonjs/modules/questionnaire-response-form/utils/questionnaire-submit-utils.js.map +1 -1
- package/lib/commonjs/modules/questionnaire-response-form/utils/translate-fhir-text.js +36 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/translate-fhir-text.js.map +1 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/validate-questionnaire-item-value.js +49 -0
- package/lib/commonjs/modules/questionnaire-response-form/utils/validate-questionnaire-item-value.js.map +1 -0
- package/lib/commonjs/modules/ui/components/bluetooth-state-notice.js +31 -15
- package/lib/commonjs/modules/ui/components/bluetooth-state-notice.js.map +1 -1
- package/lib/commonjs/modules/ui/components/prerequisite-gate.js +73 -0
- package/lib/commonjs/modules/ui/components/prerequisite-gate.js.map +1 -0
- package/lib/commonjs/modules/ui/default-translation.js +50 -0
- package/lib/commonjs/modules/ui/default-translation.js.map +1 -0
- package/lib/commonjs/modules/ui/index.js +11 -0
- package/lib/commonjs/modules/ui/index.js.map +1 -1
- package/lib/commonjs/polyfills/index.js +9 -7
- package/lib/commonjs/polyfills/index.js.map +1 -1
- package/lib/module/modules/auth/default-translation.js +22 -0
- package/lib/module/modules/auth/default-translation.js.map +1 -1
- package/lib/module/modules/auth/hooks/use-session.js +3 -0
- package/lib/module/modules/auth/hooks/use-session.js.map +1 -1
- package/lib/module/modules/auth/profile/components/profile-form-provider.js +3 -6
- package/lib/module/modules/auth/profile/components/profile-form-provider.js.map +1 -1
- package/lib/module/modules/auth/register/components/form/register-form-provider.js +1 -0
- package/lib/module/modules/auth/register/components/form/register-form-provider.js.map +1 -1
- package/lib/module/modules/auth/reset-password/components/form/reset-password-form-provider.js +3 -3
- package/lib/module/modules/auth/reset-password/components/form/reset-password-form-provider.js.map +1 -1
- package/lib/module/modules/auth/session/logout-session.js +5 -2
- package/lib/module/modules/auth/session/logout-session.js.map +1 -1
- package/lib/module/modules/auth/session/session-store-refresh.js +121 -0
- package/lib/module/modules/auth/session/session-store-refresh.js.map +1 -0
- package/lib/module/modules/auth/session/session-store-request-state.js +69 -0
- package/lib/module/modules/auth/session/session-store-request-state.js.map +1 -0
- package/lib/module/modules/auth/session/session-store-types.js +13 -0
- package/lib/module/modules/auth/session/session-store-types.js.map +1 -0
- package/lib/module/modules/auth/session/session-store.js +56 -123
- package/lib/module/modules/auth/session/session-store.js.map +1 -1
- package/lib/module/modules/auth/utils/sign-in-error.js +9 -4
- package/lib/module/modules/auth/utils/sign-in-error.js.map +1 -1
- package/lib/module/modules/bt-management/components/bt-provider-child-wrapper.js +5 -0
- package/lib/module/modules/bt-management/components/bt-provider-child-wrapper.js.map +1 -1
- package/lib/module/modules/bt-management/hooks/declined-device-storage.js +33 -1
- package/lib/module/modules/bt-management/hooks/declined-device-storage.js.map +1 -1
- package/lib/module/modules/bt-management/hooks/nearby-device-offer-state.js +20 -0
- package/lib/module/modules/bt-management/hooks/nearby-device-offer-state.js.map +1 -0
- package/lib/module/modules/bt-management/hooks/nearby-device-offer-types.js +4 -0
- package/lib/module/modules/bt-management/hooks/nearby-device-offer-types.js.map +1 -0
- package/lib/module/modules/bt-management/hooks/use-nearby-device-offer.js +21 -35
- package/lib/module/modules/bt-management/hooks/use-nearby-device-offer.js.map +1 -1
- package/lib/module/modules/bt-management/services/background-sync/background-sync-coordinator.js +11 -0
- package/lib/module/modules/bt-management/services/background-sync/background-sync-coordinator.js.map +1 -1
- package/lib/module/modules/data-sync/components/apple/apple-health-authorization-provider.js.map +1 -1
- package/lib/module/modules/data-sync/hooks/use-listen-changes.js.map +1 -1
- package/lib/module/modules/data-sync/services/apple-health-sync-service.js.map +1 -1
- package/lib/module/modules/data-sync/utils/convert-generic-health-data.js +74 -34
- package/lib/module/modules/data-sync/utils/convert-generic-health-data.js.map +1 -1
- package/lib/module/modules/data-sync/utils/convert-records-to-observation.js +19 -16
- package/lib/module/modules/data-sync/utils/convert-records-to-observation.js.map +1 -1
- package/lib/module/modules/data-sync/utils/convert-samples-to-observation.js +17 -4
- package/lib/module/modules/data-sync/utils/convert-samples-to-observation.js.map +1 -1
- 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.map +1 -1
- package/lib/module/modules/data-sync/utils/health-data-catalog.js +219 -16
- package/lib/module/modules/data-sync/utils/health-data-catalog.js.map +1 -1
- package/lib/module/modules/data-sync/utils/health-record-timing.js +47 -0
- package/lib/module/modules/data-sync/utils/health-record-timing.js.map +1 -0
- package/lib/module/modules/data-sync/utils/health-units.js +1 -0
- package/lib/module/modules/data-sync/utils/health-units.js.map +1 -1
- package/lib/module/modules/data-sync/utils/healthkit-data-types.js.map +1 -1
- package/lib/module/modules/data-sync/utils/normalize-core-health-observation.js +69 -0
- package/lib/module/modules/data-sync/utils/normalize-core-health-observation.js.map +1 -0
- package/lib/module/modules/picker-sheet/components/value-wheel-picker.js +36 -0
- package/lib/module/modules/picker-sheet/components/value-wheel-picker.js.map +1 -0
- package/lib/module/modules/picker-sheet/components/wheel-picker.js +56 -15
- package/lib/module/modules/picker-sheet/components/wheel-picker.js.map +1 -1
- package/lib/module/modules/picker-sheet/index.js +1 -0
- package/lib/module/modules/picker-sheet/index.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/README.md +59 -20
- package/lib/module/modules/questionnaire-response-form/components/content/questionnaire-content-item.js +8 -0
- package/lib/module/modules/questionnaire-response-form/components/content/questionnaire-content-item.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/components/content/questionnaire-content-specific-item.js +8 -0
- package/lib/module/modules/questionnaire-response-form/components/content/questionnaire-content-specific-item.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/components/fields/common/questionnaire-field-wrapper.js +8 -3
- package/lib/module/modules/questionnaire-response-form/components/fields/common/questionnaire-field-wrapper.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/components/fields/questionnaire-choice-field.js +9 -3
- package/lib/module/modules/questionnaire-response-form/components/fields/questionnaire-choice-field.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/components/fields/questionnaire-date-field.js +18 -8
- package/lib/module/modules/questionnaire-response-form/components/fields/questionnaire-date-field.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/components/fields/questionnaire-item-renderer.js +42 -3
- package/lib/module/modules/questionnaire-response-form/components/fields/questionnaire-item-renderer.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/components/fields/questionnaire-text-field.js +41 -3
- package/lib/module/modules/questionnaire-response-form/components/fields/questionnaire-text-field.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/components/header/questionnaire-header-title.js +3 -1
- package/lib/module/modules/questionnaire-response-form/components/header/questionnaire-header-title.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/components/questionnaire-form-provider.js +37 -11
- package/lib/module/modules/questionnaire-response-form/components/questionnaire-form-provider.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/components/questionnaire-form.js +1 -0
- package/lib/module/modules/questionnaire-response-form/components/questionnaire-form.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/components/questionnaire-navigation-provider.js +9 -3
- package/lib/module/modules/questionnaire-response-form/components/questionnaire-navigation-provider.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/hooks/use-initial-selected-values.js +5 -3
- package/lib/module/modules/questionnaire-response-form/hooks/use-initial-selected-values.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/hooks/use-navigation-handlers.js +15 -4
- package/lib/module/modules/questionnaire-response-form/hooks/use-navigation-handlers.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/hooks/use-questionnaire-navigation-state.js +14 -7
- package/lib/module/modules/questionnaire-response-form/hooks/use-questionnaire-navigation-state.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/index.js +2 -0
- package/lib/module/modules/questionnaire-response-form/index.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/types/questionnaire-form-values.js +2 -0
- package/lib/module/modules/questionnaire-response-form/types/questionnaire-item-render-props.js +4 -0
- package/lib/module/modules/questionnaire-response-form/types/questionnaire-item-render-props.js.map +1 -0
- package/lib/module/modules/questionnaire-response-form/types/response-values.js +2 -0
- package/lib/module/modules/questionnaire-response-form/utils/condition-utils.js +37 -6
- package/lib/module/modules/questionnaire-response-form/utils/condition-utils.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/utils/conditions/fhir-condition.js +140 -0
- package/lib/module/modules/questionnaire-response-form/utils/conditions/fhir-condition.js.map +1 -0
- package/lib/module/modules/questionnaire-response-form/utils/create-answer-from-value.js +122 -0
- package/lib/module/modules/questionnaire-response-form/utils/create-answer-from-value.js.map +1 -0
- package/lib/module/modules/questionnaire-response-form/utils/fields/get-option-text.js +4 -3
- package/lib/module/modules/questionnaire-response-form/utils/fields/get-option-text.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/utils/form-utils.js +71 -64
- package/lib/module/modules/questionnaire-response-form/utils/form-utils.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/utils/form-validation.js +23 -5
- package/lib/module/modules/questionnaire-response-form/utils/form-validation.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/utils/is-answerable-questionnaire-item.js +5 -0
- package/lib/module/modules/questionnaire-response-form/utils/is-answerable-questionnaire-item.js.map +1 -0
- package/lib/module/modules/questionnaire-response-form/utils/is-valid-questionnaire-answer.js +77 -0
- package/lib/module/modules/questionnaire-response-form/utils/is-valid-questionnaire-answer.js.map +1 -0
- package/lib/module/modules/questionnaire-response-form/utils/questionnaire-date-utils.js +49 -0
- package/lib/module/modules/questionnaire-response-form/utils/questionnaire-date-utils.js.map +1 -0
- package/lib/module/modules/questionnaire-response-form/utils/questionnaire-item-constraints.js +71 -0
- package/lib/module/modules/questionnaire-response-form/utils/questionnaire-item-constraints.js.map +1 -0
- package/lib/module/modules/questionnaire-response-form/utils/questionnaire-item-value-constraint-validators.js +57 -0
- package/lib/module/modules/questionnaire-response-form/utils/questionnaire-item-value-constraint-validators.js.map +1 -0
- package/lib/module/modules/questionnaire-response-form/utils/questionnaire-navigation-utils.js +49 -18
- package/lib/module/modules/questionnaire-response-form/utils/questionnaire-navigation-utils.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/utils/questionnaire-picker-options.js +112 -0
- package/lib/module/modules/questionnaire-response-form/utils/questionnaire-picker-options.js.map +1 -0
- package/lib/module/modules/questionnaire-response-form/utils/questionnaire-string-constraint-validator.js +105 -0
- package/lib/module/modules/questionnaire-response-form/utils/questionnaire-string-constraint-validator.js.map +1 -0
- package/lib/module/modules/questionnaire-response-form/utils/questionnaire-submit-utils.js +2 -2
- package/lib/module/modules/questionnaire-response-form/utils/questionnaire-submit-utils.js.map +1 -1
- package/lib/module/modules/questionnaire-response-form/utils/translate-fhir-text.js +31 -0
- package/lib/module/modules/questionnaire-response-form/utils/translate-fhir-text.js.map +1 -0
- package/lib/module/modules/questionnaire-response-form/utils/validate-questionnaire-item-value.js +44 -0
- package/lib/module/modules/questionnaire-response-form/utils/validate-questionnaire-item-value.js.map +1 -0
- package/lib/module/modules/ui/components/bluetooth-state-notice.js +31 -15
- package/lib/module/modules/ui/components/bluetooth-state-notice.js.map +1 -1
- package/lib/module/modules/ui/components/prerequisite-gate.js +67 -0
- package/lib/module/modules/ui/components/prerequisite-gate.js.map +1 -0
- package/lib/module/modules/ui/default-translation.js +45 -0
- package/lib/module/modules/ui/default-translation.js.map +1 -0
- package/lib/module/modules/ui/index.js +1 -0
- package/lib/module/modules/ui/index.js.map +1 -1
- package/lib/module/polyfills/index.js +11 -1
- package/lib/module/polyfills/index.js.map +1 -1
- package/lib/typescript/commonjs/src/modules/auth/default-translation.d.ts +22 -0
- package/lib/typescript/commonjs/src/modules/auth/default-translation.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/auth/hooks/use-session.d.ts +4 -1
- package/lib/typescript/commonjs/src/modules/auth/hooks/use-session.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/auth/profile/components/profile-form-provider.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/auth/register/components/form/register-form-provider.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/auth/reset-password/components/form/reset-password-form-provider.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/auth/session/logout-session.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/auth/session/session-store-refresh.d.ts +8 -0
- package/lib/typescript/commonjs/src/modules/auth/session/session-store-refresh.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/auth/session/session-store-request-state.d.ts +23 -0
- package/lib/typescript/commonjs/src/modules/auth/session/session-store-request-state.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/auth/session/session-store-types.d.ts +33 -0
- package/lib/typescript/commonjs/src/modules/auth/session/session-store-types.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/auth/session/session-store.d.ts +1 -18
- package/lib/typescript/commonjs/src/modules/auth/session/session-store.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/auth/utils/sign-in-error.d.ts +4 -2
- package/lib/typescript/commonjs/src/modules/auth/utils/sign-in-error.d.ts.map +1 -1
- 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/declined-device-storage.d.ts +10 -1
- package/lib/typescript/commonjs/src/modules/bt-management/hooks/declined-device-storage.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/hooks/nearby-device-offer-state.d.ts +6 -0
- package/lib/typescript/commonjs/src/modules/bt-management/hooks/nearby-device-offer-state.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/hooks/nearby-device-offer-types.d.ts +15 -0
- package/lib/typescript/commonjs/src/modules/bt-management/hooks/nearby-device-offer-types.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/bt-management/hooks/use-nearby-device-offer.d.ts +6 -14
- package/lib/typescript/commonjs/src/modules/bt-management/hooks/use-nearby-device-offer.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/services/background-sync/background-sync-coordinator.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/bt-management/types/background-sync.d.ts +7 -0
- package/lib/typescript/commonjs/src/modules/bt-management/types/background-sync.d.ts.map +1 -1
- 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/hooks/use-listen-changes.d.ts +2 -3
- 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/apple-health-sync-service.d.ts +4 -5
- package/lib/typescript/commonjs/src/modules/data-sync/services/apple-health-sync-service.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/data-sync/types/apple-health-authorization-provider-props.d.ts +4 -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 +7 -1
- 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/health-authorization-status.d.ts +2 -1
- 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/utils/convert-generic-health-data.d.ts +3 -2
- 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-records-to-observation.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/get-samples-from-health.d.ts +5 -4
- 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 +2 -2
- 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 +5 -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-record-timing.d.ts +10 -0
- package/lib/typescript/commonjs/src/modules/data-sync/utils/health-record-timing.d.ts.map +1 -0
- 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-data-types.d.ts +6 -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/normalize-core-health-observation.d.ts +13 -0
- package/lib/typescript/commonjs/src/modules/data-sync/utils/normalize-core-health-observation.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/picker-sheet/components/value-wheel-picker.d.ts +21 -0
- package/lib/typescript/commonjs/src/modules/picker-sheet/components/value-wheel-picker.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/picker-sheet/components/wheel-picker.d.ts +7 -3
- package/lib/typescript/commonjs/src/modules/picker-sheet/components/wheel-picker.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/picker-sheet/index.d.ts +1 -0
- package/lib/typescript/commonjs/src/modules/picker-sheet/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/components/content/questionnaire-content-item.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/components/content/questionnaire-content-specific-item.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/components/fields/common/questionnaire-field-wrapper.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/components/fields/questionnaire-choice-field.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/components/fields/questionnaire-date-field.d.ts +3 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/components/fields/questionnaire-date-field.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/components/fields/questionnaire-item-renderer.d.ts +9 -3
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/components/fields/questionnaire-item-renderer.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/components/fields/questionnaire-text-field.d.ts +5 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/components/fields/questionnaire-text-field.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/components/header/questionnaire-header-title.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/components/questionnaire-form-provider.d.ts +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/components/questionnaire-form-provider.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/components/questionnaire-form.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/components/questionnaire-navigation-provider.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/hooks/use-initial-selected-values.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/hooks/use-navigation-handlers.d.ts +6 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/hooks/use-navigation-handlers.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/hooks/use-questionnaire-navigation-state.d.ts +2 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/hooks/use-questionnaire-navigation-state.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/index.d.ts +4 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/types/extended-questionnaire-item.d.ts +7 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/types/extended-questionnaire-item.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/types/questionnaire-form-context-type.d.ts +6 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/types/questionnaire-form-context-type.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/types/questionnaire-form-props.d.ts +3 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/types/questionnaire-form-props.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/types/questionnaire-form-provider-props.d.ts +11 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/types/questionnaire-form-provider-props.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/types/questionnaire-form-values.d.ts +5 -2
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/types/questionnaire-form-values.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/types/questionnaire-item-render-props.d.ts +15 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/types/questionnaire-item-render-props.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/types/questionnaire-navigation-provider-props.d.ts +5 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/types/questionnaire-navigation-provider-props.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/types/response-values.d.ts +2 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/types/response-values.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/condition-utils.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/conditions/fhir-condition.d.ts +9 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/conditions/fhir-condition.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/create-answer-from-value.d.ts +7 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/create-answer-from-value.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/fields/get-option-text.d.ts +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/fields/get-option-text.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/form-utils.d.ts +4 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/form-utils.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/form-validation.d.ts +4 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/form-validation.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/is-answerable-questionnaire-item.d.ts +3 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/is-answerable-questionnaire-item.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/is-valid-questionnaire-answer.d.ts +8 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/is-valid-questionnaire-answer.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/questionnaire-date-utils.d.ts +5 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/questionnaire-date-utils.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/questionnaire-item-constraints.d.ts +22 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/questionnaire-item-constraints.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/questionnaire-item-value-constraint-validators.d.ts +10 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/questionnaire-item-value-constraint-validators.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/questionnaire-navigation-utils.d.ts +2 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/questionnaire-navigation-utils.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/questionnaire-picker-options.d.ts +15 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/questionnaire-picker-options.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/questionnaire-string-constraint-validator.d.ts +5 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/questionnaire-string-constraint-validator.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/questionnaire-submit-utils.d.ts +3 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/questionnaire-submit-utils.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/translate-fhir-text.d.ts +4 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/translate-fhir-text.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/validate-questionnaire-item-value.d.ts +6 -0
- package/lib/typescript/commonjs/src/modules/questionnaire-response-form/utils/validate-questionnaire-item-value.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/ui/components/bluetooth-state-notice.d.ts +8 -5
- package/lib/typescript/commonjs/src/modules/ui/components/bluetooth-state-notice.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/modules/ui/components/prerequisite-gate.d.ts +19 -0
- package/lib/typescript/commonjs/src/modules/ui/components/prerequisite-gate.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/ui/default-translation.d.ts +30 -0
- package/lib/typescript/commonjs/src/modules/ui/default-translation.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/modules/ui/index.d.ts +1 -0
- package/lib/typescript/commonjs/src/modules/ui/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/polyfills/index.d.ts +7 -1
- package/lib/typescript/commonjs/src/polyfills/index.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/auth/default-translation.d.ts +22 -0
- package/lib/typescript/module/src/modules/auth/default-translation.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/auth/hooks/use-session.d.ts +4 -1
- package/lib/typescript/module/src/modules/auth/hooks/use-session.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/auth/profile/components/profile-form-provider.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/auth/register/components/form/register-form-provider.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/auth/reset-password/components/form/reset-password-form-provider.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/auth/session/logout-session.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/auth/session/session-store-refresh.d.ts +8 -0
- package/lib/typescript/module/src/modules/auth/session/session-store-refresh.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/auth/session/session-store-request-state.d.ts +23 -0
- package/lib/typescript/module/src/modules/auth/session/session-store-request-state.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/auth/session/session-store-types.d.ts +33 -0
- package/lib/typescript/module/src/modules/auth/session/session-store-types.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/auth/session/session-store.d.ts +1 -18
- package/lib/typescript/module/src/modules/auth/session/session-store.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/auth/utils/sign-in-error.d.ts +4 -2
- package/lib/typescript/module/src/modules/auth/utils/sign-in-error.d.ts.map +1 -1
- 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/declined-device-storage.d.ts +10 -1
- package/lib/typescript/module/src/modules/bt-management/hooks/declined-device-storage.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/hooks/nearby-device-offer-state.d.ts +6 -0
- package/lib/typescript/module/src/modules/bt-management/hooks/nearby-device-offer-state.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/hooks/nearby-device-offer-types.d.ts +15 -0
- package/lib/typescript/module/src/modules/bt-management/hooks/nearby-device-offer-types.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/bt-management/hooks/use-nearby-device-offer.d.ts +6 -14
- package/lib/typescript/module/src/modules/bt-management/hooks/use-nearby-device-offer.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/services/background-sync/background-sync-coordinator.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/bt-management/types/background-sync.d.ts +7 -0
- package/lib/typescript/module/src/modules/bt-management/types/background-sync.d.ts.map +1 -1
- 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/hooks/use-listen-changes.d.ts +2 -3
- 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/apple-health-sync-service.d.ts +4 -5
- package/lib/typescript/module/src/modules/data-sync/services/apple-health-sync-service.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/data-sync/types/apple-health-authorization-provider-props.d.ts +4 -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 +7 -1
- 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/health-authorization-status.d.ts +2 -1
- 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/utils/convert-generic-health-data.d.ts +3 -2
- 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-records-to-observation.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/get-samples-from-health.d.ts +5 -4
- 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 +2 -2
- 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 +5 -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-record-timing.d.ts +10 -0
- package/lib/typescript/module/src/modules/data-sync/utils/health-record-timing.d.ts.map +1 -0
- 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-data-types.d.ts +6 -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/normalize-core-health-observation.d.ts +13 -0
- package/lib/typescript/module/src/modules/data-sync/utils/normalize-core-health-observation.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/picker-sheet/components/value-wheel-picker.d.ts +21 -0
- package/lib/typescript/module/src/modules/picker-sheet/components/value-wheel-picker.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/picker-sheet/components/wheel-picker.d.ts +7 -3
- package/lib/typescript/module/src/modules/picker-sheet/components/wheel-picker.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/picker-sheet/index.d.ts +1 -0
- package/lib/typescript/module/src/modules/picker-sheet/index.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/components/content/questionnaire-content-item.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/components/content/questionnaire-content-specific-item.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/components/fields/common/questionnaire-field-wrapper.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/components/fields/questionnaire-choice-field.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/components/fields/questionnaire-date-field.d.ts +3 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/components/fields/questionnaire-date-field.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/components/fields/questionnaire-item-renderer.d.ts +9 -3
- package/lib/typescript/module/src/modules/questionnaire-response-form/components/fields/questionnaire-item-renderer.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/components/fields/questionnaire-text-field.d.ts +5 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/components/fields/questionnaire-text-field.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/components/header/questionnaire-header-title.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/components/questionnaire-form-provider.d.ts +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/components/questionnaire-form-provider.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/components/questionnaire-form.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/components/questionnaire-navigation-provider.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/hooks/use-initial-selected-values.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/hooks/use-navigation-handlers.d.ts +6 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/hooks/use-navigation-handlers.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/hooks/use-questionnaire-navigation-state.d.ts +2 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/hooks/use-questionnaire-navigation-state.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/index.d.ts +4 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/index.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/types/extended-questionnaire-item.d.ts +7 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/types/extended-questionnaire-item.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/types/questionnaire-form-context-type.d.ts +6 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/types/questionnaire-form-context-type.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/types/questionnaire-form-props.d.ts +3 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/types/questionnaire-form-props.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/types/questionnaire-form-provider-props.d.ts +11 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/types/questionnaire-form-provider-props.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/types/questionnaire-form-values.d.ts +5 -2
- package/lib/typescript/module/src/modules/questionnaire-response-form/types/questionnaire-form-values.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/types/questionnaire-item-render-props.d.ts +15 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/types/questionnaire-item-render-props.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/types/questionnaire-navigation-provider-props.d.ts +5 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/types/questionnaire-navigation-provider-props.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/types/response-values.d.ts +2 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/types/response-values.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/condition-utils.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/conditions/fhir-condition.d.ts +9 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/conditions/fhir-condition.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/create-answer-from-value.d.ts +7 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/create-answer-from-value.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/fields/get-option-text.d.ts +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/fields/get-option-text.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/form-utils.d.ts +4 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/form-utils.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/form-validation.d.ts +4 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/form-validation.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/is-answerable-questionnaire-item.d.ts +3 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/is-answerable-questionnaire-item.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/is-valid-questionnaire-answer.d.ts +8 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/is-valid-questionnaire-answer.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/questionnaire-date-utils.d.ts +5 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/questionnaire-date-utils.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/questionnaire-item-constraints.d.ts +22 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/questionnaire-item-constraints.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/questionnaire-item-value-constraint-validators.d.ts +10 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/questionnaire-item-value-constraint-validators.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/questionnaire-navigation-utils.d.ts +2 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/questionnaire-navigation-utils.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/questionnaire-picker-options.d.ts +15 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/questionnaire-picker-options.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/questionnaire-string-constraint-validator.d.ts +5 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/questionnaire-string-constraint-validator.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/questionnaire-submit-utils.d.ts +3 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/questionnaire-submit-utils.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/translate-fhir-text.d.ts +4 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/translate-fhir-text.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/validate-questionnaire-item-value.d.ts +6 -0
- package/lib/typescript/module/src/modules/questionnaire-response-form/utils/validate-questionnaire-item-value.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/ui/components/bluetooth-state-notice.d.ts +8 -5
- package/lib/typescript/module/src/modules/ui/components/bluetooth-state-notice.d.ts.map +1 -1
- package/lib/typescript/module/src/modules/ui/components/prerequisite-gate.d.ts +19 -0
- package/lib/typescript/module/src/modules/ui/components/prerequisite-gate.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/ui/default-translation.d.ts +30 -0
- package/lib/typescript/module/src/modules/ui/default-translation.d.ts.map +1 -0
- package/lib/typescript/module/src/modules/ui/index.d.ts +1 -0
- package/lib/typescript/module/src/modules/ui/index.d.ts.map +1 -1
- package/lib/typescript/module/src/polyfills/index.d.ts +7 -1
- package/lib/typescript/module/src/polyfills/index.d.ts.map +1 -1
- package/package.json +5 -8
|
@@ -4,145 +4,75 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.getSessionStore = void 0;
|
|
7
|
+
var _netinfo = require("@react-native-community/netinfo");
|
|
7
8
|
var _logoutSession = require("./logout-session.js");
|
|
8
|
-
var
|
|
9
|
+
var _sessionStoreRefresh = require("./session-store-refresh.js");
|
|
10
|
+
var _sessionStoreRequestState = require("./session-store-request-state.js");
|
|
9
11
|
const stores = new WeakMap();
|
|
10
|
-
const normalizeSession = session => {
|
|
11
|
-
const legacy = session;
|
|
12
|
-
return {
|
|
13
|
-
id: session.id,
|
|
14
|
-
authMethod: session.authMethod,
|
|
15
|
-
remoteAddress: session.remoteAddress ?? legacy.ip,
|
|
16
|
-
lastUpdated: session.lastUpdated ?? legacy.lastActiveAt ?? legacy.createdAt
|
|
17
|
-
};
|
|
18
|
-
};
|
|
19
12
|
const createSessionStore = client => {
|
|
20
13
|
const sessionClient = client;
|
|
21
14
|
const listeners = new Set();
|
|
22
|
-
|
|
23
|
-
let
|
|
15
|
+
const requestState = new _sessionStoreRequestState.SessionStoreRequestState(client, sessionClient);
|
|
16
|
+
let unsubscribeNetwork;
|
|
17
|
+
let wasConnected;
|
|
24
18
|
let logoutRequest;
|
|
25
|
-
|
|
26
|
-
|
|
19
|
+
const storeRef = {};
|
|
20
|
+
const notify = () => listeners.forEach(listener => listener());
|
|
21
|
+
const refreshActions = (0, _sessionStoreRefresh.createSessionRefreshActions)(client, requestState, () => storeRef.current, notify);
|
|
27
22
|
const store = {
|
|
28
23
|
snapshot: {
|
|
29
24
|
status: "loading",
|
|
25
|
+
accounts: requestState.getAccounts(),
|
|
30
26
|
sessions: []
|
|
31
27
|
},
|
|
32
28
|
subscribe: listener => {
|
|
33
29
|
listeners.add(listener);
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
};
|
|
43
|
-
listeners.forEach(listener => listener());
|
|
44
|
-
return;
|
|
45
|
-
}
|
|
46
|
-
const revision = ++authRevision;
|
|
47
|
-
const previousSnapshot = store.snapshot;
|
|
48
|
-
if (store.snapshot.status !== "authenticated" && store.snapshot.status !== "offline") {
|
|
49
|
-
store.snapshot = {
|
|
50
|
-
...store.snapshot,
|
|
51
|
-
status: "loading",
|
|
52
|
-
error: undefined
|
|
53
|
-
};
|
|
54
|
-
listeners.forEach(listener => listener());
|
|
55
|
-
}
|
|
56
|
-
profileRequest ??= (profileNeedsRefresh ? client.refetchProfile() : client.getProfileAsync()).then(profile => {
|
|
57
|
-
profileNeedsRefresh = false;
|
|
58
|
-
return profile;
|
|
59
|
-
}).catch(cause => {
|
|
60
|
-
profileNeedsRefresh = true;
|
|
61
|
-
throw cause;
|
|
62
|
-
}).finally(() => {
|
|
63
|
-
profileRequest = undefined;
|
|
64
|
-
});
|
|
65
|
-
const currentProfileRequest = profileRequest;
|
|
66
|
-
if (includeSessions) {
|
|
67
|
-
sessionsRequest ??= sessionClient.getSessions().finally(() => {
|
|
68
|
-
sessionsRequest = undefined;
|
|
30
|
+
if (!unsubscribeNetwork) {
|
|
31
|
+
unsubscribeNetwork = (0, _netinfo.addEventListener)(state => {
|
|
32
|
+
const isConnected = state.isConnected === true && state.isInternetReachable !== false;
|
|
33
|
+
const shouldRefresh = isConnected && wasConnected !== true && store.snapshot.status === "offline";
|
|
34
|
+
wasConnected = isConnected;
|
|
35
|
+
if (shouldRefresh) {
|
|
36
|
+
void store.refresh(false);
|
|
37
|
+
}
|
|
69
38
|
});
|
|
70
39
|
}
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
}
|
|
79
|
-
error
|
|
80
|
-
}))]);
|
|
81
|
-
if (revision !== authRevision) {
|
|
82
|
-
return;
|
|
83
|
-
}
|
|
84
|
-
const profile = "profile" in profileResult ? profileResult.profile : previousSnapshot.profile;
|
|
85
|
-
const sessions = "sessions" in sessionsResult ? sessionsResult.sessions : previousSnapshot.sessions;
|
|
86
|
-
const error = "error" in profileResult ? profileResult.error : "error" in sessionsResult ? sessionsResult.error : undefined;
|
|
87
|
-
if (!client.getActiveLogin() || (0, _sessionErrors.getHttpStatus)(error) === 401) {
|
|
88
|
-
store.snapshot = {
|
|
89
|
-
status: "signed-out",
|
|
90
|
-
sessions: [],
|
|
91
|
-
error: error === undefined ? undefined : (0, _sessionErrors.toError)(error)
|
|
92
|
-
};
|
|
93
|
-
} else if ("error" in profileResult) {
|
|
94
|
-
store.snapshot = {
|
|
95
|
-
status: "offline",
|
|
96
|
-
profile,
|
|
97
|
-
sessions: sessions.map(normalizeSession),
|
|
98
|
-
error: (0, _sessionErrors.toError)(profileResult.error)
|
|
99
|
-
};
|
|
100
|
-
} else {
|
|
101
|
-
store.snapshot = {
|
|
102
|
-
status: "authenticated",
|
|
103
|
-
profile,
|
|
104
|
-
sessions: sessions.map(normalizeSession),
|
|
105
|
-
error: "error" in sessionsResult ? (0, _sessionErrors.toError)(sessionsResult.error) : undefined
|
|
106
|
-
};
|
|
107
|
-
}
|
|
108
|
-
listeners.forEach(listener => listener());
|
|
40
|
+
return () => {
|
|
41
|
+
listeners.delete(listener);
|
|
42
|
+
if (listeners.size === 0) {
|
|
43
|
+
unsubscribeNetwork?.();
|
|
44
|
+
unsubscribeNetwork = undefined;
|
|
45
|
+
wasConnected = undefined;
|
|
46
|
+
}
|
|
47
|
+
};
|
|
109
48
|
},
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
49
|
+
...refreshActions,
|
|
50
|
+
switchAccount: async accountId => {
|
|
51
|
+
requestState.invalidate();
|
|
52
|
+
store.snapshot = {
|
|
53
|
+
status: "loading",
|
|
54
|
+
accounts: requestState.getAccounts(),
|
|
55
|
+
sessions: []
|
|
56
|
+
};
|
|
57
|
+
notify();
|
|
58
|
+
try {
|
|
59
|
+
await sessionClient.switchAccount(accountId);
|
|
60
|
+
} finally {
|
|
61
|
+
await store.refresh(true);
|
|
118
62
|
}
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
63
|
+
},
|
|
64
|
+
removeAccount: async accountId => {
|
|
65
|
+
requestState.invalidate();
|
|
66
|
+
store.snapshot = {
|
|
67
|
+
status: "loading",
|
|
68
|
+
accounts: requestState.getAccounts(),
|
|
69
|
+
sessions: []
|
|
70
|
+
};
|
|
71
|
+
notify();
|
|
122
72
|
try {
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
sessions: sessions.map(normalizeSession),
|
|
127
|
-
error: undefined
|
|
128
|
-
};
|
|
129
|
-
listeners.forEach(listener => listener());
|
|
130
|
-
} catch (cause) {
|
|
131
|
-
const error = (0, _sessionErrors.toError)(cause);
|
|
132
|
-
if (!client.getActiveLogin() || (0, _sessionErrors.getHttpStatus)(cause) === 401) {
|
|
133
|
-
store.snapshot = {
|
|
134
|
-
status: "signed-out",
|
|
135
|
-
sessions: [],
|
|
136
|
-
error
|
|
137
|
-
};
|
|
138
|
-
} else {
|
|
139
|
-
store.snapshot = {
|
|
140
|
-
...store.snapshot,
|
|
141
|
-
error
|
|
142
|
-
};
|
|
143
|
-
}
|
|
144
|
-
listeners.forEach(listener => listener());
|
|
145
|
-
throw error;
|
|
73
|
+
await sessionClient.removeAccount(accountId);
|
|
74
|
+
} finally {
|
|
75
|
+
await store.refresh(true);
|
|
146
76
|
}
|
|
147
77
|
},
|
|
148
78
|
logout: async () => {
|
|
@@ -150,15 +80,17 @@ const createSessionStore = client => {
|
|
|
150
80
|
return logoutRequest;
|
|
151
81
|
}
|
|
152
82
|
logoutRequest = (async () => {
|
|
153
|
-
|
|
83
|
+
requestState.invalidate();
|
|
154
84
|
try {
|
|
155
85
|
await (0, _logoutSession.logoutSession)(sessionClient);
|
|
156
86
|
} finally {
|
|
87
|
+
requestState.invalidate();
|
|
157
88
|
store.snapshot = {
|
|
158
89
|
status: "signed-out",
|
|
90
|
+
accounts: requestState.getAccounts(),
|
|
159
91
|
sessions: []
|
|
160
92
|
};
|
|
161
|
-
|
|
93
|
+
notify();
|
|
162
94
|
logoutRequest = undefined;
|
|
163
95
|
}
|
|
164
96
|
})();
|
|
@@ -169,6 +101,7 @@ const createSessionStore = client => {
|
|
|
169
101
|
await store.refresh(true);
|
|
170
102
|
}
|
|
171
103
|
};
|
|
104
|
+
storeRef.current = store;
|
|
172
105
|
return store;
|
|
173
106
|
};
|
|
174
107
|
const getSessionStore = client => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["_netinfo","require","_logoutSession","_sessionStoreRefresh","_sessionStoreRequestState","stores","WeakMap","createSessionStore","client","sessionClient","listeners","Set","requestState","SessionStoreRequestState","unsubscribeNetwork","wasConnected","logoutRequest","storeRef","notify","forEach","listener","refreshActions","createSessionRefreshActions","current","store","snapshot","status","accounts","getAccounts","sessions","subscribe","add","addNetworkEventListener","state","isConnected","isInternetReachable","shouldRefresh","refresh","delete","size","undefined","switchAccount","accountId","invalidate","removeAccount","logout","logoutSession","revokeSessions","option","getSessionStore","key","existing","get","next","set","exports"],"sourceRoot":"../../../../../src","sources":["modules/auth/session/session-store.ts"],"mappings":";;;;;;AAAA,IAAAA,QAAA,GAAAC,OAAA;AAQA,IAAAC,cAAA,GAAAD,OAAA;AACA,IAAAE,oBAAA,GAAAF,OAAA;AACA,IAAAG,yBAAA,GAAAH,OAAA;AAEA,MAAMI,MAAM,GAAG,IAAIC,OAAO,CAAuB,CAAC;AAElD,MAAMC,kBAAkB,GAAIC,MAAc,IAAmB;EAC3D,MAAMC,aAAa,GAAGD,MAAkC;EACxD,MAAME,SAAS,GAAG,IAAIC,GAAG,CAAa,CAAC;EACvC,MAAMC,YAAY,GAAG,IAAIC,kDAAwB,CAACL,MAAM,EAAEC,aAAa,CAAC;EACxE,IAAIK,kBAA4C;EAChD,IAAIC,YAAiC;EACrC,IAAIC,aAAwC;EAC5C,MAAMC,QAAoC,GAAG,CAAC,CAAC;EAE/C,MAAMC,MAAM,GAAGA,CAAA,KAAMR,SAAS,CAACS,OAAO,CAAEC,QAAQ,IAAKA,QAAQ,CAAC,CAAC,CAAC;EAEhE,MAAMC,cAAc,GAAG,IAAAC,gDAA2B,EAChDd,MAAM,EACNI,YAAY,EACZ,MAAMK,QA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O,GAAGC,KAAK;EAExB,OAAOA,KAAK;AACd,CAAC;AAED,MAAMyB,eAAe,GAAIzC,MAAc,IAAmB;EACxD,MAAM0C,GAAG,GAAG1C,MAAgB;EAC5B,MAAM2C,QAAQ,GAAG9C,MAAM,CAAC+C,GAAG,CAACF,GAAG,CAAC;EAEhC,IAAIC,QAAQ,EAAE;IACZ,OAAOA,QAAQ;EACjB;EAEA,MAAME,IAAI,GAAG9C,kBAAkB,CAACC,MAAM,CAAC;EAEvCH,MAAM,CAACiD,GAAG,CAACJ,GAAG,EAAEG,IAAI,CAAC;EAErB,OAAOA,IAAI;AACb,CAAC;AAACE,OAAA,CAAAN,eAAA,GAAAA,eAAA","ignoreList":[]}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.parseSignInError = void 0;
|
|
6
|
+
exports.parseSignInError = exports.isNetworkError = void 0;
|
|
7
7
|
const asRecord = value => typeof value === "object" && value !== null ? value : undefined;
|
|
8
8
|
const parseJsonRecord = value => {
|
|
9
9
|
if (typeof value !== "string") {
|
|
@@ -37,9 +37,13 @@ const messageKeyForStatus = (status, isMfaVerification, isSignIn) => {
|
|
|
37
37
|
return undefined;
|
|
38
38
|
}
|
|
39
39
|
};
|
|
40
|
-
const isNetworkError = (error, message) =>
|
|
40
|
+
const isNetworkError = (error, message) => {
|
|
41
|
+
const errorMessage = message ?? (error instanceof Error ? error.message : asRecord(error)?.message);
|
|
42
|
+
return error instanceof TypeError || typeof errorMessage === "string" && /network request failed|network error|failed to fetch|fetch failed|unknownhostexception|no route to host|network is unreachable|unable to resolve host|could not resolve host|name resolution/i.test(errorMessage);
|
|
43
|
+
};
|
|
41
44
|
|
|
42
|
-
/** Converts transport/server failures to safe, translatable
|
|
45
|
+
/** Converts auth transport/server failures to safe, translatable error keys. */
|
|
46
|
+
exports.isNetworkError = isNetworkError;
|
|
43
47
|
const parseSignInError = (error, options = {}) => {
|
|
44
48
|
const root = asRecord(error);
|
|
45
49
|
const originalMessage = error instanceof Error ? error.message : root?.message;
|
|
@@ -50,7 +54,9 @@ const parseSignInError = (error, options = {}) => {
|
|
|
50
54
|
const code = stringValue(body?.code, nestedError?.code, root?.code);
|
|
51
55
|
const requestId = stringValue(body?.requestId, root?.requestId);
|
|
52
56
|
const fieldErrors = Array.isArray(body?.errors) ? body.errors : Array.isArray(nestedError?.errors) ? nestedError.errors : [];
|
|
53
|
-
const
|
|
57
|
+
const genericErrorKey = options.errorScope ? `${options.errorScope}.errors.generic` : "sign-in.errors.generic";
|
|
58
|
+
const networkErrorKey = options.errorScope ? `${options.errorScope}.errors.network` : "sign-in.errors.network";
|
|
59
|
+
const message = messageKeyForStatus(status, options.isMfaVerification === true, options.isSignIn !== false) ?? (isNetworkError(error, originalMessage) ? networkErrorKey : genericErrorKey);
|
|
54
60
|
const signInError = new Error(message);
|
|
55
61
|
if (status !== undefined) {
|
|
56
62
|
signInError.status = status;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["asRecord","value","undefined","parseJsonRecord","JSON","parse","numberValue","values","find","candidate","Number","isFinite","stringValue","length","messageKeyForStatus","status","isMfaVerification","isSignIn","isNetworkError","error","message","TypeError","test","parseSignInError","options","root","originalMessage","
|
|
1
|
+
{"version":3,"names":["asRecord","value","undefined","parseJsonRecord","JSON","parse","numberValue","values","find","candidate","Number","isFinite","stringValue","length","messageKeyForStatus","status","isMfaVerification","isSignIn","isNetworkError","error","message","errorMessage","Error","TypeError","test","exports","parseSignInError","options","root","originalMessage","response","body","data","nestedError","statusCode","code","requestId","fieldErrors","Array","isArray","errors","genericErrorKey","errorScope","networkErrorKey","signInError"],"sourceRoot":"../../../../../src","sources":["modules/auth/utils/sign-in-error.ts"],"mappings":";;;;;;AAeA,MAAMA,QAAQ,GAAIC,KAAc,IAC9B,OAAOA,KAAK,KAAK,QAAQ,IAAIA,KAAK,KAAK,IAAI,GACtCA,KAA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EACnE,MAAMC,SAAS,GAAGxB,WAAW,CAACmB,IAAI,EAAEK,SAAS,EAAER,IAAI,EAAEQ,SAAS,CAAC;EAE/D,MAAMC,WAAW,GACfC,KAAK,CAACC,OAAO,CAACR,IAAI,EAAES,MAAM,CAAC,GACvBT,IAAI,CAACS,MAAM,GACXF,KAAK,CAACC,OAAO,CAACN,WAAW,EAAEO,MAAM,CAAC,GAChCP,WAAW,CAACO,MAAM,GAClB,EACc;EAEtB,MAAMC,eAAe,GAAGd,OAAO,CAACe,UAAU,GACtC,GAAGf,OAAO,CAACe,UAAU,iBAAiB,GACtC,wBAAwB;EAE5B,MAAMC,eAAe,GAAGhB,OAAO,CAACe,UAAU,GACtC,GAAGf,OAAO,CAACe,UAAU,iBAAiB,GACtC,wBAAwB;EAE5B,MAAMtB,OAAO,GACXN,mBAAmB,CACjBC,MAAM,EACNY,OAAO,CAACX,iBAAiB,KAAK,IAAI,EAClCW,OAAO,CAACV,QAAQ,KAAK,KACvB,CAAC,KACAC,cAAc,CAACC,KAAK,EAAEU,eAAe,CAAC,GACnCc,eAAe,GACfF,eAAe,CAAC;EAEtB,MAAMG,WAAW,GAAG,IAAItB,KAAK,CAACF,OAAO,CAAgB;EAErD,IAAIL,MAAM,KAAKb,SAAS,EAAE;IACxB0C,WAAW,CAAC7B,MAAM,GAAGA,MAAM;EAC7B;EACA,IAAIqB,SAAS,KAAKlC,SAAS,EAAE;IAC3B0C,WAAW,CAACR,SAAS,GAAGA,SAAS;EACnC;EACA,IAAID,IAAI,KAAKjC,SAAS,EAAE;IACtB0C,WAAW,CAACT,IAAI,GAAGA,IAAI;EACzB;EAEA,OAAO;IAAEhB,KAAK,EAAEyB,WAAW;IAAEP;EAAY,CAAC;AAC5C,CAAC;AAACZ,OAAA,CAAAC,gBAAA,GAAAA,gBAAA","ignoreList":[]}
|
|
@@ -202,6 +202,7 @@ const BTProviderChildWrapper = ({
|
|
|
202
202
|
}
|
|
203
203
|
const coordinator = new _backgroundSyncCoordinator.BackgroundSyncCoordinator({
|
|
204
204
|
...current,
|
|
205
|
+
getOwnerKey: () => backgroundSyncRef.current?.getOwnerKey?.(),
|
|
205
206
|
enabled: true,
|
|
206
207
|
onError: error => {
|
|
207
208
|
backgroundSyncRef.current?.onError?.(error);
|
|
@@ -218,9 +219,13 @@ const BTProviderChildWrapper = ({
|
|
|
218
219
|
if (latest.notifications?.enabled !== true) {
|
|
219
220
|
return;
|
|
220
221
|
}
|
|
222
|
+
const shouldNotify = latest.notifications.shouldNotify;
|
|
221
223
|
const body = latest.notifications.body;
|
|
222
224
|
const data = latest.notifications.data;
|
|
223
225
|
try {
|
|
226
|
+
if (shouldNotify && !shouldNotify(result)) {
|
|
227
|
+
return;
|
|
228
|
+
}
|
|
224
229
|
await (0, _pushNotification.showBackgroundPushNotification)({
|
|
225
230
|
title: latest.notifications.title ?? "New health measurement",
|
|
226
231
|
body: body === undefined ? `${result.deviceData.name} reported a measurement` : typeof body === "function" ? body(result) : body,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["React","_interopRequireWildcard","require","_reactNative","_reactNativeBlePlx","_sentryLogger","_runtimeContext","_backgroundBleManager","_backgroundServiceUuids","_backgroundSyncCoordinator","_btManager","_pushNotification","_bluetoothError","_deviceStatus","_androidBluetoothForegroundService","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","stableSignature","value","JSON","stringify","_key","current","RegExp","source","flags","Map","entries","Set","values","toString","BTProviderChildWrapper","bleManager","acceptedDevices","children","oneReadingPerConnection","deliveredEcgFileNames","deliveredFileNames","clearDeviceHistory","onDeviceFound","onError","onDeviceStatusChanged","onConnectionEvent","onResult","resultPolicies","clockSync","autoConnect","autoConnectDelayMs","onDeviceSelectionRequired","backgroundSync","permissionStatus","btManagerRef","useRef","managerState","setManager","useState","runtimeRef","createBluetoothRuntime","enabled","runtime","permissionErrorReportedRef","runtimePermissionStatus","useSyncExternalStore","subscribeState","getSnapshot","bluetoothPermissionStatus","backgroundSyncRef","propsRef","acceptedDevicesRef","backgroundSyncCoordinatorRef","useEffect","setBluetoothPermissionStatus","setBluetoothState","subscription","onStateChange","state","BleState","PoweredOn","Unsupported","Unauthorized","remove","acceptedDevicesSignature","managerOptionsSignature","timezone","serviceUUIDs","getBackgroundServiceUUIDs","undefined","backgroundScanEnabled","getBackgroundScanEnabled","currentAcceptedDevices","length","sentryLogger","currentProps","currentBackgroundSync","backgroundOptions","backgroundEnabled","managerOptions","now","Date","btManager","keys","BTManager","destroy","backgroundCoordinatorSignature","storageKey","maxRetries","retryBackoffMs","notifications","title","body","coordinator","BackgroundSyncCoordinator","error","toBluetoothError","result","latest","Error","data","showBackgroundPushNotification","deviceData","name","storage","setAutoConnect","manager","device","deviceManager","upsertDevice","runtimeDevice","devices","find","item","id","emit","Promise","resolve","normalized","code","BluetoothErrorCode","PERMISSION_DENIED","callback","enqueue","catch","setDeviceResult","status","measurementTypeKey","DeviceStatus","DISCONNECTED","removeDevice","setDeviceStatus","event","setDeviceConnectionEvent","setBackgroundScanEnabled","AppState","currentState","startScan","restoredState","getRestoredBleState","restoreStateIdentifier","connectedPeripherals","restoreDevices","flush","includeExhausted","resetExhausted","listener","addEventListener","jsx","BluetoothRuntimeProvider","AndroidBluetoothForegroundService","options","android","foregroundService","exports"],"sourceRoot":"../../../../../src","sources":["modules/bt-management/components/bt-provider-child-wrapper.tsx"],"mappings":";;;;;;AACA,IAAAA,KAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,kBAAA,GAAAF,OAAA;AAEA,IAAAG,aAAA,GAAAH,OAAA;AACA,IAAAI,eAAA,GAAAJ,OAAA;AACA,IAAAK,qBAAA,GAAAL,OAAA;AACA,IAAAM,uBAAA,GAAAN,OAAA;AACA,IAAAO,0BAAA,GAAAP,OAAA;AACA,IAAAQ,UAAA,GAAAR,OAAA;AACA,IAA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K,EAAE,IAAAC,gCAAgB,EAACD,KAAK;UAAE,CAAC,CAAC;QAClE,CAAC,CAAC;MACJ;IACF,CAAC,CAAC;IAEF,OAAO,MAAM;MACXmD,QAAQ,CAACnF,MAAM,CAAC,CAAC;IACnB,CAAC;EACH,CAAC,EAAE,CAACrB,OAAO,CAAC,CAAC;EAEb,oBACE,IAAA9D,WAAA,CAAAwK,GAAA,EAACjL,eAAA,CAAAkL,wBAAwB;IAAC3G,OAAO,EAAEH,UAAU,CAAClC,OAAQ;IAAAY,QAAA,eACtD,IAAArC,WAAA,CAAAwK,GAAA,EAACzK,kCAAA,CAAA2K,iCAAiC;MAChC7G,OAAO,EAAE6B,qBAAsB;MAC/BiF,OAAO,EAAEvH,cAAc,EAAEwH,OAAO,EAAEC,iBAAkB;MACpDlI,OAAO,EAAEA,OAAQ;MAAAN,QAAA,EAEhBA;IAAQ,CACwB;EAAC,CACV,CAAC;AAEjC,CAAC;AAACyI,OAAA,CAAA5I,sBAAA,GAAAA,sBAAA","ignoreList":[]}
|
|
1
|
+
{"version":3,"names":["React","_interopRequireWildcard","require","_reactNative","_reactNativeBlePlx","_sentryLogger","_runtimeContext","_backgroundBleManager","_backgroundServiceUuids","_backgroundSyncCoordinator","_btManager","_pushNotification","_bluetoothError","_deviceStatus","_androidBluetoothForegroundService","_jsxRuntime","e","t","WeakMap","r","n","__esModule","o","i","f","__proto__","default","has","get","set","hasOwnProperty","call","Object","defineProperty","getOwnPropertyDescriptor","stableSignature","value","JSON","stringify","_key","current","RegExp","source","flags","Map","entries","Set","values","toString","BTProviderChildWrapper","bleManager","acceptedDevices","children","oneReadingPerConnection","deliveredEcgFileNames","deliveredFileNames","clearDeviceHistory","onDeviceFound","onError","onDeviceStatusChanged","onConnectionEvent","onResult","resultPolicies","clockSync","autoConnect","autoConnectDelayMs","onDeviceSelectionRequired","backgroundSync","permissionStatus","btManagerRef","useRef","managerState","setManager","useState","runtimeRef","createBluetoothRuntime","enabled","runtime","permissionErrorReportedRef","runtimePermissionStatus","useSyncExternalStore","subscribeState","getSnapshot","bluetoothPermissionStatus","backgroundSyncRef","propsRef","acceptedDevicesRef","backgroundSyncCoordinatorRef","useEffect","setBluetoothPermissionStatus","setBluetoothState","subscription","onStateChange","state","BleState","PoweredOn","Unsupported","Unauthorized","remove","acceptedDevicesSignature","managerOptionsSignature","timezone","serviceUUIDs","getBackgroundServiceUUIDs","undefined","backgroundScanEnabled","getBackgroundScanEnabled","currentAcceptedDevices","length","sentryLogger","currentProps","currentBackgroundSync","backgroundOptions","backgroundEnabled","managerOptions","now","Date","btManager","keys","BTManager","destroy","backgroundCoordinatorSignature","storageKey","maxRetries","retryBackoffMs","notifications","title","body","coordinator","BackgroundSyncCoordinator","getOwnerKey","error","toBluetoothError","result","latest","Error","shouldNotify","data","showBackgroundPushNotification","deviceData","name","storage","setAutoConnect","manager","device","deviceManager","upsertDevice","runtimeDevice","devices","find","item","id","emit","Promise","resolve","normalized","code","BluetoothErrorCode","PERMISSION_DENIED","callback","enqueue","catch","setDeviceResult","status","measurementTypeKey","DeviceStatus","DISCONNECTED","removeDevice","setDeviceStatus","event","setDeviceConnectionEvent","setBackgroundScanEnabled","AppState","currentState","startScan","restoredState","getRestoredBleState","restoreStateIdentifier","connectedPeripherals","restoreDevices","flush","includeExhausted","resetExhausted","listener","addEventListener","jsx","BluetoothRuntimeProvider","AndroidBluetoothForegroundService","options","android","foregroundService","exports"],"sourceRoot":"../../../../../src","sources":["modules/bt-management/components/bt-provider-child-wrapper.tsx"],"mappings":";;;;;;AACA,IAAAA,KAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,kBAAA,GAAAF,OAAA;AAEA,IAAAG,aAAA,GAAAH,OAAA;AACA,IAAAI,eAAA,GAAAJ,OAAA;AACA,IAAAK,qBAAA,GAAAL,OAAA;AACA,IAAAM,uBAAA,GAAAN,OAAA;AACA,IAAAO,0BAAA,GAAAP,OAAA;AACA,IAAAQ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O,CAAC6B,wBAAwB,CAAC,CAAC,EAAE;QAC5D,KAAKnB,4BAA4B,CAAC/C,OAAO,EAAE4I,KAAK,CAAC;UAC/CC,gBAAgB,EAAE,IAAI;UACtBC,cAAc,EAAE;QAClB,CAAC,CAAC,CAACrB,KAAK,CAAE9B,KAAc,IAAK;UACzB9C,QAAQ,CAAC7C,OAAO,CAACkB,OAAO,GAAG;YAAEyE,KAAK,EAAE,IAAAC,gCAAgB,EAACD,KAAK;UAAE,CAAC,CAAC;QAClE,CAAC,CAAC;MACJ;IACF,CAAC,CAAC;IAEF,OAAO,MAAM;MACXoD,QAAQ,CAACrF,MAAM,CAAC,CAAC;IACnB,CAAC;EACH,CAAC,EAAE,CAACrB,OAAO,CAAC,CAAC;EAEb,oBACE,IAAA9D,WAAA,CAAA0K,GAAA,EAACnL,eAAA,CAAAoL,wBAAwB;IAAC7G,OAAO,EAAEH,UAAU,CAAClC,OAAQ;IAAAY,QAAA,eACtD,IAAArC,WAAA,CAAA0K,GAAA,EAAC3K,kCAAA,CAAA6K,iCAAiC;MAChC/G,OAAO,EAAE6B,qBAAsB;MAC/BmF,OAAO,EAAEzH,cAAc,EAAE0H,OAAO,EAAEC,iBAAkB;MACpDpI,OAAO,EAAEA,OAAQ;MAAAN,QAAA,EAEhBA;IAAQ,CACwB;EAAC,CACV,CAAC;AAEjC,CAAC;AAAC2I,OAAA,CAAA9I,sBAAA,GAAAA,sBAAA","ignoreList":[]}
|
|
@@ -3,7 +3,8 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.updateDeclinedDeviceIds = exports.parseDeclinedDeviceIds = void 0;
|
|
6
|
+
exports.updateDeclinedDeviceIds = exports.publishDeclinedDeviceIds = exports.parseDeclinedDeviceIds = exports.loadDeclinedDeviceIds = exports.getDeclinedDeviceState = void 0;
|
|
7
|
+
const declinedByRuntime = new WeakMap();
|
|
7
8
|
const writesByStorage = new WeakMap();
|
|
8
9
|
const parseDeclinedDeviceIds = value => {
|
|
9
10
|
if (!value) {
|
|
@@ -17,6 +18,40 @@ const parseDeclinedDeviceIds = value => {
|
|
|
17
18
|
}
|
|
18
19
|
};
|
|
19
20
|
exports.parseDeclinedDeviceIds = parseDeclinedDeviceIds;
|
|
21
|
+
const getDeclinedDeviceState = (runtime, storageKey) => {
|
|
22
|
+
let byStorageKey = declinedByRuntime.get(runtime);
|
|
23
|
+
if (!byStorageKey) {
|
|
24
|
+
byStorageKey = new Map();
|
|
25
|
+
declinedByRuntime.set(runtime, byStorageKey);
|
|
26
|
+
}
|
|
27
|
+
let state = byStorageKey.get(storageKey);
|
|
28
|
+
if (!state) {
|
|
29
|
+
state = {
|
|
30
|
+
listeners: new Set()
|
|
31
|
+
};
|
|
32
|
+
byStorageKey.set(storageKey, state);
|
|
33
|
+
}
|
|
34
|
+
return state;
|
|
35
|
+
};
|
|
36
|
+
exports.getDeclinedDeviceState = getDeclinedDeviceState;
|
|
37
|
+
const publishDeclinedDeviceIds = (state, ids) => {
|
|
38
|
+
state.ids = ids;
|
|
39
|
+
state.listeners.forEach(listener => listener());
|
|
40
|
+
};
|
|
41
|
+
exports.publishDeclinedDeviceIds = publishDeclinedDeviceIds;
|
|
42
|
+
const loadDeclinedDeviceIds = (state, storage, storageKey) => {
|
|
43
|
+
if (state.ids) {
|
|
44
|
+
return Promise.resolve(state.ids);
|
|
45
|
+
}
|
|
46
|
+
state.loading ??= Promise.resolve().then(() => storage.getItem(storageKey)).then(parseDeclinedDeviceIds).then(ids => {
|
|
47
|
+
publishDeclinedDeviceIds(state, ids);
|
|
48
|
+
return ids;
|
|
49
|
+
}).finally(() => {
|
|
50
|
+
state.loading = undefined;
|
|
51
|
+
});
|
|
52
|
+
return state.loading;
|
|
53
|
+
};
|
|
54
|
+
exports.loadDeclinedDeviceIds = loadDeclinedDeviceIds;
|
|
20
55
|
const updateDeclinedDeviceIds = async (storage, storageKey, update) => {
|
|
21
56
|
let writes = writesByStorage.get(storage);
|
|
22
57
|
if (!writes) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["
|
|
1
|
+
{"version":3,"names":["declinedByRuntime","WeakMap","writesByStorage","parseDeclinedDeviceIds","value","parsed","JSON","parse","Array","isArray","Set","filter","id","exports","getDeclinedDeviceState","runtime","storageKey","byStorageKey","get","Map","set","state","listeners","publishDeclinedDeviceIds","ids","forEach","listener","loadDeclinedDeviceIds","storage","Promise","resolve","loading","then","getItem","finally","undefined","updateDeclinedDeviceIds","update","writes","previousWrite","nextIds","write","catch","currentIds","setItem","stringify","delete"],"sourceRoot":"../../../../../src","sources":["modules/bt-management/hooks/declined-device-storage.ts"],"mappings":";;;;;;AASA,MAAMA,iBAAiB,GAAG,IAAIC,OAAO,CAGnC,CAAC;AAEH,MAAMC,eAAe,GAAG,IAAID,OAAO,CAGjC,CAAC;AAEH,MAAME,sBAAsB,GAAIC,KAAoB,IAAe;EACjE,IAAI,CAACA,KAAK,EAAE;IACV,OAAO,EAAE;EACX;EAEA,IAAI;IACF,MAAMC,MAAe,GAAGC,IAAI,CAACC,KAAK,CAACH,KAAK,CAAC;IAEzC,OAAOI,KAAK,CAACC,OAAO,CAACJ,MAAM,CAAC,GACxB,CACE,GAAG,IAAIK,GAAG,CACRL,MAAM,CAACM,MAAM,CAAEC,EAAE,IAAmB,OAAOA,EAAE,KAAK,QAAQ,CAC5D,CAAC,CACF,GACD,EAAE;EACR,CAAC,CAAC,MAAM;IACN,OAAO,EAAE;EACX;AACF,CAAC;AAACC,OAAA,CAAAV,sBAAA,GAAAA,sBAAA;AAEF,MAAMW,sBAAsB,GAAGA,CAC7BC,OAAyB,EACzBC,UAAkB,KACM;EACxB,IAAIC,YAAY,GAAGjB,iBAAiB,CAACkB,GAAG,CAACH,OAAO,CAAC;EAEjD,IAAI,CAACE,YAAY,EAAE;IACjBA,YAAY,GAAG,IAAIE,GAAG,CAAC,CAAC;IACxBnB,iBAAiB,CAACoB,GAAG,CAACL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ports.notNearbyError = exports.getDismissedLater = void 0;
|
|
7
|
+
var _bluetoothError = require("../types/bluetooth-error.js");
|
|
8
|
+
const dismissedLaterByRuntime = new WeakMap();
|
|
9
|
+
const getDismissedLater = (runtime, storageKey) => {
|
|
10
|
+
let byStorageKey = dismissedLaterByRuntime.get(runtime);
|
|
11
|
+
if (!byStorageKey) {
|
|
12
|
+
byStorageKey = new Map();
|
|
13
|
+
dismissedLaterByRuntime.set(runtime, byStorageKey);
|
|
14
|
+
}
|
|
15
|
+
let dismissed = byStorageKey.get(storageKey);
|
|
16
|
+
if (!dismissed) {
|
|
17
|
+
dismissed = new Set();
|
|
18
|
+
byStorageKey.set(storageKey, dismissed);
|
|
19
|
+
}
|
|
20
|
+
return dismissed;
|
|
21
|
+
};
|
|
22
|
+
exports.getDismissedLater = getDismissedLater;
|
|
23
|
+
const notNearbyError = () => new _bluetoothError.BluetoothError(_bluetoothError.BluetoothErrorCode.CONNECTION_FAILED, "The device is no longer nearby.");
|
|
24
|
+
exports.notNearbyError = notNearbyError;
|
|
25
|
+
//# sourceMappingURL=nearby-device-offer-state.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_bluetoothError","require","dismissedLaterByRuntime","WeakMap","getDismissedLater","runtime","storageKey","byStorageKey","get","Map","set","dismissed","Set","exports","notNearbyError","BluetoothError","BluetoothErrorCode","CONNECTION_FAILED"],"sourceRoot":"../../../../../src","sources":["modules/bt-management/hooks/nearby-device-offer-state.ts"],"mappings":";;;;;;AAEA,IAAAA,eAAA,GAAAC,OAAA;AAEA,MAAMC,uBAAuB,GAAG,IAAIC,OAAO,CAGzC,CAAC;AAEH,MAAMC,iBAAiB,GAAGA,CACxBC,OAAyB,EACzBC,UAAkB,KACF;EAChB,IAAIC,YAAY,GAAGL,uBAAuB,CAACM,GAAG,CAACH,OAAO,CAAC;EAEvD,IAAI,CAACE,YAAY,EAAE;IACjBA,YAAY,GAAG,IAAIE,GAAG,CAAC,CAAC;IACxBP,uBAAuB,CAACQ,GAAG,CAACL,OAAO,EAAEE,YAAY,CAAC;EACpD;EAEA,IAAII,SAAS,GAAGJ,YAAY,CAACC,GAAG,CAACF,UAAU,CAAC;EAE5C,IAAI,CAACK,SAAS,EAAE;IACdA,SAAS,GAAG,IAAIC,GAAG,CAAC,CAAC;IACrBL,YAAY,CAACG,GAAG,CAACJ,UAAU,EAAEK,SAAS,CAAC;EACzC;EAEA,OAAOA,SAAS;AAClB,CAAC;AAACE,OAAA,CAAAT,iBAAA,GAAAA,iBAAA;AAEF,MAAMU,cAAc,GAAGA,CAAA,KACrB,IAAIC,8BAAc,CAChBC,kCAAkB,CAACC,iBAAiB,EACpC,iCACF,CAAC;AAACJ,OAAA,CAAAC,cAAA,GAAAA,cAAA","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sourceRoot":"../../../../../src","sources":["modules/bt-management/hooks/nearby-device-offer-types.ts"],"mappings":"","ignoreList":[]}
|