How can i move SVG Polygon element by mouse?

前端 未结 2 1747
轻奢々
轻奢々 2021-01-26 05:11

I want to move this polygon by mouse. How can i do this? I think i should use some like onMouseDown and onMouseMove get new position and transform=\"translate(x,y) but how can

2条回答
  •  佛祖请我去吃肉
    2021-01-26 05:50

    You can use draggable from jquery UI. Here is your edited code:

    
    
    
    
    	
    	Title
    	
    	
    	
    
    
    
    	
    		
    	
    
    

提交回复
热议问题