From e48676da95233806d49860a72284aea0c4900e13 Mon Sep 17 00:00:00 2001 From: uwap Date: Sun, 17 Sep 2017 06:31:37 +0200 Subject: [PATCH] Icons --- index.html | 7 +++++++ src/config.js | 12 ++++++------ src/map.js | 10 +++++++++- 3 files changed, 22 insertions(+), 7 deletions(-) diff --git a/index.html b/index.html index 6ffdae6..9e10ae5 100644 --- a/index.html +++ b/index.html @@ -1,6 +1,7 @@ + diff --git a/src/config.js b/src/config.js index 1d077f5..16b4a34 100644 --- a/src/config.js +++ b/src/config.js @@ -45,7 +45,7 @@ const config : Config = { led_stahltrager: { name: "LED Stahlträger", position: [360, 80], - icon: "", + icon: "wb_incandescent", ui: [ { type: "toggle", @@ -57,7 +57,7 @@ const config : Config = { snackbar: { name: "Snackbar", position: [550, 200], - icon: "", + icon: "kitchen", ui: [ { type: "toggle", @@ -69,7 +69,7 @@ const config : Config = { twinkle: { name: "Twinkle", position: [500, 280], - icon: "", + icon: "wb_incandescent", ui: [ { type: "toggle", @@ -81,7 +81,7 @@ const config : Config = { flyfry: { name: "Fliegenbratgerät", position: [450, 320], - icon: "", + icon: "whatshot", ui: [ { type: "toggle", @@ -93,7 +93,7 @@ const config : Config = { artnet: { name: "Artnet", position: [550,150], - icon: "", + icon: "wb_incandescent", ui: [ { type: "toggle", @@ -120,7 +120,7 @@ const config : Config = { onkyo: { name: "Onkyo", position: [350, 350], - icon: "", + icon: "volume_up", ui: [ { type: "slider", diff --git a/src/map.js b/src/map.js index 59197c5..34dad50 100644 --- a/src/map.js +++ b/src/map.js @@ -5,11 +5,19 @@ import Leaflet from "leaflet"; import R from "ramda"; import Config from "./config"; +import ActionInfo from 'material-ui/svg-icons/action/info'; +import ReactDOM from "react-dom"; + // convert width/height coordinates to -height/width coordinates const c = (p) => [-p[1], p[0]] const Markers = (props) => R.values(R.mapObjIndexed((el,key) => ( - + " + el.icon + "", + iconSize: Leaflet.point(32,32) + })}> props.store.dispatch({type: "uiopen", ui: key})} onClose={() => props.store.dispatch({type: "uiclose"})}> {el.name}