iiagodias / react-native-alerts-help

Complete set of personalized alerts for react native.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

react-native-alerts-help

Atualmente, o desempenho não é testado no IOS.


Minha primeira lib para react-native!

Demostração da lib

Instalação

React-native-alerts-help usa react-native-vector-icons como dependencia.

instalação:

npm install react-native-alerts-help

link:

react-native link

Usage

import Alert from 'react-native-alerts-help';

<Alert
 visible={this.state.warning}
 onPress={() => this.close()}
 icon="warning"
 color="#f1c40f"
 title="Warning.."
 text="Fill in all the fields below."
 textButton="Close"
/>

Props

name type description
visible bool Para que o modal seja visivel.
icon string Nome do icone FontAwesome https://oblador.github.io/react-native-vector-icons/
color string Cor hexadecimal para o botão e icone
title string Texto de titulo
text string Texto do corpo da alerta
textButton string Texto do botão

event:

name type description
onClose function Ao fechar a alerta.
onPress function Quando clica no botão.

About

Complete set of personalized alerts for react native.


Languages

Language:JavaScript 100.0%