@camunda/linting 3.5.0 → 3.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -24,9 +24,7 @@ export default class Linting {
24
24
 
25
25
  const element = this._elementRegistry.get(id);
26
26
 
27
- if (element !== this._canvas.getRootElement() && needsScrollToElement(this._canvas, element)) {
28
- this._canvas.scrollToElement(element);
29
- }
27
+ this._canvas.scrollToElement(element);
30
28
 
31
29
  if (element !== this._canvas.getRootElement()) {
32
30
  this._selection.select(element);
@@ -108,12 +106,3 @@ Linting.$inject = [
108
106
  function isLabel(element) {
109
107
  return !!element.labelTarget;
110
108
  }
111
-
112
- function needsScrollToElement(canvas, element) {
113
- const viewbox = canvas.viewbox();
114
-
115
- return viewbox.x > element.x
116
- || viewbox.y > element.y
117
- || viewbox.x + viewbox.width < element.x + element.width
118
- || viewbox.y + viewbox.height < element.y + element.height;
119
- }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camunda/linting",
3
- "version": "3.5.0",
3
+ "version": "3.5.1",
4
4
  "description": "Linting for Camunda Platform",
5
5
  "main": "index.js",
6
6
  "scripts": {