From 3066784d9127b3a2056af00960958a349885ee75 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Lemayian=20=E2=9C=A8?= <877919+DavidLemayian@users.noreply.github.com> Date: Thu, 27 Apr 2023 14:41:40 +0300 Subject: [PATCH] fix: also use column.groupTitle check if column.groupTitle is set as a function and use it --- src/components/MTableGroupRow/index.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/components/MTableGroupRow/index.js b/src/components/MTableGroupRow/index.js index 1d1160b8..c8dc4c14 100644 --- a/src/components/MTableGroupRow/index.js +++ b/src/components/MTableGroupRow/index.js @@ -118,6 +118,8 @@ function MTableGroupRow(props) { let title = column.title; if (typeof options.groupTitle === 'function') { title = options.groupTitle(props.groupData); + } else if (typeof column.groupTitle === 'function') { + title = column.groupTitle(props.groupData); } else if (typeof title !== 'string') { title = React.cloneElement(title); }