Changeset View
Changeset View
Standalone View
Standalone View
native/chat/multimedia-message.react.js
Show First 20 Lines • Show All 64 Lines • ▼ Show 20 Lines | class MultimediaMessage extends React.PureComponent<Props, State> { | ||||
onPressMultimedia = ( | onPressMultimedia = ( | ||||
mediaInfo: MediaInfo, | mediaInfo: MediaInfo, | ||||
initialCoordinates: LayoutCoordinates, | initialCoordinates: LayoutCoordinates, | ||||
) => { | ) => { | ||||
const { navigation, item, route, verticalBounds } = this.props; | const { navigation, item, route, verticalBounds } = this.props; | ||||
navigation.navigate<'VideoPlaybackModal' | 'ImageModal'>({ | navigation.navigate<'VideoPlaybackModal' | 'ImageModal'>({ | ||||
name: | name: | ||||
mediaInfo.type === 'video' | mediaInfo.type === 'video' || mediaInfo.type === 'encrypted_video' | ||||
? VideoPlaybackModalRouteName | ? VideoPlaybackModalRouteName | ||||
: ImageModalRouteName, | : ImageModalRouteName, | ||||
key: getMediaKey(item, mediaInfo), | key: getMediaKey(item, mediaInfo), | ||||
params: { | params: { | ||||
presentedFrom: route.key, | presentedFrom: route.key, | ||||
mediaInfo, | mediaInfo, | ||||
item, | item, | ||||
initialCoordinates, | initialCoordinates, | ||||
▲ Show 20 Lines • Show All 170 Lines • Show Last 20 Lines |