mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-02 12:07:55 +00:00
Add a fullscreen button to TimelineMediaPreviewScreen and hook up swiping through the timeline. (#3638)
* Add a fullscreen button to media previews - Not ideal but the gestures conflict with the preview controller. * Don't un-flip the preview thumbnail until the preview has disappeared, and only do it on iOS 18. * Add all of the loaded items for previewing in the preview controller.
This commit is contained in:
@@ -104,7 +104,6 @@ class TimelineMediaPreviewViewModelTests: XCTestCase {
|
||||
XCTAssertEqual(viewModel.state.currentItem.contentType, "JPEG image")
|
||||
|
||||
// When choosing to save the image.
|
||||
let item = context.viewState.currentItem
|
||||
let deferred = deferFulfillment(context.$viewState) { $0.bindings.alertInfo != nil }
|
||||
context.send(viewAction: .saveCurrentItem)
|
||||
try await deferred.fulfill()
|
||||
@@ -164,7 +163,7 @@ class TimelineMediaPreviewViewModelTests: XCTestCase {
|
||||
|
||||
private func loadInitialItem() async throws {
|
||||
let deferred = deferFulfillment(viewModel.state.fileLoadedPublisher) { _ in true }
|
||||
context.send(viewAction: .updateCurrentItem(context.viewState.previewItems[0]))
|
||||
context.send(viewAction: .updateCurrentItem(context.viewState.previewItems[context.viewState.initialItemIndex]))
|
||||
try await deferred.fulfill()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user