import * as React from "react"; export interface IDraggableLineWithButtonComponent { data: string; tooltip: string; iconImage: any; onIconClick: (value: string) => void; iconTitle: string; } export class DraggableLineWithButtonComponent extends React.Component { constructor(props: IDraggableLineWithButtonComponent) { super(props); } render() { return (
{ event.dataTransfer.setData("babylonjs-material-node", this.props.data); }}> {this.props.data.substr(0, this.props.data.length - 6)}
{ this.props.onIconClick(this.props.data); }} title={this.props.iconTitle}>
); } }