@scalemule/chat 0.0.8 → 0.0.9

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.
Files changed (80) hide show
  1. package/dist/ChatClient-DQPHdUHX.d.cts +107 -0
  2. package/dist/ChatClient-DtUKF-4c.d.ts +107 -0
  3. package/dist/constants.d.ts +9 -0
  4. package/dist/constants.d.ts.map +1 -0
  5. package/dist/core/ChatClient.d.ts +96 -0
  6. package/dist/core/ChatClient.d.ts.map +1 -0
  7. package/dist/core/EventEmitter.d.ts +11 -0
  8. package/dist/core/EventEmitter.d.ts.map +1 -0
  9. package/dist/core/MessageCache.d.ts +18 -0
  10. package/dist/core/MessageCache.d.ts.map +1 -0
  11. package/dist/core/OfflineQueue.d.ts +19 -0
  12. package/dist/core/OfflineQueue.d.ts.map +1 -0
  13. package/dist/element.d.cts +2 -0
  14. package/dist/element.d.ts +2 -0
  15. package/dist/element.d.ts.map +1 -0
  16. package/dist/embed/index.d.ts +2 -0
  17. package/dist/embed/index.d.ts.map +1 -0
  18. package/dist/factory.d.ts +8 -0
  19. package/dist/factory.d.ts.map +1 -0
  20. package/dist/iframe.d.cts +17 -0
  21. package/dist/iframe.d.ts +15 -0
  22. package/dist/iframe.d.ts.map +1 -0
  23. package/dist/index.d.cts +166 -0
  24. package/dist/index.d.ts +8 -0
  25. package/dist/index.d.ts.map +1 -0
  26. package/dist/react-components/ChatInput.d.ts +24 -0
  27. package/dist/react-components/ChatInput.d.ts.map +1 -0
  28. package/dist/react-components/ChatMessageItem.d.ts +24 -0
  29. package/dist/react-components/ChatMessageItem.d.ts.map +1 -0
  30. package/dist/react-components/ChatMessageList.d.ts +31 -0
  31. package/dist/react-components/ChatMessageList.d.ts.map +1 -0
  32. package/dist/react-components/ChatThread.d.ts +19 -0
  33. package/dist/react-components/ChatThread.d.ts.map +1 -0
  34. package/dist/react-components/ConversationList.d.ts +13 -0
  35. package/dist/react-components/ConversationList.d.ts.map +1 -0
  36. package/dist/react-components/EmojiPicker.d.ts +15 -0
  37. package/dist/react-components/EmojiPicker.d.ts.map +1 -0
  38. package/dist/react-components/ReactionBar.d.ts +10 -0
  39. package/dist/react-components/ReactionBar.d.ts.map +1 -0
  40. package/dist/react-components/ReportDialog.d.ts +30 -0
  41. package/dist/react-components/ReportDialog.d.ts.map +1 -0
  42. package/dist/react-components/index.d.ts +10 -0
  43. package/dist/react-components/index.d.ts.map +1 -0
  44. package/dist/react-components/theme.d.ts +19 -0
  45. package/dist/react-components/theme.d.ts.map +1 -0
  46. package/dist/react-components/utils.d.ts +4 -0
  47. package/dist/react-components/utils.d.ts.map +1 -0
  48. package/dist/react.cjs +1833 -459
  49. package/dist/react.d.cts +229 -0
  50. package/dist/react.d.ts +72 -0
  51. package/dist/react.d.ts.map +1 -0
  52. package/dist/react.js +1832 -461
  53. package/dist/shared/ChatController.d.ts +65 -0
  54. package/dist/shared/ChatController.d.ts.map +1 -0
  55. package/dist/shared/upload.d.ts +3 -0
  56. package/dist/shared/upload.d.ts.map +1 -0
  57. package/dist/support-widget.global.js +50 -25
  58. package/dist/support.d.ts +99 -0
  59. package/dist/support.d.ts.map +1 -0
  60. package/dist/transport/HttpTransport.d.ts +20 -0
  61. package/dist/transport/HttpTransport.d.ts.map +1 -0
  62. package/dist/transport/WebSocketTransport.d.ts +78 -0
  63. package/dist/transport/WebSocketTransport.d.ts.map +1 -0
  64. package/dist/types-COPVrm3K.d.cts +256 -0
  65. package/dist/types-COPVrm3K.d.ts +256 -0
  66. package/dist/types.d.ts +271 -0
  67. package/dist/types.d.ts.map +1 -0
  68. package/dist/umd.d.ts +6 -0
  69. package/dist/umd.d.ts.map +1 -0
  70. package/dist/version.d.ts +2 -0
  71. package/dist/version.d.ts.map +1 -0
  72. package/dist/widget/icons.d.ts +8 -0
  73. package/dist/widget/icons.d.ts.map +1 -0
  74. package/dist/widget/index.d.ts +2 -0
  75. package/dist/widget/index.d.ts.map +1 -0
  76. package/dist/widget/storage.d.ts +5 -0
  77. package/dist/widget/storage.d.ts.map +1 -0
  78. package/dist/widget/styles.d.ts +3 -0
  79. package/dist/widget/styles.d.ts.map +1 -0
  80. package/package.json +1 -1
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AAC/C,OAAO,EAAE,aAAa,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EAAE,cAAc,EAAE,MAAM,yBAAyB,CAAC;AACzD,YAAY,EACV,mBAAmB,EACnB,mBAAmB,EACnB,mBAAmB,EACnB,yBAAyB,GAC1B,MAAM,WAAW,CAAC;AACnB,YAAY,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AACnE,OAAO,EAAE,YAAY,EAAE,MAAM,WAAW,CAAC;AACzC,YAAY,EACV,QAAQ,EACR,WAAW,EACX,UAAU,EACV,eAAe,EACf,mBAAmB,EACnB,UAAU,EACV,YAAY,EACZ,WAAW,EACX,YAAY,EACZ,gBAAgB,EAChB,YAAY,EACZ,yBAAyB,EACzB,6BAA6B,EAC7B,sBAAsB,EACtB,kBAAkB,EAClB,wBAAwB,EACxB,kBAAkB,EAClB,gBAAgB,EAChB,WAAW,EACX,cAAc,EACd,aAAa,EACb,eAAe,EACf,UAAU,EACV,kBAAkB,EAClB,mBAAmB,GACpB,MAAM,SAAS,CAAC"}
@@ -0,0 +1,24 @@
1
+ import React from 'react';
2
+ import type { Attachment } from '../types';
3
+ interface ChatInputProps {
4
+ onSend: (content: string, attachments?: Attachment[]) => void | Promise<void>;
5
+ onTypingChange?: (isTyping: boolean) => void;
6
+ onUploadAttachment?: (file: File | Blob, onProgress?: (percent: number) => void, signal?: AbortSignal) => Promise<{
7
+ data: Attachment | null;
8
+ error: {
9
+ message: string;
10
+ } | null;
11
+ } | undefined>;
12
+ onDeleteAttachment?: (fileId: string) => void | Promise<void>;
13
+ onValidateFile?: (file: File) => {
14
+ valid: boolean;
15
+ error?: string;
16
+ };
17
+ placeholder?: string;
18
+ disabled?: boolean;
19
+ maxAttachments?: number;
20
+ accept?: string;
21
+ }
22
+ export declare function ChatInput({ onSend, onTypingChange, onUploadAttachment, onDeleteAttachment, onValidateFile, placeholder, disabled, maxAttachments, accept, }: ChatInputProps): React.JSX.Element;
23
+ export {};
24
+ //# sourceMappingURL=ChatInput.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ChatInput.d.ts","sourceRoot":"","sources":["../../src/react-components/ChatInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmD,MAAM,OAAO,CAAC;AAExE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAa3C,UAAU,cAAc;IACtB,MAAM,EAAE,CAAC,OAAO,EAAE,MAAM,EAAE,WAAW,CAAC,EAAE,UAAU,EAAE,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAC9E,cAAc,CAAC,EAAE,CAAC,QAAQ,EAAE,OAAO,KAAK,IAAI,CAAC;IAC7C,kBAAkB,CAAC,EAAE,CACnB,IAAI,EAAE,IAAI,GAAG,IAAI,EACjB,UAAU,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,EACtC,MAAM,CAAC,EAAE,WAAW,KACjB,OAAO,CAAC;QAAE,IAAI,EAAE,UAAU,GAAG,IAAI,CAAC;QAAC,KAAK,EAAE;YAAE,OAAO,EAAE,MAAM,CAAA;SAAE,GAAG,IAAI,CAAA;KAAE,GAAG,SAAS,CAAC,CAAC;IACzF,kBAAkB,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAC9D,cAAc,CAAC,EAAE,CAAC,IAAI,EAAE,IAAI,KAAK;QAAE,KAAK,EAAE,OAAO,CAAC;QAAC,KAAK,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;IACpE,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,wBAAgB,SAAS,CAAC,EACxB,MAAM,EACN,cAAc,EACd,kBAAkB,EAClB,kBAAkB,EAClB,cAAc,EACd,WAAiC,EACjC,QAAgB,EAChB,cAAkB,EAClB,MAA0B,GAC3B,EAAE,cAAc,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAgkBpC"}
@@ -0,0 +1,24 @@
1
+ import React from 'react';
2
+ import type { ChatMessage } from '../types';
3
+ interface UserProfile {
4
+ display_name: string;
5
+ username?: string;
6
+ avatar_url?: string;
7
+ }
8
+ interface ChatMessageItemProps {
9
+ message: ChatMessage;
10
+ currentUserId?: string;
11
+ conversationId?: string;
12
+ profile?: UserProfile;
13
+ onAddReaction?: (messageId: string, emoji: string) => void | Promise<void>;
14
+ onRemoveReaction?: (messageId: string, emoji: string) => void | Promise<void>;
15
+ onEdit?: (messageId: string, content: string) => void | Promise<void>;
16
+ onDelete?: (messageId: string) => void | Promise<void>;
17
+ onReport?: (messageId: string) => void;
18
+ onFetchAttachmentUrl?: (fileId: string) => Promise<string>;
19
+ isOwnMessage?: boolean;
20
+ highlight?: boolean;
21
+ }
22
+ export declare function ChatMessageItem({ message, currentUserId, conversationId, profile, onAddReaction, onRemoveReaction, onEdit, onDelete, onReport, onFetchAttachmentUrl, isOwnMessage: isOwnMessageProp, highlight, }: ChatMessageItemProps): React.JSX.Element;
23
+ export {};
24
+ //# sourceMappingURL=ChatMessageItem.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ChatMessageItem.d.ts","sourceRoot":"","sources":["../../src/react-components/ChatMessageItem.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA8B,MAAM,OAAO,CAAC;AAEnD,OAAO,KAAK,EAAE,WAAW,EAAc,MAAM,UAAU,CAAC;AAuBxD,UAAU,WAA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 +1,31 @@
1
+ import React from 'react';
2
+ import type { ChatMessage } from '../types';
3
+ interface UserProfile {
4
+ display_name: string;
5
+ username?: string;
6
+ avatar_url?: string;
7
+ }
8
+ interface ChatMessageListProps {
9
+ messages: ChatMessage[];
10
+ currentUserId?: string;
11
+ conversationId?: string;
12
+ profiles?: Map<string, UserProfile>;
13
+ hasMore?: boolean;
14
+ isLoading?: boolean;
15
+ onLoadMore?: () => void;
16
+ onAddReaction?: (messageId: string, emoji: string) => void | Promise<void>;
17
+ onRemoveReaction?: (messageId: string, emoji: string) => void | Promise<void>;
18
+ onEdit?: (messageId: string, content: string) => void | Promise<void>;
19
+ onDelete?: (messageId: string) => void | Promise<void>;
20
+ onReport?: (messageId: string) => void;
21
+ onFetchAttachmentUrl?: (fileId: string) => Promise<string>;
22
+ firstUnreadMessageId?: string;
23
+ /** @deprecated use firstUnreadMessageId instead */
24
+ unreadSince?: string;
25
+ isNearBottom?: boolean;
26
+ onReachBottom?: () => void;
27
+ emptyState?: React.ReactNode;
28
+ }
29
+ export declare function ChatMessageList({ messages, currentUserId, conversationId, profiles, hasMore, isLoading, onLoadMore, onAddReaction, onRemoveReaction, onEdit, onDelete, onReport, onFetchAttachmentUrl, firstUnreadMessageId, unreadSince, isNearBottom: isNearBottomProp, onReachBottom, emptyState, }: ChatMessageListProps): React.JSX.Element;
30
+ export {};
31
+ //# sourceMappingURL=ChatMessageList.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ChatMessageList.d.ts","sourceRoot":"","sources":["../../src/react-components/ChatMessageList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmD,MAAM,OAAO,CAAC;AAExE,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAG5C,UAAU,WAAW;IACnB,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,UAAU,oBAAoB;IAC5B,QAA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AU,EACV,aAAa,EACb,gBAAgB,EAChB,MAAM,EACN,QAAQ,EACR,QAAQ,EACR,oBAAoB,EACpB,oBAAoB,EACpB,WAAW,EACX,YAAY,EAAE,gBAAgB,EAC9B,aAAa,EACb,UAAU,GACX,EAAE,oBAAoB,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAwU1C"}
@@ -0,0 +1,19 @@
1
+ import React from 'react';
2
+ import type { ChatTheme } from './theme';
3
+ interface UserProfile {
4
+ display_name: string;
5
+ username?: string;
6
+ avatar_url?: string;
7
+ }
8
+ interface ChatThreadProps {
9
+ conversationId: string;
10
+ theme?: ChatTheme;
11
+ currentUserId?: string;
12
+ profiles?: Map<string, UserProfile>;
13
+ title?: string;
14
+ subtitle?: string;
15
+ onFetchAttachmentUrl?: (fileId: string) => Promise<string>;
16
+ }
17
+ export declare function ChatThread({ conversationId, theme, currentUserId, profiles, title, subtitle, onFetchAttachmentUrl, }: ChatThreadProps): React.JSX.Element;
18
+ export {};
19
+ //# sourceMappingURL=ChatThread.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ChatThread.d.ts","sourceRoot":"","sources":["../../src/react-components/ChatThread.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA6B,MAAM,OAAO,CAAC;AAMlD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAGzC,UAAU,WAAW;IACnB,YAAY,EAAE,MAAM,CAAC;IACrB,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,UAAU,eAAe;IACvB,cAAc,EAAE,MAAM,CAAC;IACvB,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,EAAE,GAAG,CAAC,MAAM,EAAE,WAAW,CAAC,CAAC;IACpC,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,oBAAoB,CAAC,EAAE,CAAC,MAAM,EAAE,MAAM,KAAK,OAAO,CAAC,MAAM,CAAC,CAAC;CAC5D;AAUD,wBAAgB,UAAU,CAAC,EACzB,cAAc,EACd,KAAK,EACL,aAAa,EACb,QAAQ,EACR,KAAc,EACd,QAAQ,EACR,oBAAoB,GACrB,EAAE,eAAe,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CAgKrC"}
@@ -0,0 +1,13 @@
1
+ import React from 'react';
2
+ import type { Conversation } from '../types';
3
+ import type { ChatTheme } from './theme';
4
+ interface ConversationListProps {
5
+ conversationType?: Conversation['conversation_type'];
6
+ selectedConversationId?: string | null;
7
+ onSelect?: (conversation: Conversation) => void;
8
+ theme?: ChatTheme;
9
+ title?: string;
10
+ }
11
+ export declare function ConversationList({ conversationType, selectedConversationId, onSelect, theme, title, }: ConversationListProps): React.JSX.Element;
12
+ export {};
13
+ //# sourceMappingURL=ConversationList.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ConversationList.d.ts","sourceRoot":"","sources":["../../src/react-components/ConversationList.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA4B,MAAM,OAAO,CAAC;AAGjD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,UAAU,CAAC;AAC7C,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAGzC,UAAU,qBAAqB;IAC7B,gBAAgB,CAAC,EAAE,YAAY,CAAC,mBAAmB,CAAC,CAAC;IACrD,sBAAsB,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACvC,QAAQ,CAAC,EAAE,CAAC,YAAY,EAAE,YAAY,KAAK,IAAI,CAAC;IAChD,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAUD,wBAAgB,gBAAgB,CAAC,EAC/B,gBAAgB,EAChB,sBAAsB,EACtB,QAAQ,EACR,KAAK,EACL,KAAuB,GACxB,EAAE,qBAAqB,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CA4J3C"}
@@ -0,0 +1,15 @@
1
+ import React from 'react';
2
+ interface EmojiPickerProps {
3
+ onSelect: (emoji: string) => void;
4
+ onClose: () => void;
5
+ anchorRef: React.RefObject<HTMLButtonElement | null>;
6
+ emojis?: string[];
7
+ }
8
+ export declare function EmojiPicker({ onSelect, onClose, anchorRef, emojis, }: EmojiPickerProps): React.JSX.Element | null;
9
+ interface EmojiPickerTriggerProps {
10
+ onSelect: (emoji: string) => void;
11
+ emojis?: string[];
12
+ }
13
+ export declare function EmojiPickerTrigger({ onSelect, emojis, }: EmojiPickerTriggerProps): React.JSX.Element;
14
+ export {};
15
+ //# sourceMappingURL=EmojiPicker.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"EmojiPicker.d.ts","sourceRoot":"","sources":["../../src/react-components/EmojiPicker.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmD,MAAM,OAAO,CAAC;AAKxE,UAAU,gBAAgB;IACxB,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,OAAO,EAAE,MAAM,IAAI,CAAC;IACpB,SAAS,EAAE,KAAK,CAAC,SAAS,CAAC,iBAAiB,GAAG,IAAI,CAAC,CAAC;IACrD,MAAM,CAAC,EAAE,MAAM,EAAE,CAAC;CACnB;AAED,wBAAgB,WAAW,CAAC,EAC1B,QAAQ,EACR,OAAO,EACP,SAAS,EACT,MAAwB,GACzB,EAAE,gBAAgB,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,GAAG,IAAI,CA6F7C;AAED,UAAU,uBAAuB;IAC/B,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,MAAM,CAAC,EAAE,MAAM,EAAE,CAAC;CACnB;AAED,wBAAgB,kBAAkB,CAAC,EACjC,QAAQ,EACR,MAAM,GACP,EAAE,uBAAuB,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CA4D7C"}
@@ -0,0 +1,10 @@
1
+ import React from 'react';
2
+ import type { ReactionSummary } from '../types';
3
+ interface ReactionBarProps {
4
+ reactions: ReactionSummary[];
5
+ currentUserId?: string;
6
+ onToggleReaction: (emoji: string) => void;
7
+ }
8
+ export declare function ReactionBar({ reactions, currentUserId, onToggleReaction, }: ReactionBarProps): React.JSX.Element | null;
9
+ export {};
10
+ //# sourceMappingURL=ReactionBar.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ReactionBar.d.ts","sourceRoot":"","sources":["../../src/react-components/ReactionBar.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,UAAU,CAAC;AAEhD,UAAU,gBAAgB;IACxB,SAAS,EAAE,eAAe,EAAE,CAAC;IAC7B,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,gBAAgB,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CAC3C;AAED,wBAAgB,WAAW,CAAC,EAC1B,SAAS,EACT,aAAa,EACb,gBAAgB,GACjB,EAAE,gBAAgB,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,GAAG,IAAI,CAyC7C"}
@@ -0,0 +1,30 @@
1
+ import React from 'react';
2
+ declare const REPORT_REASONS: readonly [{
3
+ readonly value: "spam";
4
+ readonly label: "Spam";
5
+ }, {
6
+ readonly value: "harassment";
7
+ readonly label: "Harassment";
8
+ }, {
9
+ readonly value: "hate";
10
+ readonly label: "Hate speech";
11
+ }, {
12
+ readonly value: "violence";
13
+ readonly label: "Violence";
14
+ }, {
15
+ readonly value: "other";
16
+ readonly label: "Other";
17
+ }];
18
+ type ReportReason = (typeof REPORT_REASONS)[number]['value'];
19
+ interface ReportDialogProps {
20
+ messageId: string;
21
+ onSubmit: (data: {
22
+ messageId: string;
23
+ reason: ReportReason;
24
+ description?: string;
25
+ }) => void | Promise<void>;
26
+ onClose: () => void;
27
+ }
28
+ export declare function ReportDialog({ messageId, onSubmit, onClose, }: ReportDialogProps): React.JSX.Element;
29
+ export {};
30
+ //# sourceMappingURL=ReportDialog.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"ReportDialog.d.ts","sourceRoot":"","sources":["../../src/react-components/ReportDialog.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAmB,MAAM,OAAO,CAAC;AAExC,QAAA,MAAM,cAAc;;;;;;;;;;;;;;;EAMV,CAAC;AAEX,KAAK,YAAY,GAAG,CAAC,OAAO,cAAc,CAAC,CAAC,MAAM,CAAC,CAAC,OAAO,CAAC,CAAC;AAE7D,UAAU,iBAAiB;IACzB,SAAS,EAAE,MAAM,CAAC;IAClB,QAAQ,EAAE,CAAC,IAAI,EAAE;QACf,SAAS,EAAE,MAAM,CAAC;QAClB,MAAM,EAAE,YAAY,CAAC;QACrB,WAAW,CAAC,EAAE,MAAM,CAAC;KACtB,KAAK,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAC3B,OAAO,EAAE,MAAM,IAAI,CAAC;CACrB;AAED,wBAAgB,YAAY,CAAC,EAC3B,SAAS,EACT,QAAQ,EACR,OAAO,GACR,EAAE,iBAAiB,GAAG,KAAK,CAAC,GAAG,CAAC,OAAO,CA6SvC"}
@@ -0,0 +1,10 @@
1
+ export { ChatInput } from './ChatInput';
2
+ export { ChatMessageItem } from './ChatMessageItem';
3
+ export { ChatMessageList } from './ChatMessageList';
4
+ export { ChatThread } from './ChatThread';
5
+ export { ConversationList } from './ConversationList';
6
+ export { EmojiPicker, EmojiPickerTrigger } from './EmojiPicker';
7
+ export { ReactionBar } from './ReactionBar';
8
+ export { ReportDialog } from './ReportDialog';
9
+ export type { ChatTheme } from './theme';
10
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/react-components/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AACxC,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,eAAe,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AACtD,OAAO,EAAE,WAAW,EAAE,kBAAkB,EAAE,MAAM,eAAe,CAAC;AAChE,OAAO,EAAE,WAAW,EAAE,MAAM,eAAe,CAAC;AAC5C,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,YAAY,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC"}
@@ -0,0 +1,19 @@
1
+ import type { CSSProperties } from 'react';
2
+ export interface ChatTheme {
3
+ primary?: string;
4
+ ownBubble?: string;
5
+ ownText?: string;
6
+ otherBubble?: string;
7
+ otherText?: string;
8
+ surface?: string;
9
+ surfaceMuted?: string;
10
+ borderColor?: string;
11
+ textColor?: string;
12
+ mutedText?: string;
13
+ borderRadius?: number | string;
14
+ fontFamily?: string;
15
+ }
16
+ type ThemeStyle = CSSProperties & Record<string, string | number | undefined>;
17
+ export declare function themeToStyle(theme?: ChatTheme): ThemeStyle;
18
+ export {};
19
+ //# sourceMappingURL=theme.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../src/react-components/theme.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAE3C,MAAM,WAAW,SAAS;IACxB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,YAAY,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC/B,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB;AAED,KAAK,UAAU,GAAG,aAAa,GAAG,MAAM,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,GAAG,SAAS,CAAC,CAAC;AAE9E,wBAAgB,YAAY,CAAC,KAAK,CAAC,EAAE,SAAS,GAAG,UAAU,CAmB1D"}
@@ -0,0 +1,4 @@
1
+ export declare function formatMessageTime(value?: string): string;
2
+ export declare function formatDayLabel(value?: string): string;
3
+ export declare function isSameDay(left?: string, right?: string): boolean;
4
+ //# sourceMappingURL=utils.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/react-components/utils.ts"],"names":[],"mappings":"AAWA,wBAAgB,iBAAiB,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAGxD;AAED,wBAAgB,cAAc,CAAC,KAAK,CAAC,EAAE,MAAM,GAAG,MAAM,CAGrD;AAED,wBAAgB,SAAS,CAAC,IAAI,CAAC,EAAE,MAAM,EAAE,KAAK,CAAC,EAAE,MAAM,GAAG,OAAO,CAUhE"}