From e72c2b64b39f2fadb5ab6d4d5093acb5238b2365 Mon Sep 17 00:00:00 2001 From: Joep Meindertsma Date: Tue, 7 Nov 2023 14:58:29 +0100 Subject: [PATCH] Subtle current drive button, improved hover #681 --- browser/data-browser/src/components/Parent.tsx | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/browser/data-browser/src/components/Parent.tsx b/browser/data-browser/src/components/Parent.tsx index 863f71784..0c77ea897 100644 --- a/browser/data-browser/src/components/Parent.tsx +++ b/browser/data-browser/src/components/Parent.tsx @@ -87,6 +87,8 @@ const MAX_BREADCRUMB_DEPTH = 4; /** Shows a "Set drive" button if the current drive is different from the Subject */ function DriveMismatch({ subject }: { subject: string }) { const { drive, setDrive } = useSettings(); + const resource = useResource(subject, { allowIncomplete: true }); + const [title] = useTitle(resource); const handleSetDrive = () => { setDrive(subject); @@ -96,7 +98,11 @@ function DriveMismatch({ subject }: { subject: string }) { if (mismatch) return ( - );