New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

rn-modal-picker-awesome

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rn-modal-picker-awesome

Cross Platform [ ios, android ] , Modal Picker Awesome , React Native Component , Full Control for Headers & Options & all Sections

  • 1.1.1
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

React Native Modal Picker Awesome

React Native Modal Picker Component , Enable Single, Multi Selection , auto close Modal
  • The Modal is Smart enough to close automatioc in both [ single, multi ] Selection
  • all section of component is reusable for developer customize
  • hope this help :)
Ios

Installation

make sure you have installed react-native-vector-icons & linked it :) , or install

$ yarn add react-native-vector-icons || npm i --save react-native-vector-icons
Then link
$ react-native link react-native-vector-icons
usage
<Modal
    onSelectOption={(option) => console.log('@option/options', option)}
    modalOptions={[
    {name:'Option 1', value:'1'},
    {name:'Option 2', value:'2'},
    {name:'Option 3', value:'3'},
    {name:'Option 4', value:'4'},
    {name:'Option 5', value:'5'},
    ]}
    visible={this.state.visible}
    autoClose={true}
    multiple={false}
/>
install the package
$ yarn add rn-modal-picker-awesome
or
$ npm i --save rn-modal-picker-awesome

Modal Functions

namepurposeusage
onSelectOptionthis func help to get selected [ option, options] depend on your multiple caseonSelectOption={(option) => console.log('@Option/options ',option)}

Modal Props

namedefaultusagedescriptiontype
visiblefalsevisible={true/false}show/hide Modalbool
multiplefalsemultiple={false/true}if true enable multi select optionsbool
autoClosefalsevisible={false/true}close automatic after select option in case multiple={false} otherwise will close automatice after all options has been selected in case multiple={true}bool
modalOptions[{ name:'Option 1', value: '1' }, ...]modalOptions=[{name:'', value:''},{...},...etc]modal Options Prop must be an array of objects contains name & valuearray
selectedOptionsnullselectedOptions=[{value:'1'},{...}]works only with multiple selection , and this will mark your values as selected ,array
selectedOptionnullselectedOption={{value:'1' }}works only with single selectionObject
animateType'slide'animateType='slide'change modal animation from [ 'slide', 'fade' ]string
modalBackground'#fff'modalBackground='#ccc'change modal background colorstring
modalHeaderBackground'#fff' or modalBackground if changedmodalHeaderBackground='#eee'modal header by default inherit the modalBackground color, but in case you need to change it seperately , do it :)string
closeIconName'ios-close-circle-outline'closeIconName='name-of-icon'this will change your icon , here is list of icons can be used IonicIconsListstring
closeIconText'Close'closeIconText='string'change the close icon textstring
closeIconStyle{}closeIconStyle={{}}overwrite the style of close icon with new styleobject
closeIconTextStyle{}closeIconTextStyle={{}}overwrite the style of close icon text with new styleobject
doneIconName'ios-checkmark-circle-outline'doneIconName='name-of-icon'this will change your icon , here is list of icons can be used IonicIconsListstring
doneIconStyle{}doneIconStyle={{}}overwrite the style of done icon with new styleobject
doneIconTextStyle{}doneIconTextStyle={{}}overwrite the style of done icon text with new styleobject
doneIconText'string'doneIconText='string'change the done icon textstring
titleStyle{}titleStyle={{}}overwrite style of title with new styleobject
titleText'Title Of Modal'titleText='string'change title of headerstring
optionContainerStyle{}optionContainerStyle={{}}change style of option Conatinerobject
optionTextContainerStyle{}optionTextContainerStyle={{}}change style of optionText Viewobject
optionTextStyle{}optionTextStyle={{}}change style of option textobject
optionCircleColor'#4caf50'optionCircleColor='color'change the color of circlestring
optionCircleInnerColor'#4caf50'optionCircleInnerColor='color'inner circle will inherit color from the main circle, but in case want to change , do it :)string

Keywords

FAQs

Package last updated on 14 Jul 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc