@atlaskit/popup
Version:
A popup displays brief content in an overlay.
19 lines (18 loc) • 630 B
JavaScript
;
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.PopupContentRenderer = PopupContentRenderer;
/**
* Calls the consumer's content render prop.
*
* The top-layer adapters render this as a child of `Popover`. `Popover` renders its children only
* while its host is mounted (open, or during the exit animation), so the render prop is not called
* while the popup is closed. The legacy path does the same: it calls the render prop only while
* open.
*/
function PopupContentRenderer(_ref) {
var render = _ref.render,
contentProps = _ref.contentProps;
return render(contentProps);
}