パッケージ、リポジトリ、アプリカテゴリを検索

curved_navigation_bar のカバー
パッケージ詳細v1.0.6

curved_navigation_bar

印象的なアニメーションカーブ形状ナビゲーションバー。色、背景色、アニメーションカーブ、アニメーション期間を調整可能。

AndroidiOSWebmacOSWindowsLinux
30日間ダウンロード
1.6万
いいね数
2100
Pub ポイント
160

パッケージをインストール

flutter pub add curved_navigation_bar

パッケージ概要

公開情報に基づく選定ガイドです。参考としてご利用ください。

Flutterアプリ用の視覚的に魅力的でアニメーション付きのカーブナビゲーションバーです。カスタマイズ可能な色、背景トーン、アニメーションカーブ、および期間設定により、ダイナミックでモダンな下部ナビゲーション体験を実現します。タブ間のスムーズな遷移を備えたユニークで流れるようなインターフェースを求めるアプリに最適です。このパッケージはAndroid、iOS、Web、macOS、Windows、Linuxなど複数のプラットフォームをサポートしています。

用途

  • カスタムアプリインターフェース
  • モダンなUIデザイン
  • アニメーション付きのボトムナビゲーション
  • クロスプラットフォームモバイルアプリ
  • インタラクティブなタブ切り替え
  • 強化されたユーザー体験

主な機能

  • アニメーション可能なカーブ形状
  • カスタマイズ可能な色
  • 調整可能なアニメーションカーブ
  • アニメーションの持続時間のカスタマイズ
  • マルチプラットフォーム対応
  • スムーズなトランジション効果

適している対象

  • デザイン重視のFlutter開発者
  • 独自のナビゲーションを必要とするアプリ
  • モダンなUI美学を持つプロジェクト
  • クロスプラットフォームアプリケーションビルダー
  • アニメーションコンポーネントを希望する開発者

注意事項

  • 低スペックデバイスでのパフォーマンスに影響を与える可能性があります
  • 視覚的特性を超えるカスタマイズは限られている
  • 複数のプラットフォームで慎重なテストが必要です
  • アニメーションはすべてのアプリスタイルに適しているとは限りません
  • シンプルなナビゲーションのニーズには適していません

元の README

関連するソースリポジトリの README 原文のスナップショットです。最新の内容はリポジトリをご覧ください。

curved_navigation_bar

pub package

A Flutter package for easy implementation of curved navigation bar.

Gif

Add dependency
dependencies:
  curved_navigation_bar: ^1.0.6 #latest version
Easy to use
Scaffold(
  bottomNavigationBar: CurvedNavigationBar(
    backgroundColor: Colors.blueAccent,
    items: <Widget>[
      Icon(Icons.add, size: 30),
      Icon(Icons.list, size: 30),
      Icon(Icons.compare_arrows, size: 30),
    ],
    onTap: (index) {
      //Handle button tap
    },
  ),
  body: Container(color: Colors.blueAccent),
)
Attributes

items: List of Widgets
index: index of NavigationBar, can be used to change current index or to set initial index
color: Color of NavigationBar, default Colors.white
buttonBackgroundColor: background color of floating button, default same as color attribute
backgroundColor: Color of NavigationBar's background, default Colors.blueAccent
onTap: Function handling taps on items
animationCurve: Curves interpolating button change animation, default Curves.easeOutCubic
animationDuration: Duration of button change animation, default Duration(milliseconds: 600)
height: Height of NavigationBar, min 0.0, max 75.0
maxWidth: Allows to set the width of the navigation bar lower than the entire screen width by default
letIndexChange: Function which takes page index as argument and returns bool. If function returns false then page is not changed on button tap. It returns true by default\

Change page programmatically
 //State class
  int _page = 0;
  GlobalKey<CurvedNavigationBarState> _bottomNavigationKey = GlobalKey();

  @override
  Widget build(BuildContext context) {
    return Scaffold(
        bottomNavigationBar: CurvedNavigationBar(
          key: _bottomNavigationKey,
          items: <Widget>[
            Icon(Icons.add, size: 30),
            Icon(Icons.list, size: 30),
            Icon(Icons.compare_arrows, size: 30),
          ],
          onTap: (index) {
            setState(() {
              _page = index;
            });
          },
        ),
        body: Container(
          color: Colors.blueAccent,
          child: Center(
            child: Column(
              children: <Widget>[
                Text(_page.toString(), textScaleFactor: 10.0),
                ElevatedButton(
                  child: Text('Go To Page of index 1'),
                  onPressed: () {
                    //Page change using state does the same as clicking index 1 navigation button
                    final CurvedNavigationBarState? navBarState =
                        _bottomNavigationKey.currentState;
                    navBarState?.setPage(1);
                  },
                )
              ],
            ),
          ),
        ));
  }

カテゴリー

依存関係

依存関係一覧 1 件

ソースリポジトリ

このパッケージを使用しているプロジェクト