Commit 50fcae81 authored by 김민수's avatar 김민수
Browse files

형태만 잡음 수정하자

parent f003d4ee
...@@ -11,7 +11,7 @@ function App() { ...@@ -11,7 +11,7 @@ function App() {
<Router> <Router>
<header> <header>
<Link to="/"> <Link to="/">
<button>Calculus</button> <button>Home</button>
</Link> </Link>
</header> </header>
<hr/> <hr/>
......
.card { /* .The-End {
font-size:'30px'; display: flex;
text-align:"center"; }
}
.Box-text-center { .card {
display:flex; display:flex;
justify-content: center; justify-content: center;
margin-top:'100px'; width: auto;
margin-top: 5%;
/* text-align:"center";
}
.card-body {
width: 18em;
text-align: center;
border: solid 1px;
}
.card-body2 {
width: 18em;
text-align: center;
} }
.card-title2 {
width: 18em;
text-align: center;
border: solid 1px;
} */
import React from 'react' import React from 'react'
import tr from './End-Image01.jpg'; // import tr from './End-Image01.jpg';
import './End.css' import './End.css'
import 'bootstrap'
// import { Link } from 'react-router-dom'; // import { Link } from 'react-router-dom';
...@@ -9,42 +9,77 @@ function End() { ...@@ -9,42 +9,77 @@ function End() {
let a = [] let a = []
for (let i = 0; i < 3; i++) { for (let i = 0; i < 3; i++) {
if (localStorage.getItem(''+(i+1)) === localStorage.getItem('정답'+(i+1))) { if (localStorage.getItem('' + (i + 1)) === localStorage.getItem('정답' + (i + 1))) {
a[i] = 1
a[i] =1
localStorage.setItem('채점'+(i+1),'O') localStorage.setItem('채점' + (i + 1), 'O')
} }
else { else {
a[i] =0 a[i] = 0
localStorage.setItem('채점'+(i+1),'X') localStorage.setItem('채점' + (i + 1), 'X')
} }
} }
return ( return (
<> <>
<div className="card" >
<div className='card-header'> <div className="container">
-채점표- <h2>채점표</h2>
<table className="table table-bordered">
<thead>
<tr>
<th> </th>
<th>이름 여기</th>
</tr>
</thead>
<tbody>
<tr>
<td>문제1 여기</td>
<td>문제1 여기</td>
</tr>
<tr>
<td>문제2 여기</td>
<td>문제2 여기</td>
</tr>
<tr>
<td>문제3 여기</td>
<td>문제3 여기</td>
</tr>
<tr>
<td>총점</td>
<td>총점 결과??</td>
</tr>
</tbody>
</table>
</div>
{/* <div className="card" >
<div className='card-body'> <div className='card-body'>
<h3 className='card-title'>이름 : {localStorage.getItem('name')}</h3> <h1 className='card-title'>-채점표-</h1>
<h3 className='card-subtitle'>이름 : {localStorage.getItem('name')}</h3>
<p className='card-text'>Quiz 1 : {localStorage.getItem('채점1')}</p> <p className='card-text'>Quiz 1 : {localStorage.getItem('채점1')}</p>
<p className='card-text'>Quiz 2 : {localStorage.getItem('채점2')}</p> <p className='card-text'>Quiz 2 : {localStorage.getItem('채점2')}</p>
<p className='card-text'>Quiz 3 : {localStorage.getItem('채점3')}</p> <p className='card-text'>Quiz 3 : {localStorage.getItem('채점3')}</p>
<p className='card-text'>Total Score : {a[0] + a[1] + a[2]}</p> <p className='card-text'>Total Score : {a[0] + a[1] + a[2]}</p>
</div> </div>
<div className="Box-text-center"> <div className="card2">
<img src={tr} alt="수고" /> <div className='card-body2'>
<h3 className='card-title2'>결과</h3>
<p className='card-text2'>합격인지 아닌지 써주자</p>
</div>
</div> */}
{/* <div >
<img src={tr} alt="수고" class="card" className="Box-text-center" />
</div> </div> */}
</div>
</div>
</> </>
) )
......
...@@ -2,6 +2,7 @@ import React, { useState } from 'react' ...@@ -2,6 +2,7 @@ import React, { useState } from 'react'
import { Redirect } from 'react-router-dom'; import { Redirect } from 'react-router-dom';
import './Home.css' import './Home.css'
function Home() { function Home() {
const [name, setName] = useState('') const [name, setName] = useState('')
const [done, setDone] = useState(false) const [done, setDone] = useState(false)
...@@ -30,7 +31,7 @@ function Home() { ...@@ -30,7 +31,7 @@ function Home() {
<div className="Box"> <div className="Box">
<div className="Name"> <div className="Name">
이름을 입력하세요 이름을 입력하세요
<input className="input-style" onChange={handleChange} /> <input className="inputBox" onChange={handleChange} />
<div className='Box2'> <div className='Box2'>
<button className="QuizStart" onClick={checking}>Quiz Start !</button> <button className="QuizStart" onClick={checking}>Quiz Start !</button>
</div> </div>
......
...@@ -4,6 +4,7 @@ import './index.css'; ...@@ -4,6 +4,7 @@ import './index.css';
import App from './App'; import App from './App';
// import Quiz from './Quiz'; // import Quiz from './Quiz';
import * as serviceWorker from './serviceWorker'; import * as serviceWorker from './serviceWorker';
import 'bootstrap/dist/css/bootstrap.css';
ReactDOM.render( ReactDOM.render(
<React.StrictMode> <React.StrictMode>
......
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