diff --git a/packages/client/src/components/app/GridBlock.svelte b/packages/client/src/components/app/GridBlock.svelte index 4ed8f91f2a..da9a3ccc4e 100644 --- a/packages/client/src/components/app/GridBlock.svelte +++ b/packages/client/src/components/app/GridBlock.svelte @@ -36,6 +36,7 @@ let grid let gridContext + let minHeight $: parsedColumns = getParsedColumns(columns) $: columnWhitelist = parsedColumns.filter(x => x.active).map(x => x.field) @@ -50,8 +51,7 @@ metadata: { dataSource: table }, }, ] - $: height = $component.styles?.normal?.height || "408px" - $: styles = getSanitisedStyles($component.styles) + $: gridContext?.minHeight?.subscribe($height => (minHeight = $height)) // Provide additional data context for live binding eval export const getAdditionalDataContext = () => { @@ -128,23 +128,16 @@ ) } - const getSanitisedStyles = styles => { - return { - ...styles, - normal: { - ...styles?.normal, - height: undefined, - }, - } - } - onMount(() => { gridContext = grid.getContext() }) -
- + +
onRowClick?.({ row: e.detail })} /> - -
+
+ diff --git a/packages/frontend-core/src/components/grid/layout/Grid.svelte b/packages/frontend-core/src/components/grid/layout/Grid.svelte index 23f61b424f..2a7624d271 100644 --- a/packages/frontend-core/src/components/grid/layout/Grid.svelte +++ b/packages/frontend-core/src/components/grid/layout/Grid.svelte @@ -1,6 +1,6 @@