Fix a bug when dismissing a media preview. (#1428)

This commit is contained in:
Doug
2023-08-01 10:45:42 +01:00
committed by GitHub
parent e39b7eb6c6
commit f06e063f03
2 changed files with 2 additions and 0 deletions
@@ -256,6 +256,7 @@ class RoomScreenViewModel: RoomScreenViewModelType, RoomScreenViewModelProtocol
switch action {
case .displayMediaFile(let file, let title):
state.bindings.composerFocused = false // Hide the keyboard otherwise a big white space is sometimes shown when dismissing the preview.
state.bindings.mediaPreviewItem = MediaPreviewItem(file: file, title: title)
case .displayLocation(let body, let geoURI, let description):
callback?(.displayLocation(body: body, geoURI: geoURI, description: description))
+1
View File
@@ -0,0 +1 @@
Fix a bug where media previews would sometimes dismiss to show the timeline with a big empty space at the bottom.