@everfur/sdk 0.1.1 → 0.3.0
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/CHANGELOG.md +634 -0
- package/README.md +58 -23
- package/consent/package.json +8 -0
- package/dist/Chat-DPUD6dnc.d.cts +128 -0
- package/dist/Chat-DwAC2vhB.d.ts +128 -0
- package/dist/DepthViews-DNEM96Se.d.ts +16 -0
- package/dist/DepthViews-DP0R-DhB.d.cts +19 -0
- package/dist/DepthViews-D_3hl4xk.d.ts +19 -0
- package/dist/DepthViews-DbFhR4Du.d.cts +16 -0
- package/dist/ErrorPolicyPort-CNf4uQZP.d.cts +22 -0
- package/dist/ErrorPolicyPort-CwbfmxzJ.d.ts +22 -0
- package/dist/{EverfurResult-D92-uL82.d.cts → EverfurResult-DN9pL2Ab.d.cts} +11 -10
- package/dist/{EverfurResult-D92-uL82.d.ts → EverfurResult-DN9pL2Ab.d.ts} +11 -10
- package/dist/{PhotoController-BItt5M7u.d.cts → PhotoController-3l7MT9jA.d.cts} +1 -1
- package/dist/{PhotoController-D8zMTdcW.d.ts → PhotoController-vzY5bfY_.d.ts} +1 -1
- package/dist/animations/index.cjs +1 -1997
- package/dist/animations/index.d.cts +35 -35
- package/dist/animations/index.d.ts +35 -35
- package/dist/animations/index.js +1 -1972
- package/dist/attachments-5NeobOCd.d.ts +256 -0
- package/dist/attachments-Bw3iMQgu.d.ts +146 -0
- package/dist/attachments-CQgFrEQ7.d.cts +146 -0
- package/dist/attachments-D8T5re7e.d.cts +256 -0
- package/dist/casesRepository-ClLv6qMl.d.ts +188 -0
- package/dist/casesRepository-DHwtGRYY.d.cts +188 -0
- package/dist/chat/index.cjs +1 -1170
- package/dist/chat/index.d.cts +31 -53
- package/dist/chat/index.d.ts +31 -53
- package/dist/chat/index.js +1 -1167
- package/dist/client/index.cjs +9 -2315
- package/dist/client/index.d.cts +77 -15
- package/dist/client/index.d.ts +77 -15
- package/dist/client/index.js +9 -2215
- package/dist/{config-CiJ0PVBB.d.ts → config-CzTZGlfF.d.cts} +63 -25
- package/dist/{config-BSjBdxrZ.d.cts → config-DW60uRb9.d.ts} +63 -25
- package/dist/consent/index.cjs +1 -0
- package/dist/consent/index.d.cts +33 -0
- package/dist/consent/index.d.ts +33 -0
- package/dist/consent/index.js +1 -0
- package/dist/context-DXhqHlPU.d.ts +159 -0
- package/dist/context-XvTzq1tE.d.cts +159 -0
- package/dist/copy-Mjoo91aS.d.ts +198 -0
- package/dist/copy-bKDNigLb.d.cts +198 -0
- package/dist/core/index.cjs +13 -3178
- package/dist/core/index.d.cts +58 -12
- package/dist/core/index.d.ts +58 -12
- package/dist/core/index.js +13 -3166
- package/dist/depth-CErXCU8J.d.cts +502 -0
- package/dist/depth-DjDcJ6kH.d.ts +502 -0
- package/dist/entitlementRepository-DKdXFgTo.d.cts +698 -0
- package/dist/entitlementRepository-DSbzuyAW.d.ts +698 -0
- package/dist/{identity-DK9zORrG.d.ts → identity-BMx2SUOM.d.ts} +19 -6
- package/dist/{identity-Brl-lDd6.d.cts → identity-DI4eVx9S.d.cts} +19 -6
- package/dist/{ids-CJ1S6adf.d.cts → ids-B2GAAifq.d.cts} +1 -1
- package/dist/{ids-CJ1S6adf.d.ts → ids-B2GAAifq.d.ts} +1 -1
- package/dist/index.cjs +12 -4494
- package/dist/index.d.cts +29 -121
- package/dist/index.d.ts +29 -121
- package/dist/index.js +12 -4470
- package/dist/models-B-Uh2LTf.d.ts +214 -0
- package/dist/models-D2EUxPZY.d.cts +214 -0
- package/dist/notifications/index.cjs +2 -0
- package/dist/notifications/index.d.cts +17 -0
- package/dist/notifications/index.d.ts +17 -0
- package/dist/notifications/index.js +2 -0
- package/dist/pets-CtQdRpWo.d.ts +92 -0
- package/dist/pets-aB8q0JyX.d.cts +92 -0
- package/dist/photo/index.cjs +1 -2189
- package/dist/photo/index.d.cts +6 -6
- package/dist/photo/index.d.ts +6 -6
- package/dist/photo/index.js +1 -2186
- package/dist/ports-BN6RHF9W.d.cts +48 -0
- package/dist/ports-BN6RHF9W.d.ts +48 -0
- package/dist/ports-DEBzEhbp.d.cts +386 -0
- package/dist/ports-DMolTRzU.d.ts +386 -0
- package/dist/profile-CSs1wlXT.d.cts +93 -0
- package/dist/profile-CSs1wlXT.d.ts +93 -0
- package/dist/records/depth/index.cjs +2 -0
- package/dist/records/depth/index.d.cts +13 -0
- package/dist/records/depth/index.d.ts +13 -0
- package/dist/records/depth/index.js +2 -0
- package/dist/records/index.cjs +3 -2839
- package/dist/records/index.d.cts +137 -203
- package/dist/records/index.d.ts +137 -203
- package/dist/records/index.js +3 -2833
- package/dist/requestFunnel-CjW7uDuA.d.ts +87 -0
- package/dist/requestFunnel-L-BQfi0z.d.cts +87 -0
- package/dist/{resolve-Dq_4_agU.d.ts → resolve-D4Ywz5OS.d.cts} +10 -4
- package/dist/{resolve-Dq_4_agU.d.cts → resolve-D4Ywz5OS.d.ts} +10 -4
- package/dist/{runtime-Bvr8yqXm.d.cts → runtime-B8s-_hv8.d.cts} +121 -59
- package/dist/{runtime-BIYzf9cK.d.ts → runtime-BR9ysG0J.d.ts} +121 -59
- package/dist/server/events/index.cjs +2 -0
- package/dist/server/events/index.d.cts +550 -0
- package/dist/server/events/index.d.ts +550 -0
- package/dist/server/events/index.js +2 -0
- package/dist/server/index.cjs +2 -533
- package/dist/server/index.d.cts +73 -18
- package/dist/server/index.d.ts +73 -18
- package/dist/server/index.js +2 -530
- package/dist/species-BXAIMh7I.d.cts +9 -0
- package/dist/species-BXAIMh7I.d.ts +9 -0
- package/dist/televet/index.cjs +1 -0
- package/dist/televet/index.d.cts +60 -0
- package/dist/televet/index.d.ts +60 -0
- package/dist/televet/index.js +1 -0
- package/dist/testing/index.cjs +5 -823
- package/dist/testing/index.d.cts +17 -3
- package/dist/testing/index.d.ts +17 -3
- package/dist/testing/index.js +5 -820
- package/dist/testing/rn/index.cjs +1 -449
- package/dist/testing/rn/index.d.cts +17 -29
- package/dist/testing/rn/index.d.ts +17 -29
- package/dist/testing/rn/index.js +1 -444
- package/dist/testing/web/index.cjs +1 -0
- package/dist/testing/web/index.d.cts +131 -0
- package/dist/testing/web/index.d.ts +131 -0
- package/dist/testing/web/index.js +1 -0
- package/dist/timelineRows-CaohZzXS.d.cts +19 -0
- package/dist/timelineRows-DZed6dAM.d.ts +19 -0
- package/dist/typeStyle-0TydiZ1w.d.cts +19 -0
- package/dist/typeStyle-CWMsoe6b.d.ts +19 -0
- package/dist/uploadTransport-D0M0T4hN.d.ts +38 -0
- package/dist/uploadTransport-DKJHs3Yj.d.cts +38 -0
- package/dist/useRecordsDepth-BHBzJ76R.d.cts +237 -0
- package/dist/useRecordsDepth-BU-OhzH6.d.ts +237 -0
- package/dist/useVetVisit-Bc84hWUU.d.cts +187 -0
- package/dist/useVetVisit-CjmMa896.d.ts +187 -0
- package/dist/video/index.cjs +1 -1941
- package/dist/video/index.d.cts +4 -4
- package/dist/video/index.d.ts +4 -4
- package/dist/video/index.js +1 -1938
- package/dist/view-C3qPIXGX.d.cts +310 -0
- package/dist/view-DtSPYpKa.d.ts +310 -0
- package/dist/visitIntent-D7_yVp1I.d.cts +8 -0
- package/dist/visitIntent-D7_yVp1I.d.ts +8 -0
- package/dist/web/consent/index.cjs +1 -0
- package/dist/web/consent/index.d.cts +34 -0
- package/dist/web/consent/index.d.ts +34 -0
- package/dist/web/consent/index.js +1 -0
- package/dist/web/index.cjs +14 -0
- package/dist/web/index.d.cts +217 -0
- package/dist/web/index.d.ts +217 -0
- package/dist/web/index.js +14 -0
- package/dist/web/notifications/index.cjs +2 -0
- package/dist/web/notifications/index.d.cts +213 -0
- package/dist/web/notifications/index.d.ts +213 -0
- package/dist/web/notifications/index.js +2 -0
- package/dist/web/records/depth/index.cjs +2 -0
- package/dist/web/records/depth/index.d.cts +12 -0
- package/dist/web/records/depth/index.d.ts +12 -0
- package/dist/web/records/depth/index.js +2 -0
- package/dist/web/records/index.cjs +4 -0
- package/dist/web/records/index.d.cts +194 -0
- package/dist/web/records/index.d.ts +194 -0
- package/dist/web/records/index.js +4 -0
- package/dist/web/televet/index.cjs +1 -0
- package/dist/web/televet/index.d.cts +50 -0
- package/dist/web/televet/index.d.ts +50 -0
- package/dist/web/televet/index.js +1 -0
- package/notifications/package.json +8 -0
- package/package.json +197 -9
- package/records/depth/package.json +8 -0
- package/server/events/device-blocked.cjs +15 -0
- package/server/events/package.json +9 -0
- package/televet/package.json +8 -0
- package/testing/web/native-blocked.cjs +12 -0
- package/testing/web/package.json +8 -0
- package/web/consent/native-blocked.cjs +12 -0
- package/web/consent/package.json +8 -0
- package/web/native-blocked.cjs +12 -0
- package/web/notifications/native-blocked.cjs +12 -0
- package/web/notifications/package.json +8 -0
- package/web/package.json +8 -0
- package/web/records/depth/native-blocked.cjs +12 -0
- package/web/records/depth/package.json +8 -0
- package/web/records/native-blocked.cjs +12 -0
- package/web/records/package.json +8 -0
- package/web/televet/native-blocked.cjs +12 -0
- package/web/televet/package.json +8 -0
- package/dist/ChatController-CKdBvPj2.d.ts +0 -146
- package/dist/ChatController-CpUMvvZf.d.cts +0 -146
- package/dist/FilePort-BabWrv7I.d.cts +0 -22
- package/dist/FilePort-BabWrv7I.d.ts +0 -22
- package/dist/petsRepository-BEGb97M9.d.cts +0 -326
- package/dist/petsRepository-Bu18r2kK.d.ts +0 -326
- package/dist/requestFunnel-DuUH-kAe.d.cts +0 -28
- package/dist/requestFunnel-dio5OmR9.d.ts +0 -28
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import {createContext,useMemo,useState,useRef,useEffect,useCallback,useContext}from'react';var Ye=Object.defineProperty;var n=(e,r)=>Ye(e,"name",{value:r,configurable:true});function T(e,r){return Object.freeze(r===void 0?{ok:true,value:e}:{ok:true,value:e,warning:r})}n(T,"ok");function u(e){return Object.freeze({ok:false,error:e})}n(u,"err");var A=class A extends Error{constructor(r,t){super(t),this.name="EverfurConfigError",this.kind=r,Object.setPrototypeOf(this,A.prototype);}};n(A,"EverfurConfigError");var F=A;var q=Object.freeze([Object.freeze({wireCode:"AccessDeniedException",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"AuthorizationException",envelope:"http_envelope",httpStatus:401,retryable:false}),Object.freeze({wireCode:"ConflictException",envelope:"http_envelope",httpStatus:409,retryable:true}),Object.freeze({wireCode:"DAILY_QUOTA_EXCEEDED",envelope:"http_envelope",httpStatus:429,retryable:true}),Object.freeze({wireCode:"FILE_TOO_LARGE",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"IDEMPOTENCY_KEY_IN_FLIGHT",envelope:"http_envelope",httpStatus:409,retryable:true}),Object.freeze({wireCode:"IDEMPOTENCY_KEY_REUSED_DIFFERENT_REQUEST",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"INVALID_CONTENT_TYPE",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"InternalFailureException",envelope:"http_envelope",httpStatus:500,retryable:true}),Object.freeze({wireCode:"MethodNotAllowedException",envelope:"http_envelope",httpStatus:405,retryable:false}),Object.freeze({wireCode:"NotImplementedException",envelope:"http_envelope",httpStatus:501,retryable:false}),Object.freeze({wireCode:"PaymentRequiredException",envelope:"http_envelope",httpStatus:402,retryable:false}),Object.freeze({wireCode:"ResourceNotFoundException",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"ServiceUnavailableException",envelope:"http_envelope",httpStatus:503,retryable:true}),Object.freeze({wireCode:"TIER_UPGRADE_REQUIRED",envelope:"http_envelope",httpStatus:402,retryable:false}),Object.freeze({wireCode:"ThrottlingException",envelope:"http_envelope",httpStatus:429,retryable:true}),Object.freeze({wireCode:"ValidationException",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"accessDenied",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"access_denied",envelope:"oauth_error",httpStatus:302,retryable:false}),Object.freeze({wireCode:"attachment_unreadable",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"authExpired",envelope:"http_envelope",httpStatus:401,retryable:true}),Object.freeze({wireCode:"authRejected",envelope:"http_envelope",httpStatus:401,retryable:false}),Object.freeze({wireCode:"consent_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"consent_required",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"consent_scope_wrong_route",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"device_cipher_unavailable",envelope:"http_envelope",httpStatus:503,retryable:true}),Object.freeze({wireCode:"email_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"event_cursor_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"event_filter_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"event_payload_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"event_type_not_available",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"event_type_unknown",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"idempotency_key_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"idempotency_key_required",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"idempotency_key_reused",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"insufficientCapability",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"insufficient_scope",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"internal_error",envelope:"sse_frame",httpStatus:200,retryable:false}),Object.freeze({wireCode:"invalidRequest",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_client",envelope:"oauth_error",httpStatus:401,retryable:false}),Object.freeze({wireCode:"invalid_client_metadata",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_grant",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_redirect_uri",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_request",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_scope",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_target",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"mcp_connection_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"mcp_request_conflict",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"mcp_request_gone",envelope:"http_envelope",httpStatus:410,retryable:false}),Object.freeze({wireCode:"mcp_request_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"not_found",envelope:"sse_frame",httpStatus:200,retryable:false}),Object.freeze({wireCode:"partner_visit_link_conflict",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"partner_visit_owner_only",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"partner_visit_pet_already_mapped",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"payload_too_large",envelope:"http_envelope",httpStatus:413,retryable:false}),Object.freeze({wireCode:"petRefInUse",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"pet_health_list_removals_unconfirmed",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"pet_health_species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"pet_not_registered",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"provider_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"rateLimited",envelope:"http_envelope",httpStatus:429,retryable:true}),Object.freeze({wireCode:"record_species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"record_subject_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"record_upload_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"records_consent_required",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"sandbox_only",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"session_required",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"share_limit_reached",envelope:"http_envelope",httpStatus:429,retryable:false}),Object.freeze({wireCode:"slow_down",envelope:"oauth_error",httpStatus:429,retryable:true}),Object.freeze({wireCode:"species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"tenant_filter_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"tenant_has_no_capabilities",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"tenant_resource_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"tenant_surface_not_enabled",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"timeout",envelope:"sse_frame",httpStatus:200,retryable:true}),Object.freeze({wireCode:"token_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"unavailable",envelope:"sse_frame",httpStatus:200,retryable:true}),Object.freeze({wireCode:"unavailable",envelope:"http_envelope",httpStatus:503,retryable:true}),Object.freeze({wireCode:"unsupported_grant_type",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"unsupported_response_type",envelope:"oauth_error",httpStatus:302,retryable:false}),Object.freeze({wireCode:"verify_mint_rate_limited",envelope:"http_envelope",httpStatus:429,retryable:true}),Object.freeze({wireCode:"verify_mint_refused",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"verify_mint_unavailable",envelope:"http_envelope",httpStatus:503,retryable:true}),Object.freeze({wireCode:"verify_user_ref_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"webhook_endpoint_update_empty",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"webhook_endpoint_update_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"webhook_url_rejected",envelope:"http_envelope",httpStatus:400,retryable:false})]);Object.freeze(q.map(e=>e.wireCode));var Ke=Object.freeze({ValidationException:"validationFailed",AuthorizationException:"authRejected",PaymentRequiredException:"paymentRequired",AccessDeniedException:"accessDenied",ResourceNotFoundException:"resourceNotFound",ConflictException:"conflict",ThrottlingException:"rateLimited",InternalFailureException:"internalError",NotImplementedException:"notImplemented",ServiceUnavailableException:"serviceUnavailable",MethodNotAllowedException:"validationFailed",authExpired:"authExpired",unavailable:"serviceUnavailable",session_required:"sessionRequired",accessDenied:"accessDenied",invalidRequest:"sdkUpdateRequired",authRejected:"authRejected",rateLimited:"rateLimited",insufficientCapability:"accessDenied",event_cursor_invalid:"validationFailed",event_filter_invalid:"validationFailed",event_payload_invalid:"validationFailed",event_type_unknown:"validationFailed",idempotency_key_invalid:"validationFailed",idempotency_key_required:"validationFailed",idempotency_key_reused:"idempotencyConflict",payload_too_large:"validationFailed",webhook_url_rejected:"validationFailed",webhook_endpoint_update_empty:"validationFailed",webhook_endpoint_update_invalid:"validationFailed",event_type_not_available:"conflict",record_subject_not_found:"resourceNotFound",records_consent_required:"conflict",record_species_unsupported:"validationFailed",record_upload_invalid:"validationFailed",FILE_TOO_LARGE:"validationFailed",INVALID_CONTENT_TYPE:"validationFailed",attachment_unreadable:"validationFailed",provider_unsupported:"validationFailed",token_invalid:"validationFailed",device_cipher_unavailable:"serviceUnavailable",email_invalid:"validationFailed",consent_required:"validationFailed",consent_invalid:"validationFailed",consent_scope_wrong_route:"validationFailed",IDEMPOTENCY_KEY_IN_FLIGHT:"idempotencyInFlight",IDEMPOTENCY_KEY_REUSED_DIFFERENT_REQUEST:"idempotencyConflict",DAILY_QUOTA_EXCEEDED:"quotaExceeded",TIER_UPGRADE_REQUIRED:"paymentRequired",not_found:"conversationNotFound",timeout:"streamTimeout",internal_error:"internalError",invalid_request:"validationFailed",invalid_client:"authRejected",invalid_grant:"authRejected",unsupported_grant_type:"validationFailed",invalid_scope:"validationFailed",invalid_target:"validationFailed",invalid_redirect_uri:"validationFailed",invalid_client_metadata:"validationFailed",unsupported_response_type:"validationFailed",access_denied:"accessDenied",slow_down:"rateLimited",mcp_request_not_found:"resourceNotFound",mcp_request_gone:"resourceNotFound",mcp_connection_not_found:"resourceNotFound",mcp_request_conflict:"conflict",sandbox_only:"accessDenied",tenant_has_no_capabilities:"conflict",verify_mint_refused:"accessDenied",verify_mint_rate_limited:"rateLimited",verify_mint_unavailable:"serviceUnavailable",verify_user_ref_invalid:"validationFailed",insufficient_scope:"accessDenied",tenant_filter_invalid:"validationFailed",tenant_resource_not_found:"resourceNotFound",tenant_surface_not_enabled:"conflict",pet_health_species_unsupported:"validationFailed",pet_health_list_removals_unconfirmed:"validationFailed",petRefInUse:"conflict",share_limit_reached:"conflict",pet_not_registered:"resourceNotFound",species_unsupported:"validationFailed",partner_visit_owner_only:"accessDenied",partner_visit_link_conflict:"conflict",partner_visit_pet_already_mapped:"conflict"}),ie=Object.freeze(q.map(e=>Object.freeze({wireCode:e.wireCode,envelope:e.envelope,retryable:e.retryable,normalized:Ke[e.wireCode]}))),He=new Map(ie.map(e=>[e.envelope+e.wireCode.toUpperCase(),e])),We=Object.freeze(["http_envelope",...[...new Set(ie.map(e=>e.envelope))].filter(e=>e!=="http_envelope").sort()]);function D(e,r){if(typeof e!="string")return;let t=e.trim().toUpperCase();if(t.length!==0)for(let o of [r??"http_envelope",...We]){let i=He.get(o+t);if(i)return i}}n(D,"contractErrorFor");function Ge(e){return e.envelope==="sse_frame"?`/errors#sse-${e.wireCode}`:e.envelope==="oauth_error"?`/errors#oauth-${e.wireCode}`:`/errors#${e.wireCode}`}n(Ge,"contractDocUrl");function ae(e){return null}n(ae,"publishedDocUrl");var $e=Object.freeze({authExpired:"authentication",authRejected:"authentication",sessionRequired:"authentication",accessDenied:"authorization",paymentRequired:"entitlement",quotaExceeded:"rateLimit",rateLimited:"rateLimit",validationFailed:"invalidRequest",sdkUpdateRequired:"invalidRequest",conversationNotFound:"notFound",petNotFound:"notFound",resourceNotFound:"notFound",conflict:"conflict",idempotencyConflict:"conflict",idempotencyInFlight:"conflict",streamTimeout:"connection",streamIncomplete:"connection",upstreamLlmTimeout:"connection",serviceUnavailable:"connection",internalError:"server",notImplemented:"server",mediaUploadFailed:"media",moderationBlocked:"policy",unknown:"unknown"});function se(e){return $e[e]}n(se,"categoryFor");function le(e){let r=D(e);if(r)return r.normalized;let t=(e??"").trim().toUpperCase(),o=t.replace(/[^A-Z0-9]/g,"");if(o==="AUTHREJECTED")return "authRejected";if(t.startsWith("AUTH"))return "authExpired";switch(o){case "DAILYQUOTAEXCEEDED":case "QUOTAEXCEEDED":return "quotaExceeded";case "RATELIMITED":case "TOOMANYREQUESTS":return "rateLimited";case "IDEMPOTENCYKEYCONFLICT":case "IDEMPOTENCYCONFLICT":return "idempotencyConflict";case "ACCESSDENIED":case "FORBIDDEN":return "accessDenied";case "NOTFOUND":case "CONVERSATIONNOTFOUND":return "conversationNotFound";case "PETNOTFOUND":return "petNotFound";case "TIMEOUT":case "STREAMTIMEOUT":return "streamTimeout";case "MEDIAUPLOADFAILED":case "UNRECOGNIZEDVIDEOFORMAT":case "FILETOOSMALL":return "mediaUploadFailed";case "MODERATIONBLOCKED":return "moderationBlocked";case "UPSTREAMLLMTIMEOUT":return "upstreamLlmTimeout";case "INTERNALERROR":case "INTERNALSERVERERROR":return "internalError";case "STREAMINCOMPLETE":case "CHATSTREAMINCOMPLETE":return "streamIncomplete";case "INVALIDANALYSISTYPE":case "INVALIDUPLOADPURPOSE":return "unknown";default:return "unknown"}}n(le,"fromWire");var Qe=new Set(["streamTimeout","rateLimited","internalError","upstreamLlmTimeout","streamIncomplete"]);function V(e){return Qe.has(e)}n(V,"isAutoRetryable");var Xe=new Set(["serviceUnavailable","conflict","idempotencyInFlight"]);function ue(e){return V(e)||Xe.has(e)}n(ue,"isRetryableCode");var Je=500,B=8e3,de=4;function ce(e,r=Math.random){let t=Math.max(0,e),o=Math.min(Je*2**t,B);return Math.floor(r()*o)}n(ce,"backoffDelayMs");var Ze=Object.freeze({authExpired:"Please sign in again to continue.",authRejected:"Please sign in again to continue.",sessionRequired:"This app needs to be updated to keep using Everfur.",accessDenied:"This feature isn't available on your account right now.",paymentRequired:"This is part of a paid plan.",quotaExceeded:"You have used today's messages. This resets tomorrow.",rateLimited:"You are sending messages quickly. Try again in a few seconds.",validationFailed:"Something in that request was not right. Check the details and try again.",sdkUpdateRequired:"This app needs to be updated to keep using Everfur.",conflict:"That is already running. Wait for it to finish, then try again.",idempotencyConflict:"That message was already delivered.",idempotencyInFlight:"That is still processing. Give it a moment.",conversationNotFound:"This conversation is no longer available.",petNotFound:"We could not find that pet. Please pick a pet and try again.",resourceNotFound:"We could not find that.",streamTimeout:"The response timed out. Tap retry to try again.",mediaUploadFailed:"We could not upload that photo. Please attach it again.",moderationBlocked:"This request cannot be answered here.",upstreamLlmTimeout:"The response timed out. Tap retry to try again.",internalError:"We hit a snag on our end. Please try again.",notImplemented:"That is not available yet.",serviceUnavailable:"That service is briefly unavailable. Try again shortly.",streamIncomplete:"The connection dropped mid-answer. Tap retry to continue.",unknown:"Something went wrong. Please try again."});function er(e){return Ze[e]}n(er,"userFacingError");function fe(e,r,t){Object.defineProperty(e,r,{value:t,enumerable:false,writable:false,configurable:false});}n(fe,"defineHidden");var rr=/^[a-z][a-z0-9_]{0,63}$/;function _(e,r){let t=D(r?.wireCode,r?.wireEnvelope),o={code:e,category:se(e),retryable:r?.retryable??ue(e),displayMessage:er(e)};if(r?.httpStatus!==void 0&&(o.httpStatus=r.httpStatus),r?.requestId&&(o.requestId=r.requestId),typeof r?.reasonCode=="string"&&rr.test(r.reasonCode)&&(o.reasonCode=r.reasonCode),t);return r?.wireMessage&&fe(o,"wireMessage",r.wireMessage),r?.raw!==void 0&&r.raw!==null&&fe(o,"raw",r.raw),Object.freeze(o)}n(_,"makeEverfurError");function pe(e){return Object.freeze({kind:"error",terminal:true,code:e.code,retryable:e.retryable,wireMessage:e.wireMessage,synthesized:e.synthesized,lastEventId:e.lastEventId,serverRequestId:e.serverRequestId??null})}n(pe,"errorFrame");function or(e){let r={};return e.mode==="personalized"?r.authorization=`Bearer ${e.token}`:r["x-everfur-partner-key"]=e.publishableKey,e.userRef&&(r["x-everfur-user-ref"]=e.userRef),e.sessionId&&(r["x-everfur-session-id"]=e.sessionId),r}n(or,"authHeaders");function x(e,r){return {...e,headers:{...ir(e.headers),...or(r)}}}n(x,"withAuthHeaders");function ir(e){if(!e)return {};let r={};for(let[t,o]of Object.entries(e)){let i=t.toLowerCase();i==="authorization"||i==="x-everfur-partner-key"||(r[t]=o);}return r}n(ir,"stripAuthHeaders");async function ye(e,r){if(r.mode==="anonymous")return r.transport.request(x(e,{mode:"anonymous",publishableKey:r.publishableKey,userRef:r.userRef,...r.sessionId?{sessionId:r.sessionId}:{}}));let t;try{t=await r.identity.currentToken();}catch{return u(Y())}let o=await r.transport.request(x(e,{mode:"personalized",token:t,userRef:r.userRef,...r.sessionId?{sessionId:r.sessionId}:{}}));if(o.ok||o.error.httpStatus!==401)return o;let i;try{i=await r.identity.currentToken({forceRefresh:!0});}catch{return u(Y())}let a=await r.transport.request(x(e,{mode:"personalized",token:i,userRef:r.userRef,...r.sessionId?{sessionId:r.sessionId}:{}}));return !a.ok&&a.error.httpStatus===401?u(Y(a.error.httpStatus)):a}n(ye,"authedSend");function Y(e){return _("authRejected",{retryable:false,...e!==void 0?{httpStatus:e}:{}})}n(Y,"authRejectedError");function ve(e){return _("internalError",{retryable:true,wireMessage:ar(e)})}n(ve,"networkError");function ar(e){return e instanceof Error?e.message:typeof e=="string"?e:"network request failed"}n(ar,"describeCause");var sr=3e4,lr=B*2,ur="idempotency-key",dr=new Set(["POST","PUT","PATCH","DELETE"]),cr=Object.freeze({onEvent(){}}),fr=Object.freeze({setTimeout:n((e,r)=>setTimeout(e,r),"setTimeout"),clearTimeout:n(e=>clearTimeout(e),"clearTimeout"),now:n(()=>Date.now(),"now")});function j(e){let r=e.observer??cr,t=e.timers??fr,o=e.rng??Math.random,i=e.sleep??((y,c)=>Tr(y,t,c)),a=e.maxAttempts??de,s=e.unaryTimeoutMs??sr,l=e.newIdempotencyKey??yr(),d=n(y=>{try{r.onEvent(y);}catch{}},"emit");async function h(y,c,C){let S=C?.maxAttempts,P=Math.max(1,S??a),f=C?.idempotent??dr.has(c.method)?l():null,p=pr(c,f),v=0;for(;;){let E=n(L=>Object.freeze({call:y,method:c.method,path:c.path,attempt:v,...f?{idempotencyKey:f}:{},...L}),"stamp");d(E({phase:"attempt"}));let te=wr(s,t),ne=Cr(te.signal,c.signal),O;try{O=await ye({...p,signal:ne.signal},e.auth);}catch(L){O=u(ve(L));}finally{ne.dispose(),te.cancel();}if(O.ok)return d(E({phase:"settled",ok:true,reason:"ok"})),O;let R=O.error,N=mr(R,v,{maxAttempts:P,rng:o,now:t.now(),aborted:c.signal?.aborted===true,...S!==void 0?{perCallMaxAttempts:S}:{},...e.errorPolicy!==void 0?{policy:e.errorPolicy}:{}}),U={ok:false,code:R.code,reason:N.reason,...R.httpStatus!==void 0?{httpStatus:R.httpStatus}:{},...R.requestId!==void 0?{requestId:R.requestId}:{}};if(!N.retry)return d(E({phase:"settled",...U})),u(R);if(d(E({phase:"retry",...U,delayMs:N.delayMs})),await i(N.delayMs,c.signal),c.signal?.aborted===true)return d(E({phase:"settled",...U,reason:"aborted"})),u(R);v+=1;}}n(h,"send");async function w(y){return x(y,await Rr(e.auth))}n(w,"authorize");async function*g(y,c,C){d(Object.freeze({call:y,phase:"stream.open",method:c.method,path:c.path,attempt:0}));try{yield*e.auth.transport.stream(c,C);}catch{yield pe({code:"internal_error",retryable:true,wireMessage:null,synthesized:true,lastEventId:null,serverRequestId:null});}}return n(g,"stream"),Object.freeze({send:h,authorize:w,stream:g})}n(j,"createRequestFunnel");function pr(e,r){let t={};for(let[o,i]of Object.entries(e.headers??{}))o.toLowerCase()!==ur&&(t[o]=i);return r!==null&&(t["Idempotency-Key"]=r),{...e,headers:t}}n(pr,"assembleHeaders");function yr(){let e=0;return ()=>`efk_${Date.now().toString(36)}_${(e++).toString(36)}_${Math.random().toString(36).slice(2,12)}`}n(yr,"defaultIdempotencyKeyFactory");var vr=10;function mr(e,r,t){if(t.aborted)return {retry:false,reason:"aborted"};let o=Er(e);if(o==="quota")return {retry:false,reason:"daily-quota-exhausted"};if(o!=="burst"&&!V(e.code))return {retry:false,reason:"terminal-code"};let i=o==="burst"?"burst-throttle":"retryable-code";if(n(()=>{if(t.policy===void 0)return false;try{return !t.policy.shouldRetry(e.code,r)}catch{return false}},"policyVetoedRetry")())return {retry:false,reason:"terminal-code"};let s=n(()=>{if(t.policy===void 0)return null;let h;try{h=t.policy.maxAttempts(e.code);}catch{return null}return typeof h!="number"||!Number.isFinite(h)?null:Math.max(1,Math.min(vr,Math.floor(h)))},"policyCeiling"),l=t.perCallMaxAttempts??s()??t.maxAttempts;if(r+1>=l)return {retry:false,reason:"attempts-exhausted"};let d=_r(e,t.now);return d!==null?d>lr?{retry:false,reason:"server-reset-beyond-budget"}:{retry:true,reason:i,delayMs:d}:{retry:true,reason:i,delayMs:ce(r,t.rng)}}n(mr,"decideRetry");function Er(e){let r=e.code==="unknown"?le(br(e.raw)):e.code;return r==="quotaExceeded"?"quota":r==="rateLimited"||e.httpStatus===429?"burst":null}n(Er,"throttleKind");function _r(e,r){let t=gr(e.raw);if(t===null)return null;let o=t-r;return o>0?o:0}n(_r,"retryOverrideMs");function gr(e){for(let r of Ee(e)){let t=r.resets_at,o=hr(t);if(o!==null)return o}return null}n(gr,"findResetsAt");function Ee(e){if(!me(e))return [];let r=[e];for(let t of ["error","detail"]){let o=e[t];me(o)&&r.push(o);}return r}n(Ee,"candidateScopes");function hr(e){if(typeof e=="number"&&Number.isFinite(e))return e<1e11?Math.round(e*1e3):Math.round(e);if(typeof e=="string"&&e.trim().length>0){let r=Date.parse(e);return Number.isFinite(r)?r:null}return null}n(hr,"parseInstantMs");function br(e){for(let r of Ee(e)){let t=r.code;if(typeof t=="string"&&t.length>0)return t}return null}n(br,"rawWireCode");function me(e){return typeof e=="object"&&e!==null}n(me,"isRecord");async function Rr(e){return e.mode==="anonymous"?{mode:"anonymous",publishableKey:e.publishableKey,userRef:e.userRef,...e.sessionId?{sessionId:e.sessionId}:{}}:{mode:"personalized",token:await e.identity.currentToken(),userRef:e.userRef,...e.sessionId?{sessionId:e.sessionId}:{}}}n(Rr,"resolveDeviceAuth");function wr(e,r){let t=new AbortController,o=r.setTimeout(()=>t.abort(),e);return {signal:t.signal,cancel:n(()=>r.clearTimeout(o),"cancel")}}n(wr,"boundedSignal");function Cr(e,r){let t=n(()=>{},"noop");if(!r)return {signal:e,dispose:t};let o=new AbortController;if(e.aborted||r.aborted)return o.abort(),{signal:o.signal,dispose:t};let i=n(()=>o.abort(),"onAbort");return e.addEventListener("abort",i,{once:true}),r.addEventListener("abort",i,{once:true}),{signal:o.signal,dispose:n(()=>{e.removeEventListener("abort",i),r.removeEventListener("abort",i);},"dispose")}}n(Cr,"mergeSignals");function Tr(e,r,t){return e<=0||t?.aborted===true?Promise.resolve():new Promise(o=>{let i=r.setTimeout(()=>{t?.removeEventListener("abort",a),o();},e),a=n(()=>{r.clearTimeout(i),o();},"onAbort");t?.addEventListener("abort",a,{once:true});})}n(Tr,"delayAbortable");function Sr(e){let r=e.raw;if(typeof r!="object"||r===null)return null;let t=r.code;return typeof t=="string"&&t.length>0?t:null}n(Sr,"wireCodeOf");function _e(e,r){let t=Sr(e);if(t===null)return e;let o=r[t];return o===void 0?e:_(o.code,{retryable:o.retryable,...e.httpStatus!==void 0?{httpStatus:e.httpStatus}:{},...e.requestId!==void 0?{requestId:e.requestId}:{},wireCode:t,reasonCode:t,...e.wireMessage!==void 0?{wireMessage:e.wireMessage}:{},raw:e.raw})}n(_e,"foldWireReason");var we=Object.freeze({provider_unsupported:"Everfur does not send through this push provider yet. Register an Expo push token (provider expo) or an FCM registration token (provider fcm); APNs direct is not available in this version.",token_invalid:"The token is not a push token of the given provider. Expo tokens look like ExponentPushToken[...]; FCM registration tokens are long opaque strings. Pass the token exactly as your notification library printed it.",device_cipher_unavailable:"Everfur could not seal the token at rest, so nothing was stored. Retry the registration later; the SDK retries it on the next launch and login.",credentials_missing:"Everfur holds no push credential for this provider on your tenant, so deliveries to it are skipped. Expo needs nothing unless you enabled push security (then your Expo access token). A bare app using FCM supplies its Firebase service-account JSON to Everfur; push credentials are set by Everfur on your tenant, never through the SDK."}),Ir=new Set(["provider_unsupported","token_invalid","device_cipher_unavailable","credentials_missing"]);function kr(e){let r=e.reasonCode;return r!==void 0&&Ir.has(r)?we[r]:null}n(kr,"explainNotificationsReason");var Ce=new Set(["expo","fcm","apns"]),Te=new Set(["ios","android"]),ge=4096,he=128,be=64,Se=/[- ]/;function b(e,r){return _("validationFailed",{retryable:false,wireMessage:e,...r?{reasonCode:r}:{}})}n(b,"invalid");function Or(e){if(typeof e!="object"||e===null)return b("registerDevice needs an input object");let{token:r,provider:t,platform:o,installationId:i}=e;return typeof t!="string"||!Ce.has(t)?b("provider must be expo, fcm or apns"):typeof o!="string"||!Te.has(o)?b("platform must be ios or android"):typeof r!="string"||r.trim().length===0||r.length>ge||Se.test(r)?b(`token must be a push token of 1..${ge} characters with no whitespace`,"token_invalid"):i!==void 0&&(typeof i!="string"||i.length===0||i.length>he)?b(`installationId must be 1..${he} characters`):null}n(Or,"validateRegister");function Fr(e){return typeof e!="string"||e.length===0||e.length>be?b(`deviceId must be 1..${be} characters`):Se.test(e)||e.includes("/")||e==="."||e===".."?b("deviceId is not a device id"):null}n(Fr,"validateDeviceId");function xr(e){if(typeof e!="object"||e===null)return b("setPreferences needs an input object");let{pushEnabled:r,emailEnabled:t}=e;return typeof r!="boolean"||typeof t!="boolean"?b("pushEnabled and emailEnabled must both be booleans: the route replaces both switches"):null}n(xr,"validatePreferences");function I(e){return typeof e=="string"&&e.length>0?e:null}n(I,"str");function Pr(e){if(typeof e!="object"||e===null)return null;let r=e,t=I(r.device_id),o=I(r.provider),i=I(r.platform),a=I(r.registered_at),s=I(r.last_seen_at);if(t===null||o===null||i===null||a===null||s===null||!Ce.has(o)||!Te.has(i))return null;let l=r.installation_id;return Object.freeze({deviceId:t,provider:o,platform:i,installationId:typeof l=="string"&&l.length>0?l:null,registeredAt:a,lastSeenAt:s})}n(Pr,"parseDevice");function Nr(e){if(typeof e!="object"||e===null)return null;let r=e,t=I(r.updated_at);return typeof r.push_enabled!="boolean"||typeof r.email_enabled!="boolean"||t===null?null:Object.freeze({pushEnabled:r.push_enabled,emailEnabled:r.email_enabled,updatedAt:t})}n(Nr,"parsePreferences");function Re(e){return _("internalError",{retryable:false,wireMessage:`${e}: the response was not the documented shape`})}n(Re,"malformed");var Ar=Object.freeze({provider_unsupported:{code:"validationFailed",retryable:false},token_invalid:{code:"validationFailed",retryable:false},device_cipher_unavailable:{code:"serviceUnavailable",retryable:true}});function K(e){return _e(e,Ar)}n(K,"refine");function H(e){return _("validationFailed",{retryable:false,wireMessage:`the Everfur runtime is disposed; ${e} was called after unmount`})}n(H,"disposed");function W(e){let r=n(()=>{let{services:t}=e.registry;return G({auth:t.authFor(null),...t.errorPolicy?{errorPolicy:t.errorPolicy}:{}})},"over");return {registerDevice:n((t,o)=>e.isDisposed?Promise.resolve(u(H("registerDevice"))):r().registerDevice(t,o),"registerDevice"),unregisterDevice:n((t,o)=>e.isDisposed?Promise.resolve(u(H("unregisterDevice"))):r().unregisterDevice(t,o),"unregisterDevice"),setPreferences:n((t,o)=>e.isDisposed?Promise.resolve(u(H("setPreferences"))):r().setPreferences(t,o),"setPreferences")}}n(W,"createNotificationsClient");function G(e){let r=e.funnel??j({auth:e.auth,...e.errorPolicy?{errorPolicy:e.errorPolicy}:{}}),t=n((o,i)=>i?{...o,signal:i}:o,"withSignal");return {async registerDevice(o,i){let a=Or(o);if(a!==null)return u(a);let s={token:o.token,provider:o.provider,platform:o.platform};o.installationId!==void 0&&(s.installation_id=o.installationId);let l=await r.send("notifications.registerDevice",t({method:"POST",path:"/widget/v1/me/devices",body:s},i?.signal));if(!l.ok)return u(K(l.error));let d=Pr(l.value);return d===null?u(Re("registerDevice")):T(d)},async unregisterDevice(o,i){let a=Fr(o);if(a!==null)return u(a);let s=await r.send("notifications.unregisterDevice",t({method:"DELETE",path:`/widget/v1/me/devices/${encodeURIComponent(o)}`},i?.signal));return s.ok?T(void 0):u(K(s.error))},async setPreferences(o,i){let a=xr(o);if(a!==null)return u(a);let s=await r.send("notifications.setPreferences",t({method:"PUT",path:"/widget/v1/me/notification-preferences",body:{push_enabled:o.pushEnabled,email_enabled:o.emailEnabled}},i?.signal));if(!s.ok)return u(K(s.error));let l=Nr(s.value);return l===null?u(Re("setPreferences")):T(l)}}}n(G,"createNotificationsClientOver");var z="everfur.notifications.device";var Ie=Symbol.for("@everfur/sdk#EverfurContext@v1"),ke=globalThis,Oe=ke[Ie]??(ke[Ie]=createContext(null));Oe.displayName??="EverfurContext";function $(){let e=useContext(Oe);if(e===null)throw new F("not-initialized","Everfur hooks must be called inside <EverfurProvider>. Wrap your tree once, high.");return e}n($,"useEverfurContext");var De=1;async function X(e){try{let r=await e.getItem(z);if(r===null)return null;let t=JSON.parse(r);if(typeof t!="object"||t===null)return null;let{v:o,userRef:i,deviceId:a}=t;return o!==De||typeof i!="string"||typeof a!="string"||a.length===0?null:{userRef:i,deviceId:a}}catch{return null}}n(X,"readStored");async function Mr(e,r){try{await e.setItem(z,JSON.stringify({v:De,...r}));}catch{}}n(Mr,"writeStored");async function xe(e){try{await e.removeItem(z);}catch{}}n(xe,"clearStored");var Pe=Object.freeze({status:"signed_out",device:null,error:null}),Ne=Object.freeze({status:"no_token",device:null,error:null});function J(){return _("sessionRequired",{retryable:false,wireMessage:"notifications need a signed-in user on the provider"})}n(J,"noUser");function je(){let{runtime:e}=$();return useMemo(()=>W(e),[e])}n(je,"useEverfurNotificationsClient");function Ur(e){let{runtime:r,userRef:t}=$(),{token:o,provider:i,platform:a,installationId:s}=e,l=r.registry.services.kv,d=je(),[h,w]=useState(t===null?Pe:Ne),g=useRef(null),y=useRef(0);useEffect(()=>{if(y.current+=1,g.current=null,w(t===null?Pe:Ne),t===null)return;let m=true;return X(l).then(f=>{if(!m||f===null||f.userRef!==t)return;let p=g.current;if(p===null){g.current=f;return}p.deviceId!==f.deviceId&&d.unregisterDevice(f.deviceId);}),()=>{m=false;}},[d,l,t]);let c=useCallback(async(m,f)=>{let p=y.current+=1;w({status:"registering",device:null,error:null});let v=await d.registerDevice({token:f,provider:i,platform:a,...s===void 0?{}:{installationId:s}});if(p!==y.current)return v;if(!v.ok)return w({status:v.error.httpStatus===404?"unavailable":"failed",device:null,error:v.error}),v;let E=g.current;return g.current={userRef:m,deviceId:v.value.deviceId},w({status:"registered",device:v.value,error:null}),await Mr(l,g.current),E!==null&&E.userRef===m&&E.deviceId!==v.value.deviceId&&d.unregisterDevice(E.deviceId),v},[d,l,i,a,s]);useEffect(()=>{t===null||o===null||c(t,o);},[c,t,o]),useEffect(()=>r.onBeforeLogout(async({userRef:m,auth:f})=>{let p=g.current??await X(l);if(p===null||p.userRef!==m)return;g.current=null;let v=j({auth:f,maxAttempts:1,unaryTimeoutMs:3e3,...r.registry.services.errorPolicy?{errorPolicy:r.registry.services.errorPolicy}:{}}),E=await G({auth:f,funnel:v}).unregisterDevice(p.deviceId);(E.ok||E.error.httpStatus===404)&&await xe(l);}),[r,l]);let C=useCallback(async()=>t===null?u(J()):o===null?u(_("validationFailed",{retryable:false,reasonCode:"token_invalid",wireMessage:"no push token was given"})):c(t,o),[c,t,o]),S=useCallback(async()=>{if(t===null)return u(J());let m=g.current??await X(l);if(m===null||m.userRef!==t)return T(void 0);let f=y.current+=1,p=await d.unregisterDevice(m.deviceId);return p.ok||p.error.httpStatus===404?(g.current=null,await xe(l),f===y.current&&w({status:"unregistered",device:null,error:null}),p.ok?p:T(void 0)):p},[d,l,t]),P=useCallback(m=>t===null?Promise.resolve(u(J())):d.setPreferences(m),[d,t]);return useMemo(()=>({status:h.status,device:h.device,error:h.error,register:C,unregister:S,setPreferences:P}),[h,C,S,P])}n(Ur,"useEverfurNotifications");var ze=Object.freeze({"visit.booked":"visit","visit.reminder":"join","visit.rescheduled":"visit","visit.followup_sent":"messages","visit.message_received":"messages","visit.completed":"summary","visit.ended":"visit","visit.cancelled":null,"visit.no_show":null});function Me(e){return Object.prototype.hasOwnProperty.call(ze,e)?ze[e]:"visit"}n(Me,"vetVisitIntentForEvent");var Le=1,qe=Object.freeze(["record_request","pet","visit","case"]),Ve=Object.freeze(["record_request.updated","record.ready","pet.vaccination.due","visit.booked","visit.cancelled","visit.completed","visit.no_show","visit.rescheduled","visit.reminder","visit.followup_sent","visit.message_received","visit.ended","chat.follow_up_due","chat.reminder_due","record.activation"]),ee=["v","event_id","event_type","target"],Lr=new Set(["kind","conversation_id","request_id","visit_ref","case_ref","pet_ref"]),qr=new Set(Ve),Vr=new Set(qe),Br=128,Yr=4096,Kr=/^evt_[A-Za-z0-9]{1,64}$/,Hr=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i,Wr=/[-]/;function k(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}n(k,"isRecord");function Be(e){return Object.keys(e)}n(Be,"keysOf");function Gr(e){if(k(e))return e;if(typeof e!="string"||e.length===0||e.length>Yr)return null;let r=JSON.parse(e);return k(r)?r:null}n(Gr,"decodeBlock");function $r(e,r){let t=e;for(let o of r){if(!k(t))return;t=t[o];}return t}n($r,"at");var Qr=[[],["data"],["request","content","data"],["notification","request","content","data"]];function Xr(e){if(!k(e))return null;for(let r of Qr){let t=$r(e,r);if(k(t)&&"everfur"in t)return t.everfur}return ee.every(r=>r in e)?e:null}n(Xr,"locateBlock");function re(e){return typeof e!="string"||e.length===0||e.length>Br||Wr.test(e)||e.includes("://")||e.toLowerCase().startsWith("everfur")?null:e}n(re,"opaqueString");function Ue(e,r){if(!(r in e))return {ok:true,value:null};let t=re(e[r]);return t===null?{ok:false}:{ok:true,value:t}}n(Ue,"optional");function Z(e,r){return r in e?re(e[r]):null}n(Z,"required");function Jr(e,r){if(!k(e))return null;let t=Be(e);if(!t.includes("kind")||t.some(s=>!Lr.has(s)))return null;let o=e.kind;if(typeof o!="string"||!Vr.has(o))return null;for(let s of t)if(s!=="kind"&&re(e[s])===null)return null;let i=Ue(e,"pet_ref");if(!i.ok)return null;let a=i.value;switch(o){case "record_request":{let s=Z(e,"request_id");return s===null?null:Object.freeze({kind:"record_request",requestId:s,petRef:a})}case "pet":return a===null?null:Object.freeze({kind:"pet",petRef:a});case "visit":{let s=Z(e,"visit_ref");return s===null?null:Object.freeze({kind:"visit",visitRef:s,petRef:a,intent:Me(r)})}case "case":{let s=Z(e,"case_ref");if(s===null)return null;let l=Ue(e,"conversation_id");return !l.ok||l.value!==null&&!Hr.test(l.value)?null:Object.freeze({kind:"case",caseRef:s,conversationId:l.value,petRef:a})}default:return null}}n(Jr,"parseTarget");function Zr(e){let r=Be(e);if(r.length!==ee.length||ee.some(a=>!r.includes(a))||e.v!==Le)return null;let t=e.event_id;if(typeof t!="string"||!Kr.test(t))return null;let o=e.event_type;if(typeof o!="string"||!qr.has(o))return null;let i=Jr(e.target,o);return i===null?null:Object.freeze({eventId:t,eventType:o,target:i})}n(Zr,"parseBlock");function et(e){try{let r=Gr(Xr(e));return r===null?null:Zr(r)}catch{return null}}n(et,"parseEverfurNotification");
|
|
2
|
+
export{Ve as EVERFUR_NOTIFICATION_EVENT_TYPES,qe as EVERFUR_NOTIFICATION_TARGET_KINDS,Le as EVERFUR_NOTIFICATION_VERSION,we as NOTIFICATIONS_REASON_MESSAGES,W as createNotificationsClient,kr as explainNotificationsReason,et as parseEverfurNotification,Ur as useEverfurNotifications,je as useEverfurNotificationsClient};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
'use strict';var react=require('react'),zod=require('zod'),jsxRuntime=require('react/jsx-runtime');var St=Object.defineProperty;var o=(e,r)=>St(e,"name",{value:r,configurable:true});function wt(e,r){if(e===void 0)return {};let t={};return e.backgroundColor!==void 0&&(t.backgroundColor=e.backgroundColor),e.borderColor!==void 0&&(t.borderColor=e.borderColor,t.borderWidth=r??1),e.borderRadius!==void 0&&(t.borderRadius=e.borderRadius),t}o(wt,"slotBox");function U(e){return e?.textColor===void 0?{}:{color:e.textColor}}o(U,"slotText");function L(e,r){let t=wt(e,r),n={};return t.backgroundColor!==void 0&&(n.backgroundColor=t.backgroundColor),t.borderColor!==void 0&&(n.border=`${t.borderWidth??1}px solid ${t.borderColor}`),t.borderRadius!==void 0&&(n.borderRadius=t.borderRadius),n}o(L,"slotBoxCss");function Ke(e){let r=globalThis.console;try{r?.error?.("[everfur] A host callback threw; the SDK ignored it.",e);}catch{}}o(Ke,"reportHostFailure");function kt(e){return (typeof e=="object"||typeof e=="function")&&e!==null&&typeof e.then=="function"}o(kt,"isThenable");function Tt(e,...r){if(typeof e=="function")try{let t=e(...r);return kt(t)&&Promise.resolve(t).then(void 0,Ke),t}catch(t){Ke(t);return}}o(Tt,"callHost");var Ge=new WeakMap;function X(e){if(typeof e!="function")return;let r=Ge.get(e);if(r!==void 0)return r;let t=o((...n)=>{Tt(e,...n);},"guarded");return Ge.set(e,t),t}o(X,"guardHost");function $(e,r){return Object.freeze(r===void 0?{ok:true,value:e}:{ok:true,value:e,warning:r})}o($,"ok");function O(e){return Object.freeze({ok:false,error:e})}o(O,"err");var oe=class oe extends Error{constructor(r,t){super(t),this.name="EverfurConfigError",this.kind=r,Object.setPrototypeOf(this,oe.prototype);}};o(oe,"EverfurConfigError");var Q=oe;var Xe=Symbol.for("@everfur/sdk#EverfurContext@v1"),Qe=globalThis,Je=Qe[Xe]??(Qe[Xe]=react.createContext(null));Je.displayName??="EverfurContext";function M(){let e=react.useContext(Je);if(e===null)throw new Q("not-initialized","Everfur hooks must be called inside <EverfurProvider>. Wrap your tree once, high.");return e}o(M,"useEverfurContext");var B=Object.freeze({loading:"Loading",empty:"No records yet",upload:"Upload records",consentRequired:"Consent required",allow:"Allow",sessionRequired:"Sign in required",recordUnavailable:"Record unavailable",retry:"Try again",records:"Records",beingReviewed:"being reviewed"});var Ft="your pet";function I(e){let r=e?.trim()??"";return r.length>0?r:Ft}o(I,"petNameOr");var Ze=Object.freeze({title:"Health records",openTimeline:"Open timeline",loading:"Loading health records",lead:o(e=>`${I(e)}\u2019s lab trends`,"lead"),retryMarkers:"Retry loading lab trends",viewFullRecord:"View full medical record",viewTimeline:"View full timeline",important:o(e=>`Important: ${e}`,"important")});Object.freeze({title:"Marker Summary",marker:"Marker",markers:"Markers",outOfRange:"OUT OF RANGE",inRange:"IN RANGE",noRange:"NO RANGE",subtitle:"Summary of your pet\u2019s biomarkers",ask:"Ask about these markers",askA11y:"Ask Everfur about these markers",a11y:o((e,r,t,n)=>`Marker summary: ${e} ${e===1?"marker":"markers"}, ${r} in range, ${t} out of range${n>0?`, ${n} without a range`:""}.`,"a11y")});Object.freeze({counter:o((e,r)=>`${e+1} of ${r}`,"counter"),a11y:o((e,r,t)=>e!==null?`${e}, marker ${r+1} of ${t}. Swipe left or right to see more markers.`:`Marker ${r+1} of ${t}`,"a11y")});Object.freeze({tapHint:"Tap a point to see where it came from.",singleHint:"One reading so far: we\u2019ll plot a trend as more come in.",empty:"No readings for this marker yet.",ask:"Ask about this marker",askA11y:o(e=>`Ask Everfur about ${e}`,"askA11y"),status:o(e=>`Status: ${e}`,"status"),latestA11y:o((e,r,t)=>`Latest reading ${e}, ${r}, collected ${t}`,"latestA11y"),readingsA11y:o(e=>`${e} readings, oldest to newest`,"readingsA11y")});Object.freeze({title:o(e=>`${I(e)}\u2019s records request`,"title"),body:o(e=>`We\u2019re requesting ${I(e)}\u2019s records from your vet. This usually takes a few days; we\u2019ll show lab trends here as soon as they arrive.`,"body"),a11y:o(e=>`Records request in progress for ${I(e)}.`,"a11y"),openA11y:o((e,r)=>`Open ${I(e)}\u2019s records request. ${r}`,"openA11y"),ask:"Ask about this request",askA11y:"Ask Everfur about this records request"});Object.freeze({title:o(e=>`Add ${I(e)}\u2019s records`,"title"),body:"Records can come from more than one clinic over a lifetime.",requestFromClinic:"Request from a clinic",requestFromClinicA11y:o(e=>`Request ${I(e)}\u2019s records from a clinic`,"requestFromClinicA11y"),uploadDocument:"Upload a document",uploadDocumentA11y:o(e=>`Upload one of ${I(e)}\u2019s records`,"uploadDocumentA11y")});function er(e){return e?.httpStatus===429?"rate_limited":e?.httpStatus===502?"service_unavailable":"error"}o(er,"recordsEmptyVariantForError");function tr(e,r){return e===null?"":r?`${e} ${r}`:e}o(tr,"formatEntityValue");var rr=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];function w(e){if(!e)return "-";let r=/^(\d{4})-(\d{2})-(\d{2})/.exec(e);if(r!==null){let i=rr[Number(r[2])-1];return i===void 0?"-":`${i} ${Number(r[3])}, ${r[1]}`}let t=Date.parse(e);if(Number.isNaN(t))return "-";let n=new Date(t);return `${rr[n.getUTCMonth()]} ${n.getUTCDate()}, ${n.getUTCFullYear()}`}o(w,"formatRecordsDate");var h=Object.freeze({timeline:"Timeline",loadingTimeline:"Loading timeline",labResults:"Blood & lab work",visits:"Visits",physicalExams:"Physical exams",visitNotes:"Visit notes",visit:"Visit",exam:"Exam",visitNote:"Visit note",notRecorded:"Not recorded",abnormal:"Abnormal",notExamined:"Not examined",normal:"Normal",measured:o(e=>`Measured ${e}`,"measured"),uploadedDocument:"Uploaded document",kind:Object.freeze({visit:"Visit",vaccine:"Vaccine",weight:"Weight",medication:"Medication"}),clinicVisit:"Clinic visit",doctor:o(e=>`Dr. ${e}`,"doctor"),lot:o(e=>`Lot ${e}`,"lot"),expires:o(e=>`Expires ${e}`,"expires")});function ir(e){switch(e){case "above":return {label:"Above range",outOfRange:true};case "below":return {label:"Below range",outOfRange:true};case "in_range":return {label:"In range",outOfRange:false};default:return {label:"No range on file",outOfRange:false}}}o(ir,"markerStatusLabel");function Dt(e,r){return r<2?null:`${e==="flat"?"Holding steady":`Trending ${e==="down"?"down":e==="up"?"up":"steady"}`} over ${r} visits`}o(Dt,"trajectoryLabel");function ie(e){let r=e.replace(/_/g," ").trim();return r.length===0?e:r.charAt(0).toUpperCase()+r.slice(1)}o(ie,"humanize");var nr=Object.freeze({general:"General / attitude",eent:"Eyes, ears, nose & throat",oral_dental:"Oral & dental",cardiovascular:"Cardiovascular",respiratory:"Respiratory",gastrointestinal:"GI / abdomen",urogenital:"Urogenital",musculoskeletal:"Musculoskeletal",neurologic:"Neurologic",integument:"Skin & coat",lymphatic:"Lymph nodes"});function ar(e){return Object.prototype.hasOwnProperty.call(nr,e)?nr[e]:ie(e)}o(ar,"bodySystemLabel");var or=Object.freeze({reason_for_visit:"Reason for visit",subjective:"Subjective",objective:"Objective",assessment:"Assessment",plan:"Plan",discharge_instructions:"Discharge instructions",follow_up:"Follow-up",remarks:"Notes"});function sr(e){return Object.prototype.hasOwnProperty.call(or,e)?or[e]:ie(e)}o(sr,"soapSectionLabel");function lr(e){return e===null||!Number.isFinite(e)?"-":`${e.toFixed(3).replace(/\.?0+$/,"")} kg`}o(lr,"formatWeightKg");function dr(e,r,t){if((e===null||!Number.isFinite(e))&&t)return t;if(e===null||!Number.isFinite(e))return "-";let n=e.toFixed(3).replace(/\.?0+$/,"");return r?`${n} ${r}`:n}o(dr,"formatMarkerReading");function ur(e,r,t){let n=Dt(r,t);return e?`${h.measured(w(e))}${n?` \xB7 ${n}`:""}`:n}o(ur,"labDetailLine");var ae=Object.freeze({visit:0,vaccine:1,weight:2,medication:3});function cr(e){if(!e)return null;let r=Date.parse(e);return Number.isNaN(r)?null:r}o(cr,"toMillis");function be(e){let r=[...e.visits.map((t,n)=>({key:`visit-${n}-${t.visitId}`,kind:"visit",kindLabel:h.kind.visit,at:t.visitDate,date:w(t.visitDate),title:t.summary??h.clinicVisit,detail:t.veterinarian?h.doctor(t.veterinarian):null,docId:t.docId})),...e.vaccines.map((t,n)=>{let i=[];return t.lot&&i.push(h.lot(t.lot)),t.expiresOn&&i.push(h.expires(w(t.expiresOn))),{key:`vaccine-${n}-${t.vaccineId}`,kind:"vaccine",kindLabel:h.kind.vaccine,at:t.administeredOn,date:w(t.administeredOn),title:t.product||h.kind.vaccine,detail:i.length?i.join(" \xB7 "):null,docId:t.docId}}),...e.weights.map((t,n)=>({key:`weight-${n}-${t.weightId}`,kind:"weight",kindLabel:h.kind.weight,at:t.observedOn,date:w(t.observedOn),title:lr(t.weightKg),detail:null,docId:t.docId})),...e.medications.map((t,n)=>{let i=[t.dose,t.route,t.frequency].filter(s=>!!s);return {key:`medication-${n}-${t.medicationId}`,kind:"medication",kindLabel:h.kind.medication,at:t.startedOn,date:w(t.startedOn),title:t.drugName||h.kind.medication,detail:i.length?i.join(" \xB7 "):null,docId:t.docId}})];return Object.freeze(r.sort((t,n)=>{let i=cr(t.at),s=cr(n.at);return i===null&&s===null?ae[t.kind]-ae[n.kind]:i===null?1:s===null?-1:s!==i?s-i:ae[t.kind]-ae[n.kind]}))}o(be,"buildTimelineRows");var he=Object.freeze([Object.freeze({wireCode:"AccessDeniedException",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"AuthorizationException",envelope:"http_envelope",httpStatus:401,retryable:false}),Object.freeze({wireCode:"ConflictException",envelope:"http_envelope",httpStatus:409,retryable:true}),Object.freeze({wireCode:"DAILY_QUOTA_EXCEEDED",envelope:"http_envelope",httpStatus:429,retryable:true}),Object.freeze({wireCode:"FILE_TOO_LARGE",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"IDEMPOTENCY_KEY_IN_FLIGHT",envelope:"http_envelope",httpStatus:409,retryable:true}),Object.freeze({wireCode:"IDEMPOTENCY_KEY_REUSED_DIFFERENT_REQUEST",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"INVALID_CONTENT_TYPE",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"InternalFailureException",envelope:"http_envelope",httpStatus:500,retryable:true}),Object.freeze({wireCode:"MethodNotAllowedException",envelope:"http_envelope",httpStatus:405,retryable:false}),Object.freeze({wireCode:"NotImplementedException",envelope:"http_envelope",httpStatus:501,retryable:false}),Object.freeze({wireCode:"PaymentRequiredException",envelope:"http_envelope",httpStatus:402,retryable:false}),Object.freeze({wireCode:"ResourceNotFoundException",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"ServiceUnavailableException",envelope:"http_envelope",httpStatus:503,retryable:true}),Object.freeze({wireCode:"TIER_UPGRADE_REQUIRED",envelope:"http_envelope",httpStatus:402,retryable:false}),Object.freeze({wireCode:"ThrottlingException",envelope:"http_envelope",httpStatus:429,retryable:true}),Object.freeze({wireCode:"ValidationException",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"accessDenied",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"access_denied",envelope:"oauth_error",httpStatus:302,retryable:false}),Object.freeze({wireCode:"attachment_unreadable",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"authExpired",envelope:"http_envelope",httpStatus:401,retryable:true}),Object.freeze({wireCode:"authRejected",envelope:"http_envelope",httpStatus:401,retryable:false}),Object.freeze({wireCode:"consent_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"consent_required",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"consent_scope_wrong_route",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"device_cipher_unavailable",envelope:"http_envelope",httpStatus:503,retryable:true}),Object.freeze({wireCode:"email_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"event_cursor_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"event_filter_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"event_payload_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"event_type_not_available",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"event_type_unknown",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"idempotency_key_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"idempotency_key_required",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"idempotency_key_reused",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"insufficientCapability",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"insufficient_scope",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"internal_error",envelope:"sse_frame",httpStatus:200,retryable:false}),Object.freeze({wireCode:"invalidRequest",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_client",envelope:"oauth_error",httpStatus:401,retryable:false}),Object.freeze({wireCode:"invalid_client_metadata",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_grant",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_redirect_uri",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_request",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_scope",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"invalid_target",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"mcp_connection_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"mcp_request_conflict",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"mcp_request_gone",envelope:"http_envelope",httpStatus:410,retryable:false}),Object.freeze({wireCode:"mcp_request_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"not_found",envelope:"sse_frame",httpStatus:200,retryable:false}),Object.freeze({wireCode:"partner_visit_link_conflict",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"partner_visit_owner_only",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"partner_visit_pet_already_mapped",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"payload_too_large",envelope:"http_envelope",httpStatus:413,retryable:false}),Object.freeze({wireCode:"petRefInUse",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"pet_health_list_removals_unconfirmed",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"pet_health_species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"pet_not_registered",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"provider_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"rateLimited",envelope:"http_envelope",httpStatus:429,retryable:true}),Object.freeze({wireCode:"record_species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"record_subject_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"record_upload_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"records_consent_required",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"sandbox_only",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"session_required",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"share_limit_reached",envelope:"http_envelope",httpStatus:429,retryable:false}),Object.freeze({wireCode:"slow_down",envelope:"oauth_error",httpStatus:429,retryable:true}),Object.freeze({wireCode:"species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"tenant_filter_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"tenant_has_no_capabilities",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"tenant_resource_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),Object.freeze({wireCode:"tenant_surface_not_enabled",envelope:"http_envelope",httpStatus:409,retryable:false}),Object.freeze({wireCode:"timeout",envelope:"sse_frame",httpStatus:200,retryable:true}),Object.freeze({wireCode:"token_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"unavailable",envelope:"sse_frame",httpStatus:200,retryable:true}),Object.freeze({wireCode:"unavailable",envelope:"http_envelope",httpStatus:503,retryable:true}),Object.freeze({wireCode:"unsupported_grant_type",envelope:"oauth_error",httpStatus:400,retryable:false}),Object.freeze({wireCode:"unsupported_response_type",envelope:"oauth_error",httpStatus:302,retryable:false}),Object.freeze({wireCode:"verify_mint_rate_limited",envelope:"http_envelope",httpStatus:429,retryable:true}),Object.freeze({wireCode:"verify_mint_refused",envelope:"http_envelope",httpStatus:403,retryable:false}),Object.freeze({wireCode:"verify_mint_unavailable",envelope:"http_envelope",httpStatus:503,retryable:true}),Object.freeze({wireCode:"verify_user_ref_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),Object.freeze({wireCode:"webhook_endpoint_update_empty",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"webhook_endpoint_update_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),Object.freeze({wireCode:"webhook_url_rejected",envelope:"http_envelope",httpStatus:400,retryable:false})]);Object.freeze(he.map(e=>e.wireCode));var It=Object.freeze({ValidationException:"validationFailed",AuthorizationException:"authRejected",PaymentRequiredException:"paymentRequired",AccessDeniedException:"accessDenied",ResourceNotFoundException:"resourceNotFound",ConflictException:"conflict",ThrottlingException:"rateLimited",InternalFailureException:"internalError",NotImplementedException:"notImplemented",ServiceUnavailableException:"serviceUnavailable",MethodNotAllowedException:"validationFailed",authExpired:"authExpired",unavailable:"serviceUnavailable",session_required:"sessionRequired",accessDenied:"accessDenied",invalidRequest:"sdkUpdateRequired",authRejected:"authRejected",rateLimited:"rateLimited",insufficientCapability:"accessDenied",event_cursor_invalid:"validationFailed",event_filter_invalid:"validationFailed",event_payload_invalid:"validationFailed",event_type_unknown:"validationFailed",idempotency_key_invalid:"validationFailed",idempotency_key_required:"validationFailed",idempotency_key_reused:"idempotencyConflict",payload_too_large:"validationFailed",webhook_url_rejected:"validationFailed",webhook_endpoint_update_empty:"validationFailed",webhook_endpoint_update_invalid:"validationFailed",event_type_not_available:"conflict",record_subject_not_found:"resourceNotFound",records_consent_required:"conflict",record_species_unsupported:"validationFailed",record_upload_invalid:"validationFailed",FILE_TOO_LARGE:"validationFailed",INVALID_CONTENT_TYPE:"validationFailed",attachment_unreadable:"validationFailed",provider_unsupported:"validationFailed",token_invalid:"validationFailed",device_cipher_unavailable:"serviceUnavailable",email_invalid:"validationFailed",consent_required:"validationFailed",consent_invalid:"validationFailed",consent_scope_wrong_route:"validationFailed",IDEMPOTENCY_KEY_IN_FLIGHT:"idempotencyInFlight",IDEMPOTENCY_KEY_REUSED_DIFFERENT_REQUEST:"idempotencyConflict",DAILY_QUOTA_EXCEEDED:"quotaExceeded",TIER_UPGRADE_REQUIRED:"paymentRequired",not_found:"conversationNotFound",timeout:"streamTimeout",internal_error:"internalError",invalid_request:"validationFailed",invalid_client:"authRejected",invalid_grant:"authRejected",unsupported_grant_type:"validationFailed",invalid_scope:"validationFailed",invalid_target:"validationFailed",invalid_redirect_uri:"validationFailed",invalid_client_metadata:"validationFailed",unsupported_response_type:"validationFailed",access_denied:"accessDenied",slow_down:"rateLimited",mcp_request_not_found:"resourceNotFound",mcp_request_gone:"resourceNotFound",mcp_connection_not_found:"resourceNotFound",mcp_request_conflict:"conflict",sandbox_only:"accessDenied",tenant_has_no_capabilities:"conflict",verify_mint_refused:"accessDenied",verify_mint_rate_limited:"rateLimited",verify_mint_unavailable:"serviceUnavailable",verify_user_ref_invalid:"validationFailed",insufficient_scope:"accessDenied",tenant_filter_invalid:"validationFailed",tenant_resource_not_found:"resourceNotFound",tenant_surface_not_enabled:"conflict",pet_health_species_unsupported:"validationFailed",pet_health_list_removals_unconfirmed:"validationFailed",petRefInUse:"conflict",share_limit_reached:"conflict",pet_not_registered:"resourceNotFound",species_unsupported:"validationFailed",partner_visit_owner_only:"accessDenied",partner_visit_link_conflict:"conflict",partner_visit_pet_already_mapped:"conflict"}),fr=Object.freeze(he.map(e=>Object.freeze({wireCode:e.wireCode,envelope:e.envelope,retryable:e.retryable,normalized:It[e.wireCode]}))),zt=new Map(fr.map(e=>[e.envelope+e.wireCode.toUpperCase(),e])),At=Object.freeze(["http_envelope",...[...new Set(fr.map(e=>e.envelope))].filter(e=>e!=="http_envelope").sort()]);function se(e,r){if(typeof e!="string")return;let t=e.trim().toUpperCase();if(t.length!==0)for(let n of [r??"http_envelope",...At]){let i=zt.get(n+t);if(i)return i}}o(se,"contractErrorFor");function jt(e){return e.envelope==="sse_frame"?`/errors#sse-${e.wireCode}`:e.envelope==="oauth_error"?`/errors#oauth-${e.wireCode}`:`/errors#${e.wireCode}`}o(jt,"contractDocUrl");function yr(e){return null}o(yr,"publishedDocUrl");var Nt=Object.freeze({authExpired:"authentication",authRejected:"authentication",sessionRequired:"authentication",accessDenied:"authorization",paymentRequired:"entitlement",quotaExceeded:"rateLimit",rateLimited:"rateLimit",validationFailed:"invalidRequest",sdkUpdateRequired:"invalidRequest",conversationNotFound:"notFound",petNotFound:"notFound",resourceNotFound:"notFound",conflict:"conflict",idempotencyConflict:"conflict",idempotencyInFlight:"conflict",streamTimeout:"connection",streamIncomplete:"connection",upstreamLlmTimeout:"connection",serviceUnavailable:"connection",internalError:"server",notImplemented:"server",mediaUploadFailed:"media",moderationBlocked:"policy",unknown:"unknown"});function mr(e){return Nt[e]}o(mr,"categoryFor");function gr(e){let r=se(e);if(r)return r.normalized;let t=(e??"").trim().toUpperCase(),n=t.replace(/[^A-Z0-9]/g,"");if(n==="AUTHREJECTED")return "authRejected";if(t.startsWith("AUTH"))return "authExpired";switch(n){case "DAILYQUOTAEXCEEDED":case "QUOTAEXCEEDED":return "quotaExceeded";case "RATELIMITED":case "TOOMANYREQUESTS":return "rateLimited";case "IDEMPOTENCYKEYCONFLICT":case "IDEMPOTENCYCONFLICT":return "idempotencyConflict";case "ACCESSDENIED":case "FORBIDDEN":return "accessDenied";case "NOTFOUND":case "CONVERSATIONNOTFOUND":return "conversationNotFound";case "PETNOTFOUND":return "petNotFound";case "TIMEOUT":case "STREAMTIMEOUT":return "streamTimeout";case "MEDIAUPLOADFAILED":case "UNRECOGNIZEDVIDEOFORMAT":case "FILETOOSMALL":return "mediaUploadFailed";case "MODERATIONBLOCKED":return "moderationBlocked";case "UPSTREAMLLMTIMEOUT":return "upstreamLlmTimeout";case "INTERNALERROR":case "INTERNALSERVERERROR":return "internalError";case "STREAMINCOMPLETE":case "CHATSTREAMINCOMPLETE":return "streamIncomplete";case "INVALIDANALYSISTYPE":case "INVALIDUPLOADPURPOSE":return "unknown";default:return "unknown"}}o(gr,"fromWire");var Lt=new Set(["streamTimeout","rateLimited","internalError","upstreamLlmTimeout","streamIncomplete"]);function ve(e){return Lt.has(e)}o(ve,"isAutoRetryable");var Mt=new Set(["serviceUnavailable","conflict","idempotencyInFlight"]);function br(e){return ve(e)||Mt.has(e)}o(br,"isRetryableCode");var Bt=500,Re=8e3,hr=4;function vr(e,r=Math.random){let t=Math.max(0,e),n=Math.min(Bt*2**t,Re);return Math.floor(r()*n)}o(vr,"backoffDelayMs");var qt=Object.freeze({authExpired:"Please sign in again to continue.",authRejected:"Please sign in again to continue.",sessionRequired:"This app needs to be updated to keep using Everfur.",accessDenied:"This feature isn't available on your account right now.",paymentRequired:"This is part of a paid plan.",quotaExceeded:"You have used today's messages. This resets tomorrow.",rateLimited:"You are sending messages quickly. Try again in a few seconds.",validationFailed:"Something in that request was not right. Check the details and try again.",sdkUpdateRequired:"This app needs to be updated to keep using Everfur.",conflict:"That is already running. Wait for it to finish, then try again.",idempotencyConflict:"That message was already delivered.",idempotencyInFlight:"That is still processing. Give it a moment.",conversationNotFound:"This conversation is no longer available.",petNotFound:"We could not find that pet. Please pick a pet and try again.",resourceNotFound:"We could not find that.",streamTimeout:"The response timed out. Tap retry to try again.",mediaUploadFailed:"We could not upload that photo. Please attach it again.",moderationBlocked:"This request cannot be answered here.",upstreamLlmTimeout:"The response timed out. Tap retry to try again.",internalError:"We hit a snag on our end. Please try again.",notImplemented:"That is not available yet.",serviceUnavailable:"That service is briefly unavailable. Try again shortly.",streamIncomplete:"The connection dropped mid-answer. Tap retry to continue.",unknown:"Something went wrong. Please try again."});function _e(e){return qt[e]}o(_e,"userFacingError");function Rr(e,r,t){Object.defineProperty(e,r,{value:t,enumerable:false,writable:false,configurable:false});}o(Rr,"defineHidden");var Ut=/^[a-z][a-z0-9_]{0,63}$/;function z(e,r){let t=se(r?.wireCode,r?.wireEnvelope),n={code:e,category:mr(e),retryable:r?.retryable??br(e),displayMessage:_e(e)};if(r?.httpStatus!==void 0&&(n.httpStatus=r.httpStatus),r?.requestId&&(n.requestId=r.requestId),typeof r?.reasonCode=="string"&&Ut.test(r.reasonCode)&&(n.reasonCode=r.reasonCode),t);return r?.wireMessage&&Rr(n,"wireMessage",r.wireMessage),r?.raw!==void 0&&r.raw!==null&&Rr(n,"raw",r.raw),Object.freeze(n)}o(z,"makeEverfurError");function _r(e){throw new Error(`assertNever: unhandled discriminated-union member ${JSON.stringify(e)}`)}o(_r,"assertNever");function Er(e){return Object.freeze({kind:"error",terminal:true,code:e.code,retryable:e.retryable,wireMessage:e.wireMessage,synthesized:e.synthesized,lastEventId:e.lastEventId,serverRequestId:e.serverRequestId??null})}o(Er,"errorFrame");function Vt(e){let r={};return e.mode==="personalized"?r.authorization=`Bearer ${e.token}`:r["x-everfur-partner-key"]=e.publishableKey,e.userRef&&(r["x-everfur-user-ref"]=e.userRef),e.sessionId&&(r["x-everfur-session-id"]=e.sessionId),r}o(Vt,"authHeaders");function J(e,r){return {...e,headers:{...Wt(e.headers),...Vt(r)}}}o(J,"withAuthHeaders");function Wt(e){if(!e)return {};let r={};for(let[t,n]of Object.entries(e)){let i=t.toLowerCase();i==="authorization"||i==="x-everfur-partner-key"||(r[t]=n);}return r}o(Wt,"stripAuthHeaders");async function xr(e,r){if(r.mode==="anonymous")return r.transport.request(J(e,{mode:"anonymous",publishableKey:r.publishableKey,userRef:r.userRef,...r.sessionId?{sessionId:r.sessionId}:{}}));let t;try{t=await r.identity.currentToken();}catch{return O(Ee())}let n=await r.transport.request(J(e,{mode:"personalized",token:t,userRef:r.userRef,...r.sessionId?{sessionId:r.sessionId}:{}}));if(n.ok||n.error.httpStatus!==401)return n;let i;try{i=await r.identity.currentToken({forceRefresh:!0});}catch{return O(Ee())}let s=await r.transport.request(J(e,{mode:"personalized",token:i,userRef:r.userRef,...r.sessionId?{sessionId:r.sessionId}:{}}));return !s.ok&&s.error.httpStatus===401?O(Ee(s.error.httpStatus)):s}o(xr,"authedSend");function Ee(e){return z("authRejected",{retryable:false,...e!==void 0?{httpStatus:e}:{}})}o(Ee,"authRejectedError");function Cr(e){return z("internalError",{retryable:true,wireMessage:Yt(e)})}o(Cr,"networkError");function Yt(e){return e instanceof Error?e.message:typeof e=="string"?e:"network request failed"}o(Yt,"describeCause");var Kt=3e4,Gt=Re*2,Xt="idempotency-key",Qt=new Set(["POST","PUT","PATCH","DELETE"]),Jt=Object.freeze({onEvent(){}}),Zt=Object.freeze({setTimeout:o((e,r)=>setTimeout(e,r),"setTimeout"),clearTimeout:o(e=>clearTimeout(e),"clearTimeout"),now:o(()=>Date.now(),"now")});function wr(e){let r=e.observer??Jt,t=e.timers??Zt,n=e.rng??Math.random,i=e.sleep??((g,b)=>fn(g,t,b)),s=e.maxAttempts??hr,c=e.unaryTimeoutMs??Kt,d=e.newIdempotencyKey??rn(),a=o(g=>{try{r.onEvent(g);}catch{}},"emit");async function u(g,b,E){let k=E?.maxAttempts,q=Math.max(1,k??s),N=E?.idempotent??Qt.has(b.method)?d():null,Ct=en(b,N),ye=0;for(;;){let K=o(ge=>Object.freeze({call:g,method:b.method,path:b.path,attempt:ye,...N?{idempotencyKey:N}:{},...ge}),"stamp");a(K({phase:"attempt"}));let We=cn(c,t),Ye=pn(We.signal,b.signal),G;try{G=await xr({...Ct,signal:Ye.signal},e.auth);}catch(ge){G=O(Cr(ge));}finally{Ye.dispose(),We.cancel();}if(G.ok)return a(K({phase:"settled",ok:true,reason:"ok"})),G;let D=G.error,ne=nn(D,ye,{maxAttempts:q,rng:n,now:t.now(),aborted:b.signal?.aborted===true,...k!==void 0?{perCallMaxAttempts:k}:{},...e.errorPolicy!==void 0?{policy:e.errorPolicy}:{}}),me={ok:false,code:D.code,reason:ne.reason,...D.httpStatus!==void 0?{httpStatus:D.httpStatus}:{},...D.requestId!==void 0?{requestId:D.requestId}:{}};if(!ne.retry)return a(K({phase:"settled",...me})),O(D);if(a(K({phase:"retry",...me,delayMs:ne.delayMs})),await i(ne.delayMs,b.signal),b.signal?.aborted===true)return a(K({phase:"settled",...me,reason:"aborted"})),O(D);ye+=1;}}o(u,"send");async function f(g){return J(g,await un(e.auth))}o(f,"authorize");async function*v(g,b,E){a(Object.freeze({call:g,phase:"stream.open",method:b.method,path:b.path,attempt:0}));try{yield*e.auth.transport.stream(b,E);}catch{yield Er({code:"internal_error",retryable:true,wireMessage:null,synthesized:true,lastEventId:null,serverRequestId:null});}}return o(v,"stream"),Object.freeze({send:u,authorize:f,stream:v})}o(wr,"createRequestFunnel");function en(e,r){let t={};for(let[n,i]of Object.entries(e.headers??{}))n.toLowerCase()!==Xt&&(t[n]=i);return r!==null&&(t["Idempotency-Key"]=r),{...e,headers:t}}o(en,"assembleHeaders");function rn(){let e=0;return ()=>`efk_${Date.now().toString(36)}_${(e++).toString(36)}_${Math.random().toString(36).slice(2,12)}`}o(rn,"defaultIdempotencyKeyFactory");var tn=10;function nn(e,r,t){if(t.aborted)return {retry:false,reason:"aborted"};let n=on(e);if(n==="quota")return {retry:false,reason:"daily-quota-exhausted"};if(n!=="burst"&&!ve(e.code))return {retry:false,reason:"terminal-code"};let i=n==="burst"?"burst-throttle":"retryable-code";if(o(()=>{if(t.policy===void 0)return false;try{return !t.policy.shouldRetry(e.code,r)}catch{return false}},"policyVetoedRetry")())return {retry:false,reason:"terminal-code"};let c=o(()=>{if(t.policy===void 0)return null;let u;try{u=t.policy.maxAttempts(e.code);}catch{return null}return typeof u!="number"||!Number.isFinite(u)?null:Math.max(1,Math.min(tn,Math.floor(u)))},"policyCeiling"),d=t.perCallMaxAttempts??c()??t.maxAttempts;if(r+1>=d)return {retry:false,reason:"attempts-exhausted"};let a=an(e,t.now);return a!==null?a>Gt?{retry:false,reason:"server-reset-beyond-budget"}:{retry:true,reason:i,delayMs:a}:{retry:true,reason:i,delayMs:vr(r,t.rng)}}o(nn,"decideRetry");function on(e){let r=e.code==="unknown"?gr(dn(e.raw)):e.code;return r==="quotaExceeded"?"quota":r==="rateLimited"||e.httpStatus===429?"burst":null}o(on,"throttleKind");function an(e,r){let t=sn(e.raw);if(t===null)return null;let n=t-r;return n>0?n:0}o(an,"retryOverrideMs");function sn(e){for(let r of kr(e)){let t=r.resets_at,n=ln(t);if(n!==null)return n}return null}o(sn,"findResetsAt");function kr(e){if(!Sr(e))return [];let r=[e];for(let t of ["error","detail"]){let n=e[t];Sr(n)&&r.push(n);}return r}o(kr,"candidateScopes");function ln(e){if(typeof e=="number"&&Number.isFinite(e))return e<1e11?Math.round(e*1e3):Math.round(e);if(typeof e=="string"&&e.trim().length>0){let r=Date.parse(e);return Number.isFinite(r)?r:null}return null}o(ln,"parseInstantMs");function dn(e){for(let r of kr(e)){let t=r.code;if(typeof t=="string"&&t.length>0)return t}return null}o(dn,"rawWireCode");function Sr(e){return typeof e=="object"&&e!==null}o(Sr,"isRecord");async function un(e){return e.mode==="anonymous"?{mode:"anonymous",publishableKey:e.publishableKey,userRef:e.userRef,...e.sessionId?{sessionId:e.sessionId}:{}}:{mode:"personalized",token:await e.identity.currentToken(),userRef:e.userRef,...e.sessionId?{sessionId:e.sessionId}:{}}}o(un,"resolveDeviceAuth");function cn(e,r){let t=new AbortController,n=r.setTimeout(()=>t.abort(),e);return {signal:t.signal,cancel:o(()=>r.clearTimeout(n),"cancel")}}o(cn,"boundedSignal");function pn(e,r){let t=o(()=>{},"noop");if(!r)return {signal:e,dispose:t};let n=new AbortController;if(e.aborted||r.aborted)return n.abort(),{signal:n.signal,dispose:t};let i=o(()=>n.abort(),"onAbort");return e.addEventListener("abort",i,{once:true}),r.addEventListener("abort",i,{once:true}),{signal:n.signal,dispose:o(()=>{e.removeEventListener("abort",i),r.removeEventListener("abort",i);},"dispose")}}o(pn,"mergeSignals");function fn(e,r,t){return e<=0||t?.aborted===true?Promise.resolve():new Promise(n=>{let i=r.setTimeout(()=>{t?.removeEventListener("abort",s),n();},e),s=o(()=>{r.clearTimeout(i),n();},"onAbort");t?.addEventListener("abort",s,{once:true});})}o(fn,"delayAbortable");function Tr(e){for(let r=0;r<e.length;r+=1){let t=e.charCodeAt(r);if(t>=55296&&t<=56319){let n=e.charCodeAt(r+1);if(!(n>=56320&&n<=57343))return true;r+=1;}else if(t>=56320&&t<=57343)return true}return false}o(Tr,"hasLoneSurrogate");var Or=64,Pr=512;function mn(e){return e==="owner_reported"||e==="clinic_document"?e:null}o(mn,"normalizeOrigin");zod.z.object({request_id:zod.z.string().min(1),pet_ref:zod.z.string().min(1),status:zod.z.string(),simple_status:zod.z.string().nullish(),simple_status_detail:zod.z.string().nullish(),status_label:zod.z.string().optional(),dispatch_status:zod.z.string().nullish(),can_retry_send:zod.z.boolean().optional(),can_revoke:zod.z.boolean().optional(),can_convert_to_upload:zod.z.boolean().optional(),can_update_clinic_email:zod.z.boolean().optional(),reminder_count:zod.z.number().int().nonnegative().optional(),last_reminder_at:zod.z.string().nullish(),waiting_expectation:zod.z.string().nullish(),document_count:zod.z.number().optional(),held_item_count:zod.z.number().optional(),received_at:zod.z.string().nullish(),parsing_started_at:zod.z.string().nullish(),review_started_at:zod.z.string().nullish(),created_at:zod.z.string().optional(),updated_at:zod.z.string().optional(),source:zod.z.string().nullish().catch(null),action_needed_label:zod.z.string().nullish().catch(null),failure_reason:zod.z.string().nullish().catch(null),failure_code:zod.z.string().nullish().catch(null),recovery_stage:zod.z.string().nullish().catch(null),show_clinic_phone:zod.z.boolean().optional().catch(void 0),clinic_name:zod.z.string().nullish().catch(null),clinic_email:zod.z.string().nullish().catch(null),clinic_phone:zod.z.string().nullish().catch(null),converted_to_upload_at:zod.z.string().nullish().catch(null),request_group_id:zod.z.string().nullish().catch(null)}).passthrough();zod.z.object({request_group_id:zod.z.string().min(1),pet_ref:zod.z.string().min(1),total:zod.z.number().int().nonnegative(),responded:zod.z.number().int().nonnegative(),pending:zod.z.number().int().nonnegative(),members:zod.z.array(zod.z.unknown())});zod.z.object({source_doc_id:zod.z.string().min(1),request_id:zod.z.string().min(1)});var gn=zod.z.object({label:zod.z.string(),value:zod.z.string()}),xe=zod.z.object({key:zod.z.string(),category:zod.z.string().optional(),label:zod.z.string().optional(),value:zod.z.string().nullish(),unit:zod.z.string().nullish(),observed_at:zod.z.string().nullish(),status:zod.z.string().nullish(),origin:zod.z.string().nullish(),canonical_key:zod.z.string().nullish()}),bn=zod.z.object({at:zod.z.string(),value:zod.z.number().nullish(),display:zod.z.string().nullish(),origin:zod.z.string().nullish()}),hn=zod.z.object({key:zod.z.string(),label:zod.z.string().optional(),points:zod.z.array(bn).optional()}),vn=zod.z.object({title:zod.z.string(),detail:zod.z.string().nullish(),due_at:zod.z.string().nullish()}),Ce=zod.z.object({doc_id:zod.z.string(),title:zod.z.string().nullish(),page_count:zod.z.number().nullish(),received_at:zod.z.string().nullish()});function Fr(e){return Object.freeze({key:e.key,category:e.category??"",label:e.label??e.key,value:e.value??null,unit:e.unit??null,observedAt:e.observed_at??null,status:e.status??null,origin:mn(e.origin),canonicalKey:e.canonical_key??null})}o(Fr,"mapEntityRow");function Dr(e){return Object.freeze({docId:e.doc_id,title:e.title??null,pageCount:e.page_count??null,receivedAt:e.received_at??null})}o(Dr,"mapDocumentRow");zod.z.object({identity:zod.z.array(gn).optional(),entities:zod.z.array(xe).optional(),entity_series:zod.z.array(hn).optional(),forward_looking:zod.z.array(vn).optional(),documents:zod.z.array(Ce).optional()});zod.z.object({pet_ref:zod.z.string().optional(),granted:zod.z.boolean().optional(),version:zod.z.string().nullish(),granted_at:zod.z.string().nullish()});var R=zod.z.string().nullish(),le=zod.z.number().nullish(),Rn=zod.z.object({collected_at:R,at:R,value:le,unit:R,qualitative_result:R,ref_low:le,ref_high:le,status:R,source_clinic:R,source_doc_id:R,doc_id:R,reviewed:zod.z.boolean().nullish()}),_n=zod.z.object({collected_at:R,at:R,value:le,unit:R,qualitative_result:R,status:R}),En=zod.z.object({marker_id:zod.z.string().min(1),canonical_name:R,name:R,loinc_code:R,canonical_unit:R,unit:R,panel_name:R,panel:R,meaning_text:R,meaning:R,latest:_n.nullish(),trajectory:R,points:zod.z.array(Rn).optional()}),xn=zod.z.object({total_markers:zod.z.number().int().nonnegative(),in_range_count:zod.z.number().int().nonnegative(),out_of_range_count:zod.z.number().int().nonnegative(),unknown_count:zod.z.number().int().nonnegative()}),Cn=zod.z.object({markers:zod.z.array(En).optional(),summary:xn.nullish(),disclaimer:zod.z.string().optional(),featured_marker_id:R});function Sn(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}o(Sn,"isObject");function Ir(e){return Object.freeze({petRef:e,withheld:true,markers:Object.freeze([]),summary:null,disclaimer:"",featuredMarkerId:null})}o(Ir,"withheldMarkers");function zr(e,r){let t=Sn(r)?r:{},n=typeof t.pet_ref=="string"&&t.pet_ref.length>0?t.pet_ref:e;if(t.withheld===true)return Ir(n);let i=Cn.safeParse(t);if(!i.success)return Ir(n);let s=i.data,c=o(a=>Object.freeze({at:a.collected_at??a.at??null,value:a.value??null,unit:a.unit??null,qualitativeResult:a.qualitative_result??null,refLow:a.ref_low??null,refHigh:a.ref_high??null,status:a.status??null,sourceClinic:a.source_clinic??null,docId:a.source_doc_id??a.doc_id??null,reviewed:a.reviewed===true}),"point"),d=(s.markers??[]).map(a=>Object.freeze({markerId:a.marker_id,name:a.canonical_name??a.name??a.marker_id,loincCode:a.loinc_code??null,unit:a.canonical_unit??a.unit??null,panel:a.panel_name??a.panel??null,meaning:a.meaning_text??a.meaning??null,latest:a.latest?Object.freeze({at:a.latest.collected_at??a.latest.at??null,value:a.latest.value??null,unit:a.latest.unit??null,qualitativeResult:a.latest.qualitative_result??null,status:a.latest.status??null}):null,trajectory:a.trajectory??null,points:Object.freeze((a.points??[]).map(c))}));return Object.freeze({petRef:n,withheld:false,markers:Object.freeze(d),summary:s.summary?Object.freeze({totalMarkers:s.summary.total_markers,inRangeCount:s.summary.in_range_count,outOfRangeCount:s.summary.out_of_range_count,unknownCount:s.summary.unknown_count}):null,disclaimer:s.disclaimer??"",featuredMarkerId:s.featured_marker_id??null})}o(zr,"mapRecordMarkers");var Ar=128,A=128;var wn=zod.z.string().min(1).refine(e=>e.startsWith("https://")),Z=zod.z.string().nullish(),kn=zod.z.object({share_id:zod.z.string().min(1),share_url:zod.z.string().min(1),expires_at:Z}),Tn=zod.z.object({shares:zod.z.array(zod.z.object({share_id:zod.z.string().min(1),expires_at:Z,created_at:Z,view_count:zod.z.number().int().nonnegative().nullish(),last_viewed_at:Z})).optional()}),On=zod.z.object({download_url:wn,expires_at:Z});function Pn(e,r){let t=e.trim();if(t.length===0)return null;try{let n=/^[a-z][a-z0-9+.-]*:/i.test(t)?new URL(t):r!==void 0?new URL(t,r):null;return n===null||n.protocol!=="https:"?null:n.toString()}catch{return null}}o(Pn,"resolveShareUrl");function jr(e,r){let t=kn.safeParse(e);if(!t.success)return null;let n=Pn(t.data.share_url,r);return n===null?null:Object.freeze({shareId:t.data.share_id,shareUrl:n,expiresAt:t.data.expires_at??null})}o(jr,"mapRecordShareLink");function Nr(e){let r=Tn.safeParse(e);return r.success?Object.freeze((r.data.shares??[]).map(t=>Object.freeze({shareId:t.share_id,expiresAt:t.expires_at??null,createdAt:t.created_at??null,viewCount:t.view_count??0,lastViewedAt:t.last_viewed_at??null}))):null}o(Nr,"mapRecordShareList");function Lr(e){let r=On.safeParse(e);return r.success?Object.freeze({downloadUrl:r.data.download_url,expiresAt:r.data.expires_at??null}):null}o(Lr,"mapRecordPdfLink");var Fn=zod.z.object({signatures:zod.z.array(zod.z.object({signature_id:zod.z.string().min(1),preview_url:zod.z.string().min(1).refine(e=>e.startsWith("https://")),created_at:zod.z.string().nullish()})).optional()});function Mr(e){let r=Fn.safeParse(e);return r.success?Object.freeze((r.data.signatures??[]).map(t=>Object.freeze({signatureId:t.signature_id,previewUrl:t.preview_url,createdAt:t.created_at??null}))):null}o(Mr,"mapSignatureSuggestions");var m=zod.z.string().nullish(),ee=zod.z.number().nullish(),Dn=zod.z.object({at:m,value:ee,unit:m,qualitative_result:m,ref_low:ee,ref_high:ee,status:m,doc_id:m}),In=zod.z.object({marker_id:zod.z.string(),name:zod.z.string(),loinc_code:m,unit:m,panel:m,meaning:m,latest:zod.z.object({at:m,value:ee,unit:m,qualitative_result:m,status:m}).nullish(),trajectory:m,points:zod.z.array(Dn).optional()}),zn=zod.z.object({encounter_id:zod.z.string(),date:m,type:m,clinic_name:m,veterinarian:m,doc_id:m}),An=zod.z.object({note_id:zod.z.string(),encounter_id:m,observed_on:m,sections:zod.z.array(zod.z.object({section:zod.z.string(),text:zod.z.string()})).optional()}),jn=zod.z.object({exam_id:zod.z.string(),encounter_id:m,observed_on:m,doc_id:m,systems:zod.z.record(zod.z.object({finding_status:m,finding:m})).optional()}),Nn=zod.z.object({has_lab_history:zod.z.boolean().optional(),has_vaccination_history:zod.z.boolean().optional(),has_weight_history:zod.z.boolean().optional(),has_vitals_history:zod.z.boolean().optional(),has_physical_exam_history:zod.z.boolean().optional(),has_procedure_history:zod.z.boolean().optional(),has_genetic_history:zod.z.boolean().optional(),has_reproductive_history:zod.z.boolean().optional(),has_parasite_prevention_history:zod.z.boolean().optional(),earliest_record_at:m,latest_record_at:m,documents_ingested:zod.z.number().int().nonnegative().optional(),documents_in_review:zod.z.number().int().nonnegative().optional(),entities_pending_review:zod.z.record(zod.z.number().int().nonnegative()).optional(),held_total:zod.z.number().int().nonnegative().optional()}),Ln=zod.z.object({conflict_id:zod.z.string(),entity_type:zod.z.string(),field:m,severity:m,candidates:zod.z.array(zod.z.object({value:zod.z.string(),source_doc_id:m,doc_id:m,collected_at:m})).optional()}),Mn=zod.z.object({lab_results:zod.z.array(In).optional(),encounters:zod.z.array(zn).optional(),clinician_notes:zod.z.array(An).optional(),physical_exams:zod.z.array(jn).optional(),completeness:Nn.nullish(),conflicts:zod.z.array(Ln).optional()}),Bn=zod.z.object({visits:zod.z.array(zod.z.object({visit_id:zod.z.string(),visit_date:m,veterinarian:m,summary:m,doc_id:m})),vaccines:zod.z.array(zod.z.object({vaccine_id:zod.z.string(),product:m,lot:m,administered_on:m,expires_on:m,doc_id:m})),weights:zod.z.array(zod.z.object({weight_id:zod.z.string(),observed_on:m,weight_kg:ee,doc_id:m})),medications:zod.z.array(zod.z.object({medication_id:zod.z.string(),drug_name:m,dose:m,route:m,frequency:m,sig:m,rx_number:m,started_on:m,stopped_on:m,doc_id:m})),disclaimer:zod.z.string().optional()}),qn=zod.z.object({document:Ce,contributions:zod.z.array(xe),contribution_count:zod.z.number().int().nonnegative().optional()});function we(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}o(we,"isObject");function ke(e,r){return typeof e.pet_ref=="string"&&e.pet_ref.length>0?e.pet_ref:r}o(ke,"petOf");function Se(e,r){return Object.freeze({petRef:e,available:false,withheld:r,labResults:Object.freeze([]),encounters:Object.freeze([]),clinicianNotes:Object.freeze([]),physicalExams:Object.freeze([]),completeness:null,conflicts:Object.freeze([])})}o(Se,"emptyDepth");function qr(e,r){let t=we(r)?r:{},n=ke(t,e);if(t.withheld===true)return Se(n,true);if(!["lab_results","encounters","clinician_notes","physical_exams","completeness","conflicts"].some(a=>a in t))return Se(n,false);let s=Mn.safeParse(t);if(!s.success)return Se(n,true);let c=s.data,d=o(a=>Object.freeze({at:a.at??null,value:a.value??null,unit:a.unit??null,qualitativeResult:a.qualitative_result??null,refLow:a.ref_low??null,refHigh:a.ref_high??null,status:a.status??null,docId:a.doc_id??null}),"point");return Object.freeze({petRef:n,available:true,withheld:false,labResults:Object.freeze((c.lab_results??[]).map(a=>Object.freeze({markerId:a.marker_id,name:a.name,loincCode:a.loinc_code??null,unit:a.unit??null,panel:a.panel??null,meaning:a.meaning??null,latest:Object.freeze({at:a.latest?.at??null,value:a.latest?.value??null,unit:a.latest?.unit??null,qualitativeResult:a.latest?.qualitative_result??null,status:a.latest?.status??null}),trajectory:a.trajectory??null,points:Object.freeze((a.points??[]).map(d))}))),encounters:Object.freeze((c.encounters??[]).map(a=>Object.freeze({encounterId:a.encounter_id,date:a.date??null,type:a.type??null,clinicName:a.clinic_name??null,veterinarian:a.veterinarian??null,docId:a.doc_id??null}))),clinicianNotes:Object.freeze((c.clinician_notes??[]).map(a=>Object.freeze({noteId:a.note_id,encounterId:a.encounter_id??null,observedOn:a.observed_on??null,sections:Object.freeze((a.sections??[]).map(u=>Object.freeze({section:u.section,text:u.text})))}))),physicalExams:Object.freeze((c.physical_exams??[]).map(a=>Object.freeze({examId:a.exam_id,encounterId:a.encounter_id??null,observedOn:a.observed_on??null,docId:a.doc_id??null,systems:Object.freeze(Object.entries(a.systems??{}).map(([u,f])=>Object.freeze({system:u,findingStatus:f.finding_status??null,finding:f.finding??null})))}))),completeness:c.completeness?Object.freeze({hasLabHistory:c.completeness.has_lab_history===true,hasVaccinationHistory:c.completeness.has_vaccination_history===true,hasWeightHistory:c.completeness.has_weight_history===true,hasVitalsHistory:c.completeness.has_vitals_history===true,hasPhysicalExamHistory:c.completeness.has_physical_exam_history===true,hasProcedureHistory:c.completeness.has_procedure_history===true,hasGeneticHistory:c.completeness.has_genetic_history===true,hasReproductiveHistory:c.completeness.has_reproductive_history===true,hasParasitePreventionHistory:c.completeness.has_parasite_prevention_history===true,earliestRecordAt:c.completeness.earliest_record_at??null,latestRecordAt:c.completeness.latest_record_at??null,documentsIngested:c.completeness.documents_ingested??0,documentsInReview:c.completeness.documents_in_review??0,entitiesPendingReview:Object.freeze({...c.completeness.entities_pending_review??{}}),heldTotal:c.completeness.held_total??0}):null,conflicts:Object.freeze((c.conflicts??[]).map(a=>Object.freeze({conflictId:a.conflict_id,entityType:a.entity_type,field:a.field??null,severity:a.severity??"needs_review",candidates:Object.freeze((a.candidates??[]).map(u=>Object.freeze({value:u.value,docId:u.source_doc_id??u.doc_id??null,collectedAt:u.collected_at??null})))})))})}o(qr,"mapRecordDepth");function Br(e){return Object.freeze({petRef:e,withheld:true,isEmpty:false,visits:Object.freeze([]),vaccines:Object.freeze([]),weights:Object.freeze([]),medications:Object.freeze([]),disclaimer:""})}o(Br,"withheldTimeline");function Ur(e,r){let t=we(r)?r:{},n=ke(t,e);if(t.withheld===true)return Br(n);let i=Bn.safeParse(t);if(!i.success)return Br(n);let s=i.data,c=s.visits.map(f=>Object.freeze({visitId:f.visit_id,visitDate:f.visit_date??null,veterinarian:f.veterinarian??null,summary:f.summary??null,docId:f.doc_id??null})),d=s.vaccines.map(f=>Object.freeze({vaccineId:f.vaccine_id,product:f.product??null,lot:f.lot??null,administeredOn:f.administered_on??null,expiresOn:f.expires_on??null,docId:f.doc_id??null})),a=s.weights.map(f=>Object.freeze({weightId:f.weight_id,observedOn:f.observed_on??null,weightKg:f.weight_kg??null,docId:f.doc_id??null})),u=s.medications.map(f=>Object.freeze({medicationId:f.medication_id,drugName:f.drug_name??null,dose:f.dose??null,route:f.route??null,frequency:f.frequency??null,sig:f.sig??null,rxNumber:f.rx_number??null,startedOn:f.started_on??null,stoppedOn:f.stopped_on??null,docId:f.doc_id??null}));return Object.freeze({petRef:n,withheld:false,isEmpty:c.length===0&&d.length===0&&a.length===0&&u.length===0,visits:Object.freeze(c),vaccines:Object.freeze(d),weights:Object.freeze(a),medications:Object.freeze(u),disclaimer:s.disclaimer??""})}o(Ur,"mapRecordsTimeline");function $r(e,r){let t=we(r)?r:{},n=ke(t,e),i=o(()=>Object.freeze({petRef:n,withheld:true,document:null,contributions:Object.freeze([]),contributionCount:0}),"withheld");if(t.withheld===true)return i();let s=qn.safeParse(t);if(!s.success)return i();let c=Object.freeze(s.data.contributions.map(Fr));return Object.freeze({petRef:n,withheld:false,document:Dr(s.data.document),contributions:c,contributionCount:s.data.contribution_count??c.length})}o($r,"mapDocumentContributions");var Un="/widget/v1/records/pets";function Hr(e){let r=e.funnel??wr({auth:e.auth,...e.errorPolicy?{errorPolicy:e.errorPolicy}:{}}),t=o((a,u)=>typeof a=="string"&&a.length>0&&!Tr(a)&&[...a].length<=u,"segment"),n=o(async(a,u,f,v)=>{if(!t(u,A))return j();let g=await r.send(a,{method:"GET",path:f});if(!g.ok)return g;let b=v(g.value);return b.petRef===u?$(b):O(z("internalError",{retryable:false}))},"read"),i=o(a=>`${Un}/${encodeURIComponent(a)}`,"pet"),s=o(a=>`${i(a)}/everfur_record`,"record"),c=o(async(a,u,f)=>{let v=await r.send(a,u,u.method==="POST"?{idempotent:false,maxAttempts:1}:void 0);if(!v.ok)return v;let g=f(v.value);return g===null?O(z("internalError",{retryable:false})):$(g)},"parsed"),d=o((a,u)=>!t(a.entityType,Or)||!t(a.canonicalKey,Pr)||a.idempotencyKey!==void 0&&!t(a.idempotencyKey,Ar)||u!==void 0&&Object.keys(u).length===0?null:{entity_type:a.entityType,canonical_key:a.canonicalKey,...u!==void 0?{corrected_fields:u}:{},...a.idempotencyKey!==void 0?{idempotency_key:a.idempotencyKey}:{}},"factBody");return {getRecordDepth:o(a=>n("records.depth.record",a,`${i(a)}/record`,u=>qr(a,u)),"getRecordDepth"),getTimeline:o(a=>n("records.depth.timeline",a,`${i(a)}/timeline`,u=>Ur(a,u)),"getTimeline"),getDocumentContributions(a,u){return t(u,64)?n("records.depth.contributions",a,`${i(a)}/documents/${encodeURIComponent(u)}/contributions`,f=>$r(a,f)):j()},getMarkers:o(a=>n("records.depth.markers",a,`${i(a)}/markers`,u=>zr(a,u)),"getMarkers"),createShare(a){return t(a,A)?c("records.share.create",{method:"POST",path:`${s(a)}/share`},u=>jr(u,e.apiBaseUrl)):j()},listShares(a){return t(a,A)?c("records.share.list",{method:"GET",path:`${s(a)}/shares`},Nr):j()},async revokeShare(a,u){if(!t(a,A)||!t(u,64))return j();let f=await r.send("records.share.revoke",{method:"DELETE",path:`${s(a)}/shares/${encodeURIComponent(u)}`},{idempotent:false,maxAttempts:1});return f.ok?$(void 0):f},getPdfLink(a){return t(a,A)?c("records.pdf.link",{method:"GET",path:`${s(a)}/pdf-link`},Lr):j()},async editFact(a,u){let f=t(a,A)?d(u,u.correctedFields):null;if(f===null)return j();let v=await r.send("records.fact.edit",{method:"POST",path:`${s(a)}/facts/edit`,body:f},{idempotent:false,maxAttempts:1});return v.ok?$(void 0):v},async removeFact(a,u){let f=t(a,A)?d(u):null;if(f===null)return j();let v=await r.send("records.fact.remove",{method:"POST",path:`${s(a)}/facts/remove`,body:f},{idempotent:false,maxAttempts:1});return v.ok?$(void 0):v},listAuthorizationSignatures:o(()=>c("records.signatures.list",{method:"GET",path:"/widget/v1/records/authorization-signatures"},Mr),"listAuthorizationSignatures")}}o(Hr,"createRecordsDepthClient");function j(){return Promise.resolve(O(z("validationFailed",{retryable:false})))}o(j,"invalid");var Vn=new Map,Vr=new Set;function Wn(e){return Vn.get(e)??0}o(Wn,"recordsConsentEpochOf");function Yn(e){return Vr.add(e),()=>{Vr.delete(e);}}o(Yn,"subscribe");function Wr(e){let r=react.useCallback(()=>Wn(e),[e]);return react.useSyncExternalStore(Yn,r,r)}o(Wr,"useRecordsConsentEpoch");function Kr(){let{runtime:e,userRef:r,scopeEpoch:t}=M();return react.useMemo(()=>{let{services:n}=e.registry;return Hr({auth:n.authFor(r),...n.errorPolicy?{errorPolicy:n.errorPolicy}:{},...typeof n.apiBaseUrl=="string"?{apiBaseUrl:n.apiBaseUrl}:{}})},[e,r,t])}o(Kr,"useEverfurRecordsDepthClient");function re(e,r,t,n=""){let i=Kr(),{userRef:s}=M(),c=Wr(e),d=react.useMemo(()=>({}),[i,e,n,c]),[a,u]=react.useState({scope:d,value:null,error:null,loading:true}),f=react.useRef(0),v=react.useCallback(async()=>{let Ve=f.current+=1;if(u({scope:d,value:null,error:null,loading:true}),s===null){u({scope:d,value:null,error:null,loading:false});return}let N=await r(i,e);Ve===f.current&&(N.ok?u({scope:d,value:N.value,error:null,loading:false}):u({scope:d,value:null,error:N.error,loading:false}));},[i,e,r,d,s]);react.useEffect(()=>(v(),()=>{f.current+=1;}),[v]);let g=a.scope===d?a:{value:null,error:null,loading:true},b=react.useCallback(()=>{v();},[v]),E=g.error===null||g.error.httpStatus!==404,k=E?g.error:null,q=g.loading?"loading":k!==null?"error":g.value===null?"empty":g.value.withheld?"populated":t(g.value)?"empty":"populated";return react.useMemo(()=>({status:q,value:g.value,error:k,available:E,refresh:b}),[q,g.value,k,E,b])}o(re,"useRecordsDepthRead");var Fe=class Fe extends react.Component{constructor(){super(...arguments);this.state={failed:false,key:this.props.resetKey};}static getDerivedStateFromError(){return {failed:true}}static getDerivedStateFromProps(t,n){return Object.is(t.resetKey,n.key)?null:{failed:false,key:t.resetKey}}render(){return this.state.failed?this.props.fallback:this.props.children}};o(Fe,"HostRenderBoundary");var Oe=Fe;function Jn({render:e}){return e()}o(Jn,"RenderHost");function Pe({render:e,fallback:r,resetKey:t}){return react.createElement(Oe,{fallback:r,resetKey:t,children:react.createElement(Jn,{render:e})})}o(Pe,"HostRender");function ze(e){if(e!==null&&typeof e=="object"&&!Object.isFrozen(e)){Object.freeze(e);for(let r of Object.keys(e))ze(e[r]);}return e}o(ze,"deepFreeze");var Zn=Object.freeze({content:0,heading:2,control:1.8,compact:1.5,badge:1.3}),Qr={xs:4,sm:8,md:12,lg:16,xl:24,xxl:32},Jr={tile:5,xs:6,sm:10,md:14,lg:20,xl:28,pill:500},Xr={nano:8,small:9,micro:10,tiny:11,caption:12,bodyTight:13,body:14,subtitle:16,heading:18,verdict:24},eo={tight:1.15,snug:1.3,normal:1.4,relaxed:1.55},ro={regular:"400",medium:"500",bold:"700"},to={eyebrow:1,monoWide:.9,headerBrand:-0.42,tight:-0.35},no=0,de="System",ue="monospace",oo=["content","heading","control","compact","badge"];function io(e){let r={};for(let t of oo)r[t]=e;return r}o(io,"authoredTierSizes");function Zr(){return {family:de,mono:ue,fontUrl:null,families:{regular:de,medium:de,bold:de,mono:ue,monoMedium:ue,monoBold:ue},namedFaces:{regular:false,medium:false,bold:false,mono:false,monoMedium:false,monoBold:false},fontUrls:{},size:Xr,tierSizes:io(Xr),lineHeight:eo,weight:ro,letterSpacing:to,scale:1,maxScale:no,scaleCaps:Zn}}o(Zr,"baseType");var et={},De=Object.freeze({standard:Object.freeze([.2,0,0,1]),emphasized:Object.freeze([.2,.8,.2,1]),exit:Object.freeze([.4,0,1,1])});function Ie(e){return `cubic-bezier(${e.join(", ")})`}o(Ie,"cssCubicBezier");var rt={duration:{instant:80,fast:140,normal:220,slow:320},spring:{gentle:{damping:18,stiffness:200}},easing:{standard:Ie(De.standard),emphasized:Ie(De.emphasized),exit:Ie(De.exit)},reducedMotion:false},ao={brand:"#10462E",brandSoft:"rgba(16,70,46,0.10)",brandSofter:"rgba(16,70,46,0.15)",brandBorder:"rgba(16,70,46,0.18)",borderHairlineGreen:"rgba(16,70,46,0.25)",brandBorderStrong:"rgba(16,70,46,0.55)",brandInk:"#10462E",linkInk:"#10462E",surface:"#FFFFFF",surfaceCream:"#FDFBF8",surfaceSubtle:"#EFE9E3",background:"#FFFFFF",borderRingCream:"#D8D2C8",chatGround:"#FFFFFF",composerFill:"#FDFBF8",composerBorder:"rgba(16,70,46,0.75)",shadow:"#0B3421",text:{primary:"#111111",secondary:"#0E462E",muted:"#6E6660",placeholder:"rgba(61,61,61,0.75)",onBrand:"#FFFFFF",metaCool:"#3D3D3D",timestamp:"rgba(61,61,61,0.75)"},primary:"#10462E",onPrimary:"#FFFFFF",accent:"#10462E",onAccent:"#FFFFFF",accentEdge:"#07C168",success:"#07C168",danger:"#B91C1C",errorRed:"#FF1B00",warningStrong:"#A45610",cautionAccent:"#D9821D",riskConcern:"#EFA700",sentiment:{up:"#07C168",neutral:"#FBC558",down:"#FF1B00"},badgeBgPositive:"rgba(7,193,104,0.12)",badgeBgCaution:"rgba(217,130,29,0.14)",badgeBgCritical:"rgba(185,28,28,0.12)",badgeBgNeutral:"rgba(110,102,96,0.12)",bubbleUser:"#10462E",bubbleAssistant:"#FFFFFF",skeleton:"#EFE9E3",scanButtonPink:"#FFC3BC",checkupCardLowRiskBg:"rgba(7,193,104,0.10)",checkupCardConcernBg:"rgba(239,167,0,0.10)"},tt=ze({brightness:"light",highContrast:false,meta:{displayName:"Everfur",logoUrl:null,placeholder:null,hidePoweredBy:false},color:ao,space:Qr,radius:Jr,type:Zr(),motion:rt,slots:et}),so={brand:"#6BD39A",brandSoft:"rgba(107,211,154,0.12)",brandSofter:"rgba(107,211,154,0.18)",brandBorder:"rgba(107,211,154,0.22)",borderHairlineGreen:"rgba(107,211,154,0.28)",brandBorderStrong:"rgba(107,211,154,0.55)",brandInk:"#6BD39A",linkInk:"#6BD39A",surface:"#1C1F23",surfaceCream:"#23272C",surfaceSubtle:"#23272C",background:"#15171A",borderRingCream:"#3A3F45",chatGround:"#1C1F23",composerFill:"#23272C",composerBorder:"rgba(107,211,154,0.75)",shadow:"#000000",text:{primary:"#F5F3F0",secondary:"#A9E4C4",muted:"#9A938C",placeholder:"rgba(255,255,255,0.55)",onBrand:"#0E1F17",metaCool:"#C9C9C9",timestamp:"rgba(245,243,240,0.7)"},primary:"#6BD39A",onPrimary:"#0E1F17",accent:"#6BD39A",onAccent:"#0E1F17",accentEdge:"#34D888",success:"#07C168",danger:"#F87171",errorRed:"#FF6B5B",warningStrong:"#F0A35E",cautionAccent:"#D9821D",riskConcern:"#EFA700",sentiment:{up:"#07C168",neutral:"#FBC558",down:"#FF1B00"},badgeBgPositive:"rgba(7,193,104,0.18)",badgeBgCaution:"rgba(217,130,29,0.20)",badgeBgCritical:"rgba(185,28,28,0.22)",badgeBgNeutral:"rgba(255,255,255,0.10)",bubbleUser:"#6BD39A",bubbleAssistant:"#1C1F23",skeleton:"#23272C",scanButtonPink:"#FFC3BC",checkupCardLowRiskBg:"rgba(7,193,104,0.16)",checkupCardConcernBg:"rgba(239,167,0,0.16)"};ze({brightness:"dark",highContrast:false,meta:{displayName:"Everfur",logoUrl:null,placeholder:null,hidePoweredBy:false},color:so,space:Qr,radius:Jr,type:Zr(),motion:rt,slots:et});var nt=Symbol.for("@everfur/sdk#EverfurThemeContext@v1"),ot=globalThis,Ae=ot[nt]??(ot[nt]=react.createContext(tt));Ae.displayName??="EverfurThemeContext";function S(){return react.useContext(Ae)}o(S,"useEverfurTheme");var it=Object.freeze({regular:"regular",medium:"medium",bold:"bold",mono:"regular",monoMedium:"medium",monoBold:"bold"});var at='system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif',co="System";function po(e){let r=e.trim();return r.length===0||r===co?at:`${st(r)}, ${at}`}o(po,"cssFontFamily");function fo(e){let r=e.trim();return r.length===0||r==="monospace"?"ui-monospace, Menlo, Consolas, monospace":`${st(r)}, ui-monospace, Menlo, Consolas, monospace`}o(fo,"cssMonoFamily");function st(e){return `"${e.replace(/[\\"]/g,"\\$&")}"`}o(st,"quote");function _(e,r){let t=e.type,n=t.families[r];return {fontFamily:r==="mono"||r==="monoMedium"||r==="monoBold"?fo(n):po(n),fontWeight:t.namedFaces[r]?t.weight.regular:t.weight[it[r]]}}o(_,"faceCss");var yo=Object.freeze({chat:Object.freeze(["chat.message.create"]),records:Object.freeze(["records.upload.create","records.record.read"]),recordsClinic:Object.freeze(["records.clinic.create"]),video:Object.freeze(["video.gait.execute"]),photo:Object.freeze(["photo.checkup.execute"]),animations:Object.freeze(["animations.state.read"]),televet:Object.freeze(["televet.visit.create"])});function mo(e){return yo[e]}o(mo,"requires");function lt(e,r,t){let n=mo(e),i=new Map;for(let d of r)i.set(d.resource,d);if(t?.isPending===true&&n.some(d=>!i.has(d)))return je({name:e,enabled:false,isPending:true,limits:{}});let s=go(n,i);return n.filter(d=>i.get(d)?.granted!==true).length===0?je({name:e,enabled:true,isPending:false,limits:s}):je({name:e,enabled:false,isPending:false,limits:s,disabled:bo(n,i)})}o(lt,"decideCapability");function go(e,r){let t={};for(let n of e){let i=r.get(n)?.limits;if(i)for(let[s,c]of Object.entries(i)){let d=t[s];t[s]=d===void 0?c:Math.min(d,c);}}return t}o(go,"mergeLimits");function bo(e,r){for(let t of e){let n=r.get(t)?.disabled;if(n)return Object.freeze({reason:n.reason,level:n.level,recoverable:n.recoverable})}return Object.freeze({reason:_e("accessDenied"),level:"user_entitlement",recoverable:false})}o(bo,"disabledFor");function je(e){let r={name:e.name,enabled:e.enabled,isPending:e.isPending,limits:Object.freeze({...e.limits})};return e.disabled!==void 0&&(r.disabled=e.disabled),Object.freeze(r)}o(je,"freezeDecision");function Ne(e){let{runtime:r}=M(),t=r.entitlements,n=react.useSyncExternalStore(t.subscribe,t.getSnapshot,t.getSnapshot);return react.useMemo(()=>lt(e,n.decisions,{isPending:n.isPending}),[e,n])}o(Ne,"useCapability");var Ro=48;function _o(e){return e.isPending?"pending":e.enabled?"enabled":"disabled"}o(_o,"selectView");function ct(e){let{capability:r,children:t,renderDisabled:n,renderPending:i,style:s,className:c}=e,d=Ne(r),a=react.useMemo(()=>_o(d),[d]);switch(a){case "enabled":return t;case "pending":return i?jsxRuntime.jsx(Pe,{render:i,fallback:jsxRuntime.jsx(dt,{capability:r,style:s,className:c})}):jsxRuntime.jsx(dt,{capability:r,style:s,className:c});case "disabled":return n?jsxRuntime.jsx(Pe,{render:()=>n(d),fallback:jsxRuntime.jsx(ut,{decision:d,style:s,className:c}),resetKey:d}):jsxRuntime.jsx(ut,{decision:d,style:s,className:c});default:return _r(a)}}o(ct,"CapabilityGate");function dt({capability:e,style:r,className:t}){let n=S(),i=react.useMemo(()=>pt(n),[n]);return jsxRuntime.jsx("div",{role:"status","aria-busy":"true","aria-label":`Loading ${e}`,className:t,style:{...i.offstate,...r},children:jsxRuntime.jsx("div",{style:i.skeletonBar})})}o(dt,"PendingSkeleton");function ut({decision:e,style:r,className:t}){let n=S(),i=react.useMemo(()=>pt(n),[n]),s=e.disabled?.reason??"";return jsxRuntime.jsx("div",{className:t,style:{...i.offstate,...r},children:s.length>0?jsxRuntime.jsx("p",{style:i.offstateText,children:s}):null})}o(ut,"OffState");function pt(e){let{color:r,space:t,radius:n,type:i}=e;return {offstate:{boxSizing:"border-box",minHeight:Ro,display:"flex",flexDirection:"column",justifyContent:"center",padding:`${t.md}px ${t.lg}px`,backgroundColor:r.surfaceCream,borderRadius:n.md,border:`1px solid ${r.brandBorder}`},offstateText:{margin:0,..._(e,"regular"),fontSize:i.size.body,lineHeight:`${Math.round(i.size.body*i.lineHeight.normal)}px`,color:r.text.muted},skeletonBar:{height:t.md,borderRadius:n.xs,backgroundColor:r.brandSofter}}}o(pt,"makeStyles");var Me=Object.freeze({title:"For educational use only",body:"Everfur is for educational purposes only. It helps you track visible changes through AI checkups. It does not diagnose, treat, prescribe, or replace veterinary care. For urgent symptoms or emergencies, contact a veterinarian immediately."});function yt(e){let r=S(),t=react.useMemo(()=>xo(r),[r]);return jsxRuntime.jsxs("div",{role:"note",className:e.className,style:{...t.container,...e.style},children:[jsxRuntime.jsx("p",{style:t.title,children:Me.title}),jsxRuntime.jsx("p",{style:t.body,children:Me.body})]})}o(yt,"ClinicalDisclaimer");function xo(e){let{color:r,space:t,type:n}=e,i=`${Math.round(n.size.caption*n.lineHeight.snug)}px`;return {container:{boxSizing:"border-box",display:"flex",flexDirection:"column",gap:t.xs,padding:`${t.md}px ${t.lg}px`,borderTop:`1px solid ${r.borderHairlineGreen}`,backgroundColor:r.surfaceCream},title:{margin:0,..._(e,"bold"),fontSize:n.size.caption,lineHeight:i,color:r.text.secondary,letterSpacing:n.letterSpacing.eyebrow},body:{margin:0,..._(e,"regular"),fontSize:n.size.caption,lineHeight:i,color:r.text.muted}}}o(xo,"makeStyles");var So=120,wo=44;function ko({reason:e,onExit:r,exitLabel:t,style:n,className:i}){let{color:s,space:c,radius:d,type:a}=S();return jsxRuntime.jsxs("div",{className:i,"data-testid":"records-gate-off",style:{boxSizing:"border-box",minHeight:So,display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"flex-start",gap:c.md,padding:c.lg,borderRadius:d.md,border:`1px solid ${s.brandBorder}`,backgroundColor:s.surfaceCream,color:s.text.primary,...n},children:[e.length>0?jsxRuntime.jsx("p",{style:{margin:0,fontSize:a.size.bodyTight,color:s.text.muted},children:e}):null,jsxRuntime.jsx("button",{type:"button",onClick:r,"data-testid":"records-gate-off-exit",style:{minHeight:wo,padding:`0 ${c.lg}px`,borderRadius:d.pill,border:`1.5px solid ${s.brand}`,backgroundColor:"transparent",color:s.brand,font:"inherit",fontSize:a.size.body,cursor:"pointer"},children:t})]})}o(ko,"RecordsGateOffState");function mt(e,r){return e===void 0?{}:{renderDisabled:o(t=>jsxRuntime.jsx(ko,{reason:t.disabled?.reason??"",onExit:e,exitLabel:r}),"renderDisabled")}}o(mt,"recordsGateExit");var Po=120,te=44,qe="Back";function Fo(){let e=S(),r=react.useMemo(()=>Do(e),[e]);return {theme:e,styles:r}}o(Fo,"useScreenStyles");function ce({title:e,onBack:r,right:t,testID:n,variant:i="brand"}){let{styles:s}=Fo();return jsxRuntime.jsxs("header",{style:s.headerRow,"data-testid":n,children:[r?jsxRuntime.jsx("button",{type:"button",onClick:r,"aria-label":qe,style:s.iconButton,"data-testid":n?`${n}-back`:void 0,children:jsxRuntime.jsx("span",{"aria-hidden":"true",style:s.backChevron})}):jsxRuntime.jsx("span",{style:s.iconButton}),jsxRuntime.jsx("h2",{style:i==="document"?s.documentTitle:s.headerTitle,children:e}),jsxRuntime.jsx("div",{style:s.headerRight,children:t??jsxRuntime.jsx("span",{style:s.iconButton})})]})}o(ce,"ScreenHeader");function Do(e){let{color:r,space:t,radius:n,type:i,slots:s}=e,c=o((b,E)=>`${Math.round(b*E)}px`,"lh"),d=o((b,E,k,q="regular")=>({margin:0,..._(e,q),fontSize:b,lineHeight:c(b,E),color:k}),"text"),a=U(s.recordCard),u=`1px solid ${r.brandBorder}`,f=e.brightness==="dark"?r.errorRed:r.danger,v=o((b,E)=>({backgroundColor:b,color:E}),"tone"),g={boxSizing:"border-box",minHeight:te,minWidth:te,padding:`${t.md}px ${t.lg+t.xs/2}px`,borderRadius:n.pill,..._(e,"bold"),fontSize:i.size.body,cursor:"pointer",display:"inline-flex",alignItems:"center",justifyContent:"center",gap:t.sm,textDecoration:"none"};return {chipTones:{neutral:v(r.badgeBgNeutral,r.text.secondary),info:v(r.brandSoft,r.brand),warning:v(r.badgeBgCaution,r.warningStrong),critical:v(r.badgeBgCritical,r.danger),positive:v(r.badgeBgPositive,r.success)},root:{boxSizing:"border-box",display:"flex",flexDirection:"column",minHeight:Po,height:"100%",backgroundColor:r.background,color:r.text.primary,..._(e,"regular")},body:{flex:"1 1 auto",minHeight:0,display:"flex",flexDirection:"column",overflowY:"auto"},content:{display:"flex",flexDirection:"column",gap:t.lg,padding:`0 ${t.lg}px ${t.xxl}px`},contentTight:{display:"flex",flexDirection:"column",gap:t.lg,padding:`0 ${t.sm}px ${t.xxl}px`},inset:{padding:`0 ${t.sm}px`},headerRow:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:t.sm,padding:`${t.xs}px ${t.lg}px ${t.md}px`},iconButton:{boxSizing:"border-box",width:te,height:te,display:"inline-flex",alignItems:"center",justifyContent:"center",border:0,background:"transparent",cursor:"pointer",padding:0,color:r.brand,flexShrink:0},backChevron:{display:"block",width:t.md,height:t.md,borderLeft:`2px solid ${r.brand}`,borderBottom:`2px solid ${r.brand}`,transform:"rotate(45deg)",marginLeft:t.xs},headerTitle:{...d(i.size.heading,i.lineHeight.tight,r.brand,"bold"),flex:1,overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},documentTitle:{...d(i.size.subtitle,i.lineHeight.snug,r.text.primary,"bold"),flex:1,textAlign:"center"},headerRight:{display:"flex",alignItems:"center",gap:t.sm+t.xs/2},section:{display:"flex",flexDirection:"column",gap:t.sm+t.xs/2},sectionHeader:{display:"flex",alignItems:"center",gap:t.sm,padding:`0 ${t.xs}px`},sectionTitle:{...d(i.size.body+1,i.lineHeight.snug,r.text.primary,"bold")},sectionCount:{...d(i.size.bodyTight,i.lineHeight.snug,r.text.muted,"medium")},card:{boxSizing:"border-box",borderRadius:n.lg-t.xs,border:u,backgroundColor:r.surface,padding:`${t.xs}px ${t.lg}px`,margin:0,listStyle:"none",...L(s.recordCard,1)},creamCard:{boxSizing:"border-box",borderRadius:n.lg-t.xs/2,border:u,backgroundColor:r.surfaceCream,padding:t.lg,display:"flex",flexDirection:"column",gap:t.md,...L(s.recordCard,1)},row:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:t.md,padding:`${t.md}px 0`},rowDivider:{borderTop:`1px solid ${r.borderHairlineGreen}`},rowMain:{flex:1,minWidth:0},rowRight:{display:"flex",flexDirection:"column",alignItems:"flex-end",gap:t.xs+t.xs/2},rowTitle:{...d(i.size.body,i.lineHeight.snug,r.text.primary,"medium"),...a},rowDetail:{...d(i.size.caption,i.lineHeight.normal,r.text.secondary),marginTop:t.xs/2,...a},rowValue:{...d(i.size.body+1,i.lineHeight.snug,r.text.primary,"bold"),marginTop:t.xs/2,...a},rowMuted:{...d(i.size.caption,i.lineHeight.normal,r.text.muted),...a},chip:{display:"inline-block",borderRadius:n.pill,padding:`${t.xs-1}px ${t.sm}px`,..._(e,"medium"),fontSize:i.size.tiny,lineHeight:c(i.size.tiny,i.lineHeight.snug),whiteSpace:"nowrap"},pill:g,pillPrimary:{border:0,backgroundColor:r.brand,color:r.onPrimary,...L(s.primaryButton),...U(s.primaryButton)},pillOutline:{border:`1.5px solid ${r.brand}`,backgroundColor:"transparent",color:r.brand},pillDanger:{border:`1.4px solid ${r.danger}`,backgroundColor:r.surface,color:r.danger,fontSize:i.size.bodyTight},pillAsk:{border:`1px solid ${r.borderRingCream}`,backgroundColor:r.surface,color:r.text.primary},pillLink:{border:0,backgroundColor:"transparent",color:r.brand,padding:`${t.sm}px`},pillDisabled:{opacity:.5,cursor:"default"},infoNote:{display:"flex",gap:t.sm,borderRadius:n.md-t.xs/2,backgroundColor:r.brandSoft,padding:`${t.sm+t.xs/2}px ${t.md}px`,...d(i.size.bodyTight,i.lineHeight.normal,r.text.primary)},cautionNote:{display:"flex",gap:t.sm,borderRadius:n.md-t.xs/2,backgroundColor:r.badgeBgCaution,padding:`${t.sm+t.xs/2}px ${t.md}px`,...d(i.size.bodyTight,i.lineHeight.normal,r.warningStrong)},statusCard:{borderRadius:n.md,backgroundColor:r.brandSoft,padding:t.md+t.xs/2,...d(i.size.bodyTight,i.lineHeight.relaxed,r.text.primary)},errorBanner:{display:"flex",gap:t.sm,borderRadius:n.md-t.xs/2,backgroundColor:r.badgeBgCritical,padding:t.md,...d(i.size.bodyTight,i.lineHeight.normal,f)},errorText:d(i.size.bodyTight,i.lineHeight.normal,f),band:{display:"flex",alignItems:"flex-start",gap:t.sm,borderRadius:n.md-t.xs/2,padding:t.md,backgroundColor:r.brandSoft,margin:0},bandText:{flex:1,...d(i.size.caption,i.lineHeight.normal,r.text.secondary)},infoGlyph:{boxSizing:"border-box",flexShrink:0,width:t.md+t.xs/2,height:t.md+t.xs/2,borderRadius:n.pill,border:`1px solid ${r.text.secondary}`,display:"inline-flex",alignItems:"center",justifyContent:"center",..._(e,"bold"),fontSize:i.size.small,color:r.text.secondary},chevron:{display:"inline-block",width:t.sm,height:t.sm,borderTop:`2px solid ${r.text.muted}`,borderRight:`2px solid ${r.text.muted}`,flexShrink:0},lead:{...d(i.size.body+1,i.lineHeight.snug,r.text.primary,"bold"),padding:`0 ${t.sm}px`},field:{boxSizing:"border-box",display:"block",width:"100%",minHeight:te,padding:`${t.sm}px ${t.md}px`,border:`1px solid ${r.borderHairlineGreen}`,borderRadius:n.sm,color:r.text.primary,backgroundColor:r.surface,..._(e,"regular"),fontSize:i.size.body},fieldLabel:{...d(i.size.bodyTight,i.lineHeight.normal,r.text.secondary,"medium"),display:"block",marginBottom:t.xs},muted:d(i.size.caption,i.lineHeight.normal,r.text.muted),bodyText:d(i.size.body,i.lineHeight.normal,r.text.primary),mono:_(e,"mono"),plainList:{listStyle:"none",margin:0,padding:0,display:"flex",flexDirection:"column"},sheetBackdrop:{position:"fixed",inset:0,backgroundColor:"rgba(0,0,0,0.4)",display:"flex",alignItems:"flex-end",justifyContent:"center",zIndex:10},sheet:{boxSizing:"border-box",width:"100%",maxWidth:560,maxHeight:"88%",overflowY:"auto",backgroundColor:r.surface,borderTopLeftRadius:n.xl-1,borderTopRightRadius:n.xl-1,padding:`${t.md}px ${t.lg+t.xs+t.xs/2}px ${n.xl}px`,display:"flex",flexDirection:"column",gap:t.md,..._(e,"regular"),color:r.text.primary},sheetHandle:{alignSelf:"center",width:t.xxl+t.xs,height:t.xs,borderRadius:n.pill,backgroundColor:r.borderRingCream},sheetHeader:{display:"flex",alignItems:"flex-start",justifyContent:"space-between",gap:t.sm},sheetTitle:{...d(i.size.heading,i.lineHeight.snug,r.text.primary,"bold")},sheetHelper:d(i.size.bodyTight,i.lineHeight.normal,r.text.muted),closeGlyph:{fontSize:i.size.verdict,lineHeight:1,color:r.text.primary}}}o(Do,"makeScreenStyles");var gt=Object.freeze({idle:Object.freeze({title:"Find your pet\u2019s clinic",body:"Search for the clinic that holds your pet\u2019s records. We\u2019ll request them on your behalf once you sign the authorization.",action:null}),no_requests:Object.freeze({title:"No record requests yet",body:"When you request records from a clinic, you\u2019ll be able to track every step here.",action:null}),no_records:Object.freeze({title:"Nothing to show just yet",body:"Once your pet\u2019s records arrive and our team reviews them, lab trends and visits will appear here.",action:null}),rate_limited:Object.freeze({title:"Slow down a moment",body:"You\u2019ve made a lot of requests just now. You can try again shortly.",action:"Try again"}),service_unavailable:Object.freeze({title:"Records search is temporarily down",body:"We\u2019re working on it. Please try again in a few minutes.",action:"Try again"}),error:Object.freeze({title:"Couldn\u2019t reach Everfur",body:"Check your connection and try again.",action:"Try again"})}),Ue=60;function bt(e){return `Try again in ${e}s`}o(bt,"coolingActionLabel");var ht="Try again, available shortly";function W({width:e,height:r,radius:t,style:n}){let{color:i,radius:s}=S();return jsxRuntime.jsx("span",{"aria-hidden":"true",style:{display:"block",width:e,height:r,borderRadius:t??s.xs,backgroundColor:i.skeleton,flexShrink:0,...n}})}o(W,"SkeletonBlock");var jo=44,$e=62;function Rt({testID:e}){let r=_t();return jsxRuntime.jsxs("div",{role:"progressbar","aria-label":h.loadingTimeline,"aria-busy":"true",style:r.timeline,"data-testid":e,children:[jsxRuntime.jsx("div",{style:r.timelineDisclaimer,children:jsxRuntime.jsx(W,{width:"100%",height:jo,radius:12})}),Array.from({length:6},(t,n)=>jsxRuntime.jsxs("div",{children:[n>0?jsxRuntime.jsx("div",{style:r.timelineSeparator}):null,jsxRuntime.jsxs("div",{style:r.timelineRow,children:[jsxRuntime.jsx(W,{width:34,height:34,radius:17}),jsxRuntime.jsxs("div",{style:r.timelineBody,children:[jsxRuntime.jsxs("div",{style:r.timelineTop,children:[jsxRuntime.jsx(W,{width:44,height:10,radius:5}),jsxRuntime.jsx(W,{width:56,height:12,radius:6})]}),jsxRuntime.jsx(W,{width:"70%",height:14,radius:7}),n%2===0?jsxRuntime.jsx(W,{width:"45%",height:12,radius:6}):null]})]})]},n))]})}o(Rt,"TimelineSkeleton");function pe({variant:e,onAction:r,message:t,testID:n}){let i=_t(),s=gt[e],[c,d]=react.useState(e==="rate_limited"?Ue:0);react.useEffect(()=>{e==="rate_limited"&&d(Ue);},[e]),react.useEffect(()=>{if(c<=0)return;let f=setTimeout(()=>d(v=>Math.max(0,v-1)),1e3);return ()=>clearTimeout(f)},[c]);let a=e==="rate_limited"&&c>0,u=a?bt(c):s.action;return jsxRuntime.jsxs("section",{role:"status",style:i.empty,"data-testid":n,children:[jsxRuntime.jsx("span",{"aria-hidden":"true",style:i.emptyGlyph}),jsxRuntime.jsx("h3",{style:i.emptyTitle,children:s.title}),jsxRuntime.jsx("p",{style:i.emptyBody,children:t??s.body}),u!==null&&r?jsxRuntime.jsx("button",{type:"button",onClick:r,disabled:a,"aria-label":a?ht:u,style:{...i.emptyAction,...a?i.emptyActionDisabled:{}},"data-testid":n?`${n}-action`:`records-empty-${e}-action`,children:u}):null]})}o(pe,"RecordsEmptyState");function _t(){let e=S();return react.useMemo(()=>No(e),[e])}o(_t,"useStyles");function No(e){let{color:r,space:t,radius:n,type:i}=e,s=`1px solid ${r.brandBorder}`;return {dashboard:{display:"flex",flexDirection:"column",gap:t.lg,padding:`${t.xs}px ${t.sm}px 0`,backgroundColor:r.background},inset:{padding:`0 ${t.sm}px`},summaryCard:{display:"flex",flexDirection:"column",alignItems:"center",gap:t.md+t.xs/2,borderRadius:n.lg-t.xs,border:s,backgroundColor:r.surface,padding:`${t.lg+t.xs}px ${t.lg}px`},badges:{display:"flex",gap:t.md},carouselCard:{borderRadius:n.lg-t.xs,border:s,backgroundColor:r.surface,padding:t.lg},dots:{display:"flex",alignItems:"center",justifyContent:"center",gap:t.xs+t.xs/2},centered:{display:"flex",justifyContent:"center"},actions:{display:"flex",flexDirection:"column",gap:t.sm+t.xs/2},actionRow:{display:"flex",alignItems:"center",justifyContent:"space-between",borderRadius:n.md,border:s,backgroundColor:r.surface,padding:t.lg},actionLeft:{flex:1,display:"flex",alignItems:"center",gap:t.md},request:{display:"flex",flexDirection:"column",gap:t.lg+t.xs/2,padding:`${t.xs}px ${t.lg}px 0`},railRow:{display:"flex",alignItems:"flex-start",gap:t.md},railColumn:{display:"flex",flexDirection:"column",alignItems:"center",gap:t.xs/2,width:24},railBody:{flex:1,display:"flex",flexDirection:"column",gap:t.xs+t.xs/2,paddingBottom:t.lg+t.xs/2},statusCard:{display:"flex",flexDirection:"column",gap:t.sm,borderRadius:n.md,backgroundColor:r.brandSoft,padding:t.md+t.xs/2},timeline:{backgroundColor:r.background},timelineDisclaimer:{padding:`${t.xs}px ${t.lg}px ${t.md}px`},timelineRow:{display:"flex",gap:t.md,padding:`${t.md+t.xs/2}px ${t.lg}px`},timelineBody:{flex:1,display:"flex",flexDirection:"column",gap:t.xs-1},timelineTop:{display:"flex",alignItems:"center",justifyContent:"space-between",gap:t.sm},timelineSeparator:{height:1,backgroundColor:r.brandBorder,marginLeft:$e},clinics:{display:"flex",flexDirection:"column",gap:t.md},clinicRow:{display:"flex",flexDirection:"column",gap:t.sm,borderRadius:n.lg-t.xs/2,border:s,backgroundColor:r.surface,padding:`${t.md+t.xs/2}px`},shares:{display:"flex",flexDirection:"column",gap:t.md,padding:t.md,borderRadius:n.md,backgroundColor:r.surfaceCream,border:s},shareRow:{display:"flex",flexDirection:"column",gap:t.xs+t.xs/2},empty:{display:"flex",flexDirection:"column",alignItems:"center",gap:t.sm+t.xs/2,padding:`${t.xxl}px ${t.xl}px`,textAlign:"center"},emptyGlyph:{boxSizing:"border-box",width:22,height:22,borderRadius:11,backgroundColor:r.brandSoft,border:s,marginBottom:t.xs},emptyTitle:{margin:0,..._(e,"bold"),fontSize:i.size.subtitle,lineHeight:`${Math.round(i.size.subtitle*i.lineHeight.snug)-1}px`,color:r.brand},emptyBody:{margin:0,..._(e,"regular"),fontSize:i.size.bodyTight,lineHeight:`${Math.round(i.size.bodyTight*i.lineHeight.normal)}px`,color:r.text.muted,maxWidth:320},emptyAction:{boxSizing:"border-box",marginTop:t.sm,minHeight:40,borderRadius:n.pill,padding:`0 ${t.lg+t.xs/2}px`,backgroundColor:r.brand,color:r.onPrimary,border:0,cursor:"pointer",..._(e,"bold"),fontSize:i.size.bodyTight},emptyActionDisabled:{opacity:.5,cursor:"default"}}}o(No,"makeStyles");var Uo=300,Et=120,xt=44,$o=o((e,r)=>e.getTimeline(r),"readTimeline"),Ho=o(e=>e.isEmpty,"timelineEmpty"),Vo=o((e,r)=>e.getRecordDepth(r),"readDepth"),Wo=o(e=>!e.available||e.labResults.length+e.encounters.length+e.clinicianNotes.length+e.physicalExams.length===0,"depthEmpty"),Yo=o(e=>e.contributions.length===0,"contributionsEmpty");function Ko({petRef:e,style:r,className:t,onBack:n}){let i=re(e,$o,Ho);return jsxRuntime.jsx(He,{state:i,style:r,className:t,onBack:n,header:jsxRuntime.jsx(ce,{title:h.timeline,onBack:X(n),testID:"timeline-header"}),loading:jsxRuntime.jsx(Rt,{testID:"timeline-loading"}),empty:jsxRuntime.jsx(pe,{variant:"no_records",testID:"timeline-empty"}),render:s=>jsxRuntime.jsx(Zo,{timeline:s})})}o(Ko,"EverfurRecordsTimeline");function Go({petRef:e,style:r,className:t,onBack:n}){let i=re(e,Vo,Wo);return jsxRuntime.jsx(He,{state:i,style:r,className:t,onBack:n,header:n?jsxRuntime.jsx(ce,{title:B.records,onBack:X(n)}):null,render:s=>jsxRuntime.jsx(ei,{depth:s})})}o(Go,"EverfurRecordDepth");function Xo({petRef:e,docId:r,style:t,className:n,onBack:i}){let s=react.useCallback((a,u)=>a.getDocumentContributions(u,r),[r]),c=re(e,s,Yo,r),d=c.value?.document?.title?.trim()||h.uploadedDocument;return jsxRuntime.jsx(He,{state:c,style:t,className:n,onBack:i,header:jsxRuntime.jsx(ce,{title:d,onBack:X(i),testID:"contributions-header"}),empty:jsxRuntime.jsx(pe,{variant:"no_records",testID:"contributions-empty"}),render:a=>jsxRuntime.jsx(ri,{view:a})})}o(Xo,"EverfurDocumentContributions");function He({state:e,style:r,className:t,header:n,loading:i,empty:s,render:c,onBack:d}){let{styles:a}=fe(),{userRef:u}=M();return jsxRuntime.jsx(ct,{capability:"records",style:r,className:t,...mt(X(d),qe),children:jsxRuntime.jsxs("div",{className:t,style:{...a.container,...r},children:[n??null,jsxRuntime.jsx("div",{style:a.body,children:u===null?jsxRuntime.jsx("p",{role:"alert",style:a.alertText,children:B.sessionRequired}):Qo(e,c,a,i,s)}),jsxRuntime.jsx(yt,{})]})})}o(He,"DepthSurface");function Qo(e,r,t,n,i){switch(e.status){case "loading":return n??jsxRuntime.jsx(Jo,{styles:t});case "empty":return i??jsxRuntime.jsx("div",{style:t.centered,children:jsxRuntime.jsx("div",{role:"img","aria-label":B.empty,style:t.emptyGlyph})});case "error":return e.error?jsxRuntime.jsx(pe,{variant:er(e.error),message:e.error.displayMessage,onAction:e.error.retryable?e.refresh:void 0,testID:"depth-error"}):null;case "populated":return e.value===null||e.value.withheld?null:r(e.value);default:return null}}o(Qo,"renderState");function Jo({styles:e}){let[r,t]=react.useState(false);return react.useEffect(()=>{let n=setTimeout(()=>t(true),Uo);return ()=>clearTimeout(n)},[]),jsxRuntime.jsx("div",{role:"status","aria-busy":"true","aria-label":B.loading,style:e.centered,children:r?jsxRuntime.jsx("div",{"aria-hidden":"true",style:e.spinner}):null})}o(Jo,"LoadingState");function Zo({timeline:e}){let{styles:r}=fe(),t=be(e);return jsxRuntime.jsxs("section",{"aria-label":h.timeline,style:r.timelineList,children:[e.disclaimer.length>0?jsxRuntime.jsx("p",{role:"note","aria-label":Ze.important(e.disclaimer),style:r.timelineBand,children:e.disclaimer}):null,jsxRuntime.jsx("ul",{style:r.plainList,children:t.map((n,i)=>jsxRuntime.jsx("li",{style:i>0?r.timelineSeparated:void 0,"data-testid":`records-timeline-row-${n.kind}`,children:jsxRuntime.jsxs("div",{style:r.timelineRow,"aria-label":[n.kindLabel,n.date,n.title,n.detail].filter(Boolean).join(", "),children:[jsxRuntime.jsx("span",{"aria-hidden":"true",style:r.timelineBubble}),jsxRuntime.jsxs("div",{style:r.timelineBody,children:[jsxRuntime.jsxs("div",{style:r.topLine,children:[jsxRuntime.jsx("span",{style:r.timelineKind,children:n.kindLabel}),jsxRuntime.jsx("span",{style:r.date,children:n.date})]}),jsxRuntime.jsx("span",{style:r.timelineTitle,children:n.title}),n.detail?jsxRuntime.jsx("span",{style:r.rowDetail,children:n.detail}):null]})]})},n.key))})]})}o(Zo,"TimelineBody");function ei({depth:e}){let{styles:r}=fe();return jsxRuntime.jsxs("section",{"aria-label":B.records,style:r.list,children:[e.labResults.length>0?jsxRuntime.jsxs("div",{style:r.section,children:[jsxRuntime.jsx("h3",{style:r.heading,children:`${h.labResults} (${e.labResults.length})`}),jsxRuntime.jsx("ul",{style:r.card,children:e.labResults.map(t=>{let n=ir(t.latest.status),i=ur(t.latest.at,t.trajectory,t.points.length);return jsxRuntime.jsxs("li",{style:r.row,children:[jsxRuntime.jsx("span",{style:r.rowTitle,children:t.name}),jsxRuntime.jsx("span",{style:r.rowValue,children:dr(t.latest.value,t.latest.unit,t.latest.qualitativeResult)}),i?jsxRuntime.jsx("span",{style:r.rowDetail,children:i}):null,jsxRuntime.jsx("span",{style:{...r.chip,...n.outOfRange?r.chipCritical:r.chipNeutral},children:n.label}),t.meaning?jsxRuntime.jsx("span",{style:r.rowDetail,children:t.meaning}):null]},t.markerId)})})]}):null,e.encounters.length>0?jsxRuntime.jsxs("div",{style:r.section,children:[jsxRuntime.jsx("h3",{style:r.heading,children:`${h.visits} (${e.encounters.length})`}),jsxRuntime.jsx("ul",{style:r.card,children:e.encounters.map(t=>{let n=[t.date?w(t.date):null,t.clinicName,t.veterinarian].filter(i=>i&&i!=="-").join(" \xB7 ");return jsxRuntime.jsxs("li",{style:r.row,children:[jsxRuntime.jsx("span",{style:r.rowTitle,children:t.type?ie(t.type):h.visit}),n?jsxRuntime.jsx("span",{style:r.rowDetail,children:n}):null]},t.encounterId)})})]}):null,e.physicalExams.length>0?jsxRuntime.jsxs("div",{style:r.section,children:[jsxRuntime.jsx("h3",{style:r.heading,children:`${h.physicalExams} (${e.physicalExams.length})`}),e.physicalExams.map(t=>jsxRuntime.jsxs("div",{style:r.card,children:[jsxRuntime.jsx("h4",{style:r.rowTitle,children:t.observedOn?w(t.observedOn):h.exam}),jsxRuntime.jsx("ul",{style:r.plainList,children:t.systems.map(n=>{let i=n.findingStatus==="abnormal",s=i?h.abnormal:n.findingStatus==="not_examined"?h.notExamined:h.normal;return jsxRuntime.jsxs("li",{style:r.row,children:[jsxRuntime.jsx("span",{style:r.rowTitle,children:ar(n.system)}),i&&n.finding?jsxRuntime.jsx("span",{style:r.rowDetail,children:n.finding}):null,jsxRuntime.jsx("span",{style:{...r.chip,...i?r.chipCaution:r.chipNeutral},children:s})]},n.system)})})]},t.examId))]}):null,e.clinicianNotes.length>0?jsxRuntime.jsxs("div",{style:r.section,children:[jsxRuntime.jsx("h3",{style:r.heading,children:`${h.visitNotes} (${e.clinicianNotes.length})`}),e.clinicianNotes.map(t=>jsxRuntime.jsxs("div",{style:r.card,children:[jsxRuntime.jsx("h4",{style:r.rowTitle,children:t.observedOn?w(t.observedOn):h.visitNote}),jsxRuntime.jsx("dl",{style:r.plainList,children:t.sections.map((n,i)=>jsxRuntime.jsxs("div",{style:r.row,children:[jsxRuntime.jsx("dt",{style:r.kindLabel,children:sr(n.section)}),jsxRuntime.jsx("dd",{style:n.text?r.rowDetail:r.rowMuted,children:n.text||h.notRecorded})]},`${n.section}:${i}`))})]},t.noteId))]}):null]})}o(ei,"DepthBody");function ri({view:e}){let{styles:r}=fe();return jsxRuntime.jsxs("section",{"aria-label":B.records,style:r.list,children:[e.document?.receivedAt?jsxRuntime.jsx("p",{style:r.rowDetail,children:w(e.document.receivedAt)}):null,jsxRuntime.jsx("dl",{style:r.card,children:e.contributions.map(t=>jsxRuntime.jsxs("div",{style:r.row,children:[jsxRuntime.jsx("dt",{style:r.rowTitle,children:t.label}),jsxRuntime.jsx("dd",{style:r.rowValue,children:tr(t.value,t.unit)}),t.observedAt?jsxRuntime.jsx("dd",{style:r.rowDetail,children:w(t.observedAt)}):null]},t.key))})]})}o(ri,"ContributionsBody");function fe(){let e=S(),r=react.useMemo(()=>ti(e),[e]);return {theme:e,styles:r}}o(fe,"useDepthTheme");function ti(e){let{color:r,space:t,radius:n,type:i,slots:s}=e,c=o((g,b)=>`${Math.round(g*b)}px`,"lh"),d=o((g,b,E,k="regular")=>({margin:0,..._(e,k),fontSize:g,lineHeight:c(g,b),color:E}),"text"),a=U(s.recordCard),u=o((g,b,E,k="regular")=>({...d(g,b,E,k),...a}),"inCard"),f=`1px solid ${r.brandBorder}`,v=e.brightness==="dark"?r.errorRed:r.danger;return {container:{boxSizing:"border-box",display:"flex",flexDirection:"column",minHeight:Et,height:"100%",backgroundColor:r.background,color:r.text.primary,..._(e,"regular")},body:{flex:"1 1 auto",minHeight:0,display:"flex",flexDirection:"column",overflowY:"auto"},centered:{boxSizing:"border-box",flex:"1 1 auto",minHeight:Et,display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",gap:t.lg,padding:t.xl,textAlign:"center"},spinner:{boxSizing:"border-box",width:24,height:24,borderRadius:n.pill,border:`3px solid ${r.brandSofter}`,borderTopColor:r.brand},emptyGlyph:{boxSizing:"border-box",width:40,height:40,borderRadius:n.lg,backgroundColor:r.brandSoft,border:f},alertText:d(i.size.subtitle,i.lineHeight.snug,r.text.secondary),errorText:d(i.size.subtitle,i.lineHeight.snug,v),primaryButton:{boxSizing:"border-box",minHeight:xt,minWidth:xt,padding:`${t.md}px ${t.xl}px`,borderRadius:n.pill,..._(e,"bold"),fontSize:i.size.body,border:0,cursor:"pointer",backgroundColor:r.primary,color:r.onPrimary,...L(s.primaryButton),...U(s.primaryButton)},list:{display:"flex",flexDirection:"column",gap:t.md,padding:t.lg},section:{display:"flex",flexDirection:"column",gap:t.sm},heading:{...d(i.size.heading,i.lineHeight.snug,r.text.primary,"bold")},card:{boxSizing:"border-box",listStyle:"none",display:"flex",flexDirection:"column",gap:t.sm,margin:0,padding:t.md,borderRadius:n.md,backgroundColor:r.surfaceCream,border:f,...L(s.recordCard,1)},plainList:{listStyle:"none",margin:0,padding:0,display:"flex",flexDirection:"column",gap:t.sm},row:{display:"flex",flexDirection:"column",gap:t.xs,padding:`${t.xs}px 0`,borderBottom:`1px solid ${r.borderHairlineGreen}`},topLine:{display:"flex",justifyContent:"space-between",gap:t.md},kindLabel:{...u(i.size.caption,i.lineHeight.normal,r.text.muted,"medium")},date:u(i.size.caption,i.lineHeight.normal,r.text.muted),rowTitle:{...u(i.size.body,i.lineHeight.normal,r.text.primary,"bold")},rowValue:{...u(i.size.body,i.lineHeight.normal,r.text.primary,"medium")},rowDetail:u(i.size.bodyTight,i.lineHeight.normal,r.text.muted),rowMuted:{...u(i.size.bodyTight,i.lineHeight.normal,r.text.muted),opacity:.7},chip:{...d(i.size.caption,i.lineHeight.normal,r.text.primary),alignSelf:"flex-start",padding:`${t.xs}px ${t.sm}px`,borderRadius:n.pill},chipNeutral:{backgroundColor:r.badgeBgNeutral},chipCaution:{backgroundColor:r.badgeBgCaution},chipCritical:{backgroundColor:r.badgeBgCritical},disclaimer:d(i.size.caption,i.lineHeight.normal,r.text.muted),timelineList:{display:"flex",flexDirection:"column",paddingBottom:t.xxl},timelineBand:{...d(i.size.caption,i.lineHeight.normal,r.text.secondary),borderRadius:n.md-t.xs/2,padding:t.md,backgroundColor:r.brandSoft,margin:`${t.xs}px ${t.lg}px ${t.md}px`},timelineSeparated:{borderTop:`1px solid ${r.brandBorder}`,marginLeft:$e,paddingLeft:0},timelineRow:{display:"flex",gap:t.md,padding:`${t.md+t.xs/2}px ${t.lg}px`},timelineBubble:{boxSizing:"border-box",flexShrink:0,width:34,height:34,borderRadius:n.pill,backgroundColor:r.brandSoft,border:f},timelineBody:{flex:1,display:"flex",flexDirection:"column",gap:t.xs-1,minWidth:0},timelineKind:{..._(e,"mono"),fontSize:i.size.micro,lineHeight:`${i.size.bodyTight}px`,letterSpacing:i.letterSpacing.eyebrow/3,textTransform:"uppercase",color:r.text.secondary},timelineTitle:{...d(i.size.body,i.lineHeight.normal,r.text.primary,"medium")}}}o(ti,"makeStyles");
|
|
2
|
+
exports.EverfurDocumentContributions=Xo;exports.EverfurRecordDepth=Go;exports.EverfurRecordsTimeline=Ko;exports.buildTimelineRows=be;exports.mapDocumentContributions=$r;exports.mapRecordDepth=qr;exports.mapRecordsTimeline=Ur;exports.useEverfurRecordsDepthClient=Kr;exports.useRecordsDepthRead=re;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export { E as EverfurDocumentContributions, a as EverfurDocumentContributionsProps, b as EverfurRecordDepth, c as EverfurRecordsDepthProps, d as EverfurRecordsTimeline } from '../../../DepthViews-DbFhR4Du.cjs';
|
|
2
|
+
export { C as ClinicDraft, a as ClinicLocation, R as RecordsAskEntityRef, b as RecordsAskHandler, c as RecordsDepthStatus, d as RecordsHostSeams, e as RecordsScreen, f as RecordsScreenBaseProps, g as RecordsUrlKind, U as UseRecordsDepthState, u as useEverfurRecordsDepthClient, h as useRecordsDepthRead } from '../../../useRecordsDepth-BHBzJ76R.cjs';
|
|
3
|
+
export { T as TimelineRow, a as TimelineRowKind, b as buildTimelineRows } from '../../../timelineRows-CaohZzXS.cjs';
|
|
4
|
+
export { R as RecordClinicianNote, a as RecordClinicianNoteSection, b as RecordCompleteness, c as RecordConflict, d as RecordConflictCandidate, e as RecordDepthView, f as RecordDocumentContributionsView, g as RecordEncounter, h as RecordExamSystem, i as RecordLabMarker, j as RecordLabPoint, k as RecordPhysicalExam, l as RecordsClinic, m as RecordsDepthClient, n as RecordsTimelineMedication, o as RecordsTimelineVaccine, p as RecordsTimelineView, q as RecordsTimelineVisit, r as RecordsTimelineWeight, s as mapDocumentContributions, t as mapRecordDepth, u as mapRecordsTimeline } from '../../../depth-CErXCU8J.cjs';
|
|
5
|
+
export { B as Brand, P as PetRef, R as RecordsRequestId, _ as __brand } from '../../../ids-B2GAAifq.cjs';
|
|
6
|
+
export { E as EverfurError, a as EverfurErrorCategory, b as EverfurErrorCode, c as EverfurResult } from '../../../EverfurResult-DN9pL2Ab.cjs';
|
|
7
|
+
export { R as RecordDocumentMeta, a as RecordEntity, b as RecordOrigin } from '../../../models-D2EUxPZY.cjs';
|
|
8
|
+
import 'react';
|
|
9
|
+
import '../../../requestFunnel-L-BQfi0z.cjs';
|
|
10
|
+
import '../../../ErrorPolicyPort-CNf4uQZP.cjs';
|
|
11
|
+
import '../../../config-CzTZGlfF.cjs';
|
|
12
|
+
import '../../../identity-DI4eVx9S.cjs';
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export { E as EverfurDocumentContributions, a as EverfurDocumentContributionsProps, b as EverfurRecordDepth, c as EverfurRecordsDepthProps, d as EverfurRecordsTimeline } from '../../../DepthViews-DNEM96Se.js';
|
|
2
|
+
export { C as ClinicDraft, a as ClinicLocation, R as RecordsAskEntityRef, b as RecordsAskHandler, c as RecordsDepthStatus, d as RecordsHostSeams, e as RecordsScreen, f as RecordsScreenBaseProps, g as RecordsUrlKind, U as UseRecordsDepthState, u as useEverfurRecordsDepthClient, h as useRecordsDepthRead } from '../../../useRecordsDepth-BU-OhzH6.js';
|
|
3
|
+
export { T as TimelineRow, a as TimelineRowKind, b as buildTimelineRows } from '../../../timelineRows-DZed6dAM.js';
|
|
4
|
+
export { R as RecordClinicianNote, a as RecordClinicianNoteSection, b as RecordCompleteness, c as RecordConflict, d as RecordConflictCandidate, e as RecordDepthView, f as RecordDocumentContributionsView, g as RecordEncounter, h as RecordExamSystem, i as RecordLabMarker, j as RecordLabPoint, k as RecordPhysicalExam, l as RecordsClinic, m as RecordsDepthClient, n as RecordsTimelineMedication, o as RecordsTimelineVaccine, p as RecordsTimelineView, q as RecordsTimelineVisit, r as RecordsTimelineWeight, s as mapDocumentContributions, t as mapRecordDepth, u as mapRecordsTimeline } from '../../../depth-DjDcJ6kH.js';
|
|
5
|
+
export { B as Brand, P as PetRef, R as RecordsRequestId, _ as __brand } from '../../../ids-B2GAAifq.js';
|
|
6
|
+
export { E as EverfurError, a as EverfurErrorCategory, b as EverfurErrorCode, c as EverfurResult } from '../../../EverfurResult-DN9pL2Ab.js';
|
|
7
|
+
export { R as RecordDocumentMeta, a as RecordEntity, b as RecordOrigin } from '../../../models-B-Uh2LTf.js';
|
|
8
|
+
import 'react';
|
|
9
|
+
import '../../../requestFunnel-CjW7uDuA.js';
|
|
10
|
+
import '../../../ErrorPolicyPort-CwbfmxzJ.js';
|
|
11
|
+
import '../../../config-DW60uRb9.js';
|
|
12
|
+
import '../../../identity-BMx2SUOM.js';
|