"use strict";
Object.defineProperty(exports, "__esModule", {
    value: true
});
Object.defineProperty(exports, "Portal", {
    enumerable: true,
    get: function() {
        return Portal;
    }
});
var _react = /*#__PURE__*/ _interop_require_default(require("react"));
var _reactdom = /*#__PURE__*/ _interop_require_default(require("react-dom"));
function _interop_require_default(obj) {
    return obj && obj.__esModule ? obj : {
        default: obj
    };
}
var Portal = function Portal(param) {
    var children = param.children, container = param.container, _param_disabled = param.disabled, disabled = _param_disabled === void 0 ? false : _param_disabled;
    var portalContainer = typeof container === 'function' ? container() : container;
    return /*#__PURE__*/ _react.default.createElement(_react.default.Fragment, null, disabled || !portalContainer ? children : /*#__PURE__*/ _reactdom.default.createPortal(children, portalContainer));
};
