OnColumnResize DataGrid#2963
Conversation
* onColumnResize DataGrid prop * onColumnResize test * simple console log callback for datagrid example
|
Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually? |
|
💚 CLA has been signed |
|
@jvince I've held off reviewing this as it was opened as a Draft; is this ready to be looked at? |
Yes, it is ready to be looked at. I would have a question: I'm not sure if it's safe to call a callback function in Is it enough to pass columnId and width on the column resize? interface |
chandlerprall
left a comment
There was a problem hiding this comment.
One small request on a name, one question, and also:
Please add an entry to CHANGELOG.md, something like this existing entry:
- Added
isSortableprops toEuiDataGridColumnandEuiDataGridSchemaDetectorto mark them as un-sortable (#2952)
* Renamed `EuiDataGridOnColumnResizeEvent` to `EuiDataGridOnColumnResizeHandler` for clarity * Renamed `EuiDataGridColumnResizeEventData` to `EuiDataGridOnColumnResizeData` for clarity * Removed useCallback `setColumnWidth`
chandlerprall
left a comment
There was a problem hiding this comment.
Changes LGTM; Pulled & tested locally
|
jenkins test this |
|
Fixed CL conflict. Will merge on green. Thank you for the sub. |
|
Preview documentation changes for this PR: https://eui.elastic.co/pr_2963/ |
|
jenkins test this Looks like a flaky unit test failed |
|
Preview documentation changes for this PR: https://eui.elastic.co/pr_2963/ |
|
Thanks @jvince ! |
Summary
Provide capability to be able to react when the DataGrid column size changes. Possible use case would be for example storing column widths into the local storage.
Checklist