From b1c3e2c639e9fd4fd5f0f5bcc861ca2087f728b0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C5=ABdolfs=20O=C5=A1i=C5=86=C5=A1?= Date: Fri, 20 Nov 2026 10:57:23 +0100 Subject: [PATCH] desktop: Keep the repo list and release counts in the cache The repo list had its own TTL cache, a counter bumped by seeding and a listener of its own, and release counts were fetched separately by the sidebar and the releases page. Now they're queries like the rest, and seeding invalidates the list like any other write. The head a loader resolved is marked through `markLoading` too, so it needs no key of its own. --- desktop/src/components/AddRepoButton.svelte | 8 +- desktop/src/components/Mention.svelte | 5 +- .../src/components/MentionAutocomplete.svelte | 12 +- desktop/src/components/ReferenceLink.svelte | 7 +- desktop/src/components/SidebarRepoList.svelte | 107 +++++------------- desktop/src/lib/cobQueries.ts | 27 +++++ desktop/src/lib/invoke.ts | 35 +----- desktop/src/lib/router/definitions.ts | 32 +++--- desktop/src/lib/seedRepo.ts | 28 ++--- desktop/src/lib/startup.svelte.ts | 14 ++- desktop/src/views/profile/JoinActor.svelte | 46 +++++--- desktop/src/views/repo/Releases.svelte | 13 +-- desktop/src/views/repo/router.ts | 16 +-- desktop/tests/unit/eventBatch.test.ts | 8 +- shared/core/src/keys.ts | 16 --- 15 files changed, 168 insertions(+), 206 deletions(-) diff --git a/desktop/src/components/AddRepoButton.svelte b/desktop/src/components/AddRepoButton.svelte index 8258caba8..e4cfc8642 100644 --- a/desktop/src/components/AddRepoButton.svelte +++ b/desktop/src/components/AddRepoButton.svelte @@ -5,8 +5,10 @@