import { ScriptCard, Script } from './ScriptCard';
import { Skeleton } from '@/components/ui/skeleton';
interface ScriptGridProps {
scripts: Script[];
isLoading: boolean;
}
export function ScriptGrid({ scripts, isLoading }: ScriptGridProps) {
if (isLoading) {
return (
{Array.from({ length: 8 }).map((_, index) => (
))}
);
}
if (scripts.length === 0) {
return (
No scripts found matching your criteria.
Try adjusting your filters or search terms.
);
}
return (
{scripts.map((script) => (
))}
);
}
function ScriptCardSkeleton() {
return (
);
}