Multiple-Dates-Picker-for-jQuery-UI icon indicating copy to clipboard operation
Multiple-Dates-Picker-for-jQuery-UI copied to clipboard

Keeping some dates always on, and custom CSS for specific dates

Open blatx opened this issue 8 years ago • 1 comments

I'm trying to find a good way to forbid removing specific days from the list of selected, thus, these days should always remain on, no matter how often the user clicks on them. It's like a combination of "disabled" and "on".

For these days I'd like to apply a custom CSS class, so I can determine myself how they look. They should not be greyed out.

By extension, I'd like to be able to associate specific dates in a list with their own CSS classes.

Is that already feasible, for example in event code, or does this need some hacking?

blatx avatar Jul 13 '17 09:07 blatx

Just adding the same date to both the "disabled" and to the "picked" array of dates does, more or less, what I want, except for the lack of custom CSS.

It looks like I have to override beforeShowDay for both features, but if I just do that, it'll mess up multiDatesPicker's own function.

It would help if I could call the built-in function, and post-process its results, adding my own CSS classes to the second value in the returned array. I'd prefer not to have to copy the source from this function.

blatx avatar Jul 13 '17 10:07 blatx