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

Additional expanded rows rendered in data table using virtual lists #2631

Closed
Riskun87 opened this issue Mar 14, 2022 · 0 comments · Fixed by #2633
Closed

Additional expanded rows rendered in data table using virtual lists #2631

Riskun87 opened this issue Mar 14, 2022 · 0 comments · Fixed by #2633
Assignees
Labels
bug Something isn't working

Comments

@Riskun87
Copy link

TuSimple/naive-ui version (版本)

2.26.4

Vue version (Vue 版本)

3.2.31

Browser and its version (浏览器及其版本)

Chrome(99.0.4844.51)

System and its version (系统及其版本)

Windows 11

Node version (Node 版本)

Reappearance link (重现链接)

https://codesandbox.io/s/inspiring-feynman-hw9hqp

Reappearance steps (重现步骤)

Expand any row except of the first one and scroll down and up again.

Expected results (期望的结果)

Expanded row is rendered in correct position.

Actual results (实际的结果)

Expanded row not only rendered on the correct position, but also on the very first position of the virtual list (and stays there even when scrolling up and down). The more you scroll up and down the more duplicated rows are added until to the point you don't see anything else except of those rows. Seems only to work correctly when expanding the first row.

Also the console shows a warning as soon as a row gets expanded and you scroll a bit:
[Vue warn]: Duplicate keys found during update: 1 Make sure keys are unique.
at <Anonymous class="v-vl-visible-items" style= {transform: 'translateY(47.390625px)'} clsPrefix="n" ... >
at <ResizeObserver onResize=fn >
at <VirtualList ref="virtualListRef" items=

Remarks (补充说明)

@github-actions github-actions bot added the untriaged need to sort label Mar 14, 2022
@XieZongChen XieZongChen added bug Something isn't working and removed untriaged need to sort labels Mar 15, 2022
@XieZongChen XieZongChen self-assigned this Mar 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants