(charts: ChartPayload[])
| 205 | } |
| 206 | |
| 207 | const appendChartBlocks = (charts: ChartPayload[]) => { |
| 208 | if (charts.length === 0) return |
| 209 | // 中文注释:图表 block 需要持久化给 CLI 生成的 AI 对话回放; |
| 210 | // 原始 SQL 行数据可能较大,保存时只保留渲染数据和字段元信息。 |
| 211 | contentBlocks.push(...charts.map((chart) => ({ type: 'chart' as const, chart: toPersistedChartPayload(chart) }))) |
| 212 | hasReplayContentBlocks = true |
| 213 | } |
| 214 | |
| 215 | const appendPlanDraftBlock = (delta: string) => { |
| 216 | if (!delta) return |
no test coverage detected