From ffa050da18da2f32687489c8619f78da8bad4fd7 Mon Sep 17 00:00:00 2001 From: shadrach Date: Thu, 7 Nov 2024 14:31:19 -0600 Subject: [PATCH] attestation updates --- package.json | 1 + .../[attestationId]/edit/page.tsx | 11 +- .../molecules/CommunityAttestations.tsx | 88 ++++++-- src/components/molecules/CommunityMembers.tsx | 6 +- .../organisms/forms/attestation-form.tsx | 9 +- .../organisms/forms/community-form.tsx | 5 +- src/lib/api/index.ts | 16 ++ yarn.lock | 190 +++++++++++------- 8 files changed, 221 insertions(+), 105 deletions(-) diff --git a/package.json b/package.json index 51894ed..37c4c7e 100644 --- a/package.json +++ b/package.json @@ -39,6 +39,7 @@ "react": "^18", "react-dom": "^18", "react-hook-form": "^7.53.0", + "react-icons": "^5.3.0", "react-markdown": "^9.0.1", "react-resizable-panels": "^2.1.2", "recharts": "^2.12.7", diff --git a/src/app/(auth)/communities/[id]/attestations/[attestationId]/edit/page.tsx b/src/app/(auth)/communities/[id]/attestations/[attestationId]/edit/page.tsx index 5a7291e..41962fa 100644 --- a/src/app/(auth)/communities/[id]/attestations/[attestationId]/edit/page.tsx +++ b/src/app/(auth)/communities/[id]/attestations/[attestationId]/edit/page.tsx @@ -1,9 +1,9 @@ "use client"; -import { useQuery, useSuspenseQuery } from "@tanstack/react-query"; -import { listAttestationsQuery, listCommunitiesQuery } from "@/lib/api"; -import { useFormState } from "react-dom"; -import { createAttestation, updateAttestation } from "@/app/actions"; +import { useQuery } from "@tanstack/react-query"; +import { listAttestationsQuery } from "@/lib/api"; +import { useFormState, useFormStatus } from "react-dom"; +import { updateAttestation } from "@/app/actions"; import AttestationForm from "@/components/organisms/forms/attestation-form"; import NotFoundError from "@/app/not-found"; import { getQueryClient } from "@/lib/get-query-client"; @@ -20,13 +20,12 @@ export default function Page({ const [state, formAction] = useFormState< ReturnType >(updateAttestation, defaultState); - + useFormStatus(); // todo: add skeleton loader const { data, isLoading } = useQuery(listAttestationsQuery, getQueryClient()); const attestation = data?.find((com) => com.id === parseInt(params.attestationId)); if (!attestation) return - return ( { diff --git a/src/components/molecules/CommunityAttestations.tsx b/src/components/molecules/CommunityAttestations.tsx index 27f7909..3abeaa4 100644 --- a/src/components/molecules/CommunityAttestations.tsx +++ b/src/components/molecules/CommunityAttestations.tsx @@ -28,6 +28,7 @@ import { DropdownMenuTrigger, } from "@/components/ui/dropdown-menu"; import { Check, X, Award, Plus, Settings, Lock, Pen } from "lucide-react"; +import { RxAccessibility } from "react-icons/rx"; import { cn } from "@/lib/utils"; import { addEntryAttestation, @@ -35,12 +36,15 @@ import { Community, listAttestationsQuery, removeEntryAttestation, + toggleEntryAttestationRequirement, } from "@/lib/api"; import Link from "next/link"; import { buttonVariants, LoaderButton } from "../custom/LoaderButton"; import { useMutation, useQuery, useSuspenseQuery } from "@tanstack/react-query"; import { DotsHorizontalIcon } from "@radix-ui/react-icons"; import { useRouter } from "next/navigation"; +import { Tooltip, TooltipContent, TooltipProvider } from "../ui/tooltip"; +import { TooltipTrigger } from "@radix-ui/react-tooltip"; export default function CommunityAttestations({ community, @@ -50,10 +54,8 @@ export default function CommunityAttestations({ const router = useRouter(); const [attestationOpen, setAttestationOpen] = useState(false); - const { - data: attestations, - refetch: refetchCommunityAttestations, - } = useQuery(attestationQueryOptions(community.id)); + const { data: attestations, refetch: refetchCommunityAttestations } = + useQuery(attestationQueryOptions(community.id)); const { data: allAttestations, refetch: refetchAttestations } = useSuspenseQuery(listAttestationsQuery); @@ -61,15 +63,15 @@ export default function CommunityAttestations({ const removeEntryMutation = useMutation({ mutationFn: removeEntryAttestation, }); + const toggleEntryMutation = useMutation({ + mutationFn: toggleEntryAttestationRequirement, + }); const toggleEntryAttestation = (id: number) => { if (!attestations) return; const isExisting = attestations.find( - (att) => - att.id === id && - att.isRequired && - att.entryAttestationId !== undefined + (att) => att.id === id && att.entryAttestationId !== undefined ) !== undefined; if (isExisting) { @@ -98,11 +100,29 @@ export default function CommunityAttestations({ } }; - const isPending = addEntryMutation.isPending || removeEntryMutation.isPending; - // const hasError = addEntryMutation.isError || removeEntryMutation.isError; - // const error = addEntryMutation.error || removeEntryMutation.error; + const toggleEntryRequirement = (id: number) => { + if (!attestations) return; + const entryAttestation = attestations.find( + (att) => att.attestationId === id && att.entryAttestationId !== undefined + ); + + if (entryAttestation?.entryAttestationId) { + toggleEntryMutation.mutate( + { + communityId: community.id, + entryId: entryAttestation.entryAttestationId, + }, + { + onSuccess() { + refetchAttestations(); + refetchCommunityAttestations(); + }, + } + ); + } + }; - // console.log("states", { isPending, hasError, error }); + const isPending = addEntryMutation.isPending || removeEntryMutation.isPending; return ( @@ -155,7 +175,7 @@ export default function CommunityAttestations({ )} {attestations?.some( - (a) => a.id === attestation.id && a.isRequired + (a) => a.attestationId === attestation.id ) && } ))} @@ -187,6 +207,21 @@ export default function CommunityAttestations({

{attestation.name}

{attestation.protected && } + {attestation.isRequired && ( + + + + + + +

+ This attestation is required strictly required to + join the community +

+
+
+
+ )}

By {attestation.communityName} @@ -215,16 +250,35 @@ export default function CommunityAttestations({ Edit Edit - {attestation.isRequired && ( + <> + + + toggleEntryAttestation(attestation.attestationId) + } + > + {attestation.entryAttestationId ? ( + + {attestation.communityName === community.name + ? "Remove from entry" + : "Delete"} + + ) : ( + Add to Entry + )} + + + {attestation.entryAttestationId && ( <> - toggleEntryAttestation(attestation.attestationId) + toggleEntryRequirement(attestation.attestationId) } > - Delete - ⌘⌫ + {attestation.isRequired + ? "Mark as Optional" + : "Mark as required"} )} diff --git a/src/components/molecules/CommunityMembers.tsx b/src/components/molecules/CommunityMembers.tsx index b21def6..78b7699 100644 --- a/src/components/molecules/CommunityMembers.tsx +++ b/src/components/molecules/CommunityMembers.tsx @@ -35,7 +35,7 @@ import { tags } from "@/lib/tags"; type User = { id: number; - name: string; + name?: string; organisations: string[]; }; @@ -153,7 +153,7 @@ export default function CommunityMembers({

- {getNameTag(user.name)} + {getNameTag(user.name ?? '')}

@@ -215,6 +215,6 @@ export default function CommunityMembers({ } const getNameTag = (name: string) => { - const split = name.split(" "); + const split = name?.split(" "); return (split[0]?.[0] ?? "") + (split?.[1]?.[0] ?? ""); }; diff --git a/src/components/organisms/forms/attestation-form.tsx b/src/components/organisms/forms/attestation-form.tsx index 8da763b..9e11e6a 100644 --- a/src/components/organisms/forms/attestation-form.tsx +++ b/src/components/organisms/forms/attestation-form.tsx @@ -27,6 +27,7 @@ import React, { } from "react"; import { getQueryClient } from "@/lib/get-query-client"; import { tags } from "@/lib/tags"; +import { useRouter } from "next/navigation"; const MAX_FILE_SIZE = 5 * 1024 * 1024; // 5MB const ACCEPTED_IMAGE_TYPES = [ @@ -85,6 +86,8 @@ export default function AttestationForm({ defaultValues?: FormValues; // pending: boolean; }) { + const router = useRouter(); + const form = useForm({ resolver: zodResolver(attestationSchema), defaultValues, @@ -124,14 +127,16 @@ export default function AttestationForm({ >; useEffect(() => { - console.log("attestationForm", formState); + console.log("attestationForm", formState.ok, form.formState.isLoading); if (formState?.ok) { getQueryClient().invalidateQueries({ queryKey: [tags.attestations], }); + getQueryClient().invalidateQueries({ queryKey: [{ type: tags.attestations, id: defaultValues?.communityId }], }); + router.back(); // todo: show success toast } - }, [defaultValues?.communityId, form, formState]); + }, [defaultValues?.communityId, form, formState, router]); const isProtected = form.watch("protected"); return ( diff --git a/src/components/organisms/forms/community-form.tsx b/src/components/organisms/forms/community-form.tsx index 9623c91..f160074 100644 --- a/src/components/organisms/forms/community-form.tsx +++ b/src/components/organisms/forms/community-form.tsx @@ -22,6 +22,7 @@ import { createCommunity } from "@/app/actions"; import { useEffect } from "react"; import { getQueryClient } from "@/lib/get-query-client"; import { tags } from "@/lib/tags"; +import { useRouter } from "next/navigation"; const MAX_FILE_SIZE = 5 * 1024 * 1024; // 5MB const ACCEPTED_IMAGE_TYPES = [ @@ -95,6 +96,7 @@ export default function CommunityForm({ control: form.control, name: "links", }); + const router = useRouter(); function onSubmit(data: FormValues) { const formData = new FormData(); @@ -137,8 +139,9 @@ export default function CommunityForm({ if (formState?.ok) { getQueryClient().invalidateQueries({ queryKey: [tags.communities] }); // todo: show success toast + router.back() } - }, [form, formState]); + }, [form, formState, router]); return ( diff --git a/src/lib/api/index.ts b/src/lib/api/index.ts index 56a5a2f..bda15ab 100644 --- a/src/lib/api/index.ts +++ b/src/lib/api/index.ts @@ -169,6 +169,22 @@ export const removeEntryAttestation = async ({ ); }; +export const toggleEntryAttestationRequirement = async ({ + communityId, + entryId, +}: { + communityId: number; + entryId: number; +}) => { + return fetch( + `${NODES_API_URL}/v1/admin/communities/${communityId}/toggleEntryAttestation/${entryId}`, + { + method: "POST", + credentials: "include", + } + ); +}; + export const addMember = async ({ communityId, userId, diff --git a/yarn.lock b/yarn.lock index 1ad974a..414d233 100644 --- a/yarn.lock +++ b/yarn.lock @@ -158,6 +158,46 @@ resolved "https://registry.npmjs.org/@next/swc-darwin-arm64/-/swc-darwin-arm64-14.2.7.tgz" integrity sha512-UhZGcOyI9LE/tZL3h9rs/2wMZaaJKwnpAyegUVDGZqwsla6hMfeSj9ssBWQS9yA4UXun3pPhrFLVnw5KXZs3vw== +"@next/swc-darwin-x64@14.2.7": + version "14.2.7" + resolved "https://registry.yarnpkg.com/@next/swc-darwin-x64/-/swc-darwin-x64-14.2.7.tgz#a1d191a293443cf8df9451b8f13a348caa718cb7" + integrity sha512-ys2cUgZYRc+CbyDeLAaAdZgS7N1Kpyy+wo0b/gAj+SeOeaj0Lw/q+G1hp+DuDiDAVyxLBCJXEY/AkhDmtihUTA== + +"@next/swc-linux-arm64-gnu@14.2.7": + version "14.2.7" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-gnu/-/swc-linux-arm64-gnu-14.2.7.tgz#9da3f993b3754b900fe7b469de51898fc51112f2" + integrity sha512-2xoWtE13sUJ3qrC1lwE/HjbDPm+kBQYFkkiVECJWctRASAHQ+NwjMzgrfqqMYHfMxFb5Wws3w9PqzZJqKFdWcQ== + +"@next/swc-linux-arm64-musl@14.2.7": + version "14.2.7" + resolved "https://registry.yarnpkg.com/@next/swc-linux-arm64-musl/-/swc-linux-arm64-musl-14.2.7.tgz#f75662bdedd2d91ad7e05778274fa17659f1f02f" + integrity sha512-+zJ1gJdl35BSAGpkCbfyiY6iRTaPrt3KTl4SF/B1NyELkqqnrNX6cp4IjjjxKpd64/7enI0kf6b9O1Uf3cL0pw== + +"@next/swc-linux-x64-gnu@14.2.7": + version "14.2.7" + resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-gnu/-/swc-linux-x64-gnu-14.2.7.tgz#3c6c5b551a5af4fc8178bd5733c8063266034e79" + integrity sha512-m6EBqrskeMUzykBrv0fDX/28lWIBGhMzOYaStp0ihkjzIYJiKUOzVYD1gULHc8XDf5EMSqoH/0/TRAgXqpQwmw== + +"@next/swc-linux-x64-musl@14.2.7": + version "14.2.7" + resolved "https://registry.yarnpkg.com/@next/swc-linux-x64-musl/-/swc-linux-x64-musl-14.2.7.tgz#16f92f00263d1fce91ae80e5f230eb1feea484e4" + integrity sha512-gUu0viOMvMlzFRz1r1eQ7Ql4OE+hPOmA7smfZAhn8vC4+0swMZaZxa9CSIozTYavi+bJNDZ3tgiSdMjmMzRJlQ== + +"@next/swc-win32-arm64-msvc@14.2.7": + version "14.2.7" + resolved "https://registry.yarnpkg.com/@next/swc-win32-arm64-msvc/-/swc-win32-arm64-msvc-14.2.7.tgz#1224cb8a04cd9caad785a2187df9e85b49414a42" + integrity sha512-PGbONHIVIuzWlYmLvuFKcj+8jXnLbx4WrlESYlVnEzDsa3+Q2hI1YHoXaSmbq0k4ZwZ7J6sWNV4UZfx1OeOlbQ== + +"@next/swc-win32-ia32-msvc@14.2.7": + version "14.2.7" + resolved "https://registry.yarnpkg.com/@next/swc-win32-ia32-msvc/-/swc-win32-ia32-msvc-14.2.7.tgz#9494aaf9cc50ddef600f8c1b2ed0f216b19f9294" + integrity sha512-BiSY5umlx9ed5RQDoHcdbuKTUkuFORDqzYKPHlLeS+STUWQKWziVOn3Ic41LuTBvqE0TRJPKpio9GSIblNR+0w== + +"@next/swc-win32-x64-msvc@14.2.7": + version "14.2.7" + resolved "https://registry.yarnpkg.com/@next/swc-win32-x64-msvc/-/swc-win32-x64-msvc-14.2.7.tgz#75e1d90758cb10a547e1cdfb878871da28123682" + integrity sha512-pxsI23gKWRt/SPHFkDEsP+w+Nd7gK37Hpv0ngc5HpWy2e7cKx9zR/+Q2ptAUqICNTecAaGWvmhway7pj/JLEWA== + "@nodelib/fs.scandir@2.1.5": version "2.1.5" resolved "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz" @@ -166,7 +206,7 @@ "@nodelib/fs.stat" "2.0.5" run-parallel "^1.1.9" -"@nodelib/fs.stat@^2.0.2", "@nodelib/fs.stat@2.0.5": +"@nodelib/fs.stat@2.0.5", "@nodelib/fs.stat@^2.0.2": version "2.0.5" resolved "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz" integrity sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A== @@ -295,26 +335,6 @@ resolved "https://registry.npmjs.org/@radix-ui/react-context/-/react-context-1.1.1.tgz" integrity sha512-UASk9zi+crv9WteK/NU4PLvOoL3OuE6BWVKNF6hPRBtYBDXQ2u5iu3O59zUlJiTVvkyuycnqrztsHVJwcK9K+Q== -"@radix-ui/react-dialog@^1.1.2": - version "1.1.2" - resolved "https://registry.npmjs.org/@radix-ui/react-dialog/-/react-dialog-1.1.2.tgz" - integrity sha512-Yj4dZtqa2o+kG61fzB0H2qUvmwBA2oyQroGLyNtBj1beo1khoQ3q1a2AO8rrQYjd8256CO9+N8L9tvsS+bnIyA== - dependencies: - "@radix-ui/primitive" "1.1.0" - "@radix-ui/react-compose-refs" "1.1.0" - "@radix-ui/react-context" "1.1.1" - "@radix-ui/react-dismissable-layer" "1.1.1" - "@radix-ui/react-focus-guards" "1.1.1" - "@radix-ui/react-focus-scope" "1.1.0" - "@radix-ui/react-id" "1.1.0" - "@radix-ui/react-portal" "1.1.2" - "@radix-ui/react-presence" "1.1.1" - "@radix-ui/react-primitive" "2.0.0" - "@radix-ui/react-slot" "1.1.0" - "@radix-ui/react-use-controllable-state" "1.1.0" - aria-hidden "^1.1.1" - react-remove-scroll "2.6.0" - "@radix-ui/react-dialog@1.0.5": version "1.0.5" resolved "https://registry.npmjs.org/@radix-ui/react-dialog/-/react-dialog-1.0.5.tgz" @@ -336,6 +356,26 @@ aria-hidden "^1.1.1" react-remove-scroll "2.5.5" +"@radix-ui/react-dialog@^1.1.2": + version "1.1.2" + resolved "https://registry.npmjs.org/@radix-ui/react-dialog/-/react-dialog-1.1.2.tgz" + integrity sha512-Yj4dZtqa2o+kG61fzB0H2qUvmwBA2oyQroGLyNtBj1beo1khoQ3q1a2AO8rrQYjd8256CO9+N8L9tvsS+bnIyA== + dependencies: + "@radix-ui/primitive" "1.1.0" + "@radix-ui/react-compose-refs" "1.1.0" + "@radix-ui/react-context" "1.1.1" + "@radix-ui/react-dismissable-layer" "1.1.1" + "@radix-ui/react-focus-guards" "1.1.1" + "@radix-ui/react-focus-scope" "1.1.0" + "@radix-ui/react-id" "1.1.0" + "@radix-ui/react-portal" "1.1.2" + "@radix-ui/react-presence" "1.1.1" + "@radix-ui/react-primitive" "2.0.0" + "@radix-ui/react-slot" "1.1.0" + "@radix-ui/react-use-controllable-state" "1.1.0" + aria-hidden "^1.1.1" + react-remove-scroll "2.6.0" + "@radix-ui/react-direction@1.1.0": version "1.1.0" resolved "https://registry.npmjs.org/@radix-ui/react-direction/-/react-direction-1.1.0.tgz" @@ -632,13 +672,6 @@ dependencies: "@radix-ui/react-primitive" "2.0.0" -"@radix-ui/react-slot@^1.1.0", "@radix-ui/react-slot@1.1.0": - version "1.1.0" - resolved "https://registry.npmjs.org/@radix-ui/react-slot/-/react-slot-1.1.0.tgz" - integrity sha512-FUCf5XMfmW4dtYl69pdS4DbxKy8nj4M7SafBgPllysxmdachynNflAdp/gCsnYWNDnge6tI9onzMp5ARYc1KNw== - dependencies: - "@radix-ui/react-compose-refs" "1.1.0" - "@radix-ui/react-slot@1.0.2": version "1.0.2" resolved "https://registry.npmjs.org/@radix-ui/react-slot/-/react-slot-1.0.2.tgz" @@ -647,6 +680,13 @@ "@babel/runtime" "^7.13.10" "@radix-ui/react-compose-refs" "1.0.1" +"@radix-ui/react-slot@1.1.0", "@radix-ui/react-slot@^1.1.0": + version "1.1.0" + resolved "https://registry.npmjs.org/@radix-ui/react-slot/-/react-slot-1.1.0.tgz" + integrity sha512-FUCf5XMfmW4dtYl69pdS4DbxKy8nj4M7SafBgPllysxmdachynNflAdp/gCsnYWNDnge6tI9onzMp5ARYc1KNw== + dependencies: + "@radix-ui/react-compose-refs" "1.1.0" + "@radix-ui/react-switch@^1.1.0": version "1.1.0" resolved "https://registry.npmjs.org/@radix-ui/react-switch/-/react-switch-1.1.0.tgz" @@ -942,14 +982,14 @@ resolved "https://registry.npmjs.org/@types/prop-types/-/prop-types-15.7.12.tgz" integrity sha512-5zvhXYtRNRluoE/jAp4GVsSduVUzNWKkOZrCDBWYtE7biZywwdC2AcEzg+cSMLFRfVgeAFqpfNabiPjxFddV1Q== -"@types/react-dom@*", "@types/react-dom@^18": +"@types/react-dom@^18": version "18.3.0" resolved "https://registry.npmjs.org/@types/react-dom/-/react-dom-18.3.0.tgz" integrity sha512-EhwApuTmMBmXuFOikhQLIBUn6uFg81SwLMOAUgodJF14SOBOCMdU04gDoYi0WOJJHD144TL32z4yDqCW3dnkQg== dependencies: "@types/react" "*" -"@types/react@*", "@types/react@^16.8.0 || ^17.0.0 || ^18.0.0", "@types/react@^16.9.0 || ^17.0.0 || ^18.0.0", "@types/react@^18", "@types/react@>=18": +"@types/react@*", "@types/react@^18": version "18.3.5" resolved "https://registry.npmjs.org/@types/react/-/react-18.3.5.tgz" integrity sha512-WeqMfGJLGuLCqHGYRGHxnKrXcTitc6L/nBUWfWPcTarG3t9PsquqUMuVeXZeca+mglY4Vo5GZjCi0A3Or2lnxA== @@ -1023,7 +1063,7 @@ acorn-jsx@^5.3.2: resolved "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz" integrity sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ== -"acorn@^6.0.0 || ^7.0.0 || ^8.0.0", acorn@^8.9.0: +acorn@^8.9.0: version "8.12.1" resolved "https://registry.npmjs.org/acorn/-/acorn-8.12.1.tgz" integrity sha512-tcpGyI9zbizT9JbV6oYE477V6mTlXvvi0T0G3SNIYE2apm/G5huBa1+K89VGeovbg+jycCrfhl3ADxErOuO6Jg== @@ -1278,7 +1318,7 @@ braces@^3.0.3, braces@~3.0.2: dependencies: fill-range "^7.1.1" -browserslist@^4.23.3, "browserslist@>= 4.21.0": +browserslist@^4.23.3: version "4.23.3" resolved "https://registry.npmjs.org/browserslist/-/browserslist-4.23.3.tgz" integrity sha512-btwCFJVjI4YWDNfau8RhZ+B1Q/VLoUITrm3RlP6y1tYGWIOa+InuYiRGXUBXo8nA1qKmHMyLB/iVQg5TT4eFoA== @@ -1354,7 +1394,7 @@ character-reference-invalid@^2.0.0: resolved "https://registry.npmjs.org/character-reference-invalid/-/character-reference-invalid-2.0.1.tgz" integrity sha512-iBZ4F4wRbyORVsu0jPV7gXkOsGYjGHPmAyv+HiHG8gi5PtC9KI2j1+v8/tlibRvjoWX027ypmG/n0HtO5t7unw== -chokidar@^3.5.3, "chokidar@>=3.0.0 <4.0.0": +"chokidar@>=3.0.0 <4.0.0", chokidar@^3.5.3: version "3.6.0" resolved "https://registry.npmjs.org/chokidar/-/chokidar-3.6.0.tgz" integrity sha512-7VT13fmjotKpGipCW9JEQAusEPE+Ei8nl6/g4FBAmIm0GOOLMua9NDDo/DWp0ZAxCr3cPq5ZpBqmPAQgDda2Pw== @@ -1381,16 +1421,16 @@ client-only@0.0.1: resolved "https://registry.npmjs.org/client-only/-/client-only-0.0.1.tgz" integrity sha512-IV3Ou0jSMzZrd3pZ48nLkT9DA7Ag1pnPzaiQhpW7c3RbcqqzvzzVu+L8gfqMp/8IM2MQtSiqaCxrrcfu8I8rMA== -clsx@^2.0.0, clsx@^2.1.1: - version "2.1.1" - resolved "https://registry.npmjs.org/clsx/-/clsx-2.1.1.tgz" - integrity sha512-eYm0QWBtUrBWZWG0d386OGAw16Z995PiOVo2B7bjWSbHedGl5e0ZWaq65kOGgUSNesEIDkB9ISbTg/JK9dhCZA== - clsx@2.0.0: version "2.0.0" resolved "https://registry.npmjs.org/clsx/-/clsx-2.0.0.tgz" integrity sha512-rQ1+kcj+ttHG0MKVGBUXwayCCF1oh39BF5COIpRzuCEv8Mwjv0XucrI2ExNTOn9IlLifGClWQcU9BrZORvtw6Q== +clsx@^2.0.0, clsx@^2.1.1: + version "2.1.1" + resolved "https://registry.npmjs.org/clsx/-/clsx-2.1.1.tgz" + integrity sha512-eYm0QWBtUrBWZWG0d386OGAw16Z995PiOVo2B7bjWSbHedGl5e0ZWaq65kOGgUSNesEIDkB9ISbTg/JK9dhCZA== + cmdk@^1.0.0: version "1.0.0" resolved "https://registry.npmjs.org/cmdk/-/cmdk-1.0.0.tgz" @@ -1452,7 +1492,7 @@ csstype@^3.0.2: resolved "https://registry.npmjs.org/csstype/-/csstype-3.1.3.tgz" integrity sha512-M1uQkMl8rQK/szD0LNhtqxIPLpimGm8sOBwU7lLnCpSbTyY3yeU1Vc7l4KT5zT4s/yOxHH5O7tIuuLOCnLADRw== -d3-array@^3.1.6, "d3-array@2 - 3", "d3-array@2.10.0 - 3": +"d3-array@2 - 3", "d3-array@2.10.0 - 3", d3-array@^3.1.6: version "3.2.4" resolved "https://registry.npmjs.org/d3-array/-/d3-array-3.2.4.tgz" integrity sha512-tdQAmyA18i4J7wprpYq8ClcxZy3SC31QMeByyCFyRt7BVHdREQZ5lpzoe5mFEYZUWe+oq8HBvk9JjpibyEV4Jg== @@ -1474,7 +1514,7 @@ d3-ease@^3.0.1: resolved "https://registry.npmjs.org/d3-format/-/d3-format-3.1.0.tgz" integrity sha512-YyUI6AEuY/Wpt8KWLgZHsIU86atmikuoOmCfommt0LYHiQSPjvX2AcFc38PX0CBpr2RCyZhjex+NS/LPOv6YqA== -d3-interpolate@^3.0.1, "d3-interpolate@1.2.0 - 3": +"d3-interpolate@1.2.0 - 3", d3-interpolate@^3.0.1: version "3.0.1" resolved "https://registry.npmjs.org/d3-interpolate/-/d3-interpolate-3.0.1.tgz" integrity sha512-3bYs1rOD33uo8aqJfKP3JWPAibgw8Zm2+L9vBKEHJ2Rg+viTR7o5Mmv5mZcieN+FRYaAOWX5SJATX6k1PWz72g== @@ -1511,7 +1551,7 @@ d3-shape@^3.1.0: dependencies: d3-time "1 - 3" -d3-time@^3.0.0, "d3-time@1 - 3", "d3-time@2.1.1 - 3": +"d3-time@1 - 3", "d3-time@2.1.1 - 3", d3-time@^3.0.0: version "3.1.0" resolved "https://registry.npmjs.org/d3-time/-/d3-time-3.1.0.tgz" integrity sha512-VqKjzBLejbSMT4IgbmVgDjpkYrNWUYJnbCGo874u7MMKIWsILRX+OpX/gTk8MqjpT1A/c6HY2dCA77ZN0lkQ2Q== @@ -1903,7 +1943,7 @@ eslint-module-utils@^2.8.1, eslint-module-utils@^2.9.0: dependencies: debug "^3.2.7" -eslint-plugin-import@*, eslint-plugin-import@^2.28.1: +eslint-plugin-import@^2.28.1: version "2.30.0" resolved "https://registry.npmjs.org/eslint-plugin-import/-/eslint-plugin-import-2.30.0.tgz" integrity sha512-/mHNE9jINJfiD2EKkg1BKyPyUk4zdnT54YgbOgfjSakWT5oyX/qQLVNTkehyfpcMxZXMy1zyonZ2v7hZTX43Yw== @@ -1996,7 +2036,7 @@ eslint-visitor-keys@^3.3.0, eslint-visitor-keys@^3.4.1, eslint-visitor-keys@^3.4 resolved "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz" integrity sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag== -eslint@*, "eslint@^2 || ^3 || ^4 || ^5 || ^6 || ^7.2.0 || ^8", "eslint@^3 || ^4 || ^5 || ^6 || ^7 || ^8", "eslint@^3 || ^4 || ^5 || ^6 || ^7 || ^8 || ^9.7", "eslint@^3.0.0 || ^4.0.0 || ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0-0", "eslint@^6.0.0 || ^7.0.0 || >=8.0.0", "eslint@^7.23.0 || ^8.0.0", eslint@^8, eslint@^8.56.0, eslint@>=7: +eslint@^8: version "8.57.0" resolved "https://registry.npmjs.org/eslint/-/eslint-8.57.0.tgz" integrity sha512-dZ6+mexnaTIbSBZWgou51U6OmzIhYM2VcNdtiTtI7qPNZm35Akpr0f6vtw3w1Kmn5PYo+tZVfh13WrhpS6oLqQ== @@ -2258,7 +2298,7 @@ get-tsconfig@^4.7.5: dependencies: resolve-pkg-maps "^1.0.0" -glob-parent@^5.1.2: +glob-parent@^5.1.2, glob-parent@~5.1.2: version "5.1.2" resolved "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz" integrity sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow== @@ -2272,14 +2312,7 @@ glob-parent@^6.0.2: dependencies: is-glob "^4.0.3" -glob-parent@~5.1.2: - version "5.1.2" - resolved "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz" - integrity sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow== - dependencies: - is-glob "^4.0.1" - -glob@^10.3.10, glob@10.3.10: +glob@10.3.10, glob@^10.3.10: version "10.3.10" resolved "https://registry.npmjs.org/glob/-/glob-10.3.10.tgz" integrity sha512-fa46+tv1Ak0UPK1TOy/pZrIybNNt4HCv7SDzwyfiOZkvZLEbjsZkJBPtDHVshZjbecAoAGSC20MjLDG/qr679g== @@ -3190,6 +3223,13 @@ mime-types@^2.1.12: dependencies: mime-db "1.52.0" +minimatch@9.0.3: + version "9.0.3" + resolved "https://registry.npmjs.org/minimatch/-/minimatch-9.0.3.tgz" + integrity sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg== + dependencies: + brace-expansion "^2.0.1" + minimatch@^3.0.5, minimatch@^3.1.1, minimatch@^3.1.2: version "3.1.2" resolved "https://registry.npmjs.org/minimatch/-/minimatch-3.1.2.tgz" @@ -3204,13 +3244,6 @@ minimatch@^9.0.1: dependencies: brace-expansion "^2.0.1" -minimatch@9.0.3: - version "9.0.3" - resolved "https://registry.npmjs.org/minimatch/-/minimatch-9.0.3.tgz" - integrity sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg== - dependencies: - brace-expansion "^2.0.1" - minimist@^1.2.0, minimist@^1.2.6: version "1.2.8" resolved "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz" @@ -3221,7 +3254,7 @@ minimist@^1.2.0, minimist@^1.2.6: resolved "https://registry.npmjs.org/minipass/-/minipass-7.1.2.tgz" integrity sha512-qOOzS1cBTWYF4BH8fVePDBOO9iptMnGUEZwNc/cMWnTV2nVLZ7VoNWEPHkYczZA0pdoA7dl6e7FL659nX9S2aw== -ms@^2.1.1, ms@2.1.2: +ms@2.1.2, ms@^2.1.1: version "2.1.2" resolved "https://registry.npmjs.org/ms/-/ms-2.1.2.tgz" integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== @@ -3519,15 +3552,6 @@ postcss-value-parser@^4.0.0, postcss-value-parser@^4.2.0: resolved "https://registry.npmjs.org/postcss-value-parser/-/postcss-value-parser-4.2.0.tgz" integrity sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ== -postcss@^8, postcss@^8.0.0, postcss@^8.1.0, postcss@^8.2.14, postcss@^8.4.21, postcss@^8.4.23, postcss@>=8.0.9: - version "8.4.44" - resolved "https://registry.npmjs.org/postcss/-/postcss-8.4.44.tgz" - integrity sha512-Aweb9unOEpQ3ezu4Q00DPvvM2ZTUitJdNKeP/+uQgr1IBIqu574IaZoURId7BKtWMREwzKa9OgzPzezWGPWFQw== - dependencies: - nanoid "^3.3.7" - picocolors "^1.0.1" - source-map-js "^1.2.0" - postcss@8.4.31: version "8.4.31" resolved "https://registry.npmjs.org/postcss/-/postcss-8.4.31.tgz" @@ -3537,6 +3561,15 @@ postcss@8.4.31: picocolors "^1.0.0" source-map-js "^1.0.2" +postcss@^8, postcss@^8.4.23: + version "8.4.44" + resolved "https://registry.npmjs.org/postcss/-/postcss-8.4.44.tgz" + integrity sha512-Aweb9unOEpQ3ezu4Q00DPvvM2ZTUitJdNKeP/+uQgr1IBIqu574IaZoURId7BKtWMREwzKa9OgzPzezWGPWFQw== + dependencies: + nanoid "^3.3.7" + picocolors "^1.0.1" + source-map-js "^1.2.0" + prelude-ls@^1.2.1: version "1.2.1" resolved "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz" @@ -3571,7 +3604,7 @@ queue-microtask@^1.2.2: resolved "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz" integrity sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A== -"react-dom@^16.0.0 || ^17.0.0 || ^18.0.0", "react-dom@^16.14.0 || ^17.0.0 || ^18.0.0", "react-dom@^16.8 || ^17 || ^18", "react-dom@^16.8 || ^17.0 || ^18.0", "react-dom@^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react-dom@^16.8.0 || ^17.0.0 || ^18.0.0", react-dom@^18, react-dom@^18.0.0, react-dom@^18.2.0, react-dom@>=16.6.0, react-dom@>=16.8, react-dom@>=16.8.0: +react-dom@^18: version "18.3.1" resolved "https://registry.npmjs.org/react-dom/-/react-dom-18.3.1.tgz" integrity sha512-5m4nQKp+rZRb09LNH59GM4BxTh9251/ylbKIbpe7TpGxfJ+9kv6BLkLBXIjjspbgbnIBNqlI23tRnTWT0snUIw== @@ -3579,11 +3612,16 @@ queue-microtask@^1.2.2: loose-envify "^1.1.0" scheduler "^0.23.2" -react-hook-form@^7.0.0, react-hook-form@^7.53.0: +react-hook-form@^7.53.0: version "7.53.0" resolved "https://registry.npmjs.org/react-hook-form/-/react-hook-form-7.53.0.tgz" integrity sha512-M1n3HhqCww6S2hxLxciEXy2oISPnAzxY7gvwVPrtlczTM/1dDadXgUxDpHMrMTblDOcm/AXtXxHwZ3jpg1mqKQ== +react-icons@^5.3.0: + version "5.3.0" + resolved "https://registry.yarnpkg.com/react-icons/-/react-icons-5.3.0.tgz#ccad07a30aebd40a89f8cfa7d82e466019203f1c" + integrity sha512-DnUk8aFbTyQPSkCfF8dbX6kQjXA9DktMeJqfjrg6cK9vwQVMxmcA3BfP4QoiztVmEHtwlTgLFsPuH2NskKT6eg== + react-is@^16.10.2, react-is@^16.13.1: version "16.13.1" resolved "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz" @@ -3679,7 +3717,7 @@ react-transition-group@^4.4.5: loose-envify "^1.4.0" prop-types "^15.6.2" -"react@^16.0.0 || ^17.0.0 || ^18.0.0", "react@^16.14.0 || ^17.0.0 || ^18.0.0", "react@^16.5.1 || ^17.0.0 || ^18.0.0 || ^19.0.0-rc", "react@^16.8 || ^17 || ^18", "react@^16.8 || ^17.0 || ^18.0", "react@^16.8 || ^17.0 || ^18.0 || ^19.0 || ^19.0.0-rc", "react@^16.8.0 || ^17 || ^18 || ^19", "react@^16.8.0 || ^17.0.0 || ^18.0.0", "react@^16.x || ^17.x || ^18.x", react@^18, "react@^18 || ^19", react@^18.0.0, react@^18.2.0, react@^18.3.1, "react@>= 16", "react@>= 16.8.0 || 17.x.x || ^18.0.0-0", react@>=16.6.0, react@>=16.8, react@>=16.8.0, react@>=18: +react@^18: version "18.3.1" resolved "https://registry.npmjs.org/react/-/react-18.3.1.tgz" integrity sha512-wS+hAgJShR0KhEvPJArfuPVN1+Hz1t0Y6n5jLrGQbkb4urgPE/0Rve+1kMB1v/oWgHgm4WIcV+i7F2pTVj+2iQ== @@ -3836,7 +3874,7 @@ safe-regex-test@^1.0.3: es-errors "^1.3.0" is-regex "^1.1.4" -sass@^1.3.0, sass@^1.78.0: +sass@^1.78.0: version "1.78.0" resolved "https://registry.npmjs.org/sass/-/sass-1.78.0.tgz" integrity sha512-AaIqGSrjo5lA2Yg7RvFZrlXDBCp3nV4XP73GrLGvdRWWwk+8H3l0SDvq/5bA4eF+0RFPLuWUk3E+P1U/YqnpsQ== @@ -3916,7 +3954,7 @@ slash@^3.0.0: resolved "https://registry.npmjs.org/slash/-/slash-3.0.0.tgz" integrity sha512-g9Q1haeby36OSStwb4ntCGGGaKsaVSjQ68fBxoQcutl5fS1vuY18H3wSt3jFyFtrkx+Kz0V1G85A4MyAdDMi2Q== -source-map-js@^1.0.2, source-map-js@^1.2.0, "source-map-js@>=0.6.2 <2.0.0": +"source-map-js@>=0.6.2 <2.0.0", source-map-js@^1.0.2, source-map-js@^1.2.0: version "1.2.0" resolved "https://registry.npmjs.org/source-map-js/-/source-map-js-1.2.0.tgz" integrity sha512-itJW8lvSA0TXEphiRoawsCksnlf8SyvmFzIhltqAHluXd88pkCd+cXJVHTDwdCr0IzwptSm035IHQktUu1QUMg== @@ -4120,7 +4158,7 @@ tailwindcss-radix@^3.0.4: resolved "https://registry.npmjs.org/tailwindcss-radix/-/tailwindcss-radix-3.0.4.tgz" integrity sha512-nnMdBWHGBon4OxfRsF0LfOaoW09WeSU5extMUpk8RckYl94nwu9uyJ6IO5eIrRpvrHNm5CVaWz6PaldcEoQ4SQ== -tailwindcss@^3.4.1, "tailwindcss@>=3.0.0 || insiders": +tailwindcss@^3.4.1: version "3.4.10" resolved "https://registry.npmjs.org/tailwindcss/-/tailwindcss-3.4.10.tgz" integrity sha512-KWZkVPm7yJRhdu4SRSl9d4AK2wM3a50UsvgHZO7xY77NQr2V+fIrEuoDGQcbvswWvFGbS2f6e+jC/6WJm1Dl0w== @@ -4275,7 +4313,7 @@ typed-array-length@^1.0.6: is-typed-array "^1.1.13" possible-typed-array-names "^1.0.0" -typescript@^5, typescript@>=3.3.1, typescript@>=4.2.0: +typescript@^5: version "5.5.4" resolved "https://registry.npmjs.org/typescript/-/typescript-5.5.4.tgz" integrity sha512-Mtq29sKDAEYP7aljRgtPOpTvOfbwRWlS6dPRzwjdE+C0R4brX/GUyhHSecbHMFLNBLcJIPt9nl9yG5TZ1weH+Q==