Skip to content

The easy-to-use open source Business Intelligence and Embedded Analytics tool that lets everyone work with data :bar_chart:

Keep thread spacing consistent in the exploration sidebar below the Summary (#83257)

Denis Berezin20056fab0526
diff --git a/frontend/src/metabase/explorations/components/ExplorationSidebar/ExplorationTreeNode.module.css b/frontend/src/metabase/explorations/components/ExplorationSidebar/ExplorationTreeNode.module.css
index 395b1252986..e4b493503aa 100644
--- a/frontend/src/metabase/explorations/components/ExplorationSidebar/ExplorationTreeNode.module.css
+++ b/frontend/src/metabase/explorations/components/ExplorationSidebar/ExplorationTreeNode.module.css
@@ -65,6 +65,10 @@
margin-top: 0.75rem;
}
+li:first-child > .treeRowThreadSeparated {
+ margin-top: 0;
+}
+
/* Group headings stick while their group is scrolled through, and the whole
* ancestor hierarchy stays visible: each heading pins just below its ancestors'
* pinned headings (top = depth × row height). Each node and its subtree are
diff --git a/frontend/src/metabase/explorations/components/ExplorationSidebar/ExplorationTreeNode.tsx b/frontend/src/metabase/explorations/components/ExplorationSidebar/ExplorationTreeNode.tsx
index 996febb5efa..fd4d75b2bcd 100644
--- a/frontend/src/metabase/explorations/components/ExplorationSidebar/ExplorationTreeNode.tsx
+++ b/frontend/src/metabase/explorations/components/ExplorationSidebar/ExplorationTreeNode.tsx
@@ -138,8 +138,7 @@ function ExplorationTreeHeading({
aria-busy={isLoading}
className={cx(S.treeRow, S.treeRowHeading, {
[S.treeRowNested]: depth > 0,
- [S.treeRowThreadSeparated]:
- depth === 0 && item.data?.headingKind === "sub-exploration",
+ [S.treeRowThreadSeparated]: depth === 0,
})}
tabIndex={0}
onKeyDown={(e) => {