Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit261d4a3

Browse files
committed
display all review level/steps
Signed-off-by: shmck <shawn.j.mckay@gmail.com>
1 parent0c1405d commit261d4a3

File tree

4 files changed

+16
-4
lines changed

4 files changed

+16
-4
lines changed

‎web-app/src/containers/Tutorial/components/Step.tsx

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ interface Props {
88
content:string
99
status:T.ProgressStatus
1010
subtasks:{name:string;pass:boolean}[]|null
11+
displayAll:boolean
1112
}
1213

1314
conststyles={
@@ -40,7 +41,7 @@ const styles = {
4041
}
4142

4243
constStep=(props:Props)=>{
43-
constshowStep=props.status!=='INCOMPLETE'
44+
constshowStep=props.displayAll||props.status!=='INCOMPLETE'
4445
if(!showStep){
4546
returnnull
4647
}

‎web-app/src/containers/Tutorial/components/Steps.tsx

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import Hints from './Hints'
66

77
interfaceProps{
88
steps:TT.Step[]
9+
displayAll:boolean
910
}
1011

1112
conststyles={
@@ -27,7 +28,13 @@ const Steps = (props: Props) => {
2728
}
2829
return(
2930
<divkey={step.id}>
30-
<Stepkey={step.id}status={step.status||'INCOMPLETE'}content={step.content}subtasks={step.subtasks}/>
31+
<Step
32+
key={step.id}
33+
status={step.status||'INCOMPLETE'}
34+
displayAll={props.displayAll}
35+
content={step.content}
36+
subtasks={step.subtasks}
37+
/>
3138
<Hintshints={step.hints||[]}/>
3239
</div>
3340
)

‎web-app/src/containers/Tutorial/components/TestStatusIcon.tsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,12 +19,16 @@ const styles = {
1919
icon:'warning',
2020
color:'#ff9300',
2121
},
22+
incomplete:{
23+
icon:'lock',
24+
color:'lightgrey',
25+
},
2226
}
2327

2428
constTestStatusIcon=(props:Props)=>{
2529
//@ts-ignore
2630
conststyle:{icon:string;color:string}=styles[props.status.toLowerCase()]
27-
return<Icontype="success-filling"size={props.size}style={{color:style.color}}/>
31+
return<Icontype={style.icon}size={props.size}style={{color:style.color}}/>
2832
}
2933

3034
exportdefaultTestStatusIcon

‎web-app/src/containers/Tutorial/containers/Review.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ const ReviewPage = (props: Props) => {
3535
<divkey={level.id}>
3636
<div>
3737
<Contenttitle={level.title}content={level.content}/>
38-
<Stepssteps={level.steps}/>
38+
<Stepssteps={level.steps}displayAll/>
3939
</div>
4040
{/* divider */}
4141
{index<props.levels.length-1 ?<hr/> :null}

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp