Skip to content

Commit

Permalink
Add Onboarding Template and fix imports
Browse files Browse the repository at this point in the history
  • Loading branch information
parkerra committed Sep 4, 2024
1 parent f0b629f commit b209839
Show file tree
Hide file tree
Showing 9 changed files with 93 additions and 28 deletions.
9 changes: 9 additions & 0 deletions web/components/Onboarding/GetStarted.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import { useState } from "react";

interface Props {
setPage: (arg0: any) => any;
}

export default function GetStartedPage({ setPage }: Props) {
return <div></div>;
}
9 changes: 9 additions & 0 deletions web/components/Onboarding/HouseholdInfo.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import { useState } from "react";

interface Props {
setPage: (arg0: any) => any;
}

export default function HouseholdInfoPage({ setPage }: Props) {
return <div></div>;
}
9 changes: 9 additions & 0 deletions web/components/Onboarding/LiabilityWaiver.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import { useState } from "react";

interface Props {
setPage: (arg0: any) => any;
}

export default function LiabilityWaiverPage({ setPage }: Props) {
return <div></div>;
}
9 changes: 9 additions & 0 deletions web/components/Onboarding/PreferredContact.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import { useState } from "react";

interface Props {
setPage: (arg0: any) => any;
}

export default function PreferredContactPage({ setPage }: Props) {
return <div></div>;
}
13 changes: 13 additions & 0 deletions web/components/Onboarding/RequestItems.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import { useState } from "react";

interface Props {
setPage: (arg0: any) => any;
}

export default function RequestItemsPage({ setPage }: Props) {

return (
<div>
</div>
)
}
9 changes: 9 additions & 0 deletions web/components/Onboarding/ShippingAddress.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import { useState } from "react";

interface Props {
setPage: (arg0: any) => any;
}

export default function ShippingAddressPage({ setPage }: Props) {
return <div></div>;
}
2 changes: 1 addition & 1 deletion web/pages/admin/caregivers.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ import { useRouter } from "next/router";
import React, { useMemo, useState } from "react";

import { Caregiver } from "@lib/types/users";
import { deleteCaretaker, getCaregivers } from "db/actions/caregiver/Caregiver";
import { deleteCaretaker, getCaregivers } from "db/actions/admin/Caregiver";

import CaretakerTable from "@components/CaretakerTable";

Expand Down
34 changes: 34 additions & 0 deletions web/pages/caregiver/onboarding.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
import { useState } from "react";

import GetStartedPage from "@components/Onboarding/GetStarted";
import HouseholdInfoPage from "@components/Onboarding/HouseholdInfo";
import LiabilityWaiverPage from "@components/Onboarding/LiabilityWaiver";
import RequestItemsPage from "@components/Onboarding/RequestItems";
import ShippingAddressPage from "@components/Onboarding/ShippingAddress";
import PreferredContactPage from "@components/Onboarding/PreferredContact";

export default function CaregiverOnboarding() {
// Page 0 - Let's Get Started, Page 1 - Household Information, Page 2 - Liability Waiver,
// Page 3 - Request Items, Page 4 - Shipping Address, Page 5 - Contact Page
const [page, setPage] = useState(0);

return (
<div>
{page == 0 ? (
<GetStartedPage setPage={setPage} />
) : page == 1 ? (
<HouseholdInfoPage setPage={setPage} />
) : page == 2 ? (
<LiabilityWaiverPage setPage={setPage} />
) : page == 3 ? (
<RequestItemsPage setPage={setPage} />
) : page == 4 ? (
<ShippingAddressPage setPage={setPage} />
) : page == 5 ? (
<PreferredContactPage setPage={setPage} />
) : null
// Save data and route to next page
}
</div>
);
}
27 changes: 0 additions & 27 deletions web/pages/index.tsx

This file was deleted.

0 comments on commit b209839

Please sign in to comment.