freeCodeCamp/curriculum
Oliver Eyton-Williams e4ba0e23ea
feat: enable reset in multifile editor (#43617)
* feat: dispatch resetChallenge action

* fix: copy challengeFiles instead of in-place sort

* fix: handle null updateFile payloads in redux

* refactor: reorganise region initialization

* refactor: pull code into editorDidMount

Then we can rely on the presence of the editor and monaco and don't have
litter the code with null checks.

* refactor: use better name for editable region init

* refactor: remove unused decoration

* refactor: rename forbidden region init functions

* fix: keep all challengeFiles when resetting

* refactor: remove unused decoration class

* fix: reinitialize editor on reset

* fix: stop adding multiple scroll listeners

Since the challengeFile update on each keystroke extra (unnecessary)
adding of listeners slowed the editor to a crawl.

* fix: only scroll to editor on mount

Rather than on any edit.

* refactor: remove logs and comments

* fix: rename toSortedArray and fix broken test

* fix: check for null not falsy in updateFile

* fix: only update project features when project

* fix: only reset if editor contents have changed

* feat: focus on editor after reset
2021-10-01 10:36:20 +02:00
..
__fixtures__ feat: curriculum dictionaries to objects (#40878) 2021-02-02 12:14:29 -07:00
challenges fix(curriculum): Fix a typo in "Problem 141: Investigating progressive numbers, n, which are also square" (#43647) 2021-10-01 08:02:13 +02:00
dictionaries chore(i18n,curriculum): update translations (#42918) 2021-07-19 16:05:37 +05:30
schema feat: localize videos (#42869) 2021-09-27 12:26:38 +03:00
test feat: enable reset in multifile editor (#43617) 2021-10-01 10:36:20 +02:00
LICENSE.md
getChallenges.acceptance.test.js chore: add jest global variables (#42573) 2021-06-20 09:14:42 +02:00
getChallenges.js refactor: files{} -> challengeFiles[], and key -> fileKey (#43023) 2021-08-12 20:48:28 +02:00
getChallenges.test.js chore: add jest global variables (#42573) 2021-06-20 09:14:42 +02:00
gulpfile.js fix: order imports and remove circular dependencies (#41824) 2021-08-02 08:39:40 -05:00
package-lock.json chore(deps): update dependency mocha to v9.1.2 2021-09-25 12:07:51 +00:00
package.json chore(deps): update dependency mocha to v9.1.2 2021-09-25 12:07:51 +00:00
utils.js chore(deps): update dependency prettier to v2.3.0 (#42074) 2021-05-10 08:48:49 -07:00