scroll_navigation 1.0.0+1
scroll_navigation: ^1.0.0+1 copied to clipboard
It is a navigation by gestures and taps. You can scroll from left to right or tap on the navigation icons.
scroll_navigation #
DEMO #
[]
Features #
- Scrolling pages by gestures.
- Page movement when tapping an icon.
- Indicator that follows the scroll.
- Works with the back button.
- Customizable colors.
Implementation #
return ScrollNavigation(
//DEFAULT VALUES
// initialPage = 0,
// showIdentifier = true,
// identifierPhysics = true,
// activeColor = Colors.blue,
// desactiveColor = Colors.grey,
// backgroundColorBody = Colors.grey[100],
// backgroundColorNav = Colors.white,
// backgroundColorAppBar = Colors.white,
// appBarBrightnessLight = false,
pages: <Widget>[
Container(color: Colors.blue),
Container(color: Colors.green),
Container(color: Colors.amber),
Container(color: Colors.yellow),
Container(color: Colors.lightBlue),
],
navItems: <BottomNavigationBarItem>[
BottomNavigationBarItem(icon: Icon(Icons.camera), title: Text(""));
BottomNavigationBarItem(icon: Icon(Icons.chat), title: Text(""));
BottomNavigationBarItem(icon: Icon(Icons.favorite), title: Text(""));
BottomNavigationBarItem(icon: Icon(Icons.notifications), title: Text(""));
BottomNavigationBarItem(icon: Icon(Icons.home), title: Text(""));
],
);
Identifier Physics #
Demo
identifierPhysics = True | identifierPhysics = False |
---|---|
[] | [] |
Code
return ScrollNavigation(
identifierPhysics = false, //Default is true
pages: <Widget>[],
navItems: <BottomNavigationBarItem>[],
);
Customizable colors #
Demo
[]
Code
return ScrollNavigation(
activeColor = Colors.amber,
desactiveColor = Colors.white,
backgroundColorNav = Colors.black,
backgroundColorAppBar = Colors.red,
pages: <Widget>[],
navItems: <BottomNavigationBarItem>[],
);
More details #
Fixed AppBar | showIdentifier = False |
---|---|
[] | [] |
Fixed AppBar Code
return ScrollNavigation(
appBar: AppBar(title: Text("Scroll Navigation")),
pages: <Widget>[],
navItems: <BottomNavigationBarItem>[],
);
Don't showIdentifier Code
return ScrollNavigation(
showIdentifier = false,
pages: <Widget>[],
navItems: <BottomNavigationBarItem>[],
);