-
Notifications
You must be signed in to change notification settings - Fork 13
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
refactor(sbb-calendar): implement initial support for other date libraries #2511
Conversation
…aries BREAKING CHANGE: The `SbbDatepicker` property `selectedDate` has been renamed to `selected`. This also applies to the attribute `selected-date`, which has been renamed to `selected`. Additionally the `DateAdapter` (and `NativeDateAdapter`) have been superficially refactored. An important change is that the month is now `1`-based, instead of `0`-based.
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.
As it is fairly complex, it's difficult to determine wether everything is fully like expected :). But generally looks good.
As testing fails, there is so far no build to manually experiment with the changes.
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.
Codewise ok, but see chromatic changes, something with disabling buttons doesn't work anymore? or not the same?
Codecov ReportAttention: Patch coverage is
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## main #2511 +/- ##
=======================================
Coverage ? 93.85%
=======================================
Files ? 299
Lines ? 24495
Branches ? 2021
=======================================
Hits ? 22990
Misses ? 1476
Partials ? 29 ☔ View full report in Codecov by Sentry. |
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.
LGTM. thanks for the effort!
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.
Love the getter/setter approach on the calendar 👍
This change allows us in the future to support different date libraries. However, this is only the implementation for the calendar. Datepicker will be done in a different PR.
BREAKING CHANGE: The
SbbDatepicker
propertyselectedDate
has been renamed toselected
. This also applies to the attributeselected-date
, which has been renamed toselected
. Additionally theDateAdapter
(andNativeDateAdapter
) have been superficially refactored. An important change is that the month is now1
-based, instead of0
-based.