UNPKG

70-react-network-diagrams

Version:
52 lines (51 loc) 2.34 kB
import { default as React } from 'react'; import { default as PropTypes } from 'prop-types'; /** * Endpoint drawing primative. This essentially renders the shape we use to represent * for an endpoint on the circuit diagrams. The result is a `<g>` element containing * the endpoint rendering, so this needs to be used within the context of an `<svg>` block, or * more likely, just use a `<Circuit>`. * * The `x` and `y` props determine the position of the endpoint on the svg grid, while * 'labelPosition' determines where the label for the endpoint will be positioned around * the endpoint. The `offset` property allow you to customize the distance the label has * from the endpoint's `x` and `y` as the initial position of the label is determined * based on these props. The `offset` property has no effect on the angled labels, as * these require pre-determined offset distances based on the rotation. The `label` prop * is the name that will be displayed on the endpoint. */ export class Endpoint extends React.Component<any, any, any> { constructor(props: any); render(): import("react/jsx-runtime").JSX.Element; } export namespace Endpoint { namespace propTypes { let label: PropTypes.Requireable<string>; let labelPosition: PropTypes.Requireable<string>; let offset: PropTypes.Requireable<number>; let shape: PropTypes.Requireable<string>; let radius: PropTypes.Requireable<number>; let roundedX: PropTypes.Requireable<number>; let roundedY: PropTypes.Requireable<number>; let style: PropTypes.Requireable<object>; let muted: PropTypes.Requireable<boolean>; let selected: PropTypes.Requireable<boolean>; let highlighted: PropTypes.Requireable<boolean>; } namespace defaultProps { let radius_1: number; export { radius_1 as radius }; let shape_1: string; export { shape_1 as shape }; let offset_1: number; export { offset_1 as offset }; let labelPosition_1: string; export { labelPosition_1 as labelPosition }; let muted_1: boolean; export { muted_1 as muted }; let selected_1: boolean; export { selected_1 as selected }; let highlighted_1: boolean; export { highlighted_1 as highlighted }; } }