Move and rename Disruption
This commit is contained in:
parent
1067277cb8
commit
a1158d4525
@ -1,7 +1,7 @@
|
|||||||
import addNotification from "react-push-notification";
|
import addNotification from "react-push-notification";
|
||||||
|
|
||||||
const Disruption = () => {
|
const DisruptionButton = () => {
|
||||||
const buttonClick = () => {
|
const genDisrupt = () => {
|
||||||
addNotification({
|
addNotification({
|
||||||
title: "Warning",
|
title: "Warning",
|
||||||
subtitle: "This is a subtitle",
|
subtitle: "This is a subtitle",
|
||||||
@ -12,12 +12,10 @@ const Disruption = () => {
|
|||||||
};
|
};
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="page">
|
<button onClick={genDisrupt} id="disruptBtn">
|
||||||
<button onClick={buttonClick} className="button">
|
Generera Störning
|
||||||
Störning
|
|
||||||
</button>
|
</button>
|
||||||
</div>
|
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
export default Disruption;
|
export default DisruptionButton;
|
@ -1,10 +1,15 @@
|
|||||||
import './css/NavigationDrawer.css';
|
|
||||||
import React, { Component } from 'react';
|
import React, { Component } from 'react';
|
||||||
|
import './css/NavigationDrawer.css';
|
||||||
|
|
||||||
|
import DisruptionButton from "./DisruptionButton.js";
|
||||||
|
|
||||||
|
|
||||||
class NavigationDrawer extends Component {
|
class NavigationDrawer extends Component {
|
||||||
render() {
|
render() {
|
||||||
return (
|
return (
|
||||||
<div id="navDrawer"></div>
|
<div id="navDrawer">
|
||||||
|
<DisruptionButton />
|
||||||
|
</div>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -9,7 +9,6 @@ import TrafficList from "../TrafficList.js";
|
|||||||
import Stop from "../../classes/Stop.js";
|
import Stop from "../../classes/Stop.js";
|
||||||
import Departure from "../../classes/Departure.js";
|
import Departure from "../../classes/Departure.js";
|
||||||
|
|
||||||
import Disruption from "./Disruption.js";
|
|
||||||
|
|
||||||
class TrafficInfo extends Component {
|
class TrafficInfo extends Component {
|
||||||
render() {
|
render() {
|
||||||
@ -36,11 +35,6 @@ class TrafficInfo extends Component {
|
|||||||
<MainArea>
|
<MainArea>
|
||||||
<TrafficList departures={testStop.departures} />
|
<TrafficList departures={testStop.departures} />
|
||||||
</MainArea>
|
</MainArea>
|
||||||
<Disruption>
|
|
||||||
<button onClick={Disruption} className="button">
|
|
||||||
Störning
|
|
||||||
</button>
|
|
||||||
</Disruption>
|
|
||||||
</>
|
</>
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user