Commit Graph

285 Commits

Author SHA1 Message Date
Kalle
19920d8524 Use same admin ID for both dev and prod 2023-12-02 15:05:30 +02:00
Kalle
7dec8c572e
SendouQ Season 2 changes (#1542)
* Initial

* Saves preferences

* Include TW

* mapModePreferencesToModeList

* mapPoolFromPreferences initial

* Preference to map pool

* Adjust seed

* q.looking tests

* adds about created map preferences to memento in the correct spot (two preferrers)

* Failing test about modes

* Mode preferences to memento

* Remove old Plus Voting code

* Fix seeding

* find match by id via kysely

* View map memento

* Fix up map list generation logic

* Mode memento info

* Future match modes

* Add TODO

* Migration number

* Migrate test DB

* Remove old map pool code

* createGroupFromPrevious new

* Settings styling

* VC to settings

* Weapon pool

* Add TODOs

* Progress

* Adjust mode exclusion policy

* Progress

* Progress

* Progress

* Notes in progress

* Note feedback after submit

* Textarea styling

* Unskip tests

* Note sorting failing test

* Private note in Q

* Ownerpicksmaps later

* New bottom section

* Mobile layout initial

* Add basic match meta

* Tabs initial

* Sticky tab

* Unseen messages in match page

* Front page i18n

* Settings i18n

* Looking 18n

* Chat i18n

* Progress

* Tranfer weapon pools script

* Sticky on match page

* Match page translations

* i18n - tiers page

* Preparing page i18n

* Icon

* Show add note right after report
2023-11-30 20:57:06 +02:00
Kalle
7a613bd1da tsconfig ES2020 2023-11-25 14:04:26 +02:00
Kalle
4960464f55 Automatically parse URLs for team twitter + calendar event discord link 2023-11-11 13:15:54 +02:00
Kalle
9a126f543d
Plus Voting to 60% criteria + leaderboard access (#1537)
* Update PlusVotingResult

* Logic

* Replace plus tiers

* Testing initial

* Test progress

* Working one test

* Tests

* Schema different file

* Dynamic test

* Fix test util
2023-11-11 12:19:57 +02:00
Kalle
c8ea75ebb6
SQL solution migration to Kysely + getting rid of routes folder (#1530)
* Kysely initial

* Badges initial

* Badge routes migrated

* Badges migrated

* Calendar work

* Fix one type problem

* Calendar work

* findResultsByUserId work

* Calendar reworking finished

* PlusSuggestions work

* Migrated suggestions

* Builds progress

* Migrated builds

* Admin migrated

* Migrate articles

* User search

* Faster getUser

* Selectable/insertable as global

* Refresh prod db script + patronTier index

* identifierToUserId

* updateProfile

* findByIdentifier

* More indexes

* User upsert

* upsertLite

* findAllPlusMembers

* updateResultHighlights

* updateMany

* User finished migration

* Fix types

* Fix PlusVotingResult typing

* PlusVotingRepository WIP

* Migrated resultsByMonthYear

* Migrated plusVotes (done with db. related migrations)

* Plus code to features folder

* Fix TODOs

* Export

* Fix range

* Migrate some user pages

* Move rest user routes

* Move /play

* Map list generator

* Front page

* Move map list generation logic

* Move plus voting logic

* Info

* API

* Adjust TODOs

* theme

* Auth

* Remove TODO
2023-11-04 13:15:36 +02:00
Kalle
24875c1fb4
SendouQ real(er) time with notifications (#1525)
* Initial

* Move code

* More events implemented

* Auto refresh take in account recent revalidates

* Add sound effects

* Add creds

* Settings

* Add error handling

* Add envs
2023-10-18 18:33:17 +03:00
Kalle
1e5c6bf7fa Use Chara introduction video 2023-10-01 12:24:47 +03:00
Kalle
501b858cad Skalop URL via root data loader 2023-09-24 15:29:30 +03:00
Kalle
9ee63f2906 Fix Skalop URL for prod 2023-09-24 15:09:26 +03:00
Kalle
0371bfcd12
SendouQ chat (#1508)
* Chat initial component

* Connect to websocket

* Chat render actual messages

* Chat keep scrolled to bottom

* Pending messages

* Pass rooms as arg

* Chat with tabs

* Message max length

* Looking tabs initial

* Fixes

* Chat on looking page w/ unread messages count

* Add reconnecting websocket

* Patron custom color

* Change ChatMessage data model

* Fix mobile layout

* Add clean up to useEffect

* Chat codes

* FF + clear messages on group morph

* Hide messages when user leaves etc.

* Fix match page layout when chat missing

* New tabs

* Tabs for mobile

* Add TODOs

* Switch to own group tab when roster changes

* Chat styling

* Redesign group cards

* Bring back manager buttons

* Remove flipped

* Remove unused code

* Align better

* Link to user profile

* Better room pass + highlighted

* Fix view when group expired

* Fix MemberAdder (missing input + overflow)

* Chat stay connected in looking

* Remove filters for now

* Fix chat number align

* Fix chat unseen messages

* Hide chat when alone

* Remove rest todos
2023-09-24 12:48:37 +03:00
Kalle
bfa9371786
SendouQ top 10 special display (#1483)
* Component initial

* TopTeanPlayer component

* Add to seasons page

* Finish
2023-09-05 21:03:36 +03:00
Kalle
dab6b00c2d Update Prettier 2023-08-26 22:38:11 +03:00
Kalle
fd7d1ea2dc
User search (#1468)
* Initial

* Search users from API

* Better feeling search

* Fix TODO

* Search via url, discord id & id

* Load initial user

* UserSearch on admin page

* UserSearch on tournaments page

* UserSearch for badges

* Plus suggestions

* Vod page

* Remove unused code

* Fix test
2023-08-26 22:10:01 +03:00
Kalle
d4b9dcd516
Weapon usage (#1466)
* Initial

* Finished?

* Remove comment
2023-08-22 21:16:28 +03:00
Kalle
082d732b3f Fix joining q directly on Safari 15 crashing 2023-08-19 13:57:35 +03:00
Kalle
255a12a069 Warn unreported matches, _action fix & default mode preference to ALL 2023-08-17 21:35:37 +03:00
Kalle
823034a0a1 SendouQ feedback changes 2023-08-15 17:51:29 +03:00
Kalle
7b5d2a2a21 Fix tier image not showing 2023-08-14 21:04:20 +03:00
Kalle
fa83790dff Privately cache user build tab response to avoid repeated requests 2023-08-13 15:36:29 +03:00
Kalle
e7bbb565be
SendouQ (#1455)
* Tables

* Clocks

* Maplist preference selector

* Fix SSR

* Nav icon

* RankedOrScrim

* Map pool

* Create group

* Redirect logic

* Persist map pool

* Advance from preparing page

* Rename query

* Fix merge

* Fix migration order

* Seed groups

* Find looking groups SQL

* Renders something

* More UI work

* Back to 30min

* Likes/dislikes

* Always return own group

* Fix like order

* 3 tc/rm/cb -> 2

* Show only 3 weapons

* Pass group size

* Handle both liked and liked by same group

* Fix SQL

* Group preference frontend work

* Morphing

* Styling

* Don't show group controls if not manager

* Give/remove manager

* Leave group

* Leave with confirm

* Delete likes when morphing groups

* Clocks consistency

* Remove bad invariant

* Persist settings to local storage

* Fix initial value flashing

* Fix never resolving loading indicator

* REFRESH_GROUP

* Flip animations

* Tweaks

* Auto refresh logic

* Groups of 4 seed

* Reduce throwing

* Load full groups initial

* Create match

* Match UI initial

* Score reporter initial

* Push footer down on match page

* Score reporter knows when set ended

* Score reporting untested

* Show score after report

* Align better

* Look again with same group functionality

* More migrations

* Team on match page

* Show confirmer before reporting score

* Report weapons

* Report weapos again by admin + skill changing

* Handle no tiebreaker given to MapPool

* Remove unranked

* Remove support for "team id skill"

* no-wrap -> nowrap

* Preparing page work

* Use common GroupCard component

* Add some metas

* MemberAdder in looking page

* Fix GroupCard actions

* Fix SZ only map list including other modes

* Add season info

* Prompt login

* Joining team

* Manage group on preparing page

* Manage group on preparing page

* Seed past matches

* Add to seed

* No map list preference when full group + fix expiry

* Fix skill matchesCount calculation

* Tiers initial work

* Some progress on tiers

* Tiering logic

* MMR in group cards

* Name to challenge

* Team MMR

* Big team rank icons

* Adjust todos

* Match score report with confirm

* Allow regular members to report score

* Handle reporting weapons edge cases

* Add tier images

* Improve GroupCard spacing

* Refactor looking page

* Looking mobile UI

* Calculate skill only for current season

* Divide groups visually when reporting weapons

* Fix match page weapons sorting

* Add cache to user skills+tier calculation

* Admin report match score

* Initial leaderboard

* Cached leaderboard

* Weapon category lb's

* Populate SkillTeamUser in SendouQ

* Team leaderboard filtered down

* Add TODOs

* Seasons initlal

* Season weapons initial

* Weapons stylized

* Show rest weapons as +

* Hide peak if same as current

* Load matches SQL initial

* Season matches UI initial

* Take user id in account

* Add weapons

* Paginated matches

* Fix pages count logic

* Scroll top on data change

* Day headers for matches

* Link from user page to user seasons page

* Summarize maps + ui initial

* Map stats

* Player info tabs

* MMR chart

* Chart adjustments

* Handle basing team MMR on player MMR

* Set initial MMR

* Add info about discord to match page

* Season support to tournaments

* Get tournament skills as well for the graph

* WIP

* New team rating logic + misc other

* tiered -> tiered.server

* Update season starting time

* TODOs

* Add rules page

* Hide elements correctly when off-season

* Fix crash when only one player with skill

* How-to video

* Fix StartRank showing when not logged in

* Make user leaderboard the default

* Make Skill season non-nullable

* Add suggested pass to match

* Add rule

* identifierToUserIds helper

* Fix tiers not showing
2023-08-12 22:42:54 +03:00
Kalle
7b18a0cfc7
Art tags (#1420)
* Have clicking pagination dots do a thing

* Add tag frontend

* Backend

* Render tags

* Filter by tag

* Persist big art to search params

* Filter by tags on the common art page

* Linking tags + user tags
2023-07-12 16:25:46 +03:00
Kalle
35168111a6
Art (#1412)
* Add to nav

* Allow nav items on front page to take full width

* Initial+

* Fix vods page title

* Add page title

* Common art type

* ArtGrid to a different component

* User arts page initial

* Add art tab to user page

* Preview initial

* Fix art counting

* Fix link and onclick overlapping

* Link to user art page to arts they made

* Artist role initial

* Show description

* Make toggle in art page saved in search params

* Add white-space pre-wrap to plus comments

Not sure why it was removed in the first place?

* Commission open / text and edit those

* Add simple pagination

* New art link display logic

* New art initial

* Upload art

* Hide art from side nav too

* Show banner when waiting for approval

* Edit art

* Fix art sub nav link not showing active

* Relocate unvalidated art text

* Delete art

* Extract ImagePreview component

* Eliminate some layout shift

* BigImageDialog extract component + prevent layout shift

* i18n

* Fix unused var

* Fix tests
2023-07-09 11:48:28 +03:00
Kalle
57e71c542b Links page 2023-07-03 10:55:02 +03:00
Kalle
35424514d6
Finalize tournament + leaderboards initial (#1404)
* Set up tables

* Initial

* Frontend for finalize tournament

* Enter summaries to DB

* Handle changes on tournament page after tournament is finalized

* Fix streams tab text not centered

* Add translations

* Results on user page

* Highlight logic for tournament results

* Leaderboard page initial

* Team leaderboard

* CSS tweaks

* Add unit tests

* Add some i18n

* Add leaderboards page meta

* Support tournaments of size 2

* Add E2E test

* Add missing group by
2023-06-29 00:21:33 +03:00
Kalle
68dac83f4f Fix users without weapon pool having one "null weapon" 2023-06-17 21:50:52 +03:00
Kalle
2c6bd22249 Favorite weapons in user weapon pool Closes #1346 2023-06-17 16:56:51 +03:00
Kalle
600c67f765 Use new Discord display name, make showing unique username optional Closes #1391 2023-06-17 16:02:09 +03:00
Kalle
734688296e
Tournament subs (#1394)
* Initial

* Progress

* Layout work

* New sub page initial

* Edit sub posting

* Delete sub posting

* Improve sub nav looks on mobile

* Finalized
2023-06-16 20:21:22 +03:00
Kalle
c6be828035 Temporary handling of new discord names 2023-06-06 21:23:27 +03:00
Kalle
ad1b1fdf84 Upgrade deps 2023-06-04 12:53:30 +03:00
Kalle
b6283a89c5
Build filters (#1382)
* Build filters WIP

* Move builds to feature folder

* Move stuff to builds feature folder

* Working filters

* AP values as dropdown

* Should revalidate logic

* Remove debounce

* Fix main ability filter not working by default

* Persist filters to search params

* Disable button if too many filters

* Stack on mobile

* Abilities in i18n json

* Ability icon in filter

* Add i18n

* E2E test

* Remove done todo
2023-06-04 11:37:05 +03:00
Kalle
73a687bb09 Tournament: Resolve map list on the server 2023-05-29 00:10:04 +03:00
Kalle
f23446659a Calendar: Fix showing past events last not working on Sunday Closes #1379 2023-05-28 16:05:40 +03:00
Kalle
7342dd1667
Tournament team page (#1380)
* WIP

* Query

* Backend for team page done

* UI function made

* UI work

* Tweaks

* Fix showing players from own team

* Optimize performance

* Inactive players styling

* Stage popover
2023-05-28 15:25:46 +03:00
Kalle
ef5c906321 Calendar: Sort this week's past events last 2023-05-23 23:13:31 +03:00
Kalle
cda9c8b082 Tournament streams initial 2023-05-22 00:43:51 +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
9da4493555 Change invariant to validate with good error message 2023-04-25 00:08:27 +03:00
Kalle
0c32456e72 Initial builds E2E tests 2023-04-23 13:26:18 +03:00
Kalle
1f6bda88b4 Private builds Closes #1242 2023-04-23 11:55:00 +03:00
Kalle
5e36b76ee8
TO Tools back (#1349)
* Remove friend code

* Revive TO Tools admin page

* Revive TO Tools maps page

* Initial one mode only map list

* Add modesIncluded arg

* Handle no maps picked for SZ only generation

* Tiebreaker is always from the maps of the teams

* Make modesIncluded necessary arg

* Tiebreaker is from neither team's pool if no overlap

* Handles worst case duplication

* Handles one team submitted no maps test

* Fix crash

* Seed

* Can change one mode tournament map pool

* Fix join page link

* Remove useless TODO

* Fixes related to mapListGeneratorAvailable

* Fix map list generation considering impossible map lists making it take forever

* Show unlisted select for both sides

* Add info texts

* Remove register button

* Add todos

* Finished version for ITZ

* Times

* Remove TODOs

* 23->24
2023-04-22 11:44:20 +03:00
PM.Net JDS
40e56d2b53
Round sub velocity to thousandths place, fix bug in round function (Fixes #1348) (#1353)
* Round velocity to thousandths place, fix bug in round function

* Prettier application
2023-04-22 11:31:35 +03:00
Kalle
cfbd18b4fe Object Damage Calc: Separate subs in the combobox Closes #1220
Also due to a bug the subs were not accessible at all before.
This was a bug introduced in c014ba5e18
2023-04-15 12:06:07 +03:00
Kalle
1061a3901d Upgrade Headless UI + combobox UI improvements 2023-04-11 00:26:00 +03:00
Kalle
c014ba5e18
Sub damage table in Build Analyzer (#1333)
* Sub weapon damage table initial

* Remove duplicate stats

* Tiny sub weapon icons

* Border-collapse collapse

* Move func location

* Varying sub damage support

* Calculates damages of various bombs

* Burst bomb direct damage

* Fizzy dmg

* Curling bomb explosion values

* Don't show comparison column if no SRU

* Torpedo

* Add note about Splash Wall and Sprinkler

* Fix comment
2023-04-10 11:46:04 +03:00
Kalle
c2e43fb535
X Rank placements (#1325)
* Read in x rank placements script

* Xsearch initial

* XSearch initial

* XSearch with select

* Add badges

* XSearch player page initial

* Consider only one build by user for popular builds Closes #1312

* Revert "Side nav labels on hover (#1290)"

This reverts commit 6e839c6c2d.

* Added and fixed DAnish translations (#1315)

* Added Danish translations

Added Danish translations for the builds.json file.

Translations for the following variables have been added
stats.count.title # used the Danish word for "average" instead of "stats", as it makes more sense in Danish.
stats.ap.title
stats.percentage.title
stats.all
linkButton.abilityStats
linkButton.popularBuilds
noPopularBuilds

* Added Danish translations

Added Danish translations in the calander.json file

tag.desc.SZ
tag.desc.TW
tag.desc.S1
tag.desc.S2
tag.desc.SR
tag.desc.CARDS

* Added Danish translations

Added Danish translations in the common.json file

The following translations have been added
pages.vods
tag.name.SZ
tag.name.TW
tag.name.S1
tag.name.S2
tag.name.SR
tag.name.CARDS

* Added Danish translations in the faq.json file

Added the following Danish translations in the faq.json file

q7
a7

* Updated the DA/game-misc.json file

Added the names for the 3.0 maps.

* Added Danish translation for team.json

Added the following Danish translations for team.json file
- roles.MIDLINE

Fixed the following translation for the team.json file
- "roles.FRONTLINE": # fixed a typo

* Created a vods.json file for the Danish trans

* Fixed typo

Fixed the following translation in the Da\contributions.json file

"yaga" # fixed a Typo of "våben"

* Add Chinese Translation (#1314)

* Update contributions.json

* Update contributions.json

* Update faq.json

* Update user.json

* Create team.json

* Update common.json

* Update analyzer.json

* Prettier

* Prettier

* Prettier

* Update builds.json

* Update calendar.json

* Update common.json

* Update faq.json

* Update team.json

* Create vods.json

* Admin link player action

* Make PlacementTable rounded if only child

* Fix arrow disappeared

* Placements on user page initial

* Remove S2 site link

* Add badge

* Add feature to README

* Fix type error

* Different badge text if XP badge

* Add badge winners script

* Better user avatar + name wrapping for mobile

* Allow script to skip users

* Fix bad align when no weapons in weapon pool

* Add aliases to player name

* Add division icon to placements table

* Link to user page

* Link to xsearch on player details page

* Top 500 icons to user build page

* Working query but slow for weapons page

* Fix lint complaints

* Add cache to builds

* Remove useless SWR value

* Group months in xsearch

* Add xsearch to nav

* Add meta

* Remove TW for now

* Add splatoon3.ink as contributor

* Remove unneeded TODO

* Fix TODOs related to fetching monthYears

* Add FAQ question

* Leaderboards to nav

* Fix sploosh build stat pages returning 404

* Add badge

* Add article

* Patch 3.1

* Fix Prettier issue

* Add badge

* Add April SR gear

* Add badges

* Rename badge

* Add badge

* Add zh badge translation (#1322)

* Splatoon Competitive Guide article (#1316)

* Create splatoon-competitive-guide.md

* Update splatoon-competitive-guide.md

* Fix ToC Issues

* Update splatoon-competitive-guide.md

* Update splatoon-competitive-guide.md

* Update splatoon-competitive-guide.md

* Corrections

* Formatting

---------

Co-authored-by: Kalle <38327916+Sendouc@users.noreply.github.com>

* Fix typos

* Rename table and adjust columns

* Make cache ttl 0 in dev

* Make placements container a bit nicer for mobile

* Rename leftover xxx

* Placements script allow passing number as arg

* Skip leaderboards for now

* Add translations

* Rename placements folder to top-search

* Add placements to seed

* Add E2E tests

* Read in x rank placements script

* Xsearch initial

* XSearch initial

* XSearch with select

* XSearch player page initial

* Admin link player action

* Make PlacementTable rounded if only child

* Fix arrow disappeared

* Placements on user page initial

* Fix bad align when no weapons in weapon pool

* Add aliases to player name

* Add division icon to placements table

* Link to user page

* Link to xsearch on player details page

* Top 500 icons to user build page

* Working query but slow for weapons page

* Fix lint complaints

* Add cache to builds

* Remove useless SWR value

* Group months in xsearch

* Add xsearch to nav

* Add meta

* Remove TW for now

* Add splatoon3.ink as contributor

* Remove unneeded TODO

* Fix TODOs related to fetching monthYears

* Add FAQ question

* Leaderboards to nav

* Fix sploosh build stat pages returning 404

* Rename table and adjust columns

* Make cache ttl 0 in dev

* Make placements container a bit nicer for mobile

* Rename leftover xxx

* Placements script allow passing number as arg

* Skip leaderboards for now

* Add translations

* Rename placements folder to top-search

* Add placements to seed

* Add E2E tests

* Rename url variable and unify

* Tweaks

---------

Co-authored-by: Frederik <112972665+FrederikFraJylland@users.noreply.github.com>
Co-authored-by: Gell <61431488+gellneko@users.noreply.github.com>
Co-authored-by: Zen <99558412+zenpk@users.noreply.github.com>
Co-authored-by: Teddi <83455454+teddinotteddy@users.noreply.github.com>
2023-04-07 21:02:18 +03:00
Kalle
7a249522a4 Fix sploosh build stat pages returning 404 2023-03-29 21:45:26 +03:00
Kalle
575d285ee4 Fix type error 2023-03-26 16:40:30 +03:00
Kalle
6a585cff5a Add caching to popular builds and buil stats Closes #1308 2023-03-12 14:17:43 +02:00