chart_components 0.1.4

  • Readme
  • Changelog
  • Example
  • Installing
  • 65

Chart_Components #

Animated bar chart for Flutter #

Customizable bar chart for Flutter. The component calculates min and max of data and resizes bars as needed.

bar chart

  • Add a data collection with the values to generate the bars.
  • Add a string collection with the labels to display below the items (optional)
  • Change bar size, margins and top corners as needed.
  • Change bar's color based on value. Callback, optional.
  • Enable/disable value on top of bar
  • Add an icon to the top of the bar based on item's value. Callback, optiona.
  • Enable/disable animation.
  • Change animation duration and curve through the properties

Animated calendar grid for Flutter #

calendar grid

  • Generates a grid for the selected month.
  • Changes day color through callback.
  • Animates changes. Animation curve and duration can be modified with the properties.

Demo #


Usage #

To use plugin, just import package import 'package:chart_components/chart_components.dart';

Example #

Check de example directory to access the project that implements the image shown above.

                            year: 2020,
                            month: 1,
                            getColorOfDay: DataRepository.getDayColor,
                            animationDuration: Duration(milliseconds: 1500),

                    child: BarChart(
                    data: data,
                    labels: labels,
                    dislplayValue: true,
                    reverse: true,
                    getColor: DataRepository.getColor,
                    getIcon: DataRepository.getIcon,
                    barWidth: 42,
                    barSeparation: 12,
                    animationDuration: Duration(milliseconds: 1800),
                    animationCurve: Curves.easeInOutSine,
                    itemRadius: 30,
                    iconHeight: 24,
                    footerHeight: 24,
                    headerValueHeight: 16,
                    roundValuesOnText: false,
                    lineGridColor: Colors.lightBlue,

[0.0.1] - 2020-01-30 #

  • An animated bar chart for Flutter. Easy to implement and customize.

[0.0.2] - 2020-02-08 #

  • An animated calendar grid for Flutter. Easy to implement and customize.

[0.1.1] - 2020-02-09 #

  • First version on pub.

[0.1.2] - 2020-02-09 #

  • Follow pub packages description guidelines.

[0.1.3] - 2020-02-14 #

  • Extra grid line on top.

[0.1.4] - 2020-02-16 #

  • White horizontal line in weekend background deleted.


import 'package:example/bar_chart_page.dart';
import 'package:flutter/material.dart';
import 'package:example/home_page.dart';

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

class MyApp extends StatelessWidget {
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      theme: ThemeData(
      initialRoute: HomePage.ID,
      routes: {
        HomePage.ID: (context) => HomePage(),
        BarChartPage.ID: (context) => BarChartPage(),

Use this package as a library

1. Depend on it

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

  chart_components: ^0.1.4

2. Install it

You can install packages from the command line:

with Flutter:

$ flutter pub get

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

3. Import it

Now in your Dart code, you can use:

import 'package:chart_components/chart_components.dart';
Describes how popular the package is relative to other packages. [more]
Code health derived from static analysis. [more]
Reflects how tidy and up-to-date the package is. [more]
Weighted score of the above. [more]
Learn more about scoring.

We analyzed this package on Mar 31, 2020, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.7.1
  • pana: 0.13.6
  • Flutter: 1.12.13+hotfix.8


Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.2.2 <3.0.0
flutter 0.0.0
Transitive dependencies
collection 1.14.11 1.14.12
meta 1.1.8
sky_engine 0.0.99
typed_data 1.1.6
vector_math 2.0.8
Dev dependencies