easyeda 0.0.258 → 0.0.259
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/browser/index.js +11 -8
- package/dist/browser/index.js.map +1 -1
- package/dist/index.js +11 -8
- package/dist/index.js.map +1 -1
- package/dist/main.cjs +12 -9
- package/dist/main.cjs.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -5368,15 +5368,12 @@ var convertEasyEdaJsonToCircuitJson = (easyEdaJson, {
|
|
|
5368
5368
|
const innerWidth = largestOuterDimensionName === "width" ? largestInnerDimension : smallestInnerDimension;
|
|
5369
5369
|
const innerHeight = largestOuterDimensionName === "height" ? largestInnerDimension : smallestInnerDimension;
|
|
5370
5370
|
additionalPlatedHoleProps = {
|
|
5371
|
-
shape: "
|
|
5372
|
-
hole_shape: "pill",
|
|
5373
|
-
pad_shape: "rect",
|
|
5371
|
+
shape: "pill",
|
|
5374
5372
|
hole_width: innerWidth,
|
|
5375
5373
|
hole_height: innerHeight,
|
|
5376
|
-
|
|
5377
|
-
|
|
5378
|
-
|
|
5379
|
-
hole_offset_y: 0
|
|
5374
|
+
outer_width: mil2mm(pad.width),
|
|
5375
|
+
outer_height: mil2mm(pad.height),
|
|
5376
|
+
ccw_rotation: pad.rotation || 0
|
|
5380
5377
|
};
|
|
5381
5378
|
} else if (pad.shape === "RECT") {
|
|
5382
5379
|
const padWidth = mil2mm(pad.width);
|
|
@@ -6815,7 +6812,13 @@ var generateFootprintTsx = (circuitJson) => {
|
|
|
6815
6812
|
}
|
|
6816
6813
|
}
|
|
6817
6814
|
for (const platedHole of platedHoles) {
|
|
6818
|
-
if (platedHole.shape === "
|
|
6815
|
+
if (platedHole.shape === "pill" || platedHole.shape === "oval") {
|
|
6816
|
+
const cccwRotationDegree = platedHole.ccw_rotation || 0;
|
|
6817
|
+
const rotation2 = cccwRotationDegree ? ` pcbRotation="${cccwRotationDegree}deg"` : "";
|
|
6818
|
+
elementStrings.push(
|
|
6819
|
+
`<platedhole portHints={${JSON.stringify(platedHole.port_hints)}} pcbX="${mmStr(platedHole.x)}" pcbY="${mmStr(platedHole.y)}" holeWidth="${mmStr(platedHole.hole_width)}" holeHeight="${mmStr(platedHole.hole_height)}" outerWidth="${mmStr(platedHole.outer_width)}" outerHeight="${mmStr(platedHole.outer_height)}"${rotation2} shape="${platedHole.shape}" />`
|
|
6820
|
+
);
|
|
6821
|
+
} else if (platedHole.shape === "pill_hole_with_rect_pad") {
|
|
6819
6822
|
elementStrings.push(
|
|
6820
6823
|
`<platedhole portHints={${JSON.stringify(platedHole.port_hints)}} pcbX="${mmStr(platedHole.x)}" pcbY="${mmStr(platedHole.y)}" holeWidth="${mmStr(platedHole.hole_width)}" holeHeight="${mmStr(platedHole.hole_height)}" outerWidth="${mmStr(platedHole.rect_pad_width)}" outerHeight="${mmStr(platedHole.rect_pad_height)}" shape="pill" />`
|
|
6821
6824
|
);
|