| 623 | let instanceId = 1; |
| 624 | |
| 625 | export default class Select< |
| 626 | Option = unknown, |
| 627 | IsMulti extends boolean = false, |
| 628 | Group extends GroupBase<Option> = GroupBase<Option> |
| 629 | > extends Component< |
| 630 | Props<Option, IsMulti, Group>, |
| 631 | State<Option, IsMulti, Group> |
| 632 | > { |
| 633 | static defaultProps = defaultProps; |
| 634 | state: State<Option, IsMulti, Group> = { |
| 635 | ariaSelection: null, |
| 636 | focusedOption: null, |
| 637 | focusedOptionId: null, |
| 638 | focusableOptionsWithIds: [], |
| 639 | focusedValue: null, |
| 640 | inputIsHidden: false, |
| 641 | isFocused: false, |
| 642 | selectValue: [], |
| 643 | clearFocusValueOnUpdate: false, |
| 644 | prevWasFocused: false, |
| 645 | inputIsHiddenAfterUpdate: undefined, |
| 646 | prevProps: undefined, |
| 647 | instancePrefix: '', |
| 648 | isAppleDevice: false, |
| 649 | }; |
| 650 | |
| 651 | // Misc. Instance Properties |
| 652 | // ------------------------------ |
| 653 | |
| 654 | blockOptionHover = false; |
| 655 | isComposing = false; |
| 656 | commonProps: any; // TODO |
| 657 | initialTouchX = 0; |
| 658 | initialTouchY = 0; |
| 659 | openAfterFocus = false; |
| 660 | scrollToFocusedOptionOnUpdate = false; |
| 661 | userIsDragging?: boolean; |
| 662 | |
| 663 | // Refs |
| 664 | // ------------------------------ |
| 665 | |
| 666 | controlRef: HTMLDivElement | null = null; |
| 667 | getControlRef: RefCallback<HTMLDivElement> = (ref) => { |
| 668 | this.controlRef = ref; |
| 669 | }; |
| 670 | focusedOptionRef: HTMLDivElement | null = null; |
| 671 | getFocusedOptionRef: RefCallback<HTMLDivElement> = (ref) => { |
| 672 | this.focusedOptionRef = ref; |
| 673 | }; |
| 674 | menuListRef: HTMLDivElement | null = null; |
| 675 | getMenuListRef: RefCallback<HTMLDivElement> = (ref) => { |
| 676 | this.menuListRef = ref; |
| 677 | }; |
| 678 | inputRef: HTMLInputElement | null = null; |
| 679 | getInputRef: RefCallback<HTMLInputElement> = (ref) => { |
| 680 | this.inputRef = ref; |
| 681 | }; |
| 682 |
nothing calls this directly
no test coverage detected
searching dependent graphs…