@webinex/chatify 1.0.0-alpha05 → 1.0.0-alpha07

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/dist/index.d.ts CHANGED
@@ -1,4 +1,5 @@
1
- import React, { PropsWithChildren, FC, Ref, RefObject, CSSProperties } from 'react';
1
+ /// <reference types="react" />
2
+ import React$1, { PropsWithChildren, FC, Ref, RefObject, CSSProperties } from 'react';
2
3
  import * as react_jsx_runtime from 'react/jsx-runtime';
3
4
  import { AxiosInstance } from 'axios';
4
5
 
@@ -8,29 +9,29 @@ interface Localizer {
8
9
  chatCreated: () => string;
9
10
  };
10
11
  message: {
11
- read: () => React.ReactNode;
12
- reading: () => React.ReactNode;
13
- sending: () => React.ReactNode;
12
+ read: () => React$1.ReactNode;
13
+ reading: () => React$1.ReactNode;
14
+ sending: () => React$1.ReactNode;
14
15
  };
15
16
  addChat: {
16
- title: () => React.ReactNode;
17
+ title: () => React$1.ReactNode;
17
18
  name: {
18
- label: () => React.ReactNode;
19
+ label: () => React$1.ReactNode;
19
20
  required: () => string;
20
21
  max250: () => string;
21
22
  };
22
23
  members: {
23
- label: () => React.ReactNode;
24
+ label: () => React$1.ReactNode;
24
25
  required: () => string;
25
26
  };
26
- submitBtn: () => React.ReactNode;
27
+ submitBtn: () => React$1.ReactNode;
27
28
  };
28
29
  }
29
- declare const LocalizerContext: React.Context<Localizer>;
30
+ declare const LocalizerContext: React$1.Context<Localizer>;
30
31
  declare function useLocalizer(): Localizer;
31
32
  declare const defaultLocalizer: Localizer;
32
33
 
33
- type Customizable<TComponent extends React.ComponentType<any>, TKey extends string> = TComponent & {
34
+ type Customizable<TComponent extends React$1.ComponentType<any>, TKey extends string> = TComponent & {
34
35
  Component: TComponent;
35
36
  key: TKey;
36
37
  };
@@ -45,7 +46,7 @@ interface Account {
45
46
  name: string;
46
47
  avatar: string;
47
48
  }
48
- interface Message$1 {
49
+ interface Message {
49
50
  id: string;
50
51
  chatId: string;
51
52
  text: string;
@@ -63,7 +64,7 @@ interface Chat {
63
64
  interface ChatListItem {
64
65
  id: string;
65
66
  name: string;
66
- message: Message$1;
67
+ message: Message;
67
68
  unreadCount: number;
68
69
  }
69
70
  interface SendMessageRequest {
@@ -127,7 +128,7 @@ declare class ChatifyClient {
127
128
  chatId: string;
128
129
  skip?: number;
129
130
  take?: number;
130
- }) => Promise<Message$1[]>;
131
+ }) => Promise<Message[]>;
131
132
  send: (request: SendMessageRequest) => Promise<void>;
132
133
  read: (request: ReadRequest) => Promise<void>;
133
134
  removeMember: (request: RemoveMemberRequest) => Promise<void>;
@@ -192,7 +193,7 @@ declare const ACTIONS: {
192
193
  chatId: string;
193
194
  }) => State;
194
195
  message_received: (state: State, { message, requestId }: {
195
- message: Message$1;
196
+ message: Message;
196
197
  requestId: string;
197
198
  }) => State;
198
199
  chat_created: (state: State, { chat }: {
@@ -233,10 +234,10 @@ type Action = {
233
234
 
234
235
  type Reducer = ReturnType<typeof useReducer>;
235
236
  type Subscriber = (state: State) => void;
236
- declare function useReducer(): readonly [React.MutableRefObject<State>, (action: Action) => void, (subscriber: Subscriber) => () => void];
237
+ declare function useReducer(): readonly [React$1.MutableRefObject<State>, (action: Action) => void, (subscriber: Subscriber) => () => void];
237
238
  declare function ReducerProvider({ children }: PropsWithChildren<{}>): react_jsx_runtime.JSX.Element;
238
239
  declare function useDispatch(): (action: Action) => void;
239
- declare function useStateRef(): React.MutableRefObject<State>;
240
+ declare function useStateRef(): React$1.MutableRefObject<State>;
240
241
  declare function useSelect<TResult>(select: (state: State) => TResult, deps: any[]): TResult;
241
242
 
242
243
  declare function useChat(args: {
@@ -251,7 +252,7 @@ declare function useLoadMore({ chatId }: {
251
252
 
252
253
  type MessageState = ({
253
254
  type: 'message';
254
- } & Message$1) | {
255
+ } & Message) | {
255
256
  type: 'more';
256
257
  } | {
257
258
  type: 'sending';
@@ -301,15 +302,15 @@ interface ChatNameProps {
301
302
  }
302
303
  declare const ChatName: Customizable<FC<ChatNameProps>, "ChatName">;
303
304
 
304
- interface ChatListItemProps {
305
+ interface ChatListItemBoxProps {
305
306
  chat: ChatListItem;
306
307
  }
307
- declare const ChatListItemName: Customizable<FC<ChatListItemProps>, "ChatListItemName">;
308
- declare const ChatListItemUnreadCount: Customizable<FC<ChatListItemProps>, "ChatListItemUnreadCount">;
309
- declare const ChatListItemLastMessage: Customizable<FC<ChatListItemProps>, "ChatListItemLastMessage">;
310
- declare const ChatListItemLastMessageAuthor: Customizable<FC<ChatListItemProps>, string>;
311
- declare const ChatListItemLastMessageContent: Customizable<FC<ChatListItemProps>, string>;
312
- declare const ChatListItemView: Customizable<FC<ChatListItemProps>, "ChatListItemView">;
308
+ declare const ChatListItemName: Customizable<FC<ChatListItemBoxProps>, "ChatListItemName">;
309
+ declare const ChatListItemUnreadCount: Customizable<FC<ChatListItemBoxProps>, "ChatListItemUnreadCount">;
310
+ declare const ChatListItemLastMessage: Customizable<FC<ChatListItemBoxProps>, "ChatListItemLastMessage">;
311
+ declare const ChatListItemLastMessageAuthor: Customizable<FC<ChatListItemBoxProps>, string>;
312
+ declare const ChatListItemLastMessageContent: Customizable<FC<ChatListItemBoxProps>, string>;
313
+ declare const ChatListItemBox: Customizable<FC<ChatListItemBoxProps>, "ChatListItemBox">;
313
314
 
314
315
  interface SendingMessageProps {
315
316
  text: string;
@@ -320,19 +321,19 @@ declare const SendingMessageInfoBox: Customizable<FC<SendingMessageProps>, strin
320
321
  declare const SendingMessageBody: Customizable<FC<SendingMessageProps>, string>;
321
322
  declare const SendingMessage: Customizable<FC<SendingMessageProps>, string>;
322
323
 
323
- interface MessageProps {
324
- message: Message$1;
324
+ interface MessageBoxProps {
325
+ message: Message;
325
326
  }
326
- interface MessageBoxProps extends MessageProps {
327
+ interface MessageRowProps extends MessageBoxProps {
327
328
  containerRef?: Ref<HTMLDivElement>;
328
329
  }
329
- declare const MessageAuthor: Customizable<FC<MessageProps>, string>;
330
- declare const MessageText: Customizable<FC<MessageProps>, string>;
331
- declare const MessageInfoBox: Customizable<FC<MessageProps>, string>;
332
- declare const MessageBody: Customizable<FC<MessageProps>, string>;
330
+ declare const MessageAuthor: Customizable<FC<MessageBoxProps>, string>;
331
+ declare const MessageText: Customizable<FC<MessageBoxProps>, string>;
332
+ declare const MessageInfoBox: Customizable<FC<MessageBoxProps>, string>;
333
+ declare const MessageBody: Customizable<FC<MessageBoxProps>, string>;
334
+ declare const MessageRow: Customizable<FC<MessageRowProps>, string>;
333
335
  declare const MessageBox: Customizable<FC<MessageBoxProps>, string>;
334
- declare const Message: Customizable<FC<MessageProps>, string>;
335
- interface MessageReadObserverProps extends MessageProps {
336
+ interface MessageReadObserverProps extends MessageBoxProps {
336
337
  messageRef: RefObject<HTMLDivElement | null>;
337
338
  }
338
339
  declare const MessageReadObserver: Customizable<FC<MessageReadObserverProps>, string>;
@@ -345,7 +346,7 @@ interface ChatifyCustomizeValue {
345
346
  ChatHeaderMembers?: typeof ChatHeaderMembers.Component | null;
346
347
  ChatSettingsButton?: typeof ChatSettingsButton.Component | null;
347
348
  ChatName?: typeof ChatName.Component | null;
348
- ChatListItem?: typeof ChatListItemView.Component | null;
349
+ ChatListItemBox?: typeof ChatListItemBox.Component | null;
349
350
  ChatListItemName?: typeof ChatListItemName.Component | null;
350
351
  ChatListItemUnreadCount?: typeof ChatListItemUnreadCount.Component | null;
351
352
  ChatListItemLastMessage?: typeof ChatListItemLastMessage.Component | null;
@@ -355,9 +356,9 @@ interface ChatifyCustomizeValue {
355
356
  SendingMessageBody?: typeof SendingMessageBody.Component | null;
356
357
  SendingMessageInfoBox?: typeof SendingMessageInfoBox.Component | null;
357
358
  SendingMessageText?: typeof SendingMessageText.Component | null;
358
- Message?: typeof Message.Component | null;
359
- MessageReadObserver?: typeof MessageReadObserver.Component | null;
360
359
  MessageBox?: typeof MessageBox.Component | null;
360
+ MessageReadObserver?: typeof MessageReadObserver.Component | null;
361
+ MessageRow?: typeof MessageRow.Component | null;
361
362
  MessageBody?: typeof MessageBody.Component | null;
362
363
  MessageInfoBox?: typeof MessageInfoBox.Component | null;
363
364
  MessageText?: typeof MessageText.Component | null;
@@ -376,6 +377,13 @@ interface ChatHeaderProps {
376
377
  }
377
378
  declare function ChatHeader(props: ChatHeaderProps): react_jsx_runtime.JSX.Element;
378
379
 
380
+ interface SystemMessageProps {
381
+ text: string;
382
+ sentAt: string;
383
+ }
384
+ declare function formatSystemMessage(localizer: Localizer, text: string): React.ReactNode;
385
+ declare function SystemMessage(props: SystemMessageProps): react_jsx_runtime.JSX.Element;
386
+
379
387
  declare function useClient(): ChatifyClient;
380
388
  declare function useMe(): string;
381
389
  interface ChatifyContextValue {
@@ -386,4 +394,4 @@ declare function ChatifyContext({ value, children }: PropsWithChildren<{
386
394
  value: ChatifyContextValue;
387
395
  }>): react_jsx_runtime.JSX.Element;
388
396
 
389
- export { ACTIONS, Account, Action, AddChatButton, AddChatRequest, AddMemberRequest, Avatar, AvatarProps, Chat, ChatHeader, ChatHeaderMembers, ChatHeaderMembersProps, ChatHeaderProps, ChatListItem, ChatListItemLastMessage, ChatListItemLastMessageAuthor, ChatListItemLastMessageContent, ChatListItemName, ChatListItemProps, ChatListItemUnreadCount, ChatListItemView, Chatify, ChatifyClient, ChatifyClientConfig, ChatifyContext, ChatifyContextValue, ChatifyCustomizeValue, ChatifyProps, ChatifySignalRConfig, File, Header, Localizer, LocalizerContext, Message$1 as Message, MessageContent, MessageState, ReadEvent, ReadRequest, Reducer, ReducerProvider, RemoveMemberRequest, SendMessageRequest, defaultLocalizer, useAccounts, useAddChat, useAddMember, useChat, useChatList, useClient, useDispatch, useLoadMore, useLocalizer, useMe, useMessages, useReadMonitor, useReducer, useRemoveMember, useSelect, useSignalRMonitor, useStateRef };
397
+ export { ACTIONS, Account, Action, AddChatButton, AddChatRequest, AddMemberRequest, Avatar, AvatarProps, Chat, ChatHeader, ChatHeaderMembers, ChatHeaderMembersProps, ChatHeaderProps, ChatListItem, ChatListItemBox, ChatListItemBoxProps, ChatListItemLastMessage, ChatListItemLastMessageAuthor, ChatListItemLastMessageContent, ChatListItemName, ChatListItemUnreadCount, Chatify, ChatifyClient, ChatifyClientConfig, ChatifyContext, ChatifyContextValue, ChatifyCustomizeValue, ChatifyProps, ChatifySignalRConfig, File, Header, Localizer, LocalizerContext, Message, MessageAuthor, MessageBody, MessageBox, MessageBoxProps, MessageContent, MessageInfoBox, MessageReadObserver, MessageReadObserverProps, MessageRow, MessageRowProps, MessageState, MessageText, ReadEvent, ReadRequest, Reducer, ReducerProvider, RemoveMemberRequest, SendMessageRequest, SystemMessage, SystemMessageProps, defaultLocalizer, formatSystemMessage, useAccounts, useAddChat, useAddMember, useChat, useChatList, useClient, useDispatch, useLoadMore, useLocalizer, useMe, useMessages, useReadMonitor, useReducer, useRemoveMember, useSelect, useSignalRMonitor, useStateRef };
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@webinex/chatify",
3
3
  "description": "Webinex Wispo",
4
4
  "private": false,
5
- "version": "1.0.0-alpha05",
5
+ "version": "1.0.0-alpha07",
6
6
  "author": "Webinex Dev",
7
7
  "license": "Apache-2.0",
8
8
  "main": "dist/cjs/index.js",
package/src/ui/Aside.tsx CHANGED
@@ -2,7 +2,7 @@ import { Menu, MenuProps } from 'antd';
2
2
  import { useCallback, useEffect, useMemo } from 'react';
3
3
  import type { MenuItemType } from 'antd/es/menu/hooks/useItems';
4
4
  import { useChatList, useDispatch, useSelect } from '../core';
5
- import { ChatListItemView } from './ChatListItem';
5
+ import { ChatListItemBox } from './ChatListItem';
6
6
 
7
7
  export function Aside() {
8
8
  const activeChatId = useSelect((x) => x.ui.chatId, []);
@@ -22,7 +22,7 @@ export function Aside() {
22
22
  return [];
23
23
  }
24
24
 
25
- return chats.map((x) => ({ key: x.id, label: <ChatListItemView chat={x} /> }));
25
+ return chats.map((x) => ({ key: x.id, label: <ChatListItemBox chat={x} /> }));
26
26
  }, [chats]);
27
27
 
28
28
  useEffect(() => {
@@ -1,4 +1,4 @@
1
- import { Message } from './Message';
1
+ import { MessageBox } from './Message';
2
2
  import { useMessages } from '../core';
3
3
  import { LoadMore } from './LoadMore';
4
4
  import { SendingMessage } from './SendingMessage';
@@ -23,7 +23,7 @@ export function ChatBody(props: ChatBodyProps) {
23
23
 
24
24
  switch (x.type) {
25
25
  case 'message': {
26
- return <Message message={x} key={x.id} />;
26
+ return <MessageBox message={x} key={x.id} />;
27
27
  }
28
28
 
29
29
  case 'sending': {
@@ -6,11 +6,11 @@ import { ChatListItem as ChatListItemModel } from '../core';
6
6
  import { FC } from 'react';
7
7
  import { customize } from '../util';
8
8
 
9
- export interface ChatListItemProps {
9
+ export interface ChatListItemBoxProps {
10
10
  chat: ChatListItemModel;
11
11
  }
12
12
 
13
- const _ChatListItemName: FC<ChatListItemProps> = (props) => {
13
+ const _ChatListItemName: FC<ChatListItemBoxProps> = (props) => {
14
14
  const { name } = props.chat;
15
15
 
16
16
  return (
@@ -24,7 +24,7 @@ _ChatListItemName.displayName = 'ChatListItemName';
24
24
 
25
25
  export const ChatListItemName = customize('ChatListItemName', _ChatListItemName);
26
26
 
27
- const _ChatListItemUnreadCount: FC<ChatListItemProps> = (props) => {
27
+ const _ChatListItemUnreadCount: FC<ChatListItemBoxProps> = (props) => {
28
28
  const { unreadCount } = props.chat;
29
29
 
30
30
  if (unreadCount <= 0) {
@@ -38,7 +38,7 @@ _ChatListItemUnreadCount.displayName = 'ChatListItemUnreadCount';
38
38
 
39
39
  export const ChatListItemUnreadCount = customize('ChatListItemUnreadCount', _ChatListItemUnreadCount);
40
40
 
41
- const _ChatListItemLastMessage: FC<ChatListItemProps> = (props) => {
41
+ const _ChatListItemLastMessage: FC<ChatListItemBoxProps> = (props) => {
42
42
  return (
43
43
  <div className="wxchtf-chat-last">
44
44
  <ChatListItemLastMessageAuthor {...props} />
@@ -51,7 +51,7 @@ _ChatListItemLastMessage.displayName = 'ChatListItemLastMessage';
51
51
 
52
52
  export const ChatListItemLastMessage = customize('ChatListItemLastMessage', _ChatListItemLastMessage);
53
53
 
54
- export const ChatListItemLastMessageAuthor = customize<FC<ChatListItemProps>, string>(
54
+ export const ChatListItemLastMessageAuthor = customize<FC<ChatListItemBoxProps>, string>(
55
55
  'ChatListItemLastMessageAuthor',
56
56
  (props) => {
57
57
  const { message } = props.chat;
@@ -68,7 +68,7 @@ export const ChatListItemLastMessageAuthor = customize<FC<ChatListItemProps>, st
68
68
  },
69
69
  );
70
70
 
71
- export const ChatListItemLastMessageContent = customize<FC<ChatListItemProps>, string>(
71
+ export const ChatListItemLastMessageContent = customize<FC<ChatListItemBoxProps>, string>(
72
72
  'ChatListItemLastMessageContent',
73
73
  (props) => {
74
74
  const { message } = props.chat;
@@ -84,7 +84,7 @@ export const ChatListItemLastMessageContent = customize<FC<ChatListItemProps>, s
84
84
  },
85
85
  );
86
86
 
87
- const _ChatListItem: FC<ChatListItemProps> = (props) => {
87
+ const _ChatListItemBox: FC<ChatListItemBoxProps> = (props) => {
88
88
  const { message } = props.chat;
89
89
 
90
90
  return (
@@ -96,6 +96,6 @@ const _ChatListItem: FC<ChatListItemProps> = (props) => {
96
96
  );
97
97
  };
98
98
 
99
- _ChatListItem.displayName = 'ChatListItem';
99
+ _ChatListItemBox.displayName = 'ChatListItemBox';
100
100
 
101
- export const ChatListItemView = customize('ChatListItemView', _ChatListItem);
101
+ export const ChatListItemBox = customize('ChatListItemBox', _ChatListItemBox);
@@ -12,7 +12,7 @@ import { AddChatButton } from './AddChatButton';
12
12
  import { Footer } from './Footer';
13
13
  import { ChatName } from './ChatName';
14
14
  import {
15
- ChatListItemView,
15
+ ChatListItemBox,
16
16
  ChatListItemLastMessage,
17
17
  ChatListItemLastMessageAuthor,
18
18
  ChatListItemLastMessageContent,
@@ -26,12 +26,12 @@ import {
26
26
  SendingMessageText,
27
27
  } from './SendingMessage';
28
28
  import {
29
- Message,
30
29
  MessageAuthor,
31
30
  MessageBody,
32
31
  MessageBox,
33
32
  MessageInfoBox,
34
33
  MessageReadObserver,
34
+ MessageRow,
35
35
  MessageText,
36
36
  } from './Message';
37
37
 
@@ -43,7 +43,7 @@ export interface ChatifyCustomizeValue {
43
43
  ChatHeaderMembers?: typeof ChatHeaderMembers.Component | null;
44
44
  ChatSettingsButton?: typeof ChatSettingsButton.Component | null;
45
45
  ChatName?: typeof ChatName.Component | null;
46
- ChatListItem?: typeof ChatListItemView.Component | null;
46
+ ChatListItemBox?: typeof ChatListItemBox.Component | null;
47
47
  ChatListItemName?: typeof ChatListItemName.Component | null;
48
48
  ChatListItemUnreadCount?: typeof ChatListItemUnreadCount.Component | null;
49
49
  ChatListItemLastMessage?: typeof ChatListItemLastMessage.Component | null;
@@ -53,9 +53,9 @@ export interface ChatifyCustomizeValue {
53
53
  SendingMessageBody?: typeof SendingMessageBody.Component | null;
54
54
  SendingMessageInfoBox?: typeof SendingMessageInfoBox.Component | null;
55
55
  SendingMessageText?: typeof SendingMessageText.Component | null;
56
- Message?: typeof Message.Component | null;
57
- MessageReadObserver?: typeof MessageReadObserver.Component | null;
58
56
  MessageBox?: typeof MessageBox.Component | null;
57
+ MessageReadObserver?: typeof MessageReadObserver.Component | null;
58
+ MessageRow?: typeof MessageRow.Component | null;
59
59
  MessageBody?: typeof MessageBody.Component | null;
60
60
  MessageInfoBox?: typeof MessageInfoBox.Component | null;
61
61
  MessageText?: typeof MessageText.Component | null;
@@ -1,19 +1,19 @@
1
1
  import { useMe } from '../ChatifyContext';
2
2
  import { FC, Ref, RefObject, useEffect, useMemo, useRef } from 'react';
3
- import { useDispatch, useSelect, Message as MessageModel } from '../core';
3
+ import { Message, useDispatch, useSelect } from '../core';
4
4
  import { customize } from '../util';
5
5
  import { useLocalizer } from './localizer';
6
6
  import { Avatar } from './Avatar';
7
7
 
8
- export interface MessageProps {
9
- message: MessageModel;
8
+ export interface MessageBoxProps {
9
+ message: Message;
10
10
  }
11
11
 
12
- export interface MessageBoxProps extends MessageProps {
12
+ export interface MessageRowProps extends MessageBoxProps {
13
13
  containerRef?: Ref<HTMLDivElement>;
14
14
  }
15
15
 
16
- export const MessageAuthor = customize<FC<MessageProps>, string>('MessageAuthor', (props) => {
16
+ export const MessageAuthor = customize<FC<MessageBoxProps>, string>('MessageAuthor', (props) => {
17
17
  const { sentBy } = props.message;
18
18
 
19
19
  return (
@@ -23,12 +23,12 @@ export const MessageAuthor = customize<FC<MessageProps>, string>('MessageAuthor'
23
23
  );
24
24
  });
25
25
 
26
- export const MessageText = customize<FC<MessageProps>, string>('MessageText', (props) => {
26
+ export const MessageText = customize<FC<MessageBoxProps>, string>('MessageText', (props) => {
27
27
  const { text } = props.message;
28
28
  return <div className="wxchtf-message-text">{text}</div>;
29
29
  });
30
30
 
31
- export const MessageInfoBox = customize<FC<MessageProps>, string>('MessageInfoBox', (props) => {
31
+ export const MessageInfoBox = customize<FC<MessageBoxProps>, string>('MessageInfoBox', (props) => {
32
32
  const { message } = props;
33
33
  const { id, sentBy, sentAt, read } = message;
34
34
  const me = useMe();
@@ -48,7 +48,7 @@ export const MessageInfoBox = customize<FC<MessageProps>, string>('MessageInfoBo
48
48
  );
49
49
  });
50
50
 
51
- export const MessageBody = customize<FC<MessageProps>, string>('MessageBody', (props) => {
51
+ export const MessageBody = customize<FC<MessageBoxProps>, string>('MessageBody', (props) => {
52
52
  return (
53
53
  <div className="wxchtf-message-body">
54
54
  <MessageText {...props} />
@@ -57,7 +57,7 @@ export const MessageBody = customize<FC<MessageProps>, string>('MessageBody', (p
57
57
  );
58
58
  });
59
59
 
60
- export const MessageBox = customize<FC<MessageBoxProps>, string>('MessageBox', (props) => {
60
+ export const MessageRow = customize<FC<MessageRowProps>, string>('MessageRow', (props) => {
61
61
  const { message, containerRef } = props;
62
62
  const { sentBy } = message;
63
63
  const me = useMe();
@@ -71,20 +71,21 @@ export const MessageBox = customize<FC<MessageBoxProps>, string>('MessageBox', (
71
71
  );
72
72
  });
73
73
 
74
- export const Message = customize<FC<MessageProps>, string>('Message', (props) => {
74
+ export const MessageBox = customize<FC<MessageBoxProps>, string>('MessageBox', (props) => {
75
75
  const ref = useRef<HTMLDivElement | null>(null);
76
76
 
77
77
  return (
78
78
  <>
79
79
  <MessageReadObserver messageRef={ref} {...props} />
80
- <MessageBox containerRef={ref} {...props} />
80
+ <MessageRow containerRef={ref} {...props} />
81
81
  </>
82
82
  );
83
83
  });
84
84
 
85
- export interface MessageReadObserverProps extends MessageProps {
85
+ export interface MessageReadObserverProps extends MessageBoxProps {
86
86
  messageRef: RefObject<HTMLDivElement | null>;
87
87
  }
88
+
88
89
  export const MessageReadObserver = customize<FC<MessageReadObserverProps>, string>(
89
90
  'MessageReadObserver',
90
91
  (props) => {
package/src/ui/index.ts CHANGED
@@ -6,3 +6,5 @@ export * from './Header';
6
6
  export * from './ChatHeader';
7
7
  export * from './ChatHeaderMembers';
8
8
  export * from './ChatListItem';
9
+ export * from './Message';
10
+ export * from './SystemMessage';