I have two view controllers, B is presented on top of A, but not full screen. I am using a UIPresentationController to custom B's frame. What I want is, when tap on A, B is dismissed and A responds to it's own tap gesture.
How to achieve this within B and the UIPresentationController, without touching A's code?
I tried to add a full screen background view for B, but don't know how to pass the tap gesture down without changing A.

Customize a background view, always return false for pointInside method to ignore the touch event and do whatever needed before return, such as dismiss B.
Add the custom background view to the UIPresentationController. Set containerView's isUserInteractionEnabled to false, otherwise the UITransitionView will block the touch event to pass down.