File tree 4 files changed +16
-3
lines changed
4 files changed +16
-3
lines changed Original file line number Diff line number Diff line change 3
3
import React from "react" ;
4
4
import PropTypes from "prop-types" ;
5
5
import RevisionTitle from "./RevisionTitle" ;
6
+ import timerFormat from "../../../utils/timerFormat" ;
6
7
7
8
export default class ResultsContainer extends React . Component {
8
9
render ( ) {
@@ -21,7 +22,8 @@ export default class ResultsContainer extends React.Component {
21
22
</ li >
22
23
< li className = "result-list-item" >
23
24
You performed { this . props . markSchemeCompleted } of{ " " }
24
- { this . props . markSchemeTotal } tasks.
25
+ { this . props . markSchemeTotal } tasks in{ " " }
26
+ { timerFormat ( this . props . timeElapsed ) } .
25
27
</ li >
26
28
</ ul >
27
29
</ div >
@@ -34,5 +36,6 @@ ResultsContainer.propTypes = {
34
36
markSchemeCompleted : PropTypes . number ,
35
37
markSchemeTotal : PropTypes . number ,
36
38
markSchemeElements : PropTypes . arrayOf ( PropTypes . object ) ,
37
- caseTitle : PropTypes . string
39
+ caseTitle : PropTypes . string ,
40
+ timeElapsed : PropTypes . number
38
41
} ;
Original file line number Diff line number Diff line change @@ -89,6 +89,7 @@ export default class RevisionPage extends React.Component {
89
89
markSchemeCompleted = { this . state . markSchemeCompleted }
90
90
markSchemeElements = { this . state . markSchemeElements }
91
91
caseTitle = { this . state . caseTitle }
92
+ timeElapsed = { this . state . time }
92
93
/>
93
94
) ;
94
95
const { exam, station } = this . props . match . params ;
Original file line number Diff line number Diff line change 73
73
display : flex ;
74
74
justify-content : center ;
75
75
}
76
+
77
+ .timer-long {
78
+ color : $peter-red ;
79
+ }
Original file line number Diff line number Diff line change @@ -18,7 +18,12 @@ export default class TopBar extends React.Component {
18
18
{ this . props . stationName && removeHyphens ( this . props . stationName ) }
19
19
</ h3 >
20
20
{ this . props . timer && (
21
- < h3 id = "topbar-timer" > { timerFormat ( this . props . time ) } </ h3 >
21
+ < h3
22
+ className = { this . props . time >= 600 ? `timer-long` : `` }
23
+ id = "topbar-timer"
24
+ >
25
+ { timerFormat ( this . props . time ) }
26
+ </ h3 >
22
27
) }
23
28
{ this . props . tickDisplayed && (
24
29
< CompleteButton
You can’t perform that action at this time.
0 commit comments