---
name: PromoInput
route: /Inputs/PromoInput
menu: Inputs
---

import { Playground, PropsTable } from 'docz'
import { PromoInput } from '../../src'
import { Alert } from 'react-native'
import { colors } from '@barcard/functions'

## PromoInput

## About

Text input for promos.

## Basic Usage

<Playground>
  <PromoInput
    placeholder={'Success, Unsecure Text Entry'}
    onChangeText={val => alert('onChangeText called!')}
    handleSubmit={val => alert('handleSubmit called!')}
    handleReturnKey={val => alert('handleReturnKey called!')}
    onBlur={() => console.log('onBlur called!')}
    success={true}
    error={false}
    multiline={true}
    secureTextEntry={false}
    isSubmitting={false}
    autoFocus={false}
    opaque={true}
    numberOfLines={1}
  />
  <PromoInput
    placeholder={'Unsecure Text Entry'}
    onChangeText={val => alert('onChangeText called!')}
    handleSubmit={val => alert('handleSubmit called!')}
    handleReturnKey={val => alert('handleReturnKey called!')}
    onBlur={() => console.log('onBlur called!')}
    success={false}
    error={false}
    multiline={true}
    secureTextEntry={false}
    isSubmitting={false}
    autoFocus={false}
    opaque={true}
    numberOfLines={1}
  />
  <PromoInput
    placeholder={'Error, Unsecure Text Entry'}
    onChangeText={val => alert('onChangeText called!')}
    handleSubmit={val => alert('handleSubmit called!')}
    handleReturnKey={val => alert('handleReturnKey called!')}
    onBlur={() => console.log('onBlur called!')}
    success={false}
    error={true}
    multiline={true}
    secureTextEntry={false}
    isSubmitting={false}
    autoFocus={false}
    opaque={true}
    numberOfLines={1}
  />
  <PromoInput
    placeholder={'Multiline, Unsecure Text Entry'}
    onChangeText={val => alert('onChangeText called!')}
    handleSubmit={val => alert('handleSubmit called!')}
    handleReturnKey={val => alert('handleReturnKey called!')}
    onBlur={() => console.log('onBlur called!')}
    success={false}
    error={false}
    multiline={true}
    secureTextEntry={false}
    isSubmitting={false}
    autoFocus={false}
    opaque={true}
    numberOfLines={3}
  />
  <PromoInput
    placeholder={'Secure Text Entry'}
    onChangeText={val => alert('onChangeText called!')}
    handleSubmit={val => alert('handleSubmit called!')}
    handleReturnKey={val => alert('handleReturnKey called!')}
    onBlur={() => console.log('onBlur called!')}
    success={false}
    error={true}
    multiline={false}
    secureTextEntry={true}
    isSubmitting={false}
    autoFocus={false}
    opaque={true}
    numberOfLines={1}
  />
  <PromoInput
    placeholder={'Non-Opaque Text Entry'}
    onChangeText={val => alert('onChangeText called!')}
    handleSubmit={val => alert('handleSubmit called!')}
    handleReturnKey={val => alert('handleReturnKey called!')}
    onBlur={() => console.log('onBlur called!')}
    success={false}
    error={true}
    multiline={false}
    secureTextEntry={false}
    isSubmitting={false}
    autoFocus={false}
    opaque={false}
    numberOfLines={1}
  />
  <PromoInput
    placeholder={'Submitting Text Entry'}
    onChangeText={val => alert('onChangeText called!')}
    handleSubmit={val => alert('handleSubmit called!')}
    handleReturnKey={val => alert('handleReturnKey called!')}
    onBlur={() => console.log('onBlur called!')}
    success={false}
    error={true}
    multiline={false}
    secureTextEntry={false}
    isSubmitting={true}
    autoFocus={false}
    opaque={true}
    numberOfLines={1}
  />
</Playground>

## Implementation Notes

The `otherProps` property hasn't been documented yet.

## Properties

<PropsTable of={PromoInput} includeDescription={true} />
