Commit graph

10754 commits

Author SHA1 Message Date
Miodec 491337217b refactor: move converted modals to a new folder, rename supportpopup to supportmodal 2024-03-07 21:41:18 +01:00
Miodec 9f5be14a13 refactor: move animated modal to utils folder 2024-03-07 21:35:45 +01:00
Miodec f46813c958 refactor: remove unnecessary import 2024-03-07 21:31:59 +01:00
Miodec b30c2b54a2 style: lower padding on smaller screens 2024-03-07 21:30:54 +01:00
Miodec a808577940 refactor: prefer modalWrapper instead of backdrop 2024-03-07 21:28:31 +01:00
Miodec 60f3958cdf refactor(support popup): use new modal system 2024-03-07 21:24:37 +01:00
Miodec b8b844bb16 refactor: remove unused code 2024-03-07 21:22:41 +01:00
Miodec 40aa1e61f8 impr: add option to pass modal show settings through the show commandline function 2024-03-07 21:15:18 +01:00
Miodec 41cb95b43e refactor: move events to the top 2024-03-06 00:01:31 +01:00
Jack 3c4212b718
refactor: commandline (#5180)
* initial rewrite

* remove title

* remove from dom on hide

* actual command dom
show active
keep active in view
update active index on keypress

* global event only shows commandline

* impr(dev): showing notifications with unhandled errors

* rename functions

* handle hover functions
handle nesting
handle exec
attaching handlers once

* void promise

* no need for async

* move font preview to ui

* add configkey to command

* add function to build single list

* add mouse mode
clearing preview on hide
add config icon

* using new function

* use fw icon

* fix incorrect type

* extract logic

* add support for input commands

* unused error

* update single list

* chevron icon margin

* only focusing when no popups and words are visible

* extract condition

* better type

* remove no icon

* only showing when nothing is already visible

* commandline lists no longer modify the commandline element
dynamically changing which funbox commnands are available
modified searching approach
showing active settings in single mode again
calling before list if needed

* ignore keydown on page transition

* add other ways to show the commandline

* always clearing previews

* incorrect icon being used

* extract logic

* support quick single list mode by starting input with >

* fix test words not being focused

* showing all if in quick single mode

* remove unused code

* rename entry to command

* remove more unused code

* add data- prefix

* rename to data-command-id

* fix input commands not refocusing words

* fix fontsize change not working as intended

* set active index to 0 when going back

* keeping active command in view

* remove console logs

* fix quick single mode

* move file

* add footer events

* add option for subgroup override
fix issue where commands would get hidden after clearing input field
fixed auto scrolling in mouse mode

* rename commands to lists

* add background after to avoid flashing

* getting config key from active subgroup

* updating active command after removing hidden class but before animating

* fix nasty hover behavior

* updating active before animation showing, keeping active after

* add keymap event

* remove comments

* invert if, use return, combine ifs to reduce nesting

* add test event

* popups events

* fix some commands not showing up on a single list

* use new animated modal

* use regex escaping function from misc

* add singlelistdisplay and singlelistdisplaynoicon properties

* add more navigation aliases

* not adding alias if not needed

* rework command filtering

* fix active icon not working

* add custom hide handlers

* fix active command not being kept in view after showing

* unused imports

* remove commandlinelists imports from other files

* delete old file

* remove unused file

* import commandline dynamically

* fix: if skeleton has wrapper, append before building animated modal

* using new parameters

* save skeleton on ready

* rename folder

* add util to get async modules

* remove empty imports

* remove unnecessary code

* unnecessary void

* catching errors and notifying user

* better error message

* making sure all the lists are fetched before getting the single command list

* add tab navigation
2024-03-05 19:34:35 +01:00
Miodec 226f5de472 fix(quote): missing dash 2024-03-05 18:32:49 +01:00
Christian Fehmer c95e3b2fa8
feat: indicate premium users (fehmer) (#5092)
* feat: indicate premium users

* frontend

* Test multiple userFlags, remove later

* cleanup

* fix flag alignment on profile and leaderboards

* fix name auto scaling

* update screenshot watermark

* update header text

* use userFlags for lbOptOut

* use flex end

* removeo unused code, increase margin

---------

Co-authored-by: Miodec <jack@monkeytype.com>
2024-03-05 16:09:23 +01:00
Miodec 7e957fb449 chore: fix eslint issue 2024-03-05 11:46:00 +01:00
Sanidhya Singh 2fb77a1693
fix: prevent automatic double newline when quick restart set to enter (sanidhyas3s) (#5184)
Fixes #5175

Co-authored-by: Jack <jack@monkeytype.com>
2024-03-05 11:44:13 +01:00
Miodec cc30f6357e fix(style): inconsistent focus border radius across buttons and links 2024-03-04 19:39:13 +01:00
Christian Fehmer b4af0917b2
chore: improve docker files for local development (#5157) 2024-03-04 16:10:22 +01:00
Dmitry ca0d6b3739
impr(quotes): add 20 belarusian quotes (Dmskrzh) (#5152)
Added 20 quotes

Co-authored-by: Jack <jack@monkeytype.com>
2024-03-04 16:09:52 +01:00
Christian Fehmer 171133c795
chore: fix eslint errors (fehmer) (#5166)
* fix eslint errors

* better type

* update type

* define type instead of ignoring errors

* add comment

---------

Co-authored-by: Miodec <jack@monkeytype.com>
2024-03-04 15:25:32 +01:00
Christian Fehmer f7fe0e3f01
impr: better handling of ghost accounts (fehmer) (#5159)
* impr: better handling of ghost accounts

* move deletion to server

* wording
2024-03-04 14:23:33 +01:00
Christian Fehmer d2d7b3e109
impr: show total completed test percentage and restarts/test on profile (fehmer) (#5169) 2024-03-04 14:18:34 +01:00
Christian Fehmer ca55b28135
impr: hide login/signUp button if user signup is disabled (fehmer) (#5172)
* impr: hide signIn button if user signup is disabled

* move UI modifying code to ready.ts

---------

Co-authored-by: Miodec <jack@monkeytype.com>
2024-03-04 14:13:39 +01:00
Christian Fehmer ff268ade7d
fix: fix two percentage symbols in leaderboard (fehmer) (#5174)
Co-authored-by: Jack <jack@monkeytype.com>
2024-03-04 14:02:23 +01:00
Christian Fehmer ae21d04021
fix: remove °C from estorian language (fehmer) (#5178)
Co-authored-by: Jack <jack@monkeytype.com>
2024-03-04 14:02:04 +01:00
github-actions[bot] f298213f04
refactor: run prettier (#5168)
Co-authored-by: monkeytypegeorge <monkeytypegeorge@gmail.com>
2024-03-04 13:59:50 +01:00
Miodec 42b6c53b91 refactor: skeleton util
move to util folder
add suport for predefined append targets
require append target to be specified
2024-03-04 13:23:56 +01:00
Miodec 1f52692151 chore: fix browser debugger not working correctly 2024-03-04 00:07:33 +01:00
Miodec b70de604b7 chore: release v24.9.1 2024-03-03 22:05:57 +01:00
Miodec f35e8fb8ee refactor: cookie popup
use animated modal class
should fix brave having issues with the cookie popup
2024-03-03 21:47:19 +01:00
Miodec e093b51553 impr(tab navigation): improve tab navigation
allow tab when quick restart is disabled and when its set to enter
allow pressing enter to trigger buttons even when quick restart is set to enter
2024-03-03 20:25:44 +01:00
Miodec b9092bf362 impr(animated modal): add setup function which only runs once
used for setting up event handlers - that way the event handlers can be loaded at any time
also connected constructor functions into an object
2024-03-03 19:32:33 +01:00
penguin-teal 5431ab97af
fix(commandline): select exact command matches (#5164)
Because of the RegEx, typing a command such as the language "code c" selects the item "code python" because the word "code" is being matched twice. This change makes it so that when an exact match of a `display` field is typed, it is selected (when I type "code c" I expect to be able to just hit enter but it selects "code python").

Co-authored-by: Jack <jack@monkeytype.com>
2024-03-01 22:27:44 +01:00
Sanidhya Singh 4c550c7d9d
fix(commandline): prevent theme switch when opening the commanline from the footer (sanidhyas3s) (#5163)
fixes #5103

Co-authored-by: Jack <jack@monkeytype.com>
2024-03-01 22:23:43 +01:00
Miodec 9a0d6bd5a9 chore: update link 2024-03-01 22:07:05 +01:00
Miodec d0fe0f536f fix(alerts): not being able to claim rewards 2024-03-01 18:11:59 +01:00
Miodec 03311d8d6f chore: add plushie banner 2024-03-01 17:39:46 +01:00
Miodec d4ec11f3a4 fix(language): fix typo in code matlab 2024-03-01 12:52:17 +01:00
Miodec 0f880a254c refactor(alerts): use animated modal 2024-03-01 02:13:02 +01:00
Miodec a2bf62edd4 refactor: improve animated modal code
allow global definition of custom show and hide animations
these can still be overridden at each show/hide call
store global default animation duration
2024-03-01 01:42:00 +01:00
Jack 1d7fde25a3
refactor: modal system (#5162)
* add animated modal class

* convert one popup to new system

* also grabbing backdrop classes

* rename

* padd modal as parameter

* rename to wrapper

* unnecessary constant

* rename parameter
remove first hashtag if present

* combine types

* rename popup to modal

* reduce options object nesting
2024-03-01 00:29:08 +01:00
Miodec 9cbca109ea chore: fix eslint errors 2024-02-29 22:48:29 +01:00
Christian Fehmer 91982e285d
chore: fix ESLint complaining about typescript version (#5153)
Co-authored-by: Jack <jack@monkeytype.com>
2024-02-29 22:44:33 +01:00
Miodec f7f09d16b1 fix: error when trying to update result tags 2024-02-29 15:10:48 +01:00
Miodec e6666c48c3 style: make backdrop element invisible 2024-02-29 15:07:00 +01:00
Miodec 86a94eacd8 chore: release v24.9.0 2024-02-29 14:04:09 +01:00
Owen Jones 6363b94c0a
impr(quotes): add Python quote (OwenJRJones) (#5139)
* Updated code_python.json

* Updated code_python.json
2024-02-29 13:58:39 +01:00
Max Harmony 8effada4d9
chore: expire security.txt 2024-06-03 (#5156)
Co-authored-by: Jack <jack@monkeytype.com>
2024-02-29 13:03:04 +01:00
Miodec c1c6972408 impr(accesibility): use button element instead of class button 2024-02-28 23:30:49 +01:00
Miodec 35b87c467f fix(alerts panel): unwanted horizontal scrolling 2024-02-28 23:15:16 +01:00
Miodec 8e0f124028 impr: use dialog element to take advantage of focus trapping 2024-02-28 23:02:35 +01:00
Miodec a88ba61758 fix: dont modify tab behavior if a modal is visible 2024-02-28 22:45:44 +01:00