"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
    return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.Page = void 0;
const react_1 = __importDefault(require("react"));
const Header_1 = require("../header/Header");
const LandingExpandedHeader_1 = require("../header/LandingExpandedHeader");
const Input_1 = require("../input/Input");
const Footer_1 = require("../footer/Footer");
require("./page.scss");
const Page = ({ children, headerArgs, className }) => {
    const [isOpenSupport, setSupportIsOpen] = react_1.default.useState(false);
    const toggleLogin = () => alert('this is a context');
    const toggleSupport = () => setSupportIsOpen(prevIsOpen => !prevIsOpen);
    return (react_1.default.createElement(react_1.default.Fragment, null,
        react_1.default.createElement("article", { className: className },
            react_1.default.createElement(Header_1.Header, { isOpenSupport: isOpenSupport, toggleLoginModal: toggleLogin, signOutAndRedirect: () => console.log('signed out'), toggleSupport: toggleSupport, profile: headerArgs.user, expanded: headerArgs.expanded, navigateToNewSearch: () => console.log('go to /search'), renderUploader: () => react_1.default.createElement("li", null, "Upload"), renderOnFreshDeskWidget: () => react_1.default.createElement(react_1.default.Fragment, null, "This is a freshdesk widget"), renderOnExpanded: profile => (react_1.default.createElement(LandingExpandedHeader_1.LandingExpandedHeader, { user: profile, renderFacetSelect: () => react_1.default.createElement(react_1.default.Fragment, null, "front facet example"), renderSearchInput: () => (react_1.default.createElement(Input_1.Input, { placeholder: "Search", type: "text", name: "front-page-search", labelStyle: "default", label: "search", value: "", setValue: value => { } })), onSearch: () => console.log('User search by keyword.') })) }),
            children,
            react_1.default.createElement("div", { className: "on-foot" },
                react_1.default.createElement(Footer_1.Footer, { version: "x.x.x" })))));
};
exports.Page = Page;
