diff --git a/components/Buttons.jsx b/components/Buttons.jsx
index 722c0b5..2be6ee6 100644
--- a/components/Buttons.jsx
+++ b/components/Buttons.jsx
@@ -1,21 +1,46 @@
import React, { Component } from 'react';
+import Word from './Word.jsx'
+import data from '../data.js'
+
class Buttons extends Component {
constructor(props) {
super(props);
this.state = { }
}
+
render() {
+ let theObjId = this.props.match.params.id
+
+ let theObj = data.find( x => x.id == theObjId)
+
+ let winColor = theObj.color
+
+ console.log('winColor', theObj)
+
+ const handleClick = (e) => {
+ if (winColor == e.target.innerHTML.toLowerCase()) {
+ this.props.history.push('/result/win')
+ } else if(winColor !== e.target.innerHTML) {
+ this.props.history.push('/result/lose')
+ }
+
+
+ }
+
return (
-
-
-
-
+
+
+
+
+
+
+
);
}
}
diff --git a/components/Header.jsx b/components/Header.jsx
index 12ed96b..089020f 100644
--- a/components/Header.jsx
+++ b/components/Header.jsx
@@ -1,20 +1,18 @@
-import React, { Component } from 'react';
+import React, { Component } from "react";
class Header extends Component {
- constructor(props) {
- super(props);
- this.state = { }
- }
- render() {
- return (
-
-
COLOUR ANXIETY
-
-
-
- )
- }
+ constructor(props) {
+ super(props);
+ this.state = {};
+ }
+ render() {
+ return (
+
+
COLOUR ANXIETY
+
+ );
+ }
}
-
+
export default Header;
diff --git a/components/Lose.jsx b/components/Lose.jsx
index 7cd0c91..d850472 100644
--- a/components/Lose.jsx
+++ b/components/Lose.jsx
@@ -1,27 +1,31 @@
-import React, { Component } from 'react';
+
+import React, { Component } from "react";
class Lose extends Component {
constructor(props) {
- super(props);
- this.state = { }
+ super(props);
+ this.state = {};
}
- render() {
- return (
-
-
That Stinks
-
-
- );
+
+ render() {
+ const handleClick = e => {
+ window.location = "/";
+ };
+
+ return (
+
+
That Stinks
+
+
+
+
+ );
}
}
+export default Lose;
-
-
-
-
-
-
-
-
-export default Lose
\ No newline at end of file
diff --git a/components/Timer.jsx b/components/Timer.jsx
index c7224db..7e59ac5 100644
--- a/components/Timer.jsx
+++ b/components/Timer.jsx
@@ -1,20 +1,23 @@
-import React from 'react'
-import CountdownTimer from "react-component-countdown-timer"
+import React from "react";
+import CountdownTimer from "react-component-countdown-timer";
class Countdown extends React.Component {
render() {
var settings = {
-count: 5,
-border: true,
-hideDay: true,
-hideHours: true,
-noPoints: true,
- };
+ count: 3,
+ border: true,
+ hideDay: true,
+ hideHours: true,
+ noPoints: true,
+ onEnd: () => {
+ if (this.props.history.location.pathname != "/result/lose") {
+ this.props.history.push("/result/lose");
+ }
+ }
+ };
-return (
-
- );
+ return ;
}
}
-export default Countdown
\ No newline at end of file
+export default Countdown;
diff --git a/components/Win.jsx b/components/Win.jsx
index 1503819..1f0b305 100644
--- a/components/Win.jsx
+++ b/components/Win.jsx
@@ -6,21 +6,26 @@ class Win extends Component {
super(props);
this.state = { }
}
- render() {
+
+
+ render() {
+ const handleClick = (e) => {
+ window.location = "/";
+ }
+
return (
That's Awesome
+
+
+
+
);
}
}
+export default Win
-
-
-
-
-
-export default Win
\ No newline at end of file
diff --git a/components/Word.jsx b/components/Word.jsx
index 56f1062..e6150f2 100644
--- a/components/Word.jsx
+++ b/components/Word.jsx
@@ -1,33 +1,29 @@
-import React, { Component } from 'react';
-import data from '../data.js'
+import React, { Component } from "react";
+import data from "../data.js";
-var min=0;
-var max=10;
-
-let randomId = Math.floor(Math.random() * (+max - +min)) + +min;
+import Countdown from "./Timer.jsx";
+import { HashRouter as Router, Route, Link } from "react-router-dom";
class Word extends Component {
- constructor(props) {
- super(props);
- this.state = { }
- }
-
-
-
- render() {
-
-
- let {color} = data[randomId]
+ constructor(props) {
+ super(props);
+ this.state = {};
+ }
- return (
-
- {data[randomId].word}
+ render() {
+ let randomId = this.props.match.params.id;
+ let {word, color} = data.find( x => x.id == randomId)
-
-
-
- );
- }
+
+ console.log('random id', randomId, 'colour', color);
+
+ return (
+
+
+ {word}
+
+ );
+ }
}
-
-export default Word;
\ No newline at end of file
+
+export default Word;
diff --git a/components/app.js b/components/app.js
index bbbcb70..7350802 100644
--- a/components/app.js
+++ b/components/app.js
@@ -1,32 +1,56 @@
-import React, { Component } from 'react'
-import Audio from "./Sounds.jsx"
-import Header from './Header.jsx'
-import Word from './Word.jsx'
-import Buttons from './Buttons.jsx'
-import Countdown from './Timer.jsx'
-class App extends Component {
+import React, { Component } from "react";
+import { Redirect } from "react-router-dom";
+import { HashRouter as Router, Route, Link } from "react-router-dom";
+
+import Audio from "./Sounds.jsx";
+import Header from "./Header.jsx";
+import Word from "./Word.jsx";
+import Buttons from "./Buttons.jsx";
+
+import Countdown from "./Timer.jsx";
+import Win from "./Win.jsx";
+import Lose from "./Lose.jsx";
+import data from "../data.js";
+
+var min = 0;
+var max = 10;
- constructor (props) {
- super(props)
+let randomId = Math.floor(Math.random() * (+max - +min)) + +min;
+
+let { id } = data[randomId];
+
+class App extends Component {
+ constructor(props) {
+ super(props);
}
- render () {
- return(
+ render() {
+ return (
- {/*
Welcome to {this.props.name}
*/}
-
-
-
-
-
-
- )
+
-
- }
+
+ }
+ />
+
+
+
+
+
+
+
+
+
+
+
+ );
+ }
}
-export default App
+export default App;
diff --git a/data.js b/data.js
index 3e7cd10..1b2f24c 100644
--- a/data.js
+++ b/data.js
@@ -1,7 +1,7 @@
const colour = [{
id:1,
word:"RED",
- color: 'royalblue'
+ color: 'blue'
},
{
id:2,
@@ -16,7 +16,7 @@ const colour = [{
{
id:4,
word:"BLUE",
- color: 'gold'
+ color: 'yellow'
},
{
id:5,
@@ -31,7 +31,7 @@ const colour = [{
{
id:7,
word:"YELLOW",
- color: 'royalblue'
+ color: 'blue'
},
{
id:8,
@@ -41,12 +41,12 @@ const colour = [{
{
id:9,
word:"BLUE",
- color: 'gold'
+ color: 'yellow'
},
{
id:10,
word:"RED",
- color: 'royalblue'
+ color: 'blue'
}
]
diff --git a/package-lock.json b/package-lock.json
index f4be7e9..9342525 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -789,14 +789,6 @@
"@babel/plugin-transform-react-jsx-source": "^7.0.0"
}
},
- "@babel/runtime": {
- "version": "7.4.3",
- "resolved": "https://registry.npmjs.org/@babel/runtime/-/runtime-7.4.3.tgz",
- "integrity": "sha512-9lsJwJLxDh/T3Q3SZszfWOTkk3pHbkmH+3KY+zwIDmsNlxsumuhS2TH3NIpktU4kNvfzy+k3eLT7aTJSPTo0OA==",
- "requires": {
- "regenerator-runtime": "^0.13.2"
- }
- },
"@babel/template": {
"version": "7.4.0",
"resolved": "https://registry.npmjs.org/@babel/template/-/template-7.4.0.tgz",
@@ -1021,11 +1013,6 @@
"integrity": "sha1-iYUI2iIm84DfkEcoRWhJwVAaSw0=",
"dev": true
},
- "asap": {
- "version": "2.0.6",
- "resolved": "https://registry.npmjs.org/asap/-/asap-2.0.6.tgz",
- "integrity": "sha1-5QNHYR1+aQlDIIu9r+vLwvuGbUY="
- },
"asn1.js": {
"version": "4.10.1",
"resolved": "https://registry.npmjs.org/asn1.js/-/asn1.js-4.10.1.tgz",
@@ -1087,6 +1074,22 @@
"integrity": "sha512-Wm6ukoaOGJi/73p/cl2GvLjTI5JM1k/O14isD73YML8StrH/7/lRFgmg8nICZgD3bZZvjwCGxtMOD3wWNAu8cg==",
"dev": true
},
+ "babel-runtime": {
+ "version": "6.26.0",
+ "resolved": "https://registry.npmjs.org/babel-runtime/-/babel-runtime-6.26.0.tgz",
+ "integrity": "sha1-llxwWGaOgrVde/4E/yM3vItWR/4=",
+ "requires": {
+ "core-js": "^2.4.0",
+ "regenerator-runtime": "^0.11.0"
+ },
+ "dependencies": {
+ "core-js": {
+ "version": "2.6.5",
+ "resolved": "https://registry.npmjs.org/core-js/-/core-js-2.6.5.tgz",
+ "integrity": "sha512-klh/kDpwX8hryYL14M9w/xei6vrv6sE8gTHDG7/T/+SEovB/G4ejwcfE/CBzO6Edsu+OETZMZ3wcX/EjUkrl5A=="
+ }
+ }
+ },
"babelify": {
"version": "10.0.0",
"resolved": "https://registry.npmjs.org/babelify/-/babelify-10.0.0.tgz",
@@ -1166,14 +1169,6 @@
"integrity": "sha512-DYWGk01lDcxeS/K9IHPGWfT8PsJmbXRtRd2Sx72Tnb8pcYZQFF1oSDb8hJtS1vhp212q1Rzi5dUf9+nq0o9UIg==",
"dev": true
},
- "bindings": {
- "version": "1.5.0",
- "resolved": "https://registry.npmjs.org/bindings/-/bindings-1.5.0.tgz",
- "integrity": "sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==",
- "requires": {
- "file-uri-to-path": "1.0.0"
- }
- },
"bn.js": {
"version": "4.11.8",
"resolved": "https://registry.npmjs.org/bn.js/-/bn.js-4.11.8.tgz",
@@ -1958,15 +1953,6 @@
"sha.js": "^2.4.8"
}
},
- "create-react-context": {
- "version": "0.2.3",
- "resolved": "https://registry.npmjs.org/create-react-context/-/create-react-context-0.2.3.tgz",
- "integrity": "sha512-CQBmD0+QGgTaxDL3OX1IDXYqjkp2It4RIbcb99jS6AEg27Ga+a9G3JtK6SIu0HBwPLZlmwt9F7UwWA4Bn92Rag==",
- "requires": {
- "fbjs": "^0.8.0",
- "gud": "^1.0.0"
- }
- },
"cross-spawn": {
"version": "6.0.5",
"resolved": "https://registry.npmjs.org/cross-spawn/-/cross-spawn-6.0.5.tgz",
@@ -2176,14 +2162,6 @@
"minimist": "^1.1.1"
}
},
- "dev": {
- "version": "0.1.3",
- "resolved": "https://registry.npmjs.org/dev/-/dev-0.1.3.tgz",
- "integrity": "sha1-if3AhwXg5+rvktAS4mdR5NdEMio=",
- "requires": {
- "inotify": ">= 0.1.6"
- }
- },
"diffie-hellman": {
"version": "5.0.3",
"resolved": "http://registry.npmjs.org/diffie-hellman/-/diffie-hellman-5.0.3.tgz",
@@ -2263,6 +2241,15 @@
"prop-types": "^15.6.0"
}
},
+ "emoji-picker-react": {
+ "version": "2.1.1",
+ "resolved": "https://registry.npmjs.org/emoji-picker-react/-/emoji-picker-react-2.1.1.tgz",
+ "integrity": "sha512-LtCmP/1o+xSzqKJk07NSCcMkPrnkpO6jdJkDLlfNpZL7IUERVDXVRhUannjDX2cY6wYuPWGDZHLvaeGIILAUfw==",
+ "requires": {
+ "babel-runtime": "^6.25.0",
+ "throttle-debounce": "^1.0.1"
+ }
+ },
"emoji-regex": {
"version": "6.5.1",
"resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-6.5.1.tgz",
@@ -2274,14 +2261,6 @@
"integrity": "sha1-rT/0yG7C0CkyL1oCw6mmBslbP1k=",
"dev": true
},
- "encoding": {
- "version": "0.1.12",
- "resolved": "https://registry.npmjs.org/encoding/-/encoding-0.1.12.tgz",
- "integrity": "sha1-U4tm8+5izRq1HsMjgp0flIDHS+s=",
- "requires": {
- "iconv-lite": "~0.4.13"
- }
- },
"end-of-stream": {
"version": "1.4.1",
"resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.1.tgz",
@@ -2746,27 +2725,6 @@
"integrity": "sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=",
"dev": true
},
- "fbjs": {
- "version": "0.8.16",
- "resolved": "https://registry.npmjs.org/fbjs/-/fbjs-0.8.16.tgz",
- "integrity": "sha1-XmdDL1UNxBtXK/VYR7ispk5TN9s=",
- "requires": {
- "core-js": "^1.0.0",
- "isomorphic-fetch": "^2.1.1",
- "loose-envify": "^1.0.0",
- "object-assign": "^4.1.0",
- "promise": "^7.1.1",
- "setimmediate": "^1.0.5",
- "ua-parser-js": "^0.7.9"
- },
- "dependencies": {
- "core-js": {
- "version": "1.2.7",
- "resolved": "https://registry.npmjs.org/core-js/-/core-js-1.2.7.tgz",
- "integrity": "sha1-ZSKUwUZR2yj6k70tX/KYOk8IxjY="
- }
- }
- },
"figures": {
"version": "1.7.0",
"resolved": "https://registry.npmjs.org/figures/-/figures-1.7.0.tgz",
@@ -2777,11 +2735,6 @@
"object-assign": "^4.1.0"
}
},
- "file-uri-to-path": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/file-uri-to-path/-/file-uri-to-path-1.0.0.tgz",
- "integrity": "sha512-0Zt+s3L7Vf1biwWZ29aARiVYLx7iMGnEUl9x33fbB/j3jR81u/O2LbqK+Bm1CDSNDKVtJ/YjwY7TUd5SkeLQLw=="
- },
"fill-range": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/fill-range/-/fill-range-4.0.0.tgz",
@@ -3587,11 +3540,6 @@
"integrity": "sha1-TK+tdrxi8C+gObL5Tpo906ORpyU=",
"dev": true
},
- "gud": {
- "version": "1.0.0",
- "resolved": "https://registry.npmjs.org/gud/-/gud-1.0.0.tgz",
- "integrity": "sha512-zGEOVKFM5sVPPrYs7J5/hYEw2Pof8KCyOwyhG8sAF26mCAeUFAcYPu1mwB7hhpIP29zOIBaDqwuHdLp0jvZXjw=="
- },
"has": {
"version": "1.0.3",
"resolved": "https://registry.npmjs.org/has/-/has-1.0.3.tgz",
@@ -3675,16 +3623,16 @@
}
},
"history": {
- "version": "4.9.0",
- "resolved": "https://registry.npmjs.org/history/-/history-4.9.0.tgz",
- "integrity": "sha512-H2DkjCjXf0Op9OAr6nJ56fcRkTSNrUiv41vNJ6IswJjif6wlpZK0BTfFbi7qK9dXLSYZxkq5lBsj3vUjlYBYZA==",
+ "version": "4.7.2",
+ "resolved": "https://registry.npmjs.org/history/-/history-4.7.2.tgz",
+ "integrity": "sha512-1zkBRWW6XweO0NBcjiphtVJVsIQ+SXF29z9DVkceeaSLVMFXHool+fdCZD4spDCfZJCILPILc3bm7Bc+HRi0nA==",
+ "dev": true,
"requires": {
- "@babel/runtime": "^7.1.2",
+ "invariant": "^2.2.1",
"loose-envify": "^1.2.0",
"resolve-pathname": "^2.2.0",
- "tiny-invariant": "^1.0.2",
- "tiny-warning": "^1.0.0",
- "value-equal": "^0.4.0"
+ "value-equal": "^0.4.0",
+ "warning": "^3.0.0"
}
},
"hmac-drbg": {
@@ -3699,12 +3647,10 @@
}
},
"hoist-non-react-statics": {
- "version": "3.3.0",
- "resolved": "https://registry.npmjs.org/hoist-non-react-statics/-/hoist-non-react-statics-3.3.0.tgz",
- "integrity": "sha512-0XsbTXxgiaCDYDIWFcwkmerZPSwywfUqYmwT4jzewKTQSWoE6FCMoUVOeBJWK3E/CrWbxRG3m5GzY4lnIwGRBA==",
- "requires": {
- "react-is": "^16.7.0"
- }
+ "version": "2.5.5",
+ "resolved": "https://registry.npmjs.org/hoist-non-react-statics/-/hoist-non-react-statics-2.5.5.tgz",
+ "integrity": "sha512-rqcy4pJo55FTTLWt+bU8ukscqHeE/e9KWvsOW2b/a3afxQZhwkQdT1rPPCJ0rYXdj4vNcasY8zHTH+jF/qStxw==",
+ "dev": true
},
"htmlescape": {
"version": "1.1.1",
@@ -3730,14 +3676,6 @@
"integrity": "sha1-7AbBDgo0wPL68Zn3/X/Hj//QPHM=",
"dev": true
},
- "iconv-lite": {
- "version": "0.4.24",
- "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.4.24.tgz",
- "integrity": "sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==",
- "requires": {
- "safer-buffer": ">= 2.1.2 < 3"
- }
- },
"ieee754": {
"version": "1.1.12",
"resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.1.12.tgz",
@@ -3784,22 +3722,6 @@
"source-map": "~0.5.3"
}
},
- "inotify": {
- "version": "1.4.6",
- "resolved": "https://registry.npmjs.org/inotify/-/inotify-1.4.6.tgz",
- "integrity": "sha512-WW8/uqIA04O3AePQVe/Ms3ZLR0yGamaz8YOEpaXc4WBAGOPZfzu58wWErEPSUYaPyDrJRIeCn6PEIQgC1ZyQ5w==",
- "requires": {
- "bindings": "^1.3.1",
- "nan": "^2.12.1"
- },
- "dependencies": {
- "nan": {
- "version": "2.13.2",
- "resolved": "https://registry.npmjs.org/nan/-/nan-2.13.2.tgz",
- "integrity": "sha512-TghvYc72wlMGMVMluVo9WRJc0mB8KxxF/gZ4YYFy7V2ZQX9l7rgbPg7vjS9mt6U5HXODVFVI2bOduCzwOMv/lw=="
- }
- }
- },
"insert-module-globals": {
"version": "7.2.0",
"resolved": "https://registry.npmjs.org/insert-module-globals/-/insert-module-globals-7.2.0.tgz",
@@ -3832,6 +3754,7 @@
"version": "2.2.4",
"resolved": "https://registry.npmjs.org/invariant/-/invariant-2.2.4.tgz",
"integrity": "sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==",
+ "dev": true,
"requires": {
"loose-envify": "^1.0.0"
}
@@ -4022,7 +3945,8 @@
"is-stream": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/is-stream/-/is-stream-1.1.0.tgz",
- "integrity": "sha1-EtSj3U5o4Lec6428hBc66A2RykQ="
+ "integrity": "sha1-EtSj3U5o4Lec6428hBc66A2RykQ=",
+ "dev": true
},
"is-symbol": {
"version": "1.0.2",
@@ -4057,15 +3981,6 @@
"integrity": "sha1-TkMekrEalzFjaqH5yNHMvP2reN8=",
"dev": true
},
- "isomorphic-fetch": {
- "version": "2.2.1",
- "resolved": "https://registry.npmjs.org/isomorphic-fetch/-/isomorphic-fetch-2.2.1.tgz",
- "integrity": "sha1-YRrhrPFPXoH3KVB0coGf6XM1WKk=",
- "requires": {
- "node-fetch": "^1.0.1",
- "whatwg-fetch": ">=0.10.0"
- }
- },
"js-levenshtein": {
"version": "1.1.4",
"resolved": "https://registry.npmjs.org/js-levenshtein/-/js-levenshtein-1.1.4.tgz",
@@ -4075,7 +3990,8 @@
"js-tokens": {
"version": "4.0.0",
"resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz",
- "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ=="
+ "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==",
+ "dev": true
},
"jsesc": {
"version": "2.5.1",
@@ -4160,10 +4076,15 @@
"integrity": "sha512-cQKh8igo5QUhZ7lg38DYWAxMvjSAKG0A8wGSVimP07SIUEK2UO+arSRKbRZWtelMtN5V0Hkwh5ryOto/SshYIg==",
"dev": true
},
- "lodash.isequal": {
- "version": "4.5.0",
- "resolved": "https://registry.npmjs.org/lodash.isequal/-/lodash.isequal-4.5.0.tgz",
- "integrity": "sha1-QVxEePK8wwEgwizhDtMib30+GOA="
+ "lodash.flatten": {
+ "version": "4.4.0",
+ "resolved": "https://registry.npmjs.org/lodash.flatten/-/lodash.flatten-4.4.0.tgz",
+ "integrity": "sha1-8xwiIlqWMtK7+OSt2+8kCqdlph8="
+ },
+ "lodash.isstring": {
+ "version": "4.0.1",
+ "resolved": "https://registry.npmjs.org/lodash.isstring/-/lodash.isstring-4.0.1.tgz",
+ "integrity": "sha1-1SfftUVuynzJu5XV2ur4i6VKVFE="
},
"lodash.memoize": {
"version": "3.0.4",
@@ -4175,6 +4096,7 @@
"version": "1.4.0",
"resolved": "https://registry.npmjs.org/loose-envify/-/loose-envify-1.4.0.tgz",
"integrity": "sha512-lyuxPGr/Wfhrlem2CL/UcnUc1zcqKAImBDzukY7Y5F/yQiNdko6+fRLevlw1HgMySw7f611UIY408EtxRSoK3Q==",
+ "dev": true,
"requires": {
"js-tokens": "^3.0.0 || ^4.0.0"
}
@@ -4432,9 +4354,9 @@
"dev": true
},
"nan": {
- "version": "2.11.1",
- "resolved": "https://registry.npmjs.org/nan/-/nan-2.11.1.tgz",
- "integrity": "sha512-iji6k87OSXa0CcrLl9z+ZiYSuR2o+c0bGuNmXdrhTQTakxytAFsC56SArGYoiHlJlFoHSnvmhpceZJaXkVuOtA==",
+ "version": "2.10.0",
+ "resolved": "https://registry.npmjs.org/nan/-/nan-2.10.0.tgz",
+ "integrity": "sha512-bAdJv7fBLhWC+/Bls0Oza+mvTaNQtP+1RyhhhvD95pgUJz6XM5IzgmxOkItJ9tkoCiplvAnXI1tNmmUD/eScyA==",
"dev": true,
"optional": true
},
@@ -4524,15 +4446,6 @@
"integrity": "sha512-2NpiFHqC87y/zFke0fC0spBXL3bBsoh/p5H1EFhshxjCR5+0g2d6BiXbUFz9v1sAcxsk2htp2eQnNIci2dIYcA==",
"dev": true
},
- "node-fetch": {
- "version": "1.7.3",
- "resolved": "https://registry.npmjs.org/node-fetch/-/node-fetch-1.7.3.tgz",
- "integrity": "sha512-NhZ4CsKx7cYm2vSrBAr2PvFOe6sWDf0UYLRqA6svUYg7+/TSfVAu49jYC4BvQ4Sms9SZgdqGBgroqfDhJdTyKQ==",
- "requires": {
- "encoding": "^0.1.11",
- "is-stream": "^1.0.1"
- }
- },
"node-releases": {
"version": "1.1.14",
"resolved": "https://registry.npmjs.org/node-releases/-/node-releases-1.1.14.tgz",
@@ -4566,7 +4479,8 @@
"object-assign": {
"version": "4.1.1",
"resolved": "https://registry.npmjs.org/object-assign/-/object-assign-4.1.1.tgz",
- "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM="
+ "integrity": "sha1-IQmtx5ZYh8/AXLvUQsrIv7s2CGM=",
+ "dev": true
},
"object-copy": {
"version": "0.1.0",
@@ -4813,6 +4727,7 @@
"version": "1.7.0",
"resolved": "https://registry.npmjs.org/path-to-regexp/-/path-to-regexp-1.7.0.tgz",
"integrity": "sha1-Wf3g9DW62suhA6hOnTvGTpa5k30=",
+ "dev": true,
"requires": {
"isarray": "0.0.1"
},
@@ -4820,7 +4735,8 @@
"isarray": {
"version": "0.0.1",
"resolved": "https://registry.npmjs.org/isarray/-/isarray-0.0.1.tgz",
- "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8="
+ "integrity": "sha1-ihis/Kmo9Bd+Cav8YDiTmwXR7t8=",
+ "dev": true
}
}
},
@@ -4929,18 +4845,11 @@
"integrity": "sha512-MtEC1TqN0EU5nephaJ4rAtThHtC86dNN9qCuEhtshvpVBkAW5ZO7BASN9REnF9eoXGcRub+pFuKEpOHE+HbEMw==",
"dev": true
},
- "promise": {
- "version": "7.3.1",
- "resolved": "https://registry.npmjs.org/promise/-/promise-7.3.1.tgz",
- "integrity": "sha512-nolQXZ/4L+bP/UGlkfaIujX9BKxGwmQ9OT4mOt5yvy8iK1h3wqTEJCijzGANTCCl9nWjY41juyAn2K3Q1hLLTg==",
- "requires": {
- "asap": "~2.0.3"
- }
- },
"prop-types": {
"version": "15.6.2",
"resolved": "https://registry.npmjs.org/prop-types/-/prop-types-15.6.2.tgz",
"integrity": "sha512-3pboPvLiWD7dkI3qf3KbUe6hKFKa52w+AE0VCqECtf+QHAKgOL37tTaNCnuX1nAAQ4ZhyP+kYVKf8rLmJ/feDQ==",
+ "dev": true,
"requires": {
"loose-envify": "^1.3.1",
"object-assign": "^4.1.1"
@@ -5062,20 +4971,6 @@
"resolved": "https://registry.npmjs.org/react-component-countdown-timer/-/react-component-countdown-timer-0.1.1.tgz",
"integrity": "sha512-xq/D+vfdHrLgiCheeTkCkfpm19rom3L4Nkupn7RAvZo/EFEuAY6fdGaUq34MdxtLNKk1UN4g5H/li3NmNBWFRQ=="
},
- "react-countdown-now": {
- "version": "2.1.0",
- "resolved": "https://registry.npmjs.org/react-countdown-now/-/react-countdown-now-2.1.0.tgz",
- "integrity": "sha512-dAI4y1bpOScdXEWEHl1OAvFjt9I7MxVd7jmExdBcWhVVGcpHjA1wfFNptTtLCwl3qDc+rlXh65Ba7qxgF5gHwQ==",
- "requires": {
- "lodash.isequal": "^4.5.0",
- "prop-types": "^15.6.2"
- }
- },
- "react-countdown-timer-component": {
- "version": "1.0.2",
- "resolved": "https://registry.npmjs.org/react-countdown-timer-component/-/react-countdown-timer-component-1.0.2.tgz",
- "integrity": "sha512-av5o4rSTMzqoFPpNtF1ZSI5txDLRWJNQRF4GHCMm5ccm7qPoTEv5qAWyb1WfSIsWMXX2vfAyCNktVCaEZCbKMA=="
- },
"react-dom": {
"version": "16.8.6",
"resolved": "https://registry.npmjs.org/react-dom/-/react-dom-16.8.6.tgz",
@@ -5088,53 +4983,35 @@
"scheduler": "^0.13.6"
}
},
-<<<<<<< HEAD
- "react-is": {
- "version": "16.8.4",
- "resolved": "https://registry.npmjs.org/react-is/-/react-is-16.8.4.tgz",
- "integrity": "sha512-PVadd+WaUDOAciICm/J1waJaSvgq+4rHE/K70j0PFqKhkTBsPv/82UGQJNXAngz1fOQLLxI6z1sEDmJDQhCTAA=="
- },
+
"react-router": {
- "version": "5.0.0",
- "resolved": "https://registry.npmjs.org/react-router/-/react-router-5.0.0.tgz",
- "integrity": "sha512-6EQDakGdLG/it2x9EaCt9ZpEEPxnd0OCLBHQ1AcITAAx7nCnyvnzf76jKWG1s2/oJ7SSviUgfWHofdYljFexsA==",
- "requires": {
- "@babel/runtime": "^7.1.2",
- "create-react-context": "^0.2.2",
- "history": "^4.9.0",
- "hoist-non-react-statics": "^3.1.0",
+ "version": "4.2.0",
+ "resolved": "https://registry.npmjs.org/react-router/-/react-router-4.2.0.tgz",
+ "integrity": "sha512-DY6pjwRhdARE4TDw7XjxjZsbx9lKmIcyZoZ+SDO7SBJ1KUeWNxT22Kara2AC7u6/c2SYEHlEDLnzBCcNhLE8Vg==",
+ "dev": true,
+ "requires": {
+ "history": "^4.7.2",
+ "hoist-non-react-statics": "^2.3.0",
+ "invariant": "^2.2.2",
"loose-envify": "^1.3.1",
"path-to-regexp": "^1.7.0",
- "prop-types": "^15.6.2",
- "react-is": "^16.6.0",
- "tiny-invariant": "^1.0.2",
- "tiny-warning": "^1.0.0"
+ "prop-types": "^15.5.4",
+ "warning": "^3.0.0"
}
},
"react-router-dom": {
- "version": "5.0.0",
- "resolved": "https://registry.npmjs.org/react-router-dom/-/react-router-dom-5.0.0.tgz",
- "integrity": "sha512-wSpja5g9kh5dIteZT3tUoggjnsa+TPFHSMrpHXMpFsaHhQkm/JNVGh2jiF9Dkh4+duj4MKCkwO6H08u6inZYgQ==",
+ "version": "4.2.2",
+ "resolved": "https://registry.npmjs.org/react-router-dom/-/react-router-dom-4.2.2.tgz",
+ "integrity": "sha512-cHMFC1ZoLDfEaMFoKTjN7fry/oczMgRt5BKfMAkTu5zEuJvUiPp1J8d0eXSVTnBh6pxlbdqDhozunOOLtmKfPA==",
+ "dev": true,
"requires": {
- "@babel/runtime": "^7.1.2",
- "history": "^4.9.0",
+ "history": "^4.7.2",
+ "invariant": "^2.2.2",
"loose-envify": "^1.3.1",
- "prop-types": "^15.6.2",
- "react-router": "5.0.0",
- "tiny-invariant": "^1.0.2",
- "tiny-warning": "^1.0.0"
-=======
- "react-emoji-render": {
- "version": "0.6.0",
- "resolved": "https://registry.npmjs.org/react-emoji-render/-/react-emoji-render-0.6.0.tgz",
- "integrity": "sha512-iKTRJfdbNAxabZfgDtpV9Jhlra7g8LduFa8RoUemxMtOcp6+3Bs1+JLli3M34a4xPvJ+4XhueHGyg1IGAANa9g==",
- "requires": {
- "classnames": "^2.2.5",
- "emoji-regex": "^6.4.1",
- "lodash.flatten": "^4.4.0",
- "prop-types": "^15.5.8",
- "string-replace-to-array": "^1.0.1"
->>>>>>> 1f829465928a4464f57f3e55bf7c8e9a71c9ce30
+ "prop-types": "^15.5.4",
+ "react-router": "^4.2.0",
+ "warning": "^3.0.0"
+
}
},
"read-only-stream": {
@@ -5188,9 +5065,9 @@
}
},
"regenerator-runtime": {
- "version": "0.13.2",
- "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.13.2.tgz",
- "integrity": "sha512-S/TQAZJO+D3m9xeN1WTI8dLKBBiRgXBlTJvbWjCThHWZj9EvHK70Ff50/tYj2J/fvBY6JtFVwRuazHN2E7M9BA=="
+ "version": "0.11.1",
+ "resolved": "https://registry.npmjs.org/regenerator-runtime/-/regenerator-runtime-0.11.1.tgz",
+ "integrity": "sha512-MguG95oij0fC3QV3URf4V2SDYGJhJnJGqvIIgdECeODCT98wSWDAJ94SSuVpYQUoTcGUIL6L4yNB7j1DFFHSBg=="
},
"regenerator-transform": {
"version": "0.13.4",
@@ -5293,7 +5170,8 @@
"resolve-pathname": {
"version": "2.2.0",
"resolved": "https://registry.npmjs.org/resolve-pathname/-/resolve-pathname-2.2.0.tgz",
- "integrity": "sha512-bAFz9ld18RzJfddgrO2e/0S2O81710++chRMUxHjXOYKF6jTAMrUNZrEZ1PvV0zlhfjidm08iRPdTLPno1FuRg=="
+ "integrity": "sha512-bAFz9ld18RzJfddgrO2e/0S2O81710++chRMUxHjXOYKF6jTAMrUNZrEZ1PvV0zlhfjidm08iRPdTLPno1FuRg==",
+ "dev": true
},
"resolve-url": {
"version": "0.2.1",
@@ -5374,11 +5252,6 @@
"ret": "~0.1.10"
}
},
- "safer-buffer": {
- "version": "2.1.2",
- "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz",
- "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg=="
- },
"scheduler": {
"version": "0.13.6",
"resolved": "https://registry.npmjs.org/scheduler/-/scheduler-0.13.6.tgz",
@@ -5482,11 +5355,6 @@
}
}
},
- "setimmediate": {
- "version": "1.0.5",
- "resolved": "https://registry.npmjs.org/setimmediate/-/setimmediate-1.0.5.tgz",
- "integrity": "sha1-KQy7Iy4waULX1+qbg3Mqt4VvgoU="
- },
"setprototypeof": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/setprototypeof/-/setprototypeof-1.1.0.tgz",
@@ -6128,6 +5996,11 @@
}
}
},
+ "throttle-debounce": {
+ "version": "1.1.0",
+ "resolved": "https://registry.npmjs.org/throttle-debounce/-/throttle-debounce-1.1.0.tgz",
+ "integrity": "sha512-XH8UiPCQcWNuk2LYePibW/4qL97+ZQ1AN3FNXwZRBNPPowo/NRU5fAlDCSNBJIYCKbioZfuYtMhG4quqoJhVzg=="
+ },
"through": {
"version": "2.3.8",
"resolved": "https://registry.npmjs.org/through/-/through-2.3.8.tgz",
@@ -6153,16 +6026,6 @@
"process": "~0.11.0"
}
},
- "tiny-invariant": {
- "version": "1.0.4",
- "resolved": "https://registry.npmjs.org/tiny-invariant/-/tiny-invariant-1.0.4.tgz",
- "integrity": "sha512-lMhRd/djQJ3MoaHEBrw8e2/uM4rs9YMNk0iOr8rHQ0QdbM7D4l0gFl3szKdeixrlyfm9Zqi4dxHCM2qVG8ND5g=="
- },
- "tiny-warning": {
- "version": "1.0.2",
- "resolved": "https://registry.npmjs.org/tiny-warning/-/tiny-warning-1.0.2.tgz",
- "integrity": "sha512-rru86D9CpQRLvsFG5XFdy0KdLAvjdQDyZCsRcuu60WtzFylDM3eAWSxEVz5kzL2Gp544XiUvPbVKtOA/txLi9Q=="
- },
"tinyify": {
"version": "2.5.0",
"resolved": "https://registry.npmjs.org/tinyify/-/tinyify-2.5.0.tgz",
@@ -6288,11 +6151,6 @@
"integrity": "sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c=",
"dev": true
},
- "ua-parser-js": {
- "version": "0.7.17",
- "resolved": "https://registry.npmjs.org/ua-parser-js/-/ua-parser-js-0.7.17.tgz",
- "integrity": "sha512-uRdSdu1oA1rncCQL7sCj8vSyZkgtL7faaw9Tc9rZ3mGgraQ7+Pdx7w5mnOSF3gw9ZNG6oc+KXfkon3bKuROm0g=="
- },
"uglifyify": {
"version": "5.0.1",
"resolved": "https://registry.npmjs.org/uglifyify/-/uglifyify-5.0.1.tgz",
@@ -6556,7 +6414,8 @@
"value-equal": {
"version": "0.4.0",
"resolved": "https://registry.npmjs.org/value-equal/-/value-equal-0.4.0.tgz",
- "integrity": "sha512-x+cYdNnaA3CxvMaTX0INdTCN8m8aF2uY9BvEqmxuYp8bL09cs/kWVQPVGcA35fMktdOsP69IgU7wFj/61dJHEw=="
+ "integrity": "sha512-x+cYdNnaA3CxvMaTX0INdTCN8m8aF2uY9BvEqmxuYp8bL09cs/kWVQPVGcA35fMktdOsP69IgU7wFj/61dJHEw==",
+ "dev": true
},
"vm-browserify": {
"version": "1.1.0",
@@ -6564,6 +6423,15 @@
"integrity": "sha512-iq+S7vZJE60yejDYM0ek6zg308+UZsdtPExWP9VZoCFCz1zkJoXFnAX7aZfd/ZwrkidzdUZL0C/ryW+JwAiIGw==",
"dev": true
},
+ "warning": {
+ "version": "3.0.0",
+ "resolved": "https://registry.npmjs.org/warning/-/warning-3.0.0.tgz",
+ "integrity": "sha1-MuU3fLVy3kqwR1O9+IIcAe1gW3w=",
+ "dev": true,
+ "requires": {
+ "loose-envify": "^1.0.0"
+ }
+ },
"watchify": {
"version": "3.11.1",
"resolved": "https://registry.npmjs.org/watchify/-/watchify-3.11.1.tgz",
@@ -6607,11 +6475,6 @@
"integrity": "sha1-tm5Wqd8L0lp2u/G1FNsSkIBhSjc=",
"dev": true
},
- "whatwg-fetch": {
- "version": "2.0.4",
- "resolved": "https://registry.npmjs.org/whatwg-fetch/-/whatwg-fetch-2.0.4.tgz",
- "integrity": "sha512-dcQ1GWpOD/eEQ97k66aiEVpNnapVj90/+R+SXTPYGHpYBBypfKJEQjLrvMZ7YXbKm21gXd4NcuxUTjiv1YtLng=="
- },
"which": {
"version": "1.3.1",
"resolved": "https://registry.npmjs.org/which/-/which-1.3.1.tgz",
diff --git a/package.json b/package.json
index bebe1a5..0cb26bc 100644
--- a/package.json
+++ b/package.json
@@ -27,10 +27,9 @@
},
"homepage": "https://github.com/author/colouranxiety",
"dependencies": {
- "dev": "^0.1.3",
- "react-component-countdown-timer": "^0.1.1",
- "react-countdown-timer-component": "^1.0.2",
- "react-router-dom": "^5.0.0"
+ "react-component-countdown-timer": "^0.1.1"
+
+
},
"devDependencies": {
"@babel/core": "^7.4.3",
@@ -42,6 +41,8 @@
"gh-pages": "^0.11.0",
"react": "^16.8.6",
"react-dom": "^16.8.6",
+ "react-router": "^4.2.0",
+ "react-router-dom": "^4.2.2",
"tap-spec": "^4.1.1",
"tape": "^4.5.1",
"tinyify": "^2.5.0",