diff --git a/graph/ui-project-details/src/lib/target-configuration-details-group-container/target-configuration-details-group-container.tsx b/graph/ui-project-details/src/lib/target-configuration-details-group-container/target-configuration-details-group-container.tsx index cb2f867d27e77..17e9d3e10aa47 100644 --- a/graph/ui-project-details/src/lib/target-configuration-details-group-container/target-configuration-details-group-container.tsx +++ b/graph/ui-project-details/src/lib/target-configuration-details-group-container/target-configuration-details-group-container.tsx @@ -15,7 +15,10 @@ export function TargetConfigurationGroupContainer({ return null; } return ( -
+
{ return (
{targetGroupName}{' '} diff --git a/nx-dev/ui-markdoc/src/lib/tags/project-details.component.tsx b/nx-dev/ui-markdoc/src/lib/tags/project-details.component.tsx index 1d8685c4ef362..13a8aeef4609c 100644 --- a/nx-dev/ui-markdoc/src/lib/tags/project-details.component.tsx +++ b/nx-dev/ui-markdoc/src/lib/tags/project-details.component.tsx @@ -58,10 +58,16 @@ export function ProjectDetails({ const header = document.getElementById('target-' + expandedTargets[0]); const container = document.getElementById('project-details-container'); if (header && container) { + const groupHeaderOffset = + header + .closest('[id^="target-group-container-"]') + ?.querySelector('[id^="target-group-header-"]') + ?.getBoundingClientRect().height ?? 0; elementRef.current?.scrollTo({ top: header?.getBoundingClientRect().top - - container.getBoundingClientRect()?.top, + container.getBoundingClientRect()?.top - + groupHeaderOffset, behavior: 'instant', }); }