React-calendar: Disable Click of Label in Navigation Bar

Created on 26 May 2020  路  4Comments  路  Source: wojtekmaj/react-calendar

Is there a way to disable the functionality when you click the label within the navigation bar? I want to be able to use next and previous buttons, but have nothing happen when the label is clicked.

I'm using double month view, and when i click the label (ie May 2020 - June 2020) it changes to year view. I've stopped this by explicitly setting view="month" but now on click of this, it resets the calendar to the beginning of the year.

Most helpful comment

@mikeyharris89 as per this other issue https://github.com/wojtekmaj/react-calendar/issues/242 you just need to set maxDetail, minDetail and view and if you want you can even disable the navigation bar

All 4 comments

@mikeyharris89 as per this other issue https://github.com/wojtekmaj/react-calendar/issues/242 you just need to set maxDetail, minDetail and view and if you want you can even disable the navigation bar

Thanks @giacomocerquone!

Awesome! Yeah it doesn't really indicate that anywhere in the docs so thanks for the quick response

@mikeyharris89 as per this other issue #242 you just need to set maxDetail, minDetail and view and if you want you can even disable the navigation bar

@giacomocerquone how do I disable the controls ?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

tranvula picture tranvula  路  4Comments

Chusynuk picture Chusynuk  路  3Comments

dumkanki picture dumkanki  路  4Comments

Muttakee31 picture Muttakee31  路  4Comments

wojtekmaj picture wojtekmaj  路  5Comments