parallax_rain 1.0.4 copy "parallax_rain: ^1.0.4" to clipboard
parallax_rain: ^1.0.4 copied to clipboard

outdated

Use this package to create cool 3D rain effects. Customize with multiple colors, different raindrop speeds, drop trail effects and more!

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:parallax_rain/parallax_rain.dart';

void main() {
  runApp(MyApp());
}

class MyApp extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Parallax Rain',
      theme: ThemeData.dark().copyWith(scaffoldBackgroundColor: Colors.black),
      home: MyHomePage(),
    );
  }
}

class MyHomePage extends StatefulWidget {
  MyHomePage({Key? key}) : super(key: key);

  @override
  _MyHomePageState createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: Column(
        mainAxisAlignment: MainAxisAlignment.center,
        children: [
          Expanded(
            child: Row(
              children: [
                Expanded(
                  child: ParallaxRain(
                    dropColors: [
                      Colors.red,
                      Colors.green,
                      Colors.blue,
                      Colors.yellow,
                      Colors.brown,
                      Colors.blueGrey
                    ],
                    child: Text(
                      "Multicolor",
                    ),
                  ),
                ),
                Expanded(
                  child: ParallaxRain(
                    dropColors: [
                      Colors.red,
                      Colors.green,
                      Colors.blue,
                      Colors.yellow,
                      Colors.brown,
                      Colors.blueGrey
                    ],
                    trail: true,
                    child: Text(
                      "Multicolor Trail",
                    ),
                  ),
                ),
              ],
            ),
          ),
          Expanded(
            child: Row(
              children: [
                Expanded(
                  child: ParallaxRain(
                    dropColors: [Colors.blueGrey],
                    trail: true,
                    child: Text(
                      "BlueGrey Trail",
                    ),
                  ),
                ),
                Expanded(
                  child: ParallaxRain(
                    dropColors: [Colors.blueGrey],
                    trail: true,
                    dropFallSpeed: 5,
                    child: Text(
                      "BlueGrey Trail Fast",
                    ),
                  ),
                ),
              ],
            ),
          ),
        ],
      ),
    );
  }
}
85
likes
0
points
148
downloads

Publisher

verified publisherzac.ac

Weekly Downloads

Use this package to create cool 3D rain effects. Customize with multiple colors, different raindrop speeds, drop trail effects and more!

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter

More

Packages that depend on parallax_rain