@tscircuit/core 0.0.983 → 0.0.985
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 +2 -1
- package/dist/index.js +61 -31
- package/package.json +3 -3
package/dist/index.d.ts
CHANGED
|
@@ -18,6 +18,7 @@ import { GraphicsObject } from 'graphics-debug';
|
|
|
18
18
|
|
|
19
19
|
declare const orderedRenderPhases: readonly ["ReactSubtreesRender", "InflateSubcircuitCircuitJson", "SourceNameDuplicateComponentRemoval", "PcbFootprintStringRender", "InitializePortsFromChildren", "CreateNetsFromProps", "AssignFallbackProps", "CreateTracesFromProps", "CreateTracesFromNetLabels", "CreateTraceHintsFromProps", "SourceGroupRender", "AssignNameToUnnamedComponents", "SourceRender", "SourceParentAttachment", "PortMatching", "OptimizeSelectorCache", "SourceTraceRender", "SourceAddConnectivityMapKey", "SourceDesignRuleChecks", "SimulationRender", "SchematicComponentRender", "SchematicPortRender", "SchematicPrimitiveRender", "SchematicComponentSizeCalculation", "SchematicLayout", "SchematicTraceRender", "SchematicReplaceNetLabelsWithSymbols", "PanelBoardLayout", "PcbComponentRender", "PcbPrimitiveRender", "PcbFootprintLayout", "PcbPortRender", "PcbPortAttachment", "PcbComponentSizeCalculation", "PcbComponentAnchorAlignment", "PcbLayout", "PcbBoardAutoSize", "PanelLayout", "PcbTraceHintRender", "PcbManualTraceRender", "PcbTraceRender", "PcbRouteNetIslands", "PcbCopperPourRender", "PcbDesignRuleChecks", "SilkscreenOverlapAdjustment", "CadModelRender", "PartsEngineRender", "SimulationSpiceEngineRender"];
|
|
20
20
|
type RenderPhase = (typeof orderedRenderPhases)[number];
|
|
21
|
+
declare const renderPhaseIndexMap: Map<"ReactSubtreesRender" | "InflateSubcircuitCircuitJson" | "SourceNameDuplicateComponentRemoval" | "PcbFootprintStringRender" | "InitializePortsFromChildren" | "CreateNetsFromProps" | "AssignFallbackProps" | "CreateTracesFromProps" | "CreateTracesFromNetLabels" | "CreateTraceHintsFromProps" | "SourceGroupRender" | "AssignNameToUnnamedComponents" | "SourceRender" | "SourceParentAttachment" | "PortMatching" | "OptimizeSelectorCache" | "SourceTraceRender" | "SourceAddConnectivityMapKey" | "SourceDesignRuleChecks" | "SimulationRender" | "SchematicComponentRender" | "SchematicPortRender" | "SchematicPrimitiveRender" | "SchematicComponentSizeCalculation" | "SchematicLayout" | "SchematicTraceRender" | "SchematicReplaceNetLabelsWithSymbols" | "PanelBoardLayout" | "PcbComponentRender" | "PcbPrimitiveRender" | "PcbFootprintLayout" | "PcbPortRender" | "PcbPortAttachment" | "PcbComponentSizeCalculation" | "PcbComponentAnchorAlignment" | "PcbLayout" | "PcbBoardAutoSize" | "PanelLayout" | "PcbTraceHintRender" | "PcbManualTraceRender" | "PcbTraceRender" | "PcbRouteNetIslands" | "PcbCopperPourRender" | "PcbDesignRuleChecks" | "SilkscreenOverlapAdjustment" | "CadModelRender" | "PartsEngineRender" | "SimulationSpiceEngineRender", number>;
|
|
21
22
|
type RenderPhaseFn<K extends RenderPhase = RenderPhase> = `doInitial${K}` | `update${K}` | `remove${K}`;
|
|
22
23
|
type RenderPhaseStates = Record<RenderPhase, {
|
|
23
24
|
initialized: boolean;
|
|
@@ -82669,4 +82670,4 @@ declare module "react/jsx-runtime" {
|
|
|
82669
82670
|
}
|
|
82670
82671
|
}
|
|
82671
82672
|
|
|
82672
|
-
export { AnalogSimulation, type AsyncEffect, type AutorouterCompleteEvent, type AutorouterErrorEvent, type AutorouterEvent, type AutorouterProgressEvent, type AutoroutingEndEvent, type AutoroutingErrorEvent, type AutoroutingProgressEvent, type AutoroutingStartEvent, Battery, Board, Breakout, BreakoutPoint, CadAssembly, CadModel, Capacitor, Chip, Circuit, type ComponentWithPins, Constraint, CopperPour, CopperText, Crystal, CurrentSource, Cutout, type DebugLogOutputEvent, Diode, FabricationNoteDimension, FabricationNotePath, FabricationNoteRect, FabricationNoteText, Fiducial, Footprint, Fuse, type GenericConnectionsAndSelectorsSel, type GenericLocalAutorouter, Group, Hole, type IRenderable, Inductor, Interconnect, Jumper, Keepout, Led, type LocalCacheEngine, Mosfet, Net, NetLabel, NormalComponent, type Obstacle, OpAmp, type PackingEndEvent, type PackingErrorEvent, type PackingStartEvent, Panel, PcbNoteDimension, PcbNoteLine, PcbNotePath, PcbNoteRect, PcbNoteText, PcbTrace, PinHeader, type PinLabelSpec, Pinout, PlatedHole, Port, Potentiometer, PowerSource, PrimitiveComponent, Project, PushButton, type RenderPhase, type RenderPhaseFn, type RenderPhaseFunctions, type RenderPhaseStates, Renderable, Resistor, Resonator, RootCircuit, type RootCircuitEventName, SOLVERS, SchematicArc, SchematicBox, SchematicCell, SchematicCircle, SchematicLine, SchematicPath, SchematicRect, SchematicRow, SchematicTable, SchematicText, type Sel, SilkscreenCircle, SilkscreenLine, SilkscreenPath, SilkscreenRect, SilkscreenText, type SimpleRouteConnection, type SimpleRouteJson, type SimplifiedPcbTrace, SmtPad, SolderJumper, type SolverName, type SolverStartedEvent, Subcircuit, Switch, SymbolComponent as Symbol, TestPoint, Trace, TraceHint, Transistor, Via, VoltageProbe, VoltageSource, applyEditEvents, applyEditEventsToManualEditsFile, applyPcbEditEventsToManualEditsFile, applySchematicEditEventsToManualEditsFile, createUseComponent, getPhaseTimingsFromRenderEvents, getSimpleRouteJsonFromCircuitJson, normalizePinLabels, orderedRenderPhases, resolveStaticFileImport, sel, useCapacitor, useChip, useDiode, useLed, useRenderedCircuit, useResistor };
|
|
82673
|
+
export { AnalogSimulation, type AsyncEffect, type AutorouterCompleteEvent, type AutorouterErrorEvent, type AutorouterEvent, type AutorouterProgressEvent, type AutoroutingEndEvent, type AutoroutingErrorEvent, type AutoroutingProgressEvent, type AutoroutingStartEvent, Battery, Board, Breakout, BreakoutPoint, CadAssembly, CadModel, Capacitor, Chip, Circuit, type ComponentWithPins, Constraint, CopperPour, CopperText, Crystal, CurrentSource, Cutout, type DebugLogOutputEvent, Diode, FabricationNoteDimension, FabricationNotePath, FabricationNoteRect, FabricationNoteText, Fiducial, Footprint, Fuse, type GenericConnectionsAndSelectorsSel, type GenericLocalAutorouter, Group, Hole, type IRenderable, Inductor, Interconnect, Jumper, Keepout, Led, type LocalCacheEngine, Mosfet, Net, NetLabel, NormalComponent, type Obstacle, OpAmp, type PackingEndEvent, type PackingErrorEvent, type PackingStartEvent, Panel, PcbNoteDimension, PcbNoteLine, PcbNotePath, PcbNoteRect, PcbNoteText, PcbTrace, PinHeader, type PinLabelSpec, Pinout, PlatedHole, Port, Potentiometer, PowerSource, PrimitiveComponent, Project, PushButton, type RenderPhase, type RenderPhaseFn, type RenderPhaseFunctions, type RenderPhaseStates, Renderable, Resistor, Resonator, RootCircuit, type RootCircuitEventName, SOLVERS, SchematicArc, SchematicBox, SchematicCell, SchematicCircle, SchematicLine, SchematicPath, SchematicRect, SchematicRow, SchematicTable, SchematicText, type Sel, SilkscreenCircle, SilkscreenLine, SilkscreenPath, SilkscreenRect, SilkscreenText, type SimpleRouteConnection, type SimpleRouteJson, type SimplifiedPcbTrace, SmtPad, SolderJumper, type SolverName, type SolverStartedEvent, Subcircuit, Switch, SymbolComponent as Symbol, TestPoint, Trace, TraceHint, Transistor, Via, VoltageProbe, VoltageSource, applyEditEvents, applyEditEventsToManualEditsFile, applyPcbEditEventsToManualEditsFile, applySchematicEditEventsToManualEditsFile, createUseComponent, getPhaseTimingsFromRenderEvents, getSimpleRouteJsonFromCircuitJson, normalizePinLabels, orderedRenderPhases, renderPhaseIndexMap, resolveStaticFileImport, sel, useCapacitor, useChip, useDiode, useLed, useRenderedCircuit, useResistor };
|
package/dist/index.js
CHANGED
|
@@ -161,6 +161,9 @@ var orderedRenderPhases = [
|
|
|
161
161
|
"PartsEngineRender",
|
|
162
162
|
"SimulationSpiceEngineRender"
|
|
163
163
|
];
|
|
164
|
+
var renderPhaseIndexMap = new Map(
|
|
165
|
+
orderedRenderPhases.map((phase, index) => [phase, index])
|
|
166
|
+
);
|
|
164
167
|
var asyncPhaseDependencies = {
|
|
165
168
|
PcbFootprintLayout: ["PcbFootprintStringRender"],
|
|
166
169
|
PcbComponentSizeCalculation: ["PcbFootprintStringRender"],
|
|
@@ -207,7 +210,7 @@ var Renderable = class _Renderable {
|
|
|
207
210
|
}
|
|
208
211
|
_markDirty(phase) {
|
|
209
212
|
this.renderPhaseStates[phase].dirty = true;
|
|
210
|
-
const phaseIndex =
|
|
213
|
+
const phaseIndex = renderPhaseIndexMap.get(phase);
|
|
211
214
|
for (let i = phaseIndex + 1; i < orderedRenderPhases.length; i++) {
|
|
212
215
|
this.renderPhaseStates[orderedRenderPhases[i]].dirty = true;
|
|
213
216
|
}
|
|
@@ -344,7 +347,7 @@ ${error.stack}`
|
|
|
344
347
|
this._emitRenderLifecycleEvent(phase, "end");
|
|
345
348
|
return;
|
|
346
349
|
}
|
|
347
|
-
const prevPhaseIndex =
|
|
350
|
+
const prevPhaseIndex = renderPhaseIndexMap.get(phase) - 1;
|
|
348
351
|
if (prevPhaseIndex >= 0) {
|
|
349
352
|
const prevPhase = orderedRenderPhases[prevPhaseIndex];
|
|
350
353
|
const hasIncompleteEffects = this._asyncEffects.filter((e) => e.phase === prevPhase).some((e) => !e.complete);
|
|
@@ -8813,7 +8816,8 @@ var NormalComponent3 = class extends PrimitiveComponent2 {
|
|
|
8813
8816
|
ftype,
|
|
8814
8817
|
name: this.name,
|
|
8815
8818
|
manufacturer_part_number: props.manufacturerPartNumber ?? props.mfn,
|
|
8816
|
-
supplier_part_numbers: props.supplierPartNumbers
|
|
8819
|
+
supplier_part_numbers: props.supplierPartNumbers,
|
|
8820
|
+
display_name: props.displayName
|
|
8817
8821
|
});
|
|
8818
8822
|
this.source_component_id = source_component.source_component_id;
|
|
8819
8823
|
}
|
|
@@ -15360,7 +15364,8 @@ var Capacitor = class extends NormalComponent3 {
|
|
|
15360
15364
|
max_voltage_rating: props.maxVoltageRating,
|
|
15361
15365
|
max_decoupling_trace_length: props.maxDecouplingTraceLength,
|
|
15362
15366
|
display_capacitance: this._getSchematicSymbolDisplayValue(),
|
|
15363
|
-
are_pins_interchangeable: !props.polarized
|
|
15367
|
+
are_pins_interchangeable: !props.polarized,
|
|
15368
|
+
display_name: props.displayName
|
|
15364
15369
|
});
|
|
15365
15370
|
this.source_component_id = source_component.source_component_id;
|
|
15366
15371
|
}
|
|
@@ -15495,7 +15500,8 @@ var Chip = class extends NormalComponent3 {
|
|
|
15495
15500
|
ftype: "simple_chip",
|
|
15496
15501
|
name: this.name,
|
|
15497
15502
|
manufacturer_part_number: props.manufacturerPartNumber,
|
|
15498
|
-
supplier_part_numbers: props.supplierPartNumbers
|
|
15503
|
+
supplier_part_numbers: props.supplierPartNumbers,
|
|
15504
|
+
display_name: props.displayName
|
|
15499
15505
|
});
|
|
15500
15506
|
this.source_component_id = source_component.source_component_id;
|
|
15501
15507
|
}
|
|
@@ -15705,7 +15711,8 @@ var Diode = class extends NormalComponent3 {
|
|
|
15705
15711
|
// @ts-ignore
|
|
15706
15712
|
manufacturer_part_number: props.manufacturerPartNumber ?? props.mfn,
|
|
15707
15713
|
supplier_part_numbers: props.supplierPartNumbers,
|
|
15708
|
-
are_pins_interchangeable: false
|
|
15714
|
+
are_pins_interchangeable: false,
|
|
15715
|
+
display_name: props.displayName
|
|
15709
15716
|
});
|
|
15710
15717
|
this.source_component_id = source_component.source_component_id;
|
|
15711
15718
|
}
|
|
@@ -15799,7 +15806,8 @@ var Inductor = class extends NormalComponent3 {
|
|
|
15799
15806
|
inductance: this.props.inductance,
|
|
15800
15807
|
display_inductance: this._getSchematicSymbolDisplayValue(),
|
|
15801
15808
|
supplier_part_numbers: props.supplierPartNumbers,
|
|
15802
|
-
are_pins_interchangeable: true
|
|
15809
|
+
are_pins_interchangeable: true,
|
|
15810
|
+
display_name: props.displayName
|
|
15803
15811
|
});
|
|
15804
15812
|
this.source_component_id = source_component.source_component_id;
|
|
15805
15813
|
}
|
|
@@ -15945,7 +15953,8 @@ var Resistor = class extends NormalComponent3 {
|
|
|
15945
15953
|
supplier_part_numbers: props.supplierPartNumbers,
|
|
15946
15954
|
resistance: props.resistance,
|
|
15947
15955
|
display_resistance: this._getSchematicSymbolDisplayValue(),
|
|
15948
|
-
are_pins_interchangeable: true
|
|
15956
|
+
are_pins_interchangeable: true,
|
|
15957
|
+
display_name: props.displayName
|
|
15949
15958
|
});
|
|
15950
15959
|
this.source_component_id = source_component.source_component_id;
|
|
15951
15960
|
}
|
|
@@ -16085,7 +16094,8 @@ var Transistor = class extends NormalComponent3 {
|
|
|
16085
16094
|
const source_component = db.source_component.insert({
|
|
16086
16095
|
ftype: "simple_transistor",
|
|
16087
16096
|
name: this.name,
|
|
16088
|
-
transistor_type: props.type
|
|
16097
|
+
transistor_type: props.type,
|
|
16098
|
+
display_name: props.displayName
|
|
16089
16099
|
});
|
|
16090
16100
|
this.source_component_id = source_component.source_component_id;
|
|
16091
16101
|
}
|
|
@@ -17188,7 +17198,8 @@ var Pinout = class extends Chip {
|
|
|
17188
17198
|
ftype: "simple_pinout",
|
|
17189
17199
|
name: this.name,
|
|
17190
17200
|
manufacturer_part_number: props.manufacturerPartNumber,
|
|
17191
|
-
supplier_part_numbers: props.supplierPartNumbers
|
|
17201
|
+
supplier_part_numbers: props.supplierPartNumbers,
|
|
17202
|
+
display_name: props.displayName
|
|
17192
17203
|
});
|
|
17193
17204
|
this.source_component_id = source_component.source_component_id;
|
|
17194
17205
|
}
|
|
@@ -17224,7 +17235,8 @@ var Fuse = class extends NormalComponent3 {
|
|
|
17224
17235
|
current_rating_amps: currentRating,
|
|
17225
17236
|
voltage_rating_volts: voltageRating,
|
|
17226
17237
|
display_current_rating: `${formatSiUnit4(currentRating)}A`,
|
|
17227
|
-
display_voltage_rating: `${formatSiUnit4(voltageRating)}V
|
|
17238
|
+
display_voltage_rating: `${formatSiUnit4(voltageRating)}V`,
|
|
17239
|
+
display_name: props.displayName
|
|
17228
17240
|
});
|
|
17229
17241
|
this.source_component_id = source_component.source_component_id;
|
|
17230
17242
|
}
|
|
@@ -17262,7 +17274,8 @@ var Jumper = class extends NormalComponent3 {
|
|
|
17262
17274
|
name: this.name,
|
|
17263
17275
|
manufacturer_part_number: props.manufacturerPartNumber,
|
|
17264
17276
|
supplier_part_numbers: props.supplierPartNumbers,
|
|
17265
|
-
are_pins_interchangeable: true
|
|
17277
|
+
are_pins_interchangeable: true,
|
|
17278
|
+
display_name: props.displayName
|
|
17266
17279
|
});
|
|
17267
17280
|
this.source_component_id = source_component.source_component_id;
|
|
17268
17281
|
}
|
|
@@ -17371,7 +17384,8 @@ var Interconnect = class extends NormalComponent3 {
|
|
|
17371
17384
|
const source_component = db.source_component.insert({
|
|
17372
17385
|
ftype: "interconnect",
|
|
17373
17386
|
name: this.name,
|
|
17374
|
-
are_pins_interchangeable: true
|
|
17387
|
+
are_pins_interchangeable: true,
|
|
17388
|
+
display_name: this._parsedProps.displayName
|
|
17375
17389
|
});
|
|
17376
17390
|
this.source_component_id = source_component.source_component_id;
|
|
17377
17391
|
}
|
|
@@ -17483,7 +17497,8 @@ var SolderJumper = class extends NormalComponent3 {
|
|
|
17483
17497
|
name: this.name,
|
|
17484
17498
|
manufacturer_part_number: props.manufacturerPartNumber,
|
|
17485
17499
|
supplier_part_numbers: props.supplierPartNumbers,
|
|
17486
|
-
are_pins_interchangeable: true
|
|
17500
|
+
are_pins_interchangeable: true,
|
|
17501
|
+
display_name: props.displayName
|
|
17487
17502
|
});
|
|
17488
17503
|
this.source_component_id = source_component.source_component_id;
|
|
17489
17504
|
}
|
|
@@ -17599,7 +17614,8 @@ var Led = class extends NormalComponent3 {
|
|
|
17599
17614
|
// @ts-ignore
|
|
17600
17615
|
manufacturer_part_number: props.manufacturerPartNumber ?? props.mfn,
|
|
17601
17616
|
supplier_part_numbers: props.supplierPartNumbers,
|
|
17602
|
-
are_pins_interchangeable: false
|
|
17617
|
+
are_pins_interchangeable: false,
|
|
17618
|
+
display_name: props.displayName
|
|
17603
17619
|
});
|
|
17604
17620
|
this.source_component_id = source_component.source_component_id;
|
|
17605
17621
|
}
|
|
@@ -17638,7 +17654,8 @@ var PowerSource = class extends NormalComponent3 {
|
|
|
17638
17654
|
name: this.name,
|
|
17639
17655
|
voltage: props.voltage,
|
|
17640
17656
|
supplier_part_numbers: props.supplierPartNumbers,
|
|
17641
|
-
are_pins_interchangeable: false
|
|
17657
|
+
are_pins_interchangeable: false,
|
|
17658
|
+
display_name: props.displayName
|
|
17642
17659
|
});
|
|
17643
17660
|
this.source_component_id = source_component.source_component_id;
|
|
17644
17661
|
}
|
|
@@ -17704,7 +17721,8 @@ var VoltageSource = class extends NormalComponent3 {
|
|
|
17704
17721
|
phase: props.phase,
|
|
17705
17722
|
duty_cycle: props.dutyCycle,
|
|
17706
17723
|
supplier_part_numbers: props.supplierPartNumbers,
|
|
17707
|
-
are_pins_interchangeable: true
|
|
17724
|
+
are_pins_interchangeable: true,
|
|
17725
|
+
display_name: props.displayName
|
|
17708
17726
|
});
|
|
17709
17727
|
this.source_component_id = source_component.source_component_id;
|
|
17710
17728
|
}
|
|
@@ -17789,7 +17807,8 @@ var CurrentSource = class extends NormalComponent3 {
|
|
|
17789
17807
|
phase: props.phase,
|
|
17790
17808
|
duty_cycle: props.dutyCycle,
|
|
17791
17809
|
supplier_part_numbers: props.supplierPartNumbers,
|
|
17792
|
-
are_pins_interchangeable: true
|
|
17810
|
+
are_pins_interchangeable: true,
|
|
17811
|
+
display_name: props.displayName
|
|
17793
17812
|
});
|
|
17794
17813
|
this.source_component_id = source_component.source_component_id;
|
|
17795
17814
|
}
|
|
@@ -19532,7 +19551,8 @@ var Battery = class extends NormalComponent3 {
|
|
|
19532
19551
|
ftype: "simple_power_source",
|
|
19533
19552
|
capacity: props.capacity,
|
|
19534
19553
|
supplier_part_numbers: props.supplierPartNumbers,
|
|
19535
|
-
are_pins_interchangeable: false
|
|
19554
|
+
are_pins_interchangeable: false,
|
|
19555
|
+
display_name: props.displayName
|
|
19536
19556
|
});
|
|
19537
19557
|
this.source_component_id = source_component.source_component_id;
|
|
19538
19558
|
}
|
|
@@ -19637,7 +19657,8 @@ var PinHeader = class extends NormalComponent3 {
|
|
|
19637
19657
|
supplier_part_numbers: props.supplierPartNumbers,
|
|
19638
19658
|
pin_count: props.pinCount,
|
|
19639
19659
|
gender: props.gender,
|
|
19640
|
-
are_pins_interchangeable: true
|
|
19660
|
+
are_pins_interchangeable: true,
|
|
19661
|
+
display_name: props.displayName
|
|
19641
19662
|
});
|
|
19642
19663
|
this.source_component_id = source_component.source_component_id;
|
|
19643
19664
|
}
|
|
@@ -19678,7 +19699,8 @@ var Resonator = class extends NormalComponent3 {
|
|
|
19678
19699
|
load_capacitance: props.loadCapacitance,
|
|
19679
19700
|
supplier_part_numbers: props.supplierPartNumbers,
|
|
19680
19701
|
pin_variant: pinVariant,
|
|
19681
|
-
are_pins_interchangeable: pinVariant === "no_ground" || pinVariant === "ground_pin"
|
|
19702
|
+
are_pins_interchangeable: pinVariant === "no_ground" || pinVariant === "ground_pin",
|
|
19703
|
+
display_name: props.displayName
|
|
19682
19704
|
});
|
|
19683
19705
|
this.source_component_id = source_component.source_component_id;
|
|
19684
19706
|
}
|
|
@@ -19725,7 +19747,8 @@ var Potentiometer = class extends NormalComponent3 {
|
|
|
19725
19747
|
name: this.name,
|
|
19726
19748
|
max_resistance: props.maxResistance,
|
|
19727
19749
|
pin_variant: pinVariant,
|
|
19728
|
-
are_pins_interchangeable: pinVariant === "two_pin"
|
|
19750
|
+
are_pins_interchangeable: pinVariant === "two_pin",
|
|
19751
|
+
display_name: props.displayName
|
|
19729
19752
|
});
|
|
19730
19753
|
this.source_component_id = source_component.source_component_id;
|
|
19731
19754
|
}
|
|
@@ -19790,7 +19813,8 @@ var PushButton = class extends NormalComponent3 {
|
|
|
19790
19813
|
name: this.name,
|
|
19791
19814
|
ftype: FTYPE.simple_push_button,
|
|
19792
19815
|
supplier_part_numbers: props.supplierPartNumbers,
|
|
19793
|
-
are_pins_interchangeable: true
|
|
19816
|
+
are_pins_interchangeable: true,
|
|
19817
|
+
display_name: props.displayName
|
|
19794
19818
|
});
|
|
19795
19819
|
this.source_component_id = source_component.source_component_id;
|
|
19796
19820
|
}
|
|
@@ -19842,7 +19866,8 @@ var Crystal = class extends NormalComponent3 {
|
|
|
19842
19866
|
frequency: props.frequency,
|
|
19843
19867
|
load_capacitance: props.loadCapacitance,
|
|
19844
19868
|
pin_variant: props.pinVariant || "two_pin",
|
|
19845
|
-
are_pins_interchangeable: (props.pinVariant || "two_pin") === "two_pin"
|
|
19869
|
+
are_pins_interchangeable: (props.pinVariant || "two_pin") === "two_pin",
|
|
19870
|
+
display_name: props.displayName
|
|
19846
19871
|
});
|
|
19847
19872
|
this.source_component_id = source_component.source_component_id;
|
|
19848
19873
|
}
|
|
@@ -19869,7 +19894,8 @@ var Mosfet = class extends NormalComponent3 {
|
|
|
19869
19894
|
ftype: "simple_mosfet",
|
|
19870
19895
|
name: this.name,
|
|
19871
19896
|
mosfet_mode: props.mosfetMode,
|
|
19872
|
-
channel_type: props.channelType
|
|
19897
|
+
channel_type: props.channelType,
|
|
19898
|
+
display_name: props.displayName
|
|
19873
19899
|
});
|
|
19874
19900
|
this.source_component_id = source_component.source_component_id;
|
|
19875
19901
|
}
|
|
@@ -19906,7 +19932,8 @@ var OpAmp = class extends NormalComponent3 {
|
|
|
19906
19932
|
const source_component = db.source_component.insert({
|
|
19907
19933
|
ftype: "simple_op_amp",
|
|
19908
19934
|
name: this.name,
|
|
19909
|
-
supplier_part_numbers: props.supplierPartNumbers
|
|
19935
|
+
supplier_part_numbers: props.supplierPartNumbers,
|
|
19936
|
+
display_name: props.displayName
|
|
19910
19937
|
});
|
|
19911
19938
|
this.source_component_id = source_component.source_component_id;
|
|
19912
19939
|
}
|
|
@@ -19975,7 +20002,8 @@ var Switch = class extends NormalComponent3 {
|
|
|
19975
20002
|
const source_component = db.source_component.insert({
|
|
19976
20003
|
ftype: "simple_switch",
|
|
19977
20004
|
name: this.name,
|
|
19978
|
-
are_pins_interchangeable: this._getSwitchType() === "spst"
|
|
20005
|
+
are_pins_interchangeable: this._getSwitchType() === "spst",
|
|
20006
|
+
display_name: props?.displayName
|
|
19979
20007
|
});
|
|
19980
20008
|
this.source_component_id = source_component.source_component_id;
|
|
19981
20009
|
}
|
|
@@ -20104,7 +20132,8 @@ var TestPoint = class extends NormalComponent3 {
|
|
|
20104
20132
|
hole_diameter: holeDiameter,
|
|
20105
20133
|
width,
|
|
20106
20134
|
height,
|
|
20107
|
-
are_pins_interchangeable: true
|
|
20135
|
+
are_pins_interchangeable: true,
|
|
20136
|
+
display_name: props.displayName
|
|
20108
20137
|
});
|
|
20109
20138
|
this.source_component_id = source_component.source_component_id;
|
|
20110
20139
|
}
|
|
@@ -20973,7 +21002,7 @@ import { identity as identity5 } from "transformation-matrix";
|
|
|
20973
21002
|
var package_default = {
|
|
20974
21003
|
name: "@tscircuit/core",
|
|
20975
21004
|
type: "module",
|
|
20976
|
-
version: "0.0.
|
|
21005
|
+
version: "0.0.984",
|
|
20977
21006
|
types: "dist/index.d.ts",
|
|
20978
21007
|
main: "dist/index.js",
|
|
20979
21008
|
module: "dist/index.js",
|
|
@@ -21029,13 +21058,13 @@ var package_default = {
|
|
|
21029
21058
|
"bun-match-svg": "0.0.12",
|
|
21030
21059
|
"calculate-elbow": "^0.0.12",
|
|
21031
21060
|
"chokidar-cli": "^3.0.0",
|
|
21032
|
-
"circuit-json": "^0.0.
|
|
21061
|
+
"circuit-json": "^0.0.357",
|
|
21033
21062
|
"circuit-json-to-bpc": "^0.0.13",
|
|
21034
21063
|
"circuit-json-to-connectivity-map": "^0.0.23",
|
|
21035
21064
|
"circuit-json-to-gltf": "^0.0.31",
|
|
21036
21065
|
"circuit-json-to-simple-3d": "^0.0.9",
|
|
21037
21066
|
"circuit-json-to-spice": "^0.0.33",
|
|
21038
|
-
"circuit-to-svg": "^0.0.
|
|
21067
|
+
"circuit-to-svg": "^0.0.316",
|
|
21039
21068
|
concurrently: "^9.1.2",
|
|
21040
21069
|
"connectivity-map": "^1.0.0",
|
|
21041
21070
|
debug: "^4.3.6",
|
|
@@ -21604,6 +21633,7 @@ export {
|
|
|
21604
21633
|
getSimpleRouteJsonFromCircuitJson,
|
|
21605
21634
|
normalizePinLabels,
|
|
21606
21635
|
orderedRenderPhases,
|
|
21636
|
+
renderPhaseIndexMap,
|
|
21607
21637
|
resolveStaticFileImport,
|
|
21608
21638
|
sel,
|
|
21609
21639
|
useCapacitor,
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tscircuit/core",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.985",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
7
|
"module": "dist/index.js",
|
|
@@ -57,13 +57,13 @@
|
|
|
57
57
|
"bun-match-svg": "0.0.12",
|
|
58
58
|
"calculate-elbow": "^0.0.12",
|
|
59
59
|
"chokidar-cli": "^3.0.0",
|
|
60
|
-
"circuit-json": "^0.0.
|
|
60
|
+
"circuit-json": "^0.0.357",
|
|
61
61
|
"circuit-json-to-bpc": "^0.0.13",
|
|
62
62
|
"circuit-json-to-connectivity-map": "^0.0.23",
|
|
63
63
|
"circuit-json-to-gltf": "^0.0.31",
|
|
64
64
|
"circuit-json-to-simple-3d": "^0.0.9",
|
|
65
65
|
"circuit-json-to-spice": "^0.0.33",
|
|
66
|
-
"circuit-to-svg": "^0.0.
|
|
66
|
+
"circuit-to-svg": "^0.0.316",
|
|
67
67
|
"concurrently": "^9.1.2",
|
|
68
68
|
"connectivity-map": "^1.0.0",
|
|
69
69
|
"debug": "^4.3.6",
|