From 8b8a4b03eed53017e4bc579dc46aafae684f8a5f Mon Sep 17 00:00:00 2001 From: Andrew Cherniavskyi Date: Mon, 27 May 2024 21:00:43 +0200 Subject: [PATCH] fix methods names --- .../src/hooks/features/clipboard/useGridClipboardImport.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/grid/x-data-grid-premium/src/hooks/features/clipboard/useGridClipboardImport.ts b/packages/grid/x-data-grid-premium/src/hooks/features/clipboard/useGridClipboardImport.ts index 9b903dd6bf189..33c3110c6add0 100644 --- a/packages/grid/x-data-grid-premium/src/hooks/features/clipboard/useGridClipboardImport.ts +++ b/packages/grid/x-data-grid-premium/src/hooks/features/clipboard/useGridClipboardImport.ts @@ -220,8 +220,8 @@ function defaultPasteResolver({ }) { const isSingleValuePasted = pastedData.length === 1 && pastedData[0].length === 1; - const cellSelectionModel = apiRef.current.getCellSelectionModel(); - const selectedCellsArray = apiRef.current.getSelectedCellsAsArray(); + const cellSelectionModel = apiRef.current.unstable_getCellSelectionModel(); + const selectedCellsArray = apiRef.current.unstable_getSelectedCellsAsArray(); if (cellSelectionModel && selectedCellsArray.length > 1) { Object.keys(cellSelectionModel).forEach((rowId, rowIndex) => { const rowDataArr = pastedData[isSingleValuePasted ? 0 : rowIndex];