diff --git a/app/onboarding/page.tsx b/app/onboarding/page.tsx
index 84626542..24907479 100644
--- a/app/onboarding/page.tsx
+++ b/app/onboarding/page.tsx
@@ -1,7 +1,7 @@
"use client";
import {Suspense} from "react";
-import MultiStepForm from "@/components/MultiStepForm";
+import OnboardingForm from "@/components/onboarding";
export default function RegisterPage() {
@@ -17,7 +17,7 @@ function RegisterComponent() {
return (
-
+
);
}
diff --git a/components/MultiStepForm.tsx b/components/onboarding.tsx
similarity index 90%
rename from components/MultiStepForm.tsx
rename to components/onboarding.tsx
index 4451dbef..76a59897 100644
--- a/components/MultiStepForm.tsx
+++ b/components/onboarding.tsx
@@ -42,37 +42,37 @@ const questions: Question[] = [
name: "gender",
label: "What's your gender?",
type: "select",
- options: ["Man", "Woman", "See all"],
- },
- {
- name: "genderOther",
- label: "How do you identify?",
- type: "select",
- options: [
- "Agender",
- "Androgynous",
- "Bigender",
- "Cis Man",
- "Cis Woman",
- "Genderfluid",
- "Genderqueer",
- "Gender Nonconforming",
- "Hijra",
- "Intersex",
- "Non-binary",
- "Other gender",
- "Pangender",
- "Transfeminine",
- "Transgender",
- "Trans Man",
- "Transmasculine",
- "Transsexual",
- "Trans Woman",
- "Two Spirit"
- ],
- optional: true,
- condition: (values) => values.gender === "See all",
+ options: ["Man", "Woman", "Other"],
},
+ // {
+ // name: "genderOther",
+ // label: "How do you identify?",
+ // type: "select",
+ // options: [
+ // "Agender",
+ // "Androgynous",
+ // "Bigender",
+ // "Cis Man",
+ // "Cis Woman",
+ // "Genderfluid",
+ // "Genderqueer",
+ // "Gender Nonconforming",
+ // "Hijra",
+ // "Intersex",
+ // "Non-binary",
+ // "Other gender",
+ // "Pangender",
+ // "Transfeminine",
+ // "Transgender",
+ // "Trans Man",
+ // "Transmasculine",
+ // "Transsexual",
+ // "Trans Woman",
+ // "Two Spirit"
+ // ],
+ // optional: true,
+ // condition: (values) => values.gender === "See all",
+ // },
{
name: "birthday",
label: "When's your birthday?",
@@ -83,43 +83,43 @@ const questions: Question[] = [
label: "What kind of relationship are you looking for?",
type: "multiselect",
options: [
- "Debate Partner",
+ // "Debate Partner",
"Friendship",
- // "Short-term relationship",
- "Relationship",
- "Other",
+ "Short-term relationship",
+ "Long-term Relationship",
+ // "Other",
],
},
- {
- name: "kids",
- label: "What are your ideal plans for children? (optional)",
- type: "select",
- options: [
- "Skip",
- "Want someday",
- "Don't want",
- "Have and want more",
- "Have and don't want more",
- "Not sure yet",
- "Have kids",
- "Open to kids",
- ],
- optional: true,
- condition: (values) =>
- ["Short-term dating", "Hookups", "Long-term dating"].includes(
- values.relationshipType
- ),
- },
- {
- name: "nonMonogamy",
- label: "Non-Monogamy Options",
- type: "select",
- options: ["Monogamous", "Non-monogamous", "Open to either"],
- condition: (values) =>
- ["Short-term dating", "Hookups", "Long-term dating"].includes(
- values.relationshipType
- ),
- },
+ // {
+ // name: "kids",
+ // label: "What are your ideal plans for children? (optional)",
+ // type: "select",
+ // options: [
+ // "Skip",
+ // "Want someday",
+ // "Don't want",
+ // "Have and want more",
+ // "Have and don't want more",
+ // "Not sure yet",
+ // "Have kids",
+ // "Open to kids",
+ // ],
+ // optional: true,
+ // condition: (values) =>
+ // ["Short-term dating", "Hookups", "Long-term dating"].includes(
+ // values.relationshipType
+ // ),
+ // },
+ // {
+ // name: "nonMonogamy",
+ // label: "Non-Monogamy Options",
+ // type: "select",
+ // options: ["Monogamous", "Non-monogamous", "Open to either"],
+ // condition: (values) =>
+ // ["Short-term dating", "Hookups", "Long-term dating"].includes(
+ // values.relationshipType
+ // ),
+ // },
// {
// name: "photos",
// label: "Add photos (optional)",
@@ -137,37 +137,37 @@ const questions: Question[] = [
type: "textarea",
},
// Personality questions
- {
- name: "intenseOrCarefree",
- label: "Which word describes you better?",
- type: "select",
- options: ["Intense", "Carefree"],
- },
- {
- name: "religion",
- label: "How important is religion/God in your life?",
- type: "select",
- options: [
- "Not at all important",
- "Slightly important",
- "Moderately important",
- "Very important",
- "Extremely important"
- ]
- },
- {
- name: "politics",
- label: "Which best describes your political beliefs?",
- type: "select",
- options: [
- "Very liberal",
- "Liberal",
- "Moderate",
- "Conservative",
- "Very conservative",
- "Other"
- ]
- },
+ // {
+ // name: "intenseOrCarefree",
+ // label: "Which word describes you better?",
+ // type: "select",
+ // options: ["Intense", "Carefree"],
+ // },
+ // {
+ // name: "religion",
+ // label: "How important is religion/God in your life?",
+ // type: "select",
+ // options: [
+ // "Not at all important",
+ // "Slightly important",
+ // "Moderately important",
+ // "Very important",
+ // "Extremely important"
+ // ]
+ // },
+ // {
+ // name: "politics",
+ // label: "Which best describes your political beliefs?",
+ // type: "select",
+ // options: [
+ // "Very liberal",
+ // "Liberal",
+ // "Moderate",
+ // "Conservative",
+ // "Very conservative",
+ // "Other"
+ // ]
+ // },
{
name: "introversion",
label: "How would you describe your social style?",
@@ -206,7 +206,7 @@ const getVisibleQuestions = (values: FormValues) =>
questions.filter((q) => !q.condition || q.condition(values));
-const MultiStepForm: React.FC = () => {
+const onboardingForm: React.FC = () => {
const searchParams = useSearchParams();
const redirect = searchParams.get('redirect') || '/';
const router = useRouter();
@@ -274,6 +274,7 @@ const MultiStepForm: React.FC = () => {
name: allValues.name,
};
for (const t of ['connections']) {
+ if (!allValues[t]) continue;
data[t] = Array.from(allValues[t]).map(name => ({
id: allFeatures[t].find(i => i.name === name)?.id,
name: name
@@ -315,7 +316,6 @@ const MultiStepForm: React.FC = () => {
const skipFrom = visibleQuestions.findIndex(q => q.name === 'relationshipDuration');
const canSkip = step >= skipFrom && skipFrom !== -1;
-
return (
{error && errorBlock(error)}
@@ -668,10 +668,9 @@ const MultiStepForm: React.FC = () => {
)}
{!isLastStep ? (