패키지, 저장소 및 앱 카테고리 검색

GitHub 저장소ajomuch92/rolling-bottom-bar-flutter

롤링 바텀바-플러터

ajomuch92/rolling-bottom-bar-flutter open-source repository details.

롤링 바텀바-플러터 프로젝트 이미지
스타
4
포크
3
최근 푸시(UTC)
2021. 6. 6.
프로젝트 상태
활성

원본 README

아래는 영문 원문 스냅샷입니다. 최신 내용은 GitHub에서 확인하세요.

Rolling Bottom Bar

This packages, based on this demo by Kabo showing a bottom bar with a dynamic ball indicator.

New Features 💥
  • Capability to avoid the bottom bar shadow by flat property on false
  • Setting active color by each item define on color property of RollingBottomBarItem widget

Demo

Instalation

Include rolling_bottom_bar in your pubspec.yaml file:

dependencies:
  flutter:
    sdk: flutter
  rolling_bottom_bar: version

Usage

To use this package, just import it into your file, build your bottom bar together with a PageView and enjoy it.

import 'package:rolling_bottom_bar/rolling_bottom_bar.dart';
import 'package:rolling_bottom_bar/rolling_bottom_bar_item.dart';

...

@override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text('Rolling Bottom Bar'),
      ),
      body: PageView(
        controller: _controller,
        children: <Widget>[
          ColoredBox(color: Colors.blueGrey.shade100),
          ColoredBox(color: Colors.redAccent),
          ColoredBox(color: Colors.greenAccent),
          ColoredBox(color: Colors.yellowAccent),
        ],
      ),
      extendBody: true,
      bottomNavigationBar: RollingBottomBar(
        controller: _controller,
        items: [
          RollingBottomBarItem(Icons.home, label: 'Page 1'),
          RollingBottomBarItem(Icons.star, label: 'Page 2'),
          RollingBottomBarItem(Icons.person, label: 'Page 3'),
          RollingBottomBarItem(Icons.access_alarm, label: 'Page 4'),
        ],
        activeItemColor: Colors.green.shade700,
        enableIconRotation: true,
        onTap: (index) {
          _controller.animateToPage(
            index,
            duration: const Duration(milliseconds: 400),
            curve: Curves.easeOut,
          );
        },
      ),
    );
  }
}

...

Options for Rolling Bottom Bar Item use

Name Description Required Default
iconData IconData to use as item icon True
label String to use as label item False
activeColor Color to use when icon is active. Only works with useActiveColorByDefault property of RollingBottomBarItem set on true False Colors.green

Options for Rolling Bottom Bar use

Name Description Required Default
controller PageView controller to use to move between pages True
items List of RollingBottomBarItem to render into bottom bar True
onTap Function triggered when an item is tapped True
color Color value to use as background False Colors.white
itemColor Color value to use with inactive items False Colors.grey[700]
activeItemColor Color value to use with active items False Colors.green
enableIconRotation Boolean value to indicate when rotation effect is triggered False false
flat Boolean value to indicate if the bottom bar has shadow or not False false
useActiveColorByDefault Boolean value to indicate when to use individual active color for each child False true
Aarón J. Montes GitHub avatar
GitHub 작성자

Aarón J. Montes ↗

System Engineer/Software developer

KSSComayagua, Honduras공식 웹사이트 ↗
언어DartSwiftKotlinObjective-C

이 저장소가 배포한 패키지

사용 중인 의존성

의존성 목록 2 개

  • flutter{"sdk":"flutter"}
  • flutter_test개발 의존성{"sdk":"flutter"}

프로젝트에 맞는 저장소를 선택하려면?

사용 목적에 따라 검색하고 개발 활동을 비교한 뒤 원본 저장소에서 요구 사항을 확인하세요.

  1. 이름, 작성자 또는 설명으로 검색하고 기술 주제로 범위를 좁힙니다.
  2. 스타, 포크, 최근 푸시를 함께 비교하세요. 스타는 관심의 지표이며 품질을 보장하지 않습니다.
  3. 사용하기 전에 GitHub에서 README, 라이선스, Issues를 확인하세요.

출처 및 관리

“A repository is the most basic element of GitHub.”

GitHub Docs — About repositories ↗