simple_parallax 0.1.1 simple_parallax: ^0.1.1 copied to clipboard
This parallax Flutter plugin that adds elegant parallax effects to your widgets using two different modes: a container mode and a widget mode. This plugin helps create dynamic and visually appealing u [...]
import 'package:flutter/material.dart';
import 'package:simple_parallax/simple_parallax.dart';
void main() => runApp(const MyApp());
/// App demo
class MyApp extends StatelessWidget {
/// App demo constructor
const MyApp({super.key});
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
body: Center(
child: SizedBox(
//height: 300,
//width: 600,
child: SimpleParallaxContainer(
//height: 300,
imagePath: 'assets/images/background.webp',
speed: 0.3,
autoSpeed: true,
decal: 1.0,
child: Column(
children: List<Widget>.generate(
20,
(int index) => Container(
height: 100,
margin: const EdgeInsets.symmetric(vertical: 10),
color: Colors.white.withOpacity(0.8),
child: Center(child: Text('Item $index')),
),
),
),
),
),
),
),
);
}
}