@tscircuit/core 0.0.1136 → 0.0.1138

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.
Files changed (2) hide show
  1. package/dist/index.js +15 -7
  2. package/package.json +2 -2
package/dist/index.js CHANGED
@@ -12377,12 +12377,19 @@ var TscircuitAutorouter = class {
12377
12377
  if (this.isRouting) return;
12378
12378
  this.isRouting = true;
12379
12379
  this.cycleCount = 0;
12380
- this.runCycleAndQueueNextCycle();
12380
+ void this.runCycleAndQueueNextCycle();
12381
+ }
12382
+ async stepSolver() {
12383
+ if ("stepAsync" in this.solver && typeof this.solver.stepAsync === "function") {
12384
+ await this.solver.stepAsync();
12385
+ return;
12386
+ }
12387
+ this.solver.step();
12381
12388
  }
12382
12389
  /**
12383
12390
  * Execute the next routing step and schedule the following one if needed
12384
12391
  */
12385
- runCycleAndQueueNextCycle() {
12392
+ async runCycleAndQueueNextCycle() {
12386
12393
  if (!this.isRouting) return;
12387
12394
  try {
12388
12395
  if (this.solver.solved || this.solver.failed) {
@@ -12403,7 +12410,7 @@ var TscircuitAutorouter = class {
12403
12410
  const startTime = Date.now();
12404
12411
  const startIterations = this.solver.iterations;
12405
12412
  while (Date.now() - startTime < 250 && !this.solver.failed && !this.solver.solved) {
12406
- this.solver.step();
12413
+ await this.stepSolver();
12407
12414
  }
12408
12415
  const iterationsPerSecond = (this.solver.iterations - startIterations) / (Date.now() - startTime) * 1e3;
12409
12416
  this.cycleCount++;
@@ -12419,12 +12426,12 @@ var TscircuitAutorouter = class {
12419
12426
  });
12420
12427
  if (this.stepDelay > 0) {
12421
12428
  this.timeoutId = setTimeout(
12422
- () => this.runCycleAndQueueNextCycle(),
12429
+ () => void this.runCycleAndQueueNextCycle(),
12423
12430
  this.stepDelay
12424
12431
  );
12425
12432
  } else {
12426
12433
  this.timeoutId = setTimeout(
12427
- () => this.runCycleAndQueueNextCycle(),
12434
+ () => void this.runCycleAndQueueNextCycle(),
12428
12435
  0
12429
12436
  );
12430
12437
  }
@@ -18738,7 +18745,7 @@ import { identity as identity5 } from "transformation-matrix";
18738
18745
  var package_default = {
18739
18746
  name: "@tscircuit/core",
18740
18747
  type: "module",
18741
- version: "0.0.1135",
18748
+ version: "0.0.1137",
18742
18749
  types: "dist/index.d.ts",
18743
18750
  main: "dist/index.js",
18744
18751
  module: "dist/index.js",
@@ -18770,7 +18777,7 @@ var package_default = {
18770
18777
  "@biomejs/biome": "^1.8.3",
18771
18778
  "@resvg/resvg-js": "^2.6.2",
18772
18779
  "@tscircuit/alphabet": "0.0.25",
18773
- "@tscircuit/capacity-autorouter": "^0.0.398",
18780
+ "@tscircuit/capacity-autorouter": "^0.0.400",
18774
18781
  "@tscircuit/checks": "0.0.115",
18775
18782
  "@tscircuit/circuit-json-util": "^0.0.90",
18776
18783
  "@tscircuit/common": "^0.0.20",
@@ -22732,6 +22739,7 @@ var Connector = class extends Chip {
22732
22739
  if (!fetchPartCircuitJson) return;
22733
22740
  this._hasStartedFootprintUrlLoad = true;
22734
22741
  const sourceComponentForQuery = {
22742
+ type: "source_component",
22735
22743
  ftype: "simple_connector",
22736
22744
  name: this.name,
22737
22745
  manufacturer_part_number: props.manufacturerPartNumber ?? props.mfn,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@tscircuit/core",
3
3
  "type": "module",
4
- "version": "0.0.1136",
4
+ "version": "0.0.1138",
5
5
  "types": "dist/index.d.ts",
6
6
  "main": "dist/index.js",
7
7
  "module": "dist/index.js",
@@ -33,7 +33,7 @@
33
33
  "@biomejs/biome": "^1.8.3",
34
34
  "@resvg/resvg-js": "^2.6.2",
35
35
  "@tscircuit/alphabet": "0.0.25",
36
- "@tscircuit/capacity-autorouter": "^0.0.398",
36
+ "@tscircuit/capacity-autorouter": "^0.0.400",
37
37
  "@tscircuit/checks": "0.0.115",
38
38
  "@tscircuit/circuit-json-util": "^0.0.90",
39
39
  "@tscircuit/common": "^0.0.20",