// Shell — Sidebar + TopNav function Sidebar({ active, onChange }) { // Sidebar items map to screens (icon-only). Order: home, journeys, contacts, opps, cal, reports, cases const items = [ { id: "painel", icon: ICN.home, label: "Painel" }, { id: "pipeline", icon: ICN.trendUp, label: "Pipeline" }, { id: "jornadas", icon: ICN.share, label: "Jornadas" }, { id: "contatos", icon: ICN.users, label: "Contatos" }, { id: "oportunidades", icon: ICN.briefcase, label: "Oportunidades" }, { id: "calendario", icon: ICN.cal, label: "Calendário" }, { id: "relatorios", icon: ICN.chart, label: "Relatórios" }, { id: "casos", icon: ICN.bolt, label: "Casos" }, { id: "conversas", icon: ICN.whatsapp, label: "Conversas" }, ]; return ( ); } function TopNav({ active, onChange, onOpenSearch, onOpenMessages, onOpenNotifs, onOpenProfile }) { return ( ); } function PageHead({ title, subtitle, back, onBack, right }) { return (
{back &&
{ICN.arrowLeft}
}

{title}

{subtitle &&
{subtitle}
}
{right}
); } function CardActions({ children, count, createLabel = 'Novo item', onCreate, onPeriod, moreItems }) { // Se children for passado, mostra eles (compat com uso antigo). // Caso contrário, usa CardActionsBar com ações reais. if (children) { return
{children}
; } return ; } function AvatarStack({ ids, max = 6, more }) { const shown = ids.slice(0, max); const extra = more ?? Math.max(0, ids.length - max); return (
{shown.map((id, i) => ( ))} {extra > 0 &&
+{extra}
}
); } Object.assign(window, { Sidebar, TopNav, PageHead, CardActions, AvatarStack });