From e03e1206c7b79754193bb9e23cb4340cbdbc5b83 Mon Sep 17 00:00:00 2001 From: yangdx Date: Mon, 17 Mar 2025 19:48:18 +0800 Subject: [PATCH] Remove refresh layout button and related code --- .../src/components/graph/LayoutsControl.tsx | 17 +---------------- 1 file changed, 1 insertion(+), 16 deletions(-) diff --git a/lightrag_webui/src/components/graph/LayoutsControl.tsx b/lightrag_webui/src/components/graph/LayoutsControl.tsx index bf853dd0..aed244f4 100644 --- a/lightrag_webui/src/components/graph/LayoutsControl.tsx +++ b/lightrag_webui/src/components/graph/LayoutsControl.tsx @@ -15,7 +15,7 @@ import { Command, CommandGroup, CommandItem, CommandList } from '@/components/ui import { controlButtonVariant } from '@/lib/constants' import { useSettingsStore } from '@/stores/settings' -import { GripIcon, PlayIcon, PauseIcon, RefreshCwIcon } from 'lucide-react' +import { GripIcon, PlayIcon, PauseIcon } from 'lucide-react' import { useTranslation } from 'react-i18next' type LayoutName = @@ -279,23 +279,8 @@ const LayoutsControl = () => { [layouts, sigma] ) - const refreshLayout = useCallback(() => { - if (!sigma) return - const graph = sigma.getGraph() - const positions = layoutForceAtlas2.positions() - animateNodes(graph, positions, { duration: 500 }) - }, [sigma, layoutForceAtlas2]) - return ( <> -
{layouts[layout] && 'worker' in layouts[layout] && (