UNPKG

uicore-ts

Version:

UICore is a library to build native-like user interfaces using pure Typescript. No HTML is needed at all. Components are described as TS classes and all user interactions are handled explicitly. This library is strongly inspired by the UIKit framework tha

35 lines (34 loc) 1.54 kB
import { UIAutocompleteItem, UIAutocompleteRowView } from "./UIAutocompleteRowView"; import { UITableView } from "./UITableView"; import { UIView } from "./UIView"; export declare class UIAutocompleteDropdownView<T> extends UIView { tableView: UITableView; _fullHeightView: UIView; _filteredItems: UIAutocompleteItem<T>[]; _filterWords: string[]; _highlightedRowIndex: number; _rowHeight: number; _maxVisibleRows: number; _isPointerInsideDropdown: boolean; _suppressHoverHighlight: boolean; didSelectItem?: (item: UIAutocompleteItem<T>) => void; anchorView?: UIView; constructor(elementID?: string); /** Override in subclass to provide custom row views. */ newRowView(identifier: string, rowIndex: number): UIAutocompleteRowView<T>; viewForRowWithIndex(index: number): UIView; get highlightedRowIndex(): number; set highlightedRowIndex(index: number); /** Internal setter. scrollIntoView=YES for keyboard navigation, NO for pointer hover. */ _setHighlightedRowIndex(index: number, scrollIntoView: boolean): void; get highlightedItem(): UIAutocompleteItem<T> | undefined; set filteredItems(items: UIAutocompleteItem<T>[]); get filteredItems(): UIAutocompleteItem<T>[]; set filterWords(words: string[]); get filterWords(): string[]; /** Anchors this dropdown below the given field view inside the rootView. */ showAnchoredToView(anchorView: UIView): void; dismiss(): void; _updateFullHeightView(): void; layoutSubviews(): void; }