From 0977139bc53afe246904deec3b221167839ac3fb Mon Sep 17 00:00:00 2001 From: Xylight Date: Mon, 2 Sep 2024 15:07:00 -0700 Subject: [PATCH] misc: change default preload rules for community page --- .../lemmy/community/CommunityItem.svelte | 1 + src/lib/components/ui/layout/pages/Tabs.svelte | 8 +++++++- src/routes/communities/+page.svelte | 15 ++++++++++----- 3 files changed, 18 insertions(+), 6 deletions(-) diff --git a/src/lib/components/lemmy/community/CommunityItem.svelte b/src/lib/components/lemmy/community/CommunityItem.svelte index 645b9870..c9b2862a 100644 --- a/src/lib/components/lemmy/community/CommunityItem.svelte +++ b/src/lib/components/lemmy/community/CommunityItem.svelte @@ -52,6 +52,7 @@ community.community.actor_id )}" class="flex-1" + data-sveltekit-preload-data="tap" >
{route.name} - {#if (currentRoute ?? $page.url.pathname) == route.href} + {#if isSelected($page.url, currentRoute, route.href)}
{#if data.communities.length > 0} -
- searchParam($page.url, 'page', p.detail.toString())} - /> +
+ + searchParam($page.url, 'page', p.detail.toString())} + /> +
{/if}