How to render a single Calendar in DateRangePicker in desktop mode

Hi,

I need to show a single calendar in the desktop view, similar to how it is rendered on a mobile device, I tried to do it with the following example as a reference ( How to render Daterangepicker with single calendar | Syncfusion ) but I have not been successful, any idea how to do it?


I currently have it like this




1 Reply 1 reply marked as answer

PK Priyanka Karthikeyan Syncfusion Team May 30, 2023 04:00 PM UTC

Hi Alberto,

We have prepared sample based on the shared information. Please find the code snippet and sample for your reference.

<DateRangePickerComponent
          ref={(calendar=> (daterangepickerInstance = calendar)}
          created={created.bind(this)}
></DateRangePickerComponent>
function created() {
    if (daterangepickerInstance) {
      daterangepickerInstance.isMobile = true;
    }
  }

Sample: https://stackblitz.com/edit/react-649gxp?file=index.js

Regards,

Priyanka K


Marked as answer
Loader.
Up arrow icon