diff --git a/packages/web/src/components/layout/ChannelSidebar.tsx b/packages/web/src/components/layout/ChannelSidebar.tsx index c86029b1..fd880a84 100644 --- a/packages/web/src/components/layout/ChannelSidebar.tsx +++ b/packages/web/src/components/layout/ChannelSidebar.tsx @@ -20,6 +20,7 @@ import { useContextMenuStore, type ContextMenuItem } from '../../stores/contextM import { ConfirmDialog } from '../ui/ConfirmDialog'; import { DmSearchBar } from './DmSearchBar'; import { useDragManager, type DropTarget, type LayoutItem } from '../../hooks/useDragManager'; +import { useDelayedLoading } from '../../hooks/useDelayedLoading'; export function ChannelSidebar() { const spaces = useSpaceStore((s) => s.spaces); @@ -88,6 +89,7 @@ export function ChannelSidebar() { const space = spaces.find(s => s.id === currentSpaceId); const mySpacePerms = currentSpaceId ? spacePermissions.get(currentSpaceId) : undefined; const isLoadingSpace = !!loadingSpaceId && loadingSpaceId === currentSpaceId; + const showChannelSkeleton = useDelayedLoading(isLoadingSpace); const federationInstances = useInstanceStore((s) => s.instances); const instanceLabel = useMemo(() => { @@ -626,7 +628,7 @@ export function ChannelSidebar() { {/* Channels — dynamic category layout */}
- {isLoadingSpace ? ( + {showChannelSkeleton ? (
{/* Category group 1 */}