@selenite/commons
Version:
This typescript package provides a set of frequently used utilities, types and svelte actions for building projects with Typescript and Svelte.
18 lines (17 loc) • 487 B
TypeScript
import type { Action } from 'svelte/action';
export type Transform = {
x: number;
y: number;
k: number;
};
declare function drawLines({ canvas, transform, spacing: baseSpacing, color, width }: {
canvas: HTMLCanvasElement;
transform: Transform;
spacing?: number;
color?: string;
width?: number;
}): void;
export declare const gridLines: Action<HTMLCanvasElement, Omit<Parameters<typeof drawLines>[0], 'canvas'> & {
visibility?: boolean;
}>;
export {};