social-platforms.tsx 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. import {
  2. FaXTwitter,
  3. FaFacebook,
  4. FaEnvelope,
  5. FaWhatsapp,
  6. FaGlobe,
  7. FaPhone,
  8. FaYoutube,
  9. FaLinkedin,
  10. FaSnapchat,
  11. FaInstagram,
  12. FaTiktok,
  13. FaThreads,
  14. } from "react-icons/fa6";
  15. import { TFunction } from "locales/client";
  16. export const SOCIAL_FIELD_PLACEHOLDERS: Record<string, string> = {
  17. x: "ex: johndoe",
  18. facebook: "ex: johndoe",
  19. instagram: "ex: johndoe",
  20. tiktok: "ex: johndoe",
  21. threads: "ex: johndoe",
  22. youtube: "ex: johndoe",
  23. linkedin: "ex: johndoe",
  24. snapchat: "ex: johndoe",
  25. twitch: "ex: johndoe",
  26. whatsapp: "ex: +33612345678",
  27. email: "ex: john@email.com",
  28. website: "ex: https://site.com",
  29. phone: "ex: +33612345678",
  30. };
  31. export const SOCIAL_FIELD_ICONS: Record<string, React.ReactNode> = {
  32. x: <FaXTwitter className="h-5 w-5 text-[#000]" />,
  33. facebook: <FaFacebook className="h-5 w-5 text-[#1877f3]" />,
  34. email: <FaEnvelope className="h-5 w-5 text-[#80b0f4]" />,
  35. whatsapp: <FaWhatsapp className="h-5 w-5 text-[#25d366]" />,
  36. website: <FaGlobe className="h-5 w-5 text-[#334155]" />,
  37. phone: <FaPhone className="h-5 w-5 text-[#66e534]" />,
  38. youtube: <FaYoutube className="h-5 w-5 text-[#ff0000]" />,
  39. linkedin: <FaLinkedin className="h-5 w-5 text-[#0077b5]" />,
  40. snapchat: <FaSnapchat className="h-5 w-5 text-[#fffc00]" />,
  41. instagram: <FaInstagram className="h-5 w-5 text-[#e1306c]" />,
  42. tiktok: <FaTiktok className="h-5 w-5 text-black" />,
  43. threads: <FaThreads className="h-5 w-5 text-black" />,
  44. };
  45. export const SOCIAL_PLATFORMS = (t: TFunction) =>
  46. [
  47. { value: "x", label: t("social_platforms.x"), icon: SOCIAL_FIELD_ICONS.x },
  48. { value: "facebook", label: t("social_platforms.facebook"), icon: SOCIAL_FIELD_ICONS.facebook },
  49. { value: "email", label: t("social_platforms.email"), icon: SOCIAL_FIELD_ICONS.email },
  50. { value: "whatsapp", label: t("social_platforms.whatsapp"), icon: SOCIAL_FIELD_ICONS.whatsapp },
  51. { value: "website", label: t("social_platforms.website"), icon: SOCIAL_FIELD_ICONS.website },
  52. { value: "phone", label: t("social_platforms.phone"), icon: SOCIAL_FIELD_ICONS.phone },
  53. { value: "youtube", label: t("social_platforms.youtube"), icon: SOCIAL_FIELD_ICONS.youtube },
  54. { value: "linkedin", label: t("social_platforms.linkedin"), icon: SOCIAL_FIELD_ICONS.linkedin },
  55. { value: "snapchat", label: t("social_platforms.snapchat"), icon: SOCIAL_FIELD_ICONS.snapchat },
  56. { value: "instagram", label: t("social_platforms.instagram"), icon: SOCIAL_FIELD_ICONS.instagram },
  57. { value: "tiktok", label: t("social_platforms.tiktok"), icon: SOCIAL_FIELD_ICONS.tiktok },
  58. { value: "threads", label: t("social_platforms.threads"), icon: SOCIAL_FIELD_ICONS.threads },
  59. ] as const;