From dd32ad585e2e5f6ad1a57c249626acf09d747048 Mon Sep 17 00:00:00 2001 From: rxf Date: Mon, 27 Oct 2025 17:24:48 +0100 Subject: [PATCH] Radiobuttons OHNE OK --- src/components/FandStattVer.jsx | 58 ++++++++++++--------------------- 1 file changed, 20 insertions(+), 38 deletions(-) diff --git a/src/components/FandStattVer.jsx b/src/components/FandStattVer.jsx index 54a0a42..e09db46 100644 --- a/src/components/FandStattVer.jsx +++ b/src/components/FandStattVer.jsx @@ -5,47 +5,29 @@ import Modal from './Modal' export default function FandStattVer({left, right, title, onNext, radioName = "fst"}) { const { formData, updateFormData } = useFormData() const [auswahl, setAuswahl] = useState(formData.stattgefunden || '') - const [showModal, setShowModal] = useState(false) - const handleOK = () => { - if(!auswahl) { - setShowModal(true) - return - } - updateFormData('stattgefunden', auswahl) - onNext(auswahl) - } - - const closeModal = () => { - setShowModal(false) + const handleRadioChange = (e) => { + const value = e.target.value + setAuswahl(value) + updateFormData('stattgefunden', value) + onNext(value) } return ( - <> -
-

{title}

-
- - - -
-
- - -

Bitte eine Option wählen

-
- +
+

{title}

+
+ + +
+
) } \ No newline at end of file