feat: show contacts from all logged-in accounts in Pro shell

This commit is contained in:
Linus Rath
2026-05-21 22:32:17 +02:00
parent 2c825af689
commit e80412b6fd
8 changed files with 438 additions and 51 deletions
+5
View File
@@ -3,6 +3,7 @@ import { persist } from 'zustand/middleware';
import { JMAPClient, RateLimitError } from '@/lib/jmap/client';
import type { IJMAPClient } from '@/lib/jmap/client-interface';
import { useIdentityStore } from './identity-store';
import { setClientLookup } from './client-registry';
import { useContactStore } from './contact-store';
import { useVacationStore } from './vacation-store';
import { useCalendarStore } from './calendar-store';
@@ -1661,3 +1662,7 @@ export const useAuthStore = create<AuthState>()(
}
)
);
// Expose getClientForAccount to the calendar/contact stores via a small
// shared registry — see [[stores/client-registry]] for rationale.
setClientLookup((accountId) => useAuthStore.getState().getClientForAccount(accountId));