{"id":22525451,"url":"https://github.com/codingfries/progress_dialog","last_synced_at":"2025-08-03T21:32:31.209Z","repository":{"id":56837236,"uuid":"412501713","full_name":"CodingFries/progress_dialog","owner":"CodingFries","description":null,"archived":false,"fork":false,"pushed_at":"2024-02-22T15:31:36.000Z","size":216,"stargazers_count":1,"open_issues_count":3,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-06-01T01:57:54.107Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/CodingFries.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2021-10-01T14:35:14.000Z","updated_at":"2024-04-19T01:46:22.000Z","dependencies_parsed_at":"2024-02-12T16:58:05.811Z","dependency_job_id":"2ab77406-7fa2-4aab-b811-d8cfc4fa1b26","html_url":"https://github.com/CodingFries/progress_dialog","commit_stats":{"total_commits":10,"total_committers":1,"mean_commits":10.0,"dds":0.0,"last_synced_commit":"6ed51474b49726d6aa3d613e899ee8e24c1d0a00"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CodingFries%2Fprogress_dialog","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CodingFries%2Fprogress_dialog/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CodingFries%2Fprogress_dialog/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CodingFries%2Fprogress_dialog/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CodingFries","download_url":"https://codeload.github.com/CodingFries/progress_dialog/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":228567016,"owners_count":17937986,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-12-07T06:10:13.024Z","updated_at":"2024-12-07T06:10:13.838Z","avatar_url":"https://github.com/CodingFries.png","language":"Dart","funding_links":[],"categories":[],"sub_categories":[],"readme":"# progress_dialog\n\nA light weight package to show progress dialog. As it is a stateful widget, you can change the text shown on the dialog dynamically.\n\nThis is the original package and it's owner\nhttps://github.com/fayaz07/progress_dialog\n\nIt was discontinued by him, but i really liked the package so I am trynna revive it :D\nI added null safety and updated most of the stuff making it null safe and useable again :)\n\n## Demo\n\n\u003cimg src=\"https://raw.githubusercontent.com/fayaz07/progress_dialog/master/progress_dialog_1.png\" height=\"35%\" width=\"35%\"  alt=\"Normal dialog Demo\"/\u003e \u003cimg src=\"https://raw.githubusercontent.com/fayaz07/progress_dialog/master/progress_dialog_2.png\"   height=\"35%\" width=\"35%\" alt=\"Download dialog Demo\" /\u003e\n\n## How to use\n\n\n\nImport the package in your dart file\n\n```dart\nimport 'package:progress_dialog/progress_dialog_null_safe.dart';\n```\nCreate and initialise a **ProgressDialog** object inside the **build()** method passing context to it\n\n\u003col\u003e\n\u003cli\u003e Initialize the ProgressDialog object \u003cbr\u003e  \n\n```dart\nfinal ProgressDialog pr = ProgressDialog(context);\n```\n\u003c/li\u003e\n\n\n\u003cli\u003e By default it is a normal dialog to show some message, if you would like to use it to show percentage of progress done, specify the optional \u003cb\u003etype\u003c/b\u003e parameter and specify if you want your dialog to dismiss when back button is pressed \u003cb\u003eisDismissible\u003c/b\u003e parameter (Optional) \u003cbr/\u003e\n\n```dart\n//For normal dialog\npr = ProgressDialog(context,type: ProgressDialogType.Normal, isDismissible: true/false, showLogs: true/false);\n    \n//For showing progress percentage\npr =  ProgressDialog(context,type: ProgressDialogType.Download, isDismissible: true/false, showLogs: true/false);\n```\n\u003c/li\u003e\n\u003e Note: Please initialize the ```ProgressDialog```, where you have availability of the context\n\n\u003cli\u003eStyle the progress dialog (Optional)\u003cbr/\u003e\n\n```dart\npr.style(\n  message: 'Downloading file...',\n  borderRadius: 10.0,\n  backgroundColor: Colors.white,\n  progressWidget: CircularProgressIndicator(),\n  elevation: 10.0,\n  insetAnimCurve: Curves.easeInOut,\n  progress: 0.0,\n  textDirection: TextDirection.rtl,\n  maxProgress: 100.0,\n  progressTextStyle: TextStyle(\n     color: Colors.black, fontSize: 13.0, fontWeight: FontWeight.w400),\n  messageTextStyle: TextStyle(\n     color: Colors.black, fontSize: 19.0, fontWeight: FontWeight.w600)\n  );\n```\n```note\nNote: You don't need to use all parameters, all of them are optional\n```\n\n\u003c/li\u003e\n\n\u003cli\u003eShowing the progress dialog\u003cbr\u003e\n\n```dart\nawait pr.show();\n```\n\u003c/li\u003e\n\n\u003cli\u003e\nDynamically update the content shown out there \u003cbr/\u003e\n\n```dart\npr.update(\n  progress: 50.0,\n  message: \"Please wait...\",\n  progressWidget: Container(\n    padding: EdgeInsets.all(8.0), child: CircularProgressIndicator()),\n  maxProgress: 100.0,\n  progressTextStyle: TextStyle(\n    color: Colors.black, fontSize: 13.0, fontWeight: FontWeight.w400),\n  messageTextStyle: TextStyle(\n    color: Colors.black, fontSize: 19.0, fontWeight: FontWeight.w600),\n  );\n```\n```note\nNote: You don't need to use all parameters, all of them are optional\n```\n\u003c/li\u003e\n\n\n\u003cli\u003e\nDismissing the progress dialog\u003cbr/\u003e\n\n```dart\npr.hide().then((isHidden) {\n  print(isHidden);\n});\n\n// or\nawait pr.hide();\n```\n\n\u003c/li\u003e\n\n\u003c/ol\u003e\n\n\u003e Navigating to next screens must be done after the completion of Future - hide(). [See here for example](https://gist.github.com/fayaz07/52dfe04d9f8594501465f169aa6ef6b6)\n\n### Check if progress dialog is showing\n\n```dart\nbool isProgressDialogShowing = pr.isShowing();\nprint(isProgressDialogShowing);\n```\n\n### Use custom body\n```dart\n    pr = ProgressDialog(\n      context,\n      type: ProgressDialogType.Normal,\n      isDismissible: true,\n      /// your body here\n      customBody: LinearProgressIndicator(\n        valueColor: AlwaysStoppedAnimation\u003cColor\u003e(Colors.blueAccent),\n        backgroundColor: Colors.white,\n      ),\n    );\n```\n\n\n---\n\n\n## Demo\n\n\u003cimg src=\"https://raw.githubusercontent.com/fayaz07/progress_dialog/master/pd_demo_nd.gif\" alt=\"Normal dialog Demo\"/\u003e \u003cimg src=\"https://raw.githubusercontent.com/fayaz07/progress_dialog/master/pd_demo_dd.gif\" alt=\"Download dialog Demo\" /\u003e\n\n\n### Default configuration/styles\n\nIf you don't like to configure/style the dialog and continue with the default style, it's okay but just have a look at our default configuration.\n\n| Attribute           | Value   |\n| -------------       | :-----:|\n| Dismissible         |    true |\n| ProgressDialogType  |    ProgressDialogType.Normal |\n| BackgroundColor     | Colors.white |\n| BorderRadius        |   RoundedRectangularBorder(radius: 8.0) |\n| AnimationCurve      |    Curves.easeInOut |\n| Elevation           |    8.0 |\n| ProgressWidget      |    Double_rings_loding_indicator |\n| MessageTextStyle    |    color: Colors.black, fontSize: 19.0, fontWeight: FontWeight.w600 |\n| ProgressTextStyle   |    color: Colors.black, fontSize: 13.0, fontWeight: FontWeight.w400 |\n| showLogs            |    false |\n\n#### Well let's discuss limits for configuring it\n\n| Attribute           | Can be updated during instantiating   | Can be updated during styling   |Can be updated during dialog is shown |\n| -------------       | :-------------------------------:     |:------------------------------: |:-------------------------------:     |\n| Dismissible         | Yes                                   |No                               |No                                    |\n| ProgressDialogType  | Yes                                   |No                               |No                                    |\n| BackgroundColor     | No                                    |Yes                              |No                                    |\n| BorderRadius        | No                                    |Yes                              |No                                    |\n| AnimationCurve      | No                                    |Yes                              |No                                    |\n| Elevation           | No                                    |Yes                              |No                                    |\n| ProgressWidget      | No                                    |Yes                              |Yes                                   |\n| MessageTextStyle    | No                                    |Yes                              |Yes                                   |\n| ProgressTextStyle   | No                                    |Yes                              |Yes                                   |\n| ShowLogs            | Yes                                   |No                               |No                                    |\n\nLoading indicator -\u003e https://loading.io/\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodingfries%2Fprogress_dialog","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcodingfries%2Fprogress_dialog","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcodingfries%2Fprogress_dialog/lists"}