2020-06-19 00:16:18 +02:00
|
|
|
import React from "react";
|
2020-07-08 00:14:08 +02:00
|
|
|
import style from "./PageTitle.module.css"
|
2020-07-24 22:47:21 +02:00
|
|
|
import darktheme from "./PageTitleDarkTheme.module.css"
|
|
|
|
import lighttheme from "./PageTitleLightTheme.module.css"
|
|
|
|
import StaticInfos from "../../GlobalInfos";
|
2020-06-19 00:16:18 +02:00
|
|
|
|
|
|
|
class PageTitle extends React.Component {
|
|
|
|
constructor(props) {
|
|
|
|
super(props);
|
|
|
|
|
|
|
|
this.props = props;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
render() {
|
2020-07-24 22:47:21 +02:00
|
|
|
const themeStyle = StaticInfos.isDarkTheme() ? darktheme : lighttheme;
|
2020-06-19 00:16:18 +02:00
|
|
|
return (
|
2020-07-24 22:47:21 +02:00
|
|
|
<div className={style.pageheader + ' ' + themeStyle.pageheader}>
|
|
|
|
<span className={style.pageheadertitle + ' ' + themeStyle.pageheadertitle}>{this.props.title}</span>
|
2020-07-08 00:14:08 +02:00
|
|
|
<span className={style.pageheadersubtitle}>{this.props.subtitle}</span>
|
2020-06-19 18:21:42 +02:00
|
|
|
<>
|
|
|
|
{this.props.children}
|
|
|
|
</>
|
2020-06-19 00:16:18 +02:00
|
|
|
<hr/>
|
|
|
|
</div>
|
2020-07-24 22:47:21 +02:00
|
|
|
)
|
|
|
|
;
|
2020-06-19 00:16:18 +02:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2020-07-24 22:47:21 +02:00
|
|
|
export default PageTitle;
|