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