Bus UI Data Display
TextTable renders trusted row nodes with static headers.
Use it when the headers are static and the row nodes already come from trusted component code. It keeps the table shape explicit while validation stays visible.
Public API
TextTable(headers []string, rows []Node, log ControlLogSink) gx.Node
The inputs are static headers and trusted row Node values. The
result is a rendered Node.
When to use it
Use TextTable when the caller already owns trusted row nodes. If
you want cell-level validation and generated row objects, use
DenseTable instead.
Live demo
Example
Go API
import (
gx "github.com/busdk/bus-gx/pkg/gx"
ui "github.com/busdk/bus-ui/pkg/ui"
)
rows := []ui.Node{
ui.Node("June receipts 3 files Ready "),
}
node := ui.TextTable([]string{"Title", "Files", "State"}, rows)
html, err := gx.RenderHTML(node)
.gx source
In .gx source, author the visible component state as GX markup.
Keep the Go API block above for the package helper or render-boundary call.
package busuiexamples
import gx "github.com/busdk/bus-gx/pkg/gx"
func TextTableExample() gx.Node {
return <TextTable caption="Document queue">
<p>Document queue</p>
</TextTable>
}
Use the public pkg/ui facade for this static table helper.