Commit Graph

546 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
c129658ad7 Switch from ts-node to swc 2023-12-02 12:18:09 +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
abf4d0a596 Add skipping plus tier admission from leaderboard 2023-11-19 12:59:07 +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
0156c298cd Update playwright 2023-10-15 14:08:36 +03:00
dependabot[bot]
234324e0a6
Bump zod from 3.22.2 to 3.22.3 (#1522)
Bumps [zod](https://github.com/colinhacks/zod) from 3.22.2 to 3.22.3.
- [Release notes](https://github.com/colinhacks/zod/releases)
- [Changelog](https://github.com/colinhacks/zod/blob/master/CHANGELOG.md)
- [Commits](https://github.com/colinhacks/zod/compare/v3.22.2...v3.22.3)

---
updated-dependencies:
- dependency-name: zod
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-10-15 12:48:24 +03:00
Kalle
b2cf401b10 Update to the new AWS API 2023-10-14 10:28:02 +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
6b9f1182fb Season initial powers script Closes #1450 2023-09-09 20:44:52 +03:00
Kalle
191de711c0 Upgrade deps 2023-08-26 23:22:51 +03:00
Kalle
dab6b00c2d Update Prettier 2023-08-26 22:38:11 +03:00
Kalle
a998f426cc Ban feature 2023-08-18 16:36:11 +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
ad54edf05e Script to delete user Closes #1430 2023-07-28 22:43:15 +03:00
dependabot[bot]
9eee07da77
Bump stylelint from 15.9.0 to 15.10.1 (#1408)
Bumps [stylelint](https://github.com/stylelint/stylelint) from 15.9.0 to 15.10.1.
- [Release notes](https://github.com/stylelint/stylelint/releases)
- [Changelog](https://github.com/stylelint/stylelint/blob/main/CHANGELOG.md)
- [Commits](https://github.com/stylelint/stylelint/compare/15.9.0...15.10.1)

---
updated-dependencies:
- dependency-name: stylelint
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-07-09 11:48:37 +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
4162bb76e2 Splatoon 3 XP badges 2023-07-01 13:14:29 +03:00
Kalle
b4323e104e Upgrade deps 2023-07-01 00:12:29 +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
cc4c9d71e2 Upgrade deps 2023-06-17 10:57:04 +03:00
Kalle
ad1b1fdf84 Upgrade deps 2023-06-04 12:53:30 +03:00
Kalle
0e28189336 Take ownership of brackets-model 2023-05-20 12:04:58 +03:00
Kalle
9ba072b3c3 Make tournament banner text visible in light mode 2023-05-18 00:49:47 +03:00
Kalle
94574c2458 Add progress indicator 2023-05-16 22:04:47 +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
ff0d6cb4d0 Add fix map pools script 2023-04-24 23:58:38 +03:00
dependabot[bot]
46a5e40ec7
Bump xml2js and aws-sdk (#1334)
Bumps [xml2js](https://github.com/Leonidas-from-XIV/node-xml2js) to 0.5.0 and updates ancestor dependency [aws-sdk](https://github.com/aws/aws-sdk-js). These dependencies need to be updated together.


Updates `xml2js` from 0.4.19 to 0.5.0
- [Release notes](https://github.com/Leonidas-from-XIV/node-xml2js/releases)
- [Commits](https://github.com/Leonidas-from-XIV/node-xml2js/compare/0.4.19...0.5.0)

Updates `aws-sdk` from 2.1353.0 to 2.1354.0
- [Release notes](https://github.com/aws/aws-sdk-js/releases)
- [Changelog](https://github.com/aws/aws-sdk-js/blob/master/CHANGELOG.md)
- [Commits](https://github.com/aws/aws-sdk-js/compare/v2.1353.0...v2.1354.0)

---
updated-dependencies:
- dependency-name: xml2js
  dependency-type: indirect
- dependency-name: aws-sdk
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-04-15 12:06:56 +03:00
Kalle
1061a3901d Upgrade Headless UI + combobox UI improvements 2023-04-11 00:26:00 +03:00
Kalle
b4f4b34de3 Upgrade deps 2023-04-10 13:41:57 +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
070229804c Add badge winners script 2023-03-26 19:42:18 +03:00
Kalle
6a585cff5a Add caching to popular builds and buil stats Closes #1308 2023-03-12 14:17:43 +02:00
Kalle
f8f4f3665f Upgrade deps 2023-03-12 14:16:11 +02:00
Kalle
5b9a0ec5f2 Upgrade deps 2023-02-15 00:22:31 +02:00
Kalle
318f7a5043 Ugprade Remix deps 2023-01-22 14:32:18 +02:00
Kalle
f0f6b14f58 Upgrade deps 2023-01-22 13:40:05 +02:00
Kalle
8ba5c715fe Remove Fathom 2023-01-20 21:59:08 +02:00
Kalle
9fecc35839 Upload image page 2023-01-10 00:06:24 +02:00
Kalle
2538801333 Upgrade deps 2022-12-28 23:34:31 +02:00
Kalle
6feb269193
Full tournament feature WIP (#1196)
* Layout initial

* Add FillRosterSection component

* Move tournaments to feature folder

* Refactor Button props

* SubmitButton

* Register action

* Identifier -> Id

* Invite link via nanoid

* Team info submit

* Enter tiebreaker map list UI

* Invite members to tournament team initial

* Show banner if joined a team not captain of

* Add back teams page

* Change team roster size color when good

* Delete tournament team member
2022-12-21 23:24:59 +02:00
Kalle
23e78f7033 Initial user page e2e tests 2022-12-13 18:51:06 +02:00
Kalle
3fdfdff429 Use Fathom 2022-12-12 20:51:18 +02:00
Kalle
c3963223b6
Add initial Playwright tests (#1191) 2022-12-11 17:18:33 +02:00
Kalle
ae47ba9990 Upgrade deps 2022-12-07 19:42:17 +02:00
Kalle
34ca290bdd
Redesign (#1179)
* Remove light mode

* Trim header

* New front page initial

* Get rid of build layout

* Breadcrumbs

* Desktop side nav

* Overhaul colors

* Add breadcrumbs

* New sub nav style

* Front page action buttons

* Add back add new build button

* Add articles page with icon

* Minor Object damage page layout tweaks

* Remove one unnecessary render from object damage

* Fix wrong link in article page

* Profile -> My Page in header

* Log in/out buttons in front

* Add drawings to front page

* Remove unnecessary comment
2022-12-05 16:05:51 +02:00
Kalle
ffc92bdbce Chill Season 2022 update (2.0) 2022-11-30 22:24:56 +02:00
Kalle
2fc3136a35 Upgrade deps 2022-11-24 00:50:07 +02:00
Kalle
a0414ee98a Upgrade to Node 18
Closes #1106
2022-11-24 00:14:56 +02:00