allow changing background image

This commit is contained in:
xmcp
2018-08-21 13:14:33 +08:00
parent 3497c664d5
commit 1ac4458223
4 changed files with 18 additions and 4 deletions

View File

@@ -31,7 +31,9 @@ class App extends Component {
render() {
return (
<div>
<div className="bg-img" />
<div className="bg-img" style={{
backgroundImage: 'url('+(localStorage['REPLACE_ERIRI_WITH_URL'] || '/eriri_bg.jpg')+')'
}} />
<Title callback={this.show_sidebar.bind(this)} set_search_text={this.set_search_text.bind(this)} />
<div className="left-container">
<Flow key={this.state.flow_render_key}

View File

@@ -31,6 +31,7 @@
.title-line::before,
.title-line::after {
background-color: #fff;
box-shadow: 0 1px 1px #000;
}
.bg-img {
@@ -40,6 +41,16 @@
left: 0;
width: 100%;
height: 100%;
background: #124 url(/eriri_bg.jpg) fixed center center;
background: #124 fixed center center;
background-size: cover;
}
.black-outline {
text-shadow:
-1px -1px 0 #000,
0 -1px 0 #000,
1px -1px 0 #000,
-1px 1px 0 #000,
0 1px 0 #000,
1px 1px 0 #000;
}

View File

@@ -36,7 +36,7 @@ export function Time(props) {
export function TitleLine(props) {
return (
<p className="centered-line title-line aux-margin">
<span>{props.text}</span>
<span className="black-outline">{props.text}</span>
</p>
)
}

View File

@@ -7,7 +7,8 @@ const HELP_TEXT=(
<ul>
<li>为保证使用体验请使用 Chrome 浏览器 stable 分支最新版</li>
<li>在列表中点击帖子可以显示全部回复</li>
<li>搜索框输入 #472865 等可以查看指定 ID 的树洞</li>
<li>搜索框输入 #472865 等可以查看指定 ID 的树洞</li>
<li>自定义背景图片请修改 localStorage['REPLACE_ERIRI_WITH_URL']</li>
</ul>
<p>使用本网站时您需要了解并同意</p>
<ul>