use crate::templates::card::card;
use anyhow::Result;
use maud::{html, Markup};
pub(crate) fn table(ctx: &crate::ctx::ClientContext, k: &str) -> Result<Markup> {
Ok(html! {
(card(ctx, html! {
h3 {
span.icon data-uk-icon=("icon: bookmark") {}
" "
(k)
}
a.(ctx.user_profile().link_class()) href="" onclick=(crate::html::onclick_event("run-sql", &format!("table-{}", k), &format!("'select * from {} limit 100'", k))) { "View First 100 Rows" }
}))
div#(format!("table-{}-results", k)) { }
})
}