fix(calendar): use full available calendar viewport height on desktop

This commit is contained in:
Ruslan Bakiev
2026-02-23 14:40:59 +07:00
parent db49c4a830
commit f6b738352b
2 changed files with 25 additions and 1 deletions

View File

@@ -52,6 +52,7 @@ defineProps<{
setCalendarContentScrollRef: (element: HTMLDivElement | null) => void;
onCalendarHierarchyWheel: (event: WheelEvent) => void;
setCalendarSceneRef: (element: HTMLDivElement | null) => void;
calendarViewportHeight: number;
normalizedCalendarView: string;
calendarSceneTransformStyle: Record<string, string>;
onCalendarSceneMouseLeave: () => void;
@@ -182,7 +183,12 @@ defineProps<{
calendarHoveredMonthIndex === item.monthIndex ? 'calendar-hover-target' : '',
calendarZoomPrimeToken === calendarPrimeMonthToken(item.monthIndex) ? 'calendar-zoom-prime-active' : '',
]"
:style="calendarPrimeStyle(calendarPrimeMonthToken(item.monthIndex))"
:style="{
...calendarPrimeStyle(calendarPrimeMonthToken(item.monthIndex)),
...(calendarView !== 'year' && item.monthIndex === calendarCursorMonth && calendarViewportHeight > 0
? { minHeight: `${Math.max(420, calendarViewportHeight)}px` }
: {}),
}"
:data-calendar-month-index="item.monthIndex"
@mouseenter="setCalendarHoveredMonthIndex(item.monthIndex)"
@click="calendarView === 'year' ? zoomToMonth(item.monthIndex) : undefined"