'use strict';Object.defineProperty(exports,"__esModule",{value:!0});var React=require("react"),PropTypes=require("prop-types"),history=require("history"),reactRouterDom=require("react-router-dom");
function StaticRouter({children:c,location:b="/"}){"string"===typeof b&&(b=history.parsePath(b));return React.createElement(reactRouterDom.Router,{children:c,action:history.Action.Pop,location:{pathname:b.pathname||"/",search:b.search||"",hash:b.hash||"",state:b.state||null,key:b.key||"default"},navigator:{createHref(a){return"string"===typeof a?a:history.createPath(a)},push(a){throw Error("You cannot use navigator.push() on the server because it is a stateless environment. This error was probably triggered when you did a "+
`\`navigate(${JSON.stringify(a)})\` somewhere in your app.`);},replace(a){throw Error("You cannot use navigator.replace() on the server because it is a stateless environment. This error was probably triggered when you did a "+`\`navigate(${JSON.stringify(a)}, { replace: true })\` somewhere `+"in your app.");},go(a){throw Error("You cannot use navigator.go() on the server because it is a stateless environment. This error was probably triggered when you did a "+`\`navigate(${a})\` somewhere in your app.`);
},back(){throw Error("You cannot use navigator.back() on the server because it is a stateless environment.");},forward(){throw Error("You cannot use navigator.forward() on the server because it is a stateless environment.");},block(){throw Error("You cannot use navigator.block() on the server because it is a stateless environment.");}},static:!0})}
"production"!==process.env.NODE_ENV&&(StaticRouter.displayName="StaticRouter",StaticRouter.propTypes={children:PropTypes.node,location:PropTypes.oneOfType([PropTypes.string,PropTypes.shape({pathname:PropTypes.string,search:PropTypes.string,hash:PropTypes.string,state:PropTypes.object,key:PropTypes.string})])});exports.StaticRouter=StaticRouter;
