@tscircuit/footprinter 0.0.332 → 0.0.334

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.js CHANGED
@@ -2148,7 +2148,7 @@ var sot23_def = base_def.extend({
2148
2148
  num_pins: z20.number().default(3),
2149
2149
  w: z20.string().default("1.92mm"),
2150
2150
  h: z20.string().default("2.74mm"),
2151
- pl: z20.string().default("1.32mm"),
2151
+ pl: z20.string().default("1.325mm"),
2152
2152
  pw: z20.string().default("0.6mm"),
2153
2153
  p: z20.string().default("0.95mm"),
2154
2154
  string: z20.string().optional()
@@ -2192,12 +2192,12 @@ var sot23 = (raw_params) => {
2192
2192
  var getCcwSot23Coords = (parameters) => {
2193
2193
  const { pn, w, h, pl, p } = parameters;
2194
2194
  if (pn === 1) {
2195
- return { x: -1.155, y: p };
2195
+ return { x: -1.1375, y: p };
2196
2196
  }
2197
2197
  if (pn === 2) {
2198
- return { x: -1.155, y: -p };
2198
+ return { x: -1.1375, y: -p };
2199
2199
  }
2200
- return { x: 1.15, y: 0 };
2200
+ return { x: 1.1375, y: 0 };
2201
2201
  };
2202
2202
  var sot23_3 = (parameters) => {
2203
2203
  const pads = [];
@@ -2229,8 +2229,8 @@ var sot23_3 = (parameters) => {
2229
2229
  const pl_val = Number.parseFloat(parameters.pl);
2230
2230
  const pw_val = Number.parseFloat(parameters.pw);
2231
2231
  const p_val = Number.parseFloat(parameters.p);
2232
- const crtMinX = -1.155 - pl_val / 2 - courtyardPadding;
2233
- const crtMaxX = 1.15 + pl_val / 2 + courtyardPadding;
2232
+ const crtMinX = -1.1375 - pl_val / 2 - courtyardPadding;
2233
+ const crtMaxX = 1.1375 + pl_val / 2 + courtyardPadding;
2234
2234
  const crtMinY = -(p_val + pw_val / 2) - courtyardPadding;
2235
2235
  const crtMaxY = p_val + pw_val / 2 + courtyardPadding;
2236
2236
  const courtyard = {
@@ -2247,19 +2247,19 @@ var sot23_3 = (parameters) => {
2247
2247
  var getCcwSot235Coords = (parameters) => {
2248
2248
  const { p, h, pn } = parameters;
2249
2249
  if (pn === 1) {
2250
- return { x: -h / 2 - 0.5, y: p };
2250
+ return { x: -1.1375, y: p };
2251
2251
  }
2252
2252
  if (pn === 2) {
2253
- return { x: -h / 2 - 0.5, y: 0 };
2253
+ return { x: -1.1375, y: 0 };
2254
2254
  }
2255
2255
  if (pn === 3) {
2256
- return { x: -h / 2 - 0.5, y: -p };
2256
+ return { x: -1.1375, y: -p };
2257
2257
  }
2258
2258
  if (pn === 4) {
2259
- return { x: h / 2 + 0.5, y: -p };
2259
+ return { x: 1.1375, y: -p };
2260
2260
  }
2261
2261
  if (pn === 5) {
2262
- return { x: h / 2 + 0.5, y: p };
2262
+ return { x: 1.1375, y: p };
2263
2263
  }
2264
2264
  throw new Error("Invalid pin number");
2265
2265
  };
@@ -2349,8 +2349,9 @@ var sot23_5 = (parameters) => {
2349
2349
  const p_val = Number.parseFloat(parameters.p);
2350
2350
  const silkY = height / 2 + p_val / 1.3;
2351
2351
  const padYExtent = p_val + pw_val / 2;
2352
- const crtMinX = -(height / 2 + 0.5 + pl_val / 2) - courtyardPadding;
2353
- const crtMaxX = height / 2 + 0.5 + pl_val / 2 + courtyardPadding;
2352
+ const padXExtent = 1.1375 + pl_val / 2;
2353
+ const crtMinX = -padXExtent - courtyardPadding;
2354
+ const crtMaxX = padXExtent + courtyardPadding;
2354
2355
  const crtMinY = -Math.max(silkY, padYExtent) - courtyardPadding;
2355
2356
  const crtMaxY = Math.max(silkY, padYExtent) + courtyardPadding;
2356
2357
  const courtyard = {
@@ -10579,7 +10580,7 @@ function isNotNull(value) {
10579
10580
 
10580
10581
  // src/footprinter.ts
10581
10582
  var normalizeDefinition = (def) => {
10582
- return def.trim().replace(/^sot-223-(\d+)(?=_|$)/i, "sot223_$1").replace(/^to-220f-(\d+)(?=_|$)/i, "to220f_$1");
10583
+ return def.trim().replace(/^sot-223-(\d+)(?=_|$)/i, "sot223_$1").replace(/^to-220f-(\d+)(?=_|$)/i, "to220f_$1").replace(/^jst_(ph|sh|zh)_(\d+)(?=_|$)/i, "jst$2_$1");
10583
10584
  };
10584
10585
  var string2 = (def) => {
10585
10586
  let fp2 = footprinter();