react-native-calendars icon indicating copy to clipboard operation
react-native-calendars copied to clipboard

How to modify the first Item in a Day using firstItemInDay boolean?

Open BillyFigueroa opened this issue 8 years ago • 4 comments

Please make our job easier by filling this template out to completion. If you're requesting a feature instead of reporting a bug, please feel free to skip the Environment and Reproducible Demo sections.

Description

I would like to know if the first item in a day can be modified in terms of its container height etc. When using renderItem function there is a boolean called firstItemInDay that can check if the item is the first in the day but how do I use this to potentially change the styling on that item?

Environment

  • iMac with latest iOS
  • "react-native-calendars": "^1.17.0",
  • Expo
  • Simulator (iPhone X) Version 10.0 (SimulatorApp-835.5)

BillyFigueroa avatar Feb 07 '18 16:02 BillyFigueroa

Hi, so you can use this prop and render a custom component according to it. I don't see there should be a problem?

tautvilas avatar Mar 01 '18 14:03 tautvilas

So check if the value is true and then return a different component? Any examples on how to modify the "day" component?

BillyFigueroa avatar Mar 01 '18 15:03 BillyFigueroa

Even i need to return diiferent component to dirrerent dates.Any examples on how to modify the "day" component?

sumanth234 avatar Apr 16 '18 11:04 sumanth234

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Aug 23 '20 02:08 stale[bot]