1
0

Compare commits

..

No commits in common. "e2f4a9ff1d10c519006390008428be2779f8d7e0" and "f8dfe65892bb77f36df7be765534dc8b90268fe5" have entirely different histories.

19 changed files with 116 additions and 254 deletions

View File

@ -1,7 +1,7 @@
{ {
"files": { "files": {
"main.css": "/static/css/main.97dfe1d2.css", "main.css": "/static/css/main.3c46fee2.css",
"main.js": "/static/js/main.17eef588.js", "main.js": "/static/js/main.e1d6cd96.js",
"static/js/787.0cfdad9c.chunk.js": "/static/js/787.0cfdad9c.chunk.js", "static/js/787.0cfdad9c.chunk.js": "/static/js/787.0cfdad9c.chunk.js",
"static/media/Roboto-ThinItalic-webfont.svg": "/static/media/Roboto-ThinItalic-webfont.e76f369acf2fa69edc40.svg", "static/media/Roboto-ThinItalic-webfont.svg": "/static/media/Roboto-ThinItalic-webfont.e76f369acf2fa69edc40.svg",
"static/media/Roboto-LightItalic-webfont.svg": "/static/media/Roboto-LightItalic-webfont.cc00b2543a4da739077c.svg", "static/media/Roboto-LightItalic-webfont.svg": "/static/media/Roboto-LightItalic-webfont.cc00b2543a4da739077c.svg",
@ -45,12 +45,12 @@
"static/media/Roboto-Thin-webfont.woff": "/static/media/Roboto-Thin-webfont.afab0292cf4cd806e344.woff", "static/media/Roboto-Thin-webfont.woff": "/static/media/Roboto-Thin-webfont.afab0292cf4cd806e344.woff",
"static/media/logo.svg": "/static/media/logo.6ce24c58023cc2f8fd88fe9d219db6c6.svg", "static/media/logo.svg": "/static/media/logo.6ce24c58023cc2f8fd88fe9d219db6c6.svg",
"index.html": "/index.html", "index.html": "/index.html",
"main.97dfe1d2.css.map": "/static/css/main.97dfe1d2.css.map", "main.3c46fee2.css.map": "/static/css/main.3c46fee2.css.map",
"main.17eef588.js.map": "/static/js/main.17eef588.js.map", "main.e1d6cd96.js.map": "/static/js/main.e1d6cd96.js.map",
"787.0cfdad9c.chunk.js.map": "/static/js/787.0cfdad9c.chunk.js.map" "787.0cfdad9c.chunk.js.map": "/static/js/787.0cfdad9c.chunk.js.map"
}, },
"entrypoints": [ "entrypoints": [
"static/css/main.97dfe1d2.css", "static/css/main.3c46fee2.css",
"static/js/main.17eef588.js" "static/js/main.e1d6cd96.js"
] ]
} }

Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

After

Width:  |  Height:  |  Size: 3.8 KiB

View File

@ -1 +1 @@
<!doctype html><html lang="en"><head><meta charset="utf-8"/><link rel="icon" href="/favicon.ico"/><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><meta name="description" content="Goodtimes"/><link rel="apple-touch-icon" href="/logo192.png"/><link rel="manifest" href="/manifest.json"/><title>Good Times</title><script defer="defer" src="/static/js/main.17eef588.js"></script><link href="/static/css/main.97dfe1d2.css" rel="stylesheet"></head><body><noscript>You need to enable JavaScript to run this app.</noscript><div id="root"></div></body></html> <!doctype html><html lang="en"><head><meta charset="utf-8"/><link rel="icon" href="/favicon.ico"/><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><meta name="description" content="Goodtimes"/><link rel="apple-touch-icon" href="/logo192.png"/><link rel="manifest" href="/manifest.json"/><title>Good Times</title><script defer="defer" src="/static/js/main.e1d6cd96.js"></script><link href="/static/css/main.3c46fee2.css" rel="stylesheet"></head><body><noscript>You need to enable JavaScript to run this app.</noscript><div id="root"></div></body></html>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.4 KiB

After

Width:  |  Height:  |  Size: 5.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.1 KiB

After

Width:  |  Height:  |  Size: 9.4 KiB

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -0,0 +1,65 @@
/*
object-assign
(c) Sindre Sorhus
@license MIT
*/
/** @license MUI v5.6.0
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/** @license React v0.20.2
* scheduler.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/** @license React v16.13.1
* react-is.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/** @license React v17.0.2
* react-dom.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/** @license React v17.0.2
* react-is.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/** @license React v17.0.2
* react-jsx-runtime.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/
/** @license React v17.0.2
* react.production.min.js
*
* Copyright (c) Facebook, Inc. and its affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*/

File diff suppressed because one or more lines are too long

126
client/package-lock.json generated
View File

@ -25,11 +25,10 @@
"moment-timezone": "^0.5.34", "moment-timezone": "^0.5.34",
"react": "^17.0.2", "react": "^17.0.2",
"react-dom": "^17.0.2", "react-dom": "^17.0.2",
"react-gravatar": "^2.6.3",
"react-moment": "^1.1.1", "react-moment": "^1.1.1",
"react-movable": "^3.0.4", "react-movable": "^3.0.4",
"react-moveable": "^0.31.1", "react-moveable": "^0.31.1",
"react-router-dom": "^6.3.0", "react-router-dom": "^6.2.1",
"react-scripts": "5.0.0", "react-scripts": "5.0.0",
"socket.io-client": "^4.4.1", "socket.io-client": "^4.4.1",
"typeface-roboto": "^1.1.13", "typeface-roboto": "^1.1.13",
@ -5738,14 +5737,6 @@
"node": ">=6" "node": ">=6"
} }
}, },
"node_modules/charenc": {
"version": "0.0.2",
"resolved": "https://registry.npmjs.org/charenc/-/charenc-0.0.2.tgz",
"integrity": "sha1-wKHS86cJLgN3S/qD8UwPxXkKhmc=",
"engines": {
"node": "*"
}
},
"node_modules/check-types": { "node_modules/check-types": {
"version": "11.1.2", "version": "11.1.2",
"resolved": "https://registry.npmjs.org/check-types/-/check-types-11.1.2.tgz", "resolved": "https://registry.npmjs.org/check-types/-/check-types-11.1.2.tgz",
@ -6122,14 +6113,6 @@
"node": ">= 8" "node": ">= 8"
} }
}, },
"node_modules/crypt": {
"version": "0.0.2",
"resolved": "https://registry.npmjs.org/crypt/-/crypt-0.0.2.tgz",
"integrity": "sha1-iNf/fsDfuG9xPch7u0LQRNPmxBs=",
"engines": {
"node": "*"
}
},
"node_modules/crypto-random-string": { "node_modules/crypto-random-string": {
"version": "2.0.0", "version": "2.0.0",
"resolved": "https://registry.npmjs.org/crypto-random-string/-/crypto-random-string-2.0.0.tgz", "resolved": "https://registry.npmjs.org/crypto-random-string/-/crypto-random-string-2.0.0.tgz",
@ -9164,11 +9147,6 @@
"url": "https://github.com/sponsors/ljharb" "url": "https://github.com/sponsors/ljharb"
} }
}, },
"node_modules/is-buffer": {
"version": "1.1.6",
"resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz",
"integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w=="
},
"node_modules/is-callable": { "node_modules/is-callable": {
"version": "1.2.4", "version": "1.2.4",
"resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.4.tgz", "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.4.tgz",
@ -9344,11 +9322,6 @@
"node": ">=0.10.0" "node": ">=0.10.0"
} }
}, },
"node_modules/is-retina": {
"version": "1.0.3",
"resolved": "https://registry.npmjs.org/is-retina/-/is-retina-1.0.3.tgz",
"integrity": "sha1-10AbKGvqKuN/Ykd1iN5QTQuGR+M="
},
"node_modules/is-root": { "node_modules/is-root": {
"version": "2.1.0", "version": "2.1.0",
"resolved": "https://registry.npmjs.org/is-root/-/is-root-2.1.0.tgz", "resolved": "https://registry.npmjs.org/is-root/-/is-root-2.1.0.tgz",
@ -11741,16 +11714,6 @@
"tmpl": "1.0.5" "tmpl": "1.0.5"
} }
}, },
"node_modules/md5": {
"version": "2.3.0",
"resolved": "https://registry.npmjs.org/md5/-/md5-2.3.0.tgz",
"integrity": "sha512-T1GITYmFaKuO91vxyoQMFETst+O71VUPEU3ze5GNzDm0OWdP8v1ziTaAEPUr/3kLsY3Sftgz242A1SetQiDL7g==",
"dependencies": {
"charenc": "0.0.2",
"crypt": "0.0.2",
"is-buffer": "~1.1.6"
}
},
"node_modules/mdn-data": { "node_modules/mdn-data": {
"version": "2.0.4", "version": "2.0.4",
"resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.4.tgz", "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.4.tgz",
@ -13869,18 +13832,6 @@
"url": "https://github.com/sponsors/ljharb" "url": "https://github.com/sponsors/ljharb"
} }
}, },
"node_modules/query-string": {
"version": "4.3.4",
"resolved": "https://registry.npmjs.org/query-string/-/query-string-4.3.4.tgz",
"integrity": "sha1-u7aTucqRXCMlFbIosaArYJBD2+s=",
"dependencies": {
"object-assign": "^4.1.0",
"strict-uri-encode": "^1.0.0"
},
"engines": {
"node": ">=0.10.0"
}
},
"node_modules/queue-microtask": { "node_modules/queue-microtask": {
"version": "1.2.3", "version": "1.2.3",
"resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz",
@ -14140,19 +14091,6 @@
"resolved": "https://registry.npmjs.org/react-error-overlay/-/react-error-overlay-6.0.10.tgz", "resolved": "https://registry.npmjs.org/react-error-overlay/-/react-error-overlay-6.0.10.tgz",
"integrity": "sha512-mKR90fX7Pm5seCOfz8q9F+66VCc1PGsWSBxKbITjfKVQHMNF2zudxHnMdJiB1fRCb+XsbQV9sO9DCkgsMQgBIA==" "integrity": "sha512-mKR90fX7Pm5seCOfz8q9F+66VCc1PGsWSBxKbITjfKVQHMNF2zudxHnMdJiB1fRCb+XsbQV9sO9DCkgsMQgBIA=="
}, },
"node_modules/react-gravatar": {
"version": "2.6.3",
"resolved": "https://registry.npmjs.org/react-gravatar/-/react-gravatar-2.6.3.tgz",
"integrity": "sha1-VAfrash+gw4qNN63YNKkxATrHaw=",
"dependencies": {
"is-retina": "^1.0.3",
"md5": "^2.1.0",
"query-string": "^4.2.2"
},
"peerDependencies": {
"react": "*"
}
},
"node_modules/react-is": { "node_modules/react-is": {
"version": "17.0.2", "version": "17.0.2",
"resolved": "https://registry.npmjs.org/react-is/-/react-is-17.0.2.tgz", "resolved": "https://registry.npmjs.org/react-is/-/react-is-17.0.2.tgz",
@ -15214,14 +15152,6 @@
"node": ">= 0.6" "node": ">= 0.6"
} }
}, },
"node_modules/strict-uri-encode": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/strict-uri-encode/-/strict-uri-encode-1.1.0.tgz",
"integrity": "sha1-J5siXfHVgrH1TmWt3UNS4Y+qBxM=",
"engines": {
"node": ">=0.10.0"
}
},
"node_modules/string_decoder": { "node_modules/string_decoder": {
"version": "1.3.0", "version": "1.3.0",
"resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz",
@ -21116,11 +21046,6 @@
"resolved": "https://registry.npmjs.org/charcodes/-/charcodes-0.2.0.tgz", "resolved": "https://registry.npmjs.org/charcodes/-/charcodes-0.2.0.tgz",
"integrity": "sha512-Y4kiDb+AM4Ecy58YkuZrrSRJBDQdQ2L+NyS1vHHFtNtUjgutcZfx3yp1dAONI/oPaPmyGfCLx5CxL+zauIMyKQ==" "integrity": "sha512-Y4kiDb+AM4Ecy58YkuZrrSRJBDQdQ2L+NyS1vHHFtNtUjgutcZfx3yp1dAONI/oPaPmyGfCLx5CxL+zauIMyKQ=="
}, },
"charenc": {
"version": "0.0.2",
"resolved": "https://registry.npmjs.org/charenc/-/charenc-0.0.2.tgz",
"integrity": "sha1-wKHS86cJLgN3S/qD8UwPxXkKhmc="
},
"check-types": { "check-types": {
"version": "11.1.2", "version": "11.1.2",
"resolved": "https://registry.npmjs.org/check-types/-/check-types-11.1.2.tgz", "resolved": "https://registry.npmjs.org/check-types/-/check-types-11.1.2.tgz",
@ -21410,11 +21335,6 @@
"which": "^2.0.1" "which": "^2.0.1"
} }
}, },
"crypt": {
"version": "0.0.2",
"resolved": "https://registry.npmjs.org/crypt/-/crypt-0.0.2.tgz",
"integrity": "sha1-iNf/fsDfuG9xPch7u0LQRNPmxBs="
},
"crypto-random-string": { "crypto-random-string": {
"version": "2.0.0", "version": "2.0.0",
"resolved": "https://registry.npmjs.org/crypto-random-string/-/crypto-random-string-2.0.0.tgz", "resolved": "https://registry.npmjs.org/crypto-random-string/-/crypto-random-string-2.0.0.tgz",
@ -23614,11 +23534,6 @@
"has-tostringtag": "^1.0.0" "has-tostringtag": "^1.0.0"
} }
}, },
"is-buffer": {
"version": "1.1.6",
"resolved": "https://registry.npmjs.org/is-buffer/-/is-buffer-1.1.6.tgz",
"integrity": "sha512-NcdALwpXkTm5Zvvbk7owOUSvVvBKDgKP5/ewfXEznmQFfs4ZRmanOeKBTjRVjka3QFoN6XJ+9F3USqfHqTaU5w=="
},
"is-callable": { "is-callable": {
"version": "1.2.4", "version": "1.2.4",
"resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.4.tgz", "resolved": "https://registry.npmjs.org/is-callable/-/is-callable-1.2.4.tgz",
@ -23725,11 +23640,6 @@
"resolved": "https://registry.npmjs.org/is-regexp/-/is-regexp-1.0.0.tgz", "resolved": "https://registry.npmjs.org/is-regexp/-/is-regexp-1.0.0.tgz",
"integrity": "sha1-/S2INUXEa6xaYz57mgnof6LLUGk=" "integrity": "sha1-/S2INUXEa6xaYz57mgnof6LLUGk="
}, },
"is-retina": {
"version": "1.0.3",
"resolved": "https://registry.npmjs.org/is-retina/-/is-retina-1.0.3.tgz",
"integrity": "sha1-10AbKGvqKuN/Ykd1iN5QTQuGR+M="
},
"is-root": { "is-root": {
"version": "2.1.0", "version": "2.1.0",
"resolved": "https://registry.npmjs.org/is-root/-/is-root-2.1.0.tgz", "resolved": "https://registry.npmjs.org/is-root/-/is-root-2.1.0.tgz",
@ -25492,16 +25402,6 @@
"tmpl": "1.0.5" "tmpl": "1.0.5"
} }
}, },
"md5": {
"version": "2.3.0",
"resolved": "https://registry.npmjs.org/md5/-/md5-2.3.0.tgz",
"integrity": "sha512-T1GITYmFaKuO91vxyoQMFETst+O71VUPEU3ze5GNzDm0OWdP8v1ziTaAEPUr/3kLsY3Sftgz242A1SetQiDL7g==",
"requires": {
"charenc": "0.0.2",
"crypt": "0.0.2",
"is-buffer": "~1.1.6"
}
},
"mdn-data": { "mdn-data": {
"version": "2.0.4", "version": "2.0.4",
"resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.4.tgz", "resolved": "https://registry.npmjs.org/mdn-data/-/mdn-data-2.0.4.tgz",
@ -26895,15 +26795,6 @@
"resolved": "https://registry.npmjs.org/qs/-/qs-6.9.7.tgz", "resolved": "https://registry.npmjs.org/qs/-/qs-6.9.7.tgz",
"integrity": "sha512-IhMFgUmuNpyRfxA90umL7ByLlgRXu6tIfKPpF5TmcfRLlLCckfP/g3IQmju6jjpu+Hh8rA+2p6A27ZSPOOHdKw==" "integrity": "sha512-IhMFgUmuNpyRfxA90umL7ByLlgRXu6tIfKPpF5TmcfRLlLCckfP/g3IQmju6jjpu+Hh8rA+2p6A27ZSPOOHdKw=="
}, },
"query-string": {
"version": "4.3.4",
"resolved": "https://registry.npmjs.org/query-string/-/query-string-4.3.4.tgz",
"integrity": "sha1-u7aTucqRXCMlFbIosaArYJBD2+s=",
"requires": {
"object-assign": "^4.1.0",
"strict-uri-encode": "^1.0.0"
}
},
"queue-microtask": { "queue-microtask": {
"version": "1.2.3", "version": "1.2.3",
"resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz",
@ -27093,16 +26984,6 @@
"resolved": "https://registry.npmjs.org/react-error-overlay/-/react-error-overlay-6.0.10.tgz", "resolved": "https://registry.npmjs.org/react-error-overlay/-/react-error-overlay-6.0.10.tgz",
"integrity": "sha512-mKR90fX7Pm5seCOfz8q9F+66VCc1PGsWSBxKbITjfKVQHMNF2zudxHnMdJiB1fRCb+XsbQV9sO9DCkgsMQgBIA==" "integrity": "sha512-mKR90fX7Pm5seCOfz8q9F+66VCc1PGsWSBxKbITjfKVQHMNF2zudxHnMdJiB1fRCb+XsbQV9sO9DCkgsMQgBIA=="
}, },
"react-gravatar": {
"version": "2.6.3",
"resolved": "https://registry.npmjs.org/react-gravatar/-/react-gravatar-2.6.3.tgz",
"integrity": "sha1-VAfrash+gw4qNN63YNKkxATrHaw=",
"requires": {
"is-retina": "^1.0.3",
"md5": "^2.1.0",
"query-string": "^4.2.2"
}
},
"react-is": { "react-is": {
"version": "17.0.2", "version": "17.0.2",
"resolved": "https://registry.npmjs.org/react-is/-/react-is-17.0.2.tgz", "resolved": "https://registry.npmjs.org/react-is/-/react-is-17.0.2.tgz",
@ -27902,11 +27783,6 @@
"resolved": "https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz", "resolved": "https://registry.npmjs.org/statuses/-/statuses-1.5.0.tgz",
"integrity": "sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow=" "integrity": "sha1-Fhx9rBd2Wf2YEfQ3cfqZOBR4Yow="
}, },
"strict-uri-encode": {
"version": "1.1.0",
"resolved": "https://registry.npmjs.org/strict-uri-encode/-/strict-uri-encode-1.1.0.tgz",
"integrity": "sha1-J5siXfHVgrH1TmWt3UNS4Y+qBxM="
},
"string_decoder": { "string_decoder": {
"version": "1.3.0", "version": "1.3.0",
"resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz", "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.3.0.tgz",

View File

@ -21,11 +21,10 @@
"moment-timezone": "^0.5.34", "moment-timezone": "^0.5.34",
"react": "^17.0.2", "react": "^17.0.2",
"react-dom": "^17.0.2", "react-dom": "^17.0.2",
"react-gravatar": "^2.6.3",
"react-moment": "^1.1.1", "react-moment": "^1.1.1",
"react-movable": "^3.0.4", "react-movable": "^3.0.4",
"react-moveable": "^0.31.1", "react-moveable": "^0.31.1",
"react-router-dom": "^6.3.0", "react-router-dom": "^6.2.1",
"react-scripts": "5.0.0", "react-scripts": "5.0.0",
"socket.io-client": "^4.4.1", "socket.io-client": "^4.4.1",
"typeface-roboto": "^1.1.13", "typeface-roboto": "^1.1.13",

Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

After

Width:  |  Height:  |  Size: 3.8 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.4 KiB

After

Width:  |  Height:  |  Size: 5.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.1 KiB

After

Width:  |  Height:  |  Size: 9.4 KiB

View File

@ -36,11 +36,3 @@
transform: rotate(360deg); transform: rotate(360deg);
} }
} }
.App .Content > .MuiPaper-root {
display: flex;
margin-top: 1rem;
padding: 0.5rem;
justify-content: stretch;
align-self: stretch;
}

View File

@ -1,52 +1,13 @@
import logo from './logo.svg'; import logo from './logo.svg';
import React, { useState } from "react";
import {
BrowserRouter,
Routes,
Route,
} from "react-router-dom";
import './App.css'; import './App.css';
import './fonts/index.css'; import './fonts/index.css';
import { GoodTimesBar } from "./GoodTimesBar.js"; import { GoodTimesBar } from "./GoodTimesBar.js";
import { GlobalContext } from "./GlobalContext.js";
import Container from '@mui/material/Container';
import Paper from '@mui/material/Paper';
import SignIn from "./SignIn.js";
import SignUp from "./SignUp.js";
function App() { function App() {
const [ user, setUser ] = useState(null);
console.log(user);
return ( return (
<div className="App"> <div className="App">
<GlobalContext.Provider value={{user, setUser}}> <GoodTimesBar />
<GoodTimesBar /> <div>Coming soon...</div>
<Container className="Content">
<Routes>
<Route path="/signin" element={<SignIn />}/>
<Route path="/signup" element={<SignUp />}/>
<Route path="/password" element={
<Paper>Not implemented... yet.</Paper>
}/>
<Route path="/" element={
<Paper style={{
flexDirection: 'column',
display: 'flex'
}}>
<div style={{ fontWeight: 'bold' }}>Goodtimes</div>
<div>The eventual new site for the legacy Beer Tuesday... coming soon...
</div>
{ user && <div>
Logged in as {user.email}
</div> }
</Paper>
}/>
</Routes>
</Container>
</GlobalContext.Provider>
</div> </div>
); );
} }

View File

@ -1,4 +1,4 @@
import React, { useContext, useEffect, useState } from 'react'; import * as React from 'react';
import AppBar from '@mui/material/AppBar'; import AppBar from '@mui/material/AppBar';
import Box from '@mui/material/Box'; import Box from '@mui/material/Box';
import Toolbar from '@mui/material/Toolbar'; import Toolbar from '@mui/material/Toolbar';
@ -7,43 +7,14 @@ import Typography from '@mui/material/Typography';
import Menu from '@mui/material/Menu'; import Menu from '@mui/material/Menu';
import MenuIcon from '@mui/icons-material/Menu'; import MenuIcon from '@mui/icons-material/Menu';
import Container from '@mui/material/Container'; import Container from '@mui/material/Container';
import Avatar from '@mui/material/Avatar';
import Button from '@mui/material/Button'; import Button from '@mui/material/Button';
import Tooltip from '@mui/material/Tooltip'; import Tooltip from '@mui/material/Tooltip';
import MenuItem from '@mui/material/MenuItem'; import MenuItem from '@mui/material/MenuItem';
import { Link } from 'react-router-dom';
import {
useParams,
useNavigate,
useLocation,
} from "react-router-dom";
import Gravatar from 'react-gravatar' const settings = ['Profile', 'Account', 'Dashboard', 'Logout'];
import { GlobalContext } from "./GlobalContext.js";
const GoodTimesBar = () => { const GoodTimesBar = () => {
const { user } = useContext(GlobalContext);
const [ settings, setSettings ] = useState([]);
const navigate = useNavigate();
useEffect(() => {
if (user) {
setSettings(['Profile', 'Account', 'Dashboard', 'Logout']
.map((setting) => (
<MenuItem key={setting} onClick={handleCloseUserMenu}>
<Typography textAlign="center">{setting}</Typography>
</MenuItem>
)));
} else {
setSettings(['Login']
.map((setting) => (
<MenuItem key={setting} onClick={handleCloseUserMenu}>
<Typography textAlign="center">{setting}</Typography>
</MenuItem>
)));
}
}, [user, setSettings]);
const [anchorElNav, setAnchorElNav] = React.useState(null); const [anchorElNav, setAnchorElNav] = React.useState(null);
const [anchorElUser, setAnchorElUser] = React.useState(null); const [anchorElUser, setAnchorElUser] = React.useState(null);
@ -112,45 +83,39 @@ const GoodTimesBar = () => {
component="div" component="div"
sx={{ flexGrow: 1, display: { xs: 'flex', md: 'none' } }} sx={{ flexGrow: 1, display: { xs: 'flex', md: 'none' } }}
> >
GOODTIMES LOGO
</Typography> </Typography>
<Box sx={{ flexGrow: 1, display: { xs: 'none', md: 'flex' } }}> <Box sx={{ flexGrow: 1, display: { xs: 'none', md: 'flex' } }}>
</Box> </Box>
<Box sx={{ flexGrow: 0 }}> <Box sx={{ flexGrow: 0 }}>
{ !user && <> <Tooltip title="Open settings">
<Tooltip title="Login"> <IconButton onClick={handleOpenUserMenu} sx={{ p: 0 }}>
<Button onClick={() => navigate("/signin")} color="inherit"> <Avatar alt="Remy Sharp" src="/static/images/avatar/2.jpg" />
Login </IconButton>
</Button> </Tooltip>
</Tooltip> <Menu
</> sx={{ mt: '45px' }}
} id="menu-appbar"
{ user && <> anchorEl={anchorElUser}
<Tooltip title="Open settings"> anchorOrigin={{
<IconButton onClick={handleOpenUserMenu} sx={{ p: 0 }}> vertical: 'top',
<Gravatar alt={user.name} md5={user.md5}/> horizontal: 'right',
</IconButton> }}
</Tooltip> keepMounted
<Menu transformOrigin={{
sx={{ mt: '45px' }} vertical: 'top',
id="menu-appbar" horizontal: 'right',
anchorEl={anchorElUser} }}
anchorOrigin={{ open={Boolean(anchorElUser)}
vertical: 'top', onClose={handleCloseUserMenu}
horizontal: 'right', >
}} {settings.map((setting) => (
keepMounted <MenuItem key={setting} onClick={handleCloseUserMenu}>
transformOrigin={{ <Typography textAlign="center">{setting}</Typography>
vertical: 'top', </MenuItem>
horizontal: 'right', ))}
}} </Menu>
open={Boolean(anchorElUser)}
onClose={handleCloseUserMenu}
>
{settings}
</Menu>
</>}
</Box> </Box>
</Toolbar> </Toolbar>
</Container> </Container>

View File

@ -3,18 +3,15 @@ import ReactDOM from 'react-dom';
import './index.css'; import './index.css';
import App from './App'; import App from './App';
import reportWebVitals from './reportWebVitals'; import reportWebVitals from './reportWebVitals';
import { BrowserRouter } from "react-router-dom";
ReactDOM.render( ReactDOM.render(
<BrowserRouter>
<React.StrictMode> <React.StrictMode>
<App /> <App />
</React.StrictMode> </React.StrictMode>,
</BrowserRouter>,
document.getElementById('root') document.getElementById('root')
); );
// If you want to start measuring performance in your app, pass a function // If you want to start measuring performance in your app, pass a function
// to log results (for example: reportWebVitals(console.log)) // to log results (for example: reportWebVitals(console.log))
// or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals // or send to an analytics endpoint. Learn more: https://bit.ly/CRA-vitals
reportWebVitals(console.log); reportWebVitals();