From 57658330da2b208d5f04eb93edaf4a1749eaa1e2 Mon Sep 17 00:00:00 2001 From: Ayush Panwar Date: Wed, 10 Jan 2024 01:15:34 +0530 Subject: [PATCH 1/2] replace depracated libraries and move components outside app --- next.config.js | 1 - package-lock.json | 744 +++---------- package.json | 17 +- src/{app => }/Constants/addUserTypes/index.js | 0 src/app/StoreProvider.js | 15 + src/app/actions/user/FetchLoggedInUserData.js | 0 src/app/actions/user/SignIn.js | 0 src/app/change-password/page.js | 51 +- src/app/create-annotation-project/page.js | 995 ----------------- src/app/create-collection-project/page.js | 192 ---- src/app/dataset/DatasetCard.jsx | 8 +- src/app/dataset/DatasetCardList.jsx | 2 +- src/app/dataset/DatasetFilterList.jsx | 12 +- src/app/dataset/automate-dataset/page1.js | 3 +- src/app/dataset/create-dataset/page1.js | 37 +- src/app/dataset/page.js | 10 +- src/app/forgot-password/page.js | 19 +- src/app/invite/page.js | 32 +- src/app/layout.js | 3 +- src/app/login/page.js | 24 +- src/app/new-project/client.js | 969 +++++++++++++++++ src/app/organizations/AddWorkspaceDialog.js | 2 +- src/app/profile/page.js | 12 +- src/app/progress/page.js | 6 +- src/app/projectdetails/page.js | 18 +- src/app/projects/page.js | 16 +- src/app/workspace/AddWorkspaceDialog.js | 2 +- src/app/workspace/BasicWorkspaceSettings.jsx | 12 +- src/app/workspace/DetailsViewPage.js | 39 +- src/app/workspace/ProjectTable.js | 4 +- src/app/workspace/WorkspaceSetting.jsx | 12 +- src/app/workspace/[id]/new-project/page.js | 905 ++++++++++++++++ .../[id]/new-project/shoonya_page.js | 996 ++++++++++++++++++ src/app/workspace/page.js | 4 +- .../components/Project/AllTasksFilterList.jsx | 16 +- .../Project/AllTasksSearchpopup.jsx | 14 +- .../components/Project/FilterList.jsx | 16 +- .../components/Project/InviteUsersDialog.jsx | 15 +- .../components/Project/MembersTable.jsx | 9 +- .../components/Project/ProjectCard.jsx | 11 +- .../components/Project/ProjectCardList.jsx | 8 +- .../components/Project/ReportsTable.jsx | 15 +- .../components/Project/SearchPopup.jsx | 12 +- .../components/Project/SuperChecker.jsx | 9 +- .../components/Project/SuperCheckerFilter.jsx | 16 +- .../components/Project/TaskTable.jsx | 21 +- .../components/Tabs/AnnotatorTable.jsx | 5 +- src/{app => }/components/Tabs/Invites.jsx | 3 +- .../components/Tabs/ManagersTable.jsx | 5 +- src/{app => }/components/Tabs/Members.jsx | 3 +- src/{app => }/components/Tabs/MyProgress.jsx | 39 +- .../components/Tabs/ProjectDescription.jsx | 15 +- src/{app => }/components/Tabs/RecentTasks.jsx | 7 +- .../components/Tabs/organizationReports.jsx | 12 +- .../components/Tabs/organizationSettings.jsx | 3 +- .../UserManagement/ProfileDetails.jsx | 15 +- .../UserManagement/ScheduleMails.jsx | 21 +- .../components/common/AddUsersDialog.jsx | 4 +- .../components/common/BackButton.jsx | 6 +- src/{app => }/components/common/Button.jsx | 0 src/{app => }/components/common/Card.jsx | 0 .../components/common/ColumnList.jsx | 12 +- .../components/common/DatasetCard.jsx | 0 src/{app => }/components/common/MenuItems.jsx | 0 .../components/common/MobileNavbar.jsx | 14 +- src/{app => }/components/common/Modal.jsx | 0 .../components/common/OutlinedTextField.jsx | 0 .../components/common/ProjectCard.jsx | 15 +- .../components/common/ProjectFilterList.jsx | 16 +- src/{app => }/components/common/Search.jsx | 10 +- src/{app => }/components/common/Snackbar.jsx | 0 src/{app => }/components/common/Spinner.jsx | 7 +- .../common/TablePaginationActions.jsx | 0 src/{app => }/components/common/Workspace.jsx | 5 +- .../components/common/WorkspaceReports.jsx | 11 +- .../components/common/WorkspaceTable.jsx | 11 +- src/{app => }/components/user/AppInfo.jsx | 7 +- src/redux/actions/Common.js | 16 - src/redux/actions/domains.js | 36 + src/redux/actions/projects.js | 41 + src/redux/actions/user.js | 36 + src/redux/fetchParams.js | 17 + src/redux/{store => }/store.js | 20 +- src/styles/Dataset.css | 417 ++++++++ src/styles/Dataset.js | 314 ------ src/themes/TableTheme.js | 59 -- src/themes/theme.js | 4 +- 87 files changed, 3936 insertions(+), 2594 deletions(-) rename src/{app => }/Constants/addUserTypes/index.js (100%) create mode 100644 src/app/StoreProvider.js delete mode 100644 src/app/actions/user/FetchLoggedInUserData.js delete mode 100644 src/app/actions/user/SignIn.js delete mode 100644 src/app/create-annotation-project/page.js delete mode 100644 src/app/create-collection-project/page.js create mode 100644 src/app/new-project/client.js create mode 100644 src/app/workspace/[id]/new-project/page.js create mode 100644 src/app/workspace/[id]/new-project/shoonya_page.js rename src/{app => }/components/Project/AllTasksFilterList.jsx (91%) rename src/{app => }/components/Project/AllTasksSearchpopup.jsx (90%) rename src/{app => }/components/Project/FilterList.jsx (94%) rename src/{app => }/components/Project/InviteUsersDialog.jsx (93%) rename src/{app => }/components/Project/MembersTable.jsx (98%) rename src/{app => }/components/Project/ProjectCard.jsx (93%) rename src/{app => }/components/Project/ProjectCardList.jsx (96%) rename src/{app => }/components/Project/ReportsTable.jsx (98%) rename src/{app => }/components/Project/SearchPopup.jsx (88%) rename src/{app => }/components/Project/SuperChecker.jsx (85%) rename src/{app => }/components/Project/SuperCheckerFilter.jsx (88%) rename src/{app => }/components/Project/TaskTable.jsx (99%) rename src/{app => }/components/Tabs/AnnotatorTable.jsx (98%) rename src/{app => }/components/Tabs/Invites.jsx (97%) rename src/{app => }/components/Tabs/ManagersTable.jsx (98%) rename src/{app => }/components/Tabs/Members.jsx (88%) rename src/{app => }/components/Tabs/MyProgress.jsx (95%) rename src/{app => }/components/Tabs/ProjectDescription.jsx (74%) rename src/{app => }/components/Tabs/RecentTasks.jsx (97%) rename src/{app => }/components/Tabs/organizationReports.jsx (98%) rename src/{app => }/components/Tabs/organizationSettings.jsx (94%) rename src/{app => }/components/UserManagement/ProfileDetails.jsx (95%) rename src/{app => }/components/UserManagement/ScheduleMails.jsx (97%) rename src/{app => }/components/common/AddUsersDialog.jsx (98%) rename src/{app => }/components/common/BackButton.jsx (61%) rename src/{app => }/components/common/Button.jsx (100%) rename src/{app => }/components/common/Card.jsx (100%) rename src/{app => }/components/common/ColumnList.jsx (90%) rename src/{app => }/components/common/DatasetCard.jsx (100%) rename src/{app => }/components/common/MenuItems.jsx (100%) rename src/{app => }/components/common/MobileNavbar.jsx (94%) rename src/{app => }/components/common/Modal.jsx (100%) rename src/{app => }/components/common/OutlinedTextField.jsx (100%) rename src/{app => }/components/common/ProjectCard.jsx (90%) rename src/{app => }/components/common/ProjectFilterList.jsx (92%) rename src/{app => }/components/common/Search.jsx (85%) rename src/{app => }/components/common/Snackbar.jsx (100%) rename src/{app => }/components/common/Spinner.jsx (76%) rename src/{app => }/components/common/TablePaginationActions.jsx (100%) rename src/{app => }/components/common/Workspace.jsx (72%) rename src/{app => }/components/common/WorkspaceReports.jsx (97%) rename src/{app => }/components/common/WorkspaceTable.jsx (94%) rename src/{app => }/components/user/AppInfo.jsx (66%) delete mode 100644 src/redux/actions/Common.js create mode 100644 src/redux/actions/domains.js create mode 100644 src/redux/actions/projects.js create mode 100644 src/redux/actions/user.js create mode 100644 src/redux/fetchParams.js rename src/redux/{store => }/store.js (66%) create mode 100644 src/styles/Dataset.css delete mode 100644 src/styles/Dataset.js delete mode 100644 src/themes/TableTheme.js diff --git a/next.config.js b/next.config.js index 491d8796..3ff8c46a 100644 --- a/next.config.js +++ b/next.config.js @@ -1,6 +1,5 @@ /** @type {import('next').NextConfig} */ const nextConfig = { - output: 'export', images: { unoptimized: true } } diff --git a/package-lock.json b/package-lock.json index 7e98ce60..12bf4b5d 100644 --- a/package-lock.json +++ b/package-lock.json @@ -10,26 +10,19 @@ "dependencies": { "@emotion/react": "^11.11.1", "@emotion/styled": "^11.11.0", - "@material-ui/core": "^4.12.4", - "@material-ui/icons": "^4.11.3", "@mui/icons-material": "^5.14.18", "@mui/material": "^5.14.18", - "@mui/styles": "^5.14.18", - "@mui/x-date-pickers-pro": "^6.18.4", + "@reduxjs/toolkit": "^2.0.1", "axios": "^1.6.3", + "date-fns": "^3.2.0", "firebase": "^10.7.1", "firebase-auth": "^0.1.2", "mui-datatables": "^4.3.0", - "next": "14.0.3", + "next": "^14.0.4", "react": "^18", - "react-date-range": "^1.4.0", + "react-date-range": "^2.0.0-alpha.4", "react-dom": "^18", - "react-router-dom": "^6.20.1", - "redux": "^5.0.1", - "redux-devtools-extension": "^2.13.9", - "redux-logger": "^3.0.6", - "redux-persist": "^6.0.0", - "redux-thunk": "^3.1.0" + "react-redux": "^9.0.4" }, "devDependencies": { "autoprefixer": "^10.4.16", @@ -1110,182 +1103,6 @@ "@jridgewell/sourcemap-codec": "^1.4.14" } }, - "node_modules/@material-ui/core": { - "version": "4.12.4", - "resolved": "https://registry.npmjs.org/@material-ui/core/-/core-4.12.4.tgz", - "integrity": "sha512-tr7xekNlM9LjA6pagJmL8QCgZXaubWUwkJnoYcMKd4gw/t4XiyvnTkjdGrUVicyB2BsdaAv1tvow45bPM4sSwQ==", - "deprecated": "Material UI v4 doesn't receive active development since September 2021. See the guide https://mui.com/material-ui/migration/migration-v4/ to upgrade to v5.", - "dependencies": { - "@babel/runtime": "^7.4.4", - "@material-ui/styles": "^4.11.5", - "@material-ui/system": "^4.12.2", - "@material-ui/types": "5.1.0", - "@material-ui/utils": "^4.11.3", - "@types/react-transition-group": "^4.2.0", - "clsx": "^1.0.4", - "hoist-non-react-statics": "^3.3.2", - "popper.js": "1.16.1-lts", - "prop-types": "^15.7.2", - "react-is": "^16.8.0 || ^17.0.0", - "react-transition-group": "^4.4.0" - }, - "engines": { - "node": ">=8.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/material-ui" - }, - "peerDependencies": { - "@types/react": "^16.8.6 || ^17.0.0", - "react": "^16.8.0 || ^17.0.0", - "react-dom": "^16.8.0 || ^17.0.0" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@material-ui/core/node_modules/@emotion/hash": { - "version": "0.8.0", - "resolved": "https://registry.npmjs.org/@emotion/hash/-/hash-0.8.0.tgz", - "integrity": "sha512-kBJtf7PH6aWwZ6fka3zQ0p6SBYzx4fl1LoZXE2RrnYST9Xljm7WfKJrU4g/Xr3Beg72MLrp1AWNUmuYJTL7Cow==" - }, - "node_modules/@material-ui/core/node_modules/@material-ui/styles": { - "version": "4.11.5", - "resolved": "https://registry.npmjs.org/@material-ui/styles/-/styles-4.11.5.tgz", - "integrity": "sha512-o/41ot5JJiUsIETME9wVLAJrmIWL3j0R0Bj2kCOLbSfqEkKf0fmaPt+5vtblUh5eXr2S+J/8J3DaCb10+CzPGA==", - "deprecated": "Material UI v4 doesn't receive active development since September 2021. See the guide https://mui.com/material-ui/migration/migration-v4/ to upgrade to v5.", - "dependencies": { - "@babel/runtime": "^7.4.4", - "@emotion/hash": "^0.8.0", - "@material-ui/types": "5.1.0", - "@material-ui/utils": "^4.11.3", - "clsx": "^1.0.4", - "csstype": "^2.5.2", - "hoist-non-react-statics": "^3.3.2", - "jss": "^10.5.1", - "jss-plugin-camel-case": "^10.5.1", - "jss-plugin-default-unit": "^10.5.1", - "jss-plugin-global": "^10.5.1", - "jss-plugin-nested": "^10.5.1", - "jss-plugin-props-sort": "^10.5.1", - "jss-plugin-rule-value-function": "^10.5.1", - "jss-plugin-vendor-prefixer": "^10.5.1", - "prop-types": "^15.7.2" - }, - "engines": { - "node": ">=8.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/material-ui" - }, - "peerDependencies": { - "@types/react": "^16.8.6 || ^17.0.0", - "react": "^16.8.0 || ^17.0.0", - "react-dom": "^16.8.0 || ^17.0.0" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@material-ui/core/node_modules/@material-ui/system": { - "version": "4.12.2", - "resolved": "https://registry.npmjs.org/@material-ui/system/-/system-4.12.2.tgz", - "integrity": "sha512-6CSKu2MtmiJgcCGf6nBQpM8fLkuB9F55EKfbdTC80NND5wpTmKzwdhLYLH3zL4cLlK0gVaaltW7/wMuyTnN0Lw==", - "dependencies": { - "@babel/runtime": "^7.4.4", - "@material-ui/utils": "^4.11.3", - "csstype": "^2.5.2", - "prop-types": "^15.7.2" - }, - "engines": { - "node": ">=8.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/material-ui" - }, - "peerDependencies": { - "@types/react": "^16.8.6 || ^17.0.0", - "react": "^16.8.0 || ^17.0.0", - "react-dom": "^16.8.0 || ^17.0.0" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@material-ui/core/node_modules/@material-ui/utils": { - "version": "4.11.3", - "resolved": "https://registry.npmjs.org/@material-ui/utils/-/utils-4.11.3.tgz", - "integrity": "sha512-ZuQPV4rBK/V1j2dIkSSEcH5uT6AaHuKWFfotADHsC0wVL1NLd2WkFCm4ZZbX33iO4ydl6V0GPngKm8HZQ2oujg==", - "dependencies": { - "@babel/runtime": "^7.4.4", - "prop-types": "^15.7.2", - "react-is": "^16.8.0 || ^17.0.0" - }, - "engines": { - "node": ">=8.0.0" - }, - "peerDependencies": { - "react": "^16.8.0 || ^17.0.0", - "react-dom": "^16.8.0 || ^17.0.0" - } - }, - "node_modules/@material-ui/core/node_modules/clsx": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/clsx/-/clsx-1.2.1.tgz", - "integrity": "sha512-EcR6r5a8bj6pu3ycsa/E/cKVGuTgZJZdsyUYHOksG/UHIiKfjxzRxYJpyVBwYaQeOvghal9fcc4PidlgzugAQg==", - "engines": { - "node": ">=6" - } - }, - "node_modules/@material-ui/core/node_modules/csstype": { - "version": "2.6.21", - "resolved": "https://registry.npmjs.org/csstype/-/csstype-2.6.21.tgz", - "integrity": "sha512-Z1PhmomIfypOpoMjRQB70jfvy/wxT50qW08YXO5lMIJkrdq4yOTR+AW7FqutScmB9NkLwxo+jU+kZLbofZZq/w==" - }, - "node_modules/@material-ui/icons": { - "version": "4.11.3", - "resolved": "https://registry.npmjs.org/@material-ui/icons/-/icons-4.11.3.tgz", - "integrity": "sha512-IKHlyx6LDh8n19vzwH5RtHIOHl9Tu90aAAxcbWME6kp4dmvODM3UvOHJeMIDzUbd4muuJKHmlNoBN+mDY4XkBA==", - "dependencies": { - "@babel/runtime": "^7.4.4" - }, - "engines": { - "node": ">=8.0.0" - }, - "peerDependencies": { - "@material-ui/core": "^4.0.0", - "@types/react": "^16.8.6 || ^17.0.0", - "react": "^16.8.0 || ^17.0.0", - "react-dom": "^16.8.0 || ^17.0.0" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, - "node_modules/@material-ui/types": { - "version": "5.1.0", - "resolved": "https://registry.npmjs.org/@material-ui/types/-/types-5.1.0.tgz", - "integrity": "sha512-7cqRjrY50b8QzRSYyhSpx4WRw2YuO0KKIGQEVk5J8uoz2BanawykgZGoWEqKm7pVIbzFDN0SpPcVV4IhOFkl8A==", - "peerDependencies": { - "@types/react": "*" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, "node_modules/@mui/base": { "version": "5.0.0-beta.24", "resolved": "https://registry.npmjs.org/@mui/base/-/base-5.0.0-beta.24.tgz", @@ -1457,46 +1274,6 @@ } } }, - "node_modules/@mui/styles": { - "version": "5.14.18", - "resolved": "https://registry.npmjs.org/@mui/styles/-/styles-5.14.18.tgz", - "integrity": "sha512-dllIn149Fd6xzlf743y5jGbr61V/8qR1JWiwsOc5NAx5eTIooHpJxEfiVErHDpChCaHjlfR6upxvcNDq8IvT2w==", - "dependencies": { - "@babel/runtime": "^7.23.2", - "@emotion/hash": "^0.9.1", - "@mui/private-theming": "^5.14.18", - "@mui/types": "^7.2.9", - "@mui/utils": "^5.14.18", - "clsx": "^2.0.0", - "csstype": "^3.1.2", - "hoist-non-react-statics": "^3.3.2", - "jss": "^10.10.0", - "jss-plugin-camel-case": "^10.10.0", - "jss-plugin-default-unit": "^10.10.0", - "jss-plugin-global": "^10.10.0", - "jss-plugin-nested": "^10.10.0", - "jss-plugin-props-sort": "^10.10.0", - "jss-plugin-rule-value-function": "^10.10.0", - "jss-plugin-vendor-prefixer": "^10.10.0", - "prop-types": "^15.8.1" - }, - "engines": { - "node": ">=12.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/mui" - }, - "peerDependencies": { - "@types/react": "^17.0.0 || ^18.0.0", - "react": "^17.0.0" - }, - "peerDependenciesMeta": { - "@types/react": { - "optional": true - } - } - }, "node_modules/@mui/system": { "version": "5.14.18", "resolved": "https://registry.npmjs.org/@mui/system/-/system-5.14.18.tgz", @@ -1581,152 +1358,10 @@ "resolved": "https://registry.npmjs.org/react-is/-/react-is-18.2.0.tgz", "integrity": "sha512-xWGDIW6x921xtzPkhiULtthJHoJvBbF3q26fzloPCK0hsvxtPVelvftw3zjbHWSkR2km9Z+4uxbDDK/6Zw9B8w==" }, - "node_modules/@mui/x-date-pickers": { - "version": "6.18.4", - "resolved": "https://registry.npmjs.org/@mui/x-date-pickers/-/x-date-pickers-6.18.4.tgz", - "integrity": "sha512-YqJ6lxZHBIt344B3bvRAVbdYSQz4dcmJQXGcfvJTn26VdKjpgzjAqwhlbQhbAt55audJOWzGB99ImuQuljDROA==", - "dependencies": { - "@babel/runtime": "^7.23.2", - "@mui/base": "^5.0.0-beta.22", - "@mui/utils": "^5.14.16", - "@types/react-transition-group": "^4.4.8", - "clsx": "^2.0.0", - "prop-types": "^15.8.1", - "react-transition-group": "^4.4.5" - }, - "engines": { - "node": ">=14.0.0" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/mui" - }, - "peerDependencies": { - "@emotion/react": "^11.9.0", - "@emotion/styled": "^11.8.1", - "@mui/material": "^5.8.6", - "@mui/system": "^5.8.0", - "date-fns": "^2.25.0", - "date-fns-jalali": "^2.13.0-0", - "dayjs": "^1.10.7", - "luxon": "^3.0.2", - "moment": "^2.29.4", - "moment-hijri": "^2.1.2", - "moment-jalaali": "^0.7.4 || ^0.8.0 || ^0.9.0 || ^0.10.0", - "react": "^17.0.0 || ^18.0.0", - "react-dom": "^17.0.0 || ^18.0.0" - }, - "peerDependenciesMeta": { - "@emotion/react": { - "optional": true - }, - "@emotion/styled": { - "optional": true - }, - "date-fns": { - "optional": true - }, - "date-fns-jalali": { - "optional": true - }, - "dayjs": { - "optional": true - }, - "luxon": { - "optional": true - }, - "moment": { - "optional": true - }, - "moment-hijri": { - "optional": true - }, - "moment-jalaali": { - "optional": true - } - } - }, - "node_modules/@mui/x-date-pickers-pro": { - "version": "6.18.4", - "resolved": "https://registry.npmjs.org/@mui/x-date-pickers-pro/-/x-date-pickers-pro-6.18.4.tgz", - "integrity": "sha512-0znZmEXn95TFfpyz5q9tcjUoJLXPcS1XFj7VaA12NJJotkYtW13Bg7idEOQqlNNhuLD/nDtEI3grYtdoQB+n5Q==", - "dependencies": { - "@babel/runtime": "^7.23.2", - "@mui/base": "^5.0.0-beta.22", - "@mui/utils": "^5.14.16", - "@mui/x-date-pickers": "6.18.4", - "@mui/x-license-pro": "6.10.2", - "clsx": "^2.0.0", - "prop-types": "^15.8.1", - "react-transition-group": "^4.4.5" - }, - "engines": { - "node": ">=14.0.0" - }, - "peerDependencies": { - "@emotion/react": "^11.9.0", - "@emotion/styled": "^11.8.1", - "@mui/material": "^5.8.6", - "@mui/system": "^5.8.0", - "date-fns": "^2.25.0", - "date-fns-jalali": "^2.13.0-0", - "dayjs": "^1.10.7", - "luxon": "^3.0.2", - "moment": "^2.29.4", - "moment-hijri": "^2.1.2", - "moment-jalaali": "^0.7.4 || ^0.8.0 || ^0.9.0 || ^0.10.0", - "react": "^17.0.0 || ^18.0.0", - "react-dom": "^17.0.0 || ^18.0.0" - }, - "peerDependenciesMeta": { - "@emotion/react": { - "optional": true - }, - "@emotion/styled": { - "optional": true - }, - "date-fns": { - "optional": true - }, - "date-fns-jalali": { - "optional": true - }, - "dayjs": { - "optional": true - }, - "luxon": { - "optional": true - }, - "moment": { - "optional": true - }, - "moment-hijri": { - "optional": true - }, - "moment-jalaali": { - "optional": true - } - } - }, - "node_modules/@mui/x-license-pro": { - "version": "6.10.2", - "resolved": "https://registry.npmjs.org/@mui/x-license-pro/-/x-license-pro-6.10.2.tgz", - "integrity": "sha512-Baw3shilU+eHgU+QYKNPFUKvfS5rSyNJ98pQx02E0gKA22hWp/XAt88K1qUfUMPlkPpvg/uci6gviQSSLZkuKw==", - "dependencies": { - "@babel/runtime": "^7.22.6", - "@mui/utils": "^5.13.7" - }, - "engines": { - "node": ">=14.0.0" - }, - "peerDependencies": { - "react": "^17.0.0 || ^18.0.0" - } - }, "node_modules/@next/env": { - "version": "14.0.3", - "resolved": "https://registry.npmjs.org/@next/env/-/env-14.0.3.tgz", - "integrity": "sha512-7xRqh9nMvP5xrW4/+L0jgRRX+HoNRGnfJpD+5Wq6/13j3dsdzxO3BCXn7D3hMqsDb+vjZnJq+vI7+EtgrYZTeA==" + "version": "14.0.4", + "resolved": "https://registry.npmjs.org/@next/env/-/env-14.0.4.tgz", + "integrity": "sha512-irQnbMLbUNQpP1wcE5NstJtbuA/69kRfzBrpAD7Gsn8zm/CY6YQYc3HQBz8QPxwISG26tIm5afvvVbu508oBeQ==" }, "node_modules/@next/eslint-plugin-next": { "version": "14.0.3", @@ -1738,9 +1373,9 @@ } }, "node_modules/@next/swc-darwin-arm64": { - "version": "14.0.3", - "resolved": "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-14.0.3.tgz", - "integrity": "sha512-64JbSvi3nbbcEtyitNn2LEDS/hcleAFpHdykpcnrstITFlzFgB/bW0ER5/SJJwUPj+ZPY+z3e+1jAfcczRLVGw==", + "version": "14.0.4", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-14.0.4.tgz", + "integrity": "sha512-mF05E/5uPthWzyYDyptcwHptucf/jj09i2SXBPwNzbgBNc+XnwzrL0U6BmPjQeOL+FiB+iG1gwBeq7mlDjSRPg==", "cpu": [ "arm64" ], @@ -1753,9 +1388,9 @@ } }, "node_modules/@next/swc-darwin-x64": { - "version": "14.0.3", - "resolved": "https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-14.0.3.tgz", - "integrity": "sha512-RkTf+KbAD0SgYdVn1XzqE/+sIxYGB7NLMZRn9I4Z24afrhUpVJx6L8hsRnIwxz3ERE2NFURNliPjJ2QNfnWicQ==", + "version": "14.0.4", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-14.0.4.tgz", + "integrity": "sha512-IZQ3C7Bx0k2rYtrZZxKKiusMTM9WWcK5ajyhOZkYYTCc8xytmwSzR1skU7qLgVT/EY9xtXDG0WhY6fyujnI3rw==", "cpu": [ "x64" ], @@ -1768,9 +1403,9 @@ } }, "node_modules/@next/swc-linux-arm64-gnu": { - "version": "14.0.3", - "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-14.0.3.tgz", - "integrity": "sha512-3tBWGgz7M9RKLO6sPWC6c4pAw4geujSwQ7q7Si4d6bo0l6cLs4tmO+lnSwFp1Tm3lxwfMk0SgkJT7EdwYSJvcg==", + "version": "14.0.4", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-14.0.4.tgz", + "integrity": "sha512-VwwZKrBQo/MGb1VOrxJ6LrKvbpo7UbROuyMRvQKTFKhNaXjUmKTu7wxVkIuCARAfiI8JpaWAnKR+D6tzpCcM4w==", "cpu": [ "arm64" ], @@ -1783,9 +1418,9 @@ } }, "node_modules/@next/swc-linux-arm64-musl": { - "version": "14.0.3", - "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-14.0.3.tgz", - "integrity": "sha512-v0v8Kb8j8T23jvVUWZeA2D8+izWspeyeDGNaT2/mTHWp7+37fiNfL8bmBWiOmeumXkacM/AB0XOUQvEbncSnHA==", + "version": "14.0.4", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-14.0.4.tgz", + "integrity": "sha512-8QftwPEW37XxXoAwsn+nXlodKWHfpMaSvt81W43Wh8dv0gkheD+30ezWMcFGHLI71KiWmHK5PSQbTQGUiidvLQ==", "cpu": [ "arm64" ], @@ -1798,9 +1433,9 @@ } }, "node_modules/@next/swc-linux-x64-gnu": { - "version": "14.0.3", - "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-14.0.3.tgz", - "integrity": "sha512-VM1aE1tJKLBwMGtyBR21yy+STfl0MapMQnNrXkxeyLs0GFv/kZqXS5Jw/TQ3TSUnbv0QPDf/X8sDXuMtSgG6eg==", + "version": "14.0.4", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-14.0.4.tgz", + "integrity": "sha512-/s/Pme3VKfZAfISlYVq2hzFS8AcAIOTnoKupc/j4WlvF6GQ0VouS2Q2KEgPuO1eMBwakWPB1aYFIA4VNVh667A==", "cpu": [ "x64" ], @@ -1813,9 +1448,9 @@ } }, "node_modules/@next/swc-linux-x64-musl": { - "version": "14.0.3", - "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-14.0.3.tgz", - "integrity": "sha512-64EnmKy18MYFL5CzLaSuUn561hbO1Gk16jM/KHznYP3iCIfF9e3yULtHaMy0D8zbHfxset9LTOv6cuYKJgcOxg==", + "version": "14.0.4", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-14.0.4.tgz", + "integrity": "sha512-m8z/6Fyal4L9Bnlxde5g2Mfa1Z7dasMQyhEhskDATpqr+Y0mjOBZcXQ7G5U+vgL22cI4T7MfvgtrM2jdopqWaw==", "cpu": [ "x64" ], @@ -1828,9 +1463,9 @@ } }, "node_modules/@next/swc-win32-arm64-msvc": { - "version": "14.0.3", - "resolved": "https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-14.0.3.tgz", - "integrity": "sha512-WRDp8QrmsL1bbGtsh5GqQ/KWulmrnMBgbnb+59qNTW1kVi1nG/2ndZLkcbs2GX7NpFLlToLRMWSQXmPzQm4tog==", + "version": "14.0.4", + "resolved": "https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-14.0.4.tgz", + "integrity": "sha512-7Wv4PRiWIAWbm5XrGz3D8HUkCVDMMz9igffZG4NB1p4u1KoItwx9qjATHz88kwCEal/HXmbShucaslXCQXUM5w==", "cpu": [ "arm64" ], @@ -1843,9 +1478,9 @@ } }, "node_modules/@next/swc-win32-ia32-msvc": { - "version": "14.0.3", - "resolved": "https://registry.npmjs.org/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-14.0.3.tgz", - "integrity": "sha512-EKffQeqCrj+t6qFFhIFTRoqb2QwX1mU7iTOvMyLbYw3QtqTw9sMwjykyiMlZlrfm2a4fA84+/aeW+PMg1MjuTg==", + "version": "14.0.4", + "resolved": "https://registry.npmjs.org/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-14.0.4.tgz", + "integrity": "sha512-zLeNEAPULsl0phfGb4kdzF/cAVIfaC7hY+kt0/d+y9mzcZHsMS3hAS829WbJ31DkSlVKQeHEjZHIdhN+Pg7Gyg==", "cpu": [ "ia32" ], @@ -1858,9 +1493,9 @@ } }, "node_modules/@next/swc-win32-x64-msvc": { - "version": "14.0.3", - "resolved": "https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-14.0.3.tgz", - "integrity": "sha512-ERhKPSJ1vQrPiwrs15Pjz/rvDHZmkmvbf/BjPN/UCOI++ODftT0GtasDPi0j+y6PPJi5HsXw+dpRaXUaw4vjuQ==", + "version": "14.0.4", + "resolved": "https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-14.0.4.tgz", + "integrity": "sha512-yEh2+R8qDlDCjxVpzOTEpBLQTEFAcP2A8fUFLaWNap9GitYKkKv1//y2S6XY6zsR4rCOPRpU7plYDR+az2n30A==", "cpu": [ "x64" ], @@ -1985,12 +1620,27 @@ "resolved": "https://registry.npmjs.org/@react-dnd/shallowequal/-/shallowequal-2.0.0.tgz", "integrity": "sha512-Pc/AFTdwZwEKJxFJvlxrSmGe/di+aAOBn60sremrpLo6VI/6cmiUYNNwlI5KNYttg7uypzA3ILPMPgxB2GYZEg==" }, - "node_modules/@remix-run/router": { - "version": "1.13.1", - "resolved": "https://registry.npmjs.org/@remix-run/router/-/router-1.13.1.tgz", - "integrity": "sha512-so+DHzZKsoOcoXrILB4rqDkMDy7NLMErRdOxvzvOKb507YINKUP4Di+shbTZDhSE/pBZ+vr7XGIpcOO0VLSA+Q==", - "engines": { - "node": ">=14.0.0" + "node_modules/@reduxjs/toolkit": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/@reduxjs/toolkit/-/toolkit-2.0.1.tgz", + "integrity": "sha512-fxIjrR9934cmS8YXIGd9e7s1XRsEU++aFc9DVNMFMRTM5Vtsg2DCRMj21eslGtDt43IUf9bJL3h5bwUlZleibA==", + "dependencies": { + "immer": "^10.0.3", + "redux": "^5.0.0", + "redux-thunk": "^3.1.0", + "reselect": "^5.0.1" + }, + "peerDependencies": { + "react": "^16.9.0 || ^17.0.0 || ^18", + "react-redux": "^7.2.1 || ^8.1.3 || ^9.0.0" + }, + "peerDependenciesMeta": { + "react": { + "optional": true + }, + "react-redux": { + "optional": true + } } }, "node_modules/@rushstack/eslint-patch": { @@ -2041,9 +1691,9 @@ "integrity": "sha512-ga8y9v9uyeiLdpKddhxYQkxNDrfvuPrlFb0N1qnZZByvcElJaXthF1UhvCh9TLWJBEHeNtdnbysW7Y6Uq8CVng==" }, "node_modules/@types/react": { - "version": "17.0.71", - "resolved": "https://registry.npmjs.org/@types/react/-/react-17.0.71.tgz", - "integrity": "sha512-lfqOu9mp16nmaGRrS8deS2Taqhd5Ih0o92Te5Ws6I1py4ytHBcXLqh0YIqVsViqwVI5f+haiFM6hju814BzcmA==", + "version": "18.2.47", + "resolved": "https://registry.npmjs.org/@types/react/-/react-18.2.47.tgz", + "integrity": "sha512-xquNkkOirwyCgoClNk85BjP+aqnIS+ckAJ8i37gAbDs14jfW/J23f2GItAf33oiUPQnqNMALiFeoM9Y5mbjpVQ==", "dependencies": { "@types/prop-types": "*", "@types/scheduler": "*", @@ -2063,6 +1713,11 @@ "resolved": "https://registry.npmjs.org/@types/scheduler/-/scheduler-0.16.8.tgz", "integrity": "sha512-WZLiwShhwLRmeV6zH+GkbOFT6Z6VklCItrDioxUnv+u4Ll+8vKeFySoFyK/0ctcRpOmwAicELfmys1sDc/Rw+A==" }, + "node_modules/@types/use-sync-external-store": { + "version": "0.0.3", + "resolved": "https://registry.npmjs.org/@types/use-sync-external-store/-/use-sync-external-store-0.0.3.tgz", + "integrity": "sha512-EwmlvuaxPNej9+T4v5AuBPJa2x2UOJVdjCtDHgcDqitUeOtjnJKJ+apYjVcAoBEMjKW1VVFGZLUb5+qqa09XFA==" + }, "node_modules/@typescript-eslint/parser": { "version": "6.12.0", "resolved": "https://registry.npmjs.org/@typescript-eslint/parser/-/parser-6.12.0.tgz", @@ -2712,9 +2367,9 @@ } }, "node_modules/classnames": { - "version": "2.3.2", - "resolved": "https://registry.npmjs.org/classnames/-/classnames-2.3.2.tgz", - "integrity": "sha512-CSbhY4cFEJRe6/GQzIk5qXZ4Jeg5pcsP7b5peFSDpffpe1cqjASH/n9UTjBwOp6XpMSTwQ8Za2K5V02ueA7Tmw==" + "version": "2.5.1", + "resolved": "https://registry.npmjs.org/classnames/-/classnames-2.5.1.tgz", + "integrity": "sha512-saHYOzhIQs6wy2sVxTM6bUDsQO4F50V9RQ22qBpEdCW+I+/Wmke2HOl6lS6dTpdxVhb88/I6+Hs+438c3lfUow==" }, "node_modules/client-only": { "version": "0.0.1", @@ -2834,15 +2489,6 @@ "node": ">= 8" } }, - "node_modules/css-vendor": { - "version": "2.0.8", - "resolved": "https://registry.npmjs.org/css-vendor/-/css-vendor-2.0.8.tgz", - "integrity": "sha512-x9Aq0XTInxrkuFeHKbYC7zWY8ai7qJ04Kxd9MnvbC1uO5DagxoHQjm4JvG+vCdXOoFtCjbL2XSZfxmoYa9uQVQ==", - "dependencies": { - "@babel/runtime": "^7.8.3", - "is-in-browser": "^1.0.2" - } - }, "node_modules/cssesc": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/cssesc/-/cssesc-3.0.0.tgz", @@ -2867,19 +2513,12 @@ "dev": true }, "node_modules/date-fns": { - "version": "2.30.0", - "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-2.30.0.tgz", - "integrity": "sha512-fnULvOpxnC5/Vg3NCiWelDsLiUc9bRwAPs/+LfTLNvetFCtCTN+yQz15C/fs4AwX1R9K5GLtLfn8QW+dWisaAw==", - "peer": true, - "dependencies": { - "@babel/runtime": "^7.21.0" - }, - "engines": { - "node": ">=0.11" - }, + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/date-fns/-/date-fns-3.2.0.tgz", + "integrity": "sha512-E4KWKavANzeuusPi0jUjpuI22SURAznGkx7eZV+4i6x2A+IZxAMcajgkvuDAU1bg40+xuhW1zRdVIIM/4khuIg==", "funding": { - "type": "opencollective", - "url": "https://opencollective.com/date-fns" + "type": "github", + "url": "https://github.com/sponsors/kossnocorp" } }, "node_modules/debug": { @@ -2899,11 +2538,6 @@ } } }, - "node_modules/deep-diff": { - "version": "0.3.8", - "resolved": "https://registry.npmjs.org/deep-diff/-/deep-diff-0.3.8.tgz", - "integrity": "sha512-yVn6RZmHiGnxRKR9sJb3iVV2XTF1Ghh2DiWRZ3dMnGc43yUdWWF/kX6lQyk3+P84iprfWKU/8zFTrlkvtFm1ug==" - }, "node_modules/deep-is": { "version": "0.1.4", "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", @@ -3847,9 +3481,9 @@ "dev": true }, "node_modules/follow-redirects": { - "version": "1.15.3", - "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.3.tgz", - "integrity": "sha512-1VzOtuEM8pC9SFU1E+8KfTjZyMztRsgEfwQl44z8A25uy13jSzTj6dyK2Df52iV0vgHCfBwLhDWevLn95w5v6Q==", + "version": "1.15.4", + "resolved": "https://registry.npmjs.org/follow-redirects/-/follow-redirects-1.15.4.tgz", + "integrity": "sha512-Cr4D/5wlrb0z9dgERpUL3LrmPKVDsETIJhaCMeDfuFYcqa5bldGV6wBsAN6X/vxlXQtFBMrXdXxdL8CbDTGniw==", "funding": [ { "type": "individual", @@ -4273,11 +3907,6 @@ "resolved": "https://registry.npmjs.org/http-parser-js/-/http-parser-js-0.5.8.tgz", "integrity": "sha512-SGeBX54F94Wgu5RH3X5jsDtf4eHyRogWX1XGT3b4HuW3tQPM4AaBzoUji/4AAJNXCEOWZ5O0DgZmJw1947gD5Q==" }, - "node_modules/hyphenate-style-name": { - "version": "1.0.4", - "resolved": "https://registry.npmjs.org/hyphenate-style-name/-/hyphenate-style-name-1.0.4.tgz", - "integrity": "sha512-ygGZLjmXfPHj+ZWh6LwbC37l43MhfztxetbFCoYTM2VjkIUpeHgSNn7QIyVFj7YQ1Wl9Cbw5sholVJPzWvC2MQ==" - }, "node_modules/idb": { "version": "7.1.1", "resolved": "https://registry.npmjs.org/idb/-/idb-7.1.1.tgz", @@ -4292,6 +3921,15 @@ "node": ">= 4" } }, + "node_modules/immer": { + "version": "10.0.3", + "resolved": "https://registry.npmjs.org/immer/-/immer-10.0.3.tgz", + "integrity": "sha512-pwupu3eWfouuaowscykeckFmVTpqbzW+rXFCX8rQLkZzM9ftBmU/++Ra+o+L27mz03zJTlyV4UUr+fdKNffo4A==", + "funding": { + "type": "opencollective", + "url": "https://opencollective.com/immer" + } + }, "node_modules/import-fresh": { "version": "3.3.0", "resolved": "https://registry.npmjs.org/import-fresh/-/import-fresh-3.3.0.tgz", @@ -4514,11 +4152,6 @@ "node": ">=0.10.0" } }, - "node_modules/is-in-browser": { - "version": "1.1.3", - "resolved": "https://registry.npmjs.org/is-in-browser/-/is-in-browser-1.1.3.tgz", - "integrity": "sha512-FeXIBgG/CPGd/WUxuEyvgGTEfwiG9Z4EKGxjNMRqviiIIfsmgrpnHLffEDdwUHqNva1VEW91o3xBT/m8Elgl9g==" - }, "node_modules/is-map": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/is-map/-/is-map-2.0.2.tgz", @@ -4787,88 +4420,6 @@ "graceful-fs": "^4.1.6" } }, - "node_modules/jss": { - "version": "10.10.0", - "resolved": "https://registry.npmjs.org/jss/-/jss-10.10.0.tgz", - "integrity": "sha512-cqsOTS7jqPsPMjtKYDUpdFC0AbhYFLTcuGRqymgmdJIeQ8cH7+AgX7YSgQy79wXloZq2VvATYxUOUQEvS1V/Zw==", - "dependencies": { - "@babel/runtime": "^7.3.1", - "csstype": "^3.0.2", - "is-in-browser": "^1.1.3", - "tiny-warning": "^1.0.2" - }, - "funding": { - "type": "opencollective", - "url": "https://opencollective.com/jss" - } - }, - "node_modules/jss-plugin-camel-case": { - "version": "10.10.0", - "resolved": "https://registry.npmjs.org/jss-plugin-camel-case/-/jss-plugin-camel-case-10.10.0.tgz", - "integrity": "sha512-z+HETfj5IYgFxh1wJnUAU8jByI48ED+v0fuTuhKrPR+pRBYS2EDwbusU8aFOpCdYhtRc9zhN+PJ7iNE8pAWyPw==", - "dependencies": { - "@babel/runtime": "^7.3.1", - "hyphenate-style-name": "^1.0.3", - "jss": "10.10.0" - } - }, - "node_modules/jss-plugin-default-unit": { - "version": "10.10.0", - "resolved": "https://registry.npmjs.org/jss-plugin-default-unit/-/jss-plugin-default-unit-10.10.0.tgz", - "integrity": "sha512-SvpajxIECi4JDUbGLefvNckmI+c2VWmP43qnEy/0eiwzRUsafg5DVSIWSzZe4d2vFX1u9nRDP46WCFV/PXVBGQ==", - "dependencies": { - "@babel/runtime": "^7.3.1", - "jss": "10.10.0" - } - }, - "node_modules/jss-plugin-global": { - "version": "10.10.0", - "resolved": "https://registry.npmjs.org/jss-plugin-global/-/jss-plugin-global-10.10.0.tgz", - "integrity": "sha512-icXEYbMufiNuWfuazLeN+BNJO16Ge88OcXU5ZDC2vLqElmMybA31Wi7lZ3lf+vgufRocvPj8443irhYRgWxP+A==", - "dependencies": { - "@babel/runtime": "^7.3.1", - "jss": "10.10.0" - } - }, - "node_modules/jss-plugin-nested": { - "version": "10.10.0", - "resolved": "https://registry.npmjs.org/jss-plugin-nested/-/jss-plugin-nested-10.10.0.tgz", - "integrity": "sha512-9R4JHxxGgiZhurDo3q7LdIiDEgtA1bTGzAbhSPyIOWb7ZubrjQe8acwhEQ6OEKydzpl8XHMtTnEwHXCARLYqYA==", - "dependencies": { - "@babel/runtime": "^7.3.1", - "jss": "10.10.0", - "tiny-warning": "^1.0.2" - } - }, - "node_modules/jss-plugin-props-sort": { - "version": "10.10.0", - "resolved": "https://registry.npmjs.org/jss-plugin-props-sort/-/jss-plugin-props-sort-10.10.0.tgz", - "integrity": "sha512-5VNJvQJbnq/vRfje6uZLe/FyaOpzP/IH1LP+0fr88QamVrGJa0hpRRyAa0ea4U/3LcorJfBFVyC4yN2QC73lJg==", - "dependencies": { - "@babel/runtime": "^7.3.1", - "jss": "10.10.0" - } - }, - "node_modules/jss-plugin-rule-value-function": { - "version": "10.10.0", - "resolved": "https://registry.npmjs.org/jss-plugin-rule-value-function/-/jss-plugin-rule-value-function-10.10.0.tgz", - "integrity": "sha512-uEFJFgaCtkXeIPgki8ICw3Y7VMkL9GEan6SqmT9tqpwM+/t+hxfMUdU4wQ0MtOiMNWhwnckBV0IebrKcZM9C0g==", - "dependencies": { - "@babel/runtime": "^7.3.1", - "jss": "10.10.0", - "tiny-warning": "^1.0.2" - } - }, - "node_modules/jss-plugin-vendor-prefixer": { - "version": "10.10.0", - "resolved": "https://registry.npmjs.org/jss-plugin-vendor-prefixer/-/jss-plugin-vendor-prefixer-10.10.0.tgz", - "integrity": "sha512-UY/41WumgjW8r1qMCO8l1ARg7NHnfRVWRhZ2E2m0DMYsr2DD91qIXLyNhiX83hHswR7Wm4D+oDYNC1zWCJWtqg==", - "dependencies": { - "@babel/runtime": "^7.3.1", - "css-vendor": "^2.0.8", - "jss": "10.10.0" - } - }, "node_modules/jsx-ast-utils": { "version": "3.3.5", "resolved": "https://registry.npmjs.org/jsx-ast-utils/-/jsx-ast-utils-3.3.5.tgz", @@ -5203,14 +4754,15 @@ "dev": true }, "node_modules/next": { - "version": "14.0.3", - "resolved": "https://registry.npmjs.org/next/-/next-14.0.3.tgz", - "integrity": "sha512-AbYdRNfImBr3XGtvnwOxq8ekVCwbFTv/UJoLwmaX89nk9i051AEY4/HAWzU0YpaTDw8IofUpmuIlvzWF13jxIw==", + "version": "14.0.4", + "resolved": "https://registry.npmjs.org/next/-/next-14.0.4.tgz", + "integrity": "sha512-qbwypnM7327SadwFtxXnQdGiKpkuhaRLE2uq62/nRul9cj9KhQ5LhHmlziTNqUidZotw/Q1I9OjirBROdUJNgA==", "dependencies": { - "@next/env": "14.0.3", + "@next/env": "14.0.4", "@swc/helpers": "0.5.2", "busboy": "1.6.0", "caniuse-lite": "^1.0.30001406", + "graceful-fs": "^4.2.11", "postcss": "8.4.31", "styled-jsx": "5.1.1", "watchpack": "2.4.0" @@ -5222,15 +4774,15 @@ "node": ">=18.17.0" }, "optionalDependencies": { - "@next/swc-darwin-arm64": "14.0.3", - "@next/swc-darwin-x64": "14.0.3", - "@next/swc-linux-arm64-gnu": "14.0.3", - "@next/swc-linux-arm64-musl": "14.0.3", - "@next/swc-linux-x64-gnu": "14.0.3", - "@next/swc-linux-x64-musl": "14.0.3", - "@next/swc-win32-arm64-msvc": "14.0.3", - "@next/swc-win32-ia32-msvc": "14.0.3", - "@next/swc-win32-x64-msvc": "14.0.3" + "@next/swc-darwin-arm64": "14.0.4", + "@next/swc-darwin-x64": "14.0.4", + "@next/swc-linux-arm64-gnu": "14.0.4", + "@next/swc-linux-arm64-musl": "14.0.4", + "@next/swc-linux-x64-gnu": "14.0.4", + "@next/swc-linux-x64-musl": "14.0.4", + "@next/swc-win32-arm64-msvc": "14.0.4", + "@next/swc-win32-ia32-msvc": "14.0.4", + "@next/swc-win32-x64-msvc": "14.0.4" }, "peerDependencies": { "@opentelemetry/api": "^1.1.0", @@ -5682,11 +5234,6 @@ "node": ">=8" } }, - "node_modules/popper.js": { - "version": "1.16.1-lts", - "resolved": "https://registry.npmjs.org/popper.js/-/popper.js-1.16.1-lts.tgz", - "integrity": "sha512-Kjw8nKRl1m+VrSFCoVGPph93W/qrSO7ZkqPpTf7F4bk/sqcfWK019dWBUpE/fBOsOQY1dks/Bmcbfn1heM/IsA==" - }, "node_modules/postcss": { "version": "8.4.32", "resolved": "https://registry.npmjs.org/postcss/-/postcss-8.4.32.tgz", @@ -5962,9 +5509,9 @@ } }, "node_modules/react-date-range": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/react-date-range/-/react-date-range-1.4.0.tgz", - "integrity": "sha512-+9t0HyClbCqw1IhYbpWecjsiaftCeRN5cdhsi9v06YdimwyMR2yYHWcgVn3URwtN/txhqKpEZB6UX1fHpvK76w==", + "version": "2.0.0-alpha.4", + "resolved": "https://registry.npmjs.org/react-date-range/-/react-date-range-2.0.0-alpha.4.tgz", + "integrity": "sha512-8IP6DVW6nGQu1PUUw7iCAOnRfLP8cKrjDNKZFb9z7SAWUZ/RiUYNbUfdZxGySlcx5V52BpgFpEuAKD16pEN+MA==", "dependencies": { "classnames": "^2.2.6", "prop-types": "^15.7.2", @@ -5972,7 +5519,7 @@ "shallow-equal": "^1.2.1" }, "peerDependencies": { - "date-fns": "2.0.0-alpha.7 || >=2.0.0", + "date-fns": "3.0.6 || >=3.0.0", "react": "^0.14 || ^15.0.0-rc || >=15.0" } }, @@ -6037,34 +5584,30 @@ "react": "0.14 || 15 - 18" } }, - "node_modules/react-router": { - "version": "6.20.1", - "resolved": "https://registry.npmjs.org/react-router/-/react-router-6.20.1.tgz", - "integrity": "sha512-ccvLrB4QeT5DlaxSFFYi/KR8UMQ4fcD8zBcR71Zp1kaYTC5oJKYAp1cbavzGrogwxca+ubjkd7XjFZKBW8CxPA==", + "node_modules/react-redux": { + "version": "9.0.4", + "resolved": "https://registry.npmjs.org/react-redux/-/react-redux-9.0.4.tgz", + "integrity": "sha512-9J1xh8sWO0vYq2sCxK2My/QO7MzUMRi3rpiILP/+tDr8krBHixC6JMM17fMK88+Oh3e4Ae6/sHIhNBgkUivwFA==", "dependencies": { - "@remix-run/router": "1.13.1" - }, - "engines": { - "node": ">=14.0.0" + "@types/use-sync-external-store": "^0.0.3", + "use-sync-external-store": "^1.0.0" }, "peerDependencies": { - "react": ">=16.8" - } - }, - "node_modules/react-router-dom": { - "version": "6.20.1", - "resolved": "https://registry.npmjs.org/react-router-dom/-/react-router-dom-6.20.1.tgz", - "integrity": "sha512-npzfPWcxfQN35psS7rJgi/EW0Gx6EsNjfdJSAk73U/HqMEJZ2k/8puxfwHFgDQhBGmS3+sjnGbMdMSV45axPQw==", - "dependencies": { - "@remix-run/router": "1.13.1", - "react-router": "6.20.1" - }, - "engines": { - "node": ">=14.0.0" + "@types/react": "^18.2.25", + "react": "^18.0", + "react-native": ">=0.69", + "redux": "^5.0.0" }, - "peerDependencies": { - "react": ">=16.8", - "react-dom": ">=16.8" + "peerDependenciesMeta": { + "@types/react": { + "optional": true + }, + "react-native": { + "optional": true + }, + "redux": { + "optional": true + } } }, "node_modules/react-sortable-tree-patch-react-17": { @@ -6214,31 +5757,6 @@ "resolved": "https://registry.npmjs.org/redux/-/redux-5.0.1.tgz", "integrity": "sha512-M9/ELqF6fy8FwmkpnF0S3YKOqMyoWJ4+CS5Efg2ct3oY9daQvd/Pc71FpGZsVsbl3Cpb+IIcjBDUnnyBdQbq4w==" }, - "node_modules/redux-devtools-extension": { - "version": "2.13.9", - "resolved": "https://registry.npmjs.org/redux-devtools-extension/-/redux-devtools-extension-2.13.9.tgz", - "integrity": "sha512-cNJ8Q/EtjhQaZ71c8I9+BPySIBVEKssbPpskBfsXqb8HJ002A3KRVHfeRzwRo6mGPqsm7XuHTqNSNeS1Khig0A==", - "deprecated": "Package moved to @redux-devtools/extension.", - "peerDependencies": { - "redux": "^3.1.0 || ^4.0.0" - } - }, - "node_modules/redux-logger": { - "version": "3.0.6", - "resolved": "https://registry.npmjs.org/redux-logger/-/redux-logger-3.0.6.tgz", - "integrity": "sha512-JoCIok7bg/XpqA1JqCqXFypuqBbQzGQySrhFzewB7ThcnysTO30l4VCst86AuB9T9tuT03MAA56Jw2PNhRSNCg==", - "dependencies": { - "deep-diff": "^0.3.5" - } - }, - "node_modules/redux-persist": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/redux-persist/-/redux-persist-6.0.0.tgz", - "integrity": "sha512-71LLMbUq2r02ng2We9S215LtPu3fY0KgaGE0k8WRgl6RkqxtGfl7HUozz1Dftwsb0D/5mZ8dwAaPbtnzfvbEwQ==", - "peerDependencies": { - "redux": ">4.0.0" - } - }, "node_modules/redux-thunk": { "version": "3.1.0", "resolved": "https://registry.npmjs.org/redux-thunk/-/redux-thunk-3.1.0.tgz", @@ -6297,6 +5815,11 @@ "node": ">=0.10.0" } }, + "node_modules/reselect": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/reselect/-/reselect-5.1.0.tgz", + "integrity": "sha512-aw7jcGLDpSgNDyWBQLv2cedml85qd95/iszJjN988zX1t7AVRJi19d9kto5+W7oCfQ94gyo40dVbT6g2k4/kXg==" + }, "node_modules/resolve": { "version": "1.22.8", "resolved": "https://registry.npmjs.org/resolve/-/resolve-1.22.8.tgz", @@ -6864,11 +6387,6 @@ "node": ">=0.8" } }, - "node_modules/tiny-warning": { - "version": "1.0.3", - "resolved": "https://registry.npmjs.org/tiny-warning/-/tiny-warning-1.0.3.tgz", - "integrity": "sha512-lBN9zLN/oAf68o3zNXYrdCt1kP8WsiGW8Oo2ka41b2IM5JL/S1CTyX1rW0mb/zSuJun0ZUrDxx4sqvYS2FWzPA==" - }, "node_modules/to-fast-properties": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/to-fast-properties/-/to-fast-properties-2.0.0.tgz", @@ -7147,6 +6665,14 @@ "punycode": "^2.1.0" } }, + "node_modules/use-sync-external-store": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/use-sync-external-store/-/use-sync-external-store-1.2.0.tgz", + "integrity": "sha512-eEgnFxGQ1Ife9bzYs6VLi8/4X6CObHMw9Qr9tPY43iKwsPw8xE8+EFsf/2cFZ5S3esXgpWgtSCtLNS41F+sKPA==", + "peerDependencies": { + "react": "^16.8.0 || ^17.0.0 || ^18.0.0" + } + }, "node_modules/util-deprecate": { "version": "1.0.2", "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", diff --git a/package.json b/package.json index b11e117a..1b6abcea 100644 --- a/package.json +++ b/package.json @@ -13,26 +13,19 @@ "dependencies": { "@emotion/react": "^11.11.1", "@emotion/styled": "^11.11.0", - "@material-ui/core": "^4.12.4", - "@material-ui/icons": "^4.11.3", "@mui/icons-material": "^5.14.18", "@mui/material": "^5.14.18", - "@mui/styles": "^5.14.18", - "@mui/x-date-pickers-pro": "^6.18.4", + "@reduxjs/toolkit": "^2.0.1", "axios": "^1.6.3", + "date-fns": "^3.2.0", "firebase": "^10.7.1", "firebase-auth": "^0.1.2", "mui-datatables": "^4.3.0", - "next": "14.0.3", + "next": "^14.0.4", "react": "^18", - "react-date-range": "^1.4.0", + "react-date-range": "^2.0.0-alpha.4", "react-dom": "^18", - "react-router-dom": "^6.20.1", - "redux": "^5.0.1", - "redux-devtools-extension": "^2.13.9", - "redux-logger": "^3.0.6", - "redux-persist": "^6.0.0", - "redux-thunk": "^3.1.0" + "react-redux": "^9.0.4" }, "devDependencies": { "autoprefixer": "^10.4.16", diff --git a/src/app/Constants/addUserTypes/index.js b/src/Constants/addUserTypes/index.js similarity index 100% rename from src/app/Constants/addUserTypes/index.js rename to src/Constants/addUserTypes/index.js diff --git a/src/app/StoreProvider.js b/src/app/StoreProvider.js new file mode 100644 index 00000000..20cda061 --- /dev/null +++ b/src/app/StoreProvider.js @@ -0,0 +1,15 @@ +'use client' +import { useRef } from 'react' +import { Provider } from 'react-redux' +import { makeStore } from '../redux/store' + +export const dynamic = 'force-dynamic' +export default function StoreProvider({ children }) { + const storeRef = useRef(); + if (!storeRef.current) { + // Create the store instance the first time this renders + storeRef.current = makeStore(); + } + + return {children} +} \ No newline at end of file diff --git a/src/app/actions/user/FetchLoggedInUserData.js b/src/app/actions/user/FetchLoggedInUserData.js deleted file mode 100644 index e69de29b..00000000 diff --git a/src/app/actions/user/SignIn.js b/src/app/actions/user/SignIn.js deleted file mode 100644 index e69de29b..00000000 diff --git a/src/app/change-password/page.js b/src/app/change-password/page.js index 1ce0639b..ba5a6978 100644 --- a/src/app/change-password/page.js +++ b/src/app/change-password/page.js @@ -1,33 +1,29 @@ 'use client' import { - Card, - Grid, - ThemeProvider, - Typography, - InputAdornment, - } from "@mui/material"; - import React, { useEffect, useState } from "react"; - import themeDefault from "../../themes/theme"; - import { translate } from "../../config/localisation"; -// import { useNavigate, useParams } from "react-router-dom"; - import Button from "../components/common/Button"; - import OutlinedTextField from "../components/common/OutlinedTextField"; - import DatasetStyle from "../../styles/Dataset"; + Card, + Grid, + ThemeProvider, + Typography, + InputAdornment, + IconButton, +} from "@mui/material"; +import React, { useEffect, useState } from "react"; +import themeDefault from "../../themes/theme"; +import { translate } from "../../config/localisation"; +import Button from "../../components/common/Button"; +import OutlinedTextField from "../../components/common/OutlinedTextField"; +import "../../styles/Dataset.css"; // import { useDispatch, useSelector } from "react-redux"; // import APITransport from "../../../../redux/actions/apitransport/apitransport"; // import ChangePasswordAPI from "../../../../redux/actions/api/UserManagement/ChangePassword" - import Spinner from "../components/common/Spinner"; - import CustomizedSnackbars from "../components/common/Snackbar"; - import VpnKeyOutlinedIcon from '@mui/icons-material/VpnKeyOutlined'; - import IconButton from "@material-ui/core/IconButton"; - import Visibility from "@material-ui/icons/Visibility"; - import VisibilityOff from "@material-ui/icons/VisibilityOff"; -import CustomButton from "../components/common/Button"; +import Spinner from "../../components/common/Spinner"; +import CustomizedSnackbars from "../../components/common/Snackbar"; +import { Visibility, VisibilityOff } from "@mui/icons-material"; +import CustomButton from "../../components/common/Button"; const ChangePassword = (props) => { - // const navigate = useNavigate(); - const classes = DatasetStyle(); + // const dispatch = useDispatch(); const [newPassword, setNewPassword] = useState("") const [currentPassword, setCurrentPassword] = useState("") @@ -71,7 +67,7 @@ import CustomButton from "../components/common/Button"; {loading && } {/* {renderSnackBar()} */} - + @@ -85,7 +81,7 @@ import CustomButton from "../components/common/Button"; */} New Password @@ -165,7 +161,7 @@ import CustomButton from "../components/common/Button"; md={12} lg={12} xl={12} - className={classes.projectsettingGrid} + className="projectsettingGrid" > Confirm Password @@ -195,7 +191,7 @@ import CustomButton from "../components/common/Button"; navigate(`/projects`)} /> diff --git a/src/app/create-annotation-project/page.js b/src/app/create-annotation-project/page.js deleted file mode 100644 index 32eb8b07..00000000 --- a/src/app/create-annotation-project/page.js +++ /dev/null @@ -1,995 +0,0 @@ -'use client' -import { - Box, - Chip, - Grid, - ThemeProvider, - Typography, - Card, - IconButton, - InputLabel, - } from "@mui/material"; - import tableTheme from "../../themes/TableTheme"; - import CancelIcon from "@mui/icons-material/Cancel"; - import React, { useEffect, useState } from "react"; - import themeDefault from "../../themes/theme"; - import Button from "../components/common/Button"; - import ColumnList from "../components/common/ColumnList"; - import OutlinedTextField from "../components/common/OutlinedTextField"; - import DatasetStyle from "../../styles/Dataset"; - import MenuItem from "@mui/material/MenuItem"; - import FormControl from "@mui/material/FormControl"; - import Select from "@mui/material/Select"; - import MUIDataTable from "mui-datatables"; - import MenuItems from "../components/common/MenuItems"; - import CustomizedSnackbars from "../components/common/Snackbar"; - import Spinner from "../components/common/Spinner"; - import FormControlLabel from "@mui/material/FormControlLabel"; - import Switch from "@mui/material/Switch"; - import SearchIcon from "@mui/icons-material/Search"; - // import DatasetSearchPopup from "../../container/Dataset/DatasetSearchPopup"; - // import DatasetSearchPopupAPI from "../../../../redux/actions/api/Dataset/DatasetSearchPopup"; - // import { MenuProps } from "../../../../utils/utils"; - - const isNum = (str) => { - var reg = new RegExp("^[0-9]*$"); - return reg.test(String(str)); - }; - const projectStage = [ - { name: "Annotation Stage", value: 1 }, - { name: "Review Stage", value: 2 }, - { name: "Super-Check Stage", value: 3 } - ]; - - const CreateAnnotationsAutomatically = [ - { name: "None", value: "none" }, - { name: "Annotation", value: "annotation" }, - { name: "Review", value: "review" }, - { name: "Supercheck", value: "supercheck" } - ]; - - const AnnotationProject = (props) => { - - const classes = DatasetStyle(); - - const [domains, setDomains] = useState([]); - const [projectTypes, setProjectTypes] = useState(null); - const [datasetTypes, setDatasetTypes] = useState(null); - const [instanceIds, setInstanceIds] = useState(null); - const [columnFields, setColumnFields] = useState(null); - const [variableParameters, setVariableParameters] = useState(null); - const [languageOptions, setLanguageOptions] = useState([]); - const [searchedCol, setSearchedCol] = useState(); - const [title, setTitle] = useState(""); - const [description, setDescription] = useState(""); - const [selectedDomain, setSelectedDomain] = useState(""); - const [selectedType, setSelectedType] = useState(""); - const [sourceLanguage, setSourceLanguage] = useState(""); - const [targetLanguage, setTargetLanguage] = useState(""); - const [samplingMode, setSamplingMode] = useState(null); - const [random, setRandom] = useState(""); - const [batchSize, setBatchSize] = useState(); - const [batchNumber, setBatchNumber] = useState([]); - const [samplingParameters, setSamplingParameters] = useState(null); - const [selectedInstances, setSelectedInstances] = useState([]); - const [confirmed, setConfirmed] = useState(false); - const [selectedAnnotatorsNum, setSelectedAnnotatorsNum] = useState(1); - const [filterString, setFilterString] = useState(null); - const [selectedVariableParameters, setSelectedVariableParameters] = useState( - [] - ); - const [taskReviews, setTaskReviews] = useState(1); - const [variable_Parameters_lang, setVariable_Parameters_lang] = useState(""); - //Table related state variables - const [columns, setColumns] = useState(null); - const [selectedColumns, setSelectedColumns] = useState([]); - const [currentPageNumber, setCurrentPageNumber] = useState(1); - const [currentRowPerPage, setCurrentRowPerPage] = useState(10); - const [totalDataitems, setTotalDataitems] = useState(10); - const [tableData, setTableData] = useState([]); - const [searchAnchor, setSearchAnchor] = useState(null); - const [selectedFilters, setsSelectedFilters] = useState({}); - const [createannotationsAutomatically, setsCreateannotationsAutomatically] = useState("none"); - const [acousticEnabledStage, setAcousticEnabledStage] = useState(null); - - const searchOpen = Boolean(searchAnchor); - const excludeKeys = [ - "parent_data_id", - // "metadata_json", - "instance_id_id", - "datasetbase_ptr_id", - "key", - "instance_id", - "labse_score", - "parent_data", - "id", - "rating", - // "conversation_json", - "machine_translated_conversation_json", - "speakers_json", - // "transcribed_json", - "conversation_json", - // "prediction_json", - "machine_transcribed_json", - "unverified_conversation_json", - "annotation_bboxes", - "annotation_labels", - "annotation_transcripts", - ]; - const renderToolBar = () => { - return ( - - - - - - - - ); - }; - const customColumnHead = (col) => { - return ( - - {col.label} - handleShowSearch(col.name, e)} - > - - - - ); - }; - const options = { - count: totalDataitems, - rowsPerPage: currentRowPerPage, - page: currentPageNumber - 1, - rowsPerPageOptions: [10, 25, 50, 100], - textLabels: { - pagination: { - next: "Next >", - previous: "< Previous", - rowsPerPage: "currentRowPerPage", - displayRows: "OF", - }, - }, - onChangePage: (currentPage) => { - setCurrentPageNumber(currentPage + 1); - }, - onChangeRowsPerPage: (rowPerPageCount) => { - setCurrentRowPerPage(rowPerPageCount); - }, - filterType: "checkbox", - selectableRows: "none", - download: false, - filter: false, - print: false, - search: false, - viewColumns: false, - textLabels: { - body: { - noMatch: "No records ", - }, - toolbar: { - search: "Search", - viewColumns: "View Column", - }, - pagination: { - rowsPerPage: "Rows per page", - }, - options: { sortDirection: "desc" }, - }, - jumpToPage: true, - serverSide: true, - customToolbar: renderToolBar, - }; - - - return ( - - - - - - - - Create a Project - - - - - - - Title: - - - - setTitle(e.target.value)} - /> - - - - - - Description: - - - - setDescription(e.target.value)} - /> - - - {domains && ( - <> - - - Select a Category to Work in: - - - - - - - )} - - {selectedDomain && ( - <> - - - Select a Project Type: - - - - { - return { - name: key, - value: key, - }; - })} - handleChange={onSelectProjectType} - value={selectedType} - /> - - - )} - - {selectedType && - variableParameters?.[selectedType]?.variable_parameters !== - undefined && ( - <> - - - Variable Parameters: - - - - - setVariable_Parameters_lang(e.target.value) - } - /> - - - )} - {(selectedDomain === "Translation" || - selectedDomain === "Conversation") && - (selectedType === "TranslationEditing" || - selectedType === "SemanticTextualSimilarity" || - selectedType === "ContextualTranslationEditing" || - selectedType === "ConversationTranslation" || - selectedType === "ConversationTranslationEditing") && ( - <> - - - Source Language: - - - - - - - - - - - Target Language: - - - - - - - - - )} - - {(selectedDomain === "Monolingual" || - selectedDomain === "Translation" || - selectedDomain === "Audio") && - (selectedType === "SentenceSplitting" || - selectedType === "ContextualSentenceVerification" || - selectedType === "MonolingualTranslation" || - selectedType === "SingleSpeakerAudioTranscriptionEditing" || - selectedType === "AudioTranscription" || - selectedType === "AudioSegmentation" || - selectedType === "AudioTranscriptionEditing" || - selectedType === "AcousticNormalisedTranscriptionEditing") && ( - <> - - - {selectedType === "SingleSpeakerAudioTranscriptionEditing" - ? "Language:" - : "Target Language:"} - - - - - - - - - )} - - {instanceIds && ( - <> - {selectedVariableParameters.map((parameter, index) => ( - <> - {selectedType === "Conversation" && - (selectedType === "ContextualTranslationEditing" || - selectedType === "ConversationTranslation") && ( - - - {processNameString(parameter["name"])}: - - - )} - - {parameter?.data["choices"] !== undefined ? ( - <> - {selectedType === "Conversation" && - (selectedType === "ContextualTranslationEditing" || - selectedType === "ConversationTranslation") && ( - { - return { - name: element[0], - value: element[0], - }; - } - )} - value={ - selectedVariableParameters[index]["value"] - } - handleChange={(e) => - handleVariableParametersChange( - parameter["name"], - e - ) - } - > - )} - - ) : ( - <> - {parameter.data["name"] === "DecimalField" || - parameter.data["name"] === "IntegerField" ? ( - - handleVariableParametersChange( - parameter["name"], - e - ) - } - inputProps={{ - step: 1, - min: 0, - max: 99999, - type: "number", - }} - /> - ) : ( - - handleVariableParametersChange( - parameter["name"], - e - ) - } - /> - )} - - )} - - - ))} - {selectedType && Object.keys(instanceIds).length > 0 && ( - <> - - - Select sources to fetch data from: - - - - - - - - - - {selectedInstances.length > 0 && ( - <> - diff --git a/src/app/components/common/Button.jsx b/src/components/common/Button.jsx similarity index 100% rename from src/app/components/common/Button.jsx rename to src/components/common/Button.jsx diff --git a/src/app/components/common/Card.jsx b/src/components/common/Card.jsx similarity index 100% rename from src/app/components/common/Card.jsx rename to src/components/common/Card.jsx diff --git a/src/app/components/common/ColumnList.jsx b/src/components/common/ColumnList.jsx similarity index 90% rename from src/app/components/common/ColumnList.jsx rename to src/components/common/ColumnList.jsx index 590d44fa..33827c1a 100644 --- a/src/app/components/common/ColumnList.jsx +++ b/src/components/common/ColumnList.jsx @@ -16,12 +16,12 @@ import { Box } from "@mui/material"; import ViewColumnIcon from "@mui/icons-material/ViewColumn"; -import DatasetStyle from "../../../styles/Dataset"; -import { translate } from "../../../config/localisation"; +import "../../styles/Dataset.css"; +import { translate } from "../../config/localisation"; const ColumnList = (props) => { - const classes = DatasetStyle(); + const [isOpen, setIsOpen] = useState(false); const buttonRef = useRef(); @@ -46,11 +46,11 @@ const ColumnList = (props) => { horizontal: "right", }} > - + {translate("label.filter.column")} : @@ -94,7 +94,7 @@ const ColumnList = (props) => { variant="outlined" color="primary" size="small" - className={classes.clearAllBtn} + className="clearAllBtn" > {" "} Close diff --git a/src/app/components/common/DatasetCard.jsx b/src/components/common/DatasetCard.jsx similarity index 100% rename from src/app/components/common/DatasetCard.jsx rename to src/components/common/DatasetCard.jsx diff --git a/src/app/components/common/MenuItems.jsx b/src/components/common/MenuItems.jsx similarity index 100% rename from src/app/components/common/MenuItems.jsx rename to src/components/common/MenuItems.jsx diff --git a/src/app/components/common/MobileNavbar.jsx b/src/components/common/MobileNavbar.jsx similarity index 94% rename from src/app/components/common/MobileNavbar.jsx rename to src/components/common/MobileNavbar.jsx index add5cd82..a27c4367 100644 --- a/src/app/components/common/MobileNavbar.jsx +++ b/src/components/common/MobileNavbar.jsx @@ -14,12 +14,12 @@ import { Box, FormControlLabel, Checkbox -} from "@material-ui/core"; +} from "@mui/material"; import Link from "next/link"; import Image from "next/image"; -import MenuIcon from "@material-ui/icons/Menu"; +import { Menu } from "@mui/icons-material"; -import headerStyle from "../../../styles/Header"; +import headerStyle from "../styles/Header"; const useStyles = makeStyles(() => ({ Navlink: { @@ -70,7 +70,7 @@ function MobileNavbar(props) { {loggedInUserData && loggedInUserData.username && loggedInUserData.username.split("")[0]} @@ -145,11 +145,11 @@ function MobileNavbar(props) { > - logo + logo setOpenDrawer(!openDrawer)}> - + diff --git a/src/app/components/common/Modal.jsx b/src/components/common/Modal.jsx similarity index 100% rename from src/app/components/common/Modal.jsx rename to src/components/common/Modal.jsx diff --git a/src/app/components/common/OutlinedTextField.jsx b/src/components/common/OutlinedTextField.jsx similarity index 100% rename from src/app/components/common/OutlinedTextField.jsx rename to src/components/common/OutlinedTextField.jsx diff --git a/src/app/components/common/ProjectCard.jsx b/src/components/common/ProjectCard.jsx similarity index 90% rename from src/app/components/common/ProjectCard.jsx rename to src/components/common/ProjectCard.jsx index a81926e4..346cb79a 100644 --- a/src/app/components/common/ProjectCard.jsx +++ b/src/components/common/ProjectCard.jsx @@ -6,18 +6,17 @@ import CardMedia from "@mui/material/CardMedia"; import Button from "@mui/material/Button"; import Typography from "@mui/material/Typography"; import { Box, Chip, Divider, Grid, ThemeProvider } from "@mui/material"; -import themeDefault from "../../../themes/theme"; -// import { Link, useNavigate, useParams } from "react-router-dom"; +import themeDefault from "../../themes/theme"; +//import { useParams, useRouter } from "next/navigation"; import Link from 'next/link' -import DatasetStyle from "../../../styles/Dataset"; -import UserMappedByProjectStage from "../../../utils/UserMappedByProjectStage"; +import "../../styles/Dataset.css"; +import UserMappedByProjectStage from "../../utils/UserMappedByProjectStage"; const ProjectCard = (props) => { -// let navigate = useNavigate(); -// let { id } = useParams(); - - const classes = DatasetStyle(); + //const router = useRouter(); + //const { id } = useParams(); + const { projectObj } = props; const userRole =projectObj.project_stage && UserMappedByProjectStage(projectObj.project_stage).name; return ( diff --git a/src/app/components/common/ProjectFilterList.jsx b/src/components/common/ProjectFilterList.jsx similarity index 92% rename from src/app/components/common/ProjectFilterList.jsx rename to src/components/common/ProjectFilterList.jsx index 9db51db7..67d78103 100644 --- a/src/app/components/common/ProjectFilterList.jsx +++ b/src/components/common/ProjectFilterList.jsx @@ -16,14 +16,14 @@ import { InputLabel, MenuItem, } from "@mui/material"; -import { translate } from "../../../config/localisation"; -import DatasetStyle from "../../../styles/Dataset"; -import roles from "../../../utils/Role"; +import { translate } from "../../config/localisation"; +import "../../styles/Dataset.css"; +import roles from "../../utils/Role"; const UserType = ["annotator", "reviewer","superchecker"]; const archivedProjects = ["true", "false"]; const ProjectFilterList = (props) => { - const classes = DatasetStyle(); + // const dispatch = useDispatch(); const { @@ -88,7 +88,7 @@ const loggedInUserData= { horizontal: "right", }} > - + Project Type @@ -146,7 +146,7 @@ const loggedInUserData= { Archived Projects : @@ -168,7 +168,7 @@ const loggedInUserData= { variant="outlined" color="primary" size="small" - className={classes.clearAllBtn} + className="clearAllBtn" > {" "} Clear All @@ -178,7 +178,7 @@ const loggedInUserData= { variant="contained" color="primary" size="small" - className={classes.clearAllBtn} + className="clearAllBtn" > {" "} Apply diff --git a/src/app/components/common/Search.jsx b/src/components/common/Search.jsx similarity index 85% rename from src/app/components/common/Search.jsx rename to src/components/common/Search.jsx index c1f3beef..918bb20e 100644 --- a/src/app/components/common/Search.jsx +++ b/src/components/common/Search.jsx @@ -1,14 +1,14 @@ import { InputBase,ThemeProvider,Grid } from "@mui/material"; import SearchIcon from '@mui/icons-material/Search'; import { useEffect, useRef, useState } from "react"; -import themeDefault from '../../../themes/theme' - import DatasetStyle from "../../../styles/Dataset"; +import themeDefault from '../../themes/theme' + import "../../styles/Dataset.css"; // import { useDispatch, useSelector } from "react-redux"; // import SearchProjectCards from "../../../../redux/actions/api/ProjectDetails/SearchProjectCards" const Search = (props) => { const ref = useRef(null); - const classes = DatasetStyle(); + // const dispatch = useDispatch(); // const SearchProject = useSelector((state) => state.SearchProjectCards.data); @@ -32,8 +32,8 @@ const Search = (props) => { return ( - - + + ({ @@ -26,10 +26,9 @@ import DatasetStyle from '../../../styles/Dataset'; function CircularIndeterminate(props) { - const classes = DatasetStyle() return ( -
- +
+
); } diff --git a/src/app/components/common/TablePaginationActions.jsx b/src/components/common/TablePaginationActions.jsx similarity index 100% rename from src/app/components/common/TablePaginationActions.jsx rename to src/components/common/TablePaginationActions.jsx diff --git a/src/app/components/common/Workspace.jsx b/src/components/common/Workspace.jsx similarity index 72% rename from src/app/components/common/Workspace.jsx rename to src/components/common/Workspace.jsx index 95b77461..70ed7e98 100644 --- a/src/app/components/common/Workspace.jsx +++ b/src/components/common/Workspace.jsx @@ -1,11 +1,10 @@ import React, { useState, useEffect } from "react"; -// import { Link, useNavigate, useParams } from 'react-router-dom'; // import MUIDataTable from "mui-datatables"; // import {useDispatch,useSelector} from 'react-redux'; // import APITransport from '../../../../redux/actions/apitransport/apitransport'; -// import UserMappedByRole from "../../../../utils/UserMappedByRole/UserMappedByRole"; +// import UserMappedByRole from "../../../utils/UserMappedByRole/UserMappedByRole"; // import CustomButton from "../common/Button"; -import WorkspaceTable from "../common/WorkspaceTable"; +import WorkspaceTable from "./WorkspaceTable"; // import GetWorkspacesAPI from "../../../../redux/actions/api/Dashboard/GetWorkspaces"; const Workspaces = () => { diff --git a/src/app/components/common/WorkspaceReports.jsx b/src/components/common/WorkspaceReports.jsx similarity index 97% rename from src/app/components/common/WorkspaceReports.jsx rename to src/components/common/WorkspaceReports.jsx index 09690475..d134c9e6 100644 --- a/src/app/components/common/WorkspaceReports.jsx +++ b/src/components/common/WorkspaceReports.jsx @@ -10,21 +10,20 @@ import { ThemeProvider, Radio, Typography, } from "@mui/material"; -import tableTheme from "../../../themes/tableTheme"; +import tableTheme from "../../themes/tableTheme"; import InputLabel from "@mui/material/InputLabel"; import MenuItem from "@mui/material/MenuItem"; import FormControl from "@mui/material/FormControl"; import Select from "@mui/material/Select"; -import { useParams } from "react-router-dom"; import RadioGroup from '@mui/material/RadioGroup'; import FormControlLabel from '@mui/material/FormControlLabel'; -import DatasetStyle from "../../../styles/Dataset"; -import ColumnList from "../common/ColumnList"; +import "../../styles/Dataset.css"; +import ColumnList from "./ColumnList"; import { DateRangePicker, defaultStaticRanges } from "react-date-range"; import ArrowDropDownIcon from "@mui/icons-material/ArrowDropDown"; import ArrowRightIcon from "@mui/icons-material/ArrowRight"; -// import { MenuProps } from "../../../../utils/utils"; +// import { MenuProps } from "../../../utils/utils"; import CustomizedSnackbars from "./Snackbar"; const ProgressType = [{ name: "Annotation Stage", value: 1 }, { name: "Review Stage", value: 2 }, { name: "Super Check Stage", value: 3 }, { name: "All Stage", value: "AllStage" }] @@ -48,7 +47,7 @@ const WorkspaceReports = () => { const [projectReportType, setProjectReportType] = useState(1); const [statisticsType, setStatisticsType] = useState(1); - const classes = DatasetStyle(); + const [snackbar, setSnackbarInfo] = useState({ open: false, message: "", diff --git a/src/app/components/common/WorkspaceTable.jsx b/src/components/common/WorkspaceTable.jsx similarity index 94% rename from src/app/components/common/WorkspaceTable.jsx rename to src/components/common/WorkspaceTable.jsx index 48fa9d69..22d73755 100644 --- a/src/app/components/common/WorkspaceTable.jsx +++ b/src/components/common/WorkspaceTable.jsx @@ -1,19 +1,18 @@ import React, { useState, useEffect } from "react"; // import { useDispatch, useSelector } from 'react-redux'; -import CustomButton from '../common/Button' -// import { Link, useNavigate, useParams } from 'react-router-dom'; +import CustomButton from './Button' import MUIDataTable from "mui-datatables"; import { ThemeProvider, Grid } from "@mui/material"; -import tableTheme from "../../../themes/tableTheme"; -import DatasetStyle from "../../../styles/Dataset"; -import Search from "../common/Search"; +import tableTheme from "../../themes/tableTheme"; +import "../../styles/Dataset.css"; +import Search from "./Search"; import Link from 'next/link'; const WorkspaceTable = (props) => { - const classes = DatasetStyle(); + // const dispatch = useDispatch(); const { showManager, showCreatedBy } = props; diff --git a/src/app/components/user/AppInfo.jsx b/src/components/user/AppInfo.jsx similarity index 66% rename from src/app/components/user/AppInfo.jsx rename to src/components/user/AppInfo.jsx index 0ca1d68a..fdd6fb0f 100644 --- a/src/app/components/user/AppInfo.jsx +++ b/src/components/user/AppInfo.jsx @@ -1,9 +1,8 @@ import { Grid, Typography, Hidden, ThemeProvider } from "@mui/material"; -import LoginStyle from "../../../styles/loginStyle"; +import "../../styles/Dataset.css"; export default function AppInfo() { - const classes = LoginStyle(); return (
@@ -14,10 +13,10 @@ export default function AppInfo() { - Anudesh + Anudesh - + Anudesh Information diff --git a/src/redux/actions/Common.js b/src/redux/actions/Common.js deleted file mode 100644 index 5db72e22..00000000 --- a/src/redux/actions/Common.js +++ /dev/null @@ -1,16 +0,0 @@ -import C from "../constants"; - -export const setPlayer = (data) => { - return { - type: C.PLAYER, - payload: data, - }; -}; - -export const setSubtitles = (data, type) => { - return { - type: type, - payload: data, - }; -}; - diff --git a/src/redux/actions/domains.js b/src/redux/actions/domains.js new file mode 100644 index 00000000..c6b610b3 --- /dev/null +++ b/src/redux/actions/domains.js @@ -0,0 +1,36 @@ +import { createAsyncThunk, createSlice } from '@reduxjs/toolkit'; +import fetchParams from '../fetchParams'; + +const initialState = { + status: 'idle', + error: null, + domains: [], +}; + +export const fetchDomains = createAsyncThunk('domains/fetchDomains', async () => { + const params = fetchParams("/projects/types"); + return fetch(params.url, params.options) + .then(response => response.json()) +}); + +const domainsSlice = createSlice({ + name: 'domains', + initialState, + reducers: {}, + extraReducers(builder) { + builder + .addCase(fetchDomains.fulfilled, (state, action) => { + state.status = 'succeeded' + state.domains = action.payload + }) + .addCase(fetchDomains.pending, (state, action) => { + state.status = 'loading' + }) + .addCase(fetchDomains.rejected, (state, action) => { + state.status = 'failed' + state.error = action.error.message + }) + } +}); + +export default domainsSlice.reducer; \ No newline at end of file diff --git a/src/redux/actions/projects.js b/src/redux/actions/projects.js new file mode 100644 index 00000000..b0c9cbbc --- /dev/null +++ b/src/redux/actions/projects.js @@ -0,0 +1,41 @@ +import { createAsyncThunk, createSlice } from '@reduxjs/toolkit'; +import fetchParams from '../fetchParams'; + +const initialState = { + status: 'idle', + error: null, + newProject: { + status: 'idle', + error: null, + res: null, + }, + projects: [], +}; + +export const createProject = createAsyncThunk('projects/createProject', async (body) => { + const params = fetchParams("/projects/", "POST", body); + return fetch(params.url, params.options) + .then(response => response.json()) +}); + +const projectsSlice = createSlice({ + name: 'projects', + initialState, + reducers: {}, + extraReducers(builder) { + builder + .addCase(createProject.fulfilled, (state, action) => { + state.newProject.status = 'succeeded' + state.newProject.res = action.payload + }) + .addCase(createProject.pending, (state, action) => { + state.newProject.status = 'loading' + }) + .addCase(createProject.rejected, (state, action) => { + state.newProject.status = 'failed' + state.newProject.error = action.error.message + }) + } +}); + +export default projectsSlice.reducer; \ No newline at end of file diff --git a/src/redux/actions/user.js b/src/redux/actions/user.js new file mode 100644 index 00000000..74af8baa --- /dev/null +++ b/src/redux/actions/user.js @@ -0,0 +1,36 @@ +import { createAsyncThunk, createSlice } from '@reduxjs/toolkit'; +import fetchParams from '../fetchParams'; + +const initialState = { + status: 'idle', + error: null, + data: null, +}; + +export const fetchUserData = createAsyncThunk('user/fetchUserData', async (id) => { + const params = fetchParams(`/users/account/${id}/fetch/`, "GET"); + return fetch(params.url, params.options) + .then(response => response.json()) +}); + +const userSlice = createSlice({ + name: 'user', + initialState, + reducers: {}, + extraReducers(builder) { + builder + .addCase(fetchUserData.fulfilled, (state, action) => { + state.status = 'succeeded' + state.data = action.payload + }) + .addCase(fetchUserData.pending, (state, action) => { + state.status = 'loading' + }) + .addCase(fetchUserData.rejected, (state, action) => { + state.status = 'failed' + state.error = action.error.message + }) + } +}); + +export default userSlice.reducer; \ No newline at end of file diff --git a/src/redux/fetchParams.js b/src/redux/fetchParams.js new file mode 100644 index 00000000..2a6db8a5 --- /dev/null +++ b/src/redux/fetchParams.js @@ -0,0 +1,17 @@ +'use client' + +const fetchParams = (endpoint, method = "GET", body = null) => { + return { + url: `${process.env.NEXT_PUBLIC_BACKEND_URL}${endpoint}`, + options: { + method: method, + body, + headers: { + "Content-Type": "application/json", + Authorization: `JWT ${window.localStorage.getItem('token')}`, + }, + } + }; +}; + +export default fetchParams; diff --git a/src/redux/store/store.js b/src/redux/store.js similarity index 66% rename from src/redux/store/store.js rename to src/redux/store.js index 60a90f0d..e8371314 100644 --- a/src/redux/store/store.js +++ b/src/redux/store.js @@ -1,4 +1,4 @@ -import { createStore, compose, applyMiddleware } from "redux"; +/* import { createStore, compose, applyMiddleware } from "redux"; import thunk from "redux-thunk"; import { createLogger } from "redux-logger"; import { composeWithDevTools } from "redux-devtools-extension"; @@ -18,7 +18,6 @@ const rootReducer = (state, action) => { if (action.type === C.LOGOUT) { state = undefined; } - return appReducer(state, action); }; @@ -35,4 +34,19 @@ const store = createStore( : compose(applyMiddleware(...middlewares)) ); -export default store; \ No newline at end of file +export default store; */ + +import { configureStore } from '@reduxjs/toolkit' +import domainsReducer from './actions/domains' +import projectsReducer from './actions/projects' +import userReducer from './actions/user' + +export const makeStore = () => { + return configureStore({ + reducer: { + domains: domainsReducer, + projects: projectsReducer, + user: userReducer, + } + }); +} \ No newline at end of file diff --git a/src/styles/Dataset.css b/src/styles/Dataset.css new file mode 100644 index 00000000..2232bfa9 --- /dev/null +++ b/src/styles/Dataset.css @@ -0,0 +1,417 @@ + + + .Projectsettingtextarea { + width: 100%; + font-size: 1.4rem; + font-family: Roboto; + font-weight: 10; + line-height: 1.2; + + } + + .custombtn { + border-radius:0 + } + + .workspaceTables { + margin-top: 20px + } + + .projectButton { + width: 100%; + text-decoration: none; + } + + .annotatorsButton { + width: 100% + } + + .managersButton { + width: 100% + } + + .settingsButton { + width: 100%; + color: #ee6633 + } + + .workspaceCard { + width: 100%; + min-height: 420px; + padding: 40px; + justify-content: center; justify-items: center + } + + .projectsettingGrid { + margin: 20px 0px 10px 0px; + } + + .filterToolbarContainer { + display: flex; + flex-direction: row; + justify-content: flex-end; + align-items: center; + column-gap: 10px; + } + + .clearAllBtn { + float: right; + margin: 9px 16px 0px auto; + padding: 0; + height: 15px; + } + + .filterContainer { + border-bottom: 1px solid #00000029; + padding: 18px; + max-height: 400px; + overflow: auto; + display: flex; + flex-direction: column; + gap: 10px; + } + + @media screen and (max-width: 550px) { + .filterContainer { + max-height: 170px; + }; + } + + .statusFilterContainer { + align-items: center; + } + + .applyBtn { + float: right; + border-radius: 20px; + margin: 9px 16px 9px auto; + width: 80px; + } + + .clrBtn { + float: right; + border-radius: 20px; + margin: 9px 10px 9px auto; + width: 100px; + } + + .menuStyle { + padding: 0px; + justify-content: left; + font-size: 1.125rem; + font-weight: 500 !important; + border-bottom: 1px solid rgba(0, 0, 0, 0.42); + } + + .menuStyle:hover { + background-color: white; + } + + .projectCardContainer { + cursor: 'pointer' + } + + .modelname { + box-sizing: border-box; + height: 64px; + background-color: white; + max-width: 90%; + min-width: '90%'; + width: auto; + display: flex; + align-items: center; + padding: 0 15px; + border-radius: 12px; + } + + .parentContainer { + min-height: 100vh; + align-items: center; + padding-bottom: 5vh; + flex-grow: 0 + } + + .projectCardContainer1 { + background-color: #2A61AD; + height: 100%; + width: 100% + + } + + .projectCardContainer2 { + background-color: #119DA4; + height: 100%; + width: 100% + } + + .userCardContainer { + direction: column; + align-items: center; + height: 100%; + place-content: center + } + + .dashboardContentContainer { + align-items: left; + justify-content: space-around; + min-height: 70vh; + border-left: '1px solid lightgray'; + padding-left: '5%' + } + + .link { + text-decoration: none + } + + .progress { + position: 'relative'; + top: '40%'; + left: '46%' + + } + + .progressDiv { + position: 'fixed'; + z-index: 1000; + width: '100%'; + height: '100%'; + top: 0; + left: 0; + opacity: 1 + } + + .search { + border-radius: 24px; + background-color: #F3F3F3; + margin-left: 0px; + width: 300px; + margin-bottom: 10px; + + } + + .searchIcon { + position: absolute; + pointer-events: none; + display: flex; + align-items: center; + justify-content: center; + color: #00000029; + margin-left: 10px; + margin-top: 10px; + }; + .divider { + border-left: 1px solid #E0E0E0; + height: 200px; + position: absolute; + }; + .rootdiv { + margin-top: 25px; + }; + .ToolbarContainer { + position: absolute; + bottom: 14px; + right: 45px + + }; + .TotalSummarydata { + padding: 4px 0px 0px 4px; + }; + .projectgrid { + text-align: start + }; + + .root { + min-height: 40; + align-items: center; + }; + .modelValue { + font-size: 14px; + font-family: Roboto; + font-weight: 400; + line-height: 22px; + display: -webkit-box; + -webkit-line-clamp: 2; + -webkit-box-orient: vertical; + overflow: hidden; + } + + .modelValue::first-letter { + text-transform: capitalize; + } + + @media screen and (max-width: 400px) { + .modelValue { + margin-left: -14px; + font-size: 12px + } + } + .descCardIcon { + display: flex; + border-radius: 20%; + padding: 15px; + height: fit-content; + }; + .formControl { + width: 300 + }; + .AddGlossaryCard { + width: 100%; + min-height: 420px; + padding: 20px 40px 20px 40px; + justify-content: center; justify-items: center + }; + .SuggestAnEditCard { + width: 100%; + min-height: 350px; + padding: 20px 40px 20px 40px; + justify-content: center; justify-items: center + }; + + .heading { + text-align: center; + margin-bottom: 35px; + color: #3A3A3A; + font-size: 2.5rem; + font-weight: 400; + }; + .topBar { + display: flex; + align-items: center; + background-color: #DEECFF; + font-size: 18px; + }; + + .topBarInnerBox { + width: 25%; + display: flex; + flex-direction: column; + text-align: center; + box-shadow: 3px 0 2px -2px #00000029; + }; + .toolTip { + width: 200px; height: 180px; font-size: 16px; background-color: white; color: black; padding: 5px 10px 10px 10px; border: 1px solid gray + }; + + .toolTips { + width: 280px; height: 220px; font-size: 16px; background-color: white; color: black; padding: 5px 10px 10px 10px; border: 1px solid gray + }; + + .textTransliteration { + border-radius: 3px; + + height: 60px; + padding: 15px 10px 10px 10px; + resize: none; + margin: 7px 0px 0px 0px; + width: 200px;font-size:16px + } + + + +.appInfo { + background: rgba(238, 102, 51, 1); + min-height: 100vh; + color:white; +} + +@media screen and (max-width: 650px) { + .appInfo { + background: white; + min-height: 15vh; + }; +} + +.title { + width: 20%; + height: auto; + margin: 22% 294px 10% 39px; + cursor:pointer; + line-height: 1.53; + letter-spacing: 3.9px; + text-align: left; +} + +@media screen and (max-width: 650px) { + .title { + margin: 0% 0% 00% 90%; + color: black; + }; +} + +.subTitle { + width: 80%; + height: auto; + max-width: 300px; + margin: 20% 70px 15% 39px; + line-height: 1.5; + letter-spacing: 1.6px; + text-align: left; +} + +@media screen and (max-width: 1040px) { + .subTitle { + letter-spacing: 1px; + max-width: 280px; + width: 80%; + }; +} + +@media screen and (max-width: 1790px) { + .subTitle { + letter-spacing: 1px; + max-width: 280px; + width: 68%; + }; +} + +.body { + width: 80%; + height: auto; + margin: 30px 0px 50px 39px; + line-height: 1.5; + letter-spacing: 1.6px; + text-align: left; + color: #f2f2f4; +} + +.parent { + display: flex; + align-items: center; + flex-direction: column; + justify-content: center; +} + +.containerForgotPassword { + margin-top: 2px; + width:70%; +} + +.link { + cursor: pointer; + width: 100%; + color: #ee6633; + float: right; + font-size: 0.875rem; + font-family: 'lato ;sans-serif'; + font-weight: 600; +} + +.Typo { + margin-right: 6px; +} + +.createLogin { + margin-top: 2%; + display: flex; + justify-content: center; + flex-direction: row; + flex-wrap: wrap; + width: 100%; +} + +.loginButtonStyle { + border-radius: 20px; + color: #FFFFFF; +} + + diff --git a/src/styles/Dataset.js b/src/styles/Dataset.js deleted file mode 100644 index d99b0dc7..00000000 --- a/src/styles/Dataset.js +++ /dev/null @@ -1,314 +0,0 @@ -import { makeStyles } from '@mui/styles'; -// #EE6633 - - -const DatasetStyle = makeStyles({ - - Projectsettingtextarea: { - width: "100%", - fontSize: "1.4rem", - fontFamily: "Roboto", - fontWeight: 10, - lineHeight: 1.2, - - }, - custombtn:{ - borderRadius:0 - }, - workspaceTables: { - marginTop: "20px" - }, - projectButton: { - width: "100%", - textDecoration: "none", - }, - annotatorsButton: { - width: "100%" - }, - managersButton: { - width: "100%" - }, - settingsButton: { - width: "100%", - color: "#ee6633" - }, - workspaceCard: { - width: "100%", - minHeight: "420px", - padding: "40px", - justifyContent: "center", justifyItems: "center" - }, - projectsettingGrid: { - margin: "20px 0px 10px 0px", - - }, - filterToolbarContainer: { - // alignItems : 'center', - // display : 'inline', - // textAlign : "end" - display: "flex", - flexDirection: "row", - justifyContent: "flex-end", - alignItems: "center", - columnGap: "10px", - - }, - - clearAllBtn: { - float: "right", - margin: "9px 16px 0px auto", - padding: "0", - height: "15px", - }, - filterContainer: { - borderBottom: "1px solid #00000029", - padding: "18px", - // marginTop: "20px", - // width: "400px", - maxHeight: "400px", - overflow: "auto", - display: "flex", - flexDirection: "column", - gap: "10px", - "@media (max-width:550px)": { - // width: "200px", - maxHeight: "170px", - }, - }, - statusFilterContainer: { - // display : 'contents', - alignItems: "center", - }, - filterTypo: { - // marginBottom: "9px", - // marginRight : "20px" - }, - applyBtn: { - float: "right", - borderRadius: "20px", - margin: "9px 16px 9px auto", - width: "80px", - }, - clrBtn: { - float: "right", - borderRadius: "20px", - margin: "9px 10px 9px auto", - width: "100px", - }, - menuStyle: { - padding: "0px", - justifyContent: "left", - fontSize: "1.125rem", - fontWeight: "500 !important", - - "&:hover": { - backgroundColor: "white", - }, - borderBottom: "1px solid rgba(0, 0, 0, 0.42)", - // borderTop:"3px solid green", - "& svg": { - marginLeft: "auto", - color: "rgba(0, 0, 0, 0.42)", - }, - }, - projectCardContainer: { - cursor: 'pointer' - }, - modelname: { - boxSizing: "border-box", - // marginTop: "15px", - height: "64px", - backgroundColor: "white", - maxWidth: "90%", - minWidth: '90%', - width: "auto", - display: "flex", - alignItems: "center", - padding: "0 15px", - borderRadius: "12px", - }, - parentContainer: { - minHeight: "100vh", - // direction: "row", - alignItems: "center", - paddingBottom: "5vh", - // justifyContent: "space-around", - flexGrow: 0 - }, - projectCardContainer1: { - backgroundColor: "#2A61AD", - height: "100%", - width: "100%" - - }, - projectCardContainer2: { - backgroundColor: "#119DA4", - height: "100%", - width: "100%" - }, - userCardContainer: { - direction: "column", - alignItems: "center", - height: "100%", - placeContent: "center" - }, - dashboardContentContainer: { - alignItems: "left", - justifyContent: "space-around", - minHeight: "70vh", - borderLeft: '1px solid lightgray', - paddingLeft: '5%' - }, - link: { - textDecoration: "none" - }, - progress: { - position: 'relative', - top: '40%', - left: '46%' - - }, - progressDiv: { - position: 'fixed', - // backgroundColor: 'rgba(0.5, 0, 0, 0.5)', - zIndex: 1000, - width: '100%', - height: '100%', - top: 0, - left: 0, - opacity: 1 - }, - search: { - //position: "relative", - borderRadius: "24px", - backgroundColor: "#F3F3F3", - marginLeft: "0px", - width: "300px", - //textAlign: "left", - //justifyContent:"center" - //float: "right", - marginBottom: "10px", - // position: "absolute", - // Right: "200px", - // top:"155px", - - }, - searchIcon: { - // padding: theme.spacing(0, 2), - // height: "100%", - position: "absolute", - pointerEvents: "none", - display: "flex", - alignItems: "center", - justifyContent: "center", - color: "#00000029", - marginLeft: "10px", - marginTop: "10px", - }, - divider: { - borderLeft: "1px solid #E0E0E0", - height: "200px", - position: "absolute", - }, - rootdiv: { - marginTop: "25px", - }, - ToolbarContainer: { - position: "absolute", - bottom: "14px", - right: "45px" - - }, - TotalSummarydata: { - padding: "4px 0px 0px 4px", - }, - projectgrid: { - textAlign: "start" - }, - // fixedWidthContainer: { - // maxWidth: "5%", - // }, - root: { - minHeight: 40, - alignItems: "center", - }, - modelValue: { - fontSize: "14px", - fontFamily: "Roboto", - fontWeight: 400, - lineHeight: "22px", - "&:first-letter": { textTransform: "capitalize" }, - display: "-webkit-box", - "-webkit-line-clamp": "2", - "-webkit-box-orient": "vertical", - overflow: "hidden", - "@media (max-width:400px)": { - marginLeft: "-14px", - fontSize: "12px" - - }, - }, - descCardIcon: { - display: "flex", - borderRadius: "20%", - padding: "15px", - height: "fit-content", - }, - formControl: { - width: 300 - }, - AddGlossaryCard: { - width: "100%", - minHeight: "420px", - padding: "20px 40px 20px 40px", - justifyContent: "center", justifyItems: "center" - }, - SuggestAnEditCard: { - width: "100%", - minHeight: "350px", - padding: "20px 40px 20px 40px", - justifyContent: "center", justifyItems: "center" - }, - - heading: { - textAlign: "center", - marginBottom: "35px", - color: "#3A3A3A", - fontSize: "2.5rem", - fontWeight: 400, - }, - topBar: { - display: "flex", - alignItems: "center", - backgroundColor: "#DEECFF", - fontSize: "18px", - }, - - topBarInnerBox: { - width: "25%", - display: "flex", - flexDirection: "column", - textAlign: "center", - boxShadow: "3px 0 2px -2px #00000029", - }, - toolTip: { - width: "200px", height: "180px", fontSize: "16px", backgroundColor: "white", color: "black", padding: "5px 10px 10px 10px", border: "1px solid gray" - }, - - toolTips: { - width: "280px", height: "220px", fontSize: "16px", backgroundColor: "white", color: "black", padding: "5px 10px 10px 10px", border: "1px solid gray" - }, - - textTransliteration:{ - borderRadius: "3px", - - height: "60px", - padding: "15px 10px 10px 10px", - resize: "none", - margin: "7px 0px 0px 0px", - width: "200px",fontSize:"16px" - } - -}) - -export default DatasetStyle \ No newline at end of file diff --git a/src/themes/TableTheme.js b/src/themes/TableTheme.js deleted file mode 100644 index 53bc6ad7..00000000 --- a/src/themes/TableTheme.js +++ /dev/null @@ -1,59 +0,0 @@ -import themeDefault from './theme'; -import { createTheme } from "@mui/material/styles"; - -const tableTheme = createTheme({ - ...themeDefault, - components: { - ...themeDefault.components, - MuiButton: { - styleOverrides: { - root: { - minWidth: "25", - borderRadius: "none", - textTransform: "none", - }, - label: { - textTransform: "none", - fontFamily: '"Roboto", "Segoe UI"', - fontSize: "16px", - letterSpacing: "0.16px", - textAlign: "center", - display: "flex", - justifyContent: "center", - height: "19px", - "@media (max-width:640px)": { - fontSize: "10px", - }, - }, - }, - }, - MuiPopover: { - styleOverrides: { - paper: { - maxHeight: "30%", - }, - }, - }, - MUIDataTableFilter: { - styleOverrides: { - root: { - backgroundColor: "white", - width: "80%", - fontFamily: '"Roboto" ,sans-serif', - }, - checkboxFormControl: { - minWidth: "120px", - }, - }, - }, - MuiFormControl: { - styleOverrides: { - root: { - padding: "24px", - }, - }, - }, - }, -}); - -export default tableTheme; \ No newline at end of file diff --git a/src/themes/theme.js b/src/themes/theme.js index 952c4957..a24eb233 100644 --- a/src/themes/theme.js +++ b/src/themes/theme.js @@ -120,10 +120,10 @@ const themeDefault = createTheme({ MuiTableRow: { styleOverrides: { root: { - "&:nth-child(odd)": { + "&:nth-of-type(odd)": { backgroundColor: "#D6EAF8", }, - "&:nth-child(even)": { + "&:nth-of-type(even)": { backgroundColor: "#E9F7EF", }, "&.MuiTableRow-hover:hover:nth-of-type(odd)": { From bf953f8923379e1123c6017fbad9eb757c7196b7 Mon Sep 17 00:00:00 2001 From: Ayush Panwar Date: Wed, 10 Jan 2024 01:55:10 +0530 Subject: [PATCH 2/2] temporarily remove dynamic routing in order to serve on gh-pages --- next.config.js | 1 + src/app/new-project/client.js | 969 ------------------ .../{workspace/[id] => }/new-project/page.js | 20 +- .../[id] => }/new-project/shoonya_page.js | 0 4 files changed, 13 insertions(+), 977 deletions(-) delete mode 100644 src/app/new-project/client.js rename src/app/{workspace/[id] => }/new-project/page.js (98%) rename src/app/{workspace/[id] => }/new-project/shoonya_page.js (100%) diff --git a/next.config.js b/next.config.js index 3ff8c46a..491d8796 100644 --- a/next.config.js +++ b/next.config.js @@ -1,5 +1,6 @@ /** @type {import('next').NextConfig} */ const nextConfig = { + output: 'export', images: { unoptimized: true } } diff --git a/src/app/new-project/client.js b/src/app/new-project/client.js deleted file mode 100644 index f594910a..00000000 --- a/src/app/new-project/client.js +++ /dev/null @@ -1,969 +0,0 @@ -import { - Box, - Chip, - Grid, - ThemeProvider, - Typography, - Card, - IconButton, - InputLabel, -} from "@mui/material"; -import tableTheme from "../../themes/TableTheme"; -import CancelIcon from "@mui/icons-material/Cancel"; -import React, { useEffect, useState } from "react"; -import themeDefault from "../../../themes/theme"; -import Button from "../../../components/common/Button"; -import ColumnList from "../../../components/common/ColumnList"; -import OutlinedTextField from "../../../components/common/OutlinedTextField"; -import "../../styles/Dataset.css"; -import MenuItem from "@mui/material/MenuItem"; -import FormControl from "@mui/material/FormControl"; -import Select from "@mui/material/Select"; -import MUIDataTable from "mui-datatables"; -import MenuItems from "../../../components/common/MenuItems"; -import CustomizedSnackbars from "../../../components/common/Snackbar"; -import Spinner from "../../../components/common/Spinner"; -import FormControlLabel from "@mui/material/FormControlLabel"; -import Switch from "@mui/material/Switch"; -import SearchIcon from "@mui/icons-material/Search"; - -const isNum = (str) => { - var reg = new RegExp("^[0-9]*$"); - return reg.test(String(str)); -}; - -const CreateProject = () => { - - - - const [domains, setDomains] = useState([]); - const [projectTypes, setProjectTypes] = useState(null); - const [datasetTypes, setDatasetTypes] = useState(null); - const [instanceIds, setInstanceIds] = useState(null); - const [columnFields, setColumnFields] = useState(null); - const [variableParameters, setVariableParameters] = useState(null); - const [languageOptions, setLanguageOptions] = useState([]); - const [searchedCol, setSearchedCol] = useState(); - const [title, setTitle] = useState(""); - const [description, setDescription] = useState(""); - const [selectedDomain, setSelectedDomain] = useState(""); - const [selectedType, setSelectedType] = useState(""); - const [sourceLanguage, setSourceLanguage] = useState(""); - const [targetLanguage, setTargetLanguage] = useState(""); - const [samplingMode, setSamplingMode] = useState(null); - const [random, setRandom] = useState(""); - const [batchSize, setBatchSize] = useState(); - const [batchNumber, setBatchNumber] = useState([]); - const [samplingParameters, setSamplingParameters] = useState(null); - const [selectedInstances, setSelectedInstances] = useState([]); - const [confirmed, setConfirmed] = useState(false); - const [selectedAnnotatorsNum, setSelectedAnnotatorsNum] = useState(1); - const [filterString, setFilterString] = useState(null); - const [selectedVariableParameters, setSelectedVariableParameters] = useState( - [] - ); - const [taskReviews, setTaskReviews] = useState(1); - const [variable_Parameters_lang, setVariable_Parameters_lang] = useState(""); - //Table related state variables - const [columns, setColumns] = useState(null); - const [selectedColumns, setSelectedColumns] = useState([]); - const [currentPageNumber, setCurrentPageNumber] = useState(1); - const [currentRowPerPage, setCurrentRowPerPage] = useState(10); - const [totalDataitems, setTotalDataitems] = useState(10); - const [tableData, setTableData] = useState([]); - const [searchAnchor, setSearchAnchor] = useState(null); - const [selectedFilters, setsSelectedFilters] = useState({}); - const [createannotationsAutomatically, setsCreateannotationsAutomatically] = useState("none"); - const [acousticEnabledStage, setAcousticEnabledStage] = useState(null); - - const searchOpen = Boolean(searchAnchor); - const excludeKeys = [ - "parent_data_id", - // "metadata_json", - "instance_id_id", - "datasetbase_ptr_id", - "key", - "instance_id", - "labse_score", - "parent_data", - "id", - "rating", - ]; - - const renderToolBar = () => { - return ( - - - - - - - - ); - }; - - const customColumnHead = (col) => { - return ( - - {col.label} - handleShowSearch(col.name, e)} - > - - - - ); - }; - - const options = { - count: totalDataitems, - rowsPerPage: currentRowPerPage, - page: currentPageNumber - 1, - rowsPerPageOptions: [10, 25, 50, 100], - textLabels: { - pagination: { - next: "Next >", - previous: "< Previous", - rowsPerPage: "currentRowPerPage", - displayRows: "OF", - }, - }, - onChangePage: (currentPage) => { - setCurrentPageNumber(currentPage + 1); - }, - onChangeRowsPerPage: (rowPerPageCount) => { - setCurrentRowPerPage(rowPerPageCount); - }, - filterType: "checkbox", - selectableRows: "none", - download: false, - filter: false, - print: false, - search: false, - viewColumns: false, - textLabels: { - body: { - noMatch: "No records ", - }, - toolbar: { - search: "Search", - viewColumns: "View Column", - }, - pagination: { - rowsPerPage: "Rows per page", - }, - options: { sortDirection: "desc" }, - }, - jumpToPage: true, - serverSide: true, - customToolbar: renderToolBar, - }; - - return ( - - - - - - - - Create a Project - - - - - - - Title: - - - - setTitle(e.target.value)} - /> - - - - - - Description: - - - - setDescription(e.target.value)} - /> - - - {domains && ( - <> - - - Select a Category to Work in: - - - - - - - )} - - {selectedDomain && ( - <> - - - Select a Project Type: - - - - { - return { - name: key, - value: key, - }; - })} - handleChange={onSelectProjectType} - value={selectedType} - /> - - - )} - - {selectedType && - variableParameters?.[selectedType]?.variable_parameters !== - undefined && ( - <> - - - Variable Parameters: - - - - - setVariable_Parameters_lang(e.target.value) - } - /> - - - )} - {(selectedDomain === "Translation" || - selectedDomain === "Conversation") && - (selectedType === "TranslationEditing" || - selectedType === "SemanticTextualSimilarity" || - selectedType === "ContextualTranslationEditing" || - selectedType === "ConversationTranslation" || - selectedType === "ConversationTranslationEditing") && ( - <> - - - Source Language: - - - - - - - - - - - Target Language: - - - - - - - - - )} - - {(selectedDomain === "Monolingual" || - selectedDomain === "Translation" || - selectedDomain === "Audio") && - (selectedType === "SentenceSplitting" || - selectedType === "ContextualSentenceVerification" || - selectedType === "MonolingualTranslation" || - selectedType === "SingleSpeakerAudioTranscriptionEditing" || - selectedType === "AudioTranscription" || - selectedType === "AudioSegmentation" || - selectedType === "AudioTranscriptionEditing" || - selectedType === "AcousticNormalisedTranscriptionEditing") && ( - <> - - - {selectedType === "SingleSpeakerAudioTranscriptionEditing" - ? "Language:" - : "Target Language:"} - - - - - - - - - )} - - {instanceIds && ( - <> - {selectedVariableParameters.map((parameter, index) => ( - <> - {selectedType === "Conversation" && - (selectedType === "ContextualTranslationEditing" || - selectedType === "ConversationTranslation") && ( - - - {processNameString(parameter["name"])}: - - - )} - - {parameter?.data["choices"] !== undefined ? ( - <> - {selectedType === "Conversation" && - (selectedType === "ContextualTranslationEditing" || - selectedType === "ConversationTranslation") && ( - { - return { - name: element[0], - value: element[0], - }; - } - )} - value={ - selectedVariableParameters[index]["value"] - } - handleChange={(e) => - handleVariableParametersChange( - parameter["name"], - e - ) - } - > - )} - - ) : ( - <> - {parameter.data["name"] === "DecimalField" || - parameter.data["name"] === "IntegerField" ? ( - - handleVariableParametersChange( - parameter["name"], - e - ) - } - inputProps={{ - step: 1, - min: 0, - max: 99999, - type: "number", - }} - /> - ) : ( - - handleVariableParametersChange( - parameter["name"], - e - ) - } - /> - )} - - )} - - - ))} - {selectedType && Object.keys(instanceIds).length > 0 && ( - <> - - - Select sources to fetch data from: - - - - - - - - - - {selectedInstances.length > 0 && ( - <> -