Skip to content

Commit 212d82c

Browse files
authored
Merge pull request #3079 from GetStream/develop
Next Release
2 parents f38dbe6 + e2a01e9 commit 212d82c

File tree

323 files changed

+3577
-5899
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

323 files changed

+3577
-5899
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
[![NPM](https://img.shields.io/npm/v/stream-chat-react-native.svg)](https://www.npmjs.com/package/stream-chat-react-native)
1111
[![Build Status](https://github.com/GetStream/stream-chat-react-native/actions/workflows/release.yml/badge.svg)](https://github.com/GetStream/stream-chat-react-native/actions)
1212
[![Component Reference](https://img.shields.io/badge/docs-component%20reference-blue.svg)](https://getstream.io/chat/docs/sdk/reactnative)
13-
![JS Bundle Size](https://img.shields.io/badge/js_bundle_size-467%20KB-blue)
13+
![JS Bundle Size](https://img.shields.io/badge/js_bundle_size-469%20KB-blue)
1414

1515
<img align="right" src="https://getstream.imgix.net/images/ios-chat-tutorial/[email protected]?auto=format,enhance" width="50%" />
1616

examples/ExpoMessaging/app.json

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,13 @@
4848
{
4949
"microphonePermission": "$(PRODUCT_NAME) would like to use your microphone for voice recording."
5050
}
51+
],
52+
[
53+
"expo-video",
54+
{
55+
"supportsBackgroundPlayback": true,
56+
"supportsPictureInPicture": true
57+
}
5158
]
5259
]
5360
}

examples/ExpoMessaging/app/index.tsx

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,14 @@ import { ChannelList } from 'stream-chat-expo';
33
import { useContext, useMemo } from 'react';
44
import { Stack, useRouter } from 'expo-router';
55
import { ChannelSort } from 'stream-chat';
6-
import { StreamChatGenerics } from '../types';
76
import { AppContext } from '../context/AppContext';
87
import { user } from '../constants';
98

109
const filters = {
1110
members: { $in: [user.id] },
1211
type: 'messaging',
1312
};
14-
const sort: ChannelSort<StreamChatGenerics> = { last_updated: -1 };
13+
const sort: ChannelSort = { last_updated: -1 };
1514
const options = {
1615
state: true,
1716
watch: true,

examples/ExpoMessaging/components/ChatWrapper.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import React, { PropsWithChildren } from 'react';
1+
import React, { PropsWithChildren, useRef } from 'react';
22
import {
33
Chat,
44
OverlayProvider,
@@ -7,7 +7,6 @@ import {
77
useCreateChatClient,
88
} from 'stream-chat-expo';
99
import { AuthProgressLoader } from './AuthProgressLoader';
10-
import { StreamChatGenerics } from '../types';
1110
import { STREAM_API_KEY, user, userToken } from '../constants';
1211
import { useSafeAreaInsets } from 'react-native-safe-area-context';
1312
import { useStreamChatTheme } from '../useStreamChatTheme';
@@ -34,7 +33,7 @@ export const ChatWrapper = ({ children }: PropsWithChildren<{}>) => {
3433
}
3534

3635
return (
37-
<OverlayProvider<StreamChatGenerics>
36+
<OverlayProvider
3837
bottomInset={bottom}
3938
i18nInstance={streami18n}
4039
value={{ style: theme }}

examples/ExpoMessaging/context/AppContext.tsx

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,14 @@
1-
import { PropsWithChildren, createContext, useContext, useState } from 'react';
2-
import { StreamChatGenerics } from '../types';
1+
import { PropsWithChildren, createContext, useState } from 'react';
32
import { Channel as ChannelType } from 'stream-chat';
43
import { ThreadContextValue } from 'stream-chat-expo';
54

65
export type AppContextType = {
7-
channel: ChannelType<StreamChatGenerics> | undefined;
8-
setChannel: React.Dispatch<React.SetStateAction<ChannelType<StreamChatGenerics> | undefined>>;
6+
channel: ChannelType | undefined;
7+
setChannel: React.Dispatch<React.SetStateAction<ChannelType | undefined>>;
98
setThread: React.Dispatch<
10-
React.SetStateAction<ThreadContextValue<StreamChatGenerics>['thread'] | undefined>
9+
React.SetStateAction<ThreadContextValue['thread'] | undefined>
1110
>;
12-
thread: ThreadContextValue<StreamChatGenerics>['thread'] | undefined;
11+
thread: ThreadContextValue['thread'] | undefined;
1312
};
1413

1514
export const AppContext = createContext<AppContextType>({
@@ -20,9 +19,9 @@ export const AppContext = createContext<AppContextType>({
2019
});
2120

2221
export const AppProvider = ({ children }: PropsWithChildren) => {
23-
const [channel, setChannel] = useState<ChannelType<StreamChatGenerics> | undefined>(undefined);
22+
const [channel, setChannel] = useState<ChannelType | undefined>(undefined);
2423
const [thread, setThread] = useState<
25-
ThreadContextValue<StreamChatGenerics>['thread'] | undefined
24+
ThreadContextValue['thread'] | undefined
2625
>(undefined);
2726

2827
return (
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
import {
2+
DefaultAttachmentData,
3+
DefaultChannelData,
4+
DefaultCommandData,
5+
DefaultEventData,
6+
DefaultMemberData,
7+
DefaultMessageData,
8+
DefaultPollData,
9+
DefaultPollOptionData,
10+
DefaultReactionData,
11+
DefaultThreadData,
12+
DefaultUserData,
13+
} from 'stream-chat-expo';
14+
15+
declare module 'stream-chat' {
16+
/* eslint-disable @typescript-eslint/no-empty-object-type */
17+
18+
interface CustomAttachmentData extends DefaultAttachmentData {}
19+
20+
interface CustomChannelData extends DefaultChannelData {}
21+
22+
interface CustomCommandData extends DefaultCommandData {}
23+
24+
interface CustomEventData extends DefaultEventData {}
25+
26+
interface CustomMemberData extends DefaultMemberData {}
27+
28+
interface CustomUserData extends DefaultUserData {}
29+
30+
interface CustomMessageData extends DefaultMessageData {}
31+
32+
interface CustomPollOptionData extends DefaultPollOptionData {}
33+
34+
interface CustomPollData extends DefaultPollData {}
35+
36+
interface CustomReactionData extends DefaultReactionData {}
37+
38+
interface CustomThreadData extends DefaultThreadData {}
39+
40+
/* eslint-enable @typescript-eslint/no-empty-object-type */
41+
}

examples/ExpoMessaging/package.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,11 @@
2323
"expo-image-manipulator": "~13.0.6",
2424
"expo-image-picker": "~16.0.6",
2525
"expo-linking": "~7.0.5",
26-
"expo-media-library": "~17.0.6",
2726
"expo-router": "~4.0.17",
2827
"expo-sharing": "~13.0.1",
2928
"expo-splash-screen": "~0.29.22",
3029
"expo-status-bar": "~2.0.1",
30+
"expo-video": "^2.0.5",
3131
"react": "18.3.1",
3232
"react-dom": "18.3.1",
3333
"react-native": "0.77.1",
@@ -46,5 +46,8 @@
4646
"@rnx-kit/metro-config": "^2.0.1",
4747
"@rnx-kit/metro-resolver-symlinks": "^0.2.1"
4848
},
49+
"resolutions": {
50+
"@types/react": "^19.0.0"
51+
},
4952
"private": true
5053
}

examples/ExpoMessaging/types.ts

Lines changed: 0 additions & 23 deletions
This file was deleted.

0 commit comments

Comments
 (0)