use yew::{function_component, html, AttrValue, Callback, Children, Classes, Html, Properties};
use crate::form_group::FormGroup;
#[derive(Debug, Clone, PartialEq, Properties)]
pub struct Props {
#[prop_or_default]
pub aria_labelled_by: AttrValue,
#[prop_or_default]
pub children: Children,
#[prop_or_default]
pub classes: Classes,
#[prop_or_default]
pub default_value: AttrValue,
#[prop_or_default]
pub name: AttrValue,
#[prop_or_default]
pub on_change: Option<Callback<String>>,
#[prop_or(false)]
pub row: bool,
#[prop_or_default]
pub style: AttrValue,
#[prop_or_default]
pub value: AttrValue,
}
#[function_component(RadioGroup)]
pub fn radio_group(props: &Props) -> Html {
html! {
<FormGroup
aria_labelled_by={&props.aria_labelled_by}
classes={&props.classes}
role="radio-group"
style={&props.style}>
{for props.children.iter()}
</FormGroup>
}
}