Update AGENTS.md. Start fixing old weird errors

This commit is contained in:
gib committed 2026-03-26 12:05:12 -05:00
1 parent 0bc04dbf6b
commit d16f4287ce
96 files changed
+18195 -9182

No files matched your search

@@ -9,12 +9,12 @@ type EventType =
| 'focusin'
| 'focusout';
export function useOnClickOutside<T extends HTMLElement = HTMLElement>(
export const useOnClickOutside = <T,>(
ref: React.RefObject<T | null> | React.RefObject<T | null>[],
handler: (event: MouseEvent | TouchEvent | FocusEvent) => void,
eventType: EventType = 'mousedown',
eventListenerOptions: AddEventListenerOptions = {},
): void {
): void => {
const savedHandler = React.useRef(handler);
React.useLayoutEffect(() => {
@@ -55,6 +55,6 @@ export function useOnClickOutside<T extends HTMLElement = HTMLElement>(
);
};
}, [ref, eventType, eventListenerOptions]);
}
};
export type { EventType };