circuit-json 0.0.500 → 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 +703 -2
- package/dist/index.mjs +24 -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"),
|
|
@@ -5086,6 +5108,7 @@ export {
|
|
|
5086
5108
|
pcb_trace_hint,
|
|
5087
5109
|
pcb_trace_missing_error,
|
|
5088
5110
|
pcb_trace_route_point,
|
|
5111
|
+
pcb_trace_route_point_teardrop,
|
|
5089
5112
|
pcb_trace_route_point_through_pad,
|
|
5090
5113
|
pcb_trace_route_point_via,
|
|
5091
5114
|
pcb_trace_route_point_wire,
|