import React, { useState } from 'react'; import { Link } from 'react-router-dom'; import { useIsMobile } from '@/hooks/use-mobile'; import { ModernSidebar, SidebarBody, SidebarLink } from '@/components/ui/modern-sidebar'; import OnboardingTour from '@/components/onboarding/OnboardingTour'; import HelpIcon from '@/components/help/HelpIcon'; import { useOnboardingTour } from '@/hooks/useOnboardingTour'; import { Home, Receipt, CreditCard, ListFilter, Target, Calendar, Crown, MessageSquareText, Users, Settings } from 'lucide-react'; import { motion } from 'framer-motion'; interface ModernLayoutProps { children: React.ReactNode; } const Logo = () => { return ( Finance Home Logo Finance Home ); }; const LogoIcon = () => { return ( Finance Home Logo ); }; export default function ModernLayout({ children }: ModernLayoutProps) { const [open, setOpen] = useState(false); const isMobile = useIsMobile(); const { isOpen: tourOpen, currentStep, nextStep, skipTour, closeTour } = useOnboardingTour(); const links = [ { label: "Dashboard", href: "/", icon: , }, { label: "Transações", href: "/transacoes", icon: , }, { label: "Cartões de Crédito", href: "/cartoes", icon: , }, { label: "Categorias", href: "/categorias", icon: , }, { label: "Metas", href: "/metas", icon: , }, { label: "Calendário", href: "/calendario", icon: , }, { label: "Assinatura", href: "/assinatura", icon: , } ]; const whatsappLinks = [ { label: "Conectar WhatsApp", href: "/whatsapp", icon: , }, { label: "Grupos", href: "/grupos-whatsapp", icon: , } ]; const configLinks = [ { label: "Configurações", href: "/configuracoes", icon: , } ]; return (
{open ? : }
{links.map((link, idx) => ( ))}
{open && ( WhatsApp )}
{whatsappLinks.map((link, idx) => ( ))}
{open && ( Configurações )}
{configLinks.map((link, idx) => ( ))}
{/* Main content */}
{children}
{/* Help Icon */} {/* Tour de Onboarding */}
); }