UNPKG

@typecad/typecad

Version:

🤖programmatically 💥create 🛰️hardware

33 lines (32 loc) 922 B
import { Component } from "../../component"; import { Pin } from "../../pin"; export interface IPadGeometry { center: { x: number; y: number; }; shape: 'circle' | 'rect' | 'oval' | 'roundrect' | 'custom'; type: 'smd' | 'thru_hole' | 'np_thru_hole' | 'connect'; size: { width: number; height: number; }; rotation: number; layer: string; layers: string[]; number: string | number; net?: string; componentRef?: string; } export declare class PadResolver { static getPadCenter(pin: Pin): { x: number; y: number; layer: string; } | null; static getPadGeometry(component: Component, pinNumber: string | number): IPadGeometry | null; private static findPadNode; private static extractPadData; private static transformToAbsolute; static getAllPadGeometries(component: Component): IPadGeometry[]; }