How to get UISheetPresentationController width to adjust for vertical toolbar on iPhone Duo?

If you run Safari in the iPhone Duo simulator and choose to share something you get a screen similar to the following:

In my own app, if I present a UIActivityViewController I get a similar result. Note that the share sheet does not cover the vertical toolbar at all.

So my question is how to present a UISheetPresentationController to look the same way. In other words, how to get the width of the UISheetPresentationController to take into account the vertical toolbar?

All of my existing code to create and present a UISheetPresentationController result in the UISheetPresentationController taking the full width of the screen. The contents of the sheet take the safe area into account, but that's not the same result. I need the sheet itself to be narrower.

I don't see an API for this. Or does this require more complicated presentation controller / delegate setup?

Here is some relevant code in the view controller that I want displayed in the sheet:

        self.modalPresentationStyle = .popover
        self.presentationController?.delegate = self
        if let sheet = popoverPresentationController?.adaptiveSheetPresentationController {
            popoverPresentationController?.passthroughViews = []
            sheet.detents = [ .medium(), .large() ]
            sheet.largestUndimmedDetentIdentifier = nil
            sheet.prefersGrabberVisible = false
            sheet.prefersScrollingExpandsWhenScrolledToEdge = true
            sheet.prefersEdgeAttachedInCompactHeight = true
            sheet.widthFollowsPreferredContentSizeWhenEdgeAttached = true
        }

Or maybe UISheetPresentationController is the wrong approach.

How to get UISheetPresentationController width to adjust for vertical toolbar on iPhone Duo?
 
 
Q