easyeda 0.0.349 → 0.0.350
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 -0
- package/dist/browser/index.js.map +1 -1
- package/dist/index.js +11 -0
- package/dist/index.js.map +1 -1
- package/dist/main.cjs +12 -1
- package/dist/main.cjs.map +1 -1
- package/package.json +1 -1
package/dist/main.cjs
CHANGED
|
@@ -1026,7 +1026,7 @@ var import_promises = __toESM(require("fs/promises"), 1);
|
|
|
1026
1026
|
var package_default = {
|
|
1027
1027
|
name: "easyeda",
|
|
1028
1028
|
type: "module",
|
|
1029
|
-
version: "0.0.
|
|
1029
|
+
version: "0.0.349",
|
|
1030
1030
|
files: [
|
|
1031
1031
|
"dist"
|
|
1032
1032
|
],
|
|
@@ -9703,6 +9703,17 @@ var generateShapeTsx = ({
|
|
|
9703
9703
|
}) => {
|
|
9704
9704
|
const transformPoint = getPointTransformer(origin);
|
|
9705
9705
|
if (shape.type === "RECTANGLE") {
|
|
9706
|
+
if (shape.fillColor && shape.fillColor !== "none" && shape.fillColor.toLowerCase() !== shape.color.toLowerCase()) {
|
|
9707
|
+
const { x, y } = shape.position;
|
|
9708
|
+
const points = [
|
|
9709
|
+
{ x, y },
|
|
9710
|
+
{ x: x + shape.width, y },
|
|
9711
|
+
{ x: x + shape.width, y: y + shape.height },
|
|
9712
|
+
{ x, y: y + shape.height },
|
|
9713
|
+
{ x, y }
|
|
9714
|
+
].map(transformPoint);
|
|
9715
|
+
return `<schematicpath points={${JSON.stringify(points)}} strokeWidth={${toSchematicUnits(shape.lineWidth)}} strokeColor=${JSON.stringify(shape.color)} isFilled fillColor=${JSON.stringify(shape.fillColor)} />`;
|
|
9716
|
+
}
|
|
9706
9717
|
const center = transformPoint({
|
|
9707
9718
|
x: shape.position.x + shape.width / 2,
|
|
9708
9719
|
y: shape.position.y + shape.height / 2
|