@tscircuit/pcb-viewer 1.11.430 → 1.11.431
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 +23 -23
- package/dist/index.js +2489 -2218
- package/dist/index.js.map +1 -1
- package/package.json +2 -1
package/dist/index.d.ts
CHANGED
|
@@ -1,14 +1,24 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
+
import { ManualEditEvent } from '@tscircuit/props';
|
|
2
3
|
import { LayerRef, AnyCircuitElement } from 'circuit-json';
|
|
3
4
|
import { GraphicsObject } from 'graphics-debug';
|
|
4
|
-
import { ManualEditEvent } from '@tscircuit/props';
|
|
5
5
|
import { Matrix } from 'transformation-matrix';
|
|
6
6
|
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
7
|
+
type GridConfig = {
|
|
8
|
+
spacing: number;
|
|
9
|
+
view_window: {
|
|
10
|
+
left: number;
|
|
11
|
+
right: number;
|
|
12
|
+
top: number;
|
|
13
|
+
bottom: number;
|
|
14
|
+
};
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
interface BoundsSelection {
|
|
18
|
+
minX: number;
|
|
19
|
+
minY: number;
|
|
20
|
+
maxX: number;
|
|
21
|
+
maxY: number;
|
|
12
22
|
}
|
|
13
23
|
|
|
14
24
|
interface State {
|
|
@@ -63,23 +73,6 @@ type StateProps = {
|
|
|
63
73
|
[key in keyof State]: State[key] extends boolean ? boolean : never;
|
|
64
74
|
};
|
|
65
75
|
|
|
66
|
-
type GridConfig = {
|
|
67
|
-
spacing: number;
|
|
68
|
-
view_window: {
|
|
69
|
-
left: number;
|
|
70
|
-
right: number;
|
|
71
|
-
top: number;
|
|
72
|
-
bottom: number;
|
|
73
|
-
};
|
|
74
|
-
};
|
|
75
|
-
|
|
76
|
-
interface BoundsSelection {
|
|
77
|
-
minX: number;
|
|
78
|
-
minY: number;
|
|
79
|
-
maxX: number;
|
|
80
|
-
maxY: number;
|
|
81
|
-
}
|
|
82
|
-
|
|
83
76
|
interface PcbViewerController {
|
|
84
77
|
/** @internal Pending command, consumed after the viewer focuses the component. */
|
|
85
78
|
focusRequest: {
|
|
@@ -101,6 +94,13 @@ declare const usePcbViewerController: () => {
|
|
|
101
94
|
focusPcbComponent: (pcbComponentId: string) => void;
|
|
102
95
|
};
|
|
103
96
|
|
|
97
|
+
/** Stable identity for hosts to locate the component in their schematic. */
|
|
98
|
+
interface ViewSchematicComponentEvent {
|
|
99
|
+
source_component_id: string;
|
|
100
|
+
pcb_component_id: string;
|
|
101
|
+
refdes: string;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
104
|
type Props = {
|
|
105
105
|
circuitJson?: AnyCircuitElement[];
|
|
106
106
|
height?: number;
|