@tscircuit/3d-viewer 0.0.492 → 0.0.494

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.
Files changed (2) hide show
  1. package/dist/index.js +6 -6
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -30825,7 +30825,7 @@ import * as THREE16 from "three";
30825
30825
  // package.json
30826
30826
  var package_default = {
30827
30827
  name: "@tscircuit/3d-viewer",
30828
- version: "0.0.491",
30828
+ version: "0.0.493",
30829
30829
  main: "./dist/index.js",
30830
30830
  module: "./dist/index.js",
30831
30831
  type: "module",
@@ -32504,7 +32504,7 @@ var platedHole = (plated_hole, ctx, options = {}) => {
32504
32504
  return (0, import_colors2.colorize)(colors.copper, (0, import_booleans2.subtract)(copperSolid, drill));
32505
32505
  }
32506
32506
  if (plated_hole.shape === "pill_hole_with_rect_pad") {
32507
- if (plated_hole.hole_shape !== "pill" || plated_hole.pad_shape !== "rect") {
32507
+ if (plated_hole.hole_shape && plated_hole.hole_shape !== "pill" || plated_hole.pad_shape && plated_hole.pad_shape !== "rect") {
32508
32508
  throw new Error(
32509
32509
  `Invalid hole_shape or pad_shape for pill_hole_with_rect_pad`
32510
32510
  );
@@ -33184,7 +33184,7 @@ var BoardGeomBuilder = class {
33184
33184
  if (ph.shape === "circle" || ph.shape === "circular_hole_with_rect_pad") {
33185
33185
  let cyGeom = null;
33186
33186
  if (ph.shape === "circular_hole_with_rect_pad") {
33187
- if (ph.hole_shape !== "circle" || ph.pad_shape !== "rect") {
33187
+ if (ph.hole_shape && ph.hole_shape !== "circle" || ph.pad_shape && ph.pad_shape !== "rect") {
33188
33188
  return;
33189
33189
  }
33190
33190
  cyGeom = (0, import_primitives7.cylinder)({
@@ -33258,7 +33258,7 @@ var BoardGeomBuilder = class {
33258
33258
  });
33259
33259
  this.platedHoleGeoms.push(platedHoleGeom);
33260
33260
  } else if (ph.shape === "pill_hole_with_rect_pad") {
33261
- if (ph.hole_shape !== "pill" || ph.pad_shape !== "rect") {
33261
+ if (ph.hole_shape && ph.hole_shape !== "pill" || ph.pad_shape && ph.pad_shape !== "rect") {
33262
33262
  return;
33263
33263
  }
33264
33264
  const shouldRotate = ph.hole_height > ph.hole_width;
@@ -36668,7 +36668,7 @@ function processPlatedHolesForManifold(Manifold, CrossSection, circuitJson, pcbT
36668
36668
  color: COPPER_COLOR
36669
36669
  });
36670
36670
  } else if (ph.shape === "pill_hole_with_rect_pad") {
36671
- if (ph.hole_shape !== "pill" || ph.pad_shape !== "rect") {
36671
+ if (ph.hole_shape && ph.hole_shape !== "pill" || ph.pad_shape && ph.pad_shape !== "rect") {
36672
36672
  return;
36673
36673
  }
36674
36674
  const holeW = ph.hole_width;
@@ -36936,7 +36936,7 @@ function processPlatedHolesForManifold(Manifold, CrossSection, circuitJson, pcbT
36936
36936
  color: COPPER_COLOR
36937
36937
  });
36938
36938
  } else if (ph.shape === "circular_hole_with_rect_pad") {
36939
- if (ph.hole_shape !== "circle" || ph.pad_shape !== "rect") {
36939
+ if (ph.hole_shape && ph.hole_shape !== "circle" || ph.pad_shape && ph.pad_shape !== "rect") {
36940
36940
  return;
36941
36941
  }
36942
36942
  const holeOffsetX = ph.hole_offset_x || 0;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tscircuit/3d-viewer",
3
- "version": "0.0.492",
3
+ "version": "0.0.494",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index.js",
6
6
  "type": "module",