UNPKG

@visactor/vrender-core

Version:
19 lines (18 loc) 642 B
import type { IGraphicAttribute, IGraphic } from '../graphic'; export type IRepeatType = 'no-repeat' | 'repeat'; export type IImageAttribute = { width: number; height: number; maxWidth?: number; maxHeight?: number; repeatX: IRepeatType; repeatY: IRepeatType; image: string | HTMLImageElement | HTMLCanvasElement; cornerRadius: number | number[]; cornerType: 'round' | 'bevel'; }; export type IImageGraphicAttribute = Partial<IGraphicAttribute> & Partial<IImageAttribute>; export interface IImage extends IGraphic<IImageGraphicAttribute> { successCallback?: () => void; failCallback?: () => void; }