Giter Site home page Giter Site logo

scrollable_clean_calendar's People

Contributors

edunatalec avatar fabiofiuza avatar fpizzicol avatar inceptusp avatar luciencorreia avatar rodrigodobbin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

scrollable_clean_calendar's Issues

Range color is not carried over to other months

Is there a problem when selecting dates between months? When selecting a date for example January 20th to February 20th, the color of the range is not maintained. Any suggestion on how to resolve?

Start day of week

Thanks for the great library.
When I change the 'startWeekDay' to DateTime.sunday, only Sunday date be shown, others invisible.
I tried to change all days of the week as the start day, but only Monday is ok.
I used the sample of this git(basic version).
If you need data or something from me, plz let me know.
Thanks in advance.

Screen Shot 2021-06-04 at 3 03 50 PM

_buildMonthLabelRow should concatenate two date formats to be valid for all locales

_buildMonthLabelRow should concatenate two date formats to be valid for all locales:

DateFormat('MMMM yyyy', widget.locale)
.format(
DateTime(month.year, month.month),
)
.capitalize(),

should be:

DateFormat('MMMM', widget.locale).format(DateTime(month.year, month.month)).capitalize() + ' ' + DateFormat('yyyy', widget.locale).format(DateTime(month.year, month.month))

otherwise when language has more complex variation by cases it will display inappropriate value.

eg. October 2021 in Polish is currently displayed as Października 2021 and it should be Październik 2021

Disable already booked dates

This package has very clean and simple beautiful implementations. i just need the feature to disable the dates which are already booked.

Initial focus date

Cloud add initial focus date ?
Like minimum date time is 2000.1.1, but i want focus on today in first time.

How to disable scrool?

Hello good morning, how do I disable the calendar scrool? I would like to have only one calendar displayed on the screen. If you have an example even better. Thank you very much

Improve the test coverage

With the new major release version (1.0.0), we didn't do a good coverage test.

So it is good to work on the test coverage to improve it.

Wrong now day

Hello, thank you for great package, but I saw 2 issues, first of all I run example and start date is 28 Tuesday, but today is 27 Tuesday(see screenshots). Second: how can I set start week from Monday ?
IMG_7113
IMG_7114

show year and month opposite in month header

Hi, I love this package cuz its conviniet and we can customize well.

One thing.
I have issue and want to suggest that month header will be able to show month and year opposite style.

defalut 
=> 2月 2023年

hope
=> 2023年 2月

Defalut expression is not fine in Japanese. So if we can use Widget like this , it will be great.

ScrollableCleanCalendar(
  monthHeader : MonthHeader.monthAndYear
  monthHeader : MonthHeader.yearAndMonth
)

I know there is dayBuilder, but it will be more usefull.
please consider it. thank you.

dai10512

Add widgets

It's possible to add widgets besides the calendar? I want to add a container above the calendar and a button, but when I try to implement it, I get an error.

dayBuilder rebuilds every time when I click onDayTapped

Is it correct that the calendar rebuilds its daybuilder each time it runs onDayTapped?

calendarController = CleanCalendarController(
      //minDate: DateTime.now(),
      //maxDate: DateTime.now().add(const Duration(days: 365)),
      minDate: DateTime(2021, 9, 2),
      maxDate: DateTime(2022, 3, 1),
      onRangeSelected: (firstDate, secondDate) {},
      onDayTapped: (date) {
        print("Clean Calendar: " + date.toString());

...

ScrollableCleanCalendar(
                  locale: language,
                  scrollController: _controller,
                  calendarController: calendarController,
                  layout: Layout.DEFAULT,
                  calendarCrossAxisSpacing: 0,
                  dayBuilder: (context, values) {
                    print("values day: " + values.day.toString());

This takes very long because it rebuilds all the days from scratch. II think it is not so good for the performance.

Make scrollController optional

We use the calendar inside a sliding sheet with a jumpTo(offset) with the previous scrollController. It's generic to other components and we need to keep the scrollController. Is it possible to make it optional again ?

daySelected color change to unselected color when update ui in onDayTapped method

CleanCalendarController get calendarController => CleanCalendarController(
        minDate: DateTime.now(),
        maxDate: DateTime.now().add(const Duration(days: 32)),
        onDayTapped: (d) {
          read.onChangedDateMain(d); <<<<<<<<<<<<<<<<<<calling method
          log('${d.timeZoneOffset.inHours}');
        },
        rangeMode: false,
        weekdayStart: DateTime.monday,
      );
void onChangedDateMain(DateTime date) {
    final formated = DateFormat('d MMMM,EEEE', 'en').format(date);
    choosedDateMain = formated;
    notifyListeners();
  }

New features

Hello,

I would like to submit a pull request with several new features:

  1. An initialMonthIndex parameter for opening the calendar on a specific date. This parameter will be used within the scrollable_positioned_list ListView. I couldn't use jumpToMonth because it throws a null error during runtime when used inside initState, and using Future.delayed to work around it seems unusual.
  2. The ability to incorporate custom logic for onDayClick. This would allow users to modify the date picking logic, such as changing the start date without removing the end date.
    What are your thoughts on these changes?

Thank you.

Init date

How can I set the initial date and scroll to it?

If I have

minDate: DateTime(2010, 10, 1),
maxDate: DateTime(2030, 3, 1),

how can I scroll to DateTime.now() ?
Maybe it could work with scrollController. But jumpTo is not working because the months have an individual height.
Do you have a minimal example how this can be done?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.