Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How can we put some customized page indicator #138

Open
MahmoodBakhshayesh opened this issue May 7, 2018 · 1 comment
Open

How can we put some customized page indicator #138

MahmoodBakhshayesh opened this issue May 7, 2018 · 1 comment

Comments

@MahmoodBakhshayesh
Copy link

hi , how can we put a customized page indicator such as something like 1/30 which shows we are in page 1 from 30 total ,
or some sort of loading bar which full by going forward or some progress bar

@tonycoco
Copy link

You can create your own component, let's say something like a ProgressBar component and then feed it a width or complete % with a state param...

<IndicatorViewPager onPageSelected={this.yourOnPageSelected} ...>
...

yourOnPageSelected = (params) => {
  this.setState({
    progress: ((params.position + 1) / numOfSteps),
  });
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants