Rework artwork list
This commit is contained in:
@ -1,8 +1,5 @@
|
||||
import ArtworkGallery from "@/components/artworks/ArtworkGallery";
|
||||
import FilterBar from "@/components/artworks/FilterBar";
|
||||
import { ArtworksTable } from "@/components/artworks/ArtworksTable";
|
||||
import { getArtworksPage } from "@/lib/queryArtworks";
|
||||
import { PlusCircleIcon } from "lucide-react";
|
||||
import Link from "next/link";
|
||||
|
||||
export default async function ArtworksPage({
|
||||
searchParams
|
||||
@ -57,32 +54,36 @@ export default async function ArtworksPage({
|
||||
)
|
||||
|
||||
return (
|
||||
<div>
|
||||
<div className="flex justify-between pb-4 items-end">
|
||||
<h1 className="text-2xl font-bold mb-4">Artworks</h1>
|
||||
<Link href="/uploads/single" className="flex gap-2 items-center cursor-pointer bg-primary hover:bg-primary/90 text-primary-foreground px-4 py-2 rounded">
|
||||
<PlusCircleIcon className="h-[1.2rem] w-[1.2rem] scale-100 rotate-0 transition-all text-primary-foreground" /> Upload new artwork
|
||||
</Link>
|
||||
<Link href="/uploads/bulk" className="flex gap-2 items-center cursor-pointer bg-primary hover:bg-primary/90 text-primary-foreground px-4 py-2 rounded">
|
||||
<PlusCircleIcon className="h-[1.2rem] w-[1.2rem] scale-100 rotate-0 transition-all text-primary-foreground" /> Upload many artwork
|
||||
</Link>
|
||||
</div>
|
||||
<FilterBar
|
||||
// types={types}
|
||||
// albums={albums}
|
||||
// years={years}
|
||||
// currentType={type}
|
||||
currentPublished={published}
|
||||
// groupBy={groupMode}
|
||||
// groupId={groupId}
|
||||
/>
|
||||
<div className="mt-6">
|
||||
{items.length > 0 ? (
|
||||
<ArtworkGallery initialArtworks={items} initialCursor={nextCursor} />
|
||||
) : (
|
||||
<p className="text-muted-foreground italic">No artworks found.</p>
|
||||
)}
|
||||
</div>
|
||||
</div >
|
||||
<div className="space-y-6">
|
||||
<h1 className="text-2xl font-bold">Artworks</h1>
|
||||
<ArtworksTable />
|
||||
</div>
|
||||
// <div>
|
||||
// <div className="flex justify-between pb-4 items-end">
|
||||
// <h1 className="text-2xl font-bold mb-4">Artworks</h1>
|
||||
// <Link href="/uploads/single" className="flex gap-2 items-center cursor-pointer bg-primary hover:bg-primary/90 text-primary-foreground px-4 py-2 rounded">
|
||||
// <PlusCircleIcon className="h-[1.2rem] w-[1.2rem] scale-100 rotate-0 transition-all text-primary-foreground" /> Upload new artwork
|
||||
// </Link>
|
||||
// <Link href="/uploads/bulk" className="flex gap-2 items-center cursor-pointer bg-primary hover:bg-primary/90 text-primary-foreground px-4 py-2 rounded">
|
||||
// <PlusCircleIcon className="h-[1.2rem] w-[1.2rem] scale-100 rotate-0 transition-all text-primary-foreground" /> Upload many artwork
|
||||
// </Link>
|
||||
// </div>
|
||||
// <FilterBar
|
||||
// // types={types}
|
||||
// // albums={albums}
|
||||
// // years={years}
|
||||
// // currentType={type}
|
||||
// currentPublished={published}
|
||||
// // groupBy={groupMode}
|
||||
// // groupId={groupId}
|
||||
// />
|
||||
// <div className="mt-6">
|
||||
// {items.length > 0 ? (
|
||||
// <ArtworkGallery initialArtworks={items} initialCursor={nextCursor} />
|
||||
// ) : (
|
||||
// <p className="text-muted-foreground italic">No artworks found.</p>
|
||||
// )}
|
||||
// </div>
|
||||
// </div >
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user