// Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. // SPDX-License-Identifier: Apache-2.0 import React, { ChangeEvent, FC, InputHTMLAttributes } from 'react'; import Radio from '../Radio'; export interface RadioProps { label: string; value: string; icon?: JSX.Element; inputProps?: InputHTMLAttributes; /* Unique identifier to target element */ testId?: string; } export interface RadioGroupProps { /** The callback fired when the state is changed. */ onChange(event: ChangeEvent): void; /** Options of radio group. */ options: RadioProps[]; /** The selected option. */ value: string; } export const RadioGroup: FC> = ( props ) => { const { options, value, onChange } = props; return ( <> {options.map((option: any, index: number) => { return ( ); })} ); }; RadioGroup.displayName = 'RadioGroup'; export default RadioGroup;