Circular Timer
This flutter package give a circular timer widget that is very easy to use and with a smooth animation
---Features
Light package that works this PLATFORM: ANDROID IOS LINUX MACOS WEB WINDOWS
 
Getting started
TO install
flutter pub add circular_timer: ^1.0.1
Usage
Basic usage
CircularTimer(
duration: const Duration(seconds: 30),
radius: 100,
),
To change the default color, use the color property
CircularTimer(
duration: const Duration(seconds: 10),
radius: 100,
color: Colors.green,
),
To repeat the timer after the duration is completed set repeat: true the default value is false.
CircularTimer(
duration: const Duration(seconds: 10),
radius: 100,
color: Colors.green,
repeat: true,
),
The startAngle is the position where it starts counting ` its value must be in radian`
startAngle default value is set to
1.5 * math.pi
To form a ring around the circular timer:
you have to set outline: true
the ring width can change by setting the outlinedWidth
to a nonNegative value
OutlinedPadding
is the distance between the ring and the circular timer and can be set to zero to form a border. The default outlinedPadding
value is 4.0
CircularTimer(
duration: const Duration(seconds: 10),
radius: 100,
color: Colors.green,
repeat: true,
outline: true,
outlinedPadding: 0.0
outlinedWidth: 3.0
),
CircularTimer has a decoration
property that allow you the rewrite the default outlinedColor
that is the ring color`
CircularTimer(
duration: const Duration(seconds: 10),
radius: 100,
color: Colors.green,
decoration: CircleDecoration(
outlinedColor: Colors.green
)
),