@everfur/sdk 0.15.1 → 0.16.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 +122 -0
- package/dist/{DepthViews.d-BuEWI6Ln.d.ts → DepthViews.d-A7S-XYiI.d.ts} +1 -1
- package/dist/{DepthViews.d--1daZblh.d.cts → DepthViews.d-C4TIZDfz.d.cts} +1 -1
- package/dist/{DepthViews.d-CKTnEeUo.d.ts → DepthViews.d-CNjaHLAS.d.ts} +1 -1
- package/dist/{DepthViews.d-PuBGdAYk.d.cts → DepthViews.d-DapfRz1S.d.cts} +1 -1
- package/dist/{RecordsPage.d-CBB8sfoY.d.ts → RecordsPage.d-6WMbieaV.d.ts} +1 -1
- package/dist/{RecordsPage.d-Dq5gpQG0.d.cts → RecordsPage.d-B2gLf8RH.d.cts} +1 -1
- package/dist/animations/index.d.cts +5 -5
- package/dist/animations/index.d.ts +5 -5
- package/dist/{Chat.d-BlsnQwCQ.d.ts → appStateLifecycle.d-B7L427MF.d.ts} +64 -141
- package/dist/{Chat.d-BO5iJsR2.d.cts → appStateLifecycle.d-CWedOJq4.d.cts} +64 -141
- package/dist/{attachments.d-DRHsJkni.d.cts → attachments.d-BARh-PrJ.d.cts} +24 -6
- package/dist/{attachments.d-DFP9yvz9.d.ts → attachments.d-CB0R1_vK.d.ts} +24 -6
- package/dist/{attachments.d-C2nkIyDB.d.ts → attachments.d-CPgp4_W-.d.ts} +2 -2
- package/dist/{attachments.d-DRUC35Ti.d.cts → attachments.d-DeoaCEMD.d.cts} +2 -2
- package/dist/{bookingCopy.d-CFL-1Be2.d.ts → bookingCopy.d-BakTjvWw.d.ts} +2 -2
- package/dist/{bookingCopy.d-bF_QknDC.d.cts → bookingCopy.d-CVmpuk9C.d.cts} +2 -2
- package/dist/{casesRepository.d-C__BnffJ.d.ts → casesRepository.d-CuokarTU.d.ts} +1 -1
- package/dist/{casesRepository.d-BMOnT1fg.d.cts → casesRepository.d-DKRLtYb8.d.cts} +1 -1
- package/dist/chat/index.cjs +227 -213
- package/dist/chat/index.d.cts +11 -9
- package/dist/chat/index.d.ts +11 -9
- package/dist/chat/index.js +228 -214
- package/dist/client/index.cjs +1 -1
- package/dist/client/index.d.cts +6 -6
- package/dist/client/index.d.ts +6 -6
- package/dist/client/index.js +1 -1
- package/dist/{clinicBatch.d-D68RYvc3.d.ts → clinicBatch.d-BP_Rpvcy.d.ts} +2 -2
- package/dist/{clinicBatch.d-C5deJ4xY.d.cts → clinicBatch.d-BTDdhMQ2.d.cts} +2 -2
- package/dist/{config.d-BQgrIDdu.d.cts → config.d-84fNJFv9.d.cts} +1 -1
- package/dist/{config.d-XSMThgVj.d.ts → config.d-B4-Mrwq2.d.ts} +1 -1
- package/dist/consent/index.d.cts +5 -5
- package/dist/consent/index.d.ts +5 -5
- package/dist/{context.d-Ba8YyJpk.d.cts → context.d-87MMrNm6.d.cts} +5 -5
- package/dist/{context.d-xoh5vmxS.d.ts → context.d-rNGMZH8T.d.ts} +5 -5
- package/dist/{copy.d-Cq-s-UUv.d.cts → copy.d-CJOLhJac.d.cts} +2 -2
- package/dist/{copy.d-HV9fU5kh.d.ts → copy.d-DbwWriBp.d.ts} +2 -2
- package/dist/core/index.cjs +1 -1
- package/dist/core/index.d.cts +13 -13
- package/dist/core/index.d.ts +13 -13
- package/dist/core/index.js +1 -1
- package/dist/{depth.d-DYnkz8Re.d.cts → depth.d-CXpPxNSK.d.cts} +2 -2
- package/dist/{depth.d-D7kKiYl7.d.ts → depth.d-Dca1T_RH.d.ts} +2 -2
- package/dist/{entitlementRepository.d-DmnUZLl_.d.ts → entitlementRepository.d-BBRYTUlp.d.ts} +2 -2
- package/dist/{entitlementRepository.d-B_kEPLhz.d.cts → entitlementRepository.d-DBhzBQjZ.d.cts} +2 -2
- package/dist/{focus.d-BHm_QtQ9.d.cts → focus.d-BQnOVAql.d.cts} +3 -3
- package/dist/{focus.d-CjL6Cj0m.d.ts → focus.d-BZ2sEpbU.d.ts} +3 -3
- package/dist/health-plan/index.cjs +134 -131
- package/dist/health-plan/index.d.cts +77 -24
- package/dist/health-plan/index.d.ts +77 -24
- package/dist/health-plan/index.js +134 -131
- package/dist/{idempotency.d-BSRK8od4.d.cts → idempotency.d-9wNNohIA.d.cts} +1 -1
- package/dist/{idempotency.d-CFc4CCc9.d.ts → idempotency.d-BdB17veP.d.ts} +1 -1
- package/dist/{identity.d-Be2Es9Td.d.ts → identity.d-DxNvhj3a.d.ts} +1 -1
- package/dist/{identity.d-HbwYQ4-z.d.cts → identity.d-nRZBzkG2.d.cts} +1 -1
- package/dist/index.cjs +232 -218
- package/dist/index.d.cts +14 -12
- package/dist/index.d.ts +14 -12
- package/dist/index.js +233 -219
- package/dist/{introEvents.d-Dr34KIaD.d.cts → introEvents.d-CQeiUeLn.d.cts} +1 -1
- package/dist/{introEvents.d-DflJ6J9H.d.ts → introEvents.d-bkIxpIKr.d.ts} +1 -1
- package/dist/notifications/index.d.cts +4 -4
- package/dist/notifications/index.d.ts +4 -4
- package/dist/{optInView.d-D23o1gtT.d.cts → optInView.d-BbVUUeoG.d.cts} +2 -2
- package/dist/{optInView.d-3mbj1mR6.d.ts → optInView.d-DVJcB4Gp.d.ts} +2 -2
- package/dist/{parse.d-BERabxHw.d.ts → parse.d-CGeJrcAC.d.ts} +1 -1
- package/dist/{parse.d-4lUXdmvY.d.cts → parse.d-Dk0BasyK.d.cts} +1 -1
- package/dist/{pets.d-D_ayuqjp.d.ts → pets.d-DBopbeRe.d.ts} +1 -1
- package/dist/{pets.d-CHU0UbXt.d.cts → pets.d-DVptPgi0.d.cts} +1 -1
- package/dist/{petsRepository.d-DUaAWoTv.d.ts → petsRepository.d-BtuooSOW.d.ts} +1 -1
- package/dist/{petsRepository.d-Bwfe8yuR.d.cts → petsRepository.d-Daef7u0o.d.cts} +1 -1
- package/dist/{ports.d-DzEJMVRs.d.ts → ports.d-BxCVSbSi.d.ts} +4 -4
- package/dist/{ports.d-ClbPRUtx.d.cts → ports.d-CAT70bVD.d.cts} +4 -4
- package/dist/records/depth/index.cjs +1 -1
- 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 -1
- package/dist/records/index.cjs +242 -200
- package/dist/records/index.d.cts +169 -73
- package/dist/records/index.d.ts +169 -73
- package/dist/records/index.js +243 -201
- package/dist/{requestFunnel.d-YabU6G-Z.d.ts → requestFunnel.d-Cxt0JqYx.d.ts} +2 -2
- package/dist/{requestFunnel.d-JoqddYSx.d.cts → requestFunnel.d-mEu6B-n8.d.cts} +2 -2
- package/dist/{runtimeTypes.d-DQTBJAbk.d.ts → runtimeTypes.d-Bkcj_XQy.d.ts} +4 -4
- package/dist/{runtimeTypes.d-Cv38YuzP.d.cts → runtimeTypes.d-D_qHJROH.d.cts} +4 -4
- package/dist/{screenProps.d-C-AuHoyF.d.cts → screenProps.d-CR1lrpzR.d.cts} +2 -2
- package/dist/{screenProps.d-BuJLzFkN.d.ts → screenProps.d-D9n-ancr.d.ts} +2 -2
- package/dist/server/events/index.cjs +1 -1
- package/dist/server/events/index.d.cts +2 -2
- package/dist/server/events/index.d.ts +2 -2
- package/dist/server/events/index.js +1 -1
- package/dist/server/index.cjs +1 -1
- package/dist/server/index.d.cts +3 -3
- package/dist/server/index.d.ts +3 -3
- package/dist/server/index.js +1 -1
- package/dist/shop/index.cjs +16 -16
- package/dist/shop/index.d.cts +12 -3
- package/dist/shop/index.d.ts +12 -3
- package/dist/shop/index.js +16 -16
- package/dist/tabs/index.cjs +4 -4
- package/dist/tabs/index.d.cts +34 -15
- package/dist/tabs/index.d.ts +34 -15
- package/dist/tabs/index.js +5 -5
- package/dist/{tabsModel.d-BfIQg6yS.d.ts → tabsModel.d-B7QMug1u.d.cts} +1 -17
- package/dist/{tabsModel.d-BfIQg6yS.d.cts → tabsModel.d-B7QMug1u.d.ts} +1 -17
- package/dist/televet/booking/index.d.cts +6 -6
- package/dist/televet/booking/index.d.ts +6 -6
- package/dist/testing/index.d.cts +1 -1
- package/dist/testing/index.d.ts +1 -1
- package/dist/testing/rn/index.cjs +1 -1
- package/dist/testing/rn/index.d.cts +7 -7
- package/dist/testing/rn/index.d.ts +7 -7
- package/dist/testing/rn/index.js +1 -1
- package/dist/testing/web/index.d.cts +7 -7
- package/dist/testing/web/index.d.ts +7 -7
- package/dist/texting/index.cjs +21 -16
- package/dist/texting/index.d.cts +5 -5
- package/dist/texting/index.d.ts +5 -5
- package/dist/texting/index.js +22 -17
- package/dist/threadOptions.d-6hfQS1x7.d.cts +55 -0
- package/dist/threadOptions.d-6hfQS1x7.d.ts +55 -0
- package/dist/threadOptions.d-BEG-LZrC.d.cts +147 -0
- package/dist/threadOptions.d-BerQM1Ql.d.ts +147 -0
- package/dist/{threadOptions.d-8x_1evAr.d.ts → threadOptions.d-BgBvSIw8.d.ts} +6 -40
- package/dist/{threadOptions.d-DBrmOwmb.d.cts → threadOptions.d-P9v7I7va.d.cts} +6 -40
- package/dist/{timelineRows.d-B6lLC8Ud.d.cts → timelineRows.d-C04lp_Vj.d.cts} +1 -1
- package/dist/{timelineRows.d-Brlkti-G.d.ts → timelineRows.d-_7JemrY-.d.ts} +1 -1
- package/dist/{planSignals.d-CON9gTvJ.d.ts → useHealthPlanSubscription.d-CUbHE6eK.d.ts} +81 -3
- package/dist/{planSignals.d-Dha2CMDF.d.cts → useHealthPlanSubscription.d-OhLZpn-n.d.cts} +81 -3
- package/dist/{usePresentation.d-Bne14SlX.d.ts → usePresentation.d-CBtBx38t.d.ts} +40 -40
- package/dist/{usePresentation.d-BcdCIuEU.d.cts → usePresentation.d-YkJeq9mf.d.cts} +40 -40
- package/dist/{useRecordsDepth.d-DAa169VY.d.cts → useRecordsDepth.d-FTImzp6T.d.cts} +1 -1
- package/dist/{useRecordsDepth.d-Cd6J03o5.d.ts → useRecordsDepth.d-_rqDIvoq.d.ts} +1 -1
- package/dist/{view.d-3d5_O7Xk.d.cts → view.d-Dd6AfMvG.d.cts} +3 -3
- package/dist/{view.d-DkGM8GNA.d.ts → view.d-gmYinlac.d.ts} +3 -3
- package/dist/web/consent/index.d.cts +5 -5
- package/dist/web/consent/index.d.ts +5 -5
- package/dist/web/health-plan/index.cjs +1 -1
- package/dist/web/health-plan/index.d.cts +15 -69
- package/dist/web/health-plan/index.d.ts +15 -69
- package/dist/web/health-plan/index.js +1 -1
- package/dist/web/index.cjs +5 -5
- package/dist/web/index.d.cts +26 -43
- package/dist/web/index.d.ts +26 -43
- package/dist/web/index.js +5 -5
- package/dist/web/intro/index.d.cts +6 -6
- package/dist/web/intro/index.d.ts +6 -6
- package/dist/web/notifications/index.d.cts +3 -3
- package/dist/web/notifications/index.d.ts +3 -3
- package/dist/web/records/depth/index.d.cts +9 -9
- package/dist/web/records/depth/index.d.ts +9 -9
- package/dist/web/records/index.d.cts +11 -11
- package/dist/web/records/index.d.ts +11 -11
- package/dist/web/records-sheet/index.cjs +10 -10
- package/dist/web/records-sheet/index.js +10 -10
- package/dist/web/shop/index.cjs +11 -11
- package/dist/web/shop/index.d.cts +3 -3
- package/dist/web/shop/index.d.ts +3 -3
- package/dist/web/shop/index.js +11 -11
- package/dist/web/televet/booking/index.d.cts +6 -6
- package/dist/web/televet/booking/index.d.ts +6 -6
- package/dist/web/texting/index.d.cts +5 -5
- package/dist/web/texting/index.d.ts +5 -5
- package/package.json +6 -2
|
@@ -3,143 +3,18 @@ import { ReactNode } from 'react';
|
|
|
3
3
|
import { StyleProp, ViewStyle } from 'react-native';
|
|
4
4
|
import { P as PetRef, C as ConversationId } from './ids.d-B2GAAifq.cjs';
|
|
5
5
|
import { i as EverfurPresentationInput } from './presentation.d-vy8kTGfR.cjs';
|
|
6
|
-
import { a as ChatCheckinTarget } from './ports.d-
|
|
7
|
-
import { W as WidgetPet, P as PetProfileInput } from './petsRepository.d-
|
|
6
|
+
import { a as ChatCheckinTarget } from './ports.d-CAT70bVD.cjs';
|
|
7
|
+
import { W as WidgetPet, P as PetProfileInput } from './petsRepository.d-Daef7u0o.cjs';
|
|
8
8
|
import { E as EverfurStarterPrompt } from './quickPrompts.d-NM_81Jc1.cjs';
|
|
9
9
|
import { L as LifecyclePort } from './LifecyclePort.d-Cr1p33a7.cjs';
|
|
10
|
-
import { U as UrgencyDisplayLevel, E as EverfurChatDraftStore } from './attachments.d-
|
|
10
|
+
import { U as UrgencyDisplayLevel, E as EverfurChatDraftStore, b as ChatFollowUpPolicy } from './attachments.d-BARh-PrJ.cjs';
|
|
11
11
|
import { F as FileHandle } from './ports.d-BX4f4UsB.cjs';
|
|
12
|
+
import { g as EverfurChatOpeningCard, a as EverfurChatAnswerCards, f as EverfurChatHistorySheet, e as EverfurChatHistoryBar, c as EverfurChatEmptyState } from './threadOptions.d-BEG-LZrC.cjs';
|
|
13
|
+
import { a as EverfurChatEmptyHeaderContext, b as EverfurChatTopCard } from './threadOptions.d-6hfQS1x7.cjs';
|
|
12
14
|
|
|
13
15
|
/** Where a picked image comes from: the host's photo library, or its camera. */
|
|
14
16
|
type AttachmentSource = 'photo' | 'camera';
|
|
15
17
|
|
|
16
|
-
/**
|
|
17
|
-
* The history bar: a "Chats" control with the member's thread count that opens the history, and a "New chat"
|
|
18
|
-
* control. For a surface that hides the SDK header and still wants the member's past chats.
|
|
19
|
-
*/
|
|
20
|
-
interface EverfurChatHistoryBar {
|
|
21
|
-
/** The history control's words ("Chats"). */
|
|
22
|
-
readonly chats: string;
|
|
23
|
-
/** The new-chat control's words ("New chat"). */
|
|
24
|
-
readonly newChat: string;
|
|
25
|
-
/** Draw the two icons your way. */
|
|
26
|
-
readonly renderIcon?: (icon: 'history' | 'edit') => ReactNode;
|
|
27
|
-
/** Your own control after "Chats". Absent, nothing is drawn. */
|
|
28
|
-
readonly extra?: ReactNode;
|
|
29
|
-
}
|
|
30
|
-
/** The empty thread's own title and chip fills. Absent, the empty state is Everfur's own. */
|
|
31
|
-
interface EverfurChatEmptyState {
|
|
32
|
-
/** The title over the starter chips, in place of "What can we help {pet} with today?". */
|
|
33
|
-
readonly title?: string;
|
|
34
|
-
/**
|
|
35
|
-
* Fills for the chips that bring none of their own, taken in turn (the first chip the first fill, and round
|
|
36
|
-
* again). Each is a fill and its ink. Absent, Raph's v3 cycle on a light theme; empty, the theme's paint.
|
|
37
|
-
*/
|
|
38
|
-
readonly chipTints?: readonly {
|
|
39
|
-
readonly tint: string;
|
|
40
|
-
readonly ink?: string;
|
|
41
|
-
}[];
|
|
42
|
-
}
|
|
43
|
-
/** One card under an answer in the cards answer style: a record, a stat, or a link to one of your screens. */
|
|
44
|
-
interface EverfurChatAnswerCard {
|
|
45
|
-
/** Stable key within the answer. */
|
|
46
|
-
readonly key: string;
|
|
47
|
-
readonly title: string;
|
|
48
|
-
/** The small line under the title. */
|
|
49
|
-
readonly meta?: string;
|
|
50
|
-
/** A status pill. */
|
|
51
|
-
readonly pill?: {
|
|
52
|
-
readonly label: string;
|
|
53
|
-
readonly tone?: string;
|
|
54
|
-
};
|
|
55
|
-
/** A stat card's value: drawn in place of the pill and the chevron. */
|
|
56
|
-
readonly value?: {
|
|
57
|
-
readonly amount: string;
|
|
58
|
-
readonly unit?: string;
|
|
59
|
-
};
|
|
60
|
-
/** The tile at the start: an icon of yours, or an https image. */
|
|
61
|
-
readonly tile?: {
|
|
62
|
-
readonly icon?: ReactNode;
|
|
63
|
-
readonly imageUrl?: string;
|
|
64
|
-
readonly tone?: string;
|
|
65
|
-
};
|
|
66
|
-
readonly variant?: string;
|
|
67
|
-
/** Given, the card is a button that calls this. Absent, a static card. */
|
|
68
|
-
readonly onPress?: () => void;
|
|
69
|
-
/** A card of your own, drawn in the card's place. If it throws, the slot draws nothing. */
|
|
70
|
-
readonly render?: () => ReactNode;
|
|
71
|
-
}
|
|
72
|
-
/** What `answerCards.cards` receives: the settled answer's text and the question it answered. */
|
|
73
|
-
interface EverfurChatAnswerContext {
|
|
74
|
-
readonly answer: string;
|
|
75
|
-
readonly question: string | null;
|
|
76
|
-
/** The answer's message id, stable for the life of the thread. */
|
|
77
|
-
readonly messageId: string;
|
|
78
|
-
}
|
|
79
|
-
/** The cards answer style's content (used while presentation `chatAnswerStyle` is `cards`). The words are yours. */
|
|
80
|
-
interface EverfurChatAnswerCards {
|
|
81
|
-
/** The line over each answer (an icon and your words). Absent, the assistant's name line. */
|
|
82
|
-
readonly byline?: {
|
|
83
|
-
readonly label: string;
|
|
84
|
-
readonly icon?: ReactNode;
|
|
85
|
-
};
|
|
86
|
-
/** Your cards under a settled answer. A throw draws none. */
|
|
87
|
-
readonly cards?: (context: EverfurChatAnswerContext) => readonly EverfurChatAnswerCard[];
|
|
88
|
-
/** Two feedback chips in place of the footer's thumbs, mapped to thumbs up and thumbs down. */
|
|
89
|
-
readonly feedback?: {
|
|
90
|
-
readonly helpful: string;
|
|
91
|
-
readonly notHelpful: string;
|
|
92
|
-
};
|
|
93
|
-
/** Your own rows at the top of the follow-ups, for the answer it receives. */
|
|
94
|
-
readonly followUpActions?: (context: EverfurChatAnswerContext) => readonly EverfurChatFollowUpAction[];
|
|
95
|
-
/** Draw the chevron your way. Absent, Everfur's glyph. */
|
|
96
|
-
readonly renderIcon?: (icon: 'chevron') => ReactNode;
|
|
97
|
-
}
|
|
98
|
-
/** A row of yours at the top of the follow-ups under an answer. */
|
|
99
|
-
interface EverfurChatFollowUpAction {
|
|
100
|
-
readonly key: string;
|
|
101
|
-
readonly label: string;
|
|
102
|
-
readonly icon?: ReactNode;
|
|
103
|
-
readonly onPress: () => void;
|
|
104
|
-
}
|
|
105
|
-
/**
|
|
106
|
-
* The card at the top of the empty thread (presentation `chatTopCard: "focus"`): one finding, in your words, with
|
|
107
|
-
* an action of yours and a question it can ask in the thread. Its close control folds it into a pill.
|
|
108
|
-
*/
|
|
109
|
-
interface EverfurChatTopCard {
|
|
110
|
-
/** The small heading ("Her focus"). */
|
|
111
|
-
readonly kicker: string;
|
|
112
|
-
/** A source badge ("<your brand> results"). */
|
|
113
|
-
readonly badge?: string;
|
|
114
|
-
readonly title: string;
|
|
115
|
-
/** The finding: a bold lead and the rest of the sentence. */
|
|
116
|
-
readonly lead?: string;
|
|
117
|
-
readonly body?: string;
|
|
118
|
-
/** Your action ("See her Health Plan"). */
|
|
119
|
-
readonly action?: {
|
|
120
|
-
readonly label: string;
|
|
121
|
-
readonly onPress: () => void;
|
|
122
|
-
};
|
|
123
|
-
/** A question the card asks in this thread. */
|
|
124
|
-
readonly ask?: {
|
|
125
|
-
readonly label: string;
|
|
126
|
-
readonly prompt: string;
|
|
127
|
-
};
|
|
128
|
-
/** The close control's accessible name. Absent, the shared `Close`. */
|
|
129
|
-
readonly closeLabel?: string;
|
|
130
|
-
/** The pill's words while the card is closed (defaults to `kicker`). */
|
|
131
|
-
readonly pill?: string;
|
|
132
|
-
/** Draw the close glyph your way. */
|
|
133
|
-
readonly renderIcon?: (icon: 'close') => ReactNode;
|
|
134
|
-
}
|
|
135
|
-
/** The history bottom sheet (presentation `chatHistoryStyle: "sheet"`). */
|
|
136
|
-
interface EverfurChatHistorySheet {
|
|
137
|
-
/** The sheet's small title ("Chats with Ask <your brand>"). Absent, Everfur's history heading. */
|
|
138
|
-
readonly title?: string;
|
|
139
|
-
/** Draw the icons your way. */
|
|
140
|
-
readonly renderIcon?: (icon: 'close' | 'chat' | 'edit') => ReactNode;
|
|
141
|
-
}
|
|
142
|
-
|
|
143
18
|
/**
|
|
144
19
|
* The host's image picker for chat attachments. The SDK depends on no picker or camera module: open your own
|
|
145
20
|
* (for example `expo-image-picker`'s `launchImageLibraryAsync({ mediaTypes: ['images'] })`, or your camera
|
|
@@ -155,7 +30,7 @@ interface EverfurChatAttachments {
|
|
|
155
30
|
readonly pick: (source: AttachmentSource) => Promise<FileHandle | readonly FileHandle[] | null>;
|
|
156
31
|
/** The sources to offer, one popover tile each; default `['photo']`. */
|
|
157
32
|
readonly sources?: readonly AttachmentSource[];
|
|
158
|
-
/** Images per message; default
|
|
33
|
+
/** Images per message; default 5, the web composer's and the server's cap. */
|
|
159
34
|
readonly maxPerMessage?: number;
|
|
160
35
|
}
|
|
161
36
|
|
|
@@ -235,10 +110,12 @@ interface EverfurChatProps {
|
|
|
235
110
|
* Your app's lifecycle signals. Everfur has no socket and no polling here, so a message the platform
|
|
236
111
|
* writes into the thread (a follow-up check-in, a reminder) is not visible until something re-reads it.
|
|
237
112
|
* Tell Everfur when your app comes back to the foreground, when connectivity returns and when a push
|
|
238
|
-
* announced a change, and the thread and the unread dot catch up on that signal alone.
|
|
239
|
-
*
|
|
113
|
+
* announced a change, and the thread and the unread dot catch up on that signal alone. Absent, Everfur uses
|
|
114
|
+
* React Native's own signal (AppState returning to `active` from the background; see `createAppStateLifecycle`).
|
|
115
|
+
* Pass your own port to add connectivity or a push announcement, or `null` to turn the re-read off, in which
|
|
116
|
+
* case chat refreshes only when the user does something.
|
|
240
117
|
*/
|
|
241
|
-
readonly lifecycle?: LifecyclePort;
|
|
118
|
+
readonly lifecycle?: LifecyclePort | null;
|
|
242
119
|
/**
|
|
243
120
|
* Your own storage for an unsent draft. Given, what the user typed and did not send survives leaving this
|
|
244
121
|
* screen; absent, the draft lives in memory for as long as the surface is mounted and nowhere else.
|
|
@@ -290,19 +167,47 @@ interface EverfurChatProps {
|
|
|
290
167
|
/**
|
|
291
168
|
* The layout settings (Raph v3): the answer style, the history style, the top card, the composer style and
|
|
292
169
|
* placeholder, the history bar's place, the general banner, the send button, the follow-up count and the upload
|
|
293
|
-
* control. Each also comes from your console
|
|
294
|
-
* unless the console locks it. `attachments` counts
|
|
295
|
-
*
|
|
296
|
-
* content only and never switch a layout on by
|
|
170
|
+
* control, and the microphone (`chatComposerMic`). Each also comes from your console
|
|
171
|
+
* (render_hints.branding.presentation); a field you set here wins unless the console locks it. `attachments` counts
|
|
172
|
+
* as your explicit `chatComposerUpload: true`, `dictation` as your `chatComposerMic` and `followUpPolicy` as your
|
|
173
|
+
* follow-up count. `topCard`, `answerCards` and `historySheet` are content only and never switch a layout on by
|
|
174
|
+
* themselves.
|
|
297
175
|
*/
|
|
298
176
|
readonly presentation?: EverfurPresentationInput;
|
|
177
|
+
/**
|
|
178
|
+
* Voice dictation on the composer (the device's own speech recognizer, no Everfur service). On by default; the
|
|
179
|
+
* control appears only when your app has the optional `expo-speech-recognition` module installed and the device
|
|
180
|
+
* has a recognizer. `false` is the kill switch.
|
|
181
|
+
*/
|
|
182
|
+
readonly dictation?: boolean;
|
|
183
|
+
/**
|
|
184
|
+
* Your own content for the top of the empty thread, above its title and starter chips (for example a card of the
|
|
185
|
+
* pet's top findings). Rendered only while the thread is empty; if it throws, the empty state draws as usual.
|
|
186
|
+
* Absent, the empty state is Everfur's own. It receives `{ ask }`: a row of your card can ask its question in
|
|
187
|
+
* this thread directly, with no screen in between.
|
|
188
|
+
*/
|
|
189
|
+
readonly renderEmptyHeader?: (context: EverfurChatEmptyHeaderContext) => ReactNode;
|
|
190
|
+
/**
|
|
191
|
+
* Your rule for the follow-ups under a reply: how many (exactly, with `fill`), which backend prompts to drop
|
|
192
|
+
* (`exclude`, for example visit or booking prompts you do not offer), your own prompts to top up with, and a
|
|
193
|
+
* visible `label` over them. Absent, at most three of the backend's, as before.
|
|
194
|
+
*/
|
|
195
|
+
readonly followUpPolicy?: ChatFollowUpPolicy;
|
|
196
|
+
/**
|
|
197
|
+
* The card a notification-opened thread starts with: drawn in place of the first bubble while that bubble is
|
|
198
|
+
* `initialAsk`. Pair it with `initialAsk` (the notification's question). Absent, the bubble draws as usual.
|
|
199
|
+
*/
|
|
200
|
+
readonly initialAskCard?: EverfurChatOpeningCard;
|
|
299
201
|
/**
|
|
300
202
|
* The focus card's content (drawn while `chatTopCard` resolves to `focus`). Absent, the card is built from the
|
|
301
203
|
* pet's Health Plan page focus; no page, no focus, a refused read or a page still loading draws no card.
|
|
302
204
|
*/
|
|
303
205
|
readonly topCard?: EverfurChatTopCard;
|
|
304
|
-
/**
|
|
305
|
-
|
|
206
|
+
/**
|
|
207
|
+
* Opens the pet's Health Plan (your tab or screen), called with the pet (the chat's `petRef`, else the provider's
|
|
208
|
+
* active pet): the plan-built focus card's `See her Health Plan` button.
|
|
209
|
+
*/
|
|
210
|
+
readonly onOpenHealthPlan?: (petRef: PetRef | null) => void;
|
|
306
211
|
/** The cards answer style's content (used while `chatAnswerStyle` resolves to `cards`). */
|
|
307
212
|
readonly answerCards?: EverfurChatAnswerCards;
|
|
308
213
|
/** The history sheet's title and icons (used while `chatHistoryStyle` resolves to `sheet`). */
|
|
@@ -335,4 +240,22 @@ interface EverfurChatProps {
|
|
|
335
240
|
*/
|
|
336
241
|
declare function EverfurChat(props: EverfurChatProps): ReactNode;
|
|
337
242
|
|
|
338
|
-
|
|
243
|
+
/** The host's loader: a thunk that requires the expo-speech-recognition module and returns it. */
|
|
244
|
+
type EverfurDictationLoader = () => unknown;
|
|
245
|
+
/**
|
|
246
|
+
* Turns on the chat composer's microphone on React Native: register the optional `expo-speech-recognition` module's
|
|
247
|
+
* loader once, in your app entry.
|
|
248
|
+
*
|
|
249
|
+
* Pass a thunk that requires the expo-speech-recognition module and returns it; the chat docs ("Dictation") show the
|
|
250
|
+
* exact line.
|
|
251
|
+
*
|
|
252
|
+
* Without it, or where the module has no native side (Expo Go, an older binary), the composer draws no microphone.
|
|
253
|
+
* Passing `null` unregisters it. Registering clears the memo, so a later registration always wins, and a composer
|
|
254
|
+
* already on screen re-reads it (best practice is still to register before the first chat renders).
|
|
255
|
+
*/
|
|
256
|
+
declare function registerEverfurDictation(next: EverfurDictationLoader | null): void;
|
|
257
|
+
|
|
258
|
+
/** The app's foreground edge for EverfurChat: AppState going from `background` back to `active`. */
|
|
259
|
+
declare function createAppStateLifecycle(): LifecyclePort;
|
|
260
|
+
|
|
261
|
+
export { type AttachmentSource as A, EverfurChat as E, type RenderVetAction as R, type EverfurChatAttachments as a, type EverfurChatProps as b, type EverfurDictationLoader as c, createAppStateLifecycle as d, registerEverfurDictation as r };
|
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
import { E as EverfurError } from './EverfurError.d-8NHtlgzA.cjs';
|
|
3
3
|
import { E as EverfurResult } from './EverfurResult.d-BFH-3s6E.cjs';
|
|
4
4
|
import { C as ConversationId, P as PetRef, b as ResponseId } from './ids.d-B2GAAifq.cjs';
|
|
5
|
-
import { f as ChatFeedbackType, l as ChatStatus, i as ChatMessage, c as ChatConversationListOptions, d as ChatConversationPage, g as ChatHistoryOptions, h as ChatMessagePage, a as ChatCheckinTarget, e as ChatFeedbackReceipt } from './ports.d-
|
|
6
|
-
import { C as CheckinAnswer, a as CheckinOutcome } from './casesRepository.d-
|
|
7
|
-
import { i as UrgencyLevel } from './config.d-
|
|
8
|
-
import { W as WidgetPet } from './petsRepository.d-
|
|
5
|
+
import { f as ChatFeedbackType, l as ChatStatus, i as ChatMessage, c as ChatConversationListOptions, d as ChatConversationPage, g as ChatHistoryOptions, h as ChatMessagePage, a as ChatCheckinTarget, e as ChatFeedbackReceipt } from './ports.d-CAT70bVD.cjs';
|
|
6
|
+
import { C as CheckinAnswer, a as CheckinOutcome } from './casesRepository.d-DKRLtYb8.cjs';
|
|
7
|
+
import { i as UrgencyLevel } from './config.d-84fNJFv9.cjs';
|
|
8
|
+
import { W as WidgetPet } from './petsRepository.d-Daef7u0o.cjs';
|
|
9
9
|
import { U as UploadTransport, F as FileHandle } from './ports.d-BX4f4UsB.cjs';
|
|
10
|
-
import { c as AttachmentQueue, d as AttachmentState, A as AttachmentError, b as AttachmentOutcome } from './attachments.d-
|
|
10
|
+
import { c as AttachmentQueue, d as AttachmentState, A as AttachmentError, b as AttachmentOutcome } from './attachments.d-DeoaCEMD.cjs';
|
|
11
11
|
|
|
12
12
|
/** A rating. The footer draws `'up'` and `'down'`; `'neutral'` is still a rating the wire and the hook accept. */
|
|
13
13
|
type ChatSentiment = 'up' | 'neutral' | 'down';
|
|
@@ -163,6 +163,24 @@ interface EverfurChatDraftStore {
|
|
|
163
163
|
/** The three server tiers plus the app's calm `general` tier for an informational turn. */
|
|
164
164
|
type UrgencyDisplayLevel = UrgencyLevel | 'general';
|
|
165
165
|
|
|
166
|
+
/**
|
|
167
|
+
* A host's rule for the follow-ups under a reply (`EverfurChat`'s `followUpPolicy`, opt-in). Without one the
|
|
168
|
+
* surface draws `visibleFollowUps` exactly as before.
|
|
169
|
+
*/
|
|
170
|
+
interface ChatFollowUpPolicy {
|
|
171
|
+
/** How many to draw, 1 to 5. With `fill` the surface draws exactly this many whenever it can. Default 3. */
|
|
172
|
+
readonly count?: number;
|
|
173
|
+
/** Drop a backend prompt this matches (a visit or booking follow-up a host does not offer). */
|
|
174
|
+
readonly exclude?: RegExp | ((prompt: string) => boolean);
|
|
175
|
+
/**
|
|
176
|
+
* The host's own prompts that top the list up to `count` after the backend's (in order, de-duplicated, the
|
|
177
|
+
* `exclude` rule applied too). A function receives the member's last question, so the top-ups can follow it.
|
|
178
|
+
*/
|
|
179
|
+
readonly fill?: readonly string[] | ((lastQuestion: string | null) => readonly string[]);
|
|
180
|
+
/** A visible label over the follow-ups ("Follow-up questions"). Absent, the list keeps only its accessible name. */
|
|
181
|
+
readonly label?: string;
|
|
182
|
+
}
|
|
183
|
+
|
|
166
184
|
/** The pet list state a header or switcher renders from. */
|
|
167
185
|
interface UseEverfurPetsState {
|
|
168
186
|
/** The registered pets, newest first as the server lists them; empty until the first fetch settles. */
|
|
@@ -234,4 +252,4 @@ interface UseChatAttachmentsOptions {
|
|
|
234
252
|
*/
|
|
235
253
|
declare function useChatAttachments(options?: UseChatAttachmentsOptions): UseChatAttachmentsState;
|
|
236
254
|
|
|
237
|
-
export { type ChatFeedbackReason as C, type EverfurChatDraftStore as E, type UrgencyDisplayLevel as U, type ChatFeedbackReasonOption as a, type
|
|
255
|
+
export { type ChatFeedbackReason as C, type EverfurChatDraftStore as E, type UrgencyDisplayLevel as U, type ChatFeedbackReasonOption as a, type ChatFollowUpPolicy as b, type ChatSentiment as c, type UseChatAttachmentsOptions as d, type UseChatAttachmentsState as e, type UseEverfurChatState as f, type UseEverfurPetsState as g, useEverfurChat as h, useEverfurPets as i, useChatAttachments as u };
|
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
import { E as EverfurError } from './EverfurError.d-8NHtlgzA.js';
|
|
3
3
|
import { E as EverfurResult } from './EverfurResult.d-D_-254ZY.js';
|
|
4
4
|
import { C as ConversationId, P as PetRef, b as ResponseId } from './ids.d-B2GAAifq.js';
|
|
5
|
-
import { f as ChatFeedbackType, l as ChatStatus, i as ChatMessage, c as ChatConversationListOptions, d as ChatConversationPage, g as ChatHistoryOptions, h as ChatMessagePage, a as ChatCheckinTarget, e as ChatFeedbackReceipt } from './ports.d-
|
|
6
|
-
import { C as CheckinAnswer, a as CheckinOutcome } from './casesRepository.d-
|
|
7
|
-
import { i as UrgencyLevel } from './config.d-
|
|
8
|
-
import { W as WidgetPet } from './petsRepository.d-
|
|
5
|
+
import { f as ChatFeedbackType, l as ChatStatus, i as ChatMessage, c as ChatConversationListOptions, d as ChatConversationPage, g as ChatHistoryOptions, h as ChatMessagePage, a as ChatCheckinTarget, e as ChatFeedbackReceipt } from './ports.d-BxCVSbSi.js';
|
|
6
|
+
import { C as CheckinAnswer, a as CheckinOutcome } from './casesRepository.d-CuokarTU.js';
|
|
7
|
+
import { i as UrgencyLevel } from './config.d-B4-Mrwq2.js';
|
|
8
|
+
import { W as WidgetPet } from './petsRepository.d-BtuooSOW.js';
|
|
9
9
|
import { U as UploadTransport, F as FileHandle } from './ports.d-BX4f4UsB.js';
|
|
10
|
-
import { c as AttachmentQueue, d as AttachmentState, A as AttachmentError, b as AttachmentOutcome } from './attachments.d-
|
|
10
|
+
import { c as AttachmentQueue, d as AttachmentState, A as AttachmentError, b as AttachmentOutcome } from './attachments.d-CPgp4_W-.js';
|
|
11
11
|
|
|
12
12
|
/** A rating. The footer draws `'up'` and `'down'`; `'neutral'` is still a rating the wire and the hook accept. */
|
|
13
13
|
type ChatSentiment = 'up' | 'neutral' | 'down';
|
|
@@ -163,6 +163,24 @@ interface EverfurChatDraftStore {
|
|
|
163
163
|
/** The three server tiers plus the app's calm `general` tier for an informational turn. */
|
|
164
164
|
type UrgencyDisplayLevel = UrgencyLevel | 'general';
|
|
165
165
|
|
|
166
|
+
/**
|
|
167
|
+
* A host's rule for the follow-ups under a reply (`EverfurChat`'s `followUpPolicy`, opt-in). Without one the
|
|
168
|
+
* surface draws `visibleFollowUps` exactly as before.
|
|
169
|
+
*/
|
|
170
|
+
interface ChatFollowUpPolicy {
|
|
171
|
+
/** How many to draw, 1 to 5. With `fill` the surface draws exactly this many whenever it can. Default 3. */
|
|
172
|
+
readonly count?: number;
|
|
173
|
+
/** Drop a backend prompt this matches (a visit or booking follow-up a host does not offer). */
|
|
174
|
+
readonly exclude?: RegExp | ((prompt: string) => boolean);
|
|
175
|
+
/**
|
|
176
|
+
* The host's own prompts that top the list up to `count` after the backend's (in order, de-duplicated, the
|
|
177
|
+
* `exclude` rule applied too). A function receives the member's last question, so the top-ups can follow it.
|
|
178
|
+
*/
|
|
179
|
+
readonly fill?: readonly string[] | ((lastQuestion: string | null) => readonly string[]);
|
|
180
|
+
/** A visible label over the follow-ups ("Follow-up questions"). Absent, the list keeps only its accessible name. */
|
|
181
|
+
readonly label?: string;
|
|
182
|
+
}
|
|
183
|
+
|
|
166
184
|
/** The pet list state a header or switcher renders from. */
|
|
167
185
|
interface UseEverfurPetsState {
|
|
168
186
|
/** The registered pets, newest first as the server lists them; empty until the first fetch settles. */
|
|
@@ -234,4 +252,4 @@ interface UseChatAttachmentsOptions {
|
|
|
234
252
|
*/
|
|
235
253
|
declare function useChatAttachments(options?: UseChatAttachmentsOptions): UseChatAttachmentsState;
|
|
236
254
|
|
|
237
|
-
export { type ChatFeedbackReason as C, type EverfurChatDraftStore as E, type UrgencyDisplayLevel as U, type ChatFeedbackReasonOption as a, type
|
|
255
|
+
export { type ChatFeedbackReason as C, type EverfurChatDraftStore as E, type UrgencyDisplayLevel as U, type ChatFeedbackReasonOption as a, type ChatFollowUpPolicy as b, type ChatSentiment as c, type UseChatAttachmentsOptions as d, type UseChatAttachmentsState as e, type UseEverfurChatState as f, type UseEverfurPetsState as g, useEverfurChat as h, useEverfurPets as i, useChatAttachments as u };
|
|
@@ -1,8 +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
|
import { E as EverfurError } from './EverfurError.d-8NHtlgzA.js';
|
|
3
|
-
import { R as RequestFunnel } from './requestFunnel.d-
|
|
3
|
+
import { R as RequestFunnel } from './requestFunnel.d-Cxt0JqYx.js';
|
|
4
4
|
import { F as FileHandle, U as UploadTransport, a as UploadPolicyWire } from './ports.d-BX4f4UsB.js';
|
|
5
|
-
import { R as ReadableStore, T as Timers } from './ports.d-
|
|
5
|
+
import { R as ReadableStore, T as Timers } from './ports.d-BxCVSbSi.js';
|
|
6
6
|
|
|
7
7
|
/** The image MIME types the chat accepts (the server's `CHAT_ATTACHMENT` rule, plus the `image/jpg` alias). */
|
|
8
8
|
declare const ATTACHMENT_MIME_TYPES: readonly string[];
|
|
@@ -1,8 +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
|
import { E as EverfurError } from './EverfurError.d-8NHtlgzA.cjs';
|
|
3
|
-
import { R as RequestFunnel } from './requestFunnel.d-
|
|
3
|
+
import { R as RequestFunnel } from './requestFunnel.d-mEu6B-n8.cjs';
|
|
4
4
|
import { F as FileHandle, U as UploadTransport, a as UploadPolicyWire } from './ports.d-BX4f4UsB.cjs';
|
|
5
|
-
import { R as ReadableStore, T as Timers } from './ports.d-
|
|
5
|
+
import { R as ReadableStore, T as Timers } from './ports.d-CAT70bVD.cjs';
|
|
6
6
|
|
|
7
7
|
/** The image MIME types the chat accepts (the server's `CHAT_ATTACHMENT` rule, plus the `image/jpg` alias). */
|
|
8
8
|
declare const ATTACHMENT_MIME_TYPES: readonly string[];
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
import { o as TelevetStatePolicy, k as TelevetBookingEntitlement, l as TelevetCancellationPolicy, m as TelevetClinician, c as TelevetSlot, n as TelevetSlotHold, j as TelevetBookingBody, T as TelevetConsult, b as TelevetCancelReceipt, p as TelevetTriageVerdict, h as ConsultStatus } from './televetGlobal.d-CC-DrqkQ.js';
|
|
3
3
|
import { E as EverfurError } from './EverfurError.d-8NHtlgzA.js';
|
|
4
4
|
import { E as EverfurResult } from './EverfurResult.d-D_-254ZY.js';
|
|
5
|
-
import { R as RequestFunnel } from './requestFunnel.d-
|
|
6
|
-
import { A as AuthContext } from './identity.d-
|
|
5
|
+
import { R as RequestFunnel } from './requestFunnel.d-Cxt0JqYx.js';
|
|
6
|
+
import { A as AuthContext } from './identity.d-DxNvhj3a.js';
|
|
7
7
|
import { E as ErrorPolicyPort } from './ErrorPolicyPort.d-68yrE3BE.js';
|
|
8
8
|
import { T as TelemetryPort } from './TelemetryPort.d-BDNr00hu.js';
|
|
9
9
|
import { b as VetCallCredential, c as VetCallJoinRefusal } from './callRoom.d-Dqm1rUqT.js';
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
import { o as TelevetStatePolicy, k as TelevetBookingEntitlement, l as TelevetCancellationPolicy, m as TelevetClinician, c as TelevetSlot, n as TelevetSlotHold, j as TelevetBookingBody, T as TelevetConsult, b as TelevetCancelReceipt, p as TelevetTriageVerdict, h as ConsultStatus } from './televetGlobal.d-CKwDCbmN.cjs';
|
|
3
3
|
import { E as EverfurError } from './EverfurError.d-8NHtlgzA.cjs';
|
|
4
4
|
import { E as EverfurResult } from './EverfurResult.d-BFH-3s6E.cjs';
|
|
5
|
-
import { R as RequestFunnel } from './requestFunnel.d-
|
|
6
|
-
import { A as AuthContext } from './identity.d-
|
|
5
|
+
import { R as RequestFunnel } from './requestFunnel.d-mEu6B-n8.cjs';
|
|
6
|
+
import { A as AuthContext } from './identity.d-nRZBzkG2.cjs';
|
|
7
7
|
import { E as ErrorPolicyPort } from './ErrorPolicyPort.d-DirW9hgO.cjs';
|
|
8
8
|
import { T as TelemetryPort } from './TelemetryPort.d-BDNr00hu.cjs';
|
|
9
9
|
import { b as VetCallCredential, c as VetCallJoinRefusal } from './callRoom.d-B1DoYdJe.cjs';
|
|
@@ -1,6 +1,6 @@
|
|
|
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
|
import { E as EverfurResult } from './EverfurResult.d-D_-254ZY.js';
|
|
3
|
-
import { A as AuthContext } from './identity.d-
|
|
3
|
+
import { A as AuthContext } from './identity.d-DxNvhj3a.js';
|
|
4
4
|
import { P as PetRef } from './ids.d-B2GAAifq.js';
|
|
5
5
|
|
|
6
6
|
/** The owner's answer to a check-in, the wire values of the consumer `CheckinResponse` enum. */
|
|
@@ -1,6 +1,6 @@
|
|
|
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
|
import { E as EverfurResult } from './EverfurResult.d-BFH-3s6E.cjs';
|
|
3
|
-
import { A as AuthContext } from './identity.d-
|
|
3
|
+
import { A as AuthContext } from './identity.d-nRZBzkG2.cjs';
|
|
4
4
|
import { P as PetRef } from './ids.d-B2GAAifq.cjs';
|
|
5
5
|
|
|
6
6
|
/** The owner's answer to a check-in, the wire values of the consumer `CheckinResponse` enum. */
|