Right-Click JS library

Has anyone had any success implementing a right-mouse click functionality.

Example:
User right-mouse clicks (or ctrl-mouse clicks) an element and a new
div element is displayed until either a new action is performed within
the div, or another action is performed elsewhere.

Thanks,

Dave