baseframe-js
Version:
A suite of useful Javascript plugins and functions to help with Front-end Development on websites
12 lines (11 loc) • 386 B
TypeScript
import type { Selector } from 'cash-dom';
interface ITrapFocusProps {
focusFirst?: boolean;
nameSpace?: string;
focusable?: ('button' | 'a' | 'input' | 'select' | 'textarea' | '[tabindex]')[];
}
export interface ITrapFocusRemove {
remove: () => void;
}
declare const trapFocus: (modalEl: Selector, props?: ITrapFocusProps) => ITrapFocusRemove;
export default trapFocus;