jscad-electronics 0.0.99 → 0.0.101
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/index.d.ts +7 -3
- package/dist/index.js +159 -90
- package/dist/index.js.map +1 -1
- package/dist/vanilla.js +54 -0
- package/dist/vanilla.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -84,12 +84,14 @@ declare const ExtrudedPads: ({ circuitJson, footprint, }: {
|
|
|
84
84
|
footprint?: string;
|
|
85
85
|
}) => react_jsx_runtime.JSX.Element;
|
|
86
86
|
|
|
87
|
-
declare const FootprintPad: ({ pad }: {
|
|
87
|
+
declare const FootprintPad: ({ pad, isPin1, }: {
|
|
88
88
|
pad: PcbSmtPad;
|
|
89
|
+
isPin1?: boolean;
|
|
89
90
|
}) => react_jsx_runtime.JSX.Element;
|
|
90
91
|
|
|
91
|
-
declare const FootprintPlatedHole: ({ hole }: {
|
|
92
|
+
declare const FootprintPlatedHole: ({ hole, isPin1, }: {
|
|
92
93
|
hole: PcbPlatedHole;
|
|
94
|
+
isPin1?: boolean;
|
|
93
95
|
}) => react_jsx_runtime.JSX.Element;
|
|
94
96
|
|
|
95
97
|
/**
|
|
@@ -242,6 +244,8 @@ declare const SOD128: () => react_jsx_runtime.JSX.Element;
|
|
|
242
244
|
|
|
243
245
|
declare const SOD323: () => react_jsx_runtime.JSX.Element;
|
|
244
246
|
|
|
247
|
+
declare const SOD323F: () => react_jsx_runtime.JSX.Element;
|
|
248
|
+
|
|
245
249
|
declare const SOD923: () => react_jsx_runtime.JSX.Element;
|
|
246
250
|
|
|
247
251
|
declare const SOT223: () => react_jsx_runtime.JSX.Element;
|
|
@@ -317,4 +321,4 @@ declare const TO220: () => react_jsx_runtime.JSX.Element;
|
|
|
317
321
|
|
|
318
322
|
declare const TO92: () => react_jsx_runtime.JSX.Element;
|
|
319
323
|
|
|
320
|
-
export { A01005, A0201, A0402, A0603, A0805, A1206, A1210, A2010, A2512, BGA, ChipBody, type ChipBodyProps, DFN, ExtrudedPads, FootprintPad, FootprintPlatedHole, Footprinter3d, HC49, type HC49Props, LQFP, MELF, type MELFProps, MINIMELF, type MINIMELFProps, MS012, MS013, MSOP, MicroMELF, type MicroMELFProps, PinRow, QFN, QFP, SMA, SMB, SMC, SMF, SOD123, SOD123F, SOD123FL, SOD123W, SOD128, SOD323, SOD523, SOD882, SOD923, SOT223, SOT233P, SOT23W, SOT323, SOT363, SOT457, SOT563, SOT723, SmdChipLead, type SmdChipLeadProps, TO220, TO92, TQFP, Tssop, VSSOP };
|
|
324
|
+
export { A01005, A0201, A0402, A0603, A0805, A1206, A1210, A2010, A2512, BGA, ChipBody, type ChipBodyProps, DFN, ExtrudedPads, FootprintPad, FootprintPlatedHole, Footprinter3d, HC49, type HC49Props, LQFP, MELF, type MELFProps, MINIMELF, type MINIMELFProps, MS012, MS013, MSOP, MicroMELF, type MicroMELFProps, PinRow, QFN, QFP, SMA, SMB, SMC, SMF, SOD123, SOD123F, SOD123FL, SOD123W, SOD128, SOD323, SOD323F, SOD523, SOD882, SOD923, SOT223, SOT233P, SOT23W, SOT323, SOT363, SOT457, SOT563, SOT723, SmdChipLead, type SmdChipLeadProps, TO220, TO92, TQFP, Tssop, VSSOP };
|
package/dist/index.js
CHANGED
|
@@ -466,9 +466,13 @@ import { fp as fp2 } from "@tscircuit/footprinter";
|
|
|
466
466
|
// lib/FootprintPad.tsx
|
|
467
467
|
import { Colorize as Colorize3, Cuboid as Cuboid12, Translate as Translate4 } from "jscad-fiber";
|
|
468
468
|
import { jsx as jsx12 } from "react/jsx-runtime";
|
|
469
|
-
var FootprintPad = ({
|
|
469
|
+
var FootprintPad = ({
|
|
470
|
+
pad,
|
|
471
|
+
isPin1
|
|
472
|
+
}) => {
|
|
470
473
|
if (pad.shape === "rect") {
|
|
471
|
-
|
|
474
|
+
const color = isPin1 ? [0, 255, 0] : [255, 0, 0];
|
|
475
|
+
return /* @__PURE__ */ jsx12(Colorize3, { color, children: /* @__PURE__ */ jsx12(Translate4, { offset: [pad.x, pad.y, -5e-3], children: /* @__PURE__ */ jsx12(Cuboid12, { size: [pad.width, pad.height, 0.01] }) }) });
|
|
472
476
|
} else {
|
|
473
477
|
throw new Error("Shape not supported: " + pad.shape);
|
|
474
478
|
}
|
|
@@ -477,15 +481,19 @@ var FootprintPad = ({ pad }) => {
|
|
|
477
481
|
// lib/FootprintPlatedHole.tsx
|
|
478
482
|
import { Colorize as Colorize4, Cuboid as Cuboid13, Translate as Translate5, Cylinder as Cylinder2, Subtract as Subtract2 } from "jscad-fiber";
|
|
479
483
|
import { jsx as jsx13, jsxs as jsxs12 } from "react/jsx-runtime";
|
|
480
|
-
var FootprintPlatedHole = ({
|
|
484
|
+
var FootprintPlatedHole = ({
|
|
485
|
+
hole,
|
|
486
|
+
isPin1
|
|
487
|
+
}) => {
|
|
488
|
+
const color = isPin1 ? "#00ff00" : "#b87333";
|
|
481
489
|
if (hole.shape === "circle") {
|
|
482
|
-
return /* @__PURE__ */ jsx13(Colorize4, { color
|
|
490
|
+
return /* @__PURE__ */ jsx13(Colorize4, { color, children: /* @__PURE__ */ jsx13(Translate5, { offset: [hole.x, hole.y, -5e-3], children: /* @__PURE__ */ jsxs12(Subtract2, { children: [
|
|
483
491
|
/* @__PURE__ */ jsx13(Cylinder2, { radius: hole.outer_diameter / 2, height: 0.01 }),
|
|
484
492
|
/* @__PURE__ */ jsx13(Cylinder2, { radius: hole.hole_diameter / 2, height: 0.01 })
|
|
485
493
|
] }) }) });
|
|
486
494
|
}
|
|
487
495
|
if (hole.shape === "circular_hole_with_rect_pad") {
|
|
488
|
-
return /* @__PURE__ */ jsx13(Colorize4, { color
|
|
496
|
+
return /* @__PURE__ */ jsx13(Colorize4, { color, children: /* @__PURE__ */ jsx13(Translate5, { offset: [hole.x, hole.y, 0], children: /* @__PURE__ */ jsxs12(Subtract2, { children: [
|
|
489
497
|
/* @__PURE__ */ jsx13(
|
|
490
498
|
Cuboid13,
|
|
491
499
|
{
|
|
@@ -511,14 +519,18 @@ var ExtrudedPads = ({
|
|
|
511
519
|
if (!circuitJson)
|
|
512
520
|
throw new Error("No circuit json or footprint provided to ExtrudedPads");
|
|
513
521
|
return /* @__PURE__ */ jsxs13(Fragment11, { children: [
|
|
514
|
-
circuitJson.filter((s) => s.type === "pcb_smtpad").map((pad, i) =>
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
522
|
+
circuitJson.filter((s) => s.type === "pcb_smtpad").map((pad, i) => {
|
|
523
|
+
const isPin1 = pad.port_hints?.includes("1");
|
|
524
|
+
return (
|
|
525
|
+
// biome-ignore lint/suspicious/noArrayIndexKey:
|
|
526
|
+
/* @__PURE__ */ jsx14(FootprintPad, { pad, isPin1 }, i)
|
|
527
|
+
);
|
|
528
|
+
}),
|
|
518
529
|
circuitJson.filter((s) => s.type === "pcb_plated_hole").map((hole, i) => {
|
|
530
|
+
const isPin1 = hole.port_hints?.includes("1");
|
|
519
531
|
return (
|
|
520
532
|
// biome-ignore lint/suspicious/noArrayIndexKey:
|
|
521
|
-
/* @__PURE__ */ jsx14(FootprintPlatedHole, { hole }, i)
|
|
533
|
+
/* @__PURE__ */ jsx14(FootprintPlatedHole, { hole, isPin1 }, i)
|
|
522
534
|
);
|
|
523
535
|
})
|
|
524
536
|
] });
|
|
@@ -3851,15 +3863,69 @@ var SOD323 = () => {
|
|
|
3851
3863
|
] });
|
|
3852
3864
|
};
|
|
3853
3865
|
|
|
3866
|
+
// lib/sod-323F.tsx
|
|
3867
|
+
import { Colorize as Colorize29, Cuboid as Cuboid36, Hull as Hull20, Translate as Translate24, Union as Union18 } from "jscad-fiber";
|
|
3868
|
+
import { Fragment as Fragment51, jsx as jsx56, jsxs as jsxs54 } from "react/jsx-runtime";
|
|
3869
|
+
var SOD323F = () => {
|
|
3870
|
+
const fullWidth = 1.7;
|
|
3871
|
+
const bodyLength10 = 1.25;
|
|
3872
|
+
const bodyHeight = 0.725;
|
|
3873
|
+
const padWidth = 0.325;
|
|
3874
|
+
const padLength = 0.4;
|
|
3875
|
+
const padThickness = 0.175;
|
|
3876
|
+
const leftPadCenterX = -fullWidth / 2 - padLength / 2;
|
|
3877
|
+
const rightPadCenterX = fullWidth / 2 + padLength / 2;
|
|
3878
|
+
const taperOffset = 0.2;
|
|
3879
|
+
const straightHeight = padThickness;
|
|
3880
|
+
return /* @__PURE__ */ jsxs54(Fragment51, { children: [
|
|
3881
|
+
/* @__PURE__ */ jsx56(
|
|
3882
|
+
Cuboid36,
|
|
3883
|
+
{
|
|
3884
|
+
color: "#ccc",
|
|
3885
|
+
size: [padLength, padWidth, padThickness],
|
|
3886
|
+
center: [leftPadCenterX, 0, padThickness / 2]
|
|
3887
|
+
}
|
|
3888
|
+
),
|
|
3889
|
+
/* @__PURE__ */ jsx56(
|
|
3890
|
+
Cuboid36,
|
|
3891
|
+
{
|
|
3892
|
+
color: "#ccc",
|
|
3893
|
+
size: [padLength, padWidth, padThickness],
|
|
3894
|
+
center: [rightPadCenterX, 0, padThickness / 2]
|
|
3895
|
+
}
|
|
3896
|
+
),
|
|
3897
|
+
/* @__PURE__ */ jsx56(Colorize29, { color: "#222", children: /* @__PURE__ */ jsxs54(Union18, { children: [
|
|
3898
|
+
/* @__PURE__ */ jsx56(Translate24, { z: straightHeight / 2, children: /* @__PURE__ */ jsx56(Cuboid36, { size: [fullWidth, bodyLength10, straightHeight] }) }),
|
|
3899
|
+
/* @__PURE__ */ jsxs54(Hull20, { children: [
|
|
3900
|
+
/* @__PURE__ */ jsx56(Translate24, { z: straightHeight, children: /* @__PURE__ */ jsx56(Cuboid36, { size: [fullWidth, bodyLength10, 0.01] }) }),
|
|
3901
|
+
/* @__PURE__ */ jsx56(Translate24, { z: bodyHeight, children: /* @__PURE__ */ jsx56(
|
|
3902
|
+
Cuboid36,
|
|
3903
|
+
{
|
|
3904
|
+
size: [fullWidth - taperOffset, bodyLength10 - taperOffset, 0.01]
|
|
3905
|
+
}
|
|
3906
|
+
) })
|
|
3907
|
+
] })
|
|
3908
|
+
] }) }),
|
|
3909
|
+
/* @__PURE__ */ jsx56(
|
|
3910
|
+
Cuboid36,
|
|
3911
|
+
{
|
|
3912
|
+
color: "#777",
|
|
3913
|
+
size: [fullWidth / 3, bodyLength10 - taperOffset, 0.02],
|
|
3914
|
+
center: [leftPadCenterX + fullWidth / 4.4 + taperOffset, 0, bodyHeight]
|
|
3915
|
+
}
|
|
3916
|
+
)
|
|
3917
|
+
] });
|
|
3918
|
+
};
|
|
3919
|
+
|
|
3854
3920
|
// lib/Footprinter3d.tsx
|
|
3855
|
-
import { jsx as
|
|
3921
|
+
import { jsx as jsx57 } from "react/jsx-runtime";
|
|
3856
3922
|
var Footprinter3d = ({ footprint }) => {
|
|
3857
3923
|
const fpJson = fp3.string(footprint).json();
|
|
3858
3924
|
switch (fpJson.fn) {
|
|
3859
3925
|
case "dip":
|
|
3860
|
-
return /* @__PURE__ */
|
|
3926
|
+
return /* @__PURE__ */ jsx57(Dip, { numPins: fpJson.num_pins, pitch: fpJson.p, bodyWidth: fpJson.w });
|
|
3861
3927
|
case "tssop":
|
|
3862
|
-
return /* @__PURE__ */
|
|
3928
|
+
return /* @__PURE__ */ jsx57(
|
|
3863
3929
|
Tssop,
|
|
3864
3930
|
{
|
|
3865
3931
|
pinCount: fpJson.num_pins,
|
|
@@ -3870,7 +3936,7 @@ var Footprinter3d = ({ footprint }) => {
|
|
|
3870
3936
|
}
|
|
3871
3937
|
);
|
|
3872
3938
|
case "msop":
|
|
3873
|
-
return /* @__PURE__ */
|
|
3939
|
+
return /* @__PURE__ */ jsx57(
|
|
3874
3940
|
MSOP,
|
|
3875
3941
|
{
|
|
3876
3942
|
pinCount: fpJson.num_pins,
|
|
@@ -3881,7 +3947,7 @@ var Footprinter3d = ({ footprint }) => {
|
|
|
3881
3947
|
}
|
|
3882
3948
|
);
|
|
3883
3949
|
case "vssop":
|
|
3884
|
-
return /* @__PURE__ */
|
|
3950
|
+
return /* @__PURE__ */ jsx57(
|
|
3885
3951
|
VSSOP,
|
|
3886
3952
|
{
|
|
3887
3953
|
pinCount: fpJson.num_pins,
|
|
@@ -3893,7 +3959,7 @@ var Footprinter3d = ({ footprint }) => {
|
|
|
3893
3959
|
}
|
|
3894
3960
|
);
|
|
3895
3961
|
case "qfp":
|
|
3896
|
-
return /* @__PURE__ */
|
|
3962
|
+
return /* @__PURE__ */ jsx57(
|
|
3897
3963
|
QFP,
|
|
3898
3964
|
{
|
|
3899
3965
|
pinCount: fpJson.num_pins,
|
|
@@ -3904,12 +3970,12 @@ var Footprinter3d = ({ footprint }) => {
|
|
|
3904
3970
|
}
|
|
3905
3971
|
);
|
|
3906
3972
|
case "tqfp":
|
|
3907
|
-
return /* @__PURE__ */
|
|
3973
|
+
return /* @__PURE__ */ jsx57(tqfp_default, {});
|
|
3908
3974
|
case "lqfp":
|
|
3909
|
-
return /* @__PURE__ */
|
|
3975
|
+
return /* @__PURE__ */ jsx57(LQFP, { pinCount: fpJson.num_pins });
|
|
3910
3976
|
case "qfn": {
|
|
3911
3977
|
const hasThermalPad = typeof fpJson.thermalpad?.x === "number" && typeof fpJson.thermalpad?.y === "number";
|
|
3912
|
-
return /* @__PURE__ */
|
|
3978
|
+
return /* @__PURE__ */ jsx57(
|
|
3913
3979
|
qfn_default,
|
|
3914
3980
|
{
|
|
3915
3981
|
num_pins: fpJson.num_pins,
|
|
@@ -3927,7 +3993,7 @@ var Footprinter3d = ({ footprint }) => {
|
|
|
3927
3993
|
}
|
|
3928
3994
|
case "dfn": {
|
|
3929
3995
|
const hasThermalPad = typeof fpJson.thermalpad?.x === "number" && typeof fpJson.thermalpad?.y === "number";
|
|
3930
|
-
return /* @__PURE__ */
|
|
3996
|
+
return /* @__PURE__ */ jsx57(
|
|
3931
3997
|
DFN,
|
|
3932
3998
|
{
|
|
3933
3999
|
num_pins: fpJson.num_pins,
|
|
@@ -3945,45 +4011,47 @@ var Footprinter3d = ({ footprint }) => {
|
|
|
3945
4011
|
}
|
|
3946
4012
|
case "pinrow":
|
|
3947
4013
|
if (fpJson.male)
|
|
3948
|
-
return /* @__PURE__ */
|
|
4014
|
+
return /* @__PURE__ */ jsx57(PinRow, { numberOfPins: fpJson.num_pins, pitch: fpJson.p });
|
|
3949
4015
|
if (fpJson.female)
|
|
3950
|
-
return /* @__PURE__ */
|
|
4016
|
+
return /* @__PURE__ */ jsx57(FemaleHeader, { numberOfPins: fpJson.num_pins, pitch: fpJson.p });
|
|
3951
4017
|
case "cap": {
|
|
3952
4018
|
switch (fpJson.imperial) {
|
|
3953
4019
|
case "0402":
|
|
3954
|
-
return /* @__PURE__ */
|
|
4020
|
+
return /* @__PURE__ */ jsx57(A0402, { color: "#856c4d" });
|
|
3955
4021
|
case "0603":
|
|
3956
|
-
return /* @__PURE__ */
|
|
4022
|
+
return /* @__PURE__ */ jsx57(A0603, { color: "#856c4d" });
|
|
3957
4023
|
case "0805":
|
|
3958
|
-
return /* @__PURE__ */
|
|
4024
|
+
return /* @__PURE__ */ jsx57(A0805, { color: "#856c4d" });
|
|
3959
4025
|
case "0201":
|
|
3960
|
-
return /* @__PURE__ */
|
|
4026
|
+
return /* @__PURE__ */ jsx57(A0201, { color: "#856c4d" });
|
|
3961
4027
|
case "01005":
|
|
3962
|
-
return /* @__PURE__ */
|
|
4028
|
+
return /* @__PURE__ */ jsx57(A01005, { color: "#856c4d" });
|
|
3963
4029
|
case "1206":
|
|
3964
|
-
return /* @__PURE__ */
|
|
4030
|
+
return /* @__PURE__ */ jsx57(A1206, { color: "#856c4d" });
|
|
3965
4031
|
case "1210":
|
|
3966
|
-
return /* @__PURE__ */
|
|
4032
|
+
return /* @__PURE__ */ jsx57(A1210, { color: "#856c4d" });
|
|
3967
4033
|
case "2010":
|
|
3968
|
-
return /* @__PURE__ */
|
|
4034
|
+
return /* @__PURE__ */ jsx57(A2010, { color: "#856c4d" });
|
|
3969
4035
|
case "2512":
|
|
3970
|
-
return /* @__PURE__ */
|
|
4036
|
+
return /* @__PURE__ */ jsx57(A2512, { color: "#856c4d" });
|
|
3971
4037
|
}
|
|
3972
4038
|
}
|
|
3973
4039
|
case "sot235":
|
|
3974
|
-
return /* @__PURE__ */
|
|
4040
|
+
return /* @__PURE__ */ jsx57(SOT_235_default, {});
|
|
3975
4041
|
case "sot457":
|
|
3976
|
-
return /* @__PURE__ */
|
|
4042
|
+
return /* @__PURE__ */ jsx57(SOT457, {});
|
|
3977
4043
|
case "sot223":
|
|
3978
|
-
return /* @__PURE__ */
|
|
4044
|
+
return /* @__PURE__ */ jsx57(SOT223, {});
|
|
3979
4045
|
case "sot23w":
|
|
3980
|
-
return /* @__PURE__ */
|
|
4046
|
+
return /* @__PURE__ */ jsx57(SOT23W, {});
|
|
3981
4047
|
case "sot323":
|
|
3982
|
-
return /* @__PURE__ */
|
|
4048
|
+
return /* @__PURE__ */ jsx57(SOT323, {});
|
|
4049
|
+
case "sod323f":
|
|
4050
|
+
return /* @__PURE__ */ jsx57(SOD323F, {});
|
|
3983
4051
|
case "sot363":
|
|
3984
|
-
return /* @__PURE__ */
|
|
4052
|
+
return /* @__PURE__ */ jsx57(SOT_363_default, {});
|
|
3985
4053
|
case "pushbutton":
|
|
3986
|
-
return /* @__PURE__ */
|
|
4054
|
+
return /* @__PURE__ */ jsx57(
|
|
3987
4055
|
PushButton,
|
|
3988
4056
|
{
|
|
3989
4057
|
width: fpJson.w,
|
|
@@ -3992,7 +4060,7 @@ var Footprinter3d = ({ footprint }) => {
|
|
|
3992
4060
|
}
|
|
3993
4061
|
);
|
|
3994
4062
|
case "soic":
|
|
3995
|
-
return /* @__PURE__ */
|
|
4063
|
+
return /* @__PURE__ */ jsx57(
|
|
3996
4064
|
SOIC,
|
|
3997
4065
|
{
|
|
3998
4066
|
pinCount: fpJson.num_pins,
|
|
@@ -4003,39 +4071,39 @@ var Footprinter3d = ({ footprint }) => {
|
|
|
4003
4071
|
}
|
|
4004
4072
|
);
|
|
4005
4073
|
case "sod523":
|
|
4006
|
-
return /* @__PURE__ */
|
|
4074
|
+
return /* @__PURE__ */ jsx57(SOD523, {});
|
|
4007
4075
|
case "sod882":
|
|
4008
|
-
return /* @__PURE__ */
|
|
4076
|
+
return /* @__PURE__ */ jsx57(SOD882, {});
|
|
4009
4077
|
case "sma":
|
|
4010
|
-
return /* @__PURE__ */
|
|
4078
|
+
return /* @__PURE__ */ jsx57(SMA, {});
|
|
4011
4079
|
case "smb":
|
|
4012
|
-
return /* @__PURE__ */
|
|
4080
|
+
return /* @__PURE__ */ jsx57(SMB, {});
|
|
4013
4081
|
case "smc":
|
|
4014
|
-
return /* @__PURE__ */
|
|
4082
|
+
return /* @__PURE__ */ jsx57(SMC, {});
|
|
4015
4083
|
case "smf":
|
|
4016
|
-
return /* @__PURE__ */
|
|
4084
|
+
return /* @__PURE__ */ jsx57(SMF, {});
|
|
4017
4085
|
case "sod123f":
|
|
4018
|
-
return /* @__PURE__ */
|
|
4086
|
+
return /* @__PURE__ */ jsx57(SOD123F, {});
|
|
4019
4087
|
case "sod123fl":
|
|
4020
|
-
return /* @__PURE__ */
|
|
4088
|
+
return /* @__PURE__ */ jsx57(SOD123FL, {});
|
|
4021
4089
|
case "sod123w":
|
|
4022
|
-
return /* @__PURE__ */
|
|
4090
|
+
return /* @__PURE__ */ jsx57(SOD123W, {});
|
|
4023
4091
|
case "sod128":
|
|
4024
|
-
return /* @__PURE__ */
|
|
4092
|
+
return /* @__PURE__ */ jsx57(SOD128, {});
|
|
4025
4093
|
case "sod323":
|
|
4026
|
-
return /* @__PURE__ */
|
|
4094
|
+
return /* @__PURE__ */ jsx57(SOD323, {});
|
|
4027
4095
|
case "sod923":
|
|
4028
|
-
return /* @__PURE__ */
|
|
4096
|
+
return /* @__PURE__ */ jsx57(SOD923, {});
|
|
4029
4097
|
case "hc49":
|
|
4030
|
-
return /* @__PURE__ */
|
|
4098
|
+
return /* @__PURE__ */ jsx57(HC49, {});
|
|
4031
4099
|
case "micromelf":
|
|
4032
|
-
return /* @__PURE__ */
|
|
4100
|
+
return /* @__PURE__ */ jsx57(MicroMELF, {});
|
|
4033
4101
|
case "minimelf":
|
|
4034
|
-
return /* @__PURE__ */
|
|
4102
|
+
return /* @__PURE__ */ jsx57(MINIMELF, {});
|
|
4035
4103
|
case "melf":
|
|
4036
|
-
return /* @__PURE__ */
|
|
4104
|
+
return /* @__PURE__ */ jsx57(MELF, {});
|
|
4037
4105
|
case "ms012":
|
|
4038
|
-
return /* @__PURE__ */
|
|
4106
|
+
return /* @__PURE__ */ jsx57(
|
|
4039
4107
|
MS012,
|
|
4040
4108
|
{
|
|
4041
4109
|
pinCount: fpJson.num_pins,
|
|
@@ -4045,7 +4113,7 @@ var Footprinter3d = ({ footprint }) => {
|
|
|
4045
4113
|
}
|
|
4046
4114
|
);
|
|
4047
4115
|
case "ms013":
|
|
4048
|
-
return /* @__PURE__ */
|
|
4116
|
+
return /* @__PURE__ */ jsx57(
|
|
4049
4117
|
MS013,
|
|
4050
4118
|
{
|
|
4051
4119
|
pinCount: fpJson.num_pins,
|
|
@@ -4055,39 +4123,39 @@ var Footprinter3d = ({ footprint }) => {
|
|
|
4055
4123
|
}
|
|
4056
4124
|
);
|
|
4057
4125
|
case "sot723":
|
|
4058
|
-
return /* @__PURE__ */
|
|
4126
|
+
return /* @__PURE__ */ jsx57(SOT723, {});
|
|
4059
4127
|
case "to220":
|
|
4060
|
-
return /* @__PURE__ */
|
|
4128
|
+
return /* @__PURE__ */ jsx57(TO220, {});
|
|
4061
4129
|
case "to92":
|
|
4062
|
-
return /* @__PURE__ */
|
|
4130
|
+
return /* @__PURE__ */ jsx57(TO92, {});
|
|
4063
4131
|
}
|
|
4064
4132
|
const colorMatch = footprint.match(/_color\(([^)]+)\)/);
|
|
4065
4133
|
const color = colorMatch ? colorMatch[1] : void 0;
|
|
4066
4134
|
switch (fpJson.imperial) {
|
|
4067
4135
|
case "0402":
|
|
4068
|
-
return /* @__PURE__ */
|
|
4136
|
+
return /* @__PURE__ */ jsx57(A0402, { color });
|
|
4069
4137
|
case "0603":
|
|
4070
|
-
return /* @__PURE__ */
|
|
4138
|
+
return /* @__PURE__ */ jsx57(A0603, { color });
|
|
4071
4139
|
case "0805":
|
|
4072
|
-
return /* @__PURE__ */
|
|
4140
|
+
return /* @__PURE__ */ jsx57(A0805, { color });
|
|
4073
4141
|
case "0201":
|
|
4074
|
-
return /* @__PURE__ */
|
|
4142
|
+
return /* @__PURE__ */ jsx57(A0201, { color });
|
|
4075
4143
|
case "01005":
|
|
4076
|
-
return /* @__PURE__ */
|
|
4144
|
+
return /* @__PURE__ */ jsx57(A01005, { color });
|
|
4077
4145
|
case "1206":
|
|
4078
|
-
return /* @__PURE__ */
|
|
4146
|
+
return /* @__PURE__ */ jsx57(A1206, { color });
|
|
4079
4147
|
case "1210":
|
|
4080
|
-
return /* @__PURE__ */
|
|
4148
|
+
return /* @__PURE__ */ jsx57(A1210, { color });
|
|
4081
4149
|
case "2010":
|
|
4082
|
-
return /* @__PURE__ */
|
|
4150
|
+
return /* @__PURE__ */ jsx57(A2010, { color });
|
|
4083
4151
|
case "2512":
|
|
4084
|
-
return /* @__PURE__ */
|
|
4152
|
+
return /* @__PURE__ */ jsx57(A2512, { color });
|
|
4085
4153
|
}
|
|
4086
4154
|
return null;
|
|
4087
4155
|
};
|
|
4088
4156
|
|
|
4089
4157
|
// lib/SOT-23-3P.tsx
|
|
4090
|
-
import { Fragment as
|
|
4158
|
+
import { Fragment as Fragment52, jsx as jsx58, jsxs as jsxs55 } from "react/jsx-runtime";
|
|
4091
4159
|
var SOT233P = ({ fullWidth = 2.9, fullLength: fullLength10 = 2.8 }) => {
|
|
4092
4160
|
const bodyWidth = 1.3;
|
|
4093
4161
|
const bodyLength10 = 2.9;
|
|
@@ -4098,8 +4166,8 @@ var SOT233P = ({ fullWidth = 2.9, fullLength: fullLength10 = 2.8 }) => {
|
|
|
4098
4166
|
const padContactLength = 0.4;
|
|
4099
4167
|
const padThickness = leadThickness / 2;
|
|
4100
4168
|
const extendedBodyDistance = (fullWidth - bodyWidth) / 2 + 0.3;
|
|
4101
|
-
return /* @__PURE__ */
|
|
4102
|
-
/* @__PURE__ */
|
|
4169
|
+
return /* @__PURE__ */ jsxs55(Fragment52, { children: [
|
|
4170
|
+
/* @__PURE__ */ jsx58(
|
|
4103
4171
|
SmdChipLead,
|
|
4104
4172
|
{
|
|
4105
4173
|
rotation: Math.PI,
|
|
@@ -4116,7 +4184,7 @@ var SOT233P = ({ fullWidth = 2.9, fullLength: fullLength10 = 2.8 }) => {
|
|
|
4116
4184
|
},
|
|
4117
4185
|
1
|
|
4118
4186
|
),
|
|
4119
|
-
/* @__PURE__ */
|
|
4187
|
+
/* @__PURE__ */ jsx58(
|
|
4120
4188
|
SmdChipLead,
|
|
4121
4189
|
{
|
|
4122
4190
|
rotation: Math.PI,
|
|
@@ -4133,7 +4201,7 @@ var SOT233P = ({ fullWidth = 2.9, fullLength: fullLength10 = 2.8 }) => {
|
|
|
4133
4201
|
},
|
|
4134
4202
|
2
|
|
4135
4203
|
),
|
|
4136
|
-
/* @__PURE__ */
|
|
4204
|
+
/* @__PURE__ */ jsx58(
|
|
4137
4205
|
SmdChipLead,
|
|
4138
4206
|
{
|
|
4139
4207
|
position: {
|
|
@@ -4149,7 +4217,7 @@ var SOT233P = ({ fullWidth = 2.9, fullLength: fullLength10 = 2.8 }) => {
|
|
|
4149
4217
|
},
|
|
4150
4218
|
3
|
|
4151
4219
|
),
|
|
4152
|
-
/* @__PURE__ */
|
|
4220
|
+
/* @__PURE__ */ jsx58(
|
|
4153
4221
|
ChipBody,
|
|
4154
4222
|
{
|
|
4155
4223
|
center: { x: 0, y: 0, z: 0 },
|
|
@@ -4162,8 +4230,8 @@ var SOT233P = ({ fullWidth = 2.9, fullLength: fullLength10 = 2.8 }) => {
|
|
|
4162
4230
|
};
|
|
4163
4231
|
|
|
4164
4232
|
// lib/SOT-563.tsx
|
|
4165
|
-
import { Cuboid as
|
|
4166
|
-
import { Fragment as
|
|
4233
|
+
import { Cuboid as Cuboid37, Translate as Translate25, Rotate as Rotate10, Colorize as Colorize30 } from "jscad-fiber";
|
|
4234
|
+
import { Fragment as Fragment53, jsx as jsx59, jsxs as jsxs56 } from "react/jsx-runtime";
|
|
4167
4235
|
var SOT563 = ({ fullWidth = 1.94, fullLength: fullLength10 = 1.6 }) => {
|
|
4168
4236
|
const bodyWidth = 1.2;
|
|
4169
4237
|
const bodyLength10 = 1.6;
|
|
@@ -4173,28 +4241,28 @@ var SOT563 = ({ fullWidth = 1.94, fullLength: fullLength10 = 1.6 }) => {
|
|
|
4173
4241
|
const leadHeight = 0.13;
|
|
4174
4242
|
const leadSpacing = 0.5;
|
|
4175
4243
|
const bodyZOffset = -0.4;
|
|
4176
|
-
return /* @__PURE__ */
|
|
4177
|
-
/* @__PURE__ */
|
|
4244
|
+
return /* @__PURE__ */ jsxs56(Fragment53, { children: [
|
|
4245
|
+
/* @__PURE__ */ jsx59(Rotate10, { rotation: [45 * Math.PI, 0, 0], children: /* @__PURE__ */ jsx59(Translate25, { center: [0, 0, bodyZOffset], children: /* @__PURE__ */ jsx59(Colorize30, { color: "grey", children: /* @__PURE__ */ jsx59(Cuboid37, { size: [bodyWidth, bodyLength10, bodyHeight] }) }) }) }),
|
|
4178
4246
|
[-1, 0, 1].flatMap((yOffset, index) => [
|
|
4179
4247
|
// Left lead
|
|
4180
|
-
/* @__PURE__ */
|
|
4181
|
-
|
|
4248
|
+
/* @__PURE__ */ jsx59(
|
|
4249
|
+
Translate25,
|
|
4182
4250
|
{
|
|
4183
4251
|
center: [
|
|
4184
4252
|
-bodyWidth / 2 - 0.03,
|
|
4185
4253
|
yOffset * leadSpacing,
|
|
4186
4254
|
leadHeight / 2
|
|
4187
4255
|
],
|
|
4188
|
-
children: /* @__PURE__ */
|
|
4256
|
+
children: /* @__PURE__ */ jsx59(Cuboid37, { size: [leadLength, leadWidth, leadHeight] })
|
|
4189
4257
|
},
|
|
4190
4258
|
`left-${index}`
|
|
4191
4259
|
),
|
|
4192
4260
|
// Right lead
|
|
4193
|
-
/* @__PURE__ */
|
|
4194
|
-
|
|
4261
|
+
/* @__PURE__ */ jsx59(
|
|
4262
|
+
Translate25,
|
|
4195
4263
|
{
|
|
4196
4264
|
center: [bodyWidth / 2 + 0.03, yOffset * leadSpacing, leadHeight / 2],
|
|
4197
|
-
children: /* @__PURE__ */
|
|
4265
|
+
children: /* @__PURE__ */ jsx59(Cuboid37, { size: [leadLength, leadWidth, leadHeight] })
|
|
4198
4266
|
},
|
|
4199
4267
|
`right-${index}`
|
|
4200
4268
|
)
|
|
@@ -4203,7 +4271,7 @@ var SOT563 = ({ fullWidth = 1.94, fullLength: fullLength10 = 1.6 }) => {
|
|
|
4203
4271
|
};
|
|
4204
4272
|
|
|
4205
4273
|
// lib/sod-123.tsx
|
|
4206
|
-
import { Fragment as
|
|
4274
|
+
import { Fragment as Fragment54, jsx as jsx60, jsxs as jsxs57 } from "react/jsx-runtime";
|
|
4207
4275
|
var SOD123 = ({ fullWidth = 3.8, fullLength: fullLength10 = 1.6 }) => {
|
|
4208
4276
|
const bodyWidth = 2.9;
|
|
4209
4277
|
const bodyLength10 = 1.3;
|
|
@@ -4214,8 +4282,8 @@ var SOD123 = ({ fullWidth = 3.8, fullLength: fullLength10 = 1.6 }) => {
|
|
|
4214
4282
|
const padContactLength = 0.4;
|
|
4215
4283
|
const padThickness = leadThickness / 2;
|
|
4216
4284
|
const bodyDistance = (fullWidth - bodyWidth) / 2;
|
|
4217
|
-
return /* @__PURE__ */
|
|
4218
|
-
/* @__PURE__ */
|
|
4285
|
+
return /* @__PURE__ */ jsxs57(Fragment54, { children: [
|
|
4286
|
+
/* @__PURE__ */ jsx60(
|
|
4219
4287
|
SmdChipLead,
|
|
4220
4288
|
{
|
|
4221
4289
|
position: {
|
|
@@ -4231,7 +4299,7 @@ var SOD123 = ({ fullWidth = 3.8, fullLength: fullLength10 = 1.6 }) => {
|
|
|
4231
4299
|
},
|
|
4232
4300
|
1
|
|
4233
4301
|
),
|
|
4234
|
-
/* @__PURE__ */
|
|
4302
|
+
/* @__PURE__ */ jsx60(
|
|
4235
4303
|
SmdChipLead,
|
|
4236
4304
|
{
|
|
4237
4305
|
rotation: Math.PI,
|
|
@@ -4248,7 +4316,7 @@ var SOD123 = ({ fullWidth = 3.8, fullLength: fullLength10 = 1.6 }) => {
|
|
|
4248
4316
|
},
|
|
4249
4317
|
2
|
|
4250
4318
|
),
|
|
4251
|
-
/* @__PURE__ */
|
|
4319
|
+
/* @__PURE__ */ jsx60(
|
|
4252
4320
|
ChipBody,
|
|
4253
4321
|
{
|
|
4254
4322
|
center: { x: 0, y: 0, z: 0 },
|
|
@@ -4297,6 +4365,7 @@ export {
|
|
|
4297
4365
|
SOD123W,
|
|
4298
4366
|
SOD128,
|
|
4299
4367
|
SOD323,
|
|
4368
|
+
SOD323F,
|
|
4300
4369
|
SOD523,
|
|
4301
4370
|
SOD882,
|
|
4302
4371
|
SOD923,
|