From 1489396c84356fb6226290438ce805c209ef650a Mon Sep 17 00:00:00 2001 From: Robert Jaszczurek <92210485+rbrtj@users.noreply.github.com> Date: Mon, 14 Oct 2024 17:01:36 +0200 Subject: [PATCH] [ML] Transforms: Pagination in the source documents data grid fix (#196119) ## Summary Fix for: [#195881](https://github.com/elastic/kibana/issues/195881) After: It's hardly visible in the recording, but if you look at the `@timestamp` column, you can see that the values are changing correctly while navigating to a previous page, which was not the case before the fix. https://github.com/user-attachments/assets/33be9e8c-e558-4f48-994a-562c4e3788de --- x-pack/plugins/transform/public/app/hooks/use_index_data.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/x-pack/plugins/transform/public/app/hooks/use_index_data.ts b/x-pack/plugins/transform/public/app/hooks/use_index_data.ts index 5732a0a747c93..fb2b3628f105f 100644 --- a/x-pack/plugins/transform/public/app/hooks/use_index_data.ts +++ b/x-pack/plugins/transform/public/app/hooks/use_index_data.ts @@ -196,7 +196,7 @@ export const useIndexData = (options: UseIndexDataOptions): UseIndexDataReturnTy setStatus(INDEX_STATUS.LOADED); } // eslint-disable-next-line react-hooks/exhaustive-deps - }, [dataGridDataError, dataGridDataIsError, dataGridDataIsLoading]); + }, [dataGridDataError, dataGridDataIsError, dataGridDataIsLoading, dataGridData]); const allDataViewFieldNames = new Set(dataView.fields.map((f) => f.name)); const { error: histogramsForFieldsError, data: histogramsForFieldsData } =