Update the shared precipitation timing template

This commit is contained in:
2026-06-16 19:20:26 -05:00
parent f9d6d42b1b
commit b36e198bfe
5 changed files with 51 additions and 16 deletions

View File

@@ -76,9 +76,9 @@ fail rendering instead of producing incomplete Markdown.
Daily and Tomorrow call the shared `daypart_forecast` partial. Today calls
`today_daypart_forecast` so it can omit elapsed or missing dayparts. Daily,
Today, and Tomorrow call the shared `precipitation_timing` partial. Partial
files are parsed with each top-level template at render time and receive the
same typed render context as the caller.
Today, Tomorrow, and Hourly call the shared `precipitation_timing` partial.
Partial files are parsed with each top-level template at render time and
receive the same typed render context as the caller.
## Schema Contract

View File

@@ -18,7 +18,7 @@ Shared named partials live under `internal/reporttemplate/templates/partials/`:
- `daypart_forecast.md.tmpl`, used by Daily and Tomorrow
- `today_daypart_forecast.md.tmpl`, used by Today
- `precipitation_timing.md.tmpl`, used by Daily, Today, and Tomorrow
- `precipitation_timing.md.tmpl`, used by Daily, Today, Tomorrow, and Hourly
Templates are rendered from structured contexts such as `DailyRenderContext`,
`TodayRenderContext`, `TomorrowRenderContext`, and `HourlyRenderContext`.
@@ -294,7 +294,7 @@ Common fields:
| `.Modules.PrecipTiming.PrecipitationWindows[].MaxPopTime` | string | Friendly local time for the window maximum. |
| `.Modules.PrecipTiming.PrecipitationWindows[].MaxPopHourLabel` | string | Friendly hour label for the window maximum. |
| `.Modules.PrecipTiming.PrecipitationWindows[].PrecipitationType` | string | Conservatively inferred precipitation type, such as `showers and thunderstorms`. |
| `.Modules.PrecipTiming.PrecipitationWindows[].ExpectationPhrase` | string | Probability-based sentence used by day-style templates. |
| `.Modules.PrecipTiming.PrecipitationWindows[].ExpectationPhrase` | string | Probability-based sentence used by precipitation timing templates. |
| `.Modules.PrecipTiming.ThunderMentioned` | bool | Whether thunder is mentioned in the forecast text. |
### Daypart Summaries