feat: display multifile projects (#45220)

* refactor: DRY up certification and ProjectModal

* fix: use sensible keys for SolutionViewer

* refactor: handle legacy solutions like new ones

* refactor: correct CompletedChallenge type

* fix: store challengeType for multifile projects

* fix: use challengeType to set display type

* feat: use dropdown to display project + code

* refactor: isOpen -> showCode to avoid a clash

We need to be able both show the code and show the completed project

* refactor: remove redundant parts of projectPreview

* refactor: fix project preview types

* feat: wip, using existing modal to show project

* feat: show projects on timeline

* feat: display projects on time-line

* chore: use consistent case for GitHub

* fix(a11y): translate show solution/view

* refactor: rename showFilesSolution

* refactor: use self-closing tag

* fix: remove hardcoding (certification + timeline)

* fix: remove hardcoding (settings)

* test: supply store and mock ga

* fix: include challengeType for projects

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

* refactor: remove space

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

* fix: key -> filekey on challenge submission

* fix: handle submissions without files

Co-authored-by: Tom <20648924+moT01@users.noreply.github.com>
This commit is contained in:
Oliver Eyton-Williams
2022-03-03 02:49:54 +01:00
committed by GitHub
parent d1d04dbadf
commit c11bd163b2
19 changed files with 414 additions and 244 deletions

View File

@ -126,9 +126,7 @@ function getProjectPreviewConfig(challenge, allChallengeEdges) {
challengeType !== challengeTypes.multiFileCertProject,
challengeData: {
challengeType: lastChallenge.challengeType,
challengeFiles: projectPreviewChallengeFiles,
required: lastChallenge.required,
template: lastChallenge.template
challengeFiles: projectPreviewChallengeFiles
}
};
}