diff --git a/apps/calendar/apps/web/src/lib/components/calendar/CalendarToolbar.svelte b/apps/calendar/apps/web/src/lib/components/calendar/CalendarToolbar.svelte index 9c255b5b4..607f9d473 100644 --- a/apps/calendar/apps/web/src/lib/components/calendar/CalendarToolbar.svelte +++ b/apps/calendar/apps/web/src/lib/components/calendar/CalendarToolbar.svelte @@ -1,131 +1,189 @@ - - - +{#if !isCollapsed} + + - + - - viewStore.goToToday()} title="Zum heutigen Tag springen"> - Heute - + +
+ +
+ +
+
+{/if} - - - - viewStore.goToPrevious()} title="Zurück" iconOnly> - - - - - viewStore.goToNext()} title="Weiter" iconOnly> - - - - - - - - - settingsStore.set('showOnlyWeekdays', !settingsStore.showOnlyWeekdays)} - active={settingsStore.showOnlyWeekdays} - title="Nur Wochentage anzeigen (Mo-Fr)" + +{#if isCollapsed} + +{/if} - - + diff --git a/apps/calendar/apps/web/src/lib/components/calendar/DateStrip.svelte b/apps/calendar/apps/web/src/lib/components/calendar/DateStrip.svelte index a4abe650a..86e875875 100644 --- a/apps/calendar/apps/web/src/lib/components/calendar/DateStrip.svelte +++ b/apps/calendar/apps/web/src/lib/components/calendar/DateStrip.svelte @@ -14,6 +14,12 @@ import { onMount, tick } from 'svelte'; import SunCalc from 'suncalc'; + interface Props { + isSidebarMode?: boolean; + } + + let { isSidebarMode = false }: Props = $props(); + // Get event count for a day (max 5 dots displayed) function getEventCount(date: Date): number { const events = eventsStore.getEventsForDay(date, false); @@ -208,7 +214,7 @@ }); -
+
{#if !isTodayVisible} {/if} @@ -273,7 +279,7 @@ diff --git a/apps/calendar/apps/web/src/lib/components/calendar/MonthView.svelte b/apps/calendar/apps/web/src/lib/components/calendar/MonthView.svelte index d32183cae..936c5b755 100644 --- a/apps/calendar/apps/web/src/lib/components/calendar/MonthView.svelte +++ b/apps/calendar/apps/web/src/lib/components/calendar/MonthView.svelte @@ -18,9 +18,6 @@ isToday, isSameDay, isWeekend, - setYear, - setMonth, - setDate, getHours, getMinutes, differenceInMinutes, diff --git a/apps/calendar/apps/web/src/lib/components/calendar/PillCalendarSelector.svelte b/apps/calendar/apps/web/src/lib/components/calendar/PillCalendarSelector.svelte index 8e52c37ec..aff0d8d57 100644 --- a/apps/calendar/apps/web/src/lib/components/calendar/PillCalendarSelector.svelte +++ b/apps/calendar/apps/web/src/lib/components/calendar/PillCalendarSelector.svelte @@ -2,6 +2,16 @@ import { calendarsStore } from '$lib/stores/calendars.svelte'; import { goto } from '$app/navigation'; + // Portal action - moves element to body to escape stacking contexts + function portal(node: HTMLElement) { + document.body.appendChild(node); + return { + destroy() { + node.remove(); + }, + }; + } + interface Props { direction?: 'up' | 'down'; embedded?: boolean; @@ -80,20 +90,23 @@ {#if isOpen} - + - +