If a piece on the chessboard is accidentally dragged up to the tab area of the browser, it will open up the image file in the browser. This is annoying behavior and possibly causes the user to lose what they were doing in the application.
The best way would be to limit the dragging area to the chessboard. Unfortunately, It seems like the native HTML drag-and-drop events can't do this, and we need to disable the native events and implement our own in terms of the more primitive events like onmouseup and onmousedown. Here is a suggested implementation.
JQuery also has a way to do it, but I'd rather not pull in the jquery library just for this purpose.