UNPKG

fabric

Version:

Object model for HTML5 canvas, and SVG-to-canvas parser. Backed by jsdom and node-canvas.

21 lines (16 loc) 456 B
import type { Pattern } from './Pattern'; export type PatternRepeat = 'repeat' | 'repeat-x' | 'repeat-y' | 'no-repeat'; type ExportedKeys = | 'crossOrigin' | 'offsetX' | 'offsetY' | 'patternTransform' | 'repeat' | 'source'; export type PatternOptions = Partial<Pick<Pattern, ExportedKeys>> & { source: CanvasImageSource; }; export type SerializedPatternOptions = Omit<PatternOptions, 'source'> & { type: 'pattern'; source: string; };