Commit graph

7369 commits

Author SHA1 Message Date
Miodec 275b7cf3fa also added swapescandtab 2022-06-21 15:29:44 +02:00
Miodec 4eec1db25f changed banner message when using localhost 2022-06-21 12:09:23 +02:00
Bruce Berrios db9dcafc25
Add User Profiles (#3174)
* profile

* rounded table corners

* rounded leaderboards corners

* wider page by default

* v3

* font changes

* new pbtables

* blank by default

* showing pb popup

* removed some quotes

* rounding displayed acc

* removed created date (will be shown in profile)

* added profile module that fills the profile element

* updating font size in the middle of the swap to make the change not noticeable

* lowered max font size

* showing if user is banned,
not displaying most details if user is banned

* pbs not selectable

* renamed global stats to time typing

* completed previous commit

* changed function parameters

* only hiding when social is missing

* smaller badge

* aligning quick results
spanning time if wide

* larger badge

* fixed function parameters

* moved to root

* media queries

* Add user profile API (#3123) bruception

* Add flattenObjectDeep

* Add user profile API

* Bump coverage

* Add user profile configuration and rate limits

* Rename profile -> profileDetails

* Simplify

* Filter personal bests

* Handle banned users

* Add banned user test

* new profile layout system
"none" layout finished

* better "none" layout

* "socials" layout

* larger gap

* bioandkey layout done

* "both" layout finished

* final touches

* Add profile editing (#3135)

* Add profile editing

* lowered font size
increased right padding

* updated configuration schema

* moved discord integration to users object in configuration

* added warning comment

* rendering new lines

* edit popup styling

* Sanitize ZAlgo text

* Use trim

* Replace more than 2 spaces with two spaces

* Trim first

* Add profanity detection

* Ass

* Removed some profanities

* Update profanity detection

Co-authored-by: Miodec <bartnikjack@gmail.com>

* Add profile routing (#3143) bruception miodec

* Add profile routing

* removed check (also fixes circular deps)

* change page in special cases

* Hydrate profiles

* Link leaderboards to profiles

* Add failed to load div

* Dont refresh page

* always calling middle callback

* moved profile css into its own file

* fixed one media query

* added preloader, changed default layout

* added reset function
changed function name
updating profile before the page is shown, not after

* resetting after the page is hidden and before its updated

* Fix logic to not delete user if DB goes down (#3171)

* Dont route to account if uid equals current user uid

* temporairly allowing quicktab

* added copy link button

* only increasing padding on the account page

* set max height

* handling copy link button

* only showing avatar if it exists

* 1000 instead of 100

* removing placeholder if image request was successful

Co-authored-by: Miodec <bartnikjack@gmail.com>

* Fix quote length field

Co-authored-by: Miodec <bartnikjack@gmail.com>
2022-06-21 12:01:55 +02:00
smunky 5bf7caf3df
fix webpack reloading twice (#3176) devkennyy 2022-06-21 11:56:50 +02:00
Miodec bca69b6f09 Merge branch 'master' of https://github.com/Miodec/monkeytype 2022-06-20 16:32:05 +02:00
Miodec 3e5982f1de temporairly allowing quicktab 2022-06-20 16:31:59 +02:00
Bruce Berrios 6a3f01f6a9
Fix logic to not delete user if DB goes down (#3171) 2022-06-20 16:10:43 +02:00
Jack ae300bfa94
Disabled time typing requirement on dev (#3169)
* checking if mode is dev when adding to daily lb

* disabled time typing check on dev when recalculating leaderboards

* not replacing footer on localhost

* using ternary

* modified logic
2022-06-20 15:06:35 +02:00
Bruce Berrios 6668575cea
Refactor webpack configs (#3170)
* Refactor webpack configs

* Remove unused import
2022-06-20 15:06:22 +02:00
smunky df2a9e7f01
fixed typos (#3160) devkennyy
* fixed punctuation

* fixed last updated date

* replaced un-permitted with prohibited

* fixed last updated date
2022-06-20 13:45:20 +02:00
Miodec 6e34ebf5c1 fixed quote 2022-06-20 13:38:15 +02:00
smunky 5180dc64f5
added missing challenge (#3159) devkennyy
* added look at me i am the developer now challenge

* fixed accuracy challenge

* added message for accuracy challenges

* moved i am the developer now challenge with other script challenges

* added script for challenge
2022-06-20 13:04:46 +02:00
Miodec 9923a0e6e6 Merge branch 'master' of https://github.com/Miodec/monkeytype 2022-06-20 13:02:13 +02:00
Miodec 86082d9eba updated contributors 2022-06-20 13:00:53 +02:00
smunky 3ef606ffbc
create supporter and sugar daddy badges (#3156) devkennyy
* create supporter and sugar daddy badges

* modify descriptions and colors

Co-authored-by: Miodec <bartnikjack@gmail.com>
2022-06-20 12:58:31 +02:00
karimk123 a09849752d
Adjusted Caps warning position (#3148) karimk123 miodec
* Adjusted Caps warning position

the caps warning div was blocking the test modes text so i moved it up a little.

* animating based on the focus state instead to always stay at the correct distance from the content below

Co-authored-by: Miodec <bartnikjack@gmail.com>
2022-06-20 12:56:00 +02:00
Rizwan Mustafa a6f8f54cbf
Fix escapeHTML not working properly and create allowHTML parameter for Notifications. (#3168) rizwanmustafa
* Modify config to allow hot reload on html

* Now inject monkeytype.js bundle only in development mode

* Remove asset injunction in production

* Modify method of escapeHTML

* add parameter for allowing html

* Allow html for the banner

* remove debug log
2022-06-20 12:48:10 +02:00
SarkarKurdish d869c6f74a
Added 64K+ Kurdish words (#3131) SarkarKurdish
* Added 64K+ Kurdish words

* Added 45K+ kurdish words

* Add new language Kurdish 45K
2022-06-20 12:45:38 +02:00
Rizwan Mustafa 629c15941b
Fix webpack hot reload not working on html file changes. (#3167) rizwanmustafa devkennyy
* Modify config to allow hot reload on html

* Now inject monkeytype.js bundle only in development mode

* Remove asset injunction in production
2022-06-20 12:43:27 +02:00
Miodec d527b2359e Merge branch 'master' of https://github.com/Miodec/monkeytype 2022-06-20 12:35:13 +02:00
Zach Stence f2e8225f59
fix: hide account icon when using discord avatar (#3162)
* fix: hide account icon when using discord avatar

* fix: only use discord avatar if it loads successfully

* fix: set usingAvatar on successful avatar load only

* chore: use arrow function
2022-06-19 20:55:28 -04:00
smunky bc58cbf613
added psa request failed notification (#3155)
* added psa request failed notification

* fixed prettier issues
2022-06-19 19:19:08 -04:00
aria 709d141aa6
more english quotes (#3153)
* Added 5 quotes

* fixed lengths and added MORE quotes

* merged current with prior stream

* Fetching upstream (#1)

* extended: language 'code rust' (#3104)

Added all derives and some very common traits as well as `pub(crate)`.

* added one english quote (#3094)

* added one english quote

* added one english quote

* updated the quote id 6095

* Custom Filters [Backend] (#3105)

* Added `ResultFilters` to types
Added customFilters field to user
This field is an optional array of `ResultFilters`
It will store a user's custom filters

* Added Add and Remove functions for `ResultFilters` in user DAL

Also added unit tests

* Added Custom Filter configuration

Can now enable/disable the custom filters feature
Can also set a cap on the number of filters per user

* Add and Remove functions for `ResultFilters` in user controller

* Added one english quote (#3109)

* added one english quote

* added one english quote

* updated the quote id 6095

* Added english quote id 6096

* Custom Filters [Backend] (#3105) (#3110)

* Added `ResultFilters` to types
Added customFilters field to user
This field is an optional array of `ResultFilters`
It will store a user's custom filters

* Added Add and Remove functions for `ResultFilters` in user DAL

Also added unit tests

* Added Custom Filter configuration

Can now enable/disable the custom filters feature
Can also set a cap on the number of filters per user

* Add and Remove functions for `ResultFilters` in user controller

* Added Haskell programming language (#3108)

* added: code_haskell language;

* fixed: missing comma;

* Contributing typos fix (#3114)

* spacebar in presets and tags addition

* super mega spacebar remake

* style fix

* final name removal in ui

* replaceAll in ape removal

* using display above account chart

* create preset in command line addition

* testing removal

* one more testing removal

* create tag command line addition

* Update commandline-lists.ts

* moved add commands to the bottom
hiding if user is not signed in

* refactor

* hiding tags and presets when signed out

* fixed presets and tags display in alerts

* russian_25k and russian_50k addition

* russian 375k addition

* lil fix

* fixed windows auto-reload error

* Revert "fixed windows auto-reload error"

This reverts commit ea22621232.

* Revert "Revert "fixed windows auto-reload error""

This reverts commit 669cec4217.

* Revert "Revert "Revert "fixed windows auto-reload error"""

This reverts commit d90352633c.

* themes popup small fix

* using &&

* some typos fixed

Co-authored-by: Miodec <bartnikjack@gmail.com>
Co-authored-by: Vasiliy Novozhilov <vasya@192.168.1.3>

* Fix yesterday toggle button (#3107)

Co-authored-by: Cody Bloemhard <cblmhrd@live.nl>
Co-authored-by: Jitesh Kumar Sahoo <77315098+Jitesh117@users.noreply.github.com>
Co-authored-by: Malo Hamon <hamon.malo@gmail.com>
Co-authored-by: aNOOBis <69043738+aNOOBisTheGod@users.noreply.github.com>
Co-authored-by: Miodec <bartnikjack@gmail.com>
Co-authored-by: Vasiliy Novozhilov <vasya@192.168.1.3>
Co-authored-by: Bruce Berrios <58147810+Bruception@users.noreply.github.com>

* fixed ids and added more quotes

* i sincerely hope this is the LAST TIME I DO THIS

* more quotes!

* removed inappropriate quote

Co-authored-by: Cody Bloemhard <cblmhrd@live.nl>
Co-authored-by: Jitesh Kumar Sahoo <77315098+Jitesh117@users.noreply.github.com>
Co-authored-by: Malo Hamon <hamon.malo@gmail.com>
Co-authored-by: aNOOBis <69043738+aNOOBisTheGod@users.noreply.github.com>
Co-authored-by: Miodec <bartnikjack@gmail.com>
Co-authored-by: Vasiliy Novozhilov <vasya@192.168.1.3>
Co-authored-by: Bruce Berrios <58147810+Bruception@users.noreply.github.com>
2022-06-19 11:12:07 -04:00
Miodec 27d2dd3746 updated supporter name 2022-06-19 02:21:10 +02:00
Miodec 50581d317b Merge branch 'master' of https://github.com/Miodec/monkeytype 2022-06-18 15:26:15 +02:00
R0merol dd886223ba
Add 40 more Indonesian quotes, 171-210 (#3146)
* Added 20 more quotes (151-170)

* Fixed quote length (id: 155, 157)

* Add 40 more Indonesian quotes, 171-210

* Fixed "groups" formatting back to original

Co-authored-by: Evan <64989416+Ferotiq@users.noreply.github.com>
2022-06-18 09:21:13 -04:00
Miodec 58654fecb6 added contributor 2022-06-18 00:34:11 +02:00
devrusty 99af571948
Added code_visual_basic language (#3147)
* Create code_visual_basic.json

source: https://docs.microsoft.com/en-us/dotnet/visual-basic/language-reference/keywords/

* listed code_visual_basic

* listed code_visual_basic in code group

* removed duplicate "each"
2022-06-17 18:09:32 -04:00
Miodec b5397d9d56 added supporters 2022-06-17 17:48:39 +02:00
Evan b57e1cd895
Fix prettier issues and update package.json to allow windows to use the prettier scripts (#3145) 2022-06-17 06:47:11 -05:00
kenny bb31d75c4b
removed swapEscAndTab, replaced quickTab with quickRestart (#3139) devkennyy
* Add leaderboard language selection (#3124) bruception

* Adds leaderboard language selection

* Update mesage

* fixed disabled select2 styling

* changed button positioning

* fixed media queries

* Add languages

Co-authored-by: Miodec <bartnikjack@gmail.com>

* remove references of swapEscToTab

* Custom Filters [FrontEnd] (#3106) nocommentcode

* Add Create and Delete functions for Filter Presets to `Users` ape endpoint
- deleteFilterPreset
- addFilterPreset

* Added name and _id fields to the `ResultFilter` interface in the front end

This matches the `ResultFilter` interface in the backend
Added the new fields for the default filter
Added checks in result-filter.ts to not update the ui based on these fields

* Added new-filter-preset-popup

This popup is displayed when creating a new filter preset
It allows the user to select a name.

* Added Filter Preset Buttons in account page html

- Added the Filter Preset button
- Added the filter preset region
- Added the new and delete buttons

* Added Filter Presets to DB Snapshot

* Implemented Custom Fileter Creation, Selection and Deletion flow

- Users can now create a custom filter based on the current settings
- Users will be prompted to select a name for the filter
- User can click on any custom filter and the current filter will be updated
- User can delete a custom filter while it is selected

* Implemented Filter Preset Creation, Selection and Deletion flow

- Users can now create a filter preset based on the current settings
- Users will be prompted to select a name for the filter
- User can click on any filter preset and the current filter will be updated
- User can delete a filter preset while it is selected

* adjusted styling

* removed margin

* removed icon

* added media query

* popup wording

* automatically replacing _ when displaying and creating preset

* using loader and notifications

* fixed bork

* fixed sometimes not being able to delete preset

* make preset popup look like tags popup

Co-authored-by: Miodec <bartnikjack@gmail.com>

* added pace caret: last closes #3113

* Add rate limits to forgot password (#3129) mehdidev

* Added New Quotes

* Add More Quotes

* Add rate limit to forgot password

* Use Prettier

* Change canCall to let so that lint doesn't flag me for the 69th time

* change forgotPassword() to async & remove console.log's

* If this doesn't fix everything idk what to do

* reduced nesting, using function to create error message

* updated notification

Co-authored-by: Miodec <bartnikjack@gmail.com>

* added: code_opencl language (#3132) codybloemhard

* added: code_opencl language;

* fixed: duplicate word in code_opencl;

* fixed: another duplicate in code_opencl;

* Include language in notification (#3134)

* Add 20 more Indonesian quotes, 151-170 (#3136) R0merol

* Added 20 more quotes (151-170)

* Fixed quote length (id: 155, 157)

* using completed events language instead of current config

* add hedge theme (#3137) devkennyy

* create hedge theme

* update _list.json

* fixed sub alt color issues

* update colors

* updated colors

Co-authored-by: Miodec <bartnikjack@gmail.com>

* replaced quickTab with quickRestart

* updated keytips and statements

* update keytips

* moved keytip update to ui module

* not opening command line if quick restart is esc

* calling update keytips when changing quick restart

* handling restarting with quick restart escape

* updated settings page to reflect new quick restart setting

* swapping legacy values

* removed line which caused circular dependencies

* reordered files to fix event not firing

* handling closing with escape before opening

* not doing anything if a modal is visible

Co-authored-by: Bruce Berrios <58147810+Bruception@users.noreply.github.com>
Co-authored-by: Miodec <bartnikjack@gmail.com>
Co-authored-by: Malo Hamon <hamon.malo@gmail.com>
Co-authored-by: Mehdi Hussain <mehdi@mehdi.us>
Co-authored-by: Cody Bloemhard <cblmhrd@live.nl>
Co-authored-by: R0merol <farisfrontiers@gmail.com>
2022-06-16 23:57:34 +02:00
Bruce Berrios 7b89328f47
Refactor add user (#3133) bruception 2022-06-16 19:42:13 +02:00
Miodec 44d4f81afd Merge branch 'master' of https://github.com/Miodec/monkeytype 2022-06-16 19:00:23 +02:00
Miodec 3fe1df4370 added function to escapeHTML 2022-06-16 19:00:16 +02:00
aria e6712e98e3
Added a bunch of quotes (#3103)
* Added 5 quotes

* fixed lengths and added MORE quotes

* merged current with prior stream

* Fetching upstream (#1)

* extended: language 'code rust' (#3104)

Added all derives and some very common traits as well as `pub(crate)`.

* added one english quote (#3094)

* added one english quote

* added one english quote

* updated the quote id 6095

* Custom Filters [Backend] (#3105)

* Added `ResultFilters` to types
Added customFilters field to user
This field is an optional array of `ResultFilters`
It will store a user's custom filters

* Added Add and Remove functions for `ResultFilters` in user DAL

Also added unit tests

* Added Custom Filter configuration

Can now enable/disable the custom filters feature
Can also set a cap on the number of filters per user

* Add and Remove functions for `ResultFilters` in user controller

* Added one english quote (#3109)

* added one english quote

* added one english quote

* updated the quote id 6095

* Added english quote id 6096

* Custom Filters [Backend] (#3105) (#3110)

* Added `ResultFilters` to types
Added customFilters field to user
This field is an optional array of `ResultFilters`
It will store a user's custom filters

* Added Add and Remove functions for `ResultFilters` in user DAL

Also added unit tests

* Added Custom Filter configuration

Can now enable/disable the custom filters feature
Can also set a cap on the number of filters per user

* Add and Remove functions for `ResultFilters` in user controller

* Added Haskell programming language (#3108)

* added: code_haskell language;

* fixed: missing comma;

* Contributing typos fix (#3114)

* spacebar in presets and tags addition

* super mega spacebar remake

* style fix

* final name removal in ui

* replaceAll in ape removal

* using display above account chart

* create preset in command line addition

* testing removal

* one more testing removal

* create tag command line addition

* Update commandline-lists.ts

* moved add commands to the bottom
hiding if user is not signed in

* refactor

* hiding tags and presets when signed out

* fixed presets and tags display in alerts

* russian_25k and russian_50k addition

* russian 375k addition

* lil fix

* fixed windows auto-reload error

* Revert "fixed windows auto-reload error"

This reverts commit ea22621232.

* Revert "Revert "fixed windows auto-reload error""

This reverts commit 669cec4217.

* Revert "Revert "Revert "fixed windows auto-reload error"""

This reverts commit d90352633c.

* themes popup small fix

* using &&

* some typos fixed

Co-authored-by: Miodec <bartnikjack@gmail.com>
Co-authored-by: Vasiliy Novozhilov <vasya@192.168.1.3>

* Fix yesterday toggle button (#3107)

Co-authored-by: Cody Bloemhard <cblmhrd@live.nl>
Co-authored-by: Jitesh Kumar Sahoo <77315098+Jitesh117@users.noreply.github.com>
Co-authored-by: Malo Hamon <hamon.malo@gmail.com>
Co-authored-by: aNOOBis <69043738+aNOOBisTheGod@users.noreply.github.com>
Co-authored-by: Miodec <bartnikjack@gmail.com>
Co-authored-by: Vasiliy Novozhilov <vasya@192.168.1.3>
Co-authored-by: Bruce Berrios <58147810+Bruception@users.noreply.github.com>

* fixed ids and added more quotes

* i sincerely hope this is the LAST TIME I DO THIS

Co-authored-by: Cody Bloemhard <cblmhrd@live.nl>
Co-authored-by: Jitesh Kumar Sahoo <77315098+Jitesh117@users.noreply.github.com>
Co-authored-by: Malo Hamon <hamon.malo@gmail.com>
Co-authored-by: aNOOBis <69043738+aNOOBisTheGod@users.noreply.github.com>
Co-authored-by: Miodec <bartnikjack@gmail.com>
Co-authored-by: Vasiliy Novozhilov <vasya@192.168.1.3>
Co-authored-by: Bruce Berrios <58147810+Bruception@users.noreply.github.com>
2022-06-16 12:41:00 -04:00
Gabriel Fleury 1cf8af1e8c
Added more portuguese quotes (#3140) 2022-06-16 12:39:31 -04:00
Miodec fe6b74ccf0 Merge branch 'master' of https://github.com/Miodec/monkeytype 2022-06-16 18:29:21 +02:00
Miodec 03d90949df storing list of auto assignable roles on the server 2022-06-16 18:29:15 +02:00
kenny cc0f991d47
add hedge theme (#3137) devkennyy
* create hedge theme

* update _list.json

* fixed sub alt color issues

* update colors

* updated colors

Co-authored-by: Miodec <bartnikjack@gmail.com>
2022-06-16 11:37:31 +02:00
Miodec 44d996fe6c using completed events language instead of current config 2022-06-16 11:12:04 +02:00
R0merol 64047a0057
Add 20 more Indonesian quotes, 151-170 (#3136) R0merol
* Added 20 more quotes (151-170)

* Fixed quote length (id: 155, 157)
2022-06-16 11:10:05 +02:00
Bruce Berrios c8e3c2fbbc
Include language in notification (#3134) 2022-06-16 11:09:35 +02:00
Miodec ece2aa4273 Merge branch 'master' of https://github.com/Miodec/monkeytype 2022-06-15 19:35:11 +02:00
Miodec 3da4eb45c0 added pace caret: last closes #3113 2022-06-15 19:35:01 +02:00
Cody Bloemhard ec4e6cbc84
added: code_opencl language (#3132) codybloemhard
* added: code_opencl language;

* fixed: duplicate word in code_opencl;

* fixed: another duplicate in code_opencl;
2022-06-15 15:21:00 +02:00
Mehdi Hussain c3296929da
Add rate limits to forgot password (#3129) mehdidev
* Added New Quotes

* Add More Quotes

* Add rate limit to forgot password

* Use Prettier

* Change canCall to let so that lint doesn't flag me for the 69th time

* change forgotPassword() to async & remove console.log's

* If this doesn't fix everything idk what to do

* reduced nesting, using function to create error message

* updated notification

Co-authored-by: Miodec <bartnikjack@gmail.com>
2022-06-15 15:19:03 +02:00
Malo Hamon f02649ae9f
Custom Filters [FrontEnd] (#3106) nocommentcode
* Add Create and Delete functions for Filter Presets to `Users` ape endpoint
- deleteFilterPreset
- addFilterPreset

* Added name and _id fields to the `ResultFilter` interface in the front end

This matches the `ResultFilter` interface in the backend
Added the new fields for the default filter
Added checks in result-filter.ts to not update the ui based on these fields

* Added new-filter-preset-popup

This popup is displayed when creating a new filter preset
It allows the user to select a name.

* Added Filter Preset Buttons in account page html

- Added the Filter Preset button
- Added the filter preset region
- Added the new and delete buttons

* Added Filter Presets to DB Snapshot

* Implemented Custom Fileter Creation, Selection and Deletion flow

- Users can now create a custom filter based on the current settings
- Users will be prompted to select a name for the filter
- User can click on any custom filter and the current filter will be updated
- User can delete a custom filter while it is selected

* Implemented Filter Preset Creation, Selection and Deletion flow

- Users can now create a filter preset based on the current settings
- Users will be prompted to select a name for the filter
- User can click on any filter preset and the current filter will be updated
- User can delete a filter preset while it is selected

* adjusted styling

* removed margin

* removed icon

* added media query

* popup wording

* automatically replacing _ when displaying and creating preset

* using loader and notifications

* fixed bork

* fixed sometimes not being able to delete preset

* make preset popup look like tags popup

Co-authored-by: Miodec <bartnikjack@gmail.com>
2022-06-15 14:47:52 +02:00
Miodec 8e96570b7e Merge branch 'master' of https://github.com/Miodec/monkeytype 2022-06-15 01:46:25 +02:00
Miodec b9fe94db1b removed the punctuation check for custom mode
closes #3127
2022-06-15 01:46:19 +02:00
Bruce Berrios 0f7a25422a
Add leaderboard language selection (#3124) bruception
* Adds leaderboard language selection

* Update mesage

* fixed disabled select2 styling

* changed button positioning

* fixed media queries

* Add languages

Co-authored-by: Miodec <bartnikjack@gmail.com>
2022-06-15 01:30:46 +02:00