// @flow import React, { Component } from 'react'; import { Modal, Text, TouchableHighlight, TouchableWithoutFeedback, View } from 'react-native'; import { connect } from 'react-redux'; import { Icon } from '../../font-icons'; import { simpleBottomSheet as styles } from './styles'; /** * Underlay color for the buttons on the sheet. * * @type {string} */ const BUTTON_UNDERLAY_COLOR = '#eee'; type Option = { /** * Name of the icon which will be rendered on the right. */ iconName: string, /** * True if the element is selected (will be highlighted in blue), * false otherwise. */ selected: boolean, /** * Text which will be rendered in the row. */ text: string }; /** * The type of {@code SimpleBottomSheet}'s React {@code Component} prop types. */ type Props = { /** * Handler for the cancel event, which happens when the user dismisses * the sheet. */ onCancel: Function, /** * Handler for the event when an option has been selected in the sheet. */ onSubmit: Function, /** * Array of options which will be rendered as rows. */ options: Array