diff options
author | Renard | 2019-09-16 12:08:48 -0300 |
---|---|---|
committer | Renard | 2019-09-16 12:08:48 -0300 |
commit | e7745c7fa1d368bfaa3c3952d0ffbc27428f23e9 (patch) | |
tree | 73758751fef6323c634b08efe4726be96ab78f9b /src/Board.js | |
parent | 928e7fc069b59a6259a942dcef1e3fea3ccfb27d (diff) | |
download | bai-client-e7745c7fa1d368bfaa3c3952d0ffbc27428f23e9.tar.gz bai-client-e7745c7fa1d368bfaa3c3952d0ffbc27428f23e9.tar.xz bai-client-e7745c7fa1d368bfaa3c3952d0ffbc27428f23e9.zip |
Breadcrumb!
Diffstat (limited to 'src/Board.js')
-rw-r--r-- | src/Board.js | 18 |
1 files changed, 15 insertions, 3 deletions
diff --git a/src/Board.js b/src/Board.js index 34c7967..e5997bc 100644 --- a/src/Board.js +++ b/src/Board.js @@ -6,7 +6,8 @@ import { Header, Image, Comment, - Divider + Divider, + Breadcrumb } from "semantic-ui-react"; import { Link } from "@reach/router"; import Moment from "react-moment"; @@ -76,8 +77,19 @@ class Board extends Component { ); } + const currentBoard = this.props.boardList.find(board => { + return board.dir === this.props.dir; + }); + return ( - <div> + <React.Fragment> + <Breadcrumb> + <Breadcrumb.Section link as={Link} to="/"> + Home + </Breadcrumb.Section> + <Breadcrumb.Divider icon="right chevron" /> + <Breadcrumb.Section link>{currentBoard.name}</Breadcrumb.Section> + </Breadcrumb> {threadList.map(thread => ( <Segment.Group key={thread.id}> <Header as="h4" attached> @@ -109,7 +121,7 @@ class Board extends Component { </Segment> </Segment.Group> ))} - </div> + </React.Fragment> ); } } |