1.0.4 • Published 12 months ago

react-native-customized-calendar v1.0.4

Weekly downloads
-
License
ISC
Repository
github
Last release
12 months ago

react-native-customized-calendar

Introduction

A React-Native calendar component to show a calendar. This calendar is fully customized, you can modify it as per your need.

  • Navigate to different date, month and year
  • Handle date with custom onPress function
  • Add reminders with custom colors
Calender ViewYear Selection

Calender View With Reminder | :-------------------------:

Installation

If using yarn:

yarn add react-native-customized-calendar

If using npm:

npm i react-native-customized-calendar

Usage

import Calender from 'react-native-customized-calendar'

Simply place a <Calender /> tag for showing calendar.

<View style={{ flex:1, }}>
        <Calender />
    </View>

For reminders pass reminders props as array

<View style={{ flex:1, }}>
        <Calender 
            reminders = [
                {date:2, color:"#40E0D0"},
                {date:11, color:"#FFBF00"},
                {date:14, color:"#9FE2BF"}
            ]
        />
    </View>

Documentation

Calender Component

NameDescriptionDefaultType
fontSizeFont size of entire component16Int
primaryColorPrimary color of component#2196F3String
onPressDayOnPress function of calender cell()=>{}Func
dateTextColorColor of date textblackString
currentDateTextColorColor of current date textwhiteString
showCurrentDateFrom this props you can set either current date should be highlight or notTrueBool
weekendBackgroundColorWeekend cell column background colorgrayString
weekdaysBackgroundColorWeekdays cell column background colorwhiteString
emptyDaysBackgroundColorBackground color of empty celllightgrayString
monthButtonTextColorCurrent selected month name text colorwhiteString
monthNameTextColorNext and previous month name text colorblackString
backForwardIconTintColorBack and Forward Icon tint colorgrayString
plusMinusButtonContainerBackgroundColorYear increment and decrement button background colorwhitesmokeString
plusMinusButtonContainerBorderColorYear increment and decrement button border colorlightgrayString
plusMinusIconTintColorPlus minus button icon tint colorgrayString
yearColorYear text colorblackString
yearSelectTextColorYear select button text colorblackString
selectButtonBackgroundColorYear select button background colorwhitesmokeString
selectButtonBorderColorYear select button border colorlightgrayString
containerStyleContainer style for additional styling{}Object
calenderItemContainerBorderColorCalender cell border colorlightgrayString
remindersSet reminders on calender with different colors[]Array
reminderDateColorDate text of reminders datewhiteString

Contributing

Pull requests are always welcome! Feel free to open a new GitHub issue for any changes that can be made.

Author

Jaweed Shuja

License

MIT