Skip to content
This repository has been archived by the owner on Jan 5, 2023. It is now read-only.

Expand table on column resize #824

Closed
bentleyvk opened this issue Sep 12, 2022 Discussed in #822 · 0 comments · Fixed by #835
Closed

Expand table on column resize #824

bentleyvk opened this issue Sep 12, 2022 Discussed in #822 · 0 comments · Fixed by #835
Assignees

Comments

@bentleyvk
Copy link
Contributor

We could have some flag that toggles resize mode like react-grid https://devexpress.github.io/devextreme-reactive/react/grid/docs/guides/column-resizing/#resizing-modes

Discussed in #822

Originally posted by HaveSpacesuit September 9, 2022
It is difficult to expand columns to a wide width. Currently it looks like when a column is resized, the next column loses or gains width based on the first column resize. The overall table width stays the same.

Column resize static

It would be nice to expand/shrink the entire table width when a column is resized. If I make column A bigger, I likely do not want to make column B smaller.

This should work in situations when the table has horizontal scroll and does not have horizontal scroll - adding or removing the scroll as needed.

Here is a sandbox showing that it is not easy to expand a column past the point where the next column is at minimum width. There are examples with and without horizontal scroll. (I usually have the last column width set to undefined in order to allow the table to fill horizontal space if the columns do not all fit.)

https://codesandbox.io/s/itwinui-react-minimal-example-forked-7wizuj?file=/src/columns.ts

Column width scroll

@bentleyvk bentleyvk self-assigned this Sep 14, 2022
@iTwin iTwin deleted a comment from FlyersPh9 Sep 21, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant