UIViewControllerPresenting

此包提供了一个自定义的 SwiftUI 视图修饰符和组件,可用于使用 UIKit presentation API 从 SwiftUI 视图中呈现 UIKit 视图。它还可以通过将其他 SwiftUI 视图包装在 UIHostingController 中来呈现它们,让您可以访问 iOS 16 之前 SwiftUI 中不可用的 presentation API,例如 sheet detents。

SafariWebView

此包还包含一个构建在 UIViewControllerPresenting 之上的独立库,它允许您使用基于绑定的接口从 SwiftUI 视图中呈现 Safari web view controller。

示例

有关如何使用此库的更多示例,请参阅 Examples 目录。

文档

版权和许可

此库是在 Community.com 上的应用程序开发过程中开发的,并根据 Apache 2.0 许可证 提供。

Copyright 2022 Community.com, Inc.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    https://apache.ac.cn/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.