The drawer will now stay open if clicked anywhere else

Also gave the onkyo a green color if powered
This commit is contained in:
uwap 2017-10-31 21:51:29 +01:00
parent 9e33bfe130
commit bd3ad885e6
2 changed files with 3 additions and 6 deletions

View file

@ -245,6 +245,7 @@ const config : Config = {
onkyo: { onkyo: {
name: "Onkyo", name: "Onkyo",
position: [350, 650], position: [350, 650],
iconColor: state => state.onkyo_power == "on" ? "#00FF00" : "#000000",
icon: "volume_up", icon: "volume_up",
ui: [ ui: [
{ {

View file

@ -32,12 +32,8 @@ const Markers = (props) => R.values(R.mapObjIndexed((el,key) => (
{ {
html: iconHtml(el, props.state), html: iconHtml(el, props.state),
iconSize: Leaflet.point(32,32) iconSize: Leaflet.point(32,32)
})}> })}
<Popup onClick={() => store.dispatch({type: Actions.CHANGE_UI, payload: key})}>
onOpen={() => store.dispatch({type: Actions.CHANGE_UI, payload: key})}
onClose={() => store.dispatch({type: Actions.CHANGE_UI})}>
<span>{el.name}</span>
</Popup>
</Marker> </Marker>
), R.propOr({}, "controls", Config))); ), R.propOr({}, "controls", Config)));