Search categories, packages and repositories

flutter_fader cover
Package detailsv2.0.1

flutter_fader

A flutter widget that allows you to fade a child widget in and out. When faded out the child widget is removed from the tree (it can't be interacted with)

AndroidiOSWebmacOSWindowsLinux
30-day downloads
52
Likes
9
Pub points
160

Install package

flutter pub add flutter_fader

Package Overview

Package selection guidance compiled from public package information, community data, and project usage.

Flutter Fader is a lightweight animation widget that smoothly fades a child widget in and out. When faded out, the child is removed from the widget tree, ensuring it cannot be interacted with. Ideal for creating clean, responsive transitions in user interfaces, such as loading indicators, modals, or dynamic content updates. The package supports all major platforms including Android, iOS, Web, macOS, Windows, and Linux, making it versatile for cross-platform applications. It integrates seamlessly with Flutter's animation system and requires minimal setup.

Use cases

  • Loading state transitions
  • Modal or dialog animations
  • Dynamic content visibility
  • User interface feedback
  • Smooth screen element changes

Key features

  • Smooth fade-in/out animations
  • Removes child from tree when faded out
  • Cross-platform compatibility
  • Minimal configuration
  • Seamless integration with Flutter
  • Supports all major platforms

Suitable for

  • Developers needing simple fade effects
  • Apps with dynamic UI elements
  • Cross-platform projects
  • UI/UX enhancements
  • Interactive components requiring visibility control

Considerations

  • Child widget is not retained after fading out
  • Not suitable for persistent UI elements
  • Requires careful handling in stateful contexts
  • Limited to fade transitions only
  • No built-in reverse animation control

Original README

Original README snapshot from the linked source repository. Visit the repository for the latest content.

flutter_fader

pub package codecov style: flutter lints License: MIT

A widget for Flutter that allows you to fade in and out a child widget.
When a widget is faded out it is no longer in the view tree. Meaning that it can't be used or interacted with. Handy for hiding buttons.

Example of fader with buttons Example of fader with scroll

Getting started

In your Flutter project, add the package to your dependencies

dependencies:
  ...
  flutter_fader: ^2.0.0

Usage example

Examples of how to use the widget, and that can also be ran on your device, can be found in the example directory

Import the fader package

import 'package:flutter_fader/flutter_fader.dart';

Create a fader controller, this allows you to control when the Fader fades in or out

FaderController faderController = new FaderController();

Create a fader widget, and pass it the fader controller

Fader(
  controller: faderController,
  duration: const Duration(milliseconds: 50),
  child: Text("Hello, world!"),
)

Now you can fade the child widget in and out at will

faderController.fadeOut();
faderController.fadeIn();

Categories

Source repository

Projects using this package

No data available yet.