// templui component table - version: v0.84.0 installed by templui v0.84.0
package table
import "git.jmbit.de/jmb/scanfile/server/web/templui/utils"
type Props struct {
ID string
Class string
Attributes templ.Attributes
}
type HeaderProps struct {
ID string
Class string
Attributes templ.Attributes
}
type BodyProps struct {
ID string
Class string
Attributes templ.Attributes
}
type FooterProps struct {
ID string
Class string
Attributes templ.Attributes
}
type RowProps struct {
ID string
Class string
Attributes templ.Attributes
Selected bool
}
type HeadProps struct {
ID string
Class string
Attributes templ.Attributes
}
type CellProps struct {
ID string
Class string
Attributes templ.Attributes
}
type CaptionProps struct {
ID string
Class string
Attributes templ.Attributes
}
templ Table(props ...Props) {
{{ var p Props }}
if len(props) > 0 {
{{ p = props[0] }}
}
}
templ Header(props ...HeaderProps) {
{{ var p HeaderProps }}
if len(props) > 0 {
{{ p = props[0] }}
}
{ children... }
}
templ Body(props ...BodyProps) {
{{ var p BodyProps }}
if len(props) > 0 {
{{ p = props[0] }}
}
{ children... }
}
templ Footer(props ...FooterProps) {
{{ var p FooterProps }}
if len(props) > 0 {
{{ p = props[0] }}
}
tr]:last:border-b-0", p.Class) }
{ p.Attributes... }
>
{ children... }
}
templ Row(props ...RowProps) {
{{ var p RowProps }}
if len(props) > 0 {
{{ p = props[0] }}
}
{ children... }
}
templ Head(props ...HeadProps) {
{{ var p HeadProps }}
if len(props) > 0 {
{{ p = props[0] }}
}
[role=checkbox]]:translate-y-[2px]",
p.Class,
),
}
{ p.Attributes... }
>
{ children... }
|
}
templ Cell(props ...CellProps) {
{{ var p CellProps }}
if len(props) > 0 {
{{ p = props[0] }}
}
[role=checkbox]]:translate-y-[2px]",
p.Class,
),
}
{ p.Attributes... }
>
{ children... }
|
}
templ Caption(props ...CaptionProps) {
{{ var p CaptionProps }}
if len(props) > 0 {
{{ p = props[0] }}
}
{ children... }
}