feat: land page aggregate and phase7 document ai mainline

- 收口 page aggregate 读取、本地状态与命令客户端\n- 接入 phase7 document ai sidecar 与前端编排入口\n- 更新 architecture 与 design 状态迁移
This commit is contained in:
lix-2026
2026-04-23 07:38:34 +08:00
parent 8353aea2f9
commit 41e958769e
93 changed files with 8778 additions and 2222 deletions
@@ -8,9 +8,10 @@ import {
documentBridgeErrorResponse,
} from "@/lib/documents/bridge";
import {
executeMetadataBridgeCommand,
type DocumentTitleUpdatePayload,
} from "@/lib/documents/metadata-command-adapter";
import { executePageWriteBridgeCommand } from "@/lib/documents/page-write-command-adapter";
import { PAGE_COMMAND_NAMES } from "@/lib/documents/page-command-contract";
interface RenamePayload {
documentId: string;
@@ -27,7 +28,7 @@ export async function POST(request: Request) {
const normalizedWorkspaceId = workspaceId?.trim() || null;
const bridgeContext = await buildDocumentBridgeContext({ request, workspaceId: normalizedWorkspaceId });
const envelope = buildDocumentCommandEnvelope({
name: "documents.title.update",
name: PAGE_COMMAND_NAMES.updateTitle,
payload: {
documentId: normalizedDocumentId,
workspaceId: normalizedWorkspaceId,
@@ -39,7 +40,7 @@ export async function POST(request: Request) {
pageId: normalizedDocumentId,
},
});
const result = await executeMetadataBridgeCommand({
const result = await executePageWriteBridgeCommand({
context: bridgeContext,
envelope,
});