From 5ad75e412ba2668f2e344bc14f619c1e2511563c Mon Sep 17 00:00:00 2001 From: victorAnumudu Date: Wed, 25 Feb 2026 19:49:31 +0100 Subject: [PATCH] https validator added --- src/component/settings/LinksForm.jsx | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/src/component/settings/LinksForm.jsx b/src/component/settings/LinksForm.jsx index fbe68c5..717714e 100644 --- a/src/component/settings/LinksForm.jsx +++ b/src/component/settings/LinksForm.jsx @@ -8,12 +8,12 @@ import queryKeys from '../../services/queryKeys'; const linksValidationSchema = Yup.object().shape({ - // facebook_url: Yup.string().required("facebook is required"), - // twitter_url: Yup.string().required("twitter is required"), - // blogger_url: Yup.string().required("blog is required"), - // google_url: Yup.string().required("google is required"), - // linked_url: Yup.string().required("linkedin is required"), - // website_url: Yup.string().required("website is required"), + facebook_url: Yup.string().matches(/^https:\/\/.+/,"URL must start with https://"), + twitter_url: Yup.string().matches(/^https:\/\/.+/,"URL must start with https://"), + blogger_url: Yup.string().matches(/^https:\/\/.+/,"URL must start with https://"), + google_url: Yup.string().matches(/^https:\/\/.+/,"URL must start with https://"), + linked_url: Yup.string().matches(/^https:\/\/.+/,"URL must start with https://"), + website_url: Yup.string().matches(/^https:\/\/.+/,"URL must start with https://"), }) export default function LinksForm({data}) { @@ -90,31 +90,31 @@ export default function LinksForm({data}) { return (
- +
- +
- +
- +
- +
- +
-- 2.34.1