import React from "react";
import { SwitcherDivider } from "./components";
import { Help } from "@carbon/react/icons";
import C3NavigationSideBar from "./c3-navigation-sidebar";
import { useC3UserConfiguration } from "../../c3-user-configuration/c3-user-configuration-provider";
const C3InfoSidebar = ({ sideBar, }) => {
    const { version, ...sideBarProps } = sideBar;
    const { enableLogs } = useC3UserConfiguration();
    if (version && enableLogs)
        console.warn("The `version` prop in the info sidebar is deprecated and will be removed in a future release. Please set `version` in the `userSideBar` prop instead.");
    return (React.createElement(C3NavigationSideBar, { sideBar: {
            ...sideBarProps,
            ariaLabel: sideBarProps.ariaLabel || "Info Sidebar",
        }, icon: React.createElement(Help, { size: 20 }), bottomChildren: version !== undefined && (React.createElement(React.Fragment, null,
            React.createElement(SwitcherDivider, null),
            React.createElement("span", { className: "cds--switcher__item", style: {
                    padding: "var(--cds-spacing-05)",
                    paddingTop: "var(--cds-spacing-03)",
                    paddingBottom: 0,
                    color: "var(--cds-text-primary)",
                    fontSize: "var(--cds-body-01-font-size)",
                    fontWeight: "var(--cds-body-01-font-weight)",
                    lineHeight: "var(--cds-body-01-line-height)",
                    letterSpacing: "var(--cds-body-01-letter-spacing)",
                } },
                "Version ",
                version),
            React.createElement("span", { className: "cds--switcher__item", style: {
                    paddingRight: "var(--cds-spacing-05)",
                    paddingLeft: "var(--cds-spacing-05)",
                    color: "var(--cds-text-secondary)",
                    fontSize: "var(--cds-label-01-font-size)",
                    fontWeight: "var(--cds-label-01-font-weight)",
                    lineHeight: "var(--cds-label-01-line-height)",
                    letterSpacing: "var(--cds-label-01-letter-spacing)",
                } },
                `© Camunda Services GmbH ${new Date().getFullYear()}`,
                React.createElement("br", null),
                " All rights reserved."))) }));
};
export default C3InfoSidebar;
