2

How to add tooltip on every node using react-sortable-tree?

this is my code. I am SortableTree.

<SortableTree                                
 treeData={treeData1}                                    
   generateNodeProps={({ node, path }) => {                                                                      
   buttons: [                                                    
   <i className="fa fa-trash action-list"                                    
      title="Delete" aria-hidden="true"                                  
       onClick={() => {                                              
     if(window.confirm('Are you sure you want to delete this?')) {                           
       this.state.ondrag = false;                                                    
      this.state.ondelete = true;                                                
        this.deleteTreeNode(productId)                                   
    }}}></i>                                                 
   ],                                            
 };                                          
}}/>
---------------------------------------------------------------
  How to add tooltip here?
user3226524
  • 103
  • 3
  • 11

0 Answers0