diff --git a/app/components/settings/OpenSourceToggle.tsx b/app/components/settings/OpenSourceToggle.tsx index 9e60415..3f9f4a1 100644 --- a/app/components/settings/OpenSourceToggle.tsx +++ b/app/components/settings/OpenSourceToggle.tsx @@ -12,25 +12,26 @@ const OpenSourceModeToggle: React.FC = ({ setOpenSourceMode, setSelectedOption }) => { + // Handle toggle change event const handleToggleChange = () => { - const newValue = !openSourceMode; - setOpenSourceMode(newValue); + const newValue = !openSourceMode; // Toggle the current state + setOpenSourceMode(newValue); // Update the open source mode state // Update radio selection based on the new openSourceMode value if (newValue) { setSelectedOption('FOSS'); // Set to FOSS if enabling open source mode } else { - setSelectedOption('None'); // Or any other default value when disabling + setSelectedOption('None'); // Set to a default value when disabling } }; return ( -
+
{/* Container for the toggle setting */}