From 9e242ddf5d81a7a20e22cc4addca023205ccc379 Mon Sep 17 00:00:00 2001 From: MaxOvs19 Date: Wed, 31 May 2023 11:24:46 +0300 Subject: [PATCH] Added eslint --- .eslintrc.json | 21 + package-lock.json | 606 ++++-------------- package.json | 5 +- .../Common/AuthHeader/AuthHeader.jsx | 2 +- src/components/Description/Description.jsx | 2 +- src/components/Form/Form.jsx | 2 + .../FreeDevelopers/FreeDevelopers.jsx | 2 +- .../Modal/Tracker/ModalTicket/ModalTicket.jsx | 12 +- .../TicketFullScreen/TicketFullScreen.jsx | 12 +- .../Modal/TrackerModal/TrackerModal.jsx | 8 +- .../ProfileCalendarComponent.jsx | 1 + src/components/ProjectTiket/ProjectTiket.jsx | 2 +- .../ProtectedRoute/ProtectedRoute.js | 3 +- src/components/ReportForm/ReportForm.jsx | 2 +- src/components/ShortReport/ShortReport.jsx | 2 +- .../quiz/{AlertResult.js => AlertResult.jsx} | 0 ...ompletedTest.js => BlockCompletedTest.jsx} | 0 ...-introduction.js => Card-introduction.jsx} | 0 ...CardAviableTest.js => CardAviableTest.jsx} | 0 .../{GetOptionTask.js => GetOptionTask.jsx} | 6 - ...HeaderPageTests.js => HeaderPageTests.jsx} | 0 .../quiz/{HeaderQuiz.js => HeaderQuiz.jsx} | 3 +- .../{Instructions.js => Instructions.jsx} | 0 .../quiz/{MyTestsQuiz.js => MyTestsQuiz.jsx} | 0 ...ProgressbarQuiz.js => ProgressbarQuiz.jsx} | 0 ...mation.js => Quiz-passing-information.jsx} | 15 +- .../quiz/{QuizReport.js => QuizReport.jsx} | 0 .../features/quiz/{Results.js => Results.jsx} | 0 ...lectedCategory.js => SelectedCategory.jsx} | 0 src/components/features/quiz/Task.js | 15 +- src/pages/Article/Article.jsx | 2 +- src/pages/Blog/Blog.jsx | 2 +- .../FrequentlyAskedQuestion.jsx | 2 +- .../PartnerAddRequest/PartnerAddRequest.js | 6 +- src/pages/PartnerBid/PartnerBid.jsx | 2 +- src/pages/ProjectTracker/ProjectTracker.js | 10 +- .../SingleReportPage/SingleReportPage.js | 4 +- src/pages/quiz/PassingTests.js | 7 +- src/redux/projectsTrackerSlice.js | 2 +- src/redux/quizSlice.js | 2 +- 40 files changed, 224 insertions(+), 536 deletions(-) create mode 100644 .eslintrc.json rename src/components/features/quiz/{AlertResult.js => AlertResult.jsx} (100%) rename src/components/features/quiz/{BlockCompletedTest.js => BlockCompletedTest.jsx} (100%) rename src/components/features/quiz/{Card-introduction.js => Card-introduction.jsx} (100%) rename src/components/features/quiz/{CardAviableTest.js => CardAviableTest.jsx} (100%) rename src/components/features/quiz/{GetOptionTask.js => GetOptionTask.jsx} (86%) rename src/components/features/quiz/{HeaderPageTests.js => HeaderPageTests.jsx} (100%) rename src/components/features/quiz/{HeaderQuiz.js => HeaderQuiz.jsx} (97%) rename src/components/features/quiz/{Instructions.js => Instructions.jsx} (100%) rename src/components/features/quiz/{MyTestsQuiz.js => MyTestsQuiz.jsx} (100%) rename src/components/features/quiz/{ProgressbarQuiz.js => ProgressbarQuiz.jsx} (100%) rename src/components/features/quiz/{Quiz-passing-information.js => Quiz-passing-information.jsx} (93%) rename src/components/features/quiz/{QuizReport.js => QuizReport.jsx} (100%) rename src/components/features/quiz/{Results.js => Results.jsx} (100%) rename src/components/features/quiz/{SelectedCategory.js => SelectedCategory.jsx} (100%) diff --git a/.eslintrc.json b/.eslintrc.json new file mode 100644 index 00000000..df60b6dd --- /dev/null +++ b/.eslintrc.json @@ -0,0 +1,21 @@ +{ + "env": { + "browser": true, + "es2021": true + }, + "extends": ["eslint:recommended", "plugin:react/recommended"], + "overrides": [], + "parserOptions": { + "ecmaVersion": "latest", + "sourceType": "module" + }, + "plugins": ["react"], + "rules": { + "no-console": "warn", + "react/prop-types": 0, + "no-undef": "warn", + "react/no-unescaped-entities": 0, + "no-extra-boolean-cast": "warn", + "react/react-in-jsx-scope": 0 + } +} diff --git a/package-lock.json b/package-lock.json index 1565b33d..b968f79e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -59,6 +59,8 @@ "cross-env": "^7.0.3", "css-loader": "6.7.3", "dotenv-webpack": "^7.0.3", + "eslint": "^8.41.0", + "eslint-plugin-react": "^7.32.2", "html-webpack-plugin": "5.5.0", "mini-css-extract-plugin": "^2.7.2", "node-sass": "8.0.0", @@ -2469,7 +2471,6 @@ "version": "4.4.0", "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.4.0.tgz", "integrity": "sha512-1/sA4dwrzBAyeUoQ6oxahHKmrZvsnLCg4RfxW3ZFGGmQkSNQPFNLV9CUEFQP1x9EYXHTo5p6xdhZM1Ne9p/AfA==", - "dev": true, "dependencies": { "eslint-visitor-keys": "^3.3.0" }, @@ -2484,7 +2485,6 @@ "version": "3.4.1", "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.1.tgz", "integrity": "sha512-pZnmmLwYzf+kWaM/Qgrvpen51upAktaaiI01nsJD/Yr3lMOdNtq0cxkrrg16w64VtisN6okbs7Q8AfGqj4c9fA==", - "dev": true, "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" }, @@ -2496,36 +2496,41 @@ "version": "4.5.1", "resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.5.1.tgz", "integrity": "sha512-Z5ba73P98O1KUYCCJTUeVpja9RcGoMdncZ6T49FCUl2lN38JtCJ+3WgIDBv0AuY4WChU5PmtJmOCTlN6FZTFKQ==", - "dev": true, "engines": { "node": "^12.0.0 || ^14.0.0 || >=16.0.0" } }, "node_modules/@eslint/eslintrc": { - "version": "0.4.3", - "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-0.4.3.tgz", - "integrity": "sha512-J6KFFz5QCYUJq3pf0mjEcCJVERbzv71PUIDczuh9JkwGEzced6CO5ADLHB1rbf/+oPBtoPfMYNOpGDzCANlbXw==", - "peer": true, + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-2.0.3.tgz", + "integrity": "sha512-+5gy6OQfk+xx3q0d6jGZZC3f3KzAkXc/IanVxd1is/VIIziRqqt3ongQz0FiTUXqTk0c7aDB3OaFuKnuSoJicQ==", "dependencies": { "ajv": "^6.12.4", - "debug": "^4.1.1", - "espree": "^7.3.0", - "globals": "^13.9.0", - "ignore": "^4.0.6", + "debug": "^4.3.2", + "espree": "^9.5.2", + "globals": "^13.19.0", + "ignore": "^5.2.0", "import-fresh": "^3.2.1", - "js-yaml": "^3.13.1", - "minimatch": "^3.0.4", + "js-yaml": "^4.1.0", + "minimatch": "^3.1.2", "strip-json-comments": "^3.1.1" }, "engines": { - "node": "^10.12.0 || >=12.0.0" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" } }, + "node_modules/@eslint/eslintrc/node_modules/argparse": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", + "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==" + }, "node_modules/@eslint/eslintrc/node_modules/globals": { "version": "13.20.0", "resolved": "https://registry.npmjs.org/globals/-/globals-13.20.0.tgz", "integrity": "sha512-Qg5QtVkCy/kv3FUSlu4ukeZDVf9ee0iXLAUYX13gbR17bnejFTzr4iS9bY7kwCf1NztRNm1t91fjOiyx4CSwPQ==", - "peer": true, "dependencies": { "type-fest": "^0.20.2" }, @@ -2536,20 +2541,21 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/@eslint/eslintrc/node_modules/ignore": { - "version": "4.0.6", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-4.0.6.tgz", - "integrity": "sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg==", - "peer": true, - "engines": { - "node": ">= 4" + "node_modules/@eslint/eslintrc/node_modules/js-yaml": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", + "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", + "dependencies": { + "argparse": "^2.0.1" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" } }, "node_modules/@eslint/eslintrc/node_modules/type-fest": { "version": "0.20.2", "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", - "peer": true, "engines": { "node": ">=10" }, @@ -2561,7 +2567,6 @@ "version": "8.41.0", "resolved": "https://registry.npmjs.org/@eslint/js/-/js-8.41.0.tgz", "integrity": "sha512-LxcyMGxwmTh2lY9FwHPGWOHmYFCZvbrFCBZL4FzSSsxsRPuhrYUg/49/0KDfW8tnIEaEHtfmn6+NPN+1DqaNmA==", - "dev": true, "engines": { "node": "^12.22.0 || ^14.17.0 || >=16.0.0" } @@ -2586,14 +2591,13 @@ "dev": true }, "node_modules/@humanwhocodes/config-array": { - "version": "0.5.0", - "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.5.0.tgz", - "integrity": "sha512-FagtKFz74XrTl7y6HCzQpwDfXP0yhxe9lHLD1UZxjvZIcbyRz8zTFF/yYNfSfzU414eDwZ1SrO0Qvtyf+wFMQg==", - "peer": true, + "version": "0.11.8", + "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.8.tgz", + "integrity": "sha512-UybHIJzJnR5Qc/MsD9Kr+RpO2h+/P1GhOwdiLPXK5TWk5sgTdu88bTD9UP+CKbPPh5Rni1u0GjAdYQLemG8g+g==", "dependencies": { - "@humanwhocodes/object-schema": "^1.2.0", + "@humanwhocodes/object-schema": "^1.2.1", "debug": "^4.1.1", - "minimatch": "^3.0.4" + "minimatch": "^3.0.5" }, "engines": { "node": ">=10.10.0" @@ -2603,7 +2607,6 @@ "version": "1.0.1", "resolved": "https://registry.npmjs.org/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz", "integrity": "sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==", - "dev": true, "engines": { "node": ">=12.22" }, @@ -6436,15 +6439,6 @@ "ajv": "^6.9.1" } }, - "node_modules/ansi-colors": { - "version": "4.1.3", - "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-4.1.3.tgz", - "integrity": "sha512-/6w/C21Pm1A7aZitlI5Ni/2J6FFQN8i1Cvz3kHABAAbw93v/NlvKdVOqz7CCWz/3iv/JplRSEEZ83XION15ovw==", - "peer": true, - "engines": { - "node": ">=6" - } - }, "node_modules/ansi-escapes": { "version": "4.3.2", "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-4.3.2.tgz", @@ -6544,6 +6538,7 @@ "version": "1.0.10", "resolved": "https://registry.npmjs.org/argparse/-/argparse-1.0.10.tgz", "integrity": "sha512-o5Roy6tNG4SL/FOkCAN6RzjiakZS25RLYFrcMttJqbdd8BWrnA+fGz57iN5Pb06pvBGvl5gQ0B48dJlslXvoTg==", + "dev": true, "dependencies": { "sprintf-js": "~1.0.2" } @@ -6718,15 +6713,6 @@ "integrity": "sha512-eBvWn1lvIApYMhzQMsu9ciLfkBY499mFZlNqG+/9WR7PVlroQw0vG30cOQQbaKz3sCEc44TAOu2ykzqXSNnwag==", "dev": true }, - "node_modules/astral-regex": { - "version": "2.0.0", - "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-2.0.0.tgz", - "integrity": "sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ==", - "peer": true, - "engines": { - "node": ">=8" - } - }, "node_modules/async": { "version": "3.2.4", "resolved": "https://registry.npmjs.org/async/-/async-3.2.4.tgz", @@ -9441,18 +9427,6 @@ "resolved": "https://registry.npmjs.org/enquire.js/-/enquire.js-2.1.6.tgz", "integrity": "sha512-/KujNpO+PT63F7Hlpu4h3pE3TokKRHN26JYmQpPyjkRD/N57R7bPDNojMXdi7uveAKjYB7yQnartCxZnFWr0Xw==" }, - "node_modules/enquirer": { - "version": "2.3.6", - "resolved": "https://registry.npmjs.org/enquirer/-/enquirer-2.3.6.tgz", - "integrity": "sha512-yjNnPr315/FjS4zIsUxYguYUPP2e1NK4d7E7ZOLiyYCcbFBiTMyID+2wvm2w6+pZ/odMA7cRkjhsPbltwBOrLg==", - "peer": true, - "dependencies": { - "ansi-colors": "^4.1.1" - }, - "engines": { - "node": ">=8.6" - } - }, "node_modules/entities": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/entities/-/entities-2.2.0.tgz", @@ -9758,57 +9732,55 @@ } }, "node_modules/eslint": { - "version": "7.32.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-7.32.0.tgz", - "integrity": "sha512-VHZ8gX+EDfz+97jGcgyGCyRia/dPOd6Xh9yPv8Bl1+SoaIwD+a/vlrOmGRUyOYu7MwUhc7CxqeaDZU13S4+EpA==", - "peer": true, + "version": "8.41.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.41.0.tgz", + "integrity": "sha512-WQDQpzGBOP5IrXPo4Hc0814r4/v2rrIsB0rhT7jtunIalgg6gYXWhRMOejVO8yH21T/FGaxjmFjBMNqcIlmH1Q==", "dependencies": { - "@babel/code-frame": "7.12.11", - "@eslint/eslintrc": "^0.4.3", - "@humanwhocodes/config-array": "^0.5.0", + "@eslint-community/eslint-utils": "^4.2.0", + "@eslint-community/regexpp": "^4.4.0", + "@eslint/eslintrc": "^2.0.3", + "@eslint/js": "8.41.0", + "@humanwhocodes/config-array": "^0.11.8", + "@humanwhocodes/module-importer": "^1.0.1", + "@nodelib/fs.walk": "^1.2.8", "ajv": "^6.10.0", "chalk": "^4.0.0", "cross-spawn": "^7.0.2", - "debug": "^4.0.1", + "debug": "^4.3.2", "doctrine": "^3.0.0", - "enquirer": "^2.3.5", "escape-string-regexp": "^4.0.0", - "eslint-scope": "^5.1.1", - "eslint-utils": "^2.1.0", - "eslint-visitor-keys": "^2.0.0", - "espree": "^7.3.1", - "esquery": "^1.4.0", + "eslint-scope": "^7.2.0", + "eslint-visitor-keys": "^3.4.1", + "espree": "^9.5.2", + "esquery": "^1.4.2", "esutils": "^2.0.2", "fast-deep-equal": "^3.1.3", "file-entry-cache": "^6.0.1", - "functional-red-black-tree": "^1.0.1", - "glob-parent": "^5.1.2", - "globals": "^13.6.0", - "ignore": "^4.0.6", + "find-up": "^5.0.0", + "glob-parent": "^6.0.2", + "globals": "^13.19.0", + "graphemer": "^1.4.0", + "ignore": "^5.2.0", "import-fresh": "^3.0.0", "imurmurhash": "^0.1.4", "is-glob": "^4.0.0", - "js-yaml": "^3.13.1", + "is-path-inside": "^3.0.3", + "js-yaml": "^4.1.0", "json-stable-stringify-without-jsonify": "^1.0.1", "levn": "^0.4.1", "lodash.merge": "^4.6.2", - "minimatch": "^3.0.4", + "minimatch": "^3.1.2", "natural-compare": "^1.4.0", "optionator": "^0.9.1", - "progress": "^2.0.0", - "regexpp": "^3.1.0", - "semver": "^7.2.1", - "strip-ansi": "^6.0.0", + "strip-ansi": "^6.0.1", "strip-json-comments": "^3.1.0", - "table": "^6.0.9", - "text-table": "^0.2.0", - "v8-compile-cache": "^2.0.3" + "text-table": "^0.2.0" }, "bin": { "eslint": "bin/eslint.js" }, "engines": { - "node": "^10.12.0 || >=12.0.0" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" }, "funding": { "url": "https://opencollective.com/eslint" @@ -10231,20 +10203,10 @@ "url": "https://github.com/chalk/supports-color?sponsor=1" } }, - "node_modules/eslint/node_modules/@babel/code-frame": { - "version": "7.12.11", - "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.12.11.tgz", - "integrity": "sha512-Zt1yodBx1UcyiePMSkWnU4hPqhwq7hGi2nFL1LeA3EUl+q2LQx16MISgJ0+z7dnmgvP9QtIleuETGOiOH1RcIw==", - "peer": true, - "dependencies": { - "@babel/highlight": "^7.10.4" - } - }, "node_modules/eslint/node_modules/ansi-styles": { "version": "4.3.0", "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "peer": true, "dependencies": { "color-convert": "^2.0.1" }, @@ -10255,11 +10217,15 @@ "url": "https://github.com/chalk/ansi-styles?sponsor=1" } }, + "node_modules/eslint/node_modules/argparse": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", + "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==" + }, "node_modules/eslint/node_modules/chalk": { "version": "4.1.2", "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", - "peer": true, "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -10275,7 +10241,6 @@ "version": "2.0.1", "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "peer": true, "dependencies": { "color-name": "~1.1.4" }, @@ -10286,14 +10251,12 @@ "node_modules/eslint/node_modules/color-name": { "version": "1.1.4", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "peer": true + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==" }, "node_modules/eslint/node_modules/escape-string-regexp": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", - "peer": true, "engines": { "node": ">=10" }, @@ -10301,47 +10264,36 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/eslint/node_modules/eslint-utils": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/eslint-utils/-/eslint-utils-2.1.0.tgz", - "integrity": "sha512-w94dQYoauyvlDc43XnGB8lU3Zt713vNChgt4EWwhXAP2XkBvndfxF0AgIqKOOasjPIPzj9JqgwkwbCYD0/V3Zg==", - "peer": true, + "node_modules/eslint/node_modules/eslint-scope": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.0.tgz", + "integrity": "sha512-DYj5deGlHBfMt15J7rdtyKNq/Nqlv5KfU4iodrQ019XESsRnwXH9KAE0y3cwtUHDo2ob7CypAnCqefh6vioWRw==", "dependencies": { - "eslint-visitor-keys": "^1.1.0" + "esrecurse": "^4.3.0", + "estraverse": "^5.2.0" }, "engines": { - "node": ">=6" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" }, "funding": { - "url": "https://github.com/sponsors/mysticatea" + "url": "https://opencollective.com/eslint" } }, - "node_modules/eslint/node_modules/eslint-utils/node_modules/eslint-visitor-keys": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-1.3.0.tgz", - "integrity": "sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ==", - "peer": true, + "node_modules/eslint/node_modules/eslint-visitor-keys": { + "version": "3.4.1", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.1.tgz", + "integrity": "sha512-pZnmmLwYzf+kWaM/Qgrvpen51upAktaaiI01nsJD/Yr3lMOdNtq0cxkrrg16w64VtisN6okbs7Q8AfGqj4c9fA==", "engines": { - "node": ">=4" - } - }, - "node_modules/eslint/node_modules/glob-parent": { - "version": "5.1.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", - "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", - "peer": true, - "dependencies": { - "is-glob": "^4.0.1" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" }, - "engines": { - "node": ">= 6" + "funding": { + "url": "https://opencollective.com/eslint" } }, "node_modules/eslint/node_modules/globals": { "version": "13.20.0", "resolved": "https://registry.npmjs.org/globals/-/globals-13.20.0.tgz", "integrity": "sha512-Qg5QtVkCy/kv3FUSlu4ukeZDVf9ee0iXLAUYX13gbR17bnejFTzr4iS9bY7kwCf1NztRNm1t91fjOiyx4CSwPQ==", - "peer": true, "dependencies": { "type-fest": "^0.20.2" }, @@ -10356,25 +10308,25 @@ "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", - "peer": true, "engines": { "node": ">=8" } }, - "node_modules/eslint/node_modules/ignore": { - "version": "4.0.6", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-4.0.6.tgz", - "integrity": "sha512-cyFDKrqc/YdcWFniJhzI42+AzS+gNwmUzOSFcRCQYwySuBBBy/KjuxWLZ/FHEH6Moq1NizMOBWyTcv8O4OZIMg==", - "peer": true, - "engines": { - "node": ">= 4" + "node_modules/eslint/node_modules/js-yaml": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", + "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", + "dependencies": { + "argparse": "^2.0.1" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" } }, "node_modules/eslint/node_modules/supports-color": { "version": "7.2.0", "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", - "peer": true, "dependencies": { "has-flag": "^4.0.0" }, @@ -10386,7 +10338,6 @@ "version": "0.20.2", "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", - "peer": true, "engines": { "node": ">=10" }, @@ -10395,32 +10346,48 @@ } }, "node_modules/espree": { - "version": "7.3.1", - "resolved": "https://registry.npmjs.org/espree/-/espree-7.3.1.tgz", - "integrity": "sha512-v3JCNCE64umkFpmkFGqzVKsOT0tN1Zr+ueqLZfpV1Ob8e+CEgPWa+OxCoGH3tnhimMKIaBm4m/vaRpJ/krRz2g==", - "peer": true, + "version": "9.5.2", + "resolved": "https://registry.npmjs.org/espree/-/espree-9.5.2.tgz", + "integrity": "sha512-7OASN1Wma5fum5SrNhFMAMJxOUAbhyfQ8dQ//PJaJbNw0URTPWqIghHWt1MmAANKhHZIYOHruW4Kw4ruUWOdGw==", "dependencies": { - "acorn": "^7.4.0", - "acorn-jsx": "^5.3.1", - "eslint-visitor-keys": "^1.3.0" + "acorn": "^8.8.0", + "acorn-jsx": "^5.3.2", + "eslint-visitor-keys": "^3.4.1" }, "engines": { - "node": "^10.12.0 || >=12.0.0" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" + } + }, + "node_modules/espree/node_modules/acorn": { + "version": "8.8.2", + "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.8.2.tgz", + "integrity": "sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw==", + "bin": { + "acorn": "bin/acorn" + }, + "engines": { + "node": ">=0.4.0" } }, "node_modules/espree/node_modules/eslint-visitor-keys": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-1.3.0.tgz", - "integrity": "sha512-6J72N8UNa462wa/KFODt/PJ3IU60SDpC3QXC1Hjc1BXXpfL2C9R5+AU7jhe0F6GREqVMh4Juu+NY7xn+6dipUQ==", - "peer": true, + "version": "3.4.1", + "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.1.tgz", + "integrity": "sha512-pZnmmLwYzf+kWaM/Qgrvpen51upAktaaiI01nsJD/Yr3lMOdNtq0cxkrrg16w64VtisN6okbs7Q8AfGqj4c9fA==", "engines": { - "node": ">=4" + "node": "^12.22.0 || ^14.17.0 || >=16.0.0" + }, + "funding": { + "url": "https://opencollective.com/eslint" } }, "node_modules/esprima": { "version": "4.0.1", "resolved": "https://registry.npmjs.org/esprima/-/esprima-4.0.1.tgz", "integrity": "sha512-eGuFFw7Upda+g4p+QHvnW0RyTX/SVeJBDM/gCtMARO0cLuT2HcEKnTPvhjV6aGeqrCB/sbNop0Kszm0jsaWU4A==", + "dev": true, "bin": { "esparse": "bin/esparse.js", "esvalidate": "bin/esvalidate.js" @@ -11382,7 +11349,6 @@ "version": "6.0.2", "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz", "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==", - "dev": true, "dependencies": { "is-glob": "^4.0.3" }, @@ -11543,8 +11509,7 @@ "node_modules/graphemer": { "version": "1.4.0", "resolved": "https://registry.npmjs.org/graphemer/-/graphemer-1.4.0.tgz", - "integrity": "sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==", - "dev": true + "integrity": "sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag==" }, "node_modules/gzip-size": { "version": "6.0.0", @@ -12417,6 +12382,7 @@ "version": "3.0.0", "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", + "dev": true, "engines": { "node": ">=8" } @@ -12516,7 +12482,6 @@ "version": "3.0.3", "resolved": "https://registry.npmjs.org/is-path-inside/-/is-path-inside-3.0.3.tgz", "integrity": "sha512-Fd4gABb+ycGAmKou8eMftCupSir5lRxqf4aD/vd0cD2qc4HL07OjCeuHMr8Ro4CoMaeCKDB0/ECBOVWjTwUvPQ==", - "dev": true, "engines": { "node": ">=8" } @@ -16450,6 +16415,7 @@ "version": "3.14.1", "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-3.14.1.tgz", "integrity": "sha512-okMH7OXXJ7YrN9Ok3/SXrnu4iX9yOk+25nqX4imS2npuvTYDmo/QEZoqwZkYaIDk3jVvBOTOIEgEhaLOynBS9g==", + "dev": true, "dependencies": { "argparse": "^1.0.7", "esprima": "^4.0.0" @@ -16817,12 +16783,6 @@ "resolved": "https://registry.npmjs.org/lodash.startswith/-/lodash.startswith-4.2.1.tgz", "integrity": "sha512-XClYR1h4/fJ7H+mmCKppbiBmljN/nGs73iq2SjCT9SF4CBPoUHzLvWmH1GtZMhMBZSiRkHXfeA2RY1eIlJ75ww==" }, - "node_modules/lodash.truncate": { - "version": "4.4.2", - "resolved": "https://registry.npmjs.org/lodash.truncate/-/lodash.truncate-4.4.2.tgz", - "integrity": "sha512-jttmRe7bRse52OsWIMDLaXxWqRAmtIUccAQ3garviCqJjafXOfNMO0yMfNpdD6zbGaTU0P5Nz7e7gAT6cKmJRw==", - "peer": true - }, "node_modules/lodash.uniq": { "version": "4.5.0", "resolved": "https://registry.npmjs.org/lodash.uniq/-/lodash.uniq-4.5.0.tgz", @@ -19890,15 +19850,6 @@ "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", "dev": true }, - "node_modules/progress": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/progress/-/progress-2.0.3.tgz", - "integrity": "sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA==", - "peer": true, - "engines": { - "node": ">=0.4.0" - } - }, "node_modules/promise": { "version": "8.3.0", "resolved": "https://registry.npmjs.org/promise/-/promise-8.3.0.tgz", @@ -20655,43 +20606,6 @@ } } }, - "node_modules/react-scripts/node_modules/@eslint/eslintrc": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/@eslint/eslintrc/-/eslintrc-2.0.3.tgz", - "integrity": "sha512-+5gy6OQfk+xx3q0d6jGZZC3f3KzAkXc/IanVxd1is/VIIziRqqt3ongQz0FiTUXqTk0c7aDB3OaFuKnuSoJicQ==", - "dev": true, - "dependencies": { - "ajv": "^6.12.4", - "debug": "^4.3.2", - "espree": "^9.5.2", - "globals": "^13.19.0", - "ignore": "^5.2.0", - "import-fresh": "^3.2.1", - "js-yaml": "^4.1.0", - "minimatch": "^3.1.2", - "strip-json-comments": "^3.1.1" - }, - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, - "node_modules/react-scripts/node_modules/@humanwhocodes/config-array": { - "version": "0.11.8", - "resolved": "https://registry.npmjs.org/@humanwhocodes/config-array/-/config-array-0.11.8.tgz", - "integrity": "sha512-UybHIJzJnR5Qc/MsD9Kr+RpO2h+/P1GhOwdiLPXK5TWk5sgTdu88bTD9UP+CKbPPh5Rni1u0GjAdYQLemG8g+g==", - "dev": true, - "dependencies": { - "@humanwhocodes/object-schema": "^1.2.1", - "debug": "^4.1.1", - "minimatch": "^3.0.5" - }, - "engines": { - "node": ">=10.10.0" - } - }, "node_modules/react-scripts/node_modules/@typescript-eslint/eslint-plugin": { "version": "5.54.0", "resolved": "https://registry.npmjs.org/@typescript-eslint/eslint-plugin/-/eslint-plugin-5.54.0.tgz", @@ -20846,18 +20760,6 @@ "url": "https://opencollective.com/typescript-eslint" } }, - "node_modules/react-scripts/node_modules/acorn": { - "version": "8.8.2", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.8.2.tgz", - "integrity": "sha512-xjIYgE8HBrkpd/sJqOGNspf8uHG+NOHGOw6a/Urj8taM2EXfdNAH2oFcPeIFfsv3+kz/mJrS5VuMqbNLjCa2vw==", - "dev": true, - "bin": { - "acorn": "bin/acorn" - }, - "engines": { - "node": ">=0.4.0" - } - }, "node_modules/react-scripts/node_modules/adjust-sourcemap-loader": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/adjust-sourcemap-loader/-/adjust-sourcemap-loader-4.0.0.tgz", @@ -20876,6 +20778,8 @@ "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", "dev": true, + "optional": true, + "peer": true, "dependencies": { "color-convert": "^2.0.1" }, @@ -20901,12 +20805,6 @@ "node": ">=10" } }, - "node_modules/react-scripts/node_modules/argparse": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", - "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", - "dev": true - }, "node_modules/react-scripts/node_modules/babel-loader": { "version": "8.3.0", "resolved": "https://registry.npmjs.org/babel-loader/-/babel-loader-8.3.0.tgz", @@ -20931,6 +20829,8 @@ "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", "dev": true, + "optional": true, + "peer": true, "dependencies": { "ansi-styles": "^4.1.0", "supports-color": "^7.1.0" @@ -20947,6 +20847,8 @@ "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", "dev": true, + "optional": true, + "peer": true, "dependencies": { "color-name": "~1.1.4" }, @@ -20958,7 +20860,9 @@ "version": "1.1.4", "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "dev": true + "dev": true, + "optional": true, + "peer": true }, "node_modules/react-scripts/node_modules/dotenv": { "version": "10.0.0", @@ -20969,74 +20873,6 @@ "node": ">=10" } }, - "node_modules/react-scripts/node_modules/escape-string-regexp": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", - "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/react-scripts/node_modules/eslint": { - "version": "8.41.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-8.41.0.tgz", - "integrity": "sha512-WQDQpzGBOP5IrXPo4Hc0814r4/v2rrIsB0rhT7jtunIalgg6gYXWhRMOejVO8yH21T/FGaxjmFjBMNqcIlmH1Q==", - "dev": true, - "dependencies": { - "@eslint-community/eslint-utils": "^4.2.0", - "@eslint-community/regexpp": "^4.4.0", - "@eslint/eslintrc": "^2.0.3", - "@eslint/js": "8.41.0", - "@humanwhocodes/config-array": "^0.11.8", - "@humanwhocodes/module-importer": "^1.0.1", - "@nodelib/fs.walk": "^1.2.8", - "ajv": "^6.10.0", - "chalk": "^4.0.0", - "cross-spawn": "^7.0.2", - "debug": "^4.3.2", - "doctrine": "^3.0.0", - "escape-string-regexp": "^4.0.0", - "eslint-scope": "^7.2.0", - "eslint-visitor-keys": "^3.4.1", - "espree": "^9.5.2", - "esquery": "^1.4.2", - "esutils": "^2.0.2", - "fast-deep-equal": "^3.1.3", - "file-entry-cache": "^6.0.1", - "find-up": "^5.0.0", - "glob-parent": "^6.0.2", - "globals": "^13.19.0", - "graphemer": "^1.4.0", - "ignore": "^5.2.0", - "import-fresh": "^3.0.0", - "imurmurhash": "^0.1.4", - "is-glob": "^4.0.0", - "is-path-inside": "^3.0.3", - "js-yaml": "^4.1.0", - "json-stable-stringify-without-jsonify": "^1.0.1", - "levn": "^0.4.1", - "lodash.merge": "^4.6.2", - "minimatch": "^3.1.2", - "natural-compare": "^1.4.0", - "optionator": "^0.9.1", - "strip-ansi": "^6.0.1", - "strip-json-comments": "^3.1.0", - "text-table": "^0.2.0" - }, - "bin": { - "eslint": "bin/eslint.js" - }, - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, "node_modules/react-scripts/node_modules/eslint-config-react-app": { "version": "7.0.1", "resolved": "https://registry.npmjs.org/eslint-config-react-app/-/eslint-config-react-app-7.0.1.tgz", @@ -21123,22 +20959,6 @@ "eslint": "^7.5.0 || ^8.0.0" } }, - "node_modules/react-scripts/node_modules/eslint-scope": { - "version": "7.2.0", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-7.2.0.tgz", - "integrity": "sha512-DYj5deGlHBfMt15J7rdtyKNq/Nqlv5KfU4iodrQ019XESsRnwXH9KAE0y3cwtUHDo2ob7CypAnCqefh6vioWRw==", - "dev": true, - "dependencies": { - "esrecurse": "^4.3.0", - "estraverse": "^5.2.0" - }, - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, "node_modules/react-scripts/node_modules/eslint-visitor-keys": { "version": "3.4.1", "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.1.tgz", @@ -21151,23 +20971,6 @@ "url": "https://opencollective.com/eslint" } }, - "node_modules/react-scripts/node_modules/espree": { - "version": "9.5.2", - "resolved": "https://registry.npmjs.org/espree/-/espree-9.5.2.tgz", - "integrity": "sha512-7OASN1Wma5fum5SrNhFMAMJxOUAbhyfQ8dQ//PJaJbNw0URTPWqIghHWt1MmAANKhHZIYOHruW4Kw4ruUWOdGw==", - "dev": true, - "dependencies": { - "acorn": "^8.8.0", - "acorn-jsx": "^5.3.2", - "eslint-visitor-keys": "^3.4.1" - }, - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, "node_modules/react-scripts/node_modules/fs-extra": { "version": "10.1.0", "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-10.1.0.tgz", @@ -21204,42 +21007,17 @@ "node": ">=10" } }, - "node_modules/react-scripts/node_modules/globals": { - "version": "13.20.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-13.20.0.tgz", - "integrity": "sha512-Qg5QtVkCy/kv3FUSlu4ukeZDVf9ee0iXLAUYX13gbR17bnejFTzr4iS9bY7kwCf1NztRNm1t91fjOiyx4CSwPQ==", - "dev": true, - "dependencies": { - "type-fest": "^0.20.2" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/react-scripts/node_modules/has-flag": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", "dev": true, + "optional": true, + "peer": true, "engines": { "node": ">=8" } }, - "node_modules/react-scripts/node_modules/js-yaml": { - "version": "4.1.0", - "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.1.0.tgz", - "integrity": "sha512-wpxZs9NoxZaJESJGIZTyDEaYpl0FKSA+FB9aJiyemKhMwkxQg63h4T1KJgUGHpTqPDNRcmmYLugrRjJlBtWvRA==", - "dev": true, - "dependencies": { - "argparse": "^2.0.1" - }, - "bin": { - "js-yaml": "bin/js-yaml.js" - } - }, "node_modules/react-scripts/node_modules/lru-cache": { "version": "6.0.0", "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", @@ -21490,6 +21268,8 @@ "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", "dev": true, + "optional": true, + "peer": true, "dependencies": { "has-flag": "^4.0.0" }, @@ -21508,18 +21288,6 @@ "glob": "^7.1.2" } }, - "node_modules/react-scripts/node_modules/type-fest": { - "version": "0.20.2", - "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-0.20.2.tgz", - "integrity": "sha512-Ne+eE4r0/iWnpAxD852z3A+N0Bt5RN//NjJwRd2VFHEmrywxf5vsZlh4R6lixl6B+wz/8d+maTSAkN1FIkI3LQ==", - "dev": true, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/react-scripts/node_modules/yallist": { "version": "4.0.0", "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", @@ -22102,6 +21870,7 @@ "version": "2.0.2", "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", + "dev": true, "engines": { "node": ">=0.10.0" } @@ -22910,56 +22679,6 @@ "node": ">=8" } }, - "node_modules/slice-ansi": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-4.0.0.tgz", - "integrity": "sha512-qMCMfhY040cVHT43K9BFygqYbUPFZKHOg7K73mtTWJRb8pyP3fzf4Ixd5SzdEJQ6MRUg/WBnOLxghZtKKurENQ==", - "peer": true, - "dependencies": { - "ansi-styles": "^4.0.0", - "astral-regex": "^2.0.0", - "is-fullwidth-code-point": "^3.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/chalk/slice-ansi?sponsor=1" - } - }, - "node_modules/slice-ansi/node_modules/ansi-styles": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", - "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", - "peer": true, - "dependencies": { - "color-convert": "^2.0.1" - }, - "engines": { - "node": ">=8" - }, - "funding": { - "url": "https://github.com/chalk/ansi-styles?sponsor=1" - } - }, - "node_modules/slice-ansi/node_modules/color-convert": { - "version": "2.0.1", - "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", - "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", - "peer": true, - "dependencies": { - "color-name": "~1.1.4" - }, - "engines": { - "node": ">=7.0.0" - } - }, - "node_modules/slice-ansi/node_modules/color-name": { - "version": "1.1.4", - "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", - "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", - "peer": true - }, "node_modules/slick-carousel": { "version": "1.8.1", "resolved": "https://registry.npmjs.org/slick-carousel/-/slick-carousel-1.8.1.tgz", @@ -23179,7 +22898,8 @@ "node_modules/sprintf-js": { "version": "1.0.3", "resolved": "https://registry.npmjs.org/sprintf-js/-/sprintf-js-1.0.3.tgz", - "integrity": "sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==" + "integrity": "sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g==", + "dev": true }, "node_modules/sshpk": { "version": "1.17.0", @@ -23354,6 +23074,7 @@ "version": "4.2.3", "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", + "dev": true, "dependencies": { "emoji-regex": "^8.0.0", "is-fullwidth-code-point": "^3.0.0", @@ -23366,7 +23087,8 @@ "node_modules/string-width/node_modules/emoji-regex": { "version": "8.0.0", "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", - "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==" + "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", + "dev": true }, "node_modules/string.prototype.matchall": { "version": "4.0.8", @@ -23711,44 +23433,6 @@ "integrity": "sha512-9QNk5KwDF+Bvz+PyObkmSYjI5ksVUYtjW7AU22r2NKcfLJcXp96hkDWU3+XndOsUb+AQ9QhfzfCT2O+CNWT5Tw==", "dev": true }, - "node_modules/table": { - "version": "6.8.1", - "resolved": "https://registry.npmjs.org/table/-/table-6.8.1.tgz", - "integrity": "sha512-Y4X9zqrCftUhMeH2EptSSERdVKt/nEdijTOacGD/97EKjhQ/Qs8RTlEGABSJNNN8lac9kheH+af7yAkEWlgneA==", - "peer": true, - "dependencies": { - "ajv": "^8.0.1", - "lodash.truncate": "^4.4.2", - "slice-ansi": "^4.0.0", - "string-width": "^4.2.3", - "strip-ansi": "^6.0.1" - }, - "engines": { - "node": ">=10.0.0" - } - }, - "node_modules/table/node_modules/ajv": { - "version": "8.12.0", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.12.0.tgz", - "integrity": "sha512-sRu1kpcO9yLtYxBKvqfTeh9KzZEwO3STyX1HT+4CaDzC6HpTGYhIhPIzj9XuKU7KYDwnaeh5hcOwjy1QuJzBPA==", - "peer": true, - "dependencies": { - "fast-deep-equal": "^3.1.1", - "json-schema-traverse": "^1.0.0", - "require-from-string": "^2.0.2", - "uri-js": "^4.2.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, - "node_modules/table/node_modules/json-schema-traverse": { - "version": "1.0.0", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", - "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", - "peer": true - }, "node_modules/tailwindcss": { "version": "3.2.7", "resolved": "https://registry.npmjs.org/tailwindcss/-/tailwindcss-3.2.7.tgz", @@ -24647,12 +24331,6 @@ "uuid": "dist/bin/uuid" } }, - "node_modules/v8-compile-cache": { - "version": "2.3.0", - "resolved": "https://registry.npmjs.org/v8-compile-cache/-/v8-compile-cache-2.3.0.tgz", - "integrity": "sha512-l8lCEmLcLYZh4nbunNZvQCJc5pv7+RCwa8q/LdUx8u7lsWvPDKmpodJAJNwkAhJC//dFY48KuIEmjtd4RViDrA==", - "peer": true - }, "node_modules/v8-to-istanbul": { "version": "8.1.1", "resolved": "https://registry.npmjs.org/v8-to-istanbul/-/v8-to-istanbul-8.1.1.tgz", diff --git a/package.json b/package.json index 993d62fe..318384fa 100644 --- a/package.json +++ b/package.json @@ -55,6 +55,8 @@ "cross-env": "^7.0.3", "css-loader": "6.7.3", "dotenv-webpack": "^7.0.3", + "eslint": "^8.41.0", + "eslint-plugin-react": "^7.32.2", "html-webpack-plugin": "5.5.0", "mini-css-extract-plugin": "^2.7.2", "node-sass": "8.0.0", @@ -78,7 +80,8 @@ "build": "cross-env SERVE=true webpack -c config/webpack/prod.js", "start": "webpack serve -c config/webpack/dev.js", "analyze": "webpack --analyze -c config/webpack/analyze.js", - "format": "prettier --write \"./**/*.{js,jsx}\"" + "format": "prettier --write \"./**/*.{js,jsx}\"", + "lint": "npx eslint 'src/**/*.{js,jsx,ts,tsx}'" }, "eslintConfig": { "extends": [ diff --git a/src/components/Common/AuthHeader/AuthHeader.jsx b/src/components/Common/AuthHeader/AuthHeader.jsx index 7a87abb6..7ebe2613 100644 --- a/src/components/Common/AuthHeader/AuthHeader.jsx +++ b/src/components/Common/AuthHeader/AuthHeader.jsx @@ -7,7 +7,7 @@ import userIcon from "assets/icons/userIcon.svg"; import "./authHeader.scss"; -export const AuthHeader = ({}) => { +export const AuthHeader = () => { return (
diff --git a/src/components/Description/Description.jsx b/src/components/Description/Description.jsx index 9156d6b4..ef39d002 100644 --- a/src/components/Description/Description.jsx +++ b/src/components/Description/Description.jsx @@ -13,7 +13,7 @@ import rectangle from "assets/images/rectangle_secondPage.png"; import ErrorBoundary from "../../hoc/ErrorBoundary"; import "./description.scss"; -const Description = ({ onLoadMore, isLoadingMore }) => { +const Description = ({ onLoadMore }) => { const candidatesListArr = useSelector(selectProfiles); return ( diff --git a/src/components/Form/Form.jsx b/src/components/Form/Form.jsx index c7f998f1..b3bc2524 100644 --- a/src/components/Form/Form.jsx +++ b/src/components/Form/Form.jsx @@ -29,8 +29,10 @@ const Form = () => { const handleModal = (status) => { SweetAlert.fire({ text: + // eslint-disable-next-line no-constant-condition status !== 200 || 201 ? "Какие-то неполадки =(" : "Форма отправлена", preConfirm: () => + // eslint-disable-next-line no-constant-condition status !== 200 || 201 ? () => { setStatus(null); diff --git a/src/components/FreeDevelopers/FreeDevelopers.jsx b/src/components/FreeDevelopers/FreeDevelopers.jsx index ceaf88a3..34798e78 100644 --- a/src/components/FreeDevelopers/FreeDevelopers.jsx +++ b/src/components/FreeDevelopers/FreeDevelopers.jsx @@ -14,7 +14,7 @@ import mockWorker from "assets/images/mock/mokPerson.png"; import "./freeDevelopers.scss"; -export const FreeDevelopers = ({}) => { +export const FreeDevelopers = () => { return (
diff --git a/src/components/Modal/Tracker/ModalTicket/ModalTicket.jsx b/src/components/Modal/Tracker/ModalTicket/ModalTicket.jsx index 98b113b0..1b5da0b5 100644 --- a/src/components/Modal/Tracker/ModalTicket/ModalTicket.jsx +++ b/src/components/Modal/Tracker/ModalTicket/ModalTicket.jsx @@ -60,7 +60,7 @@ export const ModalTiсket = ({ task_id: task.id, status: 0, }, - }).then((res) => { + }).then(() => { setActive(false); dispatch(setProjectBoardFetch(projectId)); }); @@ -74,7 +74,7 @@ export const ModalTiсket = ({ title: inputsValue.title, description: inputsValue.description, }, - }).then((res) => { + }).then(() => { dispatch(setProjectBoardFetch(projectId)); }); } @@ -106,7 +106,7 @@ export const ModalTiсket = ({ comment_id: commentId, status: 0, }, - }).then((res) => { + }).then(() => { setComments((prevValue) => prevValue.filter((item) => item.id !== commentId) ); @@ -120,7 +120,7 @@ export const ModalTiсket = ({ comment_id: commentId, text: commentsEditText[commentId], }, - }).then((res) => {}); + }).then(() => {}); } function taskExecutor(person) { @@ -143,7 +143,7 @@ export const ModalTiсket = ({ task_id: task.id, executor_id: 0, }, - }).then((res) => { + }).then(() => { setExecutor(null); }); } @@ -168,7 +168,7 @@ export const ModalTiсket = ({ task_id: task.id, user_id: person.user_id, }, - }).then((res) => { + }).then(() => { setMembers(members.filter((item) => item.user_id !== person.user_id)); }); } diff --git a/src/components/Modal/Tracker/TicketFullScreen/TicketFullScreen.jsx b/src/components/Modal/Tracker/TicketFullScreen/TicketFullScreen.jsx index 7a31e7ae..8f1a3f8b 100644 --- a/src/components/Modal/Tracker/TicketFullScreen/TicketFullScreen.jsx +++ b/src/components/Modal/Tracker/TicketFullScreen/TicketFullScreen.jsx @@ -42,7 +42,7 @@ import watch from "assets/icons/watch.svg"; import "./ticketFullScreen.scss"; -export const TicketFullScreen = ({}) => { +export const TicketFullScreen = () => { const [modalAddWorker, setModalAddWorker] = useState(false); const ticketId = useParams(); const dispatch = useDispatch(); @@ -93,7 +93,7 @@ export const TicketFullScreen = ({}) => { task_id: ticketId.id, status: 0, }, - }).then((res) => { + }).then(() => { navigate(`/tracker/project/${taskInfo.project_id}`); }); } @@ -106,7 +106,7 @@ export const TicketFullScreen = ({}) => { title: inputsValue.title, description: inputsValue.description, }, - }).then((res) => {}); + }).then(() => {}); } function createComment() { @@ -137,7 +137,7 @@ export const TicketFullScreen = ({}) => { comment_id: commentId, status: 0, }, - }).then((res) => { + }).then(() => { setComments((prevValue) => prevValue.filter((item) => item.id !== commentId) ); @@ -151,7 +151,7 @@ export const TicketFullScreen = ({}) => { comment_id: commentId, text: commentsEditText[commentId], }, - }).then((res) => {}); + }).then(() => {}); } function deletePerson(userId) { @@ -161,7 +161,7 @@ export const TicketFullScreen = ({}) => { project_id: projectBoard.id, user_id: userId, }, - }).then((res) => { + }).then(() => { dispatch(deletePersonOnProject(userId)); }); } diff --git a/src/components/Modal/TrackerModal/TrackerModal.jsx b/src/components/Modal/TrackerModal/TrackerModal.jsx index 579d8134..12face24 100644 --- a/src/components/Modal/TrackerModal/TrackerModal.jsx +++ b/src/components/Modal/TrackerModal/TrackerModal.jsx @@ -57,7 +57,7 @@ export const TrackerModal = ({ project_id: projectBoard.id, title: valueColumn, }, - }).then((res) => { + }).then(() => { dispatch(setProjectBoardFetch(projectBoard.id)); }); setValueColumn(""); @@ -80,7 +80,7 @@ export const TrackerModal = ({ column_id: selectedTab, priority: priorityTask, }, - }).then((res) => { + }).then(() => { dispatch(setProjectBoardFetch(projectBoard.id)); }); @@ -96,7 +96,7 @@ export const TrackerModal = ({ project_id: projectId, name: projectName, }, - }).then((res) => { + }).then(() => { setActive(false); dispatch(editProjectName({ id: projectId, name: projectName })); }); @@ -109,7 +109,7 @@ export const TrackerModal = ({ column_id: columnId, title: columnName, }, - }).then((res) => { + }).then(() => { setActive(false); dispatch(editColumnName({ id: columnId, title: columnName })); }); diff --git a/src/components/ProfileCalendar/ProfileCalendarComponent.jsx b/src/components/ProfileCalendar/ProfileCalendarComponent.jsx index fee451bd..beb61052 100644 --- a/src/components/ProfileCalendar/ProfileCalendarComponent.jsx +++ b/src/components/ProfileCalendar/ProfileCalendarComponent.jsx @@ -23,6 +23,7 @@ import arrow from "assets/icons/arrows/arrowCalendar.png"; import calendarIcon from "assets/icons/calendar.svg"; import rectangle from "assets/images/rectangle__calendar.png"; +// eslint-disable-next-line react/display-name export const ProfileCalendarComponent = React.memo( ({ value, setValueHandler, reports, totalHours }) => { const dispatch = useDispatch(); diff --git a/src/components/ProjectTiket/ProjectTiket.jsx b/src/components/ProjectTiket/ProjectTiket.jsx index 41fa1cb1..6d565cd3 100644 --- a/src/components/ProjectTiket/ProjectTiket.jsx +++ b/src/components/ProjectTiket/ProjectTiket.jsx @@ -47,7 +47,7 @@ export const ProjectTiket = ({ project, index }) => { project_id: project.id, status: 10, }, - }).then((res) => { + }).then(() => { dispatch(deleteProject(project)); }); } diff --git a/src/components/ProtectedRoute/ProtectedRoute.js b/src/components/ProtectedRoute/ProtectedRoute.js index 32f807e4..1febac53 100644 --- a/src/components/ProtectedRoute/ProtectedRoute.js +++ b/src/components/ProtectedRoute/ProtectedRoute.js @@ -1,6 +1,6 @@ import React from "react"; import { useSelector } from "react-redux"; -import { Redirect, Route } from "react-router-dom"; +import { Route } from "react-router-dom"; import { selectAuth } from "@redux/outstaffingSlice"; @@ -9,6 +9,7 @@ export const ProtectedRoute = ({ component: Component, ...rest }) => { const existingToken = localStorage.getItem("auth_token"); const expiresAt = localStorage.getItem("access_token_expired_at"); + // eslint-disable-next-line no-unused-vars const isTokenAlive = !isAuth && existingToken && diff --git a/src/components/ReportForm/ReportForm.jsx b/src/components/ReportForm/ReportForm.jsx index 4ee38c58..205550c4 100644 --- a/src/components/ReportForm/ReportForm.jsx +++ b/src/components/ReportForm/ReportForm.jsx @@ -103,7 +103,7 @@ const ReportForm = () => { created_at: getCreatedDate(startDate), status: 1, }, - }).then((res) => { + }).then(() => { setReportSuccess("Отчет отправлен"); setTimeout(() => { setReportSuccess(""); diff --git a/src/components/ShortReport/ShortReport.jsx b/src/components/ShortReport/ShortReport.jsx index b7c08f99..7b45da0c 100644 --- a/src/components/ShortReport/ShortReport.jsx +++ b/src/components/ShortReport/ShortReport.jsx @@ -19,7 +19,7 @@ import { Loader } from "@components/Common/Loader/Loader"; import "./shortReport.scss"; -export const ShortReport = ({}) => { +export const ShortReport = () => { const reportDate = useSelector(getReportDate); const sendReport = useSelector(getSendRequest); diff --git a/src/components/features/quiz/AlertResult.js b/src/components/features/quiz/AlertResult.jsx similarity index 100% rename from src/components/features/quiz/AlertResult.js rename to src/components/features/quiz/AlertResult.jsx diff --git a/src/components/features/quiz/BlockCompletedTest.js b/src/components/features/quiz/BlockCompletedTest.jsx similarity index 100% rename from src/components/features/quiz/BlockCompletedTest.js rename to src/components/features/quiz/BlockCompletedTest.jsx diff --git a/src/components/features/quiz/Card-introduction.js b/src/components/features/quiz/Card-introduction.jsx similarity index 100% rename from src/components/features/quiz/Card-introduction.js rename to src/components/features/quiz/Card-introduction.jsx diff --git a/src/components/features/quiz/CardAviableTest.js b/src/components/features/quiz/CardAviableTest.jsx similarity index 100% rename from src/components/features/quiz/CardAviableTest.js rename to src/components/features/quiz/CardAviableTest.jsx diff --git a/src/components/features/quiz/GetOptionTask.js b/src/components/features/quiz/GetOptionTask.jsx similarity index 86% rename from src/components/features/quiz/GetOptionTask.js rename to src/components/features/quiz/GetOptionTask.jsx index f56dab9b..52cd39c9 100644 --- a/src/components/features/quiz/GetOptionTask.js +++ b/src/components/features/quiz/GetOptionTask.jsx @@ -1,12 +1,6 @@ import React from "react"; -import { useSelector } from "react-redux"; - -import { selectedTest } from "@redux/quizSlice"; export const GetOptionTask = ({ type, answer, handleChange, inputValue }) => { - const id = localStorage.getItem("id"); - const dataTest = useSelector(selectedTest); - switch (type) { case "1": return ( diff --git a/src/components/features/quiz/HeaderPageTests.js b/src/components/features/quiz/HeaderPageTests.jsx similarity index 100% rename from src/components/features/quiz/HeaderPageTests.js rename to src/components/features/quiz/HeaderPageTests.jsx diff --git a/src/components/features/quiz/HeaderQuiz.js b/src/components/features/quiz/HeaderQuiz.jsx similarity index 97% rename from src/components/features/quiz/HeaderQuiz.js rename to src/components/features/quiz/HeaderQuiz.jsx index d5ea6260..bde6f469 100644 --- a/src/components/features/quiz/HeaderQuiz.js +++ b/src/components/features/quiz/HeaderQuiz.jsx @@ -5,8 +5,7 @@ import { selectUserInfo, setUserInfo } from "@redux/quizSlice"; import { urlForLocal } from "@utils/helper"; -import { apiRequest } from "@api/request"; - +// import { apiRequest } from "@api/request"; import "./quiz.scss"; export const HeaderQuiz = ({ header }) => { diff --git a/src/components/features/quiz/Instructions.js b/src/components/features/quiz/Instructions.jsx similarity index 100% rename from src/components/features/quiz/Instructions.js rename to src/components/features/quiz/Instructions.jsx diff --git a/src/components/features/quiz/MyTestsQuiz.js b/src/components/features/quiz/MyTestsQuiz.jsx similarity index 100% rename from src/components/features/quiz/MyTestsQuiz.js rename to src/components/features/quiz/MyTestsQuiz.jsx diff --git a/src/components/features/quiz/ProgressbarQuiz.js b/src/components/features/quiz/ProgressbarQuiz.jsx similarity index 100% rename from src/components/features/quiz/ProgressbarQuiz.js rename to src/components/features/quiz/ProgressbarQuiz.jsx diff --git a/src/components/features/quiz/Quiz-passing-information.js b/src/components/features/quiz/Quiz-passing-information.jsx similarity index 93% rename from src/components/features/quiz/Quiz-passing-information.js rename to src/components/features/quiz/Quiz-passing-information.jsx index 073ef094..dca28127 100644 --- a/src/components/features/quiz/Quiz-passing-information.js +++ b/src/components/features/quiz/Quiz-passing-information.jsx @@ -10,14 +10,13 @@ import accempt from "assets/images/quiz/accempt.png"; import timer from "assets/images/quiz/timer.png"; export const QuizPassingInformation = ({ expiryTimestamp, setStartTest }) => { - const { seconds, minutes, isRunning, start, pause, resume, restart } = - useTimer({ - expiryTimestamp, - autoStart: false, - onExpire: () => { - console.warn("onExpire called"); - }, - }); + const { seconds, minutes, isRunning, start, restart } = useTimer({ + expiryTimestamp, + autoStart: false, + onExpire: () => { + console.warn("onExpire called"); + }, + }); const completedTest = useSelector(completedTestSelector); const startTesting = () => { diff --git a/src/components/features/quiz/QuizReport.js b/src/components/features/quiz/QuizReport.jsx similarity index 100% rename from src/components/features/quiz/QuizReport.js rename to src/components/features/quiz/QuizReport.jsx diff --git a/src/components/features/quiz/Results.js b/src/components/features/quiz/Results.jsx similarity index 100% rename from src/components/features/quiz/Results.js rename to src/components/features/quiz/Results.jsx diff --git a/src/components/features/quiz/SelectedCategory.js b/src/components/features/quiz/SelectedCategory.jsx similarity index 100% rename from src/components/features/quiz/SelectedCategory.js rename to src/components/features/quiz/SelectedCategory.jsx diff --git a/src/components/features/quiz/Task.js b/src/components/features/quiz/Task.js index 77136fd4..a07faa65 100644 --- a/src/components/features/quiz/Task.js +++ b/src/components/features/quiz/Task.js @@ -1,15 +1,12 @@ import React, { useEffect, useState } from "react"; import { useDispatch, useSelector } from "react-redux"; -import { useNavigate } from "react-router-dom"; import { answersSelector, - fetchGetAnswers, - fetchUserAnswerOne, - fetchUserAnswersMany, + fetchGetAnswers, // fetchUserAnswerOne, + // fetchUserAnswersMany, questionsSelector, - selectedTest, - setAnswers, + selectedTest, // setAnswers, setCompleteTest, } from "@redux/quizSlice"; @@ -18,12 +15,11 @@ import { apiRequest } from "@api/request"; import questionIcon from "assets/images/question.png"; import { GetOptionTask } from "./GetOptionTask"; -import { HeaderQuiz } from "./HeaderQuiz"; -import { Progressbar } from "./ProgressbarQuiz"; +// import { HeaderQuiz } from "./HeaderQuiz"; +// import { Progressbar } from "./ProgressbarQuiz"; import "./quiz.scss"; export const TaskQuiz = () => { - const navigate = useNavigate(); const dispatch = useDispatch(); const answers = useSelector(answersSelector); @@ -42,7 +38,6 @@ export const TaskQuiz = () => { // .then(json => console.log(json)) apiRequest(`/question/get-questions?uuid=${dataTest.uuid}`).then( (response) => { - console.log(response); dispatch(fetchGetAnswers(response[0].id)); setStripValue(((+index + 1) * 100) / response.length); } diff --git a/src/pages/Article/Article.jsx b/src/pages/Article/Article.jsx index 86e47b55..7d61aa59 100644 --- a/src/pages/Article/Article.jsx +++ b/src/pages/Article/Article.jsx @@ -17,7 +17,7 @@ import mockImgArticle from "assets/images/mock/mockImgArticle.png"; import "./article.scss"; -export const Article = ({}) => { +export const Article = () => { const [article] = useState([ { image: cardImg1, diff --git a/src/pages/Blog/Blog.jsx b/src/pages/Blog/Blog.jsx index 5d2b109e..dde9ae6e 100644 --- a/src/pages/Blog/Blog.jsx +++ b/src/pages/Blog/Blog.jsx @@ -16,7 +16,7 @@ import cardImg1 from "assets/images/mock/cardArticleItem.png"; import "./blog.scss"; -export const Blog = ({}) => { +export const Blog = () => { const [article] = useState([ { image: cardImg1, diff --git a/src/pages/FrequentlyAskedQuestion/FrequentlyAskedQuestion.jsx b/src/pages/FrequentlyAskedQuestion/FrequentlyAskedQuestion.jsx index 06936ae5..9ddf06fc 100644 --- a/src/pages/FrequentlyAskedQuestion/FrequentlyAskedQuestion.jsx +++ b/src/pages/FrequentlyAskedQuestion/FrequentlyAskedQuestion.jsx @@ -13,7 +13,7 @@ import "./FrequentlyAskedQuestion.scss"; export const FrequentlyAskedQuestion = () => { const params = useParams(); const navigate = useNavigate(); - const [question, setQuestion] = useState({ + const [question] = useState({ id: params.id, title: "Это фриланс-платформа?", answer: diff --git a/src/pages/PartnerAddRequest/PartnerAddRequest.js b/src/pages/PartnerAddRequest/PartnerAddRequest.js index 31b39d9f..a023cb85 100644 --- a/src/pages/PartnerAddRequest/PartnerAddRequest.js +++ b/src/pages/PartnerAddRequest/PartnerAddRequest.js @@ -117,7 +117,7 @@ export const PartnerAddRequest = () => { return skill.id; }), }, - }).then((res) => { + }).then(() => { navigate("/profile/requests"); }); } else { @@ -135,7 +135,7 @@ export const PartnerAddRequest = () => { return skill.id; }), }, - }).then((res) => { + }).then(() => { navigate("/profile/requests"); }); } @@ -206,7 +206,7 @@ export const PartnerAddRequest = () => { {openSpecializationList && Boolean(specializationList.length) && (
- {specializationList.map((specialization, index) => { + {specializationList.map((specialization) => { return (

{ request_id: requestId, status: 0, }, - }).then((res) => { + }).then(() => { navigate("/profile/requests"); }); }; diff --git a/src/pages/ProjectTracker/ProjectTracker.js b/src/pages/ProjectTracker/ProjectTracker.js index 55f36ac1..78a48ae8 100644 --- a/src/pages/ProjectTracker/ProjectTracker.js +++ b/src/pages/ProjectTracker/ProjectTracker.js @@ -152,7 +152,7 @@ export const ProjectTracker = () => { project_id: projectBoard.id, status: 0, }, - }).then((res) => { + }).then(() => { dispatch(setProjectBoardFetch(projectBoard.id)); }); } @@ -164,7 +164,7 @@ export const ProjectTracker = () => { project_id: projectBoard.id, user_id: userId, }, - }).then((res) => { + }).then(() => { dispatch(deletePersonOnProject(userId)); }); } @@ -338,7 +338,7 @@ export const ProjectTracker = () => {

dragOverHandler(e)} - onDragEnter={(e) => dragEnterHandler(column.id)} + onDragEnter={() => dragEnterHandler(column.id)} onDrop={(e) => dragDropHandler(e, column.id)} className={`tasks__board ${ column.tasks.length >= 3 ? "tasks__board__more" : "" @@ -398,7 +398,7 @@ export const ProjectTracker = () => {
)} - {column.tasks.map((task, index) => { + {column.tasks.map((task) => { // if (index > 2) { // if (!column.open) { // return; @@ -454,7 +454,7 @@ export const ProjectTracker = () => { ); })} {Boolean(projectBoard?.columns) && - !Boolean(projectBoard.columns.length) && ( + !projectBoard.columns.length && (
В проекте нет задач.
diff --git a/src/pages/SingleReportPage/SingleReportPage.js b/src/pages/SingleReportPage/SingleReportPage.js index 21f3b05e..455aefed 100644 --- a/src/pages/SingleReportPage/SingleReportPage.js +++ b/src/pages/SingleReportPage/SingleReportPage.js @@ -66,9 +66,9 @@ const SingleReportPage = () => {

Какие задачи были выполнены?

- {tasks.map((task) => { + {tasks.map((task, index) => { return ( -
+
); diff --git a/src/pages/quiz/PassingTests.js b/src/pages/quiz/PassingTests.js index 48ff4238..a5cfc43a 100644 --- a/src/pages/quiz/PassingTests.js +++ b/src/pages/quiz/PassingTests.js @@ -2,7 +2,7 @@ import React, { useState } from "react"; import { useSelector } from "react-redux"; import { Link } from "react-router-dom"; -import { completedTestSelector, selectedTest } from "@redux/quizSlice"; +import { completedTestSelector } from "@redux/quizSlice"; import { Footer } from "@components/Common/Footer/Footer"; import { ProfileBreadcrumbs } from "@components/ProfileBreadcrumbs/ProfileBreadcrumbs"; @@ -14,11 +14,6 @@ import { QuizPassingInformation } from "@components/features/quiz/Quiz-passing-i import { TaskQuiz } from "@components/features/quiz/Task"; export const PassingTests = () => { - //const selectedTest = useSelector(selectedTest) - - if ("") { - } - const time = new Date(); time.setSeconds(time.getSeconds() + 600); //600 - кол-во секунд для прохождения теста diff --git a/src/redux/projectsTrackerSlice.js b/src/redux/projectsTrackerSlice.js index 7d23a60c..eb1937d6 100644 --- a/src/redux/projectsTrackerSlice.js +++ b/src/redux/projectsTrackerSlice.js @@ -57,7 +57,7 @@ export const projectsTrackerSlice = createSlice({ task_id: action.payload.startWrapperIndex.task.id, column_id: column.id, }, - }).then((res) => {}); + }).then(() => {}); } if (column.id === action.payload.startWrapperIndex.index) { state.projectBoard.columns[index].tasks = column.tasks.filter( diff --git a/src/redux/quizSlice.js b/src/redux/quizSlice.js index 845e14af..79264f9b 100644 --- a/src/redux/quizSlice.js +++ b/src/redux/quizSlice.js @@ -117,7 +117,7 @@ export const quizSlice = createSlice({ setSelectedTest: (state, action) => { state.selectedTest = action.payload; }, - setCompleteTest: (state, action) => { + setCompleteTest: (state) => { state.completedTest = true; }, },