@tscircuit/props 0.0.548 → 0.0.550

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
@@ -17981,54 +17981,76 @@ var voltageProbeProps = commonComponentProps.omit({ name: true }).extend({
17981
17981
  label: z102.string().optional(),
17982
17982
  center: z102.number().optional(),
17983
17983
  offsetDivs: z102.number().optional(),
17984
- unitsPerDiv: z102.number().optional(),
17985
- color: z102.string().optional()
17984
+ unitsPerDiv: z102.number().optional()
17986
17985
  }).optional()
17987
17986
  });
17988
17987
  expectTypesMatch(true);
17989
17988
 
17989
+ // lib/components/ammeter.ts
17990
+ import { z as z103 } from "zod";
17991
+ var ammeterPinLabels = ["pin1", "pin2", "pos", "neg"];
17992
+ var hasAmmeterConnectionPair = (connections) => {
17993
+ return connections.pos !== void 0 && connections.neg !== void 0 || connections.pin1 !== void 0 && connections.pin2 !== void 0;
17994
+ };
17995
+ var ammeterDisplayOptions = z103.object({
17996
+ label: z103.string().optional(),
17997
+ center: z103.number().optional(),
17998
+ offsetDivs: z103.number().optional(),
17999
+ unitsPerDiv: z103.number().optional()
18000
+ });
18001
+ var ammeterProps = commonComponentProps.extend({
18002
+ connections: createConnectionsProp(ammeterPinLabels).refine(
18003
+ hasAmmeterConnectionPair,
18004
+ "Ammeter connections must include either pos/neg or pin1/pin2"
18005
+ ),
18006
+ color: z103.string().optional(),
18007
+ display: ammeterDisplayOptions.optional()
18008
+ });
18009
+ var ammeterPins = ammeterPinLabels;
18010
+ expectTypesMatch(true);
18011
+
17990
18012
  // lib/components/schematic-arc.ts
17991
18013
  import { distance as distance29, point as point5, rotation as rotation7 } from "circuit-json";
17992
- import { z as z103 } from "zod";
17993
- var schematicArcProps = z103.object({
18014
+ import { z as z104 } from "zod";
18015
+ var schematicArcProps = z104.object({
17994
18016
  center: point5,
17995
18017
  radius: distance29,
17996
18018
  startAngleDegrees: rotation7,
17997
18019
  endAngleDegrees: rotation7,
17998
- direction: z103.enum(["clockwise", "counterclockwise"]).default("counterclockwise"),
18020
+ direction: z104.enum(["clockwise", "counterclockwise"]).default("counterclockwise"),
17999
18021
  strokeWidth: distance29.optional(),
18000
- color: z103.string().optional(),
18001
- isDashed: z103.boolean().optional().default(false)
18022
+ color: z104.string().optional(),
18023
+ isDashed: z104.boolean().optional().default(false)
18002
18024
  });
18003
18025
  expectTypesMatch(true);
18004
18026
 
18005
18027
  // lib/components/toolingrail.ts
18006
- import { z as z104 } from "zod";
18007
- var toolingrailProps = z104.object({
18008
- children: z104.any().optional()
18028
+ import { z as z105 } from "zod";
18029
+ var toolingrailProps = z105.object({
18030
+ children: z105.any().optional()
18009
18031
  });
18010
18032
  expectTypesMatch(true);
18011
18033
 
18012
18034
  // lib/components/schematic-box.ts
18013
18035
  import { distance as distance30 } from "circuit-json";
18014
- import { z as z105 } from "zod";
18015
- var schematicBoxProps = z105.object({
18036
+ import { z as z106 } from "zod";
18037
+ var schematicBoxProps = z106.object({
18016
18038
  schX: distance30.optional(),
18017
18039
  schY: distance30.optional(),
18018
18040
  width: distance30.optional(),
18019
18041
  height: distance30.optional(),
18020
- overlay: z105.array(z105.string()).optional(),
18042
+ overlay: z106.array(z106.string()).optional(),
18021
18043
  padding: distance30.optional(),
18022
18044
  paddingLeft: distance30.optional(),
18023
18045
  paddingRight: distance30.optional(),
18024
18046
  paddingTop: distance30.optional(),
18025
18047
  paddingBottom: distance30.optional(),
18026
- title: z105.string().optional(),
18048
+ title: z106.string().optional(),
18027
18049
  titleAlignment: ninePointAnchor.default("top_left"),
18028
- titleColor: z105.string().optional(),
18050
+ titleColor: z106.string().optional(),
18029
18051
  titleFontSize: distance30.optional(),
18030
- titleInside: z105.boolean().default(false),
18031
- strokeStyle: z105.enum(["solid", "dashed"]).default("solid")
18052
+ titleInside: z106.boolean().default(false),
18053
+ strokeStyle: z106.enum(["solid", "dashed"]).default("solid")
18032
18054
  }).refine(
18033
18055
  (elm) => elm.width !== void 0 && elm.height !== void 0 || Array.isArray(elm.overlay) && elm.overlay.length > 0,
18034
18056
  {
@@ -18044,15 +18066,15 @@ expectTypesMatch(true);
18044
18066
 
18045
18067
  // lib/components/schematic-circle.ts
18046
18068
  import { distance as distance31, point as point6 } from "circuit-json";
18047
- import { z as z106 } from "zod";
18048
- var schematicCircleProps = z106.object({
18069
+ import { z as z107 } from "zod";
18070
+ var schematicCircleProps = z107.object({
18049
18071
  center: point6,
18050
18072
  radius: distance31,
18051
18073
  strokeWidth: distance31.optional(),
18052
- color: z106.string().optional(),
18053
- isFilled: z106.boolean().optional().default(false),
18054
- fillColor: z106.string().optional(),
18055
- isDashed: z106.boolean().optional().default(false)
18074
+ color: z107.string().optional(),
18075
+ isFilled: z107.boolean().optional().default(false),
18076
+ fillColor: z107.string().optional(),
18077
+ isDashed: z107.boolean().optional().default(false)
18056
18078
  });
18057
18079
  expectTypesMatch(
18058
18080
  true
@@ -18060,32 +18082,32 @@ expectTypesMatch(
18060
18082
 
18061
18083
  // lib/components/schematic-rect.ts
18062
18084
  import { distance as distance32, rotation as rotation8 } from "circuit-json";
18063
- import { z as z107 } from "zod";
18064
- var schematicRectProps = z107.object({
18085
+ import { z as z108 } from "zod";
18086
+ var schematicRectProps = z108.object({
18065
18087
  schX: distance32.optional(),
18066
18088
  schY: distance32.optional(),
18067
18089
  width: distance32,
18068
18090
  height: distance32,
18069
18091
  rotation: rotation8.default(0),
18070
18092
  strokeWidth: distance32.optional(),
18071
- color: z107.string().optional(),
18072
- isFilled: z107.boolean().optional().default(false),
18073
- fillColor: z107.string().optional(),
18074
- isDashed: z107.boolean().optional().default(false)
18093
+ color: z108.string().optional(),
18094
+ isFilled: z108.boolean().optional().default(false),
18095
+ fillColor: z108.string().optional(),
18096
+ isDashed: z108.boolean().optional().default(false)
18075
18097
  });
18076
18098
  expectTypesMatch(true);
18077
18099
 
18078
18100
  // lib/components/schematic-line.ts
18079
18101
  import { distance as distance33 } from "circuit-json";
18080
- import { z as z108 } from "zod";
18081
- var schematicLineProps = z108.object({
18102
+ import { z as z109 } from "zod";
18103
+ var schematicLineProps = z109.object({
18082
18104
  x1: distance33,
18083
18105
  y1: distance33,
18084
18106
  x2: distance33,
18085
18107
  y2: distance33,
18086
18108
  strokeWidth: distance33.optional(),
18087
- color: z108.string().optional(),
18088
- isDashed: z108.boolean().optional().default(false),
18109
+ color: z109.string().optional(),
18110
+ isDashed: z109.boolean().optional().default(false),
18089
18111
  dashLength: distance33.optional(),
18090
18112
  dashGap: distance33.optional()
18091
18113
  });
@@ -18093,11 +18115,11 @@ expectTypesMatch(true);
18093
18115
 
18094
18116
  // lib/components/schematic-text.ts
18095
18117
  import { distance as distance34, rotation as rotation9 } from "circuit-json";
18096
- import { z as z110 } from "zod";
18118
+ import { z as z111 } from "zod";
18097
18119
 
18098
18120
  // lib/common/fivePointAnchor.ts
18099
- import { z as z109 } from "zod";
18100
- var fivePointAnchor = z109.enum([
18121
+ import { z as z110 } from "zod";
18122
+ var fivePointAnchor = z110.enum([
18101
18123
  "center",
18102
18124
  "left",
18103
18125
  "right",
@@ -18106,39 +18128,39 @@ var fivePointAnchor = z109.enum([
18106
18128
  ]);
18107
18129
 
18108
18130
  // lib/components/schematic-text.ts
18109
- var schematicTextProps = z110.object({
18131
+ var schematicTextProps = z111.object({
18110
18132
  schX: distance34.optional(),
18111
18133
  schY: distance34.optional(),
18112
- text: z110.string(),
18113
- fontSize: z110.number().default(1),
18114
- anchor: z110.union([fivePointAnchor.describe("legacy"), ninePointAnchor]).default("center"),
18115
- color: z110.string().default("#000000"),
18134
+ text: z111.string(),
18135
+ fontSize: z111.number().default(1),
18136
+ anchor: z111.union([fivePointAnchor.describe("legacy"), ninePointAnchor]).default("center"),
18137
+ color: z111.string().default("#000000"),
18116
18138
  schRotation: rotation9.default(0)
18117
18139
  });
18118
18140
  expectTypesMatch(true);
18119
18141
 
18120
18142
  // lib/components/schematic-path.ts
18121
18143
  import { distance as distance35, point as point7 } from "circuit-json";
18122
- import { z as z111 } from "zod";
18123
- var schematicPathProps = z111.object({
18124
- points: z111.array(point7).optional(),
18125
- svgPath: z111.string().optional(),
18144
+ import { z as z112 } from "zod";
18145
+ var schematicPathProps = z112.object({
18146
+ points: z112.array(point7).optional(),
18147
+ svgPath: z112.string().optional(),
18126
18148
  strokeWidth: distance35.optional(),
18127
- strokeColor: z111.string().optional(),
18149
+ strokeColor: z112.string().optional(),
18128
18150
  dashLength: distance35.optional(),
18129
18151
  dashGap: distance35.optional(),
18130
- isFilled: z111.boolean().optional().default(false),
18131
- fillColor: z111.string().optional()
18152
+ isFilled: z112.boolean().optional().default(false),
18153
+ fillColor: z112.string().optional()
18132
18154
  });
18133
18155
  expectTypesMatch(true);
18134
18156
 
18135
18157
  // lib/components/schematic-table.ts
18136
18158
  import { distance as distance36 } from "circuit-json";
18137
- import { z as z112 } from "zod";
18138
- var schematicTableProps = z112.object({
18159
+ import { z as z113 } from "zod";
18160
+ var schematicTableProps = z113.object({
18139
18161
  schX: distance36.optional(),
18140
18162
  schY: distance36.optional(),
18141
- children: z112.any().optional(),
18163
+ children: z113.any().optional(),
18142
18164
  cellPadding: distance36.optional(),
18143
18165
  borderWidth: distance36.optional(),
18144
18166
  anchor: ninePointAnchor.optional(),
@@ -18148,34 +18170,34 @@ expectTypesMatch(true);
18148
18170
 
18149
18171
  // lib/components/schematic-row.ts
18150
18172
  import { distance as distance37 } from "circuit-json";
18151
- import { z as z113 } from "zod";
18152
- var schematicRowProps = z113.object({
18153
- children: z113.any().optional(),
18173
+ import { z as z114 } from "zod";
18174
+ var schematicRowProps = z114.object({
18175
+ children: z114.any().optional(),
18154
18176
  height: distance37.optional()
18155
18177
  });
18156
18178
  expectTypesMatch(true);
18157
18179
 
18158
18180
  // lib/components/schematic-cell.ts
18159
18181
  import { distance as distance38 } from "circuit-json";
18160
- import { z as z114 } from "zod";
18161
- var schematicCellProps = z114.object({
18162
- children: z114.string().optional(),
18163
- horizontalAlign: z114.enum(["left", "center", "right"]).optional(),
18164
- verticalAlign: z114.enum(["top", "middle", "bottom"]).optional(),
18182
+ import { z as z115 } from "zod";
18183
+ var schematicCellProps = z115.object({
18184
+ children: z115.string().optional(),
18185
+ horizontalAlign: z115.enum(["left", "center", "right"]).optional(),
18186
+ verticalAlign: z115.enum(["top", "middle", "bottom"]).optional(),
18165
18187
  fontSize: distance38.optional(),
18166
- rowSpan: z114.number().optional(),
18167
- colSpan: z114.number().optional(),
18188
+ rowSpan: z115.number().optional(),
18189
+ colSpan: z115.number().optional(),
18168
18190
  width: distance38.optional(),
18169
- text: z114.string().optional()
18191
+ text: z115.string().optional()
18170
18192
  });
18171
18193
  expectTypesMatch(true);
18172
18194
 
18173
18195
  // lib/components/schematic-section.ts
18174
18196
  import { distance as distance39 } from "circuit-json";
18175
- import { z as z115 } from "zod";
18176
- var schematicSectionProps = z115.object({
18177
- displayName: z115.string().optional(),
18178
- name: z115.string(),
18197
+ import { z as z116 } from "zod";
18198
+ var schematicSectionProps = z116.object({
18199
+ displayName: z116.string().optional(),
18200
+ name: z116.string(),
18179
18201
  sectionTitleFontSize: distance39.optional()
18180
18202
  });
18181
18203
  expectTypesMatch(
@@ -18184,40 +18206,40 @@ expectTypesMatch(
18184
18206
 
18185
18207
  // lib/components/copper-text.ts
18186
18208
  import { layer_ref as layer_ref10, length as length8 } from "circuit-json";
18187
- import { z as z116 } from "zod";
18209
+ import { z as z117 } from "zod";
18188
18210
  var copperTextProps = pcbLayoutProps.extend({
18189
- text: z116.string(),
18211
+ text: z117.string(),
18190
18212
  anchorAlignment: ninePointAnchor.default("center"),
18191
- font: z116.enum(["tscircuit2024"]).optional(),
18213
+ font: z117.enum(["tscircuit2024"]).optional(),
18192
18214
  fontSize: length8.optional(),
18193
- layers: z116.array(layer_ref10).optional(),
18194
- knockout: z116.boolean().optional(),
18195
- mirrored: z116.boolean().optional()
18215
+ layers: z117.array(layer_ref10).optional(),
18216
+ knockout: z117.boolean().optional(),
18217
+ mirrored: z117.boolean().optional()
18196
18218
  });
18197
18219
 
18198
18220
  // lib/components/silkscreen-text.ts
18199
18221
  import { layer_ref as layer_ref11, length as length9 } from "circuit-json";
18200
- import { z as z117 } from "zod";
18222
+ import { z as z118 } from "zod";
18201
18223
  var silkscreenTextProps = pcbLayoutProps.extend({
18202
- text: z117.string(),
18224
+ text: z118.string(),
18203
18225
  anchorAlignment: ninePointAnchor.default("center"),
18204
- font: z117.enum(["tscircuit2024"]).optional(),
18226
+ font: z118.enum(["tscircuit2024"]).optional(),
18205
18227
  fontSize: length9.optional(),
18206
18228
  /**
18207
18229
  * If true, text will knock out underlying silkscreen
18208
18230
  */
18209
- isKnockout: z117.boolean().optional(),
18231
+ isKnockout: z118.boolean().optional(),
18210
18232
  knockoutPadding: length9.optional(),
18211
18233
  knockoutPaddingLeft: length9.optional(),
18212
18234
  knockoutPaddingRight: length9.optional(),
18213
18235
  knockoutPaddingTop: length9.optional(),
18214
18236
  knockoutPaddingBottom: length9.optional(),
18215
- layers: z117.array(layer_ref11).optional()
18237
+ layers: z118.array(layer_ref11).optional()
18216
18238
  });
18217
18239
 
18218
18240
  // lib/components/silkscreen-path.ts
18219
18241
  import { length as length10, route_hint_point as route_hint_point5 } from "circuit-json";
18220
- import { z as z118 } from "zod";
18242
+ import { z as z119 } from "zod";
18221
18243
  var silkscreenPathProps = pcbLayoutProps.omit({
18222
18244
  pcbLeftEdgeX: true,
18223
18245
  pcbRightEdgeX: true,
@@ -18229,7 +18251,7 @@ var silkscreenPathProps = pcbLayoutProps.omit({
18229
18251
  pcbOffsetY: true,
18230
18252
  pcbRotation: true
18231
18253
  }).extend({
18232
- route: z118.array(route_hint_point5),
18254
+ route: z119.array(route_hint_point5),
18233
18255
  strokeWidth: length10.optional()
18234
18256
  });
18235
18257
 
@@ -18251,10 +18273,10 @@ var silkscreenLineProps = pcbLayoutProps.omit({
18251
18273
 
18252
18274
  // lib/components/silkscreen-rect.ts
18253
18275
  import { distance as distance41 } from "circuit-json";
18254
- import { z as z119 } from "zod";
18276
+ import { z as z120 } from "zod";
18255
18277
  var silkscreenRectProps = pcbLayoutProps.omit({ pcbRotation: true }).extend({
18256
- filled: z119.boolean().default(true).optional(),
18257
- stroke: z119.enum(["dashed", "solid", "none"]).optional(),
18278
+ filled: z120.boolean().default(true).optional(),
18279
+ stroke: z120.enum(["dashed", "solid", "none"]).optional(),
18258
18280
  strokeWidth: distance41.optional(),
18259
18281
  width: distance41,
18260
18282
  height: distance41,
@@ -18263,10 +18285,10 @@ var silkscreenRectProps = pcbLayoutProps.omit({ pcbRotation: true }).extend({
18263
18285
 
18264
18286
  // lib/components/silkscreen-circle.ts
18265
18287
  import { distance as distance42 } from "circuit-json";
18266
- import { z as z120 } from "zod";
18288
+ import { z as z121 } from "zod";
18267
18289
  var silkscreenCircleProps = pcbLayoutProps.omit({ pcbRotation: true }).extend({
18268
- isFilled: z120.boolean().optional(),
18269
- isOutline: z120.boolean().optional(),
18290
+ isFilled: z121.boolean().optional(),
18291
+ isOutline: z121.boolean().optional(),
18270
18292
  strokeWidth: distance42.optional(),
18271
18293
  radius: distance42
18272
18294
  });
@@ -18284,63 +18306,63 @@ expectTypesMatch(true);
18284
18306
 
18285
18307
  // lib/components/trace-hint.ts
18286
18308
  import { distance as distance43, layer_ref as layer_ref12, route_hint_point as route_hint_point6 } from "circuit-json";
18287
- import { z as z122 } from "zod";
18288
- var routeHintPointProps = z122.object({
18309
+ import { z as z123 } from "zod";
18310
+ var routeHintPointProps = z123.object({
18289
18311
  x: distance43,
18290
18312
  y: distance43,
18291
- via: z122.boolean().optional(),
18313
+ via: z123.boolean().optional(),
18292
18314
  toLayer: layer_ref12.optional()
18293
18315
  });
18294
- var traceHintProps = z122.object({
18295
- for: z122.string().optional().describe(
18316
+ var traceHintProps = z123.object({
18317
+ for: z123.string().optional().describe(
18296
18318
  "Selector for the port you're targeting, not required if you're inside a trace"
18297
18319
  ),
18298
- order: z122.number().optional(),
18320
+ order: z123.number().optional(),
18299
18321
  offset: route_hint_point6.or(routeHintPointProps).optional(),
18300
- offsets: z122.array(route_hint_point6).or(z122.array(routeHintPointProps)).optional(),
18301
- traceWidth: z122.number().optional()
18322
+ offsets: z123.array(route_hint_point6).or(z123.array(routeHintPointProps)).optional(),
18323
+ traceWidth: z123.number().optional()
18302
18324
  });
18303
18325
 
18304
18326
  // lib/components/port.ts
18305
- import { z as z123 } from "zod";
18327
+ import { z as z124 } from "zod";
18306
18328
  var portProps = commonLayoutProps.extend({
18307
- name: z123.string().optional(),
18308
- pinNumber: z123.number().optional(),
18309
- schStemLength: z123.number().optional(),
18310
- aliases: z123.array(z123.string()).optional(),
18311
- layer: z123.string().optional(),
18312
- layers: z123.array(z123.string()).optional(),
18313
- schX: z123.number().optional(),
18314
- schY: z123.number().optional(),
18329
+ name: z124.string().optional(),
18330
+ pinNumber: z124.number().optional(),
18331
+ schStemLength: z124.number().optional(),
18332
+ aliases: z124.array(z124.string()).optional(),
18333
+ layer: z124.string().optional(),
18334
+ layers: z124.array(z124.string()).optional(),
18335
+ schX: z124.number().optional(),
18336
+ schY: z124.number().optional(),
18315
18337
  direction: direction.optional(),
18316
- connectsTo: z123.string().or(z123.array(z123.string())).optional(),
18338
+ connectsTo: z124.string().or(z124.array(z124.string())).optional(),
18317
18339
  kicadPinMetadata: kicadPinMetadata.optional(),
18318
- hasInversionCircle: z123.boolean().optional()
18340
+ hasInversionCircle: z124.boolean().optional()
18319
18341
  });
18320
18342
 
18321
18343
  // lib/components/pcb-note-text.ts
18322
18344
  import { length as length11 } from "circuit-json";
18323
- import { z as z124 } from "zod";
18345
+ import { z as z125 } from "zod";
18324
18346
  var pcbNoteTextProps = pcbLayoutProps.extend({
18325
- text: z124.string(),
18326
- anchorAlignment: z124.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).default("center"),
18327
- font: z124.enum(["tscircuit2024"]).optional(),
18347
+ text: z125.string(),
18348
+ anchorAlignment: z125.enum(["center", "top_left", "top_right", "bottom_left", "bottom_right"]).default("center"),
18349
+ font: z125.enum(["tscircuit2024"]).optional(),
18328
18350
  fontSize: length11.optional(),
18329
- color: z124.string().optional()
18351
+ color: z125.string().optional()
18330
18352
  });
18331
18353
  expectTypesMatch(true);
18332
18354
 
18333
18355
  // lib/components/pcb-note-rect.ts
18334
18356
  import { distance as distance44 } from "circuit-json";
18335
- import { z as z125 } from "zod";
18357
+ import { z as z126 } from "zod";
18336
18358
  var pcbNoteRectProps = pcbLayoutProps.omit({ pcbRotation: true }).extend({
18337
18359
  width: distance44,
18338
18360
  height: distance44,
18339
18361
  strokeWidth: distance44.optional(),
18340
- isFilled: z125.boolean().optional(),
18341
- hasStroke: z125.boolean().optional(),
18342
- isStrokeDashed: z125.boolean().optional(),
18343
- color: z125.string().optional(),
18362
+ isFilled: z126.boolean().optional(),
18363
+ hasStroke: z126.boolean().optional(),
18364
+ isStrokeDashed: z126.boolean().optional(),
18365
+ color: z126.string().optional(),
18344
18366
  cornerRadius: distance44.optional()
18345
18367
  });
18346
18368
  expectTypesMatch(true);
@@ -18350,7 +18372,7 @@ import {
18350
18372
  length as length12,
18351
18373
  route_hint_point as route_hint_point7
18352
18374
  } from "circuit-json";
18353
- import { z as z126 } from "zod";
18375
+ import { z as z127 } from "zod";
18354
18376
  var pcbNotePathProps = pcbLayoutProps.omit({
18355
18377
  pcbLeftEdgeX: true,
18356
18378
  pcbRightEdgeX: true,
@@ -18362,15 +18384,15 @@ var pcbNotePathProps = pcbLayoutProps.omit({
18362
18384
  pcbOffsetY: true,
18363
18385
  pcbRotation: true
18364
18386
  }).extend({
18365
- route: z126.array(route_hint_point7),
18387
+ route: z127.array(route_hint_point7),
18366
18388
  strokeWidth: length12.optional(),
18367
- color: z126.string().optional()
18389
+ color: z127.string().optional()
18368
18390
  });
18369
18391
  expectTypesMatch(true);
18370
18392
 
18371
18393
  // lib/components/pcb-note-line.ts
18372
18394
  import { distance as distance45 } from "circuit-json";
18373
- import { z as z127 } from "zod";
18395
+ import { z as z128 } from "zod";
18374
18396
  var pcbNoteLineProps = pcbLayoutProps.omit({
18375
18397
  pcbLeftEdgeX: true,
18376
18398
  pcbRightEdgeX: true,
@@ -18387,15 +18409,15 @@ var pcbNoteLineProps = pcbLayoutProps.omit({
18387
18409
  x2: distance45,
18388
18410
  y2: distance45,
18389
18411
  strokeWidth: distance45.optional(),
18390
- color: z127.string().optional(),
18391
- isDashed: z127.boolean().optional()
18412
+ color: z128.string().optional(),
18413
+ isDashed: z128.boolean().optional()
18392
18414
  });
18393
18415
  expectTypesMatch(true);
18394
18416
 
18395
18417
  // lib/components/pcb-note-dimension.ts
18396
18418
  import { distance as distance46, length as length13 } from "circuit-json";
18397
- import { z as z128 } from "zod";
18398
- var dimensionTarget2 = z128.union([z128.string(), point]);
18419
+ import { z as z129 } from "zod";
18420
+ var dimensionTarget2 = z129.union([z129.string(), point]);
18399
18421
  var pcbNoteDimensionProps = pcbLayoutProps.omit({
18400
18422
  pcbLeftEdgeX: true,
18401
18423
  pcbRightEdgeX: true,
@@ -18409,101 +18431,101 @@ var pcbNoteDimensionProps = pcbLayoutProps.omit({
18409
18431
  }).extend({
18410
18432
  from: dimensionTarget2,
18411
18433
  to: dimensionTarget2,
18412
- text: z128.string().optional(),
18434
+ text: z129.string().optional(),
18413
18435
  offset: distance46.optional(),
18414
- font: z128.enum(["tscircuit2024"]).optional(),
18436
+ font: z129.enum(["tscircuit2024"]).optional(),
18415
18437
  fontSize: length13.optional(),
18416
- color: z128.string().optional(),
18438
+ color: z129.string().optional(),
18417
18439
  arrowSize: distance46.optional(),
18418
- units: z128.enum(["in", "mm"]).optional(),
18419
- outerEdgeToEdge: z128.literal(true).optional(),
18420
- centerToCenter: z128.literal(true).optional(),
18421
- innerEdgeToEdge: z128.literal(true).optional()
18440
+ units: z129.enum(["in", "mm"]).optional(),
18441
+ outerEdgeToEdge: z129.literal(true).optional(),
18442
+ centerToCenter: z129.literal(true).optional(),
18443
+ innerEdgeToEdge: z129.literal(true).optional()
18422
18444
  });
18423
18445
  expectTypesMatch(
18424
18446
  true
18425
18447
  );
18426
18448
 
18427
18449
  // lib/platformConfig.ts
18428
- import { z as z129 } from "zod";
18429
- var unvalidatedCircuitJson = z129.array(z129.any()).describe("Circuit JSON");
18430
- var footprintLibraryResult = z129.object({
18431
- footprintCircuitJson: z129.array(z129.any()),
18450
+ import { z as z130 } from "zod";
18451
+ var unvalidatedCircuitJson = z130.array(z130.any()).describe("Circuit JSON");
18452
+ var footprintLibraryResult = z130.object({
18453
+ footprintCircuitJson: z130.array(z130.any()),
18432
18454
  cadModel: cadModelProp.optional()
18433
18455
  });
18434
- var pathToCircuitJsonFn = z129.function().args(z129.string()).returns(z129.promise(footprintLibraryResult)).or(
18435
- z129.function().args(
18436
- z129.string(),
18437
- z129.object({ resolvedPcbStyle: pcbStyle.optional() }).optional()
18438
- ).returns(z129.promise(footprintLibraryResult))
18456
+ var pathToCircuitJsonFn = z130.function().args(z130.string()).returns(z130.promise(footprintLibraryResult)).or(
18457
+ z130.function().args(
18458
+ z130.string(),
18459
+ z130.object({ resolvedPcbStyle: pcbStyle.optional() }).optional()
18460
+ ).returns(z130.promise(footprintLibraryResult))
18439
18461
  ).describe("A function that takes a path and returns Circuit JSON");
18440
- var footprintFileParserEntry = z129.object({
18441
- loadFromUrl: z129.function().args(z129.string()).returns(z129.promise(footprintLibraryResult)).describe(
18462
+ var footprintFileParserEntry = z130.object({
18463
+ loadFromUrl: z130.function().args(z130.string()).returns(z130.promise(footprintLibraryResult)).describe(
18442
18464
  "A function that takes a footprint file URL and returns Circuit JSON"
18443
18465
  )
18444
18466
  });
18445
- var spiceEngineSimulationResult = z129.object({
18446
- engineVersionString: z129.string().optional(),
18467
+ var spiceEngineSimulationResult = z130.object({
18468
+ engineVersionString: z130.string().optional(),
18447
18469
  simulationResultCircuitJson: unvalidatedCircuitJson
18448
18470
  });
18449
- var spiceEngineZod = z129.object({
18450
- simulate: z129.function().args(z129.string()).returns(z129.promise(spiceEngineSimulationResult)).describe(
18471
+ var spiceEngineZod = z130.object({
18472
+ simulate: z130.function().args(z130.string()).returns(z130.promise(spiceEngineSimulationResult)).describe(
18451
18473
  "A function that takes a SPICE string and returns a simulation result"
18452
18474
  )
18453
18475
  });
18454
- var defaultSpiceEngine = z129.custom(
18476
+ var defaultSpiceEngine = z130.custom(
18455
18477
  (value) => typeof value === "string"
18456
18478
  );
18457
- var autorouterInstance = z129.object({
18458
- run: z129.function().args().returns(z129.promise(z129.unknown())).describe("Run the autorouter"),
18459
- getOutputSimpleRouteJson: z129.function().args().returns(z129.promise(z129.any())).describe("Get the resulting SimpleRouteJson")
18479
+ var autorouterInstance = z130.object({
18480
+ run: z130.function().args().returns(z130.promise(z130.unknown())).describe("Run the autorouter"),
18481
+ getOutputSimpleRouteJson: z130.function().args().returns(z130.promise(z130.any())).describe("Get the resulting SimpleRouteJson")
18460
18482
  });
18461
- var autorouterDefinition = z129.object({
18462
- createAutorouter: z129.function().args(z129.any(), z129.any().optional()).returns(z129.union([autorouterInstance, z129.promise(autorouterInstance)])).describe("Create an autorouter instance")
18483
+ var autorouterDefinition = z130.object({
18484
+ createAutorouter: z130.function().args(z130.any(), z130.any().optional()).returns(z130.union([autorouterInstance, z130.promise(autorouterInstance)])).describe("Create an autorouter instance")
18463
18485
  });
18464
- var platformFetch = z129.custom((value) => typeof value === "function").describe("A fetch-like function to use for platform requests");
18465
- var platformConfig = z129.object({
18486
+ var platformFetch = z130.custom((value) => typeof value === "function").describe("A fetch-like function to use for platform requests");
18487
+ var platformConfig = z130.object({
18466
18488
  partsEngine: partsEngine.optional(),
18467
18489
  autorouter: autorouterProp.optional(),
18468
- autorouterMap: z129.record(z129.string(), autorouterDefinition).optional(),
18490
+ autorouterMap: z130.record(z130.string(), autorouterDefinition).optional(),
18469
18491
  registryApiUrl: url.optional(),
18470
18492
  cloudAutorouterUrl: url.optional(),
18471
- projectName: z129.string().optional(),
18493
+ projectName: z130.string().optional(),
18472
18494
  projectBaseUrl: url.optional(),
18473
- version: z129.string().optional(),
18495
+ version: z130.string().optional(),
18474
18496
  url: url.optional(),
18475
- printBoardInformationToSilkscreen: z129.boolean().optional(),
18476
- includeBoardFiles: z129.array(z129.string()).describe(
18497
+ printBoardInformationToSilkscreen: z130.boolean().optional(),
18498
+ includeBoardFiles: z130.array(z130.string()).describe(
18477
18499
  'The board files to automatically build with "tsci build", defaults to ["**/*.circuit.tsx"]. Can be an array of files or globs'
18478
18500
  ).optional(),
18479
- snapshotsDir: z129.string().describe(
18501
+ snapshotsDir: z130.string().describe(
18480
18502
  'The directory where snapshots are stored for "tsci snapshot", defaults to "tests/__snapshots__"'
18481
18503
  ).optional(),
18482
18504
  defaultSpiceEngine: defaultSpiceEngine.optional(),
18483
- unitPreference: z129.enum(["mm", "in", "mil"]).optional(),
18484
- localCacheEngine: z129.any().optional(),
18485
- pcbDisabled: z129.boolean().optional(),
18486
- routingDisabled: z129.boolean().optional(),
18487
- schematicDisabled: z129.boolean().optional(),
18488
- partsEngineDisabled: z129.boolean().optional(),
18489
- drcChecksDisabled: z129.boolean().optional(),
18490
- netlistDrcChecksDisabled: z129.boolean().optional(),
18491
- routingDrcChecksDisabled: z129.boolean().optional(),
18492
- placementDrcChecksDisabled: z129.boolean().optional(),
18493
- pinSpecificationDrcChecksDisabled: z129.boolean().optional(),
18494
- spiceEngineMap: z129.record(z129.string(), spiceEngineZod).optional(),
18495
- footprintLibraryMap: z129.record(
18496
- z129.string(),
18497
- z129.union([
18505
+ unitPreference: z130.enum(["mm", "in", "mil"]).optional(),
18506
+ localCacheEngine: z130.any().optional(),
18507
+ pcbDisabled: z130.boolean().optional(),
18508
+ routingDisabled: z130.boolean().optional(),
18509
+ schematicDisabled: z130.boolean().optional(),
18510
+ partsEngineDisabled: z130.boolean().optional(),
18511
+ drcChecksDisabled: z130.boolean().optional(),
18512
+ netlistDrcChecksDisabled: z130.boolean().optional(),
18513
+ routingDrcChecksDisabled: z130.boolean().optional(),
18514
+ placementDrcChecksDisabled: z130.boolean().optional(),
18515
+ pinSpecificationDrcChecksDisabled: z130.boolean().optional(),
18516
+ spiceEngineMap: z130.record(z130.string(), spiceEngineZod).optional(),
18517
+ footprintLibraryMap: z130.record(
18518
+ z130.string(),
18519
+ z130.union([
18498
18520
  pathToCircuitJsonFn,
18499
- z129.record(
18500
- z129.string(),
18501
- z129.union([unvalidatedCircuitJson, pathToCircuitJsonFn])
18521
+ z130.record(
18522
+ z130.string(),
18523
+ z130.union([unvalidatedCircuitJson, pathToCircuitJsonFn])
18502
18524
  )
18503
18525
  ])
18504
18526
  ).optional(),
18505
- footprintFileParserMap: z129.record(z129.string(), footprintFileParserEntry).optional(),
18506
- resolveProjectStaticFileImportUrl: z129.function().args(z129.string()).returns(z129.promise(z129.string())).describe(
18527
+ footprintFileParserMap: z130.record(z130.string(), footprintFileParserEntry).optional(),
18528
+ resolveProjectStaticFileImportUrl: z130.function().args(z130.string()).returns(z130.promise(z130.string())).describe(
18507
18529
  "A function that returns a string URL for static files for the project"
18508
18530
  ).optional(),
18509
18531
  platformFetch: platformFetch.optional()
@@ -18525,6 +18547,10 @@ var projectConfig = platformConfigObject.pick({
18525
18547
  });
18526
18548
  expectTypesMatch(true);
18527
18549
  export {
18550
+ ammeterDisplayOptions,
18551
+ ammeterPinLabels,
18552
+ ammeterPins,
18553
+ ammeterProps,
18528
18554
  analogSimulationProps,
18529
18555
  autorouterConfig,
18530
18556
  autorouterEffortLevel,