-
Notifications
You must be signed in to change notification settings - Fork 18
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: [BD-26][EDUCATOR-5808] Part-2 Add additional pages for onboardi…
…ng / practice exams (#17) * feat: check for verification only for proctored exams (previously were checkin for practice and onboarding also) * feat: add Error, Submitted and Verified instruction pages * test: add tests for Error, Submitted and Verified instructions * feat: add allowProctoringOptOut to examState and use getSequenceMetadata API * feat: Use sequence from the learning app instead of hitting the endpoint Co-authored-by: Viktor Rusakov <[email protected]>
- Loading branch information
1 parent
e44e38e
commit 5ea7bec
Showing
25 changed files
with
689 additions
and
121 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
import React from 'react'; | ||
import PropTypes from 'prop-types'; | ||
import { Container } from '@edx/paragon'; | ||
import { ExamType } from '../constants'; | ||
import { ErrorPracticeExamInstructions } from './practice_exam'; | ||
import { ErrorOnboardingExamInstructions } from './onboarding_exam'; | ||
import { ErrorProctoredExamInstructions } from './proctored_exam'; | ||
import Footer from './proctored_exam/Footer'; | ||
|
||
const ErrorExamInstructions = ({ examType }) => { | ||
const renderInstructions = () => { | ||
switch (examType) { | ||
case ExamType.ONBOARDING: | ||
return <ErrorOnboardingExamInstructions />; | ||
case ExamType.PRACTICE: | ||
return <ErrorPracticeExamInstructions />; | ||
case ExamType.PROCTORED: | ||
return <ErrorProctoredExamInstructions />; | ||
default: | ||
return null; | ||
} | ||
}; | ||
|
||
return ( | ||
<div> | ||
<Container className="border py-5 mb-4"> | ||
{renderInstructions()} | ||
</Container> | ||
{examType !== ExamType.TIMED && <Footer />} | ||
</div> | ||
); | ||
}; | ||
|
||
ErrorExamInstructions.propTypes = { | ||
examType: PropTypes.string.isRequired, | ||
}; | ||
|
||
export default ErrorExamInstructions; |
Oops, something went wrong.