circuit-json 0.0.499 → 0.0.501
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/README.md +21 -0
- package/dist/index.d.mts +716 -2
- package/dist/index.mjs +27 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -2547,10 +2547,32 @@ var pcb_trace_route_point_through_pad = z116.object({
|
|
|
2547
2547
|
pcb_smtpad_id: z116.string().optional(),
|
|
2548
2548
|
pcb_plated_hole_id: z116.string().optional()
|
|
2549
2549
|
});
|
|
2550
|
+
var positive_width = distance.pipe(z116.number().finite().positive());
|
|
2551
|
+
var finite_route_point = point.extend({
|
|
2552
|
+
x: distance.pipe(z116.number().finite()),
|
|
2553
|
+
y: distance.pipe(z116.number().finite())
|
|
2554
|
+
});
|
|
2555
|
+
var pcb_trace_route_point_teardrop = z116.object({
|
|
2556
|
+
route_type: z116.literal("teardrop"),
|
|
2557
|
+
start: finite_route_point,
|
|
2558
|
+
end: finite_route_point,
|
|
2559
|
+
start_width: positive_width,
|
|
2560
|
+
end_width: positive_width,
|
|
2561
|
+
width_interpolation_mode: z116.enum(["linear", "smoothstep"]),
|
|
2562
|
+
layer: layer_ref,
|
|
2563
|
+
copper_pour_id: z116.string().optional(),
|
|
2564
|
+
is_inside_copper_pour: z116.boolean().optional(),
|
|
2565
|
+
start_pcb_port_id: z116.string().optional(),
|
|
2566
|
+
end_pcb_port_id: z116.string().optional()
|
|
2567
|
+
}).refine(({ start, end }) => {
|
|
2568
|
+
const length4 = Math.hypot(end.x - start.x, end.y - start.y);
|
|
2569
|
+
return Number.isFinite(length4) && length4 > 0;
|
|
2570
|
+
}, "Teardrop endpoints must define a finite, nonzero-length segment");
|
|
2550
2571
|
var pcb_trace_route_point = z116.union([
|
|
2551
2572
|
pcb_trace_route_point_wire,
|
|
2552
2573
|
pcb_trace_route_point_via,
|
|
2553
|
-
pcb_trace_route_point_through_pad
|
|
2574
|
+
pcb_trace_route_point_through_pad,
|
|
2575
|
+
pcb_trace_route_point_teardrop
|
|
2554
2576
|
]);
|
|
2555
2577
|
var pcb_trace = z116.object({
|
|
2556
2578
|
type: z116.literal("pcb_trace"),
|
|
@@ -4061,6 +4083,9 @@ var cad_component = z187.object({
|
|
|
4061
4083
|
source_component_id: z187.string(),
|
|
4062
4084
|
position: point3,
|
|
4063
4085
|
rotation: point3.optional(),
|
|
4086
|
+
is_on_folded_board: z187.boolean().optional().describe(
|
|
4087
|
+
"True when position and rotation describe the assembled folded board pose. False or omitted means the flat board pose. PCB records remain flat; pcb_component_id identifies the flat mount and owning board for reversible transforms."
|
|
4088
|
+
),
|
|
4064
4089
|
size: point3.optional(),
|
|
4065
4090
|
layer: layer_ref.optional(),
|
|
4066
4091
|
subcircuit_id: z187.string().optional(),
|
|
@@ -5083,6 +5108,7 @@ export {
|
|
|
5083
5108
|
pcb_trace_hint,
|
|
5084
5109
|
pcb_trace_missing_error,
|
|
5085
5110
|
pcb_trace_route_point,
|
|
5111
|
+
pcb_trace_route_point_teardrop,
|
|
5086
5112
|
pcb_trace_route_point_through_pad,
|
|
5087
5113
|
pcb_trace_route_point_via,
|
|
5088
5114
|
pcb_trace_route_point_wire,
|