From f88f308bff864cbaacf78b5861037194f8a06e2d Mon Sep 17 00:00:00 2001 From: "Hyunmin Woo (Hanul)" Date: Tue, 12 Sep 2023 11:56:01 +0900 Subject: [PATCH] =?UTF-8?q?=F0=9F=91=BD=20=EC=8B=9C=EA=B0=84=ED=91=9C=20?= =?UTF-8?q?=EC=9E=90=EB=8F=99=EC=A1=B0=EC=A0=95=20=EB=A1=9C=EC=A7=81=20?= =?UTF-8?q?=ED=81=B4=EB=9D=BC=EB=9E=91=20=ED=86=B5=EC=9D=BC=20=EB=B0=8F=20?= =?UTF-8?q?=EC=A2=85=EB=A3=8C=EC=8B=9C=EA=B0=84=20=EB=B2=84=EA=B7=B8=20?= =?UTF-8?q?=EC=88=98=EC=A0=95=20(#88)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/infrastructures/createTimetableViewService.ts | 4 ++-- .../friends-react-native/src/usecases/timetableViewService.ts | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/apps/friends-react-native/src/infrastructures/createTimetableViewService.ts b/apps/friends-react-native/src/infrastructures/createTimetableViewService.ts index b658de9..7ea61af 100644 --- a/apps/friends-react-native/src/infrastructures/createTimetableViewService.ts +++ b/apps/friends-react-native/src/infrastructures/createTimetableViewService.ts @@ -11,8 +11,8 @@ export const createTimetableViewService = (): TimetableViewService => { }, getHourRange: (timetable) => { const times = timetable.lectures.flatMap((l) => l.classPlaceAndTimes); - const start = Math.min(...times.map((t) => Math.floor(t.startMinute / 60)), 8) as Hour; - const end = Math.max(...times.map((t) => Math.ceil(t.endMinute / 60)), 22) as Hour; + const start = Math.min(...times.map((t) => Math.floor(t.startMinute / 60)), 9) as Hour; + const end = Math.max(...times.map((t) => Math.floor(t.endMinute / 60)), 17) as Hour; return [start, end]; }, getDayLabel: (day) => ({ 0: '월', 1: '화', 2: '수', 3: '목', 4: '금', 5: '토', 6: '일' })[day], diff --git a/apps/friends-react-native/src/usecases/timetableViewService.ts b/apps/friends-react-native/src/usecases/timetableViewService.ts index ca6f228..5f6e39c 100644 --- a/apps/friends-react-native/src/usecases/timetableViewService.ts +++ b/apps/friends-react-native/src/usecases/timetableViewService.ts @@ -4,7 +4,7 @@ import { FullTimetable } from '../entities/timetable'; export type TimetableViewService = { getDayRange: (table: Pick) => [Day, Day]; - getHourRange: (table: Pick) => [Hour, Hour]; + getHourRange: (table: Pick) => [Hour, Hour]; // Note: [9, 17] 이면 9:00 ~ 17:59 를 의미한다 getDayLabel: (day: Day) => string; getLessonColor: (lesson: FullTimetable['lectures'][number], palette: Color[]) => { bg: string; fg: string }; };