From 64e2222e3b1604739012a75e999c5ad0f5e70ac6 Mon Sep 17 00:00:00 2001 From: Jim Hodapp Date: Mon, 17 Jun 2024 10:08:15 -0500 Subject: [PATCH] Update the wording to be about selecting a coaching session, and disable select boxes until selected in proper order --- .../ui/dashboard/select-coaching-session.tsx | 61 ++++++++++++++++--- 1 file changed, 52 insertions(+), 9 deletions(-) diff --git a/src/components/ui/dashboard/select-coaching-session.tsx b/src/components/ui/dashboard/select-coaching-session.tsx index 57d7dc5..21d527e 100644 --- a/src/components/ui/dashboard/select-coaching-session.tsx +++ b/src/components/ui/dashboard/select-coaching-session.tsx @@ -9,7 +9,6 @@ import { CardHeader, CardTitle, } from "@/components/ui/card"; -import { Input } from "@/components/ui/input"; import { Label } from "@/components/ui/label"; import { Select, @@ -18,7 +17,6 @@ import { SelectTrigger, SelectValue, } from "@/components/ui/select"; -import { Textarea } from "@/components/ui/textarea"; import { fetchOrganizationsByUserId } from "@/lib/api/organizations"; import { Organization, defaultOrganizations } from "@/types/organization"; import { useEffect, useState } from "react"; @@ -32,6 +30,31 @@ export function SelectCoachingSession({ userUUID, ...props }: CoachingSessionProps) { + const [organizationSelection, setOrganizationSelection] = + useState(""); + const [relationshipSelection, setRelationshipSelection] = + useState(""); + const [coachSessionSelection, setCoachingSessionSelection] = + useState(""); + + const handleOrganizationSelectionChange = ( + event: React.ChangeEvent + ) => { + setOrganizationSelection(event.target.value); + }; + + const handleRelationshipSelectionChange = ( + event: React.ChangeEvent + ) => { + setRelationshipSelection(event.target.value); + }; + + const handleCoachingSessionChange = ( + event: React.ChangeEvent + ) => { + setCoachingSessionSelection(event.target.value); + }; + const [organizations, setOrganizations] = useState( defaultOrganizations() ); @@ -53,13 +76,19 @@ export function SelectCoachingSession({ return ( - Organization Relationship - Select current organization & coachee + Join a Coaching Session + + Select current organization, relationship and session +
- @@ -74,7 +103,12 @@ export function SelectCoachingSession({
- @@ -90,7 +124,12 @@ export function SelectCoachingSession({
- @@ -102,8 +141,12 @@ export function SelectCoachingSession({
-