import React from 'react'; import { useOrg } from '../../contexts/OrgContext'; interface NavItemProps { icon: React.ReactNode; label: string; isActive?: boolean; onClick?: () => void; } const NavItem: React.FC = ({ icon, label, isActive, onClick }) => (
{icon}
{label}
); interface ChatSidebarProps { currentPage?: string; onNavigate?: (page: string) => void; } const ChatSidebar: React.FC = ({ currentPage = 'chat', onNavigate }) => { const { org } = useOrg(); const handleNavigation = (page: string) => { if (onNavigate) { onNavigate(page); } }; return (
{/* Company Selection */}
{/* Company Icon SVG */}
{org?.name || 'Zitlac Media'}
{/* Navigation Menu */}
} label="Company Wiki" isActive={currentPage === 'wiki'} onClick={() => handleNavigation('wiki')} /> } label="Submissions" isActive={currentPage === 'submissions'} onClick={() => handleNavigation('submissions')} /> } label="Reports" isActive={currentPage === 'reports'} onClick={() => handleNavigation('reports')} /> } label="Chat" isActive={currentPage === 'chat'} onClick={() => handleNavigation('chat')} /> } label="Help" isActive={currentPage === 'help'} onClick={() => handleNavigation('help')} />
{/* Bottom Section with Settings and Company Report Builder */}
} label="Settings" isActive={currentPage === 'settings'} onClick={() => handleNavigation('settings')} /> {/* Company Report Builder Card */}
Build {org?.name || '[Company]'}'s Report
Share this form with your team members to capture valuable info about your company to train Auditly.
Invite
Copy
); }; export default ChatSidebar;