diff --git a/app/[lang]/programs/page.tsx b/app/[lang]/programs/page.tsx index 1e882dd..2421c90 100644 --- a/app/[lang]/programs/page.tsx +++ b/app/[lang]/programs/page.tsx @@ -41,6 +41,14 @@ const SectionLabel = ({ label }: { label: string }) => { ) } +const AccordionLabel = ({ label }: { label: string }) => { + return ( + + {label} + + ) +} + const ProgramDetail = ({ title, location, @@ -94,18 +102,21 @@ const ProgramDetail = ({ const ProgramSections = ["contributionsProgram", "accelerationProgram"] as const -const ChooseProgramItems: DropdownProps["items"] & { href?: string } = [ +const ChooseProgramItems: { label: string; value: string; href?: string }[] = [ { label: "Contributions Program Asia", value: "contributionsProgramAsia", + href: siteConfig.links.applyContributionProgram, }, { label: "Contributions Program LatAm", value: "contributionsProgramaLatAm", + href: siteConfig.links.applyContributionProgram, }, { label: "Acceleration Program", value: "accelerationProgram", + href: siteConfig.links.applyContributionProgram, }, ] export default function ProgramsPage({ params: { lang } }: any) { @@ -177,6 +188,17 @@ export default function ProgramsPage({ params: { lang } }: any) { "" const selectedProgramLabel = t(selectedProgramKey) + const ApplyButton = () => { + return ( + + ) + } + return (
@@ -211,12 +233,16 @@ export default function ProgramsPage({ params: { lang } }: any) { defaultItem="contributionsProgram" />
- + {!selectedProgram ? ( + + ) : ( + + + + )}
@@ -272,7 +298,7 @@ export default function ProgramsPage({ params: { lang } }: any) { -
+
{contributionsProgramDescription?.map( (description, index) => { return ( @@ -287,56 +313,84 @@ export default function ProgramsPage({ params: { lang } }: any) { )}
-
- - - {curriculum.map(({ title, items }, index) => ( -
-
- - {t("common.week", { - week: index, - })} -
- {title} -
-
-
-
    - {items.map((label: string, index: number) => { - return
  • {label}
  • - })} -
-
-
- ))} -
-
-
- +
{ - return { - label: ( - - {question} - - ), - value: index.toString(), - children: answer, - } - } - )} + className="!border-none" + iconOnHover={false} + items={[ + { + label: ( + + ), + value: "curriculum", + children: ( + + {curriculum.map(({ title, items }, index) => ( +
+
+ + {t("common.week", { + week: index, + })} +
+ {title} +
+
+
+
    + {items.map( + (label: string, index: number) => { + return
  • {label}
  • + } + )} +
+
+
+ ))} +
+ ), + }, + ]} + /> + , + value: "faq", + children: ( +
+ { + return { + label: ( + + {question} + + ), + value: index.toString(), + children: answer, + } + } + )} + /> +
+ ), + }, + ]} />
@@ -371,7 +425,7 @@ export default function ProgramsPage({ params: { lang } }: any) { -
+
{accelerationProgramDescription?.map((description, index) => { return ( @@ -380,68 +434,103 @@ export default function ProgramsPage({ params: { lang } }: any) { ) })}
-
- -
-
- {t("howToApply.openTasks.title")} -
    - {howToApply?.openTasks?.description?.map( - (task: string, index: number) => { - return ( -
  • -
    -
  • - ) - } - )} -
-
-
- {t("howToApply.submitIdea.title")} -
    - {howToApply?.submitIdea?.description?.map( - (task: string, index: number) => { - return ( -
  • -
    -
  • - ) - } - )} -
-
- {t("howToApply.description")} -
-
-
- +
{ - return { - label: ( - - {question} - - ), - value: index.toString(), - children: answer, - } - } - )} + className="!border-none" + iconOnHover={false} + items={[ + { + label: , + value: "howToApply", + children: ( +
+
+
+
+ {t("howToApply.openTasks.title")} +
    + {howToApply?.openTasks?.description?.map( + (task: string, index: number) => { + return ( +
  • +
    +
  • + ) + } + )} +
+
+
+ + {t("howToApply.submitIdea.title")} + +
    + {howToApply?.submitIdea?.description?.map( + (task: string, index: number) => { + return ( +
  • +
    +
  • + ) + } + )} +
+
+ {t("howToApply.description")} +
+
+
+ ), + }, + ]} + /> + + , + value: "faq", + children: ( +
+ { + return { + label: ( + + {question} + + ), + value: index.toString(), + children: answer, + } + } + )} + /> +
+ ), + }, + ]} />
diff --git a/components/site-footer.tsx b/components/site-footer.tsx index 2e7a29a..11bff7e 100644 --- a/components/site-footer.tsx +++ b/components/site-footer.tsx @@ -2,11 +2,12 @@ import Link from "next/link" -import { LangProps } from "@/types/common" -import { NavItem } from "@/types/nav" +import { useTranslation } from "@/app/i18n/client" import { siteConfig } from "@/config/site" import { useAppSettings } from "@/hooks/useAppSettings" -import { useTranslation } from "@/app/i18n/client" +import { cn } from "@/lib/utils" +import { LangProps } from "@/types/common" +import { NavItem } from "@/types/nav" import { Icons } from "./icons" import { AppContent } from "./ui/app-content" @@ -19,8 +20,14 @@ const SocialMedia = ({ label }: { label: string }) => { ) } -const LinksWrapper = ({ children }: { children: React.ReactNode }) => { - return
{children}
+const LinksWrapper = ({ + children, + className, +}: { + children: React.ReactNode + className?: string +}) => { + return
{children}
} export function SiteFooter({ lang }: LangProps["params"]) { @@ -31,103 +38,107 @@ export function SiteFooter({ lang }: LangProps["params"]) { return ( diff --git a/components/ui/accordion.tsx b/components/ui/accordion.tsx index e999367..0c6c996 100644 --- a/components/ui/accordion.tsx +++ b/components/ui/accordion.tsx @@ -21,6 +21,7 @@ interface AccordionProps extends RadixAccordion.AccordionImplProps { defaultValue?: string items: AccordionItemProps[] className?: string + iconOnHover?: boolean } const AccordionSizeMapping: Record = { @@ -34,6 +35,7 @@ const Accordion = ({ items, size = "sm", className, + iconOnHover = true, }: AccordionProps) => { return (
-
+