Merge pull request #365 from RyanRory/fix-modal-on-cancel

Fix customised on cancel won't dismiss the modal
pull/1061/head
Morgan Pretty 3 months ago committed by GitHub
commit 119d7e21da
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -1263,9 +1263,11 @@ extension ConversationVC:
UIApplication.shared.open(url, options: [:], completionHandler: nil)
self?.showInputAccessoryView()
},
onCancel: { [weak self] _ in
onCancel: { [weak self] modal in
UIPasteboard.general.string = url.absoluteString
self?.showInputAccessoryView()
modal.dismiss(animated: true) {
self?.showInputAccessoryView()
}
}
)
)

@ -159,10 +159,11 @@ struct LandingScreen: View {
UIApplication.shared.open(url)
}
},
onCancel: { _ in
onCancel: { modal in
if let url: URL = URL(string: "https://getsession.org/privacy-policy") {
UIApplication.shared.open(url)
}
modal.close()
}
)
)

Loading…
Cancel
Save