@poolse/react-native 3.9.0 → 3.10.1
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 +63 -0
- package/README.md +180 -0
- package/dist/index.cjs +10203 -5872
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +776 -17
- package/dist/index.d.ts +776 -17
- package/dist/index.js +10147 -5877
- package/dist/index.js.map +1 -1
- package/package.json +4 -4
package/dist/index.d.cts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { ReactNode, ReactElement } from 'react';
|
|
3
|
-
import { Conversation, Uuid, Message, LiveCall, RecordingMode, ConsentDecision, AttachmentUploadInput, Membership, PresenceState,
|
|
3
|
+
import { Conversation, Uuid, Citation, Message, MeetingMoment, LiveCall, RecordingMode, ConsentDecision, CallAgent, AgentEscalation, EscalationReply, AgentApproval, Attachment, CallSummary, RoomSession, GuestLobbyStatus, MeetingCard as MeetingCard$1, RsvpResponse, RoomPresenceEntry, AnnotationState, ScreenAnnotations, LiveTranscriptSegment, CallConnectionQuality, CallNetworkIssue, CallReaction, WhiteboardItem, WhiteboardModel, AttachmentUploadInput, Membership, PresenceState, LinkPreview, Poolse, Block, BlockActionRequest, CatchUp, Poll } from '@poolse/sdk';
|
|
4
4
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
5
|
+
import { StyleProp, ViewStyle, TextStyle } from 'react-native';
|
|
6
|
+
import { GroupPosition, UseCallAgents, UseWhisper, UseAgenda, UseBreakouts, UseLobby, UseMoments, UseQuestions, UseStage, UseBreakoutsOptions, FormatKind, SlashCommand, DlpOutcome, MentionGroup, CustomEmoji } from '@poolse/react';
|
|
7
7
|
import { ThemeInput, ColorSchemePreference, NativeThemeOptions, NativeTheme } from '@poolse/theme';
|
|
8
8
|
export { BUILT_IN_THEME_IDS, BuiltInThemeId, ColorScheme, ColorSchemePreference, DEFAULT_THEME_ID, FlatThemeTokens, Theme, ThemeInput, createTheme, decodeTheme, encodeTheme, tokensFromFlat } from '@poolse/theme';
|
|
9
9
|
|
|
@@ -87,6 +87,62 @@ interface PoolseInboxHandle {
|
|
|
87
87
|
*/
|
|
88
88
|
declare const PoolseInbox: react.ForwardRefExoticComponent<PoolseInboxProps & react.RefAttributes<PoolseInboxHandle>>;
|
|
89
89
|
|
|
90
|
+
/**
|
|
91
|
+
* What a media adapter gets (see `renderMedia`). A controlled player:
|
|
92
|
+
* follow `paused` and `rate`, seek when `seek.nonce` changes, and report
|
|
93
|
+
* the position (a few times a second), the duration, the end and errors.
|
|
94
|
+
*/
|
|
95
|
+
interface PoolseMediaProps {
|
|
96
|
+
uri: string;
|
|
97
|
+
contentType: string | null;
|
|
98
|
+
kind: 'audio' | 'video';
|
|
99
|
+
paused: boolean;
|
|
100
|
+
rate: number;
|
|
101
|
+
/** A seek request: go to `ms` whenever `nonce` changes. Null: none yet. */
|
|
102
|
+
seek: {
|
|
103
|
+
ms: number;
|
|
104
|
+
nonce: number;
|
|
105
|
+
} | null;
|
|
106
|
+
onProgress: (positionMs: number) => void;
|
|
107
|
+
onLoad: (durationMs: number | null) => void;
|
|
108
|
+
onEnd: () => void;
|
|
109
|
+
onError: (error: unknown) => void;
|
|
110
|
+
style?: StyleProp<ViewStyle>;
|
|
111
|
+
}
|
|
112
|
+
/**
|
|
113
|
+
* Plays a recording or clip. @poolse/react-native ships no media player
|
|
114
|
+
* of its own: wire the one your app uses (expo-video, expo-audio,
|
|
115
|
+
* react-native-video) — the README has an expo-video adapter. Without
|
|
116
|
+
* one, players show their chapters and transcript but no media.
|
|
117
|
+
*/
|
|
118
|
+
type RenderMedia = (props: PoolseMediaProps) => ReactNode;
|
|
119
|
+
interface MessageExtrasHandlers {
|
|
120
|
+
/**
|
|
121
|
+
* A citation was pressed. A `message` citation: focus that message;
|
|
122
|
+
* `transcript`: open the call at `startMs`; `file`: open the file.
|
|
123
|
+
* `<ConversationView>` focuses messages of its own conversation by
|
|
124
|
+
* itself when this isn't given.
|
|
125
|
+
*/
|
|
126
|
+
onOpenCitation?: (citation: Citation, message: Message) => void;
|
|
127
|
+
/**
|
|
128
|
+
* A point in a call was pressed: open its recording at `recordingMs`
|
|
129
|
+
* (when `recordingId` is set) or its transcript at `startMs`.
|
|
130
|
+
*/
|
|
131
|
+
onOpenMoment?: (moment: MeetingMoment) => void;
|
|
132
|
+
/** A poolse user id → display name (assignees in summaries). Unknown: null. */
|
|
133
|
+
nameForUserId?: (userId: string) => string | null | undefined;
|
|
134
|
+
/** A poolse user id → their `external_id`, so a name resolves live with `useUser`. */
|
|
135
|
+
externalIdForUserId?: (userId: string) => string | null | undefined;
|
|
136
|
+
/** The media adapter for clips in chat (and any player without its own). */
|
|
137
|
+
renderMedia?: RenderMedia;
|
|
138
|
+
}
|
|
139
|
+
declare function MessageExtrasProvider({ value, children, }: {
|
|
140
|
+
value: MessageExtrasHandlers;
|
|
141
|
+
children: ReactNode;
|
|
142
|
+
}): react_jsx_runtime.JSX.Element;
|
|
143
|
+
/** The nearest `MessageExtrasProvider`'s handlers (empty without one). */
|
|
144
|
+
declare function useMessageExtras(): MessageExtrasHandlers;
|
|
145
|
+
|
|
90
146
|
/**
|
|
91
147
|
* - `bubbles` — chat bubbles, own messages on the right (the default).
|
|
92
148
|
* - `list` — Slack-style full-width rows: avatar, name and time once
|
|
@@ -453,6 +509,22 @@ interface ConversationViewProps {
|
|
|
453
509
|
* (the viewer is in the room, or ringing out as its caller).
|
|
454
510
|
*/
|
|
455
511
|
currentCallId?: string | null;
|
|
512
|
+
/**
|
|
513
|
+
* A source under an assistant's answer was pressed (AG5). Without it,
|
|
514
|
+
* message sources in this conversation are focused here.
|
|
515
|
+
*/
|
|
516
|
+
onOpenCitation?: (citation: Citation, message: Message) => void;
|
|
517
|
+
/**
|
|
518
|
+
* A point in a call was pressed — a line or moment of a summary (RT6):
|
|
519
|
+
* open its recording at `moment.recordingMs` or transcript at `moment.startMs`.
|
|
520
|
+
*/
|
|
521
|
+
onOpenMoment?: (moment: MeetingMoment) => void;
|
|
522
|
+
/**
|
|
523
|
+
* Plays clips in chat (RT9): your media adapter (expo-video,
|
|
524
|
+
* expo-audio…) — see `RenderMedia` and the README. Without it a clip
|
|
525
|
+
* shows its time range only.
|
|
526
|
+
*/
|
|
527
|
+
renderMedia?: RenderMedia;
|
|
456
528
|
/** Presence badges on message avatars (where avatars show). Defaults to `false`. */
|
|
457
529
|
showPresence?: boolean;
|
|
458
530
|
/**
|
|
@@ -495,7 +567,7 @@ interface ConversationViewProps {
|
|
|
495
567
|
/** Fires after "Mark unread" succeeded (the unread counts follow over realtime). */
|
|
496
568
|
onMarkedUnread?: (conversationId: string, messageId: string) => void;
|
|
497
569
|
}
|
|
498
|
-
declare function ConversationView({ conversationId, emptyState, renderMessage, labelFor, avatarFor, header, onHeaderMembersPress, onHeaderPress, reactions, mentions, attachments, actions, threads, quotations, readReceipts, markdown, maxBodyLength, senderLabels, avatars, onMarkedRead, onSent, focusMessageId, onFocusMessageNotFound, onSenderPress, onAvatarPress, composer, readOnly, keyboardOffset, onCallBack, onJoinCall, currentCallId, layout, density, showAvatars: showAvatarsProp, timeFormat, groupWindowMinutes, daySeparators, slots, showPresence, linkPreviews, newMessagesDivider, persistDrafts, draftStorage, emojiPicker, maxFileSize, acceptedFileTypes, markUnread, onMarkedUnread, }: ConversationViewProps): react_jsx_runtime.JSX.Element;
|
|
570
|
+
declare function ConversationView({ conversationId, emptyState, renderMessage, labelFor, avatarFor, header, onHeaderMembersPress, onHeaderPress, reactions, mentions, attachments, actions, threads, quotations, readReceipts, markdown, maxBodyLength, senderLabels, avatars, onMarkedRead, onSent, focusMessageId, onFocusMessageNotFound, onSenderPress, onAvatarPress, composer, readOnly, keyboardOffset, onCallBack, onJoinCall, currentCallId, onOpenCitation, onOpenMoment, renderMedia, layout, density, showAvatars: showAvatarsProp, timeFormat, groupWindowMinutes, daySeparators, slots, showPresence, linkPreviews, newMessagesDivider, persistDrafts, draftStorage, emojiPicker, maxFileSize, acceptedFileTypes, markUnread, onMarkedUnread, }: ConversationViewProps): react_jsx_runtime.JSX.Element;
|
|
499
571
|
|
|
500
572
|
interface ChatHeaderProps {
|
|
501
573
|
conversationId: Uuid;
|
|
@@ -725,6 +797,469 @@ interface TranscriptViewerProps {
|
|
|
725
797
|
*/
|
|
726
798
|
declare function TranscriptViewer({ callId, canRename, onSeek, title, style, }: TranscriptViewerProps): react_jsx_runtime.JSX.Element | null;
|
|
727
799
|
|
|
800
|
+
interface AgentBadgeProps {
|
|
801
|
+
/** `sm` (default) beside names in lists; `xs` in dense rows. */
|
|
802
|
+
size?: 'xs' | 'sm';
|
|
803
|
+
/** Defaults to "Agent". */
|
|
804
|
+
label?: string;
|
|
805
|
+
style?: StyleProp<ViewStyle>;
|
|
806
|
+
}
|
|
807
|
+
declare function AgentBadge({ size, label, style }: AgentBadgeProps): react_jsx_runtime.JSX.Element;
|
|
808
|
+
/**
|
|
809
|
+
* The badge as nested text, for inside a `<Text>` (a sender label that
|
|
810
|
+
* is itself pressable text). Same wording and color as `<AgentBadge>`.
|
|
811
|
+
*/
|
|
812
|
+
declare function AgentBadgeInline({ label }: {
|
|
813
|
+
label?: string;
|
|
814
|
+
}): react_jsx_runtime.JSX.Element;
|
|
815
|
+
|
|
816
|
+
interface CallAgentTagProps {
|
|
817
|
+
agent: Pick<CallAgent, 'mode' | 'status' | 'speaking'>;
|
|
818
|
+
/** Show what it's doing ("Taking notes"). Defaults to true. */
|
|
819
|
+
showState?: boolean;
|
|
820
|
+
/** The participant's live speaking flag; overrides the agent's. */
|
|
821
|
+
speaking?: boolean;
|
|
822
|
+
/** Over video: light text. */
|
|
823
|
+
onMedia?: boolean;
|
|
824
|
+
style?: StyleProp<ViewStyle>;
|
|
825
|
+
}
|
|
826
|
+
/** The Agent badge with the agent's state — beside its name wherever it's listed in a call. */
|
|
827
|
+
declare function CallAgentTag({ agent, showState, speaking, onMedia, style, }: CallAgentTagProps): react_jsx_runtime.JSX.Element;
|
|
828
|
+
interface InviteAgentMenuProps {
|
|
829
|
+
/** `useCallAgents(conversationId, callId)`. */
|
|
830
|
+
callAgents: UseCallAgents;
|
|
831
|
+
onDone?: () => void;
|
|
832
|
+
style?: StyleProp<ViewStyle>;
|
|
833
|
+
}
|
|
834
|
+
/**
|
|
835
|
+
* Bring a note-taker (silent: transcript, summary and tasks) or an
|
|
836
|
+
* assistant (answers when addressed by name) into the call, switch
|
|
837
|
+
* one's mode, or send one out.
|
|
838
|
+
*/
|
|
839
|
+
declare function InviteAgentMenu({ callAgents, onDone, style }: InviteAgentMenuProps): react_jsx_runtime.JSX.Element;
|
|
840
|
+
interface WhisperPanelProps {
|
|
841
|
+
/** `useWhisper(callId)`. */
|
|
842
|
+
whisper: UseWhisper;
|
|
843
|
+
/** Height of the hint list before it scrolls. Defaults to 320. */
|
|
844
|
+
maxHeight?: number;
|
|
845
|
+
style?: StyleProp<ViewStyle>;
|
|
846
|
+
}
|
|
847
|
+
/**
|
|
848
|
+
* Private hints during a call — facts, what you promised last time,
|
|
849
|
+
* questions to raise. Only you see them; the panel says so.
|
|
850
|
+
*/
|
|
851
|
+
declare function WhisperPanel({ whisper, maxHeight, style }: WhisperPanelProps): react_jsx_runtime.JSX.Element;
|
|
852
|
+
interface EscalationCardProps {
|
|
853
|
+
escalation: AgentEscalation;
|
|
854
|
+
/** The agent's name; defaults to the directory's, else "Your agent". */
|
|
855
|
+
agentName?: string | null;
|
|
856
|
+
meetingTitle?: string | null;
|
|
857
|
+
/** Defaults to `poolse.escalations.reply`. */
|
|
858
|
+
reply?: (id: string, reply: EscalationReply) => Promise<unknown>;
|
|
859
|
+
onReplied?: (escalation: AgentEscalation) => void;
|
|
860
|
+
style?: StyleProp<ViewStyle>;
|
|
861
|
+
}
|
|
862
|
+
/**
|
|
863
|
+
* Your agent, in a meeting for you, asking something its brief doesn't
|
|
864
|
+
* cover: Approve, Decline, or write an answer.
|
|
865
|
+
*/
|
|
866
|
+
declare function EscalationCard({ escalation: e, agentName, meetingTitle, reply, onReplied, style, }: EscalationCardProps): react_jsx_runtime.JSX.Element;
|
|
867
|
+
interface EscalationListProps {
|
|
868
|
+
/** Only this call's. */
|
|
869
|
+
callId?: string | null;
|
|
870
|
+
/** Shown when nothing waits. Defaults to nothing. */
|
|
871
|
+
empty?: string | null;
|
|
872
|
+
style?: StyleProp<ViewStyle>;
|
|
873
|
+
}
|
|
874
|
+
/** Everything your agents wait for you to answer, live. */
|
|
875
|
+
declare function EscalationList({ callId, empty, style }: EscalationListProps): react_jsx_runtime.JSX.Element | null;
|
|
876
|
+
|
|
877
|
+
interface ApprovalCardProps {
|
|
878
|
+
/** The request — from `useApprovals()` or `useApproval(id)`. */
|
|
879
|
+
approval: AgentApproval;
|
|
880
|
+
/** The agent's name when the request leaves it out (e.g. the message's sender). */
|
|
881
|
+
agentName?: string | null;
|
|
882
|
+
/** After an answer went through. */
|
|
883
|
+
onDecided?: (approval: AgentApproval) => void;
|
|
884
|
+
/** How many detail lines show before "Show all". Defaults to 4. */
|
|
885
|
+
maxDetails?: number;
|
|
886
|
+
style?: StyleProp<ViewStyle>;
|
|
887
|
+
}
|
|
888
|
+
/**
|
|
889
|
+
* An agent asking before it calls a tool with an effect outside the chat. One tap
|
|
890
|
+
* approves or denies; a reason is optional. Follows the shared
|
|
891
|
+
* approvals store, so an answer given anywhere shows here at once.
|
|
892
|
+
*/
|
|
893
|
+
declare function ApprovalCard({ approval: initial, agentName, onDecided, maxDetails, style, }: ApprovalCardProps): react_jsx_runtime.JSX.Element;
|
|
894
|
+
interface MessageApprovalProps {
|
|
895
|
+
/** `approvalIdOf(message)`. */
|
|
896
|
+
approvalId: string;
|
|
897
|
+
/** The asking agent's name (the message's sender) when the directory doesn't know it. */
|
|
898
|
+
agentName?: string | null;
|
|
899
|
+
style?: StyleProp<ViewStyle>;
|
|
900
|
+
}
|
|
901
|
+
/**
|
|
902
|
+
* The approval an agent's message waits for (`agent_meta.approval_id`),
|
|
903
|
+
* loaded and kept live. Nothing shows for someone else's approval.
|
|
904
|
+
*/
|
|
905
|
+
declare function MessageApproval({ approvalId, agentName, style }: MessageApprovalProps): react_jsx_runtime.JSX.Element | null;
|
|
906
|
+
interface ApprovalListProps {
|
|
907
|
+
emptyState?: ReactNode;
|
|
908
|
+
/** Re-list every so often as a fallback to live events (ms; 0 = never). Defaults to 60 s. */
|
|
909
|
+
pollMs?: number;
|
|
910
|
+
style?: StyleProp<ViewStyle>;
|
|
911
|
+
}
|
|
912
|
+
/** Everything waiting for your approval, newest first, live. */
|
|
913
|
+
declare function ApprovalList({ emptyState, pollMs, style }: ApprovalListProps): react_jsx_runtime.JSX.Element;
|
|
914
|
+
interface MessageCitationsProps {
|
|
915
|
+
message: Message;
|
|
916
|
+
/** Defaults to `citationsOf(message)`. */
|
|
917
|
+
citations?: Citation[];
|
|
918
|
+
/** Defaults to the `MessageExtrasProvider`'s `onOpenCitation`. */
|
|
919
|
+
onOpenCitation?: (citation: Citation, message: Message) => void;
|
|
920
|
+
/** `onBrand` inside your own (coloured) bubble. */
|
|
921
|
+
tone?: 'default' | 'onBrand';
|
|
922
|
+
style?: StyleProp<ViewStyle>;
|
|
923
|
+
}
|
|
924
|
+
/** The sources of an assistant's answer as links. Plain text when nothing handles a press. */
|
|
925
|
+
declare function MessageCitations({ message, citations, onOpenCitation, tone, style, }: MessageCitationsProps): react_jsx_runtime.JSX.Element | null;
|
|
926
|
+
|
|
927
|
+
interface SummaryCardProps {
|
|
928
|
+
summary: CallSummary;
|
|
929
|
+
/** A timed line or moment was pressed. Defaults to the provider's; without one, times are plain text. */
|
|
930
|
+
onOpenMoment?: (moment: MeetingMoment) => void;
|
|
931
|
+
/** A poolse user id → name, for assignees. Defaults to the provider's, then the conversation's members. */
|
|
932
|
+
nameForUserId?: (userId: string) => string | null | undefined;
|
|
933
|
+
/** Fetch the full copy when shortened and follow `summary:ready`. Defaults to true. */
|
|
934
|
+
live?: boolean;
|
|
935
|
+
style?: StyleProp<ViewStyle>;
|
|
936
|
+
}
|
|
937
|
+
/** A call's summary: overview, decisions, action items, open questions, sections and moments. */
|
|
938
|
+
declare function SummaryCard({ summary: initial, onOpenMoment, nameForUserId, live, style, }: SummaryCardProps): react_jsx_runtime.JSX.Element;
|
|
939
|
+
interface SummaryMessageRowProps {
|
|
940
|
+
msg: Message;
|
|
941
|
+
meId: string | null;
|
|
942
|
+
nameForUserId?: (userId: string) => string | null | undefined;
|
|
943
|
+
}
|
|
944
|
+
/** A `kind: "call_summary"` message in a list: who posted it, then the card. */
|
|
945
|
+
declare function SummaryMessageRow({ msg, nameForUserId }: SummaryMessageRowProps): react_jsx_runtime.JSX.Element | null;
|
|
946
|
+
interface AskMeetingsProps {
|
|
947
|
+
callId?: string | null;
|
|
948
|
+
conversationId?: string | null;
|
|
949
|
+
onOpenMoment?: (moment: MeetingMoment) => void;
|
|
950
|
+
placeholder?: string;
|
|
951
|
+
style?: StyleProp<ViewStyle>;
|
|
952
|
+
}
|
|
953
|
+
/** A question box over your meetings, answered with links to the moments. */
|
|
954
|
+
declare function AskMeetings({ callId, conversationId, onOpenMoment, placeholder, style, }: AskMeetingsProps): react_jsx_runtime.JSX.Element;
|
|
955
|
+
interface ClipPlayerProps {
|
|
956
|
+
/** A clip shared in chat (an attachment) — plays its own file. */
|
|
957
|
+
attachment?: Attachment | null;
|
|
958
|
+
/** A clip by id — shows "Cutting…" until `clip:ready`. */
|
|
959
|
+
clipId?: string | null;
|
|
960
|
+
/** Or a range of a recording: plays from `startMs` and stops at `endMs`. */
|
|
961
|
+
clip?: {
|
|
962
|
+
recordingId: string;
|
|
963
|
+
startMs: number;
|
|
964
|
+
endMs: number;
|
|
965
|
+
} | null;
|
|
966
|
+
onOpenRecording?: (recordingId: string, startMs: number) => void;
|
|
967
|
+
/** The media adapter. Defaults to the provider's `renderMedia`. */
|
|
968
|
+
renderMedia?: RenderMedia;
|
|
969
|
+
compact?: boolean;
|
|
970
|
+
style?: StyleProp<ViewStyle>;
|
|
971
|
+
}
|
|
972
|
+
/** A short piece of a call's recording. */
|
|
973
|
+
declare function ClipPlayer({ attachment, clipId, clip: rangeClip, onOpenRecording, renderMedia, compact, style, }: ClipPlayerProps): react_jsx_runtime.JSX.Element;
|
|
974
|
+
interface RecordingPlayerProps {
|
|
975
|
+
recordingId: string;
|
|
976
|
+
showTranscript?: boolean;
|
|
977
|
+
/** Start here (recording ms — a moment's `recordingMs`); a new value seeks. */
|
|
978
|
+
startMs?: number | null;
|
|
979
|
+
defaultSkipSilence?: boolean;
|
|
980
|
+
/** The media adapter. Defaults to the provider's `renderMedia`. */
|
|
981
|
+
renderMedia?: RenderMedia;
|
|
982
|
+
style?: StyleProp<ViewStyle>;
|
|
983
|
+
}
|
|
984
|
+
interface RecordingPlayerHandle {
|
|
985
|
+
/** Seek to recording time `ms` and play. */
|
|
986
|
+
seek: (ms: number) => void;
|
|
987
|
+
/** Seek to transcript time `ms` (a summary item's `startMs`) and play. */
|
|
988
|
+
seekTranscript: (ms: number) => void;
|
|
989
|
+
play: () => void;
|
|
990
|
+
pause: () => void;
|
|
991
|
+
}
|
|
992
|
+
/**
|
|
993
|
+
* A finished recording (`GET /v1/recordings/:id/playback`): 1×–2× speed,
|
|
994
|
+
* skip silence, chapters, and the transcript scrolling along — tap a line
|
|
995
|
+
* to play from there.
|
|
996
|
+
*/
|
|
997
|
+
declare const RecordingPlayer: react.ForwardRefExoticComponent<RecordingPlayerProps & react.RefAttributes<RecordingPlayerHandle>>;
|
|
998
|
+
|
|
999
|
+
/** Someone in the call, as the panels name them. */
|
|
1000
|
+
interface MeetingParticipant {
|
|
1001
|
+
userId: string;
|
|
1002
|
+
name?: string | null;
|
|
1003
|
+
/** Joined from a guest link: shown with a Guest mark. */
|
|
1004
|
+
guest?: boolean;
|
|
1005
|
+
avatarUrl?: string | null;
|
|
1006
|
+
/**
|
|
1007
|
+
* An agent in the call (AG13): named by its `label` and shown with the
|
|
1008
|
+
* Agent badge and what it's doing. `useCallAgents().agentFor(userId)`,
|
|
1009
|
+
* or pass the call's `agents` to the panel.
|
|
1010
|
+
*/
|
|
1011
|
+
agent?: CallAgent | null;
|
|
1012
|
+
/** Speaking now (the roster's flag) — an agent shows "Speaking". */
|
|
1013
|
+
speaking?: boolean;
|
|
1014
|
+
}
|
|
1015
|
+
type NameFor = (userId: string) => string | null | undefined;
|
|
1016
|
+
interface StagePanelProps {
|
|
1017
|
+
stage: UseStage;
|
|
1018
|
+
/** Everyone in the call (from the call roster). */
|
|
1019
|
+
participants: readonly MeetingParticipant[];
|
|
1020
|
+
selfUserId?: string | null;
|
|
1021
|
+
nameForUserId?: NameFor;
|
|
1022
|
+
/** The call's agents (`useCallAgents().agents`), listed with the Agent badge. */
|
|
1023
|
+
agents?: readonly CallAgent[];
|
|
1024
|
+
style?: StyleProp<ViewStyle>;
|
|
1025
|
+
}
|
|
1026
|
+
/**
|
|
1027
|
+
* Speakers and audience, your raise-hand button, and — for moderators —
|
|
1028
|
+
* raised hands with Bring up / Lower, and Move to audience on speakers.
|
|
1029
|
+
*/
|
|
1030
|
+
declare function StagePanel({ stage, participants, selfUserId, nameForUserId, agents, style, }: StagePanelProps): react_jsx_runtime.JSX.Element;
|
|
1031
|
+
interface QuestionsPanelProps {
|
|
1032
|
+
questions: UseQuestions;
|
|
1033
|
+
/** Show Answered / Dismiss on open questions. */
|
|
1034
|
+
canModerate?: boolean;
|
|
1035
|
+
/** Offer "Ask anonymously". Defaults to true. */
|
|
1036
|
+
allowAnonymous?: boolean;
|
|
1037
|
+
nameForUserId?: NameFor;
|
|
1038
|
+
style?: StyleProp<ViewStyle>;
|
|
1039
|
+
}
|
|
1040
|
+
/** Ask a question, upvote others', and (moderators) mark them answered. */
|
|
1041
|
+
declare function QuestionsPanel({ questions, canModerate, allowAnonymous, nameForUserId, style, }: QuestionsPanelProps): react_jsx_runtime.JSX.Element;
|
|
1042
|
+
interface BreakoutBannerProps {
|
|
1043
|
+
/** `useBreakouts(…)`, or `useNativeBreakouts(…)` on @poolse/native (which moves the call itself). */
|
|
1044
|
+
breakouts: UseBreakouts | UseNativeBreakouts;
|
|
1045
|
+
/** You are in your breakout room now (not the main call). Default: `useNativeBreakouts`' own. */
|
|
1046
|
+
inBreakout?: boolean;
|
|
1047
|
+
/** Connect to the room's session (switch the call's media to it). */
|
|
1048
|
+
onJoined?: (session: RoomSession) => void;
|
|
1049
|
+
/** Connect back to the main call. */
|
|
1050
|
+
onReturned?: (session: RoomSession) => void;
|
|
1051
|
+
style?: StyleProp<ViewStyle>;
|
|
1052
|
+
}
|
|
1053
|
+
/**
|
|
1054
|
+
* "Breakout · Room 2 · 12:30 left · Join room", then "Return to main";
|
|
1055
|
+
* while closing, "Returning to the main call in 0:45". Nothing without a
|
|
1056
|
+
* session or a room for you.
|
|
1057
|
+
*/
|
|
1058
|
+
declare function BreakoutBanner({ breakouts, inBreakout: inBreakoutProp, onJoined, onReturned, style, }: BreakoutBannerProps): react_jsx_runtime.JSX.Element | null;
|
|
1059
|
+
interface UseNativeBreakoutsOptions extends Omit<UseBreakoutsOptions, 'auto'> {
|
|
1060
|
+
/**
|
|
1061
|
+
* @poolse/native's `moveToRoom`: switches the live call's media to the
|
|
1062
|
+
* session's room and keeps the system call (CallKit / Android's call
|
|
1063
|
+
* service). Injected so this package doesn't depend on the native module.
|
|
1064
|
+
*/
|
|
1065
|
+
moveToRoom: (session: RoomSession) => Promise<boolean>;
|
|
1066
|
+
/** Follow the split by yourself (default true): join your room as it opens, come back as it closes. */
|
|
1067
|
+
auto?: boolean;
|
|
1068
|
+
}
|
|
1069
|
+
interface UseNativeBreakouts extends UseBreakouts {
|
|
1070
|
+
/** The call's media is in a breakout room now (not the main room). */
|
|
1071
|
+
inBreakout: boolean;
|
|
1072
|
+
/** Join a room and move the call into it. False when the server or the core refused. */
|
|
1073
|
+
joinRoom: (roomId: string) => Promise<boolean>;
|
|
1074
|
+
/** Back to the main room. */
|
|
1075
|
+
returnToMainRoom: () => Promise<boolean>;
|
|
1076
|
+
}
|
|
1077
|
+
/**
|
|
1078
|
+
* Breakout rooms on phones (CL5): `useBreakouts` with the native call
|
|
1079
|
+
* core doing the moving. With `auto` (the default) it joins your room
|
|
1080
|
+
* when the split gives you one and returns you when it closes; the
|
|
1081
|
+
* phone's call never ends, only its media changes rooms.
|
|
1082
|
+
*
|
|
1083
|
+
* import { moveToRoom } from '@poolse/native';
|
|
1084
|
+
* const breakouts = useNativeBreakouts(conversationId, callId, { moveToRoom });
|
|
1085
|
+
* <BreakoutBanner breakouts={breakouts} />
|
|
1086
|
+
*/
|
|
1087
|
+
declare function useNativeBreakouts(conversationId: string | null, callId: string | null, opts: UseNativeBreakoutsOptions): UseNativeBreakouts;
|
|
1088
|
+
interface LobbyWaitingProps {
|
|
1089
|
+
/** The name the guest gave. */
|
|
1090
|
+
name: string;
|
|
1091
|
+
/** Where the guest stands (`waitInLobby`'s status). */
|
|
1092
|
+
status: GuestLobbyStatus['status'];
|
|
1093
|
+
/** The meeting's title, when known. */
|
|
1094
|
+
title?: string | null;
|
|
1095
|
+
onLeave: () => void;
|
|
1096
|
+
style?: StyleProp<ViewStyle>;
|
|
1097
|
+
}
|
|
1098
|
+
/** A guest's waiting screen: "Waiting for the host to let you in", then denied or ended. */
|
|
1099
|
+
declare function LobbyWaiting({ name, status, title, onLeave, style }: LobbyWaitingProps): react_jsx_runtime.JSX.Element;
|
|
1100
|
+
interface LobbyAdmitListProps {
|
|
1101
|
+
lobby: UseLobby;
|
|
1102
|
+
style?: StyleProp<ViewStyle>;
|
|
1103
|
+
}
|
|
1104
|
+
/** For members: who is waiting, with Admit / Deny and Admit all. Nothing when nobody waits. */
|
|
1105
|
+
declare function LobbyAdmitList({ lobby, style }: LobbyAdmitListProps): react_jsx_runtime.JSX.Element | null;
|
|
1106
|
+
interface MarkMomentButtonProps {
|
|
1107
|
+
moments: UseMoments;
|
|
1108
|
+
/** Icon only (a call control); the label is still read out. */
|
|
1109
|
+
compact?: boolean;
|
|
1110
|
+
style?: StyleProp<ViewStyle>;
|
|
1111
|
+
}
|
|
1112
|
+
/** "Mark moment": highlights this point in the recording and the summary; says "Marked" for 2 s. */
|
|
1113
|
+
declare function MarkMomentButton({ moments, compact, style }: MarkMomentButtonProps): react_jsx_runtime.JSX.Element;
|
|
1114
|
+
interface AgendaPanelProps {
|
|
1115
|
+
agenda: UseAgenda;
|
|
1116
|
+
/** Show Start / Done / Reopen. */
|
|
1117
|
+
canEdit?: boolean;
|
|
1118
|
+
nameForUserId?: NameFor;
|
|
1119
|
+
style?: StyleProp<ViewStyle>;
|
|
1120
|
+
}
|
|
1121
|
+
/** The meeting's agenda: owner and minutes per item, the current one highlighted, an over-time nudge. */
|
|
1122
|
+
declare function AgendaPanel({ agenda, canEdit, nameForUserId, style }: AgendaPanelProps): react_jsx_runtime.JSX.Element | null;
|
|
1123
|
+
interface RoomPresenceProps {
|
|
1124
|
+
/**
|
|
1125
|
+
* Who's in (`useRoomPresence().presence[id]`), or a live call
|
|
1126
|
+
* (`useLiveCall(id).call`); nothing renders when empty.
|
|
1127
|
+
*/
|
|
1128
|
+
call: RoomPresenceEntry | LiveCall | null | undefined;
|
|
1129
|
+
/** Most avatars to show; the rest become "+N". Defaults to 3. */
|
|
1130
|
+
max?: number;
|
|
1131
|
+
nameForUserId?: NameFor;
|
|
1132
|
+
style?: StyleProp<ViewStyle>;
|
|
1133
|
+
}
|
|
1134
|
+
/** Who is in a room, for a sidebar row: overlapping avatars and "+N". */
|
|
1135
|
+
declare function RoomPresence({ call, max, nameForUserId, style }: RoomPresenceProps): react_jsx_runtime.JSX.Element | null;
|
|
1136
|
+
interface MeetingCardProps {
|
|
1137
|
+
card: MeetingCard$1;
|
|
1138
|
+
/** Your user id, to find your answer in the lists. */
|
|
1139
|
+
meId?: string | null;
|
|
1140
|
+
/**
|
|
1141
|
+
* Record your answer yourself. Default: `PUT /meetings/:id/rsvp`
|
|
1142
|
+
* through the provider's client; `false` hides the buttons. The card
|
|
1143
|
+
* updates when the server restates the message.
|
|
1144
|
+
*/
|
|
1145
|
+
onRsvp?: ((response: RsvpResponse) => void | Promise<void>) | false;
|
|
1146
|
+
/** Join the meeting's room. */
|
|
1147
|
+
onJoin?: (card: MeetingCard$1) => void;
|
|
1148
|
+
nameForUserId?: NameFor;
|
|
1149
|
+
style?: StyleProp<ViewStyle>;
|
|
1150
|
+
}
|
|
1151
|
+
/** An invite in chat: title, time, who's coming, Accept / Maybe / Decline and Join. */
|
|
1152
|
+
declare function MeetingCard({ card, meId, onRsvp, onJoin, nameForUserId, style, }: MeetingCardProps): react_jsx_runtime.JSX.Element;
|
|
1153
|
+
interface MeetingCardMessageRowProps extends Omit<MeetingCardProps, 'card'> {
|
|
1154
|
+
msg: Message;
|
|
1155
|
+
}
|
|
1156
|
+
/** A meeting-card message in a list; nothing for any other message. */
|
|
1157
|
+
declare function MeetingCardMessageRow({ msg, ...rest }: MeetingCardMessageRowProps): react_jsx_runtime.JSX.Element | null;
|
|
1158
|
+
|
|
1159
|
+
interface CaptionsOverlayProps {
|
|
1160
|
+
/** `useLiveTranscript(callId).segments`. */
|
|
1161
|
+
segments: readonly LiveTranscriptSegment[];
|
|
1162
|
+
/** How many lines to show. Defaults to 2. */
|
|
1163
|
+
lines?: number;
|
|
1164
|
+
style?: StyleProp<ViewStyle>;
|
|
1165
|
+
}
|
|
1166
|
+
/** The last lines of the live transcript, with speaker names; words still being spoken are dimmed. */
|
|
1167
|
+
declare function CaptionsOverlay({ segments, lines, style }: CaptionsOverlayProps): react_jsx_runtime.JSX.Element | null;
|
|
1168
|
+
interface ReactionsOverlayProps {
|
|
1169
|
+
/** `useCallReactions(room).reactions`. */
|
|
1170
|
+
reactions: readonly CallReaction[];
|
|
1171
|
+
style?: StyleProp<ViewStyle>;
|
|
1172
|
+
}
|
|
1173
|
+
/** Reactions rising over the call (still, with Reduce Motion). Never takes touches. */
|
|
1174
|
+
declare function ReactionsOverlay({ reactions, style }: ReactionsOverlayProps): react_jsx_runtime.JSX.Element;
|
|
1175
|
+
interface ReactionPickerBarProps {
|
|
1176
|
+
onReact: (emoji: string) => void;
|
|
1177
|
+
emojis?: readonly string[];
|
|
1178
|
+
style?: StyleProp<ViewStyle>;
|
|
1179
|
+
}
|
|
1180
|
+
/** A row of reaction buttons (`DEFAULT_CALL_REACTIONS`). */
|
|
1181
|
+
declare function ReactionPickerBar({ onReact, emojis, style, }: ReactionPickerBarProps): react_jsx_runtime.JSX.Element;
|
|
1182
|
+
interface ConnectionIndicatorProps {
|
|
1183
|
+
/** A web `CallConnectionQuality` or the native core's `'good' | 'poor' | 'lost' | 'unknown'`. */
|
|
1184
|
+
quality: CallConnectionQuality | 'good' | 'poor' | 'lost' | 'unknown' | null | undefined;
|
|
1185
|
+
/** Bar height in px. Defaults to 12. */
|
|
1186
|
+
size?: number;
|
|
1187
|
+
style?: StyleProp<ViewStyle>;
|
|
1188
|
+
}
|
|
1189
|
+
/** Three signal bars; a weak link turns amber, a lost one red. Labelled for screen readers. */
|
|
1190
|
+
declare function ConnectionIndicator({ quality, size, style }: ConnectionIndicatorProps): react_jsx_runtime.JSX.Element | null;
|
|
1191
|
+
interface NetworkBannerProps {
|
|
1192
|
+
/** `useCallQuality(room)?.issues`, or `diagnoseCallNetwork(…)` from a native snapshot. */
|
|
1193
|
+
issues: readonly CallNetworkIssue[];
|
|
1194
|
+
onDismiss?: () => void;
|
|
1195
|
+
style?: StyleProp<ViewStyle>;
|
|
1196
|
+
}
|
|
1197
|
+
/** The worst network problem in plain words ("Your network is dropping packets…"). */
|
|
1198
|
+
declare function NetworkBanner({ issues, onDismiss, style }: NetworkBannerProps): react_jsx_runtime.JSX.Element | null;
|
|
1199
|
+
interface WhiteboardViewProps {
|
|
1200
|
+
/** `useWhiteboard(callId, Y).items`. */
|
|
1201
|
+
items: readonly WhiteboardItem[];
|
|
1202
|
+
/** With a model and not `readOnly`, a finger draws pen strokes. */
|
|
1203
|
+
model?: WhiteboardModel | null;
|
|
1204
|
+
readOnly?: boolean;
|
|
1205
|
+
/** Pen colour and width (board units). */
|
|
1206
|
+
color?: string;
|
|
1207
|
+
width?: number;
|
|
1208
|
+
style?: StyleProp<ViewStyle>;
|
|
1209
|
+
}
|
|
1210
|
+
/**
|
|
1211
|
+
* The call's whiteboard, fit to the view (1600 × 900 board units). View
|
|
1212
|
+
* only by default; pass the model to draw simple pen strokes.
|
|
1213
|
+
*/
|
|
1214
|
+
declare function WhiteboardView({ items, model, readOnly, color, width, style, }: WhiteboardViewProps): react_jsx_runtime.JSX.Element;
|
|
1215
|
+
interface AnnotationOverlayProps {
|
|
1216
|
+
/** `useScreenAnnotations(room, sharerUserId).state` (room: `callData` on @poolse/native). */
|
|
1217
|
+
state: AnnotationState | null;
|
|
1218
|
+
/**
|
|
1219
|
+
* `useScreenAnnotations(…).annotations`: with it and `drawing`, a
|
|
1220
|
+
* finger draws lines everyone in the call sees.
|
|
1221
|
+
*/
|
|
1222
|
+
annotations?: ScreenAnnotations | null;
|
|
1223
|
+
/** Draw instead of passing touches through (a pen toggle). Default false. */
|
|
1224
|
+
drawing?: boolean;
|
|
1225
|
+
/** Pen colour. Default red. */
|
|
1226
|
+
color?: string;
|
|
1227
|
+
style?: StyleProp<ViewStyle>;
|
|
1228
|
+
}
|
|
1229
|
+
/**
|
|
1230
|
+
* Lines and pointers drawn on a shared screen, laid over the screen's
|
|
1231
|
+
* video (same box as the picture: size it to the `fit="contain"` area).
|
|
1232
|
+
* View only unless given `annotations` and `drawing`.
|
|
1233
|
+
*/
|
|
1234
|
+
declare function AnnotationOverlay({ state, annotations, drawing, color, style, }: AnnotationOverlayProps): react_jsx_runtime.JSX.Element;
|
|
1235
|
+
|
|
1236
|
+
/** 45 → "0:45", 3725 → "1:02:05". */
|
|
1237
|
+
declare function formatCountdown(seconds: number | null | undefined): string;
|
|
1238
|
+
/** Show at most `max` avatars; the rest become "+N". */
|
|
1239
|
+
declare function avatarOverflow<T>(list: readonly T[], max: number): {
|
|
1240
|
+
shown: T[];
|
|
1241
|
+
more: number;
|
|
1242
|
+
};
|
|
1243
|
+
/** One caption line: a speaker's run of text, interim when still talking. */
|
|
1244
|
+
interface CaptionLine {
|
|
1245
|
+
key: string;
|
|
1246
|
+
speaker: string;
|
|
1247
|
+
text: string;
|
|
1248
|
+
interim: boolean;
|
|
1249
|
+
}
|
|
1250
|
+
/**
|
|
1251
|
+
* The last `lines` caption lines: consecutive segments of one speaker are
|
|
1252
|
+
* joined, an interim segment after them shown as still being spoken.
|
|
1253
|
+
* Each line keeps only its last `maxChars` characters.
|
|
1254
|
+
*/
|
|
1255
|
+
declare function captionLines(segments: readonly LiveTranscriptSegment[], lines?: number, maxChars?: number): CaptionLine[];
|
|
1256
|
+
/** "Budget review is 3 min over" — null when not over by a whole minute. */
|
|
1257
|
+
declare function overrunText(title: string, overrunMs: number): string | null;
|
|
1258
|
+
/** "Tue 21 Nov · 10:00–10:30" in the device's locale. */
|
|
1259
|
+
declare function meetingTimeText(card: Pick<MeetingCard$1, 'startsAt' | 'endsAt'>): string | null;
|
|
1260
|
+
/** "4 accepted · 1 maybe · 2 declined" (empty parts left out), or null. */
|
|
1261
|
+
declare function rsvpSummary(card: Pick<MeetingCard$1, 'rsvps'> & Partial<Pick<MeetingCard$1, 'counts'>>): string | null;
|
|
1262
|
+
|
|
728
1263
|
interface MessageComposerProps {
|
|
729
1264
|
/**
|
|
730
1265
|
* Called when the user taps Send. Second arg carries
|
|
@@ -732,10 +1267,7 @@ interface MessageComposerProps {
|
|
|
732
1267
|
* (resolved from the composer's upload queue). Awaited so the
|
|
733
1268
|
* composer disables until the send round-trips.
|
|
734
1269
|
*/
|
|
735
|
-
onSend: (body: string, opts?:
|
|
736
|
-
quoted_message_id?: Uuid;
|
|
737
|
-
attachment_ids?: Uuid[];
|
|
738
|
-
}) => Promise<unknown> | void;
|
|
1270
|
+
onSend: (body: string, opts?: ComposerSendOptions) => Promise<unknown> | void;
|
|
739
1271
|
/** Called on every keystroke. Hook to `useTyping().signalTyping`. */
|
|
740
1272
|
onTyping?: () => void;
|
|
741
1273
|
placeholder?: string;
|
|
@@ -786,6 +1318,21 @@ interface MessageComposerProps {
|
|
|
786
1318
|
emojiPicker?: boolean;
|
|
787
1319
|
/** Rendered above the input row — e.g. `<MentionInput>`'s suggestions. */
|
|
788
1320
|
accessory?: ReactNode;
|
|
1321
|
+
/**
|
|
1322
|
+
* Show the Markdown formatting toolbar (bold, italic, strike, code,
|
|
1323
|
+
* link, quote, lists, checklist, code block, table) above the input.
|
|
1324
|
+
* Default `false`. Pass an array to choose the buttons and their order.
|
|
1325
|
+
*/
|
|
1326
|
+
formattingToolbar?: boolean | readonly FormatKind[];
|
|
1327
|
+
/** Slash commands to suggest when the message starts with `/` (IN3). */
|
|
1328
|
+
commands?: readonly SlashCommand[];
|
|
1329
|
+
}
|
|
1330
|
+
/** The second argument of `onSend`. */
|
|
1331
|
+
interface ComposerSendOptions {
|
|
1332
|
+
quoted_message_id?: Uuid;
|
|
1333
|
+
attachment_ids?: Uuid[];
|
|
1334
|
+
/** Set when the sender chose "Send anyway" on a data-loss-prevention warning (AD6). */
|
|
1335
|
+
dlp_acknowledged?: true;
|
|
789
1336
|
}
|
|
790
1337
|
/**
|
|
791
1338
|
* Imperative handle for parents that want to add files to the
|
|
@@ -802,6 +1349,31 @@ interface MessageComposerHandle {
|
|
|
802
1349
|
}
|
|
803
1350
|
declare const MessageComposer: react.ForwardRefExoticComponent<MessageComposerProps & react.RefAttributes<MessageComposerHandle>>;
|
|
804
1351
|
|
|
1352
|
+
interface FormattingToolbarProps {
|
|
1353
|
+
onFormat: (kind: FormatKind) => void;
|
|
1354
|
+
disabled?: boolean;
|
|
1355
|
+
/** Which buttons, in order. Defaults to all of `FORMAT_ACTIONS`. */
|
|
1356
|
+
actions?: readonly FormatKind[];
|
|
1357
|
+
}
|
|
1358
|
+
/** A horizontally scrolling row of formatting buttons. */
|
|
1359
|
+
declare function FormattingToolbar({ onFormat, disabled, actions, }: FormattingToolbarProps): react_jsx_runtime.JSX.Element;
|
|
1360
|
+
/** `/command` suggestions for the text and cursor, or `null` when none match. */
|
|
1361
|
+
declare function CommandSuggestions({ commands, text, cursor, onPick, }: {
|
|
1362
|
+
commands: readonly SlashCommand[];
|
|
1363
|
+
text: string;
|
|
1364
|
+
cursor: number;
|
|
1365
|
+
onPick: (command: SlashCommand) => void;
|
|
1366
|
+
}): react_jsx_runtime.JSX.Element | null;
|
|
1367
|
+
interface DlpWarningSheetProps {
|
|
1368
|
+
outcome: DlpOutcome;
|
|
1369
|
+
/** "Send anyway" (only offered for a warning, never for a block). */
|
|
1370
|
+
onSendAnyway?: () => void;
|
|
1371
|
+
/** "Edit message": back to the composer with the text kept. */
|
|
1372
|
+
onEdit: () => void;
|
|
1373
|
+
}
|
|
1374
|
+
/** The data-loss-prevention warning as a centred modal. */
|
|
1375
|
+
declare function DlpWarningSheet({ outcome, onSendAnyway, onEdit }: DlpWarningSheetProps): react_jsx_runtime.JSX.Element;
|
|
1376
|
+
|
|
805
1377
|
interface MessageActionsProps {
|
|
806
1378
|
visible: boolean;
|
|
807
1379
|
onClose: () => void;
|
|
@@ -833,6 +1405,14 @@ interface MessageActionsProps {
|
|
|
833
1405
|
* Called after the sheet closes.
|
|
834
1406
|
*/
|
|
835
1407
|
onMoreReactions?: () => void;
|
|
1408
|
+
/** Pin or unpin (MS13); `pinned` picks the label. */
|
|
1409
|
+
onTogglePin?: () => void;
|
|
1410
|
+
pinned?: boolean;
|
|
1411
|
+
/** Forward to other conversations (MS13): open your target picker (`<ForwardSheet>`). */
|
|
1412
|
+
onForward?: () => void;
|
|
1413
|
+
/** Translate (MS21), or back to the original when `translated`. */
|
|
1414
|
+
onTranslate?: () => void;
|
|
1415
|
+
translated?: boolean;
|
|
836
1416
|
}
|
|
837
1417
|
/**
|
|
838
1418
|
* Long-press action menu — modal bottom sheet. Renders a row of
|
|
@@ -840,7 +1420,7 @@ interface MessageActionsProps {
|
|
|
840
1420
|
* action items below. Matches WhatsApp / iMessage's "long-press
|
|
841
1421
|
* shows everything inline" pattern.
|
|
842
1422
|
*/
|
|
843
|
-
declare function MessageActions({ visible, onClose, isSelf, emojis, onPickReaction, onReply, onReplyInThread, onQuote, onEdit, onDelete, onCopy, onMarkUnread, onRemovePreview, previewUrls, onMoreReactions, }: MessageActionsProps): react_jsx_runtime.JSX.Element;
|
|
1423
|
+
declare function MessageActions({ visible, onClose, isSelf, emojis, onPickReaction, onReply, onReplyInThread, onQuote, onEdit, onDelete, onCopy, onMarkUnread, onRemovePreview, previewUrls, onMoreReactions, onTogglePin, pinned, onForward, onTranslate, translated, }: MessageActionsProps): react_jsx_runtime.JSX.Element;
|
|
844
1424
|
|
|
845
1425
|
/**
|
|
846
1426
|
* Either a real message or a day-separator row. ConversationView
|
|
@@ -952,6 +1532,10 @@ interface ThreadViewProps {
|
|
|
952
1532
|
showPresence?: boolean;
|
|
953
1533
|
/** Link previews under replies. Defaults to `true`. */
|
|
954
1534
|
linkPreviews?: boolean;
|
|
1535
|
+
/** A Follow / Following button in the header (MS19). Default `true`. */
|
|
1536
|
+
follow?: boolean;
|
|
1537
|
+
/** An "Also send to channel" switch above the composer (MS19). Default `true`; off in DMs. */
|
|
1538
|
+
alsoSendToChannel?: boolean;
|
|
955
1539
|
}
|
|
956
1540
|
/**
|
|
957
1541
|
* Bottom-sheet modal for thread replies. Pull the drag handle / header
|
|
@@ -968,7 +1552,7 @@ interface ThreadViewProps {
|
|
|
968
1552
|
* sheet top (the gutter), since KAV measures its frame relative to
|
|
969
1553
|
* its parent (the sheet), not the screen.
|
|
970
1554
|
*/
|
|
971
|
-
declare function ThreadView({ visible, onClose, conversationId, rootMessage, labelFor, avatarFor, layout, timeFormat, density, showPresence, linkPreviews, }: ThreadViewProps): react_jsx_runtime.JSX.Element;
|
|
1555
|
+
declare function ThreadView({ visible, onClose, conversationId, rootMessage, labelFor, avatarFor, layout, timeFormat, density, showPresence, linkPreviews, follow, alsoSendToChannel, }: ThreadViewProps): react_jsx_runtime.JSX.Element;
|
|
972
1556
|
|
|
973
1557
|
interface ThreadSummaryProps {
|
|
974
1558
|
/** The thread's root: `reply_count`, `last_reply_at`, `thread_participants`. */
|
|
@@ -1021,12 +1605,14 @@ interface UserNameProps {
|
|
|
1021
1605
|
fallback?: string;
|
|
1022
1606
|
/** Caller-supplied label override; if it returns a string, it wins. */
|
|
1023
1607
|
labelFor?: (externalId: string) => string;
|
|
1608
|
+
/** The Agent badge after an agent's name (AG1). Defaults to `true`. */
|
|
1609
|
+
agentBadge?: boolean;
|
|
1024
1610
|
}
|
|
1025
1611
|
/**
|
|
1026
1612
|
* Display name for a user, looked up via the SDK's `userResolver`
|
|
1027
1613
|
* with caller-overridable + fallback fallbacks. Renders a `<Text>`.
|
|
1028
1614
|
*/
|
|
1029
|
-
declare function UserName({ externalId, fallback, labelFor }: UserNameProps): react_jsx_runtime.JSX.Element;
|
|
1615
|
+
declare function UserName({ externalId, fallback, labelFor, agentBadge }: UserNameProps): react_jsx_runtime.JSX.Element;
|
|
1030
1616
|
/**
|
|
1031
1617
|
* Resolves a user's display name via the 3-tier chain:
|
|
1032
1618
|
* 1. `labelFor(externalId)` — caller-supplied override
|
|
@@ -1217,13 +1803,17 @@ declare function ReactionPicker({ visible, onClose, onPick, emojis, }: ReactionP
|
|
|
1217
1803
|
interface MentionInputProps extends Omit<MessageComposerProps, 'onSend'> {
|
|
1218
1804
|
conversationId: Uuid;
|
|
1219
1805
|
/** Same callback as MessageComposer.onSend, plus the mentioned user_ids. */
|
|
1220
|
-
onSend: (body: string, opts?: {
|
|
1221
|
-
quoted_message_id?: Uuid;
|
|
1222
|
-
attachment_ids?: Uuid[];
|
|
1806
|
+
onSend: (body: string, opts?: ComposerSendOptions & {
|
|
1223
1807
|
mentions?: Uuid[];
|
|
1224
1808
|
}) => Promise<unknown> | void;
|
|
1225
1809
|
/** Most suggestions shown at once. Defaults to 6. */
|
|
1226
1810
|
maxSuggestions?: number;
|
|
1811
|
+
/**
|
|
1812
|
+
* User groups to offer after matching members (MS9): `@design`,
|
|
1813
|
+
* `@oncall`. Picking one inserts `@handle`; the Workspace expands it
|
|
1814
|
+
* when the message arrives, so nothing extra is sent.
|
|
1815
|
+
*/
|
|
1816
|
+
groups?: readonly MentionGroup[];
|
|
1227
1817
|
}
|
|
1228
1818
|
/**
|
|
1229
1819
|
* Composer with @-mentions: typing `@` (at the start or after a space)
|
|
@@ -1232,7 +1822,7 @@ interface MentionInputProps extends Omit<MessageComposerProps, 'onSend'> {
|
|
|
1232
1822
|
* carries their user id in `mentions` — for as long as `@Name` is
|
|
1233
1823
|
* still in the text.
|
|
1234
1824
|
*/
|
|
1235
|
-
declare function MentionInput({ conversationId, onSend, maxSuggestions, labelFor, value: valueProp, onChangeText, onSelectionChange, ...composerProps }: MentionInputProps): react_jsx_runtime.JSX.Element;
|
|
1825
|
+
declare function MentionInput({ conversationId, onSend, maxSuggestions, labelFor, value: valueProp, onChangeText, onSelectionChange, groups, ...composerProps }: MentionInputProps): react_jsx_runtime.JSX.Element;
|
|
1236
1826
|
|
|
1237
1827
|
interface AttachmentPickerProps {
|
|
1238
1828
|
visible: boolean;
|
|
@@ -1631,8 +2221,13 @@ interface AvatarProps {
|
|
|
1631
2221
|
userId?: string | null;
|
|
1632
2222
|
/** Size variant. `md` → 40px, `sm` → 28px, `xs` → 20px, `lg` → 56px. */
|
|
1633
2223
|
size?: 'xs' | 'sm' | 'md' | 'lg';
|
|
2224
|
+
/**
|
|
2225
|
+
* An agent, not a person (AG1): a rounded-square avatar with a small
|
|
2226
|
+
* agent mark, and "(agent)" in its label. Pass `useUser(id).agent`.
|
|
2227
|
+
*/
|
|
2228
|
+
agent?: boolean;
|
|
1634
2229
|
}
|
|
1635
|
-
declare function Avatar({ src, name, seed, online, presence, doNotDisturb, userId, size, }: AvatarProps): react_jsx_runtime.JSX.Element;
|
|
2230
|
+
declare function Avatar({ src, name, seed, online, presence, doNotDisturb, userId, size, agent, }: AvatarProps): react_jsx_runtime.JSX.Element;
|
|
1636
2231
|
|
|
1637
2232
|
declare const primitives: {
|
|
1638
2233
|
PoolseIcon: typeof PoolseIcon;
|
|
@@ -2014,4 +2609,168 @@ declare const callColors: {
|
|
|
2014
2609
|
*/
|
|
2015
2610
|
declare function useCallDuration(connected: boolean): string | null;
|
|
2016
2611
|
|
|
2017
|
-
|
|
2612
|
+
interface PollCardProps {
|
|
2613
|
+
question: string;
|
|
2614
|
+
poll: Poll;
|
|
2615
|
+
myOptionIds: readonly string[];
|
|
2616
|
+
onToggle?: (optionId: string) => void;
|
|
2617
|
+
onClose?: () => void;
|
|
2618
|
+
pending?: boolean;
|
|
2619
|
+
showResults?: boolean;
|
|
2620
|
+
}
|
|
2621
|
+
declare function PollCard({ question, poll, myOptionIds, onToggle, onClose, pending, showResults, }: PollCardProps): react_jsx_runtime.JSX.Element;
|
|
2622
|
+
interface BlockRendererProps {
|
|
2623
|
+
blocks: readonly Block[];
|
|
2624
|
+
onAction?: (req: BlockActionRequest) => Promise<unknown> | void;
|
|
2625
|
+
disabled?: boolean;
|
|
2626
|
+
}
|
|
2627
|
+
declare function BlockRenderer({ blocks, onAction, disabled }: BlockRendererProps): react_jsx_runtime.JSX.Element;
|
|
2628
|
+
interface PinsListProps {
|
|
2629
|
+
pins: readonly Message[];
|
|
2630
|
+
labelFor?: (externalId: string) => string;
|
|
2631
|
+
onOpen?: (message: Message) => void;
|
|
2632
|
+
onUnpin?: (message: Message) => void;
|
|
2633
|
+
loading?: boolean;
|
|
2634
|
+
}
|
|
2635
|
+
declare function PinsList({ pins, labelFor, onOpen, onUnpin, loading }: PinsListProps): react_jsx_runtime.JSX.Element;
|
|
2636
|
+
interface ForwardTarget {
|
|
2637
|
+
id: Uuid;
|
|
2638
|
+
name: string;
|
|
2639
|
+
}
|
|
2640
|
+
interface ForwardSheetProps {
|
|
2641
|
+
visible: boolean;
|
|
2642
|
+
targets: readonly ForwardTarget[];
|
|
2643
|
+
onForward: (conversationIds: Uuid[], comment: string) => Promise<unknown> | void;
|
|
2644
|
+
onClose: () => void;
|
|
2645
|
+
max?: number;
|
|
2646
|
+
}
|
|
2647
|
+
declare function ForwardSheet({ visible, targets, onForward, onClose, max, }: ForwardSheetProps): react_jsx_runtime.JSX.Element;
|
|
2648
|
+
interface FilesListProps {
|
|
2649
|
+
files: readonly Attachment[];
|
|
2650
|
+
onOpen?: (file: Attachment) => void;
|
|
2651
|
+
thumbnailFor?: (file: Attachment) => string | null | undefined;
|
|
2652
|
+
onVersions?: (file: Attachment) => void;
|
|
2653
|
+
hasMore?: boolean;
|
|
2654
|
+
onLoadMore?: () => void;
|
|
2655
|
+
loading?: boolean;
|
|
2656
|
+
}
|
|
2657
|
+
declare function FilesList({ files, onOpen, thumbnailFor, onVersions, hasMore, onLoadMore, loading, }: FilesListProps): react_jsx_runtime.JSX.Element;
|
|
2658
|
+
interface ForumPost {
|
|
2659
|
+
messageId: Uuid;
|
|
2660
|
+
title: string;
|
|
2661
|
+
authorName: string;
|
|
2662
|
+
replyCount: number;
|
|
2663
|
+
lastActivityAt: string;
|
|
2664
|
+
tags?: readonly {
|
|
2665
|
+
name: string;
|
|
2666
|
+
color?: string | null;
|
|
2667
|
+
}[];
|
|
2668
|
+
}
|
|
2669
|
+
interface ForumPostListProps {
|
|
2670
|
+
posts: readonly ForumPost[];
|
|
2671
|
+
onOpen?: (post: ForumPost) => void;
|
|
2672
|
+
hasMore?: boolean;
|
|
2673
|
+
onLoadMore?: () => void;
|
|
2674
|
+
loading?: boolean;
|
|
2675
|
+
}
|
|
2676
|
+
declare function ForumPostList({ posts, onOpen, hasMore, onLoadMore, loading }: ForumPostListProps): react_jsx_runtime.JSX.Element;
|
|
2677
|
+
interface CatchUpCardProps {
|
|
2678
|
+
result: CatchUp | null;
|
|
2679
|
+
loading?: boolean;
|
|
2680
|
+
error?: unknown;
|
|
2681
|
+
onRun?: () => void;
|
|
2682
|
+
onOpenMessage?: (messageId: Uuid, sequence: number) => void;
|
|
2683
|
+
onDismiss?: () => void;
|
|
2684
|
+
}
|
|
2685
|
+
declare function CatchUpCard({ result, loading, error, onRun, onOpenMessage, onDismiss, }: CatchUpCardProps): react_jsx_runtime.JSX.Element;
|
|
2686
|
+
interface TranslatedTextProps {
|
|
2687
|
+
translation: string | null;
|
|
2688
|
+
languageName?: string;
|
|
2689
|
+
loading?: boolean;
|
|
2690
|
+
onToggle?: () => void;
|
|
2691
|
+
children: ReactNode;
|
|
2692
|
+
}
|
|
2693
|
+
declare function TranslatedText({ translation, languageName, loading, onToggle, children, }: TranslatedTextProps): react_jsx_runtime.JSX.Element;
|
|
2694
|
+
interface NoteCardProps {
|
|
2695
|
+
title: string | null;
|
|
2696
|
+
encrypted?: boolean;
|
|
2697
|
+
sharedByName?: string;
|
|
2698
|
+
updatedAt?: string;
|
|
2699
|
+
updated?: boolean;
|
|
2700
|
+
unavailable?: boolean;
|
|
2701
|
+
onOpen?: () => void;
|
|
2702
|
+
}
|
|
2703
|
+
declare function NoteCard({ title, encrypted, sharedByName, updatedAt, updated, unavailable, onOpen, }: NoteCardProps): react_jsx_runtime.JSX.Element;
|
|
2704
|
+
/**
|
|
2705
|
+
* What the players need from the app's media library (expo-audio's
|
|
2706
|
+
* `useAudioPlayer` + `useAudioPlayerStatus`, expo-video's player, …).
|
|
2707
|
+
*/
|
|
2708
|
+
interface MediaPlayback {
|
|
2709
|
+
playing: boolean;
|
|
2710
|
+
positionMs: number;
|
|
2711
|
+
durationMs: number;
|
|
2712
|
+
play: () => void;
|
|
2713
|
+
pause: () => void;
|
|
2714
|
+
seek: (ms: number) => void;
|
|
2715
|
+
/** Set the speed (1, 1.5, 2). */
|
|
2716
|
+
setRate: (rate: number) => void;
|
|
2717
|
+
}
|
|
2718
|
+
interface VoiceMessagePlayerProps {
|
|
2719
|
+
player: MediaPlayback;
|
|
2720
|
+
attachment?: Attachment | null;
|
|
2721
|
+
waveform?: readonly number[];
|
|
2722
|
+
}
|
|
2723
|
+
declare function VoiceMessagePlayer({ player, attachment, waveform }: VoiceMessagePlayerProps): react_jsx_runtime.JSX.Element;
|
|
2724
|
+
interface VideoMessagePlayerProps {
|
|
2725
|
+
player: MediaPlayback;
|
|
2726
|
+
/** The video surface (expo-video's `<VideoView player={…}>`). */
|
|
2727
|
+
video: ReactNode;
|
|
2728
|
+
attachment?: Attachment | null;
|
|
2729
|
+
}
|
|
2730
|
+
declare function VideoMessagePlayer({ player, video, attachment }: VideoMessagePlayerProps): react_jsx_runtime.JSX.Element;
|
|
2731
|
+
/** The app's recorder (expo-audio's `useAudioRecorder`, …). */
|
|
2732
|
+
interface AudioRecorderAdapter {
|
|
2733
|
+
/** Ask for the microphone if needed and start. */
|
|
2734
|
+
start: () => Promise<void>;
|
|
2735
|
+
/** Stop and return the file. */
|
|
2736
|
+
stop: () => Promise<{
|
|
2737
|
+
uri: string;
|
|
2738
|
+
durationMs: number;
|
|
2739
|
+
mimeType: string;
|
|
2740
|
+
}>;
|
|
2741
|
+
/** Stop and throw it away. */
|
|
2742
|
+
cancel: () => Promise<void>;
|
|
2743
|
+
}
|
|
2744
|
+
interface VoiceRecorderProps {
|
|
2745
|
+
recorder: AudioRecorderAdapter;
|
|
2746
|
+
/** Upload with `purpose: 'voice'` and send. */
|
|
2747
|
+
onRecorded: (file: {
|
|
2748
|
+
uri: string;
|
|
2749
|
+
durationMs: number;
|
|
2750
|
+
mimeType: string;
|
|
2751
|
+
}) => void | Promise<unknown>;
|
|
2752
|
+
/** Stops by itself after this long. Default 15 minutes. */
|
|
2753
|
+
maxMs?: number;
|
|
2754
|
+
/** Shorter than this is dropped (a tap, not a recording). Default 700 ms. */
|
|
2755
|
+
minMs?: number;
|
|
2756
|
+
disabled?: boolean;
|
|
2757
|
+
onError?: (err: unknown) => void;
|
|
2758
|
+
}
|
|
2759
|
+
/** Hold to record, release to send; slide-free Cancel while recording. */
|
|
2760
|
+
declare function VoiceRecorder({ recorder, onRecorded, maxMs, minMs, disabled, onError, }: VoiceRecorderProps): react_jsx_runtime.JSX.Element;
|
|
2761
|
+
|
|
2762
|
+
declare function EmojiGlyph({ emoji, size, customEmoji, style, }: {
|
|
2763
|
+
emoji: string;
|
|
2764
|
+
size?: number;
|
|
2765
|
+
customEmoji?: readonly CustomEmoji[];
|
|
2766
|
+
/** Style for the text form. */
|
|
2767
|
+
style?: StyleProp<TextStyle>;
|
|
2768
|
+
}): react_jsx_runtime.JSX.Element;
|
|
2769
|
+
|
|
2770
|
+
/** Block and summary text without Markdown markers (RN renders it as plain text). */
|
|
2771
|
+
declare function stripMarkdown(text: string): string;
|
|
2772
|
+
declare function formatBytes(n: number): string;
|
|
2773
|
+
/** The note id in a Workspace note link, or `null`. */
|
|
2774
|
+
declare function noteIdFromLink(url: string): string | null;
|
|
2775
|
+
|
|
2776
|
+
export { AgendaPanel, type AgendaPanelProps, AgentBadge, AgentBadgeInline, type AgentBadgeProps, AnnotationOverlay, type AnnotationOverlayProps, ApprovalCard, type ApprovalCardProps, ApprovalList, type ApprovalListProps, AskMeetings, type AskMeetingsProps, AttachmentPicker, type AttachmentPickerProps, AttachmentPreview, type AttachmentPreviewProps, type AudioRecorderAdapter, type AudioRoute, type AudioRouteKind, AudioRouteSheet, type AudioRouteSheetProps, Avatar, type AvatarProps, type BackgroundClientsOptions, BlockRenderer, type BlockRendererProps, BreakoutBanner, type BreakoutBannerProps, CallAgentTag, type CallAgentTagProps, CallAvatar, type CallAvatarProps, CallControlButton, type CallControlButtonProps, CallLogRow, type CallLogRowProps, type CaptionLine, CaptionsOverlay, type CaptionsOverlayProps, CatchUpCard, type CatchUpCardProps, type ChatDensity, ChatHeader, type ChatHeaderProps, type ChatLayout, ClipPlayer, type ClipPlayerProps, CommandSuggestions, type ComposerSendOptions, ConnectionIndicator, type ConnectionIndicatorProps, ConsentPrompt, type ConsentPromptProps, type ConversationDraft, type ConversationGroupBy, ConversationList, type ConversationListProps, type ConversationSection, ConversationView, type ConversationViewProps, DaySeparator, type DaySeparatorProps, DlpWarningSheet, type DlpWarningSheetProps, type DraftStorage, EditHistorySheet, type EditHistorySheetProps, EmojiGlyph, EmojiPicker, type EmojiPickerProps, EmptyState, type EmptyStateProps, EscalationCard, type EscalationCardProps, EscalationList, type EscalationListProps, FilesList, type FilesListProps, FormattingToolbar, type FormattingToolbarProps, type ForumPost, ForumPostList, type ForumPostListProps, ForwardSheet, type ForwardSheetProps, type ForwardTarget, GroupDetailsSheet, type GroupDetailsSheetProps, type IconName, ImageMosaic, type ImageMosaicProps, type InboxUser, InviteAgentMenu, type InviteAgentMenuProps, LinkPreviewCard, type LinkPreviewCardProps, LiveCallBanner, type LiveCallBannerProps, LiveTranscriptPanel, type LiveTranscriptPanelProps, LobbyAdmitList, type LobbyAdmitListProps, LobbyWaiting, type LobbyWaitingProps, MarkMomentButton, type MarkMomentButtonProps, type MediaPlayback, MeetingCard, MeetingCardMessageRow, type MeetingCardMessageRowProps, type MeetingCardProps, type MeetingParticipant, MemberList, type MemberListProps, MentionInput, type MentionInputProps, MessageActions, type MessageActionsProps, MessageApproval, type MessageApprovalProps, MessageBubble, type MessageBubbleProps, MessageCitations, type MessageCitationsProps, MessageComposer, type MessageComposerHandle, type MessageComposerProps, type MessageExtrasHandlers, MessageExtrasProvider, MessageList, type MessageListItem, type MessageListProps, MessageRow, type MessageRowProps, type MessageSlot, type MessageSlotProps, type MessageSlots, type MessageUser, NetworkBanner, type NetworkBannerProps, NewMessagesDivider, type NewMessagesDividerProps, NoteCard, type NoteCardProps, PinsList, type PinsListProps, PollCard, type PollCardProps, PoolseIcon, type PoolseIconProps, PoolseInbox, type PoolseInboxHandle, type PoolseInboxProps, PoolseLogo, type PoolseLogoProps, type PoolseLogoVariant, type PoolseMediaProps, type PoolseRNTheme, type PoolseRNThemeOverrides, PoolseTheme, type PoolseThemeProps, PresenceBadge, type PresenceBadgeProps, primitives as Primitives, QuestionsPanel, type QuestionsPanelProps, ReactionPicker, ReactionPickerBar, type ReactionPickerBarProps, type ReactionPickerProps, ReactionStrip, type ReactionStripProps, ReactionsOverlay, type ReactionsOverlayProps, RecordingBanner, type RecordingBannerProps, RecordingIndicator, type RecordingIndicatorProps, RecordingNoticeRow, type RecordingNoticeRowProps, RecordingPlayer, type RecordingPlayerHandle, type RecordingPlayerProps, type RenderMedia, type RenderMessageContext, RoomPresence, type RoomPresenceProps, SendStatus, type SendStatusProps, StagePanel, type StagePanelProps, SummaryCard, type SummaryCardProps, SummaryMessageRow, type SummaryMessageRowProps, type ThemeColors, type ThemeRadii, type ThemeShadows, type ThemeSpacing, type ThemeType, ThreadSummary, type ThreadSummaryProps, ThreadView, type ThreadViewProps, type TimeFormat, TranscriptViewer, type TranscriptViewerProps, TranslatedText, type TranslatedTextProps, TypingIndicator, type TypingIndicatorProps, UploadQueueStrip, type UseNativeBreakouts, type UseNativeBreakoutsOptions, UserName, type UserNameProps, VideoMessagePlayer, type VideoMessagePlayerProps, VoiceMessagePlayer, type VoiceMessagePlayerProps, VoiceRecorder, type VoiceRecorderProps, WhisperPanel, type WhisperPanelProps, WhiteboardView, type WhiteboardViewProps, applyBackground, avatarOverflow, callColors, captionLines, defaultDarkTheme, defaultLightTheme, formatBytes, formatCountdown, meetingTimeText, noteIdFromLink, overrunText, rsvpSummary, stripMarkdown, useAppStateLifecycle, useAppStatePresence, useBackgroundClients, useCallDuration, useDisplayName, useMessageExtras, useNativeBreakouts, usePoolseTheme, useTheme };
|