Primeng: Calendar disable specific dates and/or days such as holidays or weekends

Created on 27 Dec 2016  路  1Comment  路  Source: primefaces/primeng

I'm submitting a ...

[x] feature request

What is the motivation / use case for changing the behavior?
In some cases it might not be appropriate to let users select specific dates or days in the calendar, ie. could be weekends or holidays.

Proposed solution
Pass an array with dates to the calendar that shouldn't be selectable and apply a specific class to these dates to enable styling. This would enable users to disable specific holidays.

Pass an array with weekdays that should be disabled, ie. if a user wants to disable weekends they would pass in 0 and 6 (disabling Saturday and Sunday), apply specific class to disabled days to enable styling.

new feature

Most helpful comment

just wondering how can I update this feature in my current installed primeng project for angular 2 is
it npm install primeng@latest --save ? I am currently using "primeng": "^2.0.5", however I am not seeing this feature works here

>All comments

just wondering how can I update this feature in my current installed primeng project for angular 2 is
it npm install primeng@latest --save ? I am currently using "primeng": "^2.0.5", however I am not seeing this feature works here

Was this page helpful?
0 / 5 - 0 ratings