iconButtonLineComponent.tsx 522 B

1234567891011121314151617181920
  1. import * as React from "react";
  2. export interface IIconButtonLineComponentProps {
  3. icon: string;
  4. onClick: () => void;
  5. tooltip: string;
  6. }
  7. export class IconButtonLineComponent extends React.Component<IIconButtonLineComponentProps> {
  8. constructor(props: IIconButtonLineComponentProps) {
  9. super(props);
  10. }
  11. render() {
  12. return (
  13. <div title={this.props.tooltip} className={`icon ${this.props.icon}`} onClick={() => this.props.onClick()} />
  14. );
  15. }
  16. }