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

Event onEnd from ItemResizing plugin triggers twice when resize from start time #223

Open
danilolima opened this issue Dec 20, 2020 · 1 comment

Comments

@danilolima
Copy link

Describe the bug
When I resize the item from the end time the onEnd event triggers once, but triggers twice when resize from start time.

gantt-schedule-timeline-calendar version
3.6.6

@3h3c
Copy link

3h3c commented Apr 15, 2022

I found out the problem. I think you will see the failure ;)

onPointerUp() {
"resize" === this.data.state && (this.data.state = "end"),
this.onLeftPointerUp(),
this.onRightPointerUp(),
this.onEnd(),
this.updateData(),
this.api.plugins.TimelinePointer.unlock("down"),
this.api.plugins.TimelinePointer.unlock("move"),
this.api.plugins.TimelinePointer.unlock("up")
}
onLeftPointerUp() {
document.body.classList.remove(this.data.bodyClassLeft),
this.data.enabled && this.data.leftIsMoving && (this.data.leftIsMoving = !1,
this.onEnd(),
this.updateData())
}
onRightPointerUp() {
document.body.classList.remove(this.data.bodyClassRight),
this.data.enabled && this.data.rightIsMoving && (this.data.rightIsMoving = !1)
}

@neuronetio it would be nice when you can fix it ;)

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

No branches or pull requests

3 participants