import { type BlockExecutor } from '../orchestration-schema.js'; /** * @serverBlockDoc * { * "version": 1, * "functionName": "renderPage", * "displayName": "渲染页面 HTML", * "category": "page", * "description": "将 Page DSL JSON 服务端渲染为包含内联样式的完整静态 HTML 文档。", * "inputs": [ * { "key": "page", "type": "Record", "required": true, "description": "待渲染的 Page DSL JSON 对象。" }, * { "key": "context", "type": "Record", "required": false, "defaultValue": {}, "description": "页面 context 数据源和变量使用的运行时上下文。" } * ], * "outputs": [ * { "key": "html", "type": "string", "description": "包含 doctype、head、内联 CSS 和 SSR body 的完整静态 HTML。" } * ], * "errors": [ * { "code": "BLOCK_RENDER_INPUT_INVALID", "description": "page 或 context 输入无效。" }, * { "code": "BLOCK_RENDER_FAILED", "description": "Block 预加载、页面数据源解析或 SSR 渲染失败。" } * ], * "config": [], * "runtime": [ * { "key": "requiresDatasource", "type": "boolean", "value": false, "description": "不需要数据库连接。" }, * { "key": "network", "type": "string", "value": "Page DSL dataSources", "description": "页面包含 datasource 数据源时会发起外部请求。" }, * { "key": "hydration", "type": "boolean", "value": false, "description": "输出不包含客户端 JavaScript,不支持浏览器端交互和 hydration。" } * ], * "examples": [ * { "title": "渲染页面", "block": { "uuid": "render_page", "functionName": "renderPage", "inputs": { "page": { "template": "{{request.body.page}}" }, "context": { "template": "{{request.body.context}}" } }, "outputs": ["html"], "nextBlock": null } } * ] * } */ export declare const executeRenderPageBlock: BlockExecutor;