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

Bug on use pickMode equals range without defaultDateRange or defaultDateRange.from equal null | undefined #9

Open
vitorgja opened this issue Nov 7, 2024 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@vitorgja
Copy link
Contributor

vitorgja commented Nov 7, 2024

Describe the bug

When using CalendarModalComponent with the pickMode == "range" parameter of CalendarModalOptions and not declaring "defaultDateRange" or declaring and not passing the “from” attribute, the display enters an error loop and crashes the display.

To Reproduce

const options: CalendarModalOptions = { pickMode: 'range' };
// or 
// const options: CalendarModalOptions = { pickMode: 'range', defaultDateRange: { from: null }};

const myCalendarModal = await this.modal.create({
    component: CalendarModal,
    componentProps: { options }
});
myCalendarModal.present();

Screenshot 2024-11-07 at 19 39 51

After that, an error loop starts

Code snippet

No response

Expected behavior

After the fix, we hope it won't go into an error loop

Node.js Version

v18.10.0

OS

OSX 14.6.1

Additional Library Versions

Angular 16.2.12

Additional context/Screenshots

No response

@heliomarpm heliomarpm self-assigned this Nov 15, 2024
@heliomarpm heliomarpm added the bug Something isn't working label Nov 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants