Commit 5d4ee11f authored by baesangjune's avatar baesangjune
Browse files

.

parent c836a803
...@@ -90,14 +90,14 @@ function Admin() { ...@@ -90,14 +90,14 @@ function Admin() {
<p className="navbar-text border-bottom">관리자 설정 변경하기</p> <p className="navbar-text border-bottom">관리자 설정 변경하기</p>
<a className="nav-link" id="setting-tab" data-toggle='pill' href="#setting" role="tab">Setting</a> <a className="nav-link" id="setting-tab" data-toggle='pill' href="#setting">Setting</a>
<p className="navbar-text border-bottom">Quiz 입력하기</p> <p className="navbar-text border-bottom">Quiz 입력하기</p>
<a className="nav-link" id="Quiz1-tab" data-toggle="pill" href="#Quiz1" role="tab" >Quiz1</a> <a className="nav-link" id="Quiz1-tab" data-toggle="pill" href="#Quiz1" >Quiz1</a>
<a className="nav-link" id="Quiz2-tab" data-toggle="pill" href="#Quiz2" role="tab" >Quiz2</a> <a className="nav-link" id="Quiz2-tab" data-toggle="pill" href="#Quiz2" >Quiz2</a>
<a className="nav-link" id="Quiz3-tab" data-toggle="pill" href="#Quiz3" role="tab" >Quiz3</a> <a className="nav-link" id="Quiz3-tab" data-toggle="pill" href="#Quiz3" >Quiz3</a>
{addQuiz} {addQuiz}
<button className="btn btn-danger navbar-btn" onClick={handleClickQuiz} >Quiz 추가</button> <button className="btn btn-danger navbar-btn" onClick={handleClickQuiz} >Quiz 추가</button>
...@@ -113,20 +113,20 @@ function Admin() { ...@@ -113,20 +113,20 @@ function Admin() {
<div className="row d-flex justify-content-center"> <div className="row d-flex justify-content-center">
<div className="col-8"> <div className="col-8">
<h1 className="p-3 border">관리자 설정 변경 </h1> <h2 className="p-3 border text-center bg-danger">관리자 설정변경</h2>
<div className="p-3 border"> <div className="p-3 border">
<h2>변경할 비밀번호를 입력하세요</h2> <h3>변경할 비밀번호를 입력하세요</h3>
<input type="text" onChange={handleChangePassword} placeholder="New Password" /> <input className='p-2' type="text" onChange={handleChangePassword} placeholder="New Password" />
</div> </div>
<div className="p-3 border"> <div className="p-3 border">
<h2>변경할 관리자 비밀번호를 입력하세요</h2> <h3>변경할 관리자 비밀번호를 입력하세요</h3>
<input type="text" onChange={handleChangeAdminPassword} placeholder="New Admin Password" /> <input className='p-2' type="text" onChange={handleChangeAdminPassword} placeholder="New Admin Password" />
</div> </div>
<div className="p-3 border"> <div className="p-3 border">
<h2>타이머를 설정하세요(초단위)</h2> <h3>타이머를 설정하세요(초단위)</h3>
<input type="text" onChange={handleChangeTime} placeholder="Set Time" /> <input className='p-2' type="text" onChange={handleChangeTime} placeholder="Set Time" />
</div> </div>
...@@ -149,24 +149,24 @@ function Admin() { ...@@ -149,24 +149,24 @@ function Admin() {
<div className="row d-flex justify-content-center"> <div className="row d-flex justify-content-center">
<div className="col-8"> <div className="col-8">
<h2 className="p-3 border text-center">문제만들기</h2> <h2 className="p-3 border text-center bg-danger ">문제만들기</h2>
<div className="p-3 borber"> <div className="p-3 borber">
<div className="p-3 "> <div className="p-3 ">
<span className="font-weight-bold mr-2 h3">1.</span> <span className="font-weight-bold mr-2 h3">1.</span>
{/* <input type="text" onChange={handleChangenumber} placeholder="Number" /> */} {/* <input type="text" onChange={handleChangenumber} placeholder="Number" /> */}
<input type="text" onChange={handleChangeQuestion} placeholder="문제를 입력하세요" /> <input className='p-2' type="text" onChange={handleChangeQuestion} placeholder="문제를 입력하세요" />
</div> </div>
<div className="p-3 "> <div className="p-3 ">
<div className="input-group"> <div className="input-group">
<div className="input-group-prepend"> <div className="input-group-prepend">
<div className="input-group-text"> <div className="input-group-text p-3">
<input type="radio" id="option" /> <input type="radio" id="option" />
</div> </div>
</div> </div>
<input type="text" className="form-control" placeholder="보기를 입력하세요" onChange={handleChangechoose} /> <input type="text" className="form-control p-4" placeholder="보기를 입력하세요" onChange={handleChangechoose} />
</div> </div>
{selectOption} {selectOption}
...@@ -176,7 +176,7 @@ function Admin() { ...@@ -176,7 +176,7 @@ function Admin() {
<div className="p-3 "> <div className="p-3 ">
<span className="font-weight-bold mr-2 h3">정답:</span> <span className="font-weight-bold mr-2 h3">정답:</span>
<input type="text" onChange={handleChangeanswer} placeholder="정답을 입력하세요" /> <input className='p-2' type="text" onChange={handleChangeanswer} placeholder="정답을 입력하세요" />
</div> </div>
<label for="inputLogin" className="d-flex justify-content-center"> <label for="inputLogin" className="d-flex justify-content-center">
...@@ -196,24 +196,24 @@ function Admin() { ...@@ -196,24 +196,24 @@ function Admin() {
<div className="row d-flex justify-content-center"> <div className="row d-flex justify-content-center">
<div className="col-8"> <div className="col-8">
<h2 className="p-3 border text-center">문제만들기</h2> <h2 className="p-3 border text-center bg-danger">문제만들기</h2>
<div className="p-3 borber"> <div className="p-3 borber">
<div className="p-3 "> <div className="p-3 ">
<span className="font-weight-bold mr-2 h3">1.</span> <span className="font-weight-bold mr-2 h3">1.</span>
{/* <input type="text" onChange={handleChangenumber} placeholder="Number" /> */} {/* <input type="text" onChange={handleChangenumber} placeholder="Number" /> */}
<input type="text" onChange={handleChangeQuestion} placeholder="문제를 입력하세요" /> <input className='p-2' type="text" onChange={handleChangeQuestion} placeholder="문제를 입력하세요" />
</div> </div>
<div className="p-3 "> <div className="p-3 ">
<div className="input-group"> <div className="input-group">
<div className="input-group-prepend"> <div className="input-group-prepend">
<div className="input-group-text"> <div className="input-group-text p-3">
<input type="radio" id="option" /> <input type="radio" id="option" />
</div> </div>
</div> </div>
<input type="text" className="form-control" placeholder="보기를 입력하세요" onChange={handleChangechoose} /> <input type="text" className="form-control p-4" placeholder="보기를 입력하세요" onChange={handleChangechoose} />
</div> </div>
{selectOption} {selectOption}
...@@ -223,7 +223,7 @@ function Admin() { ...@@ -223,7 +223,7 @@ function Admin() {
<div className="p-3 "> <div className="p-3 ">
<span className="font-weight-bold mr-2 h3">정답:</span> <span className="font-weight-bold mr-2 h3">정답:</span>
<input type="text" onChange={handleChangeanswer} placeholder="정답을 입력하세요" /> <input className='p-2' type="text" onChange={handleChangeanswer} placeholder="정답을 입력하세요" />
</div> </div>
<label for="inputLogin" className="d-flex justify-content-center"> <label for="inputLogin" className="d-flex justify-content-center">
...@@ -240,24 +240,24 @@ function Admin() { ...@@ -240,24 +240,24 @@ function Admin() {
<div className="row d-flex justify-content-center"> <div className="row d-flex justify-content-center">
<div className="col-8"> <div className="col-8">
<h2 className="p-3 border text-center">문제만들기</h2> <h2 className="p-3 border text-center bg-danger">문제만들기</h2>
<div className="p-3 borber"> <div className="p-3 borber">
<div className="p-3 "> <div className="p-3 ">
<span className="font-weight-bold mr-2 h3">1.</span> <span className="font-weight-bold mr-2 h3">1.</span>
{/* <input type="text" onChange={handleChangenumber} placeholder="Number" /> */} {/* <input type="text" onChange={handleChangenumber} placeholder="Number" /> */}
<input type="text" onChange={handleChangeQuestion} placeholder="문제를 입력하세요" /> <input className='p-2' type="text" onChange={handleChangeQuestion} placeholder="문제를 입력하세요" />
</div> </div>
<div className="p-3 "> <div className="p-3 ">
<div className="input-group"> <div className="input-group">
<div className="input-group-prepend"> <div className="input-group-prepend">
<div className="input-group-text"> <div className="input-group-text p-3">
<input type="radio" id="option" /> <input type="radio" id="option" />
</div> </div>
</div> </div>
<input type="text" className="form-control" placeholder="보기를 입력하세요" onChange={handleChangechoose} /> <input type="text" className="form-control p-4" placeholder="보기를 입력하세요" onChange={handleChangechoose} />
</div> </div>
{selectOption} {selectOption}
...@@ -267,7 +267,7 @@ function Admin() { ...@@ -267,7 +267,7 @@ function Admin() {
<div className="p-3 "> <div className="p-3 ">
<span className="font-weight-bold mr-2 h3">정답:</span> <span className="font-weight-bold mr-2 h3">정답:</span>
<input type="text" onChange={handleChangeanswer} placeholder="정답을 입력하세요" /> <input className='p-2' type="text" onChange={handleChangeanswer} placeholder="정답을 입력하세요" />
</div> </div>
<label for="inputLogin" className="d-flex justify-content-center"> <label for="inputLogin" className="d-flex justify-content-center">
......
...@@ -11,7 +11,7 @@ const QnA = [ ...@@ -11,7 +11,7 @@ const QnA = [
{ Q: "3 - 1 = ?", Choose: [1, 2, 3, 4], N: 3 } { Q: "3 - 1 = ?", Choose: [1, 2, 3, 4], N: 3 }
] ]
let Answers = [0,0,0] let Answers = [0, 0, 0]
localStorage.setItem('Answers', JSON.stringify(Answers)) localStorage.setItem('Answers', JSON.stringify(Answers))
let Solutions = [4, 3, 2] let Solutions = [4, 3, 2]
localStorage.setItem('Solutions', JSON.stringify(Solutions)) localStorage.setItem('Solutions', JSON.stringify(Solutions))
...@@ -76,8 +76,9 @@ function Quiz() { ...@@ -76,8 +76,9 @@ function Quiz() {
initialTime={36000} initialTime={36000}
direction="backward" direction="backward"
checkpoints={[ checkpoints={[
{time:1, {
callback:()=>alert('시간이 초과되었습니다.'), time: 1,
callback: () => alert('시간이 초과되었습니다.'),
}, },
{ {
time: 0, time: 0,
...@@ -88,7 +89,8 @@ function Quiz() { ...@@ -88,7 +89,8 @@ function Quiz() {
> >
{() => ( {() => (
<> <>
<Timer.Minutes /> : <Timer.Seconds></Timer.Seconds> / 60 : 00 </> <Timer.Minutes /> : <Timer.Seconds /> / 30 : 00
</>
)} )}
</Timer> {/* npm i react-compound-timer */} </Timer> {/* npm i react-compound-timer */}
</p> </p>
...@@ -98,7 +100,7 @@ function Quiz() { ...@@ -98,7 +100,7 @@ function Quiz() {
</div> </div>
</div> </div>
</div> </div>
{timeout ? <Redirect to='/end'/> : '' } {timeout ? <Redirect to='/end' /> : ''}
</> </>
) )
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment