mirror of
https://github.com/grafana/grafana.git
synced 2024-11-25 02:10:45 -06:00
Home: Remove extra padding for dashboard home (#89432)
This commit is contained in:
parent
06a1e8e22b
commit
aea894191b
@ -24,7 +24,6 @@ export function DashboardSceneRenderer({ model }: SceneComponentProps<DashboardS
|
|||||||
const pageNav = model.getPageNav(location, navIndex);
|
const pageNav = model.getPageNav(location, navIndex);
|
||||||
const bodyToRender = model.getBodyToRender();
|
const bodyToRender = model.getBodyToRender();
|
||||||
const navModel = getNavModel(navIndex, 'dashboards/browse');
|
const navModel = getNavModel(navIndex, 'dashboards/browse');
|
||||||
const isHomePage = !meta.url && !meta.slug && !meta.isNew && !meta.isSnapshot;
|
|
||||||
const hasControls = controls?.hasControls();
|
const hasControls = controls?.hasControls();
|
||||||
|
|
||||||
if (editview) {
|
if (editview) {
|
||||||
@ -84,7 +83,7 @@ export function DashboardSceneRenderer({ model }: SceneComponentProps<DashboardS
|
|||||||
className={styles.scrollbarContainer}
|
className={styles.scrollbarContainer}
|
||||||
testId={selectors.pages.Dashboard.DashNav.scrollContainer}
|
testId={selectors.pages.Dashboard.DashNav.scrollContainer}
|
||||||
>
|
>
|
||||||
<div className={cx(styles.canvasContent, isHomePage && styles.homePagePadding)}>{body}</div>
|
<div className={cx(styles.canvasContent)}>{body}</div>
|
||||||
</CustomScrollbar>
|
</CustomScrollbar>
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
@ -137,9 +136,6 @@ function getStyles(theme: GrafanaTheme2) {
|
|||||||
controlsWrapperWithScopes: css({
|
controlsWrapperWithScopes: css({
|
||||||
padding: theme.spacing(2, 2, 2, 0),
|
padding: theme.spacing(2, 2, 2, 0),
|
||||||
}),
|
}),
|
||||||
homePagePadding: css({
|
|
||||||
padding: theme.spacing(2, 2),
|
|
||||||
}),
|
|
||||||
canvasContent: css({
|
canvasContent: css({
|
||||||
label: 'canvas-content',
|
label: 'canvas-content',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
|
Loading…
Reference in New Issue
Block a user