diff --git a/config/rzl.js b/config/rzl.js index 6911718..3f2706a 100644 --- a/config/rzl.js +++ b/config/rzl.js @@ -2,6 +2,10 @@ import * as utils from './utils'; const config : Config = { + space: { + name: "RZL", + color: "orange" + }, topics: { led_stahltraeger: { state: "/service/openhab/out/pca301_ledstrips/state", diff --git a/src/index.jsx b/src/index.jsx index ed874dd..1dd5ab2 100644 --- a/src/index.jsx +++ b/src/index.jsx @@ -15,7 +15,7 @@ import SpaceMap from "./map.js"; import R from "ramda"; import Config from "./config"; import Toolbar from "material-ui/Toolbar"; -import orange from 'material-ui/colors/orange'; +import * as colors from 'material-ui/colors'; import Typography from 'material-ui/Typography'; import List, { ListSubheader } from 'material-ui/List'; import IconButton from 'material-ui/IconButton'; @@ -24,6 +24,8 @@ import AppBar from 'material-ui/AppBar'; injectTapEventPlugin(); +document.title = `${Config.space.name} Map`; + const UiItem = (state) => (props : ControlUI) => UiItems[props.type](state, props); @@ -33,7 +35,7 @@ const renderUi = (state: State, key: ?string) => const theme = createMuiTheme({ palette: { - primary: orange + primary: colors[Config.space.color] } }); @@ -52,7 +54,7 @@ class app extends React.Component<{state: State, classes: Object}> {