演示:
直接上代码:
import 'dart:math';
import 'dart:ui';
import 'package:flutter/material.dart';
import 'package:kq_flutter_widgets/widgets/chart/ex/extension.dart';
class ParticleView extends StatefulWidget {
const ParticleView({super.key});
@override
State<StatefulWidget> createState() => ParticleViewState();
}
class ParticleViewState extends State<ParticleView>
with TickerProviderStateMixin {
///动画最大值
static double maxValue = 1000.0;
late AnimationController controller;
late Animation<double> animation;
@override
void initState() {
super.initState();
controller =
AnimationController(duratio