ios – Seeking Assistance with Implementing a Compact Drawer UI in SwiftUI


I apologize if my question lacks clarity or sufficient details. I’m attempting to replicate a specific user interface as shown in the attached pictures, where a small drawer emerges from the bottom. We’ve successfully implemented this in UIKit, but are encountering challenges in SwiftUI. Our current approach involves using .sheet with medium and large detents, but we haven’t found a way to create a smaller detent like the one in our design.

We also explored using UIViewControllerRepresentable to integrate the UIKit view into SwiftUI, but this approach has not been successful. Specifically, we’re facing an issue with a view named “Presentation Hosting Controller” that consistently displays a white screen. The only workaround we’ve found is to use FullScreenModalView, which doesn’t align with our design goals.

Could someone provide guidance on the best way to achieve this small drawer effect in SwiftUI? Your expertise and suggestions would be greatly appreciated.

This the Drawer I’m talking about that has been done in UIKit

Latest articles

spot_imgspot_img

Related articles

Leave a reply

Please enter your comment!
Please enter your name here

spot_imgspot_img