Skip to content

Control sorting through props for iTwin and iModel tables#223

Open
arome wants to merge 4 commits into
mainfrom
omar/save-sort-imodel-table
Open

Control sorting through props for iTwin and iModel tables#223
arome wants to merge 4 commits into
mainfrom
omar/save-sort-imodel-table

Conversation

@arome

@arome arome commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Added the ability to control the sorting of the tables through props.
image

@arome arome changed the title Omar/save sort imodel table Save sort imodel table Jul 10, 2026
@arome arome marked this pull request as ready for review July 10, 2026 18:01
@arome arome changed the title Save sort imodel table Control sorting through props for iTwin and iModel tables Jul 10, 2026
@arome arome enabled auto-merge (squash) July 10, 2026 18:02
DataGrid,
GRID_DEFAULT_LOCALE_TEXT,
GridColDef,
GridSortModel,

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Given that we have such specific sort capabilities, do you think it would be better to define our own "sort model" data type, limited to our actual field names?

* Controlled sort model. When provided, the table's sort state is fully
* controlled by the parent and must be kept in sync via `onSortModelChange`.
*/
sortModel?: GridSortModel;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It looks like this just effects the table view, not the tile/card view. My initial thought is that would be good to keep sorting unified between both views. WDYT?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants