From 8735c8341b27bb5dba3a410b4f43030bf2d5a557 Mon Sep 17 00:00:00 2001 From: Forbes Date: Sun, 15 Feb 2026 12:59:40 -0600 Subject: [PATCH] feat(web): move edit/delete buttons into tab bar on item detail Relocate Edit and Delete buttons from the header row into the tab bar, grouping them with tab navigation to reduce mouse travel. Adds Pencil and Trash2 icons for quick visual recognition. Header now only shows part number, type badge, and close button. Closes #119 --- web/src/components/items/ItemDetail.tsx | 61 +++++++++++++++++-------- 1 file changed, 42 insertions(+), 19 deletions(-) diff --git a/web/src/components/items/ItemDetail.tsx b/web/src/components/items/ItemDetail.tsx index 92f72ef..f9e719e 100644 --- a/web/src/components/items/ItemDetail.tsx +++ b/web/src/components/items/ItemDetail.tsx @@ -1,5 +1,5 @@ import { useState, useEffect } from "react"; -import { X } from "lucide-react"; +import { X, Pencil, Trash2 } from "lucide-react"; import { get } from "../../api/client"; import type { Item } from "../../api/types"; import { MainTab } from "./MainTab"; @@ -114,22 +114,6 @@ export function ItemDetail({ {item.item_type} - {isEditor && ( - <> - - - - )} + + + )} {/* Tab Content */} @@ -207,3 +218,15 @@ const headerBtnStyle: React.CSSProperties = { fontSize: "var(--font-table)", padding: "0.25rem 0.5rem", }; + +const tabActionBtnStyle: React.CSSProperties = { + display: "inline-flex", + alignItems: "center", + gap: "0.25rem", + background: "none", + border: "none", + cursor: "pointer", + fontSize: "var(--font-table)", + padding: "0.25rem 0.5rem", + borderRadius: "0.25rem", +}; -- 2.49.1