From ea59db58d3fee698279c583389b40ccebef8f31c Mon Sep 17 00:00:00 2001 From: Maya Herrscher Date: Tue, 26 Apr 2022 15:55:54 +0200 Subject: [PATCH] Do todos --- package-lock.json | 52 +++++++++ package.json | 2 + public/index.html | 6 +- src/App.tsx | 209 ++++++++-------------------------- src/components/Todos.tsx | 183 +++++++++++++++++++++++++++++ src/hooks/useLocalStorage.tsx | 15 +++ 6 files changed, 302 insertions(+), 165 deletions(-) create mode 100644 src/components/Todos.tsx create mode 100644 src/hooks/useLocalStorage.tsx diff --git a/package-lock.json b/package-lock.json index 51bf65a..5dc443f 100644 --- a/package-lock.json +++ b/package-lock.json @@ -11,6 +11,7 @@ "@date-io/dayjs": "^2.13.1", "@emotion/react": "^11.9.0", "@emotion/styled": "^11.8.1", + "@mui/icons-material": "^5.6.2", "@mui/material": "^5.6.2", "@mui/x-date-pickers": "^5.0.0-alpha.1", "@testing-library/jest-dom": "^5.16.4", @@ -20,6 +21,7 @@ "@types/node": "^16.11.27", "@types/react": "^18.0.6", "@types/react-dom": "^18.0.2", + "date-fns": "^2.28.0", "dayjs": "^1.11.1", "react": "^18.0.0", "react-dom": "^18.0.0", @@ -3049,6 +3051,31 @@ "resolved": "https://registry.npmjs.org/react-is/-/react-is-17.0.2.tgz", "integrity": "sha512-w2GsyukL62IJnlaff/nRegPQR94C/XXamvMWmSHRJ4y7Ts/4ocGRmTHvOs8PSE6pB3dWOrD/nueuU5sduBsQ4w==" }, + "node_modules/@mui/icons-material": { + "version": "5.6.2", + "resolved": "https://registry.npmjs.org/@mui/icons-material/-/icons-material-5.6.2.tgz", + "integrity": "sha512-9QdI7axKuBAyaGz4mtdi7Uy1j73/thqFmEuxpJHxNC7O8ADEK1Da3t2veK2tgmsXsUlAHcAG63gg+GvWWeQNqQ==", + "dependencies": { + "@babel/runtime": "^7.17.2" + }, + "engines": { + "node": ">=12.0.0" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/mui" + }, + "peerDependencies": { + "@mui/material": "^5.0.0", + "@types/react": "^17.0.0 || ^18.0.0", + "react": "^17.0.0 || ^18.0.0" + }, + "peerDependenciesMeta": { + "@types/react": { + "optional": true + } + } + }, "node_modules/@mui/material": { "version": "5.6.2", "resolved": "https://registry.npmjs.org/@mui/material/-/material-5.6.2.tgz", @@ -6410,6 +6437,18 @@ "node": ">=10" } }, + "node_modules/date-fns": { + "version": "2.28.0", + "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-2.28.0.tgz", + "integrity": "sha512-8d35hViGYx/QH0icHYCeLmsLmMUheMmTyV9Fcm6gvNwdw31yXXH+O85sOBJ+OLnLQMKZowvpKb6FgMIQjcpvQw==", + "engines": { + "node": ">=0.11" + }, + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/date-fns" + } + }, "node_modules/dayjs": { "version": "1.11.1", "resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.11.1.tgz", @@ -18733,6 +18772,14 @@ } } }, + "@mui/icons-material": { + "version": "5.6.2", + "resolved": "https://registry.npmjs.org/@mui/icons-material/-/icons-material-5.6.2.tgz", + "integrity": "sha512-9QdI7axKuBAyaGz4mtdi7Uy1j73/thqFmEuxpJHxNC7O8ADEK1Da3t2veK2tgmsXsUlAHcAG63gg+GvWWeQNqQ==", + "requires": { + "@babel/runtime": "^7.17.2" + } + }, "@mui/material": { "version": "5.6.2", "resolved": "https://registry.npmjs.org/@mui/material/-/material-5.6.2.tgz", @@ -21132,6 +21179,11 @@ "whatwg-url": "^8.0.0" } }, + "date-fns": { + "version": "2.28.0", + "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-2.28.0.tgz", + "integrity": "sha512-8d35hViGYx/QH0icHYCeLmsLmMUheMmTyV9Fcm6gvNwdw31yXXH+O85sOBJ+OLnLQMKZowvpKb6FgMIQjcpvQw==" + }, "dayjs": { "version": "1.11.1", "resolved": "https://registry.npmjs.org/dayjs/-/dayjs-1.11.1.tgz", diff --git a/package.json b/package.json index 98aaac0..8599a73 100644 --- a/package.json +++ b/package.json @@ -6,6 +6,7 @@ "@date-io/dayjs": "^2.13.1", "@emotion/react": "^11.9.0", "@emotion/styled": "^11.8.1", + "@mui/icons-material": "^5.6.2", "@mui/material": "^5.6.2", "@mui/x-date-pickers": "^5.0.0-alpha.1", "@testing-library/jest-dom": "^5.16.4", @@ -15,6 +16,7 @@ "@types/node": "^16.11.27", "@types/react": "^18.0.6", "@types/react-dom": "^18.0.2", + "date-fns": "^2.28.0", "dayjs": "^1.11.1", "react": "^18.0.0", "react-dom": "^18.0.0", diff --git a/public/index.html b/public/index.html index aa069f2..e3e70e1 100644 --- a/public/index.html +++ b/public/index.html @@ -1,5 +1,5 @@ - + @@ -26,9 +26,9 @@ --> React App - + -
+