gab-social/app/javascript/gabsocial/layouts/default_layout.js

41 lines
765 B
JavaScript
Raw Normal View History

2020-04-11 23:29:19 +01:00
import Layout from './layout'
2020-02-04 15:50:18 +00:00
2020-02-17 17:50:29 +00:00
export default class DefaultLayout extends PureComponent {
2020-05-03 06:22:49 +01:00
2020-02-04 15:50:18 +00:00
static propTypes = {
2020-02-19 23:57:07 +00:00
actions: PropTypes.array,
2020-05-03 06:22:49 +01:00
children: PropTypes.node.isRequired,
2020-02-04 15:50:18 +00:00
layout: PropTypes.object,
2020-02-19 23:57:07 +00:00
showBackBtn: PropTypes.bool,
2020-05-07 06:55:24 +01:00
noComposeButton: PropTypes.bool,
2020-05-03 06:22:49 +01:00
tabs: PropTypes.array,
2020-04-11 23:29:19 +01:00
title: PropTypes.string.isRequired,
2020-02-05 22:45:48 +00:00
}
2020-02-04 15:50:18 +00:00
render() {
2020-04-11 23:29:19 +01:00
const {
2020-05-03 06:22:49 +01:00
actions,
2020-04-11 23:29:19 +01:00
children,
layout,
2020-05-03 06:22:49 +01:00
showBackBtn,
2020-04-11 23:29:19 +01:00
tabs,
2020-05-03 06:22:49 +01:00
title,
2020-05-07 06:55:24 +01:00
noComposeButton,
2020-05-03 06:22:49 +01:00
} = this.props
2020-03-25 03:08:43 +00:00
2020-02-04 15:50:18 +00:00
return (
2020-04-11 23:29:19 +01:00
<Layout
actions={actions}
layout={layout}
2020-05-03 06:22:49 +01:00
showBackBtn={showBackBtn}
tabs={tabs}
title={title}
2020-05-07 06:55:24 +01:00
noComposeButton={noComposeButton}
2020-04-11 23:29:19 +01:00
>
{children}
</Layout>
2020-02-04 15:50:18 +00:00
)
}
}