react-bootstrap-datetimerangepicker icon indicating copy to clipboard operation
react-bootstrap-datetimerangepicker copied to clipboard

Predefined ranges to work onApply()

Open NehaSharma2304 opened this issue 7 years ago • 1 comments

I am trying to use predefined range feature of this library with custom calendar and time picker, but predefined range works on selection of default range but my custom calendar works on click of apply button. It looks inconsistent, can someone help?

NehaSharma2304 avatar Oct 13 '17 19:10 NehaSharma2304

You can set the autoApply prop to true which will hide the apply and cancel buttons and trigger onApply after selecting a custom date range. This is specified in the docs, I've not tried it myself so not sure it works. If that doesn't work you could potentially subscribe to the onChange event that is fired when a date is selected, and use those dates when an endDate is chosen.

cmyers avatar Oct 13 '17 20:10 cmyers