diff --git a/.vscode/settings.json b/.vscode/settings.json index cf44815f4..a0dc78ce6 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -78,6 +78,7 @@ "oaknational", "oaknationalacademy", "oclif", + "Onboarded", "openai", "openapi", "paragraphise", diff --git a/apps/nextjs/src/app/aila/[id]/download/index.tsx b/apps/nextjs/src/app/aila/[id]/download/index.tsx index 621d31aee..49347ebfe 100644 --- a/apps/nextjs/src/app/aila/[id]/download/index.tsx +++ b/apps/nextjs/src/app/aila/[id]/download/index.tsx @@ -77,7 +77,7 @@ export function DownloadPageContents({ chat }: Readonly) { const { survey } = usePosthogFeedbackSurvey({ closeDialog: () => null, - surveyName: "Chat Feedback With Stats", + surveyName: "End of Aila generation survey launch aug24", }); useEffect(() => { diff --git a/apps/nextjs/src/components/DialogControl/ContentOptions/ChatActions.tsx b/apps/nextjs/src/components/DialogControl/ContentOptions/EndOfLessonFeedback.tsx similarity index 78% rename from apps/nextjs/src/components/DialogControl/ContentOptions/ChatActions.tsx rename to apps/nextjs/src/components/DialogControl/ContentOptions/EndOfLessonFeedback.tsx index 0db21eff3..37e0c49fc 100644 --- a/apps/nextjs/src/components/DialogControl/ContentOptions/ChatActions.tsx +++ b/apps/nextjs/src/components/DialogControl/ContentOptions/EndOfLessonFeedback.tsx @@ -3,11 +3,11 @@ import { usePosthogFeedbackSurvey } from "hooks/surveys/usePosthogFeedbackSurvey import FeedBack from "@/components/Feedback"; -const ChatActions = ({ closeDialog }: { closeDialog: () => void }) => { +const EndOfLessonFeedback = ({ closeDialog }: { closeDialog: () => void }) => { const { survey, submitSurvey, closeDialogWithPostHogDismiss } = usePosthogFeedbackSurvey({ closeDialog, - surveyName: "Chat Feedback With Stats", + surveyName: "End of Aila generation survey launch aug24", }); return ( @@ -26,4 +26,4 @@ const ChatActions = ({ closeDialog }: { closeDialog: () => void }) => { ); }; -export default ChatActions; +export default EndOfLessonFeedback; diff --git a/apps/nextjs/src/components/DialogControl/DialogContents.tsx b/apps/nextjs/src/components/DialogControl/DialogContents.tsx index 2e4174ad3..8f148b249 100644 --- a/apps/nextjs/src/components/DialogControl/DialogContents.tsx +++ b/apps/nextjs/src/components/DialogControl/DialogContents.tsx @@ -5,9 +5,9 @@ import { Message } from "ai"; import { useDialog } from "../AppComponents/DialogContext"; import { Icon } from "../Icon"; -import ChatActions from "./ContentOptions/ChatActions"; import DemoInterstitialDialog from "./ContentOptions/DemoInterstitialDialog"; import DemoShareLockedDialog from "./ContentOptions/DemoShareLockedDialog"; +import EndOfLessonFeedback from "./ContentOptions/EndOfLessonFeedback"; import ReportContentDialog from "./ContentOptions/ReportContentDialog"; import ShareChatDialog from "./ContentOptions/ShareChatDialog"; import { @@ -61,7 +61,7 @@ const DialogContents = ({ )} {dialogWindow === "feedback" && ( - + )} {dialogWindow === "report-content" && ( void; + submitSurvey: (usersResponse: { [key: string]: string }) => void; closeDialogWithPostHogDismiss: () => void; onSubmit: () => void; }) => { - const numbersOfHoursSaved = [0, 1, 2, 3, 4, 5, 6]; - const [usersResponse, setUsersResponse] = useState({ - $survey_response: "", - $survey_response_1: "", - $survey_response_2: "", - }); + const rating = [ + { text: "Poor", number: 1 }, + { text: "Needs Improvement", number: 2 }, + { text: "Satisfactory", number: 3 }, + { text: "Good", number: 4 }, + { text: "Excellent", number: 5 }, + ]; + const [usersResponse, setUsersResponse] = useState<{ [key: string]: string }>( + {}, + ); + console.log("usersResponse", usersResponse); if (!survey?.id) return null; + return ( -

Before you continue...

+

Before you continue...

{ @@ -44,32 +46,7 @@ const FeedBack = ({ }} className="flex w-full flex-col gap-14" > - {survey?.questions.map((question) => { - if (question.type === "open") { - return ( -
- -