import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
import { Box } from '../box';
import { omitThemingProps, useStyleConfig } from '../core';
import { cs } from '../utils';
import { collapsedWidth } from './consts';
/** Top container. */
export const SidemenuTop = (props) => {
    const { className, leftSlot, rightSlot, ...rest } = omitThemingProps(props);
    const styles = useStyleConfig('Sidemenu', props);
    if (!leftSlot && !rightSlot)
        return null;
    return (_jsxs(Box, { className: cs('vui-sidemenu-top', className), mb: 1, w: "100%", ...styles.sidemenuTop, ...rest, children: [!!leftSlot && (_jsx(Box, { alignItems: "center", className: "vui-sidemenu-top-left", minW: collapsedWidth, children: leftSlot })), !!rightSlot && _jsx(Box, { className: "vui-sidemenu-top-left", children: rightSlot })] }));
};
SidemenuTop.displayName = 'SidemenuTop';
export default SidemenuTop;
//# sourceMappingURL=sidemenuTop.js.map