mirror of
https://github.com/hansjone/netx.git
synced 2026-10-09 08:05:46 +08:00
Fix fabric path search, read scope, orbit total ranking, and edge menu clamp.
Prefer BFS shortest paths, allow ne:read on path find, honor objective=total clearance trades, and keep context menus on-screen without a11y clock spam. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
parent
298859e608
commit
e4a135ec16
13 changed files with 163 additions and 30 deletions
|
|
@ -3370,8 +3370,7 @@ export function TopologyPage() {
|
|||
y = Math.max(pad, window.innerHeight - rect.height - pad);
|
||||
}
|
||||
if (x !== ctxMenu.x || y !== ctxMenu.y) {
|
||||
el.style.left = `${x}px`;
|
||||
el.style.top = `${y}px`;
|
||||
setCtxMenu((prev) => (prev ? { ...prev, x, y } : null));
|
||||
}
|
||||
}, [ctxMenu]);
|
||||
|
||||
|
|
|
|||
|
|
@ -175,7 +175,7 @@ export function WorkbenchPage() {
|
|||
return (
|
||||
<div className="workbench">
|
||||
<section className="wb-hero" aria-label={t("workbench.title")}>
|
||||
<div className="wb-hero__clock" aria-live="polite">
|
||||
<div className="wb-hero__clock">
|
||||
<time className="wb-hero__clock-panel" dateTime={now.toISOString()}>
|
||||
<span className="wb-hero__clock-digits" aria-hidden="true">
|
||||
<span className="wb-hero__digit">{hh[0]}</span>
|
||||
|
|
|
|||
|
|
@ -446,10 +446,8 @@ export default function TopologyReactFlowView(props: TopologyReactFlowViewProps)
|
|||
onEdgeContextMenu={(e, edge) => {
|
||||
e.preventDefault();
|
||||
focusEdge(edge.id);
|
||||
const pos = placeCtxMenu(e.clientX, e.clientY, {
|
||||
w: 280,
|
||||
h: Math.min(560, Math.max(280, window.innerHeight - 24)),
|
||||
});
|
||||
// Modest estimate; useLayoutEffect measures real height and clamps into state.
|
||||
const pos = placeCtxMenu(e.clientX, e.clientY, { w: 280, h: 320 });
|
||||
setCtxMenu({ kind: "edge", id: edge.id, ...pos });
|
||||
}}
|
||||
onSelectionContextMenu={(e) => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue