-
Notifications
You must be signed in to change notification settings - Fork 80
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Datagrid close detail issues error for nested datagrids: row.cells.get(...) is undefined #1485
Comments
Hi there 👋, this is an automated message. To help Clarity keep track of discussions, we automatically lock closed issues after 14 days. Please look for another open issue or open a new issue with updated details and reference this one as necessary. |
dtsanevmw
pushed a commit
that referenced
this issue
Nov 18, 2024
…ackport to 16.x) (#1619) Backport 6c4b36e from #1489. <br> This change prevents propagation of cell rendering changes to rows owned by nested datagrids. CDE-2199 closes #1485 ## PR Checklist - [x] Tests for the changes have been added (for bug fixes / features) - [N/A] Docs have been added / updated (for bug fixes / features) - [N/A] If applicable, have a visual design approval ## PR Type Bugfix ## What is the current behavior? If the detail pane of a datagrid contains another datagrid with less columns than the outer datagrid, closing the detail pane results in the error: `row.cells.get(...) is undefined`. Issue Number: #1485, CDE-2199 ## What is the new behavior? No error is thrown, and the correct cells are hidden. ## Does this PR introduce a breaking change? No. Co-authored-by: Kevin Buhmann <kbuhmann@vmware.com>
# for free
to subscribe to this conversation on GitHub.
Already have an account?
#.
Describe the bug
If the detail pane of a datagrid contains another datagrid with less columns than the outer datagrid, closing the detail pane results in the error:
row.cells.get(...) is undefined
.In particular the error is thrown at the location
projects/angular/src/data/datagrid/render/main-renderer.ts:249
(accessed at: c791ff0) since therows
query list contains not only the rows of the outer datagrid but also the rows of the inner one. As the inner grid does not have as many columns as the outer one, the failing index is out of bounds.The
@ContentChildren(DatagridRowRenderer, { descendants: true })
content selector selects all rows, not only the rows which belong to the current (outer) datagrid.Presumably this issue was introduced with #1346 (ac0d4cf)
How to reproduce
See StackBlitz Example
Steps to reproduce the behavior:
Expected behavior
The datagrid should not throw an error for nested datagrids on closing the row detail.
Versions
Clarity version:
Framework version:
Angular 17
Device:
The text was updated successfully, but these errors were encountered: