diff --git a/components/RadioButton.tsx b/components/RadioButton.tsx new file mode 100644 index 0000000..2e275e0 --- /dev/null +++ b/components/RadioButton.tsx @@ -0,0 +1,36 @@ +'use client' + +// https://tailwindui.com/components/application-ui/forms/radio-groups + +import { useState } from 'react' + +export default function RadioButtonGroup({ options }: { options: {id: string}[] }) { + + const [selectedOption, setSelectedOption] = useState(options[0].id) + + function onValueChange(event: any){ + setSelectedOption(event.target.value) + } + + return ( +