{/* Scrollable container */}
{/* Simplified header for agents marketplace - only show nav controls when needed */} {!isSmallScreen && (
{!navVisible ? ( <> } /> ) : ( // Invisible placeholder to maintain height
)}
)} {/* Hero Section - scrolls away */} {!isSmallScreen && (

{localize('com_agents_marketplace')}

{localize('com_agents_marketplace_subtitle')}

)} {/* Sticky wrapper for search bar and categories */}
{/* Search bar */}
{/* TODO: Remove this once we have a better way to handle admin settings */} {/* Admin Settings */}
{/* Category tabs */}
{/* Scrollable content area */}
{/* Two-pane animated container wrapping category header + grid */}
{/* Current content pane */}
{/* Category header - only show when not searching */} {!searchQuery && (
{(() => { // Get category data for display const getCategoryData = () => { if (displayCategory === 'promoted') { return { name: localize('com_agents_top_picks'), description: localize('com_agents_recommended'), }; } if (displayCategory === 'all') { return { name: localize('com_agents_all'), description: localize('com_agents_all_description'), }; } // Find the category in the API data const categoryData = categoriesQuery.data?.find( (cat) => cat.value === displayCategory, ); if (categoryData) { return { name: categoryData.label?.startsWith('com_') ? localize(categoryData.label as TranslationKeys) : categoryData.label, description: categoryData.description?.startsWith('com_') ? localize(categoryData.description as TranslationKeys) : categoryData.description || '', }; } // Fallback for unknown categories return { name: displayCategory.charAt(0).toUpperCase() + displayCategory.slice(1), description: '', }; }; const { name, description } = getCategoryData(); return (

{name}

{description && (

{description}

)}
); })()}
)} {/* Agent grid */}
{/* Next content pane, only during transition */} {isTransitioning && nextCategory && (
{/* Category header - only show when not searching */} {!searchQuery && (
{(() => { // Get category data for display const getCategoryData = () => { if (nextCategory === 'promoted') { return { name: localize('com_agents_top_picks'), description: localize('com_agents_recommended'), }; } if (nextCategory === 'all') { return { name: localize('com_agents_all'), description: localize('com_agents_all_description'), }; } // Find the category in the API data const categoryData = categoriesQuery.data?.find( (cat) => cat.value === nextCategory, ); if (categoryData) { return { name: categoryData.label?.startsWith('com_') ? localize(categoryData.label as TranslationKeys) : categoryData.label, description: categoryData.description?.startsWith('com_') ? localize( categoryData.description as Parameters[0], ) : categoryData.description || '', }; } // Fallback for unknown categories return { name: (nextCategory || '').charAt(0).toUpperCase() + (nextCategory || '').slice(1), description: '', }; }; const { name, description } = getCategoryData(); return (

{name}

{description && (

{description}

)}
); })()}
)} {/* Agent grid */}
)} {/* Note: Using Tailwind keyframes for slide in/out animations */}