-
Notifications
You must be signed in to change notification settings - Fork 308
feat: Fixes issue #382: Add Multi-Day View Support #463
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
Conversation
|
I haven’t updated the documentation yet. I would like to confirm the direction first before proceeding with the documentation and further refinements. |
PRBaraiya
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please check all the comments.
Aside from this, please check and update documentation if necessary, remove unnecessary commented code or add notes if commented code can be reused in future and resolve merge conflicts.
Thanks for raising this PR. We are looking forward to your response.
| daysInView: 3, | ||
| width: width, | ||
| showLiveTimeLineInAllDays: true, | ||
| eventArranger: SideEventArranger(maxWidth: 30), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove max width from this.
| int getMultiDayDifference( | ||
| {required DateTime startDate, | ||
| required DateTime endDate, | ||
| daysInView = 3}) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
define type here
| required this.heightPerMinute, | ||
| required this.startHour, | ||
| this.endHour = Constants.hoursADay, | ||
| this.onlyShowToday = false}) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
refactor this code
| @override | ||
| Widget build(BuildContext context) { | ||
| final filteredDates = _filteredDate(); | ||
| return Container( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we use sizedbox here?
| : VerticalDirection.down, | ||
| crossAxisAlignment: CrossAxisAlignment.end, | ||
| children: [ | ||
| Container( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use DecoratedBox
| ), | ||
| SizedBox( | ||
| width: widget.width, | ||
| child: Container( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
^^
| (index) { | ||
| final fullDayEventList = widget.controller | ||
| .getFullDayEvent(filteredDates[index]); | ||
| return Container( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
^^
|
Changes are merged with #482 |
Description
I have added a multi-day view to fulfill my current requirements. Instead of directly modifying the existing week view, I created a new MultiDayView. However, if needed, I can integrate the changes directly into WeekView.
For the week view, I believe that when the app opens in this mode, the first visible day should always be today, while ensuring that navigation and scrolling behaviors align with the expected restrictions.
Currently, I have only utilized properties like showWeek and weekdays, which are not fully applicable to the multi-day view.
Additionally, I noticed your other branch that implements a 3-day view, but it has a bug where the selected date does not match the navigation target. The core issue seems to stem from relying directly on the number of days in a week for calculations, which causes inconsistencies.
I have also added a single-day timeline display, as well as a bottom line beneath the weekly view for better visual clarity.



Checklist
fix:,feat:,docs:etc).docsand added dartdoc comments with///.examplesordocs.Migration instructions
Related Issues
Closes #382