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

nz-tree-view 在 OnPush 模式下,删除末尾 leaf 之后,左侧 Indent line 显示异常 #6714

Closed
msyesyan opened this issue May 25, 2021 · 1 comment · Fixed by #6736
Assignees

Comments

@msyesyan
Copy link
Contributor

Reproduction link

https://stackblitz.com/edit/ng-zorro-antd-ivy-jyonfj?file=src%2Fapp%2Fapp.component.ts

Steps to reproduce

直接点击按钮 “删除末尾孩子结点”。 就可以发现结点删除之后,左侧的 indentline 没有更新为 last 的状态

What is expected?

期望左侧删除线可以正确更新

What is actually happening?

左侧删除线没有正确更新

Environment Info
ng-zorro-antd 11.4.1
Browser Chrome version 90.0.4430.212 (Official Build) (x86_64)

  1. 在 Default 策略下是没问题
  2. 曾经尝试过直接在 ng-zorro-antd 下启动 npm run start, 然后加了一个 demo 尝试去修复,发现同样的代码在这里启动就是正确的,所以本人也不知道该如何去 debug 了
  3. 我们的实际使用场景,不是直接去操作树,而是树作为 form 的一个展示。所以 demo 中的 button 用来模拟实际使用中 form 的变化
@zorro-bot
Copy link

zorro-bot bot commented May 25, 2021

Translation of this issue:

NZ-Tree-View In OnPush mode, after deleting the end Leaf, the left index is abnormal.

reproduction link

[https://stackblitz.com/Edit/ng- Zorro-antd-ivy-jyonfj?file=src%2fapp%2fapp.component.ts](https://stackblitz.com/edit/ng- ze- anan- Ivy-jyonfj? file = src% 2FAPP% 2Fapp.component.ts)

steps to reproduce

Click on the button "Delete the end of the child." You can find that the index is deleted, the indeantline on the left is not updated to the LAST.

What is expected?

Desire to delete lines on the left can be updated correctly

What is actually happens?

The left delete line is not updated correctly

ENVIRONMENT INFO
Ng-Zorro-ANTD 11.4.1
Browser Chrome Version 90.0.4430.212 (OFFICIAL Build) (x86_64)

  1. It is no problem under the Default policy.
  2. I have tried to start the `npm run start under Ng-Zorro-ANTD, and then add a demo to try to fix it, find that the same code is starting here, so I don't know how to go Debug.
  3. Our actual use scenario, not directly operating the tree, but tree as a show for Form. So the Button in DEMO is used to simulate changes in FORM in actual use.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants