import React, { useContext } from 'react';
import { SidebarNextContext } from '../SidebarNext/SidebarNextContext';
import { ContextMenu } from './components/ContextMenu';
import { AccordionMenu } from './components/AccordionMenu';
const SidebarSubMenuNext = props => {
    const context = useContext(SidebarNextContext);
    if (context?.parent === 'inContextMenu') {
        return React.createElement(ContextMenu, { ...props });
    }
    return React.createElement(AccordionMenu, { ...props });
};
SidebarSubMenuNext.displayName = 'SidebarSubMenuNext';
export default SidebarSubMenuNext;
//# sourceMappingURL=SidebarSubMenuNext.js.map