Commit 00f72026 authored by JeongYeonwoo's avatar JeongYeonwoo
Browse files

Merge remote-tracking branch 'origin/rkyoung7' into yeonwoo

parents 68cfeb07 f0cd17ba
[{"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\reportWebVitals.js":"1","C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\App.js":"2","C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Pages\\ProfilePage.js":"3","C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\index.js":"4","C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Hello.js":"5","C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Pages\\homePage.js":"6","C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Pages\\HomePage.js":"7"},{"size":362,"mtime":1608689321626,"results":"8","hashOfConfig":"9"},{"size":318,"mtime":1609262769832,"results":"10","hashOfConfig":"9"},{"size":6034,"mtime":1609308803556,"results":"11","hashOfConfig":"9"},{"size":1076,"mtime":1609261820667,"results":"12","hashOfConfig":"9"},{"size":1238,"mtime":1609263419304,"results":"13","hashOfConfig":"9"},{"size":356,"mtime":1609260857173,"results":"14","hashOfConfig":"9"},{"size":1590,"mtime":1609263415754,"results":"15","hashOfConfig":"9"},{"filePath":"16","messages":"17","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"zqy9n4",{"filePath":"18","messages":"19","errorCount":0,"warningCount":7,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},{"filePath":"20","messages":"21","errorCount":0,"warningCount":5,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},{"filePath":"22","messages":"23","errorCount":0,"warningCount":1,"fixableErrorCount":0,"fixableWarningCount":0,"source":"24"},{"filePath":"25","messages":"26","errorCount":0,"warningCount":2,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},{"filePath":"27","messages":"28","errorCount":1,"warningCount":1,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},{"filePath":"29","messages":"30","errorCount":0,"warningCount":2,"fixableErrorCount":0,"fixableWarningCount":0,"source":"31"},"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\reportWebVitals.js",[],"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\App.js",["32","33","34","35","36","37","38"],"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Pages\\ProfilePage.js",["39","40","41","42","43"],"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\index.js",["44"],"import React from 'react';\nimport ReactDOM from 'react-dom';\nimport 'bootstrap/dist/css/bootstrap.min.css';\nimport './index.css';\nimport { BrowserRouter as Router, Route, Redirect, Switch, BrowserRouter } from 'react-router-dom';\nimport App from './App';\nimport reportWebVitals from './reportWebVitals';\nimport ProfilePage from './Pages/ProfilePage';\nimport Hello from './Hello'\nimport HomePage from './Pages/HomePage'\n\nReactDOM.render(\n <Router>\n <Switch>\n <Route exact path=\"/\" component={App} />\n <Route path=\"/hello\" component={Hello} />\n <Route path=\"/homepage\" component={HomePage} />\n <Route path=\"/profilepage\" component={ProfilePage} />\n <Redirect path='/hello' to='/hello'/>\n </Switch>\n </Router>,\n\n // <React.StrictMode>\n // <App />\n // </React.StrictMode>,\n document.getElementById('root')\n);\n\n// If you want to start measuring performance in your app, pass a function\n// to log results (for example: reportWebVitals(console.log))\n// or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals\nreportWebVitals();\n","C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Hello.js",["45","46"],"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Pages\\homePage.js",["47","48"],"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Pages\\HomePage.js",["49","50"],"import { Button, Navbar, Nav, Form, FormControl } from 'react-bootstrap';\r\nimport React, { useState } from 'react'\r\nimport { Redirect } from 'react-router-dom'\r\n\r\nconst userName = \"정연우\";\r\n\r\n\r\nfunction HomePage() {\r\n const [toprofile, setToprofile] = useState(false)\r\n\r\n function goProfile() {\r\n return (setToprofile(true))\r\n }\r\n\r\n return (\r\n <>\r\n <Navbar bg=\"dark\" variant=\"dark\">\r\n <Navbar.Brand href=\"/homepage\">YDK Messenger</Navbar.Brand>\r\n <div className='ml-1 mr-2' style={{ color: 'white' }}>{userName} 님 환영합니다</div>\r\n <Nav className=\"mr-auto\">\r\n <Nav.Link href=\"/homepage\">Home</Nav.Link>\r\n <Nav.Link href=\"/profilepage\">Profile</Nav.Link>\r\n <Nav.Link href=\"/hello\">Hello</Nav.Link>\r\n </Nav>\r\n {/* <Form inline>\r\n <FormControl type=\"text\" placeholder=\"Search\" className=\"mr-sm-2\" />\r\n <Button variant=\"outline-info\">Search</Button>\r\n </Form> */}\r\n <Button variant=\"light\" className=\"ml-3\">Logout</Button>\r\n </Navbar>\r\n\r\n\r\n {toprofile ? <Redirect to='/profilepage' /> : ''}\r\n <h1>This is HomePage</h1>\r\n <h3>\r\n 안녕하세요. 홈페이지 입니다. 환영합니다\r\n </h3>\r\n <Button variant=\"outline-success\" size=\"sm\" className=\"ml-4\" onClick={goProfile}>프로필 보기</Button>\r\n\r\n\r\n\r\n\r\n </>\r\n )\r\n\r\n}\r\n\r\nexport default HomePage;\r\n",{"ruleId":"51","severity":1,"message":"52","line":1,"column":27,"nodeType":"53","messageId":"54","endLine":1,"endColumn":33},{"ruleId":"51","severity":1,"message":"55","line":1,"column":35,"nodeType":"53","messageId":"54","endLine":1,"endColumn":40},{"ruleId":"51","severity":1,"message":"56","line":1,"column":42,"nodeType":"53","messageId":"54","endLine":1,"endColumn":50},{"ruleId":"51","severity":1,"message":"57","line":1,"column":52,"nodeType":"53","messageId":"54","endLine":1,"endColumn":58},{"ruleId":"51","severity":1,"message":"58","line":1,"column":60,"nodeType":"53","messageId":"54","endLine":1,"endColumn":73},{"ruleId":"51","severity":1,"message":"59","line":2,"column":8,"nodeType":"53","messageId":"54","endLine":2,"endColumn":13},{"ruleId":"51","severity":1,"message":"60","line":4,"column":8,"nodeType":"53","messageId":"54","endLine":4,"endColumn":19},{"ruleId":"51","severity":1,"message":"61","line":4,"column":42,"nodeType":"53","messageId":"54","endLine":4,"endColumn":53},{"ruleId":"51","severity":1,"message":"52","line":5,"column":27,"nodeType":"53","messageId":"54","endLine":5,"endColumn":33},{"ruleId":"51","severity":1,"message":"55","line":5,"column":35,"nodeType":"53","messageId":"54","endLine":5,"endColumn":40},{"ruleId":"51","severity":1,"message":"57","line":5,"column":52,"nodeType":"53","messageId":"54","endLine":5,"endColumn":58},{"ruleId":"51","severity":1,"message":"62","line":5,"column":60,"nodeType":"53","messageId":"54","endLine":5,"endColumn":64},{"ruleId":"51","severity":1,"message":"58","line":5,"column":60,"nodeType":"53","messageId":"54","endLine":5,"endColumn":73},{"ruleId":"51","severity":1,"message":"63","line":1,"column":31,"nodeType":"53","messageId":"54","endLine":1,"endColumn":35},{"ruleId":"51","severity":1,"message":"61","line":1,"column":37,"nodeType":"53","messageId":"54","endLine":1,"endColumn":48},{"ruleId":"51","severity":1,"message":"59","line":5,"column":10,"nodeType":"53","messageId":"54","endLine":5,"endColumn":15},{"ruleId":"64","severity":2,"message":"65","line":20,"column":16,"nodeType":"53","messageId":"66","endLine":20,"endColumn":24},{"ruleId":"51","severity":1,"message":"63","line":1,"column":31,"nodeType":"53","messageId":"54","endLine":1,"endColumn":35},{"ruleId":"51","severity":1,"message":"61","line":1,"column":37,"nodeType":"53","messageId":"54","endLine":1,"endColumn":48},"no-unused-vars","'Router' is defined but never used.","Identifier","unusedVar","'Route' is defined but never used.","'Redirect' is defined but never used.","'Switch' is defined but never used.","'BrowserRouter' is defined but never used.","'Hello' is defined but never used.","'ProfilePage' is defined but never used.","'FormControl' is defined but never used.","'Link' is defined but never used.","'Form' is defined but never used.","no-undef","'HomePage' is not defined.","undef"] [{"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\reportWebVitals.js":"1","C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\App.js":"2","C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Pages\\ProfilePage.js":"3","C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\index.js":"4","C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Hello.js":"5","C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Pages\\homePage.js":"6","C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Pages\\HomePage.js":"7","C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Components\\ClosedList.js":"8","C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Components\\Chat.js":"9"},{"size":362,"mtime":1608689321626,"results":"10","hashOfConfig":"11"},{"size":333,"mtime":1609314947450,"results":"12","hashOfConfig":"11"},{"size":6034,"mtime":1609308803556,"results":"13","hashOfConfig":"11"},{"size":1108,"mtime":1609314925607,"results":"14","hashOfConfig":"11"},{"size":1238,"mtime":1609263419304,"results":"15","hashOfConfig":"11"},{"size":356,"mtime":1609260857173,"results":"16","hashOfConfig":"11"},{"size":2703,"mtime":1609315047129,"results":"17","hashOfConfig":"11"},{"size":549,"mtime":1609314121085,"results":"18","hashOfConfig":"11"},{"size":564,"mtime":1609314121084,"results":"19","hashOfConfig":"11"},{"filePath":"20","messages":"21","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"zqy9n4",{"filePath":"22","messages":"23","errorCount":0,"warningCount":7,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},{"filePath":"24","messages":"25","errorCount":0,"warningCount":5,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},{"filePath":"26","messages":"27","errorCount":0,"warningCount":1,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},{"filePath":"28","messages":"29","errorCount":0,"warningCount":2,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},{"filePath":"30","messages":"31","errorCount":1,"warningCount":1,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},{"filePath":"32","messages":"33","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},{"filePath":"34","messages":"35","errorCount":0,"warningCount":1,"fixableErrorCount":0,"fixableWarningCount":0,"source":null},{"filePath":"36","messages":"37","errorCount":0,"warningCount":0,"fixableErrorCount":0,"fixableWarningCount":0},"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\reportWebVitals.js",[],"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\App.js",["38","39","40","41","42","43","44"],"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Pages\\ProfilePage.js",["45","46","47","48","49"],"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\index.js",["50"],"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Hello.js",["51","52"],"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Pages\\homePage.js",["53","54"],"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Pages\\HomePage.js",[],"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Components\\ClosedList.js",["55"],"C:\\Users\\82109\\Desktop\\JS\\messenger\\client\\src\\Components\\Chat.js",[],{"ruleId":"56","severity":1,"message":"57","line":1,"column":27,"nodeType":"58","messageId":"59","endLine":1,"endColumn":33},{"ruleId":"56","severity":1,"message":"60","line":1,"column":35,"nodeType":"58","messageId":"59","endLine":1,"endColumn":40},{"ruleId":"56","severity":1,"message":"61","line":1,"column":42,"nodeType":"58","messageId":"59","endLine":1,"endColumn":50},{"ruleId":"56","severity":1,"message":"62","line":1,"column":52,"nodeType":"58","messageId":"59","endLine":1,"endColumn":58},{"ruleId":"56","severity":1,"message":"63","line":1,"column":60,"nodeType":"58","messageId":"59","endLine":1,"endColumn":73},{"ruleId":"56","severity":1,"message":"64","line":2,"column":8,"nodeType":"58","messageId":"59","endLine":2,"endColumn":13},{"ruleId":"56","severity":1,"message":"65","line":4,"column":8,"nodeType":"58","messageId":"59","endLine":4,"endColumn":19},{"ruleId":"56","severity":1,"message":"66","line":4,"column":42,"nodeType":"58","messageId":"59","endLine":4,"endColumn":53},{"ruleId":"56","severity":1,"message":"57","line":5,"column":27,"nodeType":"58","messageId":"59","endLine":5,"endColumn":33},{"ruleId":"56","severity":1,"message":"60","line":5,"column":35,"nodeType":"58","messageId":"59","endLine":5,"endColumn":40},{"ruleId":"56","severity":1,"message":"62","line":5,"column":52,"nodeType":"58","messageId":"59","endLine":5,"endColumn":58},{"ruleId":"56","severity":1,"message":"67","line":5,"column":60,"nodeType":"58","messageId":"59","endLine":5,"endColumn":64},{"ruleId":"56","severity":1,"message":"63","line":5,"column":60,"nodeType":"58","messageId":"59","endLine":5,"endColumn":73},{"ruleId":"56","severity":1,"message":"68","line":1,"column":31,"nodeType":"58","messageId":"59","endLine":1,"endColumn":35},{"ruleId":"56","severity":1,"message":"66","line":1,"column":37,"nodeType":"58","messageId":"59","endLine":1,"endColumn":48},{"ruleId":"56","severity":1,"message":"64","line":5,"column":10,"nodeType":"58","messageId":"59","endLine":5,"endColumn":15},{"ruleId":"69","severity":2,"message":"70","line":20,"column":16,"nodeType":"58","messageId":"71","endLine":20,"endColumn":24},{"ruleId":"56","severity":1,"message":"72","line":5,"column":16,"nodeType":"58","messageId":"59","endLine":5,"endColumn":23},"no-unused-vars","'Router' is defined but never used.","Identifier","unusedVar","'Route' is defined but never used.","'Redirect' is defined but never used.","'Switch' is defined but never used.","'BrowserRouter' is defined but never used.","'Hello' is defined but never used.","'ProfilePage' is defined but never used.","'FormControl' is defined but never used.","'Link' is defined but never used.","'Form' is defined but never used.","no-undef","'HomePage' is not defined.","undef","'setList' is assigned a value but never used."]
\ No newline at end of file \ No newline at end of file
import React from 'react';
import { Form, Button } from 'react-bootstrap';
function Chat(props) {
return (
<div className="chat" id="chat" style={{ border: "2px solid", height: "300%", margin: "1%", borderColor: "#BDBDBD" }}>
<Button variant="light" onClick={props.handleChatc} >{`<`}</Button>
<Form>
<Form.Group>
<Form.Control type="text" />
</Form.Group>
<Button variant="primary" type="submit">
전송
</Button>
</Form>
</div>
);
}
export default Chat;
\ No newline at end of file
import React, { useState } from 'react'
import { ListGroup } from 'react-bootstrap';
function ClosedList() {
const [list, setList] = useState([
{ room: '테스트 방1', memnum: 5, admin: '가영' },
{ room: '테스트 방2', memnum: 4, admin: '수현' }]
);
return (
<div>
{list.map((list, index) =>
<ListGroup key={index}>
<ListGroup.Item action>
<h2>{list.room}</h2>
</ListGroup.Item>
</ListGroup>
)}
</div>
)
}
export default ClosedList
import React, { useState } from 'react'
import { ListGroup } from 'react-bootstrap';
function OpenList() {
const [list, setList] = useState([
{ room: '테스트 방3', memnum: 7, admin: '가영2' },
{ room: '테스트 방4', memnum: 2, admin: '수현2' }]
);
return (
<div>
{list.map((list, index) =>
<ListGroup key={index}>
<ListGroup.Item action>
<h2>{list.room}</h2>
</ListGroup.Item>
</ListGroup>
)}
</div>
)
}
export default OpenList
\ No newline at end of file
import { Button, Navbar, Nav, Form, FormControl } from 'react-bootstrap'; import React, { useState } from 'react';
import React, { useState } from 'react' import { Row, Col, Modal, Button, Navbar, Nav } from 'react-bootstrap';
import { Redirect } from 'react-router-dom' import Tabs from 'react-bootstrap/Tabs';
import Tab from 'react-bootstrap/Tab';
import ClosedList from '../Components/ClosedList';
import OpenList from '../Components/OpenList';
import Chat from '../Components/Chat';
// import styled from 'styled-components';
// const List = styled.div`
// background: #FFFAFA;
// `
const userName = "정연우"; const userName = "정연우";
function HomePage() { function Home() {
const [toprofile, setToprofile] = useState(false) const [show, setShow] = useState(false);
const [chat, setChat] = useState(false);
function goProfile() { const handleClose = () => setShow(false);
return (setToprofile(true)) const handleShow = () => setShow(true);
} const handleChato = () => setChat(true);
const handleChatc = () => setChat(false);
// variant="pills"
return ( return (
<> <>
...@@ -28,21 +39,39 @@ function HomePage() { ...@@ -28,21 +39,39 @@ function HomePage() {
</Form> */} </Form> */}
<Button variant="light" className="ml-3">Logout</Button> <Button variant="light" className="ml-3">Logout</Button>
</Navbar> </Navbar>
<Row className="mr-0">
<Col className="list" md={5}>
<Tabs defaultActiveKey="closed" id="uncontrolled-tab-example">
<Tab eventKey="closed" title="내 채팅" onClick={handleChato} >
<ClosedList />
</Tab>
<Tab eventKey="open" title="공개방" >
<OpenList />
</Tab>
</Tabs>
</Col>
<Col style={{ padding: "0" }}>
{chat ? <Chat handleChatc={handleChatc} /> : null}
<Button variant="primary" onClick={handleShow} style={{ position: "fixed", bottom: "10px", right: "10px" }} >
생성
</Button>
{toprofile ? <Redirect to='/profilepage' /> : ''} <Modal show={show} onHide={handleClose}>
<h1>This is HomePage</h1> <Modal.Header closeButton>
<h3> <Modal.Title> 생성</Modal.Title>
안녕하세요. 홈페이지 입니다. 환영합니다 </Modal.Header>
</h3> <Modal.Body>여기에 form 입력</Modal.Body>
<Button variant="outline-success" size="sm" className="ml-4" onClick={goProfile}>프로필 보기</Button> <Modal.Footer>
<Button variant="primary" onClick={handleClose}>
생성
</Button>
</Modal.Footer>
</Modal>
</Col>
</Row>
</> </>
) );
} }
export default HomePage; export default Home;
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