Commit graph

1332 commits

Author SHA1 Message Date
Christian Fehmer
4c9e949f10
impr: use tsrest/zod for type-safety on both ends (@fehmer) (#5479)
!nuf
2024-07-16 15:24:06 +02:00
Jack
2af5879f23
refactor: split middlewares into smaller files (#5616)
* split

* fix imports

* rename
2024-07-15 17:08:32 +02:00
Christian Fehmer
088ff638cc
fix: optimize / fix concurrency in UserDal (@fehmer) (#5558)
* fix addResultFilterPreset

* refactor, fix  removeResultFilters

* fix isDiscordIdAvailable, addTag, editTag and removeTag

* fix removeTagPb, updateLbMemory

* incrementBanana

* addTheme, removeTheme, editTheme

* wip

* cleanup incrementBananas

* toMongoFunction

* give up on making toMongoFunction type-safe

* be less stupid, addFavoriteQuote

* removeFavoriteQuote

* cleanup updateInbox

* don't use function if possible

* cleanup

* update error messages

* update error messages again

* review comments
2024-07-15 14:18:22 +02:00
Christian Fehmer
94a393fd87
impr: provide all-time LB results during LB update (@fehmer) (#5614) 2024-07-15 12:25:47 +02:00
Christian Fehmer
aca3fe205b
test: add test coverage for PresetDal (@fehmer) (#5615) 2024-07-15 12:21:31 +02:00
Miodec
1cabbaa3e8 fix(server): not being able to view profiles which had a dot in the name 2024-07-13 21:39:07 +02:00
Miodec
9953c5ed02 impr(report quote): add reason: duplicate quote 2024-07-11 15:48:01 +02:00
Miodec
65a3f9dacb chore: relax user forgot password rate limit 2024-07-08 19:47:44 +02:00
Christian Fehmer
3722000d85
fix: updateInbox claiming all rewards (@fehmer) (#5560)
!nuf
2024-07-05 13:47:54 +02:00
Christian Fehmer
1f085580e6
fix: cleanup tmp while updating users inbox (#5559) 2024-07-04 18:35:52 +02:00
Miodec
8c00315c5b impr(server): disallow dots in tags, presets and custom theme names 2024-07-03 17:34:29 +02:00
Miodec
dd4943bae0 impr(server): dont allow dots in usernames 2024-07-03 15:08:26 +02:00
Christian Fehmer
ce093c538d
fix: concurrency issue while claiming rewards (@fehmer) (#5553) 2024-07-02 20:39:27 +02:00
Christian Fehmer
e8d9ce63da
chore: fix check annotations for dev routes (@fehmer) (#5549) 2024-07-01 14:46:04 +02:00
Christian Fehmer
d566ba6468
perf: optimize database access for UserDal (@fehmer) (#5544)
* impr: optimize database access for UserDal (@fehmer)

* rename getPartial to getPartialUser
2024-07-01 14:37:12 +02:00
Aaron
0877723fdf
chore: replace twitter urls with x (unrealapex) (#5541)
* chore: replace twitter urls with x

* chore: fix twitter account url
2024-07-01 13:53:49 +02:00
theiereman
2714af1eeb
impr(server): trim consecutive newlines when updating user profile (theiereman) (#5538) 2024-07-01 12:30:27 +02:00
Miodec
6da0e6a0fa chore: remove some words from the profanity list 2024-07-01 12:04:34 +02:00
Christian Fehmer
442153724a
feat: add test activity and streak into to the apekey endpoints (@fehmer) (#5513)
* feat: add test activity and streak into to the apekey endpoints (@fehmer)

* add public conract

* review comments
2024-06-24 13:55:13 +02:00
Christian Fehmer
b4ea7f119f
impr(dev): add endpoint to create test user/data (fehmer) (#5396)
!nuf
2024-06-17 15:21:55 +02:00
Christian Fehmer
d5b3103967
fix: unable to rename freshly created theme (fehmer) (#5486) 2024-06-12 10:24:52 +02:00
Miodec
6a768b40b4 feat(funbox): add plus zero funbox. only the current word is visible 2024-06-11 12:25:26 +02:00
Miodec
ff86c83211 impr(server): log server versions which generate 500 errors
!nuf
2024-06-06 12:49:20 +02:00
Miodec
66a91011d7 fix(server): incorrect error message when profanity was detected
this reworks the profanity check a little bit, usernames with profanity
are still considered valid if they match the regex pattern and they
match the length check
2024-06-05 15:16:38 +02:00
Christian Fehmer
01076986be
fix: test activity graph bugs (fehmer) (#5468) 2024-06-03 13:00:30 +02:00
Miodec
05d6160b2a test: remove double mock 2024-05-29 14:44:54 +02:00
Miodec
57ff186f91 build: add @shared alias pointing to the shared directory 2024-05-29 14:29:47 +02:00
Miodec
90c96a2bd7 refactor: move token revoke call to other auth util functions 2024-05-28 19:02:08 +02:00
Miodec
d2d1f83a36 fix: also disallow stop on letter on the daily leaderboards 2024-05-28 18:10:02 +02:00
Miodec
40423baa2a test: fix missing mocks breaking tests 2024-05-28 17:38:54 +02:00
Miodec
0c38d99bde fix(backend): use correct function
!nuf
2024-05-28 17:23:54 +02:00
Miodec
aa2466a0d1 feat(result): disallow stop on error letter from getting new pbs 2024-05-28 17:10:51 +02:00
Miodec
8e057e3cb6 impr(server): move password update from client to server
this allows us to make sure to invalidate user tokens on password change

!nuf
2024-05-28 11:06:14 +02:00
Miodec
313468cee3 chore: remove unnecessary import 2024-05-28 11:06:14 +02:00
Miodec
f7a97505db refactor(backend): revoke tokens, update email
move revoke tokens function from delete user to its own funciton (together with removing from cache)
remove authutil calls from dal and move them to the controller layer
make sure to revoke tokens on email change
2024-05-28 11:06:14 +02:00
Christian Fehmer
fd3fc7ca47
test: fix flaky tests on user creation (fehmer) (#5434) 2024-05-24 12:33:44 +02:00
Christian Fehmer
d9767ebc97
fix: testActivity not removed on account reset (fehmer) (#5427) 2024-05-23 10:53:23 +02:00
Miodec
3255654921 impr: add admin endpoint to send forgot password email
!nuf
2024-05-20 15:35:52 +02:00
Christian Fehmer
4589bbf679
feat: maintain hashed blocklist of banned usernames, emails and discordids (fehmer) (#5371)
* feat: maintain blocklist of banned usernames and email (fehmer)

* update privacy policy

---------

Co-authored-by: Miodec <jack@monkeytype.com>
2024-05-20 12:21:14 +02:00
Miodec
b17803918b chore: migration log 2024-05-17 22:20:54 +02:00
Miodec
c164b84291 chore: better migration script logs 2024-05-17 16:57:27 +02:00
Christian Fehmer
d9e975b286
fix: migration breaking tests (fehmer) (#5397)
!nuf
2024-05-15 16:20:09 +02:00
Christian Fehmer
59615fb02c
feat(account page): add test activity graph (fehmer, Singh233) (#5309)
* wip

* wip frontend

* cleanup

* wip

* refactoring

* wip

* first working version

* wip

* update calendar with new result

* add migration script

* dates are hard

* fix naming inconsistencies

* requested changes on migration

* timezones

* update date-fns, use date-fns/utc

* resolve cyclic dependency by extracting test activity calender into new file

* cleanup

* fix increment

* fix

* tests

* test coverage

* test migration

* migration more logging

* migration add unique index on uid if missing

* update legend styling

* 53 columns

* wip

* move dropdown and legend to the top
add dropdown border
yeet hotpink
invisible filler boxes
remove year from month format

* responsive update

* lowercase months

* handle current year, fix tests

* handle year change

* make days square again

* handle newly created users correctly

* move css

* add wrapper for easier styling
rework some font sizes/widths
reorder styles

* media queries

* align

* rework styling once more

* dont commit debug

* add days full to fill the space a bit

* show partial months

* hover on 0 tests

* start dynamic calendar on sunday

* no activity

* hover

* remove label on fillers

* remove label on fillers

* fix months, update tests for months

* adjust tests to new requirements

* cleanup

* fix migration

* impr(commandline): add "add/remove quote to favorites" commands

closes #5368

* chore: remove daily lb which is no longer in the backend

* fix: dropdown element flashing for couple frames on page load

* feat(language): add japanese romaji 1k (nthngnssmnnglss)

* fix: optional chaining

!nuf

* fix(words generator): infinite custom text tests not working correctly

* chore: missing languages in list and group files

* fix(language): remove duplicates

!nuf

* add readline sync to confirm

* gh action complaints

* unnecessary check

* premium only

* add years to drop down only if premium

* Update setup-tests.ts

* test fix

* cleanup

---------

Co-authored-by: Miodec <jack@monkeytype.com>
2024-05-15 15:23:36 +02:00
Christian Fehmer
059c9e271b
test: update to vitest 1.6.0, use v8 coverage provider (#5389) 2024-05-13 13:25:21 +02:00
Christian Fehmer
0dab2ecd7e
impr: build docker images for linux/arm64 on release (#5369)
!nuf
2024-05-13 11:53:46 +02:00
Miodec
c1e4fb3722 chore: allow user deletion again 2024-05-06 13:35:54 +02:00
Miodec
2f3fc419b8 chore: remove unused code 2024-05-05 18:11:36 +02:00
Jack
79f77b80eb
refactor: live stats (#5352) 2024-05-02 17:33:17 +02:00
Miodec
b2e563429b impr(server): dont allow banned users to unlink from discord 2024-04-30 21:19:30 +02:00
Miodec
7f04503921 impr(max line width): setting the value to 0 will now always align the words to the width of the container 2024-04-30 21:00:02 +02:00