stream-chat-react-native 4.5.0 → 4.6.0

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/README.md CHANGED
@@ -1,7 +1,7 @@
1
1
  # Official React Native SDK for Stream Chat
2
2
 
3
3
  <p align="center">
4
- <a href="https://getstream.io/chat/react-native-chat/tutorial/"><img src="https://github.com/GetStream/stream-chat-react-native/blob/master/screenshots/readme/cover.png" alt="react native chat" width="100%" /></a>
4
+ <a href="https://getstream.io/chat/react-native-chat/tutorial/"><img src="https://github.com/GetStream/stream-chat-react-native/blob/main/screenshots/readme/cover.png" alt="react native chat" width="100%" /></a>
5
5
  </p>
6
6
 
7
7
  > The official React Native and Expo components for Stream Chat, a service for
@@ -9,7 +9,7 @@
9
9
 
10
10
 
11
11
  [![NPM](https://img.shields.io/npm/v/stream-chat-react-native.svg)](https://www.npmjs.com/package/stream-chat-react-native)
12
- [![Build Status](https://github.com/GetStream/stream-chat-react-native/workflows/test/badge.svg?branch=master)](https://github.com/GetStream/stream-chat-react-native/actions)
12
+ [![Build Status](https://github.com/GetStream/stream-chat-react-native/workflows/test/badge.svg?branch=main)](https://github.com/GetStream/stream-chat-react-native/actions)
13
13
  [![Component Reference](https://img.shields.io/badge/docs-component%20reference-blue.svg)](https://getstream.io/chat/docs/sdk/reactnative)
14
14
 
15
15
  <img align="right" src="https://getstream.imgix.net/images/ios-chat-tutorial/iphone_chat_art@3x.png?auto=format,enhance" width="50%" />
@@ -68,7 +68,7 @@ We welcome code changes that improve this library or fix a problem, and please m
68
68
 
69
69
  ## Git flow & Release process
70
70
 
71
- We enforce conventional commits and have an automated releasing process using workspaces and semantic-release. Read our [git flow & release process guide](https://github.com/GetStream/stream-chat-react-native/blob/master/RELEASE_PROCESS.md) for more information
71
+ We enforce conventional commits and have an automated releasing process using workspaces and semantic-release. Read our [git flow & release process guide](https://github.com/GetStream/stream-chat-react-native/blob/main/RELEASE_PROCESS.md) for more information
72
72
 
73
73
  ## We are hiring
74
74
 
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "stream-chat-react-native",
3
3
  "description": "The official React Native SDK for Stream Chat, a service for building chat applications",
4
- "version": "4.5.0",
4
+ "version": "4.6.0",
5
5
  "author": {
6
6
  "company": "Stream.io Inc",
7
7
  "name": "Stream.io Inc"
@@ -11,7 +11,7 @@
11
11
  "types": "types/index.d.ts",
12
12
  "dependencies": {
13
13
  "es6-symbol": "^3.1.3",
14
- "stream-chat-react-native-core": "4.5.0"
14
+ "stream-chat-react-native-core": "4.6.0"
15
15
  },
16
16
  "peerDependencies": {
17
17
  "@react-native-community/cameraroll": ">=4.0.1",
package/src/index.js CHANGED
@@ -72,9 +72,9 @@ registerNativeHandlers({
72
72
  }
73
73
  const results = await CameraRoll.getPhotos({
74
74
  after,
75
- assetType: 'Photos',
75
+ assetType: 'All',
76
76
  first,
77
- include: ['imageSize'],
77
+ include: ['fileSize', 'filename', 'imageSize', 'playableDuration'],
78
78
  });
79
79
  const assets = results.edges.map((edge) => ({
80
80
  ...edge.node.image,
@@ -210,11 +210,12 @@ registerNativeHandlers({
210
210
  // https://github.com/ivpusic/react-native-image-crop-picker/issues/901
211
211
  // This we can't rely on them as it is, and we need to use Image.getSize
212
212
  // to get accurate size.
213
- const getSize = () => new Promise((resolve) => {
214
- Image.getSize(photo.path, (width, height) => {
215
- resolve({height, width});
213
+ const getSize = () =>
214
+ new Promise((resolve) => {
215
+ Image.getSize(photo.path, (width, height) => {
216
+ resolve({ height, width });
217
+ });
216
218
  });
217
- });
218
219
 
219
220
  try {
220
221
  const { height, width } = await getSize();