Nelze vybrat více než 25 témat Téma musí začínat písmenem nebo číslem, může obsahovat pomlčky („-“) a může být dlouhé až 35 znaků.

Header.tsx 1.2KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. 'use client'
  2. import { useState } from 'react'
  3. import { MenuOutlined } from '@ant-design/icons'
  4. import { FontAwesomeIcon } from '@fortawesome/react-fontawesome'
  5. import { faBars, faBell } from '@fortawesome/free-solid-svg-icons'
  6. import { Button, Space } from 'antd'
  7. import Sidebar from '@/components/layout/Sidebar'
  8. import BellNotification from '@/components/ui/BellNotification'
  9. const Header = () => {
  10. const [showSideBar, setShowSideBar] = useState(false)
  11. return (
  12. <header className="flex items-center px-4 py-2 relative z-40 bg-white shadow-sm">
  13. {/* Sidebar Trigger */}
  14. <Button
  15. type="text"
  16. icon={<FontAwesomeIcon icon={faBars} />}
  17. onClick={() => setShowSideBar(true)}
  18. className="text-lg text-gray-700"
  19. />
  20. {/* Sidebar Component */}
  21. <Sidebar open={showSideBar} setOpen={setShowSideBar} />
  22. {/* Logo + Brand */}
  23. <div className="flex items-center ms-3">
  24. <img src="/ruccan_logo.png" alt="Ruccan Logo" className="h-6 w-auto" />
  25. <span className="text-black font-bold text-lg ms-3">Ruccan.com</span>
  26. </div>
  27. {/* Notification Bell */}
  28. <div className="ms-auto">
  29. <BellNotification />
  30. </div>
  31. </header>
  32. )
  33. }
  34. export default Header