@tscircuit/capacity-autorouter 0.0.36 → 0.0.38

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.
package/dist/index.js CHANGED
@@ -7,6 +7,7 @@ var combineVisualizations = (...visualizations) => {
7
7
  rects: []
8
8
  };
9
9
  visualizations.forEach((viz, i) => {
10
+ if (!viz) return;
10
11
  if (viz.lines) {
11
12
  combined.lines = [
12
13
  ...combined.lines || [],
@@ -2320,7 +2321,7 @@ var SingleHighDensityRouteSolver = class extends BaseSolver {
2320
2321
  goalDist,
2321
2322
  currentNode.z === this.B.z
2322
2323
  );
2323
- if (goalDist <= this.cellStep && currentNode.z === this.B.z) {
2324
+ if (goalDist <= this.cellStep * Math.SQRT2 && currentNode.z === this.B.z) {
2324
2325
  this.solved = true;
2325
2326
  this.setSolvedPath(currentNode);
2326
2327
  }