Skip to content

Blueprint API

Blueprint

Extends Effect.

Factory Function

typescript
createBlueprint(config?: BlueprintConfig)

Methods

See Effect for the full method reference: mount(), start(), pause(), resume(), configure(), withFade(), and destroy().


BlueprintConfig

typescript
interface BlueprintConfig {
    speed?: number;
    gridSize?: number;
    lineColor?: string;
    backgroundColor?: string;
    complexity?: number;
    scale?: number;
}
PropertyTypeDefaultDescription
speednumber1Animation speed multiplier.
gridSizenumber30Background grid spacing in pixels.
lineColorstring'#c8deff'Color of drawn lines and shapes.
backgroundColorstring'#0d1b2a'Background fill color.
complexitynumber5Number of elements per drawing (higher = more complex shapes).
scalenumber1Global scale factor.

BlueprintElement

Internal representation of a single element within a drawing.

typescript
type BlueprintElement = {
    type: 'line' | 'rect' | 'circle' | 'arc' | 'dashed' | 'polyline' | 'dimension';
    points: number[];
    progress: number;
};