simple_coverflow 0.0.6

  • README.md
  • CHANGELOG.md
  • Example
  • Installing
  • Versions
  • new50

Simple Coverflow for Flutter

A very basic cover flow implementation to swipe between widgets in Flutter.

Pull requests certainly welcome.

[0.0.6] - 4/19/18

  • Added made the builder parameter a named argument [itemBuilder] in keeping with flutter conventions.

[0.0.5] - 4/18/18

  • Added [itemCount] field so that users can have a non-infinitely scrolling cover flow. Also adjusted the default viewport value.

[0.0.4] - 4/17/18

  • Bumped versioning constraints to support much later versions of Flutter.

[0.0.3] - 4/12/18

  • Changed typedef of OnDismissedCallback to return the number of the item called rather than the item itself.

[0.0.1] - 4/12/18

  • Initial implementation of simple coverflow.

example/lib/main.dart

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

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

class MyApp extends StatelessWidget {
  static List<Container> data = [
    new Container(color: Colors.orange),
    new Container(color: Colors.blue),
    new Container(color: Colors.amber),
    new Container(color: Colors.deepPurple),
    new Container(color: Colors.green),
    new Container(color: Colors.red),
    new Container(color: Colors.yellow),
    new Container(color: Colors.greenAccent),
    new Container(color: Colors.black)
  ];

  @override
  Widget build(BuildContext context) {
    return new MaterialApp(
      title: 'Coverflow Demo',
      theme: new ThemeData(
        primarySwatch: Colors.blue,
      ),
      home: new Scaffold(
          appBar: new AppBar(
            title: new Text('Coverflow Demo'),
          ),
          body: new CoverFlow(itemBuilder: widgetBuilder,
              dismissedCallback: disposeDismissed)
      ),
    );
  }

  Widget widgetBuilder(BuildContext context, int index) {
    if (data.length == 0) {
      return new Container();
    } else {
      return data[index % data.length];
    }
  }

  disposeDismissed(int item, DismissDirection direction) {
    data.removeAt(item % data.length);
  }
}

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  simple_coverflow: "^0.0.6"

2. Install it

You can install packages from the command line:

with Flutter:


$ flutter packages get

Alternatively, your editor might support packages get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:simple_coverflow/simple_coverflow.dart';
        
Version Uploaded Documentation Archive
0.0.6 Apr 19, 2018 Go to the documentation of simple_coverflow 0.0.6 Download simple_coverflow 0.0.6 archive
0.0.5 Apr 18, 2018 Go to the documentation of simple_coverflow 0.0.5 Download simple_coverflow 0.0.5 archive
0.0.4 Apr 18, 2018 Go to the documentation of simple_coverflow 0.0.4 Download simple_coverflow 0.0.4 archive
0.0.3 Apr 13, 2018 Go to the documentation of simple_coverflow 0.0.3 Download simple_coverflow 0.0.3 archive
0.0.2 Apr 13, 2018 Go to the documentation of simple_coverflow 0.0.2 Download simple_coverflow 0.0.2 archive

Analysis

We analyzed this package on Apr 23, 2018, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.0.0-dev.49.0
  • pana: 0.10.6
  • Flutter: 0.3.2

Scores

Popularity:
Describes how popular the package is relative to other packages. [more]
0 / 100
Health:
Code health derived from static analysis. [more]
99 / 100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
100 / 100
Overall score:
Weighted score of the above. [more]
50
Learn more about scoring.

Platforms

Detected platforms: Flutter

References Flutter, and has no conflicting libraries.

Suggestions

  • Package is pre-v1 release.

    While there is nothing inherently wrong with versions of 0.*.*, it usually means that the author is still experimenting with the general direction API.

  • Fix analysis and formatting issues.

    Analysis or formatting checks reported 1 hint.

    Run flutter format to format lib/simple_coverflow.dart.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=1.19.0 <2.1.0
flutter 0.0.0
Transitive dependencies
collection 1.14.6 1.14.9
meta 1.1.2
sky_engine 0.0.99
typed_data 1.1.5
vector_math 2.0.6
Dev dependencies
flutter_test