From d015c4cfb66951bdf8b2bc06b80b83d666ee3b97 Mon Sep 17 00:00:00 2001 From: Ersin Erdal Date: Mon, 10 Jan 2022 20:56:35 +0100 Subject: [PATCH] use the new row height (28) --- .../public/components/t_grid/body/height_hack.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/x-pack/plugins/timelines/public/components/t_grid/body/height_hack.ts b/x-pack/plugins/timelines/public/components/t_grid/body/height_hack.ts index 130b1b6720ed2d..b09adc940cf8a3 100644 --- a/x-pack/plugins/timelines/public/components/t_grid/body/height_hack.ts +++ b/x-pack/plugins/timelines/public/components/t_grid/body/height_hack.ts @@ -11,10 +11,10 @@ import { useState, useLayoutEffect } from 'react'; // rowHeight * pageSize + (filtersHeight + headerHeight + paginationHeight + 1) // +1 is for useLayoutEffect to detect the change const DATA_GRID_HEIGHT_BY_PAGE_SIZE: { [key: number]: number } = { - 10: 449, - 25: 959, - 50: 1809, - 100: 3509, + 10: 389, + 25: 809, + 50: 1509, + 100: 2909, }; /** @@ -30,7 +30,7 @@ const DATA_GRID_HEIGHT_BY_PAGE_SIZE: { [key: number]: number } = { const filtersHeight = 32; const headerHeight = 40; const paginationHeight = 36; -const rowHeight = 34; +const rowHeight = 28; export const useDataGridHeightHack = (pageSize: number, rowCount: number) => { const [height, setHeight] = useState(DATA_GRID_HEIGHT_BY_PAGE_SIZE[pageSize]);