1

目前,我正在使用以下代码PKAddPaymentPassViewController在我的应用程序中展示react-native

let delegate = PKAddPaymentPassDelegate();
let pkAddPaymentPassViewController = PKAddPaymentPassViewController.init(requestConfiguration: pkAddPaymentPassRequestConfiguration!, delegate:delegate );
DispatchQueue.main.async {
  RCTPresentedViewController()?.present(pkAddPaymentPassViewController!, animated: true, completion: nil);
}

问题是,当我cancel点击左上角的按钮时,视图并没有消失。

有没有人遇到过这个问题?任何帮助,将不胜感激

4

1 回答 1

0

也许您present(vc, animated: )曾经以模态方式显示此内容,但尝试使用popViewController(animated: )而不是dismiss(animated: , completion: )

于 2022-02-10T08:18:21.850 回答