搜索插件、代码仓与 APP 分类

titled_navigation_bar 封面
插件详情v4.1.0

titled_navigation_bar

一个美观、简洁且简单的底部导航栏,点击时具有平滑的动画效果。此包高度可定制,请参阅下方以了解更多信息。

近 30 天下载
193
喜欢数
142
Pub 分数
40

安装插件

flutter pub add titled_navigation_bar

插件介绍

基于插件公开信息、社区数据与项目使用情况整理的选型参考。

一个视觉上吸引人且极简的底部导航栏,选择时具有平滑的动画过渡效果。高度可定制,允许开发者根据应用的设计调整外观和行为。该包专注于简洁美观的视觉效果和直观的用户交互,非常适合注重现代、精致界面的应用。通过简单的 pub 命令即可轻松集成,并且在性能和可用性方面得到了持续维护。

适合场景

  • 需要简洁底部导航栏的移动应用
  • 可自定义的导航体验
  • 专注于视觉美化和用户体验的应用程序
  • 简单而优雅的 UI 组件
  • 带有动画状态变化的导航栏

主要特点

  • 平滑点击动画
  • 高度可定制的设计
  • 极简而干净的美学
  • 与 Flutter 的轻松集成
  • 支持动态标签样式

适合对象

  • 寻求现代导航 UI 的 Flutter 开发者
  • 强调设计一致性的项目
  • 具有多个标签页或部分的应用程序
  • 想要轻量级导航解决方案的开发者
  • 注重设计的移动应用

使用建议

  • 有限的平台特定自定义
  • 无内置图标支持(需要手动设置)
  • 最适合简单的导航模式
  • 可能需要额外的样式来实现复杂布局
  • 未针对非常大的导航集进行优化

原始 README

以下为关联源码仓库的 README 原文快照,最新内容请访问源码仓库。

Pub Awesome Flutter

Titled Bottom Navigation Bar

A beautiful, clean and simple bottom navigation bar with smooth animation on click. This package is high customizable, read more bellow for more details.

You can see the source code of this lib inside the /lib folder.

Show some :heart: and star the repo to support this project

Preview (default mode)

Default Mode Gif

Preview (with reverse mode)

Reversed Mode Gif

Package overview

  • [x] Custom icon color
  • [x] Custom indicator color
  • [x] Support from two to five items
  • [x] Reverse mode (show selected item as icon or title)
  • [x] Option to define custom item background color
  • [x] Use currentIndex property to update the Bar giving a tab position
  • [x] No need setState(...) to update the current index
  • [x] Support RTL TextDirection (thanks to Victor Uvarov)

Getting Started

Follow these steps to use this library

Add the plugin:
dependencies:
  ...
  titled_navigation_bar: ^5.0.0-nullsafety.0
Import the package
import 'package:titled_navigation_bar/titled_navigation_bar.dart';
Adding the widget
bottomNavigationBar: TitledBottomNavigationBar(
  currentIndex: 2, // Use this to update the Bar giving a position
  onTap: (index){
    print("Selected Index: $index");
  },
  items: [
      TitledNavigationBarItem(title: Text('Home'), icon: Icons.home),
      TitledNavigationBarItem(title: Text('Search'), icon: Icons.search),
      TitledNavigationBarItem(title: Text('Bag'), icon: Icons.card_travel),
      TitledNavigationBarItem(title: Text('Orders'), icon: Icons.shopping_cart),
      TitledNavigationBarItem(title: Text('Profile'), icon: Icons.person_outline),
  ]
)

Customization (Optional)

TitledBottomNavigationBar

onTap - Use this to get notified when an item is clicked, you can retrieve the current item's index on this function. Should not be null!
items - The items of your bottom navigation bar. Use the TitledNavigationBarItem class to add items. Should not be null!
curve - Use this to define your custom curve animation. Should not be null!
reverse - If true, the visible widget of the selected item will be the Text (with the title of the item). If false, the visible widget of the selected item will be the icon. Default to false
activeColor - The active Text/Icon color. The default color is the indicatorColor of your app Theme.
inactiveColor - The inactive Text/Icon color. The default is the black color.
indicatorColor - The indicator color. The default color is the indicatorColor of your app Theme.
currentIndex - Use this to update the Bar giving a position.
enableShadow - Use this to remove the NavigationBar's shadow

TitledNavigationBarItem

icon -The icon of this item. This will be used as default state if reverse mode is disabled
title - The title of this item. This will be used as default state if reverse mode is enabled

所属分类

源码仓库

使用此插件的项目