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

loading_animation_widget 封面
插件详情v1.3.0

loading_animation_widget

加载动画或加载旋转图标或加载器。用于在应用程序处于加载状态或某些操作需要不确定时间处理时显示加载动画。

AndroidiOSWebmacOSWindowsLinux
近 30 天下载
17.1万
喜欢数
2030
Pub 分数
150

安装插件

flutter pub add loading_animation_widget

插件介绍

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

一个 Flutter 包,提供可自定义的加载动画、旋转器和加载器,用于在应用程序中视觉化地表示加载或处理状态。它支持多种动画样式,非常适合在异步操作期间提升用户体验。该小部件轻量级,易于集成,并可在所有主要平台(包括 Android、iOS、Web、macOS、Windows 和 Linux)上运行。非常适合在数据获取或任务进行时显示进度。

适合场景

  • 在 API 调用期间显示加载状态
  • 指示背景处理
  • 在数据获取期间增强UI
  • 显示应用初始化进度
  • 改善屏幕切换期间的用户体验

主要特点

  • 多种内置动画样式
  • 可自定义大小和颜色
  • 跨平台兼容性
  • 与 Flutter 的简单集成
  • 轻量且高性能
  • 支持圆形和线性加载器

适合对象

  • 开发响应式 UI 的开发者
  • 需要在异步操作期间提供视觉反馈的应用程序
  • 寻求动画指示器的UI/UX设计师
  • 面向多平台的项目

使用建议

  • 可能需要额外的样式来实现复杂的设计
  • 超出基本属性的自定义功能有限
  • 未针对极高频率的更新进行优化

原始 README

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

Loading Animation Widget

YouTube Badge Twitter Badge Patreon Badge pub package WateryDesert


How to use

Installation

Add loading_animation_widget: to your pubspec.yaml dependencies then run flutter pub get

 dependencies:
  loading_animation_widget:
Import

Add this line to import the package.

import 'package:loading_animation_widget/loading_animation_widget.dart';


All loading animation APIs are same straight forward. There is a static method for each animation inside LoadingAnimationWidget class, which returns the Object of that animation. Both size and color are required some animations need more than one color.

Loading animation with one color

Scaffold(
    body: Center(
      child: LoadingAnimationWidget.staggeredDotsWave(
        color: Colors.white,
        size: 200,
      ),
    ),

Loading animation with more than one color. You have to provide both required colors.

Scaffold(
    body: Center(
        child: LoadingAnimationWidget.twistingDots(
          leftDotColor: const Color(0xFF1A1A3F),
          rightDotColor: const Color(0xFFEA3799),
          size: 200,
        ),
      ),

Screen recordings with design credits

waveDots

inkDrop

twistingDots

threeRotatingDots

staggeredDotsWave

fourRotatingDots

fallingDot

progressiveDots

discreteCircular

threeArchedCircle

bouncingBall

flickr

hexagonDots

beat

twoRotatingArc

horizontalRotatingDots

newtonCradle

stretchedDots

halfTriangleDot

dotsTriangle


All flutter packages

● Sliding Clipped Nav Bar
● Water Drop Nav Bar
● Swipeable Tile
➜ Loading Animation Widget


所属分类

源码仓库

使用此插件的项目