calendarro 0.0.5

  • Example
  • Installing
  • Versions
  • 81

Calendarro #

Calendar widget library for Flutter apps. Offers multiple ways to customize the widget.

Getting Started #

Installation #

Add dependency to your pubspec.yaml:

calendarro: ^0.0.5

Basic use #

First, add an import to your code:

import 'package:calendarro/calendarro.dart';

Add a widget to your code:

  startDate: DateUtils.getFirstDayOfCurrentMonth(),
  endDate: DateUtils.getLastDayOfCurrentMonth()

alt tag

Customization #

alt tag

<b>1. Display Mode</b> - If you prefer to operate on multiple rows to see whole month, use:

  displayMode: DisplayMode.MONTHS,

<b>2. Selection Mode</b> - If you want to select multiple dates, use:

  selectionMode: SelectionMode.MULTI,

<b>3. Weekday Labels</b> - If you want to provide your own row widget for displaying weekday names, use:

  weekdayLabelsRow: CustomWeekdayLabelsRow()

you can create your CustomWeekdayLabelsRow by looking at default CalendarroWeekdayLabelsView.

<b>4. Day Tile Builder</b> - If you want to build day tiles your own way, you can use:

  dayTileBuilder: CustomDayTileBuilder()

you can create your CustomDayTileBuilder looking upon DefaultDayTileBuilder.

<b>5. Initial selected dates</b> - When you want some dates to be selected from the scratch, use selectedDate (SelectionMode.SINGLE) or selectedDates (SelectionMode.MULTI) arguments:

  selectedDate: DateTime(2018, 8, 1)
  selectedDates: [DateTime(2018, 8, 1), DateTime(2018, 8, 8)]

you can create your CustomDayTileBuilder looking upon DefaultDayTileBuilder.

Selecting date callback #

If you want to get a callback when a date tile is clicked, there is onTap param:

    onTap: (date) {
        //your code

Advanced usage: #

For more advanced usage see:

[0.0.5] 17 November 2018

  • Fix counting pages for DisplayMode.WEEKS due to bug for February.

[0.0.4] 17 November 2018

  • Change Calendarro height in month mode

[0.0.3] 17 November 2018

  • Add onTap callback for Calendarro

[0.0.2] 3 September 2018

  • Fix

[0.0.1] - 6 August 2018

  • Introduce Calendarro!


sample #

sample app

Getting Started #

For help getting started with Flutter, view our online documentation.

Use this package as a library

1. Depend on it

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

  calendarro: ^0.0.5

2. Install it

You can install packages from the command line:

with Flutter:

$ flutter packages get

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

3. Import it

Now in your Dart code, you can use:

import 'package:calendarro/calendarro.dart';
Version Uploaded Documentation Archive
0.0.5 Feb 4, 2019 Go to the documentation of calendarro 0.0.5 Download calendarro 0.0.5 archive
0.0.4 Jan 3, 2019 Go to the documentation of calendarro 0.0.4 Download calendarro 0.0.4 archive
0.0.3 Nov 17, 2018 Go to the documentation of calendarro 0.0.3 Download calendarro 0.0.3 archive
0.0.2 Sep 3, 2018 Go to the documentation of calendarro 0.0.2 Download calendarro 0.0.2 archive
0.0.1 Aug 7, 2018 Go to the documentation of calendarro 0.0.1 Download calendarro 0.0.1 archive
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 Feb 14, 2019, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.1.0
  • pana: 0.12.13
  • Flutter: 1.2.0


Detected platforms: Flutter

References Flutter, and has no conflicting libraries.

Health suggestions

Fix lib/calendarro.dart. (-1.49 points)

Analysis of lib/calendarro.dart reported 3 hints:

line 18 col 7: This class (or a class which this class inherits from) is marked as '@immutable', but one or more of its instance fields are not final: Calendarro.startDate, Calendarro.endDate, Calendarro.displayMode, Calendarro.selectionMode, Calendarro.dayTileBuilder, Calendarro.weekdayLabelsRow, Calendarro.onTap, Calendarro.selectedDate, Calendarro.selectedDates, Calendarro.startDayOffset, Calendarro.state

line 94 col 30: The operator x ~/ y is more efficient than (x / y).toInt().

line 232 col 7: Avoid empty statements.

Fix lib/calendarro_page.dart. (-1.49 points)

Analysis of lib/calendarro_page.dart reported 3 hints:

line 3 col 8: Unused import: 'package:calendarro/default_weekday_labels_row.dart'.

line 6 col 7: This class (or a class which this class inherits from) is marked as '@immutable', but one or more of its instance fields are not final: CalendarroPage.pageStartDate, CalendarroPage.pageEndDate, CalendarroPage.weekdayLabelsRow, CalendarroPage.startDayOffset

line 8 col 16: Name non-constant identifiers using lowerCamelCase.

Fix lib/default_day_tile.dart. (-0.50 points)

Analysis of lib/default_day_tile.dart reported 1 hint:

line 5 col 7: This class (or a class which this class inherits from) is marked as '@immutable', but one or more of its instance fields are not final:, CalendarroDayItem.calendarroState, CalendarroDayItem.onTap

Fix additional 3 files with analysis or formatting issues.

Additional issues in the following files:

  • lib/date_utils.dart (Run flutter format to format lib/date_utils.dart.)
  • lib/default_day_tile_builder.dart (Run flutter format to format lib/default_day_tile_builder.dart.)
  • lib/default_weekday_labels_row.dart (Run flutter format to format lib/default_weekday_labels_row.dart.)

Maintenance suggestions

The package description is too short. (-19 points)

Add more detail to the description field of pubspec.yaml. Use 60 to 180 characters to describe the package, what it does, and its target use case.

Package is pre-v0.1 release. (-10 points)

While nothing is inherently wrong with versions of 0.0.*, it might mean that the author is still experimenting with the general direction of the API.


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