diff --git a/common/changes/@itwin/imodel-browser-react/omar-fix-cursor-row-clickable_2025-10-09-13-29.json b/common/changes/@itwin/imodel-browser-react/omar-fix-cursor-row-clickable_2025-10-09-13-29.json new file mode 100644 index 00000000..f0ad6837 --- /dev/null +++ b/common/changes/@itwin/imodel-browser-react/omar-fix-cursor-row-clickable_2025-10-09-13-29.json @@ -0,0 +1,10 @@ +{ + "changes": [ + { + "packageName": "@itwin/imodel-browser-react", + "comment": "Fix: Cursor pointer on clickable rows in table", + "type": "patch" + } + ], + "packageName": "@itwin/imodel-browser-react" +} \ No newline at end of file diff --git a/packages/modules/imodel-browser/src/containers/ITwinGrid/ITwinGrid.scss b/packages/modules/imodel-browser/src/containers/ITwinGrid/ITwinGrid.scss index ed2a80a4..3ec24211 100644 --- a/packages/modules/imodel-browser/src/containers/ITwinGrid/ITwinGrid.scss +++ b/packages/modules/imodel-browser/src/containers/ITwinGrid/ITwinGrid.scss @@ -16,7 +16,7 @@ } .row-cursor { - div[role="rowgroup"] div[role="row"] { + div[role="row"] { cursor: pointer; } } \ No newline at end of file diff --git a/packages/modules/imodel-browser/src/containers/ITwinGrid/ITwinGrid.tsx b/packages/modules/imodel-browser/src/containers/ITwinGrid/ITwinGrid.tsx index d11c39dd..7128c0b3 100644 --- a/packages/modules/imodel-browser/src/containers/ITwinGrid/ITwinGrid.tsx +++ b/packages/modules/imodel-browser/src/containers/ITwinGrid/ITwinGrid.tsx @@ -251,7 +251,6 @@ export const ITwinGrid = ({ ) : ( - className={onThumbnailClick ? "row-cursor" : ""} columns={columns} data={iTwins} onRowClick={onRowClick} @@ -264,6 +263,7 @@ export const ITwinGrid = ({ onBottomReached={fetchMore} autoResetFilters={false} autoResetSortBy={false} + bodyProps={{ className: onThumbnailClick ? "row-cursor" : "" }} /> ); diff --git a/packages/modules/imodel-browser/src/containers/iModelGrid/IModelGrid.module.scss b/packages/modules/imodel-browser/src/containers/iModelGrid/IModelGrid.module.scss index a09784c7..a08719fa 100644 --- a/packages/modules/imodel-browser/src/containers/iModelGrid/IModelGrid.module.scss +++ b/packages/modules/imodel-browser/src/containers/iModelGrid/IModelGrid.module.scss @@ -3,7 +3,7 @@ * See LICENSE.md in the project root for license terms and full copyright notice. *--------------------------------------------------------------------------------------------*/ .rowCursor { - div[role="rowgroup"] div[role="row"] { + div[role="row"] { cursor: pointer; } } \ No newline at end of file diff --git a/packages/modules/imodel-browser/src/containers/iModelGrid/IModelGrid.tsx b/packages/modules/imodel-browser/src/containers/iModelGrid/IModelGrid.tsx index 2ef7ffea..7626788b 100644 --- a/packages/modules/imodel-browser/src/containers/iModelGrid/IModelGrid.tsx +++ b/packages/modules/imodel-browser/src/containers/iModelGrid/IModelGrid.tsx @@ -252,7 +252,6 @@ export const IModelGrid = ({ ) : ( - className={onThumbnailClick ? styles.rowCursor : ""} columns={columns} data={iModels} onRowClick={onRowClick} @@ -283,6 +282,9 @@ export const IModelGrid = ({ onBottomReached={fetchMore} autoResetFilters={false} autoResetSortBy={false} + bodyProps={{ + className: onThumbnailClick ? styles.rowCursor : "", + }} /> )}