pivotick - v2.0.1
    Preparing search index...

    Type Alias EdgeCreateDecision

    EdgeCreateDecision:
        | boolean
        | {
            accept: boolean;
            data?: EdgeData;
            directed?: boolean
            | null;
            id?: string;
            persisted?: boolean;
            style?: PartialEdgeFullStyle;
        }

    The decision returned by InterractionCallbacks.onBeforeEdgeCreate.

    true accepts with defaults, false vetoes. The object form accepts (when accept is true) and lets the consumer supply the new edge's data/style/id/ direction. The data/style/id/directed fields apply to edges only and are ignored for note-links.

    Type Declaration

    • boolean
    • {
          accept: boolean;
          data?: EdgeData;
          directed?: boolean | null;
          id?: string;
          persisted?: boolean;
          style?: PartialEdgeFullStyle;
      }
      • accept: boolean
      • Optionaldata?: EdgeData
      • Optionaldirected?: boolean | null
      • Optionalid?: string
      • Optionalpersisted?: boolean

        The consumer wrote this creation through to its own backend — only the consumer can know a write happened, so only the consumer can declare it. The history row is marked saved and still reverses: undo takes the element off the canvas, the backend keeps its copy, and the menu says so before the click.

      • Optionalstyle?: PartialEdgeFullStyle