New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pass modifiers to renderDay #237

Closed
davincho opened this Issue Dec 2, 2016 · 6 comments

Comments

3 participants
@davincho

davincho commented Dec 2, 2016

I would need access to modifiers within the renderDay callback. What's about passing not only day but also dayModifers to the callback (see

{this.props.renderDay(day)}
)

Before: {this.props.renderDay(day)}
After: {this.props.renderDay(day, dayModifiers)}

@jirikolarik

This comment has been minimized.

Show comment
Hide comment
@jirikolarik

jirikolarik Jan 31, 2017

I'd like to see this feature as well. What do you think @gpbl? It will allow you to render specific content based on modifier. I can create PR if you wish

jirikolarik commented Jan 31, 2017

I'd like to see this feature as well. What do you think @gpbl? It will allow you to render specific content based on modifier. I can create PR if you wish

@gpbl

This comment has been minimized.

Show comment
Hide comment
@gpbl

gpbl Feb 9, 2017

Owner

I'd like first to understand the use case, as I've in mind a new feature that may help in this direction :)

The modifiers are intended to add a CSS classname to the day cell. What is your case @davincho, @jirikolarik ?

Owner

gpbl commented Feb 9, 2017

I'd like first to understand the use case, as I've in mind a new feature that may help in this direction :)

The modifiers are intended to add a CSS classname to the day cell. What is your case @davincho, @jirikolarik ?

@gpbl gpbl added the discussion 💬 label Feb 9, 2017

@jirikolarik

This comment has been minimized.

Show comment
Hide comment
@jirikolarik

jirikolarik Feb 10, 2017

If we have dayModifiers passed to renderDay object, we know how that date differentiate between others. For example, if the date is "occupied", we can currently make it grey, green or yellow, but with this information in renderDay method we could also render different content as the actual word "occupied" without checking if the date is occupied again inside the method.

I'll check this new feature, maybe it's something we can utilise for this use case

jirikolarik commented Feb 10, 2017

If we have dayModifiers passed to renderDay object, we know how that date differentiate between others. For example, if the date is "occupied", we can currently make it grey, green or yellow, but with this information in renderDay method we could also render different content as the actual word "occupied" without checking if the date is occupied again inside the method.

I'll check this new feature, maybe it's something we can utilise for this use case

@gpbl gpbl added new feature and removed discussion 💬 labels Feb 10, 2017

@gpbl

This comment has been minimized.

Show comment
Hide comment
@gpbl

gpbl Feb 10, 2017

Owner

Thanks @jirikolarik for the feedback! As this is a simple to implement, it's going to be added in the next minor release!

Owner

gpbl commented Feb 10, 2017

Thanks @jirikolarik for the feedback! As this is a simple to implement, it's going to be added in the next minor release!

@davincho

This comment has been minimized.

Show comment
Hide comment
@davincho

davincho Feb 10, 2017

Yes having the same use cases as @jirikolarik described. Looking forward for next minor release!

davincho commented Feb 10, 2017

Yes having the same use cases as @jirikolarik described. Looking forward for next minor release!

@gpbl gpbl added this to the v4 milestone Feb 10, 2017

@gpbl gpbl closed this in ac9ba6f Feb 10, 2017

@gpbl

This comment has been minimized.

Show comment
Hide comment
@gpbl

gpbl Feb 14, 2017

Owner

Released as v4.0. It is a major release because of some minor breaking changes – it should be easy to upgrade!

Owner

gpbl commented Feb 14, 2017

Released as v4.0. It is a major release because of some minor breaking changes – it should be easy to upgrade!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment