Documentation
¶
Overview ¶
templ: version: v0.3.1020
Index ¶
- func Card(label string) templ.Component
- func Dot(status string) templ.Component
- func Duration(d *time.Duration) string
- func Empty(msg, hint string) templ.Component
- func ErrorButton(runID string) templ.Component
- func ErrorDialog(runID, workflow, status, message string) templ.Component
- func Metric(label, value, nota string, matiz string) templ.Component
- func Rosca(i postgres.Indicators) templ.Component
- func RunsChart(buckets []postgres.Bucket) templ.Component
- func State(status string) templ.Component
- func Tag(text, rota string) templ.Component
- func Timestamp(t *time.Time) string
- func When(t *time.Time) string
- type Arc
- type Bar
- type Brand
- type GridLine
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Card ¶ added in v0.7.0
Card is the base panel: a light surface, a thin border, a warm wide shadow.
func Dot ¶ added in v0.7.0
Dot is the minimal version, for dense tables where the label is already in the column.
func Duration ¶ added in v0.7.0
Duration picks the unit by order of magnitude. "0.4s" says more than "400ms" in a column whose neighbour takes minutes.
func Empty ¶ added in v0.7.0
Empty communicates the absence of data without looking like an error. An empty table with no explanation sends the operator looking for a defect where there is none.
func ErrorButton ¶ added in v0.7.0
--------------------------------------------------------------------------- Err em dialogo
The error used to occupy a whole row below the run, inside the table. With a real stack trace that pushed the rest of the list off the screen and mixed two things — the list and the detail. Now the row holds a button, and the text lives in a native <dialog>: ESC closes it, the backdrop dims and the focus stays trapped inside it without a line of JavaScript of ours. ---------------------------------------------------------------------------
func ErrorDialog ¶ added in v0.7.0
func Metric ¶ added in v0.7.0
Metric is one of the four numbers at the top of the Overview. The large serif number is what sets the editorial tone — in sans it would become just another dashboard.
func Rosca ¶
func Rosca(i postgres.Indicators) templ.Component
Rosca resume a mesma janela em proporcao. O total no centro evita a leitura only relative: 95% of twenty runs is not 95% of two thousand.
func RunsChart ¶ added in v0.7.0
RunsChart draws one stacked column per hour, with the average-duration line on top — the two readings the Overview screen has to cross: "how many" and "quanto tempo".
func State ¶ added in v0.7.0
State desenha o estado de um Run.
The colours are desaturated on purpose: a dashboard's pure green and red fight the parchment and shout louder than the information. The shape carries meaning too — the dot is filled for what has finished and ringed for what is still alive — so it does not depend on colour alone.