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

History does not work with vertices #3327

Closed
bodinsamuel opened this issue Mar 1, 2023 · 3 comments · Fixed by #3765
Closed

History does not work with vertices #3327

bodinsamuel opened this issue Mar 1, 2023 · 3 comments · Fixed by #3765
Labels
type: feature 新功能 Feature/enhancement requests

Comments

@bodinsamuel
Copy link
Contributor

Describe the bug

Hey,

When using the History Plugin, it realised the vertices event are received by the beforeAddCommand but they are not actually handled by the plugin. Maybe it's a limitation of the plugin which would be sad, but maybe it's just a mistake.

Currently when we add/remove vertices they are ignored by the undo/redo feature.

PS: the function beforeAddCommand sometimes receive one argument and sometimes two, but not the same order, which makes it harder to use and I didn't understand why.

Your Example Website or App

https://codesandbox.io/s/new-sky-n37gp1?file=/src/app.tsx

Steps to Reproduce the Bug or Issue

  1. Add a vertice
  2. Click undo
  3. The step before the vertice is undo but not the vertice

Expected behavior

The vertice add/remove should be part of the stack.

Screenshots or Videos

Screen.Recording.2023-03-01.at.14.07.27.mov

Platform

  • OS: macOS
  • Browser: Chrome
  • Version: 110

Additional context

No response

@x6-bot
Copy link
Contributor

x6-bot bot commented Mar 1, 2023

👋 @bodinsamuel

Thanks for opening your first issue here! If you're reporting a 🐞 bug, please make sure you include steps to reproduce it.
To help make it easier for us to investigate your issue, please follow the contributing guidelines.
We get a lot of issues on this repo, so please be patient and we will get back to you as soon as we can.

@NewByVector NewByVector added the type: feature 新功能 Feature/enhancement requests label Mar 2, 2023
@NewByVector
Copy link
Contributor

Please upgrade to @antv/[email protected].

@x6-bot
Copy link
Contributor

x6-bot bot commented Jul 12, 2024

This thread has been automatically locked because it has not had recent activity.

Please open a new issue for related bugs and link to relevant comments in this thread.

@x6-bot x6-bot bot locked as resolved and limited conversation to collaborators Jul 12, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
type: feature 新功能 Feature/enhancement requests
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants