Files
zhaojunlin.0405 f3558878cb refactor: move mail +triage pagination into data (im/calendar-style)
Align mail +triage with the repo-wide list convention: pagination lives inside
the data object, not meta. Output is {ok, data:{messages, total, has_more,
page_token}} with meta=nil.

Uses a typed triageOutput struct (like calendar +search-event) rather than a
map: output.toGeneric JSON-round-trips a struct, normalizing the nested
messages into []interface{} so output.ExtractItems can find it for
table/csv/ndjson rendering. (A top-level map is not round-tripped, which would
flatten the wrapper into a single row — caught by the new
TestMailTriageNdjsonEmitsOneMessagePerLine regression test.)

internal/output/envelope.go is restored to main (no Meta.HasMore/PageToken, no
Count omitempty change) — this PR no longer touches the shared envelope struct;
supersedes the CodeRabbit-A/P2 discussion. Docs, skill-eval, E2E updated to
.data.messages / .data.total / .data.has_more / .data.page_token.
2026-07-13 16:12:40 +08:00
..
2026-06-17 16:29:33 +08:00