@tscircuit/pcb-viewer 1.4.4 → 1.4.5

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 CHANGED
@@ -4,7 +4,9 @@
4
4
 
5
5
  [Examples](https://pcb-viewer.vercel.app/) · [TSCircuit](https://tscircuit.com) · [Open in CodeSandbox](https://codesandbox.io/p/github/tscircuit/pcb-viewer)
6
6
 
7
- Render PCBs w/ React
7
+ Render Printed Circuit Boards w/ React
8
+
9
+ If you want to render to an image, check out [circuit-to-png](https://github.com/tscircuit/circuit-to-png)
8
10
 
9
11
  ![image](https://github.com/tscircuit/pcb-viewer/assets/1910070/e010f44e-b8c0-4e1d-9d59-1ea66716427f)
10
12
 
package/dist/index.js CHANGED
@@ -11979,7 +11979,9 @@ var LAYER_NAME_TO_COLOR = _object_spread({
11979
11979
  tkeepout: colors_default.board.b_crtyd,
11980
11980
  tplace: colors_default.board.b_silks,
11981
11981
  top_silkscreen: colors_default.board.f_silks,
11982
- bottom_silkscreen: colors_default.board.b_silks
11982
+ bottom_silkscreen: colors_default.board.b_silks,
11983
+ top_fabrication: colors_default.board.f_fab,
11984
+ bottom_fabrication: colors_default.board.b_fab
11983
11985
  }, colors_default.board);
11984
11986
  var DEFAULT_DRAW_ORDER = [
11985
11987
  "top",
@@ -12746,14 +12748,14 @@ var convertElementToPrimitives = function(element, allElements) {
12746
12748
  }
12747
12749
  return route1.slice(0, -1).map(function(point, index) {
12748
12750
  var nextPoint = route1[index + 1];
12751
+ var _element_stroke_width;
12749
12752
  return {
12750
12753
  pcb_drawing_type: "line",
12751
12754
  x1: point.x,
12752
12755
  y1: point.y,
12753
12756
  x2: nextPoint.x,
12754
12757
  y2: nextPoint.y,
12755
- width: 0.1,
12756
- // TODO add strokewidth
12758
+ width: (_element_stroke_width = element.stroke_width) !== null && _element_stroke_width !== void 0 ? _element_stroke_width : 0.1,
12757
12759
  squareCap: false,
12758
12760
  layer: layer2,
12759
12761
  _element: element,
@@ -13288,7 +13290,7 @@ var import_soup2 = __toESM(require_dist());
13288
13290
  // package.json
13289
13291
  var package_default = {
13290
13292
  name: "@tscircuit/pcb-viewer",
13291
- version: "1.4.3",
13293
+ version: "1.4.4",
13292
13294
  main: "dist/index.js",
13293
13295
  repository: "tscircuit/pcb-viewer",
13294
13296
  license: "MIT",