multi_image_picker_view 0.0.4 copy "multi_image_picker_view: ^0.0.4" to clipboard
multi_image_picker_view: ^0.0.4 copied to clipboard

outdated

A complete widget which can easily pick multiple images from device and display them in UI. Also picked image can be re-ordered and removed easily.

example/lib/main.dart

import 'package:example/custom_examples.dart';
import 'package:flutter/material.dart';
import 'package:multi_image_picker_view/multi_image_picker_view.dart';

void main() {
  runApp(MaterialApp(
    debugShowCheckedModeBanner: false,
    title: 'Mutli Image Picker View Example',
    theme: ThemeData(
      primarySwatch: Colors.blue,
    ),
    home: const DemoPage(),

  ));
}

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

  @override
  State<DemoPage> createState() => _DemoPageState();
}

class _DemoPageState extends State<DemoPage> {
  final controller = MultiImagePickerController(
    maxImages: 10,
    allowedImageTypes: ['png', 'jpg', 'jpeg'],
  );

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: Column(
        children: [
          MultiImagePickerView(
            controller: controller,
            padding: const EdgeInsets.all(10),
          ),
          const SizedBox(height: 32),
          CustomExamples()
        ],
      ),
      appBar: AppBar(
        title: Text('Multi Image Picker View'),
        actions: [
          IconButton(
            icon: Icon(Icons.arrow_upward),
            onPressed: () {
              final images = controller.images;
              // use these images
              print(images);
            },
          ),
        ],
      ),
    );
  }

  @override
  void dispose() {
    controller.dispose();
    super.dispose();
  }
}
109
likes
0
pub points
94%
popularity

Publisher

unverified uploader

A complete widget which can easily pick multiple images from device and display them in UI. Also picked image can be re-ordered and removed easily.

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

file_picker, flutter, flutter_reorderable_grid_view

More

Packages that depend on multi_image_picker_view