Browse Source

Stuff

master
Niko Hakala 5 years ago
parent
commit
7a9db72981
22 changed files with 72 additions and 15 deletions
  1. BIN
      public/Photos/valkosipulivk3.jpg
  2. +0
    -1
      public/index.html
  3. BIN
      public/logo192.png
  4. BIN
      public/logo512.png
  5. +9
    -9
      src/App.css
  6. +3
    -0
      src/Components/ModalGrid.js
  7. +1
    -1
      src/Components/ModalList.js
  8. +1
    -0
      src/Components/Modalbox1.js
  9. +1
    -0
      src/Components/Modalbox10.js
  10. +1
    -0
      src/Components/Modalbox11.js
  11. +36
    -0
      src/Components/Modalbox12.js
  12. +1
    -0
      src/Components/Modalbox2.js
  13. +1
    -0
      src/Components/Modalbox3.js
  14. +1
    -0
      src/Components/Modalbox4.js
  15. +1
    -0
      src/Components/Modalbox5.js
  16. +1
    -0
      src/Components/Modalbox6.js
  17. +1
    -0
      src/Components/Modalbox7.js
  18. +1
    -0
      src/Components/Modalbox8.js
  19. +1
    -0
      src/Components/Modalbox9.js
  20. +1
    -1
      src/Components/Navigator.js
  21. +1
    -2
      src/Components/Plants.js
  22. +10
    -1
      src/Components/Sysinfo.js

BIN
public/Photos/valkosipulivk3.jpg View File

Before After
Width: 1959  |  Height: 2612  |  Size: 1003 KiB

+ 0
- 1
public/index.html View File

@ -9,7 +9,6 @@
name="description" name="description"
content="Web site created using create-react-app" content="Web site created using create-react-app"
/> />
<link rel="apple-touch-icon" href="logo192.png" />
<!-- <!--
manifest.json provides metadata used when your web app is installed on a manifest.json provides metadata used when your web app is installed on a
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/ user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/


BIN
public/logo192.png View File

Before After
Width: 192  |  Height: 192  |  Size: 8.4 KiB

BIN
public/logo512.png View File

Before After
Width: 512  |  Height: 512  |  Size: 22 KiB

+ 9
- 9
src/App.css View File

@ -62,28 +62,28 @@
} }
.Modaldiv{ .Modaldiv{
width:30%;
margin-top: 50px; margin-top: 50px;
margin-left: 300px; margin-left: 300px;
align-content:auto; align-content:auto;
color: white; color: white;
width: 20%;
} }
.modal-wrapper{ .modal-wrapper{
width: 50%;
display:grid;
background: lightgray;
width: 70%;
display: grid;
grid-column-gap: 12px; grid-column-gap: 12px;
grid-row-gap: 12px; grid-row-gap: 12px;
grid-template-columns: 1fr 1fr 1fr; grid-template-columns: 1fr 1fr 1fr;
} }
.nav-link{ .nav-link{
font-size: 35px;
align-content: center;
font-size: 30px;
} }
.navbar-brand{ .navbar-brand{
font-size: 45px;
}
padding: 3px;
font-size: 40px;
}

+ 3
- 0
src/Components/ModalGrid.js View File

@ -10,6 +10,8 @@ import Modalbox8 from './Modalbox8';
import Modalbox9 from './Modalbox9'; import Modalbox9 from './Modalbox9';
import Modalbox10 from './Modalbox10'; import Modalbox10 from './Modalbox10';
import Modalbox11 from './Modalbox11'; import Modalbox11 from './Modalbox11';
import Modalbox12 from './Modalbox12';
const ModalGrid = () => { const ModalGrid = () => {
return ( return (
@ -25,6 +27,7 @@ const ModalGrid = () => {
<Modalbox11 /> <Modalbox11 />
<Modalbox7 /> <Modalbox7 />
<Modalbox8 /> <Modalbox8 />
<Modalbox12 />
</div> </div>
); );
}; };


+ 1
- 1
src/Components/ModalList.js View File

@ -51,7 +51,7 @@ const ModalList = () => {
</div>) </div>)
} }
</div> </div>
</div>
</div>
); );
}; };

+ 1
- 0
src/Components/Modalbox1.js View File

@ -25,6 +25,7 @@ const Modalbox1 = () => {
> >
<div className="Modaldiv"> <div className="Modaldiv">
<img alt="Broken" src='../Photos/kolvaus1.jpeg' width="600"></img> <img alt="Broken" src='../Photos/kolvaus1.jpeg' width="600"></img>
<p style={{background:'black', color:'gray', width:600}}>Johtojen pidennystä</p>
</div> </div>
</Modal> </Modal>
</div> </div>


+ 1
- 0
src/Components/Modalbox10.js View File

@ -25,6 +25,7 @@ const Modalbox10 = props => {
> >
<div className="Modaldiv"> <div className="Modaldiv">
<img alt="Broken" src='../Photos/kolvaus3.jpg' height="500"></img> <img alt="Broken" src='../Photos/kolvaus3.jpg' height="500"></img>
<p style={{background:'black', color:'gray', width:442}}>Viellä lisää kolvausta</p>
</div> </div>
</Modal> </Modal>
</div> </div>


+ 1
- 0
src/Components/Modalbox11.js View File

@ -25,6 +25,7 @@ const Modalbox11 = props => {
> >
<div className="Modaldiv"> <div className="Modaldiv">
<img alt="Broken" src='../Photos/kolvaus4.jpg' height="500"></img> <img alt="Broken" src='../Photos/kolvaus4.jpg' height="500"></img>
<p style={{background:'black', color:'gray', width:889}}>Viellä vähän kolvausta</p>
</div> </div>
</Modal> </Modal>
</div> </div>


+ 36
- 0
src/Components/Modalbox12.js View File

@ -0,0 +1,36 @@
import React from 'react';
import Modal from '@material-ui/core/Modal';
import '../App.css';
const Modalbox12 = props => {
const [open, setOpen] = React.useState(false);
const handleOpen = () => {
setOpen(true);
};
const handleClose = () => {
setOpen(false);
};
return (
<div>
<button type="button" onClick={handleOpen}>
<img alt="Broken" src='../Photos/valkosipulivk3.jpg' width="250"></img>
</button>
<Modal
open={open}
onClose={handleClose}
>
<div className="Modaldiv">
<img alt="Broken" src='../Photos/valkosipulivk3.jpg' height="500"></img>
<p style={{background:'black', color:'gray', width:376}}>Valkosipulin kasvu viikko 3</p>
</div>
</Modal>
</div>
);
};
export default Modalbox12;

+ 1
- 0
src/Components/Modalbox2.js View File

@ -25,6 +25,7 @@ const Modalbox2 = () => {
> >
<div className="Modaldiv"> <div className="Modaldiv">
<img alt="Broken" src='../Photos/kokous1.jpeg' width="600"></img> <img alt="Broken" src='../Photos/kokous1.jpeg' width="600"></img>
<p style={{background:'black', color:'gray', width:600}}>Ensimmäinen kokous</p>
</div> </div>
</Modal> </Modal>
</div> </div>


+ 1
- 0
src/Components/Modalbox3.js View File

@ -25,6 +25,7 @@ const Modalbox3 = () => {
> >
<div className="Modaldiv"> <div className="Modaldiv">
<img alt="Broken" src='../Photos/konstaRpi.jpeg' width="600"></img> <img alt="Broken" src='../Photos/konstaRpi.jpeg' width="600"></img>
<p style={{background:'black', color:'gray', width:600}}>Konsta hommissa</p>
</div> </div>
</Modal> </Modal>
</div> </div>


+ 1
- 0
src/Components/Modalbox4.js View File

@ -25,6 +25,7 @@ const Modalbox4 = () => {
> >
<div className="Modaldiv"> <div className="Modaldiv">
<img alt="Broken" src='../Photos/rpiMoist.jpeg' width="600"></img> <img alt="Broken" src='../Photos/rpiMoist.jpeg' width="600"></img>
<p style={{background:'black', color:'gray', width:600}}>Kosteusensori toiminnassa</p>
</div> </div>
</Modal> </Modal>
</div> </div>


+ 1
- 0
src/Components/Modalbox5.js View File

@ -25,6 +25,7 @@ const Modalbox5 = () => {
> >
<div className="Modaldiv"> <div className="Modaldiv">
<img alt="Broken" src='../Photos/rpiPek.jpeg' width="600"></img> <img alt="Broken" src='../Photos/rpiPek.jpeg' width="600"></img>
<p style={{background:'black', color:'gray', width:600}}>Pumput testissä</p>
</div> </div>
</Modal> </Modal>
</div> </div>


+ 1
- 0
src/Components/Modalbox6.js View File

@ -25,6 +25,7 @@ const Modalbox6 = props => {
> >
<div className="Modaldiv"> <div className="Modaldiv">
<img alt="Broken" src='../Photos/rpiTemp.jpeg' width="600"></img> <img alt="Broken" src='../Photos/rpiTemp.jpeg' width="600"></img>
<p style={{background:'black', color:'gray', width:600}}>Pumput toiminnassa kosteusensorin kosteuden mukaan</p>
</div> </div>
</Modal> </Modal>
</div> </div>


+ 1
- 0
src/Components/Modalbox7.js View File

@ -25,6 +25,7 @@ const Modalbox7 = props => {
> >
<div className="Modaldiv"> <div className="Modaldiv">
<img alt="Broken" src='../Photos/valkosipulivk1.jpeg' height="500"></img> <img alt="Broken" src='../Photos/valkosipulivk1.jpeg' height="500"></img>
<p style={{background:'black', color:'gray', width:400}}>Valkosipulin kasvu viikko 1</p>
</div> </div>
</Modal> </Modal>
</div> </div>


+ 1
- 0
src/Components/Modalbox8.js View File

@ -25,6 +25,7 @@ const Modalbox8 = props => {
> >
<div className="Modaldiv"> <div className="Modaldiv">
<img alt="Broken" src='../Photos/valkosipulivk2.jpg' height="500"></img> <img alt="Broken" src='../Photos/valkosipulivk2.jpg' height="500"></img>
<p style={{background:'black', color:'gray', width:360}}>Valkosipulin kasvu viikko 2</p>
</div> </div>
</Modal> </Modal>
</div> </div>


+ 1
- 0
src/Components/Modalbox9.js View File

@ -25,6 +25,7 @@ const Modalbox9 = props => {
> >
<div className="Modaldiv"> <div className="Modaldiv">
<img alt="Broken" src='../Photos/kolvaus2.jpg' height="500"></img> <img alt="Broken" src='../Photos/kolvaus2.jpg' height="500"></img>
<p style={{background:'black', color:'gray', width:344}}>Lisää kolvailua</p>
</div> </div>
</Modal> </Modal>
</div> </div>


+ 1
- 1
src/Components/Navigator.js View File

@ -17,7 +17,7 @@ const Navigator = () => {
<Link className="nav-link" to="/">Home</Link> <Link className="nav-link" to="/">Home</Link>
</li> </li>
<li className="nav-item"> <li className="nav-item">
<Link className="nav-link" to="/system">System information</Link>
<Link className="nav-link" to="/system">System Information</Link>
</li> </li>
<li className="nav-item"> <li className="nav-item">
<Link className="nav-link" to="/plants">My Plants</Link> <Link className="nav-link" to="/plants">My Plants</Link>


+ 1
- 2
src/Components/Plants.js View File

@ -5,7 +5,7 @@ const Plants = () => {
// TODO Figure out layout and what information to pull form json // TODO Figure out layout and what information to pull form json
// Maby add pictures etc. // Maby add pictures etc.
// plantinfo.json is a temporary file
const [plant, setPlant] = useState([]); const [plant, setPlant] = useState([]);
@ -24,7 +24,6 @@ const Plants = () => {
return ( return (
<div> <div>
<div className="wrapper"> <div className="wrapper">
<h2 style={{padding:10}}>Plant Information</h2> <h2 style={{padding:10}}>Plant Information</h2>
<div className="plants"> <div className="plants">


+ 10
- 1
src/Components/Sysinfo.js View File

@ -4,12 +4,21 @@ const Sysinfo = () => {
// TODO Pull system info etc. // TODO Pull system info etc.
//const [sysinfo, setSysinfo] = useState([]);
// const jsonFetch = () => {
// fetch('../sysinfo.json')
// .then((res) => res.json())
// .then(data => setSysinfo(data))
// .catch(err => console.error(err))
//}
return ( return (
<div> <div>
<div className="wrapper"> <div className="wrapper">
<h2 style={{padding:10}}>System Information</h2> <h2 style={{padding:10}}>System Information</h2>
<div className="sys1"> <div className="sys1">
<h5>Systeminfo</h5>
<h5>System Information</h5>
<h6>Temperature: Pull system temp</h6> <h6>Temperature: Pull system temp</h6>
<h6>Kernel: Pull kernel info</h6> <h6>Kernel: Pull kernel info</h6>
</div> </div>


Loading…
Cancel
Save