From 9d63f6a0d0bf2ba1a64aa38ee9521e944547d0fb Mon Sep 17 00:00:00 2001 From: Gabor Juhasz Date: Thu, 28 Jul 2022 10:39:41 +0200 Subject: [PATCH] add more details --- components/Box.tsx | 21 ++++++++++++++++++++- components/Detail.tsx | 21 ++++++++++++++++++++- types.ts | 1 + 3 files changed, 41 insertions(+), 2 deletions(-) diff --git a/components/Box.tsx b/components/Box.tsx index c6805d8..3bfd3f8 100644 --- a/components/Box.tsx +++ b/components/Box.tsx @@ -74,6 +74,17 @@ export const Box: FC = ({ item, startOfDay, favorites, setDetailId }) ); })} + + {item.title} @@ -86,7 +97,15 @@ export const Box: FC = ({ item, startOfDay, favorites, setDetailId }) justifyContent: "space-between", }} > -

{dayjs(item.date).locale("hu").format("HH:mm")}

+

+ {dayjs(item.date).locale("hu").format("HH:mm")} + - + + {dayjs(item.date + item.duration * 60 * 1000) + .locale("hu") + .format("HH:mm")} + +

{item.duration} perc

diff --git a/components/Detail.tsx b/components/Detail.tsx index c02278e..1d0252e 100644 --- a/components/Detail.tsx +++ b/components/Detail.tsx @@ -27,7 +27,15 @@ export const Detail: FC = ({ item, favorites, setFavoriteState }) = justifyContent: "space-between", }} > -

{dayjs(item.date).locale("hu").format("HH:mm")}

+

+ {dayjs(item.date).locale("hu").format("HH:mm")} + - + + {dayjs(item.date + item.duration * 60 * 1000) + .locale("hu") + .format("HH:mm")} + +

{item.duration} perc

@@ -44,6 +52,17 @@ export const Detail: FC = ({ item, favorites, setFavoriteState }) = })} + {item.title} +

diff --git a/types.ts b/types.ts index ee4d8f9..ea047f5 100644 --- a/types.ts +++ b/types.ts @@ -9,6 +9,7 @@ export interface Item { village: undefined | { name: Village }; stage: undefined | { name: Stage }; labels: undefined | { name: Topic }[]; + thumbnail: { mobile: string }; // extra id: ID; date: number;