Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set selecting limite. #2

Closed
aminejafur opened this issue Dec 19, 2018 · 1 comment
Closed

Set selecting limite. #2

aminejafur opened this issue Dec 19, 2018 · 1 comment

Comments

@aminejafur
Copy link

Hi, first of all i want to say thanks for this awsome package.

• I was wondring and trying to set a limite for selected dates ( by default you can select more than 5++) but i want to stop the select in the UI once the user has selected 5 days.

• And please how can i set the " endDate " to current day.

Thanks.

@adamstyrc
Copy link
Owner

Hey,
I'm very sorry for long response :( I was out of the project.

I was wondring and trying to set a limite for selected dates ( by default you can select more than 5++) but i want to stop the select in the UI once the user has selected 5 days.

Currently if you want to implement a limit for selecting date you would have to implement your own
DayTileBuilder . Please look into DefaultDayTileBuilder and CalendarroDayItem . You could prepare similar method to CalendarroDayItem.handleTap() but with check on the limitation you want using calendarroState.selectedDates.size .
Then pass your DayTileBuilder in Calendarro constructor field :)

Maybe I will add your idea to v0.0.5 but there is no specific plan for release yet ;)

• And please how can i set the " endDate " to current day.
e.g.
Calendarro(endDate: DateTime.now())
:)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants