From 772a173189329ed52499dcb6565c746a1ee72c4a Mon Sep 17 00:00:00 2001 From: Cedric van Putten Date: Sun, 25 Aug 2024 22:52:10 +0200 Subject: [PATCH] feature(webui): allow copying absolute and relative import paths --- webui/src/components/ModuleReferenceList.tsx | 46 +++++++++++--------- 1 file changed, 26 insertions(+), 20 deletions(-) diff --git a/webui/src/components/ModuleReferenceList.tsx b/webui/src/components/ModuleReferenceList.tsx index ece1d59..d4ca125 100644 --- a/webui/src/components/ModuleReferenceList.tsx +++ b/webui/src/components/ModuleReferenceList.tsx @@ -5,6 +5,7 @@ import PackageIcon from 'lucide-react/dist/esm/icons/box'; import FileIcon from 'lucide-react/dist/esm/icons/file'; import { PropsWithChildren } from 'react'; +import { FilePathMenu } from '~/components/FilePathMenu'; import type { AtlasModuleRef, PartialAtlasBundle } from '~core/data/types'; type ModuleReferenceListProps = PropsWithChildren<{ @@ -37,27 +38,32 @@ function ModuleImportLink(props: ModuleImportLinkProps) { const Icon = props.reference.package ? PackageIcon : FileIcon; return ( - - - - - {props.reference.relativePath} - - - - + + + + {props.reference.relativePath} + + + + + ); }