Expose portable scene bindings and an explicit React Flow peer adapter

This commit is contained in:
2026-11-09 15:07:18 +08:00
parent bceaf2eca6
commit 196ca4514e
19 changed files with 218 additions and 73 deletions
+3 -3
View File
@@ -1,9 +1,9 @@
"use client";
import { Handle, Position, BaseEdge, getBezierPath, type NodeProps, type EdgeProps } from '@xyflow/react';
import { defineComponent, editable, movable } from '@/lib/canvas-core/index';
import type { ProjectionNode, ProjectionEdge } from '@/lib/canvas-bindings/projection';
import type { CanvasRuntimeExtension } from '@/lib/canvas-bindings/react-renderers';
import { useCanvasRendererCommands } from '@/lib/canvas-bindings/renderer-context';
import type {ReactFlowProjectionNode as ProjectionNode,ReactFlowProjectionEdge as ProjectionEdge} from '@/lib/canvas-bindings/react-flow';
import type { CanvasRuntimeExtension } from '@/lib/canvas-bindings/react-flow';
import { useCanvasRendererCommands } from '@/lib/canvas-bindings/react-flow';
function Meter({data}:NodeProps<ProjectionNode>){
const commands=useCanvasRendererCommands(),record=data.__headlessRecord!;
return <div data-renderer-fixture="meter" style={{width:'100%',height:'100%',background:'white',border:'1px solid #ded7ce',padding:16}}>