Add daily render context
This commit is contained in:
@@ -53,7 +53,7 @@ render-context builder, and embedded assets.
|
||||
|
||||
## Template Contracts
|
||||
|
||||
Today, Tomorrow, and Hourly rendering use typed render contexts with:
|
||||
Daily, Today, Tomorrow, and Hourly rendering use typed render contexts with:
|
||||
|
||||
- report metadata labels such as title, location, valid period, and generation
|
||||
time
|
||||
@@ -62,14 +62,13 @@ Today, Tomorrow, and Hourly rendering use typed render contexts with:
|
||||
conditions, hourly forecast rows, precipitation timing, alerts, SPC outlooks,
|
||||
forecast discussion, SPC discussion, and weather story
|
||||
|
||||
Today and Tomorrow additionally expose forecast-date labels, ordered daypart
|
||||
forecast rows, daily/daypart summaries, planning facts, and a multi-paragraph
|
||||
forecast discussion generated-text slot. The ordered daypart slice is built in
|
||||
Go so templates do not range over maps.
|
||||
Daily, Today, and Tomorrow additionally expose forecast-date labels, ordered
|
||||
daypart forecast rows, daily/daypart summaries, planning facts, and a
|
||||
multi-paragraph forecast discussion generated-text slot. The ordered daypart
|
||||
slice is built in Go so templates do not range over maps.
|
||||
|
||||
The Daily template asset uses the same Markdown structure and field surface as
|
||||
Tomorrow's template. Its typed render context in `internal/generatedtext` is
|
||||
not implemented yet.
|
||||
The Daily template asset uses the same Markdown structure as Tomorrow's
|
||||
template and renders from `generatedtext.DailyRenderContext`.
|
||||
|
||||
Templates use `text/template` with `missingkey=error`, so missing context fields
|
||||
fail rendering instead of producing incomplete Markdown.
|
||||
|
||||
Reference in New Issue
Block a user