-
Notifications
You must be signed in to change notification settings - Fork 375
Expand file tree
/
Copy pathindex.js
More file actions
76 lines (69 loc) · 1.53 KB
/
Copy pathindex.js
File metadata and controls
76 lines (69 loc) · 1.53 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
import { Platform } from 'react-native';
import { registerNativeHandlers } from 'stream-chat-react-native-core';
import { compressImage, multipartUpload } from './handlers';
import {
Audio,
deleteFile,
FlatList,
getLocalAssetUri,
getPhotos,
iOS14RefreshGallerySelection,
NativeShimmerView,
oniOS14GalleryLibrarySelectionChange,
overrideAudioRecordingConfiguration,
pickDocument,
pickImage,
saveFile,
setClipboardString,
shareImage,
Sound,
takePhoto,
triggerHaptic,
Video,
} from './optionalDependencies';
/**
* The default native handlers this package registers with the core SDK.
*/
export const defaultNativeHandlers = {
Audio,
compressImage,
deleteFile,
FlatList,
getLocalAssetUri,
getPhotos,
iOS14RefreshGallerySelection,
multipartUpload,
NativeShimmerView,
oniOS14GalleryLibrarySelectionChange,
overrideAudioRecordingConfiguration,
pickDocument,
pickImage,
saveFile,
setClipboardString,
shareImage,
Sound,
takePhoto,
triggerHaptic,
Video,
};
registerNativeHandlers({
...defaultNativeHandlers,
SDK: 'stream-chat-react-native',
});
if (Platform.OS === 'android') {
if (typeof Symbol === 'undefined') {
require('es6-symbol/implement');
if (Array.prototype[Symbol.iterator] === undefined) {
Array.prototype[Symbol.iterator] = function () {
let i = 0;
return {
next: () => ({
done: i >= this.length,
value: this[i++],
}),
};
};
}
}
}
export * from 'stream-chat-react-native-core';