location_picker_flutter_map 3.0.1 copy "location_picker_flutter_map: ^3.0.1" to clipboard
location_picker_flutter_map: ^3.0.1 copied to clipboard

Package that provides Place search and Location picker for flutter maps with alot of cusomizations using Open Street Map

example/lib/main.dart

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

void main() => runApp(const MyApp());

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Location Picker',
      debugShowCheckedModeBanner: false,
      home: Scaffold(
        appBar: AppBar(
          title: const Text('Flutter Location Picker'),
        ),
        body: FlutterLocationPicker(
          initZoom: 11,
          minZoomLevel: 5,
          maxZoomLevel: 16,
          trackMyPosition: true,
          searchBarBackgroundColor: Colors.white,
          selectedLocationButtonTextstyle: const TextStyle(fontSize: 18),
          mapLanguage: 'en',
          onError: (e) => print(e),
          selectLocationButtonLeadingIcon: const Icon(Icons.check),
          onPicked: (pickedData) {
            print(pickedData.latLong.latitude);
            print(pickedData.latLong.longitude);
            print(pickedData.address);
            print(pickedData.addressData);
          },
          onChanged: (pickedData) {
            print(pickedData.latLong.latitude);
            print(pickedData.latLong.longitude);
            print(pickedData.address);
            print(pickedData.addressData);
          },
          showContributorBadgeForOSM: true,
        ),
      ),
    );
  }
}
41
likes
130
pub points
93%
popularity

Publisher

unverified uploader

Package that provides Place search and Location picker for flutter maps with alot of cusomizations using Open Street Map

Repository (GitHub)
View/report issues

Documentation

API reference

License

MIT (LICENSE)

Dependencies

flutter, flutter_map, flutter_map_cancellable_tile_provider, flutter_map_location_marker, geolocator, http, intl, latlong2, url_launcher

More

Packages that depend on location_picker_flutter_map