the-calendar
Calendar of the-components
Installation
$ npm install the-calendar --save
Usage
'use strict' const events = id: 1 node: <span>This is event01</span> start: end: + 60 * 60 * 1000 { console } id: 2 node: <span>This is event02</span> start: + 24 * 60 * 60 * 1000 end: + 25 * 60 * 60 * 1000 { console } Component { superprops thisstate = view: 'month' date: } { return <div> <TheButtonStyle/> <TheCalendarStyle/> <TheCalendar onNavigate= this onView= this date=thisstatedate view=thisstateview events=events > </TheCalendar> </div> }
Components
TheCalendar
Calendar of the-components
Props
Name | Type | Description | Default |
---|---|---|---|
date |
object | Showing date object | `` |
events |
arrayOf object | Events to show | [] |
lang |
string | Lang | 'en' |
onNavigate |
func | Navigate to date | null |
onView |
func | Change view | null |
view |
string | View of calendar | 'month' |
views |
arrayOf string | ['month', 'day'] |
|
toolbar |
false |
TheCalendarStyle
Style for TheCalendar
Props
Name | Type | Description | Default |
---|---|---|---|
options |
object | Style options | {} |
License
This software is released under the MIT License.