digitinary-ui
Version:
Digitinary UI Library
24 lines (23 loc) • 1.34 kB
TypeScript
import React from 'react';
import { Group } from '../../types';
interface SearchInputProps {
search: string;
setSearch: (value: string) => void;
toggleDropdown: () => void;
dropdownRef: React.RefObject<HTMLDivElement>;
disabled?: boolean;
}
export declare const extractTextFromElement: (element: JSX.Element | string) => string;
export declare const getNextKey: (currentKey: string, optionRefs: React.MutableRefObject<{
[key: string]: HTMLDivElement | null;
}>) => string;
export declare const getPreviousKey: (currentKey: string, optionRefs: React.MutableRefObject<{
[key: string]: HTMLDivElement | null;
}>) => string;
export declare const getFilteredOptions: (options: Group[], search: string) => Group[];
export declare const handleFlip: (optionsContainerRef: React.RefObject<HTMLDivElement>, setDropdownDirection: any, dropdownDirection: string) => void;
export declare const handleClickOutside: (event: MouseEvent, containerRef: React.RefObject<HTMLDivElement>, setIsOpen: React.Dispatch<React.SetStateAction<boolean>>, setDropdownDirection: React.Dispatch<React.SetStateAction<string>>) => void;
export declare const isSelected: (value: any, listItem: any) => boolean;
export declare const isActive: (value: any) => "" | "activeArrow";
export declare const SearchInput: React.FC<SearchInputProps>;
export {};