aboutsummaryrefslogtreecommitdiff
path: root/packages/ui/memory-graph/navigation-controls.tsx
diff options
context:
space:
mode:
authornexxeln <[email protected]>2025-12-04 18:54:40 +0000
committernexxeln <[email protected]>2025-12-04 18:54:40 +0000
commit7a2f2cb99c50038e932f898838ab60715c4e47d6 (patch)
tree3bc23f5810349ec848a4c8cf71fd0a310efbd4e2 /packages/ui/memory-graph/navigation-controls.tsx
parentchore(@supermemory/tools): fix the documentation of withSupermemory (#601) (diff)
downloadsupermemory-use-memory-graph-package.tar.xz
supermemory-use-memory-graph-package.zip
use latest graph and remove old graph (#604)use-memory-graph-package
Diffstat (limited to 'packages/ui/memory-graph/navigation-controls.tsx')
-rw-r--r--packages/ui/memory-graph/navigation-controls.tsx67
1 files changed, 0 insertions, 67 deletions
diff --git a/packages/ui/memory-graph/navigation-controls.tsx b/packages/ui/memory-graph/navigation-controls.tsx
deleted file mode 100644
index b2abd67f..00000000
--- a/packages/ui/memory-graph/navigation-controls.tsx
+++ /dev/null
@@ -1,67 +0,0 @@
-"use client"
-
-import { memo } from "react"
-import type { GraphNode } from "./types"
-
-interface NavigationControlsProps {
- onCenter: () => void
- onZoomIn: () => void
- onZoomOut: () => void
- onAutoFit: () => void
- nodes: GraphNode[]
- className?: string
-}
-
-export const NavigationControls = memo<NavigationControlsProps>(({
- onCenter,
- onZoomIn,
- onZoomOut,
- onAutoFit,
- nodes,
- className = "",
-}) => {
- if (nodes.length === 0) {
- return null
- }
-
- return (
- <div className={`flex flex-col gap-1 ${className}`}>
- <button
- type="button"
- onClick={onAutoFit}
- className="bg-black/20 backdrop-blur-sm hover:bg-black/30 border border-white/10 hover:border-white/20 rounded-lg p-2 text-white/70 hover:text-white transition-colors text-xs font-medium min-w-16"
- title="Auto-fit graph to viewport"
- >
- Fit
- </button>
- <button
- type="button"
- onClick={onCenter}
- className="bg-black/20 backdrop-blur-sm hover:bg-black/30 border border-white/10 hover:border-white/20 rounded-lg p-2 text-white/70 hover:text-white transition-colors text-xs font-medium min-w-16"
- title="Center view on graph"
- >
- Center
- </button>
- <div className="flex flex-col">
- <button
- type="button"
- onClick={onZoomIn}
- className="bg-black/20 backdrop-blur-sm hover:bg-black/30 border border-white/10 hover:border-white/20 rounded-t-lg p-2 text-white/70 hover:text-white transition-colors text-xs font-medium min-w-16 border-b-0"
- title="Zoom in"
- >
- +
- </button>
- <button
- type="button"
- onClick={onZoomOut}
- className="bg-black/20 backdrop-blur-sm hover:bg-black/30 border border-white/10 hover:border-white/20 rounded-b-lg p-2 text-white/70 hover:text-white transition-colors text-xs font-medium min-w-16"
- title="Zoom out"
- >
- −
- </button>
- </div>
- </div>
- )
-})
-
-NavigationControls.displayName = "NavigationControls" \ No newline at end of file