Mouse Right Click

How can we right click with mouse button (Not a context click)
And element is located in Canvas on page …
How can I write the javascript for this one …

*Once if i right click an element it should be trigger the toggle *