@tscircuit/core 0.0.648 → 0.0.650

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.d.ts CHANGED
@@ -11,7 +11,7 @@ import { CircuitJsonUtilObjects } from '@tscircuit/circuit-json-util';
11
11
  import { ConnectivityMap } from 'circuit-json-to-connectivity-map';
12
12
  import { GraphicsObject } from 'graphics-debug';
13
13
 
14
- declare const orderedRenderPhases: readonly ["ReactSubtreesRender", "PcbFootprintStringRender", "InitializePortsFromChildren", "CreateNetsFromProps", "CreateTracesFromProps", "CreateTracesFromNetLabels", "CreateTraceHintsFromProps", "SourceGroupRender", "AssignNameToUnnamedComponents", "SourceRender", "SourceParentAttachment", "PortMatching", "OptimizeSelectorCache", "SourceTraceRender", "SourceAddConnectivityMapKey", "SimulationRender", "SchematicComponentRender", "SchematicPortRender", "SchematicPrimitiveRender", "SchematicLayout", "SchematicTraceRender", "SchematicReplaceNetLabelsWithSymbols", "PcbComponentRender", "PcbPrimitiveRender", "PcbFootprintLayout", "PcbPortRender", "PcbPortAttachment", "PcbComponentSizeCalculation", "PcbLayout", "PcbBoardAutoSize", "PcbTraceHintRender", "PcbManualTraceRender", "PcbTraceRender", "PcbRouteNetIslands", "PcbDesignRuleChecks", "CadModelRender", "PartsEngineRender"];
14
+ declare const orderedRenderPhases: readonly ["ReactSubtreesRender", "PcbFootprintStringRender", "InitializePortsFromChildren", "CreateNetsFromProps", "AssignFallbackProps", "CreateTracesFromProps", "CreateTracesFromNetLabels", "CreateTraceHintsFromProps", "SourceGroupRender", "AssignNameToUnnamedComponents", "SourceRender", "SourceParentAttachment", "PortMatching", "OptimizeSelectorCache", "SourceTraceRender", "SourceAddConnectivityMapKey", "SimulationRender", "SchematicComponentRender", "SchematicPortRender", "SchematicPrimitiveRender", "SchematicLayout", "SchematicTraceRender", "SchematicReplaceNetLabelsWithSymbols", "PcbComponentRender", "PcbPrimitiveRender", "PcbFootprintLayout", "PcbPortRender", "PcbPortAttachment", "PcbComponentSizeCalculation", "PcbLayout", "PcbBoardAutoSize", "PcbTraceHintRender", "PcbManualTraceRender", "PcbTraceRender", "PcbRouteNetIslands", "PcbDesignRuleChecks", "CadModelRender", "PartsEngineRender"];
15
15
  type RenderPhase = (typeof orderedRenderPhases)[number];
16
16
  type RenderPhaseFn<K extends RenderPhase = RenderPhase> = `doInitial${K}` | `update${K}` | `remove${K}`;
17
17
  type RenderPhaseStates = Record<RenderPhase, {
@@ -1084,6 +1084,7 @@ declare class NormalComponent<ZodProps extends z.ZodType = any, PortNames extend
1084
1084
  private _getSupplierPartNumbers;
1085
1085
  doInitialPartsEngineRender(): void;
1086
1086
  updatePartsEngineRender(): void;
1087
+ doInitialAssignFallbackProps(): void;
1087
1088
  doInitialCreateTracesFromProps(): void;
1088
1089
  _createTracesFromConnectionsProp(): void;
1089
1090
  }
package/dist/index.js CHANGED
@@ -87,6 +87,7 @@ var orderedRenderPhases = [
87
87
  "PcbFootprintStringRender",
88
88
  "InitializePortsFromChildren",
89
89
  "CreateNetsFromProps",
90
+ "AssignFallbackProps",
90
91
  "CreateTracesFromProps",
91
92
  "CreateTracesFromNetLabels",
92
93
  "CreateTraceHintsFromProps",
@@ -7011,6 +7012,12 @@ var NormalComponent = class extends PrimitiveComponent2 {
7011
7012
  return;
7012
7013
  }
7013
7014
  }
7015
+ doInitialAssignFallbackProps() {
7016
+ const { _parsedProps: props } = this;
7017
+ if (props.connections && !this.name) {
7018
+ this.fallbackUnassignedName = this.getSubcircuit().getNextAvailableName(this);
7019
+ }
7020
+ }
7014
7021
  doInitialCreateTracesFromProps() {
7015
7022
  this._createTracesFromConnectionsProp();
7016
7023
  }
@@ -7829,12 +7836,8 @@ var normalizePinLabels = (inputPinLabels) => {
7829
7836
  };
7830
7837
 
7831
7838
  // lib/components/primitive-components/Group/Group_doInitialSchematicLayoutMatchAdapt.ts
7832
- import { corpusNoNetLabel } from "@tscircuit/schematic-corpus";
7833
7839
  import { convertCircuitJsonToBpc } from "circuit-json-to-bpc";
7834
- import {
7835
- getGraphicsForBpcGraph,
7836
- layoutSchematicGraphVariants
7837
- } from "bpc-graph";
7840
+ import { getGraphicsForBpcGraph, layoutSchematicGraphVariants } from "bpc-graph";
7838
7841
  import Debug5 from "debug";
7839
7842
  import { buildSubtree } from "@tscircuit/circuit-json-util";
7840
7843
  var debug4 = Debug5("Group_doInitialSchematicLayoutMatchAdapt");
@@ -7887,7 +7890,7 @@ function Group_doInitialSchematicLayoutMatchAdapt(group) {
7887
7890
  return false;
7888
7891
  }).map((b) => b.boxId)
7889
7892
  ),
7890
- corpus: corpusNoNetLabel
7893
+ corpus: {}
7891
7894
  }
7892
7895
  );
7893
7896
  if (debug4.enabled) {
@@ -13670,7 +13673,7 @@ import { identity as identity5 } from "transformation-matrix";
13670
13673
  var package_default = {
13671
13674
  name: "@tscircuit/core",
13672
13675
  type: "module",
13673
- version: "0.0.647",
13676
+ version: "0.0.649",
13674
13677
  types: "dist/index.d.ts",
13675
13678
  main: "dist/index.js",
13676
13679
  module: "dist/index.js",
@@ -13711,7 +13714,6 @@ var package_default = {
13711
13714
  "@tscircuit/miniflex": "^0.0.4",
13712
13715
  "@tscircuit/props": "^0.0.287",
13713
13716
  "@tscircuit/schematic-autolayout": "^0.0.6",
13714
- "@tscircuit/schematic-corpus": "^0.0.110",
13715
13717
  "@tscircuit/schematic-match-adapt": "^0.0.16",
13716
13718
  "@tscircuit/schematic-trace-solver": "^0.0.12",
13717
13719
  "@tscircuit/simple-3d-svg": "^0.0.38",
@@ -13754,7 +13756,6 @@ var package_default = {
13754
13756
  "@tscircuit/props": "*",
13755
13757
  "@tscircuit/schematic-autolayout": "*",
13756
13758
  "@tscircuit/schematic-match-adapt": "*",
13757
- "@tscircuit/schematic-corpus": "*",
13758
13759
  "circuit-json-to-bpc": "*",
13759
13760
  "bpc-graph": "*",
13760
13761
  "@tscircuit/matchpack": "*",
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@tscircuit/core",
3
3
  "type": "module",
4
- "version": "0.0.648",
4
+ "version": "0.0.650",
5
5
  "types": "dist/index.d.ts",
6
6
  "main": "dist/index.js",
7
7
  "module": "dist/index.js",
@@ -42,7 +42,6 @@
42
42
  "@tscircuit/miniflex": "^0.0.4",
43
43
  "@tscircuit/props": "^0.0.287",
44
44
  "@tscircuit/schematic-autolayout": "^0.0.6",
45
- "@tscircuit/schematic-corpus": "^0.0.110",
46
45
  "@tscircuit/schematic-match-adapt": "^0.0.16",
47
46
  "@tscircuit/schematic-trace-solver": "^0.0.12",
48
47
  "@tscircuit/simple-3d-svg": "^0.0.38",
@@ -85,7 +84,6 @@
85
84
  "@tscircuit/props": "*",
86
85
  "@tscircuit/schematic-autolayout": "*",
87
86
  "@tscircuit/schematic-match-adapt": "*",
88
- "@tscircuit/schematic-corpus": "*",
89
87
  "circuit-json-to-bpc": "*",
90
88
  "bpc-graph": "*",
91
89
  "@tscircuit/matchpack": "*",