Commit Graph

1842 Commits

Author SHA1 Message Date
Nicholas Carrigan (he/him)
cb5244be73 feat: css magazine (#43507)
* feat: initial infrastructure

* feat: html steps done

* feat: through step 50

* feat: complete steps

* feat: write tests

* chore: apply gikf's review suggestions

Co-authored-by: Krzysztof <60067306+gikf@users.noreply.github.com>

* chore: use correct alt text

Co-authored-by: Krzysztof <60067306+gikf@users.noreply.github.com>

* fix: image size

Co-authored-by: Krzysztof <60067306+gikf@users.noreply.github.com>

* feat: add temporary width

* chore: apply sem's review suggestions

Co-authored-by: Sem Bauke <46919888+Sembauke@users.noreply.github.com>

* chore: missed one

Co-authored-by: Sem Bauke <46919888+Sembauke@users.noreply.github.com>

* chore: apply kris' review suggestions

Co-authored-by: Kristofer Koishigawa <scissorsneedfoodtoo@gmail.com>

* chore: no text walls

Co-authored-by: Kristofer Koishigawa <scissorsneedfoodtoo@gmail.com>

* chore: walls of text

* chore: remaining review suggestions

* chore: apply shaun's review suggestions

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>

* fix: linting index.md

* chore: lang tags

* feat: clarify noreferrer

* feat: clarify lazy loading

* chore: apply shaun's review suggestions

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>

* fix: note about justify

* fix: split step 7

* fix: hero title

* chore: parts are secretly steps

* chore: apply tom's review suggestions

Co-authored-by: Tom <20648924+moT01@users.noreply.github.com>

* chore: missed one

Co-authored-by: Tom <20648924+moT01@users.noreply.github.com>

Co-authored-by: Krzysztof <60067306+gikf@users.noreply.github.com>
Co-authored-by: Sem Bauke <46919888+Sembauke@users.noreply.github.com>
Co-authored-by: Kristofer Koishigawa <scissorsneedfoodtoo@gmail.com>
Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
Co-authored-by: Tom <20648924+moT01@users.noreply.github.com>
2021-10-28 14:31:12 -05:00
Sem Bauke
ab2e85978f chore(client): migrate-landing-components (#43769)
* feat: migrate landing components

* fix: import declarations

* fix: interface names

* fix: typing

* fix: attribute name

* fix: interface names

* Update client/src/declarations.d.ts

Co-authored-by: RobertoMSousa <beto.sousa22@gmail.com>

* Update client/src/components/landing/components/campers-image.tsx

* Update client/src/components/landing/components/campers-image.tsx

* Apply suggestions from code review

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>

* fix: linting issues

Co-authored-by: Tom <20648924+moT01@users.noreply.github.com>
Co-authored-by: RobertoMSousa <beto.sousa22@gmail.com>
Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
2021-10-28 08:19:45 -07:00
Nicholas Carrigan (he/him)
07bfe87419 feat: add campfire mode (#42663)
* feat: add campfire mode

fix: resolve lint issues

feat: add sound to editor

fix: restore flash messages

fix: linter issues

fix: obey sound setting

Update the editor to obey the camper's sound setting.

chore: apply suggestions from code review

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

fix: use @types/store

fix: linter issues

feat: simplify sound saga

Update client/src/redux/sound-mode-saga.js

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

fix: missing bracket

chore: use new s3 bucket

fix: lint

fix: import only needed bits

fix: remove from navbar

(was intermittently broken here anyway)

fix: dynamic imports?

fix: more dynamic imports

fix: tweak theme logic

chore: boolean | undefined

fix: dns

fix: no hammer local storage

* chore: apply oliver's review suggestions

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

* fix: lost an import

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
2021-10-27 17:50:29 -05:00
Nicholas Carrigan (he/him)
2868347742 feat: css photo gallery (#43602)
* feat: initial infra

* feat: create steps

* feat: prototype tests

Haven't tested locally yet :)

* feat: complete tests

* feat: move image size step

* chore: apply shaun's review suggestions

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>

* chore: apply kris' review suggestions

Co-authored-by: Kristofer Koishigawa <scissorsneedfoodtoo@gmail.com>

* fix: index.md linting

* chore: steps are parts in disguise

* chore: apply tom's review suggestions

Co-authored-by: Tom <20648924+moT01@users.noreply.github.com>

* fix: colon to period

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
Co-authored-by: Kristofer Koishigawa <scissorsneedfoodtoo@gmail.com>
Co-authored-by: Tom <20648924+moT01@users.noreply.github.com>
2021-10-27 13:40:44 -05:00
Arun Et-008
1ca335794c fix(client): make language dropdown as wide as the nav (#43991)
Co-authored-by: arun elanthamil <arun.elanthamil@superops.ai>
2021-10-27 13:53:16 +03:00
Oliver Eyton-Williams
21b7a9ee4f chore: fix breaking change in monaco 2021-10-27 13:52:32 +05:30
awu43
fa9fb61f6a feat(client): convert class components to functional components (#43226) 2021-10-27 11:17:47 +05:30
Krzysztof
f4cae7015f fix(client): use https for CodeAlly frame (#44024) 2021-10-26 17:46:45 -05:00
Ashis Kumar
94079b263a chore(client): Migration of SolutionViewer component to Typescript. (#43694)
* The Solutionviewer .js file has been migrated into the .tsx file.

* Apply suggestions from code review

I have added the suggestions and before adding them to the commit, I have checked it once locally and it doesn't throw any new error.

Co-authored-by: Nicholas Carrigan (he/him) <nhcarrigan@gmail.com>

* Update the SolutionViewer.tsx 

Added the "null" and "undefined" type to "solution" property.

* Update SolutionViewer.tsx

* Update ProjectModal.tsx

* Update ProjectModal.tsx

* Update SolutionViewer.tsx

* Update ProjectModal.tsx

* Apply suggestions from code review

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>

* Update client/src/components/SolutionViewer/ProjectModal.tsx

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>

* Apply suggestions from code review

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>

* Apply suggestions from code review

Co-authored-by: Nicholas Carrigan (he/him) <nhcarrigan@gmail.com>

* type of solution prop has been changed into "solution?:string;"

* assert solution is not `null` for modal

Co-authored-by: Nicholas Carrigan (he/him) <nhcarrigan@gmail.com>
Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
2021-10-26 12:16:25 -07:00
Maciek Sitkowski
cf0286dd36 chore(client): migrate Tool-Panel component to ts (#43790)
* chore: rename Tool-Panel.js to tool-panel.tsx

* feat: migrate tool-panel to ts

* chore: remove unused ts-expect-error

* chore: improve videoUrl and guideUrl types

* chore: update executeChallenge prop type
2021-10-26 09:00:17 -07:00
Oliver Eyton-Williams
866c9ee9d9 refactor: clean up MultifileEditor (#43996) 2021-10-25 22:06:11 -05:00
AndreiD049
a07a16b38b fix: added possibility to revert back to default profile picture (#43962)
* added possibility to revert to default profile picture

* removed required from picture input

* remove addPlaceholderImage and replaced with empty string

* added test for empty string to avatar-renderer
2021-10-25 21:06:32 +02:00
Vishwasa Navada K
9abc5f66ba feat(client): ts-migrate multiple files (#43262)
* feat(client): ts-migrate rename files

* feat(client): ts-migrate client/src/templates/Introduction/*

* feat(client): ts-migrate client/src/components/formHelpers/form*

* fix: import

* Update client/src/components/formHelpers/form-validators.tsx

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>

* Update client/src/components/formHelpers/form-fields.tsx

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>

* Update client/src/components/formHelpers/form-fields.tsx

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>

* fix: types in client/src/components/formHelpers/index.tsx

* fix: types in client/src/templates/Introduction/super-block-intro.tsx

* fix: types in client/src/components/formHelpers/*

* fix: signInLoading and value types

* Update client/src/templates/Introduction/super-block-intro.tsx

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

* Update client/src/components/formHelpers/index.tsx

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

* Update client/src/components/formHelpers/index.tsx

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

* Update client/src/components/formHelpers/index.tsx

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

* chore(deps): update dependency rollup to v2.58.1

* fix: rename variables and fix imports for ts-migrate

* fix: remove `Type` suffix from the type definition.

* Update client/src/components/formHelpers/form.tsx

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
Co-authored-by: Renovate Bot <bot@renovateapp.com>
2021-10-25 18:45:36 +01:00
Shaun Hamilton
d100132f75 feat(client): refactor Flash/redux into TS (#42725)
* feat(client): ts-migrate Flash/redux

* add app types

* convert Flash/redux/index to vanilla TS

* update redux types.ts

* use FlashState type over State type

* update typing

* fix: prettier errors I caused?

* fix: re-add comment I removed

* remove comment

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

* fix type to not include {}

* remove commented out code for future use

* remove unused initialState object

* rename Flash onClose prop to match action name

* directly type reducer to return state

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

Co-authored-by: moT01 <20648924+moT01@users.noreply.github.com>
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
2021-10-20 12:58:10 -05:00
Oliver Eyton-Williams
6c20301204 feat: control editor focus (#43882)
* refactor: MultifileEditor to functional component.

* fix: make editor acquire focus once on mount

Now the editors can leave the dom (e.g. if a tab is clicked), but an
editor will only call for focus if the MultifileEditor itself remounts
2021-10-19 08:52:51 -07:00
Shaun Hamilton
2bddbbff42 feat(client): refactor desktop-layout to ts (#42651)
Co-authored-by: moT01 <20648924+moT01@users.noreply.github.com>
2021-10-19 09:51:38 -05:00
Zachary Dixon
beb179ab1c Removed duplicate map.test.tsx (#43924)
* removed duplicate Map.test.tsx

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
2021-10-19 14:32:51 +04:00
Lucas Barros
2cd11a0ac8 feat: Typescript migration Map test (#43802) 2021-10-19 08:36:46 +05:30
Ahmed Ghoneim
0d1055fd08 (chore): refactor Map.test.js to map.test.tsx (#43897)
* chore: rename Map.test.js to map.test.tsx

* chore: refactor Map.test.js to typescript
2021-10-18 23:40:09 +04:00
Oliver Eyton-Williams
b9c1bc92cd refactor: remove redundant parts of the editor (#43847)
* refactor: remove forbidden regions

We aren't using them and they're implemented badly. To recreate them, we
should simply track the editable region and update them when it's Range
changes.

* refactor: simplify the refs considerably

There's no point keeping an object with properties for all possible
editors when only one is created at once.
2021-10-18 16:23:36 +03:00
Oliver Eyton-Williams
6a5f586f73 fix: handle challenge resets through redux (#43843)
Instead of relying on heuristics like "does the current content
differ from the initial content?" this just resets if the reset button
has been pressed.
2021-10-18 14:58:06 +03:00
Lim Shang Yi
3dbe40410c feat(client): language dropdown in the side menu is now a drop down (#43729)
* feat(UI): language in the side menu is now a drop down. navigation items are now text wrapped

* fix: use redux navigation to redirect links instead

* fix: fix to use clientLocale as curent language instead

* fix: tests to use clientLocale
2021-10-15 16:08:35 +03:00
Oliver Eyton-Williams
6b26ce2e0f fix(client): only target editor calls for focus (#43839)
For legacy challenges, there's only one editor and it must be focused.

For project steps, only the editor with the editable region should call
for focus.
2021-10-15 11:42:50 +01:00
RobertoMSousa
cb0a502d82 chore: tree shaking - unused / redundant code (#43867) 2021-10-15 13:13:43 +05:30
Shaun Hamilton
4a605c5cd2 feat(curriculum): add registration form practice project (#42876)
* feat(curriculum): add registration-form practice project

* add parts 001-006

* add parts 007-009

* add parts 010-013

* add parts 014-024, fix 013

* add parts 025-043

* add parts 043-046

* add parts 0047-057 without tests

* fix tests and adjust index.md file I do not understand

* add css tests to parts 037-040

* add tests parts 040-057

* remove space around ERM

* add true assertion until document iframe is fixed

* add critical review suggestions

Co-authored-by: Tom <20648924+moT01@users.noreply.github.com>
Co-authored-by: gikf <60067306+gikf@users.noreply.github.com>

* use clear, Tom-like language for 038

Co-authored-by: Tom <20648924+moT01@users.noreply.github.com>

* change order to match author's age

* apply suggestions with personal pazzaz

* add that thing Nich forgets

* use innerText

Co-authored-by: Nicholas Carrigan (he/him) <nhcarrigan@gmail.com>

Co-authored-by: Tom <20648924+moT01@users.noreply.github.com>
Co-authored-by: gikf <60067306+gikf@users.noreply.github.com>
Co-authored-by: Nicholas Carrigan (he/him) <nhcarrigan@gmail.com>
2021-10-14 15:33:13 -07:00
Meron Ogbai
06518c04a7 feat(ts-migrate): migrate sass-compile.js and test-evaluator.js to ts (#43145)
* feat(ts-migrate): rename sass-compile.js to ts

* feat(ts-migrate): rename test-evaluator.js to ts

* feat(ts-migrate): add webworker in client tsconfig

* fix(ts-migrate): fix errors in sass-compile.ts

* chore(ts-migrate): install chai types in client

* fix(ts-migrate): fix errors in test-evaluator.ts

* fix(ts-migrate): rename extensions in webpack-worker

* fix(ts-migrate): separate tsconfig for workers

* fix(ts-migrate): add worker tsconfig to parser options

* chore(ts-migrate): remove unnecessary comment

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

* fix(ts-migrate): use let instead of const

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

* fix(ts-migrate): fix eslint errors in sass-compile.ts

* fix(ts-migrate): fix eslint errors in test-evaluator.ts

* chore(ts-migrate): use unknown instead of generics

* chore(ts-migrate): revert worker tsconfig

* chore(ts-migrate): add libs in client tsconfig

* fix(ts-migrate): use ctx alias in test-evaluator.ts

* fix(ts-migrate): use ctx alias in sass-compile.ts

* chore: fix errors

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
2021-10-14 13:44:55 -05:00
Oliver Eyton-Williams
9bb1919e83 feat: display instructions on frontend projects (#43862) 2021-10-14 10:55:40 -05:00
Ahmad Abdolsaheb
4d245ef004 feat: remove unused files (#43861) 2021-10-14 15:48:08 +02:00
RobertoMSousa
01fd9a80d8 CHORE: migrate intro component (#43784)
* migrate intro component

* Update client/src/components/Intro/index.tsx

Co-authored-by: Nicholas Carrigan (he/him) <nhcarrigan@gmail.com>

* Update client/src/components/Intro/index.tsx

Co-authored-by: Nicholas Carrigan (he/him) <nhcarrigan@gmail.com>

Co-authored-by: Nicholas Carrigan (he/him) <nhcarrigan@gmail.com>
2021-10-14 15:19:03 +02:00
Ethan Edmond
d36a9a3c66 chore: delete obsolete file throwers.js (#43850) 2021-10-14 10:43:32 +02:00
Oliver Eyton-Williams
8a47b60890 chore: remove debugging console logs (#43837) 2021-10-13 15:11:02 +03:00
Oliver Eyton-Williams
22afdd1aad fix: stop modal appearing in steps (#43728)
* fix: stop showing completion modal on steps

* feat: submit steps with ctrl+enter

* fix: handle ctrl+enter when not focussing editor

* fix: reset tests when user types

* refactor: pass showCompletionModal as an option

Otherwise we have to write executeChallenge(true) which does not mean
what you might reasonably expect.

* fix: always executeChallenge when not on step

* fix: update frontend project show

* fix: handle missing payload

* refactor: isProjectStep -> hasEditableRegion

* refactor: more renaming

* fix: make meta.json control multifile editor use

* fix: update the challengeSchema correctly

* Update client/src/templates/Challenges/classic/editor.tsx

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>

* fix: remove logging

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>

Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
2021-10-13 14:47:59 +03:00
RobertoMSousa
9220bfedad migrate donation (#43783) 2021-10-13 12:49:02 +03:00
Oliver Eyton-Williams
61d6b02c79 fix: update jaws on resize (#43777)
* fix: update jaws on resize

Use isProjectStep to determine if the jaws need to be updated

* refactor: isProjectStep -> hasEditableRegion

isProjectStep was misleading.  hasEditableRegion correctly describes
that function and leaves isProjectStep to enable features that are
unique to project steps, but nothing to do with the editable region
2021-10-13 12:40:28 +03:00
Maciek Sitkowski
3eae0645ab fix: add translated close button label in alert messages (#43810) 2021-10-13 11:07:29 +02:00
Oliver Eyton-Williams
e209582daf chore: remove night-mode-saga (#43829)
The saga only sets the value of fcc-theme in storage, but the values are
never retrieved, so the saga can be removed.
2021-10-13 12:00:00 +03:00
Oliver Eyton-Williams
461e429598 fix(client): prevent jumping between editor tabs (#43771) 2021-10-08 22:14:15 +01:00
Ahmad Abdolsaheb
982a6e90d4 feat: add placeholder color to card form (#43757) 2021-10-07 18:03:39 +05:30
Oliver Eyton-Williams
e3e794ddef fix(client): only jump to editable region on reset (#43748)
If the code has changed without the user typing (e.g. they've pushed
the restart button), then we jump them back to the editable region.
Otherwise (e.g. they've typed in the editor) we reset the display, but
do not move the editor.
2021-10-06 14:09:04 -07:00
Lim Shang Yi
df8dc9b9c6 fix(ui): Fix crash when viewing an invalid certificate (#43681)
* fix: remove empty object literal creation causing #43224

* fix: initialize userByName selector using empty object from initialState to keep the same reference instead

* fix(lang): added translation for invalid certificate
2021-10-06 21:05:05 +02:00
Oliver Eyton-Williams
c8d7f0a782 feat(tools): remove eslint-plugin-prettier for prettier (#42438)
* feat: remove eslint-plugin-prettier for prettier

This removes the annoying lint warnings when all that needs to change is
formatting

* fix: use .js lint-staged config to ignore properly

* fix: lint everything if a lot of files are changed

It's faster than making lots of individual linter calls

* chore: apply prettier

* fix: ignore code in curriculum-file-structure
2021-10-06 21:02:21 +05:30
Noor Fakhry
8518079316 fix(client):make menu bar disappear after user chooses item from it on landing page (#43458)
* removed serachBarRef

* removed serachBarRef

* Revert "removed serachBarRef"

This reverts commit 6a5c2f4cb3.

* Revert "removed serachBarRef"

This reverts commit 67710b3d18.

* added innerRef as ref to SearchBarOptimized component

* Update client/src/components/Header/index.tsx

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

* Update client/src/components/search/searchBar/search-bar-optimized.tsx

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

* Update client/src/components/search/searchBar/search-bar-optimized.tsx

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>

Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
2021-10-06 16:42:54 +02:00
Budbreaker
bc802cbbbd feat: added warning for unreachable server (#43576)
* feat: added warning for unreachable server

* fix: update initial state in test file

* fix: make offline warning scroll with page

* adjust z-indexes for warning banners

* add hyperlink for offline warning
2021-10-06 15:18:02 +02:00
Oliver Eyton-Williams
83354c5632 fix: stop using .night to control theme (#43745)
.light-palette and .dark-palette should be enough, so there's no need
to attach the default or night classes to the html element
2021-10-06 11:30:15 +01:00
Kristofer Koishigawa
580f57cf5f feat: add code highlighting to descriptions in the new editor (#43740) 2021-10-06 11:26:22 +02:00
Oliver Eyton-Williams
b0d48b8463 fix: reset editor display on user interaction (#43730)
If the user types in the editor or pushes the reset button, the lower
jaw now resets to the default state.
2021-10-06 12:22:00 +03:00
Tomer Ben-Rachel
4ffc06e014 fix: correct theme when viewing certifications challenges solutions 2021-10-06 11:05:52 +02:00
Oliver Eyton-Williams
38d65f95b4 refactor(editor): improve naming and comments (#43662)
Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
Co-authored-by: Sem Bauke <46919888+Sembauke@users.noreply.github.com>
2021-10-04 19:18:57 +05:30
RobertoMSousa
f5de80dc4f chore: migrate to jsx element (#43707) 2021-10-04 19:16:34 +05:30
Eric Cheng
1f880a552d fix(docs): modified grammar and phrasing in docs and comments (#43682)
* docs: fixed minor typos in how-to-open-a-pull-request.md

* docs: grammar fixes in FAQ.md

* refactor: streamlined comments in multiple TS files

* fix: linting issues
2021-10-02 23:43:14 +01:00