"use client"; import { BaseEdge, Handle, Position, getBezierPath, type EdgeProps, type NodeProps } from "@xyflow/react"; import type { ProjectionNode } from "@/lib/canvas-bindings/projection"; import type { CanvasEdgeModel } from "@/lib/canvas-v2"; import styles from "./canvas.module.css"; const positions={top:Position.Top,right:Position.Right,bottom:Position.Bottom,left:Position.Left}; /** Render only the known envelope and derived endpoints, never interpret opaque payload fields. */ export function UnsupportedNode({data,selected}:NodeProps){ const fallback=data.__headlessFallback; return
{data.title}此元素需要兼容的组件版本才能编辑 {fallback?.reason==='renderer-unavailable'?'当前视图暂无此类型的编辑器':'原始内容已保留'} {fallback?.handles.map(handle=>)}
; } export function UnsupportedEdge(props:EdgeProps){ const [path]=getBezierPath(props); return 原始连线内容已保留; }