@extclp/vexip-ui
Version:
A Vue 3 UI library, Highly customizability, full TypeScript, performance pretty good
30 lines (29 loc) • 885 B
TypeScript
export interface CaptchaHollowOptions {
ctx: CanvasRenderingContext2D;
/**
* The x coordinate of slide target center
*/
x: number;
/**
* The y coordinate of slide target center
*/
y: number;
/**
* Current canvas width
*/
width: number;
/**
* Current canvas height
*/
height: number;
}
/**
* Specify the react of the hollow's shape
*/
export type CaptchaHollowResult = [x: number, y: number, width: number, height: number];
export type CaptchaHollowProcess = (options: CaptchaHollowOptions) => CaptchaHollowResult;
export type CaptchaHollowType = 'square' | 'puzzle' | 'shield' | 'heart';
export declare const squarePath: CaptchaHollowProcess;
export declare const puzzlePath: CaptchaHollowProcess;
export declare const shieldPath: CaptchaHollowProcess;
export declare const heartPath: CaptchaHollowProcess;