react-native-instagram-like-picker

1.0.2 • Public • Published

react-native-instagram-like-picker

Pick the image like instagram and manupulate it.

Installation

npm install react-native-instagram-like-picker

Basic Usage

import React from 'react';
import { View } from 'react-native';
import { InstagramLikePicker } from 'react-native-instagram-like-picker';

class UploadFiles extends React.Component {

    constructor(props) {
        super(props);
        this.state = {};
    }

    onSelectImage = (data) => {
        console.log('onSelectImage =>', data);
    }

    onCropped = (data) => {
        console.log('onCropped =>', data);
    }

    onClose = () => {
        console.log('onClose');
    }

    render() {
        return (
            <View style={{ flex: 1, backgroundColor: '#000000' }}>
                <InstagramLikePicker
                    onClose={()=>this.onClose()}
                    onCropped={(croppedUri) => this.onCropped(croppedUri)}
                    onSelectImage={(result) => this.onSelectImage(result)}
                    headerTitle="Last Post"
                />
            </View>
        )
    }
}

Props

Parameter type required default description
onClose function Yes this will call onclick of cross icon
onCropped function js (selectUrl)=>{} No this function return the cropped image url
onSelectImage function js (selectUrl)=>{} No call on changing image selection
headerTitle string No New Post Header Title

Contributing

See the contributing guide to learn how to contribute to the repository and the development workflow.

License

MIT

Package Sidebar

Install

npm i react-native-instagram-like-picker

Weekly Downloads

18

Version

1.0.2

License

MIT

Unpacked Size

70.8 kB

Total Files

15

Last publish

Collaborators

  • amitpanday