import { Tab } from '@fluid-design/fluid-ui'; import { PhotoIcon } from '@heroicons/react/24/outline'; import { useEffect, useState } from 'react'; import clsxm from '@/lib/clsxm'; import { CodeFrameComponentWrap } from '../framework/CodeFrameComponentWrap'; const Content = ({ title }) => { return ( <>

{title}

); }; const tabs = ['Recent', 'Trending', 'For You'].map((title) => ({ title, content: , })); const tabClassName = 'flex h-full items-center justify-center px-4 lg:px-6 w-4/5 max-w-lg'; const DefaultTab = ({ className = '' }) => { return ( ); }; const AsComponent = ({ className = '' }) => { return ( Tab 1 Tab 2 Tab 3 ); }; const ProgrammaticTab = ({ className = '' }) => { const [activeTabIndex, setActiveTabIndex] = useState(0); useEffect(() => { const interval = setInterval(() => { setActiveTabIndex((prev) => { if (prev === 2) { return 0; } return prev + 1; }); }, 3800); return () => clearInterval(interval); }, []); return ( ); }; DefaultTab.displayName = 'DefaultTab'; AsComponent.displayName = 'AsComponent'; ProgrammaticTab.displayName = 'ProgrammaticTab'; export const TabExamples = Object.assign( {}, { Default: DefaultTab, AsComponent, Programmatic: ProgrammaticTab } );