Bookmark.js 2.54 KB
Newer Older
Lee SeoYeon's avatar
.    
Lee SeoYeon committed
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
import React, { useState, useEffect } from 'react'
import { Alert, Col, Card, Container, Form, Row, Button, Nav, Navbar, ListGroup, Image, Table } from "react-bootstrap"
import axios from "axios"
import { Redirect } from 'react-router-dom'
// import ohuhsm  from "./ohuh-sm.PNG";

// function addFavorite() {
//     const title = document.title
//     const url = location.href
//     if (window.sidebar && window.sidebar.addPanel) {
//         window.sidebar.addPanel(title, url, "")
//     } else if (window.opera && window.print) {
//         const elem = document.createElement('a');
//         elem.setAttribute('href', url);
//         elem.setAttribute('title', title);
//         elem.setAttribute('rel', 'sidebar');
//         elem.click();
//     } else if (document.all) { //msie
//         window.external.AddFavorite(url, title);
//     } else {
//         alert("해당브라우저는 즐겨찾기 추가기능이 지원되지 않습니다.\n\n수동으로 즐겨찾기에 추가해주세요.");
//         return true;
//     }
//     return (
//         <Container>
//             <Col>

//             </Col>
//         </Container>
//     )

// }


function Bookmark() {
    const [index, setIndex] = useState(1);
    const [showSet, setShowSet] = useState([false, false, false, false]);
    const url = [{
        urlname: "북마크이름",
        urlpage: "안녕하세요",
    }]

    return (
        <Container>
            <Navbar bg="primary" variant="dark">
                <Navbar.Brand href="/">북마크</Navbar.Brand>
                <Nav className="mr-auto">
                    <Nav.Link href="/">Home</Nav.Link>
                </Nav>
                {/* <Form inline>
                <FormControl type="text" placeholder="Search" className="mr-sm-2" />
                <Button variant="outline-light">Search</Button>
            </Form> */}
            </Navbar>
                <Form>
                    <ListGroup>
                        <Row>{url.urlname}</Row>
                        <ListGroup.Item action href="/">북마크1</ListGroup.Item>
                        <ListGroup.Item>북마크2</ListGroup.Item>
                        <ListGroup.Item>북마크3</ListGroup.Item>
                        <ListGroup.Item>북마크4</ListGroup.Item>
                        <ListGroup.Item>북마크5</ListGroup.Item>
                        <ListGroup.Item>북마크6</ListGroup.Item>
                        <ListGroup.Item>북마크7</ListGroup.Item>
                    </ListGroup>
                </Form>
        </Container>
    )
}

export default Bookmark