{"id":21748394,"url":"https://github.com/surfstudio/flutter-bottom-navigation-bar","last_synced_at":"2025-07-19T00:32:01.040Z","repository":{"id":46413834,"uuid":"384332822","full_name":"surfstudio/flutter-bottom-navigation-bar","owner":"surfstudio","description":null,"archived":true,"fork":false,"pushed_at":"2023-04-20T13:15:08.000Z","size":93,"stargazers_count":5,"open_issues_count":1,"forks_count":0,"subscribers_count":5,"default_branch":"main","last_synced_at":"2025-03-29T19:22:20.061Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/surfstudio.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2021-07-09T05:37:54.000Z","updated_at":"2024-04-08T13:24:11.000Z","dependencies_parsed_at":"2022-09-23T00:31:57.172Z","dependency_job_id":null,"html_url":"https://github.com/surfstudio/flutter-bottom-navigation-bar","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/surfstudio/flutter-bottom-navigation-bar","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/surfstudio%2Fflutter-bottom-navigation-bar","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/surfstudio%2Fflutter-bottom-navigation-bar/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/surfstudio%2Fflutter-bottom-navigation-bar/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/surfstudio%2Fflutter-bottom-navigation-bar/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/surfstudio","download_url":"https://codeload.github.com/surfstudio/flutter-bottom-navigation-bar/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/surfstudio%2Fflutter-bottom-navigation-bar/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":265863727,"owners_count":23840883,"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-11-26T08:13:20.467Z","updated_at":"2025-07-19T00:32:00.798Z","avatar_url":"https://github.com/surfstudio.png","language":"Dart","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Bottom Navigation Bar\n\n[![Build Status](https://shields.io/github/workflow/status/surfstudio/SurfGear/build?logo=github\u0026logoColor=white)](https://github.com/surfstudio/SurfGear/tree/main/packages/bottom_navigation_bar)\n[![Coverage Status](https://img.shields.io/codecov/c/github/surfstudio/SurfGear?flag=bottom_navigation_bar\u0026logo=codecov\u0026logoColor=white)](https://codecov.io/gh/surfstudio/SurfGear)\n[![Pub Version](https://img.shields.io/pub/v/bottom_navigation_bar?logo=dart\u0026logoColor=white)](https://pub.dev/packages/bottom_navigation_bar)\n[![Pub Likes](https://badgen.net/pub/likes/bottom_navigation_bar)](https://pub.dev/packages/bottom_navigation_bar)\n[![Pub popularity](https://badgen.net/pub/popularity/bottom_navigation_bar)](https://pub.dev/packages/bottom_navigation_bar/score)\n![Flutter Platform](https://badgen.net/pub/flutter-platform/bottom_navigation_bar)\n\nThis package made by [Surf](https://surf.ru).\n\n## About\n\nBottom navigation bar\n\n## Description\n\nMain classes:\n\n1. [Bottom navigator](lib/src/bottom_navigator.dart)\n2. [Bottom navigator bar](lib/src/bottom_nav_bar.dart)\n3. [Type of tab](lib/src/bottom_nav_tab_type.dart)\n4. [Relation between item in bar and content](lib/src/bottom_navigation_relationship.dart)\n\n## Example\n\nThe easiest interaction with the library is as follows:\n\n1. Initialize:\n\n```dart\nfinal _selectorController = StreamController\u003cBottomNavTabType\u003e.broadcast();\n\nlate List\u003cBottomNavTabType\u003e _types;\nlate Map\u003cBottomNavTabType, BottomNavigationRelationship\u003e _map;\n\nvar _isCustom = true;\n\n@override\nvoid initState() {\n  super.initState();\n\n  _types = const [\n    BottomNavTabType(0),\n    BottomNavTabType(1),\n    BottomNavTabType(2),\n  ];\n\n  _map = {\n    _types[0]: BottomNavigationRelationship(\n      tabBuilder: () =\u003e _buildPage(const Color(0xFFFF0000)),\n      navElementBuilder: (isSelected) =\u003e _buildElement(\n        isSelected,\n        const Color(0x55FF0000),\n      ),\n    ),\n    _types[1]: BottomNavigationRelationship(\n      tabBuilder: () =\u003e _buildPage(const Color(0xFF00FF00)),\n      navElementBuilder: (isSelected) =\u003e _buildElement(\n        isSelected,\n        const Color(0x5500FF00),\n      ),\n    ),\n    _types[2]: BottomNavigationRelationship(\n      tabBuilder: () =\u003e _buildPage(const Color(0xFF0000FF)),\n      navElementBuilder: (isSelected) =\u003e _buildElement(\n        isSelected,\n        const Color(0x550000FF),\n      ),\n    ),\n  };\n\n  _selectorController.stream.listen((type) =\u003e print(type.value));\n}\n```\n\n1. Display:\n\n```dart\n@override\nWidget build(BuildContext context) {\n  return Scaffold(\n    body: Container(\n      child:\n          _isCustom ? _buildBottomNavigator() : _buildCustomBottomNavigator(),\n    ),\n  );\n}\n\nBottomNavigator _buildBottomNavigator() {\n  return BottomNavigator(\n    key: UniqueKey(),\n    initialTab: _types[0],\n    tabsMap: _map,\n    selectController: _selectorController,\n  );\n}\n\nBottomNavigator _buildCustomBottomNavigator() {\n  return BottomNavigator.custom(\n    key: UniqueKey(),\n    tabsMap: _map,\n    initialTab: _types[0],\n    bottomNavBar: _buildNavBar(),\n    selectController: _selectorController,\n  );\n}\n```\n\n## BottomNavigator\n\nWidget for simple switch content by selected item in bottom bar.\nMore details of using you can see in example.\n\n## Installation\n\nAdd `bottom_navigation_bar` to your `pubspec.yaml` file:\n\n```yaml\ndependencies:\n  bottom_navigation_bar: ^1.0.0\n```\n\nYou can use both `stable` and `dev` versions of the package listed above in the badges bar.\n\n## Changelog\n\nAll notable changes to this project will be documented in [this file](./CHANGELOG.md).\n\n## Issues\n\nFor issues, file directly in the Issues section.\n\n## Contribute\n\nIf you would like to contribute to the package (e.g. by improving the documentation, solving a bug or adding a cool new feature), please review our [contribution guide](../../CONTRIBUTING.md) first and send us your pull request.\n\nYour PRs are always welcome.\n\n## How to reach us\n\nPlease feel free to ask any questions about this package. Join our community chat on Telegram. We speak English and Russian.\n\n[![Telegram](https://img.shields.io/badge/chat-on%20Telegram-blue.svg)](https://t.me/SurfGear)\n\n## License\n\n[Apache License, Version 2.0](https://www.apache.org/licenses/LICENSE-2.0)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsurfstudio%2Fflutter-bottom-navigation-bar","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsurfstudio%2Fflutter-bottom-navigation-bar","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsurfstudio%2Fflutter-bottom-navigation-bar/lists"}