@everfur/sdk 0.18.2 → 0.19.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 +124 -0
- package/README.md +6 -5
- package/dist/{Chat.d-BkLu9G00.d.ts → Chat.d-BHovj6Ku.d.ts} +1 -1
- package/dist/{Chat.d-B7iUVGmB.d.cts → Chat.d-BO-XtVYe.d.cts} +1 -1
- package/dist/{DepthViews.d-BiS-GTEf.d.cts → DepthViews.d-BwIkdmWZ.d.cts} +1 -1
- package/dist/{DepthViews.d-C-zs_BnZ.d.cts → DepthViews.d-Bx85LeiP.d.cts} +1 -1
- package/dist/{DepthViews.d-hXV6Ef0y.d.ts → DepthViews.d-CBUunxP1.d.ts} +1 -1
- package/dist/{DepthViews.d-C0DVqywN.d.ts → DepthViews.d-DKoZgF8l.d.ts} +1 -1
- package/dist/{IntakeMedia.d-4a89XrP7.d.ts → IntakeMedia.d-B_ZVDxh3.d.ts} +1 -1
- package/dist/{IntakeMedia.d-JJCUvQu7.d.cts → IntakeMedia.d-CnGzpllr.d.cts} +1 -1
- package/dist/{IntakeMedia.d-DGxrhgIW.d.ts → IntakeMedia.d-DNUAks9E.d.ts} +1 -1
- package/dist/{IntakeMedia.d-DUPR4lVM.d.cts → IntakeMedia.d-Dqc5V_YH.d.cts} +1 -1
- package/dist/{RecordsPage.d-BG_RDR1V.d.ts → RecordsPage.d-CsvBhU0f.d.ts} +1 -1
- package/dist/{RecordsPage.d-5rHMTDyY.d.cts → RecordsPage.d-DRFp2LXH.d.cts} +1 -1
- package/dist/animations/index.cjs +1 -94
- package/dist/animations/index.d.cts +3 -3
- package/dist/animations/index.d.ts +3 -3
- package/dist/animations/index.js +1 -94
- package/dist/{attachments.d-_mgNU-ur.d.ts → attachments.d-DOZjCdkb.d.ts} +2 -2
- package/dist/{attachments.d-DFbXLAYK.d.cts → attachments.d-DWUsHPf9.d.cts} +2 -2
- package/dist/{bookingCopy.d-RU8lNYJ4.d.ts → bookingCopy.d-BlMWlvgv.d.ts} +10 -3
- package/dist/{bookingCopy.d-0K1trjxx.d.cts → bookingCopy.d-tvO7y6MK.d.cts} +10 -3
- package/dist/{casesRepository.d-D2SQFL27.d.ts → casesRepository.d-C7qbrOL-.d.ts} +1 -1
- package/dist/{casesRepository.d-D7vIZ9oX.d.cts → casesRepository.d-sSo6oakf.d.cts} +1 -1
- package/dist/chat/index.cjs +29 -119
- package/dist/chat/index.d.cts +11 -10
- package/dist/chat/index.d.ts +11 -10
- package/dist/chat/index.js +30 -120
- package/dist/chat/lite/index.cjs +29 -119
- package/dist/chat/lite/index.d.cts +11 -10
- package/dist/chat/lite/index.d.ts +11 -10
- package/dist/chat/lite/index.js +30 -120
- package/dist/{attachments.d-D7f7OfPE.d.ts → chatHandoffToken.d-C4tEyuCT.d.ts} +33 -9
- package/dist/{attachments.d-HmRqizDG.d.cts → chatHandoffToken.d-D6GUoBvs.d.cts} +33 -9
- package/dist/{ports.d-RKc2C07X.d.ts → chatTypes.d-BI4vidgu.d.ts} +41 -52
- package/dist/{ports.d-CB9YZT2L.d.cts → chatTypes.d-CSyw9em_.d.cts} +41 -52
- package/dist/client/index.cjs +2 -95
- package/dist/client/index.d.cts +7 -7
- package/dist/client/index.d.ts +7 -7
- package/dist/client/index.js +2 -95
- package/dist/{clinicBatch.d-BN1jfVGo.d.cts → clinicBatch.d-BxA_uGBb.d.cts} +2 -2
- package/dist/{clinicBatch.d-BhaCdstU.d.ts → clinicBatch.d-T5oSAhY-.d.ts} +2 -2
- package/dist/{config.d-D_k_rNZZ.d.ts → config.d-N5Xzy53V.d.ts} +1 -1
- package/dist/{config.d-BFTqU7ft.d.cts → config.d-jCmrhM4a.d.cts} +1 -1
- package/dist/consent/index.cjs +1 -94
- package/dist/consent/index.d.cts +5 -5
- package/dist/consent/index.d.ts +5 -5
- package/dist/consent/index.js +1 -94
- package/dist/{context.d-B4LODPF1.d.ts → context.d-BJEpEERH.d.ts} +7 -6
- package/dist/{context.d-D2fhrjAM.d.cts → context.d-l4HkFJI8.d.cts} +7 -6
- package/dist/{copy.d-Bn9eIgkW.d.ts → copy.d-hFRaovog.d.ts} +2 -2
- package/dist/{copy.d-DjYhMxxS.d.cts → copy.d-hS49oJ4w.d.cts} +2 -2
- package/dist/core/index.cjs +6 -99
- package/dist/core/index.d.cts +14 -13
- package/dist/core/index.d.ts +14 -13
- package/dist/core/index.js +6 -99
- package/dist/{depth.d-CsKZkLNi.d.cts → depth.d-BYwddMNU.d.cts} +2 -2
- package/dist/{depth.d-DlaIV8TV.d.ts → depth.d-C99_xup2.d.ts} +2 -2
- package/dist/{entitlementRepository.d-CpIRpfzy.d.cts → entitlementRepository.d-CiU_QIPL.d.cts} +2 -2
- package/dist/{entitlementRepository.d-C5d_6QMi.d.ts → entitlementRepository.d-qZAlET7C.d.ts} +2 -2
- package/dist/{focus.d-DOlAaNIU.d.ts → focus.d-CG6KhDBK.d.ts} +2 -2
- package/dist/{focus.d-DdBbwzjP.d.cts → focus.d-RJMXplJc.d.cts} +2 -2
- package/dist/health-plan/index.cjs +1 -94
- package/dist/health-plan/index.d.cts +9 -9
- package/dist/health-plan/index.d.ts +9 -9
- package/dist/health-plan/index.js +1 -94
- package/dist/{idempotency.d-CmQc1OUv.d.ts → idempotency.d-D-ZWpO9p.d.ts} +1 -1
- package/dist/{idempotency.d-P4O5lNBq.d.cts → idempotency.d-DJyOZDPb.d.cts} +1 -1
- package/dist/{identity.d-BmbAwQYx.d.cts → identity.d-CA7mW59I.d.cts} +1 -1
- package/dist/{identity.d-BZXPu9Hi.d.ts → identity.d-DIOnFzXL.d.ts} +1 -1
- package/dist/index.cjs +30 -120
- package/dist/index.d.cts +14 -13
- package/dist/index.d.ts +14 -13
- package/dist/index.js +31 -121
- package/dist/{introEvents.d-Bqw2Hcpt.d.cts → introEvents.d-7wNDMhEF.d.cts} +1 -1
- package/dist/{introEvents.d-Cy8yxOoe.d.ts → introEvents.d-BjqfFgE1.d.ts} +1 -1
- package/dist/notifications/inbox/index.cjs +44 -0
- package/dist/notifications/inbox/index.d.cts +50 -0
- package/dist/notifications/inbox/index.d.ts +50 -0
- package/dist/notifications/inbox/index.js +44 -0
- package/dist/notifications/index.cjs +18 -98
- package/dist/notifications/index.d.cts +12 -6
- package/dist/notifications/index.d.ts +12 -6
- package/dist/notifications/index.js +18 -98
- package/dist/{optInView.d-wGSNOB86.d.ts → optInView.d-B5v4cDDW.d.ts} +2 -2
- package/dist/{optInView.d-DXj2w4KU.d.cts → optInView.d-BQhHPleh.d.cts} +2 -2
- package/dist/parse.d-DYsx1Q2V.d.cts +168 -0
- package/dist/parse.d-Do0sdAgm.d.ts +168 -0
- package/dist/{pets.d-CP13kAFa.d.cts → pets.d-DRqMaP8A.d.cts} +1 -1
- package/dist/{pets.d-tqGZP3Co.d.ts → pets.d-DVrOb-Bj.d.ts} +1 -1
- package/dist/{petsRepository.d-CLyzuoo4.d.ts → petsRepository.d-CpYWRWFq.d.ts} +1 -1
- package/dist/{petsRepository.d-CyerzD5G.d.cts → petsRepository.d-tZADfKA1.d.cts} +1 -1
- package/dist/photo/index.cjs +1 -94
- package/dist/photo/index.js +1 -94
- package/dist/records/depth/index.cjs +1 -94
- package/dist/records/depth/index.d.cts +9 -9
- package/dist/records/depth/index.d.ts +9 -9
- package/dist/records/depth/index.js +1 -94
- package/dist/records/index.cjs +2 -95
- package/dist/records/index.d.cts +10 -10
- package/dist/records/index.d.ts +10 -10
- package/dist/records/index.js +2 -95
- package/dist/{requestFunnel.d-BPWf5SQf.d.ts → requestFunnel.d-B8OVGh0p.d.ts} +2 -2
- package/dist/{requestFunnel.d-DocT7FXR.d.cts → requestFunnel.d-C4abgvt9.d.cts} +2 -2
- package/dist/{parse.d-MQST1RP3.d.ts → route.d-BAZqGLfl.d.ts} +90 -53
- package/dist/{parse.d-C9_UMXfA.d.cts → route.d-CTf8h9vS.d.cts} +90 -53
- package/dist/{runtimeTypes.d-CkwEMpy8.d.cts → runtimeTypes.d-DbaQKGLv.d.cts} +39 -5
- package/dist/{runtimeTypes.d-D4Cjjf_C.d.ts → runtimeTypes.d-DrIz5e6L.d.ts} +39 -5
- package/dist/{screenProps.d-DNTTp7hU.d.ts → screenProps.d-BP8LAZWn.d.ts} +1 -1
- package/dist/{screenProps.d-Byla6nJL.d.cts → screenProps.d-Di3wYGCn.d.cts} +1 -1
- package/dist/server/events/index.cjs +2 -95
- package/dist/server/events/index.d.cts +122 -4
- package/dist/server/events/index.d.ts +122 -4
- package/dist/server/events/index.js +2 -95
- package/dist/server/index.cjs +2 -95
- package/dist/server/index.d.cts +3 -3
- package/dist/server/index.d.ts +3 -3
- package/dist/server/index.js +2 -95
- package/dist/shop/index.d.cts +3 -3
- package/dist/shop/index.d.ts +3 -3
- package/dist/tabs/index.cjs +3 -96
- package/dist/tabs/index.d.cts +6 -6
- package/dist/tabs/index.d.ts +6 -6
- package/dist/tabs/index.js +3 -96
- package/dist/televet/booking/index.cjs +11 -103
- package/dist/televet/booking/index.d.cts +13 -11
- package/dist/televet/booking/index.d.ts +13 -11
- package/dist/televet/booking/index.js +11 -103
- package/dist/televet/index.cjs +1 -94
- package/dist/televet/index.d.cts +3 -3
- package/dist/televet/index.d.ts +3 -3
- package/dist/televet/index.js +1 -94
- package/dist/{televetGlobal.d-CC-DrqkQ.d.ts → televetGlobal.d-B0_jbCtC.d.ts} +7 -0
- package/dist/{televetGlobal.d-CKwDCbmN.d.cts → televetGlobal.d-BWYJR391.d.cts} +7 -0
- package/dist/testing/index.cjs +1 -94
- package/dist/testing/index.d.cts +1 -1
- package/dist/testing/index.d.ts +1 -1
- package/dist/testing/index.js +1 -94
- package/dist/testing/rn/index.cjs +1 -94
- package/dist/testing/rn/index.d.cts +8 -7
- package/dist/testing/rn/index.d.ts +8 -7
- package/dist/testing/rn/index.js +1 -94
- package/dist/testing/web/index.cjs +1 -94
- package/dist/testing/web/index.d.cts +8 -7
- package/dist/testing/web/index.d.ts +8 -7
- package/dist/testing/web/index.js +1 -94
- package/dist/texting/index.cjs +1 -94
- package/dist/texting/index.d.cts +5 -5
- package/dist/texting/index.d.ts +5 -5
- package/dist/texting/index.js +1 -94
- package/dist/{threadOptions.d-jgk_sHrj.d.ts → threadOptions.d-Cwmyu8pc.d.ts} +2 -2
- package/dist/{threadOptions.d-CIrevUL8.d.cts → threadOptions.d-REwBuXAY.d.cts} +2 -2
- package/dist/{timelineRows.d-BST14weg.d.ts → timelineRows.d-CTlGQTB0.d.ts} +1 -1
- package/dist/{timelineRows.d-BEjiHpkP.d.cts → timelineRows.d-CongJG58.d.cts} +1 -1
- package/dist/unreadStore.d-gCsleb6l.d.ts +74 -0
- package/dist/unreadStore.d-w5x6lEpR.d.cts +74 -0
- package/dist/{useHealthPlanSubscription.d-C9kh4mvk.d.ts → useHealthPlanSubscription.d-BSo5kFT9.d.ts} +2 -2
- package/dist/{useHealthPlanSubscription.d-CYJi9ZNE.d.cts → useHealthPlanSubscription.d-Br7GKHTt.d.cts} +2 -2
- package/dist/useInboxUnread.d-Blxu00eY.d.ts +206 -0
- package/dist/useInboxUnread.d-pi6FNnK-.d.cts +206 -0
- package/dist/{usePresentation.d-COEh8Xa1.d.cts → usePresentation.d-C6ci1s3j.d.cts} +1 -1
- package/dist/{usePresentation.d-WA3sfMpz.d.ts → usePresentation.d-yd9Gh4GB.d.ts} +1 -1
- package/dist/{useRecordsDepth.d-DZfdRdIU.d.cts → useRecordsDepth.d-BIDVPfx7.d.cts} +1 -1
- package/dist/{useRecordsDepth.d-CAYnVYl1.d.ts → useRecordsDepth.d-C5snbNxR.d.ts} +1 -1
- package/dist/{appStateLifecycle.d-_TM06yEk.d.cts → useUnread.d-CORommFJ.d.cts} +49 -14
- package/dist/{appStateLifecycle.d-7H_2a9it.d.ts → useUnread.d-w0dKMnx7.d.ts} +49 -14
- package/dist/video/index.cjs +1 -94
- package/dist/video/index.js +1 -94
- package/dist/{view.d-D8soknYh.d.ts → view.d-CK2UN4qn.d.ts} +3 -3
- package/dist/{view.d-eM315KIZ.d.cts → view.d-DUhKppyl.d.cts} +3 -3
- package/dist/web/consent/index.cjs +1 -94
- package/dist/web/consent/index.d.cts +5 -5
- package/dist/web/consent/index.d.ts +5 -5
- package/dist/web/consent/index.js +1 -94
- package/dist/web/health-plan/index.cjs +1 -94
- package/dist/web/health-plan/index.d.cts +11 -11
- package/dist/web/health-plan/index.d.ts +11 -11
- package/dist/web/health-plan/index.js +1 -94
- package/dist/web/inbox/index.cjs +49 -0
- package/dist/web/inbox/index.d.cts +191 -0
- package/dist/web/inbox/index.d.ts +191 -0
- package/dist/web/inbox/index.js +49 -0
- package/dist/web/index.cjs +28 -118
- package/dist/web/index.d.cts +76 -36
- package/dist/web/index.d.ts +76 -36
- package/dist/web/index.js +28 -118
- package/dist/web/intro/index.cjs +3 -96
- package/dist/web/intro/index.d.cts +6 -6
- package/dist/web/intro/index.d.ts +6 -6
- package/dist/web/intro/index.js +3 -96
- package/dist/web/notifications/index.cjs +16 -96
- package/dist/web/notifications/index.d.cts +8 -3
- package/dist/web/notifications/index.d.ts +8 -3
- package/dist/web/notifications/index.js +16 -96
- package/dist/web/records/depth/index.cjs +1 -94
- package/dist/web/records/depth/index.d.cts +9 -9
- package/dist/web/records/depth/index.d.ts +9 -9
- package/dist/web/records/depth/index.js +1 -94
- package/dist/web/records/index.cjs +1 -94
- package/dist/web/records/index.d.cts +11 -11
- package/dist/web/records/index.d.ts +11 -11
- package/dist/web/records/index.js +1 -94
- package/dist/web/records-sheet/index.cjs +2 -95
- package/dist/web/records-sheet/index.js +2 -95
- package/dist/web/shop/index.d.cts +3 -3
- package/dist/web/shop/index.d.ts +3 -3
- package/dist/web/televet/booking/index.cjs +9 -102
- package/dist/web/televet/booking/index.d.cts +18 -11
- package/dist/web/televet/booking/index.d.ts +18 -11
- package/dist/web/televet/booking/index.js +9 -102
- package/dist/web/televet/index.cjs +1 -94
- package/dist/web/televet/index.d.cts +3 -3
- package/dist/web/televet/index.d.ts +3 -3
- package/dist/web/televet/index.js +1 -94
- package/dist/web/texting/index.cjs +1 -94
- package/dist/web/texting/index.d.cts +5 -5
- package/dist/web/texting/index.d.ts +5 -5
- package/dist/web/texting/index.js +1 -94
- package/notifications/inbox/package.json +8 -0
- package/package.json +29 -1
- package/web/inbox/native-blocked.cjs +12 -0
- package/web/inbox/package.json +8 -0
|
@@ -1,101 +1,8 @@
|
|
|
1
1
|
/*! @everfur/sdk. Copyright (c) 2026 Strand Health Inc. dba Everfur. All rights reserved. Use is subject to the Everfur SDK License: https://docs.everfur.com/license */
|
|
2
2
|
"use strict";var react=require("react"),reactNative=require("react-native"),zod=require("zod"),jsxRuntime=require("react/jsx-runtime"),callModule=require("@everfur/sdk/televet/call"),reactNativeSafeAreaContext=require("react-native-safe-area-context");function _interopNamespace(e){if(e&&e.__esModule)return e;var n=Object.create(null);if(e){Object.keys(e).forEach(function(k){if(k!=="default"){var d=Object.getOwnPropertyDescriptor(e,k);Object.defineProperty(n,k,d.get?d:{enumerable:true,get:function(){return e[k]}})}})}n.default=e;return Object.freeze(n)}var callModule__namespace=/*#__PURE__*/_interopNamespace(callModule);function assertNever(x){throw new Error(`assertNever: unhandled discriminated-union member ${JSON.stringify(x)}`)}function errorFrame(fields){/* @__PURE__ */
|
|
3
3
|
return Object.freeze({kind:"error",terminal:true,code:fields.code,retryable:fields.retryable,wireMessage:fields.wireMessage,synthesized:fields.synthesized,lastEventId:fields.lastEventId,serverRequestId:null})}var CONSULT_STATUSES=["scheduled","in_progress","awaiting_summary","completed","cancelled_owner","cancelled_ops","no_show_owner","no_show_vet"],TERMINAL_CONSULT_STATUSES=/* @__PURE__ */new Set(["completed","cancelled_owner","cancelled_ops","no_show_owner","no_show_vet"]),LIVE_CONSULT_STATUSES=/* @__PURE__ */new Set(["scheduled","in_progress","awaiting_summary"]);function isLiveConsult(consult){return LIVE_CONSULT_STATUSES.has(consult.status)}var CONSULT_KINDS=["wellness","prescription"],SLOT_MINUTES_MAX=60;function televetSlotMinutes(slot){let starts=Date.parse(slot.startsAt),ends=Date.parse(slot.endsAt);if(Number.isNaN(starts)||Number.isNaN(ends))return null;let minutes=Math.round((ends-starts)/6e4);return minutes>0?Math.min(minutes,SLOT_MINUTES_MAX):null}var CANCELLATION_POLICY_VERSION_MAX=64,REASON_TEXT_MAX=2e3,MEDIA_REFS_MAX=10;function isWellFormedStateCode(state){return typeof state=="string"&&/^[A-Za-z]{2}$/.test(state.trim())}function row(value){return typeof value=="object"&&value!==null?value:null}function str(value){return typeof value=="string"&&value.length>0?value:null}function trimmedOrNull(value){return typeof value=="string"&&value.trim().length>0?value.trim():null}function bool(value,fallback){return typeof value=="boolean"?value:fallback}function num(value){return typeof value=="number"&&Number.isFinite(value)?value:null}function closed(set,value){return typeof value=="string"&&set.includes(value)?value:"unknown"}function parseList(wire,parseRow){if(!Array.isArray(wire))/* @__PURE__ */return Object.freeze([]);let out=[];for(let item of wire){let parsed=parseRow(item);parsed!==null&&out.push(parsed)}/* @__PURE__ */
|
|
4
|
-
return Object.freeze(out)}function parseStatePolicy(wire,askedFor){let r=row(wire);return r===null?null:/* @__PURE__ */Object.freeze({state:str(r.state)??askedFor,wellnessAvailable:bool(r.wellness_available,false),prescriptionsAvailable:bool(r.prescriptions_available,false),cancellationPolicyText:trimmedOrNull(r.cancellation_policy_text)})}function parseCancellationPolicy(wire){let r=row(wire);if(r===null)return null;let summary=trimmedOrNull(r.summary),version=trimmedOrNull(r.version);return summary===null||version===null?null:/* @__PURE__ */Object.freeze({summary:summary,version:version})}function parseClinician(wire){let r=row(wire);if(r===null)return null;let clinicianId=str(r.clinician_id),displayName=str(r.display_name);return clinicianId===null||displayName===null?null:/* @__PURE__ */Object.freeze({clinicianId:clinicianId,displayName:displayName,credentials:trimmedOrNull(r.credentials_text),rating:num(r.rating),ratingCount:num(r.rating_count),bio:trimmedOrNull(r.bio),photoRef:str(r.photo_ref),licensedStates:parseList(r.licensed_states,item=>{let l=row(item),state=l===null?null:str(l.state);return state===null?null:/* @__PURE__ */Object.freeze({state:state,canPrescribe:bool(l?.can_prescribe,false)})})})}function parseSlot(wire){let r=row(wire);if(r===null)return null;let slotId=str(r.slot_id),startsAt=str(r.starts_at);return slotId===null||startsAt===null?null:/* @__PURE__ */Object.freeze({slotId:slotId,startsAt:startsAt,endsAt:str(r.ends_at)??startsAt})}function parseTriageVerdict(wire){let r=row(wire);if(r===null)return null;let isEmergency=r.is_emergency===true,fallback=r.fallback===true;return isEmergency||fallback?/* @__PURE__ */Object.freeze({isEmergency:isEmergency,fallback:fallback}):r.is_emergency===false&&r.fallback===false?/* @__PURE__ */Object.freeze({isEmergency:false,fallback:false}):null}function parseSlotHold(wire){let r=row(wire);if(r===null)return null;let slotId=str(r.slot_id),expiresAt=str(r.hold_expires_at);return slotId===null||expiresAt===null?null:/* @__PURE__ */Object.freeze({slotId:slotId,expiresAt:expiresAt})}function parseConsult(wire){let r=row(wire);if(r===null)return null;let consultId=str(r.consult_id),scheduledAt=str(r.scheduled_at);return consultId===null||scheduledAt===null?null:/* @__PURE__ */Object.freeze({consultId:consultId,petId:str(r.pet_id)??"",clinicianId:str(r.clinician_id)??"",clinicianName:trimmedOrNull(r.display_name),reasonText:trimmedOrNull(r.reason_text),mediaRefs:parseList(r.media_refs,item=>str(item)),status:closed(CONSULT_STATUSES,r.status),kind:closed(CONSULT_KINDS,r.kind),scheduledAt:scheduledAt,emergencyFlagged:bool(r.emergency_flagged,false),hasRoom:str(r.meeting_url)!==null})}function parseBookingEntitlement(wire){let r=row(wire);/* @__PURE__ */
|
|
5
|
-
return Object.freeze({active:bool(r?.active,false)})}var CANCEL_REASON_MAX=240;function parseCancelReceipt(wire){let r=row(wire);if(r===null)return null;let feeCents=num(r.fee_cents);return feeCents===null||feeCents<0?null:/* @__PURE__ */Object.freeze({feeCents:feeCents,currency:str(r.currency)??"usd",feeRecorded:bool(r.fee_recorded,feeCents>0),summary:trimmedOrNull(r.summary)})}var TELEVET_JOIN_OPENS_MINUTES_BEFORE=15,TELEVET_JOIN_CLOSES_MINUTES_AFTER=250,JOINABLE=/* @__PURE__ */new Set(["scheduled","in_progress"]);function startsAtMs(consult){let parsed=Date.parse(consult.scheduledAt);return Number.isNaN(parsed)?null:parsed}function televetJoinOpensAtMs(consult){let start=startsAtMs(consult);return start===null?null:start-TELEVET_JOIN_OPENS_MINUTES_BEFORE*6e4}function televetJoinReadiness(consult,nowMs){if(consult===null)return{ready:false,reason:"not_open_yet"};if(TERMINAL_CONSULT_STATUSES.has(consult.status))return{ready:false,reason:"consult_over"};if(consult.status==="in_progress")return{ready:true};let start=startsAtMs(consult);return start===null?{ready:false,reason:"not_open_yet"}:nowMs<start-TELEVET_JOIN_OPENS_MINUTES_BEFORE*6e4?{ready:false,reason:"not_open_yet"}:nowMs>start+TELEVET_JOIN_CLOSES_MINUTES_AFTER*6e4?{ready:false,reason:"consult_over"}:{ready:true}}function televetJoinDecision(consult,nowMs){if(!JOINABLE.has(consult.status))return{joinable:false,reason:`status_${consult.status}`};if(!consult.hasRoom)return{joinable:false,reason:"room_not_ready"};let start=startsAtMs(consult);return start===null||nowMs<start-TELEVET_JOIN_OPENS_MINUTES_BEFORE*6e4?{joinable:false,reason:"too_early"}:nowMs>start+TELEVET_JOIN_CLOSES_MINUTES_AFTER*6e4?{joinable:false,reason:"too_late"}:{joinable:true}}function splitTelevetVisits(consults,nowMs){let upcoming=[],past=[];for(let consult of consults){let start=startsAtMs(consult);(JOINABLE.has(consult.status)&&start!==null&&start+TELEVET_JOIN_CLOSES_MINUTES_AFTER*6e4>nowMs?upcoming:past).push(consult)}return upcoming.sort((a,b)=>(startsAtMs(a)??0)-(startsAtMs(b)??0)),past.sort((a,b)=>(startsAtMs(b)??0)-(startsAtMs(a)??0)),/* @__PURE__ */Object.freeze({upcoming:/* @__PURE__ */Object.freeze(upcoming),past:/* @__PURE__ */Object.freeze(past)})}function canManageTelevetVisit(status){return status==="scheduled"}function reportHostFailure(error){let globalConsole=globalThis.console;try{globalConsole?.error?.("[everfur] A host callback threw; the SDK ignored it.",error)}catch{}}function isThenable(value){return(typeof value=="object"||typeof value=="function")&&value!==null&&typeof value.then=="function"}function callHost(fn,...args){if(typeof fn=="function")try{let result=fn(...args);return isThenable(result)&&Promise.resolve(result).then(void 0,reportHostFailure),result}catch(error){reportHostFailure(error);return}}var GUARDED=/* @__PURE__ */new WeakMap;function guardHost(fn){if(typeof fn!="function")return;let cached=GUARDED.get(fn);if(cached!==void 0)return cached;let guarded=(...args)=>{callHost(fn,...args)};return GUARDED.set(fn,guarded),guarded}function guardHostProps(props,names){let guarded=null;for(let name of names){let fn=props[name];typeof fn=="function"&&(guarded??={...props},guarded[name]=guardHost(fn))}return guarded??props}function callHostAsync(fn,...args){let started;try{started=fn(...args)}catch(error){return reportHostFailure(error),Promise.resolve({ok:false,error:error})}return Promise.resolve(started).then(value=>({ok:true,value:value}),error=>({ok:false,error:error}))}function createTelevetBackChannel(){let handlers=[];return{register(handler){return handlers=[...handlers,handler],()=>{handlers=handlers.filter(h=>h!==handler)}},dispatch(){for(let handler of[...handlers].reverse())try{if(handler())return!0}catch{}return false}}}var TelevetBackChannelContext=react.createContext(null);function useTelevetBackChannel(handler,enabled=true){let channel=react.useContext(TelevetBackChannelContext),current=react.useRef(handler);current.current=handler,react.useEffect(()=>{if(!(channel===null||!enabled))return channel.register(()=>current.current())},[channel,enabled])}var EMERGENCY_ER_LINE="Go to the nearest emergency vet now.";var DRAFT=s=>s,PLACEHOLDER_MARKERS=["[PLACEHOLDER","[PLAN NAME]","[LINK]","[Last]","TODO","TBD"];function isPlaceholderCopy(value){return PLACEHOLDER_MARKERS.some(m=>value.toUpperCase().includes(m.toUpperCase()))}function fill(template,slots){let out=template;for(let[key,value]of Object.entries(slots))out=out.split(`{${key}}`).join(value);return out}var TELEVET_BOOKING_COPY=/* @__PURE__ */Object.freeze({stateBlockedTitle:DRAFT("Not available in this state yet"),noCliniciansTitle:DRAFT("No vets available right now"),noCliniciansBody:DRAFT("Nobody is free in your area at the moment. This changes through the day."),noCliniciansRetryCta:DRAFT("Check again"),noCliniciansRegionBody:DRAFT("Video visits have to be with a vet licensed in your state, and we don’t have one there yet."),yourVetTitle:DRAFT("Your vet"),licensedPillTemplate:DRAFT("Licensed in {state}"),reviewsLabel:DRAFT("reviews"),rescheduleFromTemplate:DRAFT("Moving your visit on {when}"),rescheduleFailed:DRAFT("That did not move. Your original time is unchanged."),rescheduleStepLabel:DRAFT("Reschedule"),rescheduleTitleTemplate:DRAFT("Pick a new time for {pet}"),rescheduleNowLabel:DRAFT("Now"),rescheduleMoveTemplate:DRAFT("Move to {when}"),rescheduleMoving:DRAFT("Moving…"),rescheduleKeepLabel:DRAFT("Keep the visit as it is"),keepExistingCta:DRAFT("Keep my current time"),bookingPausedTitle:DRAFT("Booking is not available right now."),slotsErrorTitle:DRAFT("Could not load times"),noSlotsTitle:DRAFT("No times available"),nextOpeningTemplate:DRAFT("Next opening across our vets: {when}"),seeOtherVetsCta:DRAFT("See other vets"),retryCta:DRAFT("Try again"),holdExpired:DRAFT("That time is no longer held. Pick another."),slotTaken:DRAFT("That time was just taken. Pick another."),reasonPlaceholder:DRAFT("What is going on with your pet?"),reasonTooLong:DRAFT("That is too long. Please shorten it."),shareRecordsOff:DRAFT("Share health records with this vet"),confirmNotEntitled:DRAFT("A Pro membership is needed to book a video visit."),confirmFailed:DRAFT("That did not book. Try again."),checkAvailabilityCta:DRAFT("Check availability"),stateInterest:/* @__PURE__ */Object.freeze({cta:DRAFT("Add me to the list"),submitting:DRAFT("Adding you to the list…"),joinedTitle:DRAFT("You are on the list"),joinedBody:DRAFT("We will let you know when this changes."),failed:DRAFT("That did not save. Try again.")}),media:/* @__PURE__ */Object.freeze({droppedTemplate:DRAFT("{n} attachment did not upload."),droppedPluralTemplate:DRAFT("{n} attachments did not upload."),refusedSizeTemplate:DRAFT("{n} attachment was too large to send."),refusedSizePluralTemplate:DRAFT("{n} attachments were too large to send."),refusedTypeTemplate:DRAFT("{n} attachment is a file type that cannot be sent."),refusedTypePluralTemplate:DRAFT("{n} attachments are file types that cannot be sent."),refusedUnreadableTemplate:DRAFT("{n} attachment could not be read."),refusedUnreadablePluralTemplate:DRAFT("{n} attachments could not be read.")}),navTitle:DRAFT("Book a visit"),petFallback:"your pet",whereTitleTemplate:DRAFT("Where will {pet} be during the visit?"),whereLeadTemplate:DRAFT("Pick where {pronoun} be for the call, not where you live. It decides what the vet can do."),wherePronounFallback:"they’ll",whereFormLabelTemplate:DRAFT("Where {pet} will be"),whereLegend:DRAFT("State"),wherePrescribeMetaTemplate:DRAFT("Video visit, and prescriptions if {pet} needs them"),whereWellnessMeta:DRAFT("Wellness visit: advice and a care plan, no prescriptions yet"),whereAnotherState:DRAFT("Another state"),whereWhichState:DRAFT("Which state?"),whereLicensedTemplate:DRAFT("{vet} is licensed in {state}, so a prescription can be part of {pet}’s plan."),whereAskEveryTime:DRAFT("We ask every time: state rules require it."),issuesTitleTemplate:DRAFT("What’s going on with {pet}?"),issuesHint:DRAFT("Pick as many as you like."),issuesFormLabel:DRAFT("What’s going on"),issuesLegend:DRAFT("Main issues"),issuesPickOne:DRAFT("Pick at least one. Not sure? Choose Something else."),otherIssue:DRAFT("Something else"),describeHeadingTemplate:DRAFT("Tell {vet} what you’re seeing"),describeFieldLabel:DRAFT("What you’re seeing"),emergencyCheck:/* @__PURE__ */Object.freeze({titleTemplate:DRAFT("Is {pet} doing any of these right now?"),lead:DRAFT("A scheduled video visit isn’t the right place for an emergency."),signs:/* @__PURE__ */Object.freeze([DRAFT("Trouble breathing, or blue, grey or very pale gums"),DRAFT("Collapsed, or can’t stand up"),DRAFT("A seizure"),DRAFT("Ate something toxic, like grapes, chocolate, xylitol or medicine"),DRAFT("A swollen, hard belly, or retching with nothing coming up"),DRAFT("Bleeding that won’t stop"),DRAFT("Straining to pee with nothing coming out")]),formLabel:DRAFT("Emergency check"),legend:DRAFT("Any of these now?"),noneCta:DRAFT("No, none of these"),someCta:DRAFT("Yes, at least one")}),timeHeading:DRAFT("Pick a time"),timeMorning:DRAFT("Morning"),timeAfternoon:DRAFT("Afternoon"),timeEvening:DRAFT("Evening"),timeLegendTemplate:DRAFT("Time on {day}"),dayLegend:DRAFT("Day"),reviewHeading:DRAFT("Does this look right?"),summaryWhere:DRAFT("Where"),changeCta:DRAFT("Change"),whereAttestTemplate:DRAFT("{pet} and I will be in {state} during the visit."),attestBoth:DRAFT("Check both boxes to book the visit."),bookedStepLabel:DRAFT("Booked"),bookedTitleTemplate:DRAFT("You’re booked with {vet}"),bookedLeadTemplate:DRAFT("{when}, for {pet}."),footnote:DRAFT("Video visits are with a licensed veterinarian. Prescriptions where allowed, starting with California. In an emergency, go to the nearest emergency animal hospital."),rescheduleNavTitle:DRAFT("Change your visit"),close:DRAFT("Close"),continueCta:DRAFT("Continue"),petSelectTitle:DRAFT("Who is this visit for?"),addPetCta:DRAFT("Add a pet"),addAnotherPetCta:DRAFT("Add another pet"),locationUnknownTitle:DRAFT("We need your location to find a vet"),locationUnknownBody:DRAFT("Turn on location for Everfur, then try again."),locationUnknownCta:DRAFT("Allow location"),locationBlockedTitle:DRAFT("Location is turned off"),locationBlockedBody:DRAFT("Everfur needs your location to match you with a vet in your area."),locationBlockedCta:DRAFT("Open Settings"),locationUnavailableTitle:DRAFT("We could not read your location"),locationUnavailableBody:DRAFT("Try again in a moment."),stateAttestTemplate:DRAFT("I confirm my pet and I are in {state} right now."),describeHeading:DRAFT("Tell the vet what you are seeing"),describeHelpLong:DRAFT("When it started, what’s changed, what you’ve tried. Anything helps."),addPhotoCta:DRAFT("Add photos or videos"),addPhotoMeta:DRAFT("Optional. A close-up in good light helps."),removePhotoLabel:DRAFT("Remove photo"),summaryPet:DRAFT("Pet"),summaryVet:DRAFT("Vet"),summaryWhen:DRAFT("When"),summaryLength:DRAFT("Length"),summaryReason:DRAFT("About"),summaryLengthTemplate:DRAFT("{n} minutes"),confirmCta:DRAFT("Book the visit"),confirmBusy:DRAFT("Booking…"),bookedTitle:DRAFT("You are booked."),addToCalendarCta:DRAFT("Add to calendar"),doneCta:DRAFT("Done"),booked:/* @__PURE__ */Object.freeze({remindPromise:DRAFT("We will notify you 30 minutes before."),summaryPromise:DRAFT("{pet}'s summary goes to the vet ahead of the call."),recordsPromiseTemplate:DRAFT("{pet}’s records and your notes go to {vet} ahead of the call."),recordsPhotoPromiseTemplate:DRAFT("{pet}’s records, your notes and the photo go to {vet} ahead of the call."),stepsLabel:DRAFT("What happens next"),joinPromise:DRAFT("Join right here in the app. No links to hunt for."),backToPet:DRAFT("Back to {pet}"),calendarAdded:DRAFT("Added to your calendar"),calendarFailedBody:DRAFT("That did not save to your calendar.")}),chrome:/* @__PURE__ */Object.freeze({closeHint:DRAFT("Closes without saving"),discardTitle:DRAFT("Leave without booking?"),discardBody:DRAFT("Your answers will not be saved."),discardConfirmCta:DRAFT("Leave"),discardKeepCta:DRAFT("Keep going"),noPetsTitle:DRAFT("No pets on this account"),loadFailedTitle:DRAFT("Could not load"),retryCta:DRAFT("Try again")}),emergency:/* @__PURE__ */Object.freeze({bannerTitle:DRAFT("This can’t wait for a scheduled visit."),keepBookingCta:DRAFT("I’ve handled this, continue booking"),lede:DRAFT("What you’re describing is the kind of thing vets want to see in person, now. Call one of these first."),ledeWithoutExits:DRAFT("What you’re describing is the kind of thing vets want to see in person, now."),exitPrimaryVetTitle:DRAFT("Call {petName}’s regular vet"),exitFindErTitle:DRAFT("Find an emergency vet near you"),exitGoToErTitle:EMERGENCY_ER_LINE,startCallHint:DRAFT("Starts a phone call"),poisonControl:DRAFT("ASPCA Animal Poison Control"),poisonControlDetail:DRAFT("(888) 426-4435 · a fee may apply"),poisonControlTel:"tel:+18884264435"}),visit:/* @__PURE__ */Object.freeze({title:DRAFT("Your visit")}),loading:/* @__PURE__ */Object.freeze({pets:"Loading pets. Nothing to read yet.",clinicians:"Loading vets. Nothing to read yet.",slots:"Loading times. Nothing to read yet.",consult:"Loading your visit. Nothing to read yet.",progressTemplate:"Step {step} of {total}"})});function televetBookingCopyValues(node=TELEVET_BOOKING_COPY){return typeof node=="string"?[node]:typeof node!="object"||node===null?[]:Object.values(node).flatMap(v=>televetBookingCopyValues(v))}function isTelevetBookingCopyReady(){return televetBookingCopyValues().every(value=>value.trim().length>0&&!isPlaceholderCopy(value))}var CONTRACT_RETRYABILITY=/* @__PURE__ */Object.freeze([
|
|
6
|
-
/* @__PURE__ */Object.freeze({wireCode:"AccessDeniedException",envelope:"http_envelope",httpStatus:403,retryable:false}),
|
|
7
|
-
/* @__PURE__ */Object.freeze({wireCode:"AuthorizationException",envelope:"http_envelope",httpStatus:401,retryable:false}),
|
|
8
|
-
/* @__PURE__ */Object.freeze({wireCode:"ConflictException",envelope:"http_envelope",httpStatus:409,retryable:true}),
|
|
9
|
-
/* @__PURE__ */Object.freeze({wireCode:"DAILY_QUOTA_EXCEEDED",envelope:"http_envelope",httpStatus:429,retryable:true}),
|
|
10
|
-
/* @__PURE__ */Object.freeze({wireCode:"FILE_TOO_LARGE",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
11
|
-
/* @__PURE__ */Object.freeze({wireCode:"IDEMPOTENCY_KEY_IN_FLIGHT",envelope:"http_envelope",httpStatus:409,retryable:true}),
|
|
12
|
-
/* @__PURE__ */Object.freeze({wireCode:"IDEMPOTENCY_KEY_REUSED_DIFFERENT_REQUEST",envelope:"http_envelope",httpStatus:409,retryable:false}),
|
|
13
|
-
/* @__PURE__ */Object.freeze({wireCode:"INVALID_CONTENT_TYPE",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
14
|
-
/* @__PURE__ */Object.freeze({wireCode:"InternalFailureException",envelope:"http_envelope",httpStatus:500,retryable:true}),
|
|
15
|
-
/* @__PURE__ */Object.freeze({wireCode:"MethodNotAllowedException",envelope:"http_envelope",httpStatus:405,retryable:false}),
|
|
16
|
-
/* @__PURE__ */Object.freeze({wireCode:"NotImplementedException",envelope:"http_envelope",httpStatus:501,retryable:false}),
|
|
17
|
-
/* @__PURE__ */Object.freeze({wireCode:"PaymentRequiredException",envelope:"http_envelope",httpStatus:402,retryable:false}),
|
|
18
|
-
/* @__PURE__ */Object.freeze({wireCode:"ResourceNotFoundException",envelope:"http_envelope",httpStatus:404,retryable:false}),
|
|
19
|
-
/* @__PURE__ */Object.freeze({wireCode:"ServiceUnavailableException",envelope:"http_envelope",httpStatus:503,retryable:true}),
|
|
20
|
-
/* @__PURE__ */Object.freeze({wireCode:"TIER_UPGRADE_REQUIRED",envelope:"http_envelope",httpStatus:402,retryable:false}),
|
|
21
|
-
/* @__PURE__ */Object.freeze({wireCode:"ThrottlingException",envelope:"http_envelope",httpStatus:429,retryable:true}),
|
|
22
|
-
/* @__PURE__ */Object.freeze({wireCode:"ValidationException",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
23
|
-
/* @__PURE__ */Object.freeze({wireCode:"accessDenied",envelope:"http_envelope",httpStatus:403,retryable:false}),
|
|
24
|
-
/* @__PURE__ */Object.freeze({wireCode:"access_denied",envelope:"oauth_error",httpStatus:302,retryable:false}),
|
|
25
|
-
/* @__PURE__ */Object.freeze({wireCode:"attachment_unreadable",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
26
|
-
/* @__PURE__ */Object.freeze({wireCode:"authExpired",envelope:"http_envelope",httpStatus:401,retryable:true}),
|
|
27
|
-
/* @__PURE__ */Object.freeze({wireCode:"authRejected",envelope:"http_envelope",httpStatus:401,retryable:false}),
|
|
28
|
-
/* @__PURE__ */Object.freeze({wireCode:"catalog_empty_refused",envelope:"http_envelope",httpStatus:409,retryable:false}),
|
|
29
|
-
/* @__PURE__ */Object.freeze({wireCode:"catalog_shrink_refused",envelope:"http_envelope",httpStatus:409,retryable:false}),
|
|
30
|
-
/* @__PURE__ */Object.freeze({wireCode:"consent_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),
|
|
31
|
-
/* @__PURE__ */Object.freeze({wireCode:"consent_required",envelope:"http_envelope",httpStatus:422,retryable:false}),
|
|
32
|
-
/* @__PURE__ */Object.freeze({wireCode:"consent_scope_wrong_route",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
33
|
-
/* @__PURE__ */Object.freeze({wireCode:"device_cipher_unavailable",envelope:"http_envelope",httpStatus:503,retryable:true}),
|
|
34
|
-
/* @__PURE__ */Object.freeze({wireCode:"email_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),
|
|
35
|
-
/* @__PURE__ */Object.freeze({wireCode:"event_cursor_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
36
|
-
/* @__PURE__ */Object.freeze({wireCode:"event_filter_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
37
|
-
/* @__PURE__ */Object.freeze({wireCode:"event_payload_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
38
|
-
/* @__PURE__ */Object.freeze({wireCode:"event_type_not_available",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
39
|
-
/* @__PURE__ */Object.freeze({wireCode:"event_type_unknown",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
40
|
-
/* @__PURE__ */Object.freeze({wireCode:"idempotency_key_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
41
|
-
/* @__PURE__ */Object.freeze({wireCode:"idempotency_key_required",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
42
|
-
/* @__PURE__ */Object.freeze({wireCode:"idempotency_key_reused",envelope:"http_envelope",httpStatus:409,retryable:false}),
|
|
43
|
-
/* @__PURE__ */Object.freeze({wireCode:"insufficientCapability",envelope:"http_envelope",httpStatus:403,retryable:false}),
|
|
44
|
-
/* @__PURE__ */Object.freeze({wireCode:"insufficient_scope",envelope:"http_envelope",httpStatus:403,retryable:false}),
|
|
45
|
-
/* @__PURE__ */Object.freeze({wireCode:"internal_error",envelope:"sse_frame",httpStatus:200,retryable:false}),
|
|
46
|
-
/* @__PURE__ */Object.freeze({wireCode:"invalidRequest",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
47
|
-
/* @__PURE__ */Object.freeze({wireCode:"invalid_client",envelope:"oauth_error",httpStatus:401,retryable:false}),
|
|
48
|
-
/* @__PURE__ */Object.freeze({wireCode:"invalid_client_metadata",envelope:"oauth_error",httpStatus:400,retryable:false}),
|
|
49
|
-
/* @__PURE__ */Object.freeze({wireCode:"invalid_grant",envelope:"oauth_error",httpStatus:400,retryable:false}),
|
|
50
|
-
/* @__PURE__ */Object.freeze({wireCode:"invalid_redirect_uri",envelope:"oauth_error",httpStatus:400,retryable:false}),
|
|
51
|
-
/* @__PURE__ */Object.freeze({wireCode:"invalid_request",envelope:"oauth_error",httpStatus:400,retryable:false}),
|
|
52
|
-
/* @__PURE__ */Object.freeze({wireCode:"invalid_scope",envelope:"oauth_error",httpStatus:400,retryable:false}),
|
|
53
|
-
/* @__PURE__ */Object.freeze({wireCode:"invalid_target",envelope:"oauth_error",httpStatus:400,retryable:false}),
|
|
54
|
-
/* @__PURE__ */Object.freeze({wireCode:"linked_account_read_only",envelope:"http_envelope",httpStatus:409,retryable:false}),
|
|
55
|
-
/* @__PURE__ */Object.freeze({wireCode:"mcp_connection_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),
|
|
56
|
-
/* @__PURE__ */Object.freeze({wireCode:"mcp_request_conflict",envelope:"http_envelope",httpStatus:409,retryable:false}),
|
|
57
|
-
/* @__PURE__ */Object.freeze({wireCode:"mcp_request_gone",envelope:"http_envelope",httpStatus:410,retryable:false}),
|
|
58
|
-
/* @__PURE__ */Object.freeze({wireCode:"mcp_request_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),
|
|
59
|
-
/* @__PURE__ */Object.freeze({wireCode:"not_found",envelope:"sse_frame",httpStatus:200,retryable:false}),
|
|
60
|
-
/* @__PURE__ */Object.freeze({wireCode:"partner_visit_link_conflict",envelope:"http_envelope",httpStatus:409,retryable:false}),
|
|
61
|
-
/* @__PURE__ */Object.freeze({wireCode:"partner_visit_owner_only",envelope:"http_envelope",httpStatus:403,retryable:false}),
|
|
62
|
-
/* @__PURE__ */Object.freeze({wireCode:"partner_visit_pet_already_mapped",envelope:"http_envelope",httpStatus:409,retryable:false}),
|
|
63
|
-
/* @__PURE__ */Object.freeze({wireCode:"payload_too_large",envelope:"http_envelope",httpStatus:413,retryable:false}),
|
|
64
|
-
/* @__PURE__ */Object.freeze({wireCode:"petRefInUse",envelope:"http_envelope",httpStatus:409,retryable:false}),
|
|
65
|
-
/* @__PURE__ */Object.freeze({wireCode:"pet_health_list_removals_unconfirmed",envelope:"http_envelope",httpStatus:422,retryable:false}),
|
|
66
|
-
/* @__PURE__ */Object.freeze({wireCode:"pet_health_species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),
|
|
67
|
-
/* @__PURE__ */Object.freeze({wireCode:"pet_not_registered",envelope:"http_envelope",httpStatus:404,retryable:false}),
|
|
68
|
-
/* @__PURE__ */Object.freeze({wireCode:"provider_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),
|
|
69
|
-
/* @__PURE__ */Object.freeze({wireCode:"rateLimited",envelope:"http_envelope",httpStatus:429,retryable:true}),
|
|
70
|
-
/* @__PURE__ */Object.freeze({wireCode:"record_species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),
|
|
71
|
-
/* @__PURE__ */Object.freeze({wireCode:"record_subject_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),
|
|
72
|
-
/* @__PURE__ */Object.freeze({wireCode:"record_upload_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
73
|
-
/* @__PURE__ */Object.freeze({wireCode:"records_consent_required",envelope:"http_envelope",httpStatus:409,retryable:false}),
|
|
74
|
-
/* @__PURE__ */Object.freeze({wireCode:"sandbox_only",envelope:"http_envelope",httpStatus:403,retryable:false}),
|
|
75
|
-
/* @__PURE__ */Object.freeze({wireCode:"session_required",envelope:"http_envelope",httpStatus:403,retryable:false}),
|
|
76
|
-
/* @__PURE__ */Object.freeze({wireCode:"session_revoked",envelope:"http_envelope",httpStatus:401,retryable:false}),
|
|
77
|
-
/* @__PURE__ */Object.freeze({wireCode:"share_limit_reached",envelope:"http_envelope",httpStatus:429,retryable:false}),
|
|
78
|
-
/* @__PURE__ */Object.freeze({wireCode:"slow_down",envelope:"oauth_error",httpStatus:429,retryable:true}),
|
|
79
|
-
/* @__PURE__ */Object.freeze({wireCode:"species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false}),
|
|
80
|
-
/* @__PURE__ */Object.freeze({wireCode:"tenant_filter_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
81
|
-
/* @__PURE__ */Object.freeze({wireCode:"tenant_has_no_capabilities",envelope:"http_envelope",httpStatus:409,retryable:false}),
|
|
82
|
-
/* @__PURE__ */Object.freeze({wireCode:"tenant_resource_not_found",envelope:"http_envelope",httpStatus:404,retryable:false}),
|
|
83
|
-
/* @__PURE__ */Object.freeze({wireCode:"tenant_surface_not_enabled",envelope:"http_envelope",httpStatus:409,retryable:false}),
|
|
84
|
-
/* @__PURE__ */Object.freeze({wireCode:"timeout",envelope:"sse_frame",httpStatus:200,retryable:true}),
|
|
85
|
-
/* @__PURE__ */Object.freeze({wireCode:"token_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),
|
|
86
|
-
/* @__PURE__ */Object.freeze({wireCode:"unavailable",envelope:"sse_frame",httpStatus:200,retryable:true}),
|
|
87
|
-
/* @__PURE__ */Object.freeze({wireCode:"unavailable",envelope:"http_envelope",httpStatus:503,retryable:true}),
|
|
88
|
-
/* @__PURE__ */Object.freeze({wireCode:"unrestrictedKeyRequired",envelope:"http_envelope",httpStatus:403,retryable:false}),
|
|
89
|
-
/* @__PURE__ */Object.freeze({wireCode:"unsupported_grant_type",envelope:"oauth_error",httpStatus:400,retryable:false}),
|
|
90
|
-
/* @__PURE__ */Object.freeze({wireCode:"unsupported_response_type",envelope:"oauth_error",httpStatus:302,retryable:false}),
|
|
91
|
-
/* @__PURE__ */Object.freeze({wireCode:"user_ref_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
92
|
-
/* @__PURE__ */Object.freeze({wireCode:"verify_mint_rate_limited",envelope:"http_envelope",httpStatus:429,retryable:true}),
|
|
93
|
-
/* @__PURE__ */Object.freeze({wireCode:"verify_mint_refused",envelope:"http_envelope",httpStatus:403,retryable:false}),
|
|
94
|
-
/* @__PURE__ */Object.freeze({wireCode:"verify_mint_unavailable",envelope:"http_envelope",httpStatus:503,retryable:true}),
|
|
95
|
-
/* @__PURE__ */Object.freeze({wireCode:"verify_user_ref_invalid",envelope:"http_envelope",httpStatus:422,retryable:false}),
|
|
96
|
-
/* @__PURE__ */Object.freeze({wireCode:"webhook_endpoint_update_empty",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
97
|
-
/* @__PURE__ */Object.freeze({wireCode:"webhook_endpoint_update_invalid",envelope:"http_envelope",httpStatus:400,retryable:false}),
|
|
98
|
-
/* @__PURE__ */Object.freeze({wireCode:"webhook_url_rejected",envelope:"http_envelope",httpStatus:400,retryable:false})]);/* @__PURE__ */Object.freeze(CONTRACT_RETRYABILITY.map(row2=>row2.wireCode));var NORMALIZED_FOLD=/* @__PURE__ */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",session_revoked:"authExpired",accessDenied:"accessDenied",invalidRequest:"sdkUpdateRequired",authRejected:"authRejected",rateLimited:"rateLimited",insufficientCapability:"accessDenied",unrestrictedKeyRequired:"accessDenied",user_ref_invalid:"validationFailed",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",linked_account_read_only:"conflict",catalog_empty_refused:"conflict",catalog_shrink_refused:"conflict"}),CONTRACT_ERROR_ROWS=/* @__PURE__ */Object.freeze(CONTRACT_RETRYABILITY.map(generated=>/* @__PURE__ */Object.freeze({wireCode:generated.wireCode,envelope:generated.envelope,retryable:generated.retryable,normalized:NORMALIZED_FOLD[generated.wireCode]}))),BY_KEY=new Map(CONTRACT_ERROR_ROWS.map(r=>[r.envelope+r.wireCode.toUpperCase(),r])),ENVELOPE_LOOKUP_ORDER=/* @__PURE__ */Object.freeze(["http_envelope",...[...new Set(CONTRACT_ERROR_ROWS.map(r=>r.envelope))].filter(e=>e!=="http_envelope").sort()]);function contractErrorFor(wireCode,envelope){if(typeof wireCode!="string")return;let key=wireCode.trim().toUpperCase();if(key.length!==0)for(let candidate of[envelope??"http_envelope",...ENVELOPE_LOOKUP_ORDER]){let row2=BY_KEY.get(candidate+key);if(row2)return row2}}var CATEGORY_OF=/* @__PURE__ */Object.freeze({authExpired:"authentication",authRejected:"authentication",sessionRequired:"authentication",identitySignatureRequired:"authentication",accessDenied:"authorization",paymentRequired:"entitlement",quotaExceeded:"rateLimit",rateLimited:"rateLimit",validationFailed:"invalidRequest",sdkUpdateRequired:"invalidRequest",runtimeDisposed:"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 categoryFor(code){return CATEGORY_OF[code]}function fromWire(wire){let contractRow=contractErrorFor(wire);if(contractRow)return contractRow.normalized;let upper=(wire??"").trim().toUpperCase(),canonical=upper.replace(/[^A-Z0-9]/g,"");if(canonical==="AUTHREJECTED")return"authRejected";if(upper.startsWith("AUTH"))return"authExpired";switch(canonical){case"DAILYQUOTAEXCEEDED":case"QUOTAEXCEEDED":return"quotaExceeded";case"RATELIMITED":case"TOOMANYREQUESTS":case"TELEVETRATELIMITED":return"rateLimited";case"IDEMPOTENCYKEYCONFLICT":case"IDEMPOTENCYCONFLICT":return"idempotencyConflict";case"ACCESSDENIED":case"FORBIDDEN":return"accessDenied";case"IDENTITYSIGNATUREREQUIRED":return"identitySignatureRequired";case"RUNTIMEDISPOSED":return"runtimeDisposed";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"}}var AUTO_RETRYABLE_CODES=/* @__PURE__ */new Set(["streamTimeout","rateLimited","internalError","upstreamLlmTimeout","streamIncomplete"]);function isAutoRetryable(code){return AUTO_RETRYABLE_CODES.has(code)}var RETRYABLE_CONTRACT_CODES=/* @__PURE__ */new Set(["serviceUnavailable","conflict","idempotencyInFlight"]);function isRetryableCode(code){return isAutoRetryable(code)||RETRYABLE_CONTRACT_CODES.has(code)}var BACKOFF_BASE_MS=500,BACKOFF_CAP_MS=8e3,MAX_RETRY_ATTEMPTS=4;function backoffDelayMs(attempt,rng=Math.random){let bounded=Math.max(0,attempt),ceiling=Math.min(BACKOFF_BASE_MS*2**bounded,BACKOFF_CAP_MS);return Math.floor(rng()*ceiling)}var ACCESS_DENIED_COPY="This feature isn't available on your account right now.",VALIDATION_FAILED_COPY="Something in that request was not right. Check the details and try again.",USER_FACING_COPY=/* @__PURE__ */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:ACCESS_DENIED_COPY,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:VALIDATION_FAILED_COPY,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.",identitySignatureRequired:ACCESS_DENIED_COPY,runtimeDisposed:VALIDATION_FAILED_COPY,unknown:"Something went wrong. Please try again."}),SESSION_REVOKED_COPY="This session has ended. Please sign in again.",LINKED_ACCOUNT_READ_ONLY="linked_account_read_only";function displayFor(code,wireCode,reasonCode){return code==="conflict"&&reasonCode===LINKED_ACCOUNT_READ_ONLY?ACCESS_DENIED_COPY:(code==="authRejected"||code==="authExpired")&&typeof wireCode=="string"&&wireCode.trim().toLowerCase()==="session_revoked"?SESSION_REVOKED_COPY:userFacingError(code)}function userFacingError(code){return USER_FACING_COPY[code]}function defineHidden(target,key,value){Object.defineProperty(target,key,{value:value,enumerable:false,writable:false,configurable:false})}var REASON_CODE_SHAPE=/^[a-z][a-z0-9_]{0,63}$/;function makeEverfurError(code,opts){let row2=contractErrorFor(opts?.wireCode,opts?.wireEnvelope),linkedReadOnly=code==="conflict"&&opts?.reasonCode===LINKED_ACCOUNT_READ_ONLY,error={code:code,category:categoryFor(code),retryable:opts?.retryable??(linkedReadOnly?false:isRetryableCode(code)),displayMessage:displayFor(code,opts?.wireCode,linkedReadOnly?LINKED_ACCOUNT_READ_ONLY:null)};opts?.httpStatus!==void 0&&(error.httpStatus=opts.httpStatus),opts?.requestId&&(error.requestId=opts.requestId),typeof opts?.reasonCode=="string"&&REASON_CODE_SHAPE.test(opts.reasonCode)&&(error.reasonCode=opts.reasonCode);let wait=opts?.retryAfterSeconds;if(typeof wait=="number"&&Number.isFinite(wait)&&wait>=0&&(error.retryAfterSeconds=Math.round(wait)),row2);return opts?.wireMessage&&defineHidden(error,"wireMessage",opts.wireMessage),opts?.raw!==void 0&&opts.raw!==null&&defineHidden(error,"raw",opts.raw),/* @__PURE__ */Object.freeze(error)}function ok(value,warning){/* @__PURE__ */
|
|
4
|
+
return Object.freeze(out)}function parseStatePolicy(wire,askedFor){let r=row(wire);return r===null?null:/* @__PURE__ */Object.freeze({state:str(r.state)??askedFor,wellnessAvailable:bool(r.wellness_available,false),prescriptionsAvailable:bool(r.prescriptions_available,false),cancellationPolicyText:trimmedOrNull(r.cancellation_policy_text)})}function parseCancellationPolicy(wire){let r=row(wire);if(r===null)return null;let summary=trimmedOrNull(r.summary),version=trimmedOrNull(r.version);return summary===null||version===null?null:/* @__PURE__ */Object.freeze({summary:summary,version:version})}function parseClinician(wire){let r=row(wire);if(r===null)return null;let clinicianId=str(r.clinician_id),displayName=str(r.display_name);return clinicianId===null||displayName===null?null:/* @__PURE__ */Object.freeze({clinicianId:clinicianId,displayName:displayName,credentials:trimmedOrNull(r.credentials_text),rating:num(r.rating),ratingCount:num(r.rating_count),bio:trimmedOrNull(r.bio),photoRef:str(r.photo_ref),licensedStates:parseList(r.licensed_states,item=>{let l=row(item),state=l===null?null:str(l.state);return state===null?null:/* @__PURE__ */Object.freeze({state:state,canPrescribe:bool(l?.can_prescribe,false)})}),role:parseClinicianRole(r.clinician_role)})}function parseClinicianRole(wire){let value=str(wire)?.trim().toLowerCase();return value==="vet"||value==="vet_tech"?value:null}function parseSlot(wire){let r=row(wire);if(r===null)return null;let slotId=str(r.slot_id),startsAt=str(r.starts_at);return slotId===null||startsAt===null?null:/* @__PURE__ */Object.freeze({slotId:slotId,startsAt:startsAt,endsAt:str(r.ends_at)??startsAt})}function parseTriageVerdict(wire){let r=row(wire);if(r===null)return null;let isEmergency=r.is_emergency===true,fallback=r.fallback===true;return isEmergency||fallback?/* @__PURE__ */Object.freeze({isEmergency:isEmergency,fallback:fallback}):r.is_emergency===false&&r.fallback===false?/* @__PURE__ */Object.freeze({isEmergency:false,fallback:false}):null}function parseSlotHold(wire){let r=row(wire);if(r===null)return null;let slotId=str(r.slot_id),expiresAt=str(r.hold_expires_at);return slotId===null||expiresAt===null?null:/* @__PURE__ */Object.freeze({slotId:slotId,expiresAt:expiresAt})}function parseConsult(wire){let r=row(wire);if(r===null)return null;let consultId=str(r.consult_id),scheduledAt=str(r.scheduled_at);return consultId===null||scheduledAt===null?null:/* @__PURE__ */Object.freeze({consultId:consultId,petId:str(r.pet_id)??"",clinicianId:str(r.clinician_id)??"",clinicianName:trimmedOrNull(r.display_name),reasonText:trimmedOrNull(r.reason_text),mediaRefs:parseList(r.media_refs,item=>str(item)),status:closed(CONSULT_STATUSES,r.status),kind:closed(CONSULT_KINDS,r.kind),scheduledAt:scheduledAt,emergencyFlagged:bool(r.emergency_flagged,false),hasRoom:str(r.meeting_url)!==null})}function parseBookingEntitlement(wire){let r=row(wire);/* @__PURE__ */
|
|
5
|
+
return Object.freeze({active:bool(r?.active,false)})}var CANCEL_REASON_MAX=240;function parseCancelReceipt(wire){let r=row(wire);if(r===null)return null;let feeCents=num(r.fee_cents);return feeCents===null||feeCents<0?null:/* @__PURE__ */Object.freeze({feeCents:feeCents,currency:str(r.currency)??"usd",feeRecorded:bool(r.fee_recorded,feeCents>0),summary:trimmedOrNull(r.summary)})}var TELEVET_JOIN_OPENS_MINUTES_BEFORE=15,TELEVET_JOIN_CLOSES_MINUTES_AFTER=250,JOINABLE=/* @__PURE__ */new Set(["scheduled","in_progress"]);function startsAtMs(consult){let parsed=Date.parse(consult.scheduledAt);return Number.isNaN(parsed)?null:parsed}function televetJoinOpensAtMs(consult){let start=startsAtMs(consult);return start===null?null:start-TELEVET_JOIN_OPENS_MINUTES_BEFORE*6e4}function televetJoinReadiness(consult,nowMs){if(consult===null)return{ready:false,reason:"not_open_yet"};if(TERMINAL_CONSULT_STATUSES.has(consult.status))return{ready:false,reason:"consult_over"};if(consult.status==="in_progress")return{ready:true};let start=startsAtMs(consult);return start===null?{ready:false,reason:"not_open_yet"}:nowMs<start-TELEVET_JOIN_OPENS_MINUTES_BEFORE*6e4?{ready:false,reason:"not_open_yet"}:nowMs>start+TELEVET_JOIN_CLOSES_MINUTES_AFTER*6e4?{ready:false,reason:"consult_over"}:{ready:true}}function televetJoinDecision(consult,nowMs){if(!JOINABLE.has(consult.status))return{joinable:false,reason:`status_${consult.status}`};if(!consult.hasRoom)return{joinable:false,reason:"room_not_ready"};let start=startsAtMs(consult);return start===null||nowMs<start-TELEVET_JOIN_OPENS_MINUTES_BEFORE*6e4?{joinable:false,reason:"too_early"}:nowMs>start+TELEVET_JOIN_CLOSES_MINUTES_AFTER*6e4?{joinable:false,reason:"too_late"}:{joinable:true}}function splitTelevetVisits(consults,nowMs){let upcoming=[],past=[];for(let consult of consults){let start=startsAtMs(consult);(JOINABLE.has(consult.status)&&start!==null&&start+TELEVET_JOIN_CLOSES_MINUTES_AFTER*6e4>nowMs?upcoming:past).push(consult)}return upcoming.sort((a,b)=>(startsAtMs(a)??0)-(startsAtMs(b)??0)),past.sort((a,b)=>(startsAtMs(b)??0)-(startsAtMs(a)??0)),/* @__PURE__ */Object.freeze({upcoming:/* @__PURE__ */Object.freeze(upcoming),past:/* @__PURE__ */Object.freeze(past)})}function canManageTelevetVisit(status){return status==="scheduled"}function reportHostFailure(error){let globalConsole=globalThis.console;try{globalConsole?.error?.("[everfur] A host callback threw; the SDK ignored it.",error)}catch{}}function isThenable(value){return(typeof value=="object"||typeof value=="function")&&value!==null&&typeof value.then=="function"}function callHost(fn,...args){if(typeof fn=="function")try{let result=fn(...args);return isThenable(result)&&Promise.resolve(result).then(void 0,reportHostFailure),result}catch(error){reportHostFailure(error);return}}var GUARDED=/* @__PURE__ */new WeakMap;function guardHost(fn){if(typeof fn!="function")return;let cached=GUARDED.get(fn);if(cached!==void 0)return cached;let guarded=(...args)=>{callHost(fn,...args)};return GUARDED.set(fn,guarded),guarded}function guardHostProps(props,names){let guarded=null;for(let name of names){let fn=props[name];typeof fn=="function"&&(guarded??={...props},guarded[name]=guardHost(fn))}return guarded??props}function callHostAsync(fn,...args){let started;try{started=fn(...args)}catch(error){return reportHostFailure(error),Promise.resolve({ok:false,error:error})}return Promise.resolve(started).then(value=>({ok:true,value:value}),error=>({ok:false,error:error}))}function createTelevetBackChannel(){let handlers=[];return{register(handler){return handlers=[...handlers,handler],()=>{handlers=handlers.filter(h=>h!==handler)}},dispatch(){for(let handler of[...handlers].reverse())try{if(handler())return!0}catch{}return false}}}var TelevetBackChannelContext=react.createContext(null);function useTelevetBackChannel(handler,enabled=true){let channel=react.useContext(TelevetBackChannelContext),current=react.useRef(handler);current.current=handler,react.useEffect(()=>{if(!(channel===null||!enabled))return channel.register(()=>current.current())},[channel,enabled])}var EMERGENCY_ER_LINE="Go to the nearest emergency vet now.";var DRAFT=s=>s,PLACEHOLDER_MARKERS=["[PLACEHOLDER","[PLAN NAME]","[LINK]","[Last]","TODO","TBD"];function isPlaceholderCopy(value){return PLACEHOLDER_MARKERS.some(m=>value.toUpperCase().includes(m.toUpperCase()))}function fill(template,slots){let out=template;for(let[key,value]of Object.entries(slots))out=out.split(`{${key}}`).join(value);return out}var TELEVET_BOOKING_COPY=/* @__PURE__ */Object.freeze({stateBlockedTitle:DRAFT("Not available in this state yet"),noCliniciansTitle:DRAFT("No vets available right now"),noCliniciansBody:DRAFT("Nobody is free in your area at the moment. This changes through the day."),noCliniciansRetryCta:DRAFT("Check again"),noCliniciansRegionBody:DRAFT("Video visits have to be with a vet licensed in your state, and we don’t have one there yet."),yourVetTitle:DRAFT("Your vet"),licensedPillTemplate:DRAFT("Licensed in {state}"),reviewsLabel:DRAFT("reviews"),vetTechRoleLabel:DRAFT("Vet tech"),vetTechNoRxLine:DRAFT("Vet techs can’t prescribe medication."),rescheduleFromTemplate:DRAFT("Moving your visit on {when}"),rescheduleFailed:DRAFT("That did not move. Your original time is unchanged."),rescheduleStepLabel:DRAFT("Reschedule"),rescheduleTitleTemplate:DRAFT("Pick a new time for {pet}"),rescheduleNowLabel:DRAFT("Now"),rescheduleMoveTemplate:DRAFT("Move to {when}"),rescheduleMoving:DRAFT("Moving…"),rescheduleKeepLabel:DRAFT("Keep the visit as it is"),keepExistingCta:DRAFT("Keep my current time"),bookingPausedTitle:DRAFT("Booking is not available right now."),slotsErrorTitle:DRAFT("Could not load times"),noSlotsTitle:DRAFT("No times available"),nextOpeningTemplate:DRAFT("Next opening across our vets: {when}"),seeOtherVetsCta:DRAFT("See other vets"),retryCta:DRAFT("Try again"),holdExpired:DRAFT("That time is no longer held. Pick another."),slotTaken:DRAFT("That time was just taken. Pick another."),reasonPlaceholder:DRAFT("What is going on with your pet?"),reasonTooLong:DRAFT("That is too long. Please shorten it."),shareRecordsOff:DRAFT("Share health records with this vet"),confirmNotEntitled:DRAFT("A Pro membership is needed to book a video visit."),confirmFailed:DRAFT("That did not book. Try again."),checkAvailabilityCta:DRAFT("Check availability"),stateInterest:/* @__PURE__ */Object.freeze({cta:DRAFT("Add me to the list"),submitting:DRAFT("Adding you to the list…"),joinedTitle:DRAFT("You are on the list"),joinedBody:DRAFT("We will let you know when this changes."),failed:DRAFT("That did not save. Try again.")}),media:/* @__PURE__ */Object.freeze({droppedTemplate:DRAFT("{n} attachment did not upload."),droppedPluralTemplate:DRAFT("{n} attachments did not upload."),refusedSizeTemplate:DRAFT("{n} attachment was too large to send."),refusedSizePluralTemplate:DRAFT("{n} attachments were too large to send."),refusedTypeTemplate:DRAFT("{n} attachment is a file type that cannot be sent."),refusedTypePluralTemplate:DRAFT("{n} attachments are file types that cannot be sent."),refusedUnreadableTemplate:DRAFT("{n} attachment could not be read."),refusedUnreadablePluralTemplate:DRAFT("{n} attachments could not be read.")}),navTitle:DRAFT("Book a visit"),petFallback:"your pet",whereTitleTemplate:DRAFT("Where will {pet} be during the visit?"),whereLeadTemplate:DRAFT("Pick where {pronoun} be for the call, not where you live. It decides what the vet can do."),wherePronounFallback:"they’ll",whereFormLabelTemplate:DRAFT("Where {pet} will be"),whereLegend:DRAFT("State"),wherePrescribeMetaTemplate:DRAFT("Video visit, and prescriptions if {pet} needs them"),whereWellnessMeta:DRAFT("Wellness visit: advice and a care plan, no prescriptions yet"),whereAnotherState:DRAFT("Another state"),whereWhichState:DRAFT("Which state?"),whereLicensedTemplate:DRAFT("{vet} is licensed in {state}, so a prescription can be part of {pet}’s plan."),whereAskEveryTime:DRAFT("We ask every time: state rules require it."),issuesTitleTemplate:DRAFT("What’s going on with {pet}?"),issuesHint:DRAFT("Pick as many as you like."),issuesFormLabel:DRAFT("What’s going on"),issuesLegend:DRAFT("Main issues"),issuesPickOne:DRAFT("Pick at least one. Not sure? Choose Something else."),otherIssue:DRAFT("Something else"),describeHeadingTemplate:DRAFT("Tell {vet} what you’re seeing"),describeFieldLabel:DRAFT("What you’re seeing"),emergencyCheck:/* @__PURE__ */Object.freeze({titleTemplate:DRAFT("Is {pet} doing any of these right now?"),lead:DRAFT("A scheduled video visit isn’t the right place for an emergency."),signs:/* @__PURE__ */Object.freeze([DRAFT("Trouble breathing, or blue, grey or very pale gums"),DRAFT("Collapsed, or can’t stand up"),DRAFT("A seizure"),DRAFT("Ate something toxic, like grapes, chocolate, xylitol or medicine"),DRAFT("A swollen, hard belly, or retching with nothing coming up"),DRAFT("Bleeding that won’t stop"),DRAFT("Straining to pee with nothing coming out")]),formLabel:DRAFT("Emergency check"),legend:DRAFT("Any of these now?"),noneCta:DRAFT("No, none of these"),someCta:DRAFT("Yes, at least one")}),timeHeading:DRAFT("Pick a time"),timeMorning:DRAFT("Morning"),timeAfternoon:DRAFT("Afternoon"),timeEvening:DRAFT("Evening"),timeLegendTemplate:DRAFT("Time on {day}"),dayLegend:DRAFT("Day"),reviewHeading:DRAFT("Does this look right?"),summaryWhere:DRAFT("Where"),changeCta:DRAFT("Change"),whereAttestTemplate:DRAFT("{pet} and I will be in {state} during the visit."),attestBoth:DRAFT("Check both boxes to book the visit."),bookedStepLabel:DRAFT("Booked"),bookedTitleTemplate:DRAFT("You’re booked with {vet}"),bookedLeadTemplate:DRAFT("{when}, for {pet}."),footnote:DRAFT("Video visits are with a licensed veterinarian. Prescriptions where allowed, starting with California. In an emergency, go to the nearest emergency animal hospital."),rescheduleNavTitle:DRAFT("Change your visit"),close:DRAFT("Close"),continueCta:DRAFT("Continue"),petSelectTitle:DRAFT("Who is this visit for?"),addPetCta:DRAFT("Add a pet"),addAnotherPetCta:DRAFT("Add another pet"),locationUnknownTitle:DRAFT("We need your location to find a vet"),locationUnknownBody:DRAFT("Turn on location for Everfur, then try again."),locationUnknownCta:DRAFT("Allow location"),locationBlockedTitle:DRAFT("Location is turned off"),locationBlockedBody:DRAFT("Everfur needs your location to match you with a vet in your area."),locationBlockedCta:DRAFT("Open Settings"),locationUnavailableTitle:DRAFT("We could not read your location"),locationUnavailableBody:DRAFT("Try again in a moment."),stateAttestTemplate:DRAFT("I confirm my pet and I are in {state} right now."),describeHeading:DRAFT("Tell the vet what you are seeing"),describeHelpLong:DRAFT("When it started, what’s changed, what you’ve tried. Anything helps."),addPhotoCta:DRAFT("Add photos or videos"),addPhotoMeta:DRAFT("Optional. A close-up in good light helps."),removePhotoLabel:DRAFT("Remove photo"),summaryPet:DRAFT("Pet"),summaryVet:DRAFT("Vet"),summaryWhen:DRAFT("When"),summaryLength:DRAFT("Length"),summaryReason:DRAFT("About"),summaryLengthTemplate:DRAFT("{n} minutes"),confirmCta:DRAFT("Book the visit"),confirmBusy:DRAFT("Booking…"),bookedTitle:DRAFT("You are booked."),addToCalendarCta:DRAFT("Add to calendar"),doneCta:DRAFT("Done"),booked:/* @__PURE__ */Object.freeze({remindPromise:DRAFT("We will notify you 30 minutes before."),summaryPromise:DRAFT("{pet}'s summary goes to the vet ahead of the call."),recordsPromiseTemplate:DRAFT("{pet}’s records and your notes go to {vet} ahead of the call."),recordsPhotoPromiseTemplate:DRAFT("{pet}’s records, your notes and the photo go to {vet} ahead of the call."),stepsLabel:DRAFT("What happens next"),joinPromise:DRAFT("Join right here in the app. No links to hunt for."),backToPet:DRAFT("Back to {pet}"),calendarAdded:DRAFT("Added to your calendar"),calendarFailedBody:DRAFT("That did not save to your calendar.")}),chrome:/* @__PURE__ */Object.freeze({closeHint:DRAFT("Closes without saving"),discardTitle:DRAFT("Leave without booking?"),discardBody:DRAFT("Your answers will not be saved."),discardConfirmCta:DRAFT("Leave"),discardKeepCta:DRAFT("Keep going"),noPetsTitle:DRAFT("No pets on this account"),loadFailedTitle:DRAFT("Could not load"),retryCta:DRAFT("Try again")}),emergency:/* @__PURE__ */Object.freeze({bannerTitle:DRAFT("This can’t wait for a scheduled visit."),keepBookingCta:DRAFT("I’ve handled this, continue booking"),lede:DRAFT("What you’re describing is the kind of thing vets want to see in person, now. Call one of these first."),ledeWithoutExits:DRAFT("What you’re describing is the kind of thing vets want to see in person, now."),exitPrimaryVetTitle:DRAFT("Call {petName}’s regular vet"),exitFindErTitle:DRAFT("Find an emergency vet near you"),exitGoToErTitle:EMERGENCY_ER_LINE,startCallHint:DRAFT("Starts a phone call"),poisonControl:DRAFT("ASPCA Animal Poison Control"),poisonControlDetail:DRAFT("(888) 426-4435 · a fee may apply"),poisonControlTel:"tel:+18884264435"}),visit:/* @__PURE__ */Object.freeze({title:DRAFT("Your visit")}),loading:/* @__PURE__ */Object.freeze({pets:"Loading pets. Nothing to read yet.",clinicians:"Loading vets. Nothing to read yet.",slots:"Loading times. Nothing to read yet.",consult:"Loading your visit. Nothing to read yet.",progressTemplate:"Step {step} of {total}"})});function televetBookingCopyValues(node=TELEVET_BOOKING_COPY){return typeof node=="string"?[node]:typeof node!="object"||node===null?[]:Object.values(node).flatMap(v=>televetBookingCopyValues(v))}function isTelevetBookingCopyReady(){return televetBookingCopyValues().every(value=>value.trim().length>0&&!isPlaceholderCopy(value))}var RETRYABILITY_ROWS=[{wireCode:"AccessDeniedException",envelope:"http_envelope",httpStatus:403,retryable:false},{wireCode:"AuthorizationException",envelope:"http_envelope",httpStatus:401,retryable:false},{wireCode:"ConflictException",envelope:"http_envelope",httpStatus:409,retryable:true},{wireCode:"DAILY_QUOTA_EXCEEDED",envelope:"http_envelope",httpStatus:429,retryable:true},{wireCode:"FILE_TOO_LARGE",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"IDEMPOTENCY_KEY_IN_FLIGHT",envelope:"http_envelope",httpStatus:409,retryable:true},{wireCode:"IDEMPOTENCY_KEY_REUSED_DIFFERENT_REQUEST",envelope:"http_envelope",httpStatus:409,retryable:false},{wireCode:"INVALID_CONTENT_TYPE",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"InternalFailureException",envelope:"http_envelope",httpStatus:500,retryable:true},{wireCode:"MethodNotAllowedException",envelope:"http_envelope",httpStatus:405,retryable:false},{wireCode:"NotImplementedException",envelope:"http_envelope",httpStatus:501,retryable:false},{wireCode:"PaymentRequiredException",envelope:"http_envelope",httpStatus:402,retryable:false},{wireCode:"ResourceNotFoundException",envelope:"http_envelope",httpStatus:404,retryable:false},{wireCode:"ServiceUnavailableException",envelope:"http_envelope",httpStatus:503,retryable:true},{wireCode:"TIER_UPGRADE_REQUIRED",envelope:"http_envelope",httpStatus:402,retryable:false},{wireCode:"ThrottlingException",envelope:"http_envelope",httpStatus:429,retryable:true},{wireCode:"ValidationException",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"accessDenied",envelope:"http_envelope",httpStatus:403,retryable:false},{wireCode:"access_denied",envelope:"oauth_error",httpStatus:302,retryable:false},{wireCode:"attachment_unreadable",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"authExpired",envelope:"http_envelope",httpStatus:401,retryable:true},{wireCode:"authRejected",envelope:"http_envelope",httpStatus:401,retryable:false},{wireCode:"catalog_empty_refused",envelope:"http_envelope",httpStatus:409,retryable:false},{wireCode:"catalog_shrink_refused",envelope:"http_envelope",httpStatus:409,retryable:false},{wireCode:"consent_invalid",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"consent_required",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"consent_scope_wrong_route",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"device_cipher_unavailable",envelope:"http_envelope",httpStatus:503,retryable:true},{wireCode:"email_invalid",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"endpoint_not_allowed",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"event_cursor_invalid",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"event_filter_invalid",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"event_id_invalid",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"event_payload_invalid",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"event_type_not_available",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"event_type_unknown",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"idempotency_key_invalid",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"idempotency_key_required",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"idempotency_key_reused",envelope:"http_envelope",httpStatus:409,retryable:false},{wireCode:"inbox_cursor_invalid",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"insufficientCapability",envelope:"http_envelope",httpStatus:403,retryable:false},{wireCode:"insufficient_scope",envelope:"http_envelope",httpStatus:403,retryable:false},{wireCode:"internal_error",envelope:"sse_frame",httpStatus:200,retryable:false},{wireCode:"invalidRequest",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"invalid_client",envelope:"oauth_error",httpStatus:401,retryable:false},{wireCode:"invalid_client_metadata",envelope:"oauth_error",httpStatus:400,retryable:false},{wireCode:"invalid_grant",envelope:"oauth_error",httpStatus:400,retryable:false},{wireCode:"invalid_redirect_uri",envelope:"oauth_error",httpStatus:400,retryable:false},{wireCode:"invalid_request",envelope:"oauth_error",httpStatus:400,retryable:false},{wireCode:"invalid_scope",envelope:"oauth_error",httpStatus:400,retryable:false},{wireCode:"invalid_target",envelope:"oauth_error",httpStatus:400,retryable:false},{wireCode:"item_id_invalid",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"linked_account_read_only",envelope:"http_envelope",httpStatus:409,retryable:false},{wireCode:"mcp_connection_not_found",envelope:"http_envelope",httpStatus:404,retryable:false},{wireCode:"mcp_request_conflict",envelope:"http_envelope",httpStatus:409,retryable:false},{wireCode:"mcp_request_gone",envelope:"http_envelope",httpStatus:410,retryable:false},{wireCode:"mcp_request_not_found",envelope:"http_envelope",httpStatus:404,retryable:false},{wireCode:"not_found",envelope:"sse_frame",httpStatus:200,retryable:false},{wireCode:"open_url_not_allowed",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"partner_visit_link_conflict",envelope:"http_envelope",httpStatus:409,retryable:false},{wireCode:"partner_visit_owner_only",envelope:"http_envelope",httpStatus:403,retryable:false},{wireCode:"partner_visit_pet_already_mapped",envelope:"http_envelope",httpStatus:409,retryable:false},{wireCode:"payload_too_large",envelope:"http_envelope",httpStatus:413,retryable:false},{wireCode:"petRefInUse",envelope:"http_envelope",httpStatus:409,retryable:false},{wireCode:"pet_health_list_removals_unconfirmed",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"pet_health_species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"pet_not_registered",envelope:"http_envelope",httpStatus:404,retryable:false},{wireCode:"provider_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"rateLimited",envelope:"http_envelope",httpStatus:429,retryable:true},{wireCode:"read_target_invalid",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"record_species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"record_subject_not_found",envelope:"http_envelope",httpStatus:404,retryable:false},{wireCode:"record_upload_invalid",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"records_consent_required",envelope:"http_envelope",httpStatus:409,retryable:false},{wireCode:"sandbox_only",envelope:"http_envelope",httpStatus:403,retryable:false},{wireCode:"session_required",envelope:"http_envelope",httpStatus:403,retryable:false},{wireCode:"session_revoked",envelope:"http_envelope",httpStatus:401,retryable:false},{wireCode:"share_limit_reached",envelope:"http_envelope",httpStatus:429,retryable:false},{wireCode:"slow_down",envelope:"oauth_error",httpStatus:429,retryable:true},{wireCode:"species_unsupported",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"subscription_keys_invalid",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"tenant_filter_invalid",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"tenant_has_no_capabilities",envelope:"http_envelope",httpStatus:409,retryable:false},{wireCode:"tenant_resource_not_found",envelope:"http_envelope",httpStatus:404,retryable:false},{wireCode:"tenant_surface_not_enabled",envelope:"http_envelope",httpStatus:409,retryable:false},{wireCode:"timeout",envelope:"sse_frame",httpStatus:200,retryable:true},{wireCode:"token_invalid",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"unavailable",envelope:"sse_frame",httpStatus:200,retryable:true},{wireCode:"unavailable",envelope:"http_envelope",httpStatus:503,retryable:true},{wireCode:"unrestrictedKeyRequired",envelope:"http_envelope",httpStatus:403,retryable:false},{wireCode:"unsupported_grant_type",envelope:"oauth_error",httpStatus:400,retryable:false},{wireCode:"unsupported_response_type",envelope:"oauth_error",httpStatus:302,retryable:false},{wireCode:"user_ref_invalid",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"verify_mint_rate_limited",envelope:"http_envelope",httpStatus:429,retryable:true},{wireCode:"verify_mint_refused",envelope:"http_envelope",httpStatus:403,retryable:false},{wireCode:"verify_mint_unavailable",envelope:"http_envelope",httpStatus:503,retryable:true},{wireCode:"verify_user_ref_invalid",envelope:"http_envelope",httpStatus:422,retryable:false},{wireCode:"web_push_unavailable",envelope:"http_envelope",httpStatus:503,retryable:true},{wireCode:"webhook_endpoint_update_empty",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"webhook_endpoint_update_invalid",envelope:"http_envelope",httpStatus:400,retryable:false},{wireCode:"webhook_url_rejected",envelope:"http_envelope",httpStatus:400,retryable:false}],CONTRACT_RETRYABILITY=/* @__PURE__ */Object.freeze(RETRYABILITY_ROWS.map(row2=>/* @__PURE__ */Object.freeze(row2)));/* @__PURE__ */Object.freeze(CONTRACT_RETRYABILITY.map(row2=>row2.wireCode));var NORMALIZED_FOLD=/* @__PURE__ */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",session_revoked:"authExpired",accessDenied:"accessDenied",invalidRequest:"sdkUpdateRequired",authRejected:"authRejected",rateLimited:"rateLimited",insufficientCapability:"accessDenied",unrestrictedKeyRequired:"accessDenied",user_ref_invalid:"validationFailed",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",linked_account_read_only:"conflict",catalog_empty_refused:"conflict",catalog_shrink_refused:"conflict",endpoint_not_allowed:"validationFailed",event_id_invalid:"validationFailed",inbox_cursor_invalid:"validationFailed",item_id_invalid:"validationFailed",open_url_not_allowed:"validationFailed",read_target_invalid:"validationFailed",subscription_keys_invalid:"validationFailed",web_push_unavailable:"serviceUnavailable"}),CONTRACT_ERROR_ROWS=/* @__PURE__ */Object.freeze(CONTRACT_RETRYABILITY.map(generated=>/* @__PURE__ */Object.freeze({wireCode:generated.wireCode,envelope:generated.envelope,retryable:generated.retryable,normalized:NORMALIZED_FOLD[generated.wireCode]}))),BY_KEY=new Map(CONTRACT_ERROR_ROWS.map(r=>[r.envelope+r.wireCode.toUpperCase(),r])),ENVELOPE_LOOKUP_ORDER=/* @__PURE__ */Object.freeze(["http_envelope",...[...new Set(CONTRACT_ERROR_ROWS.map(r=>r.envelope))].filter(e=>e!=="http_envelope").sort()]);function contractErrorFor(wireCode,envelope){if(typeof wireCode!="string")return;let key=wireCode.trim().toUpperCase();if(key.length!==0)for(let candidate of[envelope??"http_envelope",...ENVELOPE_LOOKUP_ORDER]){let row2=BY_KEY.get(candidate+key);if(row2)return row2}}var CATEGORY_OF=/* @__PURE__ */Object.freeze({authExpired:"authentication",authRejected:"authentication",sessionRequired:"authentication",identitySignatureRequired:"authentication",accessDenied:"authorization",paymentRequired:"entitlement",quotaExceeded:"rateLimit",rateLimited:"rateLimit",validationFailed:"invalidRequest",sdkUpdateRequired:"invalidRequest",runtimeDisposed:"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 categoryFor(code){return CATEGORY_OF[code]}function fromWire(wire){let contractRow=contractErrorFor(wire);if(contractRow)return contractRow.normalized;let upper=(wire??"").trim().toUpperCase(),canonical=upper.replace(/[^A-Z0-9]/g,"");if(canonical==="AUTHREJECTED")return"authRejected";if(upper.startsWith("AUTH"))return"authExpired";switch(canonical){case"DAILYQUOTAEXCEEDED":case"QUOTAEXCEEDED":return"quotaExceeded";case"RATELIMITED":case"TOOMANYREQUESTS":case"TELEVETRATELIMITED":return"rateLimited";case"IDEMPOTENCYKEYCONFLICT":case"IDEMPOTENCYCONFLICT":return"idempotencyConflict";case"ACCESSDENIED":case"FORBIDDEN":return"accessDenied";case"IDENTITYSIGNATUREREQUIRED":return"identitySignatureRequired";case"RUNTIMEDISPOSED":return"runtimeDisposed";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"}}var AUTO_RETRYABLE_CODES=/* @__PURE__ */new Set(["streamTimeout","rateLimited","internalError","upstreamLlmTimeout","streamIncomplete"]);function isAutoRetryable(code){return AUTO_RETRYABLE_CODES.has(code)}var RETRYABLE_CONTRACT_CODES=/* @__PURE__ */new Set(["serviceUnavailable","conflict","idempotencyInFlight"]);function isRetryableCode(code){return isAutoRetryable(code)||RETRYABLE_CONTRACT_CODES.has(code)}var BACKOFF_BASE_MS=500,BACKOFF_CAP_MS=8e3,MAX_RETRY_ATTEMPTS=4;function backoffDelayMs(attempt,rng=Math.random){let bounded=Math.max(0,attempt),ceiling=Math.min(BACKOFF_BASE_MS*2**bounded,BACKOFF_CAP_MS);return Math.floor(rng()*ceiling)}var ACCESS_DENIED_COPY="This feature isn't available on your account right now.",VALIDATION_FAILED_COPY="Something in that request was not right. Check the details and try again.",USER_FACING_COPY=/* @__PURE__ */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:ACCESS_DENIED_COPY,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:VALIDATION_FAILED_COPY,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.",identitySignatureRequired:ACCESS_DENIED_COPY,runtimeDisposed:VALIDATION_FAILED_COPY,unknown:"Something went wrong. Please try again."}),SESSION_REVOKED_COPY="This session has ended. Please sign in again.",LINKED_ACCOUNT_READ_ONLY="linked_account_read_only";function displayFor(code,wireCode,reasonCode){return code==="conflict"&&reasonCode===LINKED_ACCOUNT_READ_ONLY?ACCESS_DENIED_COPY:(code==="authRejected"||code==="authExpired")&&typeof wireCode=="string"&&wireCode.trim().toLowerCase()==="session_revoked"?SESSION_REVOKED_COPY:userFacingError(code)}function userFacingError(code){return USER_FACING_COPY[code]}function defineHidden(target,key,value){Object.defineProperty(target,key,{value:value,enumerable:false,writable:false,configurable:false})}var REASON_CODE_SHAPE=/^[a-z][a-z0-9_]{0,63}$/;function makeEverfurError(code,opts){let row2=contractErrorFor(opts?.wireCode,opts?.wireEnvelope),linkedReadOnly=code==="conflict"&&opts?.reasonCode===LINKED_ACCOUNT_READ_ONLY,error={code:code,category:categoryFor(code),retryable:opts?.retryable??(linkedReadOnly?false:isRetryableCode(code)),displayMessage:displayFor(code,opts?.wireCode,linkedReadOnly?LINKED_ACCOUNT_READ_ONLY:null)};opts?.httpStatus!==void 0&&(error.httpStatus=opts.httpStatus),opts?.requestId&&(error.requestId=opts.requestId),typeof opts?.reasonCode=="string"&&REASON_CODE_SHAPE.test(opts.reasonCode)&&(error.reasonCode=opts.reasonCode);let wait=opts?.retryAfterSeconds;if(typeof wait=="number"&&Number.isFinite(wait)&&wait>=0&&(error.retryAfterSeconds=Math.round(wait)),row2);return opts?.wireMessage&&defineHidden(error,"wireMessage",opts.wireMessage),opts?.raw!==void 0&&opts.raw!==null&&defineHidden(error,"raw",opts.raw),/* @__PURE__ */Object.freeze(error)}function ok(value,warning){/* @__PURE__ */
|
|
99
6
|
return Object.freeze({ok:true,value:value})}function err(error){/* @__PURE__ */
|
|
100
7
|
return Object.freeze({ok:false,error:error})}var EverfurConfigError=class _EverfurConfigError extends Error{constructor(kind,message){super(message),this.name="EverfurConfigError",this.kind=kind,Object.setPrototypeOf(this,_EverfurConfigError.prototype)}};function mintFailedError(cause,refusal){let message=cause instanceof Error?cause.message:typeof cause=="string"?cause:null;return makeEverfurError("authRejected",{retryable:false,...refusal?.wireCode?{wireCode:refusal.wireCode}:{},...refusal?.requestId?{requestId:refusal.requestId}:{},...message?{wireMessage:message}:{},...cause!=null?{raw:cause}:{}})}function authHeaders(auth){let headers={};return auth.mode==="personalized"?headers.authorization=`Bearer ${auth.token}`:headers["x-everfur-partner-key"]=auth.publishableKey,auth.userRef&&(headers["x-everfur-user-ref"]=auth.userRef),auth.sessionId&&(headers["x-everfur-session-id"]=auth.sessionId),headers}function withAuthHeaders(req,auth){return{...req,headers:{...stripAuthHeaders(req.headers),...authHeaders(auth)}}}function stripAuthHeaders(headers){if(!headers)return{};let out={};for(let[key,value]of Object.entries(headers)){let lower=key.toLowerCase();lower==="authorization"||lower==="x-everfur-partner-key"||(out[key]=value)}return out}async function authedSend(req,ctx){if(ctx.mode==="anonymous")return ctx.transport.request(withAuthHeaders(req,{mode:"anonymous",publishableKey:ctx.publishableKey,userRef:ctx.userRef,...ctx.sessionId?{sessionId:ctx.sessionId}:{}}));let token;try{token=await ctx.identity.currentToken()}catch(cause){return ctx.identity.reportRejected?.(),err(mintFailedError(cause))}let first=await ctx.transport.request(withAuthHeaders(req,{mode:"personalized",token:token,userRef:ctx.userRef,...ctx.sessionId?{sessionId:ctx.sessionId}:{}}));if(first.ok||first.error.httpStatus!==401)return first;let refreshed;try{refreshed=await ctx.identity.currentToken({forceRefresh:!0})}catch(cause){return ctx.identity.reportRejected?.(),err(mintFailedError(cause,{wireCode:wireCodeOf(first.error.raw),requestId:first.error.requestId}))}let retry=await ctx.transport.request(withAuthHeaders(req,{mode:"personalized",token:refreshed,userRef:ctx.userRef,...ctx.sessionId?{sessionId:ctx.sessionId}:{}}));return!retry.ok&&retry.error.httpStatus===401?(ctx.identity.reportRejected?.(),err(refusedAfterRemintError(retry.error))):retry}function refusedAfterRemintError(refusal){let raw=refusal.raw,wireCode=wireCodeOf(raw);return makeEverfurError("authRejected",{retryable:false,...refusal.httpStatus!==void 0?{httpStatus:refusal.httpStatus}:{},...refusal.requestId?{requestId:refusal.requestId}:{},...wireCode?{wireCode:wireCode}:{},...refusal.reasonCode?{reasonCode:refusal.reasonCode}:{},...refusal.wireMessage?{wireMessage:refusal.wireMessage}:{},...raw!=null?{raw:raw}:{}})}function wireCodeOf(body){if(typeof body!="object"||body===null)return null;let b=body,code=(typeof b.error=="object"&&b.error!==null?b.error.code:void 0)??b.code;return typeof code=="string"&&code.length>0?code:null}function parseUrl(raw,base){let Url=globalThis.URL;if(typeof Url=="function"){let url;try{url=base===void 0?new Url(raw):new Url(raw,base)}catch{return null}try{if(url.protocol)return url}catch{}}return parseByPattern(raw)}var WHOLE_URL=/^([a-z][a-z0-9+.-]*):\/\/(?:([^:@/?#]*)(?::([^@/?#]*))?@)?(\[[0-9a-f:.]+\]|[\w.~-]+)(?::(\d*))?(\/[^?#]*)?(\?[^#]*)?(#.*)?$/i,REWRITTEN_BY_STANDARD_PARSER=/[\s\u0000-\u001f\u007f\\]/,DEFAULT_PORTS={"http:":"80","https:":"443"};function parseByPattern(raw,base){let input=raw.trim();let match=REWRITTEN_BY_STANDARD_PARSER.test(input)?null:WHOLE_URL.exec(input);if(match===null)return null;let[,scheme="",username="",password="",host="",portText="",path="",query="",fragment=""]=match,protocol=`${scheme.toLowerCase()}:`,portNumber=Number(portText);if(portNumber>65535)return null;let port=portText===""||String(portNumber)===DEFAULT_PORTS[protocol]?"":String(portNumber),special=DEFAULT_PORTS[protocol]!==void 0,hostPort=host.toLowerCase()+(port&&`:${port}`),pathname=path||(special?"/":""),credentials=username||password?`${username}${password&&`:${password}`}@`:"";return{href:`${protocol}//${credentials}${hostPort}${pathname}${query}${fragment}`,protocol:protocol,username:username,password:password,hostname:host.toLowerCase(),port:port,origin:special?`${protocol}//${hostPort}`:"null",pathname:pathname,search:query==="?"?"":query,hash:fragment==="#"?"":fragment}}function networkError(cause){return makeEverfurError("internalError",{retryable:true,wireMessage:describeCause(cause)})}function describeCause(cause){return cause instanceof Error?cause.message:typeof cause=="string"?cause:"network request failed"}var FUNNEL_UNARY_TIMEOUT_MS=3e4,RETRY_OVERRIDE_MAX_MS=BACKOFF_CAP_MS*2,IDEMPOTENCY_HEADER="idempotency-key",MUTATING_METHODS=/* @__PURE__ */new Set(["POST","PUT","PATCH","DELETE"]),NOOP_OBSERVER=/* @__PURE__ */Object.freeze({onEvent(){}}),defaultFunnelTimers=/* @__PURE__ */Object.freeze({setTimeout:(handler,ms)=>setTimeout(handler,ms),clearTimeout:handle=>clearTimeout(handle),now:()=>Date.now()});function seededIdempotencyKey(seed){let safe=seed.trim().replace(/[^A-Za-z0-9_.:-]/g,"-");return safe.length===0?null:`efs_${safe}`.slice(0,128)}function createRequestFunnel(deps){let observer=deps.observer??NOOP_OBSERVER,timers=deps.timers??defaultFunnelTimers,rng=deps.rng??Math.random,sleep=deps.sleep??((ms,signal)=>delayAbortable(ms,timers,signal)),ceiling=deps.maxAttempts??MAX_RETRY_ATTEMPTS,timeoutMs=deps.unaryTimeoutMs??FUNNEL_UNARY_TIMEOUT_MS,mintKey=deps.newIdempotencyKey??defaultIdempotencyKeyFactory(),emit=event=>{try{observer.onEvent(event)}catch{}};async function send(call,req,opts){let perCallMaxAttempts=opts?.maxAttempts,maxAttempts=Math.max(1,perCallMaxAttempts??ceiling),idempotent=opts?.idempotent??MUTATING_METHODS.has(req.method),seeded=opts?.idempotencyKey===void 0?null:seededIdempotencyKey(opts.idempotencyKey),idempotencyKey=idempotent?seeded??mintKey():null,base=assembleHeaders(req,idempotencyKey),attempt=0;for(;;){let stamp2=extra=>/* @__PURE__ */Object.freeze({call:call,method:req.method,path:req.path,attempt:attempt,...idempotencyKey?{idempotencyKey:idempotencyKey}:{},...extra});emit(stamp2({phase:"attempt"}));let deadline=boundedSignal(timeoutMs,timers),merged=mergeSignals(deadline.signal,req.signal),settled;try{settled=await authedSend({...base,signal:merged.signal},deps.auth)}catch(cause){settled=err(networkError(cause))}finally{merged.dispose(),deadline.cancel()}if(settled.ok)return emit(stamp2({phase:"settled",ok:true,reason:"ok"})),settled;let error=settled.error,decision=decideRetry(error,attempt,{maxAttempts:maxAttempts,rng:rng,now:timers.now(),aborted:req.signal?.aborted===true,...perCallMaxAttempts!==void 0?{perCallMaxAttempts:perCallMaxAttempts}:{},...deps.errorPolicy!==void 0?{policy:deps.errorPolicy}:{}}),settledEvent={ok:false,code:error.code,reason:decision.reason,...error.httpStatus!==void 0?{httpStatus:error.httpStatus}:{},...error.requestId!==void 0?{requestId:error.requestId}:{}};if(!decision.retry)return emit(stamp2({phase:"settled",...settledEvent})),err(error);if(emit(stamp2({phase:"retry",...settledEvent,delayMs:decision.delayMs})),await sleep(decision.delayMs,req.signal),req.signal?.aborted===true)return emit(stamp2({phase:"settled",...settledEvent,reason:"aborted"})),err(error);attempt+=1}}async function authorize(req){return withAuthHeaders(req,await resolveDeviceAuth(deps.auth))}async function*stream(call,req,signal){emit(
|
|
101
8
|
/* @__PURE__ */Object.freeze({call:call,phase:"stream.open",method:req.method,path:req.path,attempt:0}));try{yield*deps.auth.transport.stream(req,signal)}catch{yield errorFrame({code:"internal_error",retryable:true,wireMessage:null,synthesized:true,lastEventId:null})}}/* @__PURE__ */
|
|
@@ -201,18 +108,19 @@ return jsxRuntime.jsxs(reactNative.View,{style:styles2.root,testID:testID,childr
|
|
|
201
108
|
/* @__PURE__ */jsxRuntime.jsx(reactNative.ScrollView,{style:styles2.gridScroll,contentContainerStyle:styles2.groups,showsVerticalScrollIndicator:false,children:groups(times,periodLabels).map(group=>/* @__PURE__ */jsxRuntime.jsxs(reactNative.View,{style:styles2.group,children:[group.label?/* @__PURE__ */jsxRuntime.jsx(Text,{tier:"compact",style:styles2.period,accessibilityRole:"header",testID:`televet-slot-period-${group.key}`,children:group.label}):null,
|
|
202
109
|
/* @__PURE__ */jsxRuntime.jsx(reactNative.View,{style:styles2.grid,children:group.slots.map(slot=>{let index=times.indexOf(slot),busy=busySlotId===slot.slotId,blocked=busySlotId!==null,picked=selectedSlot?.slotId===slot.slotId,chipZone=mixedZones?zones[index]??"":"";/* @__PURE__ */
|
|
203
110
|
return jsxRuntime.jsxs(reactNative.Pressable,{onPress:()=>onPick(slot),disabled:blocked,accessibilityRole:"button",accessibilityLabel:[formatClock(slot.startsAt),chipZone].filter(part=>part.length>0).join(" "),accessibilityState:{disabled:blocked,busy:busy,selected:picked},testID:`${rowTestIdPrefix}-${slot.slotId}`,style:({pressed:pressed})=>[styles2.chip,picked?styles2.chipPicked:null,busy?styles2.chipBusy:null,blocked&&!busy?styles2.chipDisabled:null,pressed&&!theme.motion.reducedMotion?styles2.chipPressed:null],children:[
|
|
204
|
-
/* @__PURE__ */jsxRuntime.jsx(Text,{tier:"compact",style:[styles2.chipLabel,picked?styles2.chipLabelPicked:null,busy?styles2.chipLabelBusy:null],children:formatClock(slot.startsAt)}),chipZone.length>0?/* @__PURE__ */jsxRuntime.jsx(Text,{tier:"compact",style:[styles2.chipZone,picked?styles2.chipLabelPicked:null,busy?styles2.chipLabelBusy:null],testID:`${rowTestIdPrefix}-${slot.slotId}-zone`,children:chipZone}):null]},slot.slotId)})})]},group.key))})]})}function groups(times,labels){return labels?["morning","afternoon","evening"].map(period=>({key:period,label:labels[period],slots:times.filter(s=>televetDayPeriod(s.startsAt)===period)})).filter(group=>group.slots.length>0):[{key:"all",label:null,slots:times}]}function firstOffered(days,keys){for(let key of keys)if(key!==null&&days.some(day=>day.key===key))return key;return null}function makeStyles6(theme){let{color:color,space:space,radius:radius,type:type}=theme,{size:size,lineHeight:lineHeight}=type,look=televetLook(theme),chip=theme.slots.chip,chipText=slotText(chip);return reactNative.StyleSheet.create({root:{flex:1,minHeight:0},groups:{gap:space.lg,paddingBottom:space.xl},group:{gap:space.sm},period:{...face(theme,"monoBold"),color:look.muted,fontSize:12,lineHeight:16,letterSpacing:.96,textTransform:"uppercase"},gridScroll:{flex:1},zone:{textAlign:"center",...face(theme,"mono"),color:color.text.muted,fontSize:size.tiny,lineHeight:size.tiny*lineHeight.normal,letterSpacing:.4,paddingVertical:space.md},grid:{flexDirection:"row",flexWrap:"wrap",gap:space.sm},chip:{minWidth:96,flexGrow:1,flexBasis:"auto",minHeight:44,borderRadius:radius.pill,borderWidth:1.5,borderColor:look.line,backgroundColor:look.surface,alignItems:"center",justifyContent:"center",paddingHorizontal:space.md,...slotBox(chip,1.5)},chipPicked:{borderColor:look.ink,backgroundColor:look.pink},chipLabelPicked:{color:look.onPink},chipPressed:{transform:[{scale:.95}]},chipBusy:{backgroundColor:color.primary,borderColor:color.primary},chipDisabled:{opacity:.45},chipLabel:{...face(theme,"bold"),color:look.ink,fontSize:size.bodyTight,lineHeight:size.bodyTight*lineHeight.snug,fontVariant:["tabular-nums"],...chipText},chipLabelBusy:{color:color.onPrimary},chipZone:{...face(theme,"mono"),color:color.text.muted,fontSize:size.tiny,lineHeight:size.tiny*lineHeight.normal,letterSpacing:.4,...chipText}})}function TelevetSummaryRow({label:label,value:value,last:last=false,action:action,testID:testID}){let theme=useEverfurTheme(),styles2=react.useMemo(()=>makeStyles7(theme),[theme]);/* @__PURE__ */
|
|
111
|
+
/* @__PURE__ */jsxRuntime.jsx(Text,{tier:"compact",style:[styles2.chipLabel,picked?styles2.chipLabelPicked:null,busy?styles2.chipLabelBusy:null],children:formatClock(slot.startsAt)}),chipZone.length>0?/* @__PURE__ */jsxRuntime.jsx(Text,{tier:"compact",style:[styles2.chipZone,picked?styles2.chipLabelPicked:null,busy?styles2.chipLabelBusy:null],testID:`${rowTestIdPrefix}-${slot.slotId}-zone`,children:chipZone}):null]},slot.slotId)})})]},group.key))})]})}function groups(times,labels){return labels?["morning","afternoon","evening"].map(period=>({key:period,label:labels[period],slots:times.filter(s=>televetDayPeriod(s.startsAt)===period)})).filter(group=>group.slots.length>0):[{key:"all",label:null,slots:times}]}function firstOffered(days,keys){for(let key of keys)if(key!==null&&days.some(day=>day.key===key))return key;return null}function makeStyles6(theme){let{color:color,space:space,radius:radius,type:type}=theme,{size:size,lineHeight:lineHeight}=type,look=televetLook(theme),chip=theme.slots.chip,chipText=slotText(chip);return reactNative.StyleSheet.create({root:{flex:1,minHeight:0},groups:{gap:space.lg,paddingBottom:space.xl},group:{gap:space.sm},period:{...face(theme,"monoBold"),color:look.muted,fontSize:12,lineHeight:16,letterSpacing:.96,textTransform:"uppercase"},gridScroll:{flex:1},zone:{textAlign:"center",...face(theme,"mono"),color:color.text.muted,fontSize:size.tiny,lineHeight:size.tiny*lineHeight.normal,letterSpacing:.4,paddingVertical:space.md},grid:{flexDirection:"row",flexWrap:"wrap",gap:space.sm},chip:{minWidth:96,flexGrow:1,flexBasis:"auto",minHeight:44,borderRadius:radius.pill,borderWidth:1.5,borderColor:look.line,backgroundColor:look.surface,alignItems:"center",justifyContent:"center",paddingHorizontal:space.md,...slotBox(chip,1.5)},chipPicked:{borderColor:look.ink,backgroundColor:look.pink},chipLabelPicked:{color:look.onPink},chipPressed:{transform:[{scale:.95}]},chipBusy:{backgroundColor:color.primary,borderColor:color.primary},chipDisabled:{opacity:.45},chipLabel:{...face(theme,"bold"),color:look.ink,fontSize:size.bodyTight,lineHeight:size.bodyTight*lineHeight.snug,fontVariant:["tabular-nums"],...chipText},chipLabelBusy:{color:color.onPrimary},chipZone:{...face(theme,"mono"),color:color.text.muted,fontSize:size.tiny,lineHeight:size.tiny*lineHeight.normal,letterSpacing:.4,...chipText}})}function TelevetSummaryRow({label:label,value:value,last:last=false,action:action,note:note,testID:testID}){let theme=useEverfurTheme(),styles2=react.useMemo(()=>makeStyles7(theme),[theme]);/* @__PURE__ */
|
|
205
112
|
return jsxRuntime.jsxs(reactNative.View,{style:[styles2.row,last?styles2.rowLast:null],testID:testID,children:[
|
|
206
|
-
/* @__PURE__ */jsxRuntime.jsx(Text,{style:styles2.rowLabel,children:label}),
|
|
207
|
-
/* @__PURE__ */jsxRuntime.jsx(Text,{style:styles2.rowValue,children:value}),
|
|
113
|
+
/* @__PURE__ */jsxRuntime.jsx(Text,{style:styles2.rowLabel,children:label}),note?/* @__PURE__ */jsxRuntime.jsxs(reactNative.View,{style:styles2.rowValueStack,children:[
|
|
114
|
+
/* @__PURE__ */jsxRuntime.jsx(Text,{style:[styles2.rowValue,styles2.rowValueStacked],children:value}),
|
|
115
|
+
/* @__PURE__ */jsxRuntime.jsx(Text,{style:styles2.rowNote,testID:testID?`${testID}-note`:void 0,children:note})]}):/* @__PURE__ */jsxRuntime.jsx(Text,{style:styles2.rowValue,children:value}),action??null]})}function TelevetConsentCheckbox({label:label,checked:checked,onToggle:onToggle,testID:testID}){let theme=useEverfurTheme(),styles2=react.useMemo(()=>makeStyles7(theme),[theme]);/* @__PURE__ */
|
|
208
116
|
return jsxRuntime.jsxs(reactNative.Pressable,{onPress:()=>onToggle(!checked),accessibilityRole:"checkbox",accessibilityLabel:label,accessibilityState:{checked:checked},testID:testID,style:styles2.consent,children:[
|
|
209
117
|
/* @__PURE__ */jsxRuntime.jsx(reactNative.View,{style:[styles2.box,checked?styles2.boxChecked:null],children:checked?/* @__PURE__ */jsxRuntime.jsx(Text,{tier:"badge",style:styles2.tick,children:TICK}):null}),
|
|
210
118
|
/* @__PURE__ */jsxRuntime.jsx(Text,{style:styles2.consentLabel,children:label})]})}var TICK="✓";function TelevetSummaryCard({children:children,testID:testID}){let theme=useEverfurTheme(),styles2=react.useMemo(()=>makeStyles7(theme),[theme]);/* @__PURE__ */
|
|
211
|
-
return jsxRuntime.jsx(reactNative.View,{style:styles2.card,testID:testID,children:children})}function makeStyles7(theme){let{color:color,space:space,radius:radius,type:type}=theme,{size:size,lineHeight:lineHeight}=type,cardText=slotText(theme.slots.card);return reactNative.StyleSheet.create({card:{borderRadius:radius.lg,borderWidth:1,borderColor:color.borderRingCream,backgroundColor:color.surface,paddingHorizontal:space.lg,...slotBox(theme.slots.card,1)},row:{flexDirection:"row",alignItems:"center",gap:space.md,minHeight:48,paddingVertical:space.md,borderBottomWidth:1,borderBottomColor:color.borderRingCream},rowLast:{borderBottomWidth:0},rowLabel:{width:64,...face(theme,"regular"),color:color.text.muted,fontSize:size.bodyTight,lineHeight:size.bodyTight*lineHeight.normal,...cardText},rowValue:{flex:1,...face(theme,"bold"),color:color.brandInk,fontSize:size.bodyTight,lineHeight:size.bodyTight*lineHeight.normal,...cardText},consent:{flexDirection:"row",alignItems:"flex-start",gap:space.md,minHeight:MIN_TOUCH_TARGET,paddingVertical:14,paddingHorizontal:space.lg,borderRadius:radius.sm,backgroundColor:color.surfaceSubtle},box:{width:22,height:22,borderRadius:radius.xs,borderWidth:1.5,borderColor:color.brandInk,backgroundColor:color.surface,alignItems:"center",justifyContent:"center"},boxChecked:{backgroundColor:color.primary,borderColor:color.primary},tick:{...face(theme,"bold"),color:color.onPrimary,fontSize:size.caption,lineHeight:size.caption,includeFontPadding:false},consentLabel:{flex:1,...face(theme,"regular"),color:color.text.primary,fontSize:size.bodyTight,lineHeight:size.bodyTight*lineHeight.relaxed}})}function ReviewStep({when:when,onChangeWhen:onChangeWhen,stateName:stateName,about:about,lengthMinutes:lengthMinutes,clinician:clinician,petName:petName,reason:reason,shareRecords:shareRecords,onToggleShare:onToggleShare,stateCode:stateCode,stateAttested:stateAttested,onToggleStateAttest:onToggleStateAttest,cancellationTerms:cancellationTerms,termsAttested:termsAttested,onToggleTermsAttest:onToggleTermsAttest,canConfirm:ready,busy:busy,failure:failure2,onConfirm:onConfirm,emergency:emergency,onAcknowledgeEmergency:onAcknowledgeEmergency,onSeeOtherVets:onSeeOtherVets,mediaShortfall:mediaShortfall=NO_MEDIA_SHORTFALL,primaryVet:primaryVet,onFindEmergencyVet:onFindEmergencyVet}){let styles2=useBookingStyles(),theme=useEverfurTheme(),local=react.useMemo(()=>makeLocalStyles(theme),[theme]),place=stateName??stateCode??"",attestLabel=petName?fill(TELEVET_BOOKING_COPY.whereAttestTemplate,{pet:petName,state:place}):fill(TELEVET_BOOKING_COPY.stateAttestTemplate,{state:place}),aboutLine=about??reason,emergencyLede=TELEVET_BOOKING_COPY.emergency.lede;/* @__PURE__ */
|
|
119
|
+
return jsxRuntime.jsx(reactNative.View,{style:styles2.card,testID:testID,children:children})}function makeStyles7(theme){let{color:color,space:space,radius:radius,type:type}=theme,{size:size,lineHeight:lineHeight}=type,cardText=slotText(theme.slots.card);return reactNative.StyleSheet.create({card:{borderRadius:radius.lg,borderWidth:1,borderColor:color.borderRingCream,backgroundColor:color.surface,paddingHorizontal:space.lg,...slotBox(theme.slots.card,1)},row:{flexDirection:"row",alignItems:"center",gap:space.md,minHeight:48,paddingVertical:space.md,borderBottomWidth:1,borderBottomColor:color.borderRingCream},rowLast:{borderBottomWidth:0},rowLabel:{width:64,...face(theme,"regular"),color:color.text.muted,fontSize:size.bodyTight,lineHeight:size.bodyTight*lineHeight.normal,...cardText},rowValue:{flex:1,...face(theme,"bold"),color:color.brandInk,fontSize:size.bodyTight,lineHeight:size.bodyTight*lineHeight.normal,...cardText},rowValueStack:{flex:1,gap:2},rowValueStacked:{flex:0},rowNote:{...face(theme,"regular"),color:color.text.muted,fontSize:size.caption,lineHeight:size.caption*lineHeight.normal,...cardText},consent:{flexDirection:"row",alignItems:"flex-start",gap:space.md,minHeight:MIN_TOUCH_TARGET,paddingVertical:14,paddingHorizontal:space.lg,borderRadius:radius.sm,backgroundColor:color.surfaceSubtle},box:{width:22,height:22,borderRadius:radius.xs,borderWidth:1.5,borderColor:color.brandInk,backgroundColor:color.surface,alignItems:"center",justifyContent:"center"},boxChecked:{backgroundColor:color.primary,borderColor:color.primary},tick:{...face(theme,"bold"),color:color.onPrimary,fontSize:size.caption,lineHeight:size.caption,includeFontPadding:false},consentLabel:{flex:1,...face(theme,"regular"),color:color.text.primary,fontSize:size.bodyTight,lineHeight:size.bodyTight*lineHeight.relaxed}})}function ReviewStep({when:when,onChangeWhen:onChangeWhen,stateName:stateName,about:about,lengthMinutes:lengthMinutes,clinician:clinician,clinicianRole:clinicianRole,petName:petName,reason:reason,shareRecords:shareRecords,onToggleShare:onToggleShare,stateCode:stateCode,stateAttested:stateAttested,onToggleStateAttest:onToggleStateAttest,cancellationTerms:cancellationTerms,termsAttested:termsAttested,onToggleTermsAttest:onToggleTermsAttest,canConfirm:ready,busy:busy,failure:failure2,onConfirm:onConfirm,emergency:emergency,onAcknowledgeEmergency:onAcknowledgeEmergency,onSeeOtherVets:onSeeOtherVets,mediaShortfall:mediaShortfall=NO_MEDIA_SHORTFALL,primaryVet:primaryVet,onFindEmergencyVet:onFindEmergencyVet}){let styles2=useBookingStyles(),theme=useEverfurTheme(),local=react.useMemo(()=>makeLocalStyles(theme),[theme]),place=stateName??stateCode??"",attestLabel=petName?fill(TELEVET_BOOKING_COPY.whereAttestTemplate,{pet:petName,state:place}):fill(TELEVET_BOOKING_COPY.stateAttestTemplate,{state:place}),aboutLine=about??reason,emergencyLede=TELEVET_BOOKING_COPY.emergency.lede;/* @__PURE__ */
|
|
212
120
|
return jsxRuntime.jsxs(reactNative.View,{style:styles2.scrollRoot,testID:"televet-booking-review",children:[
|
|
213
121
|
/* @__PURE__ */jsxRuntime.jsxs(reactNative.ScrollView,{style:styles2.scrollBody,contentContainerStyle:local.body,keyboardShouldPersistTaps:"handled",showsVerticalScrollIndicator:false,testID:"televet-booking-review-scroll",children:[
|
|
214
122
|
/* @__PURE__ */jsxRuntime.jsx(Text,{tier:"heading",style:styles2.stepTitle,accessibilityRole:"header",children:TELEVET_BOOKING_COPY.reviewHeading}),
|
|
215
|
-
/* @__PURE__ */jsxRuntime.jsxs(TelevetSummaryCard,{testID:"televet-review-summary",children:[petName?/* @__PURE__ */jsxRuntime.jsx(TelevetSummaryRow,{label:TELEVET_BOOKING_COPY.summaryPet,value:petName,testID:"televet-review-row-pet"}):null,clinician?/* @__PURE__ */jsxRuntime.jsx(TelevetSummaryRow,{label:TELEVET_BOOKING_COPY.summaryVet,value:clinician,testID:"televet-review-row-vet"}):null,
|
|
123
|
+
/* @__PURE__ */jsxRuntime.jsxs(TelevetSummaryCard,{testID:"televet-review-summary",children:[petName?/* @__PURE__ */jsxRuntime.jsx(TelevetSummaryRow,{label:TELEVET_BOOKING_COPY.summaryPet,value:petName,testID:"televet-review-row-pet"}):null,clinician?/* @__PURE__ */jsxRuntime.jsx(TelevetSummaryRow,{label:TELEVET_BOOKING_COPY.summaryVet,value:clinicianRole==="vet_tech"?`${clinician} · ${TELEVET_BOOKING_COPY.vetTechRoleLabel}`:clinician,note:clinicianRole==="vet_tech"?TELEVET_BOOKING_COPY.vetTechNoRxLine:null,testID:"televet-review-row-vet"}):null,
|
|
216
124
|
/* @__PURE__ */jsxRuntime.jsx(TelevetSummaryRow,{label:TELEVET_BOOKING_COPY.summaryWhen,value:when,testID:"televet-review-row-when",action:onChangeWhen?/* @__PURE__ */jsxRuntime.jsx(TelevetButton,{label:TELEVET_BOOKING_COPY.changeCta,kind:"quiet",fullWidth:false,onPress:onChangeWhen,testID:"televet-review-change-when"}):null}),
|
|
217
125
|
/* @__PURE__ */jsxRuntime.jsx(TelevetSummaryRow,{label:TELEVET_BOOKING_COPY.summaryLength,value:fill(TELEVET_BOOKING_COPY.summaryLengthTemplate,{n:String(lengthMinutes)}),testID:"televet-review-row-length"}),place?/* @__PURE__ */jsxRuntime.jsx(TelevetSummaryRow,{label:TELEVET_BOOKING_COPY.summaryWhere,value:place,testID:"televet-review-row-where"}):null,aboutLine?/* @__PURE__ */jsxRuntime.jsx(TelevetSummaryRow,{label:TELEVET_BOOKING_COPY.summaryReason,value:aboutLine,last:true,testID:"televet-review-row-reason"}):null]}),stateCode?/* @__PURE__ */jsxRuntime.jsx(TelevetConsentCheckbox,{label:attestLabel,checked:stateAttested,onToggle:onToggleStateAttest,testID:"televet-review-state-attest"}):null,cancellationTerms?/* @__PURE__ */jsxRuntime.jsx(TelevetConsentCheckbox,{label:cancellationTerms,checked:termsAttested,onToggle:onToggleTermsAttest,testID:"televet-review-terms-attest"}):null,
|
|
218
126
|
/* @__PURE__ */jsxRuntime.jsx(TelevetConsentCheckbox,{label:TELEVET_BOOKING_COPY.shareRecordsOff,checked:shareRecords,onToggle:onToggleShare,testID:"televet-review-share-records"}),
|
|
@@ -234,10 +142,10 @@ return jsxRuntime.jsxs(reactNative.Pressable,{onPress:onPress,accessibilityRole:
|
|
|
234
142
|
/* @__PURE__ */jsxRuntime.jsx(reactNative.View,{style:local.choices,accessibilityRole:"radiogroup",testID:"televet-pets",children:pets.map(pet=>/* @__PURE__ */jsxRuntime.jsx(TelevetChoiceRow,{title:pet.name??"",meta:formatTelevetPetMetaLine(pet),selected:selectedId===pet.petRef,onPress:()=>onSelect(pet.petRef),testID:`televet-pet-${pet.petRef}`,leading:/* @__PURE__ */jsxRuntime.jsx(reactNative.View,{style:local.petDisc,children:/* @__PURE__ */jsxRuntime.jsx(Text,{tier:"compact",style:local.petDiscGlyph,children:initialOf(pet.name??"")})})},pet.petRef))}),onAddPet?/* @__PURE__ */jsxRuntime.jsx(TelevetButton,{label:TELEVET_BOOKING_COPY.addAnotherPetCta,kind:"quiet",fullWidth:false,onPress:onAddPet,testID:"televet-pet-add"}):null]})}function initialOf(name){let trimmed=name.trim();return trimmed.length===0?PERSON_GLYPH:trimmed.slice(0,1).toUpperCase()}function ClinicianStep({clinicians:clinicians,isPending:isPending,isError:isError,error:error,selectedId:selectedId,stateCode:stateCode,stateName:stateName,onSelect:onSelect,onRetry:onRetry}){let styles2=useBookingStyles(),theme=useEverfurTheme(),local=react.useMemo(()=>makeLocalStyles(theme),[theme]);if(isPending)/* @__PURE__ */
|
|
235
143
|
return jsxRuntime.jsx(reactNative.View,{style:styles2.list,testID:"televet-clinicians-loading",children:/* @__PURE__ */jsxRuntime.jsx(TelevetSkeletonBlock,{height:220})});if(isError)/* @__PURE__ */
|
|
236
144
|
return jsxRuntime.jsx(reactNative.View,{testID:"televet-clinicians-error",children:/* @__PURE__ */jsxRuntime.jsx(TelevetLoadFailed,{error:error,title:TELEVET_BOOKING_COPY.chrome.loadFailedTitle,actionLabel:TELEVET_BOOKING_COPY.chrome.retryCta,onRetry:onRetry})});if(clinicians.length===0)/* @__PURE__ */
|
|
237
|
-
return jsxRuntime.jsx(reactNative.View,{testID:"televet-clinicians-empty",children:/* @__PURE__ */jsxRuntime.jsx(TelevetStateCard,{title:TELEVET_BOOKING_COPY.noCliniciansTitle,message:TELEVET_BOOKING_COPY.noCliniciansBody,actionLabel:TELEVET_BOOKING_COPY.noCliniciansRetryCta,onAction:onRetry})});let vet=clinicians.find(c=>c.clinicianId===selectedId)??clinicians[0];if(vet===void 0)return null;let code=stateCode?.trim().toUpperCase()??"",licensedHere=code.length>0&&vet.licensedStates.some(l=>l.state.trim().toUpperCase()===code);/* @__PURE__ */
|
|
145
|
+
return jsxRuntime.jsx(reactNative.View,{testID:"televet-clinicians-empty",children:/* @__PURE__ */jsxRuntime.jsx(TelevetStateCard,{title:TELEVET_BOOKING_COPY.noCliniciansTitle,message:TELEVET_BOOKING_COPY.noCliniciansBody,actionLabel:TELEVET_BOOKING_COPY.noCliniciansRetryCta,onAction:onRetry})});let vet=clinicians.find(c=>c.clinicianId===selectedId)??clinicians[0];if(vet===void 0)return null;let code=stateCode?.trim().toUpperCase()??"",licensedHere=code.length>0&&vet.licensedStates.some(l=>l.state.trim().toUpperCase()===code),isTech=vet.role==="vet_tech";/* @__PURE__ */
|
|
238
146
|
return jsxRuntime.jsx(TelevetStepFrame,{heading:TELEVET_BOOKING_COPY.yourVetTitle,testID:"televet-clinicians",footer:/* @__PURE__ */jsxRuntime.jsx(TelevetButton,{label:TELEVET_BOOKING_COPY.continueCta,kind:"primary",onPress:()=>onSelect(vet.clinicianId),testID:`televet-clinician-${vet.clinicianId}`}),children:/* @__PURE__ */jsxRuntime.jsxs(reactNative.View,{style:local.meet,children:[
|
|
239
147
|
/* @__PURE__ */jsxRuntime.jsx(reactNative.View,{style:local.vetAvatar,children:/* @__PURE__ */jsxRuntime.jsx(Text,{tier:"heading",style:local.vetAvatarText,children:clinicianInitial(vet.displayName)||PERSON_GLYPH})}),
|
|
240
|
-
/* @__PURE__ */jsxRuntime.jsx(Text,{style:local.vetName,children:vet.credentials?`${vet.displayName}, ${vet.credentials}`:vet.displayName}),licensedHere&&stateName?/* @__PURE__ */jsxRuntime.jsx(reactNative.View,{style:local.pill,testID:"televet-vet-licensed",children:/* @__PURE__ */jsxRuntime.jsx(Text,{tier:"badge",style:local.pillText,children:fill(TELEVET_BOOKING_COPY.licensedPillTemplate,{state:stateName})})}):null,vet.rating!==null&&vet.ratingCount!==null?/* @__PURE__ */jsxRuntime.jsx(Text,{tier:"compact",style:local.vetRating,testID:"televet-vet-rating",children:`★ ${String(vet.rating)} · ${String(vet.ratingCount)} ${TELEVET_BOOKING_COPY.reviewsLabel}`}):null,vet.bio?/* @__PURE__ */jsxRuntime.jsx(Text,{style:local.vetBio,testID:"televet-vet-bio",children:vet.bio}):null]})})}function SlotStep({slots:slots,enabled:enabled,isPending:isPending,isError:isError,error:error,busySlotId:busySlotId,failure:failure2,selectedSlot:selectedSlot,nextOpening:nextOpening,onPick:onPick,onRetry:onRetry,onSeeOtherVets:onSeeOtherVets}){let styles2=useBookingStyles();return enabled?isPending?/* @__PURE__ */jsxRuntime.jsx(reactNative.View,{style:styles2.list,testID:"televet-slots-loading",children:[0,1,2].map(i=>/* @__PURE__ */jsxRuntime.jsx(TelevetSkeletonBlock,{height:48},i))}):isError?/* @__PURE__ */jsxRuntime.jsx(TelevetLoadFailed,{error:error,title:TELEVET_BOOKING_COPY.slotsErrorTitle,actionLabel:TELEVET_BOOKING_COPY.retryCta,onRetry:onRetry,testID:"televet-slots-error"}):slots.length===0?/* @__PURE__ */jsxRuntime.jsx(reactNative.View,{testID:"televet-slots-empty",children:/* @__PURE__ */jsxRuntime.jsx(TelevetStateCard,{title:TELEVET_BOOKING_COPY.noSlotsTitle,message:nextOpening?fill(TELEVET_BOOKING_COPY.nextOpeningTemplate,{when:formatWhenWithDay(nextOpening.startsAt)}):void 0,actionLabel:nextOpening?TELEVET_BOOKING_COPY.seeOtherVetsCta:void 0,onAction:nextOpening?onSeeOtherVets:void 0})}):
|
|
148
|
+
/* @__PURE__ */jsxRuntime.jsx(Text,{style:local.vetName,children:vet.credentials?`${vet.displayName}, ${vet.credentials}`:vet.displayName}),isTech?/* @__PURE__ */jsxRuntime.jsx(reactNative.View,{style:local.pill,testID:"televet-vet-role",children:/* @__PURE__ */jsxRuntime.jsx(Text,{tier:"badge",style:local.pillText,children:TELEVET_BOOKING_COPY.vetTechRoleLabel})}):null,licensedHere&&stateName?/* @__PURE__ */jsxRuntime.jsx(reactNative.View,{style:local.pill,testID:"televet-vet-licensed",children:/* @__PURE__ */jsxRuntime.jsx(Text,{tier:"badge",style:local.pillText,children:fill(TELEVET_BOOKING_COPY.licensedPillTemplate,{state:stateName})})}):null,isTech?/* @__PURE__ */jsxRuntime.jsx(Text,{tier:"compact",style:local.vetRating,testID:"televet-vet-no-rx",children:TELEVET_BOOKING_COPY.vetTechNoRxLine}):null,vet.rating!==null&&vet.ratingCount!==null?/* @__PURE__ */jsxRuntime.jsx(Text,{tier:"compact",style:local.vetRating,testID:"televet-vet-rating",children:`★ ${String(vet.rating)} · ${String(vet.ratingCount)} ${TELEVET_BOOKING_COPY.reviewsLabel}`}):null,vet.bio?/* @__PURE__ */jsxRuntime.jsx(Text,{style:local.vetBio,testID:"televet-vet-bio",children:vet.bio}):null]})})}function SlotStep({slots:slots,enabled:enabled,isPending:isPending,isError:isError,error:error,busySlotId:busySlotId,failure:failure2,selectedSlot:selectedSlot,nextOpening:nextOpening,onPick:onPick,onRetry:onRetry,onSeeOtherVets:onSeeOtherVets}){let styles2=useBookingStyles();return enabled?isPending?/* @__PURE__ */jsxRuntime.jsx(reactNative.View,{style:styles2.list,testID:"televet-slots-loading",children:[0,1,2].map(i=>/* @__PURE__ */jsxRuntime.jsx(TelevetSkeletonBlock,{height:48},i))}):isError?/* @__PURE__ */jsxRuntime.jsx(TelevetLoadFailed,{error:error,title:TELEVET_BOOKING_COPY.slotsErrorTitle,actionLabel:TELEVET_BOOKING_COPY.retryCta,onRetry:onRetry,testID:"televet-slots-error"}):slots.length===0?/* @__PURE__ */jsxRuntime.jsx(reactNative.View,{testID:"televet-slots-empty",children:/* @__PURE__ */jsxRuntime.jsx(TelevetStateCard,{title:TELEVET_BOOKING_COPY.noSlotsTitle,message:nextOpening?fill(TELEVET_BOOKING_COPY.nextOpeningTemplate,{when:formatWhenWithDay(nextOpening.startsAt)}):void 0,actionLabel:nextOpening?TELEVET_BOOKING_COPY.seeOtherVetsCta:void 0,onAction:nextOpening?onSeeOtherVets:void 0})}):
|
|
241
149
|
/* @__PURE__ */jsxRuntime.jsxs(reactNative.View,{style:styles2.stepFillBox,testID:"televet-slots",children:[
|
|
242
150
|
/* @__PURE__ */jsxRuntime.jsx(Text,{tier:"heading",style:styles2.stepTitle,accessibilityRole:"header",children:TELEVET_BOOKING_COPY.timeHeading}),failure2==="expired"?/* @__PURE__ */jsxRuntime.jsx(TelevetFailureLine,{message:TELEVET_BOOKING_COPY.holdExpired}):null,failure2==="taken"?/* @__PURE__ */jsxRuntime.jsx(TelevetFailureLine,{message:TELEVET_BOOKING_COPY.slotTaken}):null,failure2==="failed"||failure2==="rate_limited"?/* @__PURE__ */jsxRuntime.jsx(TelevetFailureLine,{message:TELEVET_BOOKING_COPY.confirmFailed,testID:"televet-slots-hold-failed"}):null,
|
|
243
151
|
/* @__PURE__ */jsxRuntime.jsx(TelevetSlotPicker,{slots:slots,busySlotId:busySlotId,onPick:onPick,selectedSlot:selectedSlot,periodLabels:{morning:TELEVET_BOOKING_COPY.timeMorning,afternoon:TELEVET_BOOKING_COPY.timeAfternoon,evening:TELEVET_BOOKING_COPY.timeEvening}})]}):/* @__PURE__ */jsxRuntime.jsx(reactNative.View,{testID:"televet-slots-unavailable",children:/* @__PURE__ */jsxRuntime.jsx(TelevetStateCard,{title:TELEVET_BOOKING_COPY.bookingPausedTitle})})}function ReasonStep({value:value,composed:composed,vetName:vetName,onChange:onChange,onNext:onNext,media:media,onChangeMedia:onChangeMedia,onPickMedia:onPickMedia,mediaLive:mediaLive=false,checking:checking=false}){let theme=useEverfurTheme(),local=react.useMemo(()=>makeLocalStyles(theme),[theme]),trimmed=(composed??value).trim(),valid=trimmed.length>0&&trimmed.length<=REASON_TEXT_MAX,heading=vetName?fill(TELEVET_BOOKING_COPY.describeHeadingTemplate,{vet:vetName}):TELEVET_BOOKING_COPY.describeHeading;/* @__PURE__ */
|
|
@@ -271,7 +179,7 @@ return jsxRuntime.jsxs(TelevetStepFrame,{heading:fill(check.titleTemplate,{pet:p
|
|
|
271
179
|
/* @__PURE__ */jsxRuntime.jsx(Text,{style:local.emergencyLede,children:lede}),
|
|
272
180
|
/* @__PURE__ */jsxRuntime.jsx(TelevetEmergencyExits,{petName:petName,primaryVet:primaryVet,onFindEmergencyVet:onFindEmergencyVet}),
|
|
273
181
|
/* @__PURE__ */jsxRuntime.jsx(TelevetButton,{label:TELEVET_BOOKING_COPY.emergency.keepBookingCta,kind:"quiet",fullWidth:false,onPress:onHandled,testID:"televet-emergency-handled"})]}):null]})}function makePickStyles(theme){let{space:space,radius:radius,type:type}=theme,{size:size,lineHeight:lineHeight}=type,look=televetLook(theme),chip=theme.slots.chip;return reactNative.StyleSheet.create({pickRow:{flexDirection:"row",flexWrap:"wrap",gap:10},pick:{minHeight:44,flexDirection:"row",alignItems:"center",gap:space.sm,paddingHorizontal:space.lg,borderRadius:radius.pill,borderWidth:1,borderColor:look.ink,backgroundColor:look.surface,...slotBox(chip,1)},pickOn:{backgroundColor:look.pink,borderColor:look.ink},pressed:{transform:[{scale:.97}]},check:{width:12,height:7,marginTop:-3,borderLeftWidth:2,borderBottomWidth:2,borderColor:look.onPink,transform:[{rotate:"-45deg"}]},pickLabel:{...face(theme,"bold"),color:look.ink,fontSize:size.bodyTight,lineHeight:size.bodyTight*lineHeight.snug,...slotText(chip)},pickLabelOn:{color:look.onPink},note:{...face(theme,"regular"),color:look.muted,fontSize:size.bodyTight,lineHeight:size.bodyTight*lineHeight.relaxed},callout:{padding:space.md,borderRadius:radius.sm,backgroundColor:look.mist,overflow:"hidden",...face(theme,"regular"),color:look.text,fontSize:size.bodyTight,lineHeight:size.bodyTight*lineHeight.relaxed},signs:{gap:space.sm},sign:{flexDirection:"row",gap:space.md,alignItems:"flex-start"},bullet:{width:6,height:6,borderRadius:3,backgroundColor:look.text,marginTop:size.body*.6},signText:{flex:1,...face(theme,"regular"),color:look.text,fontSize:size.body,lineHeight:size.body*lineHeight.relaxed}})}function EverfurTelevetBooking(props){let{petRef:petRef,usState:usState,controller:injected,onBooked:onBooked,onExit:onExit,onAddPet:onAddPet,onPickMedia:onPickMedia,onAddToCalendar:onAddToCalendar,onConfirmDiscard:onConfirmDiscard,onRequestLocation:onRequestLocation,locationStatus:locationStatus="unknown",onTriageReason:onTriageReason,onStateInterest:onStateInterest,primaryVet:primaryVet,onFindEmergencyVet:onFindEmergencyVet,canJoinInApp:canJoinInApp=false,renderUnavailable:renderUnavailable,style:style,testID:testID}=guardHostProps(props,["onBooked","onExit","onAddPet","onRequestLocation","onFindEmergencyVet"]),styles2=useBookingStyles(),theme=useEverfurTheme(),local=react.useMemo(()=>makeLocalStyles(theme),[theme]),controller=useTelevetBookingController(injected),roster=useEverfurPets(),pets=roster.pets,ownedPetCount=pets.length,ctx=react.useMemo(()=>({ownedPetCount:ownedPetCount,withIssues:true}),[ownedPetCount]),[state,rawDispatch]=react.useReducer((s,a)=>televetBookingReducer(s,a,ctx),void 0,()=>initialTelevetBookingState({ownedPetCount:0,withIssues:true},{petId:petRef??null,state:usState??null})),dispatch=react.useCallback(action=>rawDispatch(action),[]),[reasonText,setReasonText]=react.useState(""),[failure2,setFailure]=react.useState(null),[emergency,setEmergency]=react.useState(null),[stateAttested,setStateAttested]=react.useState(false),[termsAttested,setTermsAttested]=react.useState(false),[media,setMedia]=react.useState([]),mediaTransport=react.useMemo(()=>createRnChatAttachmentTransport(),[]),sendMedia=useTelevetBookingMedia({media:media,controller:controller,transport:mediaTransport}),[bookedConsult,setBookedConsult]=react.useState(null),{draft:draft}=state,step=currentStep(state),attestedFor=react.useRef(draft.state);attestedFor.current!==draft.state&&(attestedFor.current=draft.state,stateAttested&&setStateAttested(false),termsAttested&&setTermsAttested(false));let policy=useTelevetStatePolicy(draft.state,controller),cancellation=useTelevetCancellationPolicy(controller),entitlement=useTelevetBookingEntitlement(controller),rosterController=useTelevetRosterController(controller,entitlement),clinicians=useTelevetClinicians(draft.state,rosterController),slots=useTelevetSlots(draft.clinicianId,rosterController),refetchSlots=slots.refetch,nextOpening=useTelevetNextSlot(rosterController).data??null,hold=useTelevetHoldSlot(controller),book=useTelevetBookConsult(controller),controllerTriage=react.useMemo(()=>televetTriageReadFrom(controller),[controller]),triage=useEarlyTriage(onTriageReason??controllerTriage),noLicensedVetInterest=useStateInterest(draft.state,onStateInterest??null).actionFor("no_licensed_vet"),hostState=usState??null,petName=nameOf(pets,draft.petId),intake=useTelevetBookingIntake({reasonText:reasonText,state:draft.state,hostState:hostState,clinicianId:draft.clinicianId,clinicians:clinicians.data,policy:policy,petName:petName,controller:controller,dispatch:dispatch}),{composedReason:composedReason,where:where,matchedClinician:matchedClinician}=intake;react.useEffect(()=>{hostState&&!draft.state&&!intake.whereTouched.current&&dispatch({type:"patch",patch:{state:hostState}})},[hostState,draft.state,dispatch]),react.useEffect(()=>{petRef&&!draft.petId&&dispatch({type:"patch",patch:{petId:petRef}})},[petRef,draft.petId,dispatch]);let lonePetRef=pets.length===1?pets[0]?.petRef??null:null;react.useEffect(()=>{lonePetRef&&!draft.petId&&dispatch({type:"patch",patch:{petId:lonePetRef}})},[lonePetRef,draft.petId,dispatch]);let stepRef=react.useRef(step);stepRef.current=step;let petIdRef=react.useRef(draft.petId);petIdRef.current=draft.petId;let settledCount=react.useRef(0);react.useEffect(()=>{if(ownedPetCount===settledCount.current)return;settledCount.current=ownedPetCount;let needsPet=ownedPetCount>1&&!petIdRef.current;dispatch({type:"goTo",step:needsPet?"pet":stepRef.current})},[ownedPetCount,dispatch]);let matchedClinicianId=clinicians.data?.[0]?.clinicianId??null;react.useEffect(()=>{matchedClinicianId&&!draft.clinicianId&&dispatch({type:"patch",patch:{clinicianId:matchedClinicianId}})},[matchedClinicianId,draft.clinicianId,dispatch]);let holdAndAdvance=useSlotHold({draft:draft,hold:hold,dispatch:dispatch,setFailure:setFailure,refetchSlots:refetchSlots});useHoldRelease({controller:controller,draft:draft,keep:step==="booked"||book.isPending});let{submitBooking:submitBooking,confirm:confirm}=useBookingSubmit({draft:draft,reasonText:composedReason,book:book,stateAttested:stateAttested,termsAttested:termsAttested,cancellationPolicy:cancellation.data??null,triage:triage,goTo:react.useCallback(next=>dispatch({type:"goTo",step:next}),[dispatch]),releaseSlot:react.useCallback(()=>{dispatch({type:"patch",patch:RELEASED_HOLD}),refetchSlots()},[dispatch,refetchSlots]),setFailure:setFailure,setEmergency:setEmergency,setBookedConsult:setBookedConsult,...onBooked?{onBooked:onBooked}:{},media:sendMedia}),policyBlocked=policy.enabled&&policy.data!==null&&!policy.data.wellnessAvailable&&step!=="pet"&&step!=="where",notEntitled=entitlement.enabled&&entitlement.data?.active===false||failure2==="not_entitled",{simulate:simulate,fundingRefused:fundingRefused}=useTelevetSimulatorRoute(entitlement,notEntitled),surfaceServed=entitlement.enabled&&entitlement.data!==null,emptyRosterCause=televetEmptyRosterCause(surfaceServed),isDirty=composedReason.trim().length>0||!!draft.slot,surfaceUnavailable=controller===null||failure2==="unavailable"||televetReadIsDark(entitlement)||televetReadIsDark(policy),clinicianState={noState:!draft.state,isPending:clinicians.enabled&&clinicians.isPending,isError:clinicians.isError,isEmpty:(clinicians.data?.length??0)===0,notEntitled:fundingRefused},clinicianOutcome=televetClinicianOutcomeApplies(clinicianState),gateState={surfaceUnavailable:surfaceUnavailable,notEntitled:fundingRefused,policyBlocked:policyBlocked,triageOpen:triage.open,step:step},gated=televetBookingGateApplies(gateState);return isTelevetBookingCopyReady()?/* @__PURE__ */jsxRuntime.jsxs(reactNative.View,{style:[styles2.screen,style],testID:testID??"televet-booking",children:[
|
|
274
|
-
/* @__PURE__ */jsxRuntime.jsx(TelevetBookingChrome,{step:step,furthestIndex:state.furthestIndex,canGoBack:!simulate&&(triage.open||hasPreviousStep(state,ctx))&&step!=="booked",isDirty:isDirty,onBack:()=>{if(triage.open){triage.close();return}triage.cancel(),dispatch({type:"back"})},onClose:()=>onExit?.(),triageOpen:triage.open,stepContext:ctx,...onConfirmDiscard?{onConfirmDiscard:onConfirmDiscard}:{}}),simulate?/* @__PURE__ */jsxRuntime.jsx(TelevetVisitSimulator,{petId:draft.petId,roster:roster,onAddPet:onAddPet,onPickPet:petId=>dispatch({type:"patch",patch:{petId:petId}})}):gated?/* @__PURE__ */jsxRuntime.jsx(TelevetBookingGate,{state:gateState,petName:nameOf(pets,draft.petId),...primaryVet?{primaryVet:primaryVet}:{},onFindEmergencyVet:onFindEmergencyVet,stateInterest:noLicensedVetInterest,...onStateInterest?{onCheckAvailability:()=>dispatch({type:"goTo",step:"clinician"})}:{},onAcknowledgeEmergency:()=>{triage.acknowledge(composedReason),dispatch({type:"next"})},...renderUnavailable?{renderUnavailable:renderUnavailable}:{}}):step==="time"?/* @__PURE__ */jsxRuntime.jsx(SlotStep,{slots:slots.data??[],enabled:slots.enabled,isPending:slots.enabled&&slots.isPending&&slots.data===null,isError:slots.isError,error:slots.error,busySlotId:hold.isPending?hold.variables:null,failure:failure2,selectedSlot:draft.slot,nextOpening:nextOpening,onPick:holdAndAdvance,onRetry:()=>slots.refetch(),onSeeOtherVets:()=>dispatch({type:"goTo",step:"clinician"})}):step==="review"?/* @__PURE__ */jsxRuntime.jsx(ReviewStep,{when:draft.slot?formatVisitDayTime(draft.slot.startsAt):"",onChangeWhen:()=>dispatch({type:"goTo",step:"time"}),stateName:where.stateName,about:intake.aboutLine,lengthMinutes:(draft.slot?televetSlotMinutes(draft.slot):null)??CONSULT_MINUTES,petName:nameOf(pets,draft.petId),reason:composedReason.trim(),clinician:clinicians.data?.find(c=>c.clinicianId===draft.clinicianId)?.displayName??null,shareRecords:draft.shareHealthRecords,stateCode:draft.state,stateAttested:stateAttested,onToggleStateAttest:setStateAttested,cancellationTerms:cancellation.data?.summary??null,termsAttested:termsAttested,onToggleTermsAttest:setTermsAttested,onToggleShare:next=>dispatch({type:"patch",patch:{shareHealthRecords:next}}),canConfirm:canConfirm(draft,composedReason),busy:book.isPending||sendMedia.sending,failure:failure2,onConfirm:confirm,emergency:emergency,onAcknowledgeEmergency:()=>submitBooking(true),onSeeOtherVets:()=>dispatch({type:"goTo",step:"clinician"}),mediaShortfall:sendMedia.shortfall,primaryVet:primaryVet,onFindEmergencyVet:onFindEmergencyVet}):step==="booked"?/* @__PURE__ */jsxRuntime.jsx(reactNative.View,{style:styles2.stepFill,testID:"televet-booking-booked",children:bookedConsult?/* @__PURE__ */jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[
|
|
182
|
+
/* @__PURE__ */jsxRuntime.jsx(TelevetBookingChrome,{step:step,furthestIndex:state.furthestIndex,canGoBack:!simulate&&(triage.open||hasPreviousStep(state,ctx))&&step!=="booked",isDirty:isDirty,onBack:()=>{if(triage.open){triage.close();return}triage.cancel(),dispatch({type:"back"})},onClose:()=>onExit?.(),triageOpen:triage.open,stepContext:ctx,...onConfirmDiscard?{onConfirmDiscard:onConfirmDiscard}:{}}),simulate?/* @__PURE__ */jsxRuntime.jsx(TelevetVisitSimulator,{petId:draft.petId,roster:roster,onAddPet:onAddPet,onPickPet:petId=>dispatch({type:"patch",patch:{petId:petId}})}):gated?/* @__PURE__ */jsxRuntime.jsx(TelevetBookingGate,{state:gateState,petName:nameOf(pets,draft.petId),...primaryVet?{primaryVet:primaryVet}:{},onFindEmergencyVet:onFindEmergencyVet,stateInterest:noLicensedVetInterest,...onStateInterest?{onCheckAvailability:()=>dispatch({type:"goTo",step:"clinician"})}:{},onAcknowledgeEmergency:()=>{triage.acknowledge(composedReason),dispatch({type:"next"})},...renderUnavailable?{renderUnavailable:renderUnavailable}:{}}):step==="time"?/* @__PURE__ */jsxRuntime.jsx(SlotStep,{slots:slots.data??[],enabled:slots.enabled,isPending:slots.enabled&&slots.isPending&&slots.data===null,isError:slots.isError,error:slots.error,busySlotId:hold.isPending?hold.variables:null,failure:failure2,selectedSlot:draft.slot,nextOpening:nextOpening,onPick:holdAndAdvance,onRetry:()=>slots.refetch(),onSeeOtherVets:()=>dispatch({type:"goTo",step:"clinician"})}):step==="review"?/* @__PURE__ */jsxRuntime.jsx(ReviewStep,{when:draft.slot?formatVisitDayTime(draft.slot.startsAt):"",onChangeWhen:()=>dispatch({type:"goTo",step:"time"}),stateName:where.stateName,about:intake.aboutLine,lengthMinutes:(draft.slot?televetSlotMinutes(draft.slot):null)??CONSULT_MINUTES,petName:nameOf(pets,draft.petId),reason:composedReason.trim(),clinician:clinicians.data?.find(c=>c.clinicianId===draft.clinicianId)?.displayName??null,clinicianRole:clinicians.data?.find(c=>c.clinicianId===draft.clinicianId)?.role??null,shareRecords:draft.shareHealthRecords,stateCode:draft.state,stateAttested:stateAttested,onToggleStateAttest:setStateAttested,cancellationTerms:cancellation.data?.summary??null,termsAttested:termsAttested,onToggleTermsAttest:setTermsAttested,onToggleShare:next=>dispatch({type:"patch",patch:{shareHealthRecords:next}}),canConfirm:canConfirm(draft,composedReason),busy:book.isPending||sendMedia.sending,failure:failure2,onConfirm:confirm,emergency:emergency,onAcknowledgeEmergency:()=>submitBooking(true),onSeeOtherVets:()=>dispatch({type:"goTo",step:"clinician"}),mediaShortfall:sendMedia.shortfall,primaryVet:primaryVet,onFindEmergencyVet:onFindEmergencyVet}):step==="booked"?/* @__PURE__ */jsxRuntime.jsx(reactNative.View,{style:styles2.stepFill,testID:"televet-booking-booked",children:bookedConsult?/* @__PURE__ */jsxRuntime.jsxs(jsxRuntime.Fragment,{children:[
|
|
275
183
|
/* @__PURE__ */jsxRuntime.jsx(TelevetBookedScreen,{consult:bookedConsult,petName:nameOf(pets,bookedConsult.petId)??nameOf(pets,draft.petId),onDone:()=>onExit?.(),canJoinInApp:canJoinInApp,sharedRecords:draft.shareHealthRecords,sentPhoto:sendMedia.sentOnePhoto(bookedConsult),...onAddToCalendar?{onAddToCalendar:onAddToCalendar}:{}}),
|
|
276
184
|
/* @__PURE__ */jsxRuntime.jsx(TelevetMediaDropNotice,{shortfall:sendMedia.bookedShortfall(bookedConsult),testIDPrefix:"televet-booked"})]}):null}):step==="clinician"&&clinicianOutcome?
|
|
277
185
|
/* @__PURE__ */jsxRuntime.jsx(TelevetClinicianOutcome,{state:clinicianState,cause:emptyRosterCause,locationStatus:locationStatus,...onRequestLocation?{onRequestLocation:onRequestLocation}:{},onRetry:()=>clinicians.refetch(),stateInterest:noLicensedVetInterest,...renderUnavailable?{renderUnavailable:renderUnavailable}:{}}):step==="clinician"?/* @__PURE__ */jsxRuntime.jsx(ClinicianStep,{clinicians:clinicians.data??[],isPending:clinicians.enabled&&clinicians.isPending,isError:clinicians.isError,error:clinicians.error,selectedId:draft.clinicianId,stateCode:draft.state,stateName:where.stateName,onRetry:()=>clinicians.refetch(),onSelect:clinicianId=>{dispatch({type:"patch",patch:{clinicianId:clinicianId}}),dispatch({type:"next"})}}):step==="reason"?/* @__PURE__ */jsxRuntime.jsx(ReasonStep,{value:reasonText,composed:composedReason,vetName:matchedClinician?.displayName??null,onChange:setReasonText,media:media,onChangeMedia:setMedia,mediaLive:sendMedia.live,...onPickMedia?{onPickMedia:onPickMedia}:{},checking:triage.checking,onNext:()=>{triage.check(composedReason).then(goOn=>{goOn&&dispatch({type:"next"})})}}):step==="pet"?
|
|
@@ -3,21 +3,21 @@ import { ReactNode, ComponentType, ReactElement } from 'react';
|
|
|
3
3
|
import { StyleProp, ViewStyle } from 'react-native';
|
|
4
4
|
import { P as PetRef } from '../../ids.d-B2GAAifq.cjs';
|
|
5
5
|
export { B as Brand, _ as __brand } from '../../ids.d-B2GAAifq.cjs';
|
|
6
|
-
import { T as TelevetEmptyRosterCause, a as TelevetStateInterestAction$1, b as TelevetMediaShortfall, c as TelevetBookingStep, d as TelevetBookingContext, e as TelevetBookingController, f as TelevetTriageRead, g as TelevetStateInterestWrite, h as TelevetVetThreadTarget, i as TelevetDayPeriod } from '../../bookingCopy.d-
|
|
7
|
-
export { C as CONSULT_MINUTES, N as NO_MEDIA_SHORTFALL, j as TELEVET_BOOKING_BASE, k as TELEVET_BOOKING_COPY, l as TELEVET_BOOKING_STEPS, m as TELEVET_CONSULT_PAGE_LIMIT, n as TELEVET_JOIN_CLOSES_MINUTES_AFTER, o as TELEVET_JOIN_OPENS_MINUTES_BEFORE, p as TELEVET_MESSAGE_THREADS_PATH, q as TelevetAttachmentMeta, r as TelevetAttachmentPolicy, s as TelevetBookingAction, t as TelevetBookingControllerDeps, u as TelevetBookingCopy, v as TelevetBookingDraft, w as TelevetBookingFailure, x as TelevetBookingRefusal, y as TelevetBookingState, z as TelevetEarlyTriage, A as TelevetEmptyRosterView, B as TelevetJoinReadiness, D as TelevetJoinState, E as TelevetMediaRefusal, F as TelevetRead, G as TelevetStateInterestReason, H as TelevetWrite, U as UpcomingTelevetVisitState, I as UseVetThreadOptions, V as VET_MESSAGES_COPY, J as VET_MESSAGE_CONTENT_MAX, K as VET_MESSAGE_PAGE_DEFAULT, L as VET_MESSAGE_PAGE_MAX, M as VetMessage, O as VetMessagePage, P as VetMessageRole, Q as VetMessagesAvailability, R as VetSendFailure, S as VetThread, W as VetThreadState, X as VetThreadsState, Y as VisitSummary, Z as VisitSummaryMedication, _ as VisitSummaryState, $ as attestation, a0 as canConfirm, a1 as canManageTelevetVisit, a2 as createTelevetBookingController, a3 as currentStep, a4 as emptyTelevetDraft, a5 as formatVisitRange, a6 as formatWhen, a7 as formatWhenWithDay, a8 as hasPreviousStep, a9 as initialTelevetBookingState, aa as isHoldExpired, ab as isMediaShortfallEmpty, ac as isSkipped, ad as isTelevetBookingCopyReady, ae as isVetMessagesDark, af as isVetThreadVetFirst, ag as mediaShortfallFromUnsentPicks, ah as splitTelevetVisits, ai as televetBookingKey, aj as televetBookingReducer, ak as televetBookingRefusal, al as televetCancelCall, am as televetConsultCall, an as televetEmptyRosterCause, ao as televetEmptyRosterView, ap as televetHoldCall, aq as televetJoinCall, ar as televetJoinOpensAtMs, as as televetJoinReadiness, at as televetMediaShortfallLines, au as televetRescheduleCall, av as televetThreadMessagesCall, aw as televetThreadReadCall, ax as televetVisitSummaryCall, ay as useEarlyTriage, az as useStateInterest, aA as useTelevetBookConsult, aB as useTelevetBookingAvailable, aC as useTelevetBookingController, aD as useTelevetBookingEntitlement, aE as useTelevetCancellationPolicy, aF as useTelevetClinicians, aG as useTelevetHoldSlot, aH as useTelevetJoin, aI as useTelevetNextSlot, aJ as useTelevetRescheduleConsult, aK as useTelevetSlots, aL as useTelevetStatePolicy, aM as useUpcomingTelevetVisit, aN as useVetThread, aO as useVetThreads, aP as useVisitSummary, aQ as validateBookingBody, aR as vetThreadPetRef, aS as withUnsentPicks } from '../../bookingCopy.d-
|
|
8
|
-
import { T as TelevetConsult, E as EverfurTelevetFlowRequest, b as TelevetCancelReceipt, c as TelevetSlot } from '../../televetGlobal.d-
|
|
9
|
-
export { C as CANCELLATION_POLICY_VERSION_MAX, d as CANCEL_REASON_MAX, e as CONSULT_KINDS, f as CONSULT_STATUSES, g as ConsultKind, h as ConsultStatus, M as MEDIA_REFS_MAX, R as REASON_TEXT_MAX, i as TERMINAL_CONSULT_STATUSES, j as TelevetBookingBody, k as TelevetBookingEntitlement, l as TelevetCancellationPolicy, m as TelevetClinician, n as TelevetSlotHold, o as TelevetStatePolicy, p as TelevetTriageVerdict, q as isWellFormedStateCode } from '../../televetGlobal.d-
|
|
6
|
+
import { T as TelevetEmptyRosterCause, a as TelevetStateInterestAction$1, b as TelevetMediaShortfall, c as TelevetBookingStep, d as TelevetBookingContext, e as TelevetBookingController, f as TelevetTriageRead, g as TelevetStateInterestWrite, h as TelevetVetThreadTarget, i as TelevetDayPeriod } from '../../bookingCopy.d-tvO7y6MK.cjs';
|
|
7
|
+
export { C as CONSULT_MINUTES, N as NO_MEDIA_SHORTFALL, j as TELEVET_BOOKING_BASE, k as TELEVET_BOOKING_COPY, l as TELEVET_BOOKING_STEPS, m as TELEVET_CONSULT_PAGE_LIMIT, n as TELEVET_JOIN_CLOSES_MINUTES_AFTER, o as TELEVET_JOIN_OPENS_MINUTES_BEFORE, p as TELEVET_MESSAGE_THREADS_PATH, q as TelevetAttachmentMeta, r as TelevetAttachmentPolicy, s as TelevetBookingAction, t as TelevetBookingControllerDeps, u as TelevetBookingCopy, v as TelevetBookingDraft, w as TelevetBookingFailure, x as TelevetBookingRefusal, y as TelevetBookingState, z as TelevetEarlyTriage, A as TelevetEmptyRosterView, B as TelevetJoinReadiness, D as TelevetJoinState, E as TelevetMediaRefusal, F as TelevetRead, G as TelevetStateInterestReason, H as TelevetWrite, U as UpcomingTelevetVisitState, I as UseVetThreadOptions, V as VET_MESSAGES_COPY, J as VET_MESSAGE_CONTENT_MAX, K as VET_MESSAGE_PAGE_DEFAULT, L as VET_MESSAGE_PAGE_MAX, M as VetMessage, O as VetMessagePage, P as VetMessageRole, Q as VetMessagesAvailability, R as VetSendFailure, S as VetThread, W as VetThreadState, X as VetThreadsState, Y as VisitSummary, Z as VisitSummaryMedication, _ as VisitSummaryState, $ as attestation, a0 as canConfirm, a1 as canManageTelevetVisit, a2 as createTelevetBookingController, a3 as currentStep, a4 as emptyTelevetDraft, a5 as formatVisitRange, a6 as formatWhen, a7 as formatWhenWithDay, a8 as hasPreviousStep, a9 as initialTelevetBookingState, aa as isHoldExpired, ab as isMediaShortfallEmpty, ac as isSkipped, ad as isTelevetBookingCopyReady, ae as isVetMessagesDark, af as isVetThreadVetFirst, ag as mediaShortfallFromUnsentPicks, ah as splitTelevetVisits, ai as televetBookingKey, aj as televetBookingReducer, ak as televetBookingRefusal, al as televetCancelCall, am as televetConsultCall, an as televetEmptyRosterCause, ao as televetEmptyRosterView, ap as televetHoldCall, aq as televetJoinCall, ar as televetJoinOpensAtMs, as as televetJoinReadiness, at as televetMediaShortfallLines, au as televetRescheduleCall, av as televetThreadMessagesCall, aw as televetThreadReadCall, ax as televetVisitSummaryCall, ay as useEarlyTriage, az as useStateInterest, aA as useTelevetBookConsult, aB as useTelevetBookingAvailable, aC as useTelevetBookingController, aD as useTelevetBookingEntitlement, aE as useTelevetCancellationPolicy, aF as useTelevetClinicians, aG as useTelevetHoldSlot, aH as useTelevetJoin, aI as useTelevetNextSlot, aJ as useTelevetRescheduleConsult, aK as useTelevetSlots, aL as useTelevetStatePolicy, aM as useUpcomingTelevetVisit, aN as useVetThread, aO as useVetThreads, aP as useVisitSummary, aQ as validateBookingBody, aR as vetThreadPetRef, aS as withUnsentPicks } from '../../bookingCopy.d-tvO7y6MK.cjs';
|
|
8
|
+
import { T as TelevetConsult, E as EverfurTelevetFlowRequest, b as TelevetCancelReceipt, c as TelevetSlot } from '../../televetGlobal.d-BWYJR391.cjs';
|
|
9
|
+
export { C as CANCELLATION_POLICY_VERSION_MAX, d as CANCEL_REASON_MAX, e as CONSULT_KINDS, f as CONSULT_STATUSES, g as ConsultKind, h as ConsultStatus, M as MEDIA_REFS_MAX, R as REASON_TEXT_MAX, i as TERMINAL_CONSULT_STATUSES, j as TelevetBookingBody, k as TelevetBookingEntitlement, l as TelevetCancellationPolicy, m as TelevetClinician, n as TelevetSlotHold, o as TelevetStatePolicy, p as TelevetTriageVerdict, q as isWellFormedStateCode } from '../../televetGlobal.d-BWYJR391.cjs';
|
|
10
10
|
import { V as VetVisitIntent } from '../../visitIntent.d-D7_yVp1I.cjs';
|
|
11
|
-
import { b as TelevetPrimaryVet, a as TelevetMediaPicker, T as TelevetCalendarWriter } from '../../IntakeMedia.d-
|
|
12
|
-
export { e as TelevetBookedScreen, f as TelevetBookedScreenProps, c as TelevetCalendarEvent, g as TelevetEmergencyExits, h as TelevetIntakeMedia, d as TelevetIntakeMediaItem, i as TelevetIntakeMediaProps, t as televetConsultCalendarKey } from '../../IntakeMedia.d-
|
|
11
|
+
import { b as TelevetPrimaryVet, a as TelevetMediaPicker, T as TelevetCalendarWriter } from '../../IntakeMedia.d-Dqc5V_YH.cjs';
|
|
12
|
+
export { e as TelevetBookedScreen, f as TelevetBookedScreenProps, c as TelevetCalendarEvent, g as TelevetEmergencyExits, h as TelevetIntakeMedia, d as TelevetIntakeMediaItem, i as TelevetIntakeMediaProps, t as televetConsultCalendarKey } from '../../IntakeMedia.d-Dqc5V_YH.cjs';
|
|
13
13
|
export { b as VetCallCredential, c as VetCallJoinRefusal, d as VetCallLimits, p as parseVetCallCredential, v as vetCallJoinReason, e as vetCallJoinRefusal } from '../../callRoom.d-B1DoYdJe.cjs';
|
|
14
14
|
export { E as EverfurError, a as EverfurErrorCategory, b as EverfurErrorCode } from '../../EverfurError.d-8NHtlgzA.cjs';
|
|
15
15
|
export { E as EverfurResult } from '../../EverfurResult.d-BFH-3s6E.cjs';
|
|
16
|
-
export { W as WidgetPet } from '../../petsRepository.d-
|
|
17
|
-
import '../../requestFunnel.d-
|
|
16
|
+
export { W as WidgetPet } from '../../petsRepository.d-tZADfKA1.cjs';
|
|
17
|
+
import '../../requestFunnel.d-C4abgvt9.cjs';
|
|
18
18
|
import '../../ErrorPolicyPort.d-DirW9hgO.cjs';
|
|
19
|
-
import '../../config.d-
|
|
20
|
-
import '../../identity.d-
|
|
19
|
+
import '../../config.d-jCmrhM4a.cjs';
|
|
20
|
+
import '../../identity.d-CA7mW59I.cjs';
|
|
21
21
|
import '../../TelemetryPort.d-BDNr00hu.cjs';
|
|
22
22
|
import '../../profile.d-CSs1wlXT.cjs';
|
|
23
23
|
|
|
@@ -547,11 +547,13 @@ interface TelevetSlotPickerProps {
|
|
|
547
547
|
declare function TelevetSlotPicker({ slots, busySlotId, onPick, selectedSlot, ListHeaderComponent, rowTestIdPrefix, testID, periodLabels, }: TelevetSlotPickerProps): ReactNode;
|
|
548
548
|
|
|
549
549
|
/** One "label ... value" row in the summary card. */
|
|
550
|
-
declare function TelevetSummaryRow({ label, value, last, action, testID, }: {
|
|
550
|
+
declare function TelevetSummaryRow({ label, value, last, action, note, testID, }: {
|
|
551
551
|
readonly label: string;
|
|
552
552
|
readonly value: string;
|
|
553
553
|
/** The last row draws no divider, so the card does not end on a line. */
|
|
554
554
|
readonly last?: boolean;
|
|
555
|
+
/** One plain line under the value (a vet tech's "can't prescribe"). Absent, the row is the value alone. */
|
|
556
|
+
readonly note?: string | null | undefined;
|
|
555
557
|
/** A control at the row's end (the review's "Change" on When). */
|
|
556
558
|
readonly action?: ReactNode;
|
|
557
559
|
readonly testID?: string;
|
|
@@ -3,21 +3,21 @@ import { ReactNode, ComponentType, ReactElement } from 'react';
|
|
|
3
3
|
import { StyleProp, ViewStyle } from 'react-native';
|
|
4
4
|
import { P as PetRef } from '../../ids.d-B2GAAifq.js';
|
|
5
5
|
export { B as Brand, _ as __brand } from '../../ids.d-B2GAAifq.js';
|
|
6
|
-
import { T as TelevetEmptyRosterCause, a as TelevetStateInterestAction$1, b as TelevetMediaShortfall, c as TelevetBookingStep, d as TelevetBookingContext, e as TelevetBookingController, f as TelevetTriageRead, g as TelevetStateInterestWrite, h as TelevetVetThreadTarget, i as TelevetDayPeriod } from '../../bookingCopy.d-
|
|
7
|
-
export { C as CONSULT_MINUTES, N as NO_MEDIA_SHORTFALL, j as TELEVET_BOOKING_BASE, k as TELEVET_BOOKING_COPY, l as TELEVET_BOOKING_STEPS, m as TELEVET_CONSULT_PAGE_LIMIT, n as TELEVET_JOIN_CLOSES_MINUTES_AFTER, o as TELEVET_JOIN_OPENS_MINUTES_BEFORE, p as TELEVET_MESSAGE_THREADS_PATH, q as TelevetAttachmentMeta, r as TelevetAttachmentPolicy, s as TelevetBookingAction, t as TelevetBookingControllerDeps, u as TelevetBookingCopy, v as TelevetBookingDraft, w as TelevetBookingFailure, x as TelevetBookingRefusal, y as TelevetBookingState, z as TelevetEarlyTriage, A as TelevetEmptyRosterView, B as TelevetJoinReadiness, D as TelevetJoinState, E as TelevetMediaRefusal, F as TelevetRead, G as TelevetStateInterestReason, H as TelevetWrite, U as UpcomingTelevetVisitState, I as UseVetThreadOptions, V as VET_MESSAGES_COPY, J as VET_MESSAGE_CONTENT_MAX, K as VET_MESSAGE_PAGE_DEFAULT, L as VET_MESSAGE_PAGE_MAX, M as VetMessage, O as VetMessagePage, P as VetMessageRole, Q as VetMessagesAvailability, R as VetSendFailure, S as VetThread, W as VetThreadState, X as VetThreadsState, Y as VisitSummary, Z as VisitSummaryMedication, _ as VisitSummaryState, $ as attestation, a0 as canConfirm, a1 as canManageTelevetVisit, a2 as createTelevetBookingController, a3 as currentStep, a4 as emptyTelevetDraft, a5 as formatVisitRange, a6 as formatWhen, a7 as formatWhenWithDay, a8 as hasPreviousStep, a9 as initialTelevetBookingState, aa as isHoldExpired, ab as isMediaShortfallEmpty, ac as isSkipped, ad as isTelevetBookingCopyReady, ae as isVetMessagesDark, af as isVetThreadVetFirst, ag as mediaShortfallFromUnsentPicks, ah as splitTelevetVisits, ai as televetBookingKey, aj as televetBookingReducer, ak as televetBookingRefusal, al as televetCancelCall, am as televetConsultCall, an as televetEmptyRosterCause, ao as televetEmptyRosterView, ap as televetHoldCall, aq as televetJoinCall, ar as televetJoinOpensAtMs, as as televetJoinReadiness, at as televetMediaShortfallLines, au as televetRescheduleCall, av as televetThreadMessagesCall, aw as televetThreadReadCall, ax as televetVisitSummaryCall, ay as useEarlyTriage, az as useStateInterest, aA as useTelevetBookConsult, aB as useTelevetBookingAvailable, aC as useTelevetBookingController, aD as useTelevetBookingEntitlement, aE as useTelevetCancellationPolicy, aF as useTelevetClinicians, aG as useTelevetHoldSlot, aH as useTelevetJoin, aI as useTelevetNextSlot, aJ as useTelevetRescheduleConsult, aK as useTelevetSlots, aL as useTelevetStatePolicy, aM as useUpcomingTelevetVisit, aN as useVetThread, aO as useVetThreads, aP as useVisitSummary, aQ as validateBookingBody, aR as vetThreadPetRef, aS as withUnsentPicks } from '../../bookingCopy.d-
|
|
8
|
-
import { T as TelevetConsult, E as EverfurTelevetFlowRequest, b as TelevetCancelReceipt, c as TelevetSlot } from '../../televetGlobal.d-
|
|
9
|
-
export { C as CANCELLATION_POLICY_VERSION_MAX, d as CANCEL_REASON_MAX, e as CONSULT_KINDS, f as CONSULT_STATUSES, g as ConsultKind, h as ConsultStatus, M as MEDIA_REFS_MAX, R as REASON_TEXT_MAX, i as TERMINAL_CONSULT_STATUSES, j as TelevetBookingBody, k as TelevetBookingEntitlement, l as TelevetCancellationPolicy, m as TelevetClinician, n as TelevetSlotHold, o as TelevetStatePolicy, p as TelevetTriageVerdict, q as isWellFormedStateCode } from '../../televetGlobal.d-
|
|
6
|
+
import { T as TelevetEmptyRosterCause, a as TelevetStateInterestAction$1, b as TelevetMediaShortfall, c as TelevetBookingStep, d as TelevetBookingContext, e as TelevetBookingController, f as TelevetTriageRead, g as TelevetStateInterestWrite, h as TelevetVetThreadTarget, i as TelevetDayPeriod } from '../../bookingCopy.d-BlMWlvgv.js';
|
|
7
|
+
export { C as CONSULT_MINUTES, N as NO_MEDIA_SHORTFALL, j as TELEVET_BOOKING_BASE, k as TELEVET_BOOKING_COPY, l as TELEVET_BOOKING_STEPS, m as TELEVET_CONSULT_PAGE_LIMIT, n as TELEVET_JOIN_CLOSES_MINUTES_AFTER, o as TELEVET_JOIN_OPENS_MINUTES_BEFORE, p as TELEVET_MESSAGE_THREADS_PATH, q as TelevetAttachmentMeta, r as TelevetAttachmentPolicy, s as TelevetBookingAction, t as TelevetBookingControllerDeps, u as TelevetBookingCopy, v as TelevetBookingDraft, w as TelevetBookingFailure, x as TelevetBookingRefusal, y as TelevetBookingState, z as TelevetEarlyTriage, A as TelevetEmptyRosterView, B as TelevetJoinReadiness, D as TelevetJoinState, E as TelevetMediaRefusal, F as TelevetRead, G as TelevetStateInterestReason, H as TelevetWrite, U as UpcomingTelevetVisitState, I as UseVetThreadOptions, V as VET_MESSAGES_COPY, J as VET_MESSAGE_CONTENT_MAX, K as VET_MESSAGE_PAGE_DEFAULT, L as VET_MESSAGE_PAGE_MAX, M as VetMessage, O as VetMessagePage, P as VetMessageRole, Q as VetMessagesAvailability, R as VetSendFailure, S as VetThread, W as VetThreadState, X as VetThreadsState, Y as VisitSummary, Z as VisitSummaryMedication, _ as VisitSummaryState, $ as attestation, a0 as canConfirm, a1 as canManageTelevetVisit, a2 as createTelevetBookingController, a3 as currentStep, a4 as emptyTelevetDraft, a5 as formatVisitRange, a6 as formatWhen, a7 as formatWhenWithDay, a8 as hasPreviousStep, a9 as initialTelevetBookingState, aa as isHoldExpired, ab as isMediaShortfallEmpty, ac as isSkipped, ad as isTelevetBookingCopyReady, ae as isVetMessagesDark, af as isVetThreadVetFirst, ag as mediaShortfallFromUnsentPicks, ah as splitTelevetVisits, ai as televetBookingKey, aj as televetBookingReducer, ak as televetBookingRefusal, al as televetCancelCall, am as televetConsultCall, an as televetEmptyRosterCause, ao as televetEmptyRosterView, ap as televetHoldCall, aq as televetJoinCall, ar as televetJoinOpensAtMs, as as televetJoinReadiness, at as televetMediaShortfallLines, au as televetRescheduleCall, av as televetThreadMessagesCall, aw as televetThreadReadCall, ax as televetVisitSummaryCall, ay as useEarlyTriage, az as useStateInterest, aA as useTelevetBookConsult, aB as useTelevetBookingAvailable, aC as useTelevetBookingController, aD as useTelevetBookingEntitlement, aE as useTelevetCancellationPolicy, aF as useTelevetClinicians, aG as useTelevetHoldSlot, aH as useTelevetJoin, aI as useTelevetNextSlot, aJ as useTelevetRescheduleConsult, aK as useTelevetSlots, aL as useTelevetStatePolicy, aM as useUpcomingTelevetVisit, aN as useVetThread, aO as useVetThreads, aP as useVisitSummary, aQ as validateBookingBody, aR as vetThreadPetRef, aS as withUnsentPicks } from '../../bookingCopy.d-BlMWlvgv.js';
|
|
8
|
+
import { T as TelevetConsult, E as EverfurTelevetFlowRequest, b as TelevetCancelReceipt, c as TelevetSlot } from '../../televetGlobal.d-B0_jbCtC.js';
|
|
9
|
+
export { C as CANCELLATION_POLICY_VERSION_MAX, d as CANCEL_REASON_MAX, e as CONSULT_KINDS, f as CONSULT_STATUSES, g as ConsultKind, h as ConsultStatus, M as MEDIA_REFS_MAX, R as REASON_TEXT_MAX, i as TERMINAL_CONSULT_STATUSES, j as TelevetBookingBody, k as TelevetBookingEntitlement, l as TelevetCancellationPolicy, m as TelevetClinician, n as TelevetSlotHold, o as TelevetStatePolicy, p as TelevetTriageVerdict, q as isWellFormedStateCode } from '../../televetGlobal.d-B0_jbCtC.js';
|
|
10
10
|
import { V as VetVisitIntent } from '../../visitIntent.d-D7_yVp1I.js';
|
|
11
|
-
import { b as TelevetPrimaryVet, a as TelevetMediaPicker, T as TelevetCalendarWriter } from '../../IntakeMedia.d-
|
|
12
|
-
export { e as TelevetBookedScreen, f as TelevetBookedScreenProps, c as TelevetCalendarEvent, g as TelevetEmergencyExits, h as TelevetIntakeMedia, d as TelevetIntakeMediaItem, i as TelevetIntakeMediaProps, t as televetConsultCalendarKey } from '../../IntakeMedia.d-
|
|
11
|
+
import { b as TelevetPrimaryVet, a as TelevetMediaPicker, T as TelevetCalendarWriter } from '../../IntakeMedia.d-DNUAks9E.js';
|
|
12
|
+
export { e as TelevetBookedScreen, f as TelevetBookedScreenProps, c as TelevetCalendarEvent, g as TelevetEmergencyExits, h as TelevetIntakeMedia, d as TelevetIntakeMediaItem, i as TelevetIntakeMediaProps, t as televetConsultCalendarKey } from '../../IntakeMedia.d-DNUAks9E.js';
|
|
13
13
|
export { b as VetCallCredential, c as VetCallJoinRefusal, d as VetCallLimits, p as parseVetCallCredential, v as vetCallJoinReason, e as vetCallJoinRefusal } from '../../callRoom.d-Dqm1rUqT.js';
|
|
14
14
|
export { E as EverfurError, a as EverfurErrorCategory, b as EverfurErrorCode } from '../../EverfurError.d-8NHtlgzA.js';
|
|
15
15
|
export { E as EverfurResult } from '../../EverfurResult.d-D_-254ZY.js';
|
|
16
|
-
export { W as WidgetPet } from '../../petsRepository.d-
|
|
17
|
-
import '../../requestFunnel.d-
|
|
16
|
+
export { W as WidgetPet } from '../../petsRepository.d-CpYWRWFq.js';
|
|
17
|
+
import '../../requestFunnel.d-B8OVGh0p.js';
|
|
18
18
|
import '../../ErrorPolicyPort.d-68yrE3BE.js';
|
|
19
|
-
import '../../config.d-
|
|
20
|
-
import '../../identity.d-
|
|
19
|
+
import '../../config.d-N5Xzy53V.js';
|
|
20
|
+
import '../../identity.d-DIOnFzXL.js';
|
|
21
21
|
import '../../TelemetryPort.d-BDNr00hu.js';
|
|
22
22
|
import '../../profile.d-CSs1wlXT.js';
|
|
23
23
|
|
|
@@ -547,11 +547,13 @@ interface TelevetSlotPickerProps {
|
|
|
547
547
|
declare function TelevetSlotPicker({ slots, busySlotId, onPick, selectedSlot, ListHeaderComponent, rowTestIdPrefix, testID, periodLabels, }: TelevetSlotPickerProps): ReactNode;
|
|
548
548
|
|
|
549
549
|
/** One "label ... value" row in the summary card. */
|
|
550
|
-
declare function TelevetSummaryRow({ label, value, last, action, testID, }: {
|
|
550
|
+
declare function TelevetSummaryRow({ label, value, last, action, note, testID, }: {
|
|
551
551
|
readonly label: string;
|
|
552
552
|
readonly value: string;
|
|
553
553
|
/** The last row draws no divider, so the card does not end on a line. */
|
|
554
554
|
readonly last?: boolean;
|
|
555
|
+
/** One plain line under the value (a vet tech's "can't prescribe"). Absent, the row is the value alone. */
|
|
556
|
+
readonly note?: string | null | undefined;
|
|
555
557
|
/** A control at the row's end (the review's "Change" on When). */
|
|
556
558
|
readonly action?: ReactNode;
|
|
557
559
|
readonly testID?: string;
|