1
0
mirror of https://github.com/mgerb/mywebsite synced 2026-01-10 09:52:51 +00:00

fixed css

This commit is contained in:
2016-09-18 18:15:30 +00:00
parent 87d941804a
commit b5c7546579
4 changed files with 16 additions and 3 deletions

View File

@@ -1,4 +1,6 @@
import React from 'react';
import {Link} from 'react-router';
import Loading from '../utils/Loading';
import _chartjs from 'chart.js';
import Chart from 'react-chartjs';
@@ -97,6 +99,9 @@ export default class SensorInfo extends React.Component {
{sensor.fetchedUniqueDates && sensor.fetchedInfo
? <LineChart data={data} options={ChartOptions} redraw/>
: null}
{sensor.fetchedUniqueDates && sensor.fetchedInfo
? <div class="home"><Link to="/" class="link"><i class="fa fa-caret-left" aria-hidden="true"></i> Home</Link></div>
: null}
</div>
);
}

View File

@@ -14,4 +14,7 @@
margin-left: 5px;
}
}
.home{
margin-top: 1em;
}
}

View File

@@ -30,10 +30,10 @@ export default class SensorList extends React.Component {
return (
<div key={index} class="row" onClick={() => {this.openLink(sensor.location)}}>
<div class="item">
<div class="temperature">
<h1>{sensor.temperature}°f</h1>
</div>
<div class="item">
<div class="info">
<h3>{sensor.location}</h3>
<span class="date">Updated: {date.toLocaleString('en-us', options)}
{Date.now() - date < 420000

View File

@@ -12,8 +12,13 @@
background-color: #D1D1D1;
}
.item + .item{
.temperature{
flex: .5;
}
.info{
margin-left: 1em;
flex: 1;
}
h2{