You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
BREAKING CHANGE: stylesheet import path changed & v1 stylesheet has been dropped, see release guide for more information
BREAKING CHANGE: theme v1 related markup and classNames have been removed
BREAKING CHANGE: `themeVersion` property has been removed from `ChatContext`
Copy file name to clipboardExpand all lines: docusaurus/docs/React/basics/overview.mdx
+3-2Lines changed: 3 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -14,12 +14,13 @@ Use cases include team and social messaging, virtual events, livestream gaming,
14
14
- Text input commands (ex: Giphy and @mentions)
15
15
- Image and file uploads
16
16
- Video playback
17
+
- Audio recording
17
18
- Read state and typing indicators
18
19
- Channel and message lists
19
20
20
21
## Where to get started
21
22
22
-
If you are new to our SDK it is best to go through a of our [tutorial](https://getstream.io/chat/react-chat/tutorial/).
23
+
If you are new to our SDK it is best to go through our [tutorial](https://getstream.io/chat/react-chat/tutorial/).
23
24
24
25
After that, our [getting started page](./getting-started.mdx) is a great next step.
25
26
@@ -32,4 +33,4 @@ If you are integrating our SDK, please pay attention to our [Theming](../theming
32
33
A common pattern in the library is the use of context provider hooks. These custom hooks allow for effective value sharing between parent components and their children.
33
34
This makes customization straightforward, as you can use our exported hooks in your custom components to receive the exact values needed, while also subscribing to context changes.
34
35
35
-
The left navigation will guide you to the various documentation sections for information on everything regarding our robust component library. Check out the instructions below for adding the library to your React project.
36
+
The left navigation will guide you to the various documentation sections for information on everything regarding our robust component library. Check out the instructions for adding the library to your React project.
The value is forwarded to the context from the `Channel` component [prop `acceptedFiles`](../../components/core-components/channel.mdx#acceptedfiles).
22
22
23
23
| Type |
24
24
| -------- |
@@ -48,9 +48,24 @@ The configurations object for the currently active channel.
48
48
| ------ |
49
49
| object |
50
50
51
+
### channelUnreadUiState
52
+
53
+
The read state maintained for use by components representing channel unread state (for example `UnreadMessagesSeparator`, `UnreadMessagesNotification`).
|**last_read**|`Date`| Date when the channel was marked read the last time. |
58
+
|**unread_messages**|`number`| The count of unread messages in a given channel. Unread count refers only to foreign (not own) unread messages. |
59
+
|**first_unread_message_id**|`string` or `undefined`| The ID of the message that was marked unread (`notification.mark_unread` event). The value is available only when a message is marked unread. Therefore, cannot be relied on to place unread messages UI. |
60
+
|**last_read_message_id**|`string` or `undefined`| The ID of the message preceding the first unread message. |
61
+
62
+
| Type |
63
+
| ---------------------- |
64
+
|`ChannelUnreadUiState`|
65
+
51
66
### dragAndDropWindow
52
67
53
-
If true, chat users will be able to drag and drop file uploads to the entire channel window.
68
+
The value is forwarded to the context from the `Channel` component [prop `dragAndDropWindow`](../../components/core-components/channel.mdx#draganddropwindow).
54
69
55
70
| Type | Default |
56
71
| ------- | ------- |
@@ -66,8 +81,7 @@ Number of milliseconds to debounce firing the URL enrichment queries when typing
66
81
67
82
### enrichURLForPreview
68
83
69
-
A global flag to toggle the URL enrichment and link previews in `MessageInput`. By default, the feature is disabled. It can be overridden on Thread and MessageList level through `additionalMessageInputProps`
70
-
or directly on `MessageInput` level through `urlEnrichmentConfig` prop.
84
+
The value is forwarded to the context from the `Channel` component [prop `enrichURLForPreview`](../../components/core-components/channel.mdx#enrichurlforpreview).
71
85
72
86
| Type | Default |
73
87
| ------- | ------- |
@@ -91,18 +105,18 @@ Custom function to identify URLs in a string for later generation of link previe
91
105
92
106
### giphyVersion
93
107
94
-
The giphy version to use when displaying giphies.
108
+
The value is forwarded to the context from the `Channel` component [prop `giphyVersion`](../../components/core-components/channel.mdx#giphyversion).
A custom function to provide size configuration for image attachments
116
+
The value is forwarded to the context from the `Channel` component [prop `imageAttachmentSizeHandler`](../../components/core-components/channel.mdx#imageattachmentsizehandler).
@@ -145,7 +159,7 @@ Boolean for the `channel` loading more messages.
145
159
| ------- |
146
160
| boolean |
147
161
148
-
### loadingMoreNewer?
162
+
### loadingMoreNewer
149
163
150
164
Flag signalling whether newer messages are being loaded as the user scrolls down in the message list. Used internally by `VirtualizedMessageList`.
151
165
@@ -155,7 +169,7 @@ Flag signalling whether newer messages are being loaded as the user scrolls down
155
169
156
170
### maxNumberOfFiles
157
171
158
-
The maximum number of attachments allowed per `message`, defaults to the Stream Chat API maximum.
172
+
The value is forwarded to the context from the `Channel` component [prop `maxNumberOfFiles`](../../components/core-components/channel.mdx#maxnumberoffiles).
159
173
160
174
| Type | Default |
161
175
| ------ | ------- |
@@ -179,7 +193,7 @@ Array of [message objects](https://getstream.io/chat/docs/javascript/message_for
179
193
180
194
### multipleUploads
181
195
182
-
Whether to allow multiple attachment uploads on a message.
196
+
The value is forwarded to the context from the `Channel` component [prop `multipleUploads`](../../components/core-components/channel.mdx#multipleuploads).
183
197
184
198
| Type | Default |
185
199
| ------- | ------- |
@@ -209,21 +223,6 @@ Custom function to react to link preview dismissal. See the guide [Link Previews
209
223
| ------------------------------------ |
210
224
|`(linkPreview: LinkPreview) => void`|
211
225
212
-
### channelUnreadUiState
213
-
214
-
The read state maintained for use by components representing channel unread state (for example `UnreadMessagesSeparator`, `UnreadMessagesNotification`).
|**last_read**|`Date`| Date when the channel was marked read the last time. |
219
-
|**unread_messages**|`number`| The count of unread messages in a given channel. Unread count refers only to foreign (not own) unread messages. |
220
-
|**first_unread_message_id**|`string` or `undefined`| The ID of the message that was marked unread (`notification.mark_unread` event). The value is available only when a message is marked unread. Therefore, cannot be relied on to place unread messages UI. |
221
-
|**last_read_message_id**|`string` or `undefined`| The ID of the message preceding the first unread message. |
222
-
223
-
| Type |
224
-
|-----------------------|
225
-
|`ChannelUnreadUiState`|
226
-
227
226
### pinnedMessages
228
227
229
228
The messages that are pinned in the `channel`.
@@ -258,7 +257,7 @@ Flag signalling whether the scroll to the bottom is prevented. Used internally b
258
257
259
258
### shouldGenerateVideoThumbnail
260
259
261
-
You can turn on/off thumbnail generation for video attachments
260
+
The value is forwarded to the context from the `Channel` component [prop `shouldGenerateVideoThumbnail`](../../components/core-components/channel.mdx#shouldgeneratevideothumbnail).
262
261
263
262
| Type |
264
263
| --------- |
@@ -306,7 +305,7 @@ Flag signalling whether the scroll to the bottom is prevented in thread. Used in
306
305
307
306
### videoAttachmentSizeHandler
308
307
309
-
A custom function to provide size configuration for video attachments
308
+
The value is forwarded to the context from the `Channel` component [prop `videoAttachmentSizeHandler`](../../components/core-components/channel.mdx#videoattachmentsizehandler).
The `StreamChat` client instance. Any methods from the `stream-chat-js` API interface can be run off this object.
21
+
The value is forwarded to the context from the `Chat` component [prop `client`](../../components/core-components/chat.mdx#client).
22
22
23
23
| Type |
24
24
| ------ |
@@ -49,7 +49,7 @@ The `queryInProgress` values are:
49
49
-`null` - at least one channels page has been loaded and there is no query in progress at the moment
50
50
51
51
| Type |
52
-
|----------------------|
52
+
|--------------------|
53
53
|`ChannelsQueryState`|
54
54
55
55
### closeMobileNav
@@ -62,8 +62,7 @@ The function to close mobile navigation.
62
62
63
63
### customClasses
64
64
65
-
Object containing custom CSS classnames to override the library's default container CSS. See [CSS and Theming](../../guides/theming/css-and-theming.mdx)
66
-
for implementation assistance.
65
+
The value is forwarded to the context from the `Chat` component [prop `customClasses`](../../components/core-components/chat.mdx#customclasses)
67
66
68
67
| Type |
69
68
| ------ |
@@ -120,25 +119,15 @@ You can override the default behavior by pulling it from context and then utiliz
120
119
121
120
### theme
122
121
123
-
Deprecated and to be removed in a future major release. Use the `customStyles` prop to adjust CSS variables and [customize the theme](../../guides/theming/css-and-theming.mdx#css-variables) of your app.
122
+
The value is forwarded to the context from the `Chat` component [prop `theme`](../../components/core-components/chat.mdx#theme)
124
123
125
-
| Type |
126
-
| ----- |
127
-
| Theme |
128
-
129
-
### themeVersion
130
-
131
-
Stream chat theme version 2 has been introduced with the release of stream-chat-react v10.0.0. This flag is used internally by some UI components of the SDK and the integrators shouldn't need to use it. The value is extracted from a CSS variable `--str-chat__theme-version`. You can set it to values `'1'` or `'2'` in your stylesheets and import the corresponding v2 stylesheet from `stream-chat-react/dist`. Find out more about benefits that the theme version 2 brings to the integrators with [the theming guide](../../theming/introduction.mdx).
132
-
133
-
| Type | Default |
134
-
| -------------- | ------- |
135
-
|`'1'`\|`'2'`|`'1'`|
124
+
| Type |
125
+
| ------ |
126
+
| string |
136
127
137
128
### useImageFlagEmojisOnWindow
138
129
139
-
Windows 10 does not support country flag emojis out of the box. It chooses to render these emojis as characters instead.
140
-
Stream Chat can override this behavior by loading a custom web font that will render images instead (PNGs or SVGs depending
141
-
on the platform). Set this prop to true if you want to use these custom emojis for Windows users.
130
+
The value is forwarded to the context from the `Chat` component [prop `useImageFlagEmojisOnWindow`](../../components/core-components/chat.mdx#useimageflagemojisonwindow).
Custom UI component to override the default suggestion Item component.
@@ -346,11 +338,11 @@ Custom UI component to display the header of a `Thread`.
346
338
347
339
### ThreadInput
348
340
349
-
Custom UI component to replace the `MessageInput` of a `Thread`. For the applications using [theme version 1](../../guides/theming/css-and-theming.mdx), the default is `MessageInputSmall`. Applications using [theme version 2](../../theming/introduction.mdx) will use`MessageInputFlat` by default.
341
+
Custom UI component to replace the `MessageInput` of a `Thread`. The component uses`MessageInputFlat` by default.
Configuration parameter to mark the active channel as read when mounted (opened). By default, the channel is marked read on mount.
469
+
470
+
| Type | Default |
471
+
| ------- | ------- |
472
+
| boolean | true |
473
+
482
474
### maxNumberOfFiles
483
475
484
476
The maximum number of attachments allowed per message, defaults to the Stream Chat API maximum.
@@ -691,11 +683,11 @@ Custom UI component to display the header of a `Thread`.
691
683
692
684
### ThreadInput
693
685
694
-
Custom UI component to replace the `MessageInput` of a `Thread`. For the applications using [theme version 1](../../guides/theming/css-and-theming.mdx), the default is `MessageInputSmall`. Applications using [theme version 2](../../theming/introduction.mdx) will use`MessageInputFlat` by default.
686
+
Custom UI component to replace the `MessageInput` of a `Thread`. The component uses`MessageInputFlat` by default.
0 commit comments