Commit Graph

46 Commits

Author SHA1 Message Date
Kalle
78f7baf075 Revalidate subscribe pages on tab back + resub 2023-05-20 00:19:55 +03:00
Kalle
ef78d3a2c2
Tournament full (#1373)
* Got something going

* Style overwrites

* width != height

* More playing with lines

* Migrations

* Start bracket initial

* Unhardcode stage generation params

* Link to match page

* Matches page initial

* Support directly adding seed to map list generator

* Add docs

* Maps in matches page

* Add invariant about tie breaker map pool

* Fix PICNIC lacking tie breaker maps

* Only link in bracket when tournament has started

* Styled tournament roster inputs

* Prefer IGN in tournament match page

* ModeProgressIndicator

* Some conditional rendering

* Match action initial + better error display

* Persist bestOf in DB

* Resolve best of ahead of time

* Move brackets-manager to core

* Score reporting works

* Clear winner on score report

* ModeProgressIndicator: highlight winners

* Fix inconsistent input

* Better text when submitting match

* mapCountPlayedInSetWithCertainty that works

* UNDO_REPORT_SCORE implemented

* Permission check when starting tournament

* Remove IGN from upsert

* View match results page

* Source in DB

* Match page waiting for teams

* Move tournament bracket to feature folder

* REOPEN_MATCH initial

* Handle proper resetting of match

* Inline bracket-manager

* Syncify

* Transactions

* Handle match is locked gracefully

* Match page auto refresh

* Fix match refresh called "globally"

* Bracket autoupdate

* Move fillWithNullTillPowerOfTwo to utils with testing

* Fix map lists not visible after tournament started

* Optimize match events

* Show UI while in progress to members

* Fix start tournament alert not being responsive

* Teams can check in

* Fix map list 400

* xxx -> TODO

* Seeds page

* Remove map icons for team page

* Don't display link to seeds after tournament has started

* Admin actions initial

* Change captain admin action

* Make all hooks ts

* Admin actions functioning

* Fix validate error not displaying in CatchBoundary

* Adjust validate args order

* Remove admin loader

* Make delete team button menancing

* Only include checked in teams to bracket

* Optimize to.id route loads

* Working show map list generator toggle

* Update full tournaments flow

* Make full tournaments work with many start times

* Handle undefined in crud

* Dynamic stage banner

* Handle default strat if map list generation fails

* Fix crash on brackets if less than 2 teams

* Add commented out test for reference

* Add TODO

* Add players from team during register

* TrustRelationship

* Prefers not to host feature

* Last before merge

* Rename some vars

* More renames
2023-05-15 22:37:43 +03:00
Kalle
a1ceff1fd2 Filter builds on user builds page Closes #1243 2023-04-23 15:19:17 +03:00
Kalle
6da896a617 Map Planner: Persist to IndexedDB 2023-01-15 22:12:01 +02:00
William Lam
c8e707488b
Implemented some dynamic background sizing & positioning calculations for the Map Planner (#1200)
* Implemented a relatively simple dynamic background sizing calculation for the Map Planner

* Moved useWindowsSize() hook usage near the top of Planner() function

* Removed some dead space above the background image

* Adjustments

* Added a *lot* of math to adjust image spawn location based on the background image size & position, which are based on the current window size & position
- Moved the background image stuff to its own React Hook, usePlannerBg()

* Fix Prettier issue

* Added another comment

* Fixed typing for the usePlannerBg hook
- Also improved comments & some variable names to be cleaner/more consistent

Co-authored-by: Kalle <38327916+Sendouc@users.noreply.github.com>
2023-01-08 11:24:44 +02:00
Kalle
1170dc0bd0 Team: Manage roster page 2023-01-06 16:33:37 +02:00
Kalle
aea7406586
Map Planner (#1145)
* Initial

* Add images

* Tweaks

* Proper sized bg image and weapons

* Stage bg picker

* Outlined weapon images for planner

* First version

* Lint

* Add alt and title to weapon
2022-11-23 17:38:38 +02:00
Kalle
ecd5a2a2f7
TO Tools (#1077)
* Add DB tables

* Toggle TO Tools in new calendar event page

* TO tools page initial

* Add counter pick map pool UI

* Save tie breaker map pool

* Save team name

* Layout initial

* Load users own team

* Make team name input required

* Rename team

* Divide to sections

* Submit team map pool

* New style for counter pick map pool section expand

* Fix tiebreaker map pool not saved when new event made

* Split to many forms

* According for team name

* Small UI consistency tweaks

* Add explanation to tie breaker maps

* Remove redundant prop

* Fix new calendar event todos

* Use required hidden input component in new build page

* Fix to tools page showing even when toToolsEnabled = 0

* Delete team

* Map list generation tests initial

* Add tournament map list generation tests

* First version of map list generation

* Add seeded RNG

* Rearrange files

* Generation with strats initial

* Default map pool + allow one team not to have any maps

* Implement map generation via backtracking

* Make order of stages irrelevant

* Add one more TODO

* Seed

* Fixes

* Tournament map list generator initial

* More functional maplist

* Fix any

* Persist in search params initial

* Add date to calendar seed

* Revert "Persist in search params initial"

This reverts commit f01a9e6982.

* Allow admin to start tournament

* Rate maplist instead of optimal / suboptimal

* Add fallback if map list generation errors out

* Hide TO Tools if not admin

* Submit team roster and delete members

* Teams page

* Give roster s p a c e

* Clear user combobox on sent + layout tweaks

* Gracefully handle updating after tournament has started

* Add title

* Persist map list in search params

* Add i18n
2022-11-13 14:41:13 +02:00
Remmy Cat Stock
2fa18547b0 Wrap useTranslation to detect missing translations on the route 2022-11-05 14:45:12 +01:00
Remmy Cat Stock
d5677cf7e8
Remove useOnce hook 2022-10-27 23:12:48 +02:00
Remmy Cat Stock
d1b1367651
Add event search to map pool templates 2022-10-27 13:31:37 +02:00
Remmy Cat Stock
edd3a1d91b
Improve MapPoolSelector UI 2022-10-27 13:31:36 +02:00
Kalle
53fa0147c7 Get users to combobox via useSWR 2022-08-07 12:07:32 +03:00
Kalle
00a6ab8be1 Animate badges page entrance 2022-07-25 22:00:35 +03:00
Kalle
63d9a5b53b Set translated title on client side for FAQ 2022-07-17 11:52:35 +03:00
Kalle
4df089573e Remove desktop menu 2022-06-30 17:41:58 +03:00
Kalle
07cc6699f2 Relative time voting timing info 2022-06-11 21:53:34 +03:00
Kalle
77cadcb06d Move useUser to modules/auth 2022-06-11 11:34:25 +03:00
Kalle
ef2d56327d Stricters Typescript 2022-06-10 01:02:59 +03:00
Kalle
185295d54e
User page initial with SQLite3 (#822)
* Clean away prisma migrations

* Way to migrate WIP

* SQLite3 seeding script initial

* Fetch tournament data in loader

* CheckinActions new loader data model

* Virtual banner text color columns

* Logged in user

* Count teams

* ownTeam

* Map pool tab fully working

* Teams tab

* Fix timestamp default

* Register page

* Manage team page

* Camel case checkedInTimestamp

* Clean slate

* Add .nvmrc

* Add favicon

* Package lock file version 2

* Update tsconfig

* Add Tailwind

* Add StrictMode

* Add background color

* Auth without DB

* Revert "Add Tailwind"

This reverts commit 204713c602.

* Auth with DB

* Switch back to tilde absolute import

* Import layout

* Camel case for database columns

* Move auth routes to folder

* User popover links working

* Import linters

* User page initial

* User edit page with country

* Script to delete db files before migration in dev

* Remove "youtubeName" column

* Correct avatar size on desktop

* Fix SubNav not spanning the whole page

* Remove duplicate files

* Update README
2022-05-16 17:52:54 +03:00
Kalle
03da81a84c
New navigation (#821)
* Menu skeleton

* Menu with nav icons

* Menu opens and closes

* More menu icons + links work

* Menu closes on navigation

* Blurred menu

* Remove other nav

* Rounded nav

* Fix menu alignment for Safari

* Close on click outside

* Disable body scroll when menu open

* SubNav for tournament

* Use grid

* Make images same size again

* Remove comment

* Different style mobile nav

* Readd InfoBanner elements

* Move menu css to layout.css

* Move admin command input top left

* Page title from loader

* Fix error when getting pageTitle

* Fix CI
2022-04-30 11:10:09 +03:00
Kalle
b84917133b Edit match if winner unchanged 2022-04-21 17:34:39 +03:00
Kalle
270e00fbe1 Upgrade deps 2022-04-15 18:22:36 +03:00
Kalle
54147404c9 Fix start page crash before check-in starts 2022-04-02 20:03:29 +03:00
Kalle
e2dda84d83 Introduce eslint-plugin-react-hooks 2022-03-30 19:58:08 +03:00
Kalle
c0e4f01097 Bracket real time solution SSE -> Socket.io 2022-03-29 23:55:42 +03:00
Kalle
8d647eaeff Use React Context for sharing socket 2022-03-29 23:40:08 +03:00
Kalle
9b775dcf41 Unread indicator for chat 2022-03-27 14:22:01 +03:00
Kalle
f536918d09 Chat SSE -> socket.io 2022-03-25 00:42:29 +02:00
Kalle
2b0bdf9d92 Polling 30 -> 20 seconds 2022-02-27 10:55:00 +02:00
Kalle
244f6aab8a Fix team MMR calculation 2022-02-27 10:49:49 +02:00
Kalle
52822569de Fix lint 2022-02-18 08:26:29 +02:00
Kalle
026bd67b78 Add polling to looking 2022-02-17 09:51:07 +02:00
Kalle
b24a7f4d98 Refactor SSE logic 2022-02-13 13:29:12 +02:00
Kalle (Sendou)
b9a79103a2 Close modal on click outside 2022-01-19 18:27:01 +02:00
Kalle (Sendou)
d530e9383c Switch common hooks from /utils to /hooks 2022-01-16 22:03:53 +02:00
Kalle (Sendou)
be147a9c1f When match ends -> events 2022-01-14 08:49:02 +02:00
Kalle (Sendou)
2bc3cb1ca1 BracketData tuple -> object 2022-01-13 08:59:09 +02:00
Kalle (Sendou)
3bff18fae8 Bracket with events working 2022-01-12 18:13:37 +02:00
Kalle (Sendou)
0c659ec6af Import <Bracket /> component 2021-12-23 08:47:09 +02:00
Kalle (Sendou)
c48bdea053 Disable buttons on /start if round being edited 2021-12-18 08:57:13 +02:00
Kalle (Sendou)
7b196384cc Edit map list stages functionality 2021-12-17 22:39:00 +02:00
Kalle (Sendou)
33155e2593 Regenerate all maps 2021-12-17 19:32:07 +02:00
Kalle (Sendou)
a6a303302c Can change best of and regen maps 2021-12-17 09:17:58 +02:00
Kalle (Sendou)
357f8b1024 Fix hydration error 2021-12-17 08:31:02 +02:00
Kalle (Sendou)
1398dadc31 Start page UI hooks skeleton 2021-12-15 09:26:55 +02:00