A Flutter Widget for an AppBar that is initially flush with the body and elevated when scrolled

Overview

appbar_elevation

pub package

A Flutter Widget for an AppBar that is initially flush with the body and elevated when scrolled.

Usage

Use the ScrollActivatedAppBarElevation widget to wrap a Scaffold that contains a Scrollable view (e.g. ListView, CustomScrollView). The widget uses a NotificationListener to detect the scroll position and provides an appBarElevation value to be used.

Example

@override
Widget build(BuildContext context) {
  return ScrollActivatedAppBarElevation(
    builder: (BuildContext context, double appBarElevation) {
      return Scaffold(
        appBar: AppBar(
          elevation: appBarElevation,
        ),
        body: ListView(
          children: [
            // ...
          ],
        ),
      );
    },
  );
}

See example for full code.

License

BSD

You might also like...

Hack&Heal hybrid hackathon 2022 - Body & Mind topic

Hack&Heal hybrid hackathon 2022 - Body & Mind topic

Meditation App Hack&Heal hybrid hackathon 2022 - Body & Mind topic The MVP is available for mobile browsers here. The Problem 3.6 million citizens hav

Jun 19, 2022

Widget to count the amount of nested widget tree, useful in the dynamic construction of the interface when it is important to know the depth of widget.

Widget to count the amount of nested widget tree, useful in the dynamic construction of the interface when it is important to know the depth of widget.

widget_tree_depth_counter Widget Tree Depth Counter WidgetTreeDepthCounter is a simple widget to count the amount of nested widget tree, useful in the

Aug 1, 2022

Custom dropdown widget allows to add highly customizable widget in your projects with proper open and close animations and also comes with form required validation.

Custom dropdown widget allows to add highly customizable widget in your projects with proper open and close animations and also comes with form required validation.

Custom Dropdown Custom Dropdown package lets you add customizable animated dropdown widget. Features Lots of properties to use and customize dropdown

Dec 29, 2022

A customizable carousel slider widget in Flutter which supports inifinte scrolling, auto scrolling, custom child widget, custom animations and built-in indicators.

A customizable carousel slider widget in Flutter which supports inifinte scrolling, auto scrolling, custom child widget, custom animations and built-in indicators.

flutter_carousel_widget A customizable carousel slider widget in Flutter. Features Infinite Scroll Custom Child Widget Auto Play Horizontal and Vertic

Nov 26, 2022

A Flutter widget to show an icon collection to pick. This widget extend TextField and has a similar behavior as TextFormField

A Flutter widget to show an icon collection to pick. This widget extend TextField and has a similar behavior as TextFormField

icon_picker A Flutter widget to show an icon collection to pick. This widget extend TextField and has a similar behavior as TextFormField Usage In the

Sep 27, 2022

A new Flutter project. Use of Padding Class(Widget) and Card Class (Widget)

A new Flutter project. Use of Padding Class(Widget) and Card Class (Widget)

Use_Of_Card_And_Padding_Class A new Flutter project. Use of Padding Class(Widget) and Card Class (Widget) Getting Started This project is a starting p

Mar 18, 2022

Iridium-reader-widget - Plug and play reader widget allowing to easily integrate an Iridium viewer inside any app

Plug and play reader widget allowing to easily integrate an Iridium viewer insid

Dec 31, 2022

A simple detailed flutter widget that looks almost the same as the real instagram mention widget.

A simple detailed flutter widget that looks almost the same as the real instagram mention widget.

Instagram Mention Widgets 'small details do matter' ❤️ This package provides simple and almost the same UI details that the real Instagram mention wid

Oct 10, 2022
Comments
  • Items flickering on scroll, use SliverAppBar with scrolledUnderElevation instead

    Items flickering on scroll, use SliverAppBar with scrolledUnderElevation instead

    You can use SliverAppBar with scrolledUnderElevation instead of this package.

    Example code:

      CustomScrollView(
          slivers: [
            const SliverAppBar(
              title: Text('Dynamic elevation'),
              pinned: true,
              scrolledUnderElevation: 20,
            ),
            SliverList(
              delegate: SliverChildBuilderDelegate(
                (_, int index) {
                  return ListTile(
                    title: Text(index.toString()),
                  );
                },
                childCount: 20,
              ),
            ),
          ],
        );
    
    opened by maherjaafar 0
  • Migrate to null-safety

    Migrate to null-safety

    Currently this library can't be used with Flutter 2.5.0:

    Error: Cannot run with sound null safety, because the following dependencies
        don't support null safety:
         - package:appbar_elevation
    

    This PR migrates code to null-safety. To support it, Dart min version requirement should be 2.12.0.

    opened by devslava 3
Owner
Amit Kotlovski
Amit Kotlovski
A widget that can be dragged and scrolled in a single gesture and snapped to a list of extents.

Sliding Sheet A widget that can be dragged and scrolled in a single gesture and snapped to a list of extents. Click here to view the full example. Ins

null 394 Mar 3, 2022
(mostly) Automatic search-enabled appBar for flutter

flutter_search_bar A simple and mostly automatic material search bar for flutter (dart). Note: use flutter_search_bar and not search_bar -- I own both

Spencer 266 Dec 31, 2022
Flutter Bidirectional ListView - ListView with items that can be scrolled in both directions with a fixed item count and scroll boundaries.

Flutter Bidirectional ListView ListView with items that can be scrolled and lazy loaded in up and down direction with a fixed item count and scroll bo

Christoph Rothermel 7 May 30, 2022
Flutterbodydetection - A flutter plugin that uses MLKit on iOS/Android platforms to enable body pose and mask detection using Pose Detection and Selfie Segmentation APIs for both static images and live camera stream.

body_detection A flutter plugin that uses MLKit on iOS/Android platforms to enable body pose and mask detection using Pose Detection and Selfie Segmen

null 18 Dec 5, 2022
AMURoboclub is the official app of AMURoboclub, a student body of ZHCET that nurtures the needs of curious and innovative minds

AMURoboclub is the official app of AMURoboclub, a student body of ZHCET that nurtures the needs of curious and innovative minds. It is the nerve center of robotics enthusiasts who are curious and innovative and wish to come together to learn and share. With the motto 'Where Innovation Meets Implementation', it endeavors to ignite young minds with the fuel of robotics. Enabling that, the app ensures to acquaint its users with the various activities and achievements of AMURoboclub.

AMU Roboclub 9 Dec 6, 2022
Bmi calculator flutter - Calculate your BMI(Body Mass Index) with this app made with flutter.

bmi_calculator_flutter A new Flutter project. Getting Started This project is a starting point for a Flutter application. A few resources to get you s

Joel Nickson 1 Jan 2, 2022
It is a body mass index calculator made using flutter.

Body Mass Index (BMI) What is it? This is a flutter project. Basically this a Body Mass Index (BMI) calculator. I made this for practice purpose. The

null 1 Dec 11, 2021
BMI Calcaluator - Flutter app to calculate Body mass index (BMI)

flutter_learn A new Flutter application. Getting Started This project is a starting point for a Flutter application. A few resources to get you starte

Ahmed Abdultawab 0 Jan 3, 2022
BMI Calculator - A Body Mass Index Calculator inspired by the beautiful user interface designs.

BMI Calculator A Body Mass Index Calculator inspired by the beautiful user interface designs. A multi screen app with simple functionality but full-on

Vedant Karale 0 Dec 2, 2021
Body-mass index calculator.

bmi_calculator An body mass index calculator app. Getting Started This project is a starting point for a Flutter application. A few resources to get y

Thiago Geronimo 1 Jan 10, 2022