text_tab_bar 0.1.0 copy "text_tab_bar: ^0.1.0" to clipboard
text_tab_bar: ^0.1.0 copied to clipboard

Flutter package that implements a minimalistic tabbar widget with animated text

TextTabBar #

TextTabBar is an open-source Flutter package that provides a customizable tabbar where each element is an animated text. This will allow you to use a minimalistic and agreeable tab bar for your users.

Features #

  • 📱 The behavior completely copies the behavior of the native tabbar;
  • 🎨 Fully customizable styles for elements;
  • ✈️ Various and smooth transition animations;
  • 🐚 Simple and easy to use configuration.

Getting started #

To use TextTabBar in your Flutter project, follow these steps:

  1. Add the dependency to your pubspec.yaml file:
dependencies:
  flutter:
    sdk: flutter
  text_tab_bar: ^0.1.0
  1. Run flutter pub get to install the package.

Usage #

Import the package in your Dart file and customize the tab bar according to your needs:

Basic usage
DefaultTabController(
  length: ...,
  child: Builder(
    builder: (context) {
      final tabController = DefaultTabController.of(context);
      return Column(
        children: [
          TextTabBar(
            controller: tabController,
            tabs: ...
          ),
          Expanded(
            child: TabBarView(
              controller: tabController,
              children: ...
            ),
          ),
        ],
      );
    },
  ),
)

Сustomizable text styles

You can override the default text styles to one that suits you better, for example like this:

Customizable text
TextTabBar(
  ...,
  selectedTextStyle: TextStyle(
    color: Colors.red,
    fontSize: 24.0,
  ),
  unselectedTextStyle: TextStyle(
    color: Colors.green,
    fontSize: 18.0,
  ),
)










Floating animation

You can use a floating animation that will look like a wave, flowing from one element to another:

Floating animation
TextTabBar(
  ...,
  isFloatingAnimation: true,
)















Decorator

If you additionally want to customize the item, you can use a decorator:

Decorator
TextTabBar(
  ...,
  decorator: (index, child) {
    if (index % 3 != 0) {
      return child;
    }

    return Stack(
      children: [
        child,
        ColoredBadge(color: Colors.red),
      ],
    );
  },
)






License #

This package is licensed under the MIT License. For more information, see the LICENSE.md file.

Additional information #

For more information, visit the TextTabBar GitHub repository.

1
likes
145
points
3
downloads

Publisher

unverified uploader

Weekly Downloads

Flutter package that implements a minimalistic tabbar widget with animated text

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (license)

Dependencies

flutter

More

Packages that depend on text_tab_bar