diff --git a/packages/frontend-core/src/components/grid/layout/Grid.svelte b/packages/frontend-core/src/components/grid/layout/Grid.svelte index 789d8268aa..6edc48e537 100644 --- a/packages/frontend-core/src/components/grid/layout/Grid.svelte +++ b/packages/frontend-core/src/components/grid/layout/Grid.svelte @@ -26,6 +26,9 @@ MaxCellRenderOverflow, GutterWidth, DefaultRowHeight, + Padding, + SmallRowHeight, + ControlsHeight, } from "../lib/constants" export let API = null @@ -104,6 +107,8 @@ notifyError, buttons, }) + $: minHeight = + Padding + SmallRowHeight + $rowHeight + (showControls ? ControlsHeight : 0) // Set context for children to consume setContext("grid", context) @@ -129,7 +134,7 @@ class:quiet on:mouseenter={() => gridFocused.set(true)} on:mouseleave={() => gridFocused.set(false)} - style="--row-height:{$rowHeight}px; --default-row-height:{DefaultRowHeight}px; --gutter-width:{GutterWidth}px; --max-cell-render-overflow:{MaxCellRenderOverflow}px; --content-lines:{$contentLines};" + style="--row-height:{$rowHeight}px; --default-row-height:{DefaultRowHeight}px; --gutter-width:{GutterWidth}px; --max-cell-render-overflow:{MaxCellRenderOverflow}px; --content-lines:{$contentLines}; --min-height:{minHeight}px; --controls-height:{ControlsHeight}px;" > {#if showControls}