* chore(deps): update jest monorepo to v29
* chore: install jest-environment-jsdom
* chore: update snapshots
* fix: update config to transform nanoid+uuid
* chore: update babel's node target
This does not seem strictly necessary, but is probably for the best.
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
* feat: npm -> pnpm
This resolves the issues with the gatsby client (gatsby-plugin-pnpm
deals with the fact that gatsby is relying on its own dependencies
being de-duped)
and challenge-editor (which doesn't seem to want to automatically install
codemirror and needed its own eslint config)
* fix: correct mocha path for curriculum tests
* fix: use select workspace with -F not -w
* fix: reorganise packages and restrict hoisting
pnpm works best if the workspaces keep their own dependencies, since
dependencies are not flattened and then what node resolves from a
require is predictable.
@types seem to be a special case and more care is required to prevent
them getting smushed together in the root (hence the .npmrc)
* fix: add types for tools + root
* fix: decouple challenge-auditor from client
* fix: add ui-components types
* fix(client): use the latest types for react 16
* fix: prettify
* fix: prettierignore pnpm-lock
* fix: relax hoisting
Turns out pnpm works just fine with types. I don't know what was going
wrong before, but there are no-longer any type conflicts.
* fix: add @redux-saga/core to fix eslint issue
It seems to only be redux-saga that import/named can't cope with, so it
is probably okay to work around this one.
* chore: add chai to tools/scripts/build
* fix: add store to root for cypress
* fix: allow cypress to download binaries
If we want to keep preventing cypress from downloading binaries, we can
figure out a workaround, but I'm allowing it to ease the transition to
pnpm.
My guess about why this is happening is that npm triggers Cypress's
postinstall script, but pnpm does not (because pnpm install only
installs if necessary, perferring to link)
* chore: re-enable pre/post scripts
* fix: update build scripts for client
Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
* chore: update engines to use pnpm
* fix: enable choice of (super)block for tests
Only 'nix machines for now.
* chore: pin pnpm to version 7
* chore: remove last npms
Except web + curriculum-server. I'll update them when I start work on
them again.
* fix: lockfile check to catch any package-locks
* fix(action): install pnpm for upcoming tests
* chore: add nodemon to new api
Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
* feat: integrate the odin project
* feat: add assignment to markdown parser
* feat: add assignment logic
* fix: doe not always show assignment block
* fix: some other stuff
* fix: introdiction to html and css questions
* fix: remove assignments after first question
* fix: update snapshots and tests
* feat: create rest of HTML foundation course structure
* feat: meta file
* feat: add descriptions to 'html boiler plate' questions
* feat: add description for 'working with text and list items'
* fix: multiple logic issues
* fix: make linter happy
* feat: add description for 'links and images' questions
* fix: add assignments to Joi schema
* fix: tests
* fix: schema
* fix: add help category
* fix: change to possessive wording
* fix: set upcoming change to true in meta file
* fix: spell unordered and ordered correctly
* fix: switch order in meta
* fix: spell boilerplate correctly
* feat: add final project
* chore: add more tests to the final project
* fix: question spelling
* Apply suggestions from code review
Co-authored-by: Naomi Carrigan <nhcarrigan@gmail.com>
* Apply suggestions from code review
Co-authored-by: Naomi Carrigan <nhcarrigan@gmail.com>
* Apply suggestions from code review
Co-authored-by: Naomi Carrigan <nhcarrigan@gmail.com>
* Apply suggestions from code review
Co-authored-by: Naomi Carrigan <nhcarrigan@gmail.com>
* Apply suggestions from code review
Co-authored-by: Naomi Carrigan <nhcarrigan@gmail.com>
* Apply suggestions from code review
Co-authored-by: Naomi Carrigan <nhcarrigan@gmail.com>
* fix: translation
* Update client/i18n/locales/english/translations.json
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
* fix: create new challenge type
* fix: get the new challenge type working and remove ol css
* fix: translation location
* fix: add challenge type to epic
* fix: set correct video
* fix: max challengeType number
* fix: spelling/grammar errors in project
* fix: check if anchor tags is empty
* Apply suggestions from code review
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
* Update tools/challenge-parser/parser/plugins/add-video-question.js
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
* chore: multiple suggestions
* chore: separate assignments into different plugin
* Apply suggestions from code review
Co-authored-by: Kristofer Koishigawa <scissorsneedfoodtoo@gmail.com>
* fix: dubble answer header after review
* fix: issue with Gatsby hopefully
* fix: add assignments to Gatsby's Challenge schema
* Update curriculum/schema/challengeSchema.js
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
Co-authored-by: Naomi Carrigan <nhcarrigan@gmail.com>
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
Co-authored-by: Kristofer Koishigawa <scissorsneedfoodtoo@gmail.com>
* fix: handle missing solutions correctly
Rather than creating an [[]] the parser now creates [] which isEmpty().
This makes the test suite check the next challenge for a solution.
In addition, the logic for testing solutions was fixed.
* chore: update snapshots
* test: build new superblock in node.js-tests CI
* test: allow forward slash in superblock slug
* fix: borked tests oops
* test: ignore duplicated projects
* fix: i did not break these shaun did :)
* fix: idIndex is index of id not id
Co-authored-by: Nicholas Carrigan <nhcarrigan@gmail.com>
* feat: add notes tab to project based curriculum
* feat: add console key to i18n
* feat: add reset to i18n
* fix: use translations in action-row
* fix: use hasEditableBoundaries as check for when to display instructions/editor-tabs
* fix: clean up notes components and use prism formatting
* feat: add notes to docs/how-to-work-on-challenges
* revert: unused code
* fix: lint errors?
* fix: lint errors
* fix: add notes to graphql schema
* fix: add notes to challenge schema
* fix: only display notes on project based
* fix: add env data back to mobile layout
* fix: prettify
* revert: notes
* fix: hide notes on mobile for non project based
* rename: switchDisplayTab -> togglePane
* revert: hasEditableBoundaries check back to projectBasedChallenge check
* fix: replace index with script/styles as needed
* fix: remove redundant fileKey
It's overwritten by createPoly, so the parser does not need to create it
* fix: curriculum test suite
* Update client/src/templates/Challenges/classic/MultifileEditor.js
Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
Co-authored-by: Shaun Hamilton <shauhami020@gmail.com>
* 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
* fix(client): fix client
* fix propType and add comment
* revert user.json prettification
* slight type refactor and payload correction
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
* update ChallengeFile type imports
* add cypress test for code-storage
* update test and storage epic
* fix Shaun's tired brain's logic
* refactor with suggestions
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
* update codeReset
* increate cypress timeout because firefox is slow
* remove unused import to make linter happy
* use focus on editor
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
* use more specific seletor for cypress editor test
* account for silly null challengeFiles
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
Co-authored-by: Oliver Eyton-Williams <ojeytonwilliams@gmail.com>
* fix: remove circular dependency
redux depended on templates/Challenges/redux and vice versa. This
meant that import order mattered and confusing bugs could arise.
(cherry picked from commit 7d67a4e70922bbb3051f2f9982dcc69e240d43dc)
* feat: require imports to be in alphabetical order
Import order generally does not matter, but there are edge cases
(circular imports and css imports, for example) where changing order
changes behaviour
(cherry picked from commit b8d1393a91ec6e068caf8e8498a5c95df68c2b2c)
* chore: order imports
* fix: lift up challenge description + title comps
This brings the classic Show closer to the others as they
now all create the description and title components
* fix: remove donation-saga/index circular import
(cherry picked from commit 51a44ca668a700786d2744feffeae4fdba5fd207)
* refactor: extract action-types from settings
(cherry picked from commit 25e26124d691c84a0d0827d41dafb761c686fadd)
* fix: lint errors
* feat: prevent useless renames