fix(rack-planner): resolve infinite re-render loop in ConnectionLayer and add null-safety for VLAN tooltips
This commit is contained in:
@@ -258,22 +258,24 @@ export function RackPlanner() {
|
||||
</div>
|
||||
</div>
|
||||
) : (
|
||||
<SortableContext items={rackIds} strategy={horizontalListSortingStrategy}>
|
||||
<div
|
||||
ref={canvasRef}
|
||||
className="flex gap-4 p-4 min-h-full items-start"
|
||||
style={{ background: '#0f1117' }}
|
||||
>
|
||||
{racks.map((rack) => (
|
||||
<RackColumn
|
||||
key={rack.id}
|
||||
rack={rack}
|
||||
hoverSlot={hoverSlot}
|
||||
/>
|
||||
))}
|
||||
<ConnectionLayer />
|
||||
</div>
|
||||
</SortableContext>
|
||||
<>
|
||||
<SortableContext items={rackIds} strategy={horizontalListSortingStrategy}>
|
||||
<div
|
||||
ref={canvasRef}
|
||||
className="flex gap-4 p-4 min-h-full items-start"
|
||||
style={{ background: '#0f1117' }}
|
||||
>
|
||||
{racks.map((rack) => (
|
||||
<RackColumn
|
||||
key={rack.id}
|
||||
rack={rack}
|
||||
hoverSlot={hoverSlot}
|
||||
/>
|
||||
))}
|
||||
</div>
|
||||
</SortableContext>
|
||||
<ConnectionLayer />
|
||||
</>
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user