| {
let color = match state.clone() {
Some(s) => match s.is_ok {
true => "bg-green-600",
false => "bg-red-600",
},
None => "bg-yellow-600",
};
let text = match state {
Some(s) => match s.error {
Some(err) => err,
None => s.message.unwrap_or(String::from("")),
},
None => String::from("Loading..."),
};
view! {
}
};
view! {
{move || f(status.get())}
}
}