Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

rn-progress-loader

Package Overview
Dependencies
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

rn-progress-loader

The React Native Native iOS and Android progress indicator (spinner) which acts like an overlay. For those who have issues in iPhoneX while using both Modal and ActivityIndicator, I've made it optional

  • 1.0.7
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
65
decreased by-61.08%
Maintainers
1
Weekly downloads
 
Created
Source

rn-progress-loader

npm version MIT License

The React Native Native iOS and Android progress indicator (spinner) which acts like an overlay. For those who have issues in iPhoneX while using both Modal and ActivityIndicator, you can use normal View with some options.

See index.js for example usage

Demo

rn-progress-loader-android rn-progress-loader-ios rn-progress-loader-android-nohud rn-progress-loader-ios-nohud

Install

npm install --save rn-progress-loader

How to use

This shows the default properties.

PropertyTypeDefaultRequiredDescription
visiblebooleanfalseYESTo change the visibility of loader
isModalbooleanfalseYESChoose if you want Modal View or normal view
colorstring#FFFFFFNOColor of the loading indicator
isHUDboolfalseNOMBProgressHUD like style. Only available if isModal=true
hudColorstring#FFFFFFNOColor of rounded rectangle container. Only available if isModal=true
barHeightnumber64NOThis is an exceptional property if you are not using Modal (ie, isModal=false), This will adjust the indicator position based on app's actionbar height

import React, { View } from 'react-native';
import ProgressLoader from 'rn-progress-loader';

class ComponentClass extends React.Component {

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

    componentDidMount() {
        var self = this;
        setInterval(() => {
            self.setState({
                visible: !this.state.visible
            });
        }, 5000);
    }


    render() {
        return (
            <View
                style={{backgroundColor: "#06566e", justifyContent: 'center', alignItems: 'center', flex: 1}}>

                <ProgressLoader
                visible={this.state.visible}
                isModal={true} isHUD={true}
                hudColor={"#000000"}
                color={"#FFFFFF"} />
            </View>
        )
    }
}

Contributors

License

GPL

Keywords

FAQs

Package last updated on 05 May 2019

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