2019-09-02 14:32:57 +02:00
|
|
|
import * as React from 'react';
|
|
|
|
|
|
|
|
|
|
import NewPost from './NewPost';
|
|
|
|
|
import PostList from './PostList';
|
|
|
|
|
|
|
|
|
|
import IBoard from '../../interfaces/IBoard';
|
|
|
|
|
|
|
|
|
|
import '../../stylesheets/components/Board/Board.scss';
|
|
|
|
|
|
|
|
|
|
interface Props {
|
|
|
|
|
board: IBoard;
|
|
|
|
|
isLoggedIn: boolean;
|
|
|
|
|
authenticityToken: string;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
class Board extends React.Component<Props> {
|
|
|
|
|
render() {
|
|
|
|
|
const { board, isLoggedIn, authenticityToken } = this.props;
|
|
|
|
|
|
|
|
|
|
return (
|
|
|
|
|
<div className="boardContainer">
|
2019-09-02 19:26:34 +02:00
|
|
|
<div className="sidebar">
|
|
|
|
|
<NewPost board={board} isLoggedIn={isLoggedIn} authenticityToken={authenticityToken} />
|
|
|
|
|
</div>
|
|
|
|
|
<PostList board={board} />
|
2019-09-02 14:32:57 +02:00
|
|
|
</div>
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export default Board;
|