FLUTTER ECOSYSTEM

mohit-chauhan-98/animated_loading_border

一個套件,可讓我們以現代化的方式在載入元件時顯示動畫邊框作為佔位符,易於自訂且即開即用。

animated_loading_border 專案封面
Stars
20
Forks
3
最近推送(UTC)
2024年5月27日
專案狀態
未封存
Mohit Chauhan GitHub avatar
GITHUB User

Mohit Chauhan ↗

Software Engineer | Flutter | iOS

Ahmedabad
語言DartHTMLSwiftKotlinObjective-C

技術主題

此儲存庫發佈的套件

使用的依賴

依賴清單 3 項
  • flutter{"sdk":"flutter"}
  • flutter_test開發依賴{"sdk":"flutter"}
  • flutter_lints開發依賴^2.0.0

原始 README

以下為英文專案原文快照,最新內容請造訪 GitHub。

展開 / 收合專案 README

animated_loading_border

Flutter Website Dart Website https://img.shields.io/badge/platform-Android-deepskyblue https://img.shields.io/badge/platform-iOS-deepskyblue https://img.shields.io/badge/platform-Web-deepskyblue https://img.shields.io/badge/platform-Mac-deepskyblue https://img.shields.io/badge/platform-Linux-deepskyblue https://img.shields.io/badge/platform-Windows-deepskyblue https://app.codacy.com/project/badge/Grade/dc683c9cc61b499fa7cdbf54e4d9ff35 https://img.shields.io/github/license/mohit-chauhan-98/animated_loading_border https://img.shields.io/pub/v/animated_loading_border?color=as&label=animated_loading_border&logo=as1&logoColor=blue&style=social MIT License

Key Definition

  • A package that gives us a modern way to show animated border as a placeholder while loading our widget with easy customization and ready to use.

Preview

animated_loading_border animated_loading_border

Basic Usage

Import it to your project file

import 'package:animated_loading_border/animated_loading_border.dart';

And add it in its most basic form like it:

AnimatedLoadingBorder(
  child: Container(),
  controller: (animationController) {
     // Here we get animationController     
  },
);
Required parameters of AnimatedLoadingBorder

Parameter Description
Widget child The child contained by the AnimatedLoadingBorder
Optional parameters of AnimatedLoadingBorder

Parameter Default Description
ValueChanged? controller -- Callback that gives the AnimationController of the AnimatedLoadingBorder
Duration duration Duration(seconds: 4) Defines the animation duration
double cornerRadius 0.0 Defines the corner radius of the border
double borderWidth 1 Defines the width of the border
Color borderColor Colors.black Defines the color of the border
Color trailingBorderColor Colors.black Defines the color for the trailing part of the border
EdgeInsets padding EdgeInsets.zero Used to add child widget padding
bool startWithRandomPosition true Used to set starting position of SweepGradient
bool isTrailingTransparent true Used to set starting color of SweepGradient
Guideline for contributors

  • Contribution towards my repository is always welcome, i request contributors to create a pull request for development.
Guideline to report an issue/feature request

It would be great for me if the reporter can share the below things to understand the root cause of the issue.

  • Library version
  • Code snippet
  • Logs if applicable
  • Device specification like (Manufacturer, OS version, etc)
  • Screenshot/video with steps to reproduce the issue
  • Library used

LICENSE!

animated_loading_border is MIT-licensed.