From fa6ffc59aa407faecb24457d004f95d165d8cdd8 Mon Sep 17 00:00:00 2001
From: AmirReza Jamali
Date: Sat, 29 Nov 2025 15:19:20 +0330
Subject: [PATCH] feat(marketing): replace language input with Select; update
Countries to ISO-3
- Switch language field from text `InputGroup` to `Select` with `Languages` options,
`GlobeIcon`, clearable support, and conditional disable/require for companies
- Remove manual length validation as Select ensures valid predefined values
- Update `Countries` values from ISO-2 to ISO-3 codes for consistency
---
.../marketing/_components/MarketingForm.tsx | 24 +-
src/constants/countries.ts | 501 +++++++++---------
src/constants/languages.ts | 186 +++++++
3 files changed, 445 insertions(+), 266 deletions(-)
create mode 100644 src/constants/languages.ts
diff --git a/src/app/marketing/_components/MarketingForm.tsx b/src/app/marketing/_components/MarketingForm.tsx
index 3f161b2..dbf25d5 100644
--- a/src/app/marketing/_components/MarketingForm.tsx
+++ b/src/app/marketing/_components/MarketingForm.tsx
@@ -6,6 +6,7 @@ import { Select } from "@/components/FormElements/select";
import { ShowcaseSection } from "@/components/Layouts/showcase-section";
import Stepper, { Step } from "@/components/ui/Stepper";
import { Countries } from "@/constants/countries";
+import { Languages } from "@/constants/languages";
import { FormErrorMessages } from "@/constants/Texts";
import { BreadcrumbItem } from "@/types/shared";
import { useEffect, useRef, useState } from "react";
@@ -244,31 +245,24 @@ const MarketingForm = ({
)}
- }
disabled={!isCompany}
required={isCompany}
+ placeholder="Please select language"
+ onClear={() => setValue("language", undefined)}
/>
{pageTypeErrors.language && (
{pageTypeErrors.language.message}
)}
-