A Flutter Package for easy building dialogs

Related tags

Widgets easy_dialog
Overview

logo

pub package  GitHub stars  GitHub     LinkedIn  LinkedIn
Open Source Love


Easy Dialog package helps you easily create basic or custom dialogs. For extended documentation visit project pub package.

Star this repo if you like our project. We would love your support.

💾 Installation

In the dependencies: section of your pubspec.yaml, add the following line:

dependencies:
  easy_dialog: <latest version>

📦 Usage

Import this class

import 'package:easy_dialog/easy_dialog.dart';

Basic structure

EasyDialog(
        title: Text("Basic Easy Dialog Title"),
        description: Text("This is a basic dialog")).show(context);

🎯 Examples

Let start creating simple but beautiful dialogs.
Here you have some basic examples of what can you build and let your creativity fly.

Network

🎨 Customization and Attributes

All customizable attributes for easy_dialog

Attribute Name Example Value Description
topImage AssetImage("assets/topImage.png") Top image for decoration purpose with rounded top corners
title Text("Alert") Dialog title, located under topImage if exists
tittlePadding EdgeInsets.only(left: 8.0,right: 8.0) Title padding
description Text("Connection error") Dialog description, located between title and contentList
descriptionPadding EdgeInsets.only(left: 8.0,right: 8.0) Description padding
contentList [
Text("This is an extra text line"), FlatButton(onPressed: () {},
  child: Text("Okay"),),
]
Optional widget list, located in order before description
contentPadding EdgeInsets.all(12.0) Content padding. It wraps all widgets including title and description
height 200 Dialog height
width 250 Dialog width
cornerRadius 15.0 Dialog corner radius
fogOpacity 0.5 Fog opacity, sets the black fog opacity behind our dialog from 0 to 1
closeButton false Close button enable/disable

🧱 How to Contribute

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Add some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

📃 MIT License

Copyright (c) 2019 ricardonior29

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

Getting Started

For help getting started with Flutter, view our online documentation.

For help on editing package code, view the documentation.

You might also like...

SKAlertDialog - A highly customizable, powerful and easy-to-use alert dialog for Flutter.

 SKAlertDialog - A highly customizable, powerful and easy-to-use alert dialog for Flutter.

SKAlertDialog A highly customizable, powerful and easy-to-use alert dialog for Flutter. GIF Screenshots SKAlertDialog Basic Alert Alert with buttons A

May 18, 2022

Flutter Color Picker Wheel - an easy to use widget which can be heavily customized

Flutter Color Picker Wheel  - an easy to use widget which can be heavily customized

Flutter Color Picker Wheel Flutter Color Picker Wheel is an easy to use widget which can be heavily customized. You can use the WheelColorPicker direc

Oct 4, 2022

Provider support for overlay, make it easy to build toast and In-App notification.

overlay_support Provider support for overlay, make it easy to build toast and In-App notification. this library support ALL platform Interaction If yo

Jan 1, 2023

A popup simple topModalSheet menu button widget with handsome design and easy to use

A popup simple topModalSheet menu button widget with handsome design and easy to use

top_modal_sheet A popup simple topModalSheet menu button widget with handsome design and easy to use. Installations Add top_modal_sheet: ^1.0.0 in you

Jul 29, 2022

Flutter package: Assorted layout widgets that boldly go where no native Flutter widgets have gone before.

Flutter package: Assorted layout widgets that boldly go where no native Flutter widgets have gone before.

assorted_layout_widgets I will slowly but surely add interesting widgets, classes and methods to this package. Despite the package name, they are not

Dec 22, 2022

Flutter UI Widgets Flutter Package

Flutter UI Widgets Flutter Package This package makes different Flutter UI widgets implementation easy for you. Flutter UI Widgets The list of widgets

May 6, 2022

Flutter Package for Easier Creation of Home Screen Widgets

Flutter Package for Easier Creation of Home Screen Widgets

Home Widget HomeWidget is a Plugin to make it easier to create HomeScreen Widgets on Android and iOS. HomeWidget does not allow writing Widgets with F

Dec 31, 2022

A Flutter package which provides helper widgets for selecting single or multiple account/user from the given list.

A Flutter package which provides helper widgets for selecting single or multiple account/user from the given list.

account_selector A Flutter package which provides helper widgets for selecting single or multiple account/user from a list Supported Dart Versions Dar

Oct 7, 2021

Flutter package: Similar to a ListView, but lets you programmatically jump to any item, by index.

indexed_list_view Similar to a ListView, but lets you programmatically jump to any item, by index. The index jump happens instantly, no matter if you

Dec 27, 2022
Comments
  • If contentList is not Null, title and description are not displayed in dialog box

    If contentList is not Null, title and description are not displayed in dialog box

    Version: easy_dialog: ^1.1.0

    working code:

    EasyDialog(
            title: Text("Basic Easy Dialog Title"),
            description: Text("This is a basic dialog")).show(context);
    

    Broken Code:

    EasyDialog(
            title: Text("Basic Easy Dialog Title"),
            description: Text("This is a basic dialog"),
    contentList:[ Text("this is the only message that will now show in the dialog box"),],).show(context);
    

    This code will show the text inside contentList and will not show the text inside title or description.

    I was able to fix the problem by making the following changes in the file "easy_dialog.dart":

    Change (line #76):

    if (contentList != null) {
         _contentList = contentList as List<Widget>;
    }
    

    to:

    if (contentList != null) {
          // _contentList = contentList as List<Widget>;
        
          contentList?.forEach((element) {
            insertByIndex(EdgeInsets.zero,  element, _contentList.length);
          });
    

    Thank you for providing the easy_dialog package and for reviewing this issue.

    Best regards, Mike

    opened by MikeCodeman 2
  • How to put a callback when close button is click?

    How to put a callback when close button is click?

    Hi,

    A newbie here. This is not an issue but rather a question. Is it possible to put a callback when a close button is click? Then I can capture from future await.

    bool onClose

    onClose = await EasyDialog(...)

    Thanks in advance.

    opened by annagat 1
  • Close button padding

    Close button padding

    Is there a way to put padding for the close button widget? Maybe use the positioned widget somehow?

    Really looking forward to a response :D Appreciate it.

    opened by FlaviusBanc 0
Owner
Ricardo Niño
Flutter Dev
Ricardo Niño
A flutter package for displaying common picker dialogs.

Flutter Material Pickers A flutter package containing commonly used material design picker dialogs. Some are new, some wrap existing or built in picke

CodeGrue 89 Jan 2, 2023
Dialog-manager - A Flutter package that allows for neater declaration, abstraction and use of customisable dialogs

flutter_dialog_manager A Flutter package that allows for neater declaration, abs

Lucky Ebere 2 Dec 28, 2022
A new Flutter package project for simple a awesome dialogs

awesome_dialog A new Flutter package project for simple and awesome dialogs Usage To use this package, add awesome_dialog as a dependency in your pubs

Marcos Rodriguez Toranzo 286 Jan 6, 2023
Flutter package: Easy and powerful internationalization using Dart extensions.

i18n_extension Non-boilerplate Translation and Internationalization (i18n) for Flutter Start with a widget with some text in it: Text("Hello, how are

Marcelo Glasberg 262 Dec 29, 2022
This flutter package provides an easy implementation of a Slider Button to cancel current transaction or screen

This flutter package provides an easy implementation of a Slider Button to cancel current transaction or screen

null 222 Nov 8, 2022
A Simple and easy to use flutter package for showing progress bar.

progress_dialog A Simple and easy to use flutter package for showing progress bar. #Usage Import the package import 'package:custom_progress_dialog/cu

Vikas Jilla 6 May 23, 2022
Flutter Easy Getx Implementations .

People ask me how I manage state,dependency,routes etc when I work with flutter,Here is the Simple Brief About GetX which I used for Dummy Basic Ecommerce Concept based flutter app development .

Tasnuva Tabassum oshin 13 Oct 18, 2022
A really easy to use flutter toast library

BotToast ?? A really easy to use flutter toast library! Language: English | 中文简体 ?? Overview ?? Online Demo ?? Example ?? Renderings ?? Getting starte

null 719 Dec 28, 2022
📸 Easy to use yet very customizable zoomable image widget for Flutter, Photo View provides a gesture sensitive zoomable widget.

?? Easy to use yet very customizable zoomable image widget for Flutter, Photo View provides a gesture sensitive zoomable widget. Photo View is largely used to show interacive images and other stuff such as SVG.

Blue Fire 1.7k Jan 7, 2023
A Redux version tailored for Flutter, which is easy to learn, to use, to test, and has no boilerplate

A Redux version tailored for Flutter, which is easy to learn, to use, to test, and has no boilerplate. Allows for both sync and async reducers.

Marcelo Glasberg 214 Dec 13, 2022