"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
    return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.StaticPage = void 0;
const react_1 = __importDefault(require("react"));
const StaticPages_1 = require("./StaticPages");
exports.StaticPage = ({ routeProps, appName, mainPath, staticRoutes, apiConfig }) => {
    const { pathname } = routeProps.location;
    let TargetPage = () => (react_1.default.createElement(StaticPages_1.DefaultPage, { appName: appName, mainPath: mainPath, body: pathname }));
    if (staticRoutes && staticRoutes[pathname]) {
        TargetPage = staticRoutes[pathname];
    }
    return (react_1.default.createElement(TargetPage, Object.assign({ appName: appName, mainPath: mainPath, apiConfig: apiConfig }, routeProps)));
};
//# sourceMappingURL=StaticPage.js.map