This is supported on Chrome and Safari (and probably Opera), but
not Firefox because Firefox is too buggy.
(Honestly, every browser's HTML5 drag-and-drop implementation is
super buggy, but Firefox happens to be buggy in a way that makes
this feature semi-impossible.)
This is pretty experimental, but all the bugs I found are worked
out.
While researching how to best implement this, I came across the
famous PPK rant on why HTML5 drag-and-drop sucks:
http://quirksmode.org/blog/archives/2009/09/the_html5_drag.html
A lot of his complaints aren't really a big deal to me, but boy
was he right about browser bugs. Apparently mobile will never
support HTML5 drag-and-drop, either, and there are a lot of
other limitations. Oh well, this is all worth it for an
upcoming planned features: dragging and dropping team files to
and from your desktop.
This adds 1px top and bottom padding to popupmenu's button to match its
hover offset. Necessary because of a bug in Mozilla involving box-sizing
of buttons.
This is a major refactor that changes the teambuilder to store
teams in packed format whenever possible, for approximately 50%
less memory usage for team storage.
The only visible change here is that pokemon nicknames have been
replaced with pokemon icons in the teambuilder team list, to
match the team selector in the main menu, which simplifies
extracting information from packed teams.
Specifically, |wide| makes a wide popup, suitable for modlog results.
And |modal| makes a modal popup, currently only used for locks and
bans, to make sure they're not accidentally dismissed.
A lot of people think the case of someone wanting to forfeit but
not leave the room is obscure, but for now, I think it's still
worth supporting. It's currently implemented as a checkbox, so
it's pretty unobtrusive.
See Zarel/Pokemon-Showdown@d5c622b493
New system is backwards-compatible with old one. This also slightly
refactors some other stuff, for an overall simpler system.