import * as React from 'react'; import { RelayLocation } from '../../shared/daemon-rpc-types'; import { IRelayLocationRedux } from '../redux/settings/reducers'; import LocationList, { LocationSelection, LocationSelectionType, RelayLocations, } from './LocationList'; interface IExitLocationsProps { source: IRelayLocationRedux[]; defaultExpandedLocations?: RelayLocation[]; selectedValue?: RelayLocation; selectedElementRef?: React.Ref; onSelect?: (value: LocationSelection) => void; onWillExpand?: (locationRect: DOMRect, expandedContentHeight: number) => void; onTransitionEnd?: () => void; } const ExitLocations = React.forwardRef(function ExitLocationsT( props: IExitLocationsProps, ref: React.Ref>, ) { const selectedValue: LocationSelection | undefined = props.selectedValue ? { type: LocationSelectionType.relay, value: props.selectedValue } : undefined; return ( ); }); export default ExitLocations;