This is mostly a hack rather than a real fix, in that it doesn't
eliminate the need for separate ballistic2 and ballistic2Back
transitions. But it works.
Fixes#1093
The Preact client now supports receiving formats from the server and
displaying them in a menu.
This is a very rough draft that doesn't add CSS to the menu.
This took way too long to get to a presentable state.
- search.js has been refactored into battle-search.ts (search logic)
and battle-searchresults.tsx (display)
- panel-teambuilder.tsx has been split into teambuilder (team list) and
teambuilder-team (team editor).
- The teambuilder's text editor can now detect which line it's on,
and show the appropriate search result panel.
- The teambuilder's text editor now detects sets dynamically, and has
the beginnings of support for set comments.
Currently, everything here is really basic, and mostly just a tech
demo for people to play around with and understand the direction of
the new teambuilder, but it'll be improved over time.
git rev-parse --short sometimes returns less than 8 characters,
meaning the dedup logic is off. One alternative is just to check
origin.startsWith instead, but making them both a uniform 8 works as
well.
If a user never changes their notification settings, 'tournaments'
will be absent from showdown_prefs in localStorage, though will
appear selected in the UI. This change treats the absence of the
setting as being the same as the default ('notify').
This required a new architecture for serving replays from inside the
client repository, because that seems like a better call than
introducing yet another PS repository.
(Experience gives me the impression that separating repositories wasn't
a good idea, and we should be working to make PS more mono-repo-like,
rather than less.)
License for replay code is tentatively AGPLv3, although feel free to ask
for a more permissive license if you have plans to use it in an
open-source project that requires it.