Voice-to-text dictation app with local (Nvidia Parakeet/Whisper) and cloud models (BYOK). Privacy-first and available cross-platform.
JavaScript aianthropiccross-platformgeminigroqlinuxmacosnvidiaopen-sourceopenaiparakeetspeech-to-texttranscribewhisperwindows
feat(calendar): redesign Coming up sidebar with join-and-take-notes and empty states
Gabriel Steina5e59ee400a2
diff --git a/src/components/ControlPanel.tsx b/src/components/ControlPanel.tsxindex a59e1a1bc..5876e5a0d 100644--- a/src/components/ControlPanel.tsx+++ b/src/components/ControlPanel.tsx@@ -1201,6 +1201,7 @@ export default function ControlPanel({ initialSettingsSection }: ControlPanelProsetSettingsSection(section);setShowSettings(true);}}+ onOpenIntegrations={() => setActiveView("integrations")}/>)}{activeView === "chat" && agentAllowedByPolicy && (diff --git a/src/components/HistoryView.tsx b/src/components/HistoryView.tsxindex b22bfe7ca..f2a6ec54b 100644--- a/src/components/HistoryView.tsx+++ b/src/components/HistoryView.tsx@@ -26,6 +26,7 @@ interface HistoryViewProps {deleteTranscription: (id: number) => void;clearAllTranscriptions: () => void;onOpenSettings: (section?: string) => void;+ onOpenIntegrations: () => void;onShowAudioInFolder: (id: number) => void;onRetryTranscription: (id: number, options?: { isRecover?: boolean }) => Promise<void>;showDiscarded: boolean;@@ -45,6 +46,7 @@ export default function HistoryView({deleteTranscription,clearAllTranscriptions,onOpenSettings,+ onOpenIntegrations,onShowAudioInFolder,onRetryTranscription,showDiscarded,@@ -171,16 +173,14 @@ export default function HistoryView({</div>)}- <div className={cn(isConnected ? "flex gap-6" : "")}>- <div className={cn("min-w-0", isConnected ? "flex-1" : "w-full")}>- {isConnected && (- <div className="flex items-center gap-1.5 pb-2.5">- <Mic size={12} className="text-muted-foreground" />- <span className="text-[11px] font-semibold text-muted-foreground uppercase tracking-wide">- {t("upcoming.transcriptions")}- </span>- </div>- )}+ <div className="flex gap-6">+ <div className="min-w-0 flex-1">+ <div className="flex items-center gap-1.5 pb-2.5">+ <Mic size={12} className="text-muted-foreground" />+ <span className="text-[11px] font-semibold text-muted-foreground uppercase tracking-wide">+ {t("upcoming.transcriptions")}+ </span>+ </div>{!dataRetentionEnabled && (<div className="mb-3 rounded-lg border border-amber-500/30 bg-amber-500/5 dark:bg-amber-500/10 px-3.5 py-2.5 flex items-center gap-2.5"><span className="text-amber-600 dark:text-amber-400 shrink-0 text-sm">⊘</span>@@ -340,13 +340,16 @@ export default function HistoryView({)}</div>- {isConnected && (- <div className="w-64 shrink-0 hidden sm:block">- <div className="sticky top-4">- <UpcomingMeetings events={events} isLoading={eventsLoading} />- </div>+ <div className="w-64 shrink-0 hidden sm:block">+ <div className="sticky top-4">+ <UpcomingMeetings+ events={events}+ isLoading={eventsLoading}+ isConnected={isConnected}+ onConnectCalendar={onOpenIntegrations}+ /></div>- )}+ </div></div></div></div>diff --git a/src/components/UpcomingMeetings.tsx b/src/components/UpcomingMeetings.tsxindex 7a803b9c0..6e1c3d727 100644--- a/src/components/UpcomingMeetings.tsx+++ b/src/components/UpcomingMeetings.tsx@@ -1,18 +1,20 @@-import { useState, useMemo } from "react";+import { useMemo } from "react";import { useTranslation } from "react-i18next";-import { Calendar, Loader2, LogIn, Monitor, Video } from "lucide-react";+import { Calendar, ExternalLink, Loader2, Mic, Monitor, Video } from "lucide-react";import { Button } from "./ui/button";+import { Popover, PopoverContent, PopoverTrigger } from "./ui/popover";+import PersonAvatar from "./ui/PersonAvatar";import { cn } from "./lib/utils";-import type { CalendarEvent } from "../types/calendar";-import { formatUpcomingDateGroup } from "../utils/dateFormatting";+import type { CalendarAttendee, CalendarEvent } from "../types/calendar";import { useSystemAudioPermission } from "../hooks/useSystemAudioPermission";-import { useSettingsStore } from "../stores/settingsStore";import { canManageSystemAudioInApp } from "../utils/systemAudioAccess";import { getMeetingJoinUrl } from "../helpers/meetingJoinUrl";interface UpcomingMeetingsProps {events: CalendarEvent[];isLoading: boolean;+ isConnected: boolean;+ onConnectCalendar: () => void;}const openJoinUrl = (url: string) => {@@ -23,51 +25,283 @@ const openJoinUrl = (url: string) => {}};-export default function UpcomingMeetings({ events, isLoading }: UpcomingMeetingsProps) {+function parseAttendees(event: CalendarEvent): CalendarAttendee[] {+ if (!event.attendees) return [];+ try {+ const parsed = JSON.parse(event.attendees);+ return Array.isArray(parsed) ? parsed : [];+ } catch {+ return [];+ }+}++function formatTimeRange(locale: string, startTime: string, endTime: string): string {+ const format = (value: string) =>+ new Date(value).toLocaleTimeString(locale, { hour: "numeric", minute: "2-digit" });+ return `${format(startTime)} – ${format(endTime)}`;+}++interface DayGroup {+ key: string;+ date: Date;+ isToday: boolean;+ items: CalendarEvent[];+}++function groupEventsByDay(events: CalendarEvent[], now: Date): DayGroup[] {+ const groups: DayGroup[] = [];+ const byKey = new Map<string, DayGroup>();+ for (const event of events) {+ const date = new Date(event.start_time);+ const key = date.toDateString();+ let group = byKey.get(key);+ if (!group) {+ group = { key, date, isToday: key === now.toDateString(), items: [] };+ byKey.set(key, group);+ groups.push(group);+ }+ group.items.push(event);+ }+ // Surface "today" even when it has nothing scheduled, so the list always+ // answers "what's next today?" at a glance.+ if (groups.length > 0 && !groups.some((g) => g.isToday)) {+ groups.unshift({ key: now.toDateString(), date: now, isToday: true, items: [] });+ }+ return groups;+}++const RSVP_DOT: Record<string, string> = {+ accepted: "bg-green-500",+ declined: "bg-red-400",+ tentative: "bg-amber-400",+};++function AttendeePopover({+ event,+ attendees,+ timeRange,+ joinUrl,+}: {+ event: CalendarEvent;+ attendees: CalendarAttendee[];+ timeRange: string;+ joinUrl: string | null;+}) {+ const { t } = useTranslation();++ return (+ <Popover>+ <PopoverTrigger asChild>+ <button+ aria-label={`${attendees.length} ${t("notes.participants.attendees")}`}+ className="flex shrink-0 items-center -space-x-1.5 rounded-full pt-0.5 outline-none transition-opacity hover:opacity-80 focus-visible:ring-1 focus-visible:ring-ring/40"+ >+ {attendees.slice(0, 3).map((a) => (+ <PersonAvatar+ key={a.email}+ email={a.email}+ displayName={a.displayName}+ size={16}+ className="ring-1 ring-background"+ />+ ))}+ {attendees.length > 3 && (+ <span className="flex h-4 min-w-4 items-center justify-center rounded-full bg-muted px-0.5 text-[9px] font-medium text-muted-foreground ring-1 ring-background">+ +{attendees.length - 3}+ </span>+ )}+ </button>+ </PopoverTrigger>+ <PopoverContent align="end" className="w-72 p-0">+ <div className="border-b border-border/50 px-3 py-2.5">+ <p className="text-xs font-medium leading-snug text-foreground">+ {event.summary || t("upcoming.untitledEvent")}+ </p>+ <p className="mt-0.5 text-[11px] tabular-nums text-muted-foreground">{timeRange}</p>+ </div>+ <div className="max-h-56 overflow-y-auto p-1">+ {attendees.map((a) => (+ <div key={a.email} className="flex items-center gap-2 rounded-md px-2 py-1.5">+ <PersonAvatar email={a.email} displayName={a.displayName} />+ <div className="min-w-0 flex-1">+ <p className="truncate text-xs text-foreground/80">+ {a.displayName || a.email.split("@")[0]}+ {a.self && (+ <span className="ml-1 text-foreground/30">{t("notes.participants.me")}</span>+ )}+ </p>+ <p className="truncate text-[11px] text-foreground/35">{a.email}</p>+ </div>+ <span+ className={cn(+ "h-1.5 w-1.5 shrink-0 rounded-full",+ RSVP_DOT[a.responseStatus ?? ""] ?? "bg-muted-foreground/25"+ )}+ />+ </div>+ ))}+ </div>+ {joinUrl && (+ <div className="border-t border-border/50 p-1">+ <button+ onClick={() => openJoinUrl(joinUrl)}+ className="flex w-full cursor-pointer items-center gap-2 rounded-md px-2 py-1.5 text-xs text-foreground/70 transition-colors hover:bg-foreground/5"+ >+ <ExternalLink size={12} className="shrink-0" />+ {t("upcoming.openMeetingLink")}+ </button>+ </div>+ )}+ </PopoverContent>+ </Popover>+ );+}++function EventRow({ event, isNow }: { event: CalendarEvent; isNow: boolean }) {+ const { t, i18n } = useTranslation();+ const joinUrl = getMeetingJoinUrl(event);+ const attendees = useMemo(() => parseAttendees(event), [event]);+ const timeRange = formatTimeRange(i18n.language, event.start_time, event.end_time);++ const startNotes = () => {+ if (joinUrl) openJoinUrl(joinUrl);+ window.electronAPI?.joinCalendarMeeting?.(event.id);+ };++ return (+ <div+ className={cn(+ "group/event border-l-2 pl-2.5",+ isNow ? "border-green-500/60" : "border-primary/25"+ )}+ >+ <div className="flex items-start gap-2">+ <p className="min-w-0 flex-1 text-[13px] font-medium leading-snug text-foreground line-clamp-2">+ {event.summary || t("upcoming.untitledEvent")}+ </p>+ {attendees.length > 1 ? (+ <AttendeePopover+ event={event}+ attendees={attendees}+ timeRange={timeRange}+ joinUrl={joinUrl}+ />+ ) : event.attendees_count > 1 ? (+ <span className="shrink-0 pt-0.5 text-[11px] tabular-nums text-muted-foreground/70">+ +{event.attendees_count - 1}+ </span>+ ) : null}+ </div>+ <div className="mt-1 flex items-center justify-between gap-2">+ {isNow ? (+ <span className="flex items-center gap-1.5">+ <span className="relative flex h-1.5 w-1.5">+ <span className="absolute inline-flex h-full w-full animate-pulse rounded-full bg-green-500 opacity-75" />+ <span className="relative inline-flex h-1.5 w-1.5 rounded-full bg-green-500" />+ </span>+ <span className="text-[11px] font-medium tabular-nums text-green-600 dark:text-green-400">+ {t("upcoming.now")}+ </span>+ </span>+ ) : (+ <span className="text-[11px] tabular-nums text-muted-foreground">{timeRange}</span>+ )}+ <Button+ size="sm"+ variant={isNow ? "default" : "ghost"}+ onClick={startNotes}+ className={cn(+ "h-6 min-w-0 gap-1 px-2 text-[11px] font-medium",+ !isNow &&+ "text-muted-foreground opacity-0 transition-opacity duration-150 hover:text-foreground focus-visible:opacity-100 group-hover/event:opacity-100"+ )}+ >+ {joinUrl ? (+ <Video size={11} className="shrink-0" />+ ) : (+ <Mic size={11} className="shrink-0" />+ )}+ <span className="truncate">+ {joinUrl ? t("upcoming.joinAndTakeNotes") : t("upcoming.takeNotes")}+ </span>+ </Button>+ </div>+ </div>+ );+}++function DayCard({ group, isNowFn }: { group: DayGroup; isNowFn: (e: CalendarEvent) => boolean }) {const { t, i18n } = useTranslation();- const [hoveredEventId, setHoveredEventId] = useState<string | null>(null);+ const locale = i18n.language;++ return (+ <div className="rounded-lg border border-border/40 bg-card/50 px-3 py-2.5 dark:border-border-subtle/60 dark:bg-surface-2/60">+ <div className="flex items-center gap-2 pb-2">+ <span className="text-[22px] font-semibold leading-none tabular-nums text-foreground">+ {group.date.getDate()}+ </span>+ <div className="flex flex-col justify-center">+ <span className="inline-flex items-center gap-1 text-[11px] font-medium leading-tight text-foreground">+ {group.date.toLocaleDateString(locale, { month: "long" })}+ {group.isToday && <span className="h-1 w-1 rounded-full bg-red-500" />}+ </span>+ <span className="text-[10px] leading-tight text-muted-foreground">+ {group.date.toLocaleDateString(locale, { weekday: "short" })}+ </span>+ </div>+ </div>+ {group.items.length === 0 ? (+ <div className="border-l-2 border-border/40 pl-2.5 text-xs text-muted-foreground/60">+ {t("upcoming.noEventsToday")}+ </div>+ ) : (+ <div className="space-y-2.5">+ {group.items.map((event) => (+ <EventRow key={event.id} event={event} isNow={isNowFn(event)} />+ ))}+ </div>+ )}+ </div>+ );+}++function SidebarCard({+ icon: Icon,+ title,+ description,+ children,+}: {+ icon: typeof Calendar;+ title?: string;+ description?: string;+ children?: React.ReactNode;+}) {+ return (+ <div className="flex flex-col items-center rounded-lg border border-border/40 bg-card/50 px-4 py-6 text-center dark:border-border-subtle/60 dark:bg-surface-2/60">+ <Icon size={20} className="mb-2 text-muted-foreground/40" />+ {title && <p className="text-xs font-medium text-foreground/80">{title}</p>}+ {description && (+ <p className="mt-1 text-xs leading-relaxed text-muted-foreground/60">{description}</p>+ )}+ {children && <div className="mt-3">{children}</div>}+ </div>+ );+}++export default function UpcomingMeetings({+ events,+ isLoading,+ isConnected,+ onConnectCalendar,+}: UpcomingMeetingsProps) {+ const { t } = useTranslation();const systemAudio = useSystemAudioPermission();- const isSignedIn = useSettingsStore((s) => s.isSignedIn);- const appleCalendarConnected = useSettingsStore((s) => s.appleCalendarConnected);const needsSystemAudioGrant = !systemAudio.granted && canManageSystemAudioInApp(systemAudio);const now = useMemo(() => new Date(), []);+ const groupedEvents = useMemo(() => groupEventsByDay(events, now), [events, now]);- const groupedEvents = useMemo(() => {- if (events.length === 0) return [];- const groups: { label: string; items: CalendarEvent[] }[] = [];- let currentLabel: string | null = null;-- for (const event of events) {- const label = formatUpcomingDateGroup(event.start_time, t);- if (label !== currentLabel) {- groups.push({ label, items: [event] });- currentLabel = label;- } else {- groups[groups.length - 1].items.push(event);- }- }- return groups;- }, [events, t]);-- const formatTimeRange = (startTime: string, endTime: string): string => {- const start = new Date(startTime);- const end = new Date(endTime);- const locale = i18n.language;-- const startStr = start.toLocaleTimeString(locale, {- hour: "numeric",- minute: "2-digit",- });- const endStr = end.toLocaleTimeString(locale, {- hour: "numeric",- minute: "2-digit",- });-- return `${startStr} \u2013 ${endStr}`;- };-- const isHappeningNow = (event: CalendarEvent): boolean => {+ const isNowFn = (event: CalendarEvent) => {const start = new Date(event.start_time);const end = new Date(event.end_time);return start <= now && now <= end;@@ -78,7 +312,7 @@ export default function UpcomingMeetings({ events, isLoading }: UpcomingMeetings{/* Header */}<div className="flex items-center gap-1.5 pb-2.5"><Calendar size={12} className="text-muted-foreground" />- <span className="text-[11px] font-semibold text-muted-foreground uppercase tracking-wide">+ <span className="text-[11px] font-semibold uppercase tracking-wide text-muted-foreground">{t("upcoming.title")}</span></div>@@ -90,133 +324,56 @@ export default function UpcomingMeetings({ events, isLoading }: UpcomingMeetings</div>)}- {/* Empty state */}- {!isLoading && events.length === 0 && (- <div className="flex flex-col items-center justify-center py-8 px-3">- {needsSystemAudioGrant ? (- <>- <Monitor size={24} className="text-muted-foreground/30 mb-2.5" />- <p className="text-xs text-muted-foreground/60 text-center mb-3">- {t("upcoming.systemAudioRequired")}- </p>- <Button- size="sm"- variant="outline"- onClick={() => systemAudio.request()}- className="text-xs h-7"- >- {systemAudio.mode === "native"- ? t("upcoming.openSettings")- : t("onboarding.permissions.grantAccess")}- </Button>- </>- ) : !isSignedIn && !appleCalendarConnected ? (- <>- <LogIn size={24} className="text-muted-foreground/30 mb-2.5" />- <p className="text-xs font-medium text-muted-foreground/70 text-center mb-1">- {t("upcoming.signInRequired")}- </p>- <p className="text-xs text-muted-foreground/50 text-center mb-3">- {t("upcoming.signInDescription")}- </p>- </>- ) : (- <>- <Calendar size={24} className="text-muted-foreground/30 mb-2.5" />- <p className="text-xs text-muted-foreground/60 text-center">- {t("upcoming.noMoreMeetings")}- </p>- </>- )}- </div>+ {/* Calendar not connected */}+ {!isLoading && !isConnected && (+ <SidebarCard+ icon={Calendar}+ title={t("upcoming.connectCalendar")}+ description={t("upcoming.connectCalendarDescription")}+ >+ <Button size="sm" onClick={onConnectCalendar} className="h-7 text-xs">+ {t("upcoming.connectCalendarButton")}+ </Button>+ </SidebarCard>)}- {/* Grouped event list */}- {!isLoading && groupedEvents.length > 0 && (- <div>- {groupedEvents.map((group, groupIndex) => (- <div key={group.label} className={groupIndex > 0 ? "mt-4" : ""}>- <div className="pt-2 pb-2">- <span className="text-[11px] font-semibold text-muted-foreground uppercase tracking-wide">- {group.label}- </span>- </div>- <div className="space-y-1.5">- {group.items.map((event) => {- const joinUrl = getMeetingJoinUrl(event);- const isNow = isHappeningNow(event);- const isHovered = hoveredEventId === event.id;-- return (- <div- key={event.id}- className="group rounded-md border border-border/40 dark:border-border-subtle/60 bg-card/50 dark:bg-surface-2/60 px-3 py-2.5 transition-colors duration-150 hover:bg-muted/30 dark:hover:bg-surface-2/80"- onMouseEnter={() => setHoveredEventId(event.id)}- onMouseLeave={() => setHoveredEventId(null)}- >- <div className="flex items-start gap-2.5">- {/* Time / Now indicator */}- <div className="shrink-0 pt-0.5">- {isNow ? (- <div className="flex items-center gap-1.5">- <span className="relative flex h-1.5 w-1.5">- <span className="absolute inline-flex h-full w-full animate-pulse rounded-full bg-green-500 opacity-75" />- <span className="relative inline-flex h-1.5 w-1.5 rounded-full bg-green-500" />- </span>- <span className="text-[11px] font-medium text-green-600 dark:text-green-400 tabular-nums">- {t("upcoming.now")}- </span>- </div>- ) : (- <span className="text-[11px] text-muted-foreground tabular-nums">- {formatTimeRange(event.start_time, event.end_time)}- </span>- )}- </div>-- {/* Spacer to push join button right */}- <div className="flex-1" />-- {/* Join button (on hover) */}- {joinUrl && (- <div- className={cn(- "shrink-0 transition-opacity duration-150",- isHovered ? "opacity-100" : "opacity-0"- )}- >- <Button- size="icon"- variant="ghost"- onClick={() => {- openJoinUrl(joinUrl);- window.electronAPI?.joinCalendarMeeting?.(event.id);- }}- title={t("upcoming.join")}- className="h-6 w-6 rounded-sm text-muted-foreground hover:text-foreground hover:bg-foreground/10"- >- <Video size={12} />- </Button>- </div>- )}- </div>-- {/* Title + attendees */}- <div className="mt-1 flex items-baseline gap-1.5">- <p className="flex-1 min-w-0 text-foreground text-sm leading-snug line-clamp-2">- {event.summary || t("upcoming.untitledEvent")}- </p>- {event.attendees_count > 1 && (- <span className="shrink-0 text-[11px] text-muted-foreground/70 tabular-nums">- +{event.attendees_count - 1}- </span>- )}- </div>- </div>- );- })}- </div>- </div>+ {/* Connected, nothing scheduled */}+ {!isLoading &&+ isConnected &&+ events.length === 0 &&+ (needsSystemAudioGrant ? (+ <SidebarCard icon={Monitor} description={t("upcoming.systemAudioRequired")}>+ <Button+ size="sm"+ variant="outline"+ onClick={() => systemAudio.request()}+ className="h-7 text-xs"+ >+ {systemAudio.mode === "native"+ ? t("upcoming.openSettings")+ : t("onboarding.permissions.grantAccess")}+ </Button>+ </SidebarCard>+ ) : (+ <SidebarCard+ icon={Calendar}+ title={t("upcoming.noUpcomingEvents")}+ description={t("upcoming.moreCalendarsHint")}+ >+ <button+ onClick={onConnectCalendar}+ className="cursor-pointer text-xs text-primary underline-offset-2 outline-none hover:underline focus-visible:underline"+ >+ {t("upcoming.connectHere")}+ </button>+ </SidebarCard>+ ))}++ {/* Day cards */}+ {!isLoading && isConnected && groupedEvents.length > 0 && (+ <div className="space-y-2">+ {groupedEvents.map((group) => (+ <DayCard key={group.key} group={group} isNowFn={isNowFn} />))}</div>)}diff --git a/src/helpers/meetingDetectionEngine.js b/src/helpers/meetingDetectionEngine.jsindex 4d1e80211..cb70694b5 100644--- a/src/helpers/meetingDetectionEngine.js+++ b/src/helpers/meetingDetectionEngine.js@@ -492,6 +492,20 @@ class MeetingDetectionEngine {const eventSummary = detection.event?.summary || "New note";+ const isRealEvent =+ detection.event?.calendar_id &&+ detection.event.calendar_id !== "__detected__" &&+ detection.event.calendar_id !== "__manual__";++ if (+ isRealEvent &&+ (await this._resumeExistingEventNote(detection.event, "calendar-join"))+ ) {+ this._meetingModeActive = true;+ this.audioActivityDetector.resetPrompt();+ return;+ }+const noteResult = this.databaseManager.saveNote(eventSummary, "", "meeting");const meetingsFolder = this.databaseManager.getMeetingsFolder();@@ -508,11 +522,6 @@ class MeetingDetectionEngine {broadcastToWindows("note-added", noteResult.note);- const isRealEvent =- detection.event?.calendar_id &&- detection.event.calendar_id !== "__detected__" &&- detection.event.calendar_id !== "__manual__";-if (isRealEvent) {const calEvent = this.databaseManager.getCalendarEventById(detection.event.id);const updates = { calendar_event_id: detection.event.id };@@ -588,6 +597,24 @@ class MeetingDetectionEngine {});}+ /** Navigates to the note already linked to a calendar event, if any. */+ async _resumeExistingEventNote(event, trigger) {+ const existingNote = this.databaseManager.getNoteByCalendarEventId(event.id);+ if (!existingNote?.id) return false;+ debugLogger.info(+ "Reusing existing note for calendar meeting",+ { eventId: event.id, noteId: existingNote.id, trigger },+ "meeting"+ );+ await this.windowManager.queueMeetingNoteNavigation({+ noteId: existingNote.id,+ folderId: existingNote.folder_id ?? this.databaseManager.getMeetingsFolder()?.id,+ event,+ trigger,+ });+ return true;+ }+async joinCalendarMeeting(eventId, trigger = "calendar-join") {this._meetingModeActive = true;debugLogger.info("Joining calendar meeting", { eventId, trigger }, "meeting");@@ -599,6 +626,11 @@ class MeetingDetectionEngine {return;}+ // Joining the same event twice resumes its note instead of creating a duplicate.+ if (await this._resumeExistingEventNote(calEvent, trigger)) {+ return;+ }+const noteResult = this.databaseManager.saveNote(calEvent.summary || "New note", "", "meeting");const meetingsFolder = this.databaseManager.getMeetingsFolder();diff --git a/src/locales/de/translation.json b/src/locales/de/translation.jsonindex c32d46a9e..6d0e09a0a 100644--- a/src/locales/de/translation.json+++ b/src/locales/de/translation.json@@ -851,20 +851,21 @@"tomorrow": "Morgen"},"upcoming": {- "title": "Anstehende Meetings",+ "title": "Demnächst","transcriptions": "Transkriptionen",- "tomorrow": "Morgen",- "noMoreMeetings": "Keine weiteren Meetings heute","now": "Jetzt",- "join": "Beitreten","untitledEvent": "Unbenanntes Ereignis",+ "joinAndTakeNotes": "Beitreten & Notizen",+ "takeNotes": "Notizen machen",+ "noEventsToday": "Heute keine Termine",+ "noUpcomingEvents": "Keine anstehenden Termine",+ "moreCalendarsHint": "Weitere Kalender gewünscht?",+ "connectHere": "Hier verbinden",+ "openMeetingLink": "Meeting-Link öffnen","systemAudioRequired": "Die Systemaudio-Berechtigung wird benötigt, um den Ton anderer Teilnehmer aufzunehmen.","openSettings": "Systemeinstellungen öffnen",- "signInRequired": "Melden Sie sich an, um Meeting-Aufnahmen zu nutzen",- "signInDescription": "Erstellen Sie ein Konto oder melden Sie sich an, um Meetings aufzunehmen und zu transkribieren.","connectCalendar": "Kalender verbinden",- "connectCalendarDescription": "Verknüpfe deinen Google Kalender, um anstehende Meetings zu sehen und automatisch Notizen aufzuzeichnen.",- "notABot": "OpenWhispr nimmt über dein Systemaudio auf — es tritt niemals als Bot deinen Meetings bei.",+ "connectCalendarDescription": "Sieh deine Meetings und tritt ihnen bei, ohne OpenWhispr zu verlassen.","connectCalendarButton": "Kalender verbinden"},"cleanupPrompt": "Textbereinigung",diff --git a/src/locales/en/translation.json b/src/locales/en/translation.jsonindex 07474bd08..ef9cfa885 100644--- a/src/locales/en/translation.json+++ b/src/locales/en/translation.json@@ -851,20 +851,21 @@"tomorrow": "Tomorrow"},"upcoming": {- "title": "Upcoming Meetings",+ "title": "Coming up","transcriptions": "Transcriptions",- "tomorrow": "Tomorrow",- "noMoreMeetings": "No more meetings today","now": "Now",- "join": "Join","untitledEvent": "Untitled Event",+ "joinAndTakeNotes": "Join & take notes",+ "takeNotes": "Take notes",+ "noEventsToday": "No events today",+ "noUpcomingEvents": "No upcoming events",+ "moreCalendarsHint": "Want additional calendars?",+ "connectHere": "Connect them here",+ "openMeetingLink": "Open meeting link","systemAudioRequired": "System Audio permission is needed to capture other participants' audio.","openSettings": "Open System Settings",- "signInRequired": "Sign in to use meeting recording",- "signInDescription": "Create an account or sign in to record and transcribe meetings.","connectCalendar": "Connect your calendar",- "connectCalendarDescription": "Link your Google Calendar to see upcoming meetings and automatically record notes.",- "notABot": "OpenWhispr records using your system audio — it never joins meetings as a bot.",+ "connectCalendarDescription": "See your meetings and join them without leaving OpenWhispr.","connectCalendarButton": "Connect Calendar"},"cleanupPrompt": "Cleanup",diff --git a/src/locales/es/translation.json b/src/locales/es/translation.jsonindex 0286738bb..5fc0fb133 100644--- a/src/locales/es/translation.json+++ b/src/locales/es/translation.json@@ -3275,20 +3275,21 @@"tomorrow": "Mañana"},"upcoming": {- "title": "Próximas reuniones",+ "title": "Próximamente","transcriptions": "Transcripciones",- "tomorrow": "Mañana",- "noMoreMeetings": "No hay más reuniones hoy","now": "Ahora",- "join": "Unirse","untitledEvent": "Evento sin título",+ "joinAndTakeNotes": "Unirse y tomar notas",+ "takeNotes": "Tomar notas",+ "noEventsToday": "Hoy no hay eventos",+ "noUpcomingEvents": "No hay próximos eventos",+ "moreCalendarsHint": "¿Quieres añadir más calendarios?",+ "connectHere": "Conéctalos aquí",+ "openMeetingLink": "Abrir enlace de la reunión","systemAudioRequired": "Se necesita el permiso de Audio del Sistema para capturar el audio de otros participantes.","openSettings": "Abrir Ajustes del Sistema",- "signInRequired": "Inicia sesión para usar la grabación de reuniones",- "signInDescription": "Crea una cuenta o inicia sesión para grabar y transcribir reuniones.","connectCalendar": "Conecta tu calendario",- "connectCalendarDescription": "Vincula tu Google Calendar para ver próximas reuniones y grabar notas automáticamente.",- "notABot": "OpenWhispr graba usando el audio de tu sistema — nunca se une a las reuniones como un bot.",+ "connectCalendarDescription": "Ve tus reuniones y únete a ellas sin salir de OpenWhispr.","connectCalendarButton": "Conectar calendario"},"notesView": {diff --git a/src/locales/fr/translation.json b/src/locales/fr/translation.jsonindex 8c44526c5..482152a50 100644--- a/src/locales/fr/translation.json+++ b/src/locales/fr/translation.json@@ -851,20 +851,21 @@"tomorrow": "Demain"},"upcoming": {- "title": "Réunions à venir",+ "title": "À venir","transcriptions": "Transcriptions",- "tomorrow": "Demain",- "noMoreMeetings": "Plus de réunions aujourd'hui","now": "En cours",- "join": "Rejoindre","untitledEvent": "Événement sans titre",+ "joinAndTakeNotes": "Rejoindre et noter",+ "takeNotes": "Prendre des notes",+ "noEventsToday": "Aucun événement aujourd'hui",+ "noUpcomingEvents": "Aucun événement à venir",+ "moreCalendarsHint": "Vous voulez d'autres calendriers ?",+ "connectHere": "Connectez-les ici",+ "openMeetingLink": "Ouvrir le lien de la réunion","systemAudioRequired": "L'autorisation Audio Système est nécessaire pour capturer l'audio des autres participants.","openSettings": "Ouvrir les Réglages Système",- "signInRequired": "Connectez-vous pour utiliser l'enregistrement de réunions",- "signInDescription": "Créez un compte ou connectez-vous pour enregistrer et transcrire vos réunions.","connectCalendar": "Connectez votre calendrier",- "connectCalendarDescription": "Associez votre Google Calendar pour voir vos prochaines réunions et enregistrer des notes automatiquement.",- "notABot": "OpenWhispr enregistre via l'audio de votre système — il ne rejoint jamais vos réunions en tant que bot.",+ "connectCalendarDescription": "Consultez vos réunions et rejoignez-les sans quitter OpenWhispr.","connectCalendarButton": "Connecter le calendrier"},"cleanupPrompt": "Correction",diff --git a/src/locales/it/translation.json b/src/locales/it/translation.jsonindex 79bcc9732..48f218d7f 100644--- a/src/locales/it/translation.json+++ b/src/locales/it/translation.json@@ -3227,20 +3227,21 @@"tomorrow": "Domani"},"upcoming": {- "title": "Riunioni in programma",+ "title": "In arrivo","transcriptions": "Trascrizioni",- "tomorrow": "Domani",- "noMoreMeetings": "Nessun'altra riunione oggi","now": "In corso",- "join": "Partecipa","untitledEvent": "Evento senza titolo",+ "joinAndTakeNotes": "Partecipa e prendi note",+ "takeNotes": "Prendi note",+ "noEventsToday": "Nessun evento oggi",+ "noUpcomingEvents": "Nessun evento in programma",+ "moreCalendarsHint": "Vuoi altri calendari?",+ "connectHere": "Collegali qui",+ "openMeetingLink": "Apri il link della riunione","systemAudioRequired": "L'autorizzazione Audio di Sistema è necessaria per catturare l'audio degli altri partecipanti.","openSettings": "Apri Impostazioni di Sistema",- "signInRequired": "Accedi per utilizzare la registrazione delle riunioni",- "signInDescription": "Crea un account o accedi per registrare e trascrivere le riunioni.","connectCalendar": "Collega il tuo calendario",- "connectCalendarDescription": "Collega il tuo Google Calendar per vedere le prossime riunioni e registrare note automaticamente.",- "notABot": "OpenWhispr registra usando l'audio del tuo sistema — non entra mai nelle riunioni come bot.",+ "connectCalendarDescription": "Vedi le tue riunioni e partecipa senza uscire da OpenWhispr.","connectCalendarButton": "Collega calendario"},"notesView": {diff --git a/src/locales/ja/translation.json b/src/locales/ja/translation.jsonindex 4d70ad1b0..e6b864789 100644--- a/src/locales/ja/translation.json+++ b/src/locales/ja/translation.json@@ -3227,20 +3227,21 @@"tomorrow": "明日"},"upcoming": {- "title": "今後の会議",+ "title": "今後の予定","transcriptions": "文字起こし",- "tomorrow": "明日",- "noMoreMeetings": "今日の予定はありません","now": "進行中",- "join": "参加","untitledEvent": "無題のイベント",+ "joinAndTakeNotes": "参加してメモを取る",+ "takeNotes": "メモを取る",+ "noEventsToday": "今日の予定はありません",+ "noUpcomingEvents": "今後の予定はありません",+ "moreCalendarsHint": "他のカレンダーも連携しますか?",+ "connectHere": "ここから連携",+ "openMeetingLink": "会議リンクを開く","systemAudioRequired": "他の参加者の音声を録音するには、システムオーディオの権限が必要です。","openSettings": "システム設定を開く",- "signInRequired": "会議録音を使用するにはログインしてください",- "signInDescription": "アカウントを作成またはログインして、会議を録音・文字起こしできます。","connectCalendar": "カレンダーを接続",- "connectCalendarDescription": "Google カレンダーを連携して、今後のミーティングを確認し、自動的にノートを記録します。",- "notABot": "OpenWhispr はシステムオーディオで録音します — ボットとしてミーティングに参加することはありません。",+ "connectCalendarDescription": "OpenWhispr を離れずに会議を確認して参加できます。","connectCalendarButton": "カレンダーを接続"},"notesView": {diff --git a/src/locales/pt/translation.json b/src/locales/pt/translation.jsonindex 8c78bfa70..de8f86ae5 100644--- a/src/locales/pt/translation.json+++ b/src/locales/pt/translation.json@@ -3227,20 +3227,21 @@"tomorrow": "Amanhã"},"upcoming": {- "title": "Próximas reuniões",+ "title": "Em breve","transcriptions": "Transcrições",- "tomorrow": "Amanhã",- "noMoreMeetings": "Sem mais reuniões hoje","now": "Agora",- "join": "Entrar","untitledEvent": "Evento sem título",+ "joinAndTakeNotes": "Entrar e fazer anotações",+ "takeNotes": "Fazer anotações",+ "noEventsToday": "Nenhum evento hoje",+ "noUpcomingEvents": "Nenhum evento próximo",+ "moreCalendarsHint": "Quer calendários adicionais?",+ "connectHere": "Conecte-os aqui",+ "openMeetingLink": "Abrir link da reunião","systemAudioRequired": "A permissão de Áudio do Sistema é necessária para capturar o áudio dos outros participantes.","openSettings": "Abrir Configurações do Sistema",- "signInRequired": "Entre na sua conta para gravar reuniões",- "signInDescription": "Crie uma conta ou entre para gravar e transcrever reuniões.","connectCalendar": "Conecte seu calendário",- "connectCalendarDescription": "Vincule seu Google Calendar para ver próximas reuniões e gravar notas automaticamente.",- "notABot": "O OpenWhispr grava usando o áudio do seu sistema — ele nunca entra nas reuniões como um bot.",+ "connectCalendarDescription": "Veja suas reuniões e entre nelas sem sair do OpenWhispr.","connectCalendarButton": "Conectar calendário"},"notesView": {diff --git a/src/locales/ru/translation.json b/src/locales/ru/translation.jsonindex 2e1712ba0..8b6e193fa 100644--- a/src/locales/ru/translation.json+++ b/src/locales/ru/translation.json@@ -3253,20 +3253,21 @@"tomorrow": "Завтра"},"upcoming": {- "title": "Предстоящие встречи",+ "title": "Скоро","transcriptions": "Транскрипции",- "tomorrow": "Завтра",- "noMoreMeetings": "Больше встреч сегодня нет","now": "Сейчас",- "join": "Присоединиться","untitledEvent": "Без названия",+ "joinAndTakeNotes": "Присоединиться и вести заметки",+ "takeNotes": "Вести заметки",+ "noEventsToday": "Сегодня событий нет",+ "noUpcomingEvents": "Нет предстоящих событий",+ "moreCalendarsHint": "Нужны другие календари?",+ "connectHere": "Подключите их здесь",+ "openMeetingLink": "Открыть ссылку на встречу","systemAudioRequired": "Разрешение «Системное аудио» необходимо для записи звука других участников.","openSettings": "Открыть Системные настройки",- "signInRequired": "Войдите, чтобы записывать встречи",- "signInDescription": "Создайте аккаунт или войдите для записи и транскрипции встреч.","connectCalendar": "Подключите календарь",- "connectCalendarDescription": "Свяжите Google Календарь, чтобы видеть предстоящие встречи и автоматически записывать заметки.",- "notABot": "OpenWhispr записывает через системный звук — он никогда не присоединяется к встречам как бот.",+ "connectCalendarDescription": "Просматривайте встречи и присоединяйтесь к ним, не выходя из OpenWhispr.","connectCalendarButton": "Подключить календарь"},"notesView": {diff --git a/src/locales/zh-CN/translation.json b/src/locales/zh-CN/translation.jsonindex c41fb63e5..b265bb1b7 100644--- a/src/locales/zh-CN/translation.json+++ b/src/locales/zh-CN/translation.json@@ -3227,20 +3227,21 @@"tomorrow": "明天"},"upcoming": {- "title": "即将开始的会议",+ "title": "即将开始","transcriptions": "转录",- "tomorrow": "明天",- "noMoreMeetings": "今天没有更多会议了","now": "进行中",- "join": "加入","untitledEvent": "无标题事件",+ "joinAndTakeNotes": "加入并记笔记",+ "takeNotes": "记笔记",+ "noEventsToday": "今天没有日程",+ "noUpcomingEvents": "暂无即将开始的日程",+ "moreCalendarsHint": "想连接更多日历?",+ "connectHere": "在这里连接",+ "openMeetingLink": "打开会议链接","systemAudioRequired": "需要系统音频权限来录制其他参与者的音频。","openSettings": "打开系统设置",- "signInRequired": "登录以使用会议录制",- "signInDescription": "创建账户或登录以录制和转录会议。","connectCalendar": "连接您的日历",- "connectCalendarDescription": "关联 Google 日历以查看即将到来的会议并自动记录笔记。",- "notABot": "OpenWhispr 通过系统音频录制 — 它不会以机器人身份加入您的会议。",+ "connectCalendarDescription": "无需离开 OpenWhispr 即可查看并加入您的会议。","connectCalendarButton": "连接日历"},"notesView": {diff --git a/src/locales/zh-TW/translation.json b/src/locales/zh-TW/translation.jsonindex e575078bd..281865d6e 100644--- a/src/locales/zh-TW/translation.json+++ b/src/locales/zh-TW/translation.json@@ -3227,20 +3227,21 @@"tomorrow": "明天"},"upcoming": {- "title": "即將開始的會議",+ "title": "即將開始","transcriptions": "轉錄",- "tomorrow": "明天",- "noMoreMeetings": "今天沒有更多會議了","now": "進行中",- "join": "加入","untitledEvent": "無標題事件",+ "joinAndTakeNotes": "加入並記筆記",+ "takeNotes": "記筆記",+ "noEventsToday": "今天沒有行程",+ "noUpcomingEvents": "暫無即將開始的行程",+ "moreCalendarsHint": "想連接更多日曆?",+ "connectHere": "在這裡連接",+ "openMeetingLink": "開啟會議連結","systemAudioRequired": "需要系統音訊權限來錄製其他參與者的音訊。","openSettings": "打開系統設定",- "signInRequired": "登入以使用會議錄製",- "signInDescription": "建立帳戶或登入以錄製和轉錄會議。","connectCalendar": "連接您的日曆",- "connectCalendarDescription": "關聯 Google 日曆以查看即將到來的會議並自動記錄筆記。",- "notABot": "OpenWhispr 透過系統音訊錄製 — 它不會以機器人身分加入您的會議。",+ "connectCalendarDescription": "無需離開 OpenWhispr 即可查看並加入您的會議。","connectCalendarButton": "連接日曆"},"notesView": {diff --git a/src/utils/dateFormatting.ts b/src/utils/dateFormatting.tsindex 3e15c9e2e..f8bc0cb2e 100644--- a/src/utils/dateFormatting.ts+++ b/src/utils/dateFormatting.ts@@ -27,19 +27,6 @@ export function formatRelativeTime(return formatShortDate(dateStr);}-export function formatUpcomingDateGroup(date: Date | string, t: (key: string) => string): string {- const d = typeof date === "string" ? new Date(date) : date;- const now = new Date();- const today = new Date(now.getFullYear(), now.getMonth(), now.getDate());- const tomorrow = new Date(today);- tomorrow.setDate(tomorrow.getDate() + 1);- const target = new Date(d.getFullYear(), d.getMonth(), d.getDate());-- if (target.getTime() === today.getTime()) return t("controlPanel.history.dateGroups.today");- if (target.getTime() === tomorrow.getTime()) return t("upcoming.tomorrow");- return d.toLocaleDateString(undefined, { weekday: "long", month: "short", day: "numeric" });-}-export function formatDateGroup(date: Date | string, t: (key: string) => string): string {const d = typeof date === "string" ? normalizeDbDate(date) : date;const now = new Date();diff --git a/test/helpers/dateGroupFormatting.test.js b/test/helpers/dateGroupFormatting.test.jsindex a32f965c7..dbb58a6c7 100644--- a/test/helpers/dateGroupFormatting.test.js+++ b/test/helpers/dateGroupFormatting.test.js@@ -10,7 +10,6 @@ const t = (key) =>({"controlPanel.history.dateGroups.today": "Today","controlPanel.history.dateGroups.yesterday": "Yesterday",- "upcoming.tomorrow": "Tomorrow",})[key] || key;// Local-time constructors keep these assertions timezone-independent.@@ -77,21 +76,3 @@ test("history groups zone-less SQLite timestamps as UTC near a local day boundarelse process.env.TZ = previousTimezone;}});--test("upcoming groups label today and tomorrow by calendar day", async (t2) => {- const { formatUpcomingDateGroup } = await load();- t2.mock.timers.enable({ apis: ["Date"], now: NOON_JUNE_15 });-- assert.equal(formatUpcomingDateGroup(new Date(2024, 5, 15, 8), t), "Today");- assert.equal(formatUpcomingDateGroup(new Date(2024, 5, 16, 8), t), "Tomorrow");-});--test("upcoming groups fall back to a formatted date further out", async (t2) => {- const { formatUpcomingDateGroup } = await load();- t2.mock.timers.enable({ apis: ["Date"], now: NOON_JUNE_15 });-- const result = formatUpcomingDateGroup(new Date(2024, 5, 20, 12), t);- assert.ok(result);- assert.notEqual(result, "Today");- assert.notEqual(result, "Tomorrow");-});