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

Commit9ad2069

Browse files
committed
number hints
Signed-off-by: shmck <shawn.j.mckay@gmail.com>
1 parentae0c0b1 commit9ad2069

File tree

2 files changed

+8
-6
lines changed

2 files changed

+8
-6
lines changed

‎web-app/src/components/Markdown/index.tsx

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
11
importMarkdownItfrom'markdown-it'
2-
//@ts-ignore no types for package
3-
42
importPrismfrom'prismjs'
5-
63
//@ts-ignore no types for package
74
importmarkdownEmojifrom'markdown-it-emoji'
85
import*asReactfrom'react'

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

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ const styles = {
1414
marginBottom:'0.5rem',
1515
backgroundColor:'rgba(255,229,100,0.3)',
1616
borderLeft:'#ffe564',
17+
borderRadius:'2px',
1718
padding:'0 0.5rem',
1819
},
1920
}
@@ -44,11 +45,15 @@ const Hints = (props: Props) => {
4445
<divcss={styles.hintList}>
4546
{/* only show revealed hints */}
4647
{props.hints.map((hint,index)=>{
47-
returnindex<=hintIndex ?(
48+
if(index>hintIndex){
49+
// hint not yet revealed
50+
returnnull
51+
}
52+
return(
4853
<divkey={index}css={styles.hint}>
49-
<Markdowncss={styles.hint}>{hint}</Markdown>
54+
<Markdown>{`${index+1}.&nbsp;${hint}`}</Markdown>
5055
</div>
51-
) :null
56+
)
5257
})}
5358
</div>
5459
<ButtononClick={nextHint}disabled={isFinalHint}>

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp