@tscircuit/props 0.0.673 → 0.0.674

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.
@@ -22,7 +22,14 @@ export interface FabricationNoteDimensionProps
22
22
  from: string | Point
23
23
  to: string | Point
24
24
  text?: string
25
+ /** Offset distance in mm, or a unit-bearing string. Defaults to no offset. */
25
26
  offset?: string | number
27
+ /**
28
+ * Unitless direction in footprint-local coordinates (+X right, +Y up).
29
+ * Preserved as supplied; omitted uses the perpendicular to from -> to.
30
+ * The direction rotates/mirrors with the footprint, without translation.
31
+ */
32
+ offsetDirection?: { x: number; y: number }
26
33
  font?: "tscircuit2024"
27
34
  fontSize?: string | number
28
35
  color?: string
@@ -50,6 +57,9 @@ export const fabricationNoteDimensionProps = pcbLayoutProps
50
57
  to: dimensionTarget,
51
58
  text: z.string().optional(),
52
59
  offset: distance.optional(),
60
+ offsetDirection: z
61
+ .object({ x: z.number().finite(), y: z.number().finite() })
62
+ .optional(),
53
63
  font: z.enum(["tscircuit2024"]).optional(),
54
64
  fontSize: length.optional(),
55
65
  color: z.string().optional(),
@@ -22,7 +22,14 @@ export interface PcbNoteDimensionProps
22
22
  from: string | Point
23
23
  to: string | Point
24
24
  text?: string
25
+ /** Offset distance in mm, or a unit-bearing string. Defaults to no offset. */
25
26
  offset?: string | number
27
+ /**
28
+ * Unitless direction in footprint-local coordinates (+X right, +Y up).
29
+ * Preserved as supplied; omitted uses the perpendicular to from -> to.
30
+ * The direction rotates/mirrors with the footprint, without translation.
31
+ */
32
+ offsetDirection?: { x: number; y: number }
26
33
  font?: "tscircuit2024"
27
34
  fontSize?: string | number
28
35
  color?: string
@@ -50,6 +57,9 @@ export const pcbNoteDimensionProps = pcbLayoutProps
50
57
  to: dimensionTarget,
51
58
  text: z.string().optional(),
52
59
  offset: distance.optional(),
60
+ offsetDirection: z
61
+ .object({ x: z.number().finite(), y: z.number().finite() })
62
+ .optional(),
53
63
  font: z.enum(["tscircuit2024"]).optional(),
54
64
  fontSize: length.optional(),
55
65
  color: z.string().optional(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tscircuit/props",
3
- "version": "0.0.673",
3
+ "version": "0.0.674",
4
4
  "description": "Props for tscircuit builtin component types",
5
5
  "main": "dist/index.js",
6
6
  "type": "module",