Commit 85e2daf5 authored by baesangjune's avatar baesangjune
Browse files

end

parent 8f6e3d70
...@@ -3651,6 +3651,8 @@ ...@@ -3651,6 +3651,8 @@
}, },
"@testing-library/jest-dom": { "@testing-library/jest-dom": {
"version": "4.2.4", "version": "4.2.4",
"resolved": "https://registry.npmjs.org/@testing-library/jest-dom/-/jest-dom-4.2.4.tgz",
"integrity": "sha512-j31Bn0rQo12fhCWOUWy9fl7wtqkp7In/YP2p5ZFyRuiiB9Qs3g+hS4gAmDWONbAHcRmVooNJ5eOHQDCOmUFXHg==",
"requires": { "requires": {
"@babel/runtime": "^7.5.1", "@babel/runtime": "^7.5.1",
"chalk": "^2.4.1", "chalk": "^2.4.1",
...@@ -3675,6 +3677,8 @@ ...@@ -3675,6 +3677,8 @@
}, },
"@testing-library/react": { "@testing-library/react": {
"version": "9.5.0", "version": "9.5.0",
"resolved": "https://registry.npmjs.org/@testing-library/react/-/react-9.5.0.tgz",
"integrity": "sha512-di1b+D0p+rfeboHO5W7gTVeZDIK5+maEgstrZbWZSSvxDyfDRkkyBE1AJR5Psd6doNldluXlCWqXriUfqu/9Qg==",
"requires": { "requires": {
"@babel/runtime": "^7.8.4", "@babel/runtime": "^7.8.4",
"@testing-library/dom": "^6.15.0", "@testing-library/dom": "^6.15.0",
...@@ -3682,7 +3686,9 @@ ...@@ -3682,7 +3686,9 @@
} }
}, },
"@testing-library/user-event": { "@testing-library/user-event": {
"version": "7.2.1" "version": "7.2.1",
"resolved": "https://registry.npmjs.org/@testing-library/user-event/-/user-event-7.2.1.tgz",
"integrity": "sha512-oZ0Ib5I4Z2pUEcoo95cT1cr6slco9WY7yiPpG+RGNkj8YcYgJnM7pXmYmorNOReh8MIGcKSqXyeGjxnr8YiZbA=="
}, },
"@types/babel__core": { "@types/babel__core": {
"version": "7.1.9", "version": "7.1.9",
...@@ -5085,6 +5091,11 @@ ...@@ -5085,6 +5091,11 @@
"resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz", "resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz",
"integrity": "sha1-aN/1++YMUes3cl6p4+0xDcwed24=" "integrity": "sha1-aN/1++YMUes3cl6p4+0xDcwed24="
}, },
"bootstrap": {
"version": "4.5.1",
"resolved": "https://registry.npmjs.org/bootstrap/-/bootstrap-4.5.1.tgz",
"integrity": "sha512-bxUooHBSbvefnIZfjD0LE8nfdPKrtiFy2sgrxQwUZ0UpFzpjVbVMUxaGIoo9XWT4B2LG1HX6UQg0UMOakT0prQ=="
},
"brace-expansion": { "brace-expansion": {
"version": "1.1.11", "version": "1.1.11",
"resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz", "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-1.1.11.tgz",
...@@ -12298,6 +12309,8 @@ ...@@ -12298,6 +12309,8 @@
}, },
"react": { "react": {
"version": "16.13.1", "version": "16.13.1",
"resolved": "https://registry.npmjs.org/react/-/react-16.13.1.tgz",
"integrity": "sha512-YMZQQq32xHLX0bz5Mnibv1/LHb3Sqzngu7xstSM+vrkE5Kzr9xE0yMByK5kMoTK30YVJE61WfbxIFFvfeDKT1w==",
"requires": { "requires": {
"loose-envify": "^1.1.0", "loose-envify": "^1.1.0",
"object-assign": "^4.1.1", "object-assign": "^4.1.1",
...@@ -12509,6 +12522,8 @@ ...@@ -12509,6 +12522,8 @@
}, },
"react-dom": { "react-dom": {
"version": "16.13.1", "version": "16.13.1",
"resolved": "https://registry.npmjs.org/react-dom/-/react-dom-16.13.1.tgz",
"integrity": "sha512-81PIMmVLnCNLO/fFOQxdQkvEq/+Hfpv24XNJfpyZhTRfO0QcmQIF/PgCa1zCOj2w1hrn12MFLyaJ/G0+Mxtfag==",
"requires": { "requires": {
"loose-envify": "^1.1.0", "loose-envify": "^1.1.0",
"object-assign": "^4.1.1", "object-assign": "^4.1.1",
...@@ -12545,6 +12560,8 @@ ...@@ -12545,6 +12560,8 @@
}, },
"react-router-dom": { "react-router-dom": {
"version": "5.2.0", "version": "5.2.0",
"resolved": "https://registry.npmjs.org/react-router-dom/-/react-router-dom-5.2.0.tgz",
"integrity": "sha512-gxAmfylo2QUjcwxI63RhQ5G85Qqt4voZpUXSEqCwykV0baaOTQDR1f0PmY8AELqIyVc0NEZUj0Gov5lNGcXgsA==",
"requires": { "requires": {
"@babel/runtime": "^7.1.2", "@babel/runtime": "^7.1.2",
"history": "^4.9.0", "history": "^4.9.0",
...@@ -12567,6 +12584,8 @@ ...@@ -12567,6 +12584,8 @@
}, },
"react-scripts": { "react-scripts": {
"version": "3.4.1", "version": "3.4.1",
"resolved": "https://registry.npmjs.org/react-scripts/-/react-scripts-3.4.1.tgz",
"integrity": "sha512-JpTdi/0Sfd31mZA6Ukx+lq5j1JoKItX7qqEK4OiACjVQletM1P38g49d9/D0yTxp9FrSF+xpJFStkGgKEIRjlQ==",
"requires": { "requires": {
"@babel/core": "7.9.0", "@babel/core": "7.9.0",
"@svgr/webpack": "4.3.3", "@svgr/webpack": "4.3.3",
......
...@@ -9,7 +9,7 @@ function End() { ...@@ -9,7 +9,7 @@ function End() {
let score = 0 let score = 0
const answers = JSON.parse(localStorage.getItem('Answers')) const answers = JSON.parse(localStorage.getItem('Answers'))
const solutions = JSON.parse(localStorage.getItem('Solutions')) const solutions = JSON.parse(localStorage.getItem('Solutions'))
for (let i = 0; i < answers.length ; i++) { for (let i = 0; i < answers.length; i++) {
if (answers[i] === solutions[i]) { if (answers[i] === solutions[i]) {
...@@ -25,35 +25,34 @@ function End() { ...@@ -25,35 +25,34 @@ function End() {
return ( return (
<> <>
<div className="card" style={{ fontSize: '30px', textAlign: "center" }} > <div className="container">
<div className='card-header'> <h2>채점표</h2>
-채점표- <table className="table table-bordered" >
<div className='card-body'> <thead>
<h3 className='card-title'>이름 : {localStorage.getItem('name')}</h3> <tr>
<th>응시자</th>
<th>{localStorage.getItem('name')}</th>
</tr>
</thead>
<tbody>
{scores.map((score, index) => { {scores.map((score, index) => {
return (score===1) ? <p className='card-text'>Quiz {index+1} : 'O' </p> : <p className='card-text'>Quiz {index+1} : 'X' </p> return (score === 1) ? <tr><td>Quiz {index + 1}</td> <td> O </td></tr> : <tr><td>Quiz {index + 1}</td> <td> X</td></tr>
// if (score === 1) { })}
// return <p className='card-text'>Quiz {index+1} : 'O' </p> <tr>
// } <td>총점</td>
// else { return <p className='card-text'>Quiz {index+1} : 'X' </p> } <td>{score}</td>
</tr>
</tbody>
</table>
</div>
})}
<p className='card-text'>Total Score : {score}</p>
</div>
<div style={{ marginTop: '100px' }} className="Box text-center">
<img src={tr} alt="수고" />
</div>
</div>
</div>
</> </>
) )
} }
export default End; export default End;
...@@ -46,8 +46,28 @@ function Home() { ...@@ -46,8 +46,28 @@ function Home() {
KOREA UNIVERSITY KOREA UNIVERSITY
</div> </div>
<div className="d-flex justify-content-center ">
<table className="table table-bordered dark-table" style={{ width: "400px" }}>
<thead className="text-center">
<tr style={{ height: "0 px" }}>정보 입력</tr>
</thead>
<tbody className="text-center">
<tr>
<td>이름 입력<input className="ml-2 inputBox" onChange={handleChangename} /></td>
</tr>
<tr>
<td>비밀번호<input type='password' className="ml-2 inputBox" onChange={handleChangepassword} /></td>
</tr>
<tr>
<td><button className="mt-4 btn btn-dark" onClick={checking}>Login</button></td>
</tr>
</tbody>
</table>
</div>
{/* <div className="Box" style={{ border: 'solid', position: 'absolute', top: "300px", left: "68%"}} > */} {/* <div className="Box" style={{ border: 'solid', position: 'absolute', top: "300px", left: "68%"}} > */}
<div className="Name" style={{boxShadow: '5px 5px 5px 5px gray', border: 'solid', fontSize: '30px', position: "absolute", top: "300px", left: "68%" }}> {/* <div className="Name" style={{boxShadow: '5px 5px 5px 5px gray', border: 'solid', fontSize: '30px', position: "absolute", top: "300px", left: "68%" }}>
이름(Name) 이름(Name)
<input style={{ padding: '5px', border: 'solid', borderRight: 'none', borderBottom: 'none', borderTop: 'none', marginLeft: '105px', inlineSize: '160px', blockSize: '40px', fontSize: '40px' }} onChange={handleChangename} /> <input style={{ padding: '5px', border: 'solid', borderRight: 'none', borderBottom: 'none', borderTop: 'none', marginLeft: '105px', inlineSize: '160px', blockSize: '40px', fontSize: '40px' }} onChange={handleChangename} />
</div> </div>
...@@ -57,7 +77,7 @@ function Home() { ...@@ -57,7 +77,7 @@ function Home() {
</div> </div>
<div className='Box2'> <div className='Box2'>
<button style={{boxShadow: '5px 5px 5px 5px gray', marginLeft: '82%', marginTop: '10%', blockSize: '50px', inlineSize: '175px', fontSize: '35px' }} className="QuizStart" onClick={checking}>Start !</button> <button style={{boxShadow: '5px 5px 5px 5px gray', marginLeft: '82%', marginTop: '10%', blockSize: '50px', inlineSize: '175px', fontSize: '35px' }} className="QuizStart" onClick={checking}>Start !</button>
</div> </div> */}
{/* localStorage를 사용해야는지 localstorage를 사용해야하는지 */} {/* localStorage를 사용해야는지 localstorage를 사용해야하는지 */}
{/* </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