import React, {ReactElement, useState} from 'react'; import {View} from 'react-native'; import {Button, DefaultTheme, HelperText, Subheading, TextInput, Title} from 'react-native-paper'; import {ButtonProps, InputLineCountScreenProps} from '../models/ElementProps'; import {colors, styles} from './Styles'; export const InputLineCountButton = (props: ButtonProps): ReactElement => { return ; }; export const InputLineCountScreen = (props: InputLineCountScreenProps): ReactElement => { const [newLineCount, setNewLineCount] = useState('0'); const hasErrors = () => { if (newLineCount !== undefined && newLineCount !== null) { const newInt = parseInt(newLineCount, 10); return ( isNaN(newInt) || !isFinite(newInt) || newInt < 0 || newInt > 14000 ); } else { return true; } }; return Enter Line Count How many people are waiting in line? setNewLineCount(inputStr)} mode="outlined" theme={DefaultTheme} keyboardType="numeric" /> Line count must be a whole number greater than 0. }