Merge branch 'main' into feat/packages
This commit is contained in:
@@ -1,20 +1,20 @@
|
||||
import { BaseEdge, HandleElement } from './types';
|
||||
|
||||
export const errorMessages = {
|
||||
'001': () =>
|
||||
error001: () =>
|
||||
'[React Flow]: Seems like you have not used zustand provider as an ancestor. Help: https://reactflow.dev/error#001',
|
||||
'002': () =>
|
||||
error002: () =>
|
||||
"It looks like you've created a new nodeTypes or edgeTypes object. If this wasn't on purpose please define the nodeTypes/edgeTypes outside of the component or memoize them.",
|
||||
'003': (nodeType: string) => `Node type "${nodeType}" not found. Using fallback type "default".`,
|
||||
'004': () => 'The React Flow parent container needs a width and a height to render the graph.',
|
||||
'005': () => 'Only child nodes can use a parent extent.',
|
||||
'006': () => "Can't create edge. An edge needs a source and a target.",
|
||||
'007': (id: string) => `The old edge with id=${id} does not exist.`,
|
||||
'009': (type: string) => `Marker type "${type}" doesn't exist.`,
|
||||
'008': (sourceHandle: HandleElement | null, edge: BaseEdge) =>
|
||||
error003: (nodeType: string) => `Node type "${nodeType}" not found. Using fallback type "default".`,
|
||||
error004: () => 'The React Flow parent container needs a width and a height to render the graph.',
|
||||
error005: () => 'Only child nodes can use a parent extent.',
|
||||
error006: () => "Can't create edge. An edge needs a source and a target.",
|
||||
error007: (id: string) => `The old edge with id=${id} does not exist.`,
|
||||
error009: (type: string) => `Marker type "${type}" doesn't exist.`,
|
||||
error008: (sourceHandle: HandleElement | null, edge: BaseEdge) =>
|
||||
`Couldn't create edge for ${!sourceHandle ? 'source' : 'target'} handle id: "${
|
||||
!sourceHandle ? edge.sourceHandle : edge.targetHandle
|
||||
}", edge id: ${edge.id}.`,
|
||||
'010': () => 'Handle: No node id found. Make sure to only use a Handle inside a custom Node.',
|
||||
'011': (edgeType: string) => `Edge type "${edgeType}" not found. Using fallback type "default".`,
|
||||
error010: () => 'Handle: No node id found. Make sure to only use a Handle inside a custom Node.',
|
||||
error011: (edgeType: string) => `Edge type "${edgeType}" not found. Using fallback type "default".`,
|
||||
};
|
||||
|
||||
@@ -8,7 +8,7 @@ export type HandleElement = XYPosition &
|
||||
position: Position;
|
||||
};
|
||||
|
||||
export type StartHandle = {
|
||||
export type ConnectingHandle = {
|
||||
nodeId: string;
|
||||
type: HandleType;
|
||||
handleId?: string | null;
|
||||
@@ -18,6 +18,8 @@ export type HandleProps = {
|
||||
type: HandleType;
|
||||
position: Position;
|
||||
isConnectable?: boolean;
|
||||
isConnectableStart?: boolean;
|
||||
isConnectableEnd?: boolean;
|
||||
onConnect?: OnConnect;
|
||||
isValidConnection?: (connection: Connection) => boolean;
|
||||
id?: string;
|
||||
|
||||
Reference in New Issue
Block a user