"use strict";
var __assign = (this && this.__assign) || function () {
    __assign = Object.assign || function(t) {
        for (var s, i = 1, n = arguments.length; i < n; i++) {
            s = arguments[i];
            for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
                t[p] = s[p];
        }
        return t;
    };
    return __assign.apply(this, arguments);
};
Object.defineProperty(exports, "__esModule", { value: true });
var jsx_runtime_1 = require("react/jsx-runtime");
/*
 *  This file is part of CoCalc: Copyright © 2021 Sagemath, Inc.
 *  License: AGPLv3 s.t. "Commons Clause" – see LICENSE.md for details
 */
var antd_1 = require("antd");
var Content = antd_1.Layout.Content;
var STYLE = {
    background: "white",
    minHeight: "75vh",
    maxWidth: "992px",
    width: "100%",
    margin: "0 auto",
    padding: "0 20px",
};
function Main(props) {
    var nav = props.nav, children = props.children;
    var style = __assign(__assign({}, STYLE), props.style);
    function renderNav() {
        if (nav == null)
            return null;
        return ((0, jsx_runtime_1.jsx)(antd_1.Breadcrumb, __assign({ style: { margin: "50px 0 25px 0" } }, { children: nav.map(function (entry, idx) { return ((0, jsx_runtime_1.jsx)(antd_1.Breadcrumb.Item, { children: entry }, idx)); }) })));
    }
    return ((0, jsx_runtime_1.jsxs)(Content, __assign({ style: style }, { children: [renderNav(), children] })));
}
exports.default = Main;
//# sourceMappingURL=main.js.map