PanelEditor: Fixes double top border around Queries (#112865)

* PanelEditor: Fixes double top border around Queries

* Fixes
This commit is contained in:
Torkel Ödegaard
2025-10-30 10:49:54 +01:00
committed by GitHub
parent ee62a8d431
commit 3cabc12f4c
@@ -80,14 +80,16 @@ function PanelDataPaneRendered({ model }: SceneComponentProps<PanelDataPane>) {
return (
<div className={styles.dataPane} data-testid={selectors.components.PanelEditor.DataPane.content}>
<TabsBar className={styles.tabsBar}>
<TabsBar hideBorder className={styles.tabsBar}>
{tabs.map((t) => t.renderTab({ active: t.tabId === tab, onChangeTab: () => model.onChangeTab(t) }))}
</TabsBar>
<ScrollContainer backgroundColor="primary">
<TabContent className={styles.tabContent}>
<Container>{currentTab && <currentTab.Component model={currentTab} />}</Container>
</TabContent>
</ScrollContainer>
<div className={styles.tabBorder}>
<ScrollContainer>
<TabContent className={styles.tabContent}>
<Container>{currentTab && <currentTab.Component model={currentTab} />}</Container>
</TabContent>
</ScrollContainer>
</div>
</div>
);
}
@@ -116,13 +118,18 @@ function getStyles(theme: GrafanaTheme2) {
height: '100%',
width: '100%',
}),
tabContent: css({
padding: theme.spacing(2),
tabBorder: css({
background: theme.colors.background.primary,
border: `1px solid ${theme.colors.border.weak}`,
borderLeft: 'none',
borderBottom: 'none',
borderTopRightRadius: theme.shape.radius.default,
flexGrow: 1,
overflow: 'hidden',
}),
tabContent: css({
padding: theme.spacing(2),
height: '100%',
}),
tabsBar: css({
flexShrink: 0,