From d351e8864da9268a0110214d91f76f671507acb3 Mon Sep 17 00:00:00 2001 From: swve Date: Thu, 22 Jun 2023 18:27:13 +0200 Subject: [PATCH] feat: implement elements authorization + bump next --- .../collection/[collectionid]/page.tsx | 5 +- .../(withmenu)/collections/admin.tsx | 60 +----- .../[orgslug]/(withmenu)/collections/page.tsx | 6 +- .../[orgslug]/(withmenu)/courses/courses.tsx | 109 ++++------- .../Security/AuthenticatedClientElement.tsx | 49 +++++ front/package-lock.json | 174 +++++++++--------- front/package.json | 2 +- 7 files changed, 187 insertions(+), 218 deletions(-) create mode 100644 front/components/Security/AuthenticatedClientElement.tsx diff --git a/front/app/orgs/[orgslug]/(withmenu)/collection/[collectionid]/page.tsx b/front/app/orgs/[orgslug]/(withmenu)/collection/[collectionid]/page.tsx index 7a79fa23..f96b7734 100644 --- a/front/app/orgs/[orgslug]/(withmenu)/collection/[collectionid]/page.tsx +++ b/front/app/orgs/[orgslug]/(withmenu)/collection/[collectionid]/page.tsx @@ -1,3 +1,4 @@ +import GeneralWrapperStyled from "@components/StyledElements/Wrappers/GeneralWrapper"; import { getBackendUrl, getUriWithOrg } from "@services/config/config"; import { getCollectionByIdWithAuthHeader } from "@services/courses/collections"; import { getOrganizationContextInfo } from "@services/organizations/orgs"; @@ -38,7 +39,7 @@ const CollectionPage = async (params : any) => { } - return
+ return

Collection

{col.name}


@@ -56,7 +57,7 @@ const CollectionPage = async (params : any) => { -
; + ; }; export default CollectionPage; \ No newline at end of file diff --git a/front/app/orgs/[orgslug]/(withmenu)/collections/admin.tsx b/front/app/orgs/[orgslug]/(withmenu)/collections/admin.tsx index a9002ab4..04a9307d 100644 --- a/front/app/orgs/[orgslug]/(withmenu)/collections/admin.tsx +++ b/front/app/orgs/[orgslug]/(withmenu)/collections/admin.tsx @@ -1,5 +1,6 @@ 'use client'; +import AuthenticatedClientElement from '@components/Security/AuthenticatedClientElement'; import { AuthContext } from '@components/Security/AuthProvider'; import { getUriWithOrg } from '@services/config/config'; import { deleteCollection } from '@services/courses/collections'; @@ -9,33 +10,7 @@ import { useRouter } from 'next/navigation'; import React from 'react' const CollectionAdminEditsArea = (props: any) => { - const org_roles_values = ["admin", "owner"]; - const user_roles_values = ["role_admin"]; const router = useRouter(); - const auth: any = React.useContext(AuthContext); - - - // this is amazingly terrible code, but gotta release that MVP - // TODO: fix this - - function isAuthorized() { - const org_id = props.collection.org_id; - const org_roles = auth.userInfo.user_object.orgs; - const user_roles = auth.userInfo.user_object.roles; - const org_role = org_roles.find((org: any) => org.org_id == org_id); - const user_role = user_roles.find((role: any) => role.org_id == org_id); - - if (org_role && user_role) { - if (org_roles_values.includes(org_role.org_role) && user_roles_values.includes(user_role.role_id)) { - return true; - } - else { - return false; - } - } else { - return false; - } - } const deleteCollectionUI = async (collectionId: number) => { await deleteCollection(collectionId); @@ -45,30 +20,15 @@ const CollectionAdminEditsArea = (props: any) => { router.push(getUriWithOrg(props.orgslug, "/collections")); } - // this is amazingly terrible code, but gotta release that MVP - // TODO: fix this - - if (auth.isAuthenticated) { - if (isAuthorized()) { - return ( -
- - -
- ) - } else { - return ( -
- ) - } - } - else { - return ( -
- ) - } + return ( + +
+ +
+
+ ) } export default CollectionAdminEditsArea; \ No newline at end of file diff --git a/front/app/orgs/[orgslug]/(withmenu)/collections/page.tsx b/front/app/orgs/[orgslug]/(withmenu)/collections/page.tsx index 235be9e3..a933fab0 100644 --- a/front/app/orgs/[orgslug]/(withmenu)/collections/page.tsx +++ b/front/app/orgs/[orgslug]/(withmenu)/collections/page.tsx @@ -1,12 +1,10 @@ +import AuthenticatedClientElement from "@components/Security/AuthenticatedClientElement"; import TypeOfContentTitle from "@components/StyledElements/Titles/TypeOfContentTitle"; import GeneralWrapperStyled from "@components/StyledElements/Wrappers/GeneralWrapper"; import { getBackendUrl, getUriWithOrg } from "@services/config/config"; import { deleteCollection, getOrgCollectionsWithAuthHeader } from "@services/courses/collections"; -import { getCourseMetadataWithAuthHeader } from "@services/courses/courses"; import { getOrganizationContextInfo } from "@services/organizations/orgs"; -import { revalidateTags } from "@services/utils/ts/requests"; import { Metadata } from "next"; -import { revalidateTag } from "next/cache"; import { cookies } from "next/headers"; import Link from "next/link"; import CollectionAdminEditsArea from "./admin"; @@ -46,9 +44,11 @@ const CollectionsPage = async (params: any) => {
+ +
{collections.map((collection: any) => ( diff --git a/front/app/orgs/[orgslug]/(withmenu)/courses/courses.tsx b/front/app/orgs/[orgslug]/(withmenu)/courses/courses.tsx index af667d97..1257e34b 100644 --- a/front/app/orgs/[orgslug]/(withmenu)/courses/courses.tsx +++ b/front/app/orgs/[orgslug]/(withmenu)/courses/courses.tsx @@ -14,6 +14,7 @@ import { revalidateTags } from '@services/utils/ts/requests'; import { useRouter } from 'next/navigation'; import GeneralWrapperStyled from '@components/StyledElements/Wrappers/GeneralWrapper'; import TypeOfContentTitle from '@components/StyledElements/Titles/TypeOfContentTitle'; +import AuthenticatedClientElement from '@components/Security/AuthenticatedClientElement'; interface CourseProps { orgslug: string; @@ -47,28 +48,30 @@ function Courses(props: CourseProps) {
- } - dialogTitle="Create Course" - dialogDescription="Create a new course" - dialogTrigger={ - - } - /> + + } + dialogTitle="Create Course" + dialogDescription="Create a new course" + dialogTrigger={ + + } + /> +
-
+
{courses.map((course: any) => ( -
- +
+
@@ -86,64 +89,20 @@ function Courses(props: CourseProps) { ) } -const AdminEditsArea = (props: any) => { - const org_roles_values = ["admin", "owner"]; - const user_roles_values = ["role_admin"]; - - const auth: any = React.useContext(AuthContext); - console.log("auth: ", auth); - - - // this is amazingly terrible code, but gotta release that MVP - // TODO: fix this - - function isAuthorized() { - const org_id = props.course.org_id; - const org_roles = auth.userInfo.user_object.orgs; - const user_roles = auth.userInfo.user_object.roles; - const org_role = org_roles.find((org: any) => org.org_id == org_id); - const user_role = user_roles.find((role: any) => role.org_id == org_id); - - if (org_role && user_role) { - if (org_roles_values.includes(org_role.org_role) && user_roles_values.includes(user_role.role_id)) { - return true; - } - else { - return false; - } - } else { - return false; - } - } - - // this is amazingly terrible code, but gotta release that MVP - // TODO: fix this - - if (auth.isAuthenticated) { - if (isAuthorized()) { - return ( -
- - - - -
- ) - } else { - return ( -
- ) - } - } - else { - return ( -
- ) - } +const AdminEditsArea = (props: { orgSlug: string, courseId: string, course: any, deleteCourses: any }) => { + return ( +
+ + + + +
+
+ ) } diff --git a/front/components/Security/AuthenticatedClientElement.tsx b/front/components/Security/AuthenticatedClientElement.tsx new file mode 100644 index 00000000..126a458a --- /dev/null +++ b/front/components/Security/AuthenticatedClientElement.tsx @@ -0,0 +1,49 @@ +'use client'; +import React from "react"; +import { AuthContext } from "./AuthProvider"; + +interface AuthenticatedClientElementProps { + children: React.ReactNode; + checkMethod: 'authentication' | 'roles'; + orgId?: string; + +} + +function AuthenticatedClientElement(props: AuthenticatedClientElementProps) { + const auth: any = React.useContext(AuthContext); + + // Available roles + const org_roles_values = ["admin", "owner"]; + const user_roles_values = ["role_admin"]; + + + async function checkRoles() { + const org_id = props.orgId; + const org_roles = auth.userInfo.user_object.orgs; + const user_roles = auth.userInfo.user_object.roles; + const org_role = org_roles.find((org: any) => org.org_id == org_id); + const user_role = user_roles.find((role: any) => role.org_id == org_id); + + if (org_role && user_role) { + if (org_roles_values.includes(org_role.org_role) && user_roles_values.includes(user_role.role_id)) { + return true; + } + else { + return false; + } + } else { + return false; + } + } + + + + if ((props.checkMethod == 'authentication' && auth.isAuthenticated) || (auth.isAuthenticated && props.checkMethod == 'roles' && checkRoles())) { + return <>{props.children}; + } + return <>; + + +} + +export default AuthenticatedClientElement \ No newline at end of file diff --git a/front/package-lock.json b/front/package-lock.json index 28d962dd..93f6cc59 100644 --- a/front/package-lock.json +++ b/front/package-lock.json @@ -26,7 +26,7 @@ "formik": "^2.2.9", "framer-motion": "^7.3.6", "lucide-react": "^0.104.1", - "next": "^13.4.7-canary.1", + "next": "^13.4.7-canary.4", "re-resizable": "^6.9.9", "react": "^18.2.0", "react-beautiful-dnd": "^13.1.1", @@ -2123,9 +2123,9 @@ } }, "node_modules/@next/env": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/env/-/env-13.4.7-canary.1.tgz", - "integrity": "sha512-2ZA+CatMIujZ5G8gN8E0ndxnMwqSEa856KUqz0hxOSJxFMT26Uds2Z6tz82sFU8biNaq4lT7cUJhGKccTXTXsg==" + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/env/-/env-13.4.7-canary.4.tgz", + "integrity": "sha512-dThTh5tfoySszTdUeu5BNacqpV72QWH8RkdlMEulpXyeInaJPnSaRhvpmT2S70tv+uRkKvUtfiFFFp+Cc/qhSA==" }, "node_modules/@next/eslint-plugin-next": { "version": "13.0.6", @@ -2137,9 +2137,9 @@ } }, "node_modules/@next/swc-darwin-arm64": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-13.4.7-canary.1.tgz", - "integrity": "sha512-LmqRfCFnBSI8HPis6es0wpH+2nX9/FiSqRYZsk8ibPWcIm37rq5Qwp5cAK3hQFWlJlNdTyGaJ1e49VKZUTEXBw==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-13.4.7-canary.4.tgz", + "integrity": "sha512-1iTgrJ0QdMjcdcfTTqHcHczELJSdDMHwMbgv/34+OQHQKiD/iUIfA1fGCSjF2FKMGY6bcf/hivknvU/WriW+eg==", "cpu": [ "arm64" ], @@ -2152,9 +2152,9 @@ } }, "node_modules/@next/swc-darwin-x64": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-13.4.7-canary.1.tgz", - "integrity": "sha512-ngS/YWlBzhC2hb9Lmw6cCcks2aZRvFIB+iHlygZIELTfBPd9OUoRlOaa/KQLa/ycKwL2c8L8AFL67i3KQs5j3g==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-13.4.7-canary.4.tgz", + "integrity": "sha512-ISZIhquYKNjlM5VzKkUXzsd7sZv3UQvBDj0H5YhYf3sKnemAtCQFQuPzLDDYfr7sHeUQYUrYJTmuBe3b6txXhg==", "cpu": [ "x64" ], @@ -2167,9 +2167,9 @@ } }, "node_modules/@next/swc-linux-arm64-gnu": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-13.4.7-canary.1.tgz", - "integrity": "sha512-5NDlJaba0tWz7mU6IpCfOQ5xDwXwFg4SV6IKLDoNFEchkmlAifW8y2i2OCdmaG+MDpODi3xUBkM1qP2Sd6oUMQ==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-13.4.7-canary.4.tgz", + "integrity": "sha512-Em/pek7kLEcdGl75nXzdV3uWFr+9iXiCpVGpQFo2KKsMBiWxQW2tfXaZI3CJFmmfgtcDKU9RBFmsr7lejd6LWA==", "cpu": [ "arm64" ], @@ -2182,9 +2182,9 @@ } }, "node_modules/@next/swc-linux-arm64-musl": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-13.4.7-canary.1.tgz", - "integrity": "sha512-bYIMi8vhtlCvAMg2xa0CCeOZ0wOZoOKUd9w46qmWfddBUuhwJj5C+QKHXOG+oTxXIVxq14Ffkww9orafYV0R6g==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-13.4.7-canary.4.tgz", + "integrity": "sha512-e/+MQ9I9EjriTK1BoXiGWCjhCPLbPLl2qIAmYDge3Nedn5bgOEvZ/KfKDhF/ZNyV6/nomI5Vy4Wt7IrCleq80Q==", "cpu": [ "arm64" ], @@ -2197,9 +2197,9 @@ } }, "node_modules/@next/swc-linux-x64-gnu": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-13.4.7-canary.1.tgz", - "integrity": "sha512-FvO2t5F02zzvWRybStIR5QZJnOSaznF6E7njBD0hcCeb3Il84rKJCc4DoMhcLt68YljI6tWhqlDbiy+7ghfJlg==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-13.4.7-canary.4.tgz", + "integrity": "sha512-l/edze3fPIkbF11PdDF2ryHsqZOMKAVkZFnqet8j3j3lJbn8ytB7lygq/+PP2XGJfkSyoi8yVfgbHjWaVVorxA==", "cpu": [ "x64" ], @@ -2212,9 +2212,9 @@ } }, "node_modules/@next/swc-linux-x64-musl": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-13.4.7-canary.1.tgz", - "integrity": "sha512-2kxqgbBvP+WUrKrrEcFqWGKrff5hGCmzEju5sbEZExuFV7sy+4nf5I9A9f0dFiP3z1hudVGJDrgbcDwt0Odvxw==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-13.4.7-canary.4.tgz", + "integrity": "sha512-KPQM4Wu3vhau90HB4DaJ94mGEpcu3/XfHli/5R6d4Dv12hOCbvMBU9tBX0HD6Epng4jwRliWhvNxZE2B/hCfBA==", "cpu": [ "x64" ], @@ -2227,9 +2227,9 @@ } }, "node_modules/@next/swc-win32-arm64-msvc": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-13.4.7-canary.1.tgz", - "integrity": "sha512-u+IxAt8i/iYc760qAMlrs0yGyYNokRJpWWdVBwTQ7n5zsjpJ2xifga3r8fWEJwdRvH0yVx15IM/QYZXQOJ8TQA==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-13.4.7-canary.4.tgz", + "integrity": "sha512-fvohejq2OZHGTHYe4caf4xTlqtMBrsqKwMJnTaq3XEdsXgkkoBGmJS53rNGGIGRPI3IgwvvpgVNEwxJjswjCeA==", "cpu": [ "arm64" ], @@ -2242,9 +2242,9 @@ } }, "node_modules/@next/swc-win32-ia32-msvc": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-13.4.7-canary.1.tgz", - "integrity": "sha512-aChXbr2c0aEwMhhkl9+JT7A2x7JMpmP5NLD7m+Drt4Ss6NZYTwecJTFEt/AbtIm5V/pMYVb1UDZXJtfTKNiHhw==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-13.4.7-canary.4.tgz", + "integrity": "sha512-g+a2ELe2iPYNy4QQp0GKQzCwvrkPM1Vc+CDLcOz47K0ERp+LR08krDtprMjBuZvo7VP7z8+23edCnfaT8jQibA==", "cpu": [ "ia32" ], @@ -2257,9 +2257,9 @@ } }, "node_modules/@next/swc-win32-x64-msvc": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-13.4.7-canary.1.tgz", - "integrity": "sha512-AcZDEqMXW3Bm2dmhMc8metReCpx/NilC8LPKP44SFM97y5OaAfhG+47n0SAmhI9L8NaWMsZCS5NryM/6scyaWQ==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-13.4.7-canary.4.tgz", + "integrity": "sha512-EVOdAT2QkAaLr/tjr77MhKwcj30zZwTDU2xWFOhwT3CFoLkrpU3krPE/YGvJa3eDb/lm0/H1mq9EmzHEJRfQew==", "cpu": [ "x64" ], @@ -6375,11 +6375,11 @@ "dev": true }, "node_modules/next": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/next/-/next-13.4.7-canary.1.tgz", - "integrity": "sha512-IKmDxqALqXSSJHSdlslKq1Dry5x8gaQfXtOo8acyVRu0GDIc/Az8Hv/TWUkRGZPA76yllZeEf16LIv3QLkvLMA==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/next/-/next-13.4.7-canary.4.tgz", + "integrity": "sha512-12wtYa0EWHFdiVGyP4fOp4BzmSV0glh4see0/EDcGUwL2fTpmrs6UxPZVGZ2gh0Nrk25YQ8vKBzO1F6mrUuQcw==", "dependencies": { - "@next/env": "13.4.7-canary.1", + "@next/env": "13.4.7-canary.4", "@swc/helpers": "0.5.1", "busboy": "1.6.0", "caniuse-lite": "^1.0.30001406", @@ -6395,15 +6395,15 @@ "node": ">=16.8.0" }, "optionalDependencies": { - "@next/swc-darwin-arm64": "13.4.7-canary.1", - "@next/swc-darwin-x64": "13.4.7-canary.1", - "@next/swc-linux-arm64-gnu": "13.4.7-canary.1", - "@next/swc-linux-arm64-musl": "13.4.7-canary.1", - "@next/swc-linux-x64-gnu": "13.4.7-canary.1", - "@next/swc-linux-x64-musl": "13.4.7-canary.1", - "@next/swc-win32-arm64-msvc": "13.4.7-canary.1", - "@next/swc-win32-ia32-msvc": "13.4.7-canary.1", - "@next/swc-win32-x64-msvc": "13.4.7-canary.1" + "@next/swc-darwin-arm64": "13.4.7-canary.4", + "@next/swc-darwin-x64": "13.4.7-canary.4", + "@next/swc-linux-arm64-gnu": "13.4.7-canary.4", + "@next/swc-linux-arm64-musl": "13.4.7-canary.4", + "@next/swc-linux-x64-gnu": "13.4.7-canary.4", + "@next/swc-linux-x64-musl": "13.4.7-canary.4", + "@next/swc-win32-arm64-msvc": "13.4.7-canary.4", + "@next/swc-win32-ia32-msvc": "13.4.7-canary.4", + "@next/swc-win32-x64-msvc": "13.4.7-canary.4" }, "peerDependencies": { "@opentelemetry/api": "^1.1.0", @@ -10056,9 +10056,9 @@ } }, "@next/env": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/env/-/env-13.4.7-canary.1.tgz", - "integrity": "sha512-2ZA+CatMIujZ5G8gN8E0ndxnMwqSEa856KUqz0hxOSJxFMT26Uds2Z6tz82sFU8biNaq4lT7cUJhGKccTXTXsg==" + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/env/-/env-13.4.7-canary.4.tgz", + "integrity": "sha512-dThTh5tfoySszTdUeu5BNacqpV72QWH8RkdlMEulpXyeInaJPnSaRhvpmT2S70tv+uRkKvUtfiFFFp+Cc/qhSA==" }, "@next/eslint-plugin-next": { "version": "13.0.6", @@ -10070,57 +10070,57 @@ } }, "@next/swc-darwin-arm64": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-13.4.7-canary.1.tgz", - "integrity": "sha512-LmqRfCFnBSI8HPis6es0wpH+2nX9/FiSqRYZsk8ibPWcIm37rq5Qwp5cAK3hQFWlJlNdTyGaJ1e49VKZUTEXBw==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-13.4.7-canary.4.tgz", + "integrity": "sha512-1iTgrJ0QdMjcdcfTTqHcHczELJSdDMHwMbgv/34+OQHQKiD/iUIfA1fGCSjF2FKMGY6bcf/hivknvU/WriW+eg==", "optional": true }, "@next/swc-darwin-x64": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-13.4.7-canary.1.tgz", - "integrity": "sha512-ngS/YWlBzhC2hb9Lmw6cCcks2aZRvFIB+iHlygZIELTfBPd9OUoRlOaa/KQLa/ycKwL2c8L8AFL67i3KQs5j3g==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-darwin-x64/-/swc-darwin-x64-13.4.7-canary.4.tgz", + "integrity": "sha512-ISZIhquYKNjlM5VzKkUXzsd7sZv3UQvBDj0H5YhYf3sKnemAtCQFQuPzLDDYfr7sHeUQYUrYJTmuBe3b6txXhg==", "optional": true }, "@next/swc-linux-arm64-gnu": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-13.4.7-canary.1.tgz", - "integrity": "sha512-5NDlJaba0tWz7mU6IpCfOQ5xDwXwFg4SV6IKLDoNFEchkmlAifW8y2i2OCdmaG+MDpODi3xUBkM1qP2Sd6oUMQ==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-13.4.7-canary.4.tgz", + "integrity": "sha512-Em/pek7kLEcdGl75nXzdV3uWFr+9iXiCpVGpQFo2KKsMBiWxQW2tfXaZI3CJFmmfgtcDKU9RBFmsr7lejd6LWA==", "optional": true }, "@next/swc-linux-arm64-musl": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-13.4.7-canary.1.tgz", - "integrity": "sha512-bYIMi8vhtlCvAMg2xa0CCeOZ0wOZoOKUd9w46qmWfddBUuhwJj5C+QKHXOG+oTxXIVxq14Ffkww9orafYV0R6g==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-13.4.7-canary.4.tgz", + "integrity": "sha512-e/+MQ9I9EjriTK1BoXiGWCjhCPLbPLl2qIAmYDge3Nedn5bgOEvZ/KfKDhF/ZNyV6/nomI5Vy4Wt7IrCleq80Q==", "optional": true }, "@next/swc-linux-x64-gnu": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-13.4.7-canary.1.tgz", - "integrity": "sha512-FvO2t5F02zzvWRybStIR5QZJnOSaznF6E7njBD0hcCeb3Il84rKJCc4DoMhcLt68YljI6tWhqlDbiy+7ghfJlg==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-13.4.7-canary.4.tgz", + "integrity": "sha512-l/edze3fPIkbF11PdDF2ryHsqZOMKAVkZFnqet8j3j3lJbn8ytB7lygq/+PP2XGJfkSyoi8yVfgbHjWaVVorxA==", "optional": true }, "@next/swc-linux-x64-musl": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-13.4.7-canary.1.tgz", - "integrity": "sha512-2kxqgbBvP+WUrKrrEcFqWGKrff5hGCmzEju5sbEZExuFV7sy+4nf5I9A9f0dFiP3z1hudVGJDrgbcDwt0Odvxw==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-13.4.7-canary.4.tgz", + "integrity": "sha512-KPQM4Wu3vhau90HB4DaJ94mGEpcu3/XfHli/5R6d4Dv12hOCbvMBU9tBX0HD6Epng4jwRliWhvNxZE2B/hCfBA==", "optional": true }, "@next/swc-win32-arm64-msvc": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-13.4.7-canary.1.tgz", - "integrity": "sha512-u+IxAt8i/iYc760qAMlrs0yGyYNokRJpWWdVBwTQ7n5zsjpJ2xifga3r8fWEJwdRvH0yVx15IM/QYZXQOJ8TQA==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-13.4.7-canary.4.tgz", + "integrity": "sha512-fvohejq2OZHGTHYe4caf4xTlqtMBrsqKwMJnTaq3XEdsXgkkoBGmJS53rNGGIGRPI3IgwvvpgVNEwxJjswjCeA==", "optional": true }, "@next/swc-win32-ia32-msvc": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-13.4.7-canary.1.tgz", - "integrity": "sha512-aChXbr2c0aEwMhhkl9+JT7A2x7JMpmP5NLD7m+Drt4Ss6NZYTwecJTFEt/AbtIm5V/pMYVb1UDZXJtfTKNiHhw==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-13.4.7-canary.4.tgz", + "integrity": "sha512-g+a2ELe2iPYNy4QQp0GKQzCwvrkPM1Vc+CDLcOz47K0ERp+LR08krDtprMjBuZvo7VP7z8+23edCnfaT8jQibA==", "optional": true }, "@next/swc-win32-x64-msvc": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-13.4.7-canary.1.tgz", - "integrity": "sha512-AcZDEqMXW3Bm2dmhMc8metReCpx/NilC8LPKP44SFM97y5OaAfhG+47n0SAmhI9L8NaWMsZCS5NryM/6scyaWQ==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-13.4.7-canary.4.tgz", + "integrity": "sha512-EVOdAT2QkAaLr/tjr77MhKwcj30zZwTDU2xWFOhwT3CFoLkrpU3krPE/YGvJa3eDb/lm0/H1mq9EmzHEJRfQew==", "optional": true }, "@nicolo-ribaudo/chokidar-2": { @@ -13093,20 +13093,20 @@ "dev": true }, "next": { - "version": "13.4.7-canary.1", - "resolved": "https://registry.npmjs.org/next/-/next-13.4.7-canary.1.tgz", - "integrity": "sha512-IKmDxqALqXSSJHSdlslKq1Dry5x8gaQfXtOo8acyVRu0GDIc/Az8Hv/TWUkRGZPA76yllZeEf16LIv3QLkvLMA==", + "version": "13.4.7-canary.4", + "resolved": "https://registry.npmjs.org/next/-/next-13.4.7-canary.4.tgz", + "integrity": "sha512-12wtYa0EWHFdiVGyP4fOp4BzmSV0glh4see0/EDcGUwL2fTpmrs6UxPZVGZ2gh0Nrk25YQ8vKBzO1F6mrUuQcw==", "requires": { - "@next/env": "13.4.7-canary.1", - "@next/swc-darwin-arm64": "13.4.7-canary.1", - "@next/swc-darwin-x64": "13.4.7-canary.1", - "@next/swc-linux-arm64-gnu": "13.4.7-canary.1", - "@next/swc-linux-arm64-musl": "13.4.7-canary.1", - "@next/swc-linux-x64-gnu": "13.4.7-canary.1", - "@next/swc-linux-x64-musl": "13.4.7-canary.1", - "@next/swc-win32-arm64-msvc": "13.4.7-canary.1", - "@next/swc-win32-ia32-msvc": "13.4.7-canary.1", - "@next/swc-win32-x64-msvc": "13.4.7-canary.1", + "@next/env": "13.4.7-canary.4", + "@next/swc-darwin-arm64": "13.4.7-canary.4", + "@next/swc-darwin-x64": "13.4.7-canary.4", + "@next/swc-linux-arm64-gnu": "13.4.7-canary.4", + "@next/swc-linux-arm64-musl": "13.4.7-canary.4", + "@next/swc-linux-x64-gnu": "13.4.7-canary.4", + "@next/swc-linux-x64-musl": "13.4.7-canary.4", + "@next/swc-win32-arm64-msvc": "13.4.7-canary.4", + "@next/swc-win32-ia32-msvc": "13.4.7-canary.4", + "@next/swc-win32-x64-msvc": "13.4.7-canary.4", "@swc/helpers": "0.5.1", "busboy": "1.6.0", "caniuse-lite": "^1.0.30001406", diff --git a/front/package.json b/front/package.json index d08c4320..df569dca 100644 --- a/front/package.json +++ b/front/package.json @@ -27,7 +27,7 @@ "formik": "^2.2.9", "framer-motion": "^7.3.6", "lucide-react": "^0.104.1", - "next": "^13.4.7-canary.1", + "next": "^13.4.7-canary.4", "re-resizable": "^6.9.9", "react": "^18.2.0", "react-beautiful-dnd": "^13.1.1",