@tscircuit/props 0.0.1 → 0.0.3

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 CHANGED
@@ -1341,6 +1341,7 @@ declare const silkscreenTextProps: z.ZodObject<z.objectUtil.extendShape<{
1341
1341
  }, {
1342
1342
  text: z.ZodString;
1343
1343
  font: z.ZodOptional<z.ZodEnum<["tscircuit2024"]>>;
1344
+ fontSize: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
1344
1345
  }>, "strip", z.ZodTypeAny, {
1345
1346
  pcbX: number;
1346
1347
  pcbY: number;
@@ -1348,6 +1349,7 @@ declare const silkscreenTextProps: z.ZodObject<z.objectUtil.extendShape<{
1348
1349
  pcbRotation?: number | undefined;
1349
1350
  layer?: "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6" | undefined;
1350
1351
  font?: "tscircuit2024" | undefined;
1352
+ fontSize?: number | undefined;
1351
1353
  }, {
1352
1354
  pcbX: string | number;
1353
1355
  pcbY: string | number;
@@ -1357,6 +1359,7 @@ declare const silkscreenTextProps: z.ZodObject<z.objectUtil.extendShape<{
1357
1359
  name: "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6";
1358
1360
  } | undefined;
1359
1361
  font?: "tscircuit2024" | undefined;
1362
+ fontSize?: string | number | undefined;
1360
1363
  }>;
1361
1364
  type SilkscreenTextProps = z.input<typeof silkscreenTextProps>;
1362
1365
  declare const silkscreenPathProps: z.ZodObject<z.objectUtil.extendShape<{
@@ -1469,7 +1472,90 @@ declare const silkscreenLineProps: z.ZodObject<z.objectUtil.extendShape<{
1469
1472
  name: "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6";
1470
1473
  } | undefined;
1471
1474
  }>;
1472
- type silkscreenLineProps = z.input<typeof silkscreenLineProps>;
1475
+ type SilkscreenLineProps = z.input<typeof silkscreenLineProps>;
1476
+ declare const silkscreenRectProps: z.ZodObject<z.objectUtil.extendShape<{
1477
+ pcbX: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>;
1478
+ pcbY: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>;
1479
+ pcbRotation: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
1480
+ layer: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodEnum<["top", "bottom", "inner1", "inner2", "inner3", "inner4", "inner5", "inner6"]>, z.ZodObject<{
1481
+ name: z.ZodEnum<["top", "bottom", "inner1", "inner2", "inner3", "inner4", "inner5", "inner6"]>;
1482
+ }, "strip", z.ZodTypeAny, {
1483
+ name: "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6";
1484
+ }, {
1485
+ name: "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6";
1486
+ }>]>, "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6", "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6" | {
1487
+ name: "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6";
1488
+ }>>;
1489
+ }, {
1490
+ isFilled: z.ZodOptional<z.ZodBoolean>;
1491
+ isOutline: z.ZodOptional<z.ZodBoolean>;
1492
+ strokeWidth: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
1493
+ width: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>;
1494
+ height: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>;
1495
+ }>, "strip", z.ZodTypeAny, {
1496
+ pcbX: number;
1497
+ pcbY: number;
1498
+ width: number;
1499
+ height: number;
1500
+ pcbRotation?: number | undefined;
1501
+ layer?: "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6" | undefined;
1502
+ isFilled?: boolean | undefined;
1503
+ strokeWidth?: number | undefined;
1504
+ isOutline?: boolean | undefined;
1505
+ }, {
1506
+ pcbX: string | number;
1507
+ pcbY: string | number;
1508
+ width: string | number;
1509
+ height: string | number;
1510
+ pcbRotation?: string | number | undefined;
1511
+ layer?: "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6" | {
1512
+ name: "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6";
1513
+ } | undefined;
1514
+ isFilled?: boolean | undefined;
1515
+ strokeWidth?: string | number | undefined;
1516
+ isOutline?: boolean | undefined;
1517
+ }>;
1518
+ type SilkscreenRectProps = z.input<typeof silkscreenRectProps>;
1519
+ declare const silkscreenCircleProps: z.ZodObject<z.objectUtil.extendShape<{
1520
+ pcbX: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>;
1521
+ pcbY: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>;
1522
+ pcbRotation: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
1523
+ layer: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodEnum<["top", "bottom", "inner1", "inner2", "inner3", "inner4", "inner5", "inner6"]>, z.ZodObject<{
1524
+ name: z.ZodEnum<["top", "bottom", "inner1", "inner2", "inner3", "inner4", "inner5", "inner6"]>;
1525
+ }, "strip", z.ZodTypeAny, {
1526
+ name: "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6";
1527
+ }, {
1528
+ name: "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6";
1529
+ }>]>, "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6", "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6" | {
1530
+ name: "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6";
1531
+ }>>;
1532
+ }, {
1533
+ isFilled: z.ZodOptional<z.ZodBoolean>;
1534
+ isOutline: z.ZodOptional<z.ZodBoolean>;
1535
+ strokeWidth: z.ZodOptional<z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>>;
1536
+ radius: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodNumber]>, number, string | number>;
1537
+ }>, "strip", z.ZodTypeAny, {
1538
+ pcbX: number;
1539
+ pcbY: number;
1540
+ radius: number;
1541
+ pcbRotation?: number | undefined;
1542
+ layer?: "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6" | undefined;
1543
+ isFilled?: boolean | undefined;
1544
+ strokeWidth?: number | undefined;
1545
+ isOutline?: boolean | undefined;
1546
+ }, {
1547
+ pcbX: string | number;
1548
+ pcbY: string | number;
1549
+ radius: string | number;
1550
+ pcbRotation?: string | number | undefined;
1551
+ layer?: "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6" | {
1552
+ name: "top" | "bottom" | "inner1" | "inner2" | "inner3" | "inner4" | "inner5" | "inner6";
1553
+ } | undefined;
1554
+ isFilled?: boolean | undefined;
1555
+ strokeWidth?: string | number | undefined;
1556
+ isOutline?: boolean | undefined;
1557
+ }>;
1558
+ type SilkscreenCircleProps = z.input<typeof silkscreenCircleProps>;
1473
1559
  declare const traceHintProps: z.ZodObject<{
1474
1560
  for: z.ZodString;
1475
1561
  order: z.ZodOptional<z.ZodNumber>;
@@ -1562,4 +1648,4 @@ declare const traceHintProps: z.ZodObject<{
1562
1648
  }>;
1563
1649
  type TraceHintProps = z.input<typeof traceHintProps>;
1564
1650
 
1565
- export { type BoardProps, type BugProps, type CapacitorProps, type CommonComponentProps, type CommonLayoutProps, type ComponentProps, type ConstrainedLayoutProps, type ConstraintProps, type DiodeProps, type Footprint, type FootprintProps, type GroupProps, type HoleProps, type InductorProps, type LedProps, type NetAliasProps, type PlatedHoleProps, type PortProps, type PowerSourceProps, type ResistorProps, type SchematicBoxProps, type SchematicLineProps, type SchematicPathProps, type SchematicTextProps, type SilkscreenPathProps, type SilkscreenTextProps, type SmtPadProps, type SupplierProps, type TraceHintProps, type TraceProps, type ViaProps, boardProps, bugProps, capacitorPins, capacitorProps, commonComponentProps, commonLayoutProps, componentProps, constrainedLayoutProps, constraintProps, diodePins, diodeProps, direction, explicitPinSideDefinition, footprintProps, groupProps, holeProps, inductorPins, inductorProps, ledPins, ledProps, lrPins, lrPolarPins, netAliasProps, pcbLayoutProps, platedHoleProps, portProps, powerSourceProps, relativeDirection, resistorPins, resistorProps, schematicBoxProps, schematicLineProps, schematicPathProps, schematicTextProps, silkscreenLineProps, silkscreenPathProps, silkscreenTextProps, smtPadProps, supplierProps, traceHintProps, traceProps, viaProps };
1651
+ export { type BoardProps, type BugProps, type CapacitorProps, type CommonComponentProps, type CommonLayoutProps, type ComponentProps, type ConstrainedLayoutProps, type ConstraintProps, type DiodeProps, type Footprint, type FootprintProps, type GroupProps, type HoleProps, type InductorProps, type LedProps, type NetAliasProps, type PlatedHoleProps, type PortProps, type PowerSourceProps, type ResistorProps, type SchematicBoxProps, type SchematicLineProps, type SchematicPathProps, type SchematicTextProps, type SilkscreenCircleProps, type SilkscreenLineProps, type SilkscreenPathProps, type SilkscreenRectProps, type SilkscreenTextProps, type SmtPadProps, type SupplierProps, type TraceHintProps, type TraceProps, type ViaProps, boardProps, bugProps, capacitorPins, capacitorProps, commonComponentProps, commonLayoutProps, componentProps, constrainedLayoutProps, constraintProps, diodePins, diodeProps, direction, explicitPinSideDefinition, footprintProps, groupProps, holeProps, inductorPins, inductorProps, ledPins, ledProps, lrPins, lrPolarPins, netAliasProps, pcbLayoutProps, platedHoleProps, portProps, powerSourceProps, relativeDirection, resistorPins, resistorProps, schematicBoxProps, schematicLineProps, schematicPathProps, schematicTextProps, silkscreenCircleProps, silkscreenLineProps, silkscreenPathProps, silkscreenRectProps, silkscreenTextProps, smtPadProps, supplierProps, traceHintProps, traceProps, viaProps };
package/dist/index.js CHANGED
@@ -54,8 +54,10 @@ __export(lib_exports, {
54
54
  schematicLineProps: () => schematicLineProps,
55
55
  schematicPathProps: () => schematicPathProps,
56
56
  schematicTextProps: () => schematicTextProps,
57
+ silkscreenCircleProps: () => silkscreenCircleProps,
57
58
  silkscreenLineProps: () => silkscreenLineProps,
58
59
  silkscreenPathProps: () => silkscreenPathProps,
60
+ silkscreenRectProps: () => silkscreenRectProps,
59
61
  silkscreenTextProps: () => silkscreenTextProps,
60
62
  smtPadProps: () => smtPadProps,
61
63
  supplierProps: () => supplierProps,
@@ -258,7 +260,8 @@ var portProps = commonLayoutProps.extend({
258
260
  });
259
261
  var silkscreenTextProps = pcbLayoutProps.extend({
260
262
  text: import_zod.z.string(),
261
- font: import_zod.z.enum(["tscircuit2024"]).optional()
263
+ font: import_zod.z.enum(["tscircuit2024"]).optional(),
264
+ fontSize: import_soup.distance.optional()
262
265
  });
263
266
  var silkscreenPathProps = pcbLayoutProps.extend({
264
267
  route: import_zod.z.array(import_soup.route_hint_point)
@@ -270,6 +273,19 @@ var silkscreenLineProps = pcbLayoutProps.extend({
270
273
  x2: import_soup.distance,
271
274
  y2: import_soup.distance
272
275
  });
276
+ var silkscreenRectProps = pcbLayoutProps.extend({
277
+ isFilled: import_zod.z.boolean().optional(),
278
+ isOutline: import_zod.z.boolean().optional(),
279
+ strokeWidth: import_soup.distance.optional(),
280
+ width: import_soup.distance,
281
+ height: import_soup.distance
282
+ });
283
+ var silkscreenCircleProps = pcbLayoutProps.extend({
284
+ isFilled: import_zod.z.boolean().optional(),
285
+ isOutline: import_zod.z.boolean().optional(),
286
+ strokeWidth: import_soup.distance.optional(),
287
+ radius: import_soup.distance
288
+ });
273
289
  var traceHintProps = import_zod.z.object({
274
290
  for: import_zod.z.string(),
275
291
  order: import_zod.z.number().optional(),
@@ -312,8 +328,10 @@ var traceHintProps = import_zod.z.object({
312
328
  schematicLineProps,
313
329
  schematicPathProps,
314
330
  schematicTextProps,
331
+ silkscreenCircleProps,
315
332
  silkscreenLineProps,
316
333
  silkscreenPathProps,
334
+ silkscreenRectProps,
317
335
  silkscreenTextProps,
318
336
  smtPadProps,
319
337
  supplierProps,
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"sources":["../lib/index.ts"],"sourcesContent":["import { z } from \"zod\"\nimport {\n distance,\n rotation,\n layer_ref,\n supplier_name,\n resistance,\n capacitance,\n inductance,\n point,\n voltage,\n route_hint_point,\n} from \"@tscircuit/soup\"\nimport type { ReactElement, ReactNode } from \"react\"\nimport type { LayoutBuilder } from \"@tscircuit/layout\"\n\nexport const direction = z.enum([\"up\", \"down\", \"left\", \"right\"])\n\nexport const relativeDirection = z.enum([\n \"top-to-bottom\",\n \"left-to-right\",\n \"bottom-to-top\",\n \"right-to-left\",\n])\n\nexport const explicitPinSideDefinition = z.object({\n pins: z.array(z.number()),\n direction: z.union([\n z.literal(\"top-to-bottom\"),\n z.literal(\"left-to-right\"),\n z.literal(\"bottom-to-top\"),\n z.literal(\"right-to-left\"),\n ]),\n})\n\nexport type Footprint = string | ReactElement\nexport const pcbLayoutProps = z.object({\n pcbX: distance,\n pcbY: distance,\n pcbRotation: rotation.optional(),\n layer: layer_ref.optional(),\n})\nexport const commonLayoutProps = z.object({\n pcbX: distance.optional(),\n pcbY: distance.optional(),\n pcbRotation: rotation.optional(),\n schX: distance.optional(),\n schY: distance.optional(),\n schRotation: rotation.optional(),\n layer: layer_ref.optional(),\n\n // TODO pull in literals from @tscircuit/footprint\n // TODO footprint can be a string or react child\n footprint: z.custom<Footprint>((v) => true).optional(),\n})\nexport type CommonLayoutProps = z.input<typeof commonLayoutProps>\n\nexport const supplierProps = z.object({\n supplierPartNumbers: z.record(supplier_name, z.array(z.string())).optional(),\n})\nexport type SupplierProps = z.input<typeof supplierProps>\n\nexport const commonComponentProps = commonLayoutProps\n .merge(supplierProps)\n .extend({\n name: z.string(),\n children: z.any().optional(),\n })\nexport type CommonComponentProps = z.input<typeof commonComponentProps>\n\nexport const lrPins = [\"pin1\", \"left\", \"pin2\", \"right\"] as const\nexport const lrPolarPins = [\n \"pin1\",\n \"left\",\n \"anode\",\n \"pos\",\n \"pin2\",\n \"right\",\n \"cathode\",\n \"neg\",\n] as const\n\nexport const resistorProps = commonComponentProps.extend({\n resistance,\n})\nexport const resistorPins = lrPins\nexport type ResistorProps = z.input<typeof resistorProps>\n\nexport const capacitorProps = commonComponentProps.extend({\n capacitance,\n})\nexport const capacitorPins = lrPolarPins\nexport type CapacitorProps = z.input<typeof capacitorProps>\n\nexport const inductorProps = commonComponentProps.extend({\n inductance,\n})\nexport const inductorPins = lrPins\nexport type InductorProps = z.input<typeof inductorProps>\n\nexport const diodeProps = commonComponentProps.extend({})\nexport const diodePins = lrPolarPins\nexport type DiodeProps = z.input<typeof diodeProps>\n\nexport const ledProps = commonComponentProps.extend({\n color: z.string().optional(),\n})\nexport const ledPins = lrPolarPins\nexport type LedProps = z.input<typeof ledProps>\n\nexport const boardProps = z.object({\n width: distance,\n height: distance,\n pcbCenterX: distance.optional().default(0),\n pcbCenterY: distance.optional().default(0),\n layout: z.any().optional(),\n children: z.any(),\n})\nexport type BoardProps = z.input<typeof boardProps>\n\nexport const bugProps = commonComponentProps.extend({\n pinLabels: z.record(z.number(), z.string()),\n schPortArrangement: z\n .object({\n leftSize: z.number().optional(),\n topSize: z.number().optional(),\n rightSize: z.number().optional(),\n bottomSize: z.number().optional(),\n })\n .or(\n z.object({\n leftSide: explicitPinSideDefinition.optional(),\n rightSide: explicitPinSideDefinition.optional(),\n topSide: explicitPinSideDefinition.optional(),\n bottomSide: explicitPinSideDefinition.optional(),\n })\n ),\n})\nexport type BugProps = z.input<typeof bugProps>\n\nexport const viaProps = commonLayoutProps.extend({\n fromLayer: layer_ref,\n toLayer: layer_ref,\n holeDiameter: distance,\n outerDiameter: distance,\n})\nexport type ViaProps = z.input<typeof viaProps>\n\nexport const netAliasProps = commonLayoutProps.extend({\n net: z.string().optional(),\n})\nexport type NetAliasProps = z.input<typeof netAliasProps>\n\nexport const traceProps = z\n .object({\n path: z.array(z.string()),\n thickness: distance.optional(),\n schematicRouteHints: z.array(point).optional(),\n pcbRouteHints: z.array(route_hint_point).optional(),\n })\n .or(\n z.object({\n from: z.string(),\n to: z.string(),\n thickness: distance.optional(),\n schematicRouteHints: z.array(point).optional(),\n pcbRouteHints: z.array(route_hint_point).optional(),\n })\n )\nexport type TraceProps = z.input<typeof traceProps>\n\nexport const smtPadProps = z.union([\n pcbLayoutProps.omit({ pcbRotation: true }).extend({\n shape: z.literal(\"circle\"),\n radius: distance.optional(),\n portHints: z.array(z.string()).optional(),\n }),\n pcbLayoutProps.omit({ pcbRotation: true }).extend({\n shape: z.literal(\"rect\"),\n width: distance.optional(),\n height: distance.optional(),\n portHints: z.array(z.string()).optional(),\n }),\n])\nexport type SmtPadProps = z.input<typeof smtPadProps>\n\nexport const platedHoleProps = pcbLayoutProps\n .omit({ pcbRotation: true, layer: true })\n .extend({\n holeDiameter: distance,\n outerDiameter: distance,\n })\nexport type PlatedHoleProps = z.input<typeof platedHoleProps>\n\nexport const holeProps = pcbLayoutProps.omit({ pcbRotation: true }).extend({\n holeDiameter: distance,\n})\nexport type HoleProps = z.input<typeof holeProps>\n\nexport const schematicBoxProps = z.object({\n schX: distance,\n schY: distance,\n width: distance,\n height: distance,\n})\nexport type SchematicBoxProps = z.input<typeof schematicBoxProps>\n\nexport const schematicTextProps = z.object({\n schX: distance,\n schY: distance,\n text: z.string(),\n})\nexport type SchematicTextProps = z.input<typeof schematicTextProps>\n\nexport const schematicLineProps = z.object({\n x1: distance,\n y1: distance,\n x2: distance,\n y2: distance,\n})\nexport type SchematicLineProps = z.input<typeof schematicLineProps>\n\nexport const schematicPathProps = z.object({\n points: z.array(point),\n isFilled: z.boolean().optional().default(false),\n fillColor: z.enum([\"red\", \"blue\"]).optional(),\n})\nexport type SchematicPathProps = z.input<typeof schematicPathProps>\n\nexport const constraintProps = z.union([\n z.object({\n type: z.literal(\"xdist\"),\n dist: distance,\n left: z.string(),\n right: z.string(),\n }),\n z.object({\n type: z.literal(\"ydist\"),\n dist: distance,\n top: z.string(),\n bottom: z.string(),\n }),\n])\nexport type ConstraintProps = z.input<typeof constraintProps>\n\nexport const constrainedLayoutProps = z.object({})\nexport type ConstrainedLayoutProps = z.input<typeof constrainedLayoutProps>\n\nexport const footprintProps = z.object({})\nexport type FootprintProps = z.input<typeof footprintProps>\n\nexport const componentProps = commonComponentProps\nexport type ComponentProps = z.input<typeof componentProps>\n\nexport const groupProps = commonLayoutProps.extend({\n name: z.string().optional(),\n layout: z.custom<LayoutBuilder>((v) => true).optional(),\n children: z.any().optional(),\n})\nexport type GroupProps = z.input<typeof groupProps>\n\nexport const powerSourceProps = commonComponentProps.extend({\n voltage,\n})\nexport type PowerSourceProps = z.input<typeof powerSourceProps>\n\nexport const portProps = commonLayoutProps.extend({\n name: z.string(),\n pinNumber: z.number().optional(),\n aliases: z.array(z.string()).optional(),\n direction: direction,\n})\nexport type PortProps = z.input<typeof portProps>\n\nexport const silkscreenTextProps = pcbLayoutProps.extend({\n text: z.string(),\n font: z.enum([\"tscircuit2024\"]).optional(),\n})\nexport type SilkscreenTextProps = z.input<typeof silkscreenTextProps>\n\nexport const silkscreenPathProps = pcbLayoutProps.extend({\n route: z.array(route_hint_point),\n})\nexport type SilkscreenPathProps = z.input<typeof silkscreenPathProps>\n\nexport const silkscreenLineProps = pcbLayoutProps.extend({\n strokeWidth: distance,\n x1: distance,\n y1: distance,\n x2: distance,\n y2: distance,\n})\nexport type silkscreenLineProps = z.input<typeof silkscreenLineProps>\n\nexport const traceHintProps = z.object({\n for: z.string(),\n order: z.number().optional(),\n offset: route_hint_point.optional(),\n offsets: z.array(route_hint_point).optional(),\n})\n\nexport type TraceHintProps = z.input<typeof traceHintPro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3B,QAAQ,6BAAiB,SAAS;AAAA,EAClC,SAAS,aAAE,MAAM,4BAAgB,EAAE,SAAS;AAC9C,CAAC;","names":[]}
1
+ {"version":3,"sources":["../lib/index.ts"],"sourcesContent":["import { z } from \"zod\"\nimport {\n distance,\n rotation,\n layer_ref,\n supplier_name,\n resistance,\n capacitance,\n inductance,\n point,\n voltage,\n route_hint_point,\n} from \"@tscircuit/soup\"\nimport type { ReactElement, ReactNode } from \"react\"\nimport type { LayoutBuilder } from \"@tscircuit/layout\"\n\nexport const direction = z.enum([\"up\", \"down\", \"left\", \"right\"])\n\nexport const relativeDirection = z.enum([\n \"top-to-bottom\",\n \"left-to-right\",\n \"bottom-to-top\",\n \"right-to-left\",\n])\n\nexport const explicitPinSideDefinition = z.object({\n pins: z.array(z.number()),\n direction: z.union([\n z.literal(\"top-to-bottom\"),\n z.literal(\"left-to-right\"),\n z.literal(\"bottom-to-top\"),\n z.literal(\"right-to-left\"),\n ]),\n})\n\nexport type Footprint = string | ReactElement\nexport const pcbLayoutProps = z.object({\n pcbX: distance,\n pcbY: distance,\n pcbRotation: rotation.optional(),\n layer: layer_ref.optional(),\n})\nexport const commonLayoutProps = z.object({\n pcbX: distance.optional(),\n pcbY: distance.optional(),\n pcbRotation: rotation.optional(),\n schX: distance.optional(),\n schY: distance.optional(),\n schRotation: rotation.optional(),\n layer: layer_ref.optional(),\n\n // TODO pull in literals from @tscircuit/footprint\n // TODO footprint can be a string or react child\n footprint: z.custom<Footprint>((v) => true).optional(),\n})\nexport type CommonLayoutProps = z.input<typeof commonLayoutProps>\n\nexport const supplierProps = z.object({\n supplierPartNumbers: z.record(supplier_name, z.array(z.string())).optional(),\n})\nexport type SupplierProps = z.input<typeof supplierProps>\n\nexport const commonComponentProps = commonLayoutProps\n .merge(supplierProps)\n .extend({\n name: z.string(),\n children: z.any().optional(),\n })\nexport type CommonComponentProps = z.input<typeof commonComponentProps>\n\nexport const lrPins = [\"pin1\", \"left\", \"pin2\", \"right\"] as const\nexport const lrPolarPins = [\n \"pin1\",\n \"left\",\n \"anode\",\n \"pos\",\n \"pin2\",\n \"right\",\n \"cathode\",\n \"neg\",\n] as const\n\nexport const resistorProps = commonComponentProps.extend({\n resistance,\n})\nexport const resistorPins = lrPins\nexport type ResistorProps = z.input<typeof resistorProps>\n\nexport const capacitorProps = commonComponentProps.extend({\n capacitance,\n})\nexport const capacitorPins = lrPolarPins\nexport type CapacitorProps = z.input<typeof capacitorProps>\n\nexport const inductorProps = commonComponentProps.extend({\n inductance,\n})\nexport const inductorPins = lrPins\nexport type InductorProps = z.input<typeof inductorProps>\n\nexport const diodeProps = commonComponentProps.extend({})\nexport const diodePins = lrPolarPins\nexport type DiodeProps = z.input<typeof diodeProps>\n\nexport const ledProps = commonComponentProps.extend({\n color: z.string().optional(),\n})\nexport const ledPins = lrPolarPins\nexport type LedProps = z.input<typeof ledProps>\n\nexport const boardProps = z.object({\n width: distance,\n height: distance,\n pcbCenterX: distance.optional().default(0),\n pcbCenterY: distance.optional().default(0),\n layout: z.any().optional(),\n children: z.any(),\n})\nexport type BoardProps = z.input<typeof boardProps>\n\nexport const bugProps = commonComponentProps.extend({\n pinLabels: z.record(z.number(), z.string()),\n schPortArrangement: z\n .object({\n leftSize: z.number().optional(),\n topSize: z.number().optional(),\n rightSize: z.number().optional(),\n bottomSize: z.number().optional(),\n })\n .or(\n z.object({\n leftSide: explicitPinSideDefinition.optional(),\n rightSide: explicitPinSideDefinition.optional(),\n topSide: explicitPinSideDefinition.optional(),\n bottomSide: explicitPinSideDefinition.optional(),\n })\n ),\n})\nexport type BugProps = z.input<typeof bugProps>\n\nexport const viaProps = commonLayoutProps.extend({\n fromLayer: layer_ref,\n toLayer: layer_ref,\n holeDiameter: distance,\n outerDiameter: distance,\n})\nexport type ViaProps = z.input<typeof viaProps>\n\nexport const netAliasProps = commonLayoutProps.extend({\n net: z.string().optional(),\n})\nexport type NetAliasProps = z.input<typeof netAliasProps>\n\nexport const traceProps = z\n .object({\n path: z.array(z.string()),\n thickness: distance.optional(),\n schematicRouteHints: z.array(point).optional(),\n pcbRouteHints: z.array(route_hint_point).optional(),\n })\n .or(\n z.object({\n from: z.string(),\n to: z.string(),\n thickness: distance.optional(),\n schematicRouteHints: z.array(point).optional(),\n pcbRouteHints: z.array(route_hint_point).optional(),\n })\n )\nexport type TraceProps = z.input<typeof traceProps>\n\nexport const smtPadProps = z.union([\n pcbLayoutProps.omit({ pcbRotation: true }).extend({\n shape: z.literal(\"circle\"),\n radius: distance.optional(),\n portHints: z.array(z.string()).optional(),\n }),\n pcbLayoutProps.omit({ pcbRotation: true }).extend({\n shape: z.literal(\"rect\"),\n width: distance.optional(),\n height: distance.optional(),\n portHints: z.array(z.string()).optional(),\n }),\n])\nexport type SmtPadProps = z.input<typeof smtPadProps>\n\nexport const platedHoleProps = pcbLayoutProps\n .omit({ pcbRotation: true, layer: true })\n .extend({\n holeDiameter: distance,\n outerDiameter: distance,\n })\nexport type PlatedHoleProps = z.input<typeof platedHoleProps>\n\nexport const holeProps = pcbLayoutProps.omit({ pcbRotation: true }).extend({\n holeDiameter: distance,\n})\nexport type HoleProps = z.input<typeof holeProps>\n\nexport const schematicBoxProps = z.object({\n schX: distance,\n schY: distance,\n width: distance,\n height: distance,\n})\nexport type SchematicBoxProps = z.input<typeof schematicBoxProps>\n\nexport const schematicTextProps = z.object({\n schX: distance,\n schY: distance,\n text: z.string(),\n})\nexport type SchematicTextProps = z.input<typeof schematicTextProps>\n\nexport const schematicLineProps = z.object({\n x1: distance,\n y1: distance,\n x2: distance,\n y2: distance,\n})\nexport type SchematicLineProps = z.input<typeof schematicLineProps>\n\nexport const schematicPathProps = z.object({\n points: z.array(point),\n isFilled: z.boolean().optional().default(false),\n fillColor: z.enum([\"red\", \"blue\"]).optional(),\n})\nexport type SchematicPathProps = z.input<typeof schematicPathProps>\n\nexport const constraintProps = z.union([\n z.object({\n type: z.literal(\"xdist\"),\n dist: distance,\n left: z.string(),\n right: z.string(),\n }),\n z.object({\n type: z.literal(\"ydist\"),\n dist: distance,\n top: z.string(),\n bottom: z.string(),\n }),\n])\nexport type ConstraintProps = z.input<typeof constraintProps>\n\nexport const constrainedLayoutProps = z.object({})\nexport type ConstrainedLayoutProps = z.input<typeof constrainedLayoutProps>\n\nexport const footprintProps = z.object({})\nexport type FootprintProps = z.input<typeof footprintProps>\n\nexport const componentProps = commonComponentProps\nexport type ComponentProps = z.input<typeof componentProps>\n\nexport const groupProps = commonLayoutProps.extend({\n name: z.string().optional(),\n layout: z.custom<LayoutBuilder>((v) => true).optional(),\n children: z.any().optional(),\n})\nexport type GroupProps = z.input<typeof groupProps>\n\nexport const powerSourceProps = commonComponentProps.extend({\n voltage,\n})\nexport type PowerSourceProps = z.input<typeof powerSourceProps>\n\nexport const portProps = commonLayoutProps.extend({\n name: z.string(),\n pinNumber: z.number().optional(),\n aliases: z.array(z.string()).optional(),\n direction: direction,\n})\nexport type PortProps = z.input<typeof portProps>\n\nexport const silkscreenTextProps = pcbLayoutProps.extend({\n text: z.string(),\n font: z.enum([\"tscircuit2024\"]).optional(),\n fontSize: distance.optional(),\n})\nexport type SilkscreenTextProps = z.input<typeof silkscreenTextProps>\n\nexport const silkscreenPathProps = pcbLayoutProps.extend({\n route: z.array(route_hint_point),\n})\nexport type SilkscreenPathProps = z.input<typeof silkscreenPathProps>\n\nexport const silkscreenLineProps = pcbLayoutProps.extend({\n strokeWidth: distance,\n x1: distance,\n y1: distance,\n x2: distance,\n y2: distance,\n})\nexport type SilkscreenLineProps = z.input<typeof silkscreenLineProps>\n\nexport const silkscreenRectProps = pcbLayoutProps.extend({\n isFilled: z.boolean().optional(),\n isOutline: z.boolean().optional(),\n strokeWidth: distance.optional(),\n width: distance,\n height: distance,\n})\nexport type SilkscreenRectProps = z.input<typeof silkscreenRectProps>\n\nexport const silkscreenCircleProps = pcbLayoutProps.extend({\n isFilled: z.boolean().optional(),\n isOutline: z.boolean().optional(),\n strokeWidth: distance.optional(),\n radius: distance,\n})\nexport type SilkscreenCircleProps = z.input<typeof silkscreenCircleProps>\n\nexport const traceHintProps = z.object({\n for: z.string(),\n order: z.number().optional(),\n offset: route_hint_point.optional(),\n offsets: z.array(route_hint_point).optional(),\n})\n\nexport type TraceHintProps = z.input<typeof traceHintProps>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,iBAAkB;AAClB,kBAWO;AAIA,IAAM,YAAY,aAAE,KAAK,CAAC,MAAM,QAAQ,QAAQ,OAAO,CAAC;AAExD,IAAM,oBAAoB,aAAE,KAAK;AAAA,EACtC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,CAAC;AAEM,IAAM,4BAA4B,aAAE,OAAO;AAAA,EAChD,MAAM,aAAE,MAAM,aAAE,OAAO,CAAC;AAAA,EACxB,WAAW,aAAE,MAAM;AAAA,IACjB,aAAE,QAAQ,eAAe;AAAA,IACzB,aAAE,QAAQ,eAAe;AAAA,IACzB,aAAE,QAAQ,eAAe;AAAA,IACzB,aAAE,QAAQ,eAAe;AAAA,EAC3B,CAAC;AACH,CAAC;AAGM,IAAM,iBAAiB,aAAE,OAAO;AAAA,EACrC,MAAM;AAAA,EACN,MAAM;AAAA,EACN,aAAa,qBAAS,SAAS;AAAA,EAC/B,OAAO,sBAAU,SAAS;AAC5B,CAAC;AACM,IAAM,oBAAoB,aAAE,OAAO;AAAA,EACxC,MAAM,qBAAS,SAAS;AAAA,EACxB,MAAM,qBAAS,SAAS;AAAA,EACxB,aAAa,qBAAS,SAAS;AAAA,EAC/B,MAAM,qBAAS,SAAS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AAa;AAAA,EACb,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AAAA,EACJ,IAAI;AACN,CAAC;AAGM,IAAM,sBAAsB,eAAe,OAAO;AAAA,EACvD,UAAU,aAAE,QAAQ,EAAE,SAAS;AAAA,EAC/B,WAAW,aAAE,QAAQ,EAAE,SAAS;AAAA,EAChC,aAAa,qBAAS,SAAS;AAAA,EAC/B,OAAO;AAAA,EACP,QAAQ;AACV,CAAC;AAGM,IAAM,wBAAwB,eAAe,OAAO;AAAA,EACzD,UAAU,aAAE,QAAQ,EAAE,SAAS;AAAA,EAC/B,WAAW,aAAE,QAAQ,EAAE,SAAS;AAAA,EAChC,aAAa,qBAAS,SAAS;AAAA,EAC/B,QAAQ;AACV,CAAC;AAGM,IAAM,iBAAiB,aAAE,OAAO;AAAA,EACrC,KAAK,aAAE,OAAO;AAAA,EACd,OAAO,aAAE,OAAO,EAAE,SAAS;AAAA,EAC3B,QAAQ,6BAAiB,SAAS;AAAA,EAClC,SAAS,aAAE,MAAM,4BAAgB,EAAE,SAAS;AAC9C,CAAC;","names":[]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tscircuit/props",
3
- "version": "0.0.1",
3
+ "version": "0.0.3",
4
4
  "description": "Props for tscircuit builtin component types",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {
@@ -16,6 +16,7 @@
16
16
  "@tscircuit/layout": "^0.0.11",
17
17
  "@tscircuit/soup": "^0.0.17",
18
18
  "@types/node": "^20.12.11",
19
+ "@types/react": "^18.3.2",
19
20
  "ava": "^6.1.3",
20
21
  "react": "^18.3.1",
21
22
  "tsup": "^8.0.2",