persistent_bottom_nav_bar_v2 5.0.0-beta.1 copy "persistent_bottom_nav_bar_v2: ^5.0.0-beta.1" to clipboard
persistent_bottom_nav_bar_v2: ^5.0.0-beta.1 copied to clipboard

outdated

A do all, highly customizable persistent/static bottom navigation bar for flutter. Includes up-to 20 styles. Based on persistent_bottom_nav_bar which currently is not continued.

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:persistent_bottom_nav_bar_v2/persistent_bottom_nav_bar_v2.dart';
import 'package:persistent_bottom_nav_bar_v2_example_project/interactive_example.dart';
import 'package:persistent_bottom_nav_bar_v2_example_project/screens.dart';

void main() => runApp(PersistenBottomNavBarDemo());

class PersistenBottomNavBarDemo extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Persistent Bottom Navigation Bar Demo',
      home: InteractiveExample(),
      routes: {
        // When navigating to the "/first" route, build the FirstScreen widget.
        '/first': (context) => MainScreen2(),
        // When navigating to the "/second" route, build the SecondScreen widget.
        '/second': (context) => MainScreen3(),
      },
    );
  }
}

class MinimalExample extends StatelessWidget {
  MinimalExample({Key key}) : super(key: key);

  List<PersistentTabConfig> _tabs() {
    return [
      PersistentTabConfig(
        screen: MainScreen(),
        item: ItemConfig(
          icon: Icon(Icons.home),
          title: "Home",
        ),
      ),
      PersistentTabConfig(
        screen: MainScreen(),
        item: ItemConfig(
          icon: Icon(Icons.message),
          title: "Messages",
        ),
      ),
      PersistentTabConfig(
        screen: MainScreen(),
        item: ItemConfig(
          icon: Icon(Icons.settings),
          title: "Settings",
        ),
      ),
    ];
  }

  @override
  Widget build(BuildContext context) {
    return PersistentTabView(
      tabs: _tabs(),
      navBarBuilder: (navBarConfig) => Style1BottomNavBar(
        navBarConfig: navBarConfig,
        navBarDecoration: NavBarDecoration(
          color: Colors.white,
        ),
      ),
    );
  }
}
350
likes
0
pub points
98%
popularity

Publisher

unverified uploader

A do all, highly customizable persistent/static bottom navigation bar for flutter. Includes up-to 20 styles. Based on persistent_bottom_nav_bar which currently is not continued.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter

More

Packages that depend on persistent_bottom_nav_bar_v2