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

giffy_dialog 封面
插件详情v2.3.0

giffy_dialog

一个用于快速、便捷且美观的 gif 对话框和底部弹出层的 Flutter 包。

AndroidiOSWebmacOSWindowsLinux
近 30 天下载
1220
喜欢数
605
Pub 分数
150

安装插件

flutter pub add giffy_dialog

插件介绍

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

GiffyDialog 是一个 Flutter 包,使用 GIF 动画提供视觉上吸引人的对话框和底部弹出层。它使开发者能够用最少的代码快速实现引人入胜的用户交互。该包支持 Android、iOS、Web、macOS、Windows 和 Linux 等多个平台。通过可自定义的主题和简单的命令集成方式,它通过添加趣味性和动态视觉反馈来提升应用用户体验。非常适合用于引导页面、提示信息或应用中的庆祝时刻。

适合场景

  • 引导页面
  • 用户提醒
  • 庆祝弹窗
  • 应用引导
  • 反馈提示

主要特点

  • Animated GIF 支持
  • 可自定义对话框
  • 跨平台兼容性
  • 简单 API
  • 底部弹出菜单集成

适合对象

  • 移动应用开发者
  • 以用户体验为中心的项目
  • 交互式UI增强
  • 快速对话框实现

使用建议

  • 大型 GIF 文件可能会影响性能
  • 复杂布局的自定义选项有限
  • 需要仔细优化GIF文件
  • 不适合轻量级对话
  • 取决于网络状况,加载远程GIF

原始 README

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

Giffy Dialog

Open Source Love License Dart CI CodeCov Version

A beautiful and custom alert dialog for flutter highly inspired from FancyAlertDialog-Android.

Show some ❤️ and star the repo to support the project

Live Demo: https://xsahil03x.github.io/giffy_dialog

An animated image of the GiffyDialog

Migration from v1 to v2

Please refer to the migration guide to migrate from v1 to v2.

Installation

Add the following to your pubspec.yaml and replace [version] with the latest version:

dependencies:
  giffy_dialog: ^[version]

Usage

Import the package:

import 'package:giffy_dialog/giffy_dialog.dart';

Use it like a dialog:

 showDialog(
   context: context,
   builder: (BuildContext context) {
     return GiffyDialog.image(
       Image.network(
         "https://raw.githubusercontent.com/Shashank02051997/FancyGifDialog-Android/master/GIF's/gif14.gif",
         height: 200,
         fit: BoxFit.cover,
       ),
       title: Text(
         'Image Animation',
         textAlign: TextAlign.center,
       ),
       content: Text(
         'This is a image animation dialog box. This library helps you easily create fancy giffy dialog.',
         textAlign: TextAlign.center,
       ),
       actions: [
         TextButton(
           onPressed: () => Navigator.pop(context, 'CANCEL'),
           child: const Text('CANCEL'),
         ),
         TextButton(
           onPressed: () => Navigator.pop(context, 'OK'),
           child: const Text('OK'),
         ),
       ],
     );
   },
 );

Or use it like a bottom sheet:

 showModalBottomSheet(
   context: context,
   clipBehavior: Clip.antiAlias,
   isScrollControlled: true,
   shape: RoundedRectangleBorder(
     borderRadius: BorderRadius.vertical(
       top: Radius.circular(useMaterial3 ? 32 : 4),
     ),
   ),
   builder: (BuildContext context) {
     return GiffyBottomSheet.image(
       Image.network(
         "https://raw.githubusercontent.com/Shashank02051997/FancyGifDialog-Android/master/GIF's/gif14.gif",
         height: 200,
         fit: BoxFit.cover,
       ),
       title: Text(
         'Image Animation',
         textAlign: TextAlign.center,
       ),
       content: Text(
         'This is a image animation bottom sheet. This library helps you easily create fancy giffy bottom sheet.',
         textAlign: TextAlign.center,
       ),
       actions: [
         TextButton(
           onPressed: () => Navigator.pop(context, 'CANCEL'),
           child: const Text('CANCEL'),
         ),
         TextButton(
           onPressed: () => Navigator.pop(context, 'OK'),
           child: const Text('OK'),
         ),
       ],
     );
   },
 );

Demo

Giffy Dialog Giffy BottomSheet
Material 2 Material 3 Material 2 Material 3
Image Giffy Image Giffy Dialog Image Giffy Dialog Image Giffy Dialog Image Giffy Dialog
Rive Giffy Image Giffy Dialog Image Giffy Dialog Image Giffy Dialog Image Giffy Dialog
Lottie Giffy Image Giffy Dialog Image Giffy Dialog Image Giffy Dialog Image Giffy Dialog

Customization

The GiffyDialog widget provides several customization options, such as the dialog title, description, buttons, animations, and more. Please refer to the documentation for a complete list of available options.

Contributors

Thanks goes to these wonderful people (emoji key):


ArtemKolichenkov

📖 🤔

Alex Fierro

💻

Kasidech C.

💻

Jai Sachdeva

💬

Tarekk Mohamed Abdalla

💻

madhukesh_048

⚠️

dpedrinha

💻

Nate

💻 💡

Alex

💻

jritchie

💻

Saad Bin Shahid

💻

This project follows the all-contributors specification. Contributions of any kind welcome!

License

MIT License

所属分类

依赖

依赖清单 2 项

源码仓库

使用此插件的项目