Skip to content

Commit

Permalink
fix: scroll endpoint pos bug
Browse files Browse the repository at this point in the history
  • Loading branch information
noonnightstorm committed Nov 25, 2021
1 parent f804c28 commit 5c1dafc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
@@ -1,6 +1,6 @@
{
"name": "butterfly-dag",
"version": "4.1.14",
"version": "4.1.15",
"description": "一个基于数据驱动的节点式编排组件库,让你有方便快捷定制可视化流程图表",
"main": "dist/index.js",
"es": "es/index.js",
Expand Down
4 changes: 2 additions & 2 deletions src/endpoint/baseEndpoint.js
Expand Up @@ -102,8 +102,8 @@ class BaseEndpoint extends Endpoint {
this._height = $(this.dom).outerHeight();

// 计算锚点起始值
this._left = this._coordinateService._terminal2canvas('x', $(this.dom).offset().left);
this._top = this._coordinateService._terminal2canvas('y', $(this.dom).offset().top);
this._left = this._coordinateService._terminal2canvas('x', $(this.dom).offset().left + this._coordinateService.scrollLeft);
this._top = this._coordinateService._terminal2canvas('y', $(this.dom).offset().top + this._coordinateService.scrollTop);

this._posLeft = this._left;
this._posTop = this._top;
Expand Down

0 comments on commit 5c1dafc

Please sign in to comment.