fybdp-d3-kg
Version:
Knowledge Graph using React and D3.js
49 lines (48 loc) • 1.32 kB
TypeScript
import React, { Component, ReactNode, ReactElement } from 'react';
import { DiscreteLegendSymbol, DiscreteLegendSymbolProps } from './DiscreteLegendSymbol';
export interface DiscreteLegendEntryProps {
/**
* Label for the entry.
*/
label: string;
/**
* Color for the entry.
*/
color: string;
/**
* Symbol for the entry.
*/
symbol: ReactElement<DiscreteLegendSymbolProps, typeof DiscreteLegendSymbol> | ReactNode;
/**
* CSS Styles.
*/
style?: any;
/**
* CSS Class names.
*/
className?: any;
/**
* HTML Title Attribute.
*/
title?: string;
/**
* Orientation of the entry set internally by `DiscreteLegend`.
*/
orientation: 'horizontal' | 'vertical';
/**
* Mouse enter event.
*/
onMouseEnter: (event: React.MouseEvent<HTMLDivElement>) => void;
/**
* Mouse leave event.
*/
onMouseLeave: (event: React.MouseEvent<HTMLDivElement>) => void;
/**
* On click event.
*/
onClick: (event: React.MouseEvent<HTMLDivElement>) => void;
}
export declare class DiscreteLegendEntry extends Component<DiscreteLegendEntryProps> {
static defaultProps: Partial<DiscreteLegendEntryProps>;
render(): JSX.Element;
}