fix(config): color of search indicator

This commit is contained in:
Alexey Kasyanchuk
2018-02-17 20:42:29 +03:00
parent e5b9e4793a
commit fd4f3b09e5
3 changed files with 214 additions and 50 deletions

View File

@ -50,10 +50,19 @@ export default class AdminPage extends Page {
style={{marginTop: '10px'}}
label="Enabled network scanning"
toggled={this.options.indexer}
thumbSwitchedStyle={{backgroundColor: 'red'}}
trackSwitchedStyle={{backgroundColor: '#ff9d9d'}}
onToggle={(e, checked) => {
this.options.indexer = checked
this.options.indexer = checked
if(!this.options.indexer)
this.options.p2p = false
this.forceUpdate()
}}
/>
<Toggle
style={{marginTop: '10px'}}
label="Enabled p2p search"
toggled={this.options.p2p}
onToggle={(e, checked) => {
this.options.p2p = this.options.indexer && checked
this.forceUpdate()
}}
/>