fix: fix Artwork object in demo

This commit is contained in:
Ole Marius Løset 2023-11-19 21:19:56 +01:00
parent c7561acdd2
commit 9fe7eb58c5
2 changed files with 10 additions and 2 deletions

View File

@ -2,20 +2,24 @@
import { ScrollArea, ScrollBar } from '@/lib/registry/default/ui/scroll-area' import { ScrollArea, ScrollBar } from '@/lib/registry/default/ui/scroll-area'
interface Artwork { interface Artwork {
id: string
artist: string artist: string
art: string art: string
} }
const works: Artwork[] = [ const works: Artwork[] = [
{ {
id: '1',
artist: 'Ornella Binni', artist: 'Ornella Binni',
art: 'https://images.unsplash.com/photo-1465869185982-5a1a7522cbcb?auto=format&fit=crop&w=300&q=80', art: 'https://images.unsplash.com/photo-1465869185982-5a1a7522cbcb?auto=format&fit=crop&w=300&q=80',
}, },
{ {
id: '2',
artist: 'Tom Byrom', artist: 'Tom Byrom',
art: 'https://images.unsplash.com/photo-1548516173-3cabfa4607e9?auto=format&fit=crop&w=300&q=80', art: 'https://images.unsplash.com/photo-1548516173-3cabfa4607e9?auto=format&fit=crop&w=300&q=80',
}, },
{ {
id: '3',
artist: 'Vladimir Malyavko', artist: 'Vladimir Malyavko',
art: 'https://images.unsplash.com/photo-1494337480532-3725c85fd2ab?auto=format&fit=crop&w=300&q=80', art: 'https://images.unsplash.com/photo-1494337480532-3725c85fd2ab?auto=format&fit=crop&w=300&q=80',
}, },
@ -30,7 +34,7 @@ const works: Artwork[] = [
<div class="overflow-hidden rounded-md"> <div class="overflow-hidden rounded-md">
<img <img
:src="artwork.art" :src="artwork.art"
:alt="`Photo by ${artwork.name}`" :alt="`Photo by ${artwork.artist}`"
class="aspect-[3/4] w-36 h-56 object-cover" class="aspect-[3/4] w-36 h-56 object-cover"
> >
</div> </div>

View File

@ -2,20 +2,24 @@
import { ScrollArea, ScrollBar } from '@/lib/registry/new-york/ui/scroll-area' import { ScrollArea, ScrollBar } from '@/lib/registry/new-york/ui/scroll-area'
interface Artwork { interface Artwork {
id: string
artist: string artist: string
art: string art: string
} }
const works: Artwork[] = [ const works: Artwork[] = [
{ {
id: '1',
artist: 'Ornella Binni', artist: 'Ornella Binni',
art: 'https://images.unsplash.com/photo-1465869185982-5a1a7522cbcb?auto=format&fit=crop&w=300&q=80', art: 'https://images.unsplash.com/photo-1465869185982-5a1a7522cbcb?auto=format&fit=crop&w=300&q=80',
}, },
{ {
id: '2',
artist: 'Tom Byrom', artist: 'Tom Byrom',
art: 'https://images.unsplash.com/photo-1548516173-3cabfa4607e9?auto=format&fit=crop&w=300&q=80', art: 'https://images.unsplash.com/photo-1548516173-3cabfa4607e9?auto=format&fit=crop&w=300&q=80',
}, },
{ {
id: '3',
artist: 'Vladimir Malyavko', artist: 'Vladimir Malyavko',
art: 'https://images.unsplash.com/photo-1494337480532-3725c85fd2ab?auto=format&fit=crop&w=300&q=80', art: 'https://images.unsplash.com/photo-1494337480532-3725c85fd2ab?auto=format&fit=crop&w=300&q=80',
}, },
@ -30,7 +34,7 @@ const works: Artwork[] = [
<div class="overflow-hidden rounded-md"> <div class="overflow-hidden rounded-md">
<img <img
:src="artwork.art" :src="artwork.art"
:alt="`Photo by ${artwork.name}`" :alt="`Photo by ${artwork.artist}`"
class="aspect-[3/4] w-36 h-56 object-cover" class="aspect-[3/4] w-36 h-56 object-cover"
> >
</div> </div>