From 6909547bb8b82d873a06a9331ad4e8f4ac696c90 Mon Sep 17 00:00:00 2001 From: melloware Date: Sat, 18 Nov 2023 16:15:59 -0500 Subject: [PATCH] Fix #5342: Checkbox selection prevent onRowClick --- components/lib/datatable/TableBody.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/components/lib/datatable/TableBody.js b/components/lib/datatable/TableBody.js index 427c7c8f7e..0c22e16ce2 100644 --- a/components/lib/datatable/TableBody.js +++ b/components/lib/datatable/TableBody.js @@ -471,10 +471,12 @@ export const TableBody = React.memo( }; const onRowClick = (event) => { - if (allowCellSelection() || !allowSelection(event) || event.defaultPrevented) { + if (allowCellSelection() || !allowSelection(event) || event.defaultPrevented || event.originalEvent.defaultPrevented) { return; } + console.log('OnClick'); + props.onRowClick && props.onRowClick(event); if (allowRowSelection()) {