{"id":13792016,"url":"https://github.com/leocavalcante/page_view_indicator","last_synced_at":"2025-04-09T15:08:26.191Z","repository":{"id":37384994,"uuid":"141769224","full_name":"leocavalcante/page_view_indicator","owner":"leocavalcante","description":"👆🏻 Builds indication marks for PageView.","archived":false,"fork":false,"pushed_at":"2021-11-03T04:07:24.000Z","size":621,"stargazers_count":164,"open_issues_count":4,"forks_count":28,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-09T15:08:21.127Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/leocavalcante.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-07-21T00:36:16.000Z","updated_at":"2024-03-25T22:05:14.000Z","dependencies_parsed_at":"2022-09-09T19:10:24.074Z","dependency_job_id":null,"html_url":"https://github.com/leocavalcante/page_view_indicator","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leocavalcante%2Fpage_view_indicator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leocavalcante%2Fpage_view_indicator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leocavalcante%2Fpage_view_indicator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leocavalcante%2Fpage_view_indicator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/leocavalcante","download_url":"https://codeload.github.com/leocavalcante/page_view_indicator/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248055283,"owners_count":21040157,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-03T22:01:06.988Z","updated_at":"2025-04-09T15:08:26.174Z","avatar_url":"https://github.com/leocavalcante.png","language":"Dart","funding_links":[],"categories":["组件","Components","Navigation [🔝](#readme)"],"sub_categories":["导航","Navigation"],"readme":"# PageViewIndicator [![Pub Package](https://img.shields.io/pub/v/page_view_indicator.svg)](https://pub.dartlang.org/packages/page_view_indicator)\nBuilds indication marks for PageView.\n\n## Import\n```dart\nimport 'package:page_view_indicator/page_view_indicator.dart';\n```\n\n## Usage\n\n### Default Material behavior\n```dart\nreturn PageViewIndicator(\n  pageIndexNotifier: pageIndexNotifier,\n  length: length,\n  normalBuilder: (animationController, index) =\u003e Circle(\n        size: 8.0,\n        color: Colors.black87,\n      ),\n  highlightedBuilder: (animationController, index) =\u003e ScaleTransition(\n        scale: CurvedAnimation(\n          parent: animationController,\n          curve: Curves.ease,\n        ),\n        child: Circle(\n          size: 12.0,\n          color: Colors.black45,\n        ),\n      ),\n);\n```\n![Example 1](example1.gif)\n\n---\n\n### Custom animations\n```dart\nreturn PageViewIndicator(\n  pageIndexNotifier: pageIndexNotifier,\n  length: length,\n  normalBuilder: (animationController, index) =\u003e Circle(\n        size: 8.0,\n        color: Colors.black87,\n      ),\n  highlightedBuilder: (animationController, index) =\u003e ScaleTransition(\n        scale: CurvedAnimation(\n          parent: animationController,\n          curve: Curves.ease,\n        ),\n        child: Circle(\n          size: 8.0,\n          color: Colors.white,\n        ),\n      ),\n);\n```\n![Example 2](example2.gif)\n\n---\n\n### Custom icons\nIt's not just about dots!\n```dart\nreturn PageViewIndicator(\n  pageIndexNotifier: pageIndexNotifier,\n  length: length,\n  normalBuilder: (animationController, index) =\u003e ScaleTransition(\n        scale: CurvedAnimation(\n          parent: animationController,\n          curve: Curves.ease,\n        ),\n        child: Icon(\n          Icons.favorite,\n          color: Colors.black87,\n        ),\n      ),\n  highlightedBuilder: (animationController, index) =\u003e ScaleTransition(\n        scale: CurvedAnimation(\n          parent: animationController,\n          curve: Curves.ease,\n        ),\n        child: Icon(\n          Icons.star,\n          color: Colors.white,\n        ),\n      ),\n);\n```\n![Example 3](example3.gif)\n\n### Changing the space bettwen the indicators\n\nYou can change the padding around the indicators using the `indicatorPadding` property:\n\n```dart\nreturn PageViewIndicator(\n  pageIndexNotifier: pageIndexNotifier,\n  length: length,\n  indicatorPadding: const EdgeInsets.all(4.0)\n  ...\n```\n\nDefault is `const EdgeInsets.all(8.0)`.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleocavalcante%2Fpage_view_indicator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fleocavalcante%2Fpage_view_indicator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleocavalcante%2Fpage_view_indicator/lists"}