Download this source code for
5 USD


Download this source code for
5 USD


Download this source code for
5 USD


Download this source code for
5 USD

calendar widget for flutter that is swipeable horizontally. this widget can help you build your own widget highly customizable.

swipeable horizontally calendar
rectangular style
calendar2
circular style
calendar3
no border
calendar4
marked dates

getting started

for help getting started with flutter, view our online documentation.

props

propstypesdefaultvalues
weekdays [‘sun’, ‘mon’, ‘tue’, ‘wed’, ‘thur’, ‘fri’, ‘sat’]
viewportfractiondouble1.0
prevdaystextstyletextstyle 
daystextstyletextstyle 
nextdaystextstyletextstyle 
prevmonthdaybordercolorcolorcolors.transparent
thismonthdaybordercolorcolorcolors.transparent
nextmonthdaybordercolorcolorcolors.transparent
daypaddingdouble2.0
heightdoubledouble.infinity
widthdoubledouble.infinity
todaytextstyletextstylefontsize: 14.0, color: colors.white
daybuttoncolorcolorcolors.red
todaybordercolorcolorcolors.red
todaybuttoncolorcolorscolors.red
selecteddatetimedatetime 
selecteddaytextstyletextstylefontsize: 14.0, color: colors.white
selecteddaybordercolorcolorcolors.green
selecteddaybuttoncolorcolorcolors.green
dayshavecircularborderbool 
ondaypressedfunc 
weekdaytextstyletextstylefontsize: 14.0, color: colors.deeporange
iconcolorcolorcolors.blueaccent
headertexttexttext('${dateformat.ymmm().format(this._dates[1])}')
weekendtextstyletextstylefontsize: 14.0, color: colors.pinkaccent
markeddateslist<datetime[]
markeddatecolorcolorcolors.blueaccent
markeddatewidgetcolorpositioned(child: container(color: colors.blueaccent, height: 4.0, width: 4.0), bottom: 4.0, left: 18.0);
headermarginedgetinsetsconst edgeinsets.symmetric(vertical: 16.0)
childaspectratiodouble1.0
weekdaymarginedgeinsetsconst edgeinsets.only(bottom: 4.0)

install

add flutter_calendar_carousel as a dependency in pubspec.yaml
for help on adding as a dependency, view the documentation.

usage

import 'package:flutter_calendar_carousel/flutter_calendar_carousel.dart' show calendarcarousel;
widget widget() {
  return container(
    margin: edgeinsets.symmetric(horizontal: 16.0),
    child: calendarcarousel(
      current: datetime.now(),
      ondaypressed: (datetime date) {
        this.setstate(() => _currentdate = date);
      },
      thismonthdaybordercolor: colors.grey,
      height: 420.0,
      selecteddatetime: _currentdate,
      dayshavecircularborder: false, /// null for not rendering any border, true for circular border, false for rectangular border
//          weekendstyle: textstyle(
//            color: colors.red,
//          ),
//          weekdays: null, /// for pass null when you do not want to render weekdays
//          headertext: container( /// example for rendering custom header
//            child: text('custom header'),
//          ),
    ),
  );
}

todo

  • [x] render weekdays.
  • [x] customizable headerwidget.
  • [x] set weekdays visibility.
  • [x] customizable textstyles for days in weekend.
  • [x] marked dates.
  • [ ] multiple days selections.
  • [ ] widget test.

Download this source code for
5 USD


Download this source code for
5 USD


Download this source code for
5 USD


Download this source code for
5 USD

Comments are closed.