From 9da5b99b28046a804c44d2c8c37ea6f7ccecceff Mon Sep 17 00:00:00 2001 From: Nathan Mattes Date: Wed, 24 Jul 2024 16:01:25 +0200 Subject: [PATCH] Show modal on ipad (IOS-241) --- .../Provider/DataSourceFacade+Notifications.swift | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/Mastodon/Protocol/Provider/DataSourceFacade+Notifications.swift b/Mastodon/Protocol/Provider/DataSourceFacade+Notifications.swift index f6dac507c..7abca3694 100644 --- a/Mastodon/Protocol/Provider/DataSourceFacade+Notifications.swift +++ b/Mastodon/Protocol/Provider/DataSourceFacade+Notifications.swift @@ -17,7 +17,15 @@ extension DataSourceFacade { provider.coordinator.hideLoading() - provider.coordinator.present(scene: .notificationRequests(viewModel: viewModel), transition: .show) + let transition: SceneCoordinator.Transition + + if provider.traitCollection.userInterfaceIdiom == .phone { + transition = .show + } else { + transition = .modal(animated: true) + } + + provider.coordinator.present(scene: .notificationRequests(viewModel: viewModel), transition: transition) } catch { //TODO: Error Handling provider.coordinator.hideLoading()