Flutter-手擼一個加載彈框LoadingDialog

loading_dialog

A flutter widget of loading dialog.Easy to use.bash

Installing

dependencies:
  loading_dialog: ^0.0.1+1 #latest version
複製代碼

Getting Started

Defaultide

LoadingDialog loading = LoadingDialog(context);
loading.show();
loading.hide();
複製代碼

Your customui

LoadingDialog loadingDialog = LoadingDialog(
  buildContext: context,
  loadingView: null, //yourself loading view ,default is CircularProgressIndicator
  radius: 15, //dialog bg radius
  elevation: 0, //dialog elevation
  size: 50, // loading view size
  padding: 10, //text to loading view
  width: 150, //dialog width
  height: 150, //dialog height
  loadingMessage: "Loading...", //your message,if null dismiss
  textColor: Colors.black54, //message text color
  textSize: 14,//message text size
  style: LoadingDialogStyle.horizontal, // or vertical
  backgroundColor: Colors.white, //dialog background color
  barrierColor: Colors.black54, //window color
  barrierDismissible: true, //touch window dismiss
);
複製代碼

上面屬性能夠針對本身需求設置spa

Simulator Screen Shot - iPhone Xʀ - 2019-07-03 at 14.59.14.png
Simulator Screen Shot - iPhone Xʀ - 2019-07-03 at 14.49.29.png
相關文章
相關標籤/搜索
本站公眾號
   歡迎關注本站公眾號,獲取更多信息