From 74d3cabcc3eb5f483580cd672d174435f8570603 Mon Sep 17 00:00:00 2001 From: Altay Date: Sat, 16 Dec 2023 14:34:47 +0300 Subject: [PATCH] refactor: remove `description` prop from `show-card` --- app/shows/page.tsx | 8 ++------ components/show-card.stories.tsx | 2 -- components/show-card.tsx | 2 +- 3 files changed, 3 insertions(+), 9 deletions(-) diff --git a/app/shows/page.tsx b/app/shows/page.tsx index d925d55..702bb3d 100644 --- a/app/shows/page.tsx +++ b/app/shows/page.tsx @@ -9,9 +9,7 @@ import { cookies } from 'next/headers'; const fetchAllShows = async () => { const supabase = createSupabaseServerClient(cookies()); - const response = await supabase - .from('show') - .select('id, title, description, images'); + const response = await supabase.from('show').select('id, title, images'); return response; }; @@ -21,7 +19,7 @@ const fetchMyShows = async () => { const accountId = await getAccountId(); const response = await supabase .from('account_show_relation') - .select('show (id, title, description, images)') + .select('show (id, title, images)') .eq('account', accountId) .not('show', 'is', null); @@ -71,7 +69,6 @@ export default async function Page() { > {myShows.map(({ show }) => ( {showsData?.map((show) => ( = { render: () => ( = { return ( , 'description' | 'images' | 'title'>; +type Props = Pick, 'images' | 'title'>; function ShowCardImage(props: Pick) { return (