agora-classroom-sdk
Version:
For publishing npm package agora-classroom-sdk (Web & Electron). Get more information from https://docs.agora.io
23 lines (22 loc) • 840 B
TypeScript
export declare const useUnMount: (cb: CallableFunction) => void;
export declare const useMounted: () => boolean;
export declare const useTimeout: (fn: CallableFunction, delay: number) => void;
export declare const useDebounce: <T>(value: T, delay?: number | undefined) => T;
/**
* figure out a position that the target can make use to be centered in the container which has the `bounds` class.
* @param
* draggableHeight: target's height
* draggableWidth: target's width
* bounds: class of the container which the target will be centered in
* @returns
*/
export declare const useDraggableDefaultCenterPosition: ({ draggableHeight, draggableWidth, bounds, }: {
draggableWidth: number;
draggableHeight: number;
bounds?: string | undefined;
}) => {
x: number;
y: number;
width: number;
height: number;
};