From 36f34d4a90ca92bc909abc8b2060e162da9aed0d Mon Sep 17 00:00:00 2001 From: Elite16 Date: Fri, 27 Jan 2023 18:41:56 +0530 Subject: [PATCH] selection area fixed --- src/components/Forms/_FormElement.js | 19 ++++++++++++++++--- 1 file changed, 16 insertions(+), 3 deletions(-) diff --git a/src/components/Forms/_FormElement.js b/src/components/Forms/_FormElement.js index e009c7a..3bd7324 100644 --- a/src/components/Forms/_FormElement.js +++ b/src/components/Forms/_FormElement.js @@ -1,6 +1,19 @@ -import React from "react"; +import React,{useState} from "react"; const FormElement = ({ Label, Value, Type, onChange, onSwitch, ImageHandler }) => { + const [fix,setfix] = useState(""); + const hoverClick=()=>{ + onSwitch(); + if (fix === "") { + setfix("yes"); + } + else { + setfix(""); + } + } + + + return (
{(() => { @@ -36,13 +49,13 @@ const FormElement = ({ Label, Value, Type, onChange, onSwitch, ImageHandler }) = case "Switch": return (
-
+