Skip to main content

polyline_animation_plus 1.3.0 copy "polyline_animation_plus: ^1.3.0" to clipboard
polyline_animation_plus: ^1.3.0 copied to clipboard

A Flutter package for creating smooth, customizable polyline animations on Google Maps, ideal for transport, delivery, and route-visualization applications.

example/lib/main.dart

import 'package:flutter/material.dart';

import 'animators_screen.dart';
import 'tracking_screen.dart';

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

/// Try the package: a simulated vehicle on a route, and each animator.
class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'polyline_animation_plus',
      debugShowCheckedModeBanner: false,
      theme: ThemeData(colorSchemeSeed: const Color(0xFF1565C0)),
      home: const HomeScreen(),
    );
  }
}

class HomeScreen extends StatefulWidget {
  const HomeScreen({super.key});

  @override
  State<HomeScreen> createState() => _HomeScreenState();
}

class _HomeScreenState extends State<HomeScreen> {
  int _index = 0;

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: IndexedStack(
        index: _index,
        children: [
          // Each screen has its own map; only the visible one is built.
          if (_index == 0) const TrackingScreen() else const SizedBox(),
          if (_index == 1) const AnimatorsScreen() else const SizedBox(),
        ],
      ),
      bottomNavigationBar: NavigationBar(
        selectedIndex: _index,
        onDestinationSelected: (i) => setState(() => _index = i),
        destinations: const [
          NavigationDestination(
            icon: Icon(Icons.directions_car),
            label: 'Vehicle tracking',
          ),
          NavigationDestination(icon: Icon(Icons.timeline), label: 'Animators'),
        ],
      ),
    );
  }
}
8
likes
150
points
255
downloads

Documentation

Documentation
API reference

Publisher

unverified uploader

Weekly Downloads

A Flutter package for creating smooth, customizable polyline animations on Google Maps, ideal for transport, delivery, and route-visualization applications.

Repository (GitHub)
View/report issues

Topics

#map-animation #animated-polylines

License

unknown (license)

Dependencies

flutter, google_maps_flutter_platform_interface

More

Packages that depend on polyline_animation_plus