From c0865d51967fb9ba9b0f268f9b84e8524f396186 Mon Sep 17 00:00:00 2001 From: MayaTheShy Date: Fri, 20 Feb 2026 02:35:41 -0500 Subject: [PATCH] feat: Add equipment and inventory action buttons to TurtleCard --- client/src/components/ControlPanel.jsx | 75 ++++++++++++++++++++++++-- 1 file changed, 72 insertions(+), 3 deletions(-) diff --git a/client/src/components/ControlPanel.jsx b/client/src/components/ControlPanel.jsx index bc105d5..6ed0763 100644 --- a/client/src/components/ControlPanel.jsx +++ b/client/src/components/ControlPanel.jsx @@ -487,17 +487,86 @@ function TurtleDetails({ turtle }) { + {/* Equipment & Inventory Actions */} +
+

Equipment & Inventory

+
+ + + + + + + + +
+
+ {turtle.inventory && turtle.inventory.length > 0 && (
-

Inventory ({turtle.inventoryCount || turtle.inventory.length}/16)

+

Inventory ({turtle.inventoryCount || turtle.inventory.length}/16) — Slot: {turtle.selectedSlot || 1}

{Array.from({ length: 16 }, (_, slotIndex) => { const item = turtle.inventory[slotIndex]; + const isSelected = (turtle.selectedSlot || 1) === (slotIndex + 1); return (
handleSlotClick(slotIndex)} + style={isSelected ? { outline: '2px solid #60a5fa', outlineOffset: '-2px' } : {}} > {item ? ( <>