use colored::Colorize;
use tabled::{object::Segment, Alignment, Modify, Table, Tabled};
pub fn render_list<I, T>(iter: I) -> String
where
I: IntoIterator<Item = T>,
T: Tabled,
{
let color = tabled::style::Color::try_from(" ".cyan().to_string()).unwrap();
Table::new(iter)
.with(tabled::Style::rounded())
.with(color)
.with(Modify::new(Segment::all()).with(Alignment::center()))
.to_string()
}