floating_bubbles 0.0.9 copy "floating_bubbles: ^0.0.9" to clipboard
floating_bubbles: ^0.0.9 copied to clipboard

outdated

A Flutter Package for adding Floating bubbles on the Foreground to any Flutter widget.

Floating Bubbles Build Status #

pub version

A Flutter Package for adding Floating bubbles in the Foreground to a widget. #

Getting Started #

In your flutter project(in pubspec.yaml) add the dependency:

dependencies:
   floating_bubbles: ^0.0.9

Import the package:

import 'package:floating_bubbles/floating_bubbles.dart';

Usage #

Breaking Changes to the Api is made in v0.0.8, if you are using below v0.0.8, read before you upgrade.!! #

Here is an snippet on how to use Floating Bubbles to any Widget.

Creating FloatingBubbles() (this creates the animation and plays for amount of time you give as the duration.) #

 return Stack(
    children: [
     Positioned.fill(
        child: Container(
        color: Colors.red,
      ),
     ),
     Positioned.fill(
         child: FloatingBubbles(
         noOfBubbles: 25,
         colorOfBubbles: Colors.green.withAlpha(30),
         sizeFactor: 0.16,
         duration: 120,//120 seconds. 
    ),
 );

Creating FloatingBubbles.alwaysRepeating() (Creates Floating Bubbles that always floats and doesn't stop.) #

return Stack(
   children: [
    Positioned.fill(
       child: Container(
       color: Colors.red,
     ),
    ),
    Positioned.fill(
        child: FloatingBubbles.alwaysRepeating(
        noOfBubbles: 25,
        colorOfBubbles: Colors.green.withAlpha(30),
        sizeFactor: 0.16,
   ),
);

Parameters: #

For Creating FloatingBubbles() #

Name Description Is It Required Default Value
noOfBubbles No. of Bubbles to be present in the screen at a given Time Yes -
colorOfBubbles Color of the bubbles Yes -
sizeFactor Size Factor of each bubbles Yes -
duration Duration to play the animation (input is taken as seconds) Yes -

For Creating FloatingBubbles.alwaysRepeating() #

Name Description Is It Required Default Value
noOfBubbles No. of Bubbles to be present in the screen at a given Time Yes -
colorOfBubbles Color of the bubbles Yes -
sizeFactor Size Factor of each bubbles Yes -

Example #

The code for the Example shown below is here.

About Me #

Support #

Give a ⭐/👍 if you liked the work!! :) Suggestions are Welcome. Any issues just open an issue. I will reach you as soon as possible.

License #

The Scripts and Documentation in this project are released under the MIT License

80
likes
40
pub points
90%
popularity

Publisher

unverified uploader

A Flutter Package for adding Floating bubbles on the Foreground to any Flutter widget.

Repository (GitHub)
View/report issues
Contributing

License

MIT (license)

Dependencies

flutter, simple_animations

More

Packages that depend on floating_bubbles