Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add check for undefined header in Column resizer #1156

Merged
merged 9 commits into from
May 10, 2023
5 changes: 5 additions & 0 deletions .changeset/hip-suns-repeat.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@itwin/itwinui-react': patch
---

Fixes an issue where table crashes when resizing the Column Manager column in expand mode.
Original file line number Diff line number Diff line change
Expand Up @@ -496,6 +496,9 @@ function getLeafHeaders(header: HeaderGroup) {
const getHeaderWidth = <T extends Record<string, unknown>>(
header: ColumnInstance<T>,
) => {
if (!header) {
return 0;
}
return Number(header.width || header.resizeWidth || 0);
};

Expand Down