@ertekinno/human-like
Version:
A sophisticated React typewriter effect library with realistic human typing behavior, mobile/desktop keyboards, and comprehensive theming support
25 lines (24 loc) • 930 B
TypeScript
import { HumanLikeConfig, HumanLikeHookReturn, MistakeInfo, KeyInfo, StateChangeEvent } from '../types';
interface UseHumanLikeOptions {
text: string;
config?: Partial<HumanLikeConfig>;
autoStart?: boolean;
showCursor?: boolean;
cursorChar?: string;
cursorBlinkSpeed?: number;
id?: string;
onStart?: (id?: string) => void;
onComplete?: (id?: string) => void;
onChar?: (char: string, index: number, id?: string) => void;
onMistake?: (mistake: MistakeInfo, id?: string) => void;
onBackspace?: (id?: string) => void;
onPause?: () => void;
onResume?: () => void;
onStateChange?: (event: StateChangeEvent) => void;
onKeyboardReset?: () => void;
keyboardMode?: 'mobile' | 'desktop';
onKey?: (keyInfo: KeyInfo) => void;
}
export declare function useHumanLike(options: UseHumanLikeOptions): HumanLikeHookReturn;
export {};
//# sourceMappingURL=useHumanLike.d.ts.map